Imported Upstream version 1.41.0 upstream/1.41.0
authorJinWang An <jinwang.an@samsung.com>
Wed, 1 Dec 2021 08:53:25 +0000 (17:53 +0900)
committerJinWang An <jinwang.an@samsung.com>
Wed, 1 Dec 2021 08:53:25 +0000 (17:53 +0900)
1941 files changed:
.clang-format
.gitattributes [new file with mode: 0644]
.github/ISSUE_TEMPLATE/bug_report.md
.github/ISSUE_TEMPLATE/cleanup_request.md
.github/ISSUE_TEMPLATE/feature_request.md
.github/ISSUE_TEMPLATE/question.md
.github/labeler.yml [new file with mode: 0644]
.github/pull_request_template.md
.github/workflows/happy-pancakes.yml [new file with mode: 0644]
.github/workflows/pr-auto-fix.yaml [new file with mode: 0644]
.github/workflows/pr-auto-tag.yaml [new file with mode: 0644]
BUILD
CMakeLists.txt
CONCEPTS.md
Makefile
WORKSPACE
_metadata.py
bazel/grpc_build_system.bzl
bazel/grpc_deps.bzl
build_autogenerated.yaml
build_config.rb
build_handwritten.yaml
cmake/abseil-cpp.cmake
config.m4
config.w32
doc/core/moving-to-c++.md
doc/environment_variables.md
doc/g_stands_for.md
doc/grpc_xds_features.md
doc/interop-test-descriptions.md
examples/android/binder/java/io/grpc/binder/cpp/example/AndroidManifest.xml
examples/android/binder/java/io/grpc/binder/cpp/example/BUILD
examples/android/binder/java/io/grpc/binder/cpp/example/native.cc
examples/android/binder/java/io/grpc/binder/cpp/exampleserver/AndroidManifest.xml [new file with mode: 0644]
examples/android/binder/java/io/grpc/binder/cpp/exampleserver/AndroidManifest_endpoint.xml [new file with mode: 0644]
examples/android/binder/java/io/grpc/binder/cpp/exampleserver/BUILD [new file with mode: 0644]
examples/android/binder/java/io/grpc/binder/cpp/exampleserver/ButtonPressHandler.java [new file with mode: 0644]
examples/android/binder/java/io/grpc/binder/cpp/exampleserver/ExportedEndpointService.java [new file with mode: 0644]
examples/android/binder/java/io/grpc/binder/cpp/exampleserver/MainActivity.java [new file with mode: 0644]
examples/android/binder/java/io/grpc/binder/cpp/exampleserver/native.cc [new file with mode: 0644]
examples/android/binder/java/io/grpc/binder/cpp/exampleserver/res/layout/activity_main.xml [new file with mode: 0644]
examples/android/binder/java/io/grpc/binder/cpp/exampleserver/res/values/strings.xml [new file with mode: 0644]
examples/cpp/helloworld/greeter_async_client2.cc
examples/cpp/keyvaluestore/client.cc
examples/cpp/route_guide/route_guide_callback_client.cc
examples/cpp/route_guide/route_guide_callback_server.cc
examples/cpp/route_guide/route_guide_client.cc
examples/cpp/route_guide/route_guide_server.cc
examples/php/composer.json
examples/php/greeter_and_routeguide_multi_server.php
examples/php/greeter_server.php
examples/php/route_guide/route_guide_server.php
gRPC-C++.podspec
gRPC-Core.podspec
gRPC-ProtoRPC.podspec
gRPC-RxLibrary.podspec
gRPC.podspec
grpc.gemspec
grpc.gyp
include/grpc/byte_buffer.h
include/grpc/byte_buffer_reader.h
include/grpc/event_engine/endpoint_config.h
include/grpc/event_engine/event_engine.h
include/grpc/event_engine/port.h
include/grpc/event_engine/slice_allocator.h
include/grpc/fork.h
include/grpc/grpc.h
include/grpc/grpc_posix.h
include/grpc/impl/codegen/atm.h
include/grpc/impl/codegen/atm_gcc_atomic.h
include/grpc/impl/codegen/atm_gcc_sync.h
include/grpc/impl/codegen/atm_windows.h
include/grpc/impl/codegen/byte_buffer.h
include/grpc/impl/codegen/byte_buffer_reader.h
include/grpc/impl/codegen/compression_types.h
include/grpc/impl/codegen/connectivity_state.h
include/grpc/impl/codegen/fork.h
include/grpc/impl/codegen/gpr_slice.h
include/grpc/impl/codegen/gpr_types.h
include/grpc/impl/codegen/grpc_types.h
include/grpc/impl/codegen/log.h
include/grpc/impl/codegen/port_platform.h
include/grpc/impl/codegen/propagation_bits.h
include/grpc/impl/codegen/slice.h
include/grpc/impl/codegen/status.h
include/grpc/impl/codegen/sync.h
include/grpc/impl/codegen/sync_abseil.h
include/grpc/impl/codegen/sync_custom.h
include/grpc/impl/codegen/sync_generic.h
include/grpc/impl/codegen/sync_posix.h
include/grpc/impl/codegen/sync_windows.h
include/grpc/slice.h
include/grpc/status.h
include/grpc/support/atm.h
include/grpc/support/atm_gcc_atomic.h
include/grpc/support/atm_gcc_sync.h
include/grpc/support/atm_windows.h
include/grpc/support/log.h
include/grpc/support/port_platform.h
include/grpc/support/sync.h
include/grpc/support/sync_abseil.h
include/grpc/support/sync_custom.h
include/grpc/support/sync_generic.h
include/grpc/support/sync_posix.h
include/grpc/support/sync_windows.h
include/grpc/support/time.h
include/grpcpp/client_context.h
include/grpcpp/completion_queue.h
include/grpcpp/create_channel_posix.h
include/grpcpp/generic/async_generic_service.h
include/grpcpp/grpcpp.h
include/grpcpp/impl/call.h
include/grpcpp/impl/client_unary_call.h
include/grpcpp/impl/codegen/async_generic_service.h
include/grpcpp/impl/codegen/async_stream.h
include/grpcpp/impl/codegen/async_unary_call.h
include/grpcpp/impl/codegen/byte_buffer.h
include/grpcpp/impl/codegen/call.h
include/grpcpp/impl/codegen/call_hook.h
include/grpcpp/impl/codegen/call_op_set.h
include/grpcpp/impl/codegen/call_op_set_interface.h
include/grpcpp/impl/codegen/callback_common.h
include/grpcpp/impl/codegen/channel_interface.h
include/grpcpp/impl/codegen/client_callback.h
include/grpcpp/impl/codegen/client_context.h
include/grpcpp/impl/codegen/client_interceptor.h
include/grpcpp/impl/codegen/client_unary_call.h
include/grpcpp/impl/codegen/completion_queue.h
include/grpcpp/impl/codegen/completion_queue_tag.h
include/grpcpp/impl/codegen/config.h
include/grpcpp/impl/codegen/config_protobuf.h
include/grpcpp/impl/codegen/core_codegen.h
include/grpcpp/impl/codegen/core_codegen_interface.h
include/grpcpp/impl/codegen/create_auth_context.h
include/grpcpp/impl/codegen/delegating_channel.h
include/grpcpp/impl/codegen/grpc_library.h
include/grpcpp/impl/codegen/intercepted_channel.h
include/grpcpp/impl/codegen/interceptor.h
include/grpcpp/impl/codegen/interceptor_common.h
include/grpcpp/impl/codegen/message_allocator.h
include/grpcpp/impl/codegen/metadata_map.h
include/grpcpp/impl/codegen/method_handler.h
include/grpcpp/impl/codegen/method_handler_impl.h
include/grpcpp/impl/codegen/proto_buffer_reader.h
include/grpcpp/impl/codegen/proto_buffer_writer.h
include/grpcpp/impl/codegen/proto_utils.h
include/grpcpp/impl/codegen/rpc_method.h
include/grpcpp/impl/codegen/rpc_service_method.h
include/grpcpp/impl/codegen/security/auth_context.h
include/grpcpp/impl/codegen/serialization_traits.h
include/grpcpp/impl/codegen/server_callback.h
include/grpcpp/impl/codegen/server_callback_handlers.h
include/grpcpp/impl/codegen/server_context.h
include/grpcpp/impl/codegen/server_interceptor.h
include/grpcpp/impl/codegen/server_interface.h
include/grpcpp/impl/codegen/service_type.h
include/grpcpp/impl/codegen/slice.h
include/grpcpp/impl/codegen/status.h
include/grpcpp/impl/codegen/status_code_enum.h
include/grpcpp/impl/codegen/string_ref.h
include/grpcpp/impl/codegen/stub_options.h
include/grpcpp/impl/codegen/sync.h
include/grpcpp/impl/codegen/sync_stream.h
include/grpcpp/impl/codegen/time.h
include/grpcpp/impl/grpc_library.h
include/grpcpp/impl/rpc_method.h
include/grpcpp/impl/rpc_service_method.h
include/grpcpp/impl/serialization_traits.h
include/grpcpp/impl/service_type.h
include/grpcpp/security/alts_context.h
include/grpcpp/security/alts_util.h
include/grpcpp/security/auth_context.h
include/grpcpp/security/authorization_policy_provider.h
include/grpcpp/security/credentials.h
include/grpcpp/security/server_credentials.h
include/grpcpp/security/tls_certificate_provider.h
include/grpcpp/security/tls_credentials_options.h
include/grpcpp/server.h
include/grpcpp/server_builder.h
include/grpcpp/server_context.h
include/grpcpp/server_posix.h
include/grpcpp/support/async_stream.h
include/grpcpp/support/async_unary_call.h
include/grpcpp/support/byte_buffer.h
include/grpcpp/support/client_callback.h
include/grpcpp/support/client_interceptor.h
include/grpcpp/support/config.h
include/grpcpp/support/interceptor.h
include/grpcpp/support/message_allocator.h
include/grpcpp/support/method_handler.h
include/grpcpp/support/proto_buffer_reader.h
include/grpcpp/support/proto_buffer_writer.h
include/grpcpp/support/server_callback.h
include/grpcpp/support/server_interceptor.h
include/grpcpp/support/slice.h
include/grpcpp/support/status.h
include/grpcpp/support/status_code_enum.h
include/grpcpp/support/string_ref.h
include/grpcpp/support/stub_options.h
include/grpcpp/support/sync_stream.h
include/grpcpp/support/time.h
include/grpcpp/test/client_context_test_peer.h
include/grpcpp/test/mock_stream.h
include/grpcpp/xds_server_builder.h
package.xml
requirements.bazel.txt
setup.py
src/boringssl/boringssl_prefix_symbols.h
src/compiler/config.h
src/compiler/cpp_generator.cc
src/compiler/cpp_plugin.h
src/compiler/csharp_generator.cc
src/compiler/node_generator.cc
src/compiler/objective_c_generator.cc
src/compiler/objective_c_generator_helpers.h
src/compiler/objective_c_plugin.cc
src/compiler/php_generator.cc
src/compiler/protobuf_plugin.h
src/compiler/python_generator.cc
src/compiler/ruby_generator.cc
src/compiler/ruby_generator_map-inl.h
src/compiler/ruby_generator_string-inl.h
src/compiler/schema_interface.h
src/core/ext/filters/census/grpc_context.cc
src/core/ext/filters/client_channel/backend_metric.cc
src/core/ext/filters/client_channel/backup_poller.h
src/core/ext/filters/client_channel/channel_connectivity.cc
src/core/ext/filters/client_channel/client_channel.cc
src/core/ext/filters/client_channel/client_channel.h
src/core/ext/filters/client_channel/client_channel_channelz.cc
src/core/ext/filters/client_channel/client_channel_channelz.h
src/core/ext/filters/client_channel/client_channel_factory.cc
src/core/ext/filters/client_channel/client_channel_plugin.cc
src/core/ext/filters/client_channel/config_selector.cc
src/core/ext/filters/client_channel/health/health_check_client.cc
src/core/ext/filters/client_channel/health/health_check_client.h
src/core/ext/filters/client_channel/http_connect_handshaker.cc
src/core/ext/filters/client_channel/http_connect_handshaker.h
src/core/ext/filters/client_channel/lb_policy.h
src/core/ext/filters/client_channel/lb_policy/child_policy_handler.cc
src/core/ext/filters/client_channel/lb_policy/grpclb/grpclb.cc
src/core/ext/filters/client_channel/lb_policy/grpclb/grpclb_channel.cc
src/core/ext/filters/client_channel/lb_policy/grpclb/grpclb_channel_secure.cc
src/core/ext/filters/client_channel/lb_policy/grpclb/grpclb_client_stats.cc
src/core/ext/filters/client_channel/lb_policy/grpclb/grpclb_client_stats.h
src/core/ext/filters/client_channel/lb_policy/grpclb/load_balancer_api.cc
src/core/ext/filters/client_channel/lb_policy/priority/priority.cc
src/core/ext/filters/client_channel/lb_policy/ring_hash/ring_hash.cc
src/core/ext/filters/client_channel/lb_policy/subchannel_list.h
src/core/ext/filters/client_channel/lb_policy/weighted_target/weighted_target.cc
src/core/ext/filters/client_channel/lb_policy/xds/cds.cc
src/core/ext/filters/client_channel/lb_policy/xds/xds_cluster_impl.cc
src/core/ext/filters/client_channel/lb_policy/xds/xds_cluster_manager.cc
src/core/ext/filters/client_channel/lb_policy/xds/xds_cluster_resolver.cc
src/core/ext/filters/client_channel/lb_policy_registry.cc
src/core/ext/filters/client_channel/resolver/dns/c_ares/dns_resolver_ares.cc
src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver.h
src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_libuv.cc [deleted file]
src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_posix.cc
src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_windows.cc
src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper.cc
src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_libuv.cc [deleted file]
src/core/ext/filters/client_channel/resolver/dns/native/dns_resolver.cc
src/core/ext/filters/client_channel/resolver/fake/fake_resolver.cc
src/core/ext/filters/client_channel/resolver/google_c2p/google_c2p_resolver.cc
src/core/ext/filters/client_channel/resolver/xds/xds_resolver.cc
src/core/ext/filters/client_channel/resolver_result_parsing.cc
src/core/ext/filters/client_idle/client_idle_filter.cc
src/core/ext/filters/fault_injection/fault_injection_filter.cc
src/core/ext/filters/fault_injection/service_config_parser.cc
src/core/ext/filters/http/client/http_client_filter.cc
src/core/ext/filters/http/client_authority_filter.cc
src/core/ext/filters/http/message_compress/message_compress_filter.cc
src/core/ext/filters/http/message_compress/message_decompress_filter.cc
src/core/ext/filters/http/server/http_server_filter.cc
src/core/ext/filters/load_reporting/server_load_reporting_filter.cc
src/core/ext/filters/message_size/message_size_filter.cc
src/core/ext/transport/binder/client/BUILD [new file with mode: 0644]
src/core/ext/transport/binder/client/channel_create.cc [new file with mode: 0644]
src/core/ext/transport/binder/client/channel_create.h [new file with mode: 0644]
src/core/ext/transport/binder/client/channel_create_impl.cc [new file with mode: 0644]
src/core/ext/transport/binder/client/channel_create_impl.h [new file with mode: 0644]
src/core/ext/transport/binder/client/jni_utils.cc [new file with mode: 0644]
src/core/ext/transport/binder/client/jni_utils.h [new file with mode: 0644]
src/core/ext/transport/binder/java/WORKSPACE [new file with mode: 0644]
src/core/ext/transport/binder/java/io/grpc/binder/cpp/BUILD [moved from src/python/grpcio/grpc/_cython/_cygrpc/aio/iomgr/resolver.pxd.pxi with 62% similarity]
src/core/ext/transport/binder/java/io/grpc/binder/cpp/NativeConnectionHelper.java [new file with mode: 0644]
src/core/ext/transport/binder/java/io/grpc/binder/cpp/SyncServiceConnection.java [new file with mode: 0644]
src/core/ext/transport/binder/server/BUILD [new file with mode: 0644]
src/core/ext/transport/binder/server/binder_server.cc [new file with mode: 0644]
src/core/ext/transport/binder/server/binder_server.h [new file with mode: 0644]
src/core/ext/transport/binder/server/binder_server_credentials.cc [new file with mode: 0644]
src/core/ext/transport/binder/server/binder_server_credentials.h [new file with mode: 0644]
src/core/ext/transport/binder/transport/BUILD [new file with mode: 0644]
src/core/ext/transport/binder/transport/binder_stream.h [new file with mode: 0644]
src/core/ext/transport/binder/transport/binder_transport.cc [new file with mode: 0644]
src/core/ext/transport/binder/transport/binder_transport.h [new file with mode: 0644]
src/core/ext/transport/binder/utils/BUILD
src/core/ext/transport/binder/utils/transport_stream_receiver.h
src/core/ext/transport/binder/utils/transport_stream_receiver_impl.cc
src/core/ext/transport/binder/utils/transport_stream_receiver_impl.h
src/core/ext/transport/binder/wire_format/BUILD
src/core/ext/transport/binder/wire_format/binder.h
src/core/ext/transport/binder/wire_format/binder_android.cc
src/core/ext/transport/binder/wire_format/binder_android.h
src/core/ext/transport/binder/wire_format/binder_constants.cc
src/core/ext/transport/binder/wire_format/binder_constants.h
src/core/ext/transport/binder/wire_format/transaction.cc
src/core/ext/transport/binder/wire_format/transaction.h
src/core/ext/transport/binder/wire_format/wire_reader.h
src/core/ext/transport/binder/wire_format/wire_reader_impl.cc
src/core/ext/transport/binder/wire_format/wire_reader_impl.h
src/core/ext/transport/binder/wire_format/wire_writer.cc
src/core/ext/transport/binder/wire_format/wire_writer.h
src/core/ext/transport/chttp2/alpn/alpn.cc
src/core/ext/transport/chttp2/client/chttp2_connector.cc
src/core/ext/transport/chttp2/client/chttp2_connector.h
src/core/ext/transport/chttp2/client/insecure/channel_create.cc
src/core/ext/transport/chttp2/client/insecure/channel_create_posix.cc
src/core/ext/transport/chttp2/client/secure/secure_channel_create.cc
src/core/ext/transport/chttp2/server/chttp2_server.cc
src/core/ext/transport/chttp2/server/insecure/server_chttp2.cc
src/core/ext/transport/chttp2/server/insecure/server_chttp2_posix.cc
src/core/ext/transport/chttp2/server/secure/server_secure_chttp2.cc
src/core/ext/transport/chttp2/transport/bin_decoder.cc
src/core/ext/transport/chttp2/transport/bin_decoder.h
src/core/ext/transport/chttp2/transport/bin_encoder.cc
src/core/ext/transport/chttp2/transport/chttp2_slice_allocator.cc
src/core/ext/transport/chttp2/transport/chttp2_slice_allocator.h
src/core/ext/transport/chttp2/transport/chttp2_transport.cc
src/core/ext/transport/chttp2/transport/chttp2_transport.h
src/core/ext/transport/chttp2/transport/context_list.h
src/core/ext/transport/chttp2/transport/flow_control.cc
src/core/ext/transport/chttp2/transport/flow_control.h
src/core/ext/transport/chttp2/transport/frame_data.cc
src/core/ext/transport/chttp2/transport/frame_data.h
src/core/ext/transport/chttp2/transport/frame_goaway.cc
src/core/ext/transport/chttp2/transport/frame_goaway.h
src/core/ext/transport/chttp2/transport/frame_ping.cc
src/core/ext/transport/chttp2/transport/frame_ping.h
src/core/ext/transport/chttp2/transport/frame_rst_stream.cc
src/core/ext/transport/chttp2/transport/frame_rst_stream.h
src/core/ext/transport/chttp2/transport/frame_settings.cc
src/core/ext/transport/chttp2/transport/frame_settings.h
src/core/ext/transport/chttp2/transport/frame_window_update.cc
src/core/ext/transport/chttp2/transport/frame_window_update.h
src/core/ext/transport/chttp2/transport/hpack_constants.h [new file with mode: 0644]
src/core/ext/transport/chttp2/transport/hpack_encoder.cc
src/core/ext/transport/chttp2/transport/hpack_encoder.h
src/core/ext/transport/chttp2/transport/hpack_encoder_index.h [new file with mode: 0644]
src/core/ext/transport/chttp2/transport/hpack_encoder_table.cc [new file with mode: 0644]
src/core/ext/transport/chttp2/transport/hpack_encoder_table.h [new file with mode: 0644]
src/core/ext/transport/chttp2/transport/hpack_parser.cc
src/core/ext/transport/chttp2/transport/hpack_parser.h
src/core/ext/transport/chttp2/transport/hpack_parser_table.cc [new file with mode: 0644]
src/core/ext/transport/chttp2/transport/hpack_parser_table.h [new file with mode: 0644]
src/core/ext/transport/chttp2/transport/hpack_table.cc [deleted file]
src/core/ext/transport/chttp2/transport/hpack_table.h [deleted file]
src/core/ext/transport/chttp2/transport/hpack_utils.cc [new file with mode: 0644]
src/core/ext/transport/chttp2/transport/hpack_utils.h [new file with mode: 0644]
src/core/ext/transport/chttp2/transport/incoming_metadata.cc
src/core/ext/transport/chttp2/transport/internal.h
src/core/ext/transport/chttp2/transport/parsing.cc
src/core/ext/transport/chttp2/transport/popularity_count.h [new file with mode: 0644]
src/core/ext/transport/chttp2/transport/stream_lists.cc
src/core/ext/transport/chttp2/transport/varint.cc
src/core/ext/transport/chttp2/transport/varint.h
src/core/ext/transport/chttp2/transport/writing.cc
src/core/ext/transport/cronet/client/secure/cronet_channel_create.cc
src/core/ext/transport/cronet/transport/cronet_api_phony.cc
src/core/ext/transport/cronet/transport/cronet_status.cc
src/core/ext/transport/cronet/transport/cronet_transport.cc
src/core/ext/transport/inproc/inproc_transport.cc
src/core/ext/upb-generated/envoy/admin/v3/config_dump.upb.c
src/core/ext/upb-generated/envoy/admin/v3/config_dump.upb.h
src/core/ext/upb-generated/envoy/annotations/deprecation.upb.c
src/core/ext/upb-generated/envoy/annotations/deprecation.upb.h
src/core/ext/upb-generated/envoy/annotations/resource.upb.c
src/core/ext/upb-generated/envoy/annotations/resource.upb.h
src/core/ext/upb-generated/envoy/config/accesslog/v3/accesslog.upb.c
src/core/ext/upb-generated/envoy/config/accesslog/v3/accesslog.upb.h
src/core/ext/upb-generated/envoy/config/bootstrap/v3/bootstrap.upb.c
src/core/ext/upb-generated/envoy/config/bootstrap/v3/bootstrap.upb.h
src/core/ext/upb-generated/envoy/config/cluster/v3/circuit_breaker.upb.c
src/core/ext/upb-generated/envoy/config/cluster/v3/circuit_breaker.upb.h
src/core/ext/upb-generated/envoy/config/cluster/v3/cluster.upb.c
src/core/ext/upb-generated/envoy/config/cluster/v3/cluster.upb.h
src/core/ext/upb-generated/envoy/config/cluster/v3/filter.upb.c
src/core/ext/upb-generated/envoy/config/cluster/v3/filter.upb.h
src/core/ext/upb-generated/envoy/config/cluster/v3/outlier_detection.upb.c
src/core/ext/upb-generated/envoy/config/cluster/v3/outlier_detection.upb.h
src/core/ext/upb-generated/envoy/config/core/v3/address.upb.c
src/core/ext/upb-generated/envoy/config/core/v3/address.upb.h
src/core/ext/upb-generated/envoy/config/core/v3/backoff.upb.c
src/core/ext/upb-generated/envoy/config/core/v3/backoff.upb.h
src/core/ext/upb-generated/envoy/config/core/v3/base.upb.c
src/core/ext/upb-generated/envoy/config/core/v3/base.upb.h
src/core/ext/upb-generated/envoy/config/core/v3/config_source.upb.c
src/core/ext/upb-generated/envoy/config/core/v3/config_source.upb.h
src/core/ext/upb-generated/envoy/config/core/v3/event_service_config.upb.c
src/core/ext/upb-generated/envoy/config/core/v3/event_service_config.upb.h
src/core/ext/upb-generated/envoy/config/core/v3/extension.upb.c
src/core/ext/upb-generated/envoy/config/core/v3/extension.upb.h
src/core/ext/upb-generated/envoy/config/core/v3/grpc_service.upb.c
src/core/ext/upb-generated/envoy/config/core/v3/grpc_service.upb.h
src/core/ext/upb-generated/envoy/config/core/v3/health_check.upb.c
src/core/ext/upb-generated/envoy/config/core/v3/health_check.upb.h
src/core/ext/upb-generated/envoy/config/core/v3/http_uri.upb.c
src/core/ext/upb-generated/envoy/config/core/v3/http_uri.upb.h
src/core/ext/upb-generated/envoy/config/core/v3/protocol.upb.c
src/core/ext/upb-generated/envoy/config/core/v3/protocol.upb.h
src/core/ext/upb-generated/envoy/config/core/v3/proxy_protocol.upb.c
src/core/ext/upb-generated/envoy/config/core/v3/proxy_protocol.upb.h
src/core/ext/upb-generated/envoy/config/core/v3/resolver.upb.c
src/core/ext/upb-generated/envoy/config/core/v3/resolver.upb.h
src/core/ext/upb-generated/envoy/config/core/v3/socket_option.upb.c
src/core/ext/upb-generated/envoy/config/core/v3/socket_option.upb.h
src/core/ext/upb-generated/envoy/config/core/v3/substitution_format_string.upb.c
src/core/ext/upb-generated/envoy/config/core/v3/substitution_format_string.upb.h
src/core/ext/upb-generated/envoy/config/core/v3/udp_socket_config.upb.c
src/core/ext/upb-generated/envoy/config/core/v3/udp_socket_config.upb.h
src/core/ext/upb-generated/envoy/config/endpoint/v3/endpoint.upb.c
src/core/ext/upb-generated/envoy/config/endpoint/v3/endpoint.upb.h
src/core/ext/upb-generated/envoy/config/endpoint/v3/endpoint_components.upb.c
src/core/ext/upb-generated/envoy/config/endpoint/v3/endpoint_components.upb.h
src/core/ext/upb-generated/envoy/config/endpoint/v3/load_report.upb.c
src/core/ext/upb-generated/envoy/config/endpoint/v3/load_report.upb.h
src/core/ext/upb-generated/envoy/config/listener/v3/api_listener.upb.c
src/core/ext/upb-generated/envoy/config/listener/v3/api_listener.upb.h
src/core/ext/upb-generated/envoy/config/listener/v3/listener.upb.c
src/core/ext/upb-generated/envoy/config/listener/v3/listener.upb.h
src/core/ext/upb-generated/envoy/config/listener/v3/listener_components.upb.c
src/core/ext/upb-generated/envoy/config/listener/v3/listener_components.upb.h
src/core/ext/upb-generated/envoy/config/listener/v3/quic_config.upb.c
src/core/ext/upb-generated/envoy/config/listener/v3/quic_config.upb.h
src/core/ext/upb-generated/envoy/config/listener/v3/udp_listener_config.upb.c
src/core/ext/upb-generated/envoy/config/listener/v3/udp_listener_config.upb.h
src/core/ext/upb-generated/envoy/config/metrics/v3/stats.upb.c
src/core/ext/upb-generated/envoy/config/metrics/v3/stats.upb.h
src/core/ext/upb-generated/envoy/config/overload/v3/overload.upb.c
src/core/ext/upb-generated/envoy/config/overload/v3/overload.upb.h
src/core/ext/upb-generated/envoy/config/rbac/v3/rbac.upb.c
src/core/ext/upb-generated/envoy/config/rbac/v3/rbac.upb.h
src/core/ext/upb-generated/envoy/config/route/v3/route.upb.c
src/core/ext/upb-generated/envoy/config/route/v3/route.upb.h
src/core/ext/upb-generated/envoy/config/route/v3/route_components.upb.c
src/core/ext/upb-generated/envoy/config/route/v3/route_components.upb.h
src/core/ext/upb-generated/envoy/config/route/v3/scoped_route.upb.c
src/core/ext/upb-generated/envoy/config/route/v3/scoped_route.upb.h
src/core/ext/upb-generated/envoy/config/trace/v3/http_tracer.upb.c
src/core/ext/upb-generated/envoy/config/trace/v3/http_tracer.upb.h
src/core/ext/upb-generated/envoy/extensions/clusters/aggregate/v3/cluster.upb.c
src/core/ext/upb-generated/envoy/extensions/clusters/aggregate/v3/cluster.upb.h
src/core/ext/upb-generated/envoy/extensions/filters/common/fault/v3/fault.upb.c
src/core/ext/upb-generated/envoy/extensions/filters/common/fault/v3/fault.upb.h
src/core/ext/upb-generated/envoy/extensions/filters/http/fault/v3/fault.upb.c
src/core/ext/upb-generated/envoy/extensions/filters/http/fault/v3/fault.upb.h
src/core/ext/upb-generated/envoy/extensions/filters/http/router/v3/router.upb.c
src/core/ext/upb-generated/envoy/extensions/filters/http/router/v3/router.upb.h
src/core/ext/upb-generated/envoy/extensions/filters/network/http_connection_manager/v3/http_connection_manager.upb.c
src/core/ext/upb-generated/envoy/extensions/filters/network/http_connection_manager/v3/http_connection_manager.upb.h
src/core/ext/upb-generated/envoy/extensions/transport_sockets/tls/v3/cert.upb.c
src/core/ext/upb-generated/envoy/extensions/transport_sockets/tls/v3/cert.upb.h
src/core/ext/upb-generated/envoy/extensions/transport_sockets/tls/v3/common.upb.c
src/core/ext/upb-generated/envoy/extensions/transport_sockets/tls/v3/common.upb.h
src/core/ext/upb-generated/envoy/extensions/transport_sockets/tls/v3/secret.upb.c
src/core/ext/upb-generated/envoy/extensions/transport_sockets/tls/v3/secret.upb.h
src/core/ext/upb-generated/envoy/extensions/transport_sockets/tls/v3/tls.upb.c
src/core/ext/upb-generated/envoy/extensions/transport_sockets/tls/v3/tls.upb.h
src/core/ext/upb-generated/envoy/service/cluster/v3/cds.upb.c
src/core/ext/upb-generated/envoy/service/cluster/v3/cds.upb.h
src/core/ext/upb-generated/envoy/service/discovery/v3/ads.upb.c
src/core/ext/upb-generated/envoy/service/discovery/v3/ads.upb.h
src/core/ext/upb-generated/envoy/service/discovery/v3/discovery.upb.c
src/core/ext/upb-generated/envoy/service/discovery/v3/discovery.upb.h
src/core/ext/upb-generated/envoy/service/endpoint/v3/eds.upb.c
src/core/ext/upb-generated/envoy/service/endpoint/v3/eds.upb.h
src/core/ext/upb-generated/envoy/service/listener/v3/lds.upb.c
src/core/ext/upb-generated/envoy/service/listener/v3/lds.upb.h
src/core/ext/upb-generated/envoy/service/load_stats/v3/lrs.upb.c
src/core/ext/upb-generated/envoy/service/load_stats/v3/lrs.upb.h
src/core/ext/upb-generated/envoy/service/route/v3/rds.upb.c
src/core/ext/upb-generated/envoy/service/route/v3/rds.upb.h
src/core/ext/upb-generated/envoy/service/route/v3/srds.upb.c
src/core/ext/upb-generated/envoy/service/route/v3/srds.upb.h
src/core/ext/upb-generated/envoy/service/status/v3/csds.upb.c
src/core/ext/upb-generated/envoy/service/status/v3/csds.upb.h
src/core/ext/upb-generated/envoy/type/http/v3/path_transformation.upb.c
src/core/ext/upb-generated/envoy/type/http/v3/path_transformation.upb.h
src/core/ext/upb-generated/envoy/type/matcher/v3/metadata.upb.c
src/core/ext/upb-generated/envoy/type/matcher/v3/metadata.upb.h
src/core/ext/upb-generated/envoy/type/matcher/v3/node.upb.c
src/core/ext/upb-generated/envoy/type/matcher/v3/node.upb.h
src/core/ext/upb-generated/envoy/type/matcher/v3/number.upb.c
src/core/ext/upb-generated/envoy/type/matcher/v3/number.upb.h
src/core/ext/upb-generated/envoy/type/matcher/v3/path.upb.c
src/core/ext/upb-generated/envoy/type/matcher/v3/path.upb.h
src/core/ext/upb-generated/envoy/type/matcher/v3/regex.upb.c
src/core/ext/upb-generated/envoy/type/matcher/v3/regex.upb.h
src/core/ext/upb-generated/envoy/type/matcher/v3/string.upb.c
src/core/ext/upb-generated/envoy/type/matcher/v3/string.upb.h
src/core/ext/upb-generated/envoy/type/matcher/v3/struct.upb.c
src/core/ext/upb-generated/envoy/type/matcher/v3/struct.upb.h
src/core/ext/upb-generated/envoy/type/matcher/v3/value.upb.c
src/core/ext/upb-generated/envoy/type/matcher/v3/value.upb.h
src/core/ext/upb-generated/envoy/type/metadata/v3/metadata.upb.c
src/core/ext/upb-generated/envoy/type/metadata/v3/metadata.upb.h
src/core/ext/upb-generated/envoy/type/tracing/v3/custom_tag.upb.c
src/core/ext/upb-generated/envoy/type/tracing/v3/custom_tag.upb.h
src/core/ext/upb-generated/envoy/type/v3/http.upb.c
src/core/ext/upb-generated/envoy/type/v3/http.upb.h
src/core/ext/upb-generated/envoy/type/v3/percent.upb.c
src/core/ext/upb-generated/envoy/type/v3/percent.upb.h
src/core/ext/upb-generated/envoy/type/v3/range.upb.c
src/core/ext/upb-generated/envoy/type/v3/range.upb.h
src/core/ext/upb-generated/envoy/type/v3/semantic_version.upb.c
src/core/ext/upb-generated/envoy/type/v3/semantic_version.upb.h
src/core/ext/upb-generated/google/api/annotations.upb.c
src/core/ext/upb-generated/google/api/annotations.upb.h
src/core/ext/upb-generated/google/api/expr/v1alpha1/checked.upb.c
src/core/ext/upb-generated/google/api/expr/v1alpha1/checked.upb.h
src/core/ext/upb-generated/google/api/expr/v1alpha1/syntax.upb.c
src/core/ext/upb-generated/google/api/expr/v1alpha1/syntax.upb.h
src/core/ext/upb-generated/google/api/http.upb.c
src/core/ext/upb-generated/google/api/http.upb.h
src/core/ext/upb-generated/google/protobuf/any.upb.c
src/core/ext/upb-generated/google/protobuf/any.upb.h
src/core/ext/upb-generated/google/protobuf/descriptor.upb.c
src/core/ext/upb-generated/google/protobuf/descriptor.upb.h
src/core/ext/upb-generated/google/protobuf/duration.upb.c
src/core/ext/upb-generated/google/protobuf/duration.upb.h
src/core/ext/upb-generated/google/protobuf/empty.upb.c
src/core/ext/upb-generated/google/protobuf/empty.upb.h
src/core/ext/upb-generated/google/protobuf/struct.upb.c
src/core/ext/upb-generated/google/protobuf/struct.upb.h
src/core/ext/upb-generated/google/protobuf/timestamp.upb.c
src/core/ext/upb-generated/google/protobuf/timestamp.upb.h
src/core/ext/upb-generated/google/protobuf/wrappers.upb.c
src/core/ext/upb-generated/google/protobuf/wrappers.upb.h
src/core/ext/upb-generated/google/rpc/status.upb.c
src/core/ext/upb-generated/google/rpc/status.upb.h
src/core/ext/upb-generated/src/proto/grpc/gcp/altscontext.upb.c
src/core/ext/upb-generated/src/proto/grpc/gcp/altscontext.upb.h
src/core/ext/upb-generated/src/proto/grpc/gcp/handshaker.upb.c
src/core/ext/upb-generated/src/proto/grpc/gcp/handshaker.upb.h
src/core/ext/upb-generated/src/proto/grpc/gcp/transport_security_common.upb.c
src/core/ext/upb-generated/src/proto/grpc/gcp/transport_security_common.upb.h
src/core/ext/upb-generated/src/proto/grpc/health/v1/health.upb.c
src/core/ext/upb-generated/src/proto/grpc/health/v1/health.upb.h
src/core/ext/upb-generated/src/proto/grpc/lb/v1/load_balancer.upb.c
src/core/ext/upb-generated/src/proto/grpc/lb/v1/load_balancer.upb.h
src/core/ext/upb-generated/third_party/istio/security/proto/providers/google/meshca.upb.c
src/core/ext/upb-generated/third_party/istio/security/proto/providers/google/meshca.upb.h
src/core/ext/upb-generated/udpa/annotations/migrate.upb.c
src/core/ext/upb-generated/udpa/annotations/migrate.upb.h
src/core/ext/upb-generated/udpa/annotations/security.upb.c
src/core/ext/upb-generated/udpa/annotations/security.upb.h
src/core/ext/upb-generated/udpa/annotations/sensitive.upb.c
src/core/ext/upb-generated/udpa/annotations/sensitive.upb.h
src/core/ext/upb-generated/udpa/annotations/status.upb.c
src/core/ext/upb-generated/udpa/annotations/status.upb.h
src/core/ext/upb-generated/udpa/annotations/versioning.upb.c
src/core/ext/upb-generated/udpa/annotations/versioning.upb.h
src/core/ext/upb-generated/udpa/data/orca/v1/orca_load_report.upb.c
src/core/ext/upb-generated/udpa/data/orca/v1/orca_load_report.upb.h
src/core/ext/upb-generated/udpa/type/v1/typed_struct.upb.c
src/core/ext/upb-generated/udpa/type/v1/typed_struct.upb.h
src/core/ext/upb-generated/validate/validate.upb.c
src/core/ext/upb-generated/validate/validate.upb.h
src/core/ext/upb-generated/xds/core/v3/authority.upb.c
src/core/ext/upb-generated/xds/core/v3/authority.upb.h
src/core/ext/upb-generated/xds/core/v3/collection_entry.upb.c
src/core/ext/upb-generated/xds/core/v3/collection_entry.upb.h
src/core/ext/upb-generated/xds/core/v3/context_params.upb.c
src/core/ext/upb-generated/xds/core/v3/context_params.upb.h
src/core/ext/upb-generated/xds/core/v3/resource.upb.c
src/core/ext/upb-generated/xds/core/v3/resource.upb.h
src/core/ext/upb-generated/xds/core/v3/resource_locator.upb.c
src/core/ext/upb-generated/xds/core/v3/resource_locator.upb.h
src/core/ext/upb-generated/xds/core/v3/resource_name.upb.c
src/core/ext/upb-generated/xds/core/v3/resource_name.upb.h
src/core/ext/upbdefs-generated/envoy/config/cluster/v3/cluster.upbdefs.c
src/core/ext/upbdefs-generated/envoy/config/endpoint/v3/endpoint_components.upbdefs.c
src/core/ext/upbdefs-generated/envoy/config/endpoint/v3/endpoint_components.upbdefs.h
src/core/ext/upbdefs-generated/envoy/config/overload/v3/overload.upbdefs.c
src/core/ext/upbdefs-generated/envoy/config/overload/v3/overload.upbdefs.h
src/core/ext/upbdefs-generated/envoy/config/rbac/v3/rbac.upbdefs.c
src/core/ext/upbdefs-generated/envoy/config/route/v3/route_components.upbdefs.c
src/core/ext/upbdefs-generated/envoy/extensions/filters/network/http_connection_manager/v3/http_connection_manager.upbdefs.c
src/core/ext/upbdefs-generated/envoy/extensions/transport_sockets/tls/v3/common.upbdefs.c
src/core/ext/upbdefs-generated/envoy/extensions/transport_sockets/tls/v3/common.upbdefs.h
src/core/ext/upbdefs-generated/envoy/extensions/transport_sockets/tls/v3/tls.upbdefs.c
src/core/ext/upbdefs-generated/envoy/type/matcher/v3/metadata.upbdefs.c
src/core/ext/upbdefs-generated/google/protobuf/descriptor.upbdefs.c
src/core/ext/xds/certificate_provider_registry.cc
src/core/ext/xds/xds_api.cc
src/core/ext/xds/xds_api.h
src/core/ext/xds/xds_bootstrap.cc
src/core/ext/xds/xds_client.cc
src/core/ext/xds/xds_client_stats.cc
src/core/ext/xds/xds_client_stats.h
src/core/ext/xds/xds_http_fault_filter.cc
src/core/ext/xds/xds_http_fault_filter.h
src/core/ext/xds/xds_http_filters.cc
src/core/ext/xds/xds_server_config_fetcher.cc
src/core/lib/address_utils/parse_address.cc
src/core/lib/address_utils/sockaddr_utils.cc
src/core/lib/channel/channel_args.cc
src/core/lib/channel/channel_stack.cc
src/core/lib/channel/channel_stack_builder.cc
src/core/lib/channel/channel_stack_builder.h
src/core/lib/channel/channel_trace.cc
src/core/lib/channel/channel_trace.h
src/core/lib/channel/channelz.cc
src/core/lib/channel/channelz.h
src/core/lib/channel/channelz_registry.cc
src/core/lib/channel/connected_channel.cc
src/core/lib/channel/handshaker.cc
src/core/lib/channel/handshaker.h
src/core/lib/channel/handshaker_factory.h
src/core/lib/channel/handshaker_registry.cc
src/core/lib/channel/handshaker_registry.h
src/core/lib/channel/status_util.h
src/core/lib/compression/algorithm_metadata.h
src/core/lib/compression/compression_args.cc
src/core/lib/compression/compression_internal.cc
src/core/lib/compression/message_compress.cc
src/core/lib/compression/stream_compression.cc
src/core/lib/compression/stream_compression.h
src/core/lib/compression/stream_compression_gzip.cc
src/core/lib/compression/stream_compression_identity.cc
src/core/lib/config/core_configuration.cc [new file with mode: 0644]
src/core/lib/config/core_configuration.h [new file with mode: 0644]
src/core/lib/debug/stats.h
src/core/lib/debug/stats_data.cc
src/core/lib/debug/stats_data.h
src/core/lib/debug/trace.cc
src/core/lib/debug/trace.h
src/core/lib/event_engine/endpoint_config.cc
src/core/lib/event_engine/event_engine.cc
src/core/lib/event_engine/sockaddr.cc
src/core/lib/gpr/alloc.cc
src/core/lib/gpr/env_linux.cc
src/core/lib/gpr/env_posix.cc
src/core/lib/gpr/log.cc
src/core/lib/gpr/log_android.cc
src/core/lib/gpr/log_linux.cc
src/core/lib/gpr/log_posix.cc
src/core/lib/gpr/string.h
src/core/lib/gpr/sync.cc
src/core/lib/gpr/sync_abseil.cc
src/core/lib/gpr/sync_posix.cc
src/core/lib/gpr/time.cc
src/core/lib/gpr/time_windows.cc
src/core/lib/gpr/tls.h
src/core/lib/gpr/tls_gcc.h [deleted file]
src/core/lib/gpr/tls_msvc.h [deleted file]
src/core/lib/gpr/tls_pthread.cc [deleted file]
src/core/lib/gpr/tls_pthread.h [deleted file]
src/core/lib/gpr/tls_stdcpp.h [deleted file]
src/core/lib/gpr/tmpfile_posix.cc
src/core/lib/gprpp/arena.cc
src/core/lib/gprpp/arena.h
src/core/lib/gprpp/atomic.h [deleted file]
src/core/lib/gprpp/atomic_utils.h [new file with mode: 0644]
src/core/lib/gprpp/bitset.h
src/core/lib/gprpp/capture.h [new file with mode: 0644]
src/core/lib/gprpp/construct_destruct.h [new file with mode: 0644]
src/core/lib/gprpp/dual_ref_counted.h
src/core/lib/gprpp/fork.cc
src/core/lib/gprpp/fork.h
src/core/lib/gprpp/global_config.h
src/core/lib/gprpp/global_config_env.cc
src/core/lib/gprpp/global_config_generic.h
src/core/lib/gprpp/manual_constructor.h
src/core/lib/gprpp/match.h
src/core/lib/gprpp/memory.h
src/core/lib/gprpp/mpscq.cc
src/core/lib/gprpp/mpscq.h
src/core/lib/gprpp/orphanable.h
src/core/lib/gprpp/ref_counted.h
src/core/lib/gprpp/status_helper.cc
src/core/lib/gprpp/sync.h
src/core/lib/gprpp/table.h
src/core/lib/gprpp/thd_posix.cc
src/core/lib/gprpp/thd_windows.cc
src/core/lib/gprpp/time_util.cc
src/core/lib/gprpp/time_util.h
src/core/lib/http/format_request.cc
src/core/lib/http/format_request.h
src/core/lib/http/httpcli.cc
src/core/lib/http/httpcli.h
src/core/lib/http/httpcli_security_connector.cc
src/core/lib/http/parser.h
src/core/lib/iomgr/buffer_list.cc
src/core/lib/iomgr/buffer_list.h
src/core/lib/iomgr/call_combiner.cc
src/core/lib/iomgr/cfstream_handle.cc
src/core/lib/iomgr/combiner.cc
src/core/lib/iomgr/combiner.h
src/core/lib/iomgr/dualstack_socket_posix.cc
src/core/lib/iomgr/endpoint.cc
src/core/lib/iomgr/endpoint.h
src/core/lib/iomgr/endpoint_cfstream.cc
src/core/lib/iomgr/endpoint_cfstream.h
src/core/lib/iomgr/endpoint_pair.h
src/core/lib/iomgr/endpoint_pair_event_engine.cc
src/core/lib/iomgr/endpoint_pair_posix.cc
src/core/lib/iomgr/endpoint_pair_uv.cc [deleted file]
src/core/lib/iomgr/endpoint_pair_windows.cc
src/core/lib/iomgr/error.h
src/core/lib/iomgr/error_cfstream.cc
src/core/lib/iomgr/error_internal.h
src/core/lib/iomgr/ev_epoll1_linux.cc
src/core/lib/iomgr/ev_epollex_linux.cc
src/core/lib/iomgr/ev_poll_posix.cc
src/core/lib/iomgr/ev_posix.cc
src/core/lib/iomgr/event_engine/endpoint.cc
src/core/lib/iomgr/event_engine/endpoint.h
src/core/lib/iomgr/event_engine/iomgr.cc
src/core/lib/iomgr/event_engine/iomgr.h
src/core/lib/iomgr/event_engine/resolver.cc
src/core/lib/iomgr/event_engine/tcp.cc
src/core/lib/iomgr/exec_ctx.cc
src/core/lib/iomgr/exec_ctx.h
src/core/lib/iomgr/executor.cc
src/core/lib/iomgr/executor/mpmcqueue.cc
src/core/lib/iomgr/executor/mpmcqueue.h
src/core/lib/iomgr/executor/threadpool.cc
src/core/lib/iomgr/executor/threadpool.h
src/core/lib/iomgr/grpc_if_nametoindex_posix.cc
src/core/lib/iomgr/grpc_if_nametoindex_unsupported.cc
src/core/lib/iomgr/internal_errqueue.cc
src/core/lib/iomgr/iocp_windows.cc
src/core/lib/iomgr/iomgr.h
src/core/lib/iomgr/iomgr_custom.cc
src/core/lib/iomgr/iomgr_custom.h
src/core/lib/iomgr/iomgr_internal.cc
src/core/lib/iomgr/iomgr_uv.cc [deleted file]
src/core/lib/iomgr/iomgr_windows.cc
src/core/lib/iomgr/is_epollexclusive_available.cc
src/core/lib/iomgr/polling_entity.cc
src/core/lib/iomgr/pollset_custom.cc
src/core/lib/iomgr/pollset_custom.h
src/core/lib/iomgr/pollset_set_custom.cc
src/core/lib/iomgr/pollset_set_windows.cc
src/core/lib/iomgr/pollset_uv.cc [deleted file]
src/core/lib/iomgr/pollset_uv.h [deleted file]
src/core/lib/iomgr/port.h
src/core/lib/iomgr/python_util.h
src/core/lib/iomgr/resolve_address.cc
src/core/lib/iomgr/resolve_address.h
src/core/lib/iomgr/resolve_address_custom.cc
src/core/lib/iomgr/resolve_address_custom.h
src/core/lib/iomgr/resolve_address_posix.cc
src/core/lib/iomgr/resolve_address_windows.cc
src/core/lib/iomgr/resource_quota.cc
src/core/lib/iomgr/resource_quota.h
src/core/lib/iomgr/sockaddr.h
src/core/lib/iomgr/sockaddr_custom.h [deleted file]
src/core/lib/iomgr/socket_factory_posix.cc
src/core/lib/iomgr/socket_factory_posix.h
src/core/lib/iomgr/socket_mutator.h
src/core/lib/iomgr/socket_utils_common_posix.cc
src/core/lib/iomgr/socket_utils_linux.cc
src/core/lib/iomgr/socket_utils_posix.cc
src/core/lib/iomgr/socket_utils_posix.h
src/core/lib/iomgr/socket_utils_uv.cc [deleted file]
src/core/lib/iomgr/socket_utils_windows.cc
src/core/lib/iomgr/tcp_client.cc
src/core/lib/iomgr/tcp_client.h
src/core/lib/iomgr/tcp_client_cfstream.cc
src/core/lib/iomgr/tcp_client_custom.cc
src/core/lib/iomgr/tcp_client_posix.cc
src/core/lib/iomgr/tcp_client_posix.h
src/core/lib/iomgr/tcp_client_windows.cc
src/core/lib/iomgr/tcp_custom.cc
src/core/lib/iomgr/tcp_custom.h
src/core/lib/iomgr/tcp_posix.cc
src/core/lib/iomgr/tcp_posix.h
src/core/lib/iomgr/tcp_server.cc
src/core/lib/iomgr/tcp_server.h
src/core/lib/iomgr/tcp_server_custom.cc
src/core/lib/iomgr/tcp_server_posix.cc
src/core/lib/iomgr/tcp_server_utils_posix.h
src/core/lib/iomgr/tcp_server_utils_posix_common.cc
src/core/lib/iomgr/tcp_server_utils_posix_ifaddrs.cc
src/core/lib/iomgr/tcp_server_utils_posix_noifaddrs.cc
src/core/lib/iomgr/tcp_server_windows.cc
src/core/lib/iomgr/tcp_uv.cc [deleted file]
src/core/lib/iomgr/tcp_windows.cc
src/core/lib/iomgr/tcp_windows.h
src/core/lib/iomgr/timer.cc
src/core/lib/iomgr/timer.h
src/core/lib/iomgr/timer_custom.cc
src/core/lib/iomgr/timer_generic.cc
src/core/lib/iomgr/timer_generic.h
src/core/lib/iomgr/timer_heap.cc
src/core/lib/iomgr/timer_uv.cc [deleted file]
src/core/lib/iomgr/udp_server.cc
src/core/lib/iomgr/unix_sockets_posix.cc
src/core/lib/iomgr/unix_sockets_posix.h
src/core/lib/iomgr/wakeup_fd_nospecial.cc
src/core/lib/iomgr/wakeup_fd_pipe.cc
src/core/lib/iomgr/wakeup_fd_posix.cc
src/core/lib/iomgr/work_serializer.cc
src/core/lib/iomgr/work_serializer.h
src/core/lib/json/json_reader.cc
src/core/lib/json/json_util.h
src/core/lib/matchers/matchers.h
src/core/lib/profiling/basic_timers.cc
src/core/lib/profiling/stap_timers.cc
src/core/lib/promise/activity.cc [new file with mode: 0644]
src/core/lib/promise/activity.h [new file with mode: 0644]
src/core/lib/promise/context.h [new file with mode: 0644]
src/core/lib/promise/detail/basic_join.h [new file with mode: 0644]
src/core/lib/promise/detail/basic_seq.h [new file with mode: 0644]
src/core/lib/promise/detail/promise_factory.h [new file with mode: 0644]
src/core/lib/promise/detail/promise_like.h [new file with mode: 0644]
src/core/lib/promise/detail/status.h [new file with mode: 0644]
src/core/lib/promise/detail/switch.h [new file with mode: 0644]
src/core/lib/promise/for_each.h [new file with mode: 0644]
src/core/lib/promise/if.h [new file with mode: 0644]
src/core/lib/promise/intra_activity_waiter.h [new file with mode: 0644]
src/core/lib/promise/join.h [new file with mode: 0644]
src/core/lib/promise/latch.h [new file with mode: 0644]
src/core/lib/promise/loop.h [new file with mode: 0644]
src/core/lib/promise/map.h [new file with mode: 0644]
src/core/lib/promise/observable.h [new file with mode: 0644]
src/core/lib/promise/pipe.h [new file with mode: 0644]
src/core/lib/promise/poll.h [new file with mode: 0644]
src/core/lib/promise/promise.h [new file with mode: 0644]
src/core/lib/promise/race.h [new file with mode: 0644]
src/core/lib/promise/seq.h [new file with mode: 0644]
src/core/lib/promise/try_join.h [new file with mode: 0644]
src/core/lib/promise/try_seq.h [new file with mode: 0644]
src/core/lib/promise/wait_set.h [new file with mode: 0644]
src/core/lib/security/authorization/authorization_policy_provider.h
src/core/lib/security/authorization/cel_authorization_engine.cc
src/core/lib/security/authorization/cel_authorization_engine.h
src/core/lib/security/authorization/evaluate_args.cc
src/core/lib/security/authorization/grpc_authorization_policy_provider.cc
src/core/lib/security/authorization/grpc_authorization_policy_provider.h
src/core/lib/security/authorization/matchers.cc
src/core/lib/security/authorization/mock_cel/cel_expression.h
src/core/lib/security/authorization/mock_cel/evaluator_core.h
src/core/lib/security/authorization/rbac_translator.cc
src/core/lib/security/authorization/rbac_translator.h
src/core/lib/security/authorization/sdk_server_authz_filter.cc [new file with mode: 0644]
src/core/lib/security/authorization/sdk_server_authz_filter.h [new file with mode: 0644]
src/core/lib/security/context/security_context.cc
src/core/lib/security/credentials/alts/check_gcp_environment_linux.cc
src/core/lib/security/credentials/alts/check_gcp_environment_no_op.cc
src/core/lib/security/credentials/alts/check_gcp_environment_windows.cc
src/core/lib/security/credentials/composite/composite_credentials.cc
src/core/lib/security/credentials/credentials.cc
src/core/lib/security/credentials/credentials.h
src/core/lib/security/credentials/credentials_metadata.cc
src/core/lib/security/credentials/external/aws_external_account_credentials.cc
src/core/lib/security/credentials/external/aws_external_account_credentials.h
src/core/lib/security/credentials/external/aws_request_signer.cc
src/core/lib/security/credentials/external/external_account_credentials.cc
src/core/lib/security/credentials/external/url_external_account_credentials.cc
src/core/lib/security/credentials/google_default/credentials_generic.cc
src/core/lib/security/credentials/google_default/google_default_credentials.cc
src/core/lib/security/credentials/iam/iam_credentials.cc
src/core/lib/security/credentials/jwt/json_token.cc
src/core/lib/security/credentials/jwt/json_token.h
src/core/lib/security/credentials/jwt/jwt_credentials.cc
src/core/lib/security/credentials/jwt/jwt_credentials.h
src/core/lib/security/credentials/jwt/jwt_verifier.cc
src/core/lib/security/credentials/jwt/jwt_verifier.h
src/core/lib/security/credentials/oauth2/oauth2_credentials.cc
src/core/lib/security/credentials/oauth2/oauth2_credentials.h
src/core/lib/security/credentials/plugin/plugin_credentials.cc
src/core/lib/security/credentials/ssl/ssl_credentials.cc
src/core/lib/security/credentials/ssl/ssl_credentials.h
src/core/lib/security/credentials/tls/grpc_tls_certificate_distributor.cc
src/core/lib/security/credentials/tls/grpc_tls_certificate_distributor.h
src/core/lib/security/credentials/tls/grpc_tls_certificate_provider.cc
src/core/lib/security/credentials/tls/grpc_tls_certificate_provider.h
src/core/lib/security/credentials/tls/grpc_tls_credentials_options.h
src/core/lib/security/security_connector/fake/fake_security_connector.cc
src/core/lib/security/security_connector/load_system_roots_fallback.cc
src/core/lib/security/security_connector/load_system_roots_linux.cc
src/core/lib/security/security_connector/ssl/ssl_security_connector.cc
src/core/lib/security/security_connector/ssl/ssl_security_connector.h
src/core/lib/security/security_connector/ssl_utils.cc
src/core/lib/security/security_connector/tls/tls_security_connector.cc
src/core/lib/security/transport/auth_filters.h
src/core/lib/security/transport/client_auth_filter.cc
src/core/lib/security/transport/secure_endpoint.cc
src/core/lib/security/transport/secure_endpoint.h
src/core/lib/security/transport/security_handshaker.cc
src/core/lib/security/transport/security_handshaker.h
src/core/lib/security/util/json_util.cc
src/core/lib/slice/percent_encoding.cc
src/core/lib/slice/percent_encoding.h
src/core/lib/slice/slice.cc
src/core/lib/slice/slice_buffer.cc
src/core/lib/slice/slice_intern.cc
src/core/lib/slice/slice_internal.h
src/core/lib/surface/api_trace.cc
src/core/lib/surface/api_trace.h
src/core/lib/surface/byte_buffer_reader.cc
src/core/lib/surface/call.cc
src/core/lib/surface/call.h
src/core/lib/surface/call_details.cc
src/core/lib/surface/call_log_batch.cc
src/core/lib/surface/channel.cc
src/core/lib/surface/channel.h
src/core/lib/surface/channel_ping.cc
src/core/lib/surface/channel_stack_type.cc
src/core/lib/surface/completion_queue.cc
src/core/lib/surface/completion_queue_factory.cc
src/core/lib/surface/completion_queue_factory.h
src/core/lib/surface/event_string.cc
src/core/lib/surface/init.cc
src/core/lib/surface/init.h
src/core/lib/surface/init_secure.cc
src/core/lib/surface/init_unsecure.cc
src/core/lib/surface/lame_client.cc
src/core/lib/surface/metadata_array.cc
src/core/lib/surface/server.cc
src/core/lib/surface/server.h
src/core/lib/surface/validate_metadata.cc
src/core/lib/surface/version.cc
src/core/lib/transport/byte_stream.h
src/core/lib/transport/connectivity_state.cc
src/core/lib/transport/connectivity_state.h
src/core/lib/transport/error_utils.cc
src/core/lib/transport/metadata.cc
src/core/lib/transport/metadata.h
src/core/lib/transport/metadata_batch.h
src/core/lib/transport/transport_op_string.cc
src/core/plugin_registry/grpc_plugin_registry.cc
src/core/plugin_registry/grpc_unsecure_plugin_registry.cc
src/core/tsi/alts/crypt/aes_gcm.cc
src/core/tsi/alts/crypt/gsec.h
src/core/tsi/alts/handshaker/alts_handshaker_client.cc
src/core/tsi/alts/handshaker/alts_handshaker_client.h
src/core/tsi/alts/zero_copy_frame_protector/alts_grpc_integrity_only_record_protocol.cc
src/core/tsi/ssl/session_cache/ssl_session_cache.cc
src/core/tsi/ssl/session_cache/ssl_session_openssl.cc
src/core/tsi/ssl_transport_security.cc
src/core/tsi/ssl_transport_security.h
src/core/tsi/transport_security.cc
src/core/tsi/transport_security_grpc.h
src/cpp/Protobuf-C++.podspec
src/cpp/README.md
src/cpp/client/channel_cc.cc
src/cpp/client/channel_test_peer.cc
src/cpp/client/client_context.cc
src/cpp/client/create_channel_internal.cc
src/cpp/client/cronet_credentials.cc
src/cpp/client/insecure_credentials.cc
src/cpp/client/secure_credentials.cc
src/cpp/client/secure_credentials.h
src/cpp/client/xds_credentials.cc
src/cpp/common/alarm.cc
src/cpp/common/auth_property_iterator.cc
src/cpp/common/channel_arguments.cc
src/cpp/common/channel_filter.cc
src/cpp/common/channel_filter.h
src/cpp/common/completion_queue_cc.cc
src/cpp/common/core_codegen.cc
src/cpp/common/secure_channel_arguments.cc
src/cpp/common/secure_create_auth_context.cc
src/cpp/common/tls_certificate_provider.cc
src/cpp/common/tls_credentials_options.cc
src/cpp/common/tls_credentials_options_util.cc
src/cpp/common/version_cc.cc
src/cpp/ext/filters/census/client_filter.cc
src/cpp/ext/filters/census/client_filter.h
src/cpp/ext/filters/census/context.cc
src/cpp/ext/filters/census/context.h
src/cpp/ext/filters/census/grpc_plugin.cc
src/cpp/ext/filters/census/grpc_plugin.h
src/cpp/ext/filters/census/measures.cc
src/cpp/ext/filters/census/measures.h
src/cpp/ext/filters/census/server_filter.cc
src/cpp/ext/filters/census/server_filter.h
src/cpp/ext/filters/census/views.cc
src/cpp/ext/proto_server_reflection.cc
src/cpp/ext/proto_server_reflection.h
src/cpp/server/admin/admin_services.cc
src/cpp/server/async_generic_service.cc
src/cpp/server/channelz/channelz_service.h
src/cpp/server/csds/csds.cc
src/cpp/server/csds/csds.h
src/cpp/server/health/default_health_check_service.cc
src/cpp/server/insecure_server_credentials.cc
src/cpp/server/load_reporter/get_cpu_stats_windows.cc
src/cpp/server/load_reporter/load_data_store.cc
src/cpp/server/load_reporter/load_reporter.cc
src/cpp/server/load_reporter/load_reporter.h
src/cpp/server/load_reporter/load_reporter_async_service_impl.cc
src/cpp/server/load_reporter/util.cc
src/cpp/server/secure_server_credentials.cc
src/cpp/server/secure_server_credentials.h
src/cpp/server/server_builder.cc
src/cpp/server/server_cc.cc
src/cpp/server/server_context.cc
src/cpp/server/server_credentials.cc
src/cpp/server/server_posix.cc
src/cpp/server/xds_server_credentials.cc
src/cpp/thread_manager/thread_manager.cc
src/cpp/util/core_stats.h
src/csharp/Grpc.Core.Api/VersionInfo.cs
src/csharp/Grpc.Core.Tests/Internal/AsyncCallTest.cs
src/csharp/Grpc.Core/Internal/AsyncCall.cs
src/csharp/Grpc.Core/Internal/AsyncCallBase.cs
src/csharp/Grpc.Core/Internal/UnmanagedLibrary.cs
src/csharp/Grpc.Core/build/net45/Grpc.Core.targets
src/csharp/Grpc.Examples/Math.cs
src/csharp/Grpc.HealthCheck/Health.cs
src/csharp/Grpc.IntegrationTesting/Control.cs
src/csharp/Grpc.IntegrationTesting/CoreStats/Stats.cs
src/csharp/Grpc.IntegrationTesting/EchoMessages.cs
src/csharp/Grpc.IntegrationTesting/Empty.cs
src/csharp/Grpc.IntegrationTesting/Messages.cs
src/csharp/Grpc.IntegrationTesting/Metrics.cs
src/csharp/Grpc.IntegrationTesting/Payloads.cs
src/csharp/Grpc.IntegrationTesting/Stats.cs
src/csharp/Grpc.Reflection/Reflection.cs
src/csharp/build/dependencies.props
src/csharp/experimental/build_native_ext_for_ios.sh
src/csharp/ext/grpc_csharp_ext.c
src/objective-c/!ProtoCompiler-gRPCCppPlugin.podspec
src/objective-c/!ProtoCompiler-gRPCPlugin.podspec
src/objective-c/!ProtoCompiler.podspec
src/objective-c/BoringSSL-GRPC.podspec
src/objective-c/GRPCClient/GRPCCallLegacy.h
src/objective-c/GRPCClient/GRPCCallLegacy.m
src/objective-c/GRPCClient/private/GRPCCore/GRPCChannelPool.m
src/objective-c/GRPCClient/private/GRPCCore/GRPCHost.m
src/objective-c/GRPCClient/private/GRPCCore/GRPCSecureChannelFactory.m
src/objective-c/GRPCClient/private/GRPCCore/GRPCWrappedCall.m
src/objective-c/GRPCClient/version.h
src/objective-c/tests/InteropTests/InteropTests.m
src/objective-c/tests/run_one_test.sh
src/objective-c/tests/version.h
src/php/bin/xds_manager.py
src/php/composer.json
src/php/ext/grpc/version.h
src/php/tests/generated_code/math_server.php
src/php/tests/generated_code/package.json
src/php/tests/interop/Grpc/Testing/ResponseParameters.php
src/php/tests/interop/Grpc/Testing/SimpleRequest.php
src/php/tests/interop/Grpc/Testing/SimpleResponse.php
src/php/tests/interop/Grpc/Testing/StreamingInputCallRequest.php
src/php/tests/interop/Grpc/Testing/StreamingOutputCallRequest.php
src/php/tests/interop/Grpc/Testing/StreamingOutputCallResponse.php
src/proto/grpc/testing/xds/v3/BUILD
src/proto/grpc/testing/xds/v3/base.proto
src/proto/grpc/testing/xds/v3/extension.proto [new file with mode: 0644]
src/proto/grpc/testing/xds/v3/tls.proto
src/python/grpcio/README.rst
src/python/grpcio/grpc/__init__.py
src/python/grpcio/grpc/_cython/_cygrpc/aio/completion_queue.pxd.pxi
src/python/grpcio/grpc/_cython/_cygrpc/aio/completion_queue.pyx.pxi
src/python/grpcio/grpc/_cython/_cygrpc/aio/grpc_aio.pyx.pxi
src/python/grpcio/grpc/_cython/_cygrpc/aio/iomgr/iomgr.pyx.pxi [deleted file]
src/python/grpcio/grpc/_cython/_cygrpc/aio/iomgr/resolver.pyx.pxi [deleted file]
src/python/grpcio/grpc/_cython/_cygrpc/aio/iomgr/socket.pxd.pxi [deleted file]
src/python/grpcio/grpc/_cython/_cygrpc/aio/iomgr/socket.pyx.pxi [deleted file]
src/python/grpcio/grpc/_cython/_cygrpc/aio/iomgr/timer.pyx.pxi [deleted file]
src/python/grpcio/grpc/_cython/cygrpc.pxd
src/python/grpcio/grpc/_cython/cygrpc.pyx
src/python/grpcio/grpc/_grpcio_metadata.py
src/python/grpcio/grpc/aio/_base_server.py
src/python/grpcio/grpc_core_dependencies.py
src/python/grpcio/grpc_version.py
src/python/grpcio_admin/grpc_version.py
src/python/grpcio_channelz/README.rst
src/python/grpcio_channelz/grpc_version.py
src/python/grpcio_channelz/setup.py
src/python/grpcio_csds/grpc_version.py
src/python/grpcio_health_checking/README.rst
src/python/grpcio_health_checking/grpc_version.py
src/python/grpcio_health_checking/setup.py
src/python/grpcio_reflection/README.rst
src/python/grpcio_reflection/grpc_version.py
src/python/grpcio_reflection/setup.py
src/python/grpcio_status/README.rst
src/python/grpcio_status/grpc_version.py
src/python/grpcio_status/setup.py
src/python/grpcio_testing/README.rst
src/python/grpcio_testing/grpc_version.py
src/python/grpcio_tests/grpc_version.py
src/python/grpcio_tests/tests/unit/_api_test.py
src/python/grpcio_tests/tests/unit/_dns_resolver_test.py
src/python/grpcio_tests/tests_py3_only/interop/xds_interop_client.py
src/ruby/ext/grpc/extconf.rb
src/ruby/ext/grpc/rb_byte_buffer.c
src/ruby/ext/grpc/rb_call.c
src/ruby/ext/grpc/rb_call_credentials.c
src/ruby/ext/grpc/rb_channel.c
src/ruby/ext/grpc/rb_channel_args.c
src/ruby/ext/grpc/rb_channel_credentials.c
src/ruby/ext/grpc/rb_channel_credentials.h
src/ruby/ext/grpc/rb_completion_queue.c
src/ruby/ext/grpc/rb_compression_options.c
src/ruby/ext/grpc/rb_event_thread.c
src/ruby/ext/grpc/rb_grpc.c
src/ruby/ext/grpc/rb_grpc.h
src/ruby/ext/grpc/rb_server.c
src/ruby/ext/grpc/rb_server_credentials.c
src/ruby/ext/grpc/rb_server_credentials.h
src/ruby/ext/grpc/rb_xds_channel_credentials.c
src/ruby/ext/grpc/rb_xds_channel_credentials.h
src/ruby/ext/grpc/rb_xds_server_credentials.c
src/ruby/ext/grpc/rb_xds_server_credentials.h
src/ruby/lib/grpc/version.rb
src/ruby/tools/version.rb
src/upb/gen_build_yaml.py
templates/gRPC-Core.podspec.template
templates/src/objective-c/BoringSSL-GRPC.podspec.template
templates/tools/dockerfile/debian_8_header.include [new file with mode: 0644]
templates/tools/dockerfile/debian_9_header.include [new file with mode: 0644]
templates/tools/dockerfile/debian_jessie_header.include [deleted file]
templates/tools/dockerfile/grpc_clang_tidy/Dockerfile.template
templates/tools/dockerfile/interoptest/grpc_interop_cxx/Dockerfile.template
templates/tools/dockerfile/interoptest/grpc_interop_java/Dockerfile.include
templates/tools/dockerfile/interoptest/grpc_interop_node/Dockerfile.template
templates/tools/dockerfile/interoptest/grpc_interop_nodepurejs/Dockerfile.template
templates/tools/dockerfile/interoptest/grpc_interop_php7/Dockerfile.template
templates/tools/dockerfile/python_deps.include
templates/tools/dockerfile/ruby_deps.include
templates/tools/dockerfile/test/cxx_alpine_x64/Dockerfile.template
templates/tools/dockerfile/test/cxx_jessie_x64/Dockerfile.template
templates/tools/dockerfile/test/node_jessie_x64/Dockerfile.template
templates/tools/dockerfile/test/php7_jessie_x64/Dockerfile.template
test/core/address_utils/parse_address_test.cc
test/core/address_utils/parse_address_with_named_scope_id_test.cc
test/core/address_utils/sockaddr_utils_test.cc
test/core/backoff/backoff_test.cc
test/core/bad_client/bad_client.cc
test/core/bad_client/bad_client.h
test/core/bad_client/tests/bad_streaming_id.cc
test/core/bad_client/tests/badreq.cc
test/core/bad_client/tests/duplicate_header.cc
test/core/bad_client/tests/head_of_line_blocking.cc
test/core/bad_client/tests/large_metadata.cc
test/core/bad_client/tests/out_of_bounds.cc
test/core/bad_client/tests/server_registered_method.cc
test/core/bad_client/tests/simple_request.cc
test/core/bad_client/tests/unknown_frame.cc
test/core/bad_client/tests/window_overflow.cc
test/core/bad_connection/close_fd_test.cc
test/core/bad_ssl/server_common.cc
test/core/bad_ssl/servers/alpn.cc
test/core/bad_ssl/servers/cert.cc
test/core/channel/channel_args_test.cc
test/core/channel/channel_trace_test.cc
test/core/channel/channelz_registry_test.cc
test/core/channel/channelz_test.cc
test/core/channel/minimal_stack_is_minimal_test.cc
test/core/client_channel/certificate_provider_registry_test.cc
test/core/client_channel/resolvers/fake_resolver_test.cc
test/core/client_channel/resolvers/sockaddr_resolver_test.cc
test/core/client_channel/service_config_test.cc
test/core/compiler_bugs/BUILD [new file with mode: 0644]
test/core/compiler_bugs/miscompile_with_no_unique_address_test.cc [new file with mode: 0644]
test/core/compression/algorithm_test.cc
test/core/compression/message_compress_fuzzer.cc
test/core/compression/message_compress_test.cc
test/core/compression/message_decompress_fuzzer.cc
test/core/compression/stream_compression_fuzzer.cc
test/core/compression/stream_compression_test.cc
test/core/compression/stream_decompression_fuzzer.cc
test/core/config/BUILD [new file with mode: 0644]
test/core/config/core_configuration_test.cc [new file with mode: 0644]
test/core/debug/stats_test.cc
test/core/end2end/bad_server_response_test.cc
test/core/end2end/connection_refused_test.cc
test/core/end2end/cq_verifier.cc
test/core/end2end/cq_verifier.h
test/core/end2end/cq_verifier_native.cc
test/core/end2end/cq_verifier_uv.cc [deleted file]
test/core/end2end/end2end_test_utils.cc
test/core/end2end/end2end_tests.cc
test/core/end2end/fixtures/h2_census.cc
test/core/end2end/fixtures/h2_compress.cc
test/core/end2end/fixtures/h2_fakesec.cc
test/core/end2end/fixtures/h2_fd.cc
test/core/end2end/fixtures/h2_full+pipe.cc
test/core/end2end/fixtures/h2_full+trace.cc
test/core/end2end/fixtures/h2_full+workarounds.cc
test/core/end2end/fixtures/h2_full.cc
test/core/end2end/fixtures/h2_http_proxy.cc
test/core/end2end/fixtures/h2_insecure.cc
test/core/end2end/fixtures/h2_oauth2.cc
test/core/end2end/fixtures/h2_proxy.cc
test/core/end2end/fixtures/h2_sockpair+trace.cc
test/core/end2end/fixtures/h2_sockpair.cc
test/core/end2end/fixtures/h2_sockpair_1byte.cc
test/core/end2end/fixtures/h2_ssl.cc
test/core/end2end/fixtures/h2_ssl_cred_reload.cc
test/core/end2end/fixtures/h2_ssl_proxy.cc
test/core/end2end/fixtures/h2_tls.cc
test/core/end2end/fixtures/h2_uds.cc
test/core/end2end/fixtures/http_proxy_fixture.cc
test/core/end2end/fixtures/inproc.cc
test/core/end2end/fixtures/local_util.h
test/core/end2end/fuzzers/client_fuzzer.cc
test/core/end2end/fuzzers/server_fuzzer.cc
test/core/end2end/generate_tests.bzl
test/core/end2end/goaway_server_test.cc
test/core/end2end/h2_ssl_cert_test.cc
test/core/end2end/h2_ssl_session_reuse_test.cc
test/core/end2end/inproc_callback_test.cc
test/core/end2end/multiple_server_queues_test.cc
test/core/end2end/tests/authority_not_supported.cc
test/core/end2end/tests/bad_hostname.cc
test/core/end2end/tests/bad_ping.cc
test/core/end2end/tests/binary_metadata.cc
test/core/end2end/tests/call_creds.cc
test/core/end2end/tests/call_host_override.cc
test/core/end2end/tests/cancel_after_accept.cc
test/core/end2end/tests/cancel_after_client_done.cc
test/core/end2end/tests/cancel_after_invoke.cc
test/core/end2end/tests/cancel_after_round_trip.cc
test/core/end2end/tests/cancel_before_invoke.cc
test/core/end2end/tests/cancel_in_a_vacuum.cc
test/core/end2end/tests/cancel_with_status.cc
test/core/end2end/tests/channelz.cc
test/core/end2end/tests/client_streaming.cc
test/core/end2end/tests/compressed_payload.cc
test/core/end2end/tests/connectivity.cc
test/core/end2end/tests/default_host.cc
test/core/end2end/tests/disappearing_server.cc
test/core/end2end/tests/empty_batch.cc
test/core/end2end/tests/filter_causes_close.cc
test/core/end2end/tests/filter_context.cc
test/core/end2end/tests/filter_init_fails.cc
test/core/end2end/tests/filter_latency.cc
test/core/end2end/tests/filter_status_code.cc
test/core/end2end/tests/graceful_server_shutdown.cc
test/core/end2end/tests/high_initial_seqno.cc
test/core/end2end/tests/hpack_size.cc
test/core/end2end/tests/idempotent_request.cc
test/core/end2end/tests/invoke_large_request.cc
test/core/end2end/tests/keepalive_timeout.cc
test/core/end2end/tests/large_metadata.cc
test/core/end2end/tests/load_reporting_hook.cc
test/core/end2end/tests/max_concurrent_streams.cc
test/core/end2end/tests/max_connection_age.cc
test/core/end2end/tests/max_connection_idle.cc
test/core/end2end/tests/max_message_length.cc
test/core/end2end/tests/negative_deadline.cc
test/core/end2end/tests/no_error_on_hotpath.cc
test/core/end2end/tests/no_logging.cc
test/core/end2end/tests/no_op.cc
test/core/end2end/tests/payload.cc
test/core/end2end/tests/ping.cc
test/core/end2end/tests/ping_pong_streaming.cc
test/core/end2end/tests/proxy_auth.cc
test/core/end2end/tests/registered_call.cc
test/core/end2end/tests/request_with_flags.cc
test/core/end2end/tests/request_with_payload.cc
test/core/end2end/tests/resource_quota_server.cc
test/core/end2end/tests/retry.cc
test/core/end2end/tests/retry_cancel_during_delay.cc
test/core/end2end/tests/retry_cancel_with_multiple_send_batches.cc
test/core/end2end/tests/retry_cancellation.cc
test/core/end2end/tests/retry_disabled.cc
test/core/end2end/tests/retry_exceeds_buffer_size_in_delay.cc
test/core/end2end/tests/retry_exceeds_buffer_size_in_initial_batch.cc
test/core/end2end/tests/retry_exceeds_buffer_size_in_subsequent_batch.cc
test/core/end2end/tests/retry_lb_drop.cc
test/core/end2end/tests/retry_lb_fail.cc
test/core/end2end/tests/retry_non_retriable_status.cc
test/core/end2end/tests/retry_non_retriable_status_before_recv_trailing_metadata_started.cc
test/core/end2end/tests/retry_per_attempt_recv_timeout.cc
test/core/end2end/tests/retry_per_attempt_recv_timeout_on_last_attempt.cc
test/core/end2end/tests/retry_recv_initial_metadata.cc
test/core/end2end/tests/retry_recv_message.cc
test/core/end2end/tests/retry_recv_trailing_metadata_error.cc
test/core/end2end/tests/retry_send_initial_metadata_refs.cc
test/core/end2end/tests/retry_send_op_fails.cc
test/core/end2end/tests/retry_server_pushback_delay.cc
test/core/end2end/tests/retry_server_pushback_disabled.cc
test/core/end2end/tests/retry_streaming.cc
test/core/end2end/tests/retry_streaming_after_commit.cc
test/core/end2end/tests/retry_streaming_succeeds_before_replay_finished.cc
test/core/end2end/tests/retry_throttled.cc
test/core/end2end/tests/retry_too_many_attempts.cc
test/core/end2end/tests/sdk_authz.cc [new file with mode: 0644]
test/core/end2end/tests/server_finishes_request.cc
test/core/end2end/tests/server_streaming.cc
test/core/end2end/tests/shutdown_finishes_calls.cc
test/core/end2end/tests/shutdown_finishes_tags.cc
test/core/end2end/tests/simple_cacheable_request.cc
test/core/end2end/tests/simple_delayed_request.cc
test/core/end2end/tests/simple_metadata.cc
test/core/end2end/tests/simple_request.cc
test/core/end2end/tests/stream_compression_compressed_payload.cc
test/core/end2end/tests/stream_compression_payload.cc
test/core/end2end/tests/stream_compression_ping_pong_streaming.cc
test/core/end2end/tests/streaming_error_response.cc
test/core/end2end/tests/trailing_metadata.cc
test/core/end2end/tests/workaround_cronet_compression.cc
test/core/end2end/tests/write_buffering.cc
test/core/end2end/tests/write_buffering_at_end.cc
test/core/event_engine/endpoint_config_test.cc
test/core/fling/client.cc
test/core/fling/server.cc
test/core/gpr/BUILD
test/core/gpr/cpu_test.cc
test/core/gpr/env_test.cc
test/core/gpr/murmur_hash_test.cc
test/core/gpr/sync_test.cc
test/core/gpr/time_test.cc
test/core/gpr/tls_test.cc
test/core/gpr/useful_test.cc
test/core/gprpp/BUILD
test/core/gprpp/bitset_test.cc
test/core/gprpp/capture_test.cc [new file with mode: 0644]
test/core/gprpp/global_config_env_test.cc
test/core/gprpp/global_config_test.cc
test/core/gprpp/host_port_test.cc
test/core/gprpp/manual_constructor_test.cc
test/core/gprpp/match_test.cc
test/core/gprpp/overload_test.cc
test/core/gprpp/stat_test.cc
test/core/gprpp/table_test.cc
test/core/gprpp/time_util_test.cc
test/core/handshake/client_ssl.cc
test/core/handshake/readahead_handshaker_server_ssl.cc
test/core/handshake/server_ssl.cc
test/core/handshake/server_ssl_common.cc
test/core/handshake/verify_peer_options.cc
test/core/http/format_request_test.cc
test/core/http/httpcli_test.cc
test/core/http/httpscli_test.cc
test/core/iomgr/buffer_list_test.cc
test/core/iomgr/endpoint_pair_test.cc
test/core/iomgr/error_test.cc
test/core/iomgr/ev_epollex_linux_test.cc
test/core/iomgr/fd_conservation_posix_test.cc
test/core/iomgr/fd_posix_test.cc
test/core/iomgr/grpc_ipv6_loopback_available_test.cc
test/core/iomgr/ios/CFStreamTests/CFStreamClientTests.mm
test/core/iomgr/ios/CFStreamTests/CFStreamEndpointTests.mm
test/core/iomgr/ios/CFStreamTests/Podfile
test/core/iomgr/load_file_test.cc
test/core/iomgr/resolve_address_posix_test.cc
test/core/iomgr/resolve_address_test.cc
test/core/iomgr/resource_quota_test.cc
test/core/iomgr/socket_utils_test.cc
test/core/iomgr/stranded_event_test.cc
test/core/iomgr/tcp_client_posix_test.cc
test/core/iomgr/tcp_client_uv_test.cc [deleted file]
test/core/iomgr/tcp_posix_test.cc
test/core/iomgr/tcp_server_posix_test.cc
test/core/iomgr/tcp_server_uv_test.cc [deleted file]
test/core/iomgr/threadpool_test.cc
test/core/iomgr/time_averaged_stats_test.cc
test/core/iomgr/timer_heap_test.cc
test/core/iomgr/timer_list_test.cc
test/core/iomgr/udp_server_test.cc
test/core/iomgr/work_serializer_test.cc
test/core/json/json_test.cc
test/core/promise/BUILD [new file with mode: 0644]
test/core/promise/activity_test.cc [new file with mode: 0644]
test/core/promise/context_test.cc [new file with mode: 0644]
test/core/promise/for_each_test.cc [new file with mode: 0644]
test/core/promise/if_test.cc [new file with mode: 0644]
test/core/promise/join_test.cc [new file with mode: 0644]
test/core/promise/latch_test.cc [new file with mode: 0644]
test/core/promise/loop_test.cc [new file with mode: 0644]
test/core/promise/map_test.cc [new file with mode: 0644]
test/core/promise/observable_test.cc [new file with mode: 0644]
test/core/promise/pipe_test.cc [new file with mode: 0644]
test/core/promise/poll_test.cc [new file with mode: 0644]
test/core/promise/promise_factory_test.cc [new file with mode: 0644]
test/core/promise/promise_test.cc [new file with mode: 0644]
test/core/promise/race_test.cc [moved from test/core/transport/binder/binder_smoke_test.cc with 67% similarity]
test/core/promise/seq_test.cc [new file with mode: 0644]
test/core/promise/try_join_test.cc [new file with mode: 0644]
test/core/promise/try_seq_test.cc [new file with mode: 0644]
test/core/security/alts_credentials_fuzzer.cc
test/core/security/alts_security_connector_test.cc
test/core/security/auth_context_test.cc
test/core/security/aws_request_signer_test.cc
test/core/security/check_gcp_environment_windows_test.cc
test/core/security/create_jwt.cc
test/core/security/credentials_test.cc
test/core/security/evaluate_args_test.cc
test/core/security/fetch_oauth2.cc
test/core/security/grpc_alts_credentials_options_test.cc
test/core/security/grpc_authorization_engine_test.cc
test/core/security/grpc_authorization_policy_provider_test.cc
test/core/security/grpc_tls_certificate_distributor_test.cc
test/core/security/grpc_tls_certificate_provider_test.cc
test/core/security/grpc_tls_credentials_options_test.cc
test/core/security/insecure_security_connector_test.cc
test/core/security/json_token_test.cc
test/core/security/jwt_verifier_test.cc
test/core/security/linux_system_roots_test.cc
test/core/security/rbac_translator_test.cc
test/core/security/secure_endpoint_test.cc
test/core/security/security_connector_test.cc
test/core/security/ssl_credentials_test.cc
test/core/security/ssl_server_fuzzer.cc
test/core/security/tls_security_connector_test.cc
test/core/slice/b64_encode_fuzzer.cc
test/core/slice/b64_test.cc
test/core/slice/percent_decode_fuzzer.cc
test/core/slice/percent_encode_fuzzer.cc
test/core/slice/percent_encoding_test.cc
test/core/slice/slice_buffer_test.cc
test/core/slice/slice_test.cc
test/core/surface/byte_buffer_reader_test.cc
test/core/surface/completion_queue_test.cc
test/core/surface/completion_queue_threading_test.cc
test/core/surface/concurrent_connectivity_test.cc
test/core/surface/init_test.cc
test/core/surface/lame_client_test.cc
test/core/surface/secure_channel_create_test.cc
test/core/surface/server_chttp2_test.cc
test/core/surface/server_test.cc
test/core/transport/bdp_estimator_test.cc
test/core/transport/binder/BUILD
test/core/transport/binder/binder_transport_test.cc [new file with mode: 0644]
test/core/transport/binder/end2end/BUILD [new file with mode: 0644]
test/core/transport/binder/end2end/binder_server_test.cc [new file with mode: 0644]
test/core/transport/binder/end2end/echo.proto [new file with mode: 0644]
test/core/transport/binder/end2end/echo_service.cc [new file with mode: 0644]
test/core/transport/binder/end2end/echo_service.h [new file with mode: 0644]
test/core/transport/binder/end2end/end2end_binder_transport_test.cc [new file with mode: 0644]
test/core/transport/binder/end2end/fake_binder.cc [new file with mode: 0644]
test/core/transport/binder/end2end/fake_binder.h [new file with mode: 0644]
test/core/transport/binder/end2end/fake_binder_test.cc [new file with mode: 0644]
test/core/transport/binder/end2end/testing_channel_create.cc [new file with mode: 0644]
test/core/transport/binder/end2end/testing_channel_create.h [new file with mode: 0644]
test/core/transport/binder/mock_objects.cc [new file with mode: 0644]
test/core/transport/binder/mock_objects.h [new file with mode: 0644]
test/core/transport/binder/transport_stream_receiver_test.cc [new file with mode: 0644]
test/core/transport/binder/wire_reader_test.cc [new file with mode: 0644]
test/core/transport/binder/wire_writer_test.cc [new file with mode: 0644]
test/core/transport/byte_stream_test.cc
test/core/transport/chttp2/BUILD
test/core/transport/chttp2/alpn_test.cc
test/core/transport/chttp2/bin_decoder_test.cc
test/core/transport/chttp2/bin_encoder_test.cc
test/core/transport/chttp2/binary-metadata.headers [new file with mode: 0644]
test/core/transport/chttp2/context_list_test.cc
test/core/transport/chttp2/flow_control_test.cc [new file with mode: 0644]
test/core/transport/chttp2/hpack_encoder_index_test.cc [new file with mode: 0644]
test/core/transport/chttp2/hpack_encoder_test.cc
test/core/transport/chttp2/hpack_parser_fuzzer_test.cc
test/core/transport/chttp2/hpack_parser_table_test.cc [moved from test/core/transport/chttp2/hpack_table_test.cc with 51% similarity]
test/core/transport/chttp2/hpack_parser_test.cc
test/core/transport/chttp2/hpack_utils_test.cc [new file with mode: 0644]
test/core/transport/chttp2/popularity_count_test.cc [new file with mode: 0644]
test/core/transport/chttp2/remove_stream_from_stalled_lists_test.cc
test/core/transport/chttp2/settings_timeout_test.cc
test/core/transport/chttp2/stream_map_test.cc
test/core/transport/chttp2/too_many_pings_test.cc
test/core/transport/chttp2/varint_test.cc
test/core/transport/error_utils_test.cc
test/core/transport/metadata_test.cc
test/core/transport/pid_controller_test.cc
test/core/transport/static_metadata_test.cc
test/core/transport/status_conversion_test.cc
test/core/transport/status_metadata_test.cc
test/core/transport/stream_owned_slice_test.cc
test/core/tsi/alts/crypt/aes_gcm_test.cc
test/core/tsi/alts/fake_handshaker/fake_handshaker_server_main.cc
test/core/tsi/alts/frame_protector/alts_counter_test.cc
test/core/tsi/alts/frame_protector/alts_crypter_test.cc
test/core/tsi/alts/frame_protector/alts_frame_protector_test.cc
test/core/tsi/alts/frame_protector/frame_handler_test.cc
test/core/tsi/alts/handshaker/alts_concurrent_connectivity_test.cc
test/core/tsi/alts/handshaker/alts_handshaker_client_test.cc
test/core/tsi/alts/handshaker/alts_tsi_handshaker_test.cc
test/core/tsi/alts/handshaker/alts_tsi_utils_test.cc
test/core/tsi/alts/handshaker/transport_security_common_api_test.cc
test/core/tsi/alts/zero_copy_frame_protector/alts_grpc_record_protocol_test.cc
test/core/tsi/alts/zero_copy_frame_protector/alts_iovec_record_protocol_test.cc
test/core/tsi/alts/zero_copy_frame_protector/alts_zero_copy_grpc_protector_test.cc
test/core/tsi/fake_transport_security_test.cc
test/core/tsi/ssl_session_cache_test.cc
test/core/tsi/ssl_transport_security_test.cc
test/core/tsi/transport_security_test.cc
test/core/tsi/transport_security_test_lib.cc
test/core/tsi/transport_security_test_lib.h
test/core/uri/uri_parser_test.cc
test/core/util/BUILD
test/core/util/cmdline.cc
test/core/util/cmdline_test.cc
test/core/util/fuzzer_corpus_test.cc
test/core/util/histogram.cc
test/core/util/histogram.h
test/core/util/histogram_test.cc
test/core/util/memory_counters.cc
test/core/util/mock_authorization_endpoint.h
test/core/util/mock_endpoint.cc
test/core/util/mock_endpoint.h
test/core/util/one_corpus_entry_fuzzer.cc
test/core/util/parse_hexstring.cc
test/core/util/passthru_endpoint.cc
test/core/util/passthru_endpoint.h
test/core/util/port.cc
test/core/util/port_isolated_runtime_environment.cc
test/core/util/port_server_client.cc
test/core/util/reconnect_server.cc
test/core/util/reconnect_server.h
test/core/util/resource_user_util.cc [new file with mode: 0644]
test/core/util/resource_user_util.h [new file with mode: 0644]
test/core/util/stack_tracer_test.cc
test/core/util/subprocess_posix.cc
test/core/util/subprocess_windows.cc
test/core/util/test_config.cc
test/core/util/test_lb_policies.cc
test/core/util/test_tcp_server.cc
test/core/util/test_tcp_server.h
test/core/util/tracer_util.cc
test/core/util/trickle_endpoint.cc
test/core/xds/certificate_provider_store_test.cc
test/core/xds/file_watcher_certificate_provider_factory_test.cc
test/core/xds/google_mesh_ca_certificate_provider_factory_test.cc
test/core/xds/xds_bootstrap_test.cc
test/core/xds/xds_certificate_provider_test.cc
test/cpp/client/client_channel_stress_test.cc
test/cpp/client/credentials_test.cc
test/cpp/client/destroy_grpclb_channel_with_active_connect_stress_test.cc
test/cpp/codegen/codegen_test_full.cc
test/cpp/codegen/golden_file_test.cc
test/cpp/codegen/proto_utils_test.cc
test/cpp/common/alarm_test.cc
test/cpp/common/alts_util_test.cc
test/cpp/common/auth_property_iterator_test.cc
test/cpp/common/channel_arguments_test.cc
test/cpp/common/channel_filter_test.cc
test/cpp/common/secure_auth_context_test.cc
test/cpp/common/time_jump_test.cc
test/cpp/common/timer_test.cc
test/cpp/end2end/BUILD
test/cpp/end2end/admin_services_end2end_test.cc
test/cpp/end2end/async_end2end_test.cc
test/cpp/end2end/cfstream_test.cc
test/cpp/end2end/channelz_service_test.cc
test/cpp/end2end/client_callback_end2end_test.cc
test/cpp/end2end/client_crash_test.cc
test/cpp/end2end/client_crash_test_server.cc
test/cpp/end2end/client_interceptors_end2end_test.cc
test/cpp/end2end/client_lb_end2end_test.cc
test/cpp/end2end/context_allocator_end2end_test.cc
test/cpp/end2end/delegating_channel_test.cc
test/cpp/end2end/end2end_test.cc
test/cpp/end2end/exception_test.cc
test/cpp/end2end/filter_end2end_test.cc
test/cpp/end2end/flaky_network_test.cc
test/cpp/end2end/generic_end2end_test.cc
test/cpp/end2end/grpclb_end2end_test.cc
test/cpp/end2end/health_service_end2end_test.cc
test/cpp/end2end/hybrid_end2end_test.cc
test/cpp/end2end/interceptors_util.h
test/cpp/end2end/message_allocator_end2end_test.cc
test/cpp/end2end/mock_test.cc
test/cpp/end2end/nonblocking_test.cc
test/cpp/end2end/port_sharing_end2end_test.cc
test/cpp/end2end/proto_server_reflection_test.cc
test/cpp/end2end/raw_end2end_test.cc
test/cpp/end2end/sdk_authz_end2end_test.cc [new file with mode: 0644]
test/cpp/end2end/server_builder_plugin_test.cc
test/cpp/end2end/server_crash_test.cc
test/cpp/end2end/server_crash_test_client.cc
test/cpp/end2end/server_early_return_test.cc
test/cpp/end2end/server_interceptors_end2end_test.cc
test/cpp/end2end/service_config_end2end_test.cc
test/cpp/end2end/shutdown_test.cc
test/cpp/end2end/streaming_throughput_test.cc
test/cpp/end2end/test_service_impl.cc
test/cpp/end2end/test_service_impl.h
test/cpp/end2end/thread_stress_test.cc
test/cpp/end2end/time_change_test.cc
test/cpp/end2end/xds_credentials_end2end_test.cc
test/cpp/end2end/xds_end2end_test.cc
test/cpp/ext/filters/census/stats_plugin_end2end_test.cc
test/cpp/grpclb/grpclb_api_test.cc
test/cpp/interop/client.cc
test/cpp/interop/client_helper.cc
test/cpp/interop/grpclb_fallback_test.cc
test/cpp/interop/http2_client.cc
test/cpp/interop/http2_client.h
test/cpp/interop/interop_client.cc
test/cpp/interop/interop_client.h
test/cpp/interop/interop_server.cc
test/cpp/interop/interop_test.cc
test/cpp/interop/metrics_client.cc
test/cpp/interop/reconnect_interop_client.cc
test/cpp/interop/reconnect_interop_server.cc
test/cpp/interop/server_helper.cc
test/cpp/interop/server_helper.h
test/cpp/interop/stress_test.cc
test/cpp/interop/xds_interop_client.cc
test/cpp/interop/xds_interop_server.cc
test/cpp/ios/CronetTests/TestHelper.h
test/cpp/microbenchmarks/bm_alarm.cc
test/cpp/microbenchmarks/bm_arena.cc
test/cpp/microbenchmarks/bm_byte_buffer.cc
test/cpp/microbenchmarks/bm_call_create.cc
test/cpp/microbenchmarks/bm_channel.cc
test/cpp/microbenchmarks/bm_chttp2_hpack.cc
test/cpp/microbenchmarks/bm_chttp2_transport.cc
test/cpp/microbenchmarks/bm_closure.cc
test/cpp/microbenchmarks/bm_cq.cc
test/cpp/microbenchmarks/bm_cq_multiple_threads.cc
test/cpp/microbenchmarks/bm_error.cc
test/cpp/microbenchmarks/bm_fullstack_trickle.cc
test/cpp/microbenchmarks/bm_metadata.cc
test/cpp/microbenchmarks/bm_opencensus_plugin.cc
test/cpp/microbenchmarks/bm_pollset.cc
test/cpp/microbenchmarks/bm_threadpool.cc
test/cpp/microbenchmarks/bm_timer.cc
test/cpp/microbenchmarks/callback_streaming_ping_pong.h
test/cpp/microbenchmarks/callback_test_service.h
test/cpp/microbenchmarks/callback_unary_ping_pong.h
test/cpp/microbenchmarks/fullstack_fixtures.h
test/cpp/microbenchmarks/fullstack_streaming_ping_pong.h
test/cpp/microbenchmarks/fullstack_streaming_pump.h
test/cpp/microbenchmarks/fullstack_unary_ping_pong.h
test/cpp/microbenchmarks/helpers.cc
test/cpp/microbenchmarks/helpers.h
test/cpp/naming/address_sorting_test.cc
test/cpp/naming/cancel_ares_query_test.cc
test/cpp/naming/dns_test_util.cc
test/cpp/naming/resolver_component_test.cc
test/cpp/naming/resolver_component_tests_runner_invoker.cc
test/cpp/performance/writes_per_rpc_test.cc
test/cpp/qps/benchmark_config.cc
test/cpp/qps/client.h
test/cpp/qps/client_async.cc
test/cpp/qps/client_callback.cc
test/cpp/qps/driver.cc
test/cpp/qps/qps_benchmark_script.bzl
test/cpp/qps/qps_interarrival_test.cc
test/cpp/qps/qps_json_driver.cc
test/cpp/qps/qps_worker.cc
test/cpp/qps/report.cc
test/cpp/qps/report.h
test/cpp/qps/server.h
test/cpp/qps/server_async.cc
test/cpp/qps/worker.cc
test/cpp/server/authorization_policy_provider_test.cc
test/cpp/server/credentials_test.cc
test/cpp/server/load_reporter/get_cpu_stats_test.cc
test/cpp/server/load_reporter/load_data_store_test.cc
test/cpp/server/load_reporter/load_reporter_test.cc
test/cpp/server/server_builder_test.cc
test/cpp/server/server_builder_with_socket_mutator_test.cc
test/cpp/server/server_request_call_test.cc
test/cpp/test/client_context_test_peer_test.cc
test/cpp/test/mock_stream_test.cc
test/cpp/test/server_context_test_spouse_test.cc
test/cpp/thread_manager/thread_manager_test.cc
test/cpp/util/BUILD
test/cpp/util/byte_buffer_test.cc
test/cpp/util/channel_trace_proto_helper.cc
test/cpp/util/channelz_sampler.cc
test/cpp/util/channelz_sampler_test.cc
test/cpp/util/cli_call.cc
test/cpp/util/cli_call.h
test/cpp/util/cli_call_test.cc
test/cpp/util/cli_credentials.cc
test/cpp/util/create_test_channel.cc
test/cpp/util/error_details_test.cc
test/cpp/util/grpc_cli.cc
test/cpp/util/grpc_tool.cc
test/cpp/util/grpc_tool_test.cc
test/cpp/util/proto_reflection_descriptor_database.h
test/cpp/util/service_describer.h
test/cpp/util/slice_test.cc
test/cpp/util/string_ref_test.cc
test/cpp/util/test_config.h
test/cpp/util/test_config_cc.cc
test/cpp/util/test_credentials_provider.cc
test/cpp/util/time_test.cc
test/distrib/cpp/run_distrib_test_cmake_aarch64_cross.sh
test/distrib/cpp/run_distrib_test_cmake_module_install.sh
test/distrib/cpp/run_distrib_test_cmake_module_install_pkgconfig.sh
third_party/README.md
third_party/protobuf.patch
third_party/upb/.bazelci/presubmit.yml
third_party/upb/.bazelrc
third_party/upb/.github/workflows/cifuzz.yml [new file with mode: 0644]
third_party/upb/BUILD
third_party/upb/LICENSE
third_party/upb/README.md
third_party/upb/WORKSPACE
third_party/upb/bazel/BUILD
third_party/upb/bazel/build_defs.bzl
third_party/upb/bazel/lua.BUILD
third_party/upb/bazel/ragel.BUILD [deleted file]
third_party/upb/bazel/upb_proto_library.bzl
third_party/upb/bazel/workspace_deps.bzl
third_party/upb/benchmarks/BUILD
third_party/upb/benchmarks/BUILD.googleapis
third_party/upb/benchmarks/benchmark.cc
third_party/upb/benchmarks/build_defs.bzl
third_party/upb/benchmarks/compare.py
third_party/upb/benchmarks/gen_protobuf_binary_cc.py
third_party/upb/benchmarks/gen_synthetic_protos.py
third_party/upb/benchmarks/gen_upb_binary_c.py
third_party/upb/cmake/BUILD
third_party/upb/cmake/CMakeLists.txt
third_party/upb/cmake/build_defs.bzl
third_party/upb/cmake/google/protobuf/descriptor.upb.c
third_party/upb/cmake/google/protobuf/descriptor.upb.h
third_party/upb/cmake/make_cmakelists.py
third_party/upb/cmake/staleness_test.py
third_party/upb/cmake/staleness_test_lib.py
third_party/upb/cmake/upb/json/parser.c [deleted file]
third_party/upb/examples/bazel/BUILD
third_party/upb/examples/bazel/test_binary.c
third_party/upb/kokoro/ubuntu/build.sh
third_party/upb/tests/BUILD
third_party/upb/tests/bindings/lua/BUILD
third_party/upb/tests/bindings/lua/main.c
third_party/upb/tests/bindings/lua/test.proto
third_party/upb/tests/bindings/lua/test_upb.lua
third_party/upb/tests/conformance_upb.c
third_party/upb/tests/corpus/temp.cc
third_party/upb/tests/file_descriptor_parsenew_fuzzer.cc
third_party/upb/tests/json/enum_from_separate_file.proto [deleted file]
third_party/upb/tests/json/test.proto [deleted file]
third_party/upb/tests/json/test.proto.pb [deleted file]
third_party/upb/tests/json/test_json.cc [deleted file]
third_party/upb/tests/pb/test_decoder.cc [deleted file]
third_party/upb/tests/pb/test_decoder.proto [deleted file]
third_party/upb/tests/pb/test_encoder.cc [deleted file]
third_party/upb/tests/test_cpp.cc
third_party/upb/tests/test_cpp.proto
third_party/upb/tests/test_generated_code.c
third_party/upb/tests/test_table.cc
third_party/upb/tests/test_util.h [deleted file]
third_party/upb/tests/testmain.cc
third_party/upb/tests/upb_test.h
third_party/upb/third_party/wyhash/BUILD [deleted file]
third_party/upb/third_party/wyhash/LICENSE [deleted file]
third_party/upb/third_party/wyhash/wyhash.h [deleted file]
third_party/upb/tools/amalgamate.py
third_party/upb/upb/bindings/lua/BUILD
third_party/upb/upb/bindings/lua/def.c
third_party/upb/upb/bindings/lua/lua_proto_library.bzl
third_party/upb/upb/bindings/lua/msg.c
third_party/upb/upb/bindings/lua/upb.c
third_party/upb/upb/bindings/lua/upb.h
third_party/upb/upb/bindings/lua/upb.lua
third_party/upb/upb/bindings/lua/upbc.cc
third_party/upb/upb/decode.c
third_party/upb/upb/decode.h
third_party/upb/upb/decode_fast.c
third_party/upb/upb/decode_fast.h
third_party/upb/upb/decode_internal.h [moved from third_party/upb/upb/decode.int.h with 68% similarity]
third_party/upb/upb/def.c
third_party/upb/upb/def.h
third_party/upb/upb/def.hpp
third_party/upb/upb/encode.c
third_party/upb/upb/encode.h
third_party/upb/upb/handlers-inl.h [deleted file]
third_party/upb/upb/handlers.c [deleted file]
third_party/upb/upb/handlers.h [deleted file]
third_party/upb/upb/json/parser.h [deleted file]
third_party/upb/upb/json/parser.rl [deleted file]
third_party/upb/upb/json/printer.c [deleted file]
third_party/upb/upb/json/printer.h [deleted file]
third_party/upb/upb/json_decode.c
third_party/upb/upb/json_decode.h
third_party/upb/upb/json_encode.c
third_party/upb/upb/json_encode.h
third_party/upb/upb/msg.c
third_party/upb/upb/msg.h
third_party/upb/upb/msg_internal.h [new file with mode: 0644]
third_party/upb/upb/pb/compile_decoder.c [deleted file]
third_party/upb/upb/pb/decoder.c [deleted file]
third_party/upb/upb/pb/decoder.h [deleted file]
third_party/upb/upb/pb/decoder.int.h [deleted file]
third_party/upb/upb/pb/encoder.c [deleted file]
third_party/upb/upb/pb/encoder.h [deleted file]
third_party/upb/upb/pb/make-gdb-script.rb [deleted file]
third_party/upb/upb/pb/textprinter.c [deleted file]
third_party/upb/upb/pb/textprinter.h [deleted file]
third_party/upb/upb/pb/varint.c [deleted file]
third_party/upb/upb/pb/varint.int.h [deleted file]
third_party/upb/upb/port_def.inc
third_party/upb/upb/port_undef.inc
third_party/upb/upb/reflection.c
third_party/upb/upb/reflection.h
third_party/upb/upb/reflection.hpp [new file with mode: 0644]
third_party/upb/upb/sink.c [deleted file]
third_party/upb/upb/sink.h [deleted file]
third_party/upb/upb/table.c
third_party/upb/upb/table_internal.h [moved from third_party/upb/upb/table.int.h with 60% similarity]
third_party/upb/upb/text_encode.c
third_party/upb/upb/text_encode.h
third_party/upb/upb/upb.c
third_party/upb/upb/upb.h
third_party/upb/upb/upb.hpp
third_party/upb/upb/upb.int.h [deleted file]
third_party/upb/upb/upb_internal.h [new file with mode: 0644]
third_party/upb/upbc/BUILD
third_party/upb/upbc/common.cc
third_party/upb/upbc/common.h
third_party/upb/upbc/message_layout.cc
third_party/upb/upbc/message_layout.h
third_party/upb/upbc/protoc-gen-upb.cc
third_party/upb/upbc/protoc-gen-upbdefs.cc
third_party/xxhash/LICENSE
tools/buildgen/plugins/make_fuzzer_tests.py
tools/codegen/core/gen_legal_metadata_characters.cc [deleted file]
tools/codegen/core/gen_percent_encoding_tables.cc [deleted file]
tools/codegen/core/gen_switch.py [new file with mode: 0755]
tools/distrib/add-iwyu.py [new file with mode: 0755]
tools/distrib/python/grpc_version.py
tools/distrib/python/grpcio_tools/README.rst
tools/distrib/python/grpcio_tools/grpc_tools/main.cc
tools/distrib/python/grpcio_tools/grpc_version.py
tools/distrib/python/grpcio_tools/protoc_lib_deps.py
tools/distrib/run_clang_tidy.py
tools/distrib/sanitize.sh
tools/dockerfile/distribtest/python_buster_x64/Dockerfile [moved from tools/dockerfile/distribtest/python_stretch_x64/Dockerfile with 97% similarity]
tools/dockerfile/distribtest/python_buster_x86/Dockerfile [moved from tools/dockerfile/distribtest/python_stretch_x86/Dockerfile with 97% similarity]
tools/dockerfile/grpc_artifact_centos6_x64/Dockerfile
tools/dockerfile/grpc_artifact_centos6_x86/Dockerfile
tools/dockerfile/grpc_artifact_python_linux_armv7/Dockerfile
tools/dockerfile/grpc_artifact_python_linux_armv7/install_python_for_wheel_crosscompilation.sh
tools/dockerfile/grpc_artifact_python_manylinux2014_aarch64/Dockerfile [moved from tools/dockerfile/grpc_artifact_python_manylinux_2_24_aarch64/Dockerfile with 63% similarity]
tools/dockerfile/grpc_artifact_python_manylinux2014_x64/Dockerfile
tools/dockerfile/grpc_artifact_python_manylinux2014_x86/Dockerfile
tools/dockerfile/grpc_clang_format/clang_format_all_the_things.sh
tools/dockerfile/grpc_clang_tidy/Dockerfile
tools/dockerfile/interoptest/grpc_interop_csharp/Dockerfile
tools/dockerfile/interoptest/grpc_interop_csharpcoreclr/Dockerfile
tools/dockerfile/interoptest/grpc_interop_cxx/Dockerfile
tools/dockerfile/interoptest/grpc_interop_go/Dockerfile
tools/dockerfile/interoptest/grpc_interop_go1.11/Dockerfile
tools/dockerfile/interoptest/grpc_interop_go1.16/Dockerfile
tools/dockerfile/interoptest/grpc_interop_go1.8/Dockerfile
tools/dockerfile/interoptest/grpc_interop_http2/Dockerfile
tools/dockerfile/interoptest/grpc_interop_java/Dockerfile
tools/dockerfile/interoptest/grpc_interop_node/Dockerfile
tools/dockerfile/interoptest/grpc_interop_nodepurejs/Dockerfile
tools/dockerfile/interoptest/grpc_interop_php7/Dockerfile
tools/dockerfile/interoptest/grpc_interop_ruby/Dockerfile
tools/dockerfile/interoptest/lb_interop_fake_servers/Dockerfile
tools/dockerfile/test/csharp_buster_x64/Dockerfile
tools/dockerfile/test/cxx_alpine_x64/Dockerfile
tools/dockerfile/test/cxx_buster_openssl102_x64/Dockerfile
tools/dockerfile/test/cxx_buster_x64/Dockerfile
tools/dockerfile/test/cxx_jessie_x64/Dockerfile
tools/dockerfile/test/cxx_jessie_x86/Dockerfile
tools/dockerfile/test/cxx_ubuntu1604_x64/Dockerfile
tools/dockerfile/test/cxx_ubuntu1804_x64/Dockerfile
tools/dockerfile/test/node_jessie_x64/Dockerfile
tools/dockerfile/test/php73_zts_stretch_x64/Dockerfile
tools/dockerfile/test/php7_jessie_x64/Dockerfile
tools/dockerfile/test/python_alpine_x64/Dockerfile
tools/dockerfile/test/ruby_buster_x64/Dockerfile
tools/doxygen/Doxyfile.c++
tools/doxygen/Doxyfile.c++.internal
tools/doxygen/Doxyfile.core
tools/doxygen/Doxyfile.core.internal
tools/doxygen/Doxyfile.objc
tools/doxygen/Doxyfile.objc.internal
tools/doxygen/Doxyfile.php
tools/internal_ci/helper_scripts/install_python_interpreters.ps1
tools/internal_ci/helper_scripts/list_leftover_loadtests.sh [deleted file]
tools/internal_ci/helper_scripts/prepare_build_macos_rc
tools/internal_ci/linux/grpc_binder_transport_apk_build_in_docker.sh
tools/internal_ci/linux/grpc_distribtests_php.cfg [moved from tools/internal_ci/windows/pull_request/grpc_portability.cfg with 78% similarity]
tools/internal_ci/linux/grpc_distribtests_php.sh [new file with mode: 0755]
tools/internal_ci/linux/grpc_distribtests_python.sh
tools/internal_ci/linux/grpc_distribtests_ruby.cfg [new file with mode: 0644]
tools/internal_ci/linux/grpc_distribtests_ruby.sh [new file with mode: 0755]
tools/internal_ci/linux/grpc_e2e_performance_gke.sh
tools/internal_ci/linux/grpc_e2e_performance_v2.sh
tools/internal_ci/linux/grpc_xds_bazel_python_test_in_docker.sh
tools/internal_ci/linux/grpc_xds_bazel_test_in_docker.sh
tools/internal_ci/linux/grpc_xds_k8s_install_test_driver.sh
tools/internal_ci/linux/grpc_xds_k8s_lb.cfg [new file with mode: 0644]
tools/internal_ci/linux/grpc_xds_k8s_lb.sh [new file with mode: 0755]
tools/internal_ci/linux/grpc_xds_k8s_lb_python.cfg [new file with mode: 0644]
tools/internal_ci/linux/grpc_xds_k8s_lb_python.sh [new file with mode: 0755]
tools/internal_ci/linux/grpc_xds_k8s_xlang.cfg [new file with mode: 0644]
tools/internal_ci/linux/grpc_xds_k8s_xlang.sh [new file with mode: 0755]
tools/internal_ci/linux/grpc_xds_php_test_in_docker.sh
tools/internal_ci/linux/grpc_xds_ruby_test_in_docker.sh
tools/internal_ci/linux/grpc_xds_url_map.cfg
tools/internal_ci/linux/grpc_xds_url_map.sh
tools/internal_ci/linux/grpc_xds_url_map_python.cfg
tools/internal_ci/linux/grpc_xds_url_map_python.sh
tools/internal_ci/macos/grpc_distribtests_php.cfg [new file with mode: 0644]
tools/internal_ci/macos/grpc_distribtests_php.sh [new file with mode: 0644]
tools/internal_ci/windows/grpc_portability.cfg
tools/interop_matrix/client_matrix.py
tools/interop_matrix/create_matrix_images.py
tools/run_tests/artifacts/artifact_targets.py
tools/run_tests/artifacts/build_artifact_php.sh
tools/run_tests/artifacts/build_artifact_python.sh
tools/run_tests/artifacts/build_package_php.sh
tools/run_tests/artifacts/build_package_python.sh
tools/run_tests/artifacts/build_package_ruby.sh
tools/run_tests/artifacts/distribtest_targets.py
tools/run_tests/generated/tests.json
tools/run_tests/helper_scripts/prep_xds.sh
tools/run_tests/performance/bq_upload_result.py
tools/run_tests/performance/scenario_result_schema.json
tools/run_tests/python_utils/jobset.py
tools/run_tests/run_tests.py
tools/run_tests/run_tests_matrix.py
tools/run_tests/run_xds_tests.py
tools/run_tests/sanity/check_do_not_submit.sh [moved from src/python/grpcio/grpc/_cython/_cygrpc/aio/iomgr/timer.pxd.pxi with 64% similarity, mode: 0755]
tools/run_tests/sanity/check_include_style.py [new file with mode: 0755]
tools/run_tests/sanity/check_submodules.sh
tools/run_tests/sanity/sanity_tests.yaml
tools/run_tests/xds_k8s_test_driver/README.md
tools/run_tests/xds_k8s_test_driver/config/url-map.cfg
tools/run_tests/xds_k8s_test_driver/framework/infrastructure/gcp/api.py
tools/run_tests/xds_k8s_test_driver/framework/infrastructure/gcp/compute.py
tools/run_tests/xds_k8s_test_driver/framework/infrastructure/gcp/network_security.py
tools/run_tests/xds_k8s_test_driver/framework/infrastructure/gcp/network_services.py
tools/run_tests/xds_k8s_test_driver/framework/infrastructure/traffic_director.py
tools/run_tests/xds_k8s_test_driver/framework/test_app/client_app.py
tools/run_tests/xds_k8s_test_driver/framework/test_app/server_app.py
tools/run_tests/xds_k8s_test_driver/framework/xds_k8s_flags.py
tools/run_tests/xds_k8s_test_driver/framework/xds_k8s_testcase.py
tools/run_tests/xds_k8s_test_driver/framework/xds_url_map_test_resources.py
tools/run_tests/xds_k8s_test_driver/framework/xds_url_map_testcase.py
tools/run_tests/xds_k8s_test_driver/kubernetes-manifests/client.deployment.yaml
tools/run_tests/xds_k8s_test_driver/kubernetes-manifests/server.deployment.yaml
tools/run_tests/xds_k8s_test_driver/tests/affinity_test.py [new file with mode: 0644]
tools/run_tests/xds_k8s_test_driver/tests/app_net_test.py
tools/run_tests/xds_k8s_test_driver/tests/subsetting_test.py [new file with mode: 0644]
tools/run_tests/xds_k8s_test_driver/tests/url_map/affinity_test.py
tools/run_tests/xds_k8s_test_driver/tests/url_map/retry_test.py
tools/run_tests/xds_k8s_test_driver/tests/url_map/timeout_test.py

index 7460950..953705e 100644 (file)
@@ -3,7 +3,44 @@ Language: Cpp
 BasedOnStyle: Google
 DerivePointerAlignment: false
 PointerAlignment: Left
-IncludeBlocks: Preserve
+IncludeBlocks: Regroup
+IncludeCategories:
+  # port_platform.h is before almost everything
+  - Regex: '^<grpc/(support|impl/codegen)/port_platform.h>'
+    Priority: -100
+  # ruby.h is even more first if it's included
+  - Regex: '^<ruby/ruby.h>'
+    Priority: -200
+  # Some platforms (namely msys) need wchar to be included BEFORE
+  # anything else, especially strsafe.h.
+  - Regex: '^<wchar.h>'
+    Priority: 5
+  # use priority 100+ for grpc headers so they sort last
+  # 'system' headers - include things that have " in the names to make them
+  # stand out and get fixed
+  - Regex: '^(<|")grpc'
+    Priority: 100
+  # similary using include/ to get system headers should stand out and get
+  # fixed
+  - Regex: '^"include/'
+    Priority: 100
+  # source headers go last
+  - Regex: '^"(src|test)/'
+    Priority: 101
+  # not-grpc headers follow
+  # first, non system headers that are included like <> - these are all
+  # local carveouts, and get sorted below c++ but before non grpc "" files
+  - Regex: '^<(openssl/|uv\.h|ares\.h|address_sorting/|gmock/|gtest/|zlib|benchmark/|google/)'
+    Priority: 30
+  # first C system headers - they have a . in the filename
+  - Regex: '^<.*\.'
+    Priority: 10
+  # then C++ system headers - no ., the only thing that will match now
+  - Regex: '^<'
+    Priority: 20
+  # finally other "" includes go between system headers and our headers
+  - Regex: '^"'
+    Priority: 40
 ---
 Language: ObjC
 BasedOnStyle: Google
diff --git a/.gitattributes b/.gitattributes
new file mode 100644 (file)
index 0000000..af02580
--- /dev/null
@@ -0,0 +1,32 @@
+src/core/ext/upb-generated/** linguist-generated=true
+src/core/ext/upbdefs-generated/** linguist-generated=true
+Makefile linguist-generated=true
+BUILD.gn linguist-generated=true
+CMakeLists.txt linguist-generated=true
+build_autogenerated.yaml linguist-generated=true
+config.m4 linguist-generated=true
+config.w32 linguist-generated=true
+gRPC-C++.podspec linguist-generated=true
+gRPC-Core.podspec linguist-generated=true
+gRPC-ProtoRPC.podspec linguist-generated=true
+gRPC-RxLibrary.podspec linguist-generated=true
+gRPC.podspec linguist-generated=true
+grpc.gemspec linguist-generated=true
+grpc.gyp linguist-generated=true
+grpc.def linguist-generated=true
+package.xml linguist-generated=true
+binding.gyp linguist-generated=true
+src/python/grpcio/grpc_core_dependencies.py linguist-generated=true
+src/ruby/ext/grpc/rb_grpc_imports.generated.h linguist-generated=true
+src/ruby/ext/grpc/rb_grpc_imports.generated.c linguist-generated=true
+test/core/end2end/end2end_tests.cc linguist-generated=true
+test/core/end2end/end2end_nosec_tests.cc linguist-generated=true
+test/core/surface/public_headers_must_be_c89.c linguist-generated=true
+tools/doxygen/Doxyfile.c++.internal linguist-generated=true
+tools/doxygen/Doxyfile.core.internal linguist-generated=true
+tools/run_tests/sources_and_headers.json linguist-generated=true
+tools/run_tests/tests.json linguist-generated=true
+tools/run_tests/generated/tests.json linguist-generated=true
+tools/run_tests/generated/sources_and_headers.json linguist-generated=true
+src/core/lib/transport/static_metadata.h linguist-generated=true
+src/core/lib/transport/static_metadata.cc linguist-generated=true
index a191005..111533e 100644 (file)
@@ -2,7 +2,7 @@
 name: Report a bug
 about: Create a report to help us improve
 labels: kind/bug, priority/P2
-assignees: yashykt
+assignees: drfloob
 
 ---
 
index 98b0a5a..6652601 100644 (file)
@@ -2,7 +2,7 @@
 name: Request a cleanup
 about: Suggest a cleanup in our repository
 labels: kind/internal cleanup, priority/P2
-assignees: yashykt
+assignees: drfloob
 
 ---
 
index b6a5493..adc5b1c 100644 (file)
@@ -2,7 +2,7 @@
 name: Request a feature
 about: Suggest an idea for this project
 labels: kind/enhancement, priority/P2
-assignees: yashykt
+assignees: drfloob
 
 ---
 
index b92cd62..770a386 100644 (file)
@@ -2,7 +2,7 @@
 name: Ask a question
 about: Ask a question
 labels: kind/question, priority/P3
-assignees: yashykt
+assignees: drfloob
 
 ---
 
diff --git a/.github/labeler.yml b/.github/labeler.yml
new file mode 100644 (file)
index 0000000..ed627b2
--- /dev/null
@@ -0,0 +1,15 @@
+lang/core:
+- src/core/**
+- include/grpc/**
+- test/core/**
+- tools/codegen/core/**
+
+lang/c++:
+- src/cpp/**
+- include/grpc++/**
+- include/grpcpp/**
+- test/cpp/**
+
+area/infra:
+- .github/**
+
index 380c2bd..5424b01 100644 (file)
@@ -8,4 +8,4 @@ If you know who should review your pull request, please remove the mentioning be
 
 -->
 
-@yashykt
+@drfloob
diff --git a/.github/workflows/happy-pancakes.yml b/.github/workflows/happy-pancakes.yml
new file mode 100644 (file)
index 0000000..6b90c44
--- /dev/null
@@ -0,0 +1,74 @@
+name: Happy Pancakes
+on:
+  pull_request:
+    types: [opened, edited, labeled, unlabeled, synchronize, ready_for_review, auto_merge_enabled, auto_merge_disabled]
+jobs:
+  check_status:
+    name: Check Required Status or force-merge label
+    runs-on: ubuntu-latest
+    steps:
+      # Cancel current runs if they're still running
+      # (saves processing on fast pushes)
+      - name: Cancel Previous Runs
+        uses: styfle/cancel-workflow-action@0.9.1
+        with:
+          access_token: ${{ github.token }}
+      # Wait until our required statuses are ready or failed
+      # Unless force-merge is present, and then just be good.
+      - name: Check Status
+        uses: actions/github-script@v4
+        with:
+          script: |
+            function sleep(ms) {
+              return new Promise(resolve => setTimeout(resolve, ms));
+            }
+            let pull = await github.pulls.get({
+              owner: "grpc",
+              repo: "grpc",
+              pull_number: ${{ github.event.pull_request.number }}
+            });
+            for (var i = 0; i < pull.data.labels.length; i++) {
+              let label = pull.data.labels[i];
+              if (label.name == "force-merge") {
+                console.log("Saw force-merge label");
+                return;
+              }
+            }
+            while (true) {
+              var need = new Set();
+              need.add("Bazel Basic build for C/C++");
+              need.add("Portability Tests Linux [Build Only] (internal CI)");
+              for (var page=1;; page++) {
+                console.log("***** page " + page);
+                let statuses = await github.repos.listCommitStatusesForRef({
+                  owner: "grpc",
+                  repo: "grpc",
+                  ref: "${{ github.event.pull_request.head.sha }}",
+                  per_page: 100,
+                  page: page
+                });
+                for (var i = 0; i < statuses.data.length; i++) {
+                  let status = statuses.data[i];
+                  console.log(status.context, status.state, need);
+                  if (need.has(status.context)) {
+                    if (status.state == "success") {
+                      need.delete(status.context);
+                    } else if (status.state == "pending") {
+                      // do nothing
+                    } else {
+                      core.setFailed("Required status failed: " + status.context);
+                      return;
+                    }
+                  }
+                }
+                if (statuses.data.length < 100) {
+                  break;
+                }
+              }
+              if (need.size == 0) {
+                return;
+              }
+              // Sleep 15 minutes between polls
+              await sleep(15 * 60 * 1000);
+            }
+
diff --git a/.github/workflows/pr-auto-fix.yaml b/.github/workflows/pr-auto-fix.yaml
new file mode 100644 (file)
index 0000000..8cb40ae
--- /dev/null
@@ -0,0 +1,76 @@
+name: PR AutoFix
+on: [push]
+jobs:
+  PRAutoFix:
+    runs-on: ubuntu-latest
+    steps:
+      # Cache bazel build
+      - name: Cache bazel
+        uses: actions/cache@v2
+        env:
+          cache-name: bazel-cache
+        with:
+          path: ~/.cache/bazel
+          key: ${{ runner.os }}-${{ env.cache-name }}
+      # Cancel current runs if they're still running
+      # (saves processing on fast pushes)
+      - name: Cancel Previous Runs
+        uses: styfle/cancel-workflow-action@0.9.1
+        with:
+          access_token: ${{ github.token }}
+      # Allow opt-out for some users
+      - name: Should I Stay Or Should I Go
+        uses: actions/github-script@v4
+        id: check
+        with:
+          script: |
+            // If you'd like not to run this code on your commits, add your github user id here:
+            NO_AUTOFIX_USERS = []
+            const { owner, repo } = context.repo
+            if (NO_AUTOFIX_USERS.includes(context.actor)) {
+              console.log('Cancelling');
+              const run_id = "${{ github.run_id }}";
+              await github.actions.cancelWorkflowRun({ owner, repo, run_id });
+              return 'go';
+            } else {
+              return 'stay';
+            }
+      - name: Wait for cancellation
+        run: sleep 60
+        if: steps.check.outputs.result == 'go'
+      - name: Should build?
+        run: test "${{ steps.check.outputs.result }}" = "stay"
+      # Setup to run sanity suite
+      - name: Install Python Interpreter
+        uses: actions/setup-python@v2
+        with:
+          python-version: 3.8
+      - name: Install Python Packages
+        run: |
+          python -m pip install --upgrade pip
+          pip install pyyaml mako virtualenv
+          sudo apt-get install python-dev
+      - name: Check out repository code
+        uses: actions/checkout@v2
+        with:
+          submodules: True
+          fetch-depth: 0
+      # Run the things!
+      - name: clang-tidy fixes
+        run: ${{ github.workspace }}/tools/distrib/clang_tidy_code.sh --fix --only-changed || true
+      - name: Run sanitize
+        run: ${{ github.workspace }}/tools/distrib/sanitize.sh
+      # Report back with a PR if things are broken
+      - name: Create Pull Request
+        uses: peter-evans/create-pull-request@v3
+        with:
+          delete-branch: true
+          branch-suffix: short-commit-hash
+          commit-message: "Automated change: Fix sanity tests"
+          title: Automated fix for ${{ github.ref }}
+          body: |
+            PanCakes to the rescue!
+
+            We noticed that our 'sanity' test was going to fail, but we think we can fix that automatically, so we put together this PR to do just that!
+
+            If you'd like to opt-out of these PR's, add yourself to NO_AUTOFIX_USERS in .github/workflows/pr-auto-fix.yaml
diff --git a/.github/workflows/pr-auto-tag.yaml b/.github/workflows/pr-auto-tag.yaml
new file mode 100644 (file)
index 0000000..22041f6
--- /dev/null
@@ -0,0 +1,12 @@
+name: PR AutoTag
+on:
+  pull_request_target:
+    types: [opened, reopened, synchronized, edited]
+jobs:
+  triage:
+    runs-on: ubuntu-latest
+    steps:
+    - uses: actions/labeler@v3
+      with:
+        repo-token: "${{ secrets.GITHUB_TOKEN }}"
+
diff --git a/BUILD b/BUILD
index 6997bbe..39ee9f9 100644 (file)
--- a/BUILD
+++ b/BUILD
@@ -109,11 +109,11 @@ config_setting(
 python_config_settings()
 
 # This should be updated along with build_handwritten.yaml
-g_stands_for = "guileless"  # @unused
+g_stands_for = "goat"  # @unused
 
-core_version = "18.0.0"  # @unused
+core_version = "19.0.0"  # @unused
 
-version = "1.40.0"  # @unused
+version = "1.41.0"  # @unused
 
 GPR_PUBLIC_HDRS = [
     "include/grpc/support/alloc.h",
@@ -323,6 +323,7 @@ grpc_cc_library(
     language = "c++",
     public_hdrs = GPR_PUBLIC_HDRS,
     standalone = True,
+    tags = ["avoid_dep"],
     visibility = ["@grpc:public"],
     deps = [
         "gpr_base",
@@ -330,6 +331,13 @@ grpc_cc_library(
 )
 
 grpc_cc_library(
+    name = "atomic_utils",
+    language = "c++",
+    public_hdrs = ["src/core/lib/gprpp/atomic_utils.h"],
+    deps = ["gpr_platform"],
+)
+
+grpc_cc_library(
     name = "grpc_unsecure",
     srcs = [
         "src/core/lib/security/authorization/authorization_policy_provider_null_vtable.cc",
@@ -340,8 +348,10 @@ grpc_cc_library(
     language = "c++",
     public_hdrs = GRPC_PUBLIC_HDRS,
     standalone = True,
+    tags = ["avoid_dep"],
     visibility = ["@grpc:public"],
     deps = [
+        "config",
         "gpr_base",
         "grpc_base_c",
         "grpc_common",
@@ -379,6 +389,7 @@ grpc_cc_library(
         "@grpc:public",
     ],
     deps = [
+        "config",
         "gpr_base",
         "grpc_base_c",
         "grpc_common",
@@ -513,6 +524,7 @@ grpc_cc_library(
     ],
     language = "c++",
     standalone = True,
+    tags = ["avoid_dep"],
     visibility = ["@grpc:public"],
     deps = [
         "gpr",
@@ -587,6 +599,7 @@ grpc_cc_library(
     public_hdrs = [
         "include/grpc/census.h",
     ],
+    visibility = ["@grpc:public"],
     deps = [
         "gpr_base",
         "grpc_base_c",
@@ -638,7 +651,6 @@ grpc_cc_library(
         "src/core/lib/gpr/time_posix.cc",
         "src/core/lib/gpr/time_precise.cc",
         "src/core/lib/gpr/time_windows.cc",
-        "src/core/lib/gpr/tls_pthread.cc",
         "src/core/lib/gpr/tmpfile_msys.cc",
         "src/core/lib/gpr/tmpfile_posix.cc",
         "src/core/lib/gpr/tmpfile_windows.cc",
@@ -666,15 +678,9 @@ grpc_cc_library(
         "src/core/lib/gpr/string.h",
         "src/core/lib/gpr/string_windows.h",
         "src/core/lib/gpr/time_precise.h",
-        "src/core/lib/gpr/tls.h",
-        "src/core/lib/gpr/tls_gcc.h",
-        "src/core/lib/gpr/tls_msvc.h",
-        "src/core/lib/gpr/tls_pthread.h",
-        "src/core/lib/gpr/tls_stdcpp.h",
         "src/core/lib/gpr/tmpfile.h",
         "src/core/lib/gpr/useful.h",
         "src/core/lib/gprpp/arena.h",
-        "src/core/lib/gprpp/atomic.h",
         "src/core/lib/gprpp/examine_stack.h",
         "src/core/lib/gprpp/fork.h",
         "src/core/lib/gprpp/global_config.h",
@@ -709,14 +715,36 @@ grpc_cc_library(
     public_hdrs = GPR_PUBLIC_HDRS,
     visibility = ["@grpc:alt_gpr_base_legacy"],
     deps = [
+        "construct_destruct",
         "debug_location",
         "google_api_upb",
         "gpr_codegen",
+        "gpr_tls",
         "grpc_codegen",
     ],
 )
 
 grpc_cc_library(
+    name = "gpr_tls",
+    hdrs = ["src/core/lib/gpr/tls.h"],
+    deps = ["gpr_platform"],
+)
+
+grpc_cc_library(
+    name = "capture",
+    external_deps = ["absl/utility"],
+    language = "c++",
+    public_hdrs = ["src/core/lib/gprpp/capture.h"],
+    deps = ["gpr_platform"],
+)
+
+grpc_cc_library(
+    name = "construct_destruct",
+    language = "c++",
+    public_hdrs = ["src/core/lib/gprpp/construct_destruct.h"],
+)
+
+grpc_cc_library(
     name = "gpr_codegen",
     language = "c++",
     public_hdrs = [
@@ -763,13 +791,17 @@ grpc_cc_library(
 )
 
 grpc_cc_library(
-    name = "atomic",
+    name = "config",
+    srcs = [
+        "src/core/lib/config/core_configuration.cc",
+    ],
     language = "c++",
     public_hdrs = [
-        "src/core/lib/gprpp/atomic.h",
+        "src/core/lib/config/core_configuration.h",
     ],
     deps = [
-        "gpr",
+        "gpr_platform",
+        "handshaker_registry",
     ],
 )
 
@@ -835,11 +867,334 @@ grpc_cc_library(
 )
 
 grpc_cc_library(
+    name = "poll",
+    external_deps = [
+        "absl/types:variant",
+    ],
+    language = "c++",
+    public_hdrs = [
+        "src/core/lib/promise/poll.h",
+    ],
+    deps = ["gpr_platform"],
+)
+
+grpc_cc_library(
+    name = "context",
+    language = "c++",
+    public_hdrs = [
+        "src/core/lib/promise/context.h",
+    ],
+    deps = [
+        "gpr_platform",
+        "gpr_tls",
+    ],
+)
+
+grpc_cc_library(
+    name = "map",
+    language = "c++",
+    public_hdrs = ["src/core/lib/promise/map.h"],
+    deps = [
+        "gpr_platform",
+        "poll",
+        "promise_like",
+    ],
+)
+
+grpc_cc_library(
+    name = "promise",
+    external_deps = [
+        "absl/types:optional",
+    ],
+    language = "c++",
+    public_hdrs = [
+        "src/core/lib/promise/promise.h",
+    ],
+    deps = [
+        "gpr_platform",
+        "poll",
+        "promise_like",
+    ],
+)
+
+grpc_cc_library(
+    name = "promise_like",
+    language = "c++",
+    public_hdrs = [
+        "src/core/lib/promise/detail/promise_like.h",
+    ],
+    deps = [
+        "gpr_platform",
+        "poll",
+    ],
+)
+
+grpc_cc_library(
+    name = "promise_factory",
+    language = "c++",
+    public_hdrs = [
+        "src/core/lib/promise/detail/promise_factory.h",
+    ],
+    deps = [
+        "gpr_platform",
+        "poll",
+        "promise_like",
+    ],
+)
+
+grpc_cc_library(
+    name = "if",
+    external_deps = [
+        "absl/status:statusor",
+    ],
+    language = "c++",
+    public_hdrs = ["src/core/lib/promise/if.h"],
+    deps = [
+        "gpr_platform",
+        "poll",
+        "promise_factory",
+    ],
+)
+
+grpc_cc_library(
+    name = "promise_status",
+    external_deps = [
+        "absl/status",
+        "absl/status:statusor",
+    ],
+    language = "c++",
+    public_hdrs = [
+        "src/core/lib/promise/detail/status.h",
+    ],
+    deps = ["gpr_platform"],
+)
+
+grpc_cc_library(
+    name = "race",
+    language = "c++",
+    public_hdrs = ["src/core/lib/promise/race.h"],
+    deps = [
+        "gpr_platform",
+        "poll",
+    ],
+)
+
+grpc_cc_library(
+    name = "loop",
+    language = "c++",
+    public_hdrs = [
+        "src/core/lib/promise/loop.h",
+    ],
+    deps = [
+        "gpr_platform",
+        "poll",
+        "promise_factory",
+    ],
+)
+
+grpc_cc_library(
+    name = "switch",
+    language = "c++",
+    public_hdrs = [
+        "src/core/lib/promise/detail/switch.h",
+    ],
+    deps = ["gpr_platform"],
+)
+
+grpc_cc_library(
+    name = "basic_join",
+    language = "c++",
+    public_hdrs = [
+        "src/core/lib/promise/detail/basic_join.h",
+    ],
+    deps = [
+        "bitset",
+        "construct_destruct",
+        "gpr_platform",
+        "poll",
+        "promise_factory",
+    ],
+)
+
+grpc_cc_library(
+    name = "join",
+    language = "c++",
+    public_hdrs = [
+        "src/core/lib/promise/join.h",
+    ],
+    deps = [
+        "basic_join",
+        "gpr_platform",
+    ],
+)
+
+grpc_cc_library(
+    name = "try_join",
+    language = "c++",
+    public_hdrs = [
+        "src/core/lib/promise/try_join.h",
+    ],
+    deps = [
+        "basic_join",
+        "gpr_platform",
+        "promise_status",
+    ],
+)
+
+grpc_cc_library(
+    name = "basic_seq",
+    language = "c++",
+    public_hdrs = [
+        "src/core/lib/promise/detail/basic_seq.h",
+    ],
+    deps = [
+        "construct_destruct",
+        "gpr_platform",
+        "poll",
+        "promise_factory",
+        "switch",
+    ],
+)
+
+grpc_cc_library(
+    name = "seq",
+    language = "c++",
+    public_hdrs = [
+        "src/core/lib/promise/seq.h",
+    ],
+    deps = [
+        "basic_seq",
+        "gpr_platform",
+    ],
+)
+
+grpc_cc_library(
+    name = "try_seq",
+    language = "c++",
+    public_hdrs = [
+        "src/core/lib/promise/try_seq.h",
+    ],
+    deps = [
+        "basic_seq",
+        "gpr_platform",
+        "promise_status",
+    ],
+)
+
+grpc_cc_library(
+    name = "activity",
+    srcs = [
+        "src/core/lib/promise/activity.cc",
+    ],
+    language = "c++",
+    public_hdrs = [
+        "src/core/lib/promise/activity.h",
+    ],
+    deps = [
+        "atomic_utils",
+        "construct_destruct",
+        "context",
+        "gpr_base",
+        "gpr_codegen",
+        "poll",
+        "promise_factory",
+        "promise_status",
+    ],
+)
+
+grpc_cc_library(
+    name = "wait_set",
+    external_deps = [
+        "absl/container:flat_hash_set",
+    ],
+    language = "c++",
+    public_hdrs = [
+        "src/core/lib/promise/wait_set.h",
+    ],
+    deps = [
+        "activity",
+        "gpr_platform",
+    ],
+)
+
+grpc_cc_library(
+    name = "intra_activity_waiter",
+    language = "c++",
+    public_hdrs = [
+        "src/core/lib/promise/intra_activity_waiter.h",
+    ],
+    deps = [
+        "activity",
+        "gpr_platform",
+    ],
+)
+
+grpc_cc_library(
+    name = "latch",
+    external_deps = [
+        "absl/status",
+    ],
+    language = "c++",
+    public_hdrs = [
+        "src/core/lib/promise/latch.h",
+    ],
+    deps = [
+        "activity",
+        "gpr_platform",
+        "intra_activity_waiter",
+    ],
+)
+
+grpc_cc_library(
+    name = "observable",
+    language = "c++",
+    public_hdrs = [
+        "src/core/lib/promise/observable.h",
+    ],
+    deps = [
+        "activity",
+        "gpr_platform",
+        "wait_set",
+    ],
+)
+
+grpc_cc_library(
+    name = "pipe",
+    external_deps = [
+        "absl/status",
+    ],
+    language = "c++",
+    public_hdrs = [
+        "src/core/lib/promise/pipe.h",
+    ],
+    deps = [
+        "activity",
+        "gpr_platform",
+        "intra_activity_waiter",
+    ],
+)
+
+grpc_cc_library(
+    name = "for_each",
+    external_deps = [
+        "absl/status",
+        "absl/types:variant",
+    ],
+    language = "c++",
+    public_hdrs = ["src/core/lib/promise/for_each.h"],
+    deps = [
+        "gpr_platform",
+        "poll",
+        "promise_factory",
+    ],
+)
+
+grpc_cc_library(
     name = "ref_counted",
     language = "c++",
     public_hdrs = ["src/core/lib/gprpp/ref_counted.h"],
     deps = [
-        "atomic",
+        "atomic_utils",
         "debug_location",
         "gpr_base",
         "grpc_trace",
@@ -852,7 +1207,6 @@ grpc_cc_library(
     language = "c++",
     public_hdrs = ["src/core/lib/gprpp/dual_ref_counted.h"],
     deps = [
-        "atomic",
         "debug_location",
         "gpr_base",
         "grpc_trace",
@@ -872,6 +1226,32 @@ grpc_cc_library(
 )
 
 grpc_cc_library(
+    name = "handshaker_factory",
+    language = "c++",
+    public_hdrs = [
+        "src/core/lib/channel/handshaker_factory.h",
+    ],
+    deps = [
+        "gpr_base",
+    ],
+)
+
+grpc_cc_library(
+    name = "handshaker_registry",
+    srcs = [
+        "src/core/lib/channel/handshaker_registry.cc",
+    ],
+    language = "c++",
+    public_hdrs = [
+        "src/core/lib/channel/handshaker_registry.h",
+    ],
+    deps = [
+        "gpr_base",
+        "handshaker_factory",
+    ],
+)
+
+grpc_cc_library(
     name = "grpc_base_c",
     srcs = [
         "src/core/lib/address_utils/parse_address.cc",
@@ -886,7 +1266,6 @@ grpc_cc_library(
         "src/core/lib/channel/channelz_registry.cc",
         "src/core/lib/channel/connected_channel.cc",
         "src/core/lib/channel/handshaker.cc",
-        "src/core/lib/channel/handshaker_registry.cc",
         "src/core/lib/channel/status_util.cc",
         "src/core/lib/compression/compression.cc",
         "src/core/lib/compression/compression_args.cc",
@@ -912,7 +1291,6 @@ grpc_cc_library(
         "src/core/lib/iomgr/endpoint_cfstream.cc",
         "src/core/lib/iomgr/endpoint_pair_event_engine.cc",
         "src/core/lib/iomgr/endpoint_pair_posix.cc",
-        "src/core/lib/iomgr/endpoint_pair_uv.cc",
         "src/core/lib/iomgr/endpoint_pair_windows.cc",
         "src/core/lib/iomgr/error.cc",
         "src/core/lib/iomgr/error_cfstream.cc",
@@ -948,7 +1326,6 @@ grpc_cc_library(
         "src/core/lib/iomgr/iomgr_internal.cc",
         "src/core/lib/iomgr/iomgr_posix.cc",
         "src/core/lib/iomgr/iomgr_posix_cfstream.cc",
-        "src/core/lib/iomgr/iomgr_uv.cc",
         "src/core/lib/iomgr/iomgr_windows.cc",
         "src/core/lib/iomgr/is_epollexclusive_available.cc",
         "src/core/lib/iomgr/load_file.cc",
@@ -959,7 +1336,6 @@ grpc_cc_library(
         "src/core/lib/iomgr/pollset_set.cc",
         "src/core/lib/iomgr/pollset_set_custom.cc",
         "src/core/lib/iomgr/pollset_set_windows.cc",
-        "src/core/lib/iomgr/pollset_uv.cc",
         "src/core/lib/iomgr/pollset_windows.cc",
         "src/core/lib/iomgr/resolve_address.cc",
         "src/core/lib/iomgr/resolve_address_custom.cc",
@@ -971,7 +1347,6 @@ grpc_cc_library(
         "src/core/lib/iomgr/socket_utils_common_posix.cc",
         "src/core/lib/iomgr/socket_utils_linux.cc",
         "src/core/lib/iomgr/socket_utils_posix.cc",
-        "src/core/lib/iomgr/socket_utils_uv.cc",
         "src/core/lib/iomgr/socket_utils_windows.cc",
         "src/core/lib/iomgr/socket_windows.cc",
         "src/core/lib/iomgr/tcp_client.cc",
@@ -988,7 +1363,6 @@ grpc_cc_library(
         "src/core/lib/iomgr/tcp_server_utils_posix_ifaddrs.cc",
         "src/core/lib/iomgr/tcp_server_utils_posix_noifaddrs.cc",
         "src/core/lib/iomgr/tcp_server_windows.cc",
-        "src/core/lib/iomgr/tcp_uv.cc",
         "src/core/lib/iomgr/tcp_windows.cc",
         "src/core/lib/iomgr/time_averaged_stats.cc",
         "src/core/lib/iomgr/timer.cc",
@@ -996,7 +1370,6 @@ grpc_cc_library(
         "src/core/lib/iomgr/timer_generic.cc",
         "src/core/lib/iomgr/timer_heap.cc",
         "src/core/lib/iomgr/timer_manager.cc",
-        "src/core/lib/iomgr/timer_uv.cc",
         "src/core/lib/iomgr/udp_server.cc",
         "src/core/lib/iomgr/unix_sockets_posix.cc",
         "src/core/lib/iomgr/unix_sockets_posix_noop.cc",
@@ -1062,8 +1435,6 @@ grpc_cc_library(
         "src/core/lib/channel/connected_channel.h",
         "src/core/lib/channel/context.h",
         "src/core/lib/channel/handshaker.h",
-        "src/core/lib/channel/handshaker_factory.h",
-        "src/core/lib/channel/handshaker_registry.h",
         "src/core/lib/channel/status_util.h",
         "src/core/lib/compression/algorithm_metadata.h",
         "src/core/lib/compression/compression_args.h",
@@ -1124,7 +1495,6 @@ grpc_cc_library(
         "src/core/lib/iomgr/pollset_set.h",
         "src/core/lib/iomgr/pollset_set_custom.h",
         "src/core/lib/iomgr/pollset_set_windows.h",
-        "src/core/lib/iomgr/pollset_uv.h",
         "src/core/lib/iomgr/pollset_windows.h",
         "src/core/lib/iomgr/port.h",
         "src/core/lib/iomgr/python_util.h",
@@ -1132,7 +1502,6 @@ grpc_cc_library(
         "src/core/lib/iomgr/resolve_address_custom.h",
         "src/core/lib/iomgr/resource_quota.h",
         "src/core/lib/iomgr/sockaddr.h",
-        "src/core/lib/iomgr/sockaddr_custom.h",
         "src/core/lib/iomgr/sockaddr_posix.h",
         "src/core/lib/iomgr/sockaddr_windows.h",
         "src/core/lib/iomgr/socket_factory_posix.h",
@@ -1212,9 +1581,11 @@ grpc_cc_library(
     public_hdrs = GRPC_PUBLIC_HDRS + GRPC_PUBLIC_EVENT_ENGINE_HDRS,
     visibility = ["@grpc:alt_grpc_base_legacy"],
     deps = [
+        "bitset",
         "dual_ref_counted",
         "gpr_base",
         "gpr_codegen",
+        "gpr_tls",
         "grpc_codegen",
         "grpc_trace",
         "orphanable",
@@ -1231,7 +1602,6 @@ grpc_cc_library(
     language = "c++",
     visibility = ["@grpc:alt_grpc_base_legacy"],
     deps = [
-        "atomic",
         "gpr_base",
         "grpc_base_c",
     ],
@@ -1347,6 +1717,7 @@ grpc_cc_library(
     language = "c++",
     visibility = ["@grpc:client_channel"],
     deps = [
+        "config",
         "debug_location",
         "gpr_base",
         "grpc_base_c",
@@ -1354,6 +1725,7 @@ grpc_cc_library(
         "grpc_deadline_filter",
         "grpc_health_upb",
         "grpc_trace",
+        "handshaker_registry",
         "orphanable",
         "ref_counted",
         "ref_counted_ptr",
@@ -2120,12 +2492,10 @@ grpc_cc_library(
     srcs = [
         "src/core/ext/filters/client_channel/resolver/dns/c_ares/dns_resolver_ares.cc",
         "src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_event_engine.cc",
-        "src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_libuv.cc",
         "src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_posix.cc",
         "src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_windows.cc",
         "src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper.cc",
         "src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_event_engine.cc",
-        "src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_libuv.cc",
         "src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_posix.cc",
         "src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_windows.cc",
     ],
@@ -2231,6 +2601,7 @@ grpc_cc_library(
         "src/core/lib/http/httpcli_security_connector.cc",
         "src/core/lib/security/authorization/authorization_policy_provider_vtable.cc",
         "src/core/lib/security/authorization/evaluate_args.cc",
+        "src/core/lib/security/authorization/sdk_server_authz_filter.cc",
         "src/core/lib/security/context/security_context.cc",
         "src/core/lib/security/credentials/alts/alts_credentials.cc",
         "src/core/lib/security/credentials/composite/composite_credentials.cc",
@@ -2283,6 +2654,7 @@ grpc_cc_library(
         "src/core/lib/security/authorization/authorization_engine.h",
         "src/core/lib/security/authorization/authorization_policy_provider.h",
         "src/core/lib/security/authorization/evaluate_args.h",
+        "src/core/lib/security/authorization/sdk_server_authz_filter.h",
         "src/core/lib/security/context/security_context.h",
         "src/core/lib/security/credentials/alts/alts_credentials.h",
         "src/core/lib/security/credentials/composite/composite_credentials.h",
@@ -2337,6 +2709,7 @@ grpc_cc_library(
     visibility = ["@grpc:public"],
     deps = [
         "alts_util",
+        "config",
         "gpr_base",
         "grpc_base",
         "grpc_base_c",
@@ -2485,6 +2858,60 @@ grpc_cc_library(
 )
 
 grpc_cc_library(
+    name = "popularity_count",
+    hdrs = [
+        "src/core/ext/transport/chttp2/transport/popularity_count.h",
+    ],
+    language = "c++",
+    deps = [
+        "gpr_platform",
+    ],
+)
+
+grpc_cc_library(
+    name = "hpack_constants",
+    hdrs = [
+        "src/core/ext/transport/chttp2/transport/hpack_constants.h",
+    ],
+    language = "c++",
+    deps = [
+        "gpr_platform",
+    ],
+)
+
+grpc_cc_library(
+    name = "hpack_encoder_index",
+    hdrs = [
+        "src/core/ext/transport/chttp2/transport/hpack_encoder_index.h",
+    ],
+    external_deps = [
+        "absl/types:optional",
+    ],
+    language = "c++",
+    deps = [
+        "gpr_platform",
+    ],
+)
+
+grpc_cc_library(
+    name = "hpack_encoder_table",
+    srcs = [
+        "src/core/ext/transport/chttp2/transport/hpack_encoder_table.cc",
+    ],
+    hdrs = [
+        "src/core/ext/transport/chttp2/transport/hpack_encoder_table.h",
+    ],
+    external_deps = [
+        "absl/container:inlined_vector",
+    ],
+    language = "c++",
+    deps = [
+        "gpr",
+        "hpack_constants",
+    ],
+)
+
+grpc_cc_library(
     name = "grpc_transport_chttp2",
     srcs = [
         "src/core/ext/transport/chttp2/transport/bin_decoder.cc",
@@ -2502,7 +2929,8 @@ grpc_cc_library(
         "src/core/ext/transport/chttp2/transport/frame_window_update.cc",
         "src/core/ext/transport/chttp2/transport/hpack_encoder.cc",
         "src/core/ext/transport/chttp2/transport/hpack_parser.cc",
-        "src/core/ext/transport/chttp2/transport/hpack_table.cc",
+        "src/core/ext/transport/chttp2/transport/hpack_parser_table.cc",
+        "src/core/ext/transport/chttp2/transport/hpack_utils.cc",
         "src/core/ext/transport/chttp2/transport/http2_settings.cc",
         "src/core/ext/transport/chttp2/transport/huffsyms.cc",
         "src/core/ext/transport/chttp2/transport/incoming_metadata.cc",
@@ -2528,7 +2956,8 @@ grpc_cc_library(
         "src/core/ext/transport/chttp2/transport/frame_window_update.h",
         "src/core/ext/transport/chttp2/transport/hpack_encoder.h",
         "src/core/ext/transport/chttp2/transport/hpack_parser.h",
-        "src/core/ext/transport/chttp2/transport/hpack_table.h",
+        "src/core/ext/transport/chttp2/transport/hpack_parser_table.h",
+        "src/core/ext/transport/chttp2/transport/hpack_utils.h",
         "src/core/ext/transport/chttp2/transport/http2_settings.h",
         "src/core/ext/transport/chttp2/transport/huffsyms.h",
         "src/core/ext/transport/chttp2/transport/incoming_metadata.h",
@@ -2551,6 +2980,11 @@ grpc_cc_library(
         "grpc_http_filters",
         "grpc_trace",
         "grpc_transport_chttp2_alpn",
+        "hpack_constants",
+        "hpack_encoder_index",
+        "hpack_encoder_table",
+        "match",
+        "popularity_count",
     ],
 )
 
@@ -2580,6 +3014,7 @@ grpc_cc_library(
     ],
     language = "c++",
     deps = [
+        "config",
         "gpr_base",
         "grpc_base_c",
         "grpc_client_channel",
@@ -2633,6 +3068,7 @@ grpc_cc_library(
     ],
     language = "c++",
     deps = [
+        "config",
         "gpr_base",
         "grpc_base_c",
         "grpc_codegen",
@@ -2878,6 +3314,7 @@ grpc_cc_library(
     ],
     language = "c++",
     public_hdrs = GRPCXX_PUBLIC_HDRS,
+    tags = ["avoid_dep"],
     visibility = ["@grpc:alt_grpc++_base_unsecure_legacy"],
     deps = [
         "gpr_base",
@@ -3060,6 +3497,7 @@ grpc_cc_library(
     public_hdrs = [
         "include/grpcpp/ext/channelz_service_plugin.h",
     ],
+    visibility = ["@grpc:channelz"],
     deps = [
         "gpr",
         "grpc",
@@ -3120,6 +3558,7 @@ grpc_cc_library(
 
 grpc_cc_library(
     name = "grpc++_test",
+    testonly = True,
     srcs = [
         "src/cpp/client/channel_test_peer.cc",
     ],
index e00b434..0e8fbde 100644 (file)
 cmake_minimum_required(VERSION 3.5.1)
 
 set(PACKAGE_NAME          "grpc")
-set(PACKAGE_VERSION       "1.40.0")
-set(gRPC_CORE_VERSION     "18.0.0")
-set(gRPC_CORE_SOVERSION   "18")
-set(gRPC_CPP_VERSION      "1.40.0")
-set(gRPC_CPP_SOVERSION    "1.40")
-set(gRPC_CSHARP_VERSION   "2.40.0")
-set(gRPC_CSHARP_SOVERSION "2.40")
+set(PACKAGE_VERSION       "1.41.0")
+set(gRPC_CORE_VERSION     "19.0.0")
+set(gRPC_CORE_SOVERSION   "19")
+set(gRPC_CPP_VERSION      "1.41.0")
+set(gRPC_CPP_SOVERSION    "1.41")
+set(gRPC_CSHARP_VERSION   "2.41.0")
+set(gRPC_CSHARP_SOVERSION "2.41")
 set(PACKAGE_STRING        "${PACKAGE_NAME} ${PACKAGE_VERSION}")
 set(PACKAGE_TARNAME       "${PACKAGE_NAME}-${PACKAGE_VERSION}")
 set(PACKAGE_BUGREPORT     "https://github.com/grpc/grpc/issues/")
@@ -251,7 +251,7 @@ endif()
 if (gRPC_XDS_USER_AGENT_IS_CSHARP)
   # The value of the defines needs to contain quotes.
   # See https://github.com/grpc/grpc/blob/fbf32836a418cc84f58786700273b65cb9174e1d/src/core/ext/xds/xds_api.cc#L854
-  add_definitions("-DGRPC_XDS_USER_AGENT_NAME_SUFFIX=\"csharp\"" "-DGRPC_XDS_USER_AGENT_VERSION_SUFFIX=\"2.40.0\"")
+  add_definitions("-DGRPC_XDS_USER_AGENT_NAME_SUFFIX=\"csharp\"" "-DGRPC_XDS_USER_AGENT_VERSION_SUFFIX=\"2.41.0\"")
 endif()
 
 include(cmake/abseil-cpp.cmake)
@@ -377,8 +377,6 @@ add_custom_target(tools_c
 add_custom_target(tools_cxx
   DEPENDS
   gen_hpack_tables
-  gen_legal_metadata_characters
-  gen_percent_encoding_tables
 )
 
 add_custom_target(tools
@@ -490,6 +488,9 @@ protobuf_generate_grpc_cpp(
   src/proto/grpc/testing/xds/v3/endpoint.proto
 )
 protobuf_generate_grpc_cpp(
+  src/proto/grpc/testing/xds/v3/extension.proto
+)
+protobuf_generate_grpc_cpp(
   src/proto/grpc/testing/xds/v3/fault.proto
 )
 protobuf_generate_grpc_cpp(
@@ -532,6 +533,9 @@ protobuf_generate_grpc_cpp(
   src/proto/grpc/testing/xds/v3/tls.proto
 )
 protobuf_generate_grpc_cpp(
+  test/core/transport/binder/end2end/echo.proto
+)
+protobuf_generate_grpc_cpp(
   test/core/tsi/alts/fake_handshaker/handshaker.proto
 )
 protobuf_generate_grpc_cpp(
@@ -629,8 +633,8 @@ if(gRPC_BUILD_TESTS)
   add_dependencies(buildtests_c histogram_test)
   add_dependencies(buildtests_c host_port_test)
   add_dependencies(buildtests_c hpack_encoder_test)
+  add_dependencies(buildtests_c hpack_parser_table_test)
   add_dependencies(buildtests_c hpack_parser_test)
-  add_dependencies(buildtests_c hpack_table_test)
   if(_gRPC_PLATFORM_LINUX OR _gRPC_PLATFORM_MAC OR _gRPC_PLATFORM_POSIX)
     add_dependencies(buildtests_c httpcli_test)
   endif()
@@ -714,7 +718,6 @@ if(gRPC_BUILD_TESTS)
   add_dependencies(buildtests_c timeout_encoding_test)
   add_dependencies(buildtests_c timer_heap_test)
   add_dependencies(buildtests_c timer_list_test)
-  add_dependencies(buildtests_c tls_test)
   add_dependencies(buildtests_c transport_security_common_api_test)
   add_dependencies(buildtests_c transport_security_test)
   if(_gRPC_PLATFORM_LINUX OR _gRPC_PLATFORM_MAC OR _gRPC_PLATFORM_POSIX)
@@ -724,6 +727,7 @@ if(gRPC_BUILD_TESTS)
   add_dependencies(buildtests_c varint_test)
 
   add_custom_target(buildtests_cxx)
+  add_dependencies(buildtests_cxx activity_test)
   if(_gRPC_PLATFORM_LINUX OR _gRPC_PLATFORM_MAC OR _gRPC_PLATFORM_POSIX)
     add_dependencies(buildtests_cxx address_sorting_test)
   endif()
@@ -749,7 +753,8 @@ if(gRPC_BUILD_TESTS)
   if(_gRPC_PLATFORM_LINUX OR _gRPC_PLATFORM_MAC OR _gRPC_PLATFORM_POSIX)
     add_dependencies(buildtests_cxx bdp_estimator_test)
   endif()
-  add_dependencies(buildtests_cxx binder_smoke_test)
+  add_dependencies(buildtests_cxx binder_server_test)
+  add_dependencies(buildtests_cxx binder_transport_test)
   add_dependencies(buildtests_cxx bitset_test)
   if(_gRPC_PLATFORM_LINUX OR _gRPC_PLATFORM_POSIX)
     add_dependencies(buildtests_cxx bm_alarm)
@@ -817,6 +822,7 @@ if(gRPC_BUILD_TESTS)
   add_dependencies(buildtests_cxx byte_buffer_test)
   add_dependencies(buildtests_cxx byte_stream_test)
   add_dependencies(buildtests_cxx cancel_ares_query_test)
+  add_dependencies(buildtests_cxx capture_test)
   add_dependencies(buildtests_cxx cel_authorization_engine_test)
   add_dependencies(buildtests_cxx certificate_provider_registry_test)
   add_dependencies(buildtests_cxx certificate_provider_store_test)
@@ -843,10 +849,13 @@ if(gRPC_BUILD_TESTS)
   add_dependencies(buildtests_cxx connectivity_state_test)
   add_dependencies(buildtests_cxx context_allocator_end2end_test)
   add_dependencies(buildtests_cxx context_list_test)
+  add_dependencies(buildtests_cxx context_test)
+  add_dependencies(buildtests_cxx core_configuration_test)
   add_dependencies(buildtests_cxx delegating_channel_test)
   add_dependencies(buildtests_cxx destroy_grpclb_channel_with_active_connect_stress_test)
   add_dependencies(buildtests_cxx dual_ref_counted_test)
   add_dependencies(buildtests_cxx duplicate_header_bad_client_test)
+  add_dependencies(buildtests_cxx end2end_binder_transport_test)
   add_dependencies(buildtests_cxx end2end_test)
   add_dependencies(buildtests_cxx endpoint_config_test)
   add_dependencies(buildtests_cxx error_details_test)
@@ -856,9 +865,12 @@ if(gRPC_BUILD_TESTS)
     add_dependencies(buildtests_cxx examine_stack_test)
   endif()
   add_dependencies(buildtests_cxx exception_test)
+  add_dependencies(buildtests_cxx fake_binder_test)
   add_dependencies(buildtests_cxx file_watcher_certificate_provider_factory_test)
   add_dependencies(buildtests_cxx filter_end2end_test)
   add_dependencies(buildtests_cxx flaky_network_test)
+  add_dependencies(buildtests_cxx flow_control_test)
+  add_dependencies(buildtests_cxx for_each_test)
   add_dependencies(buildtests_cxx generic_end2end_test)
   if(_gRPC_PLATFORM_LINUX OR _gRPC_PLATFORM_MAC OR _gRPC_PLATFORM_POSIX)
     add_dependencies(buildtests_cxx global_config_env_test)
@@ -882,8 +894,10 @@ if(gRPC_BUILD_TESTS)
   add_dependencies(buildtests_cxx head_of_line_blocking_bad_client_test)
   add_dependencies(buildtests_cxx headers_bad_client_test)
   add_dependencies(buildtests_cxx health_service_end2end_test)
+  add_dependencies(buildtests_cxx hpack_encoder_index_test)
   add_dependencies(buildtests_cxx http2_client)
   add_dependencies(buildtests_cxx hybrid_end2end_test)
+  add_dependencies(buildtests_cxx if_test)
   add_dependencies(buildtests_cxx init_test)
   add_dependencies(buildtests_cxx initial_settings_frame_bad_client_test)
   add_dependencies(buildtests_cxx insecure_security_connector_test)
@@ -892,28 +906,40 @@ if(gRPC_BUILD_TESTS)
   if(_gRPC_PLATFORM_LINUX OR _gRPC_PLATFORM_MAC OR _gRPC_PLATFORM_POSIX)
     add_dependencies(buildtests_cxx interop_test)
   endif()
+  add_dependencies(buildtests_cxx join_test)
   add_dependencies(buildtests_cxx json_test)
   add_dependencies(buildtests_cxx large_metadata_bad_client_test)
+  add_dependencies(buildtests_cxx latch_test)
   add_dependencies(buildtests_cxx lb_get_cpu_stats_test)
   add_dependencies(buildtests_cxx lb_load_data_store_test)
   add_dependencies(buildtests_cxx linux_system_roots_test)
   add_dependencies(buildtests_cxx log_test)
+  add_dependencies(buildtests_cxx loop_test)
   add_dependencies(buildtests_cxx match_test)
   add_dependencies(buildtests_cxx matchers_test)
   add_dependencies(buildtests_cxx message_allocator_end2end_test)
+  add_dependencies(buildtests_cxx miscompile_with_no_unique_address_test)
   add_dependencies(buildtests_cxx mock_stream_test)
   add_dependencies(buildtests_cxx mock_test)
   add_dependencies(buildtests_cxx nonblocking_test)
   add_dependencies(buildtests_cxx noop-benchmark)
+  add_dependencies(buildtests_cxx observable_test)
   add_dependencies(buildtests_cxx orphanable_test)
   add_dependencies(buildtests_cxx out_of_bounds_bad_client_test)
   add_dependencies(buildtests_cxx overload_test)
   add_dependencies(buildtests_cxx pid_controller_test)
+  add_dependencies(buildtests_cxx pipe_test)
+  add_dependencies(buildtests_cxx poll_test)
+  add_dependencies(buildtests_cxx popularity_count_test)
   add_dependencies(buildtests_cxx port_sharing_end2end_test)
+  add_dependencies(buildtests_cxx promise_factory_test)
+  add_dependencies(buildtests_cxx promise_map_test)
+  add_dependencies(buildtests_cxx promise_test)
   add_dependencies(buildtests_cxx proto_server_reflection_test)
   add_dependencies(buildtests_cxx proto_utils_test)
   add_dependencies(buildtests_cxx qps_json_driver)
   add_dependencies(buildtests_cxx qps_worker)
+  add_dependencies(buildtests_cxx race_test)
   add_dependencies(buildtests_cxx raw_end2end_test)
   add_dependencies(buildtests_cxx rbac_translator_test)
   add_dependencies(buildtests_cxx ref_counted_ptr_test)
@@ -922,7 +948,9 @@ if(gRPC_BUILD_TESTS)
     add_dependencies(buildtests_cxx remove_stream_from_stalled_lists_test)
   endif()
   add_dependencies(buildtests_cxx retry_throttle_test)
+  add_dependencies(buildtests_cxx sdk_authz_end2end_test)
   add_dependencies(buildtests_cxx secure_auth_context_test)
+  add_dependencies(buildtests_cxx seq_test)
   add_dependencies(buildtests_cxx server_builder_plugin_test)
   if(_gRPC_PLATFORM_LINUX OR _gRPC_PLATFORM_MAC OR _gRPC_PLATFORM_POSIX)
     add_dependencies(buildtests_cxx server_builder_test)
@@ -975,10 +1003,16 @@ if(gRPC_BUILD_TESTS)
   add_dependencies(buildtests_cxx time_util_test)
   add_dependencies(buildtests_cxx timer_test)
   add_dependencies(buildtests_cxx tls_security_connector_test)
+  add_dependencies(buildtests_cxx tls_test)
   add_dependencies(buildtests_cxx too_many_pings_test)
+  add_dependencies(buildtests_cxx transport_stream_receiver_test)
+  add_dependencies(buildtests_cxx try_join_test)
+  add_dependencies(buildtests_cxx try_seq_test)
   add_dependencies(buildtests_cxx unknown_frame_bad_client_test)
   add_dependencies(buildtests_cxx uri_parser_test)
   add_dependencies(buildtests_cxx window_overflow_bad_client_test)
+  add_dependencies(buildtests_cxx wire_reader_test)
+  add_dependencies(buildtests_cxx wire_writer_test)
   if(_gRPC_PLATFORM_LINUX OR _gRPC_PLATFORM_MAC OR _gRPC_PLATFORM_POSIX)
     add_dependencies(buildtests_cxx work_serializer_test)
   endif()
@@ -1207,6 +1241,11 @@ endif()
 if(gRPC_BUILD_TESTS)
 
 add_library(end2end_tests
+  src/core/lib/security/authorization/grpc_authorization_engine.cc
+  src/core/lib/security/authorization/grpc_authorization_policy_provider.cc
+  src/core/lib/security/authorization/matchers.cc
+  src/core/lib/security/authorization/rbac_policy.cc
+  src/core/lib/security/authorization/rbac_translator.cc
   test/core/end2end/cq_verifier.cc
   test/core/end2end/data/client_certs.cc
   test/core/end2end/data/server1_cert.cc
@@ -1291,6 +1330,7 @@ add_library(end2end_tests
   test/core/end2end/tests/retry_streaming_succeeds_before_replay_finished.cc
   test/core/end2end/tests/retry_throttled.cc
   test/core/end2end/tests/retry_too_many_attempts.cc
+  test/core/end2end/tests/sdk_authz.cc
   test/core/end2end/tests/server_finishes_request.cc
   test/core/end2end/tests/server_streaming.cc
   test/core/end2end/tests/shutdown_finishes_calls.cc
@@ -1386,7 +1426,6 @@ add_library(gpr
   src/core/lib/gpr/time_posix.cc
   src/core/lib/gpr/time_precise.cc
   src/core/lib/gpr/time_windows.cc
-  src/core/lib/gpr/tls_pthread.cc
   src/core/lib/gpr/tmpfile_msys.cc
   src/core/lib/gpr/tmpfile_posix.cc
   src/core/lib/gpr/tmpfile_windows.cc
@@ -1556,12 +1595,10 @@ add_library(grpc
   src/core/ext/filters/client_channel/resolver.cc
   src/core/ext/filters/client_channel/resolver/dns/c_ares/dns_resolver_ares.cc
   src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_event_engine.cc
-  src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_libuv.cc
   src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_posix.cc
   src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_windows.cc
   src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper.cc
   src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_event_engine.cc
-  src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_libuv.cc
   src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_posix.cc
   src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_windows.cc
   src/core/ext/filters/client_channel/resolver/dns/dns_resolver_selection.cc
@@ -1619,8 +1656,10 @@ add_library(grpc
   src/core/ext/transport/chttp2/transport/frame_settings.cc
   src/core/ext/transport/chttp2/transport/frame_window_update.cc
   src/core/ext/transport/chttp2/transport/hpack_encoder.cc
+  src/core/ext/transport/chttp2/transport/hpack_encoder_table.cc
   src/core/ext/transport/chttp2/transport/hpack_parser.cc
-  src/core/ext/transport/chttp2/transport/hpack_table.cc
+  src/core/ext/transport/chttp2/transport/hpack_parser_table.cc
+  src/core/ext/transport/chttp2/transport/hpack_utils.cc
   src/core/ext/transport/chttp2/transport/http2_settings.cc
   src/core/ext/transport/chttp2/transport/huffsyms.cc
   src/core/ext/transport/chttp2/transport/incoming_metadata.cc
@@ -1847,6 +1886,7 @@ add_library(grpc
   src/core/lib/compression/stream_compression.cc
   src/core/lib/compression/stream_compression_gzip.cc
   src/core/lib/compression/stream_compression_identity.cc
+  src/core/lib/config/core_configuration.cc
   src/core/lib/debug/stats.cc
   src/core/lib/debug/stats_data.cc
   src/core/lib/debug/trace.cc
@@ -1866,7 +1906,6 @@ add_library(grpc
   src/core/lib/iomgr/endpoint_cfstream.cc
   src/core/lib/iomgr/endpoint_pair_event_engine.cc
   src/core/lib/iomgr/endpoint_pair_posix.cc
-  src/core/lib/iomgr/endpoint_pair_uv.cc
   src/core/lib/iomgr/endpoint_pair_windows.cc
   src/core/lib/iomgr/error.cc
   src/core/lib/iomgr/error_cfstream.cc
@@ -1902,7 +1941,6 @@ add_library(grpc
   src/core/lib/iomgr/iomgr_internal.cc
   src/core/lib/iomgr/iomgr_posix.cc
   src/core/lib/iomgr/iomgr_posix_cfstream.cc
-  src/core/lib/iomgr/iomgr_uv.cc
   src/core/lib/iomgr/iomgr_windows.cc
   src/core/lib/iomgr/is_epollexclusive_available.cc
   src/core/lib/iomgr/load_file.cc
@@ -1913,7 +1951,6 @@ add_library(grpc
   src/core/lib/iomgr/pollset_set.cc
   src/core/lib/iomgr/pollset_set_custom.cc
   src/core/lib/iomgr/pollset_set_windows.cc
-  src/core/lib/iomgr/pollset_uv.cc
   src/core/lib/iomgr/pollset_windows.cc
   src/core/lib/iomgr/resolve_address.cc
   src/core/lib/iomgr/resolve_address_custom.cc
@@ -1925,7 +1962,6 @@ add_library(grpc
   src/core/lib/iomgr/socket_utils_common_posix.cc
   src/core/lib/iomgr/socket_utils_linux.cc
   src/core/lib/iomgr/socket_utils_posix.cc
-  src/core/lib/iomgr/socket_utils_uv.cc
   src/core/lib/iomgr/socket_utils_windows.cc
   src/core/lib/iomgr/socket_windows.cc
   src/core/lib/iomgr/tcp_client.cc
@@ -1942,7 +1978,6 @@ add_library(grpc
   src/core/lib/iomgr/tcp_server_utils_posix_ifaddrs.cc
   src/core/lib/iomgr/tcp_server_utils_posix_noifaddrs.cc
   src/core/lib/iomgr/tcp_server_windows.cc
-  src/core/lib/iomgr/tcp_uv.cc
   src/core/lib/iomgr/tcp_windows.cc
   src/core/lib/iomgr/time_averaged_stats.cc
   src/core/lib/iomgr/timer.cc
@@ -1950,7 +1985,6 @@ add_library(grpc
   src/core/lib/iomgr/timer_generic.cc
   src/core/lib/iomgr/timer_heap.cc
   src/core/lib/iomgr/timer_manager.cc
-  src/core/lib/iomgr/timer_uv.cc
   src/core/lib/iomgr/udp_server.cc
   src/core/lib/iomgr/unix_sockets_posix.cc
   src/core/lib/iomgr/unix_sockets_posix_noop.cc
@@ -1965,6 +1999,7 @@ add_library(grpc
   src/core/lib/matchers/matchers.cc
   src/core/lib/security/authorization/authorization_policy_provider_vtable.cc
   src/core/lib/security/authorization/evaluate_args.cc
+  src/core/lib/security/authorization/sdk_server_authz_filter.cc
   src/core/lib/security/context/security_context.cc
   src/core/lib/security/credentials/alts/alts_credentials.cc
   src/core/lib/security/credentials/alts/check_gcp_environment.cc
@@ -2129,6 +2164,7 @@ target_link_libraries(grpc
   absl::inlined_vector
   absl::bind_front
   absl::statusor
+  absl::variant
   gpr
   ${_gRPC_SSL_LIBRARIES}
   address_sorting
@@ -2231,6 +2267,7 @@ add_library(grpc_test_util
   test/core/util/port_server_client.cc
   test/core/util/reconnect_server.cc
   test/core/util/resolve_localhost_ip46.cc
+  test/core/util/resource_user_util.cc
   test/core/util/slice_splitter.cc
   test/core/util/stack_tracer.cc
   test/core/util/subprocess_posix.cc
@@ -2300,6 +2337,7 @@ add_library(grpc_test_util_unsecure
   test/core/util/port_server_client.cc
   test/core/util/reconnect_server.cc
   test/core/util/resolve_localhost_ip46.cc
+  test/core/util/resource_user_util.cc
   test/core/util/slice_splitter.cc
   test/core/util/stack_tracer.cc
   test/core/util/subprocess_posix.cc
@@ -2388,12 +2426,10 @@ add_library(grpc_unsecure
   src/core/ext/filters/client_channel/resolver.cc
   src/core/ext/filters/client_channel/resolver/dns/c_ares/dns_resolver_ares.cc
   src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_event_engine.cc
-  src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_libuv.cc
   src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_posix.cc
   src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_windows.cc
   src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper.cc
   src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_event_engine.cc
-  src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_libuv.cc
   src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_posix.cc
   src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_windows.cc
   src/core/ext/filters/client_channel/resolver/dns/dns_resolver_selection.cc
@@ -2447,8 +2483,10 @@ add_library(grpc_unsecure
   src/core/ext/transport/chttp2/transport/frame_settings.cc
   src/core/ext/transport/chttp2/transport/frame_window_update.cc
   src/core/ext/transport/chttp2/transport/hpack_encoder.cc
+  src/core/ext/transport/chttp2/transport/hpack_encoder_table.cc
   src/core/ext/transport/chttp2/transport/hpack_parser.cc
-  src/core/ext/transport/chttp2/transport/hpack_table.cc
+  src/core/ext/transport/chttp2/transport/hpack_parser_table.cc
+  src/core/ext/transport/chttp2/transport/hpack_utils.cc
   src/core/ext/transport/chttp2/transport/http2_settings.cc
   src/core/ext/transport/chttp2/transport/huffsyms.cc
   src/core/ext/transport/chttp2/transport/incoming_metadata.cc
@@ -2484,6 +2522,7 @@ add_library(grpc_unsecure
   src/core/lib/compression/stream_compression.cc
   src/core/lib/compression/stream_compression_gzip.cc
   src/core/lib/compression/stream_compression_identity.cc
+  src/core/lib/config/core_configuration.cc
   src/core/lib/debug/stats.cc
   src/core/lib/debug/stats_data.cc
   src/core/lib/debug/trace.cc
@@ -2502,7 +2541,6 @@ add_library(grpc_unsecure
   src/core/lib/iomgr/endpoint_cfstream.cc
   src/core/lib/iomgr/endpoint_pair_event_engine.cc
   src/core/lib/iomgr/endpoint_pair_posix.cc
-  src/core/lib/iomgr/endpoint_pair_uv.cc
   src/core/lib/iomgr/endpoint_pair_windows.cc
   src/core/lib/iomgr/error.cc
   src/core/lib/iomgr/error_cfstream.cc
@@ -2538,7 +2576,6 @@ add_library(grpc_unsecure
   src/core/lib/iomgr/iomgr_internal.cc
   src/core/lib/iomgr/iomgr_posix.cc
   src/core/lib/iomgr/iomgr_posix_cfstream.cc
-  src/core/lib/iomgr/iomgr_uv.cc
   src/core/lib/iomgr/iomgr_windows.cc
   src/core/lib/iomgr/is_epollexclusive_available.cc
   src/core/lib/iomgr/load_file.cc
@@ -2549,7 +2586,6 @@ add_library(grpc_unsecure
   src/core/lib/iomgr/pollset_set.cc
   src/core/lib/iomgr/pollset_set_custom.cc
   src/core/lib/iomgr/pollset_set_windows.cc
-  src/core/lib/iomgr/pollset_uv.cc
   src/core/lib/iomgr/pollset_windows.cc
   src/core/lib/iomgr/resolve_address.cc
   src/core/lib/iomgr/resolve_address_custom.cc
@@ -2561,7 +2597,6 @@ add_library(grpc_unsecure
   src/core/lib/iomgr/socket_utils_common_posix.cc
   src/core/lib/iomgr/socket_utils_linux.cc
   src/core/lib/iomgr/socket_utils_posix.cc
-  src/core/lib/iomgr/socket_utils_uv.cc
   src/core/lib/iomgr/socket_utils_windows.cc
   src/core/lib/iomgr/socket_windows.cc
   src/core/lib/iomgr/tcp_client.cc
@@ -2578,7 +2613,6 @@ add_library(grpc_unsecure
   src/core/lib/iomgr/tcp_server_utils_posix_ifaddrs.cc
   src/core/lib/iomgr/tcp_server_utils_posix_noifaddrs.cc
   src/core/lib/iomgr/tcp_server_windows.cc
-  src/core/lib/iomgr/tcp_uv.cc
   src/core/lib/iomgr/tcp_windows.cc
   src/core/lib/iomgr/time_averaged_stats.cc
   src/core/lib/iomgr/timer.cc
@@ -2586,7 +2620,6 @@ add_library(grpc_unsecure
   src/core/lib/iomgr/timer_generic.cc
   src/core/lib/iomgr/timer_heap.cc
   src/core/lib/iomgr/timer_manager.cc
-  src/core/lib/iomgr/timer_uv.cc
   src/core/lib/iomgr/udp_server.cc
   src/core/lib/iomgr/unix_sockets_posix.cc
   src/core/lib/iomgr/unix_sockets_posix_noop.cc
@@ -2684,6 +2717,7 @@ target_link_libraries(grpc_unsecure
   absl::inlined_vector
   absl::bind_front
   absl::statusor
+  absl::variant
   gpr
   address_sorting
 )
@@ -3988,58 +4022,6 @@ target_link_libraries(gen_hpack_tables
 )
 
 
-
-add_executable(gen_legal_metadata_characters
-  tools/codegen/core/gen_legal_metadata_characters.cc
-)
-
-target_include_directories(gen_legal_metadata_characters
-  PRIVATE
-    ${CMAKE_CURRENT_SOURCE_DIR}
-    ${CMAKE_CURRENT_SOURCE_DIR}/include
-    ${_gRPC_ADDRESS_SORTING_INCLUDE_DIR}
-    ${_gRPC_RE2_INCLUDE_DIR}
-    ${_gRPC_SSL_INCLUDE_DIR}
-    ${_gRPC_UPB_GENERATED_DIR}
-    ${_gRPC_UPB_GRPC_GENERATED_DIR}
-    ${_gRPC_UPB_INCLUDE_DIR}
-    ${_gRPC_XXHASH_INCLUDE_DIR}
-    ${_gRPC_ZLIB_INCLUDE_DIR}
-    ${_gRPC_PROTO_GENS_DIR}
-)
-
-target_link_libraries(gen_legal_metadata_characters
-  ${_gRPC_PROTOBUF_LIBRARIES}
-  ${_gRPC_ALLTARGETS_LIBRARIES}
-)
-
-
-
-add_executable(gen_percent_encoding_tables
-  tools/codegen/core/gen_percent_encoding_tables.cc
-)
-
-target_include_directories(gen_percent_encoding_tables
-  PRIVATE
-    ${CMAKE_CURRENT_SOURCE_DIR}
-    ${CMAKE_CURRENT_SOURCE_DIR}/include
-    ${_gRPC_ADDRESS_SORTING_INCLUDE_DIR}
-    ${_gRPC_RE2_INCLUDE_DIR}
-    ${_gRPC_SSL_INCLUDE_DIR}
-    ${_gRPC_UPB_GENERATED_DIR}
-    ${_gRPC_UPB_GRPC_GENERATED_DIR}
-    ${_gRPC_UPB_INCLUDE_DIR}
-    ${_gRPC_XXHASH_INCLUDE_DIR}
-    ${_gRPC_ZLIB_INCLUDE_DIR}
-    ${_gRPC_PROTO_GENS_DIR}
-)
-
-target_link_libraries(gen_percent_encoding_tables
-  ${_gRPC_PROTOBUF_LIBRARIES}
-  ${_gRPC_ALLTARGETS_LIBRARIES}
-)
-
-
 if(gRPC_BUILD_TESTS)
 
 add_executable(algorithm_test
@@ -5855,11 +5837,11 @@ target_link_libraries(hpack_encoder_test
 endif()
 if(gRPC_BUILD_TESTS)
 
-add_executable(hpack_parser_test
-  test/core/transport/chttp2/hpack_parser_test.cc
+add_executable(hpack_parser_table_test
+  test/core/transport/chttp2/hpack_parser_table_test.cc
 )
 
-target_include_directories(hpack_parser_test
+target_include_directories(hpack_parser_table_test
   PRIVATE
     ${CMAKE_CURRENT_SOURCE_DIR}
     ${CMAKE_CURRENT_SOURCE_DIR}/include
@@ -5873,7 +5855,7 @@ target_include_directories(hpack_parser_test
     ${_gRPC_ZLIB_INCLUDE_DIR}
 )
 
-target_link_libraries(hpack_parser_test
+target_link_libraries(hpack_parser_table_test
   ${_gRPC_ALLTARGETS_LIBRARIES}
   grpc_test_util
 )
@@ -5882,11 +5864,11 @@ target_link_libraries(hpack_parser_test
 endif()
 if(gRPC_BUILD_TESTS)
 
-add_executable(hpack_table_test
-  test/core/transport/chttp2/hpack_table_test.cc
+add_executable(hpack_parser_test
+  test/core/transport/chttp2/hpack_parser_test.cc
 )
 
-target_include_directories(hpack_table_test
+target_include_directories(hpack_parser_test
   PRIVATE
     ${CMAKE_CURRENT_SOURCE_DIR}
     ${CMAKE_CURRENT_SOURCE_DIR}/include
@@ -5900,7 +5882,7 @@ target_include_directories(hpack_table_test
     ${_gRPC_ZLIB_INCLUDE_DIR}
 )
 
-target_link_libraries(hpack_table_test
+target_link_libraries(hpack_parser_test
   ${_gRPC_ALLTARGETS_LIBRARIES}
   grpc_test_util
 )
@@ -7551,33 +7533,6 @@ target_link_libraries(timer_list_test
 endif()
 if(gRPC_BUILD_TESTS)
 
-add_executable(tls_test
-  test/core/gpr/tls_test.cc
-)
-
-target_include_directories(tls_test
-  PRIVATE
-    ${CMAKE_CURRENT_SOURCE_DIR}
-    ${CMAKE_CURRENT_SOURCE_DIR}/include
-    ${_gRPC_ADDRESS_SORTING_INCLUDE_DIR}
-    ${_gRPC_RE2_INCLUDE_DIR}
-    ${_gRPC_SSL_INCLUDE_DIR}
-    ${_gRPC_UPB_GENERATED_DIR}
-    ${_gRPC_UPB_GRPC_GENERATED_DIR}
-    ${_gRPC_UPB_INCLUDE_DIR}
-    ${_gRPC_XXHASH_INCLUDE_DIR}
-    ${_gRPC_ZLIB_INCLUDE_DIR}
-)
-
-target_link_libraries(tls_test
-  ${_gRPC_ALLTARGETS_LIBRARIES}
-  grpc_test_util
-)
-
-
-endif()
-if(gRPC_BUILD_TESTS)
-
 add_executable(transport_security_common_api_test
   test/core/tsi/alts/handshaker/transport_security_common_api_test.cc
 )
@@ -7714,6 +7669,111 @@ target_link_libraries(varint_test
 
 endif()
 if(gRPC_BUILD_TESTS)
+
+add_executable(activity_test
+  src/core/ext/upb-generated/google/api/annotations.upb.c
+  src/core/ext/upb-generated/google/api/expr/v1alpha1/checked.upb.c
+  src/core/ext/upb-generated/google/api/expr/v1alpha1/syntax.upb.c
+  src/core/ext/upb-generated/google/api/http.upb.c
+  src/core/ext/upb-generated/google/protobuf/any.upb.c
+  src/core/ext/upb-generated/google/protobuf/duration.upb.c
+  src/core/ext/upb-generated/google/protobuf/empty.upb.c
+  src/core/ext/upb-generated/google/protobuf/struct.upb.c
+  src/core/ext/upb-generated/google/protobuf/timestamp.upb.c
+  src/core/ext/upb-generated/google/protobuf/wrappers.upb.c
+  src/core/ext/upb-generated/google/rpc/status.upb.c
+  src/core/lib/gpr/alloc.cc
+  src/core/lib/gpr/atm.cc
+  src/core/lib/gpr/cpu_iphone.cc
+  src/core/lib/gpr/cpu_linux.cc
+  src/core/lib/gpr/cpu_posix.cc
+  src/core/lib/gpr/cpu_windows.cc
+  src/core/lib/gpr/env_linux.cc
+  src/core/lib/gpr/env_posix.cc
+  src/core/lib/gpr/env_windows.cc
+  src/core/lib/gpr/log.cc
+  src/core/lib/gpr/log_android.cc
+  src/core/lib/gpr/log_linux.cc
+  src/core/lib/gpr/log_posix.cc
+  src/core/lib/gpr/log_windows.cc
+  src/core/lib/gpr/murmur_hash.cc
+  src/core/lib/gpr/string.cc
+  src/core/lib/gpr/string_posix.cc
+  src/core/lib/gpr/string_util_windows.cc
+  src/core/lib/gpr/string_windows.cc
+  src/core/lib/gpr/sync.cc
+  src/core/lib/gpr/sync_abseil.cc
+  src/core/lib/gpr/sync_posix.cc
+  src/core/lib/gpr/sync_windows.cc
+  src/core/lib/gpr/time.cc
+  src/core/lib/gpr/time_posix.cc
+  src/core/lib/gpr/time_precise.cc
+  src/core/lib/gpr/time_windows.cc
+  src/core/lib/gpr/tmpfile_msys.cc
+  src/core/lib/gpr/tmpfile_posix.cc
+  src/core/lib/gpr/tmpfile_windows.cc
+  src/core/lib/gpr/wrap_memcpy.cc
+  src/core/lib/gprpp/arena.cc
+  src/core/lib/gprpp/examine_stack.cc
+  src/core/lib/gprpp/fork.cc
+  src/core/lib/gprpp/global_config_env.cc
+  src/core/lib/gprpp/host_port.cc
+  src/core/lib/gprpp/mpscq.cc
+  src/core/lib/gprpp/stat_posix.cc
+  src/core/lib/gprpp/stat_windows.cc
+  src/core/lib/gprpp/status_helper.cc
+  src/core/lib/gprpp/thd_posix.cc
+  src/core/lib/gprpp/thd_windows.cc
+  src/core/lib/gprpp/time_util.cc
+  src/core/lib/profiling/basic_timers.cc
+  src/core/lib/profiling/stap_timers.cc
+  src/core/lib/promise/activity.cc
+  test/core/promise/activity_test.cc
+  third_party/googletest/googletest/src/gtest-all.cc
+  third_party/googletest/googlemock/src/gmock-all.cc
+)
+
+target_include_directories(activity_test
+  PRIVATE
+    ${CMAKE_CURRENT_SOURCE_DIR}
+    ${CMAKE_CURRENT_SOURCE_DIR}/include
+    ${_gRPC_ADDRESS_SORTING_INCLUDE_DIR}
+    ${_gRPC_RE2_INCLUDE_DIR}
+    ${_gRPC_SSL_INCLUDE_DIR}
+    ${_gRPC_UPB_GENERATED_DIR}
+    ${_gRPC_UPB_GRPC_GENERATED_DIR}
+    ${_gRPC_UPB_INCLUDE_DIR}
+    ${_gRPC_XXHASH_INCLUDE_DIR}
+    ${_gRPC_ZLIB_INCLUDE_DIR}
+    third_party/googletest/googletest/include
+    third_party/googletest/googletest
+    third_party/googletest/googlemock/include
+    third_party/googletest/googlemock
+    ${_gRPC_PROTO_GENS_DIR}
+)
+
+target_link_libraries(activity_test
+  ${_gRPC_PROTOBUF_LIBRARIES}
+  ${_gRPC_ALLTARGETS_LIBRARIES}
+  absl::base
+  absl::core_headers
+  absl::flat_hash_set
+  absl::memory
+  absl::status
+  absl::statusor
+  absl::cord
+  absl::str_format
+  absl::strings
+  absl::synchronization
+  absl::time
+  absl::optional
+  absl::variant
+  upb
+)
+
+
+endif()
+if(gRPC_BUILD_TESTS)
 if(_gRPC_PLATFORM_LINUX OR _gRPC_PLATFORM_MAC OR _gRPC_PLATFORM_POSIX)
 
   add_executable(address_sorting_test
@@ -8323,13 +8383,85 @@ endif()
 endif()
 if(gRPC_BUILD_TESTS)
 
-add_executable(binder_smoke_test
-  test/core/transport/binder/binder_smoke_test.cc
+add_executable(binder_server_test
+  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/echo.pb.cc
+  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/echo.grpc.pb.cc
+  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/echo.pb.h
+  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/echo.grpc.pb.h
+  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/echo_messages.pb.cc
+  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/echo_messages.grpc.pb.cc
+  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/echo_messages.pb.h
+  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/echo_messages.grpc.pb.h
+  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/simple_messages.pb.cc
+  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/simple_messages.grpc.pb.cc
+  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/simple_messages.pb.h
+  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/simple_messages.grpc.pb.h
+  ${_gRPC_PROTO_GENS_DIR}/test/core/transport/binder/end2end/echo.pb.cc
+  ${_gRPC_PROTO_GENS_DIR}/test/core/transport/binder/end2end/echo.grpc.pb.cc
+  ${_gRPC_PROTO_GENS_DIR}/test/core/transport/binder/end2end/echo.pb.h
+  ${_gRPC_PROTO_GENS_DIR}/test/core/transport/binder/end2end/echo.grpc.pb.h
+  src/core/ext/transport/binder/client/channel_create_impl.cc
+  src/core/ext/transport/binder/server/binder_server.cc
+  src/core/ext/transport/binder/server/binder_server_credentials.cc
+  src/core/ext/transport/binder/transport/binder_transport.cc
+  src/core/ext/transport/binder/utils/transport_stream_receiver_impl.cc
+  src/core/ext/transport/binder/wire_format/binder_android.cc
+  src/core/ext/transport/binder/wire_format/binder_constants.cc
+  src/core/ext/transport/binder/wire_format/transaction.cc
+  src/core/ext/transport/binder/wire_format/wire_reader_impl.cc
+  src/core/ext/transport/binder/wire_format/wire_writer.cc
+  test/core/transport/binder/end2end/binder_server_test.cc
+  test/core/transport/binder/end2end/echo_service.cc
+  test/core/transport/binder/end2end/fake_binder.cc
+  test/cpp/end2end/test_service_impl.cc
+  third_party/googletest/googletest/src/gtest-all.cc
+  third_party/googletest/googlemock/src/gmock-all.cc
+)
+
+target_include_directories(binder_server_test
+  PRIVATE
+    ${CMAKE_CURRENT_SOURCE_DIR}
+    ${CMAKE_CURRENT_SOURCE_DIR}/include
+    ${_gRPC_ADDRESS_SORTING_INCLUDE_DIR}
+    ${_gRPC_RE2_INCLUDE_DIR}
+    ${_gRPC_SSL_INCLUDE_DIR}
+    ${_gRPC_UPB_GENERATED_DIR}
+    ${_gRPC_UPB_GRPC_GENERATED_DIR}
+    ${_gRPC_UPB_INCLUDE_DIR}
+    ${_gRPC_XXHASH_INCLUDE_DIR}
+    ${_gRPC_ZLIB_INCLUDE_DIR}
+    third_party/googletest/googletest/include
+    third_party/googletest/googletest
+    third_party/googletest/googlemock/include
+    third_party/googletest/googlemock
+    ${_gRPC_PROTO_GENS_DIR}
+)
+
+target_link_libraries(binder_server_test
+  ${_gRPC_PROTOBUF_LIBRARIES}
+  ${_gRPC_ALLTARGETS_LIBRARIES}
+  absl::random_random
+  grpc++_test_util
+)
+
+
+endif()
+if(gRPC_BUILD_TESTS)
+
+add_executable(binder_transport_test
+  src/core/ext/transport/binder/transport/binder_transport.cc
+  src/core/ext/transport/binder/utils/transport_stream_receiver_impl.cc
+  src/core/ext/transport/binder/wire_format/binder_constants.cc
+  src/core/ext/transport/binder/wire_format/transaction.cc
+  src/core/ext/transport/binder/wire_format/wire_reader_impl.cc
+  src/core/ext/transport/binder/wire_format/wire_writer.cc
+  test/core/transport/binder/binder_transport_test.cc
+  test/core/transport/binder/mock_objects.cc
   third_party/googletest/googletest/src/gtest-all.cc
   third_party/googletest/googlemock/src/gmock-all.cc
 )
 
-target_include_directories(binder_smoke_test
+target_include_directories(binder_transport_test
   PRIVATE
     ${CMAKE_CURRENT_SOURCE_DIR}
     ${CMAKE_CURRENT_SOURCE_DIR}/include
@@ -8348,7 +8480,7 @@ target_include_directories(binder_smoke_test
     ${_gRPC_PROTO_GENS_DIR}
 )
 
-target_link_libraries(binder_smoke_test
+target_link_libraries(binder_transport_test
   ${_gRPC_PROTOBUF_LIBRARIES}
   ${_gRPC_ALLTARGETS_LIBRARIES}
   grpc_test_util
@@ -9286,17 +9418,13 @@ target_link_libraries(cancel_ares_query_test
 endif()
 if(gRPC_BUILD_TESTS)
 
-add_executable(cel_authorization_engine_test
-  src/core/lib/security/authorization/cel_authorization_engine.cc
-  src/core/lib/security/authorization/grpc_authorization_engine.cc
-  src/core/lib/security/authorization/matchers.cc
-  src/core/lib/security/authorization/rbac_policy.cc
-  test/core/security/cel_authorization_engine_test.cc
+add_executable(capture_test
+  test/core/gprpp/capture_test.cc
   third_party/googletest/googletest/src/gtest-all.cc
   third_party/googletest/googlemock/src/gmock-all.cc
 )
 
-target_include_directories(cel_authorization_engine_test
+target_include_directories(capture_test
   PRIVATE
     ${CMAKE_CURRENT_SOURCE_DIR}
     ${CMAKE_CURRENT_SOURCE_DIR}/include
@@ -9315,24 +9443,27 @@ target_include_directories(cel_authorization_engine_test
     ${_gRPC_PROTO_GENS_DIR}
 )
 
-target_link_libraries(cel_authorization_engine_test
+target_link_libraries(capture_test
   ${_gRPC_PROTOBUF_LIBRARIES}
   ${_gRPC_ALLTARGETS_LIBRARIES}
-  absl::flat_hash_set
-  grpc_test_util
+  absl::utility
 )
 
 
 endif()
 if(gRPC_BUILD_TESTS)
 
-add_executable(certificate_provider_registry_test
-  test/core/client_channel/certificate_provider_registry_test.cc
+add_executable(cel_authorization_engine_test
+  src/core/lib/security/authorization/cel_authorization_engine.cc
+  src/core/lib/security/authorization/grpc_authorization_engine.cc
+  src/core/lib/security/authorization/matchers.cc
+  src/core/lib/security/authorization/rbac_policy.cc
+  test/core/security/cel_authorization_engine_test.cc
   third_party/googletest/googletest/src/gtest-all.cc
   third_party/googletest/googlemock/src/gmock-all.cc
 )
 
-target_include_directories(certificate_provider_registry_test
+target_include_directories(cel_authorization_engine_test
   PRIVATE
     ${CMAKE_CURRENT_SOURCE_DIR}
     ${CMAKE_CURRENT_SOURCE_DIR}/include
@@ -9351,7 +9482,43 @@ target_include_directories(certificate_provider_registry_test
     ${_gRPC_PROTO_GENS_DIR}
 )
 
-target_link_libraries(certificate_provider_registry_test
+target_link_libraries(cel_authorization_engine_test
+  ${_gRPC_PROTOBUF_LIBRARIES}
+  ${_gRPC_ALLTARGETS_LIBRARIES}
+  absl::flat_hash_set
+  grpc_test_util
+)
+
+
+endif()
+if(gRPC_BUILD_TESTS)
+
+add_executable(certificate_provider_registry_test
+  test/core/client_channel/certificate_provider_registry_test.cc
+  third_party/googletest/googletest/src/gtest-all.cc
+  third_party/googletest/googlemock/src/gmock-all.cc
+)
+
+target_include_directories(certificate_provider_registry_test
+  PRIVATE
+    ${CMAKE_CURRENT_SOURCE_DIR}
+    ${CMAKE_CURRENT_SOURCE_DIR}/include
+    ${_gRPC_ADDRESS_SORTING_INCLUDE_DIR}
+    ${_gRPC_RE2_INCLUDE_DIR}
+    ${_gRPC_SSL_INCLUDE_DIR}
+    ${_gRPC_UPB_GENERATED_DIR}
+    ${_gRPC_UPB_GRPC_GENERATED_DIR}
+    ${_gRPC_UPB_INCLUDE_DIR}
+    ${_gRPC_XXHASH_INCLUDE_DIR}
+    ${_gRPC_ZLIB_INCLUDE_DIR}
+    third_party/googletest/googletest/include
+    third_party/googletest/googletest
+    third_party/googletest/googlemock/include
+    third_party/googletest/googlemock
+    ${_gRPC_PROTO_GENS_DIR}
+)
+
+target_link_libraries(certificate_provider_registry_test
   ${_gRPC_PROTOBUF_LIBRARIES}
   ${_gRPC_ALLTARGETS_LIBRARIES}
   grpc_test_util
@@ -10218,6 +10385,143 @@ target_link_libraries(context_list_test
 endif()
 if(gRPC_BUILD_TESTS)
 
+add_executable(context_test
+  test/core/promise/context_test.cc
+  third_party/googletest/googletest/src/gtest-all.cc
+  third_party/googletest/googlemock/src/gmock-all.cc
+)
+
+target_include_directories(context_test
+  PRIVATE
+    ${CMAKE_CURRENT_SOURCE_DIR}
+    ${CMAKE_CURRENT_SOURCE_DIR}/include
+    ${_gRPC_ADDRESS_SORTING_INCLUDE_DIR}
+    ${_gRPC_RE2_INCLUDE_DIR}
+    ${_gRPC_SSL_INCLUDE_DIR}
+    ${_gRPC_UPB_GENERATED_DIR}
+    ${_gRPC_UPB_GRPC_GENERATED_DIR}
+    ${_gRPC_UPB_INCLUDE_DIR}
+    ${_gRPC_XXHASH_INCLUDE_DIR}
+    ${_gRPC_ZLIB_INCLUDE_DIR}
+    third_party/googletest/googletest/include
+    third_party/googletest/googletest
+    third_party/googletest/googlemock/include
+    third_party/googletest/googlemock
+    ${_gRPC_PROTO_GENS_DIR}
+)
+
+target_link_libraries(context_test
+  ${_gRPC_PROTOBUF_LIBRARIES}
+  ${_gRPC_ALLTARGETS_LIBRARIES}
+)
+
+
+endif()
+if(gRPC_BUILD_TESTS)
+
+add_executable(core_configuration_test
+  src/core/ext/upb-generated/google/api/annotations.upb.c
+  src/core/ext/upb-generated/google/api/expr/v1alpha1/checked.upb.c
+  src/core/ext/upb-generated/google/api/expr/v1alpha1/syntax.upb.c
+  src/core/ext/upb-generated/google/api/http.upb.c
+  src/core/ext/upb-generated/google/protobuf/any.upb.c
+  src/core/ext/upb-generated/google/protobuf/duration.upb.c
+  src/core/ext/upb-generated/google/protobuf/empty.upb.c
+  src/core/ext/upb-generated/google/protobuf/struct.upb.c
+  src/core/ext/upb-generated/google/protobuf/timestamp.upb.c
+  src/core/ext/upb-generated/google/protobuf/wrappers.upb.c
+  src/core/ext/upb-generated/google/rpc/status.upb.c
+  src/core/lib/channel/handshaker_registry.cc
+  src/core/lib/config/core_configuration.cc
+  src/core/lib/gpr/alloc.cc
+  src/core/lib/gpr/atm.cc
+  src/core/lib/gpr/cpu_iphone.cc
+  src/core/lib/gpr/cpu_linux.cc
+  src/core/lib/gpr/cpu_posix.cc
+  src/core/lib/gpr/cpu_windows.cc
+  src/core/lib/gpr/env_linux.cc
+  src/core/lib/gpr/env_posix.cc
+  src/core/lib/gpr/env_windows.cc
+  src/core/lib/gpr/log.cc
+  src/core/lib/gpr/log_android.cc
+  src/core/lib/gpr/log_linux.cc
+  src/core/lib/gpr/log_posix.cc
+  src/core/lib/gpr/log_windows.cc
+  src/core/lib/gpr/murmur_hash.cc
+  src/core/lib/gpr/string.cc
+  src/core/lib/gpr/string_posix.cc
+  src/core/lib/gpr/string_util_windows.cc
+  src/core/lib/gpr/string_windows.cc
+  src/core/lib/gpr/sync.cc
+  src/core/lib/gpr/sync_abseil.cc
+  src/core/lib/gpr/sync_posix.cc
+  src/core/lib/gpr/sync_windows.cc
+  src/core/lib/gpr/time.cc
+  src/core/lib/gpr/time_posix.cc
+  src/core/lib/gpr/time_precise.cc
+  src/core/lib/gpr/time_windows.cc
+  src/core/lib/gpr/tmpfile_msys.cc
+  src/core/lib/gpr/tmpfile_posix.cc
+  src/core/lib/gpr/tmpfile_windows.cc
+  src/core/lib/gpr/wrap_memcpy.cc
+  src/core/lib/gprpp/arena.cc
+  src/core/lib/gprpp/examine_stack.cc
+  src/core/lib/gprpp/fork.cc
+  src/core/lib/gprpp/global_config_env.cc
+  src/core/lib/gprpp/host_port.cc
+  src/core/lib/gprpp/mpscq.cc
+  src/core/lib/gprpp/stat_posix.cc
+  src/core/lib/gprpp/stat_windows.cc
+  src/core/lib/gprpp/status_helper.cc
+  src/core/lib/gprpp/thd_posix.cc
+  src/core/lib/gprpp/thd_windows.cc
+  src/core/lib/gprpp/time_util.cc
+  src/core/lib/profiling/basic_timers.cc
+  src/core/lib/profiling/stap_timers.cc
+  test/core/config/core_configuration_test.cc
+  third_party/googletest/googletest/src/gtest-all.cc
+  third_party/googletest/googlemock/src/gmock-all.cc
+)
+
+target_include_directories(core_configuration_test
+  PRIVATE
+    ${CMAKE_CURRENT_SOURCE_DIR}
+    ${CMAKE_CURRENT_SOURCE_DIR}/include
+    ${_gRPC_ADDRESS_SORTING_INCLUDE_DIR}
+    ${_gRPC_RE2_INCLUDE_DIR}
+    ${_gRPC_SSL_INCLUDE_DIR}
+    ${_gRPC_UPB_GENERATED_DIR}
+    ${_gRPC_UPB_GRPC_GENERATED_DIR}
+    ${_gRPC_UPB_INCLUDE_DIR}
+    ${_gRPC_XXHASH_INCLUDE_DIR}
+    ${_gRPC_ZLIB_INCLUDE_DIR}
+    third_party/googletest/googletest/include
+    third_party/googletest/googletest
+    third_party/googletest/googlemock/include
+    third_party/googletest/googlemock
+    ${_gRPC_PROTO_GENS_DIR}
+)
+
+target_link_libraries(core_configuration_test
+  ${_gRPC_PROTOBUF_LIBRARIES}
+  ${_gRPC_ALLTARGETS_LIBRARIES}
+  absl::base
+  absl::core_headers
+  absl::memory
+  absl::status
+  absl::cord
+  absl::str_format
+  absl::strings
+  absl::synchronization
+  absl::time
+  absl::optional
+  upb
+)
+
+
+endif()
+if(gRPC_BUILD_TESTS)
+
 add_executable(delegating_channel_test
   ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/echo.pb.cc
   ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/echo.grpc.pb.cc
@@ -10373,6 +10677,92 @@ target_link_libraries(duplicate_header_bad_client_test
 endif()
 if(gRPC_BUILD_TESTS)
 
+add_executable(end2end_binder_transport_test
+  ${_gRPC_PROTO_GENS_DIR}/test/core/transport/binder/end2end/echo.pb.cc
+  ${_gRPC_PROTO_GENS_DIR}/test/core/transport/binder/end2end/echo.grpc.pb.cc
+  ${_gRPC_PROTO_GENS_DIR}/test/core/transport/binder/end2end/echo.pb.h
+  ${_gRPC_PROTO_GENS_DIR}/test/core/transport/binder/end2end/echo.grpc.pb.h
+  src/core/ext/transport/binder/transport/binder_transport.cc
+  src/core/ext/transport/binder/utils/transport_stream_receiver_impl.cc
+  src/core/ext/transport/binder/wire_format/binder_constants.cc
+  src/core/ext/transport/binder/wire_format/transaction.cc
+  src/core/ext/transport/binder/wire_format/wire_reader_impl.cc
+  src/core/ext/transport/binder/wire_format/wire_writer.cc
+  src/cpp/client/channel_cc.cc
+  src/cpp/client/client_callback.cc
+  src/cpp/client/client_context.cc
+  src/cpp/client/client_interceptor.cc
+  src/cpp/client/create_channel.cc
+  src/cpp/client/create_channel_internal.cc
+  src/cpp/client/create_channel_posix.cc
+  src/cpp/client/credentials_cc.cc
+  src/cpp/codegen/codegen_init.cc
+  src/cpp/common/alarm.cc
+  src/cpp/common/channel_arguments.cc
+  src/cpp/common/channel_filter.cc
+  src/cpp/common/completion_queue_cc.cc
+  src/cpp/common/core_codegen.cc
+  src/cpp/common/resource_quota_cc.cc
+  src/cpp/common/rpc_method.cc
+  src/cpp/common/validate_service_config.cc
+  src/cpp/common/version_cc.cc
+  src/cpp/server/async_generic_service.cc
+  src/cpp/server/channel_argument_option.cc
+  src/cpp/server/create_default_thread_pool.cc
+  src/cpp/server/dynamic_thread_pool.cc
+  src/cpp/server/external_connection_acceptor_impl.cc
+  src/cpp/server/health/default_health_check_service.cc
+  src/cpp/server/health/health_check_service.cc
+  src/cpp/server/health/health_check_service_server_builder_option.cc
+  src/cpp/server/server_builder.cc
+  src/cpp/server/server_callback.cc
+  src/cpp/server/server_cc.cc
+  src/cpp/server/server_context.cc
+  src/cpp/server/server_credentials.cc
+  src/cpp/server/server_posix.cc
+  src/cpp/thread_manager/thread_manager.cc
+  src/cpp/util/byte_buffer_cc.cc
+  src/cpp/util/status.cc
+  src/cpp/util/string_ref.cc
+  src/cpp/util/time_cc.cc
+  test/core/transport/binder/end2end/echo_service.cc
+  test/core/transport/binder/end2end/end2end_binder_transport_test.cc
+  test/core/transport/binder/end2end/fake_binder.cc
+  test/core/transport/binder/end2end/testing_channel_create.cc
+  third_party/googletest/googletest/src/gtest-all.cc
+  third_party/googletest/googlemock/src/gmock-all.cc
+)
+
+target_include_directories(end2end_binder_transport_test
+  PRIVATE
+    ${CMAKE_CURRENT_SOURCE_DIR}
+    ${CMAKE_CURRENT_SOURCE_DIR}/include
+    ${_gRPC_ADDRESS_SORTING_INCLUDE_DIR}
+    ${_gRPC_RE2_INCLUDE_DIR}
+    ${_gRPC_SSL_INCLUDE_DIR}
+    ${_gRPC_UPB_GENERATED_DIR}
+    ${_gRPC_UPB_GRPC_GENERATED_DIR}
+    ${_gRPC_UPB_INCLUDE_DIR}
+    ${_gRPC_XXHASH_INCLUDE_DIR}
+    ${_gRPC_ZLIB_INCLUDE_DIR}
+    third_party/googletest/googletest/include
+    third_party/googletest/googletest
+    third_party/googletest/googlemock/include
+    third_party/googletest/googlemock
+    ${_gRPC_PROTO_GENS_DIR}
+)
+
+target_link_libraries(end2end_binder_transport_test
+  ${_gRPC_PROTOBUF_LIBRARIES}
+  ${_gRPC_ALLTARGETS_LIBRARIES}
+  absl::random_random
+  grpc_test_util
+)
+
+
+endif()
+if(gRPC_BUILD_TESTS)
+
 add_executable(end2end_test
   ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/duplicate/echo_duplicate.pb.cc
   ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/duplicate/echo_duplicate.grpc.pb.cc
@@ -10660,13 +11050,19 @@ target_link_libraries(exception_test
 endif()
 if(gRPC_BUILD_TESTS)
 
-add_executable(file_watcher_certificate_provider_factory_test
-  test/core/xds/file_watcher_certificate_provider_factory_test.cc
+add_executable(fake_binder_test
+  src/core/ext/transport/binder/utils/transport_stream_receiver_impl.cc
+  src/core/ext/transport/binder/wire_format/binder_constants.cc
+  src/core/ext/transport/binder/wire_format/transaction.cc
+  src/core/ext/transport/binder/wire_format/wire_reader_impl.cc
+  src/core/ext/transport/binder/wire_format/wire_writer.cc
+  test/core/transport/binder/end2end/fake_binder.cc
+  test/core/transport/binder/end2end/fake_binder_test.cc
   third_party/googletest/googletest/src/gtest-all.cc
   third_party/googletest/googlemock/src/gmock-all.cc
 )
 
-target_include_directories(file_watcher_certificate_provider_factory_test
+target_include_directories(fake_binder_test
   PRIVATE
     ${CMAKE_CURRENT_SOURCE_DIR}
     ${CMAKE_CURRENT_SOURCE_DIR}/include
@@ -10685,9 +11081,10 @@ target_include_directories(file_watcher_certificate_provider_factory_test
     ${_gRPC_PROTO_GENS_DIR}
 )
 
-target_link_libraries(file_watcher_certificate_provider_factory_test
+target_link_libraries(fake_binder_test
   ${_gRPC_PROTOBUF_LIBRARIES}
   ${_gRPC_ALLTARGETS_LIBRARIES}
+  absl::random_random
   grpc_test_util
 )
 
@@ -10695,25 +11092,60 @@ target_link_libraries(file_watcher_certificate_provider_factory_test
 endif()
 if(gRPC_BUILD_TESTS)
 
-add_executable(filter_end2end_test
-  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/duplicate/echo_duplicate.pb.cc
-  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/duplicate/echo_duplicate.grpc.pb.cc
-  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/duplicate/echo_duplicate.pb.h
-  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/duplicate/echo_duplicate.grpc.pb.h
-  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/echo.pb.cc
-  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/echo.grpc.pb.cc
-  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/echo.pb.h
-  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/echo.grpc.pb.h
-  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/echo_messages.pb.cc
-  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/echo_messages.grpc.pb.cc
-  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/echo_messages.pb.h
-  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/echo_messages.grpc.pb.h
-  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/simple_messages.pb.cc
-  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/simple_messages.grpc.pb.cc
-  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/simple_messages.pb.h
-  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/simple_messages.grpc.pb.h
-  test/cpp/end2end/filter_end2end_test.cc
-  third_party/googletest/googletest/src/gtest-all.cc
+add_executable(file_watcher_certificate_provider_factory_test
+  test/core/xds/file_watcher_certificate_provider_factory_test.cc
+  third_party/googletest/googletest/src/gtest-all.cc
+  third_party/googletest/googlemock/src/gmock-all.cc
+)
+
+target_include_directories(file_watcher_certificate_provider_factory_test
+  PRIVATE
+    ${CMAKE_CURRENT_SOURCE_DIR}
+    ${CMAKE_CURRENT_SOURCE_DIR}/include
+    ${_gRPC_ADDRESS_SORTING_INCLUDE_DIR}
+    ${_gRPC_RE2_INCLUDE_DIR}
+    ${_gRPC_SSL_INCLUDE_DIR}
+    ${_gRPC_UPB_GENERATED_DIR}
+    ${_gRPC_UPB_GRPC_GENERATED_DIR}
+    ${_gRPC_UPB_INCLUDE_DIR}
+    ${_gRPC_XXHASH_INCLUDE_DIR}
+    ${_gRPC_ZLIB_INCLUDE_DIR}
+    third_party/googletest/googletest/include
+    third_party/googletest/googletest
+    third_party/googletest/googlemock/include
+    third_party/googletest/googlemock
+    ${_gRPC_PROTO_GENS_DIR}
+)
+
+target_link_libraries(file_watcher_certificate_provider_factory_test
+  ${_gRPC_PROTOBUF_LIBRARIES}
+  ${_gRPC_ALLTARGETS_LIBRARIES}
+  grpc_test_util
+)
+
+
+endif()
+if(gRPC_BUILD_TESTS)
+
+add_executable(filter_end2end_test
+  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/duplicate/echo_duplicate.pb.cc
+  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/duplicate/echo_duplicate.grpc.pb.cc
+  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/duplicate/echo_duplicate.pb.h
+  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/duplicate/echo_duplicate.grpc.pb.h
+  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/echo.pb.cc
+  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/echo.grpc.pb.cc
+  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/echo.pb.h
+  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/echo.grpc.pb.h
+  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/echo_messages.pb.cc
+  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/echo_messages.grpc.pb.cc
+  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/echo_messages.pb.h
+  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/echo_messages.grpc.pb.h
+  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/simple_messages.pb.cc
+  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/simple_messages.grpc.pb.cc
+  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/simple_messages.pb.h
+  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/simple_messages.grpc.pb.h
+  test/cpp/end2end/filter_end2end_test.cc
+  third_party/googletest/googletest/src/gtest-all.cc
   third_party/googletest/googlemock/src/gmock-all.cc
 )
 
@@ -10794,6 +11226,147 @@ target_link_libraries(flaky_network_test
 endif()
 if(gRPC_BUILD_TESTS)
 
+add_executable(flow_control_test
+  test/core/end2end/cq_verifier.cc
+  test/core/transport/chttp2/flow_control_test.cc
+  third_party/googletest/googletest/src/gtest-all.cc
+  third_party/googletest/googlemock/src/gmock-all.cc
+)
+
+target_include_directories(flow_control_test
+  PRIVATE
+    ${CMAKE_CURRENT_SOURCE_DIR}
+    ${CMAKE_CURRENT_SOURCE_DIR}/include
+    ${_gRPC_ADDRESS_SORTING_INCLUDE_DIR}
+    ${_gRPC_RE2_INCLUDE_DIR}
+    ${_gRPC_SSL_INCLUDE_DIR}
+    ${_gRPC_UPB_GENERATED_DIR}
+    ${_gRPC_UPB_GRPC_GENERATED_DIR}
+    ${_gRPC_UPB_INCLUDE_DIR}
+    ${_gRPC_XXHASH_INCLUDE_DIR}
+    ${_gRPC_ZLIB_INCLUDE_DIR}
+    third_party/googletest/googletest/include
+    third_party/googletest/googletest
+    third_party/googletest/googlemock/include
+    third_party/googletest/googlemock
+    ${_gRPC_PROTO_GENS_DIR}
+)
+
+target_link_libraries(flow_control_test
+  ${_gRPC_PROTOBUF_LIBRARIES}
+  ${_gRPC_ALLTARGETS_LIBRARIES}
+  grpc_test_util
+)
+
+
+endif()
+if(gRPC_BUILD_TESTS)
+
+add_executable(for_each_test
+  src/core/ext/upb-generated/google/api/annotations.upb.c
+  src/core/ext/upb-generated/google/api/expr/v1alpha1/checked.upb.c
+  src/core/ext/upb-generated/google/api/expr/v1alpha1/syntax.upb.c
+  src/core/ext/upb-generated/google/api/http.upb.c
+  src/core/ext/upb-generated/google/protobuf/any.upb.c
+  src/core/ext/upb-generated/google/protobuf/duration.upb.c
+  src/core/ext/upb-generated/google/protobuf/empty.upb.c
+  src/core/ext/upb-generated/google/protobuf/struct.upb.c
+  src/core/ext/upb-generated/google/protobuf/timestamp.upb.c
+  src/core/ext/upb-generated/google/protobuf/wrappers.upb.c
+  src/core/ext/upb-generated/google/rpc/status.upb.c
+  src/core/lib/gpr/alloc.cc
+  src/core/lib/gpr/atm.cc
+  src/core/lib/gpr/cpu_iphone.cc
+  src/core/lib/gpr/cpu_linux.cc
+  src/core/lib/gpr/cpu_posix.cc
+  src/core/lib/gpr/cpu_windows.cc
+  src/core/lib/gpr/env_linux.cc
+  src/core/lib/gpr/env_posix.cc
+  src/core/lib/gpr/env_windows.cc
+  src/core/lib/gpr/log.cc
+  src/core/lib/gpr/log_android.cc
+  src/core/lib/gpr/log_linux.cc
+  src/core/lib/gpr/log_posix.cc
+  src/core/lib/gpr/log_windows.cc
+  src/core/lib/gpr/murmur_hash.cc
+  src/core/lib/gpr/string.cc
+  src/core/lib/gpr/string_posix.cc
+  src/core/lib/gpr/string_util_windows.cc
+  src/core/lib/gpr/string_windows.cc
+  src/core/lib/gpr/sync.cc
+  src/core/lib/gpr/sync_abseil.cc
+  src/core/lib/gpr/sync_posix.cc
+  src/core/lib/gpr/sync_windows.cc
+  src/core/lib/gpr/time.cc
+  src/core/lib/gpr/time_posix.cc
+  src/core/lib/gpr/time_precise.cc
+  src/core/lib/gpr/time_windows.cc
+  src/core/lib/gpr/tmpfile_msys.cc
+  src/core/lib/gpr/tmpfile_posix.cc
+  src/core/lib/gpr/tmpfile_windows.cc
+  src/core/lib/gpr/wrap_memcpy.cc
+  src/core/lib/gprpp/arena.cc
+  src/core/lib/gprpp/examine_stack.cc
+  src/core/lib/gprpp/fork.cc
+  src/core/lib/gprpp/global_config_env.cc
+  src/core/lib/gprpp/host_port.cc
+  src/core/lib/gprpp/mpscq.cc
+  src/core/lib/gprpp/stat_posix.cc
+  src/core/lib/gprpp/stat_windows.cc
+  src/core/lib/gprpp/status_helper.cc
+  src/core/lib/gprpp/thd_posix.cc
+  src/core/lib/gprpp/thd_windows.cc
+  src/core/lib/gprpp/time_util.cc
+  src/core/lib/profiling/basic_timers.cc
+  src/core/lib/profiling/stap_timers.cc
+  src/core/lib/promise/activity.cc
+  test/core/promise/for_each_test.cc
+  third_party/googletest/googletest/src/gtest-all.cc
+  third_party/googletest/googlemock/src/gmock-all.cc
+)
+
+target_include_directories(for_each_test
+  PRIVATE
+    ${CMAKE_CURRENT_SOURCE_DIR}
+    ${CMAKE_CURRENT_SOURCE_DIR}/include
+    ${_gRPC_ADDRESS_SORTING_INCLUDE_DIR}
+    ${_gRPC_RE2_INCLUDE_DIR}
+    ${_gRPC_SSL_INCLUDE_DIR}
+    ${_gRPC_UPB_GENERATED_DIR}
+    ${_gRPC_UPB_GRPC_GENERATED_DIR}
+    ${_gRPC_UPB_INCLUDE_DIR}
+    ${_gRPC_XXHASH_INCLUDE_DIR}
+    ${_gRPC_ZLIB_INCLUDE_DIR}
+    third_party/googletest/googletest/include
+    third_party/googletest/googletest
+    third_party/googletest/googlemock/include
+    third_party/googletest/googlemock
+    ${_gRPC_PROTO_GENS_DIR}
+)
+
+target_link_libraries(for_each_test
+  ${_gRPC_PROTOBUF_LIBRARIES}
+  ${_gRPC_ALLTARGETS_LIBRARIES}
+  absl::base
+  absl::core_headers
+  absl::flat_hash_set
+  absl::memory
+  absl::status
+  absl::statusor
+  absl::cord
+  absl::str_format
+  absl::strings
+  absl::synchronization
+  absl::time
+  absl::optional
+  absl::variant
+  upb
+)
+
+
+endif()
+if(gRPC_BUILD_TESTS)
+
 add_executable(generic_end2end_test
   ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/duplicate/echo_duplicate.pb.cc
   ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/duplicate/echo_duplicate.grpc.pb.cc
@@ -11504,6 +12077,7 @@ if(_gRPC_PLATFORM_LINUX OR _gRPC_PLATFORM_MAC OR _gRPC_PLATFORM_POSIX)
     ${_gRPC_PROTOBUF_LIBRARIES}
     ${_gRPC_ALLTARGETS_LIBRARIES}
     grpc++_reflection
+    grpc++_test_config
     grpc++_test_util
   )
 
@@ -11601,6 +12175,7 @@ if(_gRPC_PLATFORM_LINUX OR _gRPC_PLATFORM_MAC OR _gRPC_PLATFORM_POSIX)
   target_link_libraries(grpclb_end2end_test
     ${_gRPC_PROTOBUF_LIBRARIES}
     ${_gRPC_ALLTARGETS_LIBRARIES}
+    grpc++_test_config
     grpc++_test_util
   )
 
@@ -11775,6 +12350,41 @@ target_link_libraries(health_service_end2end_test
 endif()
 if(gRPC_BUILD_TESTS)
 
+add_executable(hpack_encoder_index_test
+  test/core/transport/chttp2/hpack_encoder_index_test.cc
+  third_party/googletest/googletest/src/gtest-all.cc
+  third_party/googletest/googlemock/src/gmock-all.cc
+)
+
+target_include_directories(hpack_encoder_index_test
+  PRIVATE
+    ${CMAKE_CURRENT_SOURCE_DIR}
+    ${CMAKE_CURRENT_SOURCE_DIR}/include
+    ${_gRPC_ADDRESS_SORTING_INCLUDE_DIR}
+    ${_gRPC_RE2_INCLUDE_DIR}
+    ${_gRPC_SSL_INCLUDE_DIR}
+    ${_gRPC_UPB_GENERATED_DIR}
+    ${_gRPC_UPB_GRPC_GENERATED_DIR}
+    ${_gRPC_UPB_INCLUDE_DIR}
+    ${_gRPC_XXHASH_INCLUDE_DIR}
+    ${_gRPC_ZLIB_INCLUDE_DIR}
+    third_party/googletest/googletest/include
+    third_party/googletest/googletest
+    third_party/googletest/googlemock/include
+    third_party/googletest/googlemock
+    ${_gRPC_PROTO_GENS_DIR}
+)
+
+target_link_libraries(hpack_encoder_index_test
+  ${_gRPC_PROTOBUF_LIBRARIES}
+  ${_gRPC_ALLTARGETS_LIBRARIES}
+  absl::optional
+)
+
+
+endif()
+if(gRPC_BUILD_TESTS)
+
 add_executable(http2_client
   ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/empty.pb.cc
   ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/empty.grpc.pb.cc
@@ -11875,6 +12485,42 @@ target_link_libraries(hybrid_end2end_test
 endif()
 if(gRPC_BUILD_TESTS)
 
+add_executable(if_test
+  test/core/promise/if_test.cc
+  third_party/googletest/googletest/src/gtest-all.cc
+  third_party/googletest/googlemock/src/gmock-all.cc
+)
+
+target_include_directories(if_test
+  PRIVATE
+    ${CMAKE_CURRENT_SOURCE_DIR}
+    ${CMAKE_CURRENT_SOURCE_DIR}/include
+    ${_gRPC_ADDRESS_SORTING_INCLUDE_DIR}
+    ${_gRPC_RE2_INCLUDE_DIR}
+    ${_gRPC_SSL_INCLUDE_DIR}
+    ${_gRPC_UPB_GENERATED_DIR}
+    ${_gRPC_UPB_GRPC_GENERATED_DIR}
+    ${_gRPC_UPB_INCLUDE_DIR}
+    ${_gRPC_XXHASH_INCLUDE_DIR}
+    ${_gRPC_ZLIB_INCLUDE_DIR}
+    third_party/googletest/googletest/include
+    third_party/googletest/googletest
+    third_party/googletest/googlemock/include
+    third_party/googletest/googlemock
+    ${_gRPC_PROTO_GENS_DIR}
+)
+
+target_link_libraries(if_test
+  ${_gRPC_PROTOBUF_LIBRARIES}
+  ${_gRPC_ALLTARGETS_LIBRARIES}
+  absl::statusor
+  absl::variant
+)
+
+
+endif()
+if(gRPC_BUILD_TESTS)
+
 add_executable(init_test
   test/core/surface/init_test.cc
   third_party/googletest/googletest/src/gtest-all.cc
@@ -12121,13 +12767,13 @@ endif()
 endif()
 if(gRPC_BUILD_TESTS)
 
-add_executable(json_test
-  test/core/json/json_test.cc
+add_executable(join_test
+  test/core/promise/join_test.cc
   third_party/googletest/googletest/src/gtest-all.cc
   third_party/googletest/googlemock/src/gmock-all.cc
 )
 
-target_include_directories(json_test
+target_include_directories(join_test
   PRIVATE
     ${CMAKE_CURRENT_SOURCE_DIR}
     ${CMAKE_CURRENT_SOURCE_DIR}/include
@@ -12146,10 +12792,45 @@ target_include_directories(json_test
     ${_gRPC_PROTO_GENS_DIR}
 )
 
-target_link_libraries(json_test
+target_link_libraries(join_test
   ${_gRPC_PROTOBUF_LIBRARIES}
   ${_gRPC_ALLTARGETS_LIBRARIES}
-  grpc_test_util
+  absl::variant
+)
+
+
+endif()
+if(gRPC_BUILD_TESTS)
+
+add_executable(json_test
+  test/core/json/json_test.cc
+  third_party/googletest/googletest/src/gtest-all.cc
+  third_party/googletest/googlemock/src/gmock-all.cc
+)
+
+target_include_directories(json_test
+  PRIVATE
+    ${CMAKE_CURRENT_SOURCE_DIR}
+    ${CMAKE_CURRENT_SOURCE_DIR}/include
+    ${_gRPC_ADDRESS_SORTING_INCLUDE_DIR}
+    ${_gRPC_RE2_INCLUDE_DIR}
+    ${_gRPC_SSL_INCLUDE_DIR}
+    ${_gRPC_UPB_GENERATED_DIR}
+    ${_gRPC_UPB_GRPC_GENERATED_DIR}
+    ${_gRPC_UPB_INCLUDE_DIR}
+    ${_gRPC_XXHASH_INCLUDE_DIR}
+    ${_gRPC_ZLIB_INCLUDE_DIR}
+    third_party/googletest/googletest/include
+    third_party/googletest/googletest
+    third_party/googletest/googlemock/include
+    third_party/googletest/googlemock
+    ${_gRPC_PROTO_GENS_DIR}
+)
+
+target_link_libraries(json_test
+  ${_gRPC_PROTOBUF_LIBRARIES}
+  ${_gRPC_ALLTARGETS_LIBRARIES}
+  grpc_test_util
 )
 
 
@@ -12193,6 +12874,110 @@ target_link_libraries(large_metadata_bad_client_test
 endif()
 if(gRPC_BUILD_TESTS)
 
+add_executable(latch_test
+  src/core/ext/upb-generated/google/api/annotations.upb.c
+  src/core/ext/upb-generated/google/api/expr/v1alpha1/checked.upb.c
+  src/core/ext/upb-generated/google/api/expr/v1alpha1/syntax.upb.c
+  src/core/ext/upb-generated/google/api/http.upb.c
+  src/core/ext/upb-generated/google/protobuf/any.upb.c
+  src/core/ext/upb-generated/google/protobuf/duration.upb.c
+  src/core/ext/upb-generated/google/protobuf/empty.upb.c
+  src/core/ext/upb-generated/google/protobuf/struct.upb.c
+  src/core/ext/upb-generated/google/protobuf/timestamp.upb.c
+  src/core/ext/upb-generated/google/protobuf/wrappers.upb.c
+  src/core/ext/upb-generated/google/rpc/status.upb.c
+  src/core/lib/gpr/alloc.cc
+  src/core/lib/gpr/atm.cc
+  src/core/lib/gpr/cpu_iphone.cc
+  src/core/lib/gpr/cpu_linux.cc
+  src/core/lib/gpr/cpu_posix.cc
+  src/core/lib/gpr/cpu_windows.cc
+  src/core/lib/gpr/env_linux.cc
+  src/core/lib/gpr/env_posix.cc
+  src/core/lib/gpr/env_windows.cc
+  src/core/lib/gpr/log.cc
+  src/core/lib/gpr/log_android.cc
+  src/core/lib/gpr/log_linux.cc
+  src/core/lib/gpr/log_posix.cc
+  src/core/lib/gpr/log_windows.cc
+  src/core/lib/gpr/murmur_hash.cc
+  src/core/lib/gpr/string.cc
+  src/core/lib/gpr/string_posix.cc
+  src/core/lib/gpr/string_util_windows.cc
+  src/core/lib/gpr/string_windows.cc
+  src/core/lib/gpr/sync.cc
+  src/core/lib/gpr/sync_abseil.cc
+  src/core/lib/gpr/sync_posix.cc
+  src/core/lib/gpr/sync_windows.cc
+  src/core/lib/gpr/time.cc
+  src/core/lib/gpr/time_posix.cc
+  src/core/lib/gpr/time_precise.cc
+  src/core/lib/gpr/time_windows.cc
+  src/core/lib/gpr/tmpfile_msys.cc
+  src/core/lib/gpr/tmpfile_posix.cc
+  src/core/lib/gpr/tmpfile_windows.cc
+  src/core/lib/gpr/wrap_memcpy.cc
+  src/core/lib/gprpp/arena.cc
+  src/core/lib/gprpp/examine_stack.cc
+  src/core/lib/gprpp/fork.cc
+  src/core/lib/gprpp/global_config_env.cc
+  src/core/lib/gprpp/host_port.cc
+  src/core/lib/gprpp/mpscq.cc
+  src/core/lib/gprpp/stat_posix.cc
+  src/core/lib/gprpp/stat_windows.cc
+  src/core/lib/gprpp/status_helper.cc
+  src/core/lib/gprpp/thd_posix.cc
+  src/core/lib/gprpp/thd_windows.cc
+  src/core/lib/gprpp/time_util.cc
+  src/core/lib/profiling/basic_timers.cc
+  src/core/lib/profiling/stap_timers.cc
+  src/core/lib/promise/activity.cc
+  test/core/promise/latch_test.cc
+  third_party/googletest/googletest/src/gtest-all.cc
+  third_party/googletest/googlemock/src/gmock-all.cc
+)
+
+target_include_directories(latch_test
+  PRIVATE
+    ${CMAKE_CURRENT_SOURCE_DIR}
+    ${CMAKE_CURRENT_SOURCE_DIR}/include
+    ${_gRPC_ADDRESS_SORTING_INCLUDE_DIR}
+    ${_gRPC_RE2_INCLUDE_DIR}
+    ${_gRPC_SSL_INCLUDE_DIR}
+    ${_gRPC_UPB_GENERATED_DIR}
+    ${_gRPC_UPB_GRPC_GENERATED_DIR}
+    ${_gRPC_UPB_INCLUDE_DIR}
+    ${_gRPC_XXHASH_INCLUDE_DIR}
+    ${_gRPC_ZLIB_INCLUDE_DIR}
+    third_party/googletest/googletest/include
+    third_party/googletest/googletest
+    third_party/googletest/googlemock/include
+    third_party/googletest/googlemock
+    ${_gRPC_PROTO_GENS_DIR}
+)
+
+target_link_libraries(latch_test
+  ${_gRPC_PROTOBUF_LIBRARIES}
+  ${_gRPC_ALLTARGETS_LIBRARIES}
+  absl::base
+  absl::core_headers
+  absl::memory
+  absl::status
+  absl::statusor
+  absl::cord
+  absl::str_format
+  absl::strings
+  absl::synchronization
+  absl::time
+  absl::optional
+  absl::variant
+  upb
+)
+
+
+endif()
+if(gRPC_BUILD_TESTS)
+
 add_executable(lb_get_cpu_stats_test
   src/cpp/server/load_reporter/get_cpu_stats_linux.cc
   src/cpp/server/load_reporter/get_cpu_stats_macos.cc
@@ -12340,6 +13125,41 @@ target_link_libraries(log_test
 endif()
 if(gRPC_BUILD_TESTS)
 
+add_executable(loop_test
+  test/core/promise/loop_test.cc
+  third_party/googletest/googletest/src/gtest-all.cc
+  third_party/googletest/googlemock/src/gmock-all.cc
+)
+
+target_include_directories(loop_test
+  PRIVATE
+    ${CMAKE_CURRENT_SOURCE_DIR}
+    ${CMAKE_CURRENT_SOURCE_DIR}/include
+    ${_gRPC_ADDRESS_SORTING_INCLUDE_DIR}
+    ${_gRPC_RE2_INCLUDE_DIR}
+    ${_gRPC_SSL_INCLUDE_DIR}
+    ${_gRPC_UPB_GENERATED_DIR}
+    ${_gRPC_UPB_GRPC_GENERATED_DIR}
+    ${_gRPC_UPB_INCLUDE_DIR}
+    ${_gRPC_XXHASH_INCLUDE_DIR}
+    ${_gRPC_ZLIB_INCLUDE_DIR}
+    third_party/googletest/googletest/include
+    third_party/googletest/googletest
+    third_party/googletest/googlemock/include
+    third_party/googletest/googlemock
+    ${_gRPC_PROTO_GENS_DIR}
+)
+
+target_link_libraries(loop_test
+  ${_gRPC_PROTOBUF_LIBRARIES}
+  ${_gRPC_ALLTARGETS_LIBRARIES}
+  absl::variant
+)
+
+
+endif()
+if(gRPC_BUILD_TESTS)
+
 add_executable(match_test
   test/core/gprpp/match_test.cc
   third_party/googletest/googletest/src/gtest-all.cc
@@ -12458,6 +13278,40 @@ target_link_libraries(message_allocator_end2end_test
 endif()
 if(gRPC_BUILD_TESTS)
 
+add_executable(miscompile_with_no_unique_address_test
+  test/core/compiler_bugs/miscompile_with_no_unique_address_test.cc
+  third_party/googletest/googletest/src/gtest-all.cc
+  third_party/googletest/googlemock/src/gmock-all.cc
+)
+
+target_include_directories(miscompile_with_no_unique_address_test
+  PRIVATE
+    ${CMAKE_CURRENT_SOURCE_DIR}
+    ${CMAKE_CURRENT_SOURCE_DIR}/include
+    ${_gRPC_ADDRESS_SORTING_INCLUDE_DIR}
+    ${_gRPC_RE2_INCLUDE_DIR}
+    ${_gRPC_SSL_INCLUDE_DIR}
+    ${_gRPC_UPB_GENERATED_DIR}
+    ${_gRPC_UPB_GRPC_GENERATED_DIR}
+    ${_gRPC_UPB_INCLUDE_DIR}
+    ${_gRPC_XXHASH_INCLUDE_DIR}
+    ${_gRPC_ZLIB_INCLUDE_DIR}
+    third_party/googletest/googletest/include
+    third_party/googletest/googletest
+    third_party/googletest/googlemock/include
+    third_party/googletest/googlemock
+    ${_gRPC_PROTO_GENS_DIR}
+)
+
+target_link_libraries(miscompile_with_no_unique_address_test
+  ${_gRPC_PROTOBUF_LIBRARIES}
+  ${_gRPC_ALLTARGETS_LIBRARIES}
+)
+
+
+endif()
+if(gRPC_BUILD_TESTS)
+
 add_executable(mock_stream_test
   ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/echo.pb.cc
   ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/echo.grpc.pb.cc
@@ -12576,7 +13430,381 @@ add_executable(nonblocking_test
   third_party/googletest/googlemock/src/gmock-all.cc
 )
 
-target_include_directories(nonblocking_test
+target_include_directories(nonblocking_test
+  PRIVATE
+    ${CMAKE_CURRENT_SOURCE_DIR}
+    ${CMAKE_CURRENT_SOURCE_DIR}/include
+    ${_gRPC_ADDRESS_SORTING_INCLUDE_DIR}
+    ${_gRPC_RE2_INCLUDE_DIR}
+    ${_gRPC_SSL_INCLUDE_DIR}
+    ${_gRPC_UPB_GENERATED_DIR}
+    ${_gRPC_UPB_GRPC_GENERATED_DIR}
+    ${_gRPC_UPB_INCLUDE_DIR}
+    ${_gRPC_XXHASH_INCLUDE_DIR}
+    ${_gRPC_ZLIB_INCLUDE_DIR}
+    third_party/googletest/googletest/include
+    third_party/googletest/googletest
+    third_party/googletest/googlemock/include
+    third_party/googletest/googlemock
+    ${_gRPC_PROTO_GENS_DIR}
+)
+
+target_link_libraries(nonblocking_test
+  ${_gRPC_PROTOBUF_LIBRARIES}
+  ${_gRPC_ALLTARGETS_LIBRARIES}
+  grpc++_test_util
+)
+
+
+endif()
+if(gRPC_BUILD_TESTS)
+
+add_executable(noop-benchmark
+  test/cpp/microbenchmarks/noop-benchmark.cc
+  third_party/googletest/googletest/src/gtest-all.cc
+  third_party/googletest/googlemock/src/gmock-all.cc
+)
+
+target_include_directories(noop-benchmark
+  PRIVATE
+    ${CMAKE_CURRENT_SOURCE_DIR}
+    ${CMAKE_CURRENT_SOURCE_DIR}/include
+    ${_gRPC_ADDRESS_SORTING_INCLUDE_DIR}
+    ${_gRPC_RE2_INCLUDE_DIR}
+    ${_gRPC_SSL_INCLUDE_DIR}
+    ${_gRPC_UPB_GENERATED_DIR}
+    ${_gRPC_UPB_GRPC_GENERATED_DIR}
+    ${_gRPC_UPB_INCLUDE_DIR}
+    ${_gRPC_XXHASH_INCLUDE_DIR}
+    ${_gRPC_ZLIB_INCLUDE_DIR}
+    third_party/googletest/googletest/include
+    third_party/googletest/googletest
+    third_party/googletest/googlemock/include
+    third_party/googletest/googlemock
+    ${_gRPC_PROTO_GENS_DIR}
+)
+
+target_link_libraries(noop-benchmark
+  ${_gRPC_PROTOBUF_LIBRARIES}
+  ${_gRPC_ALLTARGETS_LIBRARIES}
+  ${_gRPC_BENCHMARK_LIBRARIES}
+  grpc_test_util
+)
+
+
+endif()
+if(gRPC_BUILD_TESTS)
+
+add_executable(observable_test
+  src/core/ext/upb-generated/google/api/annotations.upb.c
+  src/core/ext/upb-generated/google/api/expr/v1alpha1/checked.upb.c
+  src/core/ext/upb-generated/google/api/expr/v1alpha1/syntax.upb.c
+  src/core/ext/upb-generated/google/api/http.upb.c
+  src/core/ext/upb-generated/google/protobuf/any.upb.c
+  src/core/ext/upb-generated/google/protobuf/duration.upb.c
+  src/core/ext/upb-generated/google/protobuf/empty.upb.c
+  src/core/ext/upb-generated/google/protobuf/struct.upb.c
+  src/core/ext/upb-generated/google/protobuf/timestamp.upb.c
+  src/core/ext/upb-generated/google/protobuf/wrappers.upb.c
+  src/core/ext/upb-generated/google/rpc/status.upb.c
+  src/core/lib/gpr/alloc.cc
+  src/core/lib/gpr/atm.cc
+  src/core/lib/gpr/cpu_iphone.cc
+  src/core/lib/gpr/cpu_linux.cc
+  src/core/lib/gpr/cpu_posix.cc
+  src/core/lib/gpr/cpu_windows.cc
+  src/core/lib/gpr/env_linux.cc
+  src/core/lib/gpr/env_posix.cc
+  src/core/lib/gpr/env_windows.cc
+  src/core/lib/gpr/log.cc
+  src/core/lib/gpr/log_android.cc
+  src/core/lib/gpr/log_linux.cc
+  src/core/lib/gpr/log_posix.cc
+  src/core/lib/gpr/log_windows.cc
+  src/core/lib/gpr/murmur_hash.cc
+  src/core/lib/gpr/string.cc
+  src/core/lib/gpr/string_posix.cc
+  src/core/lib/gpr/string_util_windows.cc
+  src/core/lib/gpr/string_windows.cc
+  src/core/lib/gpr/sync.cc
+  src/core/lib/gpr/sync_abseil.cc
+  src/core/lib/gpr/sync_posix.cc
+  src/core/lib/gpr/sync_windows.cc
+  src/core/lib/gpr/time.cc
+  src/core/lib/gpr/time_posix.cc
+  src/core/lib/gpr/time_precise.cc
+  src/core/lib/gpr/time_windows.cc
+  src/core/lib/gpr/tmpfile_msys.cc
+  src/core/lib/gpr/tmpfile_posix.cc
+  src/core/lib/gpr/tmpfile_windows.cc
+  src/core/lib/gpr/wrap_memcpy.cc
+  src/core/lib/gprpp/arena.cc
+  src/core/lib/gprpp/examine_stack.cc
+  src/core/lib/gprpp/fork.cc
+  src/core/lib/gprpp/global_config_env.cc
+  src/core/lib/gprpp/host_port.cc
+  src/core/lib/gprpp/mpscq.cc
+  src/core/lib/gprpp/stat_posix.cc
+  src/core/lib/gprpp/stat_windows.cc
+  src/core/lib/gprpp/status_helper.cc
+  src/core/lib/gprpp/thd_posix.cc
+  src/core/lib/gprpp/thd_windows.cc
+  src/core/lib/gprpp/time_util.cc
+  src/core/lib/profiling/basic_timers.cc
+  src/core/lib/profiling/stap_timers.cc
+  src/core/lib/promise/activity.cc
+  test/core/promise/observable_test.cc
+  third_party/googletest/googletest/src/gtest-all.cc
+  third_party/googletest/googlemock/src/gmock-all.cc
+)
+
+target_include_directories(observable_test
+  PRIVATE
+    ${CMAKE_CURRENT_SOURCE_DIR}
+    ${CMAKE_CURRENT_SOURCE_DIR}/include
+    ${_gRPC_ADDRESS_SORTING_INCLUDE_DIR}
+    ${_gRPC_RE2_INCLUDE_DIR}
+    ${_gRPC_SSL_INCLUDE_DIR}
+    ${_gRPC_UPB_GENERATED_DIR}
+    ${_gRPC_UPB_GRPC_GENERATED_DIR}
+    ${_gRPC_UPB_INCLUDE_DIR}
+    ${_gRPC_XXHASH_INCLUDE_DIR}
+    ${_gRPC_ZLIB_INCLUDE_DIR}
+    third_party/googletest/googletest/include
+    third_party/googletest/googletest
+    third_party/googletest/googlemock/include
+    third_party/googletest/googlemock
+    ${_gRPC_PROTO_GENS_DIR}
+)
+
+target_link_libraries(observable_test
+  ${_gRPC_PROTOBUF_LIBRARIES}
+  ${_gRPC_ALLTARGETS_LIBRARIES}
+  absl::base
+  absl::core_headers
+  absl::flat_hash_set
+  absl::memory
+  absl::status
+  absl::statusor
+  absl::cord
+  absl::str_format
+  absl::strings
+  absl::synchronization
+  absl::time
+  absl::optional
+  absl::variant
+  upb
+)
+
+
+endif()
+if(gRPC_BUILD_TESTS)
+
+add_executable(orphanable_test
+  test/core/gprpp/orphanable_test.cc
+  third_party/googletest/googletest/src/gtest-all.cc
+  third_party/googletest/googlemock/src/gmock-all.cc
+)
+
+target_include_directories(orphanable_test
+  PRIVATE
+    ${CMAKE_CURRENT_SOURCE_DIR}
+    ${CMAKE_CURRENT_SOURCE_DIR}/include
+    ${_gRPC_ADDRESS_SORTING_INCLUDE_DIR}
+    ${_gRPC_RE2_INCLUDE_DIR}
+    ${_gRPC_SSL_INCLUDE_DIR}
+    ${_gRPC_UPB_GENERATED_DIR}
+    ${_gRPC_UPB_GRPC_GENERATED_DIR}
+    ${_gRPC_UPB_INCLUDE_DIR}
+    ${_gRPC_XXHASH_INCLUDE_DIR}
+    ${_gRPC_ZLIB_INCLUDE_DIR}
+    third_party/googletest/googletest/include
+    third_party/googletest/googletest
+    third_party/googletest/googlemock/include
+    third_party/googletest/googlemock
+    ${_gRPC_PROTO_GENS_DIR}
+)
+
+target_link_libraries(orphanable_test
+  ${_gRPC_PROTOBUF_LIBRARIES}
+  ${_gRPC_ALLTARGETS_LIBRARIES}
+  grpc_test_util
+)
+
+
+endif()
+if(gRPC_BUILD_TESTS)
+
+add_executable(out_of_bounds_bad_client_test
+  test/core/bad_client/bad_client.cc
+  test/core/bad_client/tests/out_of_bounds.cc
+  test/core/end2end/cq_verifier.cc
+  third_party/googletest/googletest/src/gtest-all.cc
+  third_party/googletest/googlemock/src/gmock-all.cc
+)
+
+target_include_directories(out_of_bounds_bad_client_test
+  PRIVATE
+    ${CMAKE_CURRENT_SOURCE_DIR}
+    ${CMAKE_CURRENT_SOURCE_DIR}/include
+    ${_gRPC_ADDRESS_SORTING_INCLUDE_DIR}
+    ${_gRPC_RE2_INCLUDE_DIR}
+    ${_gRPC_SSL_INCLUDE_DIR}
+    ${_gRPC_UPB_GENERATED_DIR}
+    ${_gRPC_UPB_GRPC_GENERATED_DIR}
+    ${_gRPC_UPB_INCLUDE_DIR}
+    ${_gRPC_XXHASH_INCLUDE_DIR}
+    ${_gRPC_ZLIB_INCLUDE_DIR}
+    third_party/googletest/googletest/include
+    third_party/googletest/googletest
+    third_party/googletest/googlemock/include
+    third_party/googletest/googlemock
+    ${_gRPC_PROTO_GENS_DIR}
+)
+
+target_link_libraries(out_of_bounds_bad_client_test
+  ${_gRPC_PROTOBUF_LIBRARIES}
+  ${_gRPC_ALLTARGETS_LIBRARIES}
+  grpc_test_util
+)
+
+
+endif()
+if(gRPC_BUILD_TESTS)
+
+add_executable(overload_test
+  test/core/gprpp/overload_test.cc
+  third_party/googletest/googletest/src/gtest-all.cc
+  third_party/googletest/googlemock/src/gmock-all.cc
+)
+
+target_include_directories(overload_test
+  PRIVATE
+    ${CMAKE_CURRENT_SOURCE_DIR}
+    ${CMAKE_CURRENT_SOURCE_DIR}/include
+    ${_gRPC_ADDRESS_SORTING_INCLUDE_DIR}
+    ${_gRPC_RE2_INCLUDE_DIR}
+    ${_gRPC_SSL_INCLUDE_DIR}
+    ${_gRPC_UPB_GENERATED_DIR}
+    ${_gRPC_UPB_GRPC_GENERATED_DIR}
+    ${_gRPC_UPB_INCLUDE_DIR}
+    ${_gRPC_XXHASH_INCLUDE_DIR}
+    ${_gRPC_ZLIB_INCLUDE_DIR}
+    third_party/googletest/googletest/include
+    third_party/googletest/googletest
+    third_party/googletest/googlemock/include
+    third_party/googletest/googlemock
+    ${_gRPC_PROTO_GENS_DIR}
+)
+
+target_link_libraries(overload_test
+  ${_gRPC_PROTOBUF_LIBRARIES}
+  ${_gRPC_ALLTARGETS_LIBRARIES}
+)
+
+
+endif()
+if(gRPC_BUILD_TESTS)
+
+add_executable(pid_controller_test
+  test/core/transport/pid_controller_test.cc
+  third_party/googletest/googletest/src/gtest-all.cc
+  third_party/googletest/googlemock/src/gmock-all.cc
+)
+
+target_include_directories(pid_controller_test
+  PRIVATE
+    ${CMAKE_CURRENT_SOURCE_DIR}
+    ${CMAKE_CURRENT_SOURCE_DIR}/include
+    ${_gRPC_ADDRESS_SORTING_INCLUDE_DIR}
+    ${_gRPC_RE2_INCLUDE_DIR}
+    ${_gRPC_SSL_INCLUDE_DIR}
+    ${_gRPC_UPB_GENERATED_DIR}
+    ${_gRPC_UPB_GRPC_GENERATED_DIR}
+    ${_gRPC_UPB_INCLUDE_DIR}
+    ${_gRPC_XXHASH_INCLUDE_DIR}
+    ${_gRPC_ZLIB_INCLUDE_DIR}
+    third_party/googletest/googletest/include
+    third_party/googletest/googletest
+    third_party/googletest/googlemock/include
+    third_party/googletest/googlemock
+    ${_gRPC_PROTO_GENS_DIR}
+)
+
+target_link_libraries(pid_controller_test
+  ${_gRPC_PROTOBUF_LIBRARIES}
+  ${_gRPC_ALLTARGETS_LIBRARIES}
+  grpc_test_util
+)
+
+
+endif()
+if(gRPC_BUILD_TESTS)
+
+add_executable(pipe_test
+  src/core/ext/upb-generated/google/api/annotations.upb.c
+  src/core/ext/upb-generated/google/api/expr/v1alpha1/checked.upb.c
+  src/core/ext/upb-generated/google/api/expr/v1alpha1/syntax.upb.c
+  src/core/ext/upb-generated/google/api/http.upb.c
+  src/core/ext/upb-generated/google/protobuf/any.upb.c
+  src/core/ext/upb-generated/google/protobuf/duration.upb.c
+  src/core/ext/upb-generated/google/protobuf/empty.upb.c
+  src/core/ext/upb-generated/google/protobuf/struct.upb.c
+  src/core/ext/upb-generated/google/protobuf/timestamp.upb.c
+  src/core/ext/upb-generated/google/protobuf/wrappers.upb.c
+  src/core/ext/upb-generated/google/rpc/status.upb.c
+  src/core/lib/gpr/alloc.cc
+  src/core/lib/gpr/atm.cc
+  src/core/lib/gpr/cpu_iphone.cc
+  src/core/lib/gpr/cpu_linux.cc
+  src/core/lib/gpr/cpu_posix.cc
+  src/core/lib/gpr/cpu_windows.cc
+  src/core/lib/gpr/env_linux.cc
+  src/core/lib/gpr/env_posix.cc
+  src/core/lib/gpr/env_windows.cc
+  src/core/lib/gpr/log.cc
+  src/core/lib/gpr/log_android.cc
+  src/core/lib/gpr/log_linux.cc
+  src/core/lib/gpr/log_posix.cc
+  src/core/lib/gpr/log_windows.cc
+  src/core/lib/gpr/murmur_hash.cc
+  src/core/lib/gpr/string.cc
+  src/core/lib/gpr/string_posix.cc
+  src/core/lib/gpr/string_util_windows.cc
+  src/core/lib/gpr/string_windows.cc
+  src/core/lib/gpr/sync.cc
+  src/core/lib/gpr/sync_abseil.cc
+  src/core/lib/gpr/sync_posix.cc
+  src/core/lib/gpr/sync_windows.cc
+  src/core/lib/gpr/time.cc
+  src/core/lib/gpr/time_posix.cc
+  src/core/lib/gpr/time_precise.cc
+  src/core/lib/gpr/time_windows.cc
+  src/core/lib/gpr/tmpfile_msys.cc
+  src/core/lib/gpr/tmpfile_posix.cc
+  src/core/lib/gpr/tmpfile_windows.cc
+  src/core/lib/gpr/wrap_memcpy.cc
+  src/core/lib/gprpp/arena.cc
+  src/core/lib/gprpp/examine_stack.cc
+  src/core/lib/gprpp/fork.cc
+  src/core/lib/gprpp/global_config_env.cc
+  src/core/lib/gprpp/host_port.cc
+  src/core/lib/gprpp/mpscq.cc
+  src/core/lib/gprpp/stat_posix.cc
+  src/core/lib/gprpp/stat_windows.cc
+  src/core/lib/gprpp/status_helper.cc
+  src/core/lib/gprpp/thd_posix.cc
+  src/core/lib/gprpp/thd_windows.cc
+  src/core/lib/gprpp/time_util.cc
+  src/core/lib/profiling/basic_timers.cc
+  src/core/lib/profiling/stap_timers.cc
+  src/core/lib/promise/activity.cc
+  test/core/promise/pipe_test.cc
+  third_party/googletest/googletest/src/gtest-all.cc
+  third_party/googletest/googlemock/src/gmock-all.cc
+)
+
+target_include_directories(pipe_test
   PRIVATE
     ${CMAKE_CURRENT_SOURCE_DIR}
     ${CMAKE_CURRENT_SOURCE_DIR}/include
@@ -12595,23 +13823,35 @@ target_include_directories(nonblocking_test
     ${_gRPC_PROTO_GENS_DIR}
 )
 
-target_link_libraries(nonblocking_test
+target_link_libraries(pipe_test
   ${_gRPC_PROTOBUF_LIBRARIES}
   ${_gRPC_ALLTARGETS_LIBRARIES}
-  grpc++_test_util
+  absl::base
+  absl::core_headers
+  absl::memory
+  absl::status
+  absl::statusor
+  absl::cord
+  absl::str_format
+  absl::strings
+  absl::synchronization
+  absl::time
+  absl::optional
+  absl::variant
+  upb
 )
 
 
 endif()
 if(gRPC_BUILD_TESTS)
 
-add_executable(noop-benchmark
-  test/cpp/microbenchmarks/noop-benchmark.cc
+add_executable(poll_test
+  test/core/promise/poll_test.cc
   third_party/googletest/googletest/src/gtest-all.cc
   third_party/googletest/googlemock/src/gmock-all.cc
 )
 
-target_include_directories(noop-benchmark
+target_include_directories(poll_test
   PRIVATE
     ${CMAKE_CURRENT_SOURCE_DIR}
     ${CMAKE_CURRENT_SOURCE_DIR}/include
@@ -12630,24 +13870,23 @@ target_include_directories(noop-benchmark
     ${_gRPC_PROTO_GENS_DIR}
 )
 
-target_link_libraries(noop-benchmark
+target_link_libraries(poll_test
   ${_gRPC_PROTOBUF_LIBRARIES}
   ${_gRPC_ALLTARGETS_LIBRARIES}
-  ${_gRPC_BENCHMARK_LIBRARIES}
-  grpc_test_util
+  absl::variant
 )
 
 
 endif()
 if(gRPC_BUILD_TESTS)
 
-add_executable(orphanable_test
-  test/core/gprpp/orphanable_test.cc
+add_executable(popularity_count_test
+  test/core/transport/chttp2/popularity_count_test.cc
   third_party/googletest/googletest/src/gtest-all.cc
   third_party/googletest/googlemock/src/gmock-all.cc
 )
 
-target_include_directories(orphanable_test
+target_include_directories(popularity_count_test
   PRIVATE
     ${CMAKE_CURRENT_SOURCE_DIR}
     ${CMAKE_CURRENT_SOURCE_DIR}/include
@@ -12666,25 +13905,35 @@ target_include_directories(orphanable_test
     ${_gRPC_PROTO_GENS_DIR}
 )
 
-target_link_libraries(orphanable_test
+target_link_libraries(popularity_count_test
   ${_gRPC_PROTOBUF_LIBRARIES}
   ${_gRPC_ALLTARGETS_LIBRARIES}
-  grpc_test_util
 )
 
 
 endif()
 if(gRPC_BUILD_TESTS)
 
-add_executable(out_of_bounds_bad_client_test
-  test/core/bad_client/bad_client.cc
-  test/core/bad_client/tests/out_of_bounds.cc
-  test/core/end2end/cq_verifier.cc
+add_executable(port_sharing_end2end_test
+  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/echo.pb.cc
+  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/echo.grpc.pb.cc
+  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/echo.pb.h
+  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/echo.grpc.pb.h
+  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/echo_messages.pb.cc
+  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/echo_messages.grpc.pb.cc
+  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/echo_messages.pb.h
+  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/echo_messages.grpc.pb.h
+  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/simple_messages.pb.cc
+  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/simple_messages.grpc.pb.cc
+  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/simple_messages.pb.h
+  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/simple_messages.grpc.pb.h
+  test/cpp/end2end/port_sharing_end2end_test.cc
+  test/cpp/end2end/test_service_impl.cc
   third_party/googletest/googletest/src/gtest-all.cc
   third_party/googletest/googlemock/src/gmock-all.cc
 )
 
-target_include_directories(out_of_bounds_bad_client_test
+target_include_directories(port_sharing_end2end_test
   PRIVATE
     ${CMAKE_CURRENT_SOURCE_DIR}
     ${CMAKE_CURRENT_SOURCE_DIR}/include
@@ -12703,23 +13952,23 @@ target_include_directories(out_of_bounds_bad_client_test
     ${_gRPC_PROTO_GENS_DIR}
 )
 
-target_link_libraries(out_of_bounds_bad_client_test
+target_link_libraries(port_sharing_end2end_test
   ${_gRPC_PROTOBUF_LIBRARIES}
   ${_gRPC_ALLTARGETS_LIBRARIES}
-  grpc_test_util
+  grpc++_test_util
 )
 
 
 endif()
 if(gRPC_BUILD_TESTS)
 
-add_executable(overload_test
-  test/core/gprpp/overload_test.cc
+add_executable(promise_factory_test
+  test/core/promise/promise_factory_test.cc
   third_party/googletest/googletest/src/gtest-all.cc
   third_party/googletest/googlemock/src/gmock-all.cc
 )
 
-target_include_directories(overload_test
+target_include_directories(promise_factory_test
   PRIVATE
     ${CMAKE_CURRENT_SOURCE_DIR}
     ${CMAKE_CURRENT_SOURCE_DIR}/include
@@ -12738,22 +13987,26 @@ target_include_directories(overload_test
     ${_gRPC_PROTO_GENS_DIR}
 )
 
-target_link_libraries(overload_test
+target_link_libraries(promise_factory_test
   ${_gRPC_PROTOBUF_LIBRARIES}
   ${_gRPC_ALLTARGETS_LIBRARIES}
+  absl::bind_front
+  absl::optional
+  absl::variant
+  absl::utility
 )
 
 
 endif()
 if(gRPC_BUILD_TESTS)
 
-add_executable(pid_controller_test
-  test/core/transport/pid_controller_test.cc
+add_executable(promise_map_test
+  test/core/promise/map_test.cc
   third_party/googletest/googletest/src/gtest-all.cc
   third_party/googletest/googlemock/src/gmock-all.cc
 )
 
-target_include_directories(pid_controller_test
+target_include_directories(promise_map_test
   PRIVATE
     ${CMAKE_CURRENT_SOURCE_DIR}
     ${CMAKE_CURRENT_SOURCE_DIR}/include
@@ -12772,36 +14025,24 @@ target_include_directories(pid_controller_test
     ${_gRPC_PROTO_GENS_DIR}
 )
 
-target_link_libraries(pid_controller_test
+target_link_libraries(promise_map_test
   ${_gRPC_PROTOBUF_LIBRARIES}
   ${_gRPC_ALLTARGETS_LIBRARIES}
-  grpc_test_util
+  absl::optional
+  absl::variant
 )
 
 
 endif()
 if(gRPC_BUILD_TESTS)
 
-add_executable(port_sharing_end2end_test
-  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/echo.pb.cc
-  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/echo.grpc.pb.cc
-  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/echo.pb.h
-  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/echo.grpc.pb.h
-  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/echo_messages.pb.cc
-  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/echo_messages.grpc.pb.cc
-  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/echo_messages.pb.h
-  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/echo_messages.grpc.pb.h
-  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/simple_messages.pb.cc
-  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/simple_messages.grpc.pb.cc
-  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/simple_messages.pb.h
-  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/simple_messages.grpc.pb.h
-  test/cpp/end2end/port_sharing_end2end_test.cc
-  test/cpp/end2end/test_service_impl.cc
+add_executable(promise_test
+  test/core/promise/promise_test.cc
   third_party/googletest/googletest/src/gtest-all.cc
   third_party/googletest/googlemock/src/gmock-all.cc
 )
 
-target_include_directories(port_sharing_end2end_test
+target_include_directories(promise_test
   PRIVATE
     ${CMAKE_CURRENT_SOURCE_DIR}
     ${CMAKE_CURRENT_SOURCE_DIR}/include
@@ -12820,10 +14061,11 @@ target_include_directories(port_sharing_end2end_test
     ${_gRPC_PROTO_GENS_DIR}
 )
 
-target_link_libraries(port_sharing_end2end_test
+target_link_libraries(promise_test
   ${_gRPC_PROTOBUF_LIBRARIES}
   ${_gRPC_ALLTARGETS_LIBRARIES}
-  grpc++_test_util
+  absl::optional
+  absl::variant
 )
 
 
@@ -13076,6 +14318,41 @@ target_link_libraries(qps_worker
 endif()
 if(gRPC_BUILD_TESTS)
 
+add_executable(race_test
+  test/core/promise/race_test.cc
+  third_party/googletest/googletest/src/gtest-all.cc
+  third_party/googletest/googlemock/src/gmock-all.cc
+)
+
+target_include_directories(race_test
+  PRIVATE
+    ${CMAKE_CURRENT_SOURCE_DIR}
+    ${CMAKE_CURRENT_SOURCE_DIR}/include
+    ${_gRPC_ADDRESS_SORTING_INCLUDE_DIR}
+    ${_gRPC_RE2_INCLUDE_DIR}
+    ${_gRPC_SSL_INCLUDE_DIR}
+    ${_gRPC_UPB_GENERATED_DIR}
+    ${_gRPC_UPB_GRPC_GENERATED_DIR}
+    ${_gRPC_UPB_INCLUDE_DIR}
+    ${_gRPC_XXHASH_INCLUDE_DIR}
+    ${_gRPC_ZLIB_INCLUDE_DIR}
+    third_party/googletest/googletest/include
+    third_party/googletest/googletest
+    third_party/googletest/googlemock/include
+    third_party/googletest/googlemock
+    ${_gRPC_PROTO_GENS_DIR}
+)
+
+target_link_libraries(race_test
+  ${_gRPC_PROTOBUF_LIBRARIES}
+  ${_gRPC_ALLTARGETS_LIBRARIES}
+  absl::variant
+)
+
+
+endif()
+if(gRPC_BUILD_TESTS)
+
 add_executable(raw_end2end_test
   ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/duplicate/echo_duplicate.pb.cc
   ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/duplicate/echo_duplicate.grpc.pb.cc
@@ -13209,7 +14486,133 @@ add_executable(ref_counted_test
   third_party/googletest/googlemock/src/gmock-all.cc
 )
 
-target_include_directories(ref_counted_test
+target_include_directories(ref_counted_test
+  PRIVATE
+    ${CMAKE_CURRENT_SOURCE_DIR}
+    ${CMAKE_CURRENT_SOURCE_DIR}/include
+    ${_gRPC_ADDRESS_SORTING_INCLUDE_DIR}
+    ${_gRPC_RE2_INCLUDE_DIR}
+    ${_gRPC_SSL_INCLUDE_DIR}
+    ${_gRPC_UPB_GENERATED_DIR}
+    ${_gRPC_UPB_GRPC_GENERATED_DIR}
+    ${_gRPC_UPB_INCLUDE_DIR}
+    ${_gRPC_XXHASH_INCLUDE_DIR}
+    ${_gRPC_ZLIB_INCLUDE_DIR}
+    third_party/googletest/googletest/include
+    third_party/googletest/googletest
+    third_party/googletest/googlemock/include
+    third_party/googletest/googlemock
+    ${_gRPC_PROTO_GENS_DIR}
+)
+
+target_link_libraries(ref_counted_test
+  ${_gRPC_PROTOBUF_LIBRARIES}
+  ${_gRPC_ALLTARGETS_LIBRARIES}
+  grpc_test_util
+)
+
+
+endif()
+if(gRPC_BUILD_TESTS)
+if(_gRPC_PLATFORM_LINUX OR _gRPC_PLATFORM_MAC OR _gRPC_PLATFORM_POSIX)
+
+  add_executable(remove_stream_from_stalled_lists_test
+    test/core/transport/chttp2/remove_stream_from_stalled_lists_test.cc
+    third_party/googletest/googletest/src/gtest-all.cc
+    third_party/googletest/googlemock/src/gmock-all.cc
+  )
+
+  target_include_directories(remove_stream_from_stalled_lists_test
+    PRIVATE
+      ${CMAKE_CURRENT_SOURCE_DIR}
+      ${CMAKE_CURRENT_SOURCE_DIR}/include
+      ${_gRPC_ADDRESS_SORTING_INCLUDE_DIR}
+      ${_gRPC_RE2_INCLUDE_DIR}
+      ${_gRPC_SSL_INCLUDE_DIR}
+      ${_gRPC_UPB_GENERATED_DIR}
+      ${_gRPC_UPB_GRPC_GENERATED_DIR}
+      ${_gRPC_UPB_INCLUDE_DIR}
+      ${_gRPC_XXHASH_INCLUDE_DIR}
+      ${_gRPC_ZLIB_INCLUDE_DIR}
+      third_party/googletest/googletest/include
+      third_party/googletest/googletest
+      third_party/googletest/googlemock/include
+      third_party/googletest/googlemock
+      ${_gRPC_PROTO_GENS_DIR}
+  )
+
+  target_link_libraries(remove_stream_from_stalled_lists_test
+    ${_gRPC_PROTOBUF_LIBRARIES}
+    ${_gRPC_ALLTARGETS_LIBRARIES}
+    grpc_test_util
+  )
+
+
+endif()
+endif()
+if(gRPC_BUILD_TESTS)
+
+add_executable(retry_throttle_test
+  test/core/client_channel/retry_throttle_test.cc
+  third_party/googletest/googletest/src/gtest-all.cc
+  third_party/googletest/googlemock/src/gmock-all.cc
+)
+
+target_include_directories(retry_throttle_test
+  PRIVATE
+    ${CMAKE_CURRENT_SOURCE_DIR}
+    ${CMAKE_CURRENT_SOURCE_DIR}/include
+    ${_gRPC_ADDRESS_SORTING_INCLUDE_DIR}
+    ${_gRPC_RE2_INCLUDE_DIR}
+    ${_gRPC_SSL_INCLUDE_DIR}
+    ${_gRPC_UPB_GENERATED_DIR}
+    ${_gRPC_UPB_GRPC_GENERATED_DIR}
+    ${_gRPC_UPB_INCLUDE_DIR}
+    ${_gRPC_XXHASH_INCLUDE_DIR}
+    ${_gRPC_ZLIB_INCLUDE_DIR}
+    third_party/googletest/googletest/include
+    third_party/googletest/googletest
+    third_party/googletest/googlemock/include
+    third_party/googletest/googlemock
+    ${_gRPC_PROTO_GENS_DIR}
+)
+
+target_link_libraries(retry_throttle_test
+  ${_gRPC_PROTOBUF_LIBRARIES}
+  ${_gRPC_ALLTARGETS_LIBRARIES}
+  grpc_test_util
+)
+
+
+endif()
+if(gRPC_BUILD_TESTS)
+
+add_executable(sdk_authz_end2end_test
+  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/echo.pb.cc
+  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/echo.grpc.pb.cc
+  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/echo.pb.h
+  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/echo.grpc.pb.h
+  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/echo_messages.pb.cc
+  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/echo_messages.grpc.pb.cc
+  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/echo_messages.pb.h
+  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/echo_messages.grpc.pb.h
+  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/simple_messages.pb.cc
+  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/simple_messages.grpc.pb.cc
+  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/simple_messages.pb.h
+  ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/simple_messages.grpc.pb.h
+  src/core/lib/security/authorization/grpc_authorization_engine.cc
+  src/core/lib/security/authorization/grpc_authorization_policy_provider.cc
+  src/core/lib/security/authorization/matchers.cc
+  src/core/lib/security/authorization/rbac_policy.cc
+  src/core/lib/security/authorization/rbac_translator.cc
+  src/cpp/server/authorization_policy_provider.cc
+  test/cpp/end2end/sdk_authz_end2end_test.cc
+  test/cpp/end2end/test_service_impl.cc
+  third_party/googletest/googletest/src/gtest-all.cc
+  third_party/googletest/googlemock/src/gmock-all.cc
+)
+
+target_include_directories(sdk_authz_end2end_test
   PRIVATE
     ${CMAKE_CURRENT_SOURCE_DIR}
     ${CMAKE_CURRENT_SOURCE_DIR}/include
@@ -13228,60 +14631,23 @@ target_include_directories(ref_counted_test
     ${_gRPC_PROTO_GENS_DIR}
 )
 
-target_link_libraries(ref_counted_test
+target_link_libraries(sdk_authz_end2end_test
   ${_gRPC_PROTOBUF_LIBRARIES}
   ${_gRPC_ALLTARGETS_LIBRARIES}
-  grpc_test_util
+  grpc++_test_util
 )
 
 
 endif()
 if(gRPC_BUILD_TESTS)
-if(_gRPC_PLATFORM_LINUX OR _gRPC_PLATFORM_MAC OR _gRPC_PLATFORM_POSIX)
-
-  add_executable(remove_stream_from_stalled_lists_test
-    test/core/transport/chttp2/remove_stream_from_stalled_lists_test.cc
-    third_party/googletest/googletest/src/gtest-all.cc
-    third_party/googletest/googlemock/src/gmock-all.cc
-  )
-
-  target_include_directories(remove_stream_from_stalled_lists_test
-    PRIVATE
-      ${CMAKE_CURRENT_SOURCE_DIR}
-      ${CMAKE_CURRENT_SOURCE_DIR}/include
-      ${_gRPC_ADDRESS_SORTING_INCLUDE_DIR}
-      ${_gRPC_RE2_INCLUDE_DIR}
-      ${_gRPC_SSL_INCLUDE_DIR}
-      ${_gRPC_UPB_GENERATED_DIR}
-      ${_gRPC_UPB_GRPC_GENERATED_DIR}
-      ${_gRPC_UPB_INCLUDE_DIR}
-      ${_gRPC_XXHASH_INCLUDE_DIR}
-      ${_gRPC_ZLIB_INCLUDE_DIR}
-      third_party/googletest/googletest/include
-      third_party/googletest/googletest
-      third_party/googletest/googlemock/include
-      third_party/googletest/googlemock
-      ${_gRPC_PROTO_GENS_DIR}
-  )
-
-  target_link_libraries(remove_stream_from_stalled_lists_test
-    ${_gRPC_PROTOBUF_LIBRARIES}
-    ${_gRPC_ALLTARGETS_LIBRARIES}
-    grpc_test_util
-  )
-
-
-endif()
-endif()
-if(gRPC_BUILD_TESTS)
 
-add_executable(retry_throttle_test
-  test/core/client_channel/retry_throttle_test.cc
+add_executable(secure_auth_context_test
+  test/cpp/common/secure_auth_context_test.cc
   third_party/googletest/googletest/src/gtest-all.cc
   third_party/googletest/googlemock/src/gmock-all.cc
 )
 
-target_include_directories(retry_throttle_test
+target_include_directories(secure_auth_context_test
   PRIVATE
     ${CMAKE_CURRENT_SOURCE_DIR}
     ${CMAKE_CURRENT_SOURCE_DIR}/include
@@ -13300,23 +14666,23 @@ target_include_directories(retry_throttle_test
     ${_gRPC_PROTO_GENS_DIR}
 )
 
-target_link_libraries(retry_throttle_test
+target_link_libraries(secure_auth_context_test
   ${_gRPC_PROTOBUF_LIBRARIES}
   ${_gRPC_ALLTARGETS_LIBRARIES}
-  grpc_test_util
+  grpc++_test_util
 )
 
 
 endif()
 if(gRPC_BUILD_TESTS)
 
-add_executable(secure_auth_context_test
-  test/cpp/common/secure_auth_context_test.cc
+add_executable(seq_test
+  test/core/promise/seq_test.cc
   third_party/googletest/googletest/src/gtest-all.cc
   third_party/googletest/googlemock/src/gmock-all.cc
 )
 
-target_include_directories(secure_auth_context_test
+target_include_directories(seq_test
   PRIVATE
     ${CMAKE_CURRENT_SOURCE_DIR}
     ${CMAKE_CURRENT_SOURCE_DIR}/include
@@ -13335,10 +14701,10 @@ target_include_directories(secure_auth_context_test
     ${_gRPC_PROTO_GENS_DIR}
 )
 
-target_link_libraries(secure_auth_context_test
+target_link_libraries(seq_test
   ${_gRPC_PROTOBUF_LIBRARIES}
   ${_gRPC_ALLTARGETS_LIBRARIES}
-  grpc++_test_util
+  absl::variant
 )
 
 
@@ -14781,6 +16147,41 @@ target_link_libraries(tls_security_connector_test
 endif()
 if(gRPC_BUILD_TESTS)
 
+add_executable(tls_test
+  test/core/gpr/tls_test.cc
+  third_party/googletest/googletest/src/gtest-all.cc
+  third_party/googletest/googlemock/src/gmock-all.cc
+)
+
+target_include_directories(tls_test
+  PRIVATE
+    ${CMAKE_CURRENT_SOURCE_DIR}
+    ${CMAKE_CURRENT_SOURCE_DIR}/include
+    ${_gRPC_ADDRESS_SORTING_INCLUDE_DIR}
+    ${_gRPC_RE2_INCLUDE_DIR}
+    ${_gRPC_SSL_INCLUDE_DIR}
+    ${_gRPC_UPB_GENERATED_DIR}
+    ${_gRPC_UPB_GRPC_GENERATED_DIR}
+    ${_gRPC_UPB_INCLUDE_DIR}
+    ${_gRPC_XXHASH_INCLUDE_DIR}
+    ${_gRPC_ZLIB_INCLUDE_DIR}
+    third_party/googletest/googletest/include
+    third_party/googletest/googletest
+    third_party/googletest/googlemock/include
+    third_party/googletest/googlemock
+    ${_gRPC_PROTO_GENS_DIR}
+)
+
+target_link_libraries(tls_test
+  ${_gRPC_PROTOBUF_LIBRARIES}
+  ${_gRPC_ALLTARGETS_LIBRARIES}
+  grpc_test_util
+)
+
+
+endif()
+if(gRPC_BUILD_TESTS)
+
 add_executable(too_many_pings_test
   test/core/end2end/cq_verifier.cc
   test/core/transport/chttp2/too_many_pings_test.cc
@@ -14818,6 +16219,117 @@ target_link_libraries(too_many_pings_test
 endif()
 if(gRPC_BUILD_TESTS)
 
+add_executable(transport_stream_receiver_test
+  src/core/ext/transport/binder/utils/transport_stream_receiver_impl.cc
+  src/core/ext/transport/binder/wire_format/transaction.cc
+  test/core/transport/binder/transport_stream_receiver_test.cc
+  third_party/googletest/googletest/src/gtest-all.cc
+  third_party/googletest/googlemock/src/gmock-all.cc
+)
+
+target_include_directories(transport_stream_receiver_test
+  PRIVATE
+    ${CMAKE_CURRENT_SOURCE_DIR}
+    ${CMAKE_CURRENT_SOURCE_DIR}/include
+    ${_gRPC_ADDRESS_SORTING_INCLUDE_DIR}
+    ${_gRPC_RE2_INCLUDE_DIR}
+    ${_gRPC_SSL_INCLUDE_DIR}
+    ${_gRPC_UPB_GENERATED_DIR}
+    ${_gRPC_UPB_GRPC_GENERATED_DIR}
+    ${_gRPC_UPB_INCLUDE_DIR}
+    ${_gRPC_XXHASH_INCLUDE_DIR}
+    ${_gRPC_ZLIB_INCLUDE_DIR}
+    third_party/googletest/googletest/include
+    third_party/googletest/googletest
+    third_party/googletest/googlemock/include
+    third_party/googletest/googlemock
+    ${_gRPC_PROTO_GENS_DIR}
+)
+
+target_link_libraries(transport_stream_receiver_test
+  ${_gRPC_PROTOBUF_LIBRARIES}
+  ${_gRPC_ALLTARGETS_LIBRARIES}
+  grpc_test_util
+)
+
+
+endif()
+if(gRPC_BUILD_TESTS)
+
+add_executable(try_join_test
+  test/core/promise/try_join_test.cc
+  third_party/googletest/googletest/src/gtest-all.cc
+  third_party/googletest/googlemock/src/gmock-all.cc
+)
+
+target_include_directories(try_join_test
+  PRIVATE
+    ${CMAKE_CURRENT_SOURCE_DIR}
+    ${CMAKE_CURRENT_SOURCE_DIR}/include
+    ${_gRPC_ADDRESS_SORTING_INCLUDE_DIR}
+    ${_gRPC_RE2_INCLUDE_DIR}
+    ${_gRPC_SSL_INCLUDE_DIR}
+    ${_gRPC_UPB_GENERATED_DIR}
+    ${_gRPC_UPB_GRPC_GENERATED_DIR}
+    ${_gRPC_UPB_INCLUDE_DIR}
+    ${_gRPC_XXHASH_INCLUDE_DIR}
+    ${_gRPC_ZLIB_INCLUDE_DIR}
+    third_party/googletest/googletest/include
+    third_party/googletest/googletest
+    third_party/googletest/googlemock/include
+    third_party/googletest/googlemock
+    ${_gRPC_PROTO_GENS_DIR}
+)
+
+target_link_libraries(try_join_test
+  ${_gRPC_PROTOBUF_LIBRARIES}
+  ${_gRPC_ALLTARGETS_LIBRARIES}
+  absl::status
+  absl::statusor
+  absl::variant
+)
+
+
+endif()
+if(gRPC_BUILD_TESTS)
+
+add_executable(try_seq_test
+  test/core/promise/try_seq_test.cc
+  third_party/googletest/googletest/src/gtest-all.cc
+  third_party/googletest/googlemock/src/gmock-all.cc
+)
+
+target_include_directories(try_seq_test
+  PRIVATE
+    ${CMAKE_CURRENT_SOURCE_DIR}
+    ${CMAKE_CURRENT_SOURCE_DIR}/include
+    ${_gRPC_ADDRESS_SORTING_INCLUDE_DIR}
+    ${_gRPC_RE2_INCLUDE_DIR}
+    ${_gRPC_SSL_INCLUDE_DIR}
+    ${_gRPC_UPB_GENERATED_DIR}
+    ${_gRPC_UPB_GRPC_GENERATED_DIR}
+    ${_gRPC_UPB_INCLUDE_DIR}
+    ${_gRPC_XXHASH_INCLUDE_DIR}
+    ${_gRPC_ZLIB_INCLUDE_DIR}
+    third_party/googletest/googletest/include
+    third_party/googletest/googletest
+    third_party/googletest/googlemock/include
+    third_party/googletest/googlemock
+    ${_gRPC_PROTO_GENS_DIR}
+)
+
+target_link_libraries(try_seq_test
+  ${_gRPC_PROTOBUF_LIBRARIES}
+  ${_gRPC_ALLTARGETS_LIBRARIES}
+  absl::status
+  absl::statusor
+  absl::variant
+)
+
+
+endif()
+if(gRPC_BUILD_TESTS)
+
 add_executable(unknown_frame_bad_client_test
   test/core/bad_client/bad_client.cc
   test/core/bad_client/tests/unknown_frame.cc
@@ -14926,6 +16438,88 @@ target_link_libraries(window_overflow_bad_client_test
 
 endif()
 if(gRPC_BUILD_TESTS)
+
+add_executable(wire_reader_test
+  src/core/ext/transport/binder/utils/transport_stream_receiver_impl.cc
+  src/core/ext/transport/binder/wire_format/binder_constants.cc
+  src/core/ext/transport/binder/wire_format/transaction.cc
+  src/core/ext/transport/binder/wire_format/wire_reader_impl.cc
+  src/core/ext/transport/binder/wire_format/wire_writer.cc
+  test/core/transport/binder/mock_objects.cc
+  test/core/transport/binder/wire_reader_test.cc
+  third_party/googletest/googletest/src/gtest-all.cc
+  third_party/googletest/googlemock/src/gmock-all.cc
+)
+
+target_include_directories(wire_reader_test
+  PRIVATE
+    ${CMAKE_CURRENT_SOURCE_DIR}
+    ${CMAKE_CURRENT_SOURCE_DIR}/include
+    ${_gRPC_ADDRESS_SORTING_INCLUDE_DIR}
+    ${_gRPC_RE2_INCLUDE_DIR}
+    ${_gRPC_SSL_INCLUDE_DIR}
+    ${_gRPC_UPB_GENERATED_DIR}
+    ${_gRPC_UPB_GRPC_GENERATED_DIR}
+    ${_gRPC_UPB_INCLUDE_DIR}
+    ${_gRPC_XXHASH_INCLUDE_DIR}
+    ${_gRPC_ZLIB_INCLUDE_DIR}
+    third_party/googletest/googletest/include
+    third_party/googletest/googletest
+    third_party/googletest/googlemock/include
+    third_party/googletest/googlemock
+    ${_gRPC_PROTO_GENS_DIR}
+)
+
+target_link_libraries(wire_reader_test
+  ${_gRPC_PROTOBUF_LIBRARIES}
+  ${_gRPC_ALLTARGETS_LIBRARIES}
+  grpc_test_util
+)
+
+
+endif()
+if(gRPC_BUILD_TESTS)
+
+add_executable(wire_writer_test
+  src/core/ext/transport/binder/utils/transport_stream_receiver_impl.cc
+  src/core/ext/transport/binder/wire_format/binder_constants.cc
+  src/core/ext/transport/binder/wire_format/transaction.cc
+  src/core/ext/transport/binder/wire_format/wire_reader_impl.cc
+  src/core/ext/transport/binder/wire_format/wire_writer.cc
+  test/core/transport/binder/mock_objects.cc
+  test/core/transport/binder/wire_writer_test.cc
+  third_party/googletest/googletest/src/gtest-all.cc
+  third_party/googletest/googlemock/src/gmock-all.cc
+)
+
+target_include_directories(wire_writer_test
+  PRIVATE
+    ${CMAKE_CURRENT_SOURCE_DIR}
+    ${CMAKE_CURRENT_SOURCE_DIR}/include
+    ${_gRPC_ADDRESS_SORTING_INCLUDE_DIR}
+    ${_gRPC_RE2_INCLUDE_DIR}
+    ${_gRPC_SSL_INCLUDE_DIR}
+    ${_gRPC_UPB_GENERATED_DIR}
+    ${_gRPC_UPB_GRPC_GENERATED_DIR}
+    ${_gRPC_UPB_INCLUDE_DIR}
+    ${_gRPC_XXHASH_INCLUDE_DIR}
+    ${_gRPC_ZLIB_INCLUDE_DIR}
+    third_party/googletest/googletest/include
+    third_party/googletest/googletest
+    third_party/googletest/googlemock/include
+    third_party/googletest/googlemock
+    ${_gRPC_PROTO_GENS_DIR}
+)
+
+target_link_libraries(wire_writer_test
+  ${_gRPC_PROTOBUF_LIBRARIES}
+  ${_gRPC_ALLTARGETS_LIBRARIES}
+  grpc_test_util
+)
+
+
+endif()
+if(gRPC_BUILD_TESTS)
 if(_gRPC_PLATFORM_LINUX OR _gRPC_PLATFORM_MAC OR _gRPC_PLATFORM_POSIX)
 
   add_executable(work_serializer_test
@@ -14991,6 +16585,7 @@ if(_gRPC_PLATFORM_LINUX OR _gRPC_PLATFORM_MAC OR _gRPC_PLATFORM_POSIX)
     test/core/util/port_server_client.cc
     test/core/util/reconnect_server.cc
     test/core/util/resolve_localhost_ip46.cc
+    test/core/util/resource_user_util.cc
     test/core/util/slice_splitter.cc
     test/core/util/stack_tracer.cc
     test/core/util/subprocess_posix.cc
@@ -15268,6 +16863,10 @@ if(_gRPC_PLATFORM_LINUX OR _gRPC_PLATFORM_MAC OR _gRPC_PLATFORM_POSIX)
     ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/xds/v3/endpoint.grpc.pb.cc
     ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/xds/v3/endpoint.pb.h
     ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/xds/v3/endpoint.grpc.pb.h
+    ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/xds/v3/extension.pb.cc
+    ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/xds/v3/extension.grpc.pb.cc
+    ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/xds/v3/extension.pb.h
+    ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/xds/v3/extension.grpc.pb.h
     ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/xds/v3/fault.pb.cc
     ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/xds/v3/fault.grpc.pb.cc
     ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/testing/xds/v3/fault.pb.h
@@ -15353,6 +16952,7 @@ if(_gRPC_PLATFORM_LINUX OR _gRPC_PLATFORM_MAC OR _gRPC_PLATFORM_POSIX)
   target_link_libraries(xds_end2end_test
     ${_gRPC_PROTOBUF_LIBRARIES}
     ${_gRPC_ALLTARGETS_LIBRARIES}
+    grpc++_test_config
     grpc++_test_util
   )
 
@@ -16064,7 +17664,7 @@ generate_pkgconfig(
   "gRPC"
   "high performance general RPC framework"
   "${gRPC_CORE_VERSION}"
-  "gpr openssl absl_base absl_bind_front absl_cord absl_core_headers absl_flat_hash_map absl_inlined_vector absl_memory absl_optional absl_status absl_statusor absl_str_format absl_strings absl_synchronization absl_time"
+  "gpr openssl absl_base absl_bind_front absl_cord absl_core_headers absl_flat_hash_map absl_inlined_vector absl_memory absl_optional absl_status absl_statusor absl_str_format absl_strings absl_synchronization absl_time absl_variant"
   "-lgrpc -laddress_sorting -lre2 -lupb -lcares -lz"
   ""
   "grpc.pc")
@@ -16074,7 +17674,7 @@ generate_pkgconfig(
   "gRPC unsecure"
   "high performance general RPC framework without SSL"
   "${gRPC_CORE_VERSION}"
-  "gpr absl_base absl_bind_front absl_cord absl_core_headers absl_flat_hash_map absl_inlined_vector absl_memory absl_optional absl_status absl_statusor absl_str_format absl_strings absl_synchronization absl_time"
+  "gpr absl_base absl_bind_front absl_cord absl_core_headers absl_flat_hash_map absl_inlined_vector absl_memory absl_optional absl_status absl_statusor absl_str_format absl_strings absl_synchronization absl_time absl_variant"
   "-lgrpc_unsecure"
   ""
   "grpc_unsecure.pc")
@@ -16084,7 +17684,7 @@ generate_pkgconfig(
   "gRPC++"
   "C++ wrapper for gRPC"
   "${gRPC_CPP_VERSION}"
-  "grpc absl_base absl_bind_front absl_cord absl_core_headers absl_flat_hash_map absl_inlined_vector absl_memory absl_optional absl_status absl_statusor absl_str_format absl_strings absl_synchronization absl_time"
+  "grpc absl_base absl_bind_front absl_cord absl_core_headers absl_flat_hash_map absl_inlined_vector absl_memory absl_optional absl_status absl_statusor absl_str_format absl_strings absl_synchronization absl_time absl_variant"
   "-lgrpc++"
   ""
   "grpc++.pc")
@@ -16094,7 +17694,7 @@ generate_pkgconfig(
   "gRPC++ unsecure"
   "C++ wrapper for gRPC without SSL"
   "${gRPC_CPP_VERSION}"
-  "grpc_unsecure absl_base absl_bind_front absl_cord absl_core_headers absl_flat_hash_map absl_inlined_vector absl_memory absl_optional absl_status absl_statusor absl_str_format absl_strings absl_synchronization absl_time"
+  "grpc_unsecure absl_base absl_bind_front absl_cord absl_core_headers absl_flat_hash_map absl_inlined_vector absl_memory absl_optional absl_status absl_statusor absl_str_format absl_strings absl_synchronization absl_time absl_variant"
   "-lgrpc++_unsecure"
   ""
   "grpc++_unsecure.pc")
index f78be0c..c85974e 100644 (file)
@@ -54,10 +54,11 @@ clients and servers. A concrete embedding over HTTP/2 completes the picture by
 fleshing out the details of each of the required operations.
 
 ## Abstract gRPC protocol
-A gRPC call comprises of a bidirectional stream of messages, initiated by the client. In the client-to-server direction, this stream begins with a mandatory `Call Header`, followed by optional `Initial-Metadata`, followed by zero or more `Payload Messages`. The server-to-client direction contains an optional `Initial-Metadata`, followed by zero or more `Payload Messages` terminated with a mandatory `Status` and optional `Status-Metadata` (a.k.a.,`Trailing-Metadata`).
+A gRPC call comprises of a bidirectional stream of messages, initiated by the client. In the client-to-server direction, this stream begins with a mandatory `Call Header`, followed by optional `Initial-Metadata`, followed by zero or more `Payload Messages`. A client signals end of its message stream by means of an underlying lower level protocol. The server-to-client direction contains an optional `Initial-Metadata`, followed by zero or more `Payload Messages` terminated with a mandatory `Status` and optional `Status-Metadata` (a.k.a.,`Trailing-Metadata`).
 
 ## Implementation over HTTP/2
-The abstract protocol defined above is implemented over [HTTP/2](https://http2.github.io/). gRPC bidirectional streams are mapped to HTTP/2 streams. The contents of `Call Header` and `Initial Metadata` are sent as HTTP/2 headers and subject to HPACK compression. `Payload Messages` are serialized into a byte stream of length prefixed gRPC frames which are then fragmented into HTTP/2 frames at the sender and reassembled at the receiver. `Status` and `Trailing-Metadata` are sent as HTTP/2 trailing headers (a.k.a., trailers).
+The abstract protocol defined above is implemented over [HTTP/2](https://http2.github.io/). gRPC bidirectional streams are mapped to HTTP/2 streams. The contents of `Call Header` and `Initial Metadata` are sent as HTTP/2 headers and subject to HPACK compression. `Payload Messages` are serialized into a byte stream of length prefixed gRPC frames which are then fragmented into HTTP/2 frames at the sender and reassembled at the receiver. `Status` and `Trailing-Metadata` are sent as HTTP/2 trailing headers (a.k.a., trailers). A client signals end of its message stream by setting `END_STREAM` flag on the last DATA frame.
+For a detailed description see [doc/PROTOCOL-HTTP2.md](doc/PROTOCOL-HTTP2.md).
 
 ## Flow Control
 gRPC uses the flow control mechanism in HTTP/2. This enables fine-grained control of memory used for buffering in-flight messages.
index c7aa7c7..c44a46f 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -454,9 +454,9 @@ E = @echo
 Q = @
 endif
 
-CORE_VERSION = 18.0.0
-CPP_VERSION = 1.40.0
-CSHARP_VERSION = 2.40.0
+CORE_VERSION = 19.0.0
+CPP_VERSION = 1.41.0
+CSHARP_VERSION = 2.41.0
 
 CPPFLAGS_NO_ARCH += $(addprefix -I, $(INCLUDES)) $(addprefix -D, $(DEFINES))
 CPPFLAGS += $(CPPFLAGS_NO_ARCH) $(ARCH_FLAGS)
@@ -492,7 +492,7 @@ SHARED_EXT_CORE = dll
 SHARED_EXT_CPP = dll
 SHARED_EXT_CSHARP = dll
 SHARED_PREFIX =
-SHARED_VERSION_CORE = -18
+SHARED_VERSION_CORE = -19
 SHARED_VERSION_CPP = -1
 SHARED_VERSION_CSHARP = -2
 else ifeq ($(SYSTEM),Darwin)
@@ -891,8 +891,8 @@ $(LIBDIR)/$(CONFIG)/libaddress_sorting$(SHARED_VERSION_CORE).$(SHARED_EXT_CORE):
 ifeq ($(SYSTEM),Darwin)
        $(Q) $(LDXX) $(LDFLAGS) -L$(LIBDIR)/$(CONFIG) -install_name $(SHARED_PREFIX)address_sorting$(SHARED_VERSION_CORE).$(SHARED_EXT_CORE) -dynamiclib -o $(LIBDIR)/$(CONFIG)/libaddress_sorting$(SHARED_VERSION_CORE).$(SHARED_EXT_CORE) $(LIBADDRESS_SORTING_OBJS) $(ZLIB_MERGE_LIBS) $(CARES_MERGE_LIBS) $(ADDRESS_SORTING_MERGE_LIBS) $(RE2_MERGE_LIBS) $(UPB_MERGE_LIBS) $(GRPC_ABSEIL_MERGE_LIBS) $(LDLIBS)
 else
-       $(Q) $(LDXX) $(LDFLAGS) -L$(LIBDIR)/$(CONFIG) -shared -Wl,-soname,libaddress_sorting.so.18 -o $(LIBDIR)/$(CONFIG)/libaddress_sorting$(SHARED_VERSION_CORE).$(SHARED_EXT_CORE) $(LIBADDRESS_SORTING_OBJS) $(ZLIB_MERGE_LIBS) $(CARES_MERGE_LIBS) $(ADDRESS_SORTING_MERGE_LIBS) $(RE2_MERGE_LIBS) $(UPB_MERGE_LIBS) $(GRPC_ABSEIL_MERGE_LIBS) $(LDLIBS)
-       $(Q) ln -sf $(SHARED_PREFIX)address_sorting$(SHARED_VERSION_CORE).$(SHARED_EXT_CORE) $(LIBDIR)/$(CONFIG)/libaddress_sorting$(SHARED_VERSION_CORE).so.18
+       $(Q) $(LDXX) $(LDFLAGS) -L$(LIBDIR)/$(CONFIG) -shared -Wl,-soname,libaddress_sorting.so.19 -o $(LIBDIR)/$(CONFIG)/libaddress_sorting$(SHARED_VERSION_CORE).$(SHARED_EXT_CORE) $(LIBADDRESS_SORTING_OBJS) $(ZLIB_MERGE_LIBS) $(CARES_MERGE_LIBS) $(ADDRESS_SORTING_MERGE_LIBS) $(RE2_MERGE_LIBS) $(UPB_MERGE_LIBS) $(GRPC_ABSEIL_MERGE_LIBS) $(LDLIBS)
+       $(Q) ln -sf $(SHARED_PREFIX)address_sorting$(SHARED_VERSION_CORE).$(SHARED_EXT_CORE) $(LIBDIR)/$(CONFIG)/libaddress_sorting$(SHARED_VERSION_CORE).so.19
        $(Q) ln -sf $(SHARED_PREFIX)address_sorting$(SHARED_VERSION_CORE).$(SHARED_EXT_CORE) $(LIBDIR)/$(CONFIG)/libaddress_sorting$(SHARED_VERSION_CORE).so
 endif
 endif
@@ -943,7 +943,6 @@ LIBGPR_SRC = \
     src/core/lib/gpr/time_posix.cc \
     src/core/lib/gpr/time_precise.cc \
     src/core/lib/gpr/time_windows.cc \
-    src/core/lib/gpr/tls_pthread.cc \
     src/core/lib/gpr/tmpfile_msys.cc \
     src/core/lib/gpr/tmpfile_posix.cc \
     src/core/lib/gpr/tmpfile_windows.cc \
@@ -1032,8 +1031,8 @@ $(LIBDIR)/$(CONFIG)/libgpr$(SHARED_VERSION_CORE).$(SHARED_EXT_CORE): $(LIBGPR_OB
 ifeq ($(SYSTEM),Darwin)
        $(Q) $(LDXX) $(LDFLAGS) -L$(LIBDIR)/$(CONFIG) -install_name $(SHARED_PREFIX)gpr$(SHARED_VERSION_CORE).$(SHARED_EXT_CORE) -dynamiclib -o $(LIBDIR)/$(CONFIG)/libgpr$(SHARED_VERSION_CORE).$(SHARED_EXT_CORE) $(LIBGPR_OBJS) $(LIBDIR)/$(CONFIG)/libupb.a $(ZLIB_MERGE_LIBS) $(CARES_MERGE_LIBS) $(ADDRESS_SORTING_MERGE_LIBS) $(RE2_MERGE_LIBS) $(UPB_MERGE_LIBS) $(GRPC_ABSEIL_MERGE_LIBS) $(LDLIBS)
 else
-       $(Q) $(LDXX) $(LDFLAGS) -L$(LIBDIR)/$(CONFIG) -shared -Wl,-soname,libgpr.so.18 -o $(LIBDIR)/$(CONFIG)/libgpr$(SHARED_VERSION_CORE).$(SHARED_EXT_CORE) $(LIBGPR_OBJS) $(LIBDIR)/$(CONFIG)/libupb.a $(ZLIB_MERGE_LIBS) $(CARES_MERGE_LIBS) $(ADDRESS_SORTING_MERGE_LIBS) $(RE2_MERGE_LIBS) $(UPB_MERGE_LIBS) $(GRPC_ABSEIL_MERGE_LIBS) $(LDLIBS)
-       $(Q) ln -sf $(SHARED_PREFIX)gpr$(SHARED_VERSION_CORE).$(SHARED_EXT_CORE) $(LIBDIR)/$(CONFIG)/libgpr$(SHARED_VERSION_CORE).so.18
+       $(Q) $(LDXX) $(LDFLAGS) -L$(LIBDIR)/$(CONFIG) -shared -Wl,-soname,libgpr.so.19 -o $(LIBDIR)/$(CONFIG)/libgpr$(SHARED_VERSION_CORE).$(SHARED_EXT_CORE) $(LIBGPR_OBJS) $(LIBDIR)/$(CONFIG)/libupb.a $(ZLIB_MERGE_LIBS) $(CARES_MERGE_LIBS) $(ADDRESS_SORTING_MERGE_LIBS) $(RE2_MERGE_LIBS) $(UPB_MERGE_LIBS) $(GRPC_ABSEIL_MERGE_LIBS) $(LDLIBS)
+       $(Q) ln -sf $(SHARED_PREFIX)gpr$(SHARED_VERSION_CORE).$(SHARED_EXT_CORE) $(LIBDIR)/$(CONFIG)/libgpr$(SHARED_VERSION_CORE).so.19
        $(Q) ln -sf $(SHARED_PREFIX)gpr$(SHARED_VERSION_CORE).$(SHARED_EXT_CORE) $(LIBDIR)/$(CONFIG)/libgpr$(SHARED_VERSION_CORE).so
 endif
 endif
@@ -1084,12 +1083,10 @@ LIBGRPC_SRC = \
     src/core/ext/filters/client_channel/resolver.cc \
     src/core/ext/filters/client_channel/resolver/dns/c_ares/dns_resolver_ares.cc \
     src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_event_engine.cc \
-    src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_libuv.cc \
     src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_posix.cc \
     src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_windows.cc \
     src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper.cc \
     src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_event_engine.cc \
-    src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_libuv.cc \
     src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_posix.cc \
     src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_windows.cc \
     src/core/ext/filters/client_channel/resolver/dns/dns_resolver_selection.cc \
@@ -1147,8 +1144,10 @@ LIBGRPC_SRC = \
     src/core/ext/transport/chttp2/transport/frame_settings.cc \
     src/core/ext/transport/chttp2/transport/frame_window_update.cc \
     src/core/ext/transport/chttp2/transport/hpack_encoder.cc \
+    src/core/ext/transport/chttp2/transport/hpack_encoder_table.cc \
     src/core/ext/transport/chttp2/transport/hpack_parser.cc \
-    src/core/ext/transport/chttp2/transport/hpack_table.cc \
+    src/core/ext/transport/chttp2/transport/hpack_parser_table.cc \
+    src/core/ext/transport/chttp2/transport/hpack_utils.cc \
     src/core/ext/transport/chttp2/transport/http2_settings.cc \
     src/core/ext/transport/chttp2/transport/huffsyms.cc \
     src/core/ext/transport/chttp2/transport/incoming_metadata.cc \
@@ -1375,6 +1374,7 @@ LIBGRPC_SRC = \
     src/core/lib/compression/stream_compression.cc \
     src/core/lib/compression/stream_compression_gzip.cc \
     src/core/lib/compression/stream_compression_identity.cc \
+    src/core/lib/config/core_configuration.cc \
     src/core/lib/debug/stats.cc \
     src/core/lib/debug/stats_data.cc \
     src/core/lib/debug/trace.cc \
@@ -1394,7 +1394,6 @@ LIBGRPC_SRC = \
     src/core/lib/iomgr/endpoint_cfstream.cc \
     src/core/lib/iomgr/endpoint_pair_event_engine.cc \
     src/core/lib/iomgr/endpoint_pair_posix.cc \
-    src/core/lib/iomgr/endpoint_pair_uv.cc \
     src/core/lib/iomgr/endpoint_pair_windows.cc \
     src/core/lib/iomgr/error.cc \
     src/core/lib/iomgr/error_cfstream.cc \
@@ -1430,7 +1429,6 @@ LIBGRPC_SRC = \
     src/core/lib/iomgr/iomgr_internal.cc \
     src/core/lib/iomgr/iomgr_posix.cc \
     src/core/lib/iomgr/iomgr_posix_cfstream.cc \
-    src/core/lib/iomgr/iomgr_uv.cc \
     src/core/lib/iomgr/iomgr_windows.cc \
     src/core/lib/iomgr/is_epollexclusive_available.cc \
     src/core/lib/iomgr/load_file.cc \
@@ -1441,7 +1439,6 @@ LIBGRPC_SRC = \
     src/core/lib/iomgr/pollset_set.cc \
     src/core/lib/iomgr/pollset_set_custom.cc \
     src/core/lib/iomgr/pollset_set_windows.cc \
-    src/core/lib/iomgr/pollset_uv.cc \
     src/core/lib/iomgr/pollset_windows.cc \
     src/core/lib/iomgr/resolve_address.cc \
     src/core/lib/iomgr/resolve_address_custom.cc \
@@ -1453,7 +1450,6 @@ LIBGRPC_SRC = \
     src/core/lib/iomgr/socket_utils_common_posix.cc \
     src/core/lib/iomgr/socket_utils_linux.cc \
     src/core/lib/iomgr/socket_utils_posix.cc \
-    src/core/lib/iomgr/socket_utils_uv.cc \
     src/core/lib/iomgr/socket_utils_windows.cc \
     src/core/lib/iomgr/socket_windows.cc \
     src/core/lib/iomgr/tcp_client.cc \
@@ -1470,7 +1466,6 @@ LIBGRPC_SRC = \
     src/core/lib/iomgr/tcp_server_utils_posix_ifaddrs.cc \
     src/core/lib/iomgr/tcp_server_utils_posix_noifaddrs.cc \
     src/core/lib/iomgr/tcp_server_windows.cc \
-    src/core/lib/iomgr/tcp_uv.cc \
     src/core/lib/iomgr/tcp_windows.cc \
     src/core/lib/iomgr/time_averaged_stats.cc \
     src/core/lib/iomgr/timer.cc \
@@ -1478,7 +1473,6 @@ LIBGRPC_SRC = \
     src/core/lib/iomgr/timer_generic.cc \
     src/core/lib/iomgr/timer_heap.cc \
     src/core/lib/iomgr/timer_manager.cc \
-    src/core/lib/iomgr/timer_uv.cc \
     src/core/lib/iomgr/udp_server.cc \
     src/core/lib/iomgr/unix_sockets_posix.cc \
     src/core/lib/iomgr/unix_sockets_posix_noop.cc \
@@ -1493,6 +1487,7 @@ LIBGRPC_SRC = \
     src/core/lib/matchers/matchers.cc \
     src/core/lib/security/authorization/authorization_policy_provider_vtable.cc \
     src/core/lib/security/authorization/evaluate_args.cc \
+    src/core/lib/security/authorization/sdk_server_authz_filter.cc \
     src/core/lib/security/context/security_context.cc \
     src/core/lib/security/credentials/alts/alts_credentials.cc \
     src/core/lib/security/credentials/alts/check_gcp_environment.cc \
@@ -1671,8 +1666,8 @@ $(LIBDIR)/$(CONFIG)/libgrpc$(SHARED_VERSION_CORE).$(SHARED_EXT_CORE): $(LIBGRPC_
 ifeq ($(SYSTEM),Darwin)
        $(Q) $(LDXX) $(LDFLAGS) -L$(LIBDIR)/$(CONFIG) -install_name $(SHARED_PREFIX)grpc$(SHARED_VERSION_CORE).$(SHARED_EXT_CORE) -dynamiclib -o $(LIBDIR)/$(CONFIG)/libgrpc$(SHARED_VERSION_CORE).$(SHARED_EXT_CORE) $(LIBGRPC_OBJS) $(LIBDIR)/$(CONFIG)/libgpr.a $(LIBDIR)/$(CONFIG)/libaddress_sorting.a $(OPENSSL_MERGE_LIBS) $(LDLIBS_SECURE) $(ZLIB_MERGE_LIBS) $(CARES_MERGE_LIBS) $(ADDRESS_SORTING_MERGE_LIBS) $(RE2_MERGE_LIBS) $(UPB_MERGE_LIBS) $(GRPC_ABSEIL_MERGE_LIBS) $(LDLIBS)
 else
-       $(Q) $(LDXX) $(LDFLAGS) -L$(LIBDIR)/$(CONFIG) -shared -Wl,-soname,libgrpc.so.18 -o $(LIBDIR)/$(CONFIG)/libgrpc$(SHARED_VERSION_CORE).$(SHARED_EXT_CORE) $(LIBGRPC_OBJS) $(LIBDIR)/$(CONFIG)/libgpr.a $(LIBDIR)/$(CONFIG)/libaddress_sorting.a $(OPENSSL_MERGE_LIBS) $(LDLIBS_SECURE) $(ZLIB_MERGE_LIBS) $(CARES_MERGE_LIBS) $(ADDRESS_SORTING_MERGE_LIBS) $(RE2_MERGE_LIBS) $(UPB_MERGE_LIBS) $(GRPC_ABSEIL_MERGE_LIBS) $(LDLIBS)
-       $(Q) ln -sf $(SHARED_PREFIX)grpc$(SHARED_VERSION_CORE).$(SHARED_EXT_CORE) $(LIBDIR)/$(CONFIG)/libgrpc$(SHARED_VERSION_CORE).so.18
+       $(Q) $(LDXX) $(LDFLAGS) -L$(LIBDIR)/$(CONFIG) -shared -Wl,-soname,libgrpc.so.19 -o $(LIBDIR)/$(CONFIG)/libgrpc$(SHARED_VERSION_CORE).$(SHARED_EXT_CORE) $(LIBGRPC_OBJS) $(LIBDIR)/$(CONFIG)/libgpr.a $(LIBDIR)/$(CONFIG)/libaddress_sorting.a $(OPENSSL_MERGE_LIBS) $(LDLIBS_SECURE) $(ZLIB_MERGE_LIBS) $(CARES_MERGE_LIBS) $(ADDRESS_SORTING_MERGE_LIBS) $(RE2_MERGE_LIBS) $(UPB_MERGE_LIBS) $(GRPC_ABSEIL_MERGE_LIBS) $(LDLIBS)
+       $(Q) ln -sf $(SHARED_PREFIX)grpc$(SHARED_VERSION_CORE).$(SHARED_EXT_CORE) $(LIBDIR)/$(CONFIG)/libgrpc$(SHARED_VERSION_CORE).so.19
        $(Q) ln -sf $(SHARED_PREFIX)grpc$(SHARED_VERSION_CORE).$(SHARED_EXT_CORE) $(LIBDIR)/$(CONFIG)/libgrpc$(SHARED_VERSION_CORE).so
 endif
 endif
@@ -1719,8 +1714,8 @@ $(LIBDIR)/$(CONFIG)/libgrpc_csharp_ext$(SHARED_VERSION_CORE).$(SHARED_EXT_CORE):
 ifeq ($(SYSTEM),Darwin)
        $(Q) $(LDXX) $(LDFLAGS) -L$(LIBDIR)/$(CONFIG) -install_name $(SHARED_PREFIX)grpc_csharp_ext$(SHARED_VERSION_CORE).$(SHARED_EXT_CORE) -dynamiclib -o $(LIBDIR)/$(CONFIG)/libgrpc_csharp_ext$(SHARED_VERSION_CORE).$(SHARED_EXT_CORE) $(LIBGRPC_CSHARP_EXT_OBJS) $(LIBDIR)/$(CONFIG)/libgrpc.a $(ZLIB_MERGE_LIBS) $(CARES_MERGE_LIBS) $(ADDRESS_SORTING_MERGE_LIBS) $(RE2_MERGE_LIBS) $(UPB_MERGE_LIBS) $(GRPC_ABSEIL_MERGE_LIBS) $(LDLIBS)
 else
-       $(Q) $(LDXX) $(LDFLAGS) -L$(LIBDIR)/$(CONFIG) -shared -Wl,-soname,libgrpc_csharp_ext.so.18 -o $(LIBDIR)/$(CONFIG)/libgrpc_csharp_ext$(SHARED_VERSION_CORE).$(SHARED_EXT_CORE) $(LIBGRPC_CSHARP_EXT_OBJS) $(LIBDIR)/$(CONFIG)/libgrpc.a $(ZLIB_MERGE_LIBS) $(CARES_MERGE_LIBS) $(ADDRESS_SORTING_MERGE_LIBS) $(RE2_MERGE_LIBS) $(UPB_MERGE_LIBS) $(GRPC_ABSEIL_MERGE_LIBS) $(LDLIBS)
-       $(Q) ln -sf $(SHARED_PREFIX)grpc_csharp_ext$(SHARED_VERSION_CORE).$(SHARED_EXT_CORE) $(LIBDIR)/$(CONFIG)/libgrpc_csharp_ext$(SHARED_VERSION_CORE).so.18
+       $(Q) $(LDXX) $(LDFLAGS) -L$(LIBDIR)/$(CONFIG) -shared -Wl,-soname,libgrpc_csharp_ext.so.19 -o $(LIBDIR)/$(CONFIG)/libgrpc_csharp_ext$(SHARED_VERSION_CORE).$(SHARED_EXT_CORE) $(LIBGRPC_CSHARP_EXT_OBJS) $(LIBDIR)/$(CONFIG)/libgrpc.a $(ZLIB_MERGE_LIBS) $(CARES_MERGE_LIBS) $(ADDRESS_SORTING_MERGE_LIBS) $(RE2_MERGE_LIBS) $(UPB_MERGE_LIBS) $(GRPC_ABSEIL_MERGE_LIBS) $(LDLIBS)
+       $(Q) ln -sf $(SHARED_PREFIX)grpc_csharp_ext$(SHARED_VERSION_CORE).$(SHARED_EXT_CORE) $(LIBDIR)/$(CONFIG)/libgrpc_csharp_ext$(SHARED_VERSION_CORE).so.19
        $(Q) ln -sf $(SHARED_PREFIX)grpc_csharp_ext$(SHARED_VERSION_CORE).$(SHARED_EXT_CORE) $(LIBDIR)/$(CONFIG)/libgrpc_csharp_ext$(SHARED_VERSION_CORE).so
 endif
 endif
@@ -1767,12 +1762,10 @@ LIBGRPC_UNSECURE_SRC = \
     src/core/ext/filters/client_channel/resolver.cc \
     src/core/ext/filters/client_channel/resolver/dns/c_ares/dns_resolver_ares.cc \
     src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_event_engine.cc \
-    src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_libuv.cc \
     src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_posix.cc \
     src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_windows.cc \
     src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper.cc \
     src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_event_engine.cc \
-    src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_libuv.cc \
     src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_posix.cc \
     src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_windows.cc \
     src/core/ext/filters/client_channel/resolver/dns/dns_resolver_selection.cc \
@@ -1826,8 +1819,10 @@ LIBGRPC_UNSECURE_SRC = \
     src/core/ext/transport/chttp2/transport/frame_settings.cc \
     src/core/ext/transport/chttp2/transport/frame_window_update.cc \
     src/core/ext/transport/chttp2/transport/hpack_encoder.cc \
+    src/core/ext/transport/chttp2/transport/hpack_encoder_table.cc \
     src/core/ext/transport/chttp2/transport/hpack_parser.cc \
-    src/core/ext/transport/chttp2/transport/hpack_table.cc \
+    src/core/ext/transport/chttp2/transport/hpack_parser_table.cc \
+    src/core/ext/transport/chttp2/transport/hpack_utils.cc \
     src/core/ext/transport/chttp2/transport/http2_settings.cc \
     src/core/ext/transport/chttp2/transport/huffsyms.cc \
     src/core/ext/transport/chttp2/transport/incoming_metadata.cc \
@@ -1863,6 +1858,7 @@ LIBGRPC_UNSECURE_SRC = \
     src/core/lib/compression/stream_compression.cc \
     src/core/lib/compression/stream_compression_gzip.cc \
     src/core/lib/compression/stream_compression_identity.cc \
+    src/core/lib/config/core_configuration.cc \
     src/core/lib/debug/stats.cc \
     src/core/lib/debug/stats_data.cc \
     src/core/lib/debug/trace.cc \
@@ -1881,7 +1877,6 @@ LIBGRPC_UNSECURE_SRC = \
     src/core/lib/iomgr/endpoint_cfstream.cc \
     src/core/lib/iomgr/endpoint_pair_event_engine.cc \
     src/core/lib/iomgr/endpoint_pair_posix.cc \
-    src/core/lib/iomgr/endpoint_pair_uv.cc \
     src/core/lib/iomgr/endpoint_pair_windows.cc \
     src/core/lib/iomgr/error.cc \
     src/core/lib/iomgr/error_cfstream.cc \
@@ -1917,7 +1912,6 @@ LIBGRPC_UNSECURE_SRC = \
     src/core/lib/iomgr/iomgr_internal.cc \
     src/core/lib/iomgr/iomgr_posix.cc \
     src/core/lib/iomgr/iomgr_posix_cfstream.cc \
-    src/core/lib/iomgr/iomgr_uv.cc \
     src/core/lib/iomgr/iomgr_windows.cc \
     src/core/lib/iomgr/is_epollexclusive_available.cc \
     src/core/lib/iomgr/load_file.cc \
@@ -1928,7 +1922,6 @@ LIBGRPC_UNSECURE_SRC = \
     src/core/lib/iomgr/pollset_set.cc \
     src/core/lib/iomgr/pollset_set_custom.cc \
     src/core/lib/iomgr/pollset_set_windows.cc \
-    src/core/lib/iomgr/pollset_uv.cc \
     src/core/lib/iomgr/pollset_windows.cc \
     src/core/lib/iomgr/resolve_address.cc \
     src/core/lib/iomgr/resolve_address_custom.cc \
@@ -1940,7 +1933,6 @@ LIBGRPC_UNSECURE_SRC = \
     src/core/lib/iomgr/socket_utils_common_posix.cc \
     src/core/lib/iomgr/socket_utils_linux.cc \
     src/core/lib/iomgr/socket_utils_posix.cc \
-    src/core/lib/iomgr/socket_utils_uv.cc \
     src/core/lib/iomgr/socket_utils_windows.cc \
     src/core/lib/iomgr/socket_windows.cc \
     src/core/lib/iomgr/tcp_client.cc \
@@ -1957,7 +1949,6 @@ LIBGRPC_UNSECURE_SRC = \
     src/core/lib/iomgr/tcp_server_utils_posix_ifaddrs.cc \
     src/core/lib/iomgr/tcp_server_utils_posix_noifaddrs.cc \
     src/core/lib/iomgr/tcp_server_windows.cc \
-    src/core/lib/iomgr/tcp_uv.cc \
     src/core/lib/iomgr/tcp_windows.cc \
     src/core/lib/iomgr/time_averaged_stats.cc \
     src/core/lib/iomgr/timer.cc \
@@ -1965,7 +1956,6 @@ LIBGRPC_UNSECURE_SRC = \
     src/core/lib/iomgr/timer_generic.cc \
     src/core/lib/iomgr/timer_heap.cc \
     src/core/lib/iomgr/timer_manager.cc \
-    src/core/lib/iomgr/timer_uv.cc \
     src/core/lib/iomgr/udp_server.cc \
     src/core/lib/iomgr/unix_sockets_posix.cc \
     src/core/lib/iomgr/unix_sockets_posix_noop.cc \
@@ -2066,8 +2056,8 @@ $(LIBDIR)/$(CONFIG)/libgrpc_unsecure$(SHARED_VERSION_CORE).$(SHARED_EXT_CORE): $
 ifeq ($(SYSTEM),Darwin)
        $(Q) $(LDXX) $(LDFLAGS) -L$(LIBDIR)/$(CONFIG) -install_name $(SHARED_PREFIX)grpc_unsecure$(SHARED_VERSION_CORE).$(SHARED_EXT_CORE) -dynamiclib -o $(LIBDIR)/$(CONFIG)/libgrpc_unsecure$(SHARED_VERSION_CORE).$(SHARED_EXT_CORE) $(LIBGRPC_UNSECURE_OBJS) $(LIBDIR)/$(CONFIG)/libgpr.a $(LIBDIR)/$(CONFIG)/libaddress_sorting.a $(ZLIB_MERGE_LIBS) $(CARES_MERGE_LIBS) $(ADDRESS_SORTING_MERGE_LIBS) $(RE2_MERGE_LIBS) $(UPB_MERGE_LIBS) $(GRPC_ABSEIL_MERGE_LIBS) $(LDLIBS)
 else
-       $(Q) $(LDXX) $(LDFLAGS) -L$(LIBDIR)/$(CONFIG) -shared -Wl,-soname,libgrpc_unsecure.so.18 -o $(LIBDIR)/$(CONFIG)/libgrpc_unsecure$(SHARED_VERSION_CORE).$(SHARED_EXT_CORE) $(LIBGRPC_UNSECURE_OBJS) $(LIBDIR)/$(CONFIG)/libgpr.a $(LIBDIR)/$(CONFIG)/libaddress_sorting.a $(ZLIB_MERGE_LIBS) $(CARES_MERGE_LIBS) $(ADDRESS_SORTING_MERGE_LIBS) $(RE2_MERGE_LIBS) $(UPB_MERGE_LIBS) $(GRPC_ABSEIL_MERGE_LIBS) $(LDLIBS)
-       $(Q) ln -sf $(SHARED_PREFIX)grpc_unsecure$(SHARED_VERSION_CORE).$(SHARED_EXT_CORE) $(LIBDIR)/$(CONFIG)/libgrpc_unsecure$(SHARED_VERSION_CORE).so.18
+       $(Q) $(LDXX) $(LDFLAGS) -L$(LIBDIR)/$(CONFIG) -shared -Wl,-soname,libgrpc_unsecure.so.19 -o $(LIBDIR)/$(CONFIG)/libgrpc_unsecure$(SHARED_VERSION_CORE).$(SHARED_EXT_CORE) $(LIBGRPC_UNSECURE_OBJS) $(LIBDIR)/$(CONFIG)/libgpr.a $(LIBDIR)/$(CONFIG)/libaddress_sorting.a $(ZLIB_MERGE_LIBS) $(CARES_MERGE_LIBS) $(ADDRESS_SORTING_MERGE_LIBS) $(RE2_MERGE_LIBS) $(UPB_MERGE_LIBS) $(GRPC_ABSEIL_MERGE_LIBS) $(LDLIBS)
+       $(Q) ln -sf $(SHARED_PREFIX)grpc_unsecure$(SHARED_VERSION_CORE).$(SHARED_EXT_CORE) $(LIBDIR)/$(CONFIG)/libgrpc_unsecure$(SHARED_VERSION_CORE).so.19
        $(Q) ln -sf $(SHARED_PREFIX)grpc_unsecure$(SHARED_VERSION_CORE).$(SHARED_EXT_CORE) $(LIBDIR)/$(CONFIG)/libgrpc_unsecure$(SHARED_VERSION_CORE).so
 endif
 endif
@@ -2318,6 +2308,7 @@ LIBBORINGSSL_SRC = \
     third_party/boringssl-with-bazel/src/ssl/dtls_method.cc \
     third_party/boringssl-with-bazel/src/ssl/dtls_record.cc \
     third_party/boringssl-with-bazel/src/ssl/encrypted_client_hello.cc \
+    third_party/boringssl-with-bazel/src/ssl/extensions.cc \
     third_party/boringssl-with-bazel/src/ssl/handoff.cc \
     third_party/boringssl-with-bazel/src/ssl/handshake.cc \
     third_party/boringssl-with-bazel/src/ssl/handshake_client.cc \
@@ -2340,7 +2331,6 @@ LIBBORINGSSL_SRC = \
     third_party/boringssl-with-bazel/src/ssl/ssl_versions.cc \
     third_party/boringssl-with-bazel/src/ssl/ssl_x509.cc \
     third_party/boringssl-with-bazel/src/ssl/t1_enc.cc \
-    third_party/boringssl-with-bazel/src/ssl/t1_lib.cc \
     third_party/boringssl-with-bazel/src/ssl/tls13_both.cc \
     third_party/boringssl-with-bazel/src/ssl/tls13_client.cc \
     third_party/boringssl-with-bazel/src/ssl/tls13_enc.cc \
@@ -2462,8 +2452,8 @@ $(LIBDIR)/$(CONFIG)/libupb$(SHARED_VERSION_CORE).$(SHARED_EXT_CORE): $(LIBUPB_OB
 ifeq ($(SYSTEM),Darwin)
        $(Q) $(LDXX) $(LDFLAGS) -L$(LIBDIR)/$(CONFIG) -install_name $(SHARED_PREFIX)upb$(SHARED_VERSION_CORE).$(SHARED_EXT_CORE) -dynamiclib -o $(LIBDIR)/$(CONFIG)/libupb$(SHARED_VERSION_CORE).$(SHARED_EXT_CORE) $(LIBUPB_OBJS) $(ZLIB_MERGE_LIBS) $(CARES_MERGE_LIBS) $(ADDRESS_SORTING_MERGE_LIBS) $(RE2_MERGE_LIBS) $(UPB_MERGE_LIBS) $(GRPC_ABSEIL_MERGE_LIBS) $(LDLIBS)
 else
-       $(Q) $(LDXX) $(LDFLAGS) -L$(LIBDIR)/$(CONFIG) -shared -Wl,-soname,libupb.so.18 -o $(LIBDIR)/$(CONFIG)/libupb$(SHARED_VERSION_CORE).$(SHARED_EXT_CORE) $(LIBUPB_OBJS) $(ZLIB_MERGE_LIBS) $(CARES_MERGE_LIBS) $(ADDRESS_SORTING_MERGE_LIBS) $(RE2_MERGE_LIBS) $(UPB_MERGE_LIBS) $(GRPC_ABSEIL_MERGE_LIBS) $(LDLIBS)
-       $(Q) ln -sf $(SHARED_PREFIX)upb$(SHARED_VERSION_CORE).$(SHARED_EXT_CORE) $(LIBDIR)/$(CONFIG)/libupb$(SHARED_VERSION_CORE).so.18
+       $(Q) $(LDXX) $(LDFLAGS) -L$(LIBDIR)/$(CONFIG) -shared -Wl,-soname,libupb.so.19 -o $(LIBDIR)/$(CONFIG)/libupb$(SHARED_VERSION_CORE).$(SHARED_EXT_CORE) $(LIBUPB_OBJS) $(ZLIB_MERGE_LIBS) $(CARES_MERGE_LIBS) $(ADDRESS_SORTING_MERGE_LIBS) $(RE2_MERGE_LIBS) $(UPB_MERGE_LIBS) $(GRPC_ABSEIL_MERGE_LIBS) $(LDLIBS)
+       $(Q) ln -sf $(SHARED_PREFIX)upb$(SHARED_VERSION_CORE).$(SHARED_EXT_CORE) $(LIBDIR)/$(CONFIG)/libupb$(SHARED_VERSION_CORE).so.19
        $(Q) ln -sf $(SHARED_PREFIX)upb$(SHARED_VERSION_CORE).$(SHARED_EXT_CORE) $(LIBDIR)/$(CONFIG)/libupb$(SHARED_VERSION_CORE).so
 endif
 endif
@@ -2910,6 +2900,7 @@ src/core/lib/http/httpcli_security_connector.cc: $(OPENSSL_DEP)
 src/core/lib/matchers/matchers.cc: $(OPENSSL_DEP)
 src/core/lib/security/authorization/authorization_policy_provider_vtable.cc: $(OPENSSL_DEP)
 src/core/lib/security/authorization/evaluate_args.cc: $(OPENSSL_DEP)
+src/core/lib/security/authorization/sdk_server_authz_filter.cc: $(OPENSSL_DEP)
 src/core/lib/security/context/security_context.cc: $(OPENSSL_DEP)
 src/core/lib/security/credentials/alts/alts_credentials.cc: $(OPENSSL_DEP)
 src/core/lib/security/credentials/alts/check_gcp_environment.cc: $(OPENSSL_DEP)
index 9f7b7e5..2288b60 100644 (file)
--- a/WORKSPACE
+++ b/WORKSPACE
@@ -91,6 +91,16 @@ android_ndk_repository(
     # https://github.com/bazelbuild/bazel/issues/13421
 )
 
+# Prevents bazel's '...' expansion from including the following folder.
+# This is required because the BUILD file in the following folder
+# will trigger bazel failure when Android SDK is not configured.
+# The targets in the following folder need to be included in APK and will
+# be invoked by binder transport implementation through JNI.
+local_repository(
+    name = "binder_transport_android_helper",
+    path = "./src/core/ext/transport/binder/java",
+)
+
 # Create msan toolchain configuration for remote execution.
 rbe_autoconfig(
     name = "rbe_msan",
index 7bd969b..73f6b1e 100644 (file)
@@ -14,4 +14,4 @@
 
 # AUTO-GENERATED FROM `$REPO_ROOT/templates/_metadata.py.template`!!!
 
-__version__ = """1.40.0"""
+__version__ = """1.41.0"""
index a37a422..ddfb8e3 100644 (file)
@@ -78,6 +78,7 @@ def _update_visibility(visibility):
         "alt_grpc_base_legacy": PRIVATE,
         "alt_grpc++_base_unsecure_legacy": PRIVATE,
         "alts_frame_protector": PRIVATE,
+        "channelz": PRIVATE,
         "client_channel": PRIVATE,
         "debug_location": PRIVATE,
         "endpoint_tests": PRIVATE,
index f8029a5..e2ef402 100644 (file)
@@ -189,11 +189,11 @@ def grpc_deps():
             name = "boringssl",
             # Use github mirror instead of https://boringssl.googlesource.com/boringssl
             # to obtain a boringssl archive with consistent sha256
-            sha256 = "19870fcdbdfc61217ad814077483347a5b2bf4b3bbb5f6c983edac7856a40bbb",
-            strip_prefix = "boringssl-bcc01b6c66b1c6fa2816b108e50a544b757fbd7b",
+            sha256 = "6f640262999cd1fb33cf705922e453e835d2d20f3f06fe0d77f6426c19257308",
+            strip_prefix = "boringssl-fc44652a42b396e1645d5e72aba053349992136a",
             urls = [
-                "https://storage.googleapis.com/grpc-bazel-mirror/github.com/google/boringssl/archive/bcc01b6c66b1c6fa2816b108e50a544b757fbd7b.tar.gz",
-                "https://github.com/google/boringssl/archive/bcc01b6c66b1c6fa2816b108e50a544b757fbd7b.tar.gz",
+                "https://storage.googleapis.com/grpc-bazel-mirror/github.com/google/boringssl/archive/fc44652a42b396e1645d5e72aba053349992136a.tar.gz",
+                "https://github.com/google/boringssl/archive/fc44652a42b396e1645d5e72aba053349992136a.tar.gz",
             ],
         )
 
@@ -212,11 +212,11 @@ def grpc_deps():
     if "com_google_protobuf" not in native.existing_rules():
         http_archive(
             name = "com_google_protobuf",
-            sha256 = "cf63d46ef743f4c30b0e36a562caf83cabed3f10e6ca49eb476913c4655394d5",
-            strip_prefix = "protobuf-436bd7880e458532901c58f4d9d1ea23fa7edd52",
+            sha256 = "dd53cb731b1b6b515d3d679644344bf33bb9f5b88c98187ae5c7be734a665c57",
+            strip_prefix = "protobuf-909a0f36a10075c4b4bc70fdee2c7e32dd612a72",
             urls = [
-                "https://storage.googleapis.com/grpc-bazel-mirror/github.com/protocolbuffers/protobuf/archive/436bd7880e458532901c58f4d9d1ea23fa7edd52.tar.gz",
-                "https://github.com/protocolbuffers/protobuf/archive/436bd7880e458532901c58f4d9d1ea23fa7edd52.tar.gz",
+                "https://storage.googleapis.com/grpc-bazel-mirror/github.com/protocolbuffers/protobuf/archive/909a0f36a10075c4b4bc70fdee2c7e32dd612a72.tar.gz",
+                "https://github.com/protocolbuffers/protobuf/archive/909a0f36a10075c4b4bc70fdee2c7e32dd612a72.tar.gz",
             ],
             patches = ["@com_github_grpc_grpc//third_party:protobuf.patch"],
             patch_args = ["-p1"],
@@ -338,22 +338,22 @@ def grpc_deps():
     if "upb" not in native.existing_rules():
         http_archive(
             name = "upb",
-            sha256 = "c0b97bf91dfea7e8d7579c24e2ecdd02d10b00f3c5defc3dce23d95100d0e664",
-            strip_prefix = "upb-60607da72e89ba0c84c84054d2e562d8b6b61177",
+            sha256 = "6a5f67874af66b239b709c572ac1a5a00fdb1b29beaf13c3e6f79b1ba10dc7c4",
+            strip_prefix = "upb-2de300726a1ba2de9a468468dc5ff9ed17a3215f",
             urls = [
-                "https://storage.googleapis.com/grpc-bazel-mirror/github.com/protocolbuffers/upb/archive/60607da72e89ba0c84c84054d2e562d8b6b61177.tar.gz",
-                "https://github.com/protocolbuffers/upb/archive/60607da72e89ba0c84c84054d2e562d8b6b61177.tar.gz",
+                "https://storage.googleapis.com/grpc-bazel-mirror/github.com/protocolbuffers/upb/archive/2de300726a1ba2de9a468468dc5ff9ed17a3215f.tar.gz",
+                "https://github.com/protocolbuffers/upb/archive/2de300726a1ba2de9a468468dc5ff9ed17a3215f.tar.gz",
             ],
         )
 
     if "envoy_api" not in native.existing_rules():
         http_archive(
             name = "envoy_api",
-            sha256 = "68343216fe214b6fd420672e04da8dfe10ae87bb98528239dd16c848016a8a48",
-            strip_prefix = "data-plane-api-df3b1ab2773147f292c4f175f790c35448328161",
+            sha256 = "330f2f9c938fc038b7ab438919b692d30cdfba3cf596e7824410f88da16c30b5",
+            strip_prefix = "data-plane-api-2f0d081fab0b0823f088c6e368f40e1992f46fcd",
             urls = [
-                "https://storage.googleapis.com/grpc-bazel-mirror/github.com/envoyproxy/data-plane-api/archive/df3b1ab2773147f292c4f175f790c35448328161.tar.gz",
-                "https://github.com/envoyproxy/data-plane-api/archive/df3b1ab2773147f292c4f175f790c35448328161.tar.gz",
+                "https://storage.googleapis.com/grpc-bazel-mirror/github.com/envoyproxy/data-plane-api/archive/2f0d081fab0b0823f088c6e368f40e1992f46fcd.tar.gz",
+                "https://github.com/envoyproxy/data-plane-api/archive/2f0d081fab0b0823f088c6e368f40e1992f46fcd.tar.gz",
             ],
         )
 
index 32ee883..e09b30b 100644 (file)
@@ -133,6 +133,11 @@ libs:
   language: c
   public_headers: []
   headers:
+  - src/core/lib/security/authorization/grpc_authorization_engine.h
+  - src/core/lib/security/authorization/grpc_authorization_policy_provider.h
+  - src/core/lib/security/authorization/matchers.h
+  - src/core/lib/security/authorization/rbac_policy.h
+  - src/core/lib/security/authorization/rbac_translator.h
   - test/core/end2end/cq_verifier.h
   - test/core/end2end/data/ssl_test_data.h
   - test/core/end2end/end2end_tests.h
@@ -142,6 +147,11 @@ libs:
   - test/core/end2end/tests/cancel_test_helpers.h
   - test/core/util/test_lb_policies.h
   src:
+  - src/core/lib/security/authorization/grpc_authorization_engine.cc
+  - src/core/lib/security/authorization/grpc_authorization_policy_provider.cc
+  - src/core/lib/security/authorization/matchers.cc
+  - src/core/lib/security/authorization/rbac_policy.cc
+  - src/core/lib/security/authorization/rbac_translator.cc
   - test/core/end2end/cq_verifier.cc
   - test/core/end2end/data/client_certs.cc
   - test/core/end2end/data/server1_cert.cc
@@ -226,6 +236,7 @@ libs:
   - test/core/end2end/tests/retry_streaming_succeeds_before_replay_finished.cc
   - test/core/end2end/tests/retry_throttled.cc
   - test/core/end2end/tests/retry_too_many_attempts.cc
+  - test/core/end2end/tests/sdk_authz.cc
   - test/core/end2end/tests/server_finishes_request.cc
   - test/core/end2end/tests/server_streaming.cc
   - test/core/end2end/tests/shutdown_finishes_calls.cc
@@ -310,14 +321,10 @@ libs:
   - src/core/lib/gpr/string_windows.h
   - src/core/lib/gpr/time_precise.h
   - src/core/lib/gpr/tls.h
-  - src/core/lib/gpr/tls_gcc.h
-  - src/core/lib/gpr/tls_msvc.h
-  - src/core/lib/gpr/tls_pthread.h
-  - src/core/lib/gpr/tls_stdcpp.h
   - src/core/lib/gpr/tmpfile.h
   - src/core/lib/gpr/useful.h
   - src/core/lib/gprpp/arena.h
-  - src/core/lib/gprpp/atomic.h
+  - src/core/lib/gprpp/construct_destruct.h
   - src/core/lib/gprpp/debug_location.h
   - src/core/lib/gprpp/examine_stack.h
   - src/core/lib/gprpp/fork.h
@@ -374,7 +381,6 @@ libs:
   - src/core/lib/gpr/time_posix.cc
   - src/core/lib/gpr/time_precise.cc
   - src/core/lib/gpr/time_windows.cc
-  - src/core/lib/gpr/tls_pthread.cc
   - src/core/lib/gpr/tmpfile_msys.cc
   - src/core/lib/gpr/tmpfile_posix.cc
   - src/core/lib/gpr/tmpfile_windows.cc
@@ -506,13 +512,18 @@ libs:
   - src/core/ext/transport/chttp2/transport/frame_rst_stream.h
   - src/core/ext/transport/chttp2/transport/frame_settings.h
   - src/core/ext/transport/chttp2/transport/frame_window_update.h
+  - src/core/ext/transport/chttp2/transport/hpack_constants.h
   - src/core/ext/transport/chttp2/transport/hpack_encoder.h
+  - src/core/ext/transport/chttp2/transport/hpack_encoder_index.h
+  - src/core/ext/transport/chttp2/transport/hpack_encoder_table.h
   - src/core/ext/transport/chttp2/transport/hpack_parser.h
-  - src/core/ext/transport/chttp2/transport/hpack_table.h
+  - src/core/ext/transport/chttp2/transport/hpack_parser_table.h
+  - src/core/ext/transport/chttp2/transport/hpack_utils.h
   - src/core/ext/transport/chttp2/transport/http2_settings.h
   - src/core/ext/transport/chttp2/transport/huffsyms.h
   - src/core/ext/transport/chttp2/transport/incoming_metadata.h
   - src/core/ext/transport/chttp2/transport/internal.h
+  - src/core/ext/transport/chttp2/transport/popularity_count.h
   - src/core/ext/transport/chttp2/transport/stream_map.h
   - src/core/ext/transport/chttp2/transport/varint.h
   - src/core/ext/transport/inproc/inproc_transport.h
@@ -736,14 +747,18 @@ libs:
   - src/core/lib/compression/stream_compression.h
   - src/core/lib/compression/stream_compression_gzip.h
   - src/core/lib/compression/stream_compression_identity.h
+  - src/core/lib/config/core_configuration.h
   - src/core/lib/debug/stats.h
   - src/core/lib/debug/stats_data.h
   - src/core/lib/debug/trace.h
   - src/core/lib/event_engine/endpoint_config_internal.h
   - src/core/lib/event_engine/sockaddr.h
-  - src/core/lib/gprpp/atomic.h
+  - src/core/lib/gprpp/atomic_utils.h
+  - src/core/lib/gprpp/bitset.h
   - src/core/lib/gprpp/dual_ref_counted.h
+  - src/core/lib/gprpp/match.h
   - src/core/lib/gprpp/orphanable.h
+  - src/core/lib/gprpp/overload.h
   - src/core/lib/gprpp/ref_counted.h
   - src/core/lib/gprpp/ref_counted_ptr.h
   - src/core/lib/http/format_request.h
@@ -794,7 +809,6 @@ libs:
   - src/core/lib/iomgr/pollset_set.h
   - src/core/lib/iomgr/pollset_set_custom.h
   - src/core/lib/iomgr/pollset_set_windows.h
-  - src/core/lib/iomgr/pollset_uv.h
   - src/core/lib/iomgr/pollset_windows.h
   - src/core/lib/iomgr/port.h
   - src/core/lib/iomgr/python_util.h
@@ -802,7 +816,6 @@ libs:
   - src/core/lib/iomgr/resolve_address_custom.h
   - src/core/lib/iomgr/resource_quota.h
   - src/core/lib/iomgr/sockaddr.h
-  - src/core/lib/iomgr/sockaddr_custom.h
   - src/core/lib/iomgr/sockaddr_posix.h
   - src/core/lib/iomgr/sockaddr_windows.h
   - src/core/lib/iomgr/socket_factory_posix.h
@@ -835,6 +848,7 @@ libs:
   - src/core/lib/security/authorization/authorization_engine.h
   - src/core/lib/security/authorization/authorization_policy_provider.h
   - src/core/lib/security/authorization/evaluate_args.h
+  - src/core/lib/security/authorization/sdk_server_authz_filter.h
   - src/core/lib/security/context/security_context.h
   - src/core/lib/security/credentials/alts/alts_credentials.h
   - src/core/lib/security/credentials/alts/check_gcp_environment.h
@@ -979,12 +993,10 @@ libs:
   - src/core/ext/filters/client_channel/resolver.cc
   - src/core/ext/filters/client_channel/resolver/dns/c_ares/dns_resolver_ares.cc
   - src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_event_engine.cc
-  - src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_libuv.cc
   - src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_posix.cc
   - src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_windows.cc
   - src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper.cc
   - src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_event_engine.cc
-  - src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_libuv.cc
   - src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_posix.cc
   - src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_windows.cc
   - src/core/ext/filters/client_channel/resolver/dns/dns_resolver_selection.cc
@@ -1042,8 +1054,10 @@ libs:
   - src/core/ext/transport/chttp2/transport/frame_settings.cc
   - src/core/ext/transport/chttp2/transport/frame_window_update.cc
   - src/core/ext/transport/chttp2/transport/hpack_encoder.cc
+  - src/core/ext/transport/chttp2/transport/hpack_encoder_table.cc
   - src/core/ext/transport/chttp2/transport/hpack_parser.cc
-  - src/core/ext/transport/chttp2/transport/hpack_table.cc
+  - src/core/ext/transport/chttp2/transport/hpack_parser_table.cc
+  - src/core/ext/transport/chttp2/transport/hpack_utils.cc
   - src/core/ext/transport/chttp2/transport/http2_settings.cc
   - src/core/ext/transport/chttp2/transport/huffsyms.cc
   - src/core/ext/transport/chttp2/transport/incoming_metadata.cc
@@ -1270,6 +1284,7 @@ libs:
   - src/core/lib/compression/stream_compression.cc
   - src/core/lib/compression/stream_compression_gzip.cc
   - src/core/lib/compression/stream_compression_identity.cc
+  - src/core/lib/config/core_configuration.cc
   - src/core/lib/debug/stats.cc
   - src/core/lib/debug/stats_data.cc
   - src/core/lib/debug/trace.cc
@@ -1289,7 +1304,6 @@ libs:
   - src/core/lib/iomgr/endpoint_cfstream.cc
   - src/core/lib/iomgr/endpoint_pair_event_engine.cc
   - src/core/lib/iomgr/endpoint_pair_posix.cc
-  - src/core/lib/iomgr/endpoint_pair_uv.cc
   - src/core/lib/iomgr/endpoint_pair_windows.cc
   - src/core/lib/iomgr/error.cc
   - src/core/lib/iomgr/error_cfstream.cc
@@ -1325,7 +1339,6 @@ libs:
   - src/core/lib/iomgr/iomgr_internal.cc
   - src/core/lib/iomgr/iomgr_posix.cc
   - src/core/lib/iomgr/iomgr_posix_cfstream.cc
-  - src/core/lib/iomgr/iomgr_uv.cc
   - src/core/lib/iomgr/iomgr_windows.cc
   - src/core/lib/iomgr/is_epollexclusive_available.cc
   - src/core/lib/iomgr/load_file.cc
@@ -1336,7 +1349,6 @@ libs:
   - src/core/lib/iomgr/pollset_set.cc
   - src/core/lib/iomgr/pollset_set_custom.cc
   - src/core/lib/iomgr/pollset_set_windows.cc
-  - src/core/lib/iomgr/pollset_uv.cc
   - src/core/lib/iomgr/pollset_windows.cc
   - src/core/lib/iomgr/resolve_address.cc
   - src/core/lib/iomgr/resolve_address_custom.cc
@@ -1348,7 +1360,6 @@ libs:
   - src/core/lib/iomgr/socket_utils_common_posix.cc
   - src/core/lib/iomgr/socket_utils_linux.cc
   - src/core/lib/iomgr/socket_utils_posix.cc
-  - src/core/lib/iomgr/socket_utils_uv.cc
   - src/core/lib/iomgr/socket_utils_windows.cc
   - src/core/lib/iomgr/socket_windows.cc
   - src/core/lib/iomgr/tcp_client.cc
@@ -1365,7 +1376,6 @@ libs:
   - src/core/lib/iomgr/tcp_server_utils_posix_ifaddrs.cc
   - src/core/lib/iomgr/tcp_server_utils_posix_noifaddrs.cc
   - src/core/lib/iomgr/tcp_server_windows.cc
-  - src/core/lib/iomgr/tcp_uv.cc
   - src/core/lib/iomgr/tcp_windows.cc
   - src/core/lib/iomgr/time_averaged_stats.cc
   - src/core/lib/iomgr/timer.cc
@@ -1373,7 +1383,6 @@ libs:
   - src/core/lib/iomgr/timer_generic.cc
   - src/core/lib/iomgr/timer_heap.cc
   - src/core/lib/iomgr/timer_manager.cc
-  - src/core/lib/iomgr/timer_uv.cc
   - src/core/lib/iomgr/udp_server.cc
   - src/core/lib/iomgr/unix_sockets_posix.cc
   - src/core/lib/iomgr/unix_sockets_posix_noop.cc
@@ -1388,6 +1397,7 @@ libs:
   - src/core/lib/matchers/matchers.cc
   - src/core/lib/security/authorization/authorization_policy_provider_vtable.cc
   - src/core/lib/security/authorization/evaluate_args.cc
+  - src/core/lib/security/authorization/sdk_server_authz_filter.cc
   - src/core/lib/security/context/security_context.cc
   - src/core/lib/security/credentials/alts/alts_credentials.cc
   - src/core/lib/security/credentials/alts/check_gcp_environment.cc
@@ -1514,6 +1524,7 @@ libs:
   - absl/container:inlined_vector
   - absl/functional:bind_front
   - absl/status:statusor
+  - absl/types:variant
   - gpr
   - libssl
   - address_sorting
@@ -1547,6 +1558,7 @@ libs:
   - test/core/util/port_server_client.h
   - test/core/util/reconnect_server.h
   - test/core/util/resolve_localhost_ip46.h
+  - test/core/util/resource_user_util.h
   - test/core/util/slice_splitter.h
   - test/core/util/stack_tracer.h
   - test/core/util/subprocess.h
@@ -1569,6 +1581,7 @@ libs:
   - test/core/util/port_server_client.cc
   - test/core/util/reconnect_server.cc
   - test/core/util/resolve_localhost_ip46.cc
+  - test/core/util/resource_user_util.cc
   - test/core/util/slice_splitter.cc
   - test/core/util/stack_tracer.cc
   - test/core/util/subprocess_posix.cc
@@ -1602,6 +1615,7 @@ libs:
   - test/core/util/port_server_client.h
   - test/core/util/reconnect_server.h
   - test/core/util/resolve_localhost_ip46.h
+  - test/core/util/resource_user_util.h
   - test/core/util/slice_splitter.h
   - test/core/util/stack_tracer.h
   - test/core/util/subprocess.h
@@ -1623,6 +1637,7 @@ libs:
   - test/core/util/port_server_client.cc
   - test/core/util/reconnect_server.cc
   - test/core/util/resolve_localhost_ip46.cc
+  - test/core/util/resource_user_util.cc
   - test/core/util/slice_splitter.cc
   - test/core/util/stack_tracer.cc
   - test/core/util/subprocess_posix.cc
@@ -1733,13 +1748,18 @@ libs:
   - src/core/ext/transport/chttp2/transport/frame_rst_stream.h
   - src/core/ext/transport/chttp2/transport/frame_settings.h
   - src/core/ext/transport/chttp2/transport/frame_window_update.h
+  - src/core/ext/transport/chttp2/transport/hpack_constants.h
   - src/core/ext/transport/chttp2/transport/hpack_encoder.h
+  - src/core/ext/transport/chttp2/transport/hpack_encoder_index.h
+  - src/core/ext/transport/chttp2/transport/hpack_encoder_table.h
   - src/core/ext/transport/chttp2/transport/hpack_parser.h
-  - src/core/ext/transport/chttp2/transport/hpack_table.h
+  - src/core/ext/transport/chttp2/transport/hpack_parser_table.h
+  - src/core/ext/transport/chttp2/transport/hpack_utils.h
   - src/core/ext/transport/chttp2/transport/http2_settings.h
   - src/core/ext/transport/chttp2/transport/huffsyms.h
   - src/core/ext/transport/chttp2/transport/incoming_metadata.h
   - src/core/ext/transport/chttp2/transport/internal.h
+  - src/core/ext/transport/chttp2/transport/popularity_count.h
   - src/core/ext/transport/chttp2/transport/stream_map.h
   - src/core/ext/transport/chttp2/transport/varint.h
   - src/core/ext/transport/inproc/inproc_transport.h
@@ -1771,14 +1791,18 @@ libs:
   - src/core/lib/compression/stream_compression.h
   - src/core/lib/compression/stream_compression_gzip.h
   - src/core/lib/compression/stream_compression_identity.h
+  - src/core/lib/config/core_configuration.h
   - src/core/lib/debug/stats.h
   - src/core/lib/debug/stats_data.h
   - src/core/lib/debug/trace.h
   - src/core/lib/event_engine/endpoint_config_internal.h
   - src/core/lib/event_engine/sockaddr.h
-  - src/core/lib/gprpp/atomic.h
+  - src/core/lib/gprpp/atomic_utils.h
+  - src/core/lib/gprpp/bitset.h
   - src/core/lib/gprpp/dual_ref_counted.h
+  - src/core/lib/gprpp/match.h
   - src/core/lib/gprpp/orphanable.h
+  - src/core/lib/gprpp/overload.h
   - src/core/lib/gprpp/ref_counted.h
   - src/core/lib/gprpp/ref_counted_ptr.h
   - src/core/lib/http/format_request.h
@@ -1829,7 +1853,6 @@ libs:
   - src/core/lib/iomgr/pollset_set.h
   - src/core/lib/iomgr/pollset_set_custom.h
   - src/core/lib/iomgr/pollset_set_windows.h
-  - src/core/lib/iomgr/pollset_uv.h
   - src/core/lib/iomgr/pollset_windows.h
   - src/core/lib/iomgr/port.h
   - src/core/lib/iomgr/python_util.h
@@ -1837,7 +1860,6 @@ libs:
   - src/core/lib/iomgr/resolve_address_custom.h
   - src/core/lib/iomgr/resource_quota.h
   - src/core/lib/iomgr/sockaddr.h
-  - src/core/lib/iomgr/sockaddr_custom.h
   - src/core/lib/iomgr/sockaddr_posix.h
   - src/core/lib/iomgr/sockaddr_windows.h
   - src/core/lib/iomgr/socket_factory_posix.h
@@ -1936,12 +1958,10 @@ libs:
   - src/core/ext/filters/client_channel/resolver.cc
   - src/core/ext/filters/client_channel/resolver/dns/c_ares/dns_resolver_ares.cc
   - src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_event_engine.cc
-  - src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_libuv.cc
   - src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_posix.cc
   - src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_windows.cc
   - src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper.cc
   - src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_event_engine.cc
-  - src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_libuv.cc
   - src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_posix.cc
   - src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_windows.cc
   - src/core/ext/filters/client_channel/resolver/dns/dns_resolver_selection.cc
@@ -1995,8 +2015,10 @@ libs:
   - src/core/ext/transport/chttp2/transport/frame_settings.cc
   - src/core/ext/transport/chttp2/transport/frame_window_update.cc
   - src/core/ext/transport/chttp2/transport/hpack_encoder.cc
+  - src/core/ext/transport/chttp2/transport/hpack_encoder_table.cc
   - src/core/ext/transport/chttp2/transport/hpack_parser.cc
-  - src/core/ext/transport/chttp2/transport/hpack_table.cc
+  - src/core/ext/transport/chttp2/transport/hpack_parser_table.cc
+  - src/core/ext/transport/chttp2/transport/hpack_utils.cc
   - src/core/ext/transport/chttp2/transport/http2_settings.cc
   - src/core/ext/transport/chttp2/transport/huffsyms.cc
   - src/core/ext/transport/chttp2/transport/incoming_metadata.cc
@@ -2032,6 +2054,7 @@ libs:
   - src/core/lib/compression/stream_compression.cc
   - src/core/lib/compression/stream_compression_gzip.cc
   - src/core/lib/compression/stream_compression_identity.cc
+  - src/core/lib/config/core_configuration.cc
   - src/core/lib/debug/stats.cc
   - src/core/lib/debug/stats_data.cc
   - src/core/lib/debug/trace.cc
@@ -2050,7 +2073,6 @@ libs:
   - src/core/lib/iomgr/endpoint_cfstream.cc
   - src/core/lib/iomgr/endpoint_pair_event_engine.cc
   - src/core/lib/iomgr/endpoint_pair_posix.cc
-  - src/core/lib/iomgr/endpoint_pair_uv.cc
   - src/core/lib/iomgr/endpoint_pair_windows.cc
   - src/core/lib/iomgr/error.cc
   - src/core/lib/iomgr/error_cfstream.cc
@@ -2086,7 +2108,6 @@ libs:
   - src/core/lib/iomgr/iomgr_internal.cc
   - src/core/lib/iomgr/iomgr_posix.cc
   - src/core/lib/iomgr/iomgr_posix_cfstream.cc
-  - src/core/lib/iomgr/iomgr_uv.cc
   - src/core/lib/iomgr/iomgr_windows.cc
   - src/core/lib/iomgr/is_epollexclusive_available.cc
   - src/core/lib/iomgr/load_file.cc
@@ -2097,7 +2118,6 @@ libs:
   - src/core/lib/iomgr/pollset_set.cc
   - src/core/lib/iomgr/pollset_set_custom.cc
   - src/core/lib/iomgr/pollset_set_windows.cc
-  - src/core/lib/iomgr/pollset_uv.cc
   - src/core/lib/iomgr/pollset_windows.cc
   - src/core/lib/iomgr/resolve_address.cc
   - src/core/lib/iomgr/resolve_address_custom.cc
@@ -2109,7 +2129,6 @@ libs:
   - src/core/lib/iomgr/socket_utils_common_posix.cc
   - src/core/lib/iomgr/socket_utils_linux.cc
   - src/core/lib/iomgr/socket_utils_posix.cc
-  - src/core/lib/iomgr/socket_utils_uv.cc
   - src/core/lib/iomgr/socket_utils_windows.cc
   - src/core/lib/iomgr/socket_windows.cc
   - src/core/lib/iomgr/tcp_client.cc
@@ -2126,7 +2145,6 @@ libs:
   - src/core/lib/iomgr/tcp_server_utils_posix_ifaddrs.cc
   - src/core/lib/iomgr/tcp_server_utils_posix_noifaddrs.cc
   - src/core/lib/iomgr/tcp_server_windows.cc
-  - src/core/lib/iomgr/tcp_uv.cc
   - src/core/lib/iomgr/tcp_windows.cc
   - src/core/lib/iomgr/time_averaged_stats.cc
   - src/core/lib/iomgr/timer.cc
@@ -2134,7 +2152,6 @@ libs:
   - src/core/lib/iomgr/timer_generic.cc
   - src/core/lib/iomgr/timer_heap.cc
   - src/core/lib/iomgr/timer_manager.cc
-  - src/core/lib/iomgr/timer_uv.cc
   - src/core/lib/iomgr/udp_server.cc
   - src/core/lib/iomgr/unix_sockets_posix.cc
   - src/core/lib/iomgr/unix_sockets_posix_noop.cc
@@ -2194,6 +2211,7 @@ libs:
   - absl/container:inlined_vector
   - absl/functional:bind_front
   - absl/status:statusor
+  - absl/types:variant
   - gpr
   - address_sorting
   baselib: true
@@ -3509,21 +3527,21 @@ targets:
   deps:
   - grpc_test_util
   uses_polling: false
-- name: hpack_parser_test
+- name: hpack_parser_table_test
   build: test
   language: c
   headers: []
   src:
-  - test/core/transport/chttp2/hpack_parser_test.cc
+  - test/core/transport/chttp2/hpack_parser_table_test.cc
   deps:
   - grpc_test_util
   uses_polling: false
-- name: hpack_table_test
+- name: hpack_parser_test
   build: test
   language: c
   headers: []
   src:
-  - test/core/transport/chttp2/hpack_table_test.cc
+  - test/core/transport/chttp2/hpack_parser_test.cc
   deps:
   - grpc_test_util
   uses_polling: false
@@ -4125,15 +4143,6 @@ targets:
   deps:
   - grpc_test_util
   uses_polling: false
-- name: tls_test
-  build: test
-  language: c
-  headers: []
-  src:
-  - test/core/gpr/tls_test.cc
-  deps:
-  - grpc_test_util
-  uses_polling: false
 - name: transport_security_common_api_test
   build: test
   language: c
@@ -4180,6 +4189,141 @@ targets:
   deps:
   - grpc_test_util
   uses_polling: false
+- name: activity_test
+  gtest: true
+  build: test
+  language: c++
+  headers:
+  - src/core/ext/upb-generated/google/api/annotations.upb.h
+  - src/core/ext/upb-generated/google/api/expr/v1alpha1/checked.upb.h
+  - src/core/ext/upb-generated/google/api/expr/v1alpha1/syntax.upb.h
+  - src/core/ext/upb-generated/google/api/http.upb.h
+  - src/core/ext/upb-generated/google/protobuf/any.upb.h
+  - src/core/ext/upb-generated/google/protobuf/duration.upb.h
+  - src/core/ext/upb-generated/google/protobuf/empty.upb.h
+  - src/core/ext/upb-generated/google/protobuf/struct.upb.h
+  - src/core/ext/upb-generated/google/protobuf/timestamp.upb.h
+  - src/core/ext/upb-generated/google/protobuf/wrappers.upb.h
+  - src/core/ext/upb-generated/google/rpc/status.upb.h
+  - src/core/lib/gpr/alloc.h
+  - src/core/lib/gpr/env.h
+  - src/core/lib/gpr/murmur_hash.h
+  - src/core/lib/gpr/spinlock.h
+  - src/core/lib/gpr/string.h
+  - src/core/lib/gpr/string_windows.h
+  - src/core/lib/gpr/time_precise.h
+  - src/core/lib/gpr/tls.h
+  - src/core/lib/gpr/tmpfile.h
+  - src/core/lib/gpr/useful.h
+  - src/core/lib/gprpp/arena.h
+  - src/core/lib/gprpp/atomic_utils.h
+  - src/core/lib/gprpp/bitset.h
+  - src/core/lib/gprpp/construct_destruct.h
+  - src/core/lib/gprpp/debug_location.h
+  - src/core/lib/gprpp/examine_stack.h
+  - src/core/lib/gprpp/fork.h
+  - src/core/lib/gprpp/global_config.h
+  - src/core/lib/gprpp/global_config_custom.h
+  - src/core/lib/gprpp/global_config_env.h
+  - src/core/lib/gprpp/global_config_generic.h
+  - src/core/lib/gprpp/host_port.h
+  - src/core/lib/gprpp/manual_constructor.h
+  - src/core/lib/gprpp/memory.h
+  - src/core/lib/gprpp/mpscq.h
+  - src/core/lib/gprpp/stat.h
+  - src/core/lib/gprpp/status_helper.h
+  - src/core/lib/gprpp/sync.h
+  - src/core/lib/gprpp/thd.h
+  - src/core/lib/gprpp/time_util.h
+  - src/core/lib/profiling/timers.h
+  - src/core/lib/promise/activity.h
+  - src/core/lib/promise/context.h
+  - src/core/lib/promise/detail/basic_join.h
+  - src/core/lib/promise/detail/basic_seq.h
+  - src/core/lib/promise/detail/promise_factory.h
+  - src/core/lib/promise/detail/promise_like.h
+  - src/core/lib/promise/detail/status.h
+  - src/core/lib/promise/detail/switch.h
+  - src/core/lib/promise/join.h
+  - src/core/lib/promise/poll.h
+  - src/core/lib/promise/promise.h
+  - src/core/lib/promise/seq.h
+  - src/core/lib/promise/wait_set.h
+  src:
+  - src/core/ext/upb-generated/google/api/annotations.upb.c
+  - src/core/ext/upb-generated/google/api/expr/v1alpha1/checked.upb.c
+  - src/core/ext/upb-generated/google/api/expr/v1alpha1/syntax.upb.c
+  - src/core/ext/upb-generated/google/api/http.upb.c
+  - src/core/ext/upb-generated/google/protobuf/any.upb.c
+  - src/core/ext/upb-generated/google/protobuf/duration.upb.c
+  - src/core/ext/upb-generated/google/protobuf/empty.upb.c
+  - src/core/ext/upb-generated/google/protobuf/struct.upb.c
+  - src/core/ext/upb-generated/google/protobuf/timestamp.upb.c
+  - src/core/ext/upb-generated/google/protobuf/wrappers.upb.c
+  - src/core/ext/upb-generated/google/rpc/status.upb.c
+  - src/core/lib/gpr/alloc.cc
+  - src/core/lib/gpr/atm.cc
+  - src/core/lib/gpr/cpu_iphone.cc
+  - src/core/lib/gpr/cpu_linux.cc
+  - src/core/lib/gpr/cpu_posix.cc
+  - src/core/lib/gpr/cpu_windows.cc
+  - src/core/lib/gpr/env_linux.cc
+  - src/core/lib/gpr/env_posix.cc
+  - src/core/lib/gpr/env_windows.cc
+  - src/core/lib/gpr/log.cc
+  - src/core/lib/gpr/log_android.cc
+  - src/core/lib/gpr/log_linux.cc
+  - src/core/lib/gpr/log_posix.cc
+  - src/core/lib/gpr/log_windows.cc
+  - src/core/lib/gpr/murmur_hash.cc
+  - src/core/lib/gpr/string.cc
+  - src/core/lib/gpr/string_posix.cc
+  - src/core/lib/gpr/string_util_windows.cc
+  - src/core/lib/gpr/string_windows.cc
+  - src/core/lib/gpr/sync.cc
+  - src/core/lib/gpr/sync_abseil.cc
+  - src/core/lib/gpr/sync_posix.cc
+  - src/core/lib/gpr/sync_windows.cc
+  - src/core/lib/gpr/time.cc
+  - src/core/lib/gpr/time_posix.cc
+  - src/core/lib/gpr/time_precise.cc
+  - src/core/lib/gpr/time_windows.cc
+  - src/core/lib/gpr/tmpfile_msys.cc
+  - src/core/lib/gpr/tmpfile_posix.cc
+  - src/core/lib/gpr/tmpfile_windows.cc
+  - src/core/lib/gpr/wrap_memcpy.cc
+  - src/core/lib/gprpp/arena.cc
+  - src/core/lib/gprpp/examine_stack.cc
+  - src/core/lib/gprpp/fork.cc
+  - src/core/lib/gprpp/global_config_env.cc
+  - src/core/lib/gprpp/host_port.cc
+  - src/core/lib/gprpp/mpscq.cc
+  - src/core/lib/gprpp/stat_posix.cc
+  - src/core/lib/gprpp/stat_windows.cc
+  - src/core/lib/gprpp/status_helper.cc
+  - src/core/lib/gprpp/thd_posix.cc
+  - src/core/lib/gprpp/thd_windows.cc
+  - src/core/lib/gprpp/time_util.cc
+  - src/core/lib/profiling/basic_timers.cc
+  - src/core/lib/profiling/stap_timers.cc
+  - src/core/lib/promise/activity.cc
+  - test/core/promise/activity_test.cc
+  deps:
+  - absl/base:base
+  - absl/base:core_headers
+  - absl/container:flat_hash_set
+  - absl/memory:memory
+  - absl/status:status
+  - absl/status:statusor
+  - absl/strings:cord
+  - absl/strings:str_format
+  - absl/strings:strings
+  - absl/synchronization:synchronization
+  - absl/time:time
+  - absl/types:optional
+  - absl/types:variant
+  - upb
+  uses_polling: false
 - name: address_sorting_test
   gtest: true
   build: test
@@ -4409,13 +4553,75 @@ targets:
   - posix
   - mac
   uses_polling: false
-- name: binder_smoke_test
+- name: binder_server_test
   gtest: true
   build: test
   language: c++
-  headers: []
+  headers:
+  - src/core/ext/transport/binder/client/channel_create_impl.h
+  - src/core/ext/transport/binder/server/binder_server.h
+  - src/core/ext/transport/binder/server/binder_server_credentials.h
+  - src/core/ext/transport/binder/transport/binder_stream.h
+  - src/core/ext/transport/binder/transport/binder_transport.h
+  - src/core/ext/transport/binder/utils/transport_stream_receiver.h
+  - src/core/ext/transport/binder/utils/transport_stream_receiver_impl.h
+  - src/core/ext/transport/binder/wire_format/binder.h
+  - src/core/ext/transport/binder/wire_format/binder_android.h
+  - src/core/ext/transport/binder/wire_format/binder_constants.h
+  - src/core/ext/transport/binder/wire_format/transaction.h
+  - src/core/ext/transport/binder/wire_format/wire_reader.h
+  - src/core/ext/transport/binder/wire_format/wire_reader_impl.h
+  - src/core/ext/transport/binder/wire_format/wire_writer.h
+  - test/core/transport/binder/end2end/echo_service.h
+  - test/core/transport/binder/end2end/fake_binder.h
+  - test/cpp/end2end/test_service_impl.h
   src:
-  - test/core/transport/binder/binder_smoke_test.cc
+  - src/proto/grpc/testing/echo.proto
+  - src/proto/grpc/testing/echo_messages.proto
+  - src/proto/grpc/testing/simple_messages.proto
+  - test/core/transport/binder/end2end/echo.proto
+  - src/core/ext/transport/binder/client/channel_create_impl.cc
+  - src/core/ext/transport/binder/server/binder_server.cc
+  - src/core/ext/transport/binder/server/binder_server_credentials.cc
+  - src/core/ext/transport/binder/transport/binder_transport.cc
+  - src/core/ext/transport/binder/utils/transport_stream_receiver_impl.cc
+  - src/core/ext/transport/binder/wire_format/binder_android.cc
+  - src/core/ext/transport/binder/wire_format/binder_constants.cc
+  - src/core/ext/transport/binder/wire_format/transaction.cc
+  - src/core/ext/transport/binder/wire_format/wire_reader_impl.cc
+  - src/core/ext/transport/binder/wire_format/wire_writer.cc
+  - test/core/transport/binder/end2end/binder_server_test.cc
+  - test/core/transport/binder/end2end/echo_service.cc
+  - test/core/transport/binder/end2end/fake_binder.cc
+  - test/cpp/end2end/test_service_impl.cc
+  deps:
+  - absl/random:random
+  - grpc++_test_util
+- name: binder_transport_test
+  gtest: true
+  build: test
+  language: c++
+  headers:
+  - src/core/ext/transport/binder/transport/binder_stream.h
+  - src/core/ext/transport/binder/transport/binder_transport.h
+  - src/core/ext/transport/binder/utils/transport_stream_receiver.h
+  - src/core/ext/transport/binder/utils/transport_stream_receiver_impl.h
+  - src/core/ext/transport/binder/wire_format/binder.h
+  - src/core/ext/transport/binder/wire_format/binder_constants.h
+  - src/core/ext/transport/binder/wire_format/transaction.h
+  - src/core/ext/transport/binder/wire_format/wire_reader.h
+  - src/core/ext/transport/binder/wire_format/wire_reader_impl.h
+  - src/core/ext/transport/binder/wire_format/wire_writer.h
+  - test/core/transport/binder/mock_objects.h
+  src:
+  - src/core/ext/transport/binder/transport/binder_transport.cc
+  - src/core/ext/transport/binder/utils/transport_stream_receiver_impl.cc
+  - src/core/ext/transport/binder/wire_format/binder_constants.cc
+  - src/core/ext/transport/binder/wire_format/transaction.cc
+  - src/core/ext/transport/binder/wire_format/wire_reader_impl.cc
+  - src/core/ext/transport/binder/wire_format/wire_writer.cc
+  - test/core/transport/binder/binder_transport_test.cc
+  - test/core/transport/binder/mock_objects.cc
   deps:
   - grpc_test_util
   uses_polling: false
@@ -4774,6 +4980,17 @@ targets:
   deps:
   - grpc++_test_config
   - grpc++_test_util
+- name: capture_test
+  gtest: true
+  build: test
+  language: c++
+  headers:
+  - src/core/lib/gprpp/capture.h
+  src:
+  - test/core/gprpp/capture_test.cc
+  deps:
+  - absl/utility:utility
+  uses_polling: false
 - name: cel_authorization_engine_test
   gtest: true
   build: test
@@ -5100,59 +5317,268 @@ targets:
   deps:
   - grpc_test_util
   uses_polling: false
-- name: delegating_channel_test
+- name: context_test
   gtest: true
   build: test
   language: c++
   headers:
-  - test/cpp/end2end/test_service_impl.h
-  src:
-  - src/proto/grpc/testing/echo.proto
-  - src/proto/grpc/testing/echo_messages.proto
-  - src/proto/grpc/testing/simple_messages.proto
-  - test/cpp/end2end/delegating_channel_test.cc
-  - test/cpp/end2end/test_service_impl.cc
-  deps:
-  - grpc++_test_util
-- name: destroy_grpclb_channel_with_active_connect_stress_test
-  gtest: true
-  build: test
-  language: c++
-  headers: []
-  src:
-  - test/cpp/client/destroy_grpclb_channel_with_active_connect_stress_test.cc
-  deps:
-  - grpc++_test_util
-- name: dual_ref_counted_test
-  gtest: true
-  build: test
-  language: c++
-  headers: []
+  - src/core/lib/gpr/tls.h
+  - src/core/lib/promise/context.h
   src:
-  - test/core/gprpp/dual_ref_counted_test.cc
-  deps:
-  - grpc_test_util
-- name: duplicate_header_bad_client_test
+  - test/core/promise/context_test.cc
+  deps: []
+  uses_polling: false
+- name: core_configuration_test
   gtest: true
   build: test
   language: c++
   headers:
-  - test/core/bad_client/bad_client.h
-  - test/core/end2end/cq_verifier.h
+  - src/core/ext/upb-generated/google/api/annotations.upb.h
+  - src/core/ext/upb-generated/google/api/expr/v1alpha1/checked.upb.h
+  - src/core/ext/upb-generated/google/api/expr/v1alpha1/syntax.upb.h
+  - src/core/ext/upb-generated/google/api/http.upb.h
+  - src/core/ext/upb-generated/google/protobuf/any.upb.h
+  - src/core/ext/upb-generated/google/protobuf/duration.upb.h
+  - src/core/ext/upb-generated/google/protobuf/empty.upb.h
+  - src/core/ext/upb-generated/google/protobuf/struct.upb.h
+  - src/core/ext/upb-generated/google/protobuf/timestamp.upb.h
+  - src/core/ext/upb-generated/google/protobuf/wrappers.upb.h
+  - src/core/ext/upb-generated/google/rpc/status.upb.h
+  - src/core/lib/channel/handshaker_factory.h
+  - src/core/lib/channel/handshaker_registry.h
+  - src/core/lib/config/core_configuration.h
+  - src/core/lib/gpr/alloc.h
+  - src/core/lib/gpr/env.h
+  - src/core/lib/gpr/murmur_hash.h
+  - src/core/lib/gpr/spinlock.h
+  - src/core/lib/gpr/string.h
+  - src/core/lib/gpr/string_windows.h
+  - src/core/lib/gpr/time_precise.h
+  - src/core/lib/gpr/tls.h
+  - src/core/lib/gpr/tmpfile.h
+  - src/core/lib/gpr/useful.h
+  - src/core/lib/gprpp/arena.h
+  - src/core/lib/gprpp/construct_destruct.h
+  - src/core/lib/gprpp/debug_location.h
+  - src/core/lib/gprpp/examine_stack.h
+  - src/core/lib/gprpp/fork.h
+  - src/core/lib/gprpp/global_config.h
+  - src/core/lib/gprpp/global_config_custom.h
+  - src/core/lib/gprpp/global_config_env.h
+  - src/core/lib/gprpp/global_config_generic.h
+  - src/core/lib/gprpp/host_port.h
+  - src/core/lib/gprpp/manual_constructor.h
+  - src/core/lib/gprpp/memory.h
+  - src/core/lib/gprpp/mpscq.h
+  - src/core/lib/gprpp/stat.h
+  - src/core/lib/gprpp/status_helper.h
+  - src/core/lib/gprpp/sync.h
+  - src/core/lib/gprpp/thd.h
+  - src/core/lib/gprpp/time_util.h
+  - src/core/lib/profiling/timers.h
   src:
-  - test/core/bad_client/bad_client.cc
-  - test/core/bad_client/tests/duplicate_header.cc
-  - test/core/end2end/cq_verifier.cc
-  deps:
-  - grpc_test_util
-- name: end2end_test
-  gtest: true
-  build: test
-  run: false
-  language: c++
-  headers:
-  - test/cpp/end2end/interceptors_util.h
-  - test/cpp/end2end/test_service_impl.h
+  - src/core/ext/upb-generated/google/api/annotations.upb.c
+  - src/core/ext/upb-generated/google/api/expr/v1alpha1/checked.upb.c
+  - src/core/ext/upb-generated/google/api/expr/v1alpha1/syntax.upb.c
+  - src/core/ext/upb-generated/google/api/http.upb.c
+  - src/core/ext/upb-generated/google/protobuf/any.upb.c
+  - src/core/ext/upb-generated/google/protobuf/duration.upb.c
+  - src/core/ext/upb-generated/google/protobuf/empty.upb.c
+  - src/core/ext/upb-generated/google/protobuf/struct.upb.c
+  - src/core/ext/upb-generated/google/protobuf/timestamp.upb.c
+  - src/core/ext/upb-generated/google/protobuf/wrappers.upb.c
+  - src/core/ext/upb-generated/google/rpc/status.upb.c
+  - src/core/lib/channel/handshaker_registry.cc
+  - src/core/lib/config/core_configuration.cc
+  - src/core/lib/gpr/alloc.cc
+  - src/core/lib/gpr/atm.cc
+  - src/core/lib/gpr/cpu_iphone.cc
+  - src/core/lib/gpr/cpu_linux.cc
+  - src/core/lib/gpr/cpu_posix.cc
+  - src/core/lib/gpr/cpu_windows.cc
+  - src/core/lib/gpr/env_linux.cc
+  - src/core/lib/gpr/env_posix.cc
+  - src/core/lib/gpr/env_windows.cc
+  - src/core/lib/gpr/log.cc
+  - src/core/lib/gpr/log_android.cc
+  - src/core/lib/gpr/log_linux.cc
+  - src/core/lib/gpr/log_posix.cc
+  - src/core/lib/gpr/log_windows.cc
+  - src/core/lib/gpr/murmur_hash.cc
+  - src/core/lib/gpr/string.cc
+  - src/core/lib/gpr/string_posix.cc
+  - src/core/lib/gpr/string_util_windows.cc
+  - src/core/lib/gpr/string_windows.cc
+  - src/core/lib/gpr/sync.cc
+  - src/core/lib/gpr/sync_abseil.cc
+  - src/core/lib/gpr/sync_posix.cc
+  - src/core/lib/gpr/sync_windows.cc
+  - src/core/lib/gpr/time.cc
+  - src/core/lib/gpr/time_posix.cc
+  - src/core/lib/gpr/time_precise.cc
+  - src/core/lib/gpr/time_windows.cc
+  - src/core/lib/gpr/tmpfile_msys.cc
+  - src/core/lib/gpr/tmpfile_posix.cc
+  - src/core/lib/gpr/tmpfile_windows.cc
+  - src/core/lib/gpr/wrap_memcpy.cc
+  - src/core/lib/gprpp/arena.cc
+  - src/core/lib/gprpp/examine_stack.cc
+  - src/core/lib/gprpp/fork.cc
+  - src/core/lib/gprpp/global_config_env.cc
+  - src/core/lib/gprpp/host_port.cc
+  - src/core/lib/gprpp/mpscq.cc
+  - src/core/lib/gprpp/stat_posix.cc
+  - src/core/lib/gprpp/stat_windows.cc
+  - src/core/lib/gprpp/status_helper.cc
+  - src/core/lib/gprpp/thd_posix.cc
+  - src/core/lib/gprpp/thd_windows.cc
+  - src/core/lib/gprpp/time_util.cc
+  - src/core/lib/profiling/basic_timers.cc
+  - src/core/lib/profiling/stap_timers.cc
+  - test/core/config/core_configuration_test.cc
+  deps:
+  - absl/base:base
+  - absl/base:core_headers
+  - absl/memory:memory
+  - absl/status:status
+  - absl/strings:cord
+  - absl/strings:str_format
+  - absl/strings:strings
+  - absl/synchronization:synchronization
+  - absl/time:time
+  - absl/types:optional
+  - upb
+  uses_polling: false
+- name: delegating_channel_test
+  gtest: true
+  build: test
+  language: c++
+  headers:
+  - test/cpp/end2end/test_service_impl.h
+  src:
+  - src/proto/grpc/testing/echo.proto
+  - src/proto/grpc/testing/echo_messages.proto
+  - src/proto/grpc/testing/simple_messages.proto
+  - test/cpp/end2end/delegating_channel_test.cc
+  - test/cpp/end2end/test_service_impl.cc
+  deps:
+  - grpc++_test_util
+- name: destroy_grpclb_channel_with_active_connect_stress_test
+  gtest: true
+  build: test
+  language: c++
+  headers: []
+  src:
+  - test/cpp/client/destroy_grpclb_channel_with_active_connect_stress_test.cc
+  deps:
+  - grpc++_test_util
+- name: dual_ref_counted_test
+  gtest: true
+  build: test
+  language: c++
+  headers: []
+  src:
+  - test/core/gprpp/dual_ref_counted_test.cc
+  deps:
+  - grpc_test_util
+- name: duplicate_header_bad_client_test
+  gtest: true
+  build: test
+  language: c++
+  headers:
+  - test/core/bad_client/bad_client.h
+  - test/core/end2end/cq_verifier.h
+  src:
+  - test/core/bad_client/bad_client.cc
+  - test/core/bad_client/tests/duplicate_header.cc
+  - test/core/end2end/cq_verifier.cc
+  deps:
+  - grpc_test_util
+- name: end2end_binder_transport_test
+  gtest: true
+  build: test
+  language: c++
+  headers:
+  - src/core/ext/transport/binder/transport/binder_stream.h
+  - src/core/ext/transport/binder/transport/binder_transport.h
+  - src/core/ext/transport/binder/utils/transport_stream_receiver.h
+  - src/core/ext/transport/binder/utils/transport_stream_receiver_impl.h
+  - src/core/ext/transport/binder/wire_format/binder.h
+  - src/core/ext/transport/binder/wire_format/binder_constants.h
+  - src/core/ext/transport/binder/wire_format/transaction.h
+  - src/core/ext/transport/binder/wire_format/wire_reader.h
+  - src/core/ext/transport/binder/wire_format/wire_reader_impl.h
+  - src/core/ext/transport/binder/wire_format/wire_writer.h
+  - src/cpp/client/create_channel_internal.h
+  - src/cpp/common/channel_filter.h
+  - src/cpp/server/dynamic_thread_pool.h
+  - src/cpp/server/external_connection_acceptor_impl.h
+  - src/cpp/server/health/default_health_check_service.h
+  - src/cpp/server/thread_pool_interface.h
+  - src/cpp/thread_manager/thread_manager.h
+  - test/core/transport/binder/end2end/echo_service.h
+  - test/core/transport/binder/end2end/fake_binder.h
+  - test/core/transport/binder/end2end/testing_channel_create.h
+  src:
+  - test/core/transport/binder/end2end/echo.proto
+  - src/core/ext/transport/binder/transport/binder_transport.cc
+  - src/core/ext/transport/binder/utils/transport_stream_receiver_impl.cc
+  - src/core/ext/transport/binder/wire_format/binder_constants.cc
+  - src/core/ext/transport/binder/wire_format/transaction.cc
+  - src/core/ext/transport/binder/wire_format/wire_reader_impl.cc
+  - src/core/ext/transport/binder/wire_format/wire_writer.cc
+  - src/cpp/client/channel_cc.cc
+  - src/cpp/client/client_callback.cc
+  - src/cpp/client/client_context.cc
+  - src/cpp/client/client_interceptor.cc
+  - src/cpp/client/create_channel.cc
+  - src/cpp/client/create_channel_internal.cc
+  - src/cpp/client/create_channel_posix.cc
+  - src/cpp/client/credentials_cc.cc
+  - src/cpp/codegen/codegen_init.cc
+  - src/cpp/common/alarm.cc
+  - src/cpp/common/channel_arguments.cc
+  - src/cpp/common/channel_filter.cc
+  - src/cpp/common/completion_queue_cc.cc
+  - src/cpp/common/core_codegen.cc
+  - src/cpp/common/resource_quota_cc.cc
+  - src/cpp/common/rpc_method.cc
+  - src/cpp/common/validate_service_config.cc
+  - src/cpp/common/version_cc.cc
+  - src/cpp/server/async_generic_service.cc
+  - src/cpp/server/channel_argument_option.cc
+  - src/cpp/server/create_default_thread_pool.cc
+  - src/cpp/server/dynamic_thread_pool.cc
+  - src/cpp/server/external_connection_acceptor_impl.cc
+  - src/cpp/server/health/default_health_check_service.cc
+  - src/cpp/server/health/health_check_service.cc
+  - src/cpp/server/health/health_check_service_server_builder_option.cc
+  - src/cpp/server/server_builder.cc
+  - src/cpp/server/server_callback.cc
+  - src/cpp/server/server_cc.cc
+  - src/cpp/server/server_context.cc
+  - src/cpp/server/server_credentials.cc
+  - src/cpp/server/server_posix.cc
+  - src/cpp/thread_manager/thread_manager.cc
+  - src/cpp/util/byte_buffer_cc.cc
+  - src/cpp/util/status.cc
+  - src/cpp/util/string_ref.cc
+  - src/cpp/util/time_cc.cc
+  - test/core/transport/binder/end2end/echo_service.cc
+  - test/core/transport/binder/end2end/end2end_binder_transport_test.cc
+  - test/core/transport/binder/end2end/fake_binder.cc
+  - test/core/transport/binder/end2end/testing_channel_create.cc
+  deps:
+  - absl/random:random
+  - grpc_test_util
+- name: end2end_test
+  gtest: true
+  build: test
+  run: false
+  language: c++
+  headers:
+  - test/cpp/end2end/interceptors_util.h
+  - test/cpp/end2end/test_service_impl.h
   src:
   - src/proto/grpc/testing/duplicate/echo_duplicate.proto
   - src/proto/grpc/testing/echo.proto
@@ -5229,6 +5655,32 @@ targets:
   - test/cpp/end2end/exception_test.cc
   deps:
   - grpc++_test_util
+- name: fake_binder_test
+  gtest: true
+  build: test
+  language: c++
+  headers:
+  - src/core/ext/transport/binder/utils/transport_stream_receiver.h
+  - src/core/ext/transport/binder/utils/transport_stream_receiver_impl.h
+  - src/core/ext/transport/binder/wire_format/binder.h
+  - src/core/ext/transport/binder/wire_format/binder_constants.h
+  - src/core/ext/transport/binder/wire_format/transaction.h
+  - src/core/ext/transport/binder/wire_format/wire_reader.h
+  - src/core/ext/transport/binder/wire_format/wire_reader_impl.h
+  - src/core/ext/transport/binder/wire_format/wire_writer.h
+  - test/core/transport/binder/end2end/fake_binder.h
+  src:
+  - src/core/ext/transport/binder/utils/transport_stream_receiver_impl.cc
+  - src/core/ext/transport/binder/wire_format/binder_constants.cc
+  - src/core/ext/transport/binder/wire_format/transaction.cc
+  - src/core/ext/transport/binder/wire_format/wire_reader_impl.cc
+  - src/core/ext/transport/binder/wire_format/wire_writer.cc
+  - test/core/transport/binder/end2end/fake_binder.cc
+  - test/core/transport/binder/end2end/fake_binder_test.cc
+  deps:
+  - absl/random:random
+  - grpc_test_util
+  uses_polling: false
 - name: file_watcher_certificate_provider_factory_test
   gtest: true
   build: test
@@ -5266,6 +5718,156 @@ targets:
   - test/cpp/end2end/test_service_impl.cc
   deps:
   - grpc++_test_util
+- name: flow_control_test
+  gtest: true
+  build: test
+  language: c++
+  headers:
+  - test/core/end2end/cq_verifier.h
+  src:
+  - test/core/end2end/cq_verifier.cc
+  - test/core/transport/chttp2/flow_control_test.cc
+  deps:
+  - grpc_test_util
+- name: for_each_test
+  gtest: true
+  build: test
+  language: c++
+  headers:
+  - src/core/ext/upb-generated/google/api/annotations.upb.h
+  - src/core/ext/upb-generated/google/api/expr/v1alpha1/checked.upb.h
+  - src/core/ext/upb-generated/google/api/expr/v1alpha1/syntax.upb.h
+  - src/core/ext/upb-generated/google/api/http.upb.h
+  - src/core/ext/upb-generated/google/protobuf/any.upb.h
+  - src/core/ext/upb-generated/google/protobuf/duration.upb.h
+  - src/core/ext/upb-generated/google/protobuf/empty.upb.h
+  - src/core/ext/upb-generated/google/protobuf/struct.upb.h
+  - src/core/ext/upb-generated/google/protobuf/timestamp.upb.h
+  - src/core/ext/upb-generated/google/protobuf/wrappers.upb.h
+  - src/core/ext/upb-generated/google/rpc/status.upb.h
+  - src/core/lib/gpr/alloc.h
+  - src/core/lib/gpr/env.h
+  - src/core/lib/gpr/murmur_hash.h
+  - src/core/lib/gpr/spinlock.h
+  - src/core/lib/gpr/string.h
+  - src/core/lib/gpr/string_windows.h
+  - src/core/lib/gpr/time_precise.h
+  - src/core/lib/gpr/tls.h
+  - src/core/lib/gpr/tmpfile.h
+  - src/core/lib/gpr/useful.h
+  - src/core/lib/gprpp/arena.h
+  - src/core/lib/gprpp/atomic_utils.h
+  - src/core/lib/gprpp/bitset.h
+  - src/core/lib/gprpp/construct_destruct.h
+  - src/core/lib/gprpp/debug_location.h
+  - src/core/lib/gprpp/examine_stack.h
+  - src/core/lib/gprpp/fork.h
+  - src/core/lib/gprpp/global_config.h
+  - src/core/lib/gprpp/global_config_custom.h
+  - src/core/lib/gprpp/global_config_env.h
+  - src/core/lib/gprpp/global_config_generic.h
+  - src/core/lib/gprpp/host_port.h
+  - src/core/lib/gprpp/manual_constructor.h
+  - src/core/lib/gprpp/memory.h
+  - src/core/lib/gprpp/mpscq.h
+  - src/core/lib/gprpp/stat.h
+  - src/core/lib/gprpp/status_helper.h
+  - src/core/lib/gprpp/sync.h
+  - src/core/lib/gprpp/thd.h
+  - src/core/lib/gprpp/time_util.h
+  - src/core/lib/profiling/timers.h
+  - src/core/lib/promise/activity.h
+  - src/core/lib/promise/context.h
+  - src/core/lib/promise/detail/basic_join.h
+  - src/core/lib/promise/detail/basic_seq.h
+  - src/core/lib/promise/detail/promise_factory.h
+  - src/core/lib/promise/detail/promise_like.h
+  - src/core/lib/promise/detail/status.h
+  - src/core/lib/promise/detail/switch.h
+  - src/core/lib/promise/for_each.h
+  - src/core/lib/promise/intra_activity_waiter.h
+  - src/core/lib/promise/join.h
+  - src/core/lib/promise/map.h
+  - src/core/lib/promise/observable.h
+  - src/core/lib/promise/pipe.h
+  - src/core/lib/promise/poll.h
+  - src/core/lib/promise/seq.h
+  - src/core/lib/promise/wait_set.h
+  src:
+  - src/core/ext/upb-generated/google/api/annotations.upb.c
+  - src/core/ext/upb-generated/google/api/expr/v1alpha1/checked.upb.c
+  - src/core/ext/upb-generated/google/api/expr/v1alpha1/syntax.upb.c
+  - src/core/ext/upb-generated/google/api/http.upb.c
+  - src/core/ext/upb-generated/google/protobuf/any.upb.c
+  - src/core/ext/upb-generated/google/protobuf/duration.upb.c
+  - src/core/ext/upb-generated/google/protobuf/empty.upb.c
+  - src/core/ext/upb-generated/google/protobuf/struct.upb.c
+  - src/core/ext/upb-generated/google/protobuf/timestamp.upb.c
+  - src/core/ext/upb-generated/google/protobuf/wrappers.upb.c
+  - src/core/ext/upb-generated/google/rpc/status.upb.c
+  - src/core/lib/gpr/alloc.cc
+  - src/core/lib/gpr/atm.cc
+  - src/core/lib/gpr/cpu_iphone.cc
+  - src/core/lib/gpr/cpu_linux.cc
+  - src/core/lib/gpr/cpu_posix.cc
+  - src/core/lib/gpr/cpu_windows.cc
+  - src/core/lib/gpr/env_linux.cc
+  - src/core/lib/gpr/env_posix.cc
+  - src/core/lib/gpr/env_windows.cc
+  - src/core/lib/gpr/log.cc
+  - src/core/lib/gpr/log_android.cc
+  - src/core/lib/gpr/log_linux.cc
+  - src/core/lib/gpr/log_posix.cc
+  - src/core/lib/gpr/log_windows.cc
+  - src/core/lib/gpr/murmur_hash.cc
+  - src/core/lib/gpr/string.cc
+  - src/core/lib/gpr/string_posix.cc
+  - src/core/lib/gpr/string_util_windows.cc
+  - src/core/lib/gpr/string_windows.cc
+  - src/core/lib/gpr/sync.cc
+  - src/core/lib/gpr/sync_abseil.cc
+  - src/core/lib/gpr/sync_posix.cc
+  - src/core/lib/gpr/sync_windows.cc
+  - src/core/lib/gpr/time.cc
+  - src/core/lib/gpr/time_posix.cc
+  - src/core/lib/gpr/time_precise.cc
+  - src/core/lib/gpr/time_windows.cc
+  - src/core/lib/gpr/tmpfile_msys.cc
+  - src/core/lib/gpr/tmpfile_posix.cc
+  - src/core/lib/gpr/tmpfile_windows.cc
+  - src/core/lib/gpr/wrap_memcpy.cc
+  - src/core/lib/gprpp/arena.cc
+  - src/core/lib/gprpp/examine_stack.cc
+  - src/core/lib/gprpp/fork.cc
+  - src/core/lib/gprpp/global_config_env.cc
+  - src/core/lib/gprpp/host_port.cc
+  - src/core/lib/gprpp/mpscq.cc
+  - src/core/lib/gprpp/stat_posix.cc
+  - src/core/lib/gprpp/stat_windows.cc
+  - src/core/lib/gprpp/status_helper.cc
+  - src/core/lib/gprpp/thd_posix.cc
+  - src/core/lib/gprpp/thd_windows.cc
+  - src/core/lib/gprpp/time_util.cc
+  - src/core/lib/profiling/basic_timers.cc
+  - src/core/lib/profiling/stap_timers.cc
+  - src/core/lib/promise/activity.cc
+  - test/core/promise/for_each_test.cc
+  deps:
+  - absl/base:base
+  - absl/base:core_headers
+  - absl/container:flat_hash_set
+  - absl/memory:memory
+  - absl/status:status
+  - absl/status:statusor
+  - absl/strings:cord
+  - absl/strings:str_format
+  - absl/strings:strings
+  - absl/synchronization:synchronization
+  - absl/time:time
+  - absl/types:optional
+  - absl/types:variant
+  - upb
+  uses_polling: false
 - name: generic_end2end_test
   gtest: true
   build: test
@@ -5481,6 +6083,7 @@ targets:
   - test/cpp/util/service_describer.cc
   deps:
   - grpc++_reflection
+  - grpc++_test_config
   - grpc++_test_util
   platforms:
   - linux
@@ -5512,6 +6115,7 @@ targets:
   - test/cpp/end2end/grpclb_end2end_test.cc
   - test/cpp/end2end/test_service_impl.cc
   deps:
+  - grpc++_test_config
   - grpc++_test_util
   platforms:
   - linux
@@ -5570,6 +6174,16 @@ targets:
   - test/cpp/end2end/test_service_impl.cc
   deps:
   - grpc++_test_util
+- name: hpack_encoder_index_test
+  gtest: true
+  build: test
+  language: c++
+  headers:
+  - src/core/ext/transport/chttp2/transport/hpack_encoder_index.h
+  src:
+  - test/core/transport/chttp2/hpack_encoder_index_test.cc
+  deps:
+  - absl/types:optional
 - name: hpack_parser_fuzzer_test
   build: fuzzer
   language: c++
@@ -5640,7 +6254,22 @@ targets:
   - test/cpp/end2end/hybrid_end2end_test.cc
   - test/cpp/end2end/test_service_impl.cc
   deps:
-  - grpc++_test_util
+  - grpc++_test_util
+- name: if_test
+  gtest: true
+  build: test
+  language: c++
+  headers:
+  - src/core/lib/promise/detail/promise_factory.h
+  - src/core/lib/promise/detail/promise_like.h
+  - src/core/lib/promise/if.h
+  - src/core/lib/promise/poll.h
+  src:
+  - test/core/promise/if_test.cc
+  deps:
+  - absl/status:statusor
+  - absl/types:variant
+  uses_polling: false
 - name: init_test
   gtest: true
   build: test
@@ -5721,6 +6350,23 @@ targets:
   - linux
   - posix
   - mac
+- name: join_test
+  gtest: true
+  build: test
+  language: c++
+  headers:
+  - src/core/lib/gprpp/bitset.h
+  - src/core/lib/gprpp/construct_destruct.h
+  - src/core/lib/promise/detail/basic_join.h
+  - src/core/lib/promise/detail/promise_factory.h
+  - src/core/lib/promise/detail/promise_like.h
+  - src/core/lib/promise/join.h
+  - src/core/lib/promise/poll.h
+  src:
+  - test/core/promise/join_test.cc
+  deps:
+  - absl/types:variant
+  uses_polling: false
 - name: json_fuzzer_test
   build: fuzzer
   language: c++
@@ -5758,6 +6404,140 @@ targets:
   - test/core/end2end/cq_verifier.cc
   deps:
   - grpc_test_util
+- name: latch_test
+  gtest: true
+  build: test
+  language: c++
+  headers:
+  - src/core/ext/upb-generated/google/api/annotations.upb.h
+  - src/core/ext/upb-generated/google/api/expr/v1alpha1/checked.upb.h
+  - src/core/ext/upb-generated/google/api/expr/v1alpha1/syntax.upb.h
+  - src/core/ext/upb-generated/google/api/http.upb.h
+  - src/core/ext/upb-generated/google/protobuf/any.upb.h
+  - src/core/ext/upb-generated/google/protobuf/duration.upb.h
+  - src/core/ext/upb-generated/google/protobuf/empty.upb.h
+  - src/core/ext/upb-generated/google/protobuf/struct.upb.h
+  - src/core/ext/upb-generated/google/protobuf/timestamp.upb.h
+  - src/core/ext/upb-generated/google/protobuf/wrappers.upb.h
+  - src/core/ext/upb-generated/google/rpc/status.upb.h
+  - src/core/lib/gpr/alloc.h
+  - src/core/lib/gpr/env.h
+  - src/core/lib/gpr/murmur_hash.h
+  - src/core/lib/gpr/spinlock.h
+  - src/core/lib/gpr/string.h
+  - src/core/lib/gpr/string_windows.h
+  - src/core/lib/gpr/time_precise.h
+  - src/core/lib/gpr/tls.h
+  - src/core/lib/gpr/tmpfile.h
+  - src/core/lib/gpr/useful.h
+  - src/core/lib/gprpp/arena.h
+  - src/core/lib/gprpp/atomic_utils.h
+  - src/core/lib/gprpp/bitset.h
+  - src/core/lib/gprpp/construct_destruct.h
+  - src/core/lib/gprpp/debug_location.h
+  - src/core/lib/gprpp/examine_stack.h
+  - src/core/lib/gprpp/fork.h
+  - src/core/lib/gprpp/global_config.h
+  - src/core/lib/gprpp/global_config_custom.h
+  - src/core/lib/gprpp/global_config_env.h
+  - src/core/lib/gprpp/global_config_generic.h
+  - src/core/lib/gprpp/host_port.h
+  - src/core/lib/gprpp/manual_constructor.h
+  - src/core/lib/gprpp/memory.h
+  - src/core/lib/gprpp/mpscq.h
+  - src/core/lib/gprpp/stat.h
+  - src/core/lib/gprpp/status_helper.h
+  - src/core/lib/gprpp/sync.h
+  - src/core/lib/gprpp/thd.h
+  - src/core/lib/gprpp/time_util.h
+  - src/core/lib/profiling/timers.h
+  - src/core/lib/promise/activity.h
+  - src/core/lib/promise/context.h
+  - src/core/lib/promise/detail/basic_join.h
+  - src/core/lib/promise/detail/basic_seq.h
+  - src/core/lib/promise/detail/promise_factory.h
+  - src/core/lib/promise/detail/promise_like.h
+  - src/core/lib/promise/detail/status.h
+  - src/core/lib/promise/detail/switch.h
+  - src/core/lib/promise/intra_activity_waiter.h
+  - src/core/lib/promise/join.h
+  - src/core/lib/promise/latch.h
+  - src/core/lib/promise/poll.h
+  - src/core/lib/promise/seq.h
+  src:
+  - src/core/ext/upb-generated/google/api/annotations.upb.c
+  - src/core/ext/upb-generated/google/api/expr/v1alpha1/checked.upb.c
+  - src/core/ext/upb-generated/google/api/expr/v1alpha1/syntax.upb.c
+  - src/core/ext/upb-generated/google/api/http.upb.c
+  - src/core/ext/upb-generated/google/protobuf/any.upb.c
+  - src/core/ext/upb-generated/google/protobuf/duration.upb.c
+  - src/core/ext/upb-generated/google/protobuf/empty.upb.c
+  - src/core/ext/upb-generated/google/protobuf/struct.upb.c
+  - src/core/ext/upb-generated/google/protobuf/timestamp.upb.c
+  - src/core/ext/upb-generated/google/protobuf/wrappers.upb.c
+  - src/core/ext/upb-generated/google/rpc/status.upb.c
+  - src/core/lib/gpr/alloc.cc
+  - src/core/lib/gpr/atm.cc
+  - src/core/lib/gpr/cpu_iphone.cc
+  - src/core/lib/gpr/cpu_linux.cc
+  - src/core/lib/gpr/cpu_posix.cc
+  - src/core/lib/gpr/cpu_windows.cc
+  - src/core/lib/gpr/env_linux.cc
+  - src/core/lib/gpr/env_posix.cc
+  - src/core/lib/gpr/env_windows.cc
+  - src/core/lib/gpr/log.cc
+  - src/core/lib/gpr/log_android.cc
+  - src/core/lib/gpr/log_linux.cc
+  - src/core/lib/gpr/log_posix.cc
+  - src/core/lib/gpr/log_windows.cc
+  - src/core/lib/gpr/murmur_hash.cc
+  - src/core/lib/gpr/string.cc
+  - src/core/lib/gpr/string_posix.cc
+  - src/core/lib/gpr/string_util_windows.cc
+  - src/core/lib/gpr/string_windows.cc
+  - src/core/lib/gpr/sync.cc
+  - src/core/lib/gpr/sync_abseil.cc
+  - src/core/lib/gpr/sync_posix.cc
+  - src/core/lib/gpr/sync_windows.cc
+  - src/core/lib/gpr/time.cc
+  - src/core/lib/gpr/time_posix.cc
+  - src/core/lib/gpr/time_precise.cc
+  - src/core/lib/gpr/time_windows.cc
+  - src/core/lib/gpr/tmpfile_msys.cc
+  - src/core/lib/gpr/tmpfile_posix.cc
+  - src/core/lib/gpr/tmpfile_windows.cc
+  - src/core/lib/gpr/wrap_memcpy.cc
+  - src/core/lib/gprpp/arena.cc
+  - src/core/lib/gprpp/examine_stack.cc
+  - src/core/lib/gprpp/fork.cc
+  - src/core/lib/gprpp/global_config_env.cc
+  - src/core/lib/gprpp/host_port.cc
+  - src/core/lib/gprpp/mpscq.cc
+  - src/core/lib/gprpp/stat_posix.cc
+  - src/core/lib/gprpp/stat_windows.cc
+  - src/core/lib/gprpp/status_helper.cc
+  - src/core/lib/gprpp/thd_posix.cc
+  - src/core/lib/gprpp/thd_windows.cc
+  - src/core/lib/gprpp/time_util.cc
+  - src/core/lib/profiling/basic_timers.cc
+  - src/core/lib/profiling/stap_timers.cc
+  - src/core/lib/promise/activity.cc
+  - test/core/promise/latch_test.cc
+  deps:
+  - absl/base:base
+  - absl/base:core_headers
+  - absl/memory:memory
+  - absl/status:status
+  - absl/status:statusor
+  - absl/strings:cord
+  - absl/strings:str_format
+  - absl/strings:strings
+  - absl/synchronization:synchronization
+  - absl/time:time
+  - absl/types:optional
+  - absl/types:variant
+  - upb
+  uses_polling: false
 - name: lb_get_cpu_stats_test
   gtest: true
   build: test
@@ -5805,6 +6585,20 @@ targets:
   deps:
   - grpc_test_util
   uses_polling: false
+- name: loop_test
+  gtest: true
+  build: test
+  language: c++
+  headers:
+  - src/core/lib/promise/detail/promise_factory.h
+  - src/core/lib/promise/detail/promise_like.h
+  - src/core/lib/promise/loop.h
+  - src/core/lib/promise/poll.h
+  src:
+  - test/core/promise/loop_test.cc
+  deps:
+  - absl/types:variant
+  uses_polling: false
 - name: match_test
   gtest: true
   build: test
@@ -5840,6 +6634,15 @@ targets:
   - test/cpp/end2end/test_service_impl.cc
   deps:
   - grpc++_test_util
+- name: miscompile_with_no_unique_address_test
+  gtest: true
+  build: test
+  language: c++
+  headers: []
+  src:
+  - test/core/compiler_bugs/miscompile_with_no_unique_address_test.cc
+  deps: []
+  uses_polling: false
 - name: mock_stream_test
   gtest: true
   build: test
@@ -5918,6 +6721,139 @@ targets:
   - grpc_test_util
   benchmark: true
   defaults: benchmark
+- name: observable_test
+  gtest: true
+  build: test
+  language: c++
+  headers:
+  - src/core/ext/upb-generated/google/api/annotations.upb.h
+  - src/core/ext/upb-generated/google/api/expr/v1alpha1/checked.upb.h
+  - src/core/ext/upb-generated/google/api/expr/v1alpha1/syntax.upb.h
+  - src/core/ext/upb-generated/google/api/http.upb.h
+  - src/core/ext/upb-generated/google/protobuf/any.upb.h
+  - src/core/ext/upb-generated/google/protobuf/duration.upb.h
+  - src/core/ext/upb-generated/google/protobuf/empty.upb.h
+  - src/core/ext/upb-generated/google/protobuf/struct.upb.h
+  - src/core/ext/upb-generated/google/protobuf/timestamp.upb.h
+  - src/core/ext/upb-generated/google/protobuf/wrappers.upb.h
+  - src/core/ext/upb-generated/google/rpc/status.upb.h
+  - src/core/lib/gpr/alloc.h
+  - src/core/lib/gpr/env.h
+  - src/core/lib/gpr/murmur_hash.h
+  - src/core/lib/gpr/spinlock.h
+  - src/core/lib/gpr/string.h
+  - src/core/lib/gpr/string_windows.h
+  - src/core/lib/gpr/time_precise.h
+  - src/core/lib/gpr/tls.h
+  - src/core/lib/gpr/tmpfile.h
+  - src/core/lib/gpr/useful.h
+  - src/core/lib/gprpp/arena.h
+  - src/core/lib/gprpp/atomic_utils.h
+  - src/core/lib/gprpp/construct_destruct.h
+  - src/core/lib/gprpp/debug_location.h
+  - src/core/lib/gprpp/examine_stack.h
+  - src/core/lib/gprpp/fork.h
+  - src/core/lib/gprpp/global_config.h
+  - src/core/lib/gprpp/global_config_custom.h
+  - src/core/lib/gprpp/global_config_env.h
+  - src/core/lib/gprpp/global_config_generic.h
+  - src/core/lib/gprpp/host_port.h
+  - src/core/lib/gprpp/manual_constructor.h
+  - src/core/lib/gprpp/memory.h
+  - src/core/lib/gprpp/mpscq.h
+  - src/core/lib/gprpp/stat.h
+  - src/core/lib/gprpp/status_helper.h
+  - src/core/lib/gprpp/sync.h
+  - src/core/lib/gprpp/thd.h
+  - src/core/lib/gprpp/time_util.h
+  - src/core/lib/profiling/timers.h
+  - src/core/lib/promise/activity.h
+  - src/core/lib/promise/context.h
+  - src/core/lib/promise/detail/basic_seq.h
+  - src/core/lib/promise/detail/promise_factory.h
+  - src/core/lib/promise/detail/promise_like.h
+  - src/core/lib/promise/detail/status.h
+  - src/core/lib/promise/detail/switch.h
+  - src/core/lib/promise/observable.h
+  - src/core/lib/promise/poll.h
+  - src/core/lib/promise/promise.h
+  - src/core/lib/promise/seq.h
+  - src/core/lib/promise/wait_set.h
+  src:
+  - src/core/ext/upb-generated/google/api/annotations.upb.c
+  - src/core/ext/upb-generated/google/api/expr/v1alpha1/checked.upb.c
+  - src/core/ext/upb-generated/google/api/expr/v1alpha1/syntax.upb.c
+  - src/core/ext/upb-generated/google/api/http.upb.c
+  - src/core/ext/upb-generated/google/protobuf/any.upb.c
+  - src/core/ext/upb-generated/google/protobuf/duration.upb.c
+  - src/core/ext/upb-generated/google/protobuf/empty.upb.c
+  - src/core/ext/upb-generated/google/protobuf/struct.upb.c
+  - src/core/ext/upb-generated/google/protobuf/timestamp.upb.c
+  - src/core/ext/upb-generated/google/protobuf/wrappers.upb.c
+  - src/core/ext/upb-generated/google/rpc/status.upb.c
+  - src/core/lib/gpr/alloc.cc
+  - src/core/lib/gpr/atm.cc
+  - src/core/lib/gpr/cpu_iphone.cc
+  - src/core/lib/gpr/cpu_linux.cc
+  - src/core/lib/gpr/cpu_posix.cc
+  - src/core/lib/gpr/cpu_windows.cc
+  - src/core/lib/gpr/env_linux.cc
+  - src/core/lib/gpr/env_posix.cc
+  - src/core/lib/gpr/env_windows.cc
+  - src/core/lib/gpr/log.cc
+  - src/core/lib/gpr/log_android.cc
+  - src/core/lib/gpr/log_linux.cc
+  - src/core/lib/gpr/log_posix.cc
+  - src/core/lib/gpr/log_windows.cc
+  - src/core/lib/gpr/murmur_hash.cc
+  - src/core/lib/gpr/string.cc
+  - src/core/lib/gpr/string_posix.cc
+  - src/core/lib/gpr/string_util_windows.cc
+  - src/core/lib/gpr/string_windows.cc
+  - src/core/lib/gpr/sync.cc
+  - src/core/lib/gpr/sync_abseil.cc
+  - src/core/lib/gpr/sync_posix.cc
+  - src/core/lib/gpr/sync_windows.cc
+  - src/core/lib/gpr/time.cc
+  - src/core/lib/gpr/time_posix.cc
+  - src/core/lib/gpr/time_precise.cc
+  - src/core/lib/gpr/time_windows.cc
+  - src/core/lib/gpr/tmpfile_msys.cc
+  - src/core/lib/gpr/tmpfile_posix.cc
+  - src/core/lib/gpr/tmpfile_windows.cc
+  - src/core/lib/gpr/wrap_memcpy.cc
+  - src/core/lib/gprpp/arena.cc
+  - src/core/lib/gprpp/examine_stack.cc
+  - src/core/lib/gprpp/fork.cc
+  - src/core/lib/gprpp/global_config_env.cc
+  - src/core/lib/gprpp/host_port.cc
+  - src/core/lib/gprpp/mpscq.cc
+  - src/core/lib/gprpp/stat_posix.cc
+  - src/core/lib/gprpp/stat_windows.cc
+  - src/core/lib/gprpp/status_helper.cc
+  - src/core/lib/gprpp/thd_posix.cc
+  - src/core/lib/gprpp/thd_windows.cc
+  - src/core/lib/gprpp/time_util.cc
+  - src/core/lib/profiling/basic_timers.cc
+  - src/core/lib/profiling/stap_timers.cc
+  - src/core/lib/promise/activity.cc
+  - test/core/promise/observable_test.cc
+  deps:
+  - absl/base:base
+  - absl/base:core_headers
+  - absl/container:flat_hash_set
+  - absl/memory:memory
+  - absl/status:status
+  - absl/status:statusor
+  - absl/strings:cord
+  - absl/strings:str_format
+  - absl/strings:strings
+  - absl/synchronization:synchronization
+  - absl/time:time
+  - absl/types:optional
+  - absl/types:variant
+  - upb
+  uses_polling: false
 - name: orphanable_test
   gtest: true
   build: test
@@ -5987,6 +6923,161 @@ targets:
   - test/core/transport/pid_controller_test.cc
   deps:
   - grpc_test_util
+- name: pipe_test
+  gtest: true
+  build: test
+  language: c++
+  headers:
+  - src/core/ext/upb-generated/google/api/annotations.upb.h
+  - src/core/ext/upb-generated/google/api/expr/v1alpha1/checked.upb.h
+  - src/core/ext/upb-generated/google/api/expr/v1alpha1/syntax.upb.h
+  - src/core/ext/upb-generated/google/api/http.upb.h
+  - src/core/ext/upb-generated/google/protobuf/any.upb.h
+  - src/core/ext/upb-generated/google/protobuf/duration.upb.h
+  - src/core/ext/upb-generated/google/protobuf/empty.upb.h
+  - src/core/ext/upb-generated/google/protobuf/struct.upb.h
+  - src/core/ext/upb-generated/google/protobuf/timestamp.upb.h
+  - src/core/ext/upb-generated/google/protobuf/wrappers.upb.h
+  - src/core/ext/upb-generated/google/rpc/status.upb.h
+  - src/core/lib/gpr/alloc.h
+  - src/core/lib/gpr/env.h
+  - src/core/lib/gpr/murmur_hash.h
+  - src/core/lib/gpr/spinlock.h
+  - src/core/lib/gpr/string.h
+  - src/core/lib/gpr/string_windows.h
+  - src/core/lib/gpr/time_precise.h
+  - src/core/lib/gpr/tls.h
+  - src/core/lib/gpr/tmpfile.h
+  - src/core/lib/gpr/useful.h
+  - src/core/lib/gprpp/arena.h
+  - src/core/lib/gprpp/atomic_utils.h
+  - src/core/lib/gprpp/bitset.h
+  - src/core/lib/gprpp/construct_destruct.h
+  - src/core/lib/gprpp/debug_location.h
+  - src/core/lib/gprpp/examine_stack.h
+  - src/core/lib/gprpp/fork.h
+  - src/core/lib/gprpp/global_config.h
+  - src/core/lib/gprpp/global_config_custom.h
+  - src/core/lib/gprpp/global_config_env.h
+  - src/core/lib/gprpp/global_config_generic.h
+  - src/core/lib/gprpp/host_port.h
+  - src/core/lib/gprpp/manual_constructor.h
+  - src/core/lib/gprpp/memory.h
+  - src/core/lib/gprpp/mpscq.h
+  - src/core/lib/gprpp/stat.h
+  - src/core/lib/gprpp/status_helper.h
+  - src/core/lib/gprpp/sync.h
+  - src/core/lib/gprpp/thd.h
+  - src/core/lib/gprpp/time_util.h
+  - src/core/lib/profiling/timers.h
+  - src/core/lib/promise/activity.h
+  - src/core/lib/promise/context.h
+  - src/core/lib/promise/detail/basic_join.h
+  - src/core/lib/promise/detail/basic_seq.h
+  - src/core/lib/promise/detail/promise_factory.h
+  - src/core/lib/promise/detail/promise_like.h
+  - src/core/lib/promise/detail/status.h
+  - src/core/lib/promise/detail/switch.h
+  - src/core/lib/promise/intra_activity_waiter.h
+  - src/core/lib/promise/join.h
+  - src/core/lib/promise/pipe.h
+  - src/core/lib/promise/poll.h
+  - src/core/lib/promise/promise.h
+  - src/core/lib/promise/seq.h
+  src:
+  - src/core/ext/upb-generated/google/api/annotations.upb.c
+  - src/core/ext/upb-generated/google/api/expr/v1alpha1/checked.upb.c
+  - src/core/ext/upb-generated/google/api/expr/v1alpha1/syntax.upb.c
+  - src/core/ext/upb-generated/google/api/http.upb.c
+  - src/core/ext/upb-generated/google/protobuf/any.upb.c
+  - src/core/ext/upb-generated/google/protobuf/duration.upb.c
+  - src/core/ext/upb-generated/google/protobuf/empty.upb.c
+  - src/core/ext/upb-generated/google/protobuf/struct.upb.c
+  - src/core/ext/upb-generated/google/protobuf/timestamp.upb.c
+  - src/core/ext/upb-generated/google/protobuf/wrappers.upb.c
+  - src/core/ext/upb-generated/google/rpc/status.upb.c
+  - src/core/lib/gpr/alloc.cc
+  - src/core/lib/gpr/atm.cc
+  - src/core/lib/gpr/cpu_iphone.cc
+  - src/core/lib/gpr/cpu_linux.cc
+  - src/core/lib/gpr/cpu_posix.cc
+  - src/core/lib/gpr/cpu_windows.cc
+  - src/core/lib/gpr/env_linux.cc
+  - src/core/lib/gpr/env_posix.cc
+  - src/core/lib/gpr/env_windows.cc
+  - src/core/lib/gpr/log.cc
+  - src/core/lib/gpr/log_android.cc
+  - src/core/lib/gpr/log_linux.cc
+  - src/core/lib/gpr/log_posix.cc
+  - src/core/lib/gpr/log_windows.cc
+  - src/core/lib/gpr/murmur_hash.cc
+  - src/core/lib/gpr/string.cc
+  - src/core/lib/gpr/string_posix.cc
+  - src/core/lib/gpr/string_util_windows.cc
+  - src/core/lib/gpr/string_windows.cc
+  - src/core/lib/gpr/sync.cc
+  - src/core/lib/gpr/sync_abseil.cc
+  - src/core/lib/gpr/sync_posix.cc
+  - src/core/lib/gpr/sync_windows.cc
+  - src/core/lib/gpr/time.cc
+  - src/core/lib/gpr/time_posix.cc
+  - src/core/lib/gpr/time_precise.cc
+  - src/core/lib/gpr/time_windows.cc
+  - src/core/lib/gpr/tmpfile_msys.cc
+  - src/core/lib/gpr/tmpfile_posix.cc
+  - src/core/lib/gpr/tmpfile_windows.cc
+  - src/core/lib/gpr/wrap_memcpy.cc
+  - src/core/lib/gprpp/arena.cc
+  - src/core/lib/gprpp/examine_stack.cc
+  - src/core/lib/gprpp/fork.cc
+  - src/core/lib/gprpp/global_config_env.cc
+  - src/core/lib/gprpp/host_port.cc
+  - src/core/lib/gprpp/mpscq.cc
+  - src/core/lib/gprpp/stat_posix.cc
+  - src/core/lib/gprpp/stat_windows.cc
+  - src/core/lib/gprpp/status_helper.cc
+  - src/core/lib/gprpp/thd_posix.cc
+  - src/core/lib/gprpp/thd_windows.cc
+  - src/core/lib/gprpp/time_util.cc
+  - src/core/lib/profiling/basic_timers.cc
+  - src/core/lib/profiling/stap_timers.cc
+  - src/core/lib/promise/activity.cc
+  - test/core/promise/pipe_test.cc
+  deps:
+  - absl/base:base
+  - absl/base:core_headers
+  - absl/memory:memory
+  - absl/status:status
+  - absl/status:statusor
+  - absl/strings:cord
+  - absl/strings:str_format
+  - absl/strings:strings
+  - absl/synchronization:synchronization
+  - absl/time:time
+  - absl/types:optional
+  - absl/types:variant
+  - upb
+  uses_polling: false
+- name: poll_test
+  gtest: true
+  build: test
+  language: c++
+  headers:
+  - src/core/lib/promise/poll.h
+  src:
+  - test/core/promise/poll_test.cc
+  deps:
+  - absl/types:variant
+  uses_polling: false
+- name: popularity_count_test
+  gtest: true
+  build: test
+  language: c++
+  headers:
+  - src/core/ext/transport/chttp2/transport/popularity_count.h
+  src:
+  - test/core/transport/chttp2/popularity_count_test.cc
+  deps: []
 - name: port_sharing_end2end_test
   gtest: true
   build: test
@@ -6001,6 +7092,53 @@ targets:
   - test/cpp/end2end/test_service_impl.cc
   deps:
   - grpc++_test_util
+- name: promise_factory_test
+  gtest: true
+  build: test
+  language: c++
+  headers:
+  - src/core/lib/gprpp/capture.h
+  - src/core/lib/promise/detail/promise_factory.h
+  - src/core/lib/promise/detail/promise_like.h
+  - src/core/lib/promise/poll.h
+  - src/core/lib/promise/promise.h
+  src:
+  - test/core/promise/promise_factory_test.cc
+  deps:
+  - absl/functional:bind_front
+  - absl/types:optional
+  - absl/types:variant
+  - absl/utility:utility
+  uses_polling: false
+- name: promise_map_test
+  gtest: true
+  build: test
+  language: c++
+  headers:
+  - src/core/lib/promise/detail/promise_like.h
+  - src/core/lib/promise/map.h
+  - src/core/lib/promise/poll.h
+  - src/core/lib/promise/promise.h
+  src:
+  - test/core/promise/map_test.cc
+  deps:
+  - absl/types:optional
+  - absl/types:variant
+  uses_polling: false
+- name: promise_test
+  gtest: true
+  build: test
+  language: c++
+  headers:
+  - src/core/lib/promise/detail/promise_like.h
+  - src/core/lib/promise/poll.h
+  - src/core/lib/promise/promise.h
+  src:
+  - test/core/promise/promise_test.cc
+  deps:
+  - absl/types:optional
+  - absl/types:variant
+  uses_polling: false
 - name: proto_server_reflection_test
   gtest: true
   build: test
@@ -6111,6 +7249,18 @@ targets:
   deps:
   - grpc++_test_config
   - grpc++_test_util
+- name: race_test
+  gtest: true
+  build: test
+  language: c++
+  headers:
+  - src/core/lib/promise/poll.h
+  - src/core/lib/promise/race.h
+  src:
+  - test/core/promise/race_test.cc
+  deps:
+  - absl/types:variant
+  uses_polling: false
 - name: raw_end2end_test
   gtest: true
   build: test
@@ -6186,6 +7336,31 @@ targets:
   deps:
   - grpc_test_util
   uses_polling: false
+- name: sdk_authz_end2end_test
+  gtest: true
+  build: test
+  language: c++
+  headers:
+  - src/core/lib/security/authorization/grpc_authorization_engine.h
+  - src/core/lib/security/authorization/grpc_authorization_policy_provider.h
+  - src/core/lib/security/authorization/matchers.h
+  - src/core/lib/security/authorization/rbac_policy.h
+  - src/core/lib/security/authorization/rbac_translator.h
+  - test/cpp/end2end/test_service_impl.h
+  src:
+  - src/proto/grpc/testing/echo.proto
+  - src/proto/grpc/testing/echo_messages.proto
+  - src/proto/grpc/testing/simple_messages.proto
+  - src/core/lib/security/authorization/grpc_authorization_engine.cc
+  - src/core/lib/security/authorization/grpc_authorization_policy_provider.cc
+  - src/core/lib/security/authorization/matchers.cc
+  - src/core/lib/security/authorization/rbac_policy.cc
+  - src/core/lib/security/authorization/rbac_translator.cc
+  - src/cpp/server/authorization_policy_provider.cc
+  - test/cpp/end2end/sdk_authz_end2end_test.cc
+  - test/cpp/end2end/test_service_impl.cc
+  deps:
+  - grpc++_test_util
 - name: secure_auth_context_test
   gtest: true
   build: test
@@ -6195,6 +7370,23 @@ targets:
   - test/cpp/common/secure_auth_context_test.cc
   deps:
   - grpc++_test_util
+- name: seq_test
+  gtest: true
+  build: test
+  language: c++
+  headers:
+  - src/core/lib/gprpp/construct_destruct.h
+  - src/core/lib/promise/detail/basic_seq.h
+  - src/core/lib/promise/detail/promise_factory.h
+  - src/core/lib/promise/detail/promise_like.h
+  - src/core/lib/promise/detail/switch.h
+  - src/core/lib/promise/poll.h
+  - src/core/lib/promise/seq.h
+  src:
+  - test/core/promise/seq_test.cc
+  deps:
+  - absl/types:variant
+  uses_polling: false
 - name: server_builder_plugin_test
   gtest: true
   build: test
@@ -6659,6 +7851,16 @@ targets:
   - test/core/security/tls_security_connector_test.cc
   deps:
   - grpc_test_util
+- name: tls_test
+  gtest: true
+  build: test
+  language: c++
+  headers: []
+  src:
+  - test/core/gpr/tls_test.cc
+  deps:
+  - grpc_test_util
+  uses_polling: false
 - name: too_many_pings_test
   gtest: true
   build: test
@@ -6671,6 +7873,61 @@ targets:
   deps:
   - grpc++_test_config
   - grpc++_test_util
+- name: transport_stream_receiver_test
+  gtest: true
+  build: test
+  language: c++
+  headers:
+  - src/core/ext/transport/binder/utils/transport_stream_receiver.h
+  - src/core/ext/transport/binder/utils/transport_stream_receiver_impl.h
+  - src/core/ext/transport/binder/wire_format/transaction.h
+  src:
+  - src/core/ext/transport/binder/utils/transport_stream_receiver_impl.cc
+  - src/core/ext/transport/binder/wire_format/transaction.cc
+  - test/core/transport/binder/transport_stream_receiver_test.cc
+  deps:
+  - grpc_test_util
+  uses_polling: false
+- name: try_join_test
+  gtest: true
+  build: test
+  language: c++
+  headers:
+  - src/core/lib/gprpp/bitset.h
+  - src/core/lib/gprpp/construct_destruct.h
+  - src/core/lib/promise/detail/basic_join.h
+  - src/core/lib/promise/detail/promise_factory.h
+  - src/core/lib/promise/detail/promise_like.h
+  - src/core/lib/promise/detail/status.h
+  - src/core/lib/promise/poll.h
+  - src/core/lib/promise/try_join.h
+  src:
+  - test/core/promise/try_join_test.cc
+  deps:
+  - absl/status:status
+  - absl/status:statusor
+  - absl/types:variant
+  uses_polling: false
+- name: try_seq_test
+  gtest: true
+  build: test
+  language: c++
+  headers:
+  - src/core/lib/gprpp/construct_destruct.h
+  - src/core/lib/promise/detail/basic_seq.h
+  - src/core/lib/promise/detail/promise_factory.h
+  - src/core/lib/promise/detail/promise_like.h
+  - src/core/lib/promise/detail/status.h
+  - src/core/lib/promise/detail/switch.h
+  - src/core/lib/promise/poll.h
+  - src/core/lib/promise/try_seq.h
+  src:
+  - test/core/promise/try_seq_test.cc
+  deps:
+  - absl/status:status
+  - absl/status:statusor
+  - absl/types:variant
+  uses_polling: false
 - name: unknown_frame_bad_client_test
   gtest: true
   build: test
@@ -6720,6 +7977,56 @@ targets:
   - test/core/end2end/cq_verifier.cc
   deps:
   - grpc_test_util
+- name: wire_reader_test
+  gtest: true
+  build: test
+  language: c++
+  headers:
+  - src/core/ext/transport/binder/utils/transport_stream_receiver.h
+  - src/core/ext/transport/binder/utils/transport_stream_receiver_impl.h
+  - src/core/ext/transport/binder/wire_format/binder.h
+  - src/core/ext/transport/binder/wire_format/binder_constants.h
+  - src/core/ext/transport/binder/wire_format/transaction.h
+  - src/core/ext/transport/binder/wire_format/wire_reader.h
+  - src/core/ext/transport/binder/wire_format/wire_reader_impl.h
+  - src/core/ext/transport/binder/wire_format/wire_writer.h
+  - test/core/transport/binder/mock_objects.h
+  src:
+  - src/core/ext/transport/binder/utils/transport_stream_receiver_impl.cc
+  - src/core/ext/transport/binder/wire_format/binder_constants.cc
+  - src/core/ext/transport/binder/wire_format/transaction.cc
+  - src/core/ext/transport/binder/wire_format/wire_reader_impl.cc
+  - src/core/ext/transport/binder/wire_format/wire_writer.cc
+  - test/core/transport/binder/mock_objects.cc
+  - test/core/transport/binder/wire_reader_test.cc
+  deps:
+  - grpc_test_util
+  uses_polling: false
+- name: wire_writer_test
+  gtest: true
+  build: test
+  language: c++
+  headers:
+  - src/core/ext/transport/binder/utils/transport_stream_receiver.h
+  - src/core/ext/transport/binder/utils/transport_stream_receiver_impl.h
+  - src/core/ext/transport/binder/wire_format/binder.h
+  - src/core/ext/transport/binder/wire_format/binder_constants.h
+  - src/core/ext/transport/binder/wire_format/transaction.h
+  - src/core/ext/transport/binder/wire_format/wire_reader.h
+  - src/core/ext/transport/binder/wire_format/wire_reader_impl.h
+  - src/core/ext/transport/binder/wire_format/wire_writer.h
+  - test/core/transport/binder/mock_objects.h
+  src:
+  - src/core/ext/transport/binder/utils/transport_stream_receiver_impl.cc
+  - src/core/ext/transport/binder/wire_format/binder_constants.cc
+  - src/core/ext/transport/binder/wire_format/transaction.cc
+  - src/core/ext/transport/binder/wire_format/wire_reader_impl.cc
+  - src/core/ext/transport/binder/wire_format/wire_writer.cc
+  - test/core/transport/binder/mock_objects.cc
+  - test/core/transport/binder/wire_writer_test.cc
+  deps:
+  - grpc_test_util
+  uses_polling: false
 - name: work_serializer_test
   gtest: true
   build: test
@@ -6752,6 +8059,7 @@ targets:
   - test/core/util/port_server_client.h
   - test/core/util/reconnect_server.h
   - test/core/util/resolve_localhost_ip46.h
+  - test/core/util/resource_user_util.h
   - test/core/util/slice_splitter.h
   - test/core/util/stack_tracer.h
   - test/core/util/subprocess.h
@@ -6776,6 +8084,7 @@ targets:
   - test/core/util/port_server_client.cc
   - test/core/util/reconnect_server.cc
   - test/core/util/resolve_localhost_ip46.cc
+  - test/core/util/resource_user_util.cc
   - test/core/util/slice_splitter.cc
   - test/core/util/stack_tracer.cc
   - test/core/util/subprocess_posix.cc
@@ -6863,6 +8172,7 @@ targets:
   - src/proto/grpc/testing/xds/v3/csds.proto
   - src/proto/grpc/testing/xds/v3/discovery.proto
   - src/proto/grpc/testing/xds/v3/endpoint.proto
+  - src/proto/grpc/testing/xds/v3/extension.proto
   - src/proto/grpc/testing/xds/v3/fault.proto
   - src/proto/grpc/testing/xds/v3/fault_common.proto
   - src/proto/grpc/testing/xds/v3/http_connection_manager.proto
@@ -6881,6 +8191,7 @@ targets:
   - test/cpp/end2end/test_service_impl.cc
   - test/cpp/end2end/xds_end2end_test.cc
   deps:
+  - grpc++_test_config
   - grpc++_test_util
   platforms:
   - linux
index a824ddc..7b89bc5 100644 (file)
@@ -13,5 +13,5 @@
 # limitations under the License.
 
 module GrpcBuildConfig
-  CORE_WINDOWS_DLL = '/tmp/libs/opt/grpc-18.dll'
+  CORE_WINDOWS_DLL = '/tmp/libs/opt/grpc-19.dll'
 end
index b4be6f9..1fe0577 100644 (file)
@@ -12,11 +12,11 @@ settings:
   '#08': Use "-preN" suffixes to identify pre-release versions
   '#09': Per-language overrides are possible with (eg) ruby_version tag here
   '#10': See the expand_version.py for all the quirks here
-  core_version: 18.0.0
+  core_version: 19.0.0
   csharp_major_version: 2
-  g_stands_for: guileless
-  protobuf_version: 3.15.8
-  version: 1.40.0
+  g_stands_for: goat
+  protobuf_version: 3.17.3
+  version: 1.41.0
 targets:
 - name: check_epollexclusive
   build: tool
@@ -35,19 +35,6 @@ targets:
   - grpc
   - gpr
   uses_polling: false
-- name: gen_legal_metadata_characters
-  build: tool
-  language: c++
-  src:
-  - tools/codegen/core/gen_legal_metadata_characters.cc
-  deps: []
-- name: gen_percent_encoding_tables
-  build: tool
-  language: c++
-  src:
-  - tools/codegen/core/gen_percent_encoding_tables.cc
-  deps: []
-  uses_polling: false
 configs:
   asan:
     CC: clang
index 078d495..c89ba26 100644 (file)
@@ -17,15 +17,12 @@ if(gRPC_ABSL_PROVIDER STREQUAL "module")
     set(ABSL_ROOT_DIR ${CMAKE_CURRENT_SOURCE_DIR}/third_party/abseil-cpp)
   endif()
   if(EXISTS "${ABSL_ROOT_DIR}/CMakeLists.txt")
-    add_subdirectory(${ABSL_ROOT_DIR} third_party/abseil-cpp)
-    if(TARGET absl_base)
-      if(gRPC_INSTALL AND _gRPC_INSTALL_SUPPORTED_FROM_MODULE)
-        install(TARGETS ${gRPC_ABSL_USED_TARGETS} EXPORT gRPCTargets
-          RUNTIME DESTINATION ${gRPC_INSTALL_BINDIR}
-          LIBRARY DESTINATION ${gRPC_INSTALL_LIBDIR}
-          ARCHIVE DESTINATION ${gRPC_INSTALL_LIBDIR})
-      endif()
+    if(gRPC_INSTALL)
+      # When gRPC_INSTALL is enabled and Abseil will be built as a module,
+      # Abseil will be installed along with gRPC for convenience.
+      set(ABSL_ENABLE_INSTALL ON)
     endif()
+    add_subdirectory(${ABSL_ROOT_DIR} third_party/abseil-cpp)
   else()
     message(WARNING "gRPC_ABSL_PROVIDER is \"module\" but ABSL_ROOT_DIR is wrong")
   endif()
@@ -36,5 +33,5 @@ if(gRPC_ABSL_PROVIDER STREQUAL "module")
 elseif(gRPC_ABSL_PROVIDER STREQUAL "package")
   # Use "CONFIG" as there is no built-in cmake module for absl.
   find_package(absl REQUIRED CONFIG)
-  set(_gRPC_FIND_ABSL "if(NOT absl_FOUND)\n  find_package(absl CONFIG)\nendif()")
 endif()
+set(_gRPC_FIND_ABSL "if(NOT TARGET absl::strings)\n  find_package(absl CONFIG)\nendif()")
index 939efca..261cf3d 100644 (file)
--- a/config.m4
+++ b/config.m4
@@ -78,12 +78,10 @@ if test "$PHP_GRPC" != "no"; then
     src/core/ext/filters/client_channel/resolver.cc \
     src/core/ext/filters/client_channel/resolver/dns/c_ares/dns_resolver_ares.cc \
     src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_event_engine.cc \
-    src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_libuv.cc \
     src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_posix.cc \
     src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_windows.cc \
     src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper.cc \
     src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_event_engine.cc \
-    src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_libuv.cc \
     src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_posix.cc \
     src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_windows.cc \
     src/core/ext/filters/client_channel/resolver/dns/dns_resolver_selection.cc \
@@ -141,8 +139,10 @@ if test "$PHP_GRPC" != "no"; then
     src/core/ext/transport/chttp2/transport/frame_settings.cc \
     src/core/ext/transport/chttp2/transport/frame_window_update.cc \
     src/core/ext/transport/chttp2/transport/hpack_encoder.cc \
+    src/core/ext/transport/chttp2/transport/hpack_encoder_table.cc \
     src/core/ext/transport/chttp2/transport/hpack_parser.cc \
-    src/core/ext/transport/chttp2/transport/hpack_table.cc \
+    src/core/ext/transport/chttp2/transport/hpack_parser_table.cc \
+    src/core/ext/transport/chttp2/transport/hpack_utils.cc \
     src/core/ext/transport/chttp2/transport/http2_settings.cc \
     src/core/ext/transport/chttp2/transport/huffsyms.cc \
     src/core/ext/transport/chttp2/transport/incoming_metadata.cc \
@@ -382,6 +382,7 @@ if test "$PHP_GRPC" != "no"; then
     src/core/lib/compression/stream_compression.cc \
     src/core/lib/compression/stream_compression_gzip.cc \
     src/core/lib/compression/stream_compression_identity.cc \
+    src/core/lib/config/core_configuration.cc \
     src/core/lib/debug/stats.cc \
     src/core/lib/debug/stats_data.cc \
     src/core/lib/debug/trace.cc \
@@ -415,7 +416,6 @@ if test "$PHP_GRPC" != "no"; then
     src/core/lib/gpr/time_posix.cc \
     src/core/lib/gpr/time_precise.cc \
     src/core/lib/gpr/time_windows.cc \
-    src/core/lib/gpr/tls_pthread.cc \
     src/core/lib/gpr/tmpfile_msys.cc \
     src/core/lib/gpr/tmpfile_posix.cc \
     src/core/lib/gpr/tmpfile_windows.cc \
@@ -445,7 +445,6 @@ if test "$PHP_GRPC" != "no"; then
     src/core/lib/iomgr/endpoint_cfstream.cc \
     src/core/lib/iomgr/endpoint_pair_event_engine.cc \
     src/core/lib/iomgr/endpoint_pair_posix.cc \
-    src/core/lib/iomgr/endpoint_pair_uv.cc \
     src/core/lib/iomgr/endpoint_pair_windows.cc \
     src/core/lib/iomgr/error.cc \
     src/core/lib/iomgr/error_cfstream.cc \
@@ -481,7 +480,6 @@ if test "$PHP_GRPC" != "no"; then
     src/core/lib/iomgr/iomgr_internal.cc \
     src/core/lib/iomgr/iomgr_posix.cc \
     src/core/lib/iomgr/iomgr_posix_cfstream.cc \
-    src/core/lib/iomgr/iomgr_uv.cc \
     src/core/lib/iomgr/iomgr_windows.cc \
     src/core/lib/iomgr/is_epollexclusive_available.cc \
     src/core/lib/iomgr/load_file.cc \
@@ -492,7 +490,6 @@ if test "$PHP_GRPC" != "no"; then
     src/core/lib/iomgr/pollset_set.cc \
     src/core/lib/iomgr/pollset_set_custom.cc \
     src/core/lib/iomgr/pollset_set_windows.cc \
-    src/core/lib/iomgr/pollset_uv.cc \
     src/core/lib/iomgr/pollset_windows.cc \
     src/core/lib/iomgr/resolve_address.cc \
     src/core/lib/iomgr/resolve_address_custom.cc \
@@ -504,7 +501,6 @@ if test "$PHP_GRPC" != "no"; then
     src/core/lib/iomgr/socket_utils_common_posix.cc \
     src/core/lib/iomgr/socket_utils_linux.cc \
     src/core/lib/iomgr/socket_utils_posix.cc \
-    src/core/lib/iomgr/socket_utils_uv.cc \
     src/core/lib/iomgr/socket_utils_windows.cc \
     src/core/lib/iomgr/socket_windows.cc \
     src/core/lib/iomgr/tcp_client.cc \
@@ -521,7 +517,6 @@ if test "$PHP_GRPC" != "no"; then
     src/core/lib/iomgr/tcp_server_utils_posix_ifaddrs.cc \
     src/core/lib/iomgr/tcp_server_utils_posix_noifaddrs.cc \
     src/core/lib/iomgr/tcp_server_windows.cc \
-    src/core/lib/iomgr/tcp_uv.cc \
     src/core/lib/iomgr/tcp_windows.cc \
     src/core/lib/iomgr/time_averaged_stats.cc \
     src/core/lib/iomgr/timer.cc \
@@ -529,7 +524,6 @@ if test "$PHP_GRPC" != "no"; then
     src/core/lib/iomgr/timer_generic.cc \
     src/core/lib/iomgr/timer_heap.cc \
     src/core/lib/iomgr/timer_manager.cc \
-    src/core/lib/iomgr/timer_uv.cc \
     src/core/lib/iomgr/udp_server.cc \
     src/core/lib/iomgr/unix_sockets_posix.cc \
     src/core/lib/iomgr/unix_sockets_posix_noop.cc \
@@ -546,6 +540,7 @@ if test "$PHP_GRPC" != "no"; then
     src/core/lib/profiling/stap_timers.cc \
     src/core/lib/security/authorization/authorization_policy_provider_vtable.cc \
     src/core/lib/security/authorization/evaluate_args.cc \
+    src/core/lib/security/authorization/sdk_server_authz_filter.cc \
     src/core/lib/security/context/security_context.cc \
     src/core/lib/security/credentials/alts/alts_credentials.cc \
     src/core/lib/security/credentials/alts/check_gcp_environment.cc \
@@ -995,6 +990,7 @@ if test "$PHP_GRPC" != "no"; then
     third_party/boringssl-with-bazel/src/ssl/dtls_method.cc \
     third_party/boringssl-with-bazel/src/ssl/dtls_record.cc \
     third_party/boringssl-with-bazel/src/ssl/encrypted_client_hello.cc \
+    third_party/boringssl-with-bazel/src/ssl/extensions.cc \
     third_party/boringssl-with-bazel/src/ssl/handoff.cc \
     third_party/boringssl-with-bazel/src/ssl/handshake.cc \
     third_party/boringssl-with-bazel/src/ssl/handshake_client.cc \
@@ -1017,7 +1013,6 @@ if test "$PHP_GRPC" != "no"; then
     third_party/boringssl-with-bazel/src/ssl/ssl_versions.cc \
     third_party/boringssl-with-bazel/src/ssl/ssl_x509.cc \
     third_party/boringssl-with-bazel/src/ssl/t1_enc.cc \
-    third_party/boringssl-with-bazel/src/ssl/t1_lib.cc \
     third_party/boringssl-with-bazel/src/ssl/tls13_both.cc \
     third_party/boringssl-with-bazel/src/ssl/tls13_client.cc \
     third_party/boringssl-with-bazel/src/ssl/tls13_enc.cc \
@@ -1061,7 +1056,7 @@ if test "$PHP_GRPC" != "no"; then
     -D_HAS_EXCEPTIONS=0 -DNOMINMAX -DGRPC_ARES=0 \
     -DGRPC_POSIX_FORK_ALLOW_PTHREAD_ATFORK=1 \
     -DGRPC_XDS_USER_AGENT_NAME_SUFFIX='"\"PHP\""' \
-    -DGRPC_XDS_USER_AGENT_VERSION_SUFFIX='"\"1.40.0\""')
+    -DGRPC_XDS_USER_AGENT_VERSION_SUFFIX='"\"1.41.0\""')
 
   PHP_ADD_BUILD_DIR($ext_builddir/src/core/ext/filters/census)
   PHP_ADD_BUILD_DIR($ext_builddir/src/core/ext/filters/client_channel)
@@ -1186,6 +1181,7 @@ if test "$PHP_GRPC" != "no"; then
   PHP_ADD_BUILD_DIR($ext_builddir/src/core/lib/backoff)
   PHP_ADD_BUILD_DIR($ext_builddir/src/core/lib/channel)
   PHP_ADD_BUILD_DIR($ext_builddir/src/core/lib/compression)
+  PHP_ADD_BUILD_DIR($ext_builddir/src/core/lib/config)
   PHP_ADD_BUILD_DIR($ext_builddir/src/core/lib/debug)
   PHP_ADD_BUILD_DIR($ext_builddir/src/core/lib/event_engine)
   PHP_ADD_BUILD_DIR($ext_builddir/src/core/lib/gpr)
index 1d6e69d..66eb917 100644 (file)
@@ -44,12 +44,10 @@ if (PHP_GRPC != "no") {
     "src\\core\\ext\\filters\\client_channel\\resolver.cc " +
     "src\\core\\ext\\filters\\client_channel\\resolver\\dns\\c_ares\\dns_resolver_ares.cc " +
     "src\\core\\ext\\filters\\client_channel\\resolver\\dns\\c_ares\\grpc_ares_ev_driver_event_engine.cc " +
-    "src\\core\\ext\\filters\\client_channel\\resolver\\dns\\c_ares\\grpc_ares_ev_driver_libuv.cc " +
     "src\\core\\ext\\filters\\client_channel\\resolver\\dns\\c_ares\\grpc_ares_ev_driver_posix.cc " +
     "src\\core\\ext\\filters\\client_channel\\resolver\\dns\\c_ares\\grpc_ares_ev_driver_windows.cc " +
     "src\\core\\ext\\filters\\client_channel\\resolver\\dns\\c_ares\\grpc_ares_wrapper.cc " +
     "src\\core\\ext\\filters\\client_channel\\resolver\\dns\\c_ares\\grpc_ares_wrapper_event_engine.cc " +
-    "src\\core\\ext\\filters\\client_channel\\resolver\\dns\\c_ares\\grpc_ares_wrapper_libuv.cc " +
     "src\\core\\ext\\filters\\client_channel\\resolver\\dns\\c_ares\\grpc_ares_wrapper_posix.cc " +
     "src\\core\\ext\\filters\\client_channel\\resolver\\dns\\c_ares\\grpc_ares_wrapper_windows.cc " +
     "src\\core\\ext\\filters\\client_channel\\resolver\\dns\\dns_resolver_selection.cc " +
@@ -107,8 +105,10 @@ if (PHP_GRPC != "no") {
     "src\\core\\ext\\transport\\chttp2\\transport\\frame_settings.cc " +
     "src\\core\\ext\\transport\\chttp2\\transport\\frame_window_update.cc " +
     "src\\core\\ext\\transport\\chttp2\\transport\\hpack_encoder.cc " +
+    "src\\core\\ext\\transport\\chttp2\\transport\\hpack_encoder_table.cc " +
     "src\\core\\ext\\transport\\chttp2\\transport\\hpack_parser.cc " +
-    "src\\core\\ext\\transport\\chttp2\\transport\\hpack_table.cc " +
+    "src\\core\\ext\\transport\\chttp2\\transport\\hpack_parser_table.cc " +
+    "src\\core\\ext\\transport\\chttp2\\transport\\hpack_utils.cc " +
     "src\\core\\ext\\transport\\chttp2\\transport\\http2_settings.cc " +
     "src\\core\\ext\\transport\\chttp2\\transport\\huffsyms.cc " +
     "src\\core\\ext\\transport\\chttp2\\transport\\incoming_metadata.cc " +
@@ -348,6 +348,7 @@ if (PHP_GRPC != "no") {
     "src\\core\\lib\\compression\\stream_compression.cc " +
     "src\\core\\lib\\compression\\stream_compression_gzip.cc " +
     "src\\core\\lib\\compression\\stream_compression_identity.cc " +
+    "src\\core\\lib\\config\\core_configuration.cc " +
     "src\\core\\lib\\debug\\stats.cc " +
     "src\\core\\lib\\debug\\stats_data.cc " +
     "src\\core\\lib\\debug\\trace.cc " +
@@ -381,7 +382,6 @@ if (PHP_GRPC != "no") {
     "src\\core\\lib\\gpr\\time_posix.cc " +
     "src\\core\\lib\\gpr\\time_precise.cc " +
     "src\\core\\lib\\gpr\\time_windows.cc " +
-    "src\\core\\lib\\gpr\\tls_pthread.cc " +
     "src\\core\\lib\\gpr\\tmpfile_msys.cc " +
     "src\\core\\lib\\gpr\\tmpfile_posix.cc " +
     "src\\core\\lib\\gpr\\tmpfile_windows.cc " +
@@ -411,7 +411,6 @@ if (PHP_GRPC != "no") {
     "src\\core\\lib\\iomgr\\endpoint_cfstream.cc " +
     "src\\core\\lib\\iomgr\\endpoint_pair_event_engine.cc " +
     "src\\core\\lib\\iomgr\\endpoint_pair_posix.cc " +
-    "src\\core\\lib\\iomgr\\endpoint_pair_uv.cc " +
     "src\\core\\lib\\iomgr\\endpoint_pair_windows.cc " +
     "src\\core\\lib\\iomgr\\error.cc " +
     "src\\core\\lib\\iomgr\\error_cfstream.cc " +
@@ -447,7 +446,6 @@ if (PHP_GRPC != "no") {
     "src\\core\\lib\\iomgr\\iomgr_internal.cc " +
     "src\\core\\lib\\iomgr\\iomgr_posix.cc " +
     "src\\core\\lib\\iomgr\\iomgr_posix_cfstream.cc " +
-    "src\\core\\lib\\iomgr\\iomgr_uv.cc " +
     "src\\core\\lib\\iomgr\\iomgr_windows.cc " +
     "src\\core\\lib\\iomgr\\is_epollexclusive_available.cc " +
     "src\\core\\lib\\iomgr\\load_file.cc " +
@@ -458,7 +456,6 @@ if (PHP_GRPC != "no") {
     "src\\core\\lib\\iomgr\\pollset_set.cc " +
     "src\\core\\lib\\iomgr\\pollset_set_custom.cc " +
     "src\\core\\lib\\iomgr\\pollset_set_windows.cc " +
-    "src\\core\\lib\\iomgr\\pollset_uv.cc " +
     "src\\core\\lib\\iomgr\\pollset_windows.cc " +
     "src\\core\\lib\\iomgr\\resolve_address.cc " +
     "src\\core\\lib\\iomgr\\resolve_address_custom.cc " +
@@ -470,7 +467,6 @@ if (PHP_GRPC != "no") {
     "src\\core\\lib\\iomgr\\socket_utils_common_posix.cc " +
     "src\\core\\lib\\iomgr\\socket_utils_linux.cc " +
     "src\\core\\lib\\iomgr\\socket_utils_posix.cc " +
-    "src\\core\\lib\\iomgr\\socket_utils_uv.cc " +
     "src\\core\\lib\\iomgr\\socket_utils_windows.cc " +
     "src\\core\\lib\\iomgr\\socket_windows.cc " +
     "src\\core\\lib\\iomgr\\tcp_client.cc " +
@@ -487,7 +483,6 @@ if (PHP_GRPC != "no") {
     "src\\core\\lib\\iomgr\\tcp_server_utils_posix_ifaddrs.cc " +
     "src\\core\\lib\\iomgr\\tcp_server_utils_posix_noifaddrs.cc " +
     "src\\core\\lib\\iomgr\\tcp_server_windows.cc " +
-    "src\\core\\lib\\iomgr\\tcp_uv.cc " +
     "src\\core\\lib\\iomgr\\tcp_windows.cc " +
     "src\\core\\lib\\iomgr\\time_averaged_stats.cc " +
     "src\\core\\lib\\iomgr\\timer.cc " +
@@ -495,7 +490,6 @@ if (PHP_GRPC != "no") {
     "src\\core\\lib\\iomgr\\timer_generic.cc " +
     "src\\core\\lib\\iomgr\\timer_heap.cc " +
     "src\\core\\lib\\iomgr\\timer_manager.cc " +
-    "src\\core\\lib\\iomgr\\timer_uv.cc " +
     "src\\core\\lib\\iomgr\\udp_server.cc " +
     "src\\core\\lib\\iomgr\\unix_sockets_posix.cc " +
     "src\\core\\lib\\iomgr\\unix_sockets_posix_noop.cc " +
@@ -512,6 +506,7 @@ if (PHP_GRPC != "no") {
     "src\\core\\lib\\profiling\\stap_timers.cc " +
     "src\\core\\lib\\security\\authorization\\authorization_policy_provider_vtable.cc " +
     "src\\core\\lib\\security\\authorization\\evaluate_args.cc " +
+    "src\\core\\lib\\security\\authorization\\sdk_server_authz_filter.cc " +
     "src\\core\\lib\\security\\context\\security_context.cc " +
     "src\\core\\lib\\security\\credentials\\alts\\alts_credentials.cc " +
     "src\\core\\lib\\security\\credentials\\alts\\check_gcp_environment.cc " +
@@ -961,6 +956,7 @@ if (PHP_GRPC != "no") {
     "third_party\\boringssl-with-bazel\\src\\ssl\\dtls_method.cc " +
     "third_party\\boringssl-with-bazel\\src\\ssl\\dtls_record.cc " +
     "third_party\\boringssl-with-bazel\\src\\ssl\\encrypted_client_hello.cc " +
+    "third_party\\boringssl-with-bazel\\src\\ssl\\extensions.cc " +
     "third_party\\boringssl-with-bazel\\src\\ssl\\handoff.cc " +
     "third_party\\boringssl-with-bazel\\src\\ssl\\handshake.cc " +
     "third_party\\boringssl-with-bazel\\src\\ssl\\handshake_client.cc " +
@@ -983,7 +979,6 @@ if (PHP_GRPC != "no") {
     "third_party\\boringssl-with-bazel\\src\\ssl\\ssl_versions.cc " +
     "third_party\\boringssl-with-bazel\\src\\ssl\\ssl_x509.cc " +
     "third_party\\boringssl-with-bazel\\src\\ssl\\t1_enc.cc " +
-    "third_party\\boringssl-with-bazel\\src\\ssl\\t1_lib.cc " +
     "third_party\\boringssl-with-bazel\\src\\ssl\\tls13_both.cc " +
     "third_party\\boringssl-with-bazel\\src\\ssl\\tls13_client.cc " +
     "third_party\\boringssl-with-bazel\\src\\ssl\\tls13_enc.cc " +
@@ -1287,6 +1282,7 @@ if (PHP_GRPC != "no") {
   FSO.CreateFolder(base_dir+"\\ext\\grpc\\src\\core\\lib\\backoff");
   FSO.CreateFolder(base_dir+"\\ext\\grpc\\src\\core\\lib\\channel");
   FSO.CreateFolder(base_dir+"\\ext\\grpc\\src\\core\\lib\\compression");
+  FSO.CreateFolder(base_dir+"\\ext\\grpc\\src\\core\\lib\\config");
   FSO.CreateFolder(base_dir+"\\ext\\grpc\\src\\core\\lib\\debug");
   FSO.CreateFolder(base_dir+"\\ext\\grpc\\src\\core\\lib\\event_engine");
   FSO.CreateFolder(base_dir+"\\ext\\grpc\\src\\core\\lib\\gpr");
index 410435c..db1ae48 100644 (file)
@@ -44,8 +44,6 @@ C++ compatible with
   - `<ratio>`
   - `<system_error>`
   - `<filesystem>`
-- `grpc_core::Atomic` is prefered over `std::atomic` in gRPC library because it provides
-  additional debugging information.
 
 ## Roadmap
 
index 1aa0719..48c2292 100644 (file)
@@ -78,6 +78,7 @@ some configuration as environment variables that can be set.
   - ring_hash_lb - traces the ring hash load balancing policy
   - round_robin - traces the round_robin load balancing policy
   - queue_pluck
+  - sdk_authz - traces sdk authorization
   - server_channel - lightweight trace of significant server channel events
   - secure_endpoint - traces bytes flowing through encrypted channels
   - subchannel - traces the connectivity state of subchannel
@@ -96,7 +97,6 @@ some configuration as environment variables that can be set.
 
   The following tracers will only run in binaries built in DEBUG mode. This is
   accomplished by invoking `CONFIG=dbg make <target>`
-  - alarm_refcount - refcounting traces for grpc_alarm structure
   - metadata - tracks creation and mutation of metadata
   - combiner - traces combiner lock state
   - call_combiner - traces call combiner state
index 5c891c6..35b477a 100644 (file)
@@ -39,5 +39,5 @@
 - 1.37 'g' stands for ['gilded'](https://github.com/grpc/grpc/tree/v1.37.x)
 - 1.38 'g' stands for ['guadalupe_river_park_conservancy'](https://github.com/grpc/grpc/tree/v1.38.x)
 - 1.39 'g' stands for ['goofy'](https://github.com/grpc/grpc/tree/v1.39.x)
-- 1.40 'g' stands for ['guileless'](https://github.com/grpc/grpc/tree/master)
-- 1.41 'g' stands for goat
+- 1.40 'g' stands for ['guileless'](https://github.com/grpc/grpc/tree/v1.40.x)
+- 1.41 'g' stands for ['goat'](https://github.com/grpc/grpc/tree/v1.41.x)
index 1acb57b..1e8124e 100644 (file)
@@ -7,10 +7,24 @@ Note that a gRPC client will simply ignore the configuration of a feature it
 does not support. The gRPC client does not generate a log
 to indicate that some configuration was ignored. It is impractical to generate
 a log and keep it up-to-date because xDS has a large number of APIs that gRPC
-does not support and the APIs keep evolving too. We recommend reading the
+does not support and the APIs keep evolving too. In the case where an xDS
+field corresponding to a feature is supported but the value configured for
+that field is not supported, a gRPC client will NACK such a configuration.
+We recommend reading the
 [first gRFC](https://github.com/grpc/proposal/blob/master/A27-xds-global-load-balancing.md)
 on xDS support in gRPC to understand the design philosophy.
 
+Not all cluster load balancing policies are supported. A gRPC client will
+NACK the configuration that contains unsupported cluster load balancing
+policy. This will cause all cluster configurations to be rejected by the
+client because the xDS protocol currently requires rejecting all resources in
+a given response, rather than being able to reject only an individual resource
+from the response. Due to this limitation, you must ensure that all clients
+support the required cluster load balancing policy before configuring that
+policy for a service. For example, if you change the ROUND_ROBIN policy to
+RING_HASH, you must ensure that all the clients are upgraded to a version that
+supports RING_HASH.
+
 The EDS policy will *not* support
 [overprovisioning](https://www.envoyproxy.io/docs/envoy/latest/intro/arch_overview/upstream/load_balancing/overprovisioning),
 which is different from Envoy.  Envoy takes the overprovisioning into
@@ -48,3 +62,5 @@ Support for [xDS v3 APIs](https://www.envoyproxy.io/docs/envoy/latest/api-v3/api
 [Circuit Breaking](https://www.envoyproxy.io/docs/envoy/latest/api-v3/config/cluster/v3/circuit_breaker.proto):<ul><li>Only max_requests is supported.</li></ul> | [A32](https://github.com/grpc/proposal/blob/master/A32-xds-circuit-breaking.md) | v1.37.1 (N/A for PHP) | v1.37.1 | v1.37.0 | |
 [Fault Injection](https://www.envoyproxy.io/docs/envoy/latest/api-v3/extensions/filters/http/fault/v3/fault.proto):<br> Only the following fields are supported:<ul><li>delay</li><li>abort</li><li>max_active_faults</li><li>headers</li></ul> | [A33](https://github.com/grpc/proposal/blob/master/A33-Fault-Injection.md) | v1.37.1  | v1.37.1 | v1.37.0 | |
 [Client Status Discovery Service](https://github.com/envoyproxy/envoy/blob/main/api/envoy/service/status/v3/csds.proto) | [A40](https://github.com/grpc/proposal/blob/master/A40-csds-support.md) | v1.37.1 (C++)<br>v1.38.0 (Python)  | v1.37.1 | v1.37.0 | |
+[Ring hash](https://www.envoyproxy.io/docs/envoy/latest/intro/arch_overview/upstream/load_balancing/load_balancers#ring-hash) load balancing policy:<br> Only the following [policy specifiers](https://github.com/envoyproxy/envoy/blob/2443032526cf6e50d63d35770df9473dd0460fc0/api/envoy/config/route/v3/route_components.proto#L706) are supported:<ul><li>header</li><li>filter_state with key `io.grpc.channel_id`</li></ul>Only [`XX_HASH`](https://github.com/envoyproxy/envoy/blob/2443032526cf6e50d63d35770df9473dd0460fc0/api/envoy/config/cluster/v3/cluster.proto#L383) function is supported. | [A42](https://github.com/grpc/proposal/blob/master/A42-xds-ring-hash-lb-policy.md) | v1.40.0 | v1.40.1 | |
+[Retry](https://www.envoyproxy.io/docs/envoy/latest/api-v3/config/route/v3/route_components.proto#envoy-v3-api-msg-config-route-v3-retrypolicy):<br>Only the following fields are supported:<ul><li>retry_on for the following conditions: cancelled, deadline-exceeded, internal, resource-exhausted, and unavailable.</li><li>num_retries</li><li>retry_back_off</li></ul> | [A44](https://github.com/grpc/proposal/blob/master/A44-xds-retry.md) | v1.40.0 | v1.40.1 | | |
index 524ccf5..46a1ca7 100755 (executable)
@@ -1003,24 +1003,73 @@ Status: TODO
 This test verifies that a client sending faster than a server can drain sees
 pushback (i.e., attempts to send succeed only after appropriate delays).
 
-### Experimental Tests
-
-These tests are not yet standardized, and are not yet implemented in all
-languages. Therefore they are not part of our interop matrix.
-
 #### rpc_soak
 
 The client performs many large_unary RPCs in sequence over the same channel.
-The number of RPCs is configured by the experimental flag, `soak_iterations`.
+The client records the latency and status of each RPC in some data structure.
+If the test ever consumes `soak_overall_timeout_seconds` seconds and still hasn't
+completed `soak_iterations` RPCs, then the test should discontinue sending RPCs
+as soon as possible. After performing all RPCs, the test should examine
+previously recorded RPC latency and status results in a second pass and fail if
+either:
+
+a) not all `soak_iterations` RPCs were completed
+
+b) the sum of RPCs that either completed with a non-OK status or exceeded
+   `max_acceptable_per_rpc_latency_ms` exceeds `soak_max_failures`
+
+Implementations should use a timer with sub-millisecond precision to measure
+latency. Also, implementations should avoid setting RPC deadlines and should
+instead wait for each RPC to complete. Doing so provides more data for
+debugging in case of failure. For example, if RPC deadlines are set to
+`soak_per_iteration_max_acceptable_latency_ms` and one of the RPCs hits that
+deadline, it's not clear if the RPC was late by a millisecond or a minute.
+
+This test must be configurable via a few different command line flags:
+
+* `soak_iterations`: Controls the number of RPCs to perform. This should
+  default to 10.
+
+* `soak_max_failures`: An inclusive upper limit on the number of RPC failures
+  that should be tolerated (i.e. after which the test process should
+  still exit 0). A failure is considered to be either a non-OK status or an RPC
+  whose latency exceeds `soak_per_iteration_max_acceptable_latency_ms`. This
+  should default to 0.
+
+* `soak_per_iteration_max_acceptable_latency_ms`: An upper limit on the latency
+  of a single RPC in order for that RPC to be considered successful. This
+  should default to 1000.
+
+* `soak_overall_timeout_seconds`: The overall number of seconds after which
+  the test should stop and fail if `soak_iterations` have not yet been
+  completed. This should default to
+  `soak_per_iteration_max_acceptable_latency_ms` * `soak_iterations`.
+
+The following is optional but encouraged to improve debuggability:
+
+* Implementations should log the number of milliseconds that each RPC takes.
+  Additionally, implementations should use a histogram of RPC latencies
+  to log interesting latency percentiles at the end of the test (e.g. median,
+  90th, and max latency percentiles).
 
 #### channel_soak
 
-The client performs many large_unary RPCs in sequence. Before each RPC, it
-tears down and rebuilds the channel. The number of RPCs is configured by
-the experimental flag, `soak_iterations`.
+Similar to rpc_soak, but this time each RPC is performed on a new channel. The
+channel is created just before each RPC and is destroyed just after.
 
-This tests puts stress on several gRPC components; the resolver, the load
-balancer, and the RPC hotpath.
+This test is configured with the same command line flags that the rpc_soak test
+is configured with, with only one semantic difference: when measuring an RPCs
+latency to see if it exceeds `soak_per_iteration_max_acceptable_latency_ms` or
+not, the creation of the channel should be included in that
+latency measurement, but the teardown of that channel should **not** be
+included in that latency measurement (channel teardown semantics differ widely
+between languages). This latency measurement should also be the value that is
+logged and recorded in the latency histogram.
+
+### Experimental Tests
+
+These tests are not yet standardized, and are not yet implemented in all
+languages. Therefore they are not part of our interop matrix.
 
 #### long_lived_channel
 
index ffec202..7a60e90 100644 (file)
@@ -1,3 +1,4 @@
+<!-- TODO(mingcl): Rename this app to exampleclient -->
 <manifest xmlns:android="http://schemas.android.com/apk/res/android"
     package="io.grpc.binder.cpp.example"
     android:versionCode="1"
@@ -7,6 +8,10 @@
       android:minSdkVersion="29"
       android:targetSdkVersion="30" />
 
+   <queries>
+      <package android:name="io.grpc.binder.cpp.exampleserver" />
+   </queries>
+
   <application
       android:label="gRPC BinderTransport Cpp">
     <activity
index 2b78927..9ef5041 100644 (file)
@@ -20,9 +20,15 @@ cc_library(
     linkopts = [
         "-ldl",
         "-llog",
+        "-lm",
+        "-lbinder_ndk",
         "-Wl,--no-undefined",
     ],
-    deps = [],
+    deps = [
+        # Temporarily directly depend on this target before we expose a public API
+        "//src/core/ext/transport/binder/client:grpc_transport_binder_client",
+        "//examples/protos:helloworld_cc_grpc",
+    ],
     alwayslink = True,
 )
 
@@ -36,6 +42,7 @@ android_library(
     resource_files = glob(["res/**"]),
     deps = [
         ":jni_lib",
+        "@binder_transport_android_helper//io/grpc/binder/cpp:connection_helper",
     ],
 )
 
index e9cdf98..99f4941 100644 (file)
@@ -1,30 +1,48 @@
 // Copyright 2021 gRPC authors.
-// 
+//
 // Licensed under the Apache License, Version 2.0 (the "License");
 // you may not use this file except in compliance with the License.
 // You may obtain a copy of the License at
-// 
+//
 //     http://www.apache.org/licenses/LICENSE-2.0
-// 
+//
 // Unless required by applicable law or agreed to in writing, software
 // distributed under the License is distributed on an "AS IS" BASIS,
 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-
 #include <android/log.h>
 #include <jni.h>
 
+#include "examples/protos/helloworld.grpc.pb.h"
+#include "examples/protos/helloworld.pb.h"
+
+#include "src/core/ext/transport/binder/client/channel_create.h"
+
 extern "C" JNIEXPORT jstring JNICALL
 Java_io_grpc_binder_cpp_example_ButtonPressHandler_native_1entry(
-    JNIEnv* env, jobject /*this*/, jobject /*application*/) {
+    JNIEnv* env, jobject /*this*/, jobject application) {
   static bool first = true;
   __android_log_print(ANDROID_LOG_INFO, "Demo", "Line number %d", __LINE__);
   if (first) {
     first = false;
+    grpc::experimental::BindToOnDeviceServerService(
+        env, application, "io.grpc.binder.cpp.exampleserver",
+        "io.grpc.binder.cpp.exampleserver.ExportedEndpointService");
     return env->NewStringUTF("Clicked 1 time");
   } else {
-    return env->NewStringUTF("Clicked more than 1 time");
+    auto channel =
+        grpc::experimental::CreateBinderChannel(env, application, "", "");
+    auto stub = helloworld::Greeter::NewStub(channel);
+    grpc::ClientContext context;
+    helloworld::HelloRequest request;
+    helloworld::HelloReply response;
+    request.set_name("BinderTransportClient");
+    grpc::Status status = stub->SayHello(&context, request, &response);
+    if (status.ok()) {
+      return env->NewStringUTF(response.message().c_str());
+    }
+    return env->NewStringUTF("Clicked more than 1 time. Status not ok");
   }
 }
diff --git a/examples/android/binder/java/io/grpc/binder/cpp/exampleserver/AndroidManifest.xml b/examples/android/binder/java/io/grpc/binder/cpp/exampleserver/AndroidManifest.xml
new file mode 100644 (file)
index 0000000..fe2cd2e
--- /dev/null
@@ -0,0 +1,21 @@
+<manifest xmlns:android="http://schemas.android.com/apk/res/android"
+    package="io.grpc.binder.cpp.exampleserver"
+    android:versionCode="1"
+    android:versionName="1.0" >
+
+  <uses-sdk
+      android:minSdkVersion="29"
+      android:targetSdkVersion="30" />
+
+  <application
+      android:label="gRPC BinderTransport Server Cpp">
+    <activity
+        android:name=".MainActivity"
+        android:label="gRPC BinderTransport Server Cpp" >
+      <intent-filter>
+        <action android:name="android.intent.action.MAIN" />
+        <category android:name="android.intent.category.LAUNCHER" />
+      </intent-filter>
+    </activity>
+  </application>
+</manifest>
diff --git a/examples/android/binder/java/io/grpc/binder/cpp/exampleserver/AndroidManifest_endpoint.xml b/examples/android/binder/java/io/grpc/binder/cpp/exampleserver/AndroidManifest_endpoint.xml
new file mode 100644 (file)
index 0000000..a9c9d5c
--- /dev/null
@@ -0,0 +1,10 @@
+<?xml version="1.0" encoding="utf-8"?>
+<manifest xmlns:android="http://schemas.android.com/apk/res/android"
+    package="io.grpc.binder.cpp.exampleserver">
+  <uses-sdk android:minSdkVersion="29" android:targetSdkVersion="30"/>
+  <application>
+    <service
+        android:name=".ExportedEndpointService"
+        android:exported="true"/>
+  </application>
+</manifest>
diff --git a/examples/android/binder/java/io/grpc/binder/cpp/exampleserver/BUILD b/examples/android/binder/java/io/grpc/binder/cpp/exampleserver/BUILD
new file mode 100644 (file)
index 0000000..5bc44c4
--- /dev/null
@@ -0,0 +1,64 @@
+# Copyright 2021 gRPC authors.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+load("@build_bazel_rules_android//android:rules.bzl", "android_binary", "android_library")
+
+cc_library(
+    name = "jni_lib",
+    srcs = ["native.cc"],
+    linkopts = [
+        "-ldl",
+        "-llog",
+        "-lm",
+        "-lbinder_ndk",
+        "-Wl,--no-undefined",
+    ],
+    deps = [
+        # Temporarily directly depend on this target before we expose a public API
+        "//src/core/ext/transport/binder/server:grpc_transport_binder_server",
+        "//:grpc++",
+        "//examples/protos:helloworld_cc_grpc",
+    ],
+    alwayslink = True,
+)
+
+android_library(
+    name = "activity",
+    srcs = [
+        "ButtonPressHandler.java",
+        "MainActivity.java",
+    ],
+    manifest = "AndroidManifest.xml",
+    resource_files = glob(["res/**"]),
+    deps = [
+        ":endpoint",
+        ":jni_lib",
+    ],
+)
+
+android_library(
+    name = "endpoint",
+    srcs = ["ExportedEndpointService.java"],
+    exports_manifest = True,
+    manifest = "AndroidManifest_endpoint.xml",
+    deps = [],
+)
+
+android_binary(
+    name = "app",
+    manifest = "AndroidManifest.xml",
+    deps = [
+        ":activity",
+    ],
+)
diff --git a/examples/android/binder/java/io/grpc/binder/cpp/exampleserver/ButtonPressHandler.java b/examples/android/binder/java/io/grpc/binder/cpp/exampleserver/ButtonPressHandler.java
new file mode 100644 (file)
index 0000000..34d38cc
--- /dev/null
@@ -0,0 +1,13 @@
+package io.grpc.binder.cpp.exampleserver;
+
+import android.app.Application;
+
+public class ButtonPressHandler {
+  static {
+    System.loadLibrary("app");
+  }
+
+  public String onPressed(Application application) {
+    return "Server Button Pressed";
+  }
+}
diff --git a/examples/android/binder/java/io/grpc/binder/cpp/exampleserver/ExportedEndpointService.java b/examples/android/binder/java/io/grpc/binder/cpp/exampleserver/ExportedEndpointService.java
new file mode 100644 (file)
index 0000000..287b066
--- /dev/null
@@ -0,0 +1,28 @@
+package io.grpc.binder.cpp.exampleserver;
+
+import android.app.Service;
+import android.os.IBinder;
+import android.content.Intent;
+
+/** Exposes gRPC services running in the main process */
+public final class ExportedEndpointService extends Service {
+  private final IBinder binder;
+
+  static {
+    System.loadLibrary("app");
+  }
+
+  public ExportedEndpointService() {
+    init_grpc_server();
+    binder = get_endpoint_binder();
+  }
+
+  @Override
+  public IBinder onBind(Intent intent) {
+    return binder;
+  }
+
+  public native void init_grpc_server();
+
+  public native IBinder get_endpoint_binder();
+}
diff --git a/examples/android/binder/java/io/grpc/binder/cpp/exampleserver/MainActivity.java b/examples/android/binder/java/io/grpc/binder/cpp/exampleserver/MainActivity.java
new file mode 100644 (file)
index 0000000..d252e5f
--- /dev/null
@@ -0,0 +1,27 @@
+package io.grpc.binder.cpp.exampleserver;
+
+import android.app.Activity;
+import android.os.Bundle;
+import android.util.Log;
+import android.widget.Button;
+import android.widget.TextView;
+import io.grpc.binder.cpp.exampleserver.R;
+
+/** Main class for the example app. */
+public class MainActivity extends Activity {
+  @Override
+  public void onCreate(Bundle savedInstanceState) {
+    super.onCreate(savedInstanceState);
+    Log.v("Example", "hello, world");
+
+    setContentView(R.layout.activity_main);
+
+    Button clickMeButton = findViewById(R.id.clickMeButton);
+    TextView exampleTextView = findViewById(R.id.exampleTextView);
+
+    ButtonPressHandler h = new ButtonPressHandler();
+
+    clickMeButton.setOnClickListener(
+        v -> exampleTextView.setText(h.onPressed(getApplication())));
+  }
+}
diff --git a/examples/android/binder/java/io/grpc/binder/cpp/exampleserver/native.cc b/examples/android/binder/java/io/grpc/binder/cpp/exampleserver/native.cc
new file mode 100644 (file)
index 0000000..be79380
--- /dev/null
@@ -0,0 +1,82 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#include <android/binder_auto_utils.h>
+#include <android/binder_ibinder.h>
+#include <android/binder_ibinder_jni.h>
+#include <android/binder_interface_utils.h>
+#include <android/log.h>
+#include <jni.h>
+
+#include "examples/protos/helloworld.grpc.pb.h"
+#include "examples/protos/helloworld.pb.h"
+
+#include <grpcpp/grpcpp.h>
+
+#include "src/core/ext/transport/binder/server/binder_server.h"
+#include "src/core/ext/transport/binder/server/binder_server_credentials.h"
+
+namespace {
+class GreeterService : public helloworld::Greeter::Service {
+ public:
+  grpc::Status SayHello(grpc::ServerContext*,
+                        const helloworld::HelloRequest* request,
+                        helloworld::HelloReply* response) override {
+    __android_log_print(ANDROID_LOG_INFO, "DemoServer", "Line number %d",
+                        __LINE__);
+    __android_log_print(ANDROID_LOG_INFO, "DemoServer", "Got hello request: %s",
+                        request->name().c_str());
+    response->set_message("Hi, " + request->name());
+    return grpc::Status::OK;
+  }
+};
+
+}  // namespace
+
+extern "C" JNIEXPORT void JNICALL
+Java_io_grpc_binder_cpp_exampleserver_ExportedEndpointService_init_1grpc_1server(
+    JNIEnv* env, jobject /*this*/) {
+  __android_log_print(ANDROID_LOG_INFO, "DemoServer", "Line number %d",
+                      __LINE__);
+  static std::unique_ptr<grpc::Server> server = nullptr;
+
+  if (server != nullptr) {
+    // Already initiated
+    return;
+  }
+
+  static GreeterService service;
+  grpc::ServerBuilder server_builder;
+  server_builder.RegisterService(&service);
+
+  server_builder.AddListeningPort(
+      "binder://example.service",
+      grpc::experimental::BinderServerCredentials());
+
+  server = server_builder.BuildAndStart();
+}
+
+extern "C" JNIEXPORT jobject JNICALL
+Java_io_grpc_binder_cpp_exampleserver_ExportedEndpointService_get_1endpoint_1binder(
+    JNIEnv* env, jobject /*this*/) {
+  __android_log_print(ANDROID_LOG_INFO, "DemoServer", "Line number %d",
+                      __LINE__);
+
+  auto ai_binder = static_cast<AIBinder*>(
+      grpc::experimental::binder::GetEndpointBinder("example.service"));
+
+  __android_log_print(ANDROID_LOG_INFO, "DemoServer", "ai_binder = %p",
+                      ai_binder);
+  return AIBinder_toJavaBinder(env, ai_binder);
+}
diff --git a/examples/android/binder/java/io/grpc/binder/cpp/exampleserver/res/layout/activity_main.xml b/examples/android/binder/java/io/grpc/binder/cpp/exampleserver/res/layout/activity_main.xml
new file mode 100644 (file)
index 0000000..e866d8d
--- /dev/null
@@ -0,0 +1,24 @@
+<?xml version="1.0" encoding="utf-8"?>
+<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
+    android:padding="16dp"
+    android:orientation="vertical"
+    android:gravity="center_vertical"
+    android:layout_width="match_parent"
+    android:layout_height="match_parent">
+
+  <TextView
+      android:id="@+id/exampleTextView"
+      android:layout_width="wrap_content"
+      android:layout_height="wrap_content"
+      android:layout_gravity="center_horizontal"
+      android:textSize="32dp"
+      android:text="@string/thinking_face"/>
+
+  <Button
+      android:id="@+id/clickMeButton"
+      android:layout_width="wrap_content"
+      android:layout_height="wrap_content"
+      android:layout_gravity="center_horizontal"
+      android:layout_marginTop="16dp"
+      android:text="@string/click_me_button"/>
+</LinearLayout>
diff --git a/examples/android/binder/java/io/grpc/binder/cpp/exampleserver/res/values/strings.xml b/examples/android/binder/java/io/grpc/binder/cpp/exampleserver/res/values/strings.xml
new file mode 100644 (file)
index 0000000..7593624
--- /dev/null
@@ -0,0 +1,5 @@
+<?xml version="1.0" encoding="utf-8"?>
+<resources>
+  <string name="click_me_button">Run example</string>
+  <string name="thinking_face">🤔</string>
+</resources>
index 407a441..54e75c9 100644 (file)
 #include <iostream>
 #include <memory>
 #include <string>
+#include <thread>
 
 #include <grpc/support/log.h>
 #include <grpcpp/grpcpp.h>
-#include <thread>
 
 #ifdef BAZEL_BUILD
 #include "examples/protos/helloworld.grpc.pb.h"
index 57c451c..75c09a0 100644 (file)
 #include <string>
 #include <vector>
 
-#include <grpcpp/grpcpp.h>
-
 #include "caching_interceptor.h"
 
+#include <grpcpp/grpcpp.h>
+
 #ifdef BAZEL_BUILD
 #include "examples/protos/keyvaluestore.grpc.pb.h"
 #else
index 93eeaec..4bab4ae 100644 (file)
 #include <string>
 #include <thread>
 
+#include "helper.h"
+
 #include <grpc/grpc.h>
 #include <grpcpp/alarm.h>
 #include <grpcpp/channel.h>
 #include <grpcpp/client_context.h>
 #include <grpcpp/create_channel.h>
 #include <grpcpp/security/credentials.h>
-#include "helper.h"
 #ifdef BAZEL_BUILD
 #include "examples/protos/route_guide.grpc.pb.h"
 #else
index cf99d05..1c9fb5f 100644 (file)
 #include <string>
 #include <thread>
 
+#include "helper.h"
+
 #include <grpc/grpc.h>
 #include <grpcpp/security/server_credentials.h>
 #include <grpcpp/server.h>
 #include <grpcpp/server_builder.h>
 #include <grpcpp/server_context.h>
-#include "helper.h"
 #ifdef BAZEL_BUILD
 #include "examples/protos/route_guide.grpc.pb.h"
 #else
index e30636c..fd29a31 100644 (file)
 #include <string>
 #include <thread>
 
+#include "helper.h"
+
 #include <grpc/grpc.h>
 #include <grpcpp/channel.h>
 #include <grpcpp/client_context.h>
 #include <grpcpp/create_channel.h>
 #include <grpcpp/security/credentials.h>
-#include "helper.h"
 #ifdef BAZEL_BUILD
 #include "examples/protos/route_guide.grpc.pb.h"
 #else
index 58ec208..0e29125 100644 (file)
 #include <memory>
 #include <string>
 
+#include "helper.h"
+
 #include <grpc/grpc.h>
 #include <grpcpp/security/server_credentials.h>
 #include <grpcpp/server.h>
 #include <grpcpp/server_builder.h>
 #include <grpcpp/server_context.h>
-#include "helper.h"
 #ifdef BAZEL_BUILD
 #include "examples/protos/route_guide.grpc.pb.h"
 #else
index 1d44bba..b16bab4 100644 (file)
@@ -2,7 +2,7 @@
   "name": "grpc/grpc-demo",
   "description": "gRPC example for PHP",
   "require": {
-    "grpc/grpc": "^v1.30.0",
+    "grpc/grpc": "^v1.39.0",
     "google/protobuf": "^v3.12.2"
   },
   "autoload": {
index 1bdc1d7..601e048 100644 (file)
  *
  */
 
-require dirname(__FILE__) . '/../../src/php/lib/Grpc/MethodDescriptor.php';
-require dirname(__FILE__) . '/../../src/php/lib/Grpc/Status.php';
-require dirname(__FILE__) . '/../../src/php/lib/Grpc/ServerCallReader.php';
-require dirname(__FILE__) . '/../../src/php/lib/Grpc/ServerCallWriter.php';
-require dirname(__FILE__) . '/../../src/php/lib/Grpc/ServerContext.php';
-require dirname(__FILE__) . '/../../src/php/lib/Grpc/RpcServer.php';
 require dirname(__FILE__) . '/vendor/autoload.php';
 require dirname(__FILE__) . '/route_guide/RouteGuideService.php';
 
index a5d749b..684d6c6 100644 (file)
  *
  */
 
-require dirname(__FILE__) . '/../../src/php/lib/Grpc/MethodDescriptor.php';
-require dirname(__FILE__) . '/../../src/php/lib/Grpc/Status.php';
-require dirname(__FILE__) . '/../../src/php/lib/Grpc/ServerCallReader.php';
-require dirname(__FILE__) . '/../../src/php/lib/Grpc/ServerCallWriter.php';
-require dirname(__FILE__) . '/../../src/php/lib/Grpc/ServerContext.php';
-require dirname(__FILE__) . '/../../src/php/lib/Grpc/RpcServer.php';
 require dirname(__FILE__) . '/vendor/autoload.php';
 
 class Greeter extends Helloworld\GreeterStub
index 29b086f..0625a9b 100644 (file)
  *
  */
 
-require dirname(__FILE__) . '/../../../src/php/lib/Grpc/MethodDescriptor.php';
-require dirname(__FILE__) . '/../../../src/php/lib/Grpc/Status.php';
-require dirname(__FILE__) . '/../../../src/php/lib/Grpc/ServerCallReader.php';
-require dirname(__FILE__) . '/../../../src/php/lib/Grpc/ServerCallWriter.php';
-require dirname(__FILE__) . '/../../../src/php/lib/Grpc/ServerContext.php';
-require dirname(__FILE__) . '/../../../src/php/lib/Grpc/RpcServer.php';
 require dirname(__FILE__) . '/../vendor/autoload.php';
 require dirname(__FILE__) . '/RouteGuideService.php';
 
index f1628a5..a6fc52f 100644 (file)
@@ -22,7 +22,7 @@
 Pod::Spec.new do |s|
   s.name     = 'gRPC-C++'
   # TODO (mxyan): use version that match gRPC version when pod is stabilized
-  version = '1.40.0'
+  version = '1.41.0'
   s.version  = version
   s.summary  = 'gRPC C++ library'
   s.homepage = 'https://grpc.io'
@@ -202,6 +202,7 @@ Pod::Spec.new do |s|
     ss.dependency 'abseil/synchronization/synchronization', abseil_version
     ss.dependency 'abseil/time/time', abseil_version
     ss.dependency 'abseil/types/optional', abseil_version
+    ss.dependency 'abseil/types/variant', abseil_version
 
     ss.source_files = 'src/core/ext/filters/client_channel/backend_metric.h',
                       'src/core/ext/filters/client_channel/backup_poller.h',
@@ -281,13 +282,18 @@ Pod::Spec.new do |s|
                       'src/core/ext/transport/chttp2/transport/frame_rst_stream.h',
                       'src/core/ext/transport/chttp2/transport/frame_settings.h',
                       'src/core/ext/transport/chttp2/transport/frame_window_update.h',
+                      'src/core/ext/transport/chttp2/transport/hpack_constants.h',
                       'src/core/ext/transport/chttp2/transport/hpack_encoder.h',
+                      'src/core/ext/transport/chttp2/transport/hpack_encoder_index.h',
+                      'src/core/ext/transport/chttp2/transport/hpack_encoder_table.h',
                       'src/core/ext/transport/chttp2/transport/hpack_parser.h',
-                      'src/core/ext/transport/chttp2/transport/hpack_table.h',
+                      'src/core/ext/transport/chttp2/transport/hpack_parser_table.h',
+                      'src/core/ext/transport/chttp2/transport/hpack_utils.h',
                       'src/core/ext/transport/chttp2/transport/http2_settings.h',
                       'src/core/ext/transport/chttp2/transport/huffsyms.h',
                       'src/core/ext/transport/chttp2/transport/incoming_metadata.h',
                       'src/core/ext/transport/chttp2/transport/internal.h',
+                      'src/core/ext/transport/chttp2/transport/popularity_count.h',
                       'src/core/ext/transport/chttp2/transport/stream_map.h',
                       'src/core/ext/transport/chttp2/transport/varint.h',
                       'src/core/ext/transport/inproc/inproc_transport.h',
@@ -524,6 +530,7 @@ Pod::Spec.new do |s|
                       'src/core/lib/compression/stream_compression.h',
                       'src/core/lib/compression/stream_compression_gzip.h',
                       'src/core/lib/compression/stream_compression_identity.h',
+                      'src/core/lib/config/core_configuration.h',
                       'src/core/lib/debug/stats.h',
                       'src/core/lib/debug/stats_data.h',
                       'src/core/lib/debug/trace.h',
@@ -537,14 +544,12 @@ Pod::Spec.new do |s|
                       'src/core/lib/gpr/string_windows.h',
                       'src/core/lib/gpr/time_precise.h',
                       'src/core/lib/gpr/tls.h',
-                      'src/core/lib/gpr/tls_gcc.h',
-                      'src/core/lib/gpr/tls_msvc.h',
-                      'src/core/lib/gpr/tls_pthread.h',
-                      'src/core/lib/gpr/tls_stdcpp.h',
                       'src/core/lib/gpr/tmpfile.h',
                       'src/core/lib/gpr/useful.h',
                       'src/core/lib/gprpp/arena.h',
-                      'src/core/lib/gprpp/atomic.h',
+                      'src/core/lib/gprpp/atomic_utils.h',
+                      'src/core/lib/gprpp/bitset.h',
+                      'src/core/lib/gprpp/construct_destruct.h',
                       'src/core/lib/gprpp/debug_location.h',
                       'src/core/lib/gprpp/dual_ref_counted.h',
                       'src/core/lib/gprpp/examine_stack.h',
@@ -555,9 +560,11 @@ Pod::Spec.new do |s|
                       'src/core/lib/gprpp/global_config_generic.h',
                       'src/core/lib/gprpp/host_port.h',
                       'src/core/lib/gprpp/manual_constructor.h',
+                      'src/core/lib/gprpp/match.h',
                       'src/core/lib/gprpp/memory.h',
                       'src/core/lib/gprpp/mpscq.h',
                       'src/core/lib/gprpp/orphanable.h',
+                      'src/core/lib/gprpp/overload.h',
                       'src/core/lib/gprpp/ref_counted.h',
                       'src/core/lib/gprpp/ref_counted_ptr.h',
                       'src/core/lib/gprpp/stat.h',
@@ -613,7 +620,6 @@ Pod::Spec.new do |s|
                       'src/core/lib/iomgr/pollset_set.h',
                       'src/core/lib/iomgr/pollset_set_custom.h',
                       'src/core/lib/iomgr/pollset_set_windows.h',
-                      'src/core/lib/iomgr/pollset_uv.h',
                       'src/core/lib/iomgr/pollset_windows.h',
                       'src/core/lib/iomgr/port.h',
                       'src/core/lib/iomgr/python_util.h',
@@ -621,7 +627,6 @@ Pod::Spec.new do |s|
                       'src/core/lib/iomgr/resolve_address_custom.h',
                       'src/core/lib/iomgr/resource_quota.h',
                       'src/core/lib/iomgr/sockaddr.h',
-                      'src/core/lib/iomgr/sockaddr_custom.h',
                       'src/core/lib/iomgr/sockaddr_posix.h',
                       'src/core/lib/iomgr/sockaddr_windows.h',
                       'src/core/lib/iomgr/socket_factory_posix.h',
@@ -655,6 +660,7 @@ Pod::Spec.new do |s|
                       'src/core/lib/security/authorization/authorization_engine.h',
                       'src/core/lib/security/authorization/authorization_policy_provider.h',
                       'src/core/lib/security/authorization/evaluate_args.h',
+                      'src/core/lib/security/authorization/sdk_server_authz_filter.h',
                       'src/core/lib/security/context/security_context.h',
                       'src/core/lib/security/credentials/alts/alts_credentials.h',
                       'src/core/lib/security/credentials/alts/check_gcp_environment.h',
@@ -846,22 +852,23 @@ Pod::Spec.new do |s|
                       'third_party/re2/util/test.h',
                       'third_party/re2/util/utf.h',
                       'third_party/re2/util/util.h',
-                      'third_party/upb/third_party/wyhash/wyhash.h',
                       'third_party/upb/upb/decode.h',
-                      'third_party/upb/upb/decode.int.h',
                       'third_party/upb/upb/decode_fast.h',
+                      'third_party/upb/upb/decode_internal.h',
                       'third_party/upb/upb/def.h',
                       'third_party/upb/upb/def.hpp',
                       'third_party/upb/upb/encode.h',
                       'third_party/upb/upb/msg.h',
+                      'third_party/upb/upb/msg_internal.h',
                       'third_party/upb/upb/port_def.inc',
                       'third_party/upb/upb/port_undef.inc',
                       'third_party/upb/upb/reflection.h',
-                      'third_party/upb/upb/table.int.h',
+                      'third_party/upb/upb/reflection.hpp',
+                      'third_party/upb/upb/table_internal.h',
                       'third_party/upb/upb/text_encode.h',
                       'third_party/upb/upb/upb.h',
                       'third_party/upb/upb/upb.hpp',
-                      'third_party/upb/upb/upb.int.h',
+                      'third_party/upb/upb/upb_internal.h',
                       'third_party/xxhash/xxhash.h'
 
     ss.private_header_files = 'src/core/ext/filters/client_channel/backend_metric.h',
@@ -942,13 +949,18 @@ Pod::Spec.new do |s|
                               'src/core/ext/transport/chttp2/transport/frame_rst_stream.h',
                               'src/core/ext/transport/chttp2/transport/frame_settings.h',
                               'src/core/ext/transport/chttp2/transport/frame_window_update.h',
+                              'src/core/ext/transport/chttp2/transport/hpack_constants.h',
                               'src/core/ext/transport/chttp2/transport/hpack_encoder.h',
+                              'src/core/ext/transport/chttp2/transport/hpack_encoder_index.h',
+                              'src/core/ext/transport/chttp2/transport/hpack_encoder_table.h',
                               'src/core/ext/transport/chttp2/transport/hpack_parser.h',
-                              'src/core/ext/transport/chttp2/transport/hpack_table.h',
+                              'src/core/ext/transport/chttp2/transport/hpack_parser_table.h',
+                              'src/core/ext/transport/chttp2/transport/hpack_utils.h',
                               'src/core/ext/transport/chttp2/transport/http2_settings.h',
                               'src/core/ext/transport/chttp2/transport/huffsyms.h',
                               'src/core/ext/transport/chttp2/transport/incoming_metadata.h',
                               'src/core/ext/transport/chttp2/transport/internal.h',
+                              'src/core/ext/transport/chttp2/transport/popularity_count.h',
                               'src/core/ext/transport/chttp2/transport/stream_map.h',
                               'src/core/ext/transport/chttp2/transport/varint.h',
                               'src/core/ext/transport/inproc/inproc_transport.h',
@@ -1185,6 +1197,7 @@ Pod::Spec.new do |s|
                               'src/core/lib/compression/stream_compression.h',
                               'src/core/lib/compression/stream_compression_gzip.h',
                               'src/core/lib/compression/stream_compression_identity.h',
+                              'src/core/lib/config/core_configuration.h',
                               'src/core/lib/debug/stats.h',
                               'src/core/lib/debug/stats_data.h',
                               'src/core/lib/debug/trace.h',
@@ -1198,14 +1211,12 @@ Pod::Spec.new do |s|
                               'src/core/lib/gpr/string_windows.h',
                               'src/core/lib/gpr/time_precise.h',
                               'src/core/lib/gpr/tls.h',
-                              'src/core/lib/gpr/tls_gcc.h',
-                              'src/core/lib/gpr/tls_msvc.h',
-                              'src/core/lib/gpr/tls_pthread.h',
-                              'src/core/lib/gpr/tls_stdcpp.h',
                               'src/core/lib/gpr/tmpfile.h',
                               'src/core/lib/gpr/useful.h',
                               'src/core/lib/gprpp/arena.h',
-                              'src/core/lib/gprpp/atomic.h',
+                              'src/core/lib/gprpp/atomic_utils.h',
+                              'src/core/lib/gprpp/bitset.h',
+                              'src/core/lib/gprpp/construct_destruct.h',
                               'src/core/lib/gprpp/debug_location.h',
                               'src/core/lib/gprpp/dual_ref_counted.h',
                               'src/core/lib/gprpp/examine_stack.h',
@@ -1216,9 +1227,11 @@ Pod::Spec.new do |s|
                               'src/core/lib/gprpp/global_config_generic.h',
                               'src/core/lib/gprpp/host_port.h',
                               'src/core/lib/gprpp/manual_constructor.h',
+                              'src/core/lib/gprpp/match.h',
                               'src/core/lib/gprpp/memory.h',
                               'src/core/lib/gprpp/mpscq.h',
                               'src/core/lib/gprpp/orphanable.h',
+                              'src/core/lib/gprpp/overload.h',
                               'src/core/lib/gprpp/ref_counted.h',
                               'src/core/lib/gprpp/ref_counted_ptr.h',
                               'src/core/lib/gprpp/stat.h',
@@ -1274,7 +1287,6 @@ Pod::Spec.new do |s|
                               'src/core/lib/iomgr/pollset_set.h',
                               'src/core/lib/iomgr/pollset_set_custom.h',
                               'src/core/lib/iomgr/pollset_set_windows.h',
-                              'src/core/lib/iomgr/pollset_uv.h',
                               'src/core/lib/iomgr/pollset_windows.h',
                               'src/core/lib/iomgr/port.h',
                               'src/core/lib/iomgr/python_util.h',
@@ -1282,7 +1294,6 @@ Pod::Spec.new do |s|
                               'src/core/lib/iomgr/resolve_address_custom.h',
                               'src/core/lib/iomgr/resource_quota.h',
                               'src/core/lib/iomgr/sockaddr.h',
-                              'src/core/lib/iomgr/sockaddr_custom.h',
                               'src/core/lib/iomgr/sockaddr_posix.h',
                               'src/core/lib/iomgr/sockaddr_windows.h',
                               'src/core/lib/iomgr/socket_factory_posix.h',
@@ -1316,6 +1327,7 @@ Pod::Spec.new do |s|
                               'src/core/lib/security/authorization/authorization_engine.h',
                               'src/core/lib/security/authorization/authorization_policy_provider.h',
                               'src/core/lib/security/authorization/evaluate_args.h',
+                              'src/core/lib/security/authorization/sdk_server_authz_filter.h',
                               'src/core/lib/security/context/security_context.h',
                               'src/core/lib/security/credentials/alts/alts_credentials.h',
                               'src/core/lib/security/credentials/alts/check_gcp_environment.h',
@@ -1457,22 +1469,23 @@ Pod::Spec.new do |s|
                               'third_party/re2/util/test.h',
                               'third_party/re2/util/utf.h',
                               'third_party/re2/util/util.h',
-                              'third_party/upb/third_party/wyhash/wyhash.h',
                               'third_party/upb/upb/decode.h',
-                              'third_party/upb/upb/decode.int.h',
                               'third_party/upb/upb/decode_fast.h',
+                              'third_party/upb/upb/decode_internal.h',
                               'third_party/upb/upb/def.h',
                               'third_party/upb/upb/def.hpp',
                               'third_party/upb/upb/encode.h',
                               'third_party/upb/upb/msg.h',
+                              'third_party/upb/upb/msg_internal.h',
                               'third_party/upb/upb/port_def.inc',
                               'third_party/upb/upb/port_undef.inc',
                               'third_party/upb/upb/reflection.h',
-                              'third_party/upb/upb/table.int.h',
+                              'third_party/upb/upb/reflection.hpp',
+                              'third_party/upb/upb/table_internal.h',
                               'third_party/upb/upb/text_encode.h',
                               'third_party/upb/upb/upb.h',
                               'third_party/upb/upb/upb.hpp',
-                              'third_party/upb/upb/upb.int.h',
+                              'third_party/upb/upb/upb_internal.h',
                               'third_party/xxhash/xxhash.h'
   end
 
index d2af3b0..613bed8 100644 (file)
@@ -21,7 +21,7 @@
 
 Pod::Spec.new do |s|
   s.name     = 'gRPC-Core'
-  version = '1.40.0'
+  version = '1.41.0'
   s.version  = version
   s.summary  = 'Core cross-platform gRPC library, written in C'
   s.homepage = 'https://grpc.io'
@@ -177,7 +177,7 @@ Pod::Spec.new do |s|
     ss.header_mappings_dir = '.'
     ss.libraries = 'z'
     ss.dependency "#{s.name}/Interface", version
-    ss.dependency 'BoringSSL-GRPC', '0.0.19'
+    ss.dependency 'BoringSSL-GRPC', '0.0.20'
     ss.dependency 'abseil/base/base', abseil_version
     ss.dependency 'abseil/base/core_headers', abseil_version
     ss.dependency 'abseil/container/flat_hash_map', abseil_version
@@ -192,6 +192,7 @@ Pod::Spec.new do |s|
     ss.dependency 'abseil/synchronization/synchronization', abseil_version
     ss.dependency 'abseil/time/time', abseil_version
     ss.dependency 'abseil/types/optional', abseil_version
+    ss.dependency 'abseil/types/variant', abseil_version
     ss.compiler_flags = '-DBORINGSSL_PREFIX=GRPC -Wno-unreachable-code -Wno-shorten-64-to-32'
 
     ss.source_files = 'src/core/ext/filters/census/grpc_context.cc',
@@ -264,13 +265,11 @@ Pod::Spec.new do |s|
                       'src/core/ext/filters/client_channel/resolver/dns/c_ares/dns_resolver_ares.cc',
                       'src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver.h',
                       'src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_event_engine.cc',
-                      'src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_libuv.cc',
                       'src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_posix.cc',
                       'src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_windows.cc',
                       'src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper.cc',
                       'src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper.h',
                       'src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_event_engine.cc',
-                      'src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_libuv.cc',
                       'src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_posix.cc',
                       'src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_windows.cc',
                       'src/core/ext/filters/client_channel/resolver/dns/dns_resolver_selection.cc',
@@ -372,12 +371,18 @@ Pod::Spec.new do |s|
                       'src/core/ext/transport/chttp2/transport/frame_settings.h',
                       'src/core/ext/transport/chttp2/transport/frame_window_update.cc',
                       'src/core/ext/transport/chttp2/transport/frame_window_update.h',
+                      'src/core/ext/transport/chttp2/transport/hpack_constants.h',
                       'src/core/ext/transport/chttp2/transport/hpack_encoder.cc',
                       'src/core/ext/transport/chttp2/transport/hpack_encoder.h',
+                      'src/core/ext/transport/chttp2/transport/hpack_encoder_index.h',
+                      'src/core/ext/transport/chttp2/transport/hpack_encoder_table.cc',
+                      'src/core/ext/transport/chttp2/transport/hpack_encoder_table.h',
                       'src/core/ext/transport/chttp2/transport/hpack_parser.cc',
                       'src/core/ext/transport/chttp2/transport/hpack_parser.h',
-                      'src/core/ext/transport/chttp2/transport/hpack_table.cc',
-                      'src/core/ext/transport/chttp2/transport/hpack_table.h',
+                      'src/core/ext/transport/chttp2/transport/hpack_parser_table.cc',
+                      'src/core/ext/transport/chttp2/transport/hpack_parser_table.h',
+                      'src/core/ext/transport/chttp2/transport/hpack_utils.cc',
+                      'src/core/ext/transport/chttp2/transport/hpack_utils.h',
                       'src/core/ext/transport/chttp2/transport/http2_settings.cc',
                       'src/core/ext/transport/chttp2/transport/http2_settings.h',
                       'src/core/ext/transport/chttp2/transport/huffsyms.cc',
@@ -386,6 +391,7 @@ Pod::Spec.new do |s|
                       'src/core/ext/transport/chttp2/transport/incoming_metadata.h',
                       'src/core/ext/transport/chttp2/transport/internal.h',
                       'src/core/ext/transport/chttp2/transport/parsing.cc',
+                      'src/core/ext/transport/chttp2/transport/popularity_count.h',
                       'src/core/ext/transport/chttp2/transport/stream_lists.cc',
                       'src/core/ext/transport/chttp2/transport/stream_map.cc',
                       'src/core/ext/transport/chttp2/transport/stream_map.h',
@@ -857,6 +863,8 @@ Pod::Spec.new do |s|
                       'src/core/lib/compression/stream_compression_gzip.h',
                       'src/core/lib/compression/stream_compression_identity.cc',
                       'src/core/lib/compression/stream_compression_identity.h',
+                      'src/core/lib/config/core_configuration.cc',
+                      'src/core/lib/config/core_configuration.h',
                       'src/core/lib/debug/stats.cc',
                       'src/core/lib/debug/stats.h',
                       'src/core/lib/debug/stats_data.cc',
@@ -903,11 +911,6 @@ Pod::Spec.new do |s|
                       'src/core/lib/gpr/time_precise.h',
                       'src/core/lib/gpr/time_windows.cc',
                       'src/core/lib/gpr/tls.h',
-                      'src/core/lib/gpr/tls_gcc.h',
-                      'src/core/lib/gpr/tls_msvc.h',
-                      'src/core/lib/gpr/tls_pthread.cc',
-                      'src/core/lib/gpr/tls_pthread.h',
-                      'src/core/lib/gpr/tls_stdcpp.h',
                       'src/core/lib/gpr/tmpfile.h',
                       'src/core/lib/gpr/tmpfile_msys.cc',
                       'src/core/lib/gpr/tmpfile_posix.cc',
@@ -916,7 +919,9 @@ Pod::Spec.new do |s|
                       'src/core/lib/gpr/wrap_memcpy.cc',
                       'src/core/lib/gprpp/arena.cc',
                       'src/core/lib/gprpp/arena.h',
-                      'src/core/lib/gprpp/atomic.h',
+                      'src/core/lib/gprpp/atomic_utils.h',
+                      'src/core/lib/gprpp/bitset.h',
+                      'src/core/lib/gprpp/construct_destruct.h',
                       'src/core/lib/gprpp/debug_location.h',
                       'src/core/lib/gprpp/dual_ref_counted.h',
                       'src/core/lib/gprpp/examine_stack.cc',
@@ -931,10 +936,12 @@ Pod::Spec.new do |s|
                       'src/core/lib/gprpp/host_port.cc',
                       'src/core/lib/gprpp/host_port.h',
                       'src/core/lib/gprpp/manual_constructor.h',
+                      'src/core/lib/gprpp/match.h',
                       'src/core/lib/gprpp/memory.h',
                       'src/core/lib/gprpp/mpscq.cc',
                       'src/core/lib/gprpp/mpscq.h',
                       'src/core/lib/gprpp/orphanable.h',
+                      'src/core/lib/gprpp/overload.h',
                       'src/core/lib/gprpp/ref_counted.h',
                       'src/core/lib/gprpp/ref_counted_ptr.h',
                       'src/core/lib/gprpp/stat.h',
@@ -974,7 +981,6 @@ Pod::Spec.new do |s|
                       'src/core/lib/iomgr/endpoint_pair.h',
                       'src/core/lib/iomgr/endpoint_pair_event_engine.cc',
                       'src/core/lib/iomgr/endpoint_pair_posix.cc',
-                      'src/core/lib/iomgr/endpoint_pair_uv.cc',
                       'src/core/lib/iomgr/endpoint_pair_windows.cc',
                       'src/core/lib/iomgr/error.cc',
                       'src/core/lib/iomgr/error.h',
@@ -1035,7 +1041,6 @@ Pod::Spec.new do |s|
                       'src/core/lib/iomgr/iomgr_internal.h',
                       'src/core/lib/iomgr/iomgr_posix.cc',
                       'src/core/lib/iomgr/iomgr_posix_cfstream.cc',
-                      'src/core/lib/iomgr/iomgr_uv.cc',
                       'src/core/lib/iomgr/iomgr_windows.cc',
                       'src/core/lib/iomgr/is_epollexclusive_available.cc',
                       'src/core/lib/iomgr/is_epollexclusive_available.h',
@@ -1056,8 +1061,6 @@ Pod::Spec.new do |s|
                       'src/core/lib/iomgr/pollset_set_custom.h',
                       'src/core/lib/iomgr/pollset_set_windows.cc',
                       'src/core/lib/iomgr/pollset_set_windows.h',
-                      'src/core/lib/iomgr/pollset_uv.cc',
-                      'src/core/lib/iomgr/pollset_uv.h',
                       'src/core/lib/iomgr/pollset_windows.cc',
                       'src/core/lib/iomgr/pollset_windows.h',
                       'src/core/lib/iomgr/port.h',
@@ -1071,7 +1074,6 @@ Pod::Spec.new do |s|
                       'src/core/lib/iomgr/resource_quota.cc',
                       'src/core/lib/iomgr/resource_quota.h',
                       'src/core/lib/iomgr/sockaddr.h',
-                      'src/core/lib/iomgr/sockaddr_custom.h',
                       'src/core/lib/iomgr/sockaddr_posix.h',
                       'src/core/lib/iomgr/sockaddr_windows.h',
                       'src/core/lib/iomgr/socket_factory_posix.cc',
@@ -1083,7 +1085,6 @@ Pod::Spec.new do |s|
                       'src/core/lib/iomgr/socket_utils_linux.cc',
                       'src/core/lib/iomgr/socket_utils_posix.cc',
                       'src/core/lib/iomgr/socket_utils_posix.h',
-                      'src/core/lib/iomgr/socket_utils_uv.cc',
                       'src/core/lib/iomgr/socket_utils_windows.cc',
                       'src/core/lib/iomgr/socket_windows.cc',
                       'src/core/lib/iomgr/socket_windows.h',
@@ -1108,7 +1109,6 @@ Pod::Spec.new do |s|
                       'src/core/lib/iomgr/tcp_server_utils_posix_ifaddrs.cc',
                       'src/core/lib/iomgr/tcp_server_utils_posix_noifaddrs.cc',
                       'src/core/lib/iomgr/tcp_server_windows.cc',
-                      'src/core/lib/iomgr/tcp_uv.cc',
                       'src/core/lib/iomgr/tcp_windows.cc',
                       'src/core/lib/iomgr/tcp_windows.h',
                       'src/core/lib/iomgr/time_averaged_stats.cc',
@@ -1123,7 +1123,6 @@ Pod::Spec.new do |s|
                       'src/core/lib/iomgr/timer_heap.h',
                       'src/core/lib/iomgr/timer_manager.cc',
                       'src/core/lib/iomgr/timer_manager.h',
-                      'src/core/lib/iomgr/timer_uv.cc',
                       'src/core/lib/iomgr/udp_server.cc',
                       'src/core/lib/iomgr/udp_server.h',
                       'src/core/lib/iomgr/unix_sockets_posix.cc',
@@ -1152,6 +1151,8 @@ Pod::Spec.new do |s|
                       'src/core/lib/security/authorization/authorization_policy_provider_vtable.cc',
                       'src/core/lib/security/authorization/evaluate_args.cc',
                       'src/core/lib/security/authorization/evaluate_args.h',
+                      'src/core/lib/security/authorization/sdk_server_authz_filter.cc',
+                      'src/core/lib/security/authorization/sdk_server_authz_filter.h',
                       'src/core/lib/security/context/security_context.cc',
                       'src/core/lib/security/context/security_context.h',
                       'src/core/lib/security/credentials/alts/alts_credentials.cc',
@@ -1426,12 +1427,11 @@ Pod::Spec.new do |s|
                       'third_party/re2/util/test.h',
                       'third_party/re2/util/utf.h',
                       'third_party/re2/util/util.h',
-                      'third_party/upb/third_party/wyhash/wyhash.h',
                       'third_party/upb/upb/decode.c',
                       'third_party/upb/upb/decode.h',
-                      'third_party/upb/upb/decode.int.h',
                       'third_party/upb/upb/decode_fast.c',
                       'third_party/upb/upb/decode_fast.h',
+                      'third_party/upb/upb/decode_internal.h',
                       'third_party/upb/upb/def.c',
                       'third_party/upb/upb/def.h',
                       'third_party/upb/upb/def.hpp',
@@ -1439,18 +1439,20 @@ Pod::Spec.new do |s|
                       'third_party/upb/upb/encode.h',
                       'third_party/upb/upb/msg.c',
                       'third_party/upb/upb/msg.h',
+                      'third_party/upb/upb/msg_internal.h',
                       'third_party/upb/upb/port_def.inc',
                       'third_party/upb/upb/port_undef.inc',
                       'third_party/upb/upb/reflection.c',
                       'third_party/upb/upb/reflection.h',
+                      'third_party/upb/upb/reflection.hpp',
                       'third_party/upb/upb/table.c',
-                      'third_party/upb/upb/table.int.h',
+                      'third_party/upb/upb/table_internal.h',
                       'third_party/upb/upb/text_encode.c',
                       'third_party/upb/upb/text_encode.h',
                       'third_party/upb/upb/upb.c',
                       'third_party/upb/upb/upb.h',
                       'third_party/upb/upb/upb.hpp',
-                      'third_party/upb/upb/upb.int.h',
+                      'third_party/upb/upb/upb_internal.h',
                       'third_party/xxhash/xxhash.h'
     ss.private_header_files = 'src/core/ext/filters/client_channel/backend_metric.h',
                               'src/core/ext/filters/client_channel/backup_poller.h',
@@ -1530,13 +1532,18 @@ Pod::Spec.new do |s|
                               'src/core/ext/transport/chttp2/transport/frame_rst_stream.h',
                               'src/core/ext/transport/chttp2/transport/frame_settings.h',
                               'src/core/ext/transport/chttp2/transport/frame_window_update.h',
+                              'src/core/ext/transport/chttp2/transport/hpack_constants.h',
                               'src/core/ext/transport/chttp2/transport/hpack_encoder.h',
+                              'src/core/ext/transport/chttp2/transport/hpack_encoder_index.h',
+                              'src/core/ext/transport/chttp2/transport/hpack_encoder_table.h',
                               'src/core/ext/transport/chttp2/transport/hpack_parser.h',
-                              'src/core/ext/transport/chttp2/transport/hpack_table.h',
+                              'src/core/ext/transport/chttp2/transport/hpack_parser_table.h',
+                              'src/core/ext/transport/chttp2/transport/hpack_utils.h',
                               'src/core/ext/transport/chttp2/transport/http2_settings.h',
                               'src/core/ext/transport/chttp2/transport/huffsyms.h',
                               'src/core/ext/transport/chttp2/transport/incoming_metadata.h',
                               'src/core/ext/transport/chttp2/transport/internal.h',
+                              'src/core/ext/transport/chttp2/transport/popularity_count.h',
                               'src/core/ext/transport/chttp2/transport/stream_map.h',
                               'src/core/ext/transport/chttp2/transport/varint.h',
                               'src/core/ext/transport/inproc/inproc_transport.h',
@@ -1773,6 +1780,7 @@ Pod::Spec.new do |s|
                               'src/core/lib/compression/stream_compression.h',
                               'src/core/lib/compression/stream_compression_gzip.h',
                               'src/core/lib/compression/stream_compression_identity.h',
+                              'src/core/lib/config/core_configuration.h',
                               'src/core/lib/debug/stats.h',
                               'src/core/lib/debug/stats_data.h',
                               'src/core/lib/debug/trace.h',
@@ -1786,14 +1794,12 @@ Pod::Spec.new do |s|
                               'src/core/lib/gpr/string_windows.h',
                               'src/core/lib/gpr/time_precise.h',
                               'src/core/lib/gpr/tls.h',
-                              'src/core/lib/gpr/tls_gcc.h',
-                              'src/core/lib/gpr/tls_msvc.h',
-                              'src/core/lib/gpr/tls_pthread.h',
-                              'src/core/lib/gpr/tls_stdcpp.h',
                               'src/core/lib/gpr/tmpfile.h',
                               'src/core/lib/gpr/useful.h',
                               'src/core/lib/gprpp/arena.h',
-                              'src/core/lib/gprpp/atomic.h',
+                              'src/core/lib/gprpp/atomic_utils.h',
+                              'src/core/lib/gprpp/bitset.h',
+                              'src/core/lib/gprpp/construct_destruct.h',
                               'src/core/lib/gprpp/debug_location.h',
                               'src/core/lib/gprpp/dual_ref_counted.h',
                               'src/core/lib/gprpp/examine_stack.h',
@@ -1804,9 +1810,11 @@ Pod::Spec.new do |s|
                               'src/core/lib/gprpp/global_config_generic.h',
                               'src/core/lib/gprpp/host_port.h',
                               'src/core/lib/gprpp/manual_constructor.h',
+                              'src/core/lib/gprpp/match.h',
                               'src/core/lib/gprpp/memory.h',
                               'src/core/lib/gprpp/mpscq.h',
                               'src/core/lib/gprpp/orphanable.h',
+                              'src/core/lib/gprpp/overload.h',
                               'src/core/lib/gprpp/ref_counted.h',
                               'src/core/lib/gprpp/ref_counted_ptr.h',
                               'src/core/lib/gprpp/stat.h',
@@ -1862,7 +1870,6 @@ Pod::Spec.new do |s|
                               'src/core/lib/iomgr/pollset_set.h',
                               'src/core/lib/iomgr/pollset_set_custom.h',
                               'src/core/lib/iomgr/pollset_set_windows.h',
-                              'src/core/lib/iomgr/pollset_uv.h',
                               'src/core/lib/iomgr/pollset_windows.h',
                               'src/core/lib/iomgr/port.h',
                               'src/core/lib/iomgr/python_util.h',
@@ -1870,7 +1877,6 @@ Pod::Spec.new do |s|
                               'src/core/lib/iomgr/resolve_address_custom.h',
                               'src/core/lib/iomgr/resource_quota.h',
                               'src/core/lib/iomgr/sockaddr.h',
-                              'src/core/lib/iomgr/sockaddr_custom.h',
                               'src/core/lib/iomgr/sockaddr_posix.h',
                               'src/core/lib/iomgr/sockaddr_windows.h',
                               'src/core/lib/iomgr/socket_factory_posix.h',
@@ -1904,6 +1910,7 @@ Pod::Spec.new do |s|
                               'src/core/lib/security/authorization/authorization_engine.h',
                               'src/core/lib/security/authorization/authorization_policy_provider.h',
                               'src/core/lib/security/authorization/evaluate_args.h',
+                              'src/core/lib/security/authorization/sdk_server_authz_filter.h',
                               'src/core/lib/security/context/security_context.h',
                               'src/core/lib/security/credentials/alts/alts_credentials.h',
                               'src/core/lib/security/credentials/alts/check_gcp_environment.h',
@@ -2034,22 +2041,23 @@ Pod::Spec.new do |s|
                               'third_party/re2/util/test.h',
                               'third_party/re2/util/utf.h',
                               'third_party/re2/util/util.h',
-                              'third_party/upb/third_party/wyhash/wyhash.h',
                               'third_party/upb/upb/decode.h',
-                              'third_party/upb/upb/decode.int.h',
                               'third_party/upb/upb/decode_fast.h',
+                              'third_party/upb/upb/decode_internal.h',
                               'third_party/upb/upb/def.h',
                               'third_party/upb/upb/def.hpp',
                               'third_party/upb/upb/encode.h',
                               'third_party/upb/upb/msg.h',
+                              'third_party/upb/upb/msg_internal.h',
                               'third_party/upb/upb/port_def.inc',
                               'third_party/upb/upb/port_undef.inc',
                               'third_party/upb/upb/reflection.h',
-                              'third_party/upb/upb/table.int.h',
+                              'third_party/upb/upb/reflection.hpp',
+                              'third_party/upb/upb/table_internal.h',
                               'third_party/upb/upb/text_encode.h',
                               'third_party/upb/upb/upb.h',
                               'third_party/upb/upb/upb.hpp',
-                              'third_party/upb/upb/upb.int.h',
+                              'third_party/upb/upb/upb_internal.h',
                               'third_party/xxhash/xxhash.h'
   end
 
@@ -2088,7 +2096,17 @@ Pod::Spec.new do |s|
     ss.dependency 'abseil/debugging/stacktrace', abseil_version
     ss.dependency 'abseil/debugging/symbolize', abseil_version
 
-    ss.source_files = 'test/core/end2end/cq_verifier.cc',
+    ss.source_files = 'src/core/lib/security/authorization/grpc_authorization_engine.cc',
+                      'src/core/lib/security/authorization/grpc_authorization_engine.h',
+                      'src/core/lib/security/authorization/grpc_authorization_policy_provider.cc',
+                      'src/core/lib/security/authorization/grpc_authorization_policy_provider.h',
+                      'src/core/lib/security/authorization/matchers.cc',
+                      'src/core/lib/security/authorization/matchers.h',
+                      'src/core/lib/security/authorization/rbac_policy.cc',
+                      'src/core/lib/security/authorization/rbac_policy.h',
+                      'src/core/lib/security/authorization/rbac_translator.cc',
+                      'src/core/lib/security/authorization/rbac_translator.h',
+                      'test/core/end2end/cq_verifier.cc',
                       'test/core/end2end/cq_verifier.h',
                       'test/core/end2end/data/client_certs.cc',
                       'test/core/end2end/data/server1_cert.cc',
@@ -2179,6 +2197,7 @@ Pod::Spec.new do |s|
                       'test/core/end2end/tests/retry_streaming_succeeds_before_replay_finished.cc',
                       'test/core/end2end/tests/retry_throttled.cc',
                       'test/core/end2end/tests/retry_too_many_attempts.cc',
+                      'test/core/end2end/tests/sdk_authz.cc',
                       'test/core/end2end/tests/server_finishes_request.cc',
                       'test/core/end2end/tests/server_streaming.cc',
                       'test/core/end2end/tests/shutdown_finishes_calls.cc',
@@ -2222,6 +2241,8 @@ Pod::Spec.new do |s|
                       'test/core/util/reconnect_server.h',
                       'test/core/util/resolve_localhost_ip46.cc',
                       'test/core/util/resolve_localhost_ip46.h',
+                      'test/core/util/resource_user_util.cc',
+                      'test/core/util/resource_user_util.h',
                       'test/core/util/slice_splitter.cc',
                       'test/core/util/slice_splitter.h',
                       'test/core/util/stack_tracer.cc',
index ae8bb8e..4a17b7e 100644 (file)
@@ -21,7 +21,7 @@
 
 Pod::Spec.new do |s|
   s.name     = 'gRPC-ProtoRPC'
-  version = '1.40.0'
+  version = '1.41.0'
   s.version  = version
   s.summary  = 'RPC library for Protocol Buffers, based on gRPC'
   s.homepage = 'https://grpc.io'
index b00d115..5e9115a 100644 (file)
@@ -21,7 +21,7 @@
 
 Pod::Spec.new do |s|
   s.name     = 'gRPC-RxLibrary'
-  version = '1.40.0'
+  version = '1.41.0'
   s.version  = version
   s.summary  = 'Reactive Extensions library for iOS/OSX.'
   s.homepage = 'https://grpc.io'
index 3d7f663..f262cce 100644 (file)
@@ -20,7 +20,7 @@
 
 Pod::Spec.new do |s|
   s.name     = 'gRPC'
-  version = '1.40.0'
+  version = '1.41.0'
   s.version  = version
   s.summary  = 'gRPC client library for iOS/OSX'
   s.homepage = 'https://grpc.io'
index 60e758d..87bce33 100644 (file)
@@ -32,7 +32,7 @@ Gem::Specification.new do |s|
   s.require_paths = %w( src/ruby/lib src/ruby/bin src/ruby/pb )
   s.platform      = Gem::Platform::RUBY
 
-  s.add_dependency 'google-protobuf', '~> 3.15'
+  s.add_dependency 'google-protobuf', '~> 3.17'
   s.add_dependency 'googleapis-common-protos-types', '~> 1.0'
 
   s.add_development_dependency 'bundler',            '>= 1.9'
@@ -178,13 +178,11 @@ Gem::Specification.new do |s|
   s.files += %w( src/core/ext/filters/client_channel/resolver/dns/c_ares/dns_resolver_ares.cc )
   s.files += %w( src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver.h )
   s.files += %w( src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_event_engine.cc )
-  s.files += %w( src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_libuv.cc )
   s.files += %w( src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_posix.cc )
   s.files += %w( src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_windows.cc )
   s.files += %w( src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper.cc )
   s.files += %w( src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper.h )
   s.files += %w( src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_event_engine.cc )
-  s.files += %w( src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_libuv.cc )
   s.files += %w( src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_posix.cc )
   s.files += %w( src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_windows.cc )
   s.files += %w( src/core/ext/filters/client_channel/resolver/dns/dns_resolver_selection.cc )
@@ -286,12 +284,18 @@ Gem::Specification.new do |s|
   s.files += %w( src/core/ext/transport/chttp2/transport/frame_settings.h )
   s.files += %w( src/core/ext/transport/chttp2/transport/frame_window_update.cc )
   s.files += %w( src/core/ext/transport/chttp2/transport/frame_window_update.h )
+  s.files += %w( src/core/ext/transport/chttp2/transport/hpack_constants.h )
   s.files += %w( src/core/ext/transport/chttp2/transport/hpack_encoder.cc )
   s.files += %w( src/core/ext/transport/chttp2/transport/hpack_encoder.h )
+  s.files += %w( src/core/ext/transport/chttp2/transport/hpack_encoder_index.h )
+  s.files += %w( src/core/ext/transport/chttp2/transport/hpack_encoder_table.cc )
+  s.files += %w( src/core/ext/transport/chttp2/transport/hpack_encoder_table.h )
   s.files += %w( src/core/ext/transport/chttp2/transport/hpack_parser.cc )
   s.files += %w( src/core/ext/transport/chttp2/transport/hpack_parser.h )
-  s.files += %w( src/core/ext/transport/chttp2/transport/hpack_table.cc )
-  s.files += %w( src/core/ext/transport/chttp2/transport/hpack_table.h )
+  s.files += %w( src/core/ext/transport/chttp2/transport/hpack_parser_table.cc )
+  s.files += %w( src/core/ext/transport/chttp2/transport/hpack_parser_table.h )
+  s.files += %w( src/core/ext/transport/chttp2/transport/hpack_utils.cc )
+  s.files += %w( src/core/ext/transport/chttp2/transport/hpack_utils.h )
   s.files += %w( src/core/ext/transport/chttp2/transport/http2_settings.cc )
   s.files += %w( src/core/ext/transport/chttp2/transport/http2_settings.h )
   s.files += %w( src/core/ext/transport/chttp2/transport/huffsyms.cc )
@@ -300,6 +304,7 @@ Gem::Specification.new do |s|
   s.files += %w( src/core/ext/transport/chttp2/transport/incoming_metadata.h )
   s.files += %w( src/core/ext/transport/chttp2/transport/internal.h )
   s.files += %w( src/core/ext/transport/chttp2/transport/parsing.cc )
+  s.files += %w( src/core/ext/transport/chttp2/transport/popularity_count.h )
   s.files += %w( src/core/ext/transport/chttp2/transport/stream_lists.cc )
   s.files += %w( src/core/ext/transport/chttp2/transport/stream_map.cc )
   s.files += %w( src/core/ext/transport/chttp2/transport/stream_map.h )
@@ -771,6 +776,8 @@ Gem::Specification.new do |s|
   s.files += %w( src/core/lib/compression/stream_compression_gzip.h )
   s.files += %w( src/core/lib/compression/stream_compression_identity.cc )
   s.files += %w( src/core/lib/compression/stream_compression_identity.h )
+  s.files += %w( src/core/lib/config/core_configuration.cc )
+  s.files += %w( src/core/lib/config/core_configuration.h )
   s.files += %w( src/core/lib/debug/stats.cc )
   s.files += %w( src/core/lib/debug/stats.h )
   s.files += %w( src/core/lib/debug/stats_data.cc )
@@ -817,11 +824,6 @@ Gem::Specification.new do |s|
   s.files += %w( src/core/lib/gpr/time_precise.h )
   s.files += %w( src/core/lib/gpr/time_windows.cc )
   s.files += %w( src/core/lib/gpr/tls.h )
-  s.files += %w( src/core/lib/gpr/tls_gcc.h )
-  s.files += %w( src/core/lib/gpr/tls_msvc.h )
-  s.files += %w( src/core/lib/gpr/tls_pthread.cc )
-  s.files += %w( src/core/lib/gpr/tls_pthread.h )
-  s.files += %w( src/core/lib/gpr/tls_stdcpp.h )
   s.files += %w( src/core/lib/gpr/tmpfile.h )
   s.files += %w( src/core/lib/gpr/tmpfile_msys.cc )
   s.files += %w( src/core/lib/gpr/tmpfile_posix.cc )
@@ -830,7 +832,9 @@ Gem::Specification.new do |s|
   s.files += %w( src/core/lib/gpr/wrap_memcpy.cc )
   s.files += %w( src/core/lib/gprpp/arena.cc )
   s.files += %w( src/core/lib/gprpp/arena.h )
-  s.files += %w( src/core/lib/gprpp/atomic.h )
+  s.files += %w( src/core/lib/gprpp/atomic_utils.h )
+  s.files += %w( src/core/lib/gprpp/bitset.h )
+  s.files += %w( src/core/lib/gprpp/construct_destruct.h )
   s.files += %w( src/core/lib/gprpp/debug_location.h )
   s.files += %w( src/core/lib/gprpp/dual_ref_counted.h )
   s.files += %w( src/core/lib/gprpp/examine_stack.cc )
@@ -845,10 +849,12 @@ Gem::Specification.new do |s|
   s.files += %w( src/core/lib/gprpp/host_port.cc )
   s.files += %w( src/core/lib/gprpp/host_port.h )
   s.files += %w( src/core/lib/gprpp/manual_constructor.h )
+  s.files += %w( src/core/lib/gprpp/match.h )
   s.files += %w( src/core/lib/gprpp/memory.h )
   s.files += %w( src/core/lib/gprpp/mpscq.cc )
   s.files += %w( src/core/lib/gprpp/mpscq.h )
   s.files += %w( src/core/lib/gprpp/orphanable.h )
+  s.files += %w( src/core/lib/gprpp/overload.h )
   s.files += %w( src/core/lib/gprpp/ref_counted.h )
   s.files += %w( src/core/lib/gprpp/ref_counted_ptr.h )
   s.files += %w( src/core/lib/gprpp/stat.h )
@@ -888,7 +894,6 @@ Gem::Specification.new do |s|
   s.files += %w( src/core/lib/iomgr/endpoint_pair.h )
   s.files += %w( src/core/lib/iomgr/endpoint_pair_event_engine.cc )
   s.files += %w( src/core/lib/iomgr/endpoint_pair_posix.cc )
-  s.files += %w( src/core/lib/iomgr/endpoint_pair_uv.cc )
   s.files += %w( src/core/lib/iomgr/endpoint_pair_windows.cc )
   s.files += %w( src/core/lib/iomgr/error.cc )
   s.files += %w( src/core/lib/iomgr/error.h )
@@ -949,7 +954,6 @@ Gem::Specification.new do |s|
   s.files += %w( src/core/lib/iomgr/iomgr_internal.h )
   s.files += %w( src/core/lib/iomgr/iomgr_posix.cc )
   s.files += %w( src/core/lib/iomgr/iomgr_posix_cfstream.cc )
-  s.files += %w( src/core/lib/iomgr/iomgr_uv.cc )
   s.files += %w( src/core/lib/iomgr/iomgr_windows.cc )
   s.files += %w( src/core/lib/iomgr/is_epollexclusive_available.cc )
   s.files += %w( src/core/lib/iomgr/is_epollexclusive_available.h )
@@ -970,8 +974,6 @@ Gem::Specification.new do |s|
   s.files += %w( src/core/lib/iomgr/pollset_set_custom.h )
   s.files += %w( src/core/lib/iomgr/pollset_set_windows.cc )
   s.files += %w( src/core/lib/iomgr/pollset_set_windows.h )
-  s.files += %w( src/core/lib/iomgr/pollset_uv.cc )
-  s.files += %w( src/core/lib/iomgr/pollset_uv.h )
   s.files += %w( src/core/lib/iomgr/pollset_windows.cc )
   s.files += %w( src/core/lib/iomgr/pollset_windows.h )
   s.files += %w( src/core/lib/iomgr/port.h )
@@ -985,7 +987,6 @@ Gem::Specification.new do |s|
   s.files += %w( src/core/lib/iomgr/resource_quota.cc )
   s.files += %w( src/core/lib/iomgr/resource_quota.h )
   s.files += %w( src/core/lib/iomgr/sockaddr.h )
-  s.files += %w( src/core/lib/iomgr/sockaddr_custom.h )
   s.files += %w( src/core/lib/iomgr/sockaddr_posix.h )
   s.files += %w( src/core/lib/iomgr/sockaddr_windows.h )
   s.files += %w( src/core/lib/iomgr/socket_factory_posix.cc )
@@ -997,7 +998,6 @@ Gem::Specification.new do |s|
   s.files += %w( src/core/lib/iomgr/socket_utils_linux.cc )
   s.files += %w( src/core/lib/iomgr/socket_utils_posix.cc )
   s.files += %w( src/core/lib/iomgr/socket_utils_posix.h )
-  s.files += %w( src/core/lib/iomgr/socket_utils_uv.cc )
   s.files += %w( src/core/lib/iomgr/socket_utils_windows.cc )
   s.files += %w( src/core/lib/iomgr/socket_windows.cc )
   s.files += %w( src/core/lib/iomgr/socket_windows.h )
@@ -1022,7 +1022,6 @@ Gem::Specification.new do |s|
   s.files += %w( src/core/lib/iomgr/tcp_server_utils_posix_ifaddrs.cc )
   s.files += %w( src/core/lib/iomgr/tcp_server_utils_posix_noifaddrs.cc )
   s.files += %w( src/core/lib/iomgr/tcp_server_windows.cc )
-  s.files += %w( src/core/lib/iomgr/tcp_uv.cc )
   s.files += %w( src/core/lib/iomgr/tcp_windows.cc )
   s.files += %w( src/core/lib/iomgr/tcp_windows.h )
   s.files += %w( src/core/lib/iomgr/time_averaged_stats.cc )
@@ -1037,7 +1036,6 @@ Gem::Specification.new do |s|
   s.files += %w( src/core/lib/iomgr/timer_heap.h )
   s.files += %w( src/core/lib/iomgr/timer_manager.cc )
   s.files += %w( src/core/lib/iomgr/timer_manager.h )
-  s.files += %w( src/core/lib/iomgr/timer_uv.cc )
   s.files += %w( src/core/lib/iomgr/udp_server.cc )
   s.files += %w( src/core/lib/iomgr/udp_server.h )
   s.files += %w( src/core/lib/iomgr/unix_sockets_posix.cc )
@@ -1066,6 +1064,8 @@ Gem::Specification.new do |s|
   s.files += %w( src/core/lib/security/authorization/authorization_policy_provider_vtable.cc )
   s.files += %w( src/core/lib/security/authorization/evaluate_args.cc )
   s.files += %w( src/core/lib/security/authorization/evaluate_args.h )
+  s.files += %w( src/core/lib/security/authorization/sdk_server_authz_filter.cc )
+  s.files += %w( src/core/lib/security/authorization/sdk_server_authz_filter.h )
   s.files += %w( src/core/lib/security/context/security_context.cc )
   s.files += %w( src/core/lib/security/context/security_context.h )
   s.files += %w( src/core/lib/security/credentials/alts/alts_credentials.cc )
@@ -1563,12 +1563,12 @@ Gem::Specification.new do |s|
   s.files += %w( third_party/boringssl-with-bazel/src/crypto/asn1/a_utctm.c )
   s.files += %w( third_party/boringssl-with-bazel/src/crypto/asn1/a_utf8.c )
   s.files += %w( third_party/boringssl-with-bazel/src/crypto/asn1/asn1_lib.c )
-  s.files += %w( third_party/boringssl-with-bazel/src/crypto/asn1/asn1_locl.h )
   s.files += %w( third_party/boringssl-with-bazel/src/crypto/asn1/asn1_par.c )
   s.files += %w( third_party/boringssl-with-bazel/src/crypto/asn1/asn_pack.c )
   s.files += %w( third_party/boringssl-with-bazel/src/crypto/asn1/f_enum.c )
   s.files += %w( third_party/boringssl-with-bazel/src/crypto/asn1/f_int.c )
   s.files += %w( third_party/boringssl-with-bazel/src/crypto/asn1/f_string.c )
+  s.files += %w( third_party/boringssl-with-bazel/src/crypto/asn1/internal.h )
   s.files += %w( third_party/boringssl-with-bazel/src/crypto/asn1/tasn_dec.c )
   s.files += %w( third_party/boringssl-with-bazel/src/crypto/asn1/tasn_enc.c )
   s.files += %w( third_party/boringssl-with-bazel/src/crypto/asn1/tasn_fre.c )
@@ -1765,6 +1765,7 @@ Gem::Specification.new do |s|
   s.files += %w( third_party/boringssl-with-bazel/src/crypto/hrss/hrss.c )
   s.files += %w( third_party/boringssl-with-bazel/src/crypto/hrss/internal.h )
   s.files += %w( third_party/boringssl-with-bazel/src/crypto/internal.h )
+  s.files += %w( third_party/boringssl-with-bazel/src/crypto/lhash/internal.h )
   s.files += %w( third_party/boringssl-with-bazel/src/crypto/lhash/lhash.c )
   s.files += %w( third_party/boringssl-with-bazel/src/crypto/mem.c )
   s.files += %w( third_party/boringssl-with-bazel/src/crypto/obj/obj.c )
@@ -1983,6 +1984,7 @@ Gem::Specification.new do |s|
   s.files += %w( third_party/boringssl-with-bazel/src/ssl/dtls_method.cc )
   s.files += %w( third_party/boringssl-with-bazel/src/ssl/dtls_record.cc )
   s.files += %w( third_party/boringssl-with-bazel/src/ssl/encrypted_client_hello.cc )
+  s.files += %w( third_party/boringssl-with-bazel/src/ssl/extensions.cc )
   s.files += %w( third_party/boringssl-with-bazel/src/ssl/handoff.cc )
   s.files += %w( third_party/boringssl-with-bazel/src/ssl/handshake.cc )
   s.files += %w( third_party/boringssl-with-bazel/src/ssl/handshake_client.cc )
@@ -2006,7 +2008,6 @@ Gem::Specification.new do |s|
   s.files += %w( third_party/boringssl-with-bazel/src/ssl/ssl_versions.cc )
   s.files += %w( third_party/boringssl-with-bazel/src/ssl/ssl_x509.cc )
   s.files += %w( third_party/boringssl-with-bazel/src/ssl/t1_enc.cc )
-  s.files += %w( third_party/boringssl-with-bazel/src/ssl/t1_lib.cc )
   s.files += %w( third_party/boringssl-with-bazel/src/ssl/tls13_both.cc )
   s.files += %w( third_party/boringssl-with-bazel/src/ssl/tls13_client.cc )
   s.files += %w( third_party/boringssl-with-bazel/src/ssl/tls13_enc.cc )
@@ -2143,12 +2144,11 @@ Gem::Specification.new do |s|
   s.files += %w( third_party/re2/util/test.h )
   s.files += %w( third_party/re2/util/utf.h )
   s.files += %w( third_party/re2/util/util.h )
-  s.files += %w( third_party/upb/third_party/wyhash/wyhash.h )
   s.files += %w( third_party/upb/upb/decode.c )
   s.files += %w( third_party/upb/upb/decode.h )
-  s.files += %w( third_party/upb/upb/decode.int.h )
   s.files += %w( third_party/upb/upb/decode_fast.c )
   s.files += %w( third_party/upb/upb/decode_fast.h )
+  s.files += %w( third_party/upb/upb/decode_internal.h )
   s.files += %w( third_party/upb/upb/def.c )
   s.files += %w( third_party/upb/upb/def.h )
   s.files += %w( third_party/upb/upb/def.hpp )
@@ -2156,18 +2156,20 @@ Gem::Specification.new do |s|
   s.files += %w( third_party/upb/upb/encode.h )
   s.files += %w( third_party/upb/upb/msg.c )
   s.files += %w( third_party/upb/upb/msg.h )
+  s.files += %w( third_party/upb/upb/msg_internal.h )
   s.files += %w( third_party/upb/upb/port_def.inc )
   s.files += %w( third_party/upb/upb/port_undef.inc )
   s.files += %w( third_party/upb/upb/reflection.c )
   s.files += %w( third_party/upb/upb/reflection.h )
+  s.files += %w( third_party/upb/upb/reflection.hpp )
   s.files += %w( third_party/upb/upb/table.c )
-  s.files += %w( third_party/upb/upb/table.int.h )
+  s.files += %w( third_party/upb/upb/table_internal.h )
   s.files += %w( third_party/upb/upb/text_encode.c )
   s.files += %w( third_party/upb/upb/text_encode.h )
   s.files += %w( third_party/upb/upb/upb.c )
   s.files += %w( third_party/upb/upb/upb.h )
   s.files += %w( third_party/upb/upb/upb.hpp )
-  s.files += %w( third_party/upb/upb/upb.int.h )
+  s.files += %w( third_party/upb/upb/upb_internal.h )
   s.files += %w( third_party/xxhash/xxhash.h )
   s.files += %w( third_party/zlib/adler32.c )
   s.files += %w( third_party/zlib/compress.c )
index 29ede20..d3272f8 100644 (file)
--- a/grpc.gyp
+++ b/grpc.gyp
         'grpc_test_util',
       ],
       'sources': [
+        'src/core/lib/security/authorization/grpc_authorization_engine.cc',
+        'src/core/lib/security/authorization/grpc_authorization_policy_provider.cc',
+        'src/core/lib/security/authorization/matchers.cc',
+        'src/core/lib/security/authorization/rbac_policy.cc',
+        'src/core/lib/security/authorization/rbac_translator.cc',
         'test/core/end2end/cq_verifier.cc',
         'test/core/end2end/data/client_certs.cc',
         'test/core/end2end/data/server1_cert.cc',
         'test/core/end2end/tests/retry_streaming_succeeds_before_replay_finished.cc',
         'test/core/end2end/tests/retry_throttled.cc',
         'test/core/end2end/tests/retry_too_many_attempts.cc',
+        'test/core/end2end/tests/sdk_authz.cc',
         'test/core/end2end/tests/server_finishes_request.cc',
         'test/core/end2end/tests/server_streaming.cc',
         'test/core/end2end/tests/shutdown_finishes_calls.cc',
         'src/core/lib/gpr/time_posix.cc',
         'src/core/lib/gpr/time_precise.cc',
         'src/core/lib/gpr/time_windows.cc',
-        'src/core/lib/gpr/tls_pthread.cc',
         'src/core/lib/gpr/tmpfile_msys.cc',
         'src/core/lib/gpr/tmpfile_posix.cc',
         'src/core/lib/gpr/tmpfile_windows.cc',
         'absl/container:inlined_vector',
         'absl/functional:bind_front',
         'absl/status:statusor',
+        'absl/types:variant',
         'gpr',
         'address_sorting',
       ],
         'src/core/ext/filters/client_channel/resolver.cc',
         'src/core/ext/filters/client_channel/resolver/dns/c_ares/dns_resolver_ares.cc',
         'src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_event_engine.cc',
-        'src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_libuv.cc',
         'src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_posix.cc',
         'src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_windows.cc',
         'src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper.cc',
         'src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_event_engine.cc',
-        'src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_libuv.cc',
         'src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_posix.cc',
         'src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_windows.cc',
         'src/core/ext/filters/client_channel/resolver/dns/dns_resolver_selection.cc',
         'src/core/ext/transport/chttp2/transport/frame_settings.cc',
         'src/core/ext/transport/chttp2/transport/frame_window_update.cc',
         'src/core/ext/transport/chttp2/transport/hpack_encoder.cc',
+        'src/core/ext/transport/chttp2/transport/hpack_encoder_table.cc',
         'src/core/ext/transport/chttp2/transport/hpack_parser.cc',
-        'src/core/ext/transport/chttp2/transport/hpack_table.cc',
+        'src/core/ext/transport/chttp2/transport/hpack_parser_table.cc',
+        'src/core/ext/transport/chttp2/transport/hpack_utils.cc',
         'src/core/ext/transport/chttp2/transport/http2_settings.cc',
         'src/core/ext/transport/chttp2/transport/huffsyms.cc',
         'src/core/ext/transport/chttp2/transport/incoming_metadata.cc',
         'src/core/lib/compression/stream_compression.cc',
         'src/core/lib/compression/stream_compression_gzip.cc',
         'src/core/lib/compression/stream_compression_identity.cc',
+        'src/core/lib/config/core_configuration.cc',
         'src/core/lib/debug/stats.cc',
         'src/core/lib/debug/stats_data.cc',
         'src/core/lib/debug/trace.cc',
         'src/core/lib/iomgr/endpoint_cfstream.cc',
         'src/core/lib/iomgr/endpoint_pair_event_engine.cc',
         'src/core/lib/iomgr/endpoint_pair_posix.cc',
-        'src/core/lib/iomgr/endpoint_pair_uv.cc',
         'src/core/lib/iomgr/endpoint_pair_windows.cc',
         'src/core/lib/iomgr/error.cc',
         'src/core/lib/iomgr/error_cfstream.cc',
         'src/core/lib/iomgr/iomgr_internal.cc',
         'src/core/lib/iomgr/iomgr_posix.cc',
         'src/core/lib/iomgr/iomgr_posix_cfstream.cc',
-        'src/core/lib/iomgr/iomgr_uv.cc',
         'src/core/lib/iomgr/iomgr_windows.cc',
         'src/core/lib/iomgr/is_epollexclusive_available.cc',
         'src/core/lib/iomgr/load_file.cc',
         'src/core/lib/iomgr/pollset_set.cc',
         'src/core/lib/iomgr/pollset_set_custom.cc',
         'src/core/lib/iomgr/pollset_set_windows.cc',
-        'src/core/lib/iomgr/pollset_uv.cc',
         'src/core/lib/iomgr/pollset_windows.cc',
         'src/core/lib/iomgr/resolve_address.cc',
         'src/core/lib/iomgr/resolve_address_custom.cc',
         'src/core/lib/iomgr/socket_utils_common_posix.cc',
         'src/core/lib/iomgr/socket_utils_linux.cc',
         'src/core/lib/iomgr/socket_utils_posix.cc',
-        'src/core/lib/iomgr/socket_utils_uv.cc',
         'src/core/lib/iomgr/socket_utils_windows.cc',
         'src/core/lib/iomgr/socket_windows.cc',
         'src/core/lib/iomgr/tcp_client.cc',
         'src/core/lib/iomgr/tcp_server_utils_posix_ifaddrs.cc',
         'src/core/lib/iomgr/tcp_server_utils_posix_noifaddrs.cc',
         'src/core/lib/iomgr/tcp_server_windows.cc',
-        'src/core/lib/iomgr/tcp_uv.cc',
         'src/core/lib/iomgr/tcp_windows.cc',
         'src/core/lib/iomgr/time_averaged_stats.cc',
         'src/core/lib/iomgr/timer.cc',
         'src/core/lib/iomgr/timer_generic.cc',
         'src/core/lib/iomgr/timer_heap.cc',
         'src/core/lib/iomgr/timer_manager.cc',
-        'src/core/lib/iomgr/timer_uv.cc',
         'src/core/lib/iomgr/udp_server.cc',
         'src/core/lib/iomgr/unix_sockets_posix.cc',
         'src/core/lib/iomgr/unix_sockets_posix_noop.cc',
         'src/core/lib/matchers/matchers.cc',
         'src/core/lib/security/authorization/authorization_policy_provider_vtable.cc',
         'src/core/lib/security/authorization/evaluate_args.cc',
+        'src/core/lib/security/authorization/sdk_server_authz_filter.cc',
         'src/core/lib/security/context/security_context.cc',
         'src/core/lib/security/credentials/alts/alts_credentials.cc',
         'src/core/lib/security/credentials/alts/check_gcp_environment.cc',
         'test/core/util/port_server_client.cc',
         'test/core/util/reconnect_server.cc',
         'test/core/util/resolve_localhost_ip46.cc',
+        'test/core/util/resource_user_util.cc',
         'test/core/util/slice_splitter.cc',
         'test/core/util/stack_tracer.cc',
         'test/core/util/subprocess_posix.cc',
         'test/core/util/port_server_client.cc',
         'test/core/util/reconnect_server.cc',
         'test/core/util/resolve_localhost_ip46.cc',
+        'test/core/util/resource_user_util.cc',
         'test/core/util/slice_splitter.cc',
         'test/core/util/stack_tracer.cc',
         'test/core/util/subprocess_posix.cc',
         'absl/container:inlined_vector',
         'absl/functional:bind_front',
         'absl/status:statusor',
+        'absl/types:variant',
         'gpr',
         'address_sorting',
       ],
         'src/core/ext/filters/client_channel/resolver.cc',
         'src/core/ext/filters/client_channel/resolver/dns/c_ares/dns_resolver_ares.cc',
         'src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_event_engine.cc',
-        'src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_libuv.cc',
         'src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_posix.cc',
         'src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_windows.cc',
         'src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper.cc',
         'src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_event_engine.cc',
-        'src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_libuv.cc',
         'src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_posix.cc',
         'src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_windows.cc',
         'src/core/ext/filters/client_channel/resolver/dns/dns_resolver_selection.cc',
         'src/core/ext/transport/chttp2/transport/frame_settings.cc',
         'src/core/ext/transport/chttp2/transport/frame_window_update.cc',
         'src/core/ext/transport/chttp2/transport/hpack_encoder.cc',
+        'src/core/ext/transport/chttp2/transport/hpack_encoder_table.cc',
         'src/core/ext/transport/chttp2/transport/hpack_parser.cc',
-        'src/core/ext/transport/chttp2/transport/hpack_table.cc',
+        'src/core/ext/transport/chttp2/transport/hpack_parser_table.cc',
+        'src/core/ext/transport/chttp2/transport/hpack_utils.cc',
         'src/core/ext/transport/chttp2/transport/http2_settings.cc',
         'src/core/ext/transport/chttp2/transport/huffsyms.cc',
         'src/core/ext/transport/chttp2/transport/incoming_metadata.cc',
         'src/core/lib/compression/stream_compression.cc',
         'src/core/lib/compression/stream_compression_gzip.cc',
         'src/core/lib/compression/stream_compression_identity.cc',
+        'src/core/lib/config/core_configuration.cc',
         'src/core/lib/debug/stats.cc',
         'src/core/lib/debug/stats_data.cc',
         'src/core/lib/debug/trace.cc',
         'src/core/lib/iomgr/endpoint_cfstream.cc',
         'src/core/lib/iomgr/endpoint_pair_event_engine.cc',
         'src/core/lib/iomgr/endpoint_pair_posix.cc',
-        'src/core/lib/iomgr/endpoint_pair_uv.cc',
         'src/core/lib/iomgr/endpoint_pair_windows.cc',
         'src/core/lib/iomgr/error.cc',
         'src/core/lib/iomgr/error_cfstream.cc',
         'src/core/lib/iomgr/iomgr_internal.cc',
         'src/core/lib/iomgr/iomgr_posix.cc',
         'src/core/lib/iomgr/iomgr_posix_cfstream.cc',
-        'src/core/lib/iomgr/iomgr_uv.cc',
         'src/core/lib/iomgr/iomgr_windows.cc',
         'src/core/lib/iomgr/is_epollexclusive_available.cc',
         'src/core/lib/iomgr/load_file.cc',
         'src/core/lib/iomgr/pollset_set.cc',
         'src/core/lib/iomgr/pollset_set_custom.cc',
         'src/core/lib/iomgr/pollset_set_windows.cc',
-        'src/core/lib/iomgr/pollset_uv.cc',
         'src/core/lib/iomgr/pollset_windows.cc',
         'src/core/lib/iomgr/resolve_address.cc',
         'src/core/lib/iomgr/resolve_address_custom.cc',
         'src/core/lib/iomgr/socket_utils_common_posix.cc',
         'src/core/lib/iomgr/socket_utils_linux.cc',
         'src/core/lib/iomgr/socket_utils_posix.cc',
-        'src/core/lib/iomgr/socket_utils_uv.cc',
         'src/core/lib/iomgr/socket_utils_windows.cc',
         'src/core/lib/iomgr/socket_windows.cc',
         'src/core/lib/iomgr/tcp_client.cc',
         'src/core/lib/iomgr/tcp_server_utils_posix_ifaddrs.cc',
         'src/core/lib/iomgr/tcp_server_utils_posix_noifaddrs.cc',
         'src/core/lib/iomgr/tcp_server_windows.cc',
-        'src/core/lib/iomgr/tcp_uv.cc',
         'src/core/lib/iomgr/tcp_windows.cc',
         'src/core/lib/iomgr/time_averaged_stats.cc',
         'src/core/lib/iomgr/timer.cc',
         'src/core/lib/iomgr/timer_generic.cc',
         'src/core/lib/iomgr/timer_heap.cc',
         'src/core/lib/iomgr/timer_manager.cc',
-        'src/core/lib/iomgr/timer_uv.cc',
         'src/core/lib/iomgr/udp_server.cc',
         'src/core/lib/iomgr/unix_sockets_posix.cc',
         'src/core/lib/iomgr/unix_sockets_posix_noop.cc',
         'third_party/boringssl-with-bazel/src/ssl/dtls_method.cc',
         'third_party/boringssl-with-bazel/src/ssl/dtls_record.cc',
         'third_party/boringssl-with-bazel/src/ssl/encrypted_client_hello.cc',
+        'third_party/boringssl-with-bazel/src/ssl/extensions.cc',
         'third_party/boringssl-with-bazel/src/ssl/handoff.cc',
         'third_party/boringssl-with-bazel/src/ssl/handshake.cc',
         'third_party/boringssl-with-bazel/src/ssl/handshake_client.cc',
         'third_party/boringssl-with-bazel/src/ssl/ssl_versions.cc',
         'third_party/boringssl-with-bazel/src/ssl/ssl_x509.cc',
         'third_party/boringssl-with-bazel/src/ssl/t1_enc.cc',
-        'third_party/boringssl-with-bazel/src/ssl/t1_lib.cc',
         'third_party/boringssl-with-bazel/src/ssl/tls13_both.cc',
         'third_party/boringssl-with-bazel/src/ssl/tls13_client.cc',
         'third_party/boringssl-with-bazel/src/ssl/tls13_enc.cc',
index ee740f4..fff33cb 100644 (file)
@@ -21,7 +21,7 @@
 
 #include <grpc/support/port_platform.h>
 
-#include <grpc/impl/codegen/byte_buffer.h>
+#include <grpc/impl/codegen/byte_buffer.h>  // IWYU pragma: export
 #include <grpc/slice_buffer.h>
 
 #endif /* GRPC_BYTE_BUFFER_H */
index 15e06ca..763dd78 100644 (file)
@@ -21,6 +21,6 @@
 
 #include <grpc/support/port_platform.h>
 
-#include <grpc/impl/codegen/byte_buffer_reader.h>
+#include <grpc/impl/codegen/byte_buffer_reader.h>  // IWYU pragma: export
 
 #endif /* GRPC_BYTE_BUFFER_READER_H */
index ea1e172..6ca4b4f 100644 (file)
 namespace grpc_event_engine {
 namespace experimental {
 
-/// A set of parameters used to configure an endpoint, either when initiating a
-/// new connection on the client side or when listening for incoming connections
-/// on the server side. An EndpointConfig contains a set of zero or more
-/// Settings. Each setting has a unique name, which can be used to fetch that
-/// Setting via the Get() method. Each Setting has a value, which can be an
-/// integer, string, or void pointer. Each EE impl should define the set of
-/// Settings that it supports being passed into it, along with the corresponding
-/// type.
+/// Collection of parameters used to configure client and server endpoints. The
+/// \a EndpointConfig maps string-valued keys to values of type int,
+/// string_view, or void pointer. Each EventEngine implementation should
+/// document its set of supported configuration options.
 class EndpointConfig {
  public:
   virtual ~EndpointConfig() = default;
   using Setting = absl::variant<absl::monostate, int, absl::string_view, void*>;
-  /// Returns an EndpointConfig Setting. If there is no Setting associated with
-  /// \a key in the EndpointConfig, an \a absl::monostate type will be
-  /// returned. Caller does not take ownership of resulting value.
+  /// Returns the Setting for a specified key, or \a absl::monostate if there is
+  /// no such entry. Caller does not take ownership of the resulting value.
   virtual Setting Get(absl::string_view key) const = 0;
 };
 
index 1fa8e43..61e3ecb 100644 (file)
@@ -23,9 +23,9 @@
 #include "absl/status/statusor.h"
 #include "absl/time/time.h"
 
-#include "grpc/event_engine/endpoint_config.h"
-#include "grpc/event_engine/port.h"
-#include "grpc/event_engine/slice_allocator.h"
+#include <grpc/event_engine/endpoint_config.h>
+#include <grpc/event_engine/port.h>
+#include <grpc/event_engine/slice_allocator.h>
 
 // TODO(hork): Define the Endpoint::Write metrics collection system
 namespace grpc_event_engine {
@@ -73,16 +73,16 @@ namespace experimental {
 ////////////////////////////////////////////////////////////////////////////////
 class EventEngine {
  public:
-  /// A basic callable function. The first argument to all callbacks is an
+  /// Basic callable function. The first argument to all callbacks is an
   /// absl::Status indicating the status of the operation associated with this
   /// callback. Each EventEngine method that takes a callback parameter, defines
   /// the expected sets and meanings of statuses for that use case.
   using Callback = std::function<void(absl::Status)>;
-  /// A callback handle, used to cancel a callback.
+  /// Callback handle, used to cancel a callback.
   struct TaskHandle {
     intptr_t keys[2];
   };
-  /// A thin wrapper around a platform-specific sockaddr type. A sockaddr struct
+  /// Thin wrapper around a platform-specific sockaddr type. A sockaddr struct
   /// exists on all platforms that gRPC supports.
   ///
   /// Platforms are expected to provide definitions for:
@@ -104,9 +104,9 @@ class EventEngine {
     socklen_t size_ = 0;
   };
 
-  /// An Endpoint represents one end of a connection between a gRPC client and
-  /// server. Endpoints are created when connections are established, and
-  /// Endpoint operations are gRPC's primary means of communication.
+  /// One end of a connection between a gRPC client and server. Endpoints are
+  /// created when connections are established, and Endpoint operations are
+  /// gRPC's primary means of communication.
   ///
   /// Endpoints must use the provided SliceAllocator for all data buffer memory
   /// allocations. gRPC allows applications to set memory constraints per
@@ -114,10 +114,10 @@ class EventEngine {
   /// allocation being handled by the quota system.
   class Endpoint {
    public:
-    /// The Endpoint destructor is responsible for shutting down all connections
-    /// and invoking all pending read or write callbacks with an error status.
+    /// Shuts down all connections and invokes all pending read or write
+    /// callbacks with an error status.
     virtual ~Endpoint() = default;
-    /// Read data from the Endpoint.
+    /// Reads data from the Endpoint.
     ///
     /// When data is available on the connection, that data is moved into the
     /// \a buffer, and the \a on_read callback is called. The caller must ensure
@@ -125,24 +125,37 @@ class EventEngine {
     /// Ownership of the buffer is not transferred. Valid slices *may* be placed
     /// into the buffer even if the callback is invoked with a non-OK Status.
     ///
+    /// There can be at most one outstanding read per Endpoint at any given
+    /// time. An outstanding read is one in which the \a on_read callback has
+    /// not yet been executed for some previous call to \a Read.  If an attempt
+    /// is made to call \a Read while a previous read is still outstanding, the
+    /// \a EventEngine must abort.
+    ///
     /// For failed read operations, implementations should pass the appropriate
     /// statuses to \a on_read. For example, callbacks might expect to receive
     /// CANCELLED on endpoint shutdown.
     virtual void Read(Callback on_read, SliceBuffer* buffer) = 0;
-    /// Write data out on the connection.
+    /// Writes data out on the connection.
     ///
     /// \a on_writable is called when the connection is ready for more data. The
     /// Slices within the \a data buffer may be mutated at will by the Endpoint
     /// until \a on_writable is called. The \a data SliceBuffer will remain
-    /// valid after calling \a Write, but its state is otherwise undefined.
+    /// valid after calling \a Write, but its state is otherwise undefined.  All
+    /// bytes in \a data must have been written before calling \a on_writable
+    /// unless an error has occurred.
+    ///
+    /// There can be at most one outstanding write per Endpoint at any given
+    /// time. An outstanding write is one in which the \a on_writable callback
+    /// has not yet been executed for some previous call to \a Write.  If an
+    /// attempt is made to call \a Write while a previous write is still
+    /// outstanding, the \a EventEngine must abort.
     ///
     /// For failed write operations, implementations should pass the appropriate
     /// statuses to \a on_writable. For example, callbacks might expect to
     /// receive CANCELLED on endpoint shutdown.
     virtual void Write(Callback on_writable, SliceBuffer* data) = 0;
-    /// These methods return an address in the format described in DNSResolver.
-    /// The returned values are owned by the Endpoint and are expected to remain
-    /// valid for the life of the Endpoint.
+    /// Returns an address in the format described in DNSResolver. The returned
+    /// values are expected to remain valid for the life of the Endpoint.
     virtual const ResolvedAddress& GetPeerAddress() const = 0;
     virtual const ResolvedAddress& GetLocalAddress() const = 0;
   };
@@ -156,12 +169,13 @@ class EventEngine {
   using OnConnectCallback =
       std::function<void(absl::StatusOr<std::unique_ptr<Endpoint>>)>;
 
-  /// An EventEngine Listener listens for incoming connection requests from gRPC
-  /// clients and initiates request processing once connections are established.
+  /// Listens for incoming connection requests from gRPC clients and initiates
+  /// request processing once connections are established.
   class Listener {
    public:
     /// Called when the listener has accepted a new client connection.
-    using AcceptCallback = std::function<void(std::unique_ptr<Endpoint>)>;
+    using AcceptCallback = std::function<void(
+        std::unique_ptr<Endpoint>, const SliceAllocator& slice_allocator)>;
     virtual ~Listener() = default;
     /// Bind an address/port to this Listener.
     ///
@@ -175,14 +189,10 @@ class EventEngine {
   /// Factory method to create a network listener / server.
   ///
   /// Once a \a Listener is created and started, the \a on_accept callback will
-  /// be called once asynchronously for each established connection. Note that
-  /// unlike other callbacks, there is no status code parameter since the
-  /// callback will only be called in healthy scenarios where connections can be
-  /// accepted.
-  ///
-  /// This method may return a non-OK status immediately if an error was
-  /// encountered in any synchronous steps required to create the Listener. In
-  /// this case, \a on_shutdown will never be called.
+  /// be called once asynchronously for each established connection. This method
+  /// may return a non-OK status immediately if an error was encountered in any
+  /// synchronous steps required to create the Listener. In this case,
+  /// \a on_shutdown will never be called.
   ///
   /// If this method returns a Listener, then \a on_shutdown will be invoked
   /// exactly once, when the Listener is shut down. The status passed to it will
@@ -192,13 +202,13 @@ class EventEngine {
   /// for Endpoint construction.
   virtual absl::StatusOr<std::unique_ptr<Listener>> CreateListener(
       Listener::AcceptCallback on_accept, Callback on_shutdown,
-      const EndpointConfig& args,
+      const EndpointConfig& config,
       std::unique_ptr<SliceAllocatorFactory> slice_allocator_factory) = 0;
   /// Creates a client network connection to a remote network listener.
   ///
-  /// \a Connect may return an error status immediately if there was a failure
-  /// in the synchronous part of establishing a connection. In that event, the
-  /// \a on_connect callback *will not* have been executed. Otherwise, it is
+  /// May return an error status immediately if there was a failure in the
+  /// synchronous part of establishing a connection. In that event, the \a
+  /// on_connect callback *will not* have been executed. Otherwise, it is
   /// expected that the \a on_connect callback will be asynchronously executed
   /// exactly once by the EventEngine.
   ///
@@ -213,14 +223,14 @@ class EventEngine {
                                std::unique_ptr<SliceAllocator> slice_allocator,
                                absl::Time deadline) = 0;
 
-  /// The DNSResolver that provides asynchronous resolution.
+  /// Provides asynchronous resolution.
   class DNSResolver {
    public:
-    /// A task handle for DNS Resolution requests.
+    /// Task handle for DNS Resolution requests.
     struct LookupTaskHandle {
       intptr_t key[2];
     };
-    /// DNS SRV record type.
+    /// DNS SRV record type.
     struct SRVRecord {
       std::string host;
       int port = 0;
@@ -271,35 +281,40 @@ class EventEngine {
     virtual void TryCancelLookup(LookupTaskHandle handle) = 0;
   };
 
+  /// At time of destruction, the EventEngine must have no active
+  /// responsibilities. EventEngine users (applications) are responsible for
+  /// cancelling all tasks and DNS lookups, shutting down listeners and
+  /// endpoints, prior to EventEngine destruction. If there are any outstanding
+  /// tasks, any running listeners, etc. at time of EventEngine destruction,
+  /// that is an invalid use of the API, and it will result in undefined
+  /// behavior.
   virtual ~EventEngine() = default;
 
   // TODO(nnoble): consider whether we can remove this method before we
   // de-experimentalize this API.
   virtual bool IsWorkerThread() = 0;
 
-  // TODO(hork): define return status codes
-  /// Retrieves an instance of a DNSResolver.
-  virtual absl::StatusOr<std::unique_ptr<DNSResolver>> GetDNSResolver() = 0;
+  /// Creates and returns an instance of a DNSResolver.
+  virtual std::unique_ptr<DNSResolver> GetDNSResolver() = 0;
 
-  /// Intended for future expansion of Task run functionality.
-  struct RunOptions {};
-  /// Run a callback as soon as possible.
+  /// Executes a callback as soon as possible.
   ///
   /// The \a fn callback's \a status argument is used to indicate whether it was
-  /// executed normally. For example, the status may be CANCELLED if
-  /// \a TryCancel was called, or if the EventEngine is being shut down.
-  virtual TaskHandle Run(Callback fn, RunOptions opts) = 0;
+  /// executed normally. For example, the status may be CANCELLED if the
+  /// EventEngine is being shut down. \a fn is guaranteed to be called exactly
+  /// once.
+  virtual void Run(Callback fn) = 0;
   /// Synonymous with scheduling an alarm to run at time \a when.
   ///
   /// The callback \a fn will execute when either when time \a when arrives
-  /// (receiving status OK), or when the \a fn is cancelled (reveiving status
+  /// (receiving status OK), or when the \a fn is cancelled (receiving status
   /// CANCELLED). The callback is guaranteed to be called exactly once.
-  virtual TaskHandle RunAt(absl::Time when, Callback fn, RunOptions opts) = 0;
-  /// Immediately tries to cancel a callback.
+  virtual TaskHandle RunAt(absl::Time when, Callback fn) = 0;
+  /// Attempts to cancel a callback.
   /// Note that this is a "best effort" cancellation. No guarantee is made that
   /// the callback will be cancelled, the call could be in any stage.
   ///
-  /// There are three scenarios in which we may cancel a scheduled function:
+  /// There are three scenarios in which we may cancel a scheduled task:
   ///   1. We cancel the execution before it has run.
   ///   2. The callback has already run.
   ///   3. We can't cancel it because it is "in flight".
@@ -308,16 +323,6 @@ class EventEngine {
   /// callback will be run exactly once from either cancellation or from its
   /// activation.
   virtual void TryCancel(TaskHandle handle) = 0;
-  /// Immediately run all callbacks with status indicating the shutdown. Every
-  /// EventEngine is expected to shut down exactly once. No new callbacks/tasks
-  /// should be scheduled after shutdown has begun, no new connections should be
-  /// created.
-  ///
-  /// If the \a on_shutdown_complete callback is given a non-OK status, errors
-  /// are expected to be unrecoverable. For example, an implementation could
-  /// warn callers about leaks if memory cannot be freed within a certain
-  /// timeframe.
-  virtual void Shutdown(Callback on_shutdown_complete) = 0;
 };
 
 // TODO(hork): finalize the API and document it. We need to firm up the story
index d54e65e..9424586 100644 (file)
@@ -17,9 +17,7 @@
 #include <grpc/support/port_platform.h>
 
 // Platform-specific sockaddr includes
-#ifdef GRPC_UV
-#include <uv.h>
-#elif defined(GPR_ANDROID) || defined(GPR_LINUX) || defined(GPR_APPLE) ||   \
+#if defined(GPR_ANDROID) || defined(GPR_LINUX) || defined(GPR_APPLE) ||     \
     defined(GPR_FREEBSD) || defined(GPR_OPENBSD) || defined(GPR_SOLARIS) || \
     defined(GPR_AIX) || defined(GPR_NACL) || defined(GPR_FUCHSIA) ||        \
     defined(GRPC_POSIX_SOCKET)
index 96c1d17..beccfd6 100644 (file)
@@ -28,11 +28,16 @@ struct grpc_slice_buffer;
 namespace grpc_event_engine {
 namespace experimental {
 
-// TODO(hork): stubbed out here, to be replaced with a real version in next PR.
+// TODO(nnoble): needs implementation
 class SliceBuffer {
  public:
   SliceBuffer() { abort(); }
   explicit SliceBuffer(grpc_slice_buffer*) { abort(); }
+
+  grpc_slice_buffer* RawSliceBuffer() { return slice_buffer_; }
+
+ private:
+  grpc_slice_buffer* slice_buffer_;
 };
 
 class SliceAllocator {
index 26f9df9..f52cb50 100644 (file)
@@ -21,6 +21,6 @@
 
 #include <grpc/support/port_platform.h>
 
-#include <grpc/impl/codegen/fork.h>
+#include <grpc/impl/codegen/fork.h>  // IWYU pragma: export
 
 #endif /* GRPC_FORK_H */
index 5e45b47..ee30ae1 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include <grpc/status.h>
+#include <stddef.h>
 
 #include <grpc/byte_buffer.h>
 #include <grpc/impl/codegen/connectivity_state.h>
 #include <grpc/impl/codegen/grpc_types.h>
 #include <grpc/impl/codegen/propagation_bits.h>
 #include <grpc/slice.h>
+#include <grpc/status.h>
 #include <grpc/support/time.h>
-#include <stddef.h>
 
 #ifdef __cplusplus
 extern "C" {
@@ -410,12 +410,18 @@ GRPCAPI void grpc_server_register_completion_queue(grpc_server* server,
                                                    grpc_completion_queue* cq,
                                                    void* reserved);
 
+// More members might be added in later, so users should take care to memset
+// this to 0 before using it.
+typedef struct {
+  grpc_status_code code;
+  const char* error_message;
+} grpc_serving_status_update;
+
 // There might be more methods added later, so users should take care to memset
 // this to 0 before using it.
 typedef struct {
   void (*on_serving_status_update)(void* user_data, const char* uri,
-                                   grpc_status_code code,
-                                   const char* error_message);
+                                   grpc_serving_status_update update);
   void* user_data;
 } grpc_server_xds_status_notifier;
 
index fbce5e1..4f1c8f5 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include <grpc/impl/codegen/grpc_types.h>
-
 #include <stddef.h>
 
+#include <grpc/impl/codegen/grpc_types.h>
+
 #ifdef __cplusplus
 extern "C" {
 #endif
@@ -48,6 +48,9 @@ GRPCAPI grpc_channel* grpc_insecure_channel_create_from_fd(
     grpc_server_register_completion_queue API).
 
     The 'reserved' pointer MUST be NULL.
+
+    TODO(hork): add channel_args to this API to allow endpoints and transports
+    created in this function to participate in the resource quota feature.
     */
 GRPCAPI void grpc_server_add_insecure_channel_from_fd(grpc_server* server,
                                                       void* reserved, int fd);
index 00d83f0..606369a 100644 (file)
@@ -19,6 +19,8 @@
 #ifndef GRPC_IMPL_CODEGEN_ATM_H
 #define GRPC_IMPL_CODEGEN_ATM_H
 
+// IWYU pragma: private, include <grpc/support/atm.h>
+
 /** This interface provides atomic operations and barriers.
    It is internal to gpr support code and should not be used outside it.
 
 #include <grpc/impl/codegen/port_platform.h>
 
 #if defined(GPR_GCC_ATOMIC)
-#include <grpc/impl/codegen/atm_gcc_atomic.h>
+#include <grpc/impl/codegen/atm_gcc_atomic.h>  // IWYU pragma: export
 #elif defined(GPR_GCC_SYNC)
-#include <grpc/impl/codegen/atm_gcc_sync.h>
+#include <grpc/impl/codegen/atm_gcc_sync.h>  // IWYU pragma: export
 #elif defined(GPR_WINDOWS_ATOMIC)
-#include <grpc/impl/codegen/atm_windows.h>
+#include <grpc/impl/codegen/atm_windows.h>  // IWYU pragma: export
 #else
 #error could not determine platform for atm
 #endif
index 5879708..05d6e42 100644 (file)
@@ -19,6 +19,8 @@
 #ifndef GRPC_IMPL_CODEGEN_ATM_GCC_ATOMIC_H
 #define GRPC_IMPL_CODEGEN_ATM_GCC_ATOMIC_H
 
+// IWYU pragma: private, include <grpc/support/atm.h>
+
 /* atm_platform.h for gcc and gcc-like compilers with the
    __atomic_* interface.  */
 #include <grpc/impl/codegen/port_platform.h>
index 728c3d5..bdc7a17 100644 (file)
@@ -19,6 +19,8 @@
 #ifndef GRPC_IMPL_CODEGEN_ATM_GCC_SYNC_H
 #define GRPC_IMPL_CODEGEN_ATM_GCC_SYNC_H
 
+// IWYU pragma: private, include <grpc/support/atm.h>
+
 /* variant of atm_platform.h for gcc and gcc-like compiers with __sync_*
    interface */
 #include <grpc/impl/codegen/port_platform.h>
index 36c76ab..816c9a9 100644 (file)
@@ -19,6 +19,8 @@
 #ifndef GRPC_IMPL_CODEGEN_ATM_WINDOWS_H
 #define GRPC_IMPL_CODEGEN_ATM_WINDOWS_H
 
+// IWYU pragma: private, include <grpc/support/atm.h>
+
 /** Win32 variant of atm_platform.h */
 #include <grpc/impl/codegen/port_platform.h>
 
index 0413729..eeec56c 100644 (file)
@@ -19,6 +19,8 @@
 #ifndef GRPC_IMPL_CODEGEN_BYTE_BUFFER_H
 #define GRPC_IMPL_CODEGEN_BYTE_BUFFER_H
 
+// IWYU pragma: private, include <grpc/byte_buffer.h>
+
 #include <grpc/impl/codegen/port_platform.h>
 
 #include <grpc/impl/codegen/grpc_types.h>
index e06e195..35b8ee7 100644 (file)
@@ -19,6 +19,8 @@
 #ifndef GRPC_IMPL_CODEGEN_BYTE_BUFFER_READER_H
 #define GRPC_IMPL_CODEGEN_BYTE_BUFFER_READER_H
 
+// IWYU pragma: private, include <grpc/byte_buffer_reader.h>
+
 #ifdef __cplusplus
 extern "C" {
 #endif
index f778b00..129310e 100644 (file)
@@ -19,6 +19,8 @@
 #ifndef GRPC_IMPL_CODEGEN_COMPRESSION_TYPES_H
 #define GRPC_IMPL_CODEGEN_COMPRESSION_TYPES_H
 
+// IWYU pragma: private
+
 #include <grpc/impl/codegen/port_platform.h>
 
 #ifdef __cplusplus
index b70dbef..52084da 100644 (file)
@@ -19,6 +19,8 @@
 #ifndef GRPC_IMPL_CODEGEN_CONNECTIVITY_STATE_H
 #define GRPC_IMPL_CODEGEN_CONNECTIVITY_STATE_H
 
+// IWYU pragma: private
+
 #ifdef __cplusplus
 extern "C" {
 #endif
index 555df34..6818b53 100644 (file)
@@ -19,6 +19,8 @@
 #ifndef GRPC_IMPL_CODEGEN_FORK_H
 #define GRPC_IMPL_CODEGEN_FORK_H
 
+// IWYU pragma: private, include <grpc/fork.h>
+
 /**
  * gRPC applications should call this before calling fork().  There should be no
  * active gRPC function calls between calling grpc_prefork() and
index 89fa72d..8782ba3 100644 (file)
@@ -18,6 +18,8 @@
 #ifndef GRPC_IMPL_CODEGEN_GPR_SLICE_H
 #define GRPC_IMPL_CODEGEN_GPR_SLICE_H
 
+// IWYU pragma: private
+
 /** WARNING: Please do not use this header. This was added as a temporary
  * measure to not break some of the external projects that depend on
  * gpr_slice_* functions. We are actively working on moving all the
index 6daf339..415bf7a 100644 (file)
@@ -19,6 +19,8 @@
 #ifndef GRPC_IMPL_CODEGEN_GPR_TYPES_H
 #define GRPC_IMPL_CODEGEN_GPR_TYPES_H
 
+// IWYU pragma: private
+
 #include <grpc/impl/codegen/port_platform.h>
 
 #include <stddef.h>
index 4f33acf..97ca3e4 100644 (file)
 #ifndef GRPC_IMPL_CODEGEN_GRPC_TYPES_H
 #define GRPC_IMPL_CODEGEN_GRPC_TYPES_H
 
+// IWYU pragma: private
+
 #include <grpc/impl/codegen/port_platform.h>
 
+#include <stddef.h>
+
 #include <grpc/impl/codegen/compression_types.h>
 #include <grpc/impl/codegen/gpr_types.h>
 #include <grpc/impl/codegen/slice.h>
 #include <grpc/impl/codegen/status.h>
 
-#include <stddef.h>
-
 #ifdef __cplusplus
 extern "C" {
 #endif
@@ -55,9 +57,6 @@ typedef struct grpc_byte_buffer {
  * asynchronous actions. */
 typedef struct grpc_completion_queue grpc_completion_queue;
 
-/** An alarm associated with a completion queue. */
-typedef struct grpc_alarm grpc_alarm;
-
 /** The Channel interface allows creation of Call objects. */
 typedef struct grpc_channel grpc_channel;
 
index 9dd3a51..1d5d2da 100644 (file)
@@ -19,6 +19,8 @@
 #ifndef GRPC_IMPL_CODEGEN_LOG_H
 #define GRPC_IMPL_CODEGEN_LOG_H
 
+// IWYU pragma: private, include <grpc/support/log.h>
+
 #include <grpc/impl/codegen/port_platform.h>
 
 #include <stdarg.h>
index 656f5d7..8b9831b 100644 (file)
@@ -19,6 +19,8 @@
 #ifndef GRPC_IMPL_CODEGEN_PORT_PLATFORM_H
 #define GRPC_IMPL_CODEGEN_PORT_PLATFORM_H
 
+// IWYU pragma: private, include <grpc/support/port_platform.h>
+
 /*
  * Define GPR_BACKWARDS_COMPATIBILITY_MODE to try harder to be ABI
  * compatible with older platforms (currently only on Linux)
  *  - some syscalls to be made directly
  */
 
+// [[deprecated]] attribute is only available since C++14
+#if __cplusplus >= 201402L
+#define GRPC_DEPRECATED(reason) [[deprecated(reason)]]
+#else
+#define GRPC_DEPRECATED(reason)
+#endif  // __cplusplus >= 201402L
+
 /*
  * Defines GPR_ABSEIL_SYNC to use synchronization features from Abseil
  */
 #else
 #define GPR_WINDOWS_ATOMIC 1
 #endif
-#define GPR_STDCPP_TLS 1
 #elif defined(ANDROID) || defined(__ANDROID__)
 #define GPR_PLATFORM_STRING "android"
 #define GPR_ANDROID 1
+#ifdef __ANDROID_API__
+#if (__ANDROID_API__) >= 29
+#define GPR_SUPPORT_BINDER_TRANSPORT 1
+#endif
+#endif
 // TODO(apolcyn): re-evaluate support for c-ares
 // on android after upgrading our c-ares dependency.
 // See https://github.com/grpc/grpc/issues/18038.
 #endif /* _LP64 */
 #define GPR_CPU_POSIX 1
 #define GPR_GCC_SYNC 1
-#define GPR_STDCPP_TLS 1
 #define GPR_POSIX_ENV 1
 #define GPR_POSIX_TMPFILE 1
 #define GPR_POSIX_STAT 1
 #include <features.h>
 #define GPR_CPU_LINUX 1
 #define GPR_GCC_ATOMIC 1
-#define GPR_STDCPP_TLS 1
 #define GPR_LINUX 1
 #define GPR_LINUX_LOG
 #define GPR_SUPPORT_CHANNELS_FROM_FD 1
 #elif defined(__ASYLO__)
 #define GPR_ARCH_64 1
 #define GPR_CPU_POSIX 1
-#define GPR_GCC_TLS 1
 #define GPR_PLATFORM_STRING "asylo"
 #define GPR_GCC_SYNC 1
 #define GPR_POSIX_SYNC 1
 #define GPR_CPU_POSIX 1
 #define GPR_POSIX_CRASH_HANDLER 1
 #endif
-#ifdef __has_feature
-#if __has_feature(cxx_thread_local)
-#define GPR_STDCPP_TLS 1
-#endif
-#endif
-#ifndef GPR_STDCPP_TLS
+#if !(defined(__has_feature) && __has_feature(cxx_thread_local))
 #define GPR_PTHREAD_TLS 1
 #endif
 #define GPR_APPLE 1
 #define GPR_FREEBSD 1
 #define GPR_CPU_POSIX 1
 #define GPR_GCC_ATOMIC 1
-#define GPR_GCC_TLS 1
 #define GPR_POSIX_LOG 1
 #define GPR_POSIX_ENV 1
 #define GPR_POSIX_TMPFILE 1
 #define GPR_OPENBSD 1
 #define GPR_CPU_POSIX 1
 #define GPR_GCC_ATOMIC 1
-#define GPR_GCC_TLS 1
 #define GPR_POSIX_LOG 1
 #define GPR_POSIX_ENV 1
 #define GPR_POSIX_TMPFILE 1
 #define GPR_SOLARIS 1
 #define GPR_CPU_POSIX 1
 #define GPR_GCC_ATOMIC 1
-#define GPR_GCC_TLS 1
 #define GPR_POSIX_LOG 1
 #define GPR_POSIX_ENV 1
 #define GPR_POSIX_TMPFILE 1
 #define GPR_AIX 1
 #define GPR_CPU_POSIX 1
 #define GPR_GCC_ATOMIC 1
-#define GPR_GCC_TLS 1
 #define GPR_POSIX_LOG 1
 #define GPR_POSIX_ENV 1
 #define GPR_POSIX_TMPFILE 1
 #define GPR_NACL 1
 #define GPR_CPU_POSIX 1
 #define GPR_GCC_ATOMIC 1
-#define GPR_GCC_TLS 1
 #define GPR_POSIX_LOG 1
 #define GPR_POSIX_ENV 1
 #define GPR_POSIX_TMPFILE 1
 #define GPR_MUSL_LIBC_COMPAT 1
 #define GPR_CPU_POSIX 1
 #define GPR_GCC_ATOMIC 1
-#define GPR_PTHREAD_TLS 1
 #define GPR_POSIX_LOG 1
 #define GPR_POSIX_SYNC 1
 #define GPR_POSIX_ENV 1
@@ -498,12 +497,6 @@ typedef unsigned __int64 uint64_t;
 #error Must define exactly one of GPR_CPU_LINUX, GPR_CPU_POSIX, GPR_WINDOWS, GPR_CPU_IPHONE, GPR_CPU_CUSTOM
 #endif
 
-#if defined(GPR_MSVC_TLS) + defined(GPR_GCC_TLS) + defined(GPR_PTHREAD_TLS) + \
-        defined(GPR_STDCPP_TLS) + defined(GPR_CUSTOM_TLS) !=                  \
-    1
-#error Must define exactly one of GPR_MSVC_TLS, GPR_GCC_TLS, GPR_PTHREAD_TLS, GPR_STDCPP_TLS, GPR_CUSTOM_TLS
-#endif
-
 /* maximum alignment needed for any type on this platform, rounded up to a
    power of two */
 #define GPR_MAX_ALIGNMENT 16
@@ -705,4 +698,15 @@ typedef unsigned __int64 uint64_t;
 
 #define GRPC_CALLBACK_API_NONEXPERIMENTAL
 
+/* clang 11 with msan miscompiles destruction of [[no_unique_address]] members
+ * of zero size - for a repro see:
+ * test/core/compiler_bugs/miscompile_with_no_unique_address_test.cc
+ */
+#ifdef __clang__
+#if __clang__ && __clang_major__ <= 11 && __has_feature(memory_sanitizer)
+#undef GPR_NO_UNIQUE_ADDRESS
+#define GPR_NO_UNIQUE_ADDRESS
+#endif
+#endif
+
 #endif /* GRPC_IMPL_CODEGEN_PORT_PLATFORM_H */
index 824bdbd..d702099 100644 (file)
@@ -19,6 +19,8 @@
 #ifndef GRPC_IMPL_CODEGEN_PROPAGATION_BITS_H
 #define GRPC_IMPL_CODEGEN_PROPAGATION_BITS_H
 
+// IWYU pragma: private
+
 #include <grpc/impl/codegen/port_platform.h>
 
 #ifdef __cplusplus
index 3567b1e..4412058 100644 (file)
@@ -19,6 +19,8 @@
 #ifndef GRPC_IMPL_CODEGEN_SLICE_H
 #define GRPC_IMPL_CODEGEN_SLICE_H
 
+// IWYU pragma: private, include <grpc/slice.h>
+
 #include <grpc/impl/codegen/port_platform.h>
 
 #include <stddef.h>
index dec3b8f..2b18f6d 100644 (file)
@@ -19,6 +19,8 @@
 #ifndef GRPC_IMPL_CODEGEN_STATUS_H
 #define GRPC_IMPL_CODEGEN_STATUS_H
 
+// IWYU pragma: private, include <grpc/status.h>
+
 #ifdef __cplusplus
 extern "C" {
 #endif
index 49e3194..1b30ea7 100644 (file)
@@ -18,6 +18,9 @@
 
 #ifndef GRPC_IMPL_CODEGEN_SYNC_H
 #define GRPC_IMPL_CODEGEN_SYNC_H
+
+// IWYU pragma: private, include <grpc/support/sync.h>
+
 /** Synchronization primitives for GPR.
 
    The type  gpr_mu              provides a non-reentrant mutex (lock).
@@ -44,16 +47,16 @@ extern "C" {
 /* Platform-specific type declarations of gpr_mu and gpr_cv.   */
 #include <grpc/impl/codegen/port_platform.h>
 
-#include <grpc/impl/codegen/sync_generic.h>
+#include <grpc/impl/codegen/sync_generic.h>  // IWYU pragma: export
 
 #if defined(GPR_CUSTOM_SYNC)
-#include <grpc/impl/codegen/sync_custom.h>
+#include <grpc/impl/codegen/sync_custom.h>  // IWYU pragma: export
 #elif defined(GPR_ABSEIL_SYNC)
-#include <grpc/impl/codegen/sync_abseil.h>
+#include <grpc/impl/codegen/sync_abseil.h>  // IWYU pragma: export
 #elif defined(GPR_POSIX_SYNC)
-#include <grpc/impl/codegen/sync_posix.h>
+#include <grpc/impl/codegen/sync_posix.h>  // IWYU pragma: export
 #elif defined(GPR_WINDOWS)
-#include <grpc/impl/codegen/sync_windows.h>
+#include <grpc/impl/codegen/sync_windows.h>  // IWYU pragma: export
 #else
 #error Unable to determine platform for sync
 #endif
index 38dfab3..92b3169 100644 (file)
@@ -19,6 +19,8 @@
 #ifndef GRPC_IMPL_CODEGEN_SYNC_ABSEIL_H
 #define GRPC_IMPL_CODEGEN_SYNC_ABSEIL_H
 
+// IWYU pragma: private, include <grpc/support/sync.h>
+
 #include <grpc/impl/codegen/port_platform.h>
 
 #include <grpc/impl/codegen/sync_generic.h>
index 69b1bf6..ec0d672 100644 (file)
@@ -19,6 +19,8 @@
 #ifndef GRPC_IMPL_CODEGEN_SYNC_CUSTOM_H
 #define GRPC_IMPL_CODEGEN_SYNC_CUSTOM_H
 
+// IWYU pragma: private, include <grpc/support/sync.h>
+
 #include <grpc/impl/codegen/port_platform.h>
 
 #include <grpc/impl/codegen/sync_generic.h>
index eabdc51..a79b9c6 100644 (file)
@@ -18,6 +18,9 @@
 
 #ifndef GRPC_IMPL_CODEGEN_SYNC_GENERIC_H
 #define GRPC_IMPL_CODEGEN_SYNC_GENERIC_H
+
+// IWYU pragma: private, include <grpc/support/sync.h>
+
 /* Generic type definitions for gpr_sync. */
 
 #include <grpc/impl/codegen/port_platform.h>
index 2aec3a3..f5cf482 100644 (file)
 #ifndef GRPC_IMPL_CODEGEN_SYNC_POSIX_H
 #define GRPC_IMPL_CODEGEN_SYNC_POSIX_H
 
-#include <grpc/impl/codegen/port_platform.h>
+// IWYU pragma: private, include <grpc/support/sync.h>
 
-#include <grpc/impl/codegen/sync_generic.h>
+#include <grpc/impl/codegen/port_platform.h>
 
 #include <pthread.h>
 
+#include <grpc/impl/codegen/sync_generic.h>
+
 #ifdef GRPC_ASAN_ENABLED
 /* The member |leak_checker| is used to check whether there is a memory leak
  * caused by upper layer logic that's missing the |gpr_xx_destroy| call
index f2ff83b..2bee03b 100644 (file)
@@ -19,6 +19,8 @@
 #ifndef GRPC_IMPL_CODEGEN_SYNC_WINDOWS_H
 #define GRPC_IMPL_CODEGEN_SYNC_WINDOWS_H
 
+// IWYU pragma: private, include <grpc/support/sync.h>
+
 #include <grpc/impl/codegen/port_platform.h>
 
 #ifdef GPR_WINDOWS
index 51fc62b..65d2087 100644 (file)
@@ -21,7 +21,7 @@
 
 #include <grpc/support/port_platform.h>
 
-#include <grpc/impl/codegen/slice.h>
+#include <grpc/impl/codegen/slice.h>  // IWYU pragma: export
 #include <grpc/support/sync.h>
 
 #ifdef __cplusplus
index ecb9668..6763264 100644 (file)
@@ -21,6 +21,6 @@
 
 #include <grpc/support/port_platform.h>
 
-#include <grpc/impl/codegen/status.h>
+#include <grpc/impl/codegen/status.h>  // IWYU pragma: export
 
 #endif /* GRPC_STATUS_H */
index 073b0a6..fbfcee3 100644 (file)
@@ -21,6 +21,6 @@
 
 #include <grpc/support/port_platform.h>
 
-#include <grpc/impl/codegen/atm.h>
+#include <grpc/impl/codegen/atm.h>  // IWYU pragma: export
 
 #endif /* GRPC_SUPPORT_ATM_H */
index ae603db..8226349 100644 (file)
@@ -21,6 +21,6 @@
 
 #include <grpc/support/port_platform.h>
 
-#include <grpc/impl/codegen/atm_gcc_atomic.h>
+#include <grpc/impl/codegen/atm_gcc_atomic.h>  // IWYU pragma: export
 
 #endif /* GRPC_SUPPORT_ATM_GCC_ATOMIC_H */
index 6f51fdb..500a9f1 100644 (file)
@@ -21,6 +21,6 @@
 
 #include <grpc/support/port_platform.h>
 
-#include <grpc/impl/codegen/atm_gcc_sync.h>
+#include <grpc/impl/codegen/atm_gcc_sync.h>  // IWYU pragma: export
 
 #endif /* GRPC_SUPPORT_ATM_GCC_SYNC_H */
index 36955e4..b85d7f7 100644 (file)
@@ -21,6 +21,6 @@
 
 #include <grpc/support/port_platform.h>
 
-#include <grpc/impl/codegen/atm_windows.h>
+#include <grpc/impl/codegen/atm_windows.h>  // IWYU pragma: export
 
 #endif /* GRPC_SUPPORT_ATM_WINDOWS_H */
index 8d8742b..7af557d 100644 (file)
@@ -21,6 +21,6 @@
 
 #include <grpc/support/port_platform.h>
 
-#include <grpc/impl/codegen/log.h>
+#include <grpc/impl/codegen/log.h>  // IWYU pragma: export
 
 #endif /* GRPC_SUPPORT_LOG_H */
index 26025dc..fced02a 100644 (file)
@@ -19,6 +19,6 @@
 #ifndef GRPC_SUPPORT_PORT_PLATFORM_H
 #define GRPC_SUPPORT_PORT_PLATFORM_H
 
-#include <grpc/impl/codegen/port_platform.h>
+#include <grpc/impl/codegen/port_platform.h>  // IWYU pragma: export
 
 #endif /* GRPC_SUPPORT_PORT_PLATFORM_H */
index f617322..b1f5b78 100644 (file)
@@ -22,7 +22,7 @@
 #include <grpc/support/port_platform.h>
 
 #include <grpc/impl/codegen/gpr_types.h> /* for gpr_timespec */
-#include <grpc/impl/codegen/sync.h>
+#include <grpc/impl/codegen/sync.h>      // IWYU pragma: export
 
 #ifdef __cplusplus
 extern "C" {
index 3ee7348..d6ad969 100644 (file)
@@ -21,6 +21,6 @@
 
 #include <grpc/support/port_platform.h>
 
-#include <grpc/impl/codegen/sync_abseil.h>
+#include <grpc/impl/codegen/sync_abseil.h>  // IWYU pragma: export
 
 #endif /* GRPC_SUPPORT_SYNC_ABSEIL_H */
index 27cf0e0..de7e220 100644 (file)
@@ -21,6 +21,6 @@
 
 #include <grpc/support/port_platform.h>
 
-#include <grpc/impl/codegen/sync_custom.h>
+#include <grpc/impl/codegen/sync_custom.h>  // IWYU pragma: export
 
 #endif /* GRPC_SUPPORT_SYNC_CUSTOM_H */
index 93028c4..d1d9fd7 100644 (file)
@@ -21,6 +21,6 @@
 
 #include <grpc/support/port_platform.h>
 
-#include <grpc/impl/codegen/sync_generic.h>
+#include <grpc/impl/codegen/sync_generic.h>  // IWYU pragma: export
 
 #endif /* GRPC_SUPPORT_SYNC_GENERIC_H */
index 3dce7ee..b971cd1 100644 (file)
@@ -21,6 +21,6 @@
 
 #include <grpc/support/port_platform.h>
 
-#include <grpc/impl/codegen/sync_posix.h>
+#include <grpc/impl/codegen/sync_posix.h>  // IWYU pragma: export
 
 #endif /* GRPC_SUPPORT_SYNC_POSIX_H */
index a493c86..3ee4a6f 100644 (file)
@@ -21,6 +21,6 @@
 
 #include <grpc/support/port_platform.h>
 
-#include <grpc/impl/codegen/sync_windows.h>
+#include <grpc/impl/codegen/sync_windows.h>  // IWYU pragma: export
 
 #endif /* GRPC_SUPPORT_SYNC_WINDOWS_H */
index 44aead5..a193dbc 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include <grpc/impl/codegen/gpr_types.h>
-
 #include <stddef.h>
 #include <time.h>
 
+#include <grpc/impl/codegen/gpr_types.h>
+
 #ifdef __cplusplus
 extern "C" {
 #endif
index 1994fcc..74a91e2 100644 (file)
@@ -34,6 +34,6 @@
 #ifndef GRPCPP_CLIENT_CONTEXT_H
 #define GRPCPP_CLIENT_CONTEXT_H
 
-#include <grpcpp/impl/codegen/client_context.h>
+#include <grpcpp/impl/codegen/client_context.h>  // IWYU pragma: export
 
 #endif  // GRPCPP_CLIENT_CONTEXT_H
index 123b277..42637b5 100644 (file)
@@ -19,6 +19,6 @@
 #ifndef GRPCPP_COMPLETION_QUEUE_H
 #define GRPCPP_COMPLETION_QUEUE_H
 
-#include <grpcpp/impl/codegen/completion_queue.h>
+#include <grpcpp/impl/codegen/completion_queue.h>  // IWYU pragma: export
 
 #endif  // GRPCPP_COMPLETION_QUEUE_H
index 8c34330..e6019d2 100644 (file)
 #ifndef GRPCPP_CREATE_CHANNEL_POSIX_H
 #define GRPCPP_CREATE_CHANNEL_POSIX_H
 
+#include <grpc/support/port_platform.h>
+
 #include <memory>
 
-#include <grpc/support/port_platform.h>
 #include <grpcpp/channel.h>
 #include <grpcpp/support/channel_arguments.h>
 
index 2c67edc..01c7942 100644 (file)
@@ -19,6 +19,6 @@
 #ifndef GRPCPP_GENERIC_ASYNC_GENERIC_SERVICE_H
 #define GRPCPP_GENERIC_ASYNC_GENERIC_SERVICE_H
 
-#include <grpcpp/impl/codegen/async_generic_service.h>
+#include <grpcpp/impl/codegen/async_generic_service.h>  // IWYU pragma: export
 
 #endif  // GRPCPP_GENERIC_ASYNC_GENERIC_SERVICE_H
index 8912f99..9d707e2 100644 (file)
@@ -49,7 +49,6 @@
 // headers are not private for grpcpp.h and are part of its interface.
 // IWYU pragma: begin_exports
 #include <grpc/grpc.h>
-
 #include <grpcpp/channel.h>
 #include <grpcpp/client_context.h>
 #include <grpcpp/completion_queue.h>
index a6b1312..97d8fdf 100644 (file)
@@ -19,6 +19,6 @@
 #ifndef GRPCPP_IMPL_CALL_H
 #define GRPCPP_IMPL_CALL_H
 
-#include <grpcpp/impl/codegen/call.h>
+#include <grpcpp/impl/codegen/call.h>  // IWYU pragma: export
 
 #endif  // GRPCPP_IMPL_CALL_H
index 378482c..7ecf354 100644 (file)
@@ -19,6 +19,6 @@
 #ifndef GRPCPP_IMPL_CLIENT_UNARY_CALL_H
 #define GRPCPP_IMPL_CLIENT_UNARY_CALL_H
 
-#include <grpcpp/impl/codegen/client_unary_call.h>
+#include <grpcpp/impl/codegen/client_unary_call.h>  // IWYU pragma: export
 
 #endif  // GRPCPP_IMPL_CLIENT_UNARY_CALL_H
index 6cdd514..5a0f246 100644 (file)
@@ -19,6 +19,8 @@
 #ifndef GRPCPP_IMPL_CODEGEN_ASYNC_GENERIC_SERVICE_H
 #define GRPCPP_IMPL_CODEGEN_ASYNC_GENERIC_SERVICE_H
 
+// IWYU pragma: private, include <grpcpp/generic/async_generic_service.h>
+
 #include <grpc/impl/codegen/port_platform.h>
 
 #include <grpcpp/impl/codegen/async_stream.h>
index aaee93d..db5b374 100644 (file)
@@ -18,6 +18,8 @@
 #ifndef GRPCPP_IMPL_CODEGEN_ASYNC_STREAM_H
 #define GRPCPP_IMPL_CODEGEN_ASYNC_STREAM_H
 
+// IWYU pragma: private, include <grpcpp/support/async_stream.h>
+
 #include <grpcpp/impl/codegen/call.h>
 #include <grpcpp/impl/codegen/channel_interface.h>
 #include <grpcpp/impl/codegen/core_codegen_interface.h>
index 7cb7cc6..d7a3b57 100644 (file)
@@ -19,6 +19,8 @@
 #ifndef GRPCPP_IMPL_CODEGEN_ASYNC_UNARY_CALL_H
 #define GRPCPP_IMPL_CODEGEN_ASYNC_UNARY_CALL_H
 
+// IWYU pragma: private, include <grpcpp/support/async_unary_call.h>
+
 #include <grpcpp/impl/codegen/call.h>
 #include <grpcpp/impl/codegen/call_op_set.h>
 #include <grpcpp/impl/codegen/call_op_set_interface.h>
index 6959fa2..d94ac3b 100644 (file)
 #ifndef GRPCPP_IMPL_CODEGEN_BYTE_BUFFER_H
 #define GRPCPP_IMPL_CODEGEN_BYTE_BUFFER_H
 
-#include <grpc/impl/codegen/byte_buffer.h>
+// IWYU pragma: private, include <grpcpp/support/byte_buffer.h>
+
+#include <vector>
 
+#include <grpc/impl/codegen/byte_buffer.h>
 #include <grpcpp/impl/codegen/config.h>
 #include <grpcpp/impl/codegen/core_codegen_interface.h>
 #include <grpcpp/impl/codegen/serialization_traits.h>
 #include <grpcpp/impl/codegen/slice.h>
 #include <grpcpp/impl/codegen/status.h>
 
-#include <vector>
-
 namespace grpc {
 
 class ServerInterface;
index b229286..96d0de5 100644 (file)
@@ -18,6 +18,8 @@
 #ifndef GRPCPP_IMPL_CODEGEN_CALL_H
 #define GRPCPP_IMPL_CODEGEN_CALL_H
 
+// IWYU pragma: private, include <grpcpp/impl/call.h>
+
 #include <grpc/impl/codegen/grpc_types.h>
 #include <grpcpp/impl/codegen/call_hook.h>
 
index 4f7d370..8c4278e 100644 (file)
@@ -19,6 +19,8 @@
 #ifndef GRPCPP_IMPL_CODEGEN_CALL_HOOK_H
 #define GRPCPP_IMPL_CODEGEN_CALL_HOOK_H
 
+// IWYU pragma: private
+
 namespace grpc {
 
 namespace internal {
index 7fde1ed..30b36c2 100644 (file)
@@ -19,6 +19,8 @@
 #ifndef GRPCPP_IMPL_CODEGEN_CALL_OP_SET_H
 #define GRPCPP_IMPL_CODEGEN_CALL_OP_SET_H
 
+// IWYU pragma: private
+
 #include <cstring>
 #include <map>
 #include <memory>
index 3b74566..a8eed9f 100644 (file)
@@ -19,6 +19,8 @@
 #ifndef GRPCPP_IMPL_CODEGEN_CALL_OP_SET_INTERFACE_H
 #define GRPCPP_IMPL_CODEGEN_CALL_OP_SET_INTERFACE_H
 
+// IWYU pragma: private
+
 #include <grpcpp/impl/codegen/completion_queue_tag.h>
 
 namespace grpc {
index d670786..7c67c92 100644 (file)
@@ -19,6 +19,8 @@
 #ifndef GRPCPP_IMPL_CODEGEN_CALLBACK_COMMON_H
 #define GRPCPP_IMPL_CODEGEN_CALLBACK_COMMON_H
 
+// IWYU pragma: private
+
 #include <functional>
 
 #include <grpc/impl/codegen/grpc_types.h>
index ac82e2f..4a60cd9 100644 (file)
@@ -19,6 +19,8 @@
 #ifndef GRPCPP_IMPL_CODEGEN_CHANNEL_INTERFACE_H
 #define GRPCPP_IMPL_CODEGEN_CHANNEL_INTERFACE_H
 
+// IWYU pragma: private
+
 #include <grpc/impl/codegen/connectivity_state.h>
 #include <grpcpp/impl/codegen/call.h>
 #include <grpcpp/impl/codegen/status.h>
index dea0cae..f16cd9f 100644 (file)
@@ -17,6 +17,9 @@
 
 #ifndef GRPCPP_IMPL_CODEGEN_CLIENT_CALLBACK_H
 #define GRPCPP_IMPL_CODEGEN_CLIENT_CALLBACK_H
+
+// IWYU pragma: private, include <grpcpp/support/client_callback.h>
+
 #include <atomic>
 #include <functional>
 
index 761259c..5c5e065 100644 (file)
@@ -34,6 +34,8 @@
 #ifndef GRPCPP_IMPL_CODEGEN_CLIENT_CONTEXT_H
 #define GRPCPP_IMPL_CODEGEN_CLIENT_CONTEXT_H
 
+// IWYU pragma: private, include <grpcpp/client_context.h>
+
 #include <map>
 #include <memory>
 #include <string>
index ec78074..f3560b5 100644 (file)
@@ -19,6 +19,8 @@
 #ifndef GRPCPP_IMPL_CODEGEN_CLIENT_INTERCEPTOR_H
 #define GRPCPP_IMPL_CODEGEN_CLIENT_INTERCEPTOR_H
 
+// IWYU pragma: private, include <grpcpp/support/client_interceptor.h>
+
 #include <memory>
 #include <vector>
 
index d41ea1a..bad60a2 100644 (file)
@@ -19,6 +19,8 @@
 #ifndef GRPCPP_IMPL_CODEGEN_CLIENT_UNARY_CALL_H
 #define GRPCPP_IMPL_CODEGEN_CLIENT_UNARY_CALL_H
 
+// IWYU pragma: private, include <grpcpp/impl/client_unary_call.h>
+
 #include <grpcpp/impl/codegen/call.h>
 #include <grpcpp/impl/codegen/call_op_set.h>
 #include <grpcpp/impl/codegen/channel_interface.h>
index 654ff1c..ef0c7f1 100644 (file)
@@ -32,6 +32,8 @@
 #ifndef GRPCPP_IMPL_CODEGEN_COMPLETION_QUEUE_H
 #define GRPCPP_IMPL_CODEGEN_COMPLETION_QUEUE_H
 
+// IWYU pragma: private, include <grpcpp/completion_queue.h>
+
 #include <list>
 
 #include <grpc/impl/codegen/atm.h>
@@ -175,9 +177,14 @@ class CompletionQueue : private ::grpc::GrpcLibraryCodegen {
   /// \return true if got an event, false if the queue is fully drained and
   ///         shut down.
   bool Next(void** tag, bool* ok) {
+    // Check return type == GOT_EVENT... cases:
+    // SHUTDOWN  - queue has been shutdown, return false.
+    // TIMEOUT   - we passed infinity time => queue has been shutdown, return
+    //             false.
+    // GOT_EVENT - we actually got an event, return true.
     return (AsyncNextInternal(tag, ok,
                               ::grpc::g_core_codegen_interface->gpr_inf_future(
-                                  GPR_CLOCK_REALTIME)) != SHUTDOWN);
+                                  GPR_CLOCK_REALTIME)) == GOT_EVENT);
   }
 
   /// Read from the queue, blocking up to \a deadline (or the queue's shutdown).
index 304386a..9af470b 100644 (file)
@@ -19,6 +19,8 @@
 #ifndef GRPCPP_IMPL_CODEGEN_COMPLETION_QUEUE_TAG_H
 #define GRPCPP_IMPL_CODEGEN_COMPLETION_QUEUE_TAG_H
 
+// IWYU pragma: private
+
 namespace grpc {
 
 namespace internal {
index 0a8a9c1..d810cfa 100644 (file)
@@ -19,6 +19,8 @@
 #ifndef GRPCPP_IMPL_CODEGEN_CONFIG_H
 #define GRPCPP_IMPL_CODEGEN_CONFIG_H
 
+// IWYU pragma: private, include <grpcpp/support/config.h>
+
 #include <string>
 
 /// The following macros are deprecated and appear only for users
index 49db4c5..da874c5 100644 (file)
@@ -19,6 +19,8 @@
 #ifndef GRPCPP_IMPL_CODEGEN_CONFIG_PROTOBUF_H
 #define GRPCPP_IMPL_CODEGEN_CONFIG_PROTOBUF_H
 
+// IWYU pragma: private
+
 #define GRPC_OPEN_SOURCE_PROTO
 
 #ifndef GRPC_CUSTOM_MESSAGE
index df2a03c..0cefdb5 100644 (file)
@@ -19,6 +19,8 @@
 #ifndef GRPCPP_IMPL_CODEGEN_CORE_CODEGEN_H
 #define GRPCPP_IMPL_CODEGEN_CORE_CODEGEN_H
 
+// IWYU pragma: private
+
 // This file should be compiled as part of grpcpp.
 
 #include <grpc/byte_buffer.h>
index c08cf6c..edbeee2 100644 (file)
@@ -19,6 +19,8 @@
 #ifndef GRPCPP_IMPL_CODEGEN_CORE_CODEGEN_INTERFACE_H
 #define GRPCPP_IMPL_CODEGEN_CORE_CODEGEN_INTERFACE_H
 
+// IWYU pragma: private
+
 #include <grpc/impl/codegen/byte_buffer.h>
 #include <grpc/impl/codegen/byte_buffer_reader.h>
 #include <grpc/impl/codegen/grpc_types.h>
index cb6095c..817988f 100644 (file)
@@ -19,6 +19,8 @@
 #ifndef GRPCPP_IMPL_CODEGEN_CREATE_AUTH_CONTEXT_H
 #define GRPCPP_IMPL_CODEGEN_CREATE_AUTH_CONTEXT_H
 
+// IWYU pragma: private
+
 #include <memory>
 
 #include <grpc/impl/codegen/grpc_types.h>
index 0479567..f4f6794 100644 (file)
@@ -19,6 +19,8 @@
 #ifndef GRPCPP_IMPL_CODEGEN_DELEGATING_CHANNEL_H
 #define GRPCPP_IMPL_CODEGEN_DELEGATING_CHANNEL_H
 
+// IWYU pragma: private
+
 #include <memory>
 
 #include <grpcpp/impl/codegen/channel_interface.h>
index 660d6d0..9f83a7f 100644 (file)
@@ -19,6 +19,8 @@
 #ifndef GRPCPP_IMPL_CODEGEN_GRPC_LIBRARY_H
 #define GRPCPP_IMPL_CODEGEN_GRPC_LIBRARY_H
 
+// IWYU pragma: private, include <grpcpp/impl/grpc_library.h>
+
 #include <grpcpp/impl/codegen/core_codegen_interface.h>
 
 namespace grpc {
index e3a4c8e..d3df6ca 100644 (file)
@@ -19,6 +19,8 @@
 #ifndef GRPCPP_IMPL_CODEGEN_INTERCEPTED_CHANNEL_H
 #define GRPCPP_IMPL_CODEGEN_INTERCEPTED_CHANNEL_H
 
+// IWYU pragma: private
+
 #include <grpcpp/impl/codegen/channel_interface.h>
 
 namespace grpc {
index 58fb36c..8faea76 100644 (file)
@@ -19,6 +19,8 @@
 #ifndef GRPCPP_IMPL_CODEGEN_INTERCEPTOR_H
 #define GRPCPP_IMPL_CODEGEN_INTERCEPTOR_H
 
+// IWYU pragma: private, include <grpcpp/support/interceptor.h>
+
 #include <memory>
 
 #include <grpc/impl/codegen/grpc_types.h>
index b9a6ede..b084b7c 100644 (file)
 #ifndef GRPCPP_IMPL_CODEGEN_INTERCEPTOR_COMMON_H
 #define GRPCPP_IMPL_CODEGEN_INTERCEPTOR_COMMON_H
 
+// IWYU pragma: private
+
 #include <array>
 #include <functional>
 
+#include <grpc/impl/codegen/grpc_types.h>
 #include <grpcpp/impl/codegen/call.h>
 #include <grpcpp/impl/codegen/call_op_set_interface.h>
 #include <grpcpp/impl/codegen/client_interceptor.h>
 #include <grpcpp/impl/codegen/intercepted_channel.h>
 #include <grpcpp/impl/codegen/server_interceptor.h>
 
-#include <grpc/impl/codegen/grpc_types.h>
-
 namespace grpc {
 namespace internal {
 
index 23b990e..440c7f1 100644 (file)
@@ -19,6 +19,8 @@
 #ifndef GRPCPP_IMPL_CODEGEN_MESSAGE_ALLOCATOR_H
 #define GRPCPP_IMPL_CODEGEN_MESSAGE_ALLOCATOR_H
 
+// IWYU pragma: private, include <grpcpp/support/message_allocator.h>
+
 namespace grpc {
 
 // NOTE: This is an API for advanced users who need custom allocators.
index 9b9957b..931d682 100644 (file)
@@ -19,6 +19,8 @@
 #ifndef GRPCPP_IMPL_CODEGEN_METADATA_MAP_H
 #define GRPCPP_IMPL_CODEGEN_METADATA_MAP_H
 
+// IWYU pragma: private
+
 #include <map>
 
 #include <grpc/impl/codegen/log.h>
index fb093f5..b02a427 100644 (file)
@@ -19,6 +19,8 @@
 #ifndef GRPCPP_IMPL_CODEGEN_METHOD_HANDLER_H
 #define GRPCPP_IMPL_CODEGEN_METHOD_HANDLER_H
 
+// IWYU pragma: private, include <grpcpp/support/method_handler.h>
+
 #include <grpcpp/impl/codegen/byte_buffer.h>
 #include <grpcpp/impl/codegen/core_codegen_interface.h>
 #include <grpcpp/impl/codegen/rpc_service_method.h>
index cc88a13..3f1d573 100644 (file)
@@ -19,4 +19,6 @@
 #ifndef GRPCPP_IMPL_CODEGEN_METHOD_HANDLER_IMPL_H
 #define GRPCPP_IMPL_CODEGEN_METHOD_HANDLER_IMPL_H
 
+// IWYU pragma: private
+
 #endif  // GRPCPP_IMPL_CODEGEN_METHOD_HANDLER_IMPL_H
index d25b79a..d3baa2c 100644 (file)
@@ -19,6 +19,8 @@
 #ifndef GRPCPP_IMPL_CODEGEN_PROTO_BUFFER_READER_H
 #define GRPCPP_IMPL_CODEGEN_PROTO_BUFFER_READER_H
 
+// IWYU pragma: private, include <grpcpp/support/proto_buffer_reader.h>
+
 #include <type_traits>
 
 #include <grpc/impl/codegen/byte_buffer_reader.h>
index cd9d70c..a4752a4 100644 (file)
@@ -19,6 +19,8 @@
 #ifndef GRPCPP_IMPL_CODEGEN_PROTO_BUFFER_WRITER_H
 #define GRPCPP_IMPL_CODEGEN_PROTO_BUFFER_WRITER_H
 
+// IWYU pragma: private, include <grpcpp/support/proto_buffer_writer.h>
+
 #include <type_traits>
 
 #include <grpc/impl/codegen/grpc_types.h>
index 7f5c6e9..4f6d874 100644 (file)
@@ -19,6 +19,8 @@
 #ifndef GRPCPP_IMPL_CODEGEN_PROTO_UTILS_H
 #define GRPCPP_IMPL_CODEGEN_PROTO_UTILS_H
 
+// IWYU pragma: private
+
 #include <type_traits>
 
 #include <grpc/impl/codegen/byte_buffer_reader.h>
index 388784e..83dedda 100644 (file)
@@ -19,6 +19,8 @@
 #ifndef GRPCPP_IMPL_CODEGEN_RPC_METHOD_H
 #define GRPCPP_IMPL_CODEGEN_RPC_METHOD_H
 
+// IWYU pragma: private, include <grpcpp/impl/rpc_method.h>
+
 #include <memory>
 
 #include <grpcpp/impl/codegen/channel_interface.h>
index 4fcc211..f34cc8b 100644 (file)
@@ -19,6 +19,8 @@
 #ifndef GRPCPP_IMPL_CODEGEN_RPC_SERVICE_METHOD_H
 #define GRPCPP_IMPL_CODEGEN_RPC_SERVICE_METHOD_H
 
+// IWYU pragma: private, include <grpcpp/impl/rpc_service_method.h>
+
 #include <climits>
 #include <functional>
 #include <map>
index cea6dbe..d834ec1 100644 (file)
@@ -19,6 +19,8 @@
 #ifndef GRPCPP_IMPL_CODEGEN_SECURITY_AUTH_CONTEXT_H
 #define GRPCPP_IMPL_CODEGEN_SECURITY_AUTH_CONTEXT_H
 
+// IWYU pragma: private, include <grpcpp/security/auth_context.h>
+
 #include <iterator>
 #include <vector>
 
index 8f79223..3148dff 100644 (file)
@@ -19,6 +19,8 @@
 #ifndef GRPCPP_IMPL_CODEGEN_SERIALIZATION_TRAITS_H
 #define GRPCPP_IMPL_CODEGEN_SERIALIZATION_TRAITS_H
 
+// IWYU pragma: private, include <grpcpp/impl/serialization_traits.h>
+
 namespace grpc {
 
 /// Defines how to serialize and deserialize some type.
index 70b4a36..04ed5f8 100644 (file)
@@ -18,6 +18,8 @@
 #ifndef GRPCPP_IMPL_CODEGEN_SERVER_CALLBACK_H
 #define GRPCPP_IMPL_CODEGEN_SERVER_CALLBACK_H
 
+// IWYU pragma: private, include <grpcpp/support/server_callback.h>
+
 #include <atomic>
 #include <functional>
 #include <type_traits>
index 6c66c42..8713d3e 100644 (file)
@@ -18,6 +18,8 @@
 #ifndef GRPCPP_IMPL_CODEGEN_SERVER_CALLBACK_HANDLERS_H
 #define GRPCPP_IMPL_CODEGEN_SERVER_CALLBACK_HANDLERS_H
 
+// IWYU pragma: private
+
 #include <grpcpp/impl/codegen/message_allocator.h>
 #include <grpcpp/impl/codegen/rpc_service_method.h>
 #include <grpcpp/impl/codegen/server_callback.h>
@@ -81,7 +83,7 @@ class CallbackUnaryHandler : public ::grpc::internal::MethodHandler {
     ::grpc::ByteBuffer buf;
     buf.set_buffer(req);
     RequestType* request = nullptr;
-    MessageHolder<RequestType, ResponseType>* allocator_state = nullptr;
+    MessageHolder<RequestType, ResponseType>* allocator_state;
     if (allocator_ != nullptr) {
       allocator_state = allocator_->AllocateMessages();
     } else {
@@ -98,8 +100,6 @@ class CallbackUnaryHandler : public ::grpc::internal::MethodHandler {
     if (status->ok()) {
       return request;
     }
-    // Clean up on deserialization failure.
-    allocator_state->Release();
     return nullptr;
   }
 
index 9cb6455..a0cd181 100644 (file)
 #ifndef GRPCPP_IMPL_CODEGEN_SERVER_CONTEXT_H
 #define GRPCPP_IMPL_CODEGEN_SERVER_CONTEXT_H
 
+// IWYU pragma: private, include <grpcpp/server_context.h>
+
+#include <grpc/impl/codegen/port_platform.h>
+
 #include <atomic>
 #include <cassert>
 #include <map>
@@ -26,8 +30,6 @@
 #include <type_traits>
 #include <vector>
 
-#include <grpc/impl/codegen/port_platform.h>
-
 #include <grpc/impl/codegen/compression_types.h>
 #include <grpcpp/impl/codegen/call.h>
 #include <grpcpp/impl/codegen/call_op_set.h>
index 7598e72..3a8fd52 100644 (file)
@@ -19,6 +19,8 @@
 #ifndef GRPCPP_IMPL_CODEGEN_SERVER_INTERCEPTOR_H
 #define GRPCPP_IMPL_CODEGEN_SERVER_INTERCEPTOR_H
 
+// IWYU pragma: private, include <grpcpp/support/server_interceptor.h>
+
 #include <atomic>
 #include <vector>
 
index 0cea47e..69fbc41 100644 (file)
@@ -19,6 +19,8 @@
 #ifndef GRPCPP_IMPL_CODEGEN_SERVER_INTERFACE_H
 #define GRPCPP_IMPL_CODEGEN_SERVER_INTERFACE_H
 
+// IWYU pragma: private
+
 #include <grpc/impl/codegen/port_platform.h>
 
 #include <grpc/impl/codegen/grpc_types.h>
index 9b12545..182570e 100644 (file)
@@ -19,6 +19,8 @@
 #ifndef GRPCPP_IMPL_CODEGEN_SERVICE_TYPE_H
 #define GRPCPP_IMPL_CODEGEN_SERVICE_TYPE_H
 
+// IWYU pragma: private, include <grpcpp/impl/service_type.h>
+
 #include <grpcpp/impl/codegen/config.h>
 #include <grpcpp/impl/codegen/core_codegen_interface.h>
 #include <grpcpp/impl/codegen/rpc_service_method.h>
index d84b842..392986a 100644 (file)
 #ifndef GRPCPP_IMPL_CODEGEN_SLICE_H
 #define GRPCPP_IMPL_CODEGEN_SLICE_H
 
+// IWYU pragma: private, include <grpcpp/support/slice.h>
+
+#include <grpc/impl/codegen/slice.h>
 #include <grpcpp/impl/codegen/config.h>
 #include <grpcpp/impl/codegen/core_codegen_interface.h>
 #include <grpcpp/impl/codegen/string_ref.h>
 
-#include <grpc/impl/codegen/slice.h>
-
 namespace grpc {
 
 /// A wrapper around \a grpc_slice.
index 9a6cf89..f5ffc61 100644 (file)
@@ -19,6 +19,8 @@
 #ifndef GRPCPP_IMPL_CODEGEN_STATUS_H
 #define GRPCPP_IMPL_CODEGEN_STATUS_H
 
+// IWYU pragma: private, include <grpcpp/support/status.h>
+
 #include <grpc/impl/codegen/status.h>
 #include <grpcpp/impl/codegen/config.h>
 #include <grpcpp/impl/codegen/status_code_enum.h>
index bdd7ead..36ea24f 100644 (file)
@@ -19,6 +19,8 @@
 #ifndef GRPCPP_IMPL_CODEGEN_STATUS_CODE_ENUM_H
 #define GRPCPP_IMPL_CODEGEN_STATUS_CODE_ENUM_H
 
+// IWYU pragma: private, include <grpcpp/support/status_code_enum.h>
+
 namespace grpc {
 
 enum StatusCode {
index 4543e42..f71778b 100644 (file)
@@ -19,6 +19,8 @@
 #ifndef GRPCPP_IMPL_CODEGEN_STRING_REF_H
 #define GRPCPP_IMPL_CODEGEN_STRING_REF_H
 
+// IWYU pragma: private, include <grpcpp/support/string_ref.h>
+
 #include <string.h>
 
 #include <algorithm>
index 30509c2..efa1e38 100644 (file)
@@ -19,6 +19,8 @@
 #ifndef GRPCPP_IMPL_CODEGEN_STUB_OPTIONS_H
 #define GRPCPP_IMPL_CODEGEN_STUB_OPTIONS_H
 
+// IWYU pragma: private, include <grpcpp/support/stub_options.h>
+
 namespace grpc {
 
 /// Useful interface for generated stubs
index 1f4e4aa..4cb8133 100644 (file)
@@ -19,6 +19,8 @@
 #ifndef GRPCPP_IMPL_CODEGEN_SYNC_H
 #define GRPCPP_IMPL_CODEGEN_SYNC_H
 
+// IWYU pragma: private
+
 #include <grpc/impl/codegen/port_platform.h>
 
 #ifdef GPR_HAS_PTHREAD_H
 
 #include <mutex>
 
+#include "absl/synchronization/mutex.h"
+
 #include <grpc/impl/codegen/log.h>
 #include <grpc/impl/codegen/sync.h>
-
 #include <grpcpp/impl/codegen/core_codegen_interface.h>
 
-#include "absl/synchronization/mutex.h"
-
 // The core library is not accessible in C++ codegen headers, and vice versa.
 // Thus, we need to have duplicate headers with similar functionality.
 // Make sure any change to this file is also reflected in
index 408f42f..17faeb5 100644 (file)
@@ -18,6 +18,8 @@
 #ifndef GRPCPP_IMPL_CODEGEN_SYNC_STREAM_H
 #define GRPCPP_IMPL_CODEGEN_SYNC_STREAM_H
 
+// IWYU pragma: private, include <grpcpp/support/sync_stream.h>
+
 #include <grpcpp/impl/codegen/call.h>
 #include <grpcpp/impl/codegen/channel_interface.h>
 #include <grpcpp/impl/codegen/client_context.h>
index 340a06f..f2021f5 100644 (file)
@@ -19,6 +19,8 @@
 #ifndef GRPCPP_IMPL_CODEGEN_TIME_H
 #define GRPCPP_IMPL_CODEGEN_TIME_H
 
+// IWYU pragma: private, include <grpcpp/support/time.h>
+
 #include <chrono>
 
 #include <grpc/impl/codegen/grpc_types.h>
index 3711c09..0afca8e 100644 (file)
@@ -24,7 +24,7 @@
 #include <grpc/grpc.h>
 #include <grpcpp/impl/codegen/config.h>
 #include <grpcpp/impl/codegen/core_codegen.h>
-#include <grpcpp/impl/codegen/grpc_library.h>
+#include <grpcpp/impl/codegen/grpc_library.h>  // IWYU pragma: export
 
 namespace grpc {
 
index 5da7041..aeef8b7 100644 (file)
@@ -19,6 +19,6 @@
 #ifndef GRPCPP_IMPL_RPC_METHOD_H
 #define GRPCPP_IMPL_RPC_METHOD_H
 
-#include <grpcpp/impl/codegen/rpc_method.h>
+#include <grpcpp/impl/codegen/rpc_method.h>  // IWYU pragma: export
 
 #endif  // GRPCPP_IMPL_RPC_METHOD_H
index ef70a3a..86cb2dc 100644 (file)
@@ -19,6 +19,6 @@
 #ifndef GRPCPP_IMPL_RPC_SERVICE_METHOD_H
 #define GRPCPP_IMPL_RPC_SERVICE_METHOD_H
 
-#include <grpcpp/impl/codegen/rpc_service_method.h>
+#include <grpcpp/impl/codegen/rpc_service_method.h>  // IWYU pragma: export
 
 #endif  // GRPCPP_IMPL_RPC_SERVICE_METHOD_H
index 95194fb..6da8b4d 100644 (file)
@@ -19,6 +19,6 @@
 #ifndef GRPCPP_IMPL_SERIALIZATION_TRAITS_H
 #define GRPCPP_IMPL_SERIALIZATION_TRAITS_H
 
-#include <grpcpp/impl/codegen/serialization_traits.h>
+#include <grpcpp/impl/codegen/serialization_traits.h>  // IWYU pragma: export
 
 #endif  // GRPCPP_IMPL_SERIALIZATION_TRAITS_H
index 250bc8c..de45c42 100644 (file)
@@ -19,6 +19,6 @@
 #ifndef GRPCPP_IMPL_SERVICE_TYPE_H
 #define GRPCPP_IMPL_SERVICE_TYPE_H
 
-#include <grpcpp/impl/codegen/service_type.h>
+#include <grpcpp/impl/codegen/service_type.h>  // IWYU pragma: export
 
 #endif  // GRPCPP_IMPL_SERVICE_TYPE_H
index bba0fca..8d84257 100644 (file)
 #ifndef GRPCPP_SECURITY_ALTS_CONTEXT_H
 #define GRPCPP_SECURITY_ALTS_CONTEXT_H
 
-#include <grpc/grpc_security_constants.h>
-#include <grpcpp/security/auth_context.h>
-
 #include <map>
 #include <memory>
 
+#include <grpc/grpc_security_constants.h>
+#include <grpcpp/security/auth_context.h>
+
 struct grpc_gcp_AltsContext;
 
 namespace grpc {
index 2b2b07e..b0ef4b4 100644 (file)
 #ifndef GRPCPP_SECURITY_ALTS_UTIL_H
 #define GRPCPP_SECURITY_ALTS_UTIL_H
 
+#include <memory>
+
 #include <grpc/grpc_security_constants.h>
 #include <grpcpp/impl/codegen/status.h>
 #include <grpcpp/security/alts_context.h>
 #include <grpcpp/security/auth_context.h>
 
-#include <memory>
-
 struct grpc_gcp_AltsContext;
 
 namespace grpc {
index 7a6f2cb..1778450 100644 (file)
@@ -19,6 +19,6 @@
 #ifndef GRPCPP_SECURITY_AUTH_CONTEXT_H
 #define GRPCPP_SECURITY_AUTH_CONTEXT_H
 
-#include <grpcpp/impl/codegen/security/auth_context.h>
+#include <grpcpp/impl/codegen/security/auth_context.h>  // IWYU pragma: export
 
 #endif  // GRPCPP_SECURITY_AUTH_CONTEXT_H
index 9c3c6be..b3258b2 100644 (file)
 #ifndef GRPCPP_SECURITY_AUTHORIZATION_POLICY_PROVIDER_H
 #define GRPCPP_SECURITY_AUTHORIZATION_POLICY_PROVIDER_H
 
+#include <memory>
+
 #include <grpc/status.h>
 #include <grpcpp/impl/codegen/grpc_library.h>
 
-#include <memory>
-
 // TODO(yihuazhang): remove the forward declaration here and include
 // <grpc/grpc_security.h> directly once the insecure builds are cleaned up.
 typedef struct grpc_authorization_policy_provider
index 1b1f994..18dce96 100644 (file)
@@ -55,11 +55,17 @@ std::shared_ptr<grpc::Channel> CreateCustomChannelWithInterceptors(
         std::unique_ptr<grpc::experimental::ClientInterceptorFactoryInterface>>
         interceptor_creators);
 
-/// Builds XDS Credentials.
+GRPC_DEPRECATED(
+    "Use grpc::XdsCredentials instead. The experimental version will be "
+    "deleted after the 1.41 release.")
 std::shared_ptr<ChannelCredentials> XdsCredentials(
     const std::shared_ptr<ChannelCredentials>& fallback_creds);
 }  // namespace experimental
 
+/// Builds XDS Credentials.
+std::shared_ptr<ChannelCredentials> XdsCredentials(
+    const std::shared_ptr<ChannelCredentials>& fallback_creds);
+
 /// A channel credentials object encapsulates all the state needed by a client
 /// to authenticate with a server for a given channel.
 /// It can make various assertions, e.g., about the client’s identity, role
@@ -80,7 +86,7 @@ class ChannelCredentials : private grpc::GrpcLibraryCodegen {
   // AsSecureCredentials(). Once we are able to remove insecure builds from gRPC
   // (and also internal dependencies on the indirect method of creating a
   // channel through credentials), we would be able to remove this.
-  friend std::shared_ptr<ChannelCredentials> grpc::experimental::XdsCredentials(
+  friend std::shared_ptr<ChannelCredentials> grpc::XdsCredentials(
       const std::shared_ptr<ChannelCredentials>& fallback_creds);
 
   virtual SecureChannelCredentials* AsSecureCredentials() = 0;
index 0ce46a8..2d1bc07 100644 (file)
@@ -60,10 +60,16 @@ struct SslServerCredentialsOptions {
   grpc_ssl_client_certificate_request_type client_certificate_request;
 };
 
-namespace experimental {
 /// Builds Xds ServerCredentials given fallback credentials
 std::shared_ptr<ServerCredentials> XdsServerCredentials(
     const std::shared_ptr<ServerCredentials>& fallback_credentials);
+
+namespace experimental {
+GRPC_DEPRECATED(
+    "Use grpc::XdsServerCredentials instead. The experimental version will be "
+    "deleted after the 1.41 release.")
+std::shared_ptr<ServerCredentials> XdsServerCredentials(
+    const std::shared_ptr<ServerCredentials>& fallback_credentials);
 }  // namespace experimental
 
 /// Wrapper around \a grpc_server_credentials, a way to authenticate a server.
@@ -83,8 +89,7 @@ class ServerCredentials : private grpc::GrpcLibraryCodegen {
   // We need this friend declaration for access to Insecure() and
   // AsSecureServerCredentials(). When these two functions are no longer
   // necessary, this friend declaration can be removed too.
-  friend std::shared_ptr<ServerCredentials>
-  grpc::experimental::XdsServerCredentials(
+  friend std::shared_ptr<ServerCredentials> grpc::XdsServerCredentials(
       const std::shared_ptr<ServerCredentials>& fallback_credentials);
 
   /// Tries to bind \a server to the given \a addr (eg, localhost:1234,
index a7480cc..6569650 100644 (file)
 #ifndef GRPCPP_SECURITY_TLS_CERTIFICATE_PROVIDER_H
 #define GRPCPP_SECURITY_TLS_CERTIFICATE_PROVIDER_H
 
+#include <memory>
+#include <vector>
+
 #include <grpc/grpc_security_constants.h>
 #include <grpc/status.h>
 #include <grpc/support/log.h>
 #include <grpcpp/impl/codegen/grpc_library.h>
 #include <grpcpp/support/config.h>
 
-#include <memory>
-#include <vector>
-
 // TODO(yihuazhang): remove the forward declaration here and include
 // <grpc/grpc_security.h> directly once the insecure builds are cleaned up.
 typedef struct grpc_tls_certificate_provider grpc_tls_certificate_provider;
index da2b595..fb861a5 100644 (file)
 #ifndef GRPCPP_SECURITY_TLS_CREDENTIALS_OPTIONS_H
 #define GRPCPP_SECURITY_TLS_CREDENTIALS_OPTIONS_H
 
+#include <memory>
+#include <vector>
+
 #include <grpc/grpc_security_constants.h>
 #include <grpc/status.h>
 #include <grpc/support/log.h>
 #include <grpcpp/security/tls_certificate_provider.h>
 #include <grpcpp/support/config.h>
 
-#include <memory>
-#include <vector>
-
 // TODO(yihuazhang): remove the forward declaration here and include
 // <grpc/grpc_security.h> directly once the insecure builds are cleaned up.
 typedef struct grpc_tls_server_authorization_check_arg
index 4c21508..dce8744 100644 (file)
 #ifndef GRPCPP_SERVER_H
 #define GRPCPP_SERVER_H
 
+#include <grpc/impl/codegen/port_platform.h>
+
 #include <list>
 #include <memory>
 #include <vector>
 
-#include <grpc/impl/codegen/port_platform.h>
-
 #include <grpc/compression.h>
 #include <grpc/support/atm.h>
 #include <grpcpp/channel.h>
index 99d2ca3..ab63912 100644 (file)
 #ifndef GRPCPP_SERVER_BUILDER_H
 #define GRPCPP_SERVER_BUILDER_H
 
+#include <grpc/impl/codegen/port_platform.h>
+
 #include <climits>
 #include <map>
 #include <memory>
 #include <vector>
 
-#include <grpc/impl/codegen/port_platform.h>
-
 #include <grpc/compression.h>
 #include <grpc/support/cpu.h>
 #include <grpc/support/workaround_list.h>
index 45f2614..ed6bd66 100644 (file)
@@ -19,6 +19,6 @@
 #ifndef GRPCPP_SERVER_CONTEXT_H
 #define GRPCPP_SERVER_CONTEXT_H
 
-#include <grpcpp/impl/codegen/server_context.h>
+#include <grpcpp/impl/codegen/server_context.h>  // IWYU pragma: export
 
 #endif  // GRPCPP_SERVER_CONTEXT_H
index ef3ee01..2e93862 100644 (file)
 #ifndef GRPCPP_SERVER_POSIX_H
 #define GRPCPP_SERVER_POSIX_H
 
+#include <grpc/support/port_platform.h>
+
 #include <memory>
 
-#include <grpc/support/port_platform.h>
 #include <grpcpp/server.h>
 
 namespace grpc {
index ff9e455..5f71701 100644 (file)
@@ -19,6 +19,6 @@
 #ifndef GRPCPP_SUPPORT_ASYNC_STREAM_H
 #define GRPCPP_SUPPORT_ASYNC_STREAM_H
 
-#include <grpcpp/impl/codegen/async_stream.h>
+#include <grpcpp/impl/codegen/async_stream.h>  // IWYU pragma: export
 
 #endif  // GRPCPP_SUPPORT_ASYNC_STREAM_H
index 2e5181c..02071e4 100644 (file)
@@ -19,6 +19,6 @@
 #ifndef GRPCPP_SUPPORT_ASYNC_UNARY_CALL_H
 #define GRPCPP_SUPPORT_ASYNC_UNARY_CALL_H
 
-#include <grpcpp/impl/codegen/async_unary_call.h>
+#include <grpcpp/impl/codegen/async_unary_call.h>  // IWYU pragma: export
 
 #endif  // GRPCPP_SUPPORT_ASYNC_UNARY_CALL_H
index 53aeff1..6f566e7 100644 (file)
@@ -22,7 +22,7 @@
 #include <grpc/byte_buffer.h>
 #include <grpc/grpc.h>
 #include <grpc/support/log.h>
-#include <grpcpp/impl/codegen/byte_buffer.h>
+#include <grpcpp/impl/codegen/byte_buffer.h>  // IWYU pragma: export
 #include <grpcpp/impl/serialization_traits.h>
 #include <grpcpp/support/config.h>
 #include <grpcpp/support/slice.h>
index 063fdc4..c15bca0 100644 (file)
@@ -19,6 +19,6 @@
 #ifndef GRPCPP_SUPPORT_CLIENT_CALLBACK_H
 #define GRPCPP_SUPPORT_CLIENT_CALLBACK_H
 
-#include <grpcpp/impl/codegen/client_callback.h>
+#include <grpcpp/impl/codegen/client_callback.h>  // IWYU pragma: export
 
 #endif  // GRPCPP_SUPPORT_CLIENT_CALLBACK_H
index 50810e3..552cab4 100644 (file)
@@ -19,6 +19,6 @@
 #ifndef GRPCPP_SUPPORT_CLIENT_INTERCEPTOR_H
 #define GRPCPP_SUPPORT_CLIENT_INTERCEPTOR_H
 
-#include <grpcpp/impl/codegen/client_interceptor.h>
+#include <grpcpp/impl/codegen/client_interceptor.h>  // IWYU pragma: export
 
 #endif  // GRPCPP_SUPPORT_CLIENT_INTERCEPTOR_H
index 16bdab6..f2632f2 100644 (file)
@@ -19,6 +19,6 @@
 #ifndef GRPCPP_SUPPORT_CONFIG_H
 #define GRPCPP_SUPPORT_CONFIG_H
 
-#include <grpcpp/impl/codegen/config.h>
+#include <grpcpp/impl/codegen/config.h>  // IWYU pragma: export
 
 #endif  // GRPCPP_SUPPORT_CONFIG_H
index 7ff7951..d4f2ea1 100644 (file)
@@ -19,6 +19,6 @@
 #ifndef GRPCPP_SUPPORT_INTERCEPTOR_H
 #define GRPCPP_SUPPORT_INTERCEPTOR_H
 
-#include <grpcpp/impl/codegen/interceptor.h>
+#include <grpcpp/impl/codegen/interceptor.h>  // IWYU pragma: export
 
 #endif  // GRPCPP_SUPPORT_INTERCEPTOR_H
index 20ce072..22a963f 100644 (file)
@@ -19,6 +19,6 @@
 #ifndef GRPCPP_SUPPORT_MESSAGE_ALLOCATOR_H
 #define GRPCPP_SUPPORT_MESSAGE_ALLOCATOR_H
 
-#include <grpcpp/impl/codegen/message_allocator.h>
+#include <grpcpp/impl/codegen/message_allocator.h>  // IWYU pragma: export
 
 #endif  // GRPCPP_SUPPORT_MESSAGE_ALLOCATOR_H
index 038e76c..0b97a7a 100644 (file)
@@ -19,6 +19,6 @@
 #ifndef GRPCPP_SUPPORT_METHOD_HANDLER_H
 #define GRPCPP_SUPPORT_METHOD_HANDLER_H
 
-#include <grpcpp/impl/codegen/method_handler.h>
+#include <grpcpp/impl/codegen/method_handler.h>  // IWYU pragma: export
 
 #endif  // GRPCPP_SUPPORT_METHOD_HANDLER_H
index 4cdb65d..07e523e 100644 (file)
@@ -19,6 +19,6 @@
 #ifndef GRPCPP_SUPPORT_PROTO_BUFFER_READER_H
 #define GRPCPP_SUPPORT_PROTO_BUFFER_READER_H
 
-#include <grpcpp/impl/codegen/proto_buffer_reader.h>
+#include <grpcpp/impl/codegen/proto_buffer_reader.h>  // IWYU pragma: export
 
 #endif  // GRPCPP_SUPPORT_PROTO_BUFFER_READER_H
index 01cf29c..589deb8 100644 (file)
@@ -19,6 +19,6 @@
 #ifndef GRPCPP_SUPPORT_PROTO_BUFFER_WRITER_H
 #define GRPCPP_SUPPORT_PROTO_BUFFER_WRITER_H
 
-#include <grpcpp/impl/codegen/proto_buffer_writer.h>
+#include <grpcpp/impl/codegen/proto_buffer_writer.h>  // IWYU pragma: export
 
 #endif  // GRPCPP_SUPPORT_PROTO_BUFFER_WRITER_H
index b0aeeb5..1ffdce5 100644 (file)
@@ -19,6 +19,6 @@
 #ifndef GRPCPP_SUPPORT_SERVER_CALLBACK_H
 #define GRPCPP_SUPPORT_SERVER_CALLBACK_H
 
-#include <grpcpp/impl/codegen/server_callback.h>
+#include <grpcpp/impl/codegen/server_callback.h>  // IWYU pragma: export
 
 #endif  // GRPCPP_SUPPORT_SERVER_CALLBACK_H
index b0a6229..ad9c7a1 100644 (file)
@@ -19,6 +19,6 @@
 #ifndef GRPCPP_SUPPORT_SERVER_INTERCEPTOR_H
 #define GRPCPP_SUPPORT_SERVER_INTERCEPTOR_H
 
-#include <grpcpp/impl/codegen/server_interceptor.h>
+#include <grpcpp/impl/codegen/server_interceptor.h>  // IWYU pragma: export
 
 #endif  // GRPCPP_SUPPORT_SERVER_INTERCEPTOR_H
index eaeb29a..2434983 100644 (file)
@@ -20,7 +20,7 @@
 #define GRPCPP_SUPPORT_SLICE_H
 
 #include <grpc/slice.h>
-#include <grpcpp/impl/codegen/slice.h>
+#include <grpcpp/impl/codegen/slice.h>  // IWYU pragma: export
 #include <grpcpp/support/config.h>
 
 #endif  // GRPCPP_SUPPORT_SLICE_H
index 91b629f..e46b46d 100644 (file)
@@ -19,6 +19,6 @@
 #ifndef GRPCPP_SUPPORT_STATUS_H
 #define GRPCPP_SUPPORT_STATUS_H
 
-#include <grpcpp/impl/codegen/status.h>
+#include <grpcpp/impl/codegen/status.h>  // IWYU pragma: export
 
 #endif  // GRPCPP_SUPPORT_STATUS_H
index bfb47f3..eac697f 100644 (file)
@@ -19,6 +19,6 @@
 #ifndef GRPCPP_SUPPORT_STATUS_CODE_ENUM_H
 #define GRPCPP_SUPPORT_STATUS_CODE_ENUM_H
 
-#include <grpcpp/impl/codegen/status_code_enum.h>
+#include <grpcpp/impl/codegen/status_code_enum.h>  // IWYU pragma: export
 
 #endif  // GRPCPP_SUPPORT_STATUS_CODE_ENUM_H
index 0e0d3d4..6cf82be 100644 (file)
@@ -19,6 +19,6 @@
 #ifndef GRPCPP_SUPPORT_STRING_REF_H
 #define GRPCPP_SUPPORT_STRING_REF_H
 
-#include <grpcpp/impl/codegen/string_ref.h>
+#include <grpcpp/impl/codegen/string_ref.h>  // IWYU pragma: export
 
 #endif  // GRPCPP_SUPPORT_STRING_REF_H
index e9700ea..ffe1ad7 100644 (file)
@@ -19,6 +19,6 @@
 #ifndef GRPCPP_SUPPORT_STUB_OPTIONS_H
 #define GRPCPP_SUPPORT_STUB_OPTIONS_H
 
-#include <grpcpp/impl/codegen/stub_options.h>
+#include <grpcpp/impl/codegen/stub_options.h>  // IWYU pragma: export
 
 #endif  // GRPCPP_SUPPORT_STUB_OPTIONS_H
index ea60b6d..78a348d 100644 (file)
@@ -19,6 +19,6 @@
 #ifndef GRPCPP_SUPPORT_SYNC_STREAM_H
 #define GRPCPP_SUPPORT_SYNC_STREAM_H
 
-#include <grpcpp/impl/codegen/sync_stream.h>
+#include <grpcpp/impl/codegen/sync_stream.h>  // IWYU pragma: export
 
 #endif  // GRPCPP_SUPPORT_SYNC_STREAM_H
index c7408ff..b5e07b6 100644 (file)
@@ -19,6 +19,6 @@
 #ifndef GRPCPP_SUPPORT_TIME_H
 #define GRPCPP_SUPPORT_TIME_H
 
-#include <grpcpp/impl/codegen/time.h>
+#include <grpcpp/impl/codegen/time.h>  // IWYU pragma: export
 
 #endif  // GRPCPP_SUPPORT_TIME_H
index 4631873..0ce9643 100644 (file)
 #ifndef GRPCPP_TEST_CLIENT_CONTEXT_TEST_PEER_H
 #define GRPCPP_TEST_CLIENT_CONTEXT_TEST_PEER_H
 
-#include <grpcpp/client_context.h>
-
 #include <map>
 
+#include <grpcpp/client_context.h>
+
 namespace grpc {
 namespace testing {
 
index 9e12af9..f210b41 100644 (file)
@@ -22,6 +22,7 @@
 #include <stdint.h>
 
 #include <gmock/gmock.h>
+
 #include <grpcpp/impl/codegen/call.h>
 #include <grpcpp/support/async_stream.h>
 #include <grpcpp/support/async_unary_call.h>
index 076c377..b5663ee 100644 (file)
 #include <grpcpp/server_builder.h>
 
 namespace grpc {
-namespace experimental {
 
 class XdsServerServingStatusNotifierInterface {
  public:
+  struct ServingStatusUpdate {
+    ::grpc::Status status;
+  };
+
   virtual ~XdsServerServingStatusNotifierInterface() = default;
 
   // \a uri contains the listening target associated with the notification. Note
@@ -37,7 +40,8 @@ class XdsServerServingStatusNotifierInterface {
   // The API does not provide any guarantees around duplicate updates.
   // Status::OK signifies that the server is serving, while a non-OK status
   // signifies that the server is not serving.
-  virtual void OnServingStatusUpdate(std::string uri, grpc::Status status) = 0;
+  virtual void OnServingStatusUpdate(std::string uri,
+                                     ServingStatusUpdate update) = 0;
 };
 
 class XdsServerBuilder : public ::grpc::ServerBuilder {
@@ -62,18 +66,29 @@ class XdsServerBuilder : public ::grpc::ServerBuilder {
   }
 
   static void OnServingStatusUpdate(void* user_data, const char* uri,
-                                    grpc_status_code code,
-                                    const char* error_message) {
+                                    grpc_serving_status_update update) {
     if (user_data == nullptr) return;
     XdsServerServingStatusNotifierInterface* notifier =
         static_cast<XdsServerServingStatusNotifierInterface*>(user_data);
     notifier->OnServingStatusUpdate(
-        uri, grpc::Status(static_cast<StatusCode>(code), error_message));
+        uri, {grpc::Status(static_cast<StatusCode>(update.code),
+                           update.error_message)});
   }
 
   XdsServerServingStatusNotifierInterface* notifier_ = nullptr;
 };
 
+namespace experimental {
+// TODO(yashykt): Delete this after the 1.42 release.
+GRPC_DEPRECATED(
+    "Use grpc::XdsServerServingStatusNotifierInterface instead. The "
+    "experimental version will be deleted after the 1.42 release.")
+typedef grpc::XdsServerServingStatusNotifierInterface
+    XdsServerServingStatusNotifierInterface;
+GRPC_DEPRECATED(
+    "Use grpc::XdsServerBuilder instead. The experimental version will be "
+    "deleted after the 1.42 release.")
+typedef grpc::XdsServerBuilder XdsServerBuilder;
 }  // namespace experimental
 }  // namespace grpc
 
index ce6ba71..5938207 100644 (file)
@@ -13,8 +13,8 @@
  <date>2019-09-24</date>
  <time>16:06:07</time>
  <version>
-  <release>1.40.0</release>
-  <api>1.40.0</api>
+  <release>1.41.0</release>
+  <api>1.41.0</api>
  </version>
  <stability>
   <release>stable</release>
@@ -22,7 +22,7 @@
  </stability>
  <license>Apache 2.0</license>
  <notes>
-- gRPC Core 1.40.0 update
+- gRPC Core 1.41.0 update
  </notes>
  <contents>
   <dir baseinstalldir="/" name="/">
     <file baseinstalldir="/" name="src/core/ext/filters/client_channel/resolver/dns/c_ares/dns_resolver_ares.cc" role="src" />
     <file baseinstalldir="/" name="src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver.h" role="src" />
     <file baseinstalldir="/" name="src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_event_engine.cc" role="src" />
-    <file baseinstalldir="/" name="src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_libuv.cc" role="src" />
     <file baseinstalldir="/" name="src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_posix.cc" role="src" />
     <file baseinstalldir="/" name="src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_windows.cc" role="src" />
     <file baseinstalldir="/" name="src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper.cc" role="src" />
     <file baseinstalldir="/" name="src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper.h" role="src" />
     <file baseinstalldir="/" name="src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_event_engine.cc" role="src" />
-    <file baseinstalldir="/" name="src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_libuv.cc" role="src" />
     <file baseinstalldir="/" name="src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_posix.cc" role="src" />
     <file baseinstalldir="/" name="src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_windows.cc" role="src" />
     <file baseinstalldir="/" name="src/core/ext/filters/client_channel/resolver/dns/dns_resolver_selection.cc" role="src" />
     <file baseinstalldir="/" name="src/core/ext/transport/chttp2/transport/frame_settings.h" role="src" />
     <file baseinstalldir="/" name="src/core/ext/transport/chttp2/transport/frame_window_update.cc" role="src" />
     <file baseinstalldir="/" name="src/core/ext/transport/chttp2/transport/frame_window_update.h" role="src" />
+    <file baseinstalldir="/" name="src/core/ext/transport/chttp2/transport/hpack_constants.h" role="src" />
     <file baseinstalldir="/" name="src/core/ext/transport/chttp2/transport/hpack_encoder.cc" role="src" />
     <file baseinstalldir="/" name="src/core/ext/transport/chttp2/transport/hpack_encoder.h" role="src" />
+    <file baseinstalldir="/" name="src/core/ext/transport/chttp2/transport/hpack_encoder_index.h" role="src" />
+    <file baseinstalldir="/" name="src/core/ext/transport/chttp2/transport/hpack_encoder_table.cc" role="src" />
+    <file baseinstalldir="/" name="src/core/ext/transport/chttp2/transport/hpack_encoder_table.h" role="src" />
     <file baseinstalldir="/" name="src/core/ext/transport/chttp2/transport/hpack_parser.cc" role="src" />
     <file baseinstalldir="/" name="src/core/ext/transport/chttp2/transport/hpack_parser.h" role="src" />
-    <file baseinstalldir="/" name="src/core/ext/transport/chttp2/transport/hpack_table.cc" role="src" />
-    <file baseinstalldir="/" name="src/core/ext/transport/chttp2/transport/hpack_table.h" role="src" />
+    <file baseinstalldir="/" name="src/core/ext/transport/chttp2/transport/hpack_parser_table.cc" role="src" />
+    <file baseinstalldir="/" name="src/core/ext/transport/chttp2/transport/hpack_parser_table.h" role="src" />
+    <file baseinstalldir="/" name="src/core/ext/transport/chttp2/transport/hpack_utils.cc" role="src" />
+    <file baseinstalldir="/" name="src/core/ext/transport/chttp2/transport/hpack_utils.h" role="src" />
     <file baseinstalldir="/" name="src/core/ext/transport/chttp2/transport/http2_settings.cc" role="src" />
     <file baseinstalldir="/" name="src/core/ext/transport/chttp2/transport/http2_settings.h" role="src" />
     <file baseinstalldir="/" name="src/core/ext/transport/chttp2/transport/huffsyms.cc" role="src" />
     <file baseinstalldir="/" name="src/core/ext/transport/chttp2/transport/incoming_metadata.h" role="src" />
     <file baseinstalldir="/" name="src/core/ext/transport/chttp2/transport/internal.h" role="src" />
     <file baseinstalldir="/" name="src/core/ext/transport/chttp2/transport/parsing.cc" role="src" />
+    <file baseinstalldir="/" name="src/core/ext/transport/chttp2/transport/popularity_count.h" role="src" />
     <file baseinstalldir="/" name="src/core/ext/transport/chttp2/transport/stream_lists.cc" role="src" />
     <file baseinstalldir="/" name="src/core/ext/transport/chttp2/transport/stream_map.cc" role="src" />
     <file baseinstalldir="/" name="src/core/ext/transport/chttp2/transport/stream_map.h" role="src" />
     <file baseinstalldir="/" name="src/core/lib/compression/stream_compression_gzip.h" role="src" />
     <file baseinstalldir="/" name="src/core/lib/compression/stream_compression_identity.cc" role="src" />
     <file baseinstalldir="/" name="src/core/lib/compression/stream_compression_identity.h" role="src" />
+    <file baseinstalldir="/" name="src/core/lib/config/core_configuration.cc" role="src" />
+    <file baseinstalldir="/" name="src/core/lib/config/core_configuration.h" role="src" />
     <file baseinstalldir="/" name="src/core/lib/debug/stats.cc" role="src" />
     <file baseinstalldir="/" name="src/core/lib/debug/stats.h" role="src" />
     <file baseinstalldir="/" name="src/core/lib/debug/stats_data.cc" role="src" />
     <file baseinstalldir="/" name="src/core/lib/gpr/time_precise.h" role="src" />
     <file baseinstalldir="/" name="src/core/lib/gpr/time_windows.cc" role="src" />
     <file baseinstalldir="/" name="src/core/lib/gpr/tls.h" role="src" />
-    <file baseinstalldir="/" name="src/core/lib/gpr/tls_gcc.h" role="src" />
-    <file baseinstalldir="/" name="src/core/lib/gpr/tls_msvc.h" role="src" />
-    <file baseinstalldir="/" name="src/core/lib/gpr/tls_pthread.cc" role="src" />
-    <file baseinstalldir="/" name="src/core/lib/gpr/tls_pthread.h" role="src" />
-    <file baseinstalldir="/" name="src/core/lib/gpr/tls_stdcpp.h" role="src" />
     <file baseinstalldir="/" name="src/core/lib/gpr/tmpfile.h" role="src" />
     <file baseinstalldir="/" name="src/core/lib/gpr/tmpfile_msys.cc" role="src" />
     <file baseinstalldir="/" name="src/core/lib/gpr/tmpfile_posix.cc" role="src" />
     <file baseinstalldir="/" name="src/core/lib/gpr/wrap_memcpy.cc" role="src" />
     <file baseinstalldir="/" name="src/core/lib/gprpp/arena.cc" role="src" />
     <file baseinstalldir="/" name="src/core/lib/gprpp/arena.h" role="src" />
-    <file baseinstalldir="/" name="src/core/lib/gprpp/atomic.h" role="src" />
+    <file baseinstalldir="/" name="src/core/lib/gprpp/atomic_utils.h" role="src" />
+    <file baseinstalldir="/" name="src/core/lib/gprpp/bitset.h" role="src" />
+    <file baseinstalldir="/" name="src/core/lib/gprpp/construct_destruct.h" role="src" />
     <file baseinstalldir="/" name="src/core/lib/gprpp/debug_location.h" role="src" />
     <file baseinstalldir="/" name="src/core/lib/gprpp/dual_ref_counted.h" role="src" />
     <file baseinstalldir="/" name="src/core/lib/gprpp/examine_stack.cc" role="src" />
     <file baseinstalldir="/" name="src/core/lib/gprpp/host_port.cc" role="src" />
     <file baseinstalldir="/" name="src/core/lib/gprpp/host_port.h" role="src" />
     <file baseinstalldir="/" name="src/core/lib/gprpp/manual_constructor.h" role="src" />
+    <file baseinstalldir="/" name="src/core/lib/gprpp/match.h" role="src" />
     <file baseinstalldir="/" name="src/core/lib/gprpp/memory.h" role="src" />
     <file baseinstalldir="/" name="src/core/lib/gprpp/mpscq.cc" role="src" />
     <file baseinstalldir="/" name="src/core/lib/gprpp/mpscq.h" role="src" />
     <file baseinstalldir="/" name="src/core/lib/gprpp/orphanable.h" role="src" />
+    <file baseinstalldir="/" name="src/core/lib/gprpp/overload.h" role="src" />
     <file baseinstalldir="/" name="src/core/lib/gprpp/ref_counted.h" role="src" />
     <file baseinstalldir="/" name="src/core/lib/gprpp/ref_counted_ptr.h" role="src" />
     <file baseinstalldir="/" name="src/core/lib/gprpp/stat.h" role="src" />
     <file baseinstalldir="/" name="src/core/lib/iomgr/endpoint_pair.h" role="src" />
     <file baseinstalldir="/" name="src/core/lib/iomgr/endpoint_pair_event_engine.cc" role="src" />
     <file baseinstalldir="/" name="src/core/lib/iomgr/endpoint_pair_posix.cc" role="src" />
-    <file baseinstalldir="/" name="src/core/lib/iomgr/endpoint_pair_uv.cc" role="src" />
     <file baseinstalldir="/" name="src/core/lib/iomgr/endpoint_pair_windows.cc" role="src" />
     <file baseinstalldir="/" name="src/core/lib/iomgr/error.cc" role="src" />
     <file baseinstalldir="/" name="src/core/lib/iomgr/error.h" role="src" />
     <file baseinstalldir="/" name="src/core/lib/iomgr/iomgr_internal.h" role="src" />
     <file baseinstalldir="/" name="src/core/lib/iomgr/iomgr_posix.cc" role="src" />
     <file baseinstalldir="/" name="src/core/lib/iomgr/iomgr_posix_cfstream.cc" role="src" />
-    <file baseinstalldir="/" name="src/core/lib/iomgr/iomgr_uv.cc" role="src" />
     <file baseinstalldir="/" name="src/core/lib/iomgr/iomgr_windows.cc" role="src" />
     <file baseinstalldir="/" name="src/core/lib/iomgr/is_epollexclusive_available.cc" role="src" />
     <file baseinstalldir="/" name="src/core/lib/iomgr/is_epollexclusive_available.h" role="src" />
     <file baseinstalldir="/" name="src/core/lib/iomgr/pollset_set_custom.h" role="src" />
     <file baseinstalldir="/" name="src/core/lib/iomgr/pollset_set_windows.cc" role="src" />
     <file baseinstalldir="/" name="src/core/lib/iomgr/pollset_set_windows.h" role="src" />
-    <file baseinstalldir="/" name="src/core/lib/iomgr/pollset_uv.cc" role="src" />
-    <file baseinstalldir="/" name="src/core/lib/iomgr/pollset_uv.h" role="src" />
     <file baseinstalldir="/" name="src/core/lib/iomgr/pollset_windows.cc" role="src" />
     <file baseinstalldir="/" name="src/core/lib/iomgr/pollset_windows.h" role="src" />
     <file baseinstalldir="/" name="src/core/lib/iomgr/port.h" role="src" />
     <file baseinstalldir="/" name="src/core/lib/iomgr/resource_quota.cc" role="src" />
     <file baseinstalldir="/" name="src/core/lib/iomgr/resource_quota.h" role="src" />
     <file baseinstalldir="/" name="src/core/lib/iomgr/sockaddr.h" role="src" />
-    <file baseinstalldir="/" name="src/core/lib/iomgr/sockaddr_custom.h" role="src" />
     <file baseinstalldir="/" name="src/core/lib/iomgr/sockaddr_posix.h" role="src" />
     <file baseinstalldir="/" name="src/core/lib/iomgr/sockaddr_windows.h" role="src" />
     <file baseinstalldir="/" name="src/core/lib/iomgr/socket_factory_posix.cc" role="src" />
     <file baseinstalldir="/" name="src/core/lib/iomgr/socket_utils_linux.cc" role="src" />
     <file baseinstalldir="/" name="src/core/lib/iomgr/socket_utils_posix.cc" role="src" />
     <file baseinstalldir="/" name="src/core/lib/iomgr/socket_utils_posix.h" role="src" />
-    <file baseinstalldir="/" name="src/core/lib/iomgr/socket_utils_uv.cc" role="src" />
     <file baseinstalldir="/" name="src/core/lib/iomgr/socket_utils_windows.cc" role="src" />
     <file baseinstalldir="/" name="src/core/lib/iomgr/socket_windows.cc" role="src" />
     <file baseinstalldir="/" name="src/core/lib/iomgr/socket_windows.h" role="src" />
     <file baseinstalldir="/" name="src/core/lib/iomgr/tcp_server_utils_posix_ifaddrs.cc" role="src" />
     <file baseinstalldir="/" name="src/core/lib/iomgr/tcp_server_utils_posix_noifaddrs.cc" role="src" />
     <file baseinstalldir="/" name="src/core/lib/iomgr/tcp_server_windows.cc" role="src" />
-    <file baseinstalldir="/" name="src/core/lib/iomgr/tcp_uv.cc" role="src" />
     <file baseinstalldir="/" name="src/core/lib/iomgr/tcp_windows.cc" role="src" />
     <file baseinstalldir="/" name="src/core/lib/iomgr/tcp_windows.h" role="src" />
     <file baseinstalldir="/" name="src/core/lib/iomgr/time_averaged_stats.cc" role="src" />
     <file baseinstalldir="/" name="src/core/lib/iomgr/timer_heap.h" role="src" />
     <file baseinstalldir="/" name="src/core/lib/iomgr/timer_manager.cc" role="src" />
     <file baseinstalldir="/" name="src/core/lib/iomgr/timer_manager.h" role="src" />
-    <file baseinstalldir="/" name="src/core/lib/iomgr/timer_uv.cc" role="src" />
     <file baseinstalldir="/" name="src/core/lib/iomgr/udp_server.cc" role="src" />
     <file baseinstalldir="/" name="src/core/lib/iomgr/udp_server.h" role="src" />
     <file baseinstalldir="/" name="src/core/lib/iomgr/unix_sockets_posix.cc" role="src" />
     <file baseinstalldir="/" name="src/core/lib/security/authorization/authorization_policy_provider_vtable.cc" role="src" />
     <file baseinstalldir="/" name="src/core/lib/security/authorization/evaluate_args.cc" role="src" />
     <file baseinstalldir="/" name="src/core/lib/security/authorization/evaluate_args.h" role="src" />
+    <file baseinstalldir="/" name="src/core/lib/security/authorization/sdk_server_authz_filter.cc" role="src" />
+    <file baseinstalldir="/" name="src/core/lib/security/authorization/sdk_server_authz_filter.h" role="src" />
     <file baseinstalldir="/" name="src/core/lib/security/context/security_context.cc" role="src" />
     <file baseinstalldir="/" name="src/core/lib/security/context/security_context.h" role="src" />
     <file baseinstalldir="/" name="src/core/lib/security/credentials/alts/alts_credentials.cc" role="src" />
     <file baseinstalldir="/" name="third_party/boringssl-with-bazel/src/crypto/asn1/a_utctm.c" role="src" />
     <file baseinstalldir="/" name="third_party/boringssl-with-bazel/src/crypto/asn1/a_utf8.c" role="src" />
     <file baseinstalldir="/" name="third_party/boringssl-with-bazel/src/crypto/asn1/asn1_lib.c" role="src" />
-    <file baseinstalldir="/" name="third_party/boringssl-with-bazel/src/crypto/asn1/asn1_locl.h" role="src" />
     <file baseinstalldir="/" name="third_party/boringssl-with-bazel/src/crypto/asn1/asn1_par.c" role="src" />
     <file baseinstalldir="/" name="third_party/boringssl-with-bazel/src/crypto/asn1/asn_pack.c" role="src" />
     <file baseinstalldir="/" name="third_party/boringssl-with-bazel/src/crypto/asn1/f_enum.c" role="src" />
     <file baseinstalldir="/" name="third_party/boringssl-with-bazel/src/crypto/asn1/f_int.c" role="src" />
     <file baseinstalldir="/" name="third_party/boringssl-with-bazel/src/crypto/asn1/f_string.c" role="src" />
+    <file baseinstalldir="/" name="third_party/boringssl-with-bazel/src/crypto/asn1/internal.h" role="src" />
     <file baseinstalldir="/" name="third_party/boringssl-with-bazel/src/crypto/asn1/tasn_dec.c" role="src" />
     <file baseinstalldir="/" name="third_party/boringssl-with-bazel/src/crypto/asn1/tasn_enc.c" role="src" />
     <file baseinstalldir="/" name="third_party/boringssl-with-bazel/src/crypto/asn1/tasn_fre.c" role="src" />
     <file baseinstalldir="/" name="third_party/boringssl-with-bazel/src/crypto/hrss/hrss.c" role="src" />
     <file baseinstalldir="/" name="third_party/boringssl-with-bazel/src/crypto/hrss/internal.h" role="src" />
     <file baseinstalldir="/" name="third_party/boringssl-with-bazel/src/crypto/internal.h" role="src" />
+    <file baseinstalldir="/" name="third_party/boringssl-with-bazel/src/crypto/lhash/internal.h" role="src" />
     <file baseinstalldir="/" name="third_party/boringssl-with-bazel/src/crypto/lhash/lhash.c" role="src" />
     <file baseinstalldir="/" name="third_party/boringssl-with-bazel/src/crypto/mem.c" role="src" />
     <file baseinstalldir="/" name="third_party/boringssl-with-bazel/src/crypto/obj/obj.c" role="src" />
     <file baseinstalldir="/" name="third_party/boringssl-with-bazel/src/ssl/dtls_method.cc" role="src" />
     <file baseinstalldir="/" name="third_party/boringssl-with-bazel/src/ssl/dtls_record.cc" role="src" />
     <file baseinstalldir="/" name="third_party/boringssl-with-bazel/src/ssl/encrypted_client_hello.cc" role="src" />
+    <file baseinstalldir="/" name="third_party/boringssl-with-bazel/src/ssl/extensions.cc" role="src" />
     <file baseinstalldir="/" name="third_party/boringssl-with-bazel/src/ssl/handoff.cc" role="src" />
     <file baseinstalldir="/" name="third_party/boringssl-with-bazel/src/ssl/handshake.cc" role="src" />
     <file baseinstalldir="/" name="third_party/boringssl-with-bazel/src/ssl/handshake_client.cc" role="src" />
     <file baseinstalldir="/" name="third_party/boringssl-with-bazel/src/ssl/ssl_versions.cc" role="src" />
     <file baseinstalldir="/" name="third_party/boringssl-with-bazel/src/ssl/ssl_x509.cc" role="src" />
     <file baseinstalldir="/" name="third_party/boringssl-with-bazel/src/ssl/t1_enc.cc" role="src" />
-    <file baseinstalldir="/" name="third_party/boringssl-with-bazel/src/ssl/t1_lib.cc" role="src" />
     <file baseinstalldir="/" name="third_party/boringssl-with-bazel/src/ssl/tls13_both.cc" role="src" />
     <file baseinstalldir="/" name="third_party/boringssl-with-bazel/src/ssl/tls13_client.cc" role="src" />
     <file baseinstalldir="/" name="third_party/boringssl-with-bazel/src/ssl/tls13_enc.cc" role="src" />
     <file baseinstalldir="/" name="third_party/re2/util/test.h" role="src" />
     <file baseinstalldir="/" name="third_party/re2/util/utf.h" role="src" />
     <file baseinstalldir="/" name="third_party/re2/util/util.h" role="src" />
-    <file baseinstalldir="/" name="third_party/upb/third_party/wyhash/wyhash.h" role="src" />
     <file baseinstalldir="/" name="third_party/upb/upb/decode.c" role="src" />
     <file baseinstalldir="/" name="third_party/upb/upb/decode.h" role="src" />
-    <file baseinstalldir="/" name="third_party/upb/upb/decode.int.h" role="src" />
     <file baseinstalldir="/" name="third_party/upb/upb/decode_fast.c" role="src" />
     <file baseinstalldir="/" name="third_party/upb/upb/decode_fast.h" role="src" />
+    <file baseinstalldir="/" name="third_party/upb/upb/decode_internal.h" role="src" />
     <file baseinstalldir="/" name="third_party/upb/upb/def.c" role="src" />
     <file baseinstalldir="/" name="third_party/upb/upb/def.h" role="src" />
     <file baseinstalldir="/" name="third_party/upb/upb/def.hpp" role="src" />
     <file baseinstalldir="/" name="third_party/upb/upb/encode.h" role="src" />
     <file baseinstalldir="/" name="third_party/upb/upb/msg.c" role="src" />
     <file baseinstalldir="/" name="third_party/upb/upb/msg.h" role="src" />
+    <file baseinstalldir="/" name="third_party/upb/upb/msg_internal.h" role="src" />
     <file baseinstalldir="/" name="third_party/upb/upb/port_def.inc" role="src" />
     <file baseinstalldir="/" name="third_party/upb/upb/port_undef.inc" role="src" />
     <file baseinstalldir="/" name="third_party/upb/upb/reflection.c" role="src" />
     <file baseinstalldir="/" name="third_party/upb/upb/reflection.h" role="src" />
+    <file baseinstalldir="/" name="third_party/upb/upb/reflection.hpp" role="src" />
     <file baseinstalldir="/" name="third_party/upb/upb/table.c" role="src" />
-    <file baseinstalldir="/" name="third_party/upb/upb/table.int.h" role="src" />
+    <file baseinstalldir="/" name="third_party/upb/upb/table_internal.h" role="src" />
     <file baseinstalldir="/" name="third_party/upb/upb/text_encode.c" role="src" />
     <file baseinstalldir="/" name="third_party/upb/upb/text_encode.h" role="src" />
     <file baseinstalldir="/" name="third_party/upb/upb/upb.c" role="src" />
     <file baseinstalldir="/" name="third_party/upb/upb/upb.h" role="src" />
     <file baseinstalldir="/" name="third_party/upb/upb/upb.hpp" role="src" />
-    <file baseinstalldir="/" name="third_party/upb/upb/upb.int.h" role="src" />
+    <file baseinstalldir="/" name="third_party/upb/upb/upb_internal.h" role="src" />
     <file baseinstalldir="/" name="third_party/xxhash/xxhash.h" role="src" />
     <file baseinstalldir="/" name="third_party/zlib/adler32.c" role="src" />
     <file baseinstalldir="/" name="third_party/zlib/compress.c" role="src" />
index 417fe4f..57deb95 100644 (file)
@@ -3,7 +3,7 @@ coverage==4.5.4
 cython==0.29.21
 enum34==1.1.10
 protobuf>=3.5.0.post1, < 4.0dev
-six==1.15.0
+six==1.16.0
 wheel==0.36.2
 futures==3.1.1
 google-auth==1.24.0
index 65c7c37..4d34c43 100644 (file)
--- a/setup.py
+++ b/setup.py
@@ -104,6 +104,7 @@ CLASSIFIERS = [
     'Programming Language :: Python :: 3.7',
     'Programming Language :: Python :: 3.8',
     'Programming Language :: Python :: 3.9',
+    'Programming Language :: Python :: 3.10',
     'License :: OSI Approved :: Apache Software License',
 ]
 
index 3c899d0..fb08550 100644 (file)
@@ -1,4 +1,4 @@
-// generated by generate_boringssl_prefix_header.sh on BoringSSL commit: bcc01b6c66b1c6fa2816b108e50a544b757fbd7b
+// generated by generate_boringssl_prefix_header.sh on BoringSSL commit: fc44652a42b396e1645d5e72aba053349992136a
 
 // Copyright (c) 2018, Google Inc.
 //
 #define SSL_get0_alpn_selected BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, SSL_get0_alpn_selected)
 #define SSL_get0_certificate_types BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, SSL_get0_certificate_types)
 #define SSL_get0_chain_certs BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, SSL_get0_chain_certs)
+#define SSL_get0_ech_name_override BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, SSL_get0_ech_name_override)
+#define SSL_get0_ech_retry_configs BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, SSL_get0_ech_retry_configs)
 #define SSL_get0_next_proto_negotiated BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, SSL_get0_next_proto_negotiated)
 #define SSL_get0_ocsp_response BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, SSL_get0_ocsp_response)
 #define SSL_get0_param BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, SSL_get0_param)
 #define ASN1_BIT_STRING_get_bit BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, ASN1_BIT_STRING_get_bit)
 #define ASN1_BIT_STRING_it BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, ASN1_BIT_STRING_it)
 #define ASN1_BIT_STRING_new BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, ASN1_BIT_STRING_new)
+#define ASN1_BIT_STRING_num_bytes BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, ASN1_BIT_STRING_num_bytes)
 #define ASN1_BIT_STRING_set BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, ASN1_BIT_STRING_set)
 #define ASN1_BIT_STRING_set_bit BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, ASN1_BIT_STRING_set_bit)
 #define ASN1_BMPSTRING_free BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, ASN1_BMPSTRING_free)
 #define CRYPTO_set_locking_callback BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, CRYPTO_set_locking_callback)
 #define CRYPTO_set_thread_local BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, CRYPTO_set_thread_local)
 #define CRYPTO_sysrand BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, CRYPTO_sysrand)
+#define CRYPTO_sysrand_for_seed BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, CRYPTO_sysrand_for_seed)
 #define CRYPTO_sysrand_if_available BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, CRYPTO_sysrand_if_available)
 #define CRYPTO_tls1_prf BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, CRYPTO_tls1_prf)
 #define CTR_DRBG_clear BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, CTR_DRBG_clear)
 #define EVP_HPKE_CTX_aead BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, EVP_HPKE_CTX_aead)
 #define EVP_HPKE_CTX_cleanup BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, EVP_HPKE_CTX_cleanup)
 #define EVP_HPKE_CTX_export BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, EVP_HPKE_CTX_export)
+#define EVP_HPKE_CTX_free BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, EVP_HPKE_CTX_free)
 #define EVP_HPKE_CTX_kdf BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, EVP_HPKE_CTX_kdf)
 #define EVP_HPKE_CTX_max_overhead BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, EVP_HPKE_CTX_max_overhead)
+#define EVP_HPKE_CTX_new BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, EVP_HPKE_CTX_new)
 #define EVP_HPKE_CTX_open BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, EVP_HPKE_CTX_open)
 #define EVP_HPKE_CTX_seal BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, EVP_HPKE_CTX_seal)
 #define EVP_HPKE_CTX_setup_recipient BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, EVP_HPKE_CTX_setup_recipient)
 #define EVP_HPKE_KEM_id BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, EVP_HPKE_KEM_id)
 #define EVP_HPKE_KEY_cleanup BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, EVP_HPKE_KEY_cleanup)
 #define EVP_HPKE_KEY_copy BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, EVP_HPKE_KEY_copy)
+#define EVP_HPKE_KEY_free BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, EVP_HPKE_KEY_free)
 #define EVP_HPKE_KEY_generate BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, EVP_HPKE_KEY_generate)
 #define EVP_HPKE_KEY_init BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, EVP_HPKE_KEY_init)
 #define EVP_HPKE_KEY_kem BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, EVP_HPKE_KEY_kem)
+#define EVP_HPKE_KEY_new BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, EVP_HPKE_KEY_new)
 #define EVP_HPKE_KEY_private_key BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, EVP_HPKE_KEY_private_key)
 #define EVP_HPKE_KEY_public_key BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, EVP_HPKE_KEY_public_key)
 #define EVP_HPKE_KEY_zero BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, EVP_HPKE_KEY_zero)
 #define EVP_MD_block_size BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, EVP_MD_block_size)
 #define EVP_MD_flags BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, EVP_MD_flags)
 #define EVP_MD_meth_get_flags BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, EVP_MD_meth_get_flags)
+#define EVP_MD_nid BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, EVP_MD_nid)
 #define EVP_MD_size BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, EVP_MD_size)
 #define EVP_MD_type BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, EVP_MD_type)
 #define EVP_PBE_scrypt BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, EVP_PBE_scrypt)
 #define OPENSSL_hash32 BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, OPENSSL_hash32)
 #define OPENSSL_ia32cap_P BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, OPENSSL_ia32cap_P)
 #define OPENSSL_init_crypto BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, OPENSSL_init_crypto)
+#define OPENSSL_lh_delete BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, OPENSSL_lh_delete)
+#define OPENSSL_lh_doall_arg BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, OPENSSL_lh_doall_arg)
+#define OPENSSL_lh_free BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, OPENSSL_lh_free)
+#define OPENSSL_lh_insert BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, OPENSSL_lh_insert)
+#define OPENSSL_lh_new BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, OPENSSL_lh_new)
+#define OPENSSL_lh_num_items BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, OPENSSL_lh_num_items)
+#define OPENSSL_lh_retrieve BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, OPENSSL_lh_retrieve)
+#define OPENSSL_lh_retrieve_key BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, OPENSSL_lh_retrieve_key)
 #define OPENSSL_load_builtin_modules BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, OPENSSL_load_builtin_modules)
 #define OPENSSL_malloc BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, OPENSSL_malloc)
 #define OPENSSL_malloc_init BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, OPENSSL_malloc_init)
 #define OPENSSL_realloc BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, OPENSSL_realloc)
 #define OPENSSL_strcasecmp BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, OPENSSL_strcasecmp)
 #define OPENSSL_strdup BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, OPENSSL_strdup)
+#define OPENSSL_strhash BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, OPENSSL_strhash)
 #define OPENSSL_strlcat BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, OPENSSL_strlcat)
 #define OPENSSL_strlcpy BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, OPENSSL_strlcpy)
 #define OPENSSL_strncasecmp BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, OPENSSL_strncasecmp)
 #define X509at_add1_attr_by_OBJ BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, X509at_add1_attr_by_OBJ)
 #define X509at_add1_attr_by_txt BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, X509at_add1_attr_by_txt)
 #define X509at_delete_attr BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, X509at_delete_attr)
-#define X509at_get0_data_by_OBJ BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, X509at_get0_data_by_OBJ)
 #define X509at_get_attr BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, X509at_get_attr)
 #define X509at_get_attr_by_NID BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, X509at_get_attr_by_NID)
 #define X509at_get_attr_by_OBJ BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, X509at_get_attr_by_OBJ)
 #define kOpenSSLReasonValuesLen BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, kOpenSSLReasonValuesLen)
 #define level_add_node BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, level_add_node)
 #define level_find_node BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, level_find_node)
-#define lh_delete BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, lh_delete)
-#define lh_doall_arg BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, lh_doall_arg)
-#define lh_free BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, lh_free)
-#define lh_insert BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, lh_insert)
-#define lh_new BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, lh_new)
-#define lh_num_items BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, lh_num_items)
-#define lh_retrieve BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, lh_retrieve)
-#define lh_retrieve_key BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, lh_retrieve_key)
-#define lh_strhash BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, lh_strhash)
 #define md4_block_data_order BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, md4_block_data_order)
 #define md5_block_asm_data_order BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, md5_block_asm_data_order)
 #define o2i_ECPublicKey BORINGSSL_ADD_PREFIX(BORINGSSL_PREFIX, o2i_ECPublicKey)
index f25f394..49c7875 100644 (file)
 #ifndef SRC_COMPILER_CONFIG_H
 #define SRC_COMPILER_CONFIG_H
 
-#include "src/compiler/config_protobuf.h"
-
 #include <string>
 
+#include "src/compiler/config_protobuf.h"
+
 #ifdef GRPC_CUSTOM_STRING
 #warning GRPC_CUSTOM_STRING is no longer supported. Please use std::string.
 #endif
index 37178d9..f528328 100644 (file)
  *
  */
 
-#include <map>
-
 #include "src/compiler/cpp_generator.h"
 
+#include <map>
 #include <sstream>
 
 namespace grpc_cpp_generator {
index a3a0f33..3d6f19e 100644 (file)
@@ -23,7 +23,6 @@
 #include <sstream>
 
 #include "src/compiler/config.h"
-
 #include "src/compiler/cpp_generator.h"
 #include "src/compiler/generator_helpers.h"
 #include "src/compiler/protobuf_plugin.h"
index 21968c6..b42c07c 100644 (file)
  *
  */
 
+#include "src/compiler/csharp_generator.h"
+
 #include <cctype>
 #include <map>
 #include <sstream>
 #include <vector>
 
 #include "src/compiler/config.h"
-#include "src/compiler/csharp_generator.h"
 #include "src/compiler/csharp_generator_helpers.h"
 
 using grpc::protobuf::Descriptor;
index 465ac7e..8c9f026 100644 (file)
  *
  */
 
+#include "src/compiler/node_generator.h"
+
 #include <map>
 
 #include "src/compiler/config.h"
 #include "src/compiler/generator_helpers.h"
-#include "src/compiler/node_generator.h"
 #include "src/compiler/node_generator_helpers.h"
 
 using grpc::protobuf::Descriptor;
index c8f1c43..cd05ae7 100644 (file)
  *
  */
 
+#include "src/compiler/objective_c_generator.h"
+
 #include <map>
 #include <set>
 #include <sstream>
 
+#include <google/protobuf/compiler/objectivec/objectivec_helpers.h>
+
 #include "src/compiler/config.h"
-#include "src/compiler/objective_c_generator.h"
 #include "src/compiler/objective_c_generator_helpers.h"
 
-#include <google/protobuf/compiler/objectivec/objectivec_helpers.h>
-
 using ::google::protobuf::compiler::objectivec::ClassName;
 using ::grpc::protobuf::FileDescriptor;
 using ::grpc::protobuf::MethodDescriptor;
index f9320f0..4260411 100644 (file)
 #define GRPC_INTERNAL_COMPILER_OBJECTIVE_C_GENERATOR_HELPERS_H
 
 #include <map>
-#include "src/compiler/config.h"
-#include "src/compiler/generator_helpers.h"
 
 #include <google/protobuf/compiler/objectivec/objectivec_helpers.h>
 
+#include "src/compiler/config.h"
+#include "src/compiler/generator_helpers.h"
+
 namespace grpc_objective_c_generator {
 
 using ::grpc::protobuf::FileDescriptor;
index 7f4a0d3..8cc3fdf 100644 (file)
 
 #include <memory>
 
+#include <google/protobuf/compiler/objectivec/objectivec_helpers.h>
+
 #include "src/compiler/config.h"
 #include "src/compiler/objective_c_generator.h"
 #include "src/compiler/objective_c_generator_helpers.h"
 
-#include <google/protobuf/compiler/objectivec/objectivec_helpers.h>
-
 using ::google::protobuf::compiler::objectivec::
     IsProtobufLibraryBundledProtoFile;
 using ::google::protobuf::compiler::objectivec::ProtobufLibraryFrameworkName;
index 28bbebd..78d9541 100644 (file)
@@ -19,6 +19,7 @@
 #include <map>
 
 #include <google/protobuf/compiler/php/php_generator.h>
+
 #include "src/compiler/config.h"
 #include "src/compiler/generator_helpers.h"
 #include "src/compiler/php_generator_helpers.h"
index 951ff5e..0a7aa41 100644 (file)
 #ifndef GRPC_INTERNAL_COMPILER_PROTOBUF_PLUGIN_H
 #define GRPC_INTERNAL_COMPILER_PROTOBUF_PLUGIN_H
 
+#include <vector>
+
 #include "src/compiler/config.h"
 #include "src/compiler/cpp_generator_helpers.h"
 #include "src/compiler/python_generator_helpers.h"
 #include "src/compiler/python_private_generator.h"
 #include "src/compiler/schema_interface.h"
 
-#include <vector>
-
 // Get leading or trailing comments in a string.
 template <typename DescriptorType>
 inline std::string GetCommentsHelper(const DescriptorType* desc, bool leading,
index 40e79b5..753fe1c 100644 (file)
@@ -16,6 +16,8 @@
  *
  */
 
+#include "src/compiler/python_generator.h"
+
 #include <algorithm>
 #include <cassert>
 #include <cctype>
@@ -33,7 +35,6 @@
 #include "src/compiler/config.h"
 #include "src/compiler/generator_helpers.h"
 #include "src/compiler/protobuf_plugin.h"
-#include "src/compiler/python_generator.h"
 #include "src/compiler/python_generator_helpers.h"
 #include "src/compiler/python_private_generator.h"
 
index e045c96..c553e1c 100644 (file)
  *
  */
 
+#include "src/compiler/ruby_generator.h"
+
 #include <cctype>
 #include <map>
 #include <vector>
 
 #include "src/compiler/config.h"
-#include "src/compiler/ruby_generator.h"
 #include "src/compiler/ruby_generator_helpers-inl.h"
 #include "src/compiler/ruby_generator_map-inl.h"
 #include "src/compiler/ruby_generator_string-inl.h"
index 5f85abc..8951552 100644 (file)
 #ifndef GRPC_INTERNAL_COMPILER_RUBY_GENERATOR_MAP_INL_H
 #define GRPC_INTERNAL_COMPILER_RUBY_GENERATOR_MAP_INL_H
 
-#include "src/compiler/config.h"
-
 #include <initializer_list>
 #include <iostream>
 #include <map>
 #include <ostream>  // NOLINT
 #include <vector>
 
+#include "src/compiler/config.h"
+
 using std::initializer_list;
 using std::map;
 using std::vector;
index 968f795..feaa495 100644 (file)
 #ifndef GRPC_INTERNAL_COMPILER_RUBY_GENERATOR_STRING_INL_H
 #define GRPC_INTERNAL_COMPILER_RUBY_GENERATOR_STRING_INL_H
 
-#include "src/compiler/config.h"
-
 #include <algorithm>
 #include <sstream>
 #include <vector>
 
+#include "src/compiler/config.h"
+
 using std::getline;
 using std::transform;
 
index f1a255a..2e2bdd3 100644 (file)
 #ifndef GRPC_INTERNAL_COMPILER_SCHEMA_INTERFACE_H
 #define GRPC_INTERNAL_COMPILER_SCHEMA_INTERFACE_H
 
-#include "src/compiler/config.h"
-
 #include <memory>
 #include <string>
 #include <vector>
 
+#include "src/compiler/config.h"
+
 #ifdef GRPC_CUSTOM_STRING
 #warning GRPC_CUSTOM_STRING is no longer supported. Please use std::string.
 #endif
index 599a798..6659f70 100644 (file)
@@ -20,6 +20,7 @@
 
 #include <grpc/census.h>
 #include <grpc/grpc.h>
+
 #include "src/core/lib/surface/api_trace.h"
 #include "src/core/lib/surface/call.h"
 
index 441657e..964339e 100644 (file)
@@ -19,7 +19,6 @@
 #include "src/core/ext/filters/client_channel/backend_metric.h"
 
 #include "absl/strings/string_view.h"
-
 #include "udpa/data/orca/v1/orca_load_report.upb.h"
 #include "upb/upb.hpp"
 
index b412081..ae47353 100644 (file)
@@ -22,6 +22,7 @@
 #include <grpc/support/port_platform.h>
 
 #include <grpc/grpc.h>
+
 #include "src/core/lib/channel/channel_stack.h"
 #include "src/core/lib/gprpp/global_config.h"
 
index e5ec5c5..a656294 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include "src/core/lib/surface/channel.h"
-
 #include <grpc/support/log.h>
 
 #include "src/core/ext/filters/client_channel/client_channel.h"
 #include "src/core/lib/iomgr/timer.h"
 #include "src/core/lib/surface/api_trace.h"
+#include "src/core/lib/surface/channel.h"
 #include "src/core/lib/surface/completion_queue.h"
 
 grpc_connectivity_state grpc_channel_check_connectivity_state(
index 96531d4..da04ec0 100644 (file)
 
 #include <set>
 
+#include "absl/container/inlined_vector.h"
 #include "absl/strings/numbers.h"
 #include "absl/strings/str_cat.h"
 #include "absl/strings/str_join.h"
 #include "absl/strings/string_view.h"
+#include "absl/types/optional.h"
 
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/string_util.h>
 #include <grpc/support/sync.h>
 
-#include "absl/container/inlined_vector.h"
-#include "absl/types/optional.h"
-
 #include "src/core/ext/filters/client_channel/backend_metric.h"
 #include "src/core/ext/filters/client_channel/backup_poller.h"
 #include "src/core/ext/filters/client_channel/config_selector.h"
@@ -811,8 +810,8 @@ void ClientChannel::ExternalConnectivityWatcher::
 void ClientChannel::ExternalConnectivityWatcher::Notify(
     grpc_connectivity_state state, const absl::Status& /* status */) {
   bool done = false;
-  if (!done_.CompareExchangeStrong(&done, true, MemoryOrder::RELAXED,
-                                   MemoryOrder::RELAXED)) {
+  if (!done_.compare_exchange_strong(done, true, std::memory_order_relaxed,
+                                     std::memory_order_relaxed)) {
     return;  // Already done.
   }
   // Remove external watcher.
@@ -835,8 +834,8 @@ void ClientChannel::ExternalConnectivityWatcher::Notify(
 
 void ClientChannel::ExternalConnectivityWatcher::Cancel() {
   bool done = false;
-  if (!done_.CompareExchangeStrong(&done, true, MemoryOrder::RELAXED,
-                                   MemoryOrder::RELAXED)) {
+  if (!done_.compare_exchange_strong(done, true, std::memory_order_relaxed,
+                                     std::memory_order_relaxed)) {
     return;  // Already done.
   }
   ExecCtx::Run(DEBUG_LOCATION, on_complete_, GRPC_ERROR_CANCELLED);
@@ -1142,9 +1141,8 @@ ClientChannel::ClientChannel(grpc_channel_element_args* args,
       channel_args_, GRPC_ARG_KEEPALIVE_TIME_MS,
       {-1 /* default value, unset */, 1, INT_MAX});
   if (!ResolverRegistry::IsValidTarget(target_uri_.get())) {
-    std::string error_message =
-        absl::StrCat("the target uri is not valid: ", target_uri_.get());
-    *error = GRPC_ERROR_CREATE_FROM_COPIED_STRING(error_message.c_str());
+    *error = GRPC_ERROR_CREATE_FROM_CPP_STRING(
+        absl::StrCat("the target uri is not valid: ", target_uri_.get()));
     return;
   }
   *error = GRPC_ERROR_NONE;
@@ -1160,7 +1158,7 @@ ClientChannel::~ClientChannel() {
   // Stop backup polling.
   grpc_client_channel_stop_backup_polling(interested_parties_);
   grpc_pollset_set_destroy(interested_parties_);
-  GRPC_ERROR_UNREF(disconnect_error_.Load(MemoryOrder::RELAXED));
+  GRPC_ERROR_UNREF(disconnect_error_.load(std::memory_order_relaxed));
 }
 
 OrphanablePtr<ClientChannel::LoadBalancedCall>
@@ -1803,9 +1801,10 @@ void ClientChannel::StartTransportOpLocked(grpc_transport_op* op) {
       GRPC_ERROR_UNREF(op->disconnect_with_error);
     } else {
       // Disconnect.
-      GPR_ASSERT(disconnect_error_.Load(MemoryOrder::RELAXED) ==
+      GPR_ASSERT(disconnect_error_.load(std::memory_order_relaxed) ==
                  GRPC_ERROR_NONE);
-      disconnect_error_.Store(op->disconnect_with_error, MemoryOrder::RELEASE);
+      disconnect_error_.store(op->disconnect_with_error,
+                              std::memory_order_release);
       UpdateStateAndPickerLocked(
           GRPC_CHANNEL_SHUTDOWN, absl::Status(), "shutdown from API",
           absl::make_unique<LoadBalancingPolicy::TransientFailurePicker>(
@@ -2500,48 +2499,21 @@ class ClientChannel::LoadBalancedCall::Metadata
                GRPC_ERROR_NONE);
   }
 
-  iterator begin() const override {
-    static_assert(sizeof(grpc_linked_mdelem*) <= sizeof(intptr_t),
-                  "iterator size too large");
-    return iterator(
-        this, reinterpret_cast<intptr_t>(MaybeSkipEntry(batch_->list.head)));
-  }
-  iterator end() const override {
-    static_assert(sizeof(grpc_linked_mdelem*) <= sizeof(intptr_t),
-                  "iterator size too large");
-    return iterator(this, 0);
-  }
-
-  iterator erase(iterator it) override {
-    grpc_linked_mdelem* linked_mdelem =
-        reinterpret_cast<grpc_linked_mdelem*>(GetIteratorHandle(it));
-    intptr_t handle = reinterpret_cast<intptr_t>(linked_mdelem->next);
-    grpc_metadata_batch_remove(batch_, linked_mdelem);
-    return iterator(this, handle);
-  }
-
- private:
-  grpc_linked_mdelem* MaybeSkipEntry(grpc_linked_mdelem* entry) const {
-    if (entry != nullptr && batch_->idx.named.path == entry) {
-      return entry->next;
+  std::vector<std::pair<std::string, std::string>> TestOnlyCopyToVector()
+      override {
+    std::vector<std::pair<std::string, std::string>> result;
+    for (grpc_linked_mdelem* entry = batch_->list.head; entry != nullptr;
+         entry = entry->next) {
+      if (batch_->idx.named.path != entry) {
+        result.push_back(std::make_pair(
+            std::string(StringViewFromSlice(GRPC_MDKEY(entry->md))),
+            std::string(StringViewFromSlice(GRPC_MDVALUE(entry->md)))));
+      }
     }
-    return entry;
-  }
-
-  intptr_t IteratorHandleNext(intptr_t handle) const override {
-    grpc_linked_mdelem* linked_mdelem =
-        reinterpret_cast<grpc_linked_mdelem*>(handle);
-    return reinterpret_cast<intptr_t>(MaybeSkipEntry(linked_mdelem->next));
-  }
-
-  std::pair<absl::string_view, absl::string_view> IteratorHandleGet(
-      intptr_t handle) const override {
-    grpc_linked_mdelem* linked_mdelem =
-        reinterpret_cast<grpc_linked_mdelem*>(handle);
-    return std::make_pair(StringViewFromSlice(GRPC_MDKEY(linked_mdelem->md)),
-                          StringViewFromSlice(GRPC_MDVALUE(linked_mdelem->md)));
+    return result;
   }
 
+ private:
   LoadBalancedCall* lb_call_;
   grpc_metadata_batch* batch_;
 };
index 44594ab..7ff217e 100644 (file)
@@ -183,7 +183,7 @@ class ClientChannel {
     grpc_connectivity_state* state_;
     grpc_closure* on_complete_;
     grpc_closure* watcher_timer_init_;
-    Atomic<bool> done_{false};
+    std::atomic<bool> done_{false};
   };
 
   struct ResolverQueuedCall {
@@ -209,7 +209,7 @@ class ClientChannel {
 
   // Note: Does NOT return a new ref.
   grpc_error_handle disconnect_error() const {
-    return disconnect_error_.Load(MemoryOrder::ACQUIRE);
+    return disconnect_error_.load(std::memory_order_acquire);
   }
 
   // Note: All methods with "Locked" suffix must be invoked from within
@@ -348,7 +348,7 @@ class ClientChannel {
   // Fields accessed from both data plane mutex and control plane
   // work_serializer.
   //
-  Atomic<grpc_error_handle> disconnect_error_;
+  std::atomic<grpc_error_handle> disconnect_error_{GRPC_ERROR_NONE};
 
   //
   // Fields guarded by a mutex, since they need to be accessed
index 9a9e3b7..d543aa4 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include "src/core/ext/filters/client_channel/client_channel.h"
 #include "src/core/ext/filters/client_channel/client_channel_channelz.h"
+
+#include <grpc/support/string_util.h>
+
+#include "src/core/ext/filters/client_channel/client_channel.h"
 #include "src/core/lib/channel/channelz_registry.h"
 #include "src/core/lib/gpr/useful.h"
 #include "src/core/lib/surface/channel.h"
 #include "src/core/lib/transport/connectivity_state.h"
 
-#include <grpc/support/string_util.h>
-
 namespace grpc_core {
 namespace channelz {
 
@@ -39,7 +40,7 @@ SubchannelNode::SubchannelNode(std::string target_address,
 SubchannelNode::~SubchannelNode() {}
 
 void SubchannelNode::UpdateConnectivityState(grpc_connectivity_state state) {
-  connectivity_state_.Store(state, MemoryOrder::RELAXED);
+  connectivity_state_.store(state, std::memory_order_relaxed);
 }
 
 void SubchannelNode::SetChildSocket(RefCountedPtr<SocketNode> socket) {
@@ -50,7 +51,7 @@ void SubchannelNode::SetChildSocket(RefCountedPtr<SocketNode> socket) {
 Json SubchannelNode::RenderJson() {
   // Create and fill the data child.
   grpc_connectivity_state state =
-      connectivity_state_.Load(MemoryOrder::RELAXED);
+      connectivity_state_.load(std::memory_order_relaxed);
   Json::Object data = {
       {"state",
        Json::Object{
index a106897..2f53098 100644 (file)
@@ -61,7 +61,7 @@ class SubchannelNode : public BaseNode {
   void RecordCallSucceeded() { call_counter_.RecordCallSucceeded(); }
 
  private:
-  Atomic<grpc_connectivity_state> connectivity_state_{GRPC_CHANNEL_IDLE};
+  std::atomic<grpc_connectivity_state> connectivity_state_{GRPC_CHANNEL_IDLE};
   Mutex socket_mu_;
   RefCountedPtr<SocketNode> child_socket_ ABSL_GUARDED_BY(socket_mu_);
   std::string target_;
index c0d853e..caaf963 100644 (file)
@@ -19,6 +19,7 @@
 #include <grpc/support/port_platform.h>
 
 #include "src/core/ext/filters/client_channel/client_channel_factory.h"
+
 #include "src/core/lib/channel/channel_args.h"
 
 // Channel arg key for client channel factory.
index 1d33d25..8bd41f2 100644 (file)
@@ -58,7 +58,6 @@ void grpc_client_channel_init(void) {
       GRPC_CLIENT_CHANNEL, GRPC_CHANNEL_INIT_BUILTIN_PRIORITY, append_filter,
       const_cast<grpc_channel_filter*>(
           &grpc_core::ClientChannel::kFilterVtable));
-  grpc_http_connect_register_handshaker_factory();
   grpc_client_channel_global_init_backup_polling();
 }
 
@@ -71,3 +70,11 @@ void grpc_client_channel_shutdown(void) {
   grpc_core::LoadBalancingPolicyRegistry::Builder::ShutdownRegistry();
   grpc_core::ServiceConfigParser::Shutdown();
 }
+
+namespace grpc_core {
+
+void BuildClientChannelConfiguration(CoreConfiguration::Builder* builder) {
+  RegisterHttpConnectHandshaker(builder);
+}
+
+}  // namespace grpc_core
index 0c2a08e..c631adb 100644 (file)
@@ -17,6 +17,7 @@
 #include <grpc/support/port_platform.h>
 
 #include "src/core/ext/filters/client_channel/config_selector.h"
+
 #include "src/core/lib/channel/channel_args.h"
 
 namespace grpc_core {
index d33366c..d8f4455 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
+#include "src/core/ext/filters/client_channel/health/health_check_client.h"
+
 #include <stdint.h>
 #include <stdio.h>
 
-#include "src/core/ext/filters/client_channel/health/health_check_client.h"
-
 #include "upb/upb.hpp"
 
 #include "src/core/lib/debug/trace.h"
@@ -425,8 +425,9 @@ void HealthCheckClient::CallState::StartCancel(void* arg,
 
 void HealthCheckClient::CallState::Cancel() {
   bool expected = false;
-  if (cancelled_.CompareExchangeStrong(&expected, true, MemoryOrder::ACQ_REL,
-                                       MemoryOrder::ACQUIRE)) {
+  if (cancelled_.compare_exchange_strong(expected, true,
+                                         std::memory_order_acq_rel,
+                                         std::memory_order_acquire)) {
     call_->Ref(DEBUG_LOCATION, "cancel").release();
     GRPC_CALL_COMBINER_START(
         &call_combiner_,
@@ -471,7 +472,7 @@ void HealthCheckClient::CallState::DoneReadingRecvMessage(
       state, error == GRPC_ERROR_NONE && !healthy
                  ? "backend unhealthy"
                  : grpc_error_std_string(error).c_str());
-  seen_response_.Store(true, MemoryOrder::RELEASE);
+  seen_response_.store(true, std::memory_order_release);
   grpc_slice_buffer_destroy_internal(&recv_message_buffer_);
   // Start another recv_message batch.
   // This re-uses the ref we're holding.
@@ -598,7 +599,7 @@ void HealthCheckClient::CallState::CallEndedLocked(bool retry) {
     health_check_client_->call_state_.reset();
     if (retry) {
       GPR_ASSERT(!health_check_client_->shutting_down_);
-      if (seen_response_.Load(MemoryOrder::ACQUIRE)) {
+      if (seen_response_.load(std::memory_order_acquire)) {
         // If the call fails after we've gotten a successful response, reset
         // the backoff and restart the call immediately.
         health_check_client_->retry_backoff_.Reset();
index 7f61d84..b20e8d8 100644 (file)
@@ -21,6 +21,8 @@
 
 #include <grpc/support/port_platform.h>
 
+#include <atomic>
+
 #include <grpc/grpc.h>
 #include <grpc/support/sync.h>
 
@@ -28,7 +30,6 @@
 #include "src/core/ext/filters/client_channel/subchannel.h"
 #include "src/core/lib/backoff/backoff.h"
 #include "src/core/lib/gprpp/arena.h"
-#include "src/core/lib/gprpp/atomic.h"
 #include "src/core/lib/gprpp/orphanable.h"
 #include "src/core/lib/gprpp/ref_counted_ptr.h"
 #include "src/core/lib/gprpp/sync.h"
@@ -126,10 +127,10 @@ class HealthCheckClient : public InternallyRefCounted<HealthCheckClient> {
     OrphanablePtr<ByteStream> recv_message_;
     grpc_closure recv_message_ready_;
     grpc_slice_buffer recv_message_buffer_;
-    Atomic<bool> seen_response_{false};
+    std::atomic<bool> seen_response_{false};
 
     // True if the cancel_stream batch has been started.
-    Atomic<bool> cancelled_{false};
+    std::atomic<bool> cancelled_{false};
 
     // recv_trailing_metadata
     grpc_metadata_batch recv_trailing_metadata_;
index 3dff824..4140f6c 100644 (file)
@@ -32,7 +32,9 @@
 #include "src/core/ext/filters/client_channel/client_channel.h"
 #include "src/core/ext/filters/client_channel/resolver_registry.h"
 #include "src/core/lib/channel/channel_args.h"
+#include "src/core/lib/channel/handshaker.h"
 #include "src/core/lib/channel/handshaker_registry.h"
+#include "src/core/lib/config/core_configuration.h"
 #include "src/core/lib/gpr/string.h"
 #include "src/core/lib/gprpp/sync.h"
 #include "src/core/lib/http/format_request.h"
@@ -246,10 +248,9 @@ void HttpConnectHandshaker::OnReadDone(void* arg, grpc_error_handle error) {
   // Make sure we got a 2xx response.
   if (handshaker->http_response_.status < 200 ||
       handshaker->http_response_.status >= 300) {
-    error = GRPC_ERROR_CREATE_FROM_COPIED_STRING(
+    error = GRPC_ERROR_CREATE_FROM_CPP_STRING(
         absl::StrCat("HTTP proxy returned response code ",
-                     handshaker->http_response_.status)
-            .c_str());
+                     handshaker->http_response_.status));
     handshaker->HandshakeFailedLocked(error);
     goto done;
   }
@@ -382,10 +383,10 @@ class HttpConnectHandshakerFactory : public HandshakerFactory {
 
 }  // namespace
 
-}  // namespace grpc_core
-
-void grpc_http_connect_register_handshaker_factory() {
-  grpc_core::HandshakerRegistry::RegisterHandshakerFactory(
+void RegisterHttpConnectHandshaker(CoreConfiguration::Builder* builder) {
+  builder->handshaker_registry()->RegisterHandshakerFactory(
       true /* at_start */, grpc_core::HANDSHAKER_CLIENT,
       absl::make_unique<grpc_core::HttpConnectHandshakerFactory>());
 }
+
+}  // namespace grpc_core
index 26c31f2..31d25c2 100644 (file)
 #ifndef GRPC_CORE_EXT_FILTERS_CLIENT_CHANNEL_HTTP_CONNECT_HANDSHAKER_H
 #define GRPC_CORE_EXT_FILTERS_CLIENT_CHANNEL_HTTP_CONNECT_HANDSHAKER_H
 
+#include <grpc/impl/codegen/port_platform.h>
+
+#include "src/core/lib/config/core_configuration.h"
+
 /// Channel arg indicating the server in HTTP CONNECT request (string).
 /// The presence of this arg triggers the use of HTTP CONNECT.
 #define GRPC_ARG_HTTP_CONNECT_SERVER "grpc.http_connect_server"
 /// separated by colons.
 #define GRPC_ARG_HTTP_CONNECT_HEADERS "grpc.http_connect_headers"
 
-/// Registers handshaker factory.
-void grpc_http_connect_register_handshaker_factory();
+namespace grpc_core {
+
+// Register the HTTP Connect handshaker into the configuration builder.
+void RegisterHttpConnectHandshaker(CoreConfiguration::Builder* builder);
+
+}  // namespace grpc_core
 
 #endif /* GRPC_CORE_EXT_FILTERS_CLIENT_CHANNEL_HTTP_CONNECT_HANDSHAKER_H */
index 68f1eb2..c7a78c1 100644 (file)
@@ -134,35 +134,16 @@ class LoadBalancingPolicy : public InternallyRefCounted<LoadBalancingPolicy> {
   /// Implemented by the client channel and used by the SubchannelPicker.
   class MetadataInterface {
    public:
-    class iterator
-        : public std::iterator<
-              std::input_iterator_tag,
-              std::pair<absl::string_view, absl::string_view>,  // value_type
-              std::ptrdiff_t,  // difference_type
-              std::pair<absl::string_view, absl::string_view>*,  // pointer
-              std::pair<absl::string_view, absl::string_view>&   // reference
-              > {
-     public:
-      iterator(const MetadataInterface* md, intptr_t handle)
-          : md_(md), handle_(handle) {}
-      iterator& operator++() {
-        handle_ = md_->IteratorHandleNext(handle_);
-        return *this;
-      }
-      bool operator==(iterator other) const {
-        return md_ == other.md_ && handle_ == other.handle_;
-      }
-      bool operator!=(iterator other) const { return !(*this == other); }
-      value_type operator*() const { return md_->IteratorHandleGet(handle_); }
-
-     private:
-      friend class MetadataInterface;
-      const MetadataInterface* md_;
-      intptr_t handle_;
-    };
-
     virtual ~MetadataInterface() = default;
 
+    //////////////////////////////////////////////////////////////////////////
+    // TODO(ctiller): DO NOT MAKE THIS A PUBLIC API YET
+    // This needs some API design to ensure we can add/remove/replace metadata
+    // keys... we're deliberately not doing so to save some time whilst
+    // cleaning up the internal metadata representation, but we should add
+    // something back before making this a public API.
+    //////////////////////////////////////////////////////////////////////////
+
     /// Adds a key/value pair.
     /// Does NOT take ownership of \a key or \a value.
     /// Implementations must ensure that the key and value remain alive
@@ -170,23 +151,9 @@ class LoadBalancingPolicy : public InternallyRefCounted<LoadBalancingPolicy> {
     /// CallState::Alloc().
     virtual void Add(absl::string_view key, absl::string_view value) = 0;
 
-    /// Iteration interface.
-    virtual iterator begin() const = 0;
-    virtual iterator end() const = 0;
-
-    /// Removes the element pointed to by \a it.
-    /// Returns an iterator pointing to the next element.
-    virtual iterator erase(iterator it) = 0;
-
-   protected:
-    intptr_t GetIteratorHandle(const iterator& it) const { return it.handle_; }
-
-   private:
-    friend class iterator;
-
-    virtual intptr_t IteratorHandleNext(intptr_t handle) const = 0;
-    virtual std::pair<absl::string_view /*key*/, absl::string_view /*value */>
-    IteratorHandleGet(intptr_t handle) const = 0;
+    /// Produce a vector of metadata key/value strings for tests.
+    virtual std::vector<std::pair<std::string, std::string>>
+    TestOnlyCopyToVector() = 0;
   };
 
   /// Arguments used when picking a subchannel for a call.
index 0edf61d..a307ce6 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include <cstring>
-
 #include "src/core/ext/filters/client_channel/lb_policy/child_policy_handler.h"
 
+#include <cstring>
+
 #include "absl/strings/str_cat.h"
 
 #include "src/core/ext/filters/client_channel/lb_policy_registry.h"
index ca50eda..95ec208 100644 (file)
 /// \see https://github.com/grpc/grpc/blob/master/doc/load-balancing.md for the
 /// high level design and details.
 
-// With the addition of a libuv endpoint, sockaddr.h now includes uv.h when
-// using that endpoint. Because of various transitive includes in uv.h,
-// including windows.h on Windows, uv.h must be included before other system
-// headers. Therefore, sockaddr.h must always be included first.
 #include <grpc/support/port_platform.h>
 
-#include "src/core/lib/iomgr/sockaddr.h"
-#include "src/core/lib/iomgr/socket_utils.h"
+#include "src/core/ext/filters/client_channel/lb_policy/grpclb/grpclb.h"
 
 #include <inttypes.h>
 #include <limits.h>
@@ -69,7 +64,6 @@
 #include "absl/strings/str_format.h"
 #include "absl/strings/str_join.h"
 #include "absl/strings/strip.h"
-
 #include "upb/upb.hpp"
 
 #include <grpc/byte_buffer_reader.h>
@@ -81,7 +75,6 @@
 #include "src/core/ext/filters/client_channel/client_channel.h"
 #include "src/core/ext/filters/client_channel/lb_policy/child_policy_handler.h"
 #include "src/core/ext/filters/client_channel/lb_policy/grpclb/client_load_reporting_filter.h"
-#include "src/core/ext/filters/client_channel/lb_policy/grpclb/grpclb.h"
 #include "src/core/ext/filters/client_channel/lb_policy/grpclb/grpclb_balancer_addresses.h"
 #include "src/core/ext/filters/client_channel/lb_policy/grpclb/grpclb_channel.h"
 #include "src/core/ext/filters/client_channel/lb_policy/grpclb/grpclb_client_stats.h"
 #include "src/core/lib/gprpp/orphanable.h"
 #include "src/core/lib/gprpp/ref_counted_ptr.h"
 #include "src/core/lib/iomgr/sockaddr.h"
+#include "src/core/lib/iomgr/socket_utils.h"
 #include "src/core/lib/iomgr/timer.h"
 #include "src/core/lib/slice/slice_internal.h"
 #include "src/core/lib/slice/slice_string_helpers.h"
index 07c5fd6..b8b4889 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include <grpc/grpc.h>
-
 #include "src/core/ext/filters/client_channel/lb_policy/grpclb/grpclb_channel.h"
 
+#include <grpc/grpc.h>
+
 namespace grpc_core {
 
 grpc_channel_args* ModifyGrpclbBalancerChannelArgs(grpc_channel_args* args) {
index 837cc09..a4a67ea 100644 (file)
@@ -18,8 +18,6 @@
 
 #include <grpc/support/port_platform.h>
 
-#include "src/core/ext/filters/client_channel/lb_policy/grpclb/grpclb_channel.h"
-
 #include <string.h>
 
 #include "absl/container/inlined_vector.h"
@@ -30,6 +28,7 @@
 
 #include "src/core/ext/filters/client_channel/client_channel.h"
 #include "src/core/ext/filters/client_channel/lb_policy/grpclb/grpclb_balancer_addresses.h"
+#include "src/core/ext/filters/client_channel/lb_policy/grpclb/grpclb_channel.h"
 #include "src/core/ext/filters/client_channel/server_address.h"
 #include "src/core/lib/address_utils/sockaddr_utils.h"
 #include "src/core/lib/channel/channel_args.h"
index d4104ec..e7b5d28 100644 (file)
 
 #include <string.h>
 
+#include "absl/memory/memory.h"
+
 #include <grpc/support/atm.h>
 #include <grpc/support/string_util.h>
 
-#include "absl/memory/memory.h"
-
 #include "src/core/lib/gprpp/sync.h"
 
 namespace grpc_core {
index c369827..a1d77bd 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include <grpc/support/atm.h>
-
 #include "absl/container/inlined_vector.h"
 
+#include <grpc/support/atm.h>
+
 #include "src/core/lib/gprpp/memory.h"
 #include "src/core/lib/gprpp/ref_counted.h"
 #include "src/core/lib/gprpp/sync.h"
index 2ba01c1..6213a5b 100644 (file)
 #include <grpc/support/port_platform.h>
 
 #include "src/core/ext/filters/client_channel/lb_policy/grpclb/load_balancer_api.h"
-#include "src/core/lib/gpr/useful.h"
 
 #include "google/protobuf/duration.upb.h"
 #include "google/protobuf/timestamp.upb.h"
 
 #include <grpc/support/alloc.h>
 
+#include "src/core/lib/gpr/useful.h"
+
 namespace grpc_core {
 
 bool GrpcLbServer::operator==(const GrpcLbServer& other) const {
index 1f8d44f..a35ae2e 100644 (file)
@@ -812,17 +812,15 @@ class PriorityLbFactory : public LoadBalancingPolicyFactory {
         const std::string& child_name = p.first;
         const Json& element = p.second;
         if (element.type() != Json::Type::OBJECT) {
-          error_list.push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
+          error_list.push_back(GRPC_ERROR_CREATE_FROM_CPP_STRING(
               absl::StrCat("field:children key:", child_name,
-                           " error:should be type object")
-                  .c_str()));
+                           " error:should be type object")));
         } else {
           auto it2 = element.object_value().find("config");
           if (it2 == element.object_value().end()) {
-            error_list.push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
+            error_list.push_back(GRPC_ERROR_CREATE_FROM_CPP_STRING(
                 absl::StrCat("field:children key:", child_name,
-                             " error:missing 'config' field")
-                    .c_str()));
+                             " error:missing 'config' field")));
           } else {
             grpc_error_handle parse_error = GRPC_ERROR_NONE;
             auto config = LoadBalancingPolicyRegistry::ParseLoadBalancingConfig(
@@ -836,11 +834,10 @@ class PriorityLbFactory : public LoadBalancingPolicyFactory {
               if (it3->second.type() == Json::Type::JSON_TRUE) {
                 ignore_resolution_requests = true;
               } else if (it3->second.type() != Json::Type::JSON_FALSE) {
-                error_list.push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
+                error_list.push_back(GRPC_ERROR_CREATE_FROM_CPP_STRING(
                     absl::StrCat("field:children key:", child_name,
                                  " field:ignore_reresolution_requests:should "
-                                 "be type boolean")
-                        .c_str()));
+                                 "be type boolean")));
               }
             }
             if (config == nullptr) {
@@ -872,26 +869,20 @@ class PriorityLbFactory : public LoadBalancingPolicyFactory {
       for (size_t i = 0; i < array.size(); ++i) {
         const Json& element = array[i];
         if (element.type() != Json::Type::STRING) {
-          error_list.push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-              absl::StrCat("field:priorities element:", i,
-                           " error:should be type string")
-                  .c_str()));
+          error_list.push_back(GRPC_ERROR_CREATE_FROM_CPP_STRING(absl::StrCat(
+              "field:priorities element:", i, " error:should be type string")));
         } else if (children.find(element.string_value()) == children.end()) {
-          error_list.push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-              absl::StrCat("field:priorities element:", i,
-                           " error:unknown child '", element.string_value(),
-                           "'")
-                  .c_str()));
+          error_list.push_back(GRPC_ERROR_CREATE_FROM_CPP_STRING(absl::StrCat(
+              "field:priorities element:", i, " error:unknown child '",
+              element.string_value(), "'")));
         } else {
           priorities.emplace_back(element.string_value());
         }
       }
       if (priorities.size() != children.size()) {
-        error_list.push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-            absl::StrCat("field:priorities error:priorities size (",
-                         priorities.size(), ") != children size (",
-                         children.size(), ")")
-                .c_str()));
+        error_list.push_back(GRPC_ERROR_CREATE_FROM_CPP_STRING(absl::StrCat(
+            "field:priorities error:priorities size (", priorities.size(),
+            ") != children size (", children.size(), ")")));
       }
     }
     if (error_list.empty()) {
index 8d033f2..cb291a3 100644 (file)
@@ -25,6 +25,7 @@
 #include "xxhash.h"
 
 #include <grpc/support/alloc.h>
+
 #include "src/core/ext/filters/client_channel/lb_policy/subchannel_list.h"
 #include "src/core/ext/filters/client_channel/lb_policy_registry.h"
 #include "src/core/ext/filters/client_channel/subchannel.h"
index b894c59..1593f16 100644 (file)
 
 #include <string.h>
 
-#include <grpc/support/alloc.h>
-
 #include "absl/container/inlined_vector.h"
 
+#include <grpc/support/alloc.h>
+
 #include "src/core/ext/filters/client_channel/lb_policy_registry.h"
 #include "src/core/ext/filters/client_channel/server_address.h"
 // TODO(roth): Should not need the include of subchannel.h here, since
index aab5f6f..8697870 100644 (file)
@@ -655,14 +655,8 @@ class WeightedTargetLbFactory : public LoadBalancingPolicyFactory {
         std::vector<grpc_error_handle> child_errors =
             ParseChildConfig(p.second, &child_config);
         if (!child_errors.empty()) {
-          // Can't use GRPC_ERROR_CREATE_FROM_VECTOR() here, because the error
-          // string is not static in this case.
-          grpc_error_handle error = GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-              absl::StrCat("field:targets key:", p.first).c_str());
-          for (grpc_error_handle child_error : child_errors) {
-            error = grpc_error_add_child(error, child_error);
-          }
-          error_list.push_back(error);
+          error_list.push_back(GRPC_ERROR_CREATE_FROM_VECTOR_AND_CPP_STRING(
+              absl::StrCat("field:targets key:", p.first), &child_errors));
         } else {
           target_map[p.first] = std::move(child_config);
         }
index 1ac1aa4..3bbc8fe 100644 (file)
@@ -572,11 +572,11 @@ grpc_error_handle CdsLb::UpdateXdsCertificateProvider(
   }
   // Configure root cert.
   absl::string_view root_provider_instance_name =
-      cluster_data.common_tls_context.combined_validation_context
-          .validation_context_certificate_provider_instance.instance_name;
+      cluster_data.common_tls_context.certificate_validation_context
+          .ca_certificate_provider_instance.instance_name;
   absl::string_view root_provider_cert_name =
-      cluster_data.common_tls_context.combined_validation_context
-          .validation_context_certificate_provider_instance.certificate_name;
+      cluster_data.common_tls_context.certificate_validation_context
+          .ca_certificate_provider_instance.certificate_name;
   RefCountedPtr<XdsCertificateProvider> new_root_provider;
   if (!root_provider_instance_name.empty()) {
     new_root_provider =
@@ -584,10 +584,9 @@ grpc_error_handle CdsLb::UpdateXdsCertificateProvider(
             .CreateOrGetCertificateProvider(root_provider_instance_name);
     if (new_root_provider == nullptr) {
       return grpc_error_set_int(
-          GRPC_ERROR_CREATE_FROM_COPIED_STRING(
+          GRPC_ERROR_CREATE_FROM_CPP_STRING(
               absl::StrCat("Certificate provider instance name: \"",
-                           root_provider_instance_name, "\" not recognized.")
-                  .c_str()),
+                           root_provider_instance_name, "\" not recognized.")),
           GRPC_ERROR_INT_GRPC_STATUS, GRPC_STATUS_UNAVAILABLE);
     }
   }
@@ -612,11 +611,11 @@ grpc_error_handle CdsLb::UpdateXdsCertificateProvider(
           : root_certificate_provider_->distributor());
   // Configure identity cert.
   absl::string_view identity_provider_instance_name =
-      cluster_data.common_tls_context
-          .tls_certificate_certificate_provider_instance.instance_name;
+      cluster_data.common_tls_context.tls_certificate_provider_instance
+          .instance_name;
   absl::string_view identity_provider_cert_name =
-      cluster_data.common_tls_context
-          .tls_certificate_certificate_provider_instance.certificate_name;
+      cluster_data.common_tls_context.tls_certificate_provider_instance
+          .certificate_name;
   RefCountedPtr<XdsCertificateProvider> new_identity_provider;
   if (!identity_provider_instance_name.empty()) {
     new_identity_provider =
@@ -624,11 +623,9 @@ grpc_error_handle CdsLb::UpdateXdsCertificateProvider(
             .CreateOrGetCertificateProvider(identity_provider_instance_name);
     if (new_identity_provider == nullptr) {
       return grpc_error_set_int(
-          GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-              absl::StrCat("Certificate provider instance name: \"",
-                           identity_provider_instance_name,
-                           "\" not recognized.")
-                  .c_str()),
+          GRPC_ERROR_CREATE_FROM_CPP_STRING(absl::StrCat(
+              "Certificate provider instance name: \"",
+              identity_provider_instance_name, "\" not recognized.")),
           GRPC_ERROR_INT_GRPC_STATUS, GRPC_STATUS_UNAVAILABLE);
     }
   }
@@ -653,8 +650,8 @@ grpc_error_handle CdsLb::UpdateXdsCertificateProvider(
           : identity_certificate_provider_->distributor());
   // Configure SAN matchers.
   const std::vector<StringMatcher>& match_subject_alt_names =
-      cluster_data.common_tls_context.combined_validation_context
-          .default_validation_context.match_subject_alt_names;
+      cluster_data.common_tls_context.certificate_validation_context
+          .match_subject_alt_names;
   xds_certificate_provider_->UpdateSubjectAlternativeNameMatchers(
       cluster_name, match_subject_alt_names);
   return GRPC_ERROR_NONE;
index 1e5b450..bce03ce 100644 (file)
@@ -16,6 +16,8 @@
 
 #include <grpc/support/port_platform.h>
 
+#include <atomic>
+
 #include "absl/strings/string_view.h"
 
 #include <grpc/grpc.h>
@@ -31,7 +33,6 @@
 #include "src/core/lib/channel/channel_args.h"
 #include "src/core/lib/gpr/env.h"
 #include "src/core/lib/gpr/string.h"
-#include "src/core/lib/gprpp/atomic.h"
 #include "src/core/lib/gprpp/orphanable.h"
 #include "src/core/lib/gprpp/ref_counted_ptr.h"
 #include "src/core/lib/gprpp/sync.h"
@@ -57,13 +58,15 @@ class CircuitBreakerCallCounterMap {
     explicit CallCounter(Key key) : key_(std::move(key)) {}
     ~CallCounter() override;
 
-    uint32_t Load() { return concurrent_requests_.Load(MemoryOrder::SEQ_CST); }
-    uint32_t Increment() { return concurrent_requests_.FetchAdd(1); }
-    void Decrement() { concurrent_requests_.FetchSub(1); }
+    uint32_t Load() {
+      return concurrent_requests_.load(std::memory_order_seq_cst);
+    }
+    uint32_t Increment() { return concurrent_requests_.fetch_add(1); }
+    void Decrement() { concurrent_requests_.fetch_sub(1); }
 
    private:
     Key key_;
-    Atomic<uint32_t> concurrent_requests_{0};
+    std::atomic<uint32_t> concurrent_requests_{0};
   };
 
   RefCountedPtr<CallCounter> GetOrCreate(const std::string& cluster,
@@ -718,8 +721,8 @@ class XdsClusterImplLbFactory : public LoadBalancingPolicyFactory {
       std::vector<grpc_error_handle> child_errors =
           ParseDropCategory(entry, drop_config);
       if (!child_errors.empty()) {
-        grpc_error_handle error = GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-            absl::StrCat("errors parsing index ", i).c_str());
+        grpc_error_handle error = GRPC_ERROR_CREATE_FROM_CPP_STRING(
+            absl::StrCat("errors parsing index ", i));
         for (size_t i = 0; i < child_errors.size(); ++i) {
           error = grpc_error_add_child(error, child_errors[i]);
         }
index dfd9a44..214d087 100644 (file)
@@ -627,14 +627,8 @@ class XdsClusterManagerLbFactory : public LoadBalancingPolicyFactory {
         std::vector<grpc_error_handle> child_errors =
             ParseChildConfig(p.second, &child_config);
         if (!child_errors.empty()) {
-          // Can't use GRPC_ERROR_CREATE_FROM_VECTOR() here, because the error
-          // string is not static in this case.
-          grpc_error_handle error = GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-              absl::StrCat("field:children name:", child_name).c_str());
-          for (grpc_error_handle child_error : child_errors) {
-            error = grpc_error_add_child(error, child_error);
-          }
-          error_list.push_back(error);
+          error_list.push_back(GRPC_ERROR_CREATE_FROM_VECTOR_AND_CPP_STRING(
+              absl::StrCat("field:children name:", child_name), &child_errors));
         } else {
           cluster_map[child_name] = std::move(child_config);
           clusters_to_be_used.insert(child_name);
index ac222ed..ff936b9 100644 (file)
@@ -1169,9 +1169,8 @@ class XdsClusterResolverLbFactory : public LoadBalancingPolicyFactory {
         std::vector<grpc_error_handle> discovery_mechanism_errors =
             ParseDiscoveryMechanism(array[i], &discovery_mechanism);
         if (!discovery_mechanism_errors.empty()) {
-          grpc_error_handle error = GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-              absl::StrCat("field:discovery_mechanism element: ", i, " error")
-                  .c_str());
+          grpc_error_handle error = GRPC_ERROR_CREATE_FROM_CPP_STRING(
+              absl::StrCat("field:discovery_mechanism element: ", i, " error"));
           for (grpc_error_handle discovery_mechanism_error :
                discovery_mechanism_errors) {
             error = grpc_error_add_child(error, discovery_mechanism_error);
index a3f0347..c72a609 100644 (file)
@@ -154,10 +154,8 @@ grpc_error_handle ParseLoadBalancingConfigHelper(
     }
     policies_tried.push_back(it->first);
   }
-  return GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-      absl::StrCat("No known policies in list: ",
-                   absl::StrJoin(policies_tried, " "))
-          .c_str());
+  return GRPC_ERROR_CREATE_FROM_CPP_STRING(absl::StrCat(
+      "No known policies in list: ", absl::StrJoin(policies_tried, " ")));
 }
 
 }  // namespace
@@ -176,9 +174,8 @@ LoadBalancingPolicyRegistry::ParseLoadBalancingConfig(
   LoadBalancingPolicyFactory* factory =
       g_state->GetLoadBalancingPolicyFactory(policy->first.c_str());
   if (factory == nullptr) {
-    *error = GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-        absl::StrFormat("Factory not found for policy \"%s\"", policy->first)
-            .c_str());
+    *error = GRPC_ERROR_CREATE_FROM_CPP_STRING(
+        absl::StrFormat("Factory not found for policy \"%s\"", policy->first));
     return nullptr;
   }
   // Parse load balancing config via factory.
index 337aa37..2e0de37 100644 (file)
 #include <stdio.h>
 #include <string.h>
 
+#include <address_sorting/address_sorting.h>
+
 #include "absl/container/inlined_vector.h"
 #include "absl/strings/str_cat.h"
 
 #include <grpc/support/alloc.h>
 #include <grpc/support/string_util.h>
 
-#include <address_sorting/address_sorting.h>
-
 #include "src/core/ext/filters/client_channel/http_connect_handshaker.h"
 #include "src/core/ext/filters/client_channel/lb_policy/grpclb/grpclb_balancer_addresses.h"
 #include "src/core/ext/filters/client_channel/lb_policy_registry.h"
@@ -471,13 +471,6 @@ static grpc_error_handle blocking_resolve_address_ares(
 static grpc_address_resolver_vtable ares_resolver = {
     grpc_resolve_address_ares, blocking_resolve_address_ares};
 
-#ifdef GRPC_UV
-/* TODO(murgatroid99): Remove this when we want the cares resolver to be the
- * default when using libuv */
-static bool should_use_ares(const char* resolver_env) {
-  return resolver_env != nullptr && gpr_stricmp(resolver_env, "ares") == 0;
-}
-#else  /* GRPC_UV */
 static bool should_use_ares(const char* resolver_env) {
   // TODO(lidiz): Remove the "g_custom_iomgr_enabled" flag once c-ares support
   // custom IO managers (e.g. gevent).
@@ -485,7 +478,6 @@ static bool should_use_ares(const char* resolver_env) {
          (resolver_env == nullptr || strlen(resolver_env) == 0 ||
           gpr_stricmp(resolver_env, "ares") == 0);
 }
-#endif /* GRPC_UV */
 
 static bool g_use_ares_dns_resolver;
 
index 0806923..01fe179 100644 (file)
@@ -22,6 +22,7 @@
 #include <grpc/support/port_platform.h>
 
 #include <ares.h>
+
 #include "src/core/lib/iomgr/pollset_set.h"
 #include "src/core/lib/iomgr/work_serializer.h"
 
diff --git a/src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_libuv.cc b/src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_libuv.cc
deleted file mode 100644 (file)
index 5c4c535..0000000
+++ /dev/null
@@ -1,179 +0,0 @@
-/*
- *
- * Copyright 2019 gRPC authors.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- *
- */
-#include <grpc/support/port_platform.h>
-
-#include "src/core/lib/iomgr/port.h"
-#if GRPC_ARES == 1 && defined(GRPC_UV)
-
-#include "absl/strings/str_format.h"
-
-#include <ares.h>
-#include <uv.h>
-
-#include "src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver.h"
-
-#include <grpc/support/alloc.h>
-#include <grpc/support/log.h>
-#include <grpc/support/string_util.h>
-#include <grpc/support/time.h>
-#include "src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper.h"
-#include "src/core/lib/gpr/string.h"
-#include "src/core/lib/iomgr/work_serializer.h"
-
-namespace grpc_core {
-
-void ares_uv_poll_cb(uv_poll_t* handle, int status, int events);
-
-void ares_uv_poll_close_cb(uv_handle_t* handle) { delete handle; }
-
-class GrpcPolledFdLibuv : public GrpcPolledFd {
- public:
-  GrpcPolledFdLibuv(ares_socket_t as,
-                    std::shared_ptr<WorkSerializer> work_serializer)
-      : name_(absl::StrFormat("c-ares socket: %" PRIdPTR, (intptr_t)as)),
-        as_(as),
-        work_serializer_(std::move(work_serializer)) {
-    handle_ = new uv_poll_t();
-    uv_poll_init_socket(uv_default_loop(), handle_, as);
-    handle_->data = this;
-  }
-
-  void RegisterForOnReadableLocked(grpc_closure* read_closure) override {
-    GPR_ASSERT(read_closure_ == nullptr);
-    GPR_ASSERT((poll_events_ & UV_READABLE) == 0);
-    read_closure_ = read_closure;
-    poll_events_ |= UV_READABLE;
-    uv_poll_start(handle_, poll_events_, ares_uv_poll_cb);
-  }
-
-  void RegisterForOnWriteableLocked(grpc_closure* write_closure) override {
-    GPR_ASSERT(write_closure_ == nullptr);
-    GPR_ASSERT((poll_events_ & UV_WRITABLE) == 0);
-    write_closure_ = write_closure;
-    poll_events_ |= UV_WRITABLE;
-    uv_poll_start(handle_, poll_events_, ares_uv_poll_cb);
-  }
-
-  bool IsFdStillReadableLocked() override {
-    /* uv_poll_t is based on poll, which is level triggered. So, if cares
-     * leaves some data unread, the event will trigger again. */
-    return false;
-  }
-
-  void ShutdownInternalLocked(grpc_error_handle error) {
-    uv_poll_stop(handle_);
-    uv_close(reinterpret_cast<uv_handle_t*>(handle_), ares_uv_poll_close_cb);
-    if (read_closure_ != nullptr) {
-      grpc_core::ExecCtx::Run(DEBUG_LOCATION, read_closure_,
-                              GRPC_ERROR_CANCELLED);
-    }
-    if (write_closure_ != nullptr) {
-      grpc_core::ExecCtx::Run(DEBUG_LOCATION, write_closure_,
-                              GRPC_ERROR_CANCELLED);
-    }
-  }
-
-  void ShutdownLocked(grpc_error_handle error) override {
-    if (grpc_core::ExecCtx::Get() == nullptr) {
-      grpc_core::ExecCtx exec_ctx;
-      ShutdownInternalLocked(error);
-    } else {
-      ShutdownInternalLocked(error);
-    }
-  }
-
-  ares_socket_t GetWrappedAresSocketLocked() override { return as_; }
-
-  const char* GetName() override { return name_.c_str(); }
-
-  // TODO(apolcyn): Data members should be private.
-  std::string name_;
-  ares_socket_t as_;
-  uv_poll_t* handle_;
-  grpc_closure* read_closure_ = nullptr;
-  grpc_closure* write_closure_ = nullptr;
-  int poll_events_ = 0;
-  std::shared_ptr<WorkSerializer> work_serializer_;
-};
-
-struct AresUvPollCbArg {
-  AresUvPollCbArg(uv_poll_t* handle, int status, int events)
-      : handle(handle), status(status), events(events) {}
-
-  uv_poll_t* handle;
-  int status;
-  int events;
-};
-
-static void ares_uv_poll_cb_locked(AresUvPollCbArg* arg) {
-  std::unique_ptr<AresUvPollCbArg> arg_struct(arg);
-  uv_poll_t* handle = arg_struct->handle;
-  int status = arg_struct->status;
-  int events = arg_struct->events;
-  GrpcPolledFdLibuv* polled_fd =
-      reinterpret_cast<GrpcPolledFdLibuv*>(handle->data);
-  grpc_error_handle error = GRPC_ERROR_NONE;
-  if (status < 0) {
-    error = GRPC_ERROR_CREATE_FROM_STATIC_STRING("cares polling error");
-    error =
-        grpc_error_set_str(error, GRPC_ERROR_STR_OS_ERROR,
-                           grpc_slice_from_static_string(uv_strerror(status)));
-  }
-  if (events & UV_READABLE) {
-    GPR_ASSERT(polled_fd->read_closure_ != nullptr);
-    grpc_core::ExecCtx::Run(DEBUG_LOCATION, polled_fd->read_closure_, error);
-    polled_fd->read_closure_ = nullptr;
-    polled_fd->poll_events_ &= ~UV_READABLE;
-  }
-  if (events & UV_WRITABLE) {
-    GPR_ASSERT(polled_fd->write_closure_ != nullptr);
-    grpc_core::ExecCtx::Run(DEBUG_LOCATION, polled_fd->write_closure_, error);
-    polled_fd->write_closure_ = nullptr;
-    polled_fd->poll_events_ &= ~UV_WRITABLE;
-  }
-  uv_poll_start(handle, polled_fd->poll_events_, ares_uv_poll_cb);
-}
-
-void ares_uv_poll_cb(uv_poll_t* handle, int status, int events) {
-  grpc_core::ExecCtx exec_ctx;
-  GrpcPolledFdLibuv* polled_fd =
-      reinterpret_cast<GrpcPolledFdLibuv*>(handle->data);
-  AresUvPollCbArg* arg = new AresUvPollCbArg(handle, status, events);
-  polled_fd->work_serializer_->Run([arg]() { ares_uv_poll_cb_locked(arg); },
-                                   DEBUG_LOCATION);
-}
-
-class GrpcPolledFdFactoryLibuv : public GrpcPolledFdFactory {
- public:
-  GrpcPolledFd* NewGrpcPolledFdLocked(
-      ares_socket_t as, grpc_pollset_set* driver_pollset_set,
-      std::shared_ptr<WorkSerializer> work_serializer) override {
-    return new GrpcPolledFdLibuv(as, std::move(work_serializer));
-  }
-
-  void ConfigureAresChannelLocked(ares_channel channel) override {}
-};
-
-std::unique_ptr<GrpcPolledFdFactory> NewGrpcPolledFdFactory(
-    std::shared_ptr<WorkSerializer> work_serializer) {
-  return absl::make_unique<GrpcPolledFdFactoryLibuv>();
-}
-
-}  // namespace grpc_core
-
-#endif /* GRPC_ARES == 1 && defined(GRPC_UV) */
index 31de679..e25bd55 100644 (file)
 #include "src/core/lib/iomgr/port.h"
 #if GRPC_ARES == 1 && defined(GRPC_POSIX_SOCKET_ARES_EV_DRIVER)
 
-#include <ares.h>
 #include <string.h>
 #include <sys/ioctl.h>
 
-#include "absl/strings/str_cat.h"
+#include <ares.h>
 
-#include "src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver.h"
+#include "absl/strings/str_cat.h"
 
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/string_util.h>
 #include <grpc/support/time.h>
+
+#include "src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver.h"
 #include "src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper.h"
 #include "src/core/lib/address_utils/sockaddr_utils.h"
 #include "src/core/lib/gpr/string.h"
index 0b4675f..07a1b53 100644 (file)
 #include "src/core/lib/iomgr/port.h"
 #if GRPC_ARES == 1 && defined(GRPC_WINDOWS_SOCKET_ARES_EV_DRIVER)
 
-#include "absl/strings/str_format.h"
+#include <string.h>
 
 #include <ares.h>
 
+#include "absl/strings/str_format.h"
+
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/log_windows.h>
 #include <grpc/support/string_util.h>
 #include <grpc/support/time.h>
-#include <string.h>
+
+#include "src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver.h"
+#include "src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper.h"
 #include "src/core/lib/address_utils/sockaddr_utils.h"
 #include "src/core/lib/gpr/string.h"
 #include "src/core/lib/gprpp/memory.h"
@@ -40,9 +44,6 @@
 #include "src/core/lib/iomgr/work_serializer.h"
 #include "src/core/lib/slice/slice_internal.h"
 
-#include "src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver.h"
-#include "src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper.h"
-
 /* TODO(apolcyn): remove this hack after fixing upstream.
  * Our grpc/c-ares code on Windows uses the ares_set_socket_functions API,
  * which uses "struct iovec" type, which on Windows is defined inside of
index 82dbb00..045937e 100644 (file)
 
 #if GRPC_ARES == 1
 
-#include "src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper.h"
-#include "src/core/lib/iomgr/sockaddr.h"
-
 #include <string.h>
 #include <sys/types.h>
 
+#include <address_sorting/address_sorting.h>
+#include <ares.h>
+
 #include "absl/container/inlined_vector.h"
 #include "absl/strings/str_cat.h"
 #include "absl/strings/str_format.h"
 
-#include <ares.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/string_util.h>
 #include <grpc/support/time.h>
 
-#include <address_sorting/address_sorting.h>
 #include "src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver.h"
+#include "src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper.h"
 #include "src/core/lib/address_utils/parse_address.h"
 #include "src/core/lib/address_utils/sockaddr_utils.h"
 #include "src/core/lib/gpr/string.h"
@@ -46,6 +45,7 @@
 #include "src/core/lib/iomgr/executor.h"
 #include "src/core/lib/iomgr/iomgr_internal.h"
 #include "src/core/lib/iomgr/nameser.h"
+#include "src/core/lib/iomgr/sockaddr.h"
 #include "src/core/lib/iomgr/timer.h"
 #include "src/core/lib/transport/authority_override.h"
 
@@ -536,10 +536,8 @@ grpc_error_handle grpc_ares_ev_driver_create_locked(
   grpc_ares_test_only_inject_config((*ev_driver)->channel);
   GRPC_CARES_TRACE_LOG("request:%p grpc_ares_ev_driver_create_locked", request);
   if (status != ARES_SUCCESS) {
-    grpc_error_handle err = GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-        absl::StrCat("Failed to init ares channel. C-ares error: ",
-                     ares_strerror(status))
-            .c_str());
+    grpc_error_handle err = GRPC_ERROR_CREATE_FROM_CPP_STRING(absl::StrCat(
+        "Failed to init ares channel. C-ares error: ", ares_strerror(status)));
     gpr_free(*ev_driver);
     return err;
   }
@@ -721,7 +719,7 @@ static void on_hostbyname_done_locked(void* arg, int status, int /*timeouts*/,
     GRPC_CARES_TRACE_LOG("request:%p on_hostbyname_done_locked: %s", r,
                          error_msg.c_str());
     grpc_error_handle error =
-        GRPC_ERROR_CREATE_FROM_COPIED_STRING(error_msg.c_str());
+        GRPC_ERROR_CREATE_FROM_CPP_STRING(std::move(error_msg));
     r->error = grpc_error_add_child(error, r->error);
   }
   destroy_hostbyname_request_locked(hr);
@@ -766,7 +764,7 @@ static void on_srv_query_done_locked(void* arg, int status, int /*timeouts*/,
     GRPC_CARES_TRACE_LOG("request:%p on_srv_query_done_locked: %s", r,
                          error_msg.c_str());
     grpc_error_handle error =
-        GRPC_ERROR_CREATE_FROM_COPIED_STRING(error_msg.c_str());
+        GRPC_ERROR_CREATE_FROM_CPP_STRING(std::move(error_msg));
     r->error = grpc_error_add_child(error, r->error);
   }
   delete q;
@@ -823,9 +821,9 @@ fail:
   std::string error_msg =
       absl::StrFormat("C-ares status is not ARES_SUCCESS qtype=TXT name=%s: %s",
                       q->name(), ares_strerror(status));
-  error = GRPC_ERROR_CREATE_FROM_COPIED_STRING(error_msg.c_str());
   GRPC_CARES_TRACE_LOG("request:%p on_txt_done_locked %s", r,
                        error_msg.c_str());
+  error = GRPC_ERROR_CREATE_FROM_CPP_STRING(std::move(error_msg));
   r->error = grpc_error_add_child(error, r->error);
 }
 
@@ -887,10 +885,8 @@ void grpc_dns_lookup_ares_continue_after_check_localhost_and_ip_literals_locked(
     int status =
         ares_set_servers_ports(r->ev_driver->channel, &r->dns_server_addr);
     if (status != ARES_SUCCESS) {
-      error = GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-          absl::StrCat("C-ares status is not ARES_SUCCESS: ",
-                       ares_strerror(status))
-              .c_str());
+      error = GRPC_ERROR_CREATE_FROM_CPP_STRING(absl::StrCat(
+          "C-ares status is not ARES_SUCCESS: ", ares_strerror(status)));
       goto error_cleanup;
     }
   }
@@ -1128,9 +1124,8 @@ void (*grpc_cancel_ares_request_locked)(grpc_ares_request* r) =
 grpc_error_handle grpc_ares_init(void) {
   int status = ares_library_init(ARES_LIB_INIT_ALL);
   if (status != ARES_SUCCESS) {
-    return GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-        absl::StrCat("ares_library_init failed: ", ares_strerror(status))
-            .c_str());
+    return GRPC_ERROR_CREATE_FROM_CPP_STRING(
+        absl::StrCat("ares_library_init failed: ", ares_strerror(status)));
   }
   return GRPC_ERROR_NONE;
 }
diff --git a/src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_libuv.cc b/src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_libuv.cc
deleted file mode 100644 (file)
index 8735aa8..0000000
+++ /dev/null
@@ -1,38 +0,0 @@
-/*
- *
- * Copyright 2016 gRPC authors.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- *
- */
-
-#include <grpc/support/port_platform.h>
-
-#include "src/core/lib/iomgr/port.h"
-#if GRPC_ARES == 1 && defined(GRPC_UV)
-
-#include <grpc/support/string_util.h>
-
-#include "src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper.h"
-#include "src/core/ext/filters/client_channel/server_address.h"
-#include "src/core/lib/address_utils/parse_address.h"
-#include "src/core/lib/gpr/string.h"
-
-bool grpc_ares_query_ipv6() {
-  /* The libuv grpc code currently does not have the code to probe for this,
-   * so we assume for now that IPv6 is always available in contexts where this
-   * code will be used. */
-  return true;
-}
-
-#endif /* GRPC_ARES == 1 && defined(GRPC_UV) */
index 7978d59..be447c3 100644 (file)
@@ -19,6 +19,8 @@
 
 #include <grpc/support/port_platform.h>
 
+#include "src/core/ext/filters/client_channel/resolver/fake/fake_resolver.h"
+
 #include <limits.h>
 #include <stdbool.h>
 #include <stdio.h>
@@ -41,8 +43,6 @@
 #include "src/core/lib/slice/slice_internal.h"
 #include "src/core/lib/slice/slice_string_helpers.h"
 
-#include "src/core/ext/filters/client_channel/resolver/fake/fake_resolver.h"
-
 namespace grpc_core {
 
 // This cannot be in an anonymous namespace, because it is a friend of
index ed2b402..a430e7a 100644 (file)
@@ -64,7 +64,7 @@ class GoogleCloud2ProdResolver : public Resolver {
     grpc_httpcli_context context_;
     grpc_httpcli_response response_;
     grpc_closure on_done_;
-    Atomic<bool> on_done_called_{false};
+    std::atomic<bool> on_done_called_{false};
   };
 
   // A metadata server query to get the zone.
@@ -132,7 +132,6 @@ GoogleCloud2ProdResolver::MetadataQuery::MetadataQuery(
   grpc_httpcli_get(&context_, pollent, resource_quota, &request,
                    ExecCtx::Get()->Now() + 10000,  // 10s timeout
                    &on_done_, &response_);
-  grpc_resource_quota_unref_internal(resource_quota);
 }
 
 GoogleCloud2ProdResolver::MetadataQuery::~MetadataQuery() {
@@ -155,8 +154,9 @@ void GoogleCloud2ProdResolver::MetadataQuery::OnHttpRequestDone(
 void GoogleCloud2ProdResolver::MetadataQuery::MaybeCallOnDone(
     grpc_error_handle error) {
   bool expected = false;
-  if (!on_done_called_.CompareExchangeStrong(
-          &expected, true, MemoryOrder::RELAXED, MemoryOrder::RELAXED)) {
+  if (!on_done_called_.compare_exchange_strong(expected, true,
+                                               std::memory_order_relaxed,
+                                               std::memory_order_relaxed)) {
     // We've already called OnDone(), so just clean up.
     GRPC_ERROR_UNREF(error);
     Unref();
@@ -321,7 +321,7 @@ void GoogleCloud2ProdResolver::StartXdsResolver() {
   const char* server_uri =
       override_server != nullptr && strlen(override_server.get()) > 0
           ? override_server.get()
-          : "directpath-trafficdirector.googleapis.com";
+          : "directpath-pa.googleapis.com";
   Json bootstrap = Json::Object{
       {"xds_servers",
        Json::Array{
index da48e6f..c9a2974 100644 (file)
@@ -538,11 +538,9 @@ grpc_error_handle XdsResolver::XdsConfigSelector::CreateMethodConfig(
     auto method_config_field =
         filter_impl->GenerateServiceConfig(http_filter.config, config_override);
     if (!method_config_field.ok()) {
-      return GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-          absl::StrCat("failed to generate method config for HTTP filter ",
-                       http_filter.name, ": ",
-                       method_config_field.status().ToString())
-              .c_str());
+      return GRPC_ERROR_CREATE_FROM_CPP_STRING(absl::StrCat(
+          "failed to generate method config for HTTP filter ", http_filter.name,
+          ": ", method_config_field.status().ToString()));
     }
     per_filter_configs[method_config_field->service_config_field_name]
         .push_back(method_config_field->element);
@@ -848,10 +846,9 @@ void XdsResolver::OnRouteConfigUpdate(XdsApi::RdsUpdate rds_update) {
   XdsApi::RdsUpdate::VirtualHost* vhost =
       rds_update.FindVirtualHostForDomain(server_name_);
   if (vhost == nullptr) {
-    OnError(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
+    OnError(GRPC_ERROR_CREATE_FROM_CPP_STRING(
         absl::StrCat("could not find VirtualHost for ", server_name_,
-                     " in RouteConfiguration")
-            .c_str()));
+                     " in RouteConfiguration")));
     return;
   }
   // Save the virtual host in the resolver.
index b0c8eeb..fe66c3f 100644 (file)
@@ -125,11 +125,10 @@ ClientChannelServiceConfigParser::ParseGlobalParams(
         error_list.push_back(GRPC_ERROR_CREATE_FROM_STATIC_STRING(
             "field:loadBalancingPolicy error:Unknown lb policy"));
       } else if (requires_config) {
-        error_list.push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
+        error_list.push_back(GRPC_ERROR_CREATE_FROM_CPP_STRING(
             absl::StrCat("field:loadBalancingPolicy error:", lb_policy_name,
                          " requires a config. Please use loadBalancingConfig "
-                         "instead.")
-                .c_str()));
+                         "instead.")));
       }
     }
   }
index 6255d91..f27509e 100644 (file)
 
 #include <limits.h>
 
+#include <atomic>
+
 #include "src/core/lib/channel/channel_args.h"
 #include "src/core/lib/channel/channel_stack_builder.h"
-#include "src/core/lib/gprpp/atomic.h"
 #include "src/core/lib/iomgr/timer.h"
 #include "src/core/lib/surface/channel_init.h"
 #include "src/core/lib/transport/http2_errors.h"
@@ -159,8 +160,8 @@ class ChannelData {
 
   // Member data used to track the state of channel.
   grpc_millis last_idle_time_;
-  Atomic<intptr_t> call_count_{0};
-  Atomic<ChannelState> state_{IDLE};
+  std::atomic<intptr_t> call_count_{0};
+  std::atomic<ChannelState> state_{IDLE};
 
   // Idle timer and its callback closure.
   grpc_timer idle_timer_;
@@ -201,20 +202,21 @@ void ChannelData::StartTransportOp(grpc_channel_element* elem,
 }
 
 void ChannelData::IncreaseCallCount() {
-  const intptr_t previous_value = call_count_.FetchAdd(1, MemoryOrder::RELAXED);
+  const intptr_t previous_value =
+      call_count_.fetch_add(1, std::memory_order_relaxed);
   GRPC_IDLE_FILTER_LOG("call counter has increased to %" PRIuPTR,
                        previous_value + 1);
   if (previous_value == 0) {
     // This call is the one that makes the channel busy.
     // Loop here to make sure the previous decrease operation has finished.
-    ChannelState state = state_.Load(MemoryOrder::RELAXED);
+    ChannelState state = state_.load(std::memory_order_relaxed);
     while (true) {
       switch (state) {
         // Timer has not been set. Switch to CALLS_ACTIVE.
         case IDLE:
           // In this case, no other threads will modify the state, so we can
           // just store the value.
-          state_.Store(CALLS_ACTIVE, MemoryOrder::RELAXED);
+          state_.store(CALLS_ACTIVE, std::memory_order_relaxed);
           return;
         // Timer has been set. Switch to TIMER_PENDING_CALLS_ACTIVE.
         case TIMER_PENDING:
@@ -222,17 +224,17 @@ void ChannelData::IncreaseCallCount() {
           // At this point, the state may have been switched to IDLE by the
           // idle timer callback. Therefore, use CAS operation to change the
           // state atomically.
-          // Use MemoryOrder::ACQUIRE on success to ensure last_idle_time_ has
-          // been properly set in DecreaseCallCount().
-          if (state_.CompareExchangeWeak(&state, TIMER_PENDING_CALLS_ACTIVE,
-                                         MemoryOrder::ACQUIRE,
-                                         MemoryOrder::RELAXED)) {
+          // Use std::memory_order_acquire on success to ensure last_idle_time_
+          // has been properly set in DecreaseCallCount().
+          if (state_.compare_exchange_weak(state, TIMER_PENDING_CALLS_ACTIVE,
+                                           std::memory_order_acquire,
+                                           std::memory_order_relaxed)) {
             return;
           }
           break;
         default:
           // The state has not been switched to desired value yet, try again.
-          state = state_.Load(MemoryOrder::RELAXED);
+          state = state_.load(std::memory_order_relaxed);
           break;
       }
     }
@@ -240,16 +242,17 @@ void ChannelData::IncreaseCallCount() {
 }
 
 void ChannelData::DecreaseCallCount() {
-  const intptr_t previous_value = call_count_.FetchSub(1, MemoryOrder::RELAXED);
+  const intptr_t previous_value =
+      call_count_.fetch_sub(1, std::memory_order_relaxed);
   GRPC_IDLE_FILTER_LOG("call counter has decreased to %" PRIuPTR,
                        previous_value - 1);
   if (previous_value == 1) {
     // This call is the one that makes the channel idle.
-    // last_idle_time_ does not need to be Atomic<> because busy-loops in
+    // last_idle_time_ does not need to be std::atomic<> because busy-loops in
     // IncreaseCallCount(), DecreaseCallCount() and IdleTimerCallback() will
     // prevent multiple threads from simultaneously accessing this variable.
     last_idle_time_ = ExecCtx::Get()->Now();
-    ChannelState state = state_.Load(MemoryOrder::RELAXED);
+    ChannelState state = state_.load(std::memory_order_relaxed);
     while (true) {
       switch (state) {
         // Timer has not been set. Set the timer and switch to TIMER_PENDING
@@ -257,7 +260,7 @@ void ChannelData::DecreaseCallCount() {
           // Release store here to make other threads see the updated value of
           // last_idle_time_.
           StartIdleTimer();
-          state_.Store(TIMER_PENDING, MemoryOrder::RELEASE);
+          state_.store(TIMER_PENDING, std::memory_order_release);
           return;
         // Timer has been set. Switch to
         // TIMER_PENDING_CALLS_SEEN_SINCE_TIMER_START
@@ -267,15 +270,15 @@ void ChannelData::DecreaseCallCount() {
           // state atomically.
           // Release store here to make the idle timer callback see the updated
           // value of last_idle_time_ to properly reset the idle timer.
-          if (state_.CompareExchangeWeak(
-                  &state, TIMER_PENDING_CALLS_SEEN_SINCE_TIMER_START,
-                  MemoryOrder::RELEASE, MemoryOrder::RELAXED)) {
+          if (state_.compare_exchange_weak(
+                  state, TIMER_PENDING_CALLS_SEEN_SINCE_TIMER_START,
+                  std::memory_order_release, std::memory_order_relaxed)) {
             return;
           }
           break;
         default:
           // The state has not been switched to desired value yet, try again.
-          state = state_.Load(MemoryOrder::RELAXED);
+          state = state_.load(std::memory_order_relaxed);
           break;
       }
     }
@@ -313,38 +316,41 @@ void ChannelData::IdleTimerCallback(void* arg, grpc_error_handle error) {
     return;
   }
   bool finished = false;
-  ChannelState state = chand->state_.Load(MemoryOrder::RELAXED);
+  ChannelState state = chand->state_.load(std::memory_order_relaxed);
   while (!finished) {
     switch (state) {
       case TIMER_PENDING:
         // Change the state to PROCESSING to block IncreaseCallCout() until the
         // EnterIdle() operation finishes, preventing mistakenly entering IDLE
         // when active RPC exists.
-        finished = chand->state_.CompareExchangeWeak(
-            &state, PROCESSING, MemoryOrder::ACQUIRE, MemoryOrder::RELAXED);
+        finished = chand->state_.compare_exchange_weak(
+            state, PROCESSING, std::memory_order_acquire,
+            std::memory_order_relaxed);
         if (finished) {
           chand->EnterIdle();
-          chand->state_.Store(IDLE, MemoryOrder::RELAXED);
+          chand->state_.store(IDLE, std::memory_order_relaxed);
         }
         break;
       case TIMER_PENDING_CALLS_ACTIVE:
-        finished = chand->state_.CompareExchangeWeak(
-            &state, CALLS_ACTIVE, MemoryOrder::RELAXED, MemoryOrder::RELAXED);
+        finished = chand->state_.compare_exchange_weak(
+            state, CALLS_ACTIVE, std::memory_order_relaxed,
+            std::memory_order_relaxed);
         break;
       case TIMER_PENDING_CALLS_SEEN_SINCE_TIMER_START:
         // Change the state to PROCESSING to block IncreaseCallCount() until the
         // StartIdleTimer() operation finishes, preventing mistakenly restarting
         // the timer after grpc_timer_cancel() when shutdown.
-        finished = chand->state_.CompareExchangeWeak(
-            &state, PROCESSING, MemoryOrder::ACQUIRE, MemoryOrder::RELAXED);
+        finished = chand->state_.compare_exchange_weak(
+            state, PROCESSING, std::memory_order_acquire,
+            std::memory_order_relaxed);
         if (finished) {
           chand->StartIdleTimer();
-          chand->state_.Store(TIMER_PENDING, MemoryOrder::RELAXED);
+          chand->state_.store(TIMER_PENDING, std::memory_order_relaxed);
         }
         break;
       default:
         // The state has not been switched to desired value yet, try again.
-        state = chand->state_.Load(MemoryOrder::RELAXED);
+        state = chand->state_.load(std::memory_order_relaxed);
         break;
     }
   }
index 5f8d779..f4d4148 100644 (file)
@@ -18,6 +18,8 @@
 
 #include "src/core/ext/filters/fault_injection/fault_injection_filter.h"
 
+#include <atomic>
+
 #include "absl/strings/numbers.h"
 
 #include <grpc/support/alloc.h>
@@ -28,7 +30,6 @@
 #include "src/core/ext/filters/fault_injection/service_config_parser.h"
 #include "src/core/lib/channel/channel_stack.h"
 #include "src/core/lib/channel/status_util.h"
-#include "src/core/lib/gprpp/atomic.h"
 #include "src/core/lib/gprpp/sync.h"
 #include "src/core/lib/iomgr/closure.h"
 #include "src/core/lib/iomgr/timer.h"
@@ -40,9 +41,9 @@ TraceFlag grpc_fault_injection_filter_trace(false, "fault_injection_filter");
 
 namespace {
 
-Atomic<uint32_t> g_active_faults{0};
+std::atomic<uint32_t> g_active_faults{0};
 static_assert(
-    std::is_trivially_destructible<Atomic<uint32_t>>::value,
+    std::is_trivially_destructible<std::atomic<uint32_t>>::value,
     "the active fault counter needs to have a trivially destructible type");
 
 inline int GetLinkedMetadatumValueInt(grpc_linked_mdelem* md) {
@@ -140,7 +141,7 @@ class CallData {
 
   // Finishes the fault injection, should only be called once.
   void FaultInjectionFinished() {
-    g_active_faults.FetchSub(1, MemoryOrder::RELAXED);
+    g_active_faults.fetch_sub(1, std::memory_order_relaxed);
   }
 
   // This is a callback that will be invoked after the delay timer is up.
@@ -400,10 +401,11 @@ void CallData::DecideWhetherToInjectFaults(
 }
 
 bool CallData::HaveActiveFaultsQuota(bool increment) {
-  if (g_active_faults.Load(MemoryOrder::ACQUIRE) >= fi_policy_->max_faults) {
+  if (g_active_faults.load(std::memory_order_acquire) >=
+      fi_policy_->max_faults) {
     return false;
   }
-  if (increment) g_active_faults.FetchAdd(1, MemoryOrder::RELAXED);
+  if (increment) g_active_faults.fetch_add(1, std::memory_order_relaxed);
   return true;
 }
 
index e8c23e1..bbbff40 100644 (file)
@@ -22,6 +22,7 @@
 
 #include "absl/strings/str_cat.h"
 #include "absl/strings/string_view.h"
+
 #include "src/core/ext/filters/client_channel/service_config.h"
 #include "src/core/ext/filters/fault_injection/fault_injection_filter.h"
 #include "src/core/lib/channel/channel_args.h"
@@ -44,10 +45,8 @@ ParseFaultInjectionPolicy(const Json::Array& policies_json_array,
         fault_injection_policy;
     std::vector<grpc_error_handle> sub_error_list;
     if (policies_json_array[i].type() != Json::Type::OBJECT) {
-      error_list->push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-          absl::StrCat("faultInjectionPolicy index ", i,
-                       " is not a JSON object")
-              .c_str()));
+      error_list->push_back(GRPC_ERROR_CREATE_FROM_CPP_STRING(absl::StrCat(
+          "faultInjectionPolicy index ", i, " is not a JSON object")));
       continue;
     }
     const Json::Object& json_object = policies_json_array[i].object_value();
@@ -133,15 +132,9 @@ ParseFaultInjectionPolicy(const Json::Array& policies_json_array,
       }
     }
     if (!sub_error_list.empty()) {
-      // Can't use GRPC_ERROR_CREATE_FROM_VECTOR() here, because the error
-      // string is not static in this case.
-      grpc_error_handle error = GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-          absl::StrCat("failed to parse faultInjectionPolicy index ", i)
-              .c_str());
-      for (size_t i = 0; i < sub_error_list.size(); ++i) {
-        error = grpc_error_add_child(error, sub_error_list[i]);
-      }
-      error_list->push_back(error);
+      error_list->push_back(GRPC_ERROR_CREATE_FROM_VECTOR_AND_CPP_STRING(
+          absl::StrCat("failed to parse faultInjectionPolicy index ", i),
+          &sub_error_list));
     }
     policies.push_back(std::move(fault_injection_policy));
   }
index 4e1ac54..a671d31 100644 (file)
@@ -17,6 +17,8 @@
 
 #include <grpc/support/port_platform.h>
 
+#include "src/core/ext/filters/http/client/http_client_filter.h"
+
 #include <stdint.h>
 #include <string.h>
 
@@ -30,7 +32,6 @@
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 
-#include "src/core/ext/filters/http/client/http_client_filter.h"
 #include "src/core/lib/gpr/string.h"
 #include "src/core/lib/gprpp/manual_constructor.h"
 #include "src/core/lib/profiling/timers.h"
@@ -142,7 +143,7 @@ static grpc_error_handle client_filter_incoming_metadata(
   }
 
   if (b->idx.named.grpc_message != nullptr) {
-    grpc_slice pct_decoded_msg = grpc_permissive_percent_decode_slice(
+    grpc_slice pct_decoded_msg = grpc_core::PermissivePercentDecodeSlice(
         GRPC_MDVALUE(b->idx.named.grpc_message->md));
     if (grpc_slice_is_equivalent(pct_decoded_msg,
                                  GRPC_MDVALUE(b->idx.named.grpc_message->md))) {
index f44ef85..c1764ec 100644 (file)
@@ -18,6 +18,8 @@
 
 #include <grpc/support/port_platform.h>
 
+#include "src/core/ext/filters/http/client_authority_filter.h"
+
 #include <assert.h>
 #include <limits.h>
 #include <string.h>
@@ -26,7 +28,6 @@
 #include <grpc/support/log.h>
 #include <grpc/support/string_util.h>
 
-#include "src/core/ext/filters/http/client_authority_filter.h"
 #include "src/core/lib/channel/channel_args.h"
 #include "src/core/lib/gpr/string.h"
 #include "src/core/lib/slice/slice_internal.h"
index 0fc85b1..8359b1f 100644 (file)
@@ -18,6 +18,8 @@
 
 #include <grpc/support/port_platform.h>
 
+#include "src/core/ext/filters/http/message_compress/message_compress_filter.h"
+
 #include <assert.h>
 #include <string.h>
 
@@ -28,7 +30,6 @@
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 
-#include "src/core/ext/filters/http/message_compress/message_compress_filter.h"
 #include "src/core/lib/channel/channel_args.h"
 #include "src/core/lib/compression/algorithm_metadata.h"
 #include "src/core/lib/compression/compression_args.h"
index 426dd90..27718e2 100644 (file)
 #include <string.h>
 
 #include "absl/strings/str_cat.h"
+#include "absl/strings/str_format.h"
 
 #include <grpc/compression.h>
 #include <grpc/slice_buffer.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 
-#include "absl/strings/str_format.h"
 #include "src/core/ext/filters/message_size/message_size_filter.h"
 #include "src/core/lib/channel/channel_args.h"
 #include "src/core/lib/compression/algorithm_metadata.h"
@@ -196,12 +196,12 @@ void CallData::OnRecvMessageReady(void* arg, grpc_error_handle error) {
       if (calld->max_recv_message_length_ >= 0 &&
           (*calld->recv_message_)->length() >
               static_cast<uint32_t>(calld->max_recv_message_length_)) {
-        std::string message_string = absl::StrFormat(
-            "Received message larger than max (%u vs. %d)",
-            (*calld->recv_message_)->length(), calld->max_recv_message_length_);
         GPR_DEBUG_ASSERT(calld->error_ == GRPC_ERROR_NONE);
         calld->error_ = grpc_error_set_int(
-            GRPC_ERROR_CREATE_FROM_COPIED_STRING(message_string.c_str()),
+            GRPC_ERROR_CREATE_FROM_CPP_STRING(
+                absl::StrFormat("Received message larger than max (%u vs. %d)",
+                                (*calld->recv_message_)->length(),
+                                calld->max_recv_message_length_)),
             GRPC_ERROR_INT_GRPC_STATUS, GRPC_STATUS_RESOURCE_EXHAUSTED);
         return calld->ContinueRecvMessageReadyCallback(
             GRPC_ERROR_REF(calld->error_));
@@ -260,11 +260,10 @@ void CallData::FinishRecvMessage() {
   if (grpc_msg_decompress(algorithm_, &recv_slices_, &decompressed_slices) ==
       0) {
     GPR_DEBUG_ASSERT(error_ == GRPC_ERROR_NONE);
-    error_ = GRPC_ERROR_CREATE_FROM_COPIED_STRING(
+    error_ = GRPC_ERROR_CREATE_FROM_CPP_STRING(
         absl::StrCat("Unexpected error decompressing data for algorithm with "
                      "enum value ",
-                     algorithm_)
-            .c_str());
+                     algorithm_));
     grpc_slice_buffer_destroy_internal(&decompressed_slices);
   } else {
     uint32_t recv_flags =
index 226ba02..e599674 100644 (file)
 
 #include "src/core/ext/filters/http/server/http_server_filter.h"
 
+#include <string.h>
+
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
-#include <string.h>
+
 #include "src/core/lib/channel/channel_args.h"
 #include "src/core/lib/gprpp/manual_constructor.h"
 #include "src/core/lib/profiling/timers.h"
@@ -103,9 +105,9 @@ struct channel_data {
 
 static grpc_error_handle hs_filter_outgoing_metadata(grpc_metadata_batch* b) {
   if (b->idx.named.grpc_message != nullptr) {
-    grpc_slice pct_encoded_msg = grpc_percent_encode_slice(
+    grpc_slice pct_encoded_msg = grpc_core::PercentEncodeSlice(
         GRPC_MDVALUE(b->idx.named.grpc_message->md),
-        grpc_compatible_percent_encoding_unreserved_bytes);
+        grpc_core::PercentEncodingType::Compatible);
     if (grpc_slice_is_equivalent(pct_encoded_msg,
                                  GRPC_MDVALUE(b->idx.named.grpc_message->md))) {
       grpc_slice_unref_internal(pct_encoded_msg);
index 46af805..2427bc1 100644 (file)
@@ -18,6 +18,8 @@
 
 #include <grpc/support/port_platform.h>
 
+#include "src/core/ext/filters/load_reporting/server_load_reporting_filter.h"
+
 #include <string.h>
 
 #include <string>
@@ -31,7 +33,6 @@
 
 #include "src/core/ext/filters/client_channel/lb_policy/grpclb/grpclb.h"
 #include "src/core/ext/filters/load_reporting/registered_opencensus_objects.h"
-#include "src/core/ext/filters/load_reporting/server_load_reporting_filter.h"
 #include "src/core/lib/address_utils/parse_address.h"
 #include "src/core/lib/channel/channel_args.h"
 #include "src/core/lib/channel/context.h"
@@ -339,8 +340,8 @@ bool MaybeAddServerLoadReportingFilter(const grpc_channel_args& args) {
 // time if we build with the filter target.
 struct ServerLoadReportingFilterStaticRegistrar {
   ServerLoadReportingFilterStaticRegistrar() {
-    static grpc_core::Atomic<bool> registered{false};
-    if (registered.Load(grpc_core::MemoryOrder::ACQUIRE)) return;
+    static std::atomic<bool> registered{false};
+    if (registered.load(std::memory_order_acquire)) return;
     RegisterChannelFilter<ServerLoadReportingChannelData,
                           ServerLoadReportingCallData>(
         "server_load_reporting", GRPC_SERVER_CHANNEL, INT_MAX,
@@ -353,7 +354,7 @@ struct ServerLoadReportingFilterStaticRegistrar {
     ::grpc::load_reporter::MeasureEndBytesReceived();
     ::grpc::load_reporter::MeasureEndLatencyMs();
     ::grpc::load_reporter::MeasureOtherCallMetric();
-    registered.Store(true, grpc_core::MemoryOrder::RELEASE);
+    registered.store(true, std::memory_order_release);
   }
 } server_load_reporting_filter_static_registrar;
 
index 3c921e2..d98e1c7 100644 (file)
@@ -203,11 +203,9 @@ static void recv_message_ready(void* user_data, grpc_error_handle error) {
       (*calld->recv_message)->length() >
           static_cast<size_t>(calld->limits.max_recv_size)) {
     grpc_error_handle new_error = grpc_error_set_int(
-        GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-            absl::StrFormat("Received message larger than max (%u vs. %d)",
-                            (*calld->recv_message)->length(),
-                            calld->limits.max_recv_size)
-                .c_str()),
+        GRPC_ERROR_CREATE_FROM_CPP_STRING(absl::StrFormat(
+            "Received message larger than max (%u vs. %d)",
+            (*calld->recv_message)->length(), calld->limits.max_recv_size)),
         GRPC_ERROR_INT_GRPC_STATUS, GRPC_STATUS_RESOURCE_EXHAUSTED);
     error = grpc_error_add_child(GRPC_ERROR_REF(error), new_error);
     GRPC_ERROR_UNREF(calld->error);
@@ -264,14 +262,12 @@ static void message_size_start_transport_stream_op_batch(
           static_cast<size_t>(calld->limits.max_send_size)) {
     grpc_transport_stream_op_batch_finish_with_failure(
         op,
-        grpc_error_set_int(
-            GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-                absl::StrFormat(
-                    "Sent message larger than max (%u vs. %d)",
-                    op->payload->send_message.send_message->length(),
-                    calld->limits.max_send_size)
-                    .c_str()),
-            GRPC_ERROR_INT_GRPC_STATUS, GRPC_STATUS_RESOURCE_EXHAUSTED),
+        grpc_error_set_int(GRPC_ERROR_CREATE_FROM_CPP_STRING(absl::StrFormat(
+                               "Sent message larger than max (%u vs. %d)",
+                               op->payload->send_message.send_message->length(),
+                               calld->limits.max_send_size)),
+                           GRPC_ERROR_INT_GRPC_STATUS,
+                           GRPC_STATUS_RESOURCE_EXHAUSTED),
         calld->call_combiner);
     return;
   }
diff --git a/src/core/ext/transport/binder/client/BUILD b/src/core/ext/transport/binder/client/BUILD
new file mode 100644 (file)
index 0000000..42abe0d
--- /dev/null
@@ -0,0 +1,76 @@
+# Copyright 2021 gRPC authors.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+load("//bazel:grpc_build_system.bzl", "grpc_cc_library")
+
+licenses(["notice"])
+
+package(
+    default_visibility = ["//visibility:public"],
+    features = [
+        "layering_check",
+    ],
+)
+
+# TODO(mingcl): See if it is possible to add flags that warns about undefined symbol at link time
+grpc_cc_library(
+    name = "grpc_transport_binder_client",
+    srcs = [
+        "channel_create.cc",
+        "channel_create.h",
+        "jni_utils.cc",
+    ],
+    hdrs = [
+        "channel_create.h",
+        "jni_utils.h",
+    ],
+    external_deps = [
+        "absl/strings",
+        "absl/time",
+    ],
+    deps = [
+        ":grpc_transport_binder_client_impl",
+        "//:gpr",
+        "//:gpr_base",
+        "//:gpr_platform",
+        "//:grpc",
+        "//:grpc++_base",
+        "//:grpc_base",
+        "//:grpc_base_c",
+        "//:grpc_codegen",
+        "//src/core/ext/transport/binder/transport:binder_transport",
+        "//src/core/ext/transport/binder/utils:transport_stream_receiver",
+        "//src/core/ext/transport/binder/wire_format:binder_android",
+        "//src/core/ext/transport/binder/wire_format:wire_reader",
+    ],
+)
+
+grpc_cc_library(
+    name = "grpc_transport_binder_client_impl",
+    srcs = ["channel_create_impl.cc"],
+    hdrs = ["channel_create_impl.h"],
+    external_deps = [],
+    deps = [
+        "//:gpr",
+        "//:gpr_base",
+        "//:gpr_platform",
+        "//:grpc",
+        "//:grpc++_base",
+        "//:grpc_base",
+        "//:grpc_base_c",
+        "//:grpc_codegen",
+        "//src/core/ext/transport/binder/transport:binder_transport",
+        "//src/core/ext/transport/binder/wire_format:binder",
+    ],
+)
diff --git a/src/core/ext/transport/binder/client/channel_create.cc b/src/core/ext/transport/binder/client/channel_create.cc
new file mode 100644 (file)
index 0000000..cfbe336
--- /dev/null
@@ -0,0 +1,152 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#include <grpc/impl/codegen/port_platform.h>
+
+#include "src/core/ext/transport/binder/client/channel_create.h"
+
+// The interface is only defined if GPR_ANDROID is defined, because some
+// arguments requires JNI.
+// Furthermore, the interface is non-phony only when
+// GPR_SUPPORT_BINDER_TRANSPORT is true because actual implementation of binder
+// transport requires newer version of NDK API
+
+#ifdef GPR_ANDROID
+
+#include <grpc/grpc.h>
+#include <grpc/grpc_posix.h>
+
+#ifdef GPR_SUPPORT_BINDER_TRANSPORT
+
+#include <grpc/support/port_platform.h>
+
+#include <android/binder_auto_utils.h>
+#include <android/binder_ibinder.h>
+#include <android/binder_ibinder_jni.h>
+#include <android/binder_interface_utils.h>
+
+#include "absl/memory/memory.h"
+#include "absl/time/clock.h"
+#include "absl/time/time.h"
+
+#include <grpc/support/log.h>
+#include <grpcpp/impl/grpc_library.h>
+
+#include "src/core/ext/transport/binder/client/channel_create_impl.h"
+#include "src/core/ext/transport/binder/client/jni_utils.h"
+#include "src/core/ext/transport/binder/transport/binder_transport.h"
+#include "src/core/ext/transport/binder/wire_format/binder.h"
+#include "src/core/ext/transport/binder/wire_format/binder_android.h"
+#include "src/core/lib/surface/channel.h"
+#include "src/core/lib/transport/transport.h"
+#include "src/cpp/client/create_channel_internal.h"
+
+namespace grpc {
+namespace experimental {
+
+// This should be called before calling CreateBinderChannel
+// TODO(mingcl): Invoke a callback and pass binder object to caller after a
+// successful bind
+void BindToOnDeviceServerService(void* jni_env_void, jobject application,
+                                 absl::string_view package_name,
+                                 absl::string_view class_name) {
+  // Init gRPC library first so gpr_log works
+  grpc::internal::GrpcLibrary init_lib;
+  init_lib.init();
+
+  JNIEnv* jni_env = static_cast<JNIEnv*>(jni_env_void);
+
+  // clang-format off
+  grpc_binder::CallStaticJavaMethod(jni_env,
+                       "io/grpc/binder/cpp/NativeConnectionHelper",
+                       "tryEstablishConnection",
+                       "(Landroid/content/Context;Ljava/lang/String;Ljava/lang/String;)V",
+                       application, std::string(package_name), std::string(class_name));
+  // clang-format on
+}
+
+// BindToOndeviceServerService need to be called before this, in a different
+// task (due to Android API design). (Reference:
+// https://stackoverflow.com/a/3055749)
+// TODO(mingcl): Support multiple endpoint binder objects
+std::shared_ptr<grpc::Channel> CreateBinderChannel(
+    void* jni_env_void, jobject application, absl::string_view package_name,
+    absl::string_view class_name) {
+  return CreateCustomBinderChannel(jni_env_void, application, package_name,
+                                   class_name, ChannelArguments());
+}
+
+// BindToOndeviceServerService need to be called before this, in a different
+// task (due to Android API design). (Reference:
+// https://stackoverflow.com/a/3055749)
+// TODO(mingcl): Support multiple endpoint binder objects
+std::shared_ptr<grpc::Channel> CreateCustomBinderChannel(
+    void* jni_env_void, jobject /*application*/,
+    absl::string_view /*package_name*/, absl::string_view /*class_name*/,
+    const ChannelArguments& args) {
+  JNIEnv* jni_env = static_cast<JNIEnv*>(jni_env_void);
+
+  // clang-format off
+  jobject object = grpc_binder::CallStaticJavaMethodForObject(
+      jni_env,
+      "io/grpc/binder/cpp/NativeConnectionHelper",
+      "getServiceBinder",
+      "()Landroid/os/IBinder;");
+  // clang-format on
+
+  grpc_channel_args channel_args;
+  args.SetChannelArgs(&channel_args);
+  return CreateChannelInternal(
+      "",
+      ::grpc::internal::CreateChannelFromBinderImpl(
+          absl::make_unique<grpc_binder::BinderAndroid>(
+              grpc_binder::FromJavaBinder(jni_env, object)),
+          &channel_args),
+      std::vector<
+          std::unique_ptr<experimental::ClientInterceptorFactoryInterface>>());
+}
+
+}  // namespace experimental
+}  // namespace grpc
+
+#else  // !GPR_SUPPORT_BINDER_TRANSPORT
+
+namespace grpc {
+namespace experimental {
+
+void BindToOnDeviceServerService(void*, jobject, absl::string_view,
+                                 absl::string_view) {
+  GPR_ASSERT(0);
+}
+
+std::shared_ptr<grpc::Channel> CreateBinderChannel(void*, jobject,
+                                                   absl::string_view,
+                                                   absl::string_view) {
+  GPR_ASSERT(0);
+  return {};
+}
+
+std::shared_ptr<grpc::Channel> CreateCustomBinderChannel(
+    void*, jobject, absl::string_view, absl::string_view,
+    const ChannelArguments&) {
+  GPR_ASSERT(0);
+  return {};
+}
+
+}  // namespace experimental
+}  // namespace grpc
+
+#endif  // GPR_SUPPORT_BINDER_TRANSPORT
+
+#endif  // GPR_ANDROID
diff --git a/src/core/ext/transport/binder/client/channel_create.h b/src/core/ext/transport/binder/client/channel_create.h
new file mode 100644 (file)
index 0000000..e53ccc4
--- /dev/null
@@ -0,0 +1,60 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#ifndef GRPC_CORE_EXT_TRANSPORT_BINDER_CLIENT_CHANNEL_CREATE_H
+#define GRPC_CORE_EXT_TRANSPORT_BINDER_CLIENT_CHANNEL_CREATE_H
+
+#include <grpc/impl/codegen/port_platform.h>
+
+#ifdef GPR_ANDROID
+
+#include <grpc/support/port_platform.h>
+
+#include <jni.h>
+
+#include "absl/strings/string_view.h"
+
+#include <grpc/impl/codegen/grpc_types.h>
+#include <grpcpp/channel.h>
+#include <grpcpp/support/channel_arguments.h>
+
+namespace grpc {
+namespace experimental {
+
+// This need be called before calling CreateBinderChannel, and the thread need
+// to be free before invoking CreateBinderChannel.
+// TODO(mingcl): Add more explanation on this after we determine the interfaces.
+void BindToOnDeviceServerService(void* jni_env_void, jobject application,
+                                 absl::string_view /*package_name*/,
+                                 absl::string_view /*class_name*/);
+
+// Need to be invoked after BindToOnDeviceServerService
+// Create a new Channel from server package name and service class name
+std::shared_ptr<grpc::Channel> CreateBinderChannel(
+    void* jni_env_void, jobject application, absl::string_view package_name,
+    absl::string_view class_name);
+
+// Need to be invoked after BindToOnDeviceServerService
+// Create a new Channel from server package name and service class name and with
+// custom channel arguments.
+std::shared_ptr<grpc::Channel> CreateCustomBinderChannel(
+    void* jni_env_void, jobject application, absl::string_view package_name,
+    absl::string_view class_name, const ChannelArguments& args);
+
+}  // namespace experimental
+}  // namespace grpc
+
+#endif
+
+#endif  // GRPC_CORE_EXT_TRANSPORT_BINDER_CLIENT_CHANNEL_CREATE_H
diff --git a/src/core/ext/transport/binder/client/channel_create_impl.cc b/src/core/ext/transport/binder/client/channel_create_impl.cc
new file mode 100644 (file)
index 0000000..bde2afc
--- /dev/null
@@ -0,0 +1,61 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#include <grpc/impl/codegen/port_platform.h>
+
+#include "src/core/ext/transport/binder/client/channel_create_impl.h"
+
+#include <memory>
+#include <utility>
+
+#include "src/core/ext/transport/binder/transport/binder_transport.h"
+#include "src/core/ext/transport/binder/wire_format/binder.h"
+#include "src/core/lib/channel/channel_args.h"
+#include "src/core/lib/surface/api_trace.h"
+#include "src/core/lib/surface/channel.h"
+
+namespace grpc {
+namespace internal {
+
+grpc_channel* CreateChannelFromBinderImpl(
+    std::unique_ptr<grpc_binder::Binder> endpoint_binder,
+    const grpc_channel_args* args) {
+  grpc_core::ExecCtx exec_ctx;
+  GRPC_API_TRACE("grpc_channel_create_from_binder(target=%p, args=%p)", 2,
+                 ((void*)1234, args));
+
+  grpc_transport* transport =
+      grpc_create_binder_transport_client(std::move(endpoint_binder));
+  GPR_ASSERT(transport);
+
+  // TODO(b/192207753): check binder alive and ping binder
+
+  // TODO(b/192207758): Figure out if we are required to set authority here
+  grpc_arg default_authority_arg = grpc_channel_arg_string_create(
+      const_cast<char*>(GRPC_ARG_DEFAULT_AUTHORITY),
+      const_cast<char*>("test.authority"));
+  grpc_channel_args* final_args =
+      grpc_channel_args_copy_and_add(args, &default_authority_arg, 1);
+  grpc_error_handle error = GRPC_ERROR_NONE;
+  grpc_channel* channel = grpc_channel_create(
+      "binder_target_placeholder", final_args, GRPC_CLIENT_DIRECT_CHANNEL,
+      transport, nullptr, 0, &error);
+  // TODO(mingcl): Handle error properly
+  GPR_ASSERT(error == GRPC_ERROR_NONE);
+  grpc_channel_args_destroy(final_args);
+  return channel;
+}
+
+}  // namespace internal
+}  // namespace grpc
diff --git a/src/core/ext/transport/binder/client/channel_create_impl.h b/src/core/ext/transport/binder/client/channel_create_impl.h
new file mode 100644 (file)
index 0000000..017d5b2
--- /dev/null
@@ -0,0 +1,33 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#ifndef GRPC_CORE_EXT_TRANSPORT_BINDER_CLIENT_CHANNEL_CREATE_IMPL_H
+#define GRPC_CORE_EXT_TRANSPORT_BINDER_CLIENT_CHANNEL_CREATE_IMPL_H
+
+#include <grpc/impl/codegen/port_platform.h>
+
+#include "src/core/ext/transport/binder/wire_format/binder.h"
+#include "src/core/lib/channel/channel_args.h"
+
+namespace grpc {
+namespace internal {
+
+grpc_channel* CreateChannelFromBinderImpl(
+    std::unique_ptr<grpc_binder::Binder> endpoint_binder,
+    const grpc_channel_args* args);
+
+}  // namespace internal
+}  // namespace grpc
+
+#endif  // GRPC_CORE_EXT_TRANSPORT_BINDER_CLIENT_CHANNEL_CREATE_IMPL_H
diff --git a/src/core/ext/transport/binder/client/jni_utils.cc b/src/core/ext/transport/binder/client/jni_utils.cc
new file mode 100644 (file)
index 0000000..fcdea61
--- /dev/null
@@ -0,0 +1,70 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#include <grpc/impl/codegen/port_platform.h>
+
+#include "src/core/ext/transport/binder/client/jni_utils.h"
+
+#include <grpc/support/log.h>
+
+#if defined(ANDROID) || defined(__ANDROID__)
+
+namespace grpc_binder {
+
+void CallStaticJavaMethod(JNIEnv* env, const std::string& clazz,
+                          const std::string& method, const std::string& type,
+                          jobject application, const std::string& pkg,
+                          const std::string& cls) {
+  jclass cl = env->FindClass(clazz.c_str());
+  if (cl == nullptr) {
+    gpr_log(GPR_ERROR, "No class %s", clazz.c_str());
+  }
+
+  jmethodID mid = env->GetStaticMethodID(cl, method.c_str(), type.c_str());
+  if (mid == nullptr) {
+    gpr_log(GPR_ERROR, "No method id %s", method.c_str());
+  }
+
+  env->CallStaticVoidMethod(cl, mid, application,
+                            env->NewStringUTF(pkg.c_str()),
+                            env->NewStringUTF(cls.c_str()));
+}
+
+jobject CallStaticJavaMethodForObject(JNIEnv* env, const std::string& clazz,
+                                      const std::string& method,
+                                      const std::string& type) {
+  jclass cl = env->FindClass(clazz.c_str());
+  if (cl == nullptr) {
+    gpr_log(GPR_ERROR, "No class %s", clazz.c_str());
+    return nullptr;
+  }
+
+  jmethodID mid = env->GetStaticMethodID(cl, method.c_str(), type.c_str());
+  if (mid == nullptr) {
+    gpr_log(GPR_ERROR, "No method id %s", method.c_str());
+    return nullptr;
+  }
+
+  jobject object = env->CallStaticObjectMethod(cl, mid);
+  if (object == nullptr) {
+    gpr_log(GPR_ERROR, "Got null object from Java");
+    return nullptr;
+  }
+
+  return object;
+}
+
+}  // namespace grpc_binder
+
+#endif
diff --git a/src/core/ext/transport/binder/client/jni_utils.h b/src/core/ext/transport/binder/client/jni_utils.h
new file mode 100644 (file)
index 0000000..b7c55d4
--- /dev/null
@@ -0,0 +1,43 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#ifndef GRPC_CORE_EXT_TRANSPORT_BINDER_CLIENT_JNI_UTILS_H
+#define GRPC_CORE_EXT_TRANSPORT_BINDER_CLIENT_JNI_UTILS_H
+
+#if defined(ANDROID) || defined(__ANDROID__)
+
+#include <grpc/impl/codegen/port_platform.h>
+
+#include <jni.h>
+
+#include <string>
+
+namespace grpc_binder {
+
+// TODO(mingcl): Use string_view
+// For now we hard code the arguments of the Java function because this is only
+// used to call that single function.
+void CallStaticJavaMethod(JNIEnv* env, const std::string& clazz,
+                          const std::string& method, const std::string& type,
+                          jobject application, const std::string& pkg,
+                          const std::string& cls);
+
+jobject CallStaticJavaMethodForObject(JNIEnv* env, const std::string& clazz,
+                                      const std::string& method,
+                                      const std::string& type);
+}  // namespace grpc_binder
+
+#endif
+
+#endif  // GRPC_CORE_EXT_TRANSPORT_BINDER_CLIENT_JNI_UTILS_H
diff --git a/src/core/ext/transport/binder/java/WORKSPACE b/src/core/ext/transport/binder/java/WORKSPACE
new file mode 100644 (file)
index 0000000..e69de29
@@ -1,4 +1,4 @@
-# Copyright 2019 gRPC authors.
+# Copyright 2021 gRPC authors.
 #
 # Licensed under the Apache License, Version 2.0 (the "License");
 # you may not use this file except in compliance with the License.
 # See the License for the specific language governing permissions and
 # limitations under the License.
 
-cdef class _AsyncioResolver:
-    cdef:
-        object _loop
-        grpc_custom_resolver* _grpc_resolver
-        object _task_resolve
+load("@build_bazel_rules_android//android:rules.bzl", "android_library")
 
-    @staticmethod
-    cdef _AsyncioResolver create(grpc_custom_resolver* grpc_resolver)
+licenses(["notice"])
 
-    cdef void resolve(self, const char* host, const char* port)
+android_library(
+    name = "connection_helper",
+    srcs = [
+        "NativeConnectionHelper.java",
+        "SyncServiceConnection.java",
+    ],
+    visibility = ["//visibility:public"],
+    deps = [],
+)
diff --git a/src/core/ext/transport/binder/java/io/grpc/binder/cpp/NativeConnectionHelper.java b/src/core/ext/transport/binder/java/io/grpc/binder/cpp/NativeConnectionHelper.java
new file mode 100644 (file)
index 0000000..6dd1755
--- /dev/null
@@ -0,0 +1,43 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+package io.grpc.binder.cpp;
+
+import android.content.Context;
+import android.os.IBinder;
+import android.os.Parcel;
+
+/**
+ * This class will be invoked by gRPC binder transport internal implementation to perform operations
+ * that are only possible in Java
+ */
+final class NativeConnectionHelper {
+  static SyncServiceConnection s;
+
+  static void tryEstablishConnection(Context context, String pkg, String cls) {
+    s = new SyncServiceConnection(context);
+    s.tryConnect(pkg, cls);
+  }
+
+  // TODO(mingcl): We should notify C++ once we got the service binder so they don't need to call
+  // this function to check. For now we assume that this function will only be called after
+  // successful connection
+  static IBinder getServiceBinder() {
+    return s.getIBinder();
+  }
+
+  static Parcel getEmptyParcel() {
+    return Parcel.obtain();
+  }
+}
diff --git a/src/core/ext/transport/binder/java/io/grpc/binder/cpp/SyncServiceConnection.java b/src/core/ext/transport/binder/java/io/grpc/binder/cpp/SyncServiceConnection.java
new file mode 100644 (file)
index 0000000..66848f3
--- /dev/null
@@ -0,0 +1,68 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+package io.grpc.binder.cpp;
+
+import android.content.ComponentName;
+import android.content.Context;
+import android.content.Intent;
+import android.content.ServiceConnection;
+import android.os.IBinder;
+import android.util.Log;
+
+/* Connects to a service synchronously */
+public class SyncServiceConnection implements ServiceConnection {
+  private final String logTag = "SyncServiceConnection";
+
+  private Context mContext;
+  private IBinder mService;
+
+  public SyncServiceConnection(Context context) {
+    mContext = context;
+  }
+
+  @Override
+  public void onServiceConnected(ComponentName className, IBinder service) {
+    Log.e(logTag, "Service has connected: ");
+    synchronized (this) {
+      mService = service;
+    }
+  }
+
+  @Override
+  public void onServiceDisconnected(ComponentName className) {
+    Log.e(logTag, "Service has disconnected: ");
+  }
+
+  public void tryConnect(String pkg, String cls) {
+    synchronized (this) {
+      Intent intent = new Intent("grpc.io.action.BIND");
+      ComponentName compName = new ComponentName(pkg, cls);
+      intent.setComponent(compName);
+      // Will return true if the system is in the process of bringing up a service that your client
+      // has permission to bind to; false if the system couldn't find the service or if your client
+      // doesn't have permission to bind to it
+      boolean result = mContext.bindService(intent, this, Context.BIND_AUTO_CREATE);
+      if (result) {
+        Log.e(logTag, "bindService ok");
+      } else {
+        Log.e(logTag, "bindService not ok");
+      }
+    }
+  }
+
+  public IBinder getIBinder() {
+    return mService;
+  }
+}
diff --git a/src/core/ext/transport/binder/server/BUILD b/src/core/ext/transport/binder/server/BUILD
new file mode 100644 (file)
index 0000000..a5cf6df
--- /dev/null
@@ -0,0 +1,50 @@
+# Copyright 2021 gRPC authors.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+load("//bazel:grpc_build_system.bzl", "grpc_cc_library")
+
+licenses(["notice"])
+
+package(
+    default_visibility = ["//visibility:public"],
+    features = [
+        "layering_check",
+    ],
+)
+
+grpc_cc_library(
+    name = "grpc_transport_binder_server",
+    srcs = [
+        "binder_server.cc",
+        "binder_server_credentials.cc",
+    ],
+    hdrs = [
+        "binder_server.h",
+        "binder_server_credentials.h",
+    ],
+    external_deps = [
+        "absl/container:flat_hash_map",
+        "absl/memory",
+        "absl/status",
+    ],
+    language = "c++",
+    deps = [
+        "//:gpr_platform",
+        "//:grpc++_internals",
+        "//:grpc_base_c",
+        "//src/core/ext/transport/binder/transport:binder_transport",
+        "//src/core/ext/transport/binder/wire_format:binder",
+        "//src/core/ext/transport/binder/wire_format:binder_android",
+    ],
+)
diff --git a/src/core/ext/transport/binder/server/binder_server.cc b/src/core/ext/transport/binder/server/binder_server.cc
new file mode 100644 (file)
index 0000000..dae27d3
--- /dev/null
@@ -0,0 +1,188 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#include <grpc/impl/codegen/port_platform.h>
+
+#include "src/core/ext/transport/binder/server/binder_server.h"
+
+#include <memory>
+#include <string>
+#include <utility>
+
+#include "absl/memory/memory.h"
+
+#include <grpc/grpc.h>
+
+#include "src/core/ext/transport/binder/transport/binder_transport.h"
+#include "src/core/ext/transport/binder/wire_format/binder_android.h"
+#include "src/core/lib/iomgr/exec_ctx.h"
+#include "src/core/lib/surface/server.h"
+#include "src/core/lib/transport/error_utils.h"
+
+namespace grpc {
+namespace experimental {
+namespace binder {
+
+void* GetEndpointBinder(const std::string& service) {
+  return grpc_get_endpoint_binder(service);
+}
+
+void AddEndpointBinder(const std::string& service, void* endpoint_binder) {
+  grpc_add_endpoint_binder(service, endpoint_binder);
+}
+
+void RemoveEndpointBinder(const std::string& service) {
+  grpc_remove_endpoint_binder(service);
+}
+
+}  // namespace binder
+}  // namespace experimental
+}  // namespace grpc
+
+static absl::flat_hash_map<std::string, void*>* g_endpoint_binder_pool =
+    nullptr;
+
+namespace {
+
+grpc_core::Mutex* GetBinderPoolMutex() {
+  static grpc_core::Mutex* mu = new grpc_core::Mutex();
+  return mu;
+}
+
+}  // namespace
+
+void grpc_add_endpoint_binder(const std::string& service,
+                              void* endpoint_binder) {
+  grpc_core::MutexLock lock(GetBinderPoolMutex());
+  if (g_endpoint_binder_pool == nullptr) {
+    g_endpoint_binder_pool = new absl::flat_hash_map<std::string, void*>();
+  }
+  (*g_endpoint_binder_pool)[service] = endpoint_binder;
+}
+
+void grpc_remove_endpoint_binder(const std::string& service) {
+  grpc_core::MutexLock lock(GetBinderPoolMutex());
+  if (g_endpoint_binder_pool == nullptr) {
+    return;
+  }
+  g_endpoint_binder_pool->erase(service);
+}
+
+void* grpc_get_endpoint_binder(const std::string& service) {
+  grpc_core::MutexLock lock(GetBinderPoolMutex());
+  if (g_endpoint_binder_pool == nullptr) {
+    return nullptr;
+  }
+  auto iter = g_endpoint_binder_pool->find(service);
+  return iter == g_endpoint_binder_pool->end() ? nullptr : iter->second;
+}
+
+namespace grpc_core {
+
+class BinderServerListener : public Server::ListenerInterface {
+ public:
+  BinderServerListener(Server* server, std::string addr,
+                       BinderTxReceiverFactory factory)
+      : server_(server), addr_(std::move(addr)), factory_(std::move(factory)) {}
+
+  void Start(Server* /*server*/,
+             const std::vector<grpc_pollset*>* /*pollsets*/) override {
+    tx_receiver_ = factory_([this](transaction_code_t code,
+                                   const grpc_binder::ReadableParcel* parcel) {
+      return OnSetupTransport(code, parcel);
+    });
+    endpoint_binder_ = tx_receiver_->GetRawBinder();
+    grpc_add_endpoint_binder(addr_, endpoint_binder_);
+  }
+
+  channelz::ListenSocketNode* channelz_listen_socket_node() const override {
+    return nullptr;
+  }
+
+  void SetOnDestroyDone(grpc_closure* on_destroy_done) override {
+    on_destroy_done_ = on_destroy_done;
+  }
+
+  void Orphan() override { delete this; }
+
+  ~BinderServerListener() override {
+    ExecCtx::Get()->Flush();
+    if (on_destroy_done_) {
+      ExecCtx::Run(DEBUG_LOCATION, on_destroy_done_, GRPC_ERROR_NONE);
+      ExecCtx::Get()->Flush();
+    }
+    grpc_remove_endpoint_binder(addr_);
+  }
+
+ private:
+  absl::Status OnSetupTransport(transaction_code_t code,
+                                const grpc_binder::ReadableParcel* parcel) {
+    grpc_core::ExecCtx exec_ctx;
+    if (grpc_binder::BinderTransportTxCode(code) !=
+        grpc_binder::BinderTransportTxCode::SETUP_TRANSPORT) {
+      return absl::InvalidArgumentError("Not a SETUP_TRANSPORT request");
+    }
+    int version;
+    absl::Status status = parcel->ReadInt32(&version);
+    if (!status.ok()) {
+      return status;
+    }
+    gpr_log(GPR_INFO, "version = %d", version);
+    // TODO(waynetu): Check supported version.
+    std::unique_ptr<grpc_binder::Binder> client_binder{};
+    status = parcel->ReadBinder(&client_binder);
+    if (!status.ok()) {
+      return status;
+    }
+    if (!client_binder) {
+      return absl::InvalidArgumentError("NULL binder read from the parcel");
+    }
+    client_binder->Initialize();
+    // Finish the second half of SETUP_TRANSPORT in
+    // grpc_create_binder_transport_server().
+    grpc_transport* server_transport =
+        grpc_create_binder_transport_server(std::move(client_binder));
+    GPR_ASSERT(server_transport);
+    grpc_channel_args* args = grpc_channel_args_copy(server_->channel_args());
+    grpc_error_handle error = server_->SetupTransport(server_transport, nullptr,
+                                                      args, nullptr, nullptr);
+    grpc_channel_args_destroy(args);
+    return grpc_error_to_absl_status(error);
+  }
+
+  Server* server_;
+  grpc_closure* on_destroy_done_ = nullptr;
+  std::string addr_;
+  BinderTxReceiverFactory factory_;
+  void* endpoint_binder_ = nullptr;
+  std::unique_ptr<grpc_binder::TransactionReceiver> tx_receiver_;
+};
+
+bool AddBinderPort(const std::string& addr, grpc_server* server,
+                   BinderTxReceiverFactory factory) {
+  const std::string kBinderUriScheme = "binder:";
+  if (addr.compare(0, kBinderUriScheme.size(), kBinderUriScheme) != 0) {
+    return false;
+  }
+  size_t pos = kBinderUriScheme.size();
+  while (pos < addr.size() && addr[pos] == '/') pos++;
+  grpc_core::Server* core_server = server->core_server.get();
+  core_server->AddListener(
+      grpc_core::OrphanablePtr<grpc_core::Server::ListenerInterface>(
+          new grpc_core::BinderServerListener(core_server, addr.substr(pos),
+                                              std::move(factory))));
+  return true;
+}
+
+}  // namespace grpc_core
diff --git a/src/core/ext/transport/binder/server/binder_server.h b/src/core/ext/transport/binder/server/binder_server.h
new file mode 100644 (file)
index 0000000..66cbb81
--- /dev/null
@@ -0,0 +1,63 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#ifndef GRPC_CORE_EXT_TRANSPORT_BINDER_SERVER_BINDER_SERVER_H
+#define GRPC_CORE_EXT_TRANSPORT_BINDER_SERVER_BINDER_SERVER_H
+
+#include <grpc/impl/codegen/port_platform.h>
+
+#include <string>
+
+#include "absl/container/flat_hash_map.h"
+#include "absl/status/status.h"
+
+#include "src/core/ext/transport/binder/transport/binder_transport.h"
+#include "src/core/ext/transport/binder/wire_format/binder.h"
+#include "src/core/lib/iomgr/exec_ctx.h"
+#include "src/core/lib/surface/server.h"
+#include "src/core/lib/transport/error_utils.h"
+
+// TODO(waynetu): This is part of the public API and should be moved to the
+// include/ folder.
+namespace grpc {
+namespace experimental {
+namespace binder {
+
+void* GetEndpointBinder(const std::string& service);
+void AddEndpointBinder(const std::string& service, void* endpoint_binder);
+void RemoveEndpointBinder(const std::string& service);
+
+}  // namespace binder
+}  // namespace experimental
+}  // namespace grpc
+
+void grpc_add_endpoint_binder(const std::string& service,
+                              void* endpoint_binder);
+void grpc_remove_endpoint_binder(const std::string& service);
+void* grpc_get_endpoint_binder(const std::string& service);
+
+namespace grpc_core {
+
+// Consume a callback, produce a transaction listener. This is used to perform
+// testing in non-Android environments where the actual binder is not available.
+using BinderTxReceiverFactory =
+    std::function<std::unique_ptr<grpc_binder::TransactionReceiver>(
+        grpc_binder::TransactionReceiver::OnTransactCb)>;
+
+bool AddBinderPort(const std::string& addr, grpc_server* server,
+                   BinderTxReceiverFactory factory);
+
+}  // namespace grpc_core
+
+#endif  // GRPC_CORE_EXT_TRANSPORT_BINDER_SERVER_BINDER_SERVER_H
diff --git a/src/core/ext/transport/binder/server/binder_server_credentials.cc b/src/core/ext/transport/binder/server/binder_server_credentials.cc
new file mode 100644 (file)
index 0000000..ee57e6b
--- /dev/null
@@ -0,0 +1,61 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#include <grpc/impl/codegen/port_platform.h>
+
+#include <grpcpp/security/server_credentials.h>
+
+#include "src/core/ext/transport/binder/server/binder_server.h"
+#include "src/core/ext/transport/binder/wire_format/binder_android.h"
+
+namespace grpc {
+namespace experimental {
+
+namespace {
+
+class BinderServerCredentialsImpl final : public ServerCredentials {
+ public:
+#ifdef GPR_ANDROID
+  int AddPortToServer(const std::string& addr, grpc_server* server) override {
+    return grpc_core::AddBinderPort(
+        std::string(addr), server,
+        [](grpc_binder::TransactionReceiver::OnTransactCb transact_cb) {
+          return absl::make_unique<grpc_binder::TransactionReceiverAndroid>(
+              nullptr, std::move(transact_cb));
+        });
+  }
+#else
+  int AddPortToServer(const std::string& /*addr*/,
+                      grpc_server* /*server*/) override {
+    return 0;
+  }
+#endif  // GPR_ANDROID
+
+  void SetAuthMetadataProcessor(
+      const std::shared_ptr<AuthMetadataProcessor>& /*processor*/) override {
+    GPR_ASSERT(false);
+  }
+
+ private:
+  bool IsInsecure() const override { return true; }
+};
+
+}  // namespace
+
+std::shared_ptr<ServerCredentials> BinderServerCredentials() {
+  return std::shared_ptr<ServerCredentials>(new BinderServerCredentialsImpl());
+}
+
+}  // namespace experimental
+}  // namespace grpc
diff --git a/src/core/ext/transport/binder/server/binder_server_credentials.h b/src/core/ext/transport/binder/server/binder_server_credentials.h
new file mode 100644 (file)
index 0000000..e8c326f
--- /dev/null
@@ -0,0 +1,35 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#ifndef GRPC_CORE_EXT_TRANSPORT_BINDER_SERVER_BINDER_SERVER_CREDENTIALS_H
+#define GRPC_CORE_EXT_TRANSPORT_BINDER_SERVER_BINDER_SERVER_CREDENTIALS_H
+
+#include <grpc/impl/codegen/port_platform.h>
+
+#include <grpcpp/security/server_credentials.h>
+
+namespace grpc {
+namespace experimental {
+
+/// Builds Binder ServerCredentials.
+///
+/// Calling \a ServerBuilder::AddListeningPort() with Binder ServerCredentials
+/// in a non-Android environment will make the subsequent call to
+/// \a ServerBuilder::BuildAndStart() returns a null pointer.
+std::shared_ptr<grpc::ServerCredentials> BinderServerCredentials();
+
+}  // namespace experimental
+}  // namespace grpc
+
+#endif  // GRPC_CORE_EXT_TRANSPORT_BINDER_SERVER_BINDER_SERVER_CREDENTIALS_H
diff --git a/src/core/ext/transport/binder/transport/BUILD b/src/core/ext/transport/binder/transport/BUILD
new file mode 100644 (file)
index 0000000..2f83a4e
--- /dev/null
@@ -0,0 +1,49 @@
+# Copyright 2021 gRPC authors.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+load("//bazel:grpc_build_system.bzl", "grpc_cc_library")
+
+licenses(["notice"])
+
+package(
+    default_visibility = ["//visibility:public"],
+    features = [
+        "layering_check",
+    ],
+)
+
+grpc_cc_library(
+    name = "binder_transport",
+    srcs = [
+        "binder_transport.cc",
+    ],
+    hdrs = [
+        "binder_stream.h",
+        "binder_transport.h",
+    ],
+    external_deps = [
+        "absl/container:flat_hash_map",
+        "absl/memory",
+        "absl/strings",
+    ],
+    deps = [
+        "//:gpr_base",
+        "//:gpr_platform",
+        "//:grpc_base_c",
+        "//src/core/ext/transport/binder/utils:transport_stream_receiver",
+        "//src/core/ext/transport/binder/wire_format:binder",
+        "//src/core/ext/transport/binder/wire_format:wire_reader",
+        "//src/core/ext/transport/binder/wire_format:wire_writer",
+    ],
+)
diff --git a/src/core/ext/transport/binder/transport/binder_stream.h b/src/core/ext/transport/binder/transport/binder_stream.h
new file mode 100644 (file)
index 0000000..3bdd5d7
--- /dev/null
@@ -0,0 +1,113 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#ifndef GRPC_CORE_EXT_TRANSPORT_BINDER_TRANSPORT_BINDER_STREAM_H
+#define GRPC_CORE_EXT_TRANSPORT_BINDER_TRANSPORT_BINDER_STREAM_H
+
+#include <grpc/impl/codegen/port_platform.h>
+
+#include "src/core/ext/transport/binder/transport/binder_transport.h"
+
+struct RecvInitialMetadataArgs {
+  grpc_binder_stream* gbs;
+  grpc_binder_transport* gbt;
+  int tx_code;
+  absl::StatusOr<grpc_binder::Metadata> initial_metadata;
+};
+
+struct RecvMessageArgs {
+  grpc_binder_stream* gbs;
+  grpc_binder_transport* gbt;
+  int tx_code;
+  absl::StatusOr<std::string> message;
+};
+
+struct RecvTrailingMetadataArgs {
+  grpc_binder_stream* gbs;
+  grpc_binder_transport* gbt;
+  int tx_code;
+  absl::StatusOr<grpc_binder::Metadata> trailing_metadata;
+  int status;
+};
+
+// TODO(mingcl): Figure out if we want to use class instead of struct here
+struct grpc_binder_stream {
+  // server_data will be null for client, and for server it will be whatever
+  // passed in to the accept_stream_fn callback by client.
+  grpc_binder_stream(grpc_binder_transport* t, grpc_stream_refcount* refcount,
+                     const void* /*server_data*/, grpc_core::Arena* arena,
+                     int tx_code, bool is_client)
+      : t(t),
+        refcount(refcount),
+        arena(arena),
+        tx_code(tx_code),
+        is_client(is_client) {
+    // TODO(waynetu): Should this be protected?
+    t->registered_stream[tx_code] = this;
+
+    recv_initial_metadata_args.gbs = this;
+    recv_initial_metadata_args.gbt = t;
+    recv_message_args.gbs = this;
+    recv_message_args.gbt = t;
+    recv_trailing_metadata_args.gbs = this;
+    recv_trailing_metadata_args.gbt = t;
+  }
+
+  ~grpc_binder_stream() {
+    GRPC_ERROR_UNREF(cancel_self_error);
+    if (destroy_stream_then_closure != nullptr) {
+      grpc_core::ExecCtx::Run(DEBUG_LOCATION, destroy_stream_then_closure,
+                              GRPC_ERROR_NONE);
+    }
+  }
+
+  int GetTxCode() const { return tx_code; }
+
+  grpc_binder_transport* t;
+  grpc_stream_refcount* refcount;
+  grpc_core::Arena* arena;
+  grpc_core::ManualConstructor<grpc_core::SliceBufferByteStream> sbs;
+  int tx_code;
+  bool is_client;
+  bool is_closed = false;
+
+  grpc_closure* destroy_stream_then_closure = nullptr;
+  grpc_closure destroy_stream;
+
+  // The reason why this stream is cancelled and closed.
+  grpc_error_handle cancel_self_error = GRPC_ERROR_NONE;
+
+  grpc_closure recv_initial_metadata_closure;
+  RecvInitialMetadataArgs recv_initial_metadata_args;
+  grpc_closure recv_message_closure;
+  RecvMessageArgs recv_message_args;
+  grpc_closure recv_trailing_metadata_closure;
+  RecvTrailingMetadataArgs recv_trailing_metadata_args;
+
+  // We store these fields passed from op batch, in order to access them through
+  // grpc_binder_stream
+  grpc_metadata_batch* recv_initial_metadata;
+  grpc_closure* recv_initial_metadata_ready = nullptr;
+  bool* trailing_metadata_available = nullptr;
+  grpc_core::OrphanablePtr<grpc_core::ByteStream>* recv_message;
+  grpc_closure* recv_message_ready = nullptr;
+  bool* call_failed_before_recv_message = nullptr;
+  grpc_metadata_batch* recv_trailing_metadata;
+  grpc_closure* recv_trailing_metadata_finished = nullptr;
+
+  bool trailing_metadata_sent = false;
+  bool need_to_call_trailing_metadata_callback = false;
+};
+
+#endif  // GRPC_CORE_EXT_TRANSPORT_BINDER_TRANSPORT_BINDER_STREAM_H
diff --git a/src/core/ext/transport/binder/transport/binder_transport.cc b/src/core/ext/transport/binder/transport/binder_transport.cc
new file mode 100644 (file)
index 0000000..dbde037
--- /dev/null
@@ -0,0 +1,752 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#include <grpc/support/port_platform.h>
+
+#include "src/core/ext/transport/binder/transport/binder_transport.h"
+
+#include <cstdint>
+#include <memory>
+#include <string>
+#include <utility>
+
+#include "absl/memory/memory.h"
+#include "absl/strings/str_cat.h"
+#include "absl/strings/substitute.h"
+
+#include <grpc/support/log.h>
+
+#include "src/core/ext/transport/binder/transport/binder_stream.h"
+#include "src/core/ext/transport/binder/utils/transport_stream_receiver.h"
+#include "src/core/ext/transport/binder/utils/transport_stream_receiver_impl.h"
+#include "src/core/ext/transport/binder/wire_format/wire_reader.h"
+#include "src/core/ext/transport/binder/wire_format/wire_reader_impl.h"
+#include "src/core/ext/transport/binder/wire_format/wire_writer.h"
+#include "src/core/lib/iomgr/exec_ctx.h"
+#include "src/core/lib/slice/slice_utils.h"
+#include "src/core/lib/transport/byte_stream.h"
+#include "src/core/lib/transport/error_utils.h"
+#include "src/core/lib/transport/metadata_batch.h"
+#include "src/core/lib/transport/static_metadata.h"
+#include "src/core/lib/transport/status_metadata.h"
+#include "src/core/lib/transport/transport.h"
+
+#ifndef NDEBUG
+static void grpc_binder_stream_ref(grpc_binder_stream* s, const char* reason) {
+  grpc_stream_ref(s->refcount, reason);
+}
+static void grpc_binder_stream_unref(grpc_binder_stream* s,
+                                     const char* reason) {
+  grpc_stream_unref(s->refcount, reason);
+}
+static void grpc_binder_ref_transport(grpc_binder_transport* t,
+                                      const char* reason, const char* file,
+                                      int line) {
+  t->refs.Ref(grpc_core::DebugLocation(file, line), reason);
+}
+static void grpc_binder_unref_transport(grpc_binder_transport* t,
+                                        const char* reason, const char* file,
+                                        int line) {
+  if (t->refs.Unref(grpc_core::DebugLocation(file, line), reason)) {
+    delete t;
+  }
+}
+#else
+static void grpc_binder_stream_ref(grpc_binder_stream* s) {
+  grpc_stream_ref(s->refcount);
+}
+static void grpc_binder_stream_unref(grpc_binder_stream* s) {
+  grpc_stream_unref(s->refcount);
+}
+static void grpc_binder_ref_transport(grpc_binder_transport* t) {
+  t->refs.Ref();
+}
+static void grpc_binder_unref_transport(grpc_binder_transport* t) {
+  if (t->refs.Unref()) {
+    delete t;
+  }
+}
+#endif
+
+#ifndef NDEBUG
+#define GRPC_BINDER_STREAM_REF(stream, reason) \
+  grpc_binder_stream_ref(stream, reason)
+#define GRPC_BINDER_STREAM_UNREF(stream, reason) \
+  grpc_binder_stream_unref(stream, reason)
+#define GRPC_BINDER_REF_TRANSPORT(t, r) \
+  grpc_binder_ref_transport(t, r, __FILE__, __LINE__)
+#define GRPC_BINDER_UNREF_TRANSPORT(t, r) \
+  grpc_binder_unref_transport(t, r, __FILE__, __LINE__)
+#else
+#define GRPC_BINDER_STREAM_REF(stream, reason) grpc_binder_stream_ref(stream)
+#define GRPC_BINDER_STREAM_UNREF(stream, reason) \
+  grpc_binder_stream_unref(stream)
+#define GRPC_BINDER_REF_TRANSPORT(t, r) grpc_binder_ref_transport(t)
+#define GRPC_BINDER_UNREF_TRANSPORT(t, r) grpc_binder_unref_transport(t)
+#endif
+
+static int init_stream(grpc_transport* gt, grpc_stream* gs,
+                       grpc_stream_refcount* refcount, const void* server_data,
+                       grpc_core::Arena* arena) {
+  GPR_TIMER_SCOPE("init_stream", 0);
+  gpr_log(GPR_INFO, "%s = %p %p %p %p %p", __func__, gt, gs, refcount,
+          server_data, arena);
+  grpc_binder_transport* t = reinterpret_cast<grpc_binder_transport*>(gt);
+  // TODO(mingcl): Figure out if we need to worry about concurrent invocation
+  // here
+  new (gs) grpc_binder_stream(t, refcount, server_data, arena,
+                              t->NewStreamTxCode(), t->is_client);
+  return 0;
+}
+
+static void set_pollset(grpc_transport* gt, grpc_stream* gs, grpc_pollset* gp) {
+  gpr_log(GPR_INFO, "%s = %p %p %p", __func__, gt, gs, gp);
+}
+
+static void set_pollset_set(grpc_transport*, grpc_stream*, grpc_pollset_set*) {
+  gpr_log(GPR_INFO, __func__);
+}
+
+static void AssignMetadata(grpc_metadata_batch* mb, grpc_core::Arena* arena,
+                           const grpc_binder::Metadata& md) {
+  grpc_metadata_batch_init(mb);
+  for (auto& p : md) {
+    grpc_linked_mdelem* glm = static_cast<grpc_linked_mdelem*>(
+        arena->Alloc(sizeof(grpc_linked_mdelem)));
+    memset(glm, 0, sizeof(grpc_linked_mdelem));
+    grpc_slice key = grpc_slice_from_cpp_string(p.first);
+    grpc_slice value = grpc_slice_from_cpp_string(p.second);
+    glm->md = grpc_mdelem_from_slices(grpc_slice_intern(key),
+                                      grpc_slice_intern(value));
+    // Unref here to prevent memory leak
+    grpc_slice_unref_internal(key);
+    grpc_slice_unref_internal(value);
+    GPR_ASSERT(grpc_metadata_batch_link_tail(mb, glm) == GRPC_ERROR_NONE);
+  }
+}
+
+static void cancel_stream_locked(grpc_binder_transport* gbt,
+                                 grpc_binder_stream* gbs,
+                                 grpc_error_handle error) {
+  gpr_log(GPR_INFO, "cancel_stream_locked");
+  if (!gbs->is_closed) {
+    GPR_ASSERT(gbs->cancel_self_error == GRPC_ERROR_NONE);
+    gbs->is_closed = true;
+    gbs->cancel_self_error = GRPC_ERROR_REF(error);
+    gbt->transport_stream_receiver->CancelStream(gbs->tx_code);
+    gbt->registered_stream.erase(gbs->tx_code);
+    if (gbs->recv_initial_metadata_ready != nullptr) {
+      grpc_core::ExecCtx::Run(DEBUG_LOCATION, gbs->recv_initial_metadata_ready,
+                              GRPC_ERROR_REF(error));
+      gbs->recv_initial_metadata_ready = nullptr;
+      gbs->recv_initial_metadata = nullptr;
+      gbs->trailing_metadata_available = nullptr;
+    }
+    if (gbs->recv_message_ready != nullptr) {
+      grpc_core::ExecCtx::Run(DEBUG_LOCATION, gbs->recv_message_ready,
+                              GRPC_ERROR_REF(error));
+      gbs->recv_message_ready = nullptr;
+      gbs->recv_message->reset();
+      gbs->recv_message = nullptr;
+      gbs->call_failed_before_recv_message = nullptr;
+    }
+    if (gbs->recv_trailing_metadata_finished != nullptr) {
+      grpc_core::ExecCtx::Run(DEBUG_LOCATION,
+                              gbs->recv_trailing_metadata_finished,
+                              GRPC_ERROR_REF(error));
+      gbs->recv_trailing_metadata_finished = nullptr;
+      gbs->recv_trailing_metadata = nullptr;
+    }
+  }
+  GRPC_ERROR_UNREF(error);
+}
+
+static void recv_initial_metadata_locked(void* arg,
+                                         grpc_error_handle /*error*/) {
+  RecvInitialMetadataArgs* args = static_cast<RecvInitialMetadataArgs*>(arg);
+  grpc_binder_stream* gbs = args->gbs;
+
+  gpr_log(GPR_INFO,
+          "recv_initial_metadata_locked is_client = %d is_closed = %d",
+          gbs->is_client, gbs->is_closed);
+
+  if (!gbs->is_closed) {
+    grpc_error_handle error = [&] {
+      GPR_ASSERT(gbs->recv_initial_metadata);
+      GPR_ASSERT(gbs->recv_initial_metadata_ready);
+      if (!args->initial_metadata.ok()) {
+        gpr_log(GPR_ERROR, "Failed to parse initial metadata");
+        return absl_status_to_grpc_error(args->initial_metadata.status());
+      }
+      AssignMetadata(gbs->recv_initial_metadata, gbs->arena,
+                     *args->initial_metadata);
+      return GRPC_ERROR_NONE;
+    }();
+
+    grpc_closure* cb = gbs->recv_initial_metadata_ready;
+    gbs->recv_initial_metadata_ready = nullptr;
+    gbs->recv_initial_metadata = nullptr;
+    grpc_core::ExecCtx::Run(DEBUG_LOCATION, cb, error);
+  }
+  GRPC_BINDER_STREAM_UNREF(gbs, "recv_initial_metadata");
+}
+
+static void recv_message_locked(void* arg, grpc_error_handle /*error*/) {
+  RecvMessageArgs* args = static_cast<RecvMessageArgs*>(arg);
+  grpc_binder_stream* gbs = args->gbs;
+
+  gpr_log(GPR_INFO, "recv_message_locked is_client = %d is_closed = %d",
+          gbs->is_client, gbs->is_closed);
+
+  if (!gbs->is_closed) {
+    grpc_error_handle error = [&] {
+      GPR_ASSERT(gbs->recv_message);
+      GPR_ASSERT(gbs->recv_message_ready);
+      if (!args->message.ok()) {
+        gpr_log(GPR_ERROR, "Failed to receive message");
+        if (args->message.status().message() ==
+            grpc_binder::TransportStreamReceiver::
+                kGrpcBinderTransportCancelledGracefully) {
+          gpr_log(GPR_ERROR, "message cancelled gracefully");
+          // Cancelled because we've already received trailing metadata.
+          // It's not an error in this case.
+          return GRPC_ERROR_NONE;
+        } else {
+          return absl_status_to_grpc_error(args->message.status());
+        }
+      }
+      grpc_slice_buffer buf;
+      grpc_slice_buffer_init(&buf);
+      grpc_slice_buffer_add(&buf, grpc_slice_from_cpp_string(*args->message));
+
+      gbs->sbs.Init(&buf, 0);
+      gbs->recv_message->reset(gbs->sbs.get());
+      return GRPC_ERROR_NONE;
+    }();
+
+    if (error != GRPC_ERROR_NONE &&
+        gbs->call_failed_before_recv_message != nullptr) {
+      *gbs->call_failed_before_recv_message = true;
+    }
+    grpc_closure* cb = gbs->recv_message_ready;
+    gbs->recv_message_ready = nullptr;
+    gbs->recv_message = nullptr;
+    grpc_core::ExecCtx::Run(DEBUG_LOCATION, cb, error);
+  }
+
+  GRPC_BINDER_STREAM_UNREF(gbs, "recv_message");
+}
+
+static void recv_trailing_metadata_locked(void* arg,
+                                          grpc_error_handle /*error*/) {
+  RecvTrailingMetadataArgs* args = static_cast<RecvTrailingMetadataArgs*>(arg);
+  grpc_binder_stream* gbs = args->gbs;
+
+  gpr_log(GPR_INFO,
+          "recv_trailing_metadata_locked is_client = %d is_closed = %d",
+          gbs->is_client, gbs->is_closed);
+
+  if (!gbs->is_closed) {
+    grpc_error_handle error = [&] {
+      GPR_ASSERT(gbs->recv_trailing_metadata);
+      GPR_ASSERT(gbs->recv_trailing_metadata_finished);
+      if (!args->trailing_metadata.ok()) {
+        gpr_log(GPR_ERROR, "Failed to receive trailing metadata");
+        return absl_status_to_grpc_error(args->trailing_metadata.status());
+      }
+      if (!gbs->is_client) {
+        // Client will not send non-empty trailing metadata.
+        if (!args->trailing_metadata.value().empty()) {
+          gpr_log(GPR_ERROR, "Server receives non-empty trailing metadata.");
+          return GRPC_ERROR_CANCELLED;
+        }
+      } else {
+        AssignMetadata(gbs->recv_trailing_metadata, gbs->arena,
+                       *args->trailing_metadata);
+        // Append status to metadata
+        // TODO(b/192208695): See if we can avoid to manually put status
+        // code into the header
+        gpr_log(GPR_INFO, "status = %d", args->status);
+        grpc_linked_mdelem* glm = static_cast<grpc_linked_mdelem*>(
+            gbs->arena->Alloc(sizeof(grpc_linked_mdelem)));
+        glm->md = grpc_get_reffed_status_elem(args->status);
+        GPR_ASSERT(grpc_metadata_batch_link_tail(gbs->recv_trailing_metadata,
+                                                 glm) == GRPC_ERROR_NONE);
+        gpr_log(GPR_INFO, "trailing_metadata = %p",
+                gbs->recv_trailing_metadata);
+        gpr_log(GPR_INFO, "glm = %p", glm);
+      }
+      return GRPC_ERROR_NONE;
+    }();
+
+    if (gbs->is_client || gbs->trailing_metadata_sent) {
+      grpc_closure* cb = gbs->recv_trailing_metadata_finished;
+      gbs->recv_trailing_metadata_finished = nullptr;
+      gbs->recv_trailing_metadata = nullptr;
+      grpc_core::ExecCtx::Run(DEBUG_LOCATION, cb, error);
+    } else {
+      // According to transport explaineer - "Server extra: This op shouldn't
+      // actually be considered complete until the server has also sent trailing
+      // metadata to provide the other side with final status"
+      //
+      // We haven't sent trailing metadata yet, so we have to delay completing
+      // the recv_trailing_metadata callback.
+      gbs->need_to_call_trailing_metadata_callback = true;
+    }
+  }
+  GRPC_BINDER_STREAM_UNREF(gbs, "recv_trailing_metadata");
+}
+
+static void perform_stream_op_locked(void* stream_op,
+                                     grpc_error_handle /*error*/) {
+  grpc_transport_stream_op_batch* op =
+      static_cast<grpc_transport_stream_op_batch*>(stream_op);
+  grpc_binder_stream* gbs =
+      static_cast<grpc_binder_stream*>(op->handler_private.extra_arg);
+  grpc_binder_transport* gbt = gbs->t;
+  if (op->cancel_stream) {
+    // TODO(waynetu): Is this true?
+    GPR_ASSERT(!op->send_initial_metadata && !op->send_message &&
+               !op->send_trailing_metadata && !op->recv_initial_metadata &&
+               !op->recv_message && !op->recv_trailing_metadata);
+    gpr_log(GPR_INFO, "cancel_stream is_client = %d", gbs->is_client);
+    if (!gbs->is_client) {
+      // Send trailing metadata to inform the other end about the cancellation,
+      // regardless if we'd already done that or not.
+      grpc_binder::Transaction cancel_tx(gbs->GetTxCode(), gbt->is_client);
+      cancel_tx.SetSuffix(grpc_binder::Metadata{});
+      cancel_tx.SetStatus(1);
+      absl::Status status = gbt->wire_writer->RpcCall(cancel_tx);
+    }
+    cancel_stream_locked(gbt, gbs, op->payload->cancel_stream.cancel_error);
+    if (op->on_complete != nullptr) {
+      grpc_core::ExecCtx::Run(DEBUG_LOCATION, op->on_complete, GRPC_ERROR_NONE);
+    }
+    GRPC_BINDER_STREAM_UNREF(gbs, "perform_stream_op");
+    return;
+  }
+
+  if (gbs->is_closed) {
+    if (op->send_message) {
+      // Reset the send_message payload to prevent memory leaks.
+      op->payload->send_message.send_message.reset();
+    }
+    if (op->recv_initial_metadata) {
+      grpc_core::ExecCtx::Run(
+          DEBUG_LOCATION,
+          op->payload->recv_initial_metadata.recv_initial_metadata_ready,
+          GRPC_ERROR_REF(gbs->cancel_self_error));
+    }
+    if (op->recv_message) {
+      grpc_core::ExecCtx::Run(DEBUG_LOCATION,
+                              op->payload->recv_message.recv_message_ready,
+                              GRPC_ERROR_REF(gbs->cancel_self_error));
+    }
+    if (op->recv_trailing_metadata) {
+      grpc_core::ExecCtx::Run(
+          DEBUG_LOCATION,
+          op->payload->recv_trailing_metadata.recv_trailing_metadata_ready,
+          GRPC_ERROR_REF(gbs->cancel_self_error));
+    }
+    if (op->on_complete != nullptr) {
+      grpc_core::ExecCtx::Run(DEBUG_LOCATION, op->on_complete,
+                              GRPC_ERROR_REF(gbs->cancel_self_error));
+    }
+    GRPC_BINDER_STREAM_UNREF(gbs, "perform_stream_op");
+    return;
+  }
+
+  int tx_code = gbs->tx_code;
+  grpc_binder::Transaction tx(tx_code, gbt->is_client);
+
+  if (op->send_initial_metadata) {
+    gpr_log(GPR_INFO, "send_initial_metadata");
+    grpc_binder::Metadata init_md;
+    auto batch = op->payload->send_initial_metadata.send_initial_metadata;
+
+    for (grpc_linked_mdelem* md = batch->list.head; md != nullptr;
+         md = md->next) {
+      absl::string_view key =
+          grpc_core::StringViewFromSlice(GRPC_MDKEY(md->md));
+      absl::string_view value =
+          grpc_core::StringViewFromSlice(GRPC_MDVALUE(md->md));
+      gpr_log(GPR_INFO, "send initial metatday key-value %s",
+              absl::StrCat(key, " ", value).c_str());
+      if (grpc_slice_eq(GRPC_MDKEY(md->md), GRPC_MDSTR_PATH)) {
+        // TODO(b/192208403): Figure out if it is correct to simply drop '/'
+        // prefix and treat it as rpc method name
+        GPR_ASSERT(value[0] == '/');
+        std::string path = std::string(value).substr(1);
+
+        // Only client send method ref.
+        GPR_ASSERT(gbt->is_client);
+        tx.SetMethodRef(path);
+      } else {
+        init_md.emplace_back(std::string(key), std::string(value));
+      }
+    }
+    tx.SetPrefix(init_md);
+  }
+  if (op->send_message) {
+    gpr_log(GPR_INFO, "send_message");
+    size_t remaining = op->payload->send_message.send_message->length();
+    std::string message_data;
+    while (remaining > 0) {
+      grpc_slice message_slice;
+      // TODO(waynetu): Temporarily assume that the message is ready.
+      GPR_ASSERT(
+          op->payload->send_message.send_message->Next(SIZE_MAX, nullptr));
+      grpc_error_handle error =
+          op->payload->send_message.send_message->Pull(&message_slice);
+      // TODO(waynetu): Cancel the stream if error is not GRPC_ERROR_NONE.
+      GPR_ASSERT(error == GRPC_ERROR_NONE);
+      uint8_t* p = GRPC_SLICE_START_PTR(message_slice);
+      size_t len = GRPC_SLICE_LENGTH(message_slice);
+      remaining -= len;
+      message_data += std::string(reinterpret_cast<char*>(p), len);
+      grpc_slice_unref_internal(message_slice);
+    }
+    gpr_log(GPR_INFO, "message_data = %s", message_data.c_str());
+    tx.SetData(message_data);
+    // TODO(b/192369787): Are we supposed to reset here to avoid
+    // use-after-free issue in call.cc?
+    op->payload->send_message.send_message.reset();
+  }
+
+  if (op->send_trailing_metadata) {
+    gpr_log(GPR_INFO, "send_trailing_metadata");
+    auto batch = op->payload->send_trailing_metadata.send_trailing_metadata;
+    grpc_binder::Metadata trailing_metadata;
+
+    for (grpc_linked_mdelem* md = batch->list.head; md != nullptr;
+         md = md->next) {
+      // Client will not send trailing metadata.
+      GPR_ASSERT(!gbt->is_client);
+
+      if (grpc_slice_eq(GRPC_MDKEY(md->md), GRPC_MDSTR_GRPC_STATUS)) {
+        int status = grpc_get_status_code_from_metadata(md->md);
+        gpr_log(GPR_INFO, "send trailing metadata status = %d", status);
+        tx.SetStatus(status);
+      } else {
+        absl::string_view key =
+            grpc_core::StringViewFromSlice(GRPC_MDKEY(md->md));
+        absl::string_view value =
+            grpc_core::StringViewFromSlice(GRPC_MDVALUE(md->md));
+        gpr_log(GPR_INFO, "send trailing metatday key-value %s",
+                absl::StrCat(key, " ", value).c_str());
+        trailing_metadata.emplace_back(std::string(key), std::string(value));
+      }
+    }
+    // TODO(mingcl): Will we ever has key-value pair here? According to
+    // wireformat client suffix data is always empty.
+    tx.SetSuffix(trailing_metadata);
+  }
+  if (op->recv_initial_metadata) {
+    gpr_log(GPR_INFO, "recv_initial_metadata");
+    gbs->recv_initial_metadata_ready =
+        op->payload->recv_initial_metadata.recv_initial_metadata_ready;
+    gbs->recv_initial_metadata =
+        op->payload->recv_initial_metadata.recv_initial_metadata;
+    gbs->trailing_metadata_available =
+        op->payload->recv_initial_metadata.trailing_metadata_available;
+    GRPC_BINDER_STREAM_REF(gbs, "recv_initial_metadata");
+    gbt->transport_stream_receiver->RegisterRecvInitialMetadata(
+        tx_code, [tx_code, gbs,
+                  gbt](absl::StatusOr<grpc_binder::Metadata> initial_metadata) {
+          grpc_core::ExecCtx exec_ctx;
+          if (gbs->is_closed) {
+            GRPC_BINDER_STREAM_UNREF(gbs, "recv_initial_metadata");
+            return;
+          }
+          gbs->recv_initial_metadata_args.tx_code = tx_code;
+          gbs->recv_initial_metadata_args.initial_metadata =
+              std::move(initial_metadata);
+          gbt->combiner->Run(
+              GRPC_CLOSURE_INIT(&gbs->recv_initial_metadata_closure,
+                                recv_initial_metadata_locked,
+                                &gbs->recv_initial_metadata_args, nullptr),
+              GRPC_ERROR_NONE);
+        });
+  }
+  if (op->recv_message) {
+    gpr_log(GPR_INFO, "recv_message");
+    gbs->recv_message_ready = op->payload->recv_message.recv_message_ready;
+    gbs->recv_message = op->payload->recv_message.recv_message;
+    gbs->call_failed_before_recv_message =
+        op->payload->recv_message.call_failed_before_recv_message;
+    GRPC_BINDER_STREAM_REF(gbs, "recv_message");
+    gbt->transport_stream_receiver->RegisterRecvMessage(
+        tx_code, [tx_code, gbs, gbt](absl::StatusOr<std::string> message) {
+          grpc_core::ExecCtx exec_ctx;
+          if (gbs->is_closed) {
+            GRPC_BINDER_STREAM_UNREF(gbs, "recv_message");
+            return;
+          }
+          gbs->recv_message_args.tx_code = tx_code;
+          gbs->recv_message_args.message = std::move(message);
+          gbt->combiner->Run(
+              GRPC_CLOSURE_INIT(&gbs->recv_message_closure, recv_message_locked,
+                                &gbs->recv_message_args, nullptr),
+              GRPC_ERROR_NONE);
+        });
+  }
+  if (op->recv_trailing_metadata) {
+    gpr_log(GPR_INFO, "recv_trailing_metadata");
+    gbs->recv_trailing_metadata_finished =
+        op->payload->recv_trailing_metadata.recv_trailing_metadata_ready;
+    gbs->recv_trailing_metadata =
+        op->payload->recv_trailing_metadata.recv_trailing_metadata;
+    GRPC_BINDER_STREAM_REF(gbs, "recv_trailing_metadata");
+    gbt->transport_stream_receiver->RegisterRecvTrailingMetadata(
+        tx_code, [tx_code, gbs, gbt](
+                     absl::StatusOr<grpc_binder::Metadata> trailing_metadata,
+                     int status) {
+          grpc_core::ExecCtx exec_ctx;
+          if (gbs->is_closed) {
+            GRPC_BINDER_STREAM_UNREF(gbs, "recv_trailing_metadata");
+            return;
+          }
+          gbs->recv_trailing_metadata_args.tx_code = tx_code;
+          gbs->recv_trailing_metadata_args.trailing_metadata =
+              std::move(trailing_metadata);
+          gbs->recv_trailing_metadata_args.status = status;
+          gbt->combiner->Run(
+              GRPC_CLOSURE_INIT(&gbs->recv_trailing_metadata_closure,
+                                recv_trailing_metadata_locked,
+                                &gbs->recv_trailing_metadata_args, nullptr),
+              GRPC_ERROR_NONE);
+        });
+  }
+  // Only send transaction when there's a send op presented.
+  absl::Status status = absl::OkStatus();
+  if (op->send_initial_metadata || op->send_message ||
+      op->send_trailing_metadata) {
+    // TODO(waynetu): RpcCall() is doing a lot of work (including waiting for
+    // acknowledgements from the other side). Consider delaying this operation
+    // with combiner.
+    status = gbt->wire_writer->RpcCall(tx);
+    if (!gbs->is_client && op->send_trailing_metadata) {
+      gbs->trailing_metadata_sent = true;
+      // According to transport explaineer - "Server extra: This op shouldn't
+      // actually be considered complete until the server has also sent trailing
+      // metadata to provide the other side with final status"
+      //
+      // Because we've done sending trailing metadata here, we can safely
+      // complete the recv_trailing_metadata callback here.
+      if (gbs->need_to_call_trailing_metadata_callback) {
+        grpc_closure* cb = gbs->recv_trailing_metadata_finished;
+        gbs->recv_trailing_metadata_finished = nullptr;
+        grpc_core::ExecCtx::Run(DEBUG_LOCATION, cb, GRPC_ERROR_NONE);
+        gbs->need_to_call_trailing_metadata_callback = false;
+      }
+    }
+  }
+  // Note that this should only be scheduled when all non-recv ops are
+  // completed
+  if (op->on_complete != nullptr) {
+    grpc_core::ExecCtx::Run(DEBUG_LOCATION, op->on_complete,
+                            absl_status_to_grpc_error(status));
+    gpr_log(GPR_INFO, "on_complete closure schuduled");
+  }
+  GRPC_BINDER_STREAM_UNREF(gbs, "perform_stream_op");
+}
+
+static void perform_stream_op(grpc_transport* gt, grpc_stream* gs,
+                              grpc_transport_stream_op_batch* op) {
+  GPR_TIMER_SCOPE("perform_stream_op", 0);
+  grpc_binder_transport* gbt = reinterpret_cast<grpc_binder_transport*>(gt);
+  grpc_binder_stream* gbs = reinterpret_cast<grpc_binder_stream*>(gs);
+  gpr_log(GPR_INFO, "%s = %p %p %p is_client = %d", __func__, gt, gs, op,
+          gbs->is_client);
+  GRPC_BINDER_STREAM_REF(gbs, "perform_stream_op");
+  op->handler_private.extra_arg = gbs;
+  gbt->combiner->Run(GRPC_CLOSURE_INIT(&op->handler_private.closure,
+                                       perform_stream_op_locked, op, nullptr),
+                     GRPC_ERROR_NONE);
+}
+
+static void close_transport_locked(grpc_binder_transport* gbt) {
+  gbt->state_tracker.SetState(GRPC_CHANNEL_SHUTDOWN, absl::OkStatus(),
+                              "transport closed due to disconnection/goaway");
+  while (!gbt->registered_stream.empty()) {
+    cancel_stream_locked(
+        gbt, gbt->registered_stream.begin()->second,
+        grpc_error_set_int(
+            GRPC_ERROR_CREATE_FROM_STATIC_STRING("transport closed"),
+            GRPC_ERROR_INT_GRPC_STATUS, GRPC_STATUS_UNAVAILABLE));
+  }
+}
+
+static void perform_transport_op_locked(void* transport_op,
+                                        grpc_error_handle /*error*/) {
+  grpc_transport_op* op = static_cast<grpc_transport_op*>(transport_op);
+  grpc_binder_transport* gbt =
+      static_cast<grpc_binder_transport*>(op->handler_private.extra_arg);
+  // TODO(waynetu): Should we lock here to avoid data race?
+  if (op->start_connectivity_watch != nullptr) {
+    gbt->state_tracker.AddWatcher(op->start_connectivity_watch_state,
+                                  std::move(op->start_connectivity_watch));
+  }
+  if (op->stop_connectivity_watch != nullptr) {
+    gbt->state_tracker.RemoveWatcher(op->stop_connectivity_watch);
+  }
+  if (op->set_accept_stream) {
+    gbt->accept_stream_fn = op->set_accept_stream_fn;
+    gbt->accept_stream_user_data = op->set_accept_stream_user_data;
+  }
+  if (op->on_consumed) {
+    grpc_core::ExecCtx::Run(DEBUG_LOCATION, op->on_consumed, GRPC_ERROR_NONE);
+  }
+  bool do_close = false;
+  if (op->disconnect_with_error != GRPC_ERROR_NONE) {
+    do_close = true;
+    GRPC_ERROR_UNREF(op->disconnect_with_error);
+  }
+  if (op->goaway_error != GRPC_ERROR_NONE) {
+    do_close = true;
+    GRPC_ERROR_UNREF(op->goaway_error);
+  }
+  if (do_close) {
+    close_transport_locked(gbt);
+  }
+  GRPC_BINDER_UNREF_TRANSPORT(gbt, "perform_transport_op");
+}
+
+static void perform_transport_op(grpc_transport* gt, grpc_transport_op* op) {
+  gpr_log(GPR_INFO, __func__);
+  grpc_binder_transport* gbt = reinterpret_cast<grpc_binder_transport*>(gt);
+  op->handler_private.extra_arg = gbt;
+  GRPC_BINDER_REF_TRANSPORT(gbt, "perform_transport_op");
+  gbt->combiner->Run(
+      GRPC_CLOSURE_INIT(&op->handler_private.closure,
+                        perform_transport_op_locked, op, nullptr),
+      GRPC_ERROR_NONE);
+}
+
+static void destroy_stream_locked(void* sp, grpc_error_handle /*error*/) {
+  grpc_binder_stream* gbs = static_cast<grpc_binder_stream*>(sp);
+  grpc_binder_transport* gbt = gbs->t;
+  cancel_stream_locked(
+      gbt, gbs,
+      grpc_error_set_int(GRPC_ERROR_CREATE_FROM_STATIC_STRING("destroy stream"),
+                         GRPC_ERROR_INT_GRPC_STATUS, GRPC_STATUS_UNAVAILABLE));
+  gbs->~grpc_binder_stream();
+}
+
+static void destroy_stream(grpc_transport* /*gt*/, grpc_stream* gs,
+                           grpc_closure* then_schedule_closure) {
+  gpr_log(GPR_INFO, __func__);
+  grpc_binder_stream* gbs = reinterpret_cast<grpc_binder_stream*>(gs);
+  gbs->destroy_stream_then_closure = then_schedule_closure;
+  gbs->t->combiner->Run(GRPC_CLOSURE_INIT(&gbs->destroy_stream,
+                                          destroy_stream_locked, gbs, nullptr),
+                        GRPC_ERROR_NONE);
+}
+
+static void destroy_transport_locked(void* gt, grpc_error_handle /*error*/) {
+  grpc_binder_transport* gbt = static_cast<grpc_binder_transport*>(gt);
+  close_transport_locked(gbt);
+  // Release the references held by the transport.
+  gbt->wire_reader = nullptr;
+  gbt->transport_stream_receiver = nullptr;
+  gbt->wire_writer = nullptr;
+  GRPC_BINDER_UNREF_TRANSPORT(gbt, "transport destroyed");
+}
+
+static void destroy_transport(grpc_transport* gt) {
+  gpr_log(GPR_INFO, __func__);
+  grpc_binder_transport* gbt = reinterpret_cast<grpc_binder_transport*>(gt);
+  gbt->combiner->Run(
+      GRPC_CLOSURE_CREATE(destroy_transport_locked, gbt, nullptr),
+      GRPC_ERROR_NONE);
+}
+
+static grpc_endpoint* get_endpoint(grpc_transport*) {
+  gpr_log(GPR_INFO, __func__);
+  return nullptr;
+}
+
+// See grpc_transport_vtable declaration for meaning of each field
+static const grpc_transport_vtable vtable = {sizeof(grpc_binder_stream),
+                                             "binder",
+                                             init_stream,
+                                             set_pollset,
+                                             set_pollset_set,
+                                             perform_stream_op,
+                                             perform_transport_op,
+                                             destroy_stream,
+                                             destroy_transport,
+                                             get_endpoint};
+
+static const grpc_transport_vtable* get_vtable() { return &vtable; }
+
+static void accept_stream_locked(void* gt, grpc_error_handle /*error*/) {
+  grpc_binder_transport* gbt = static_cast<grpc_binder_transport*>(gt);
+  if (gbt->accept_stream_fn) {
+    // must pass in a non-null value.
+    (*gbt->accept_stream_fn)(gbt->accept_stream_user_data, &gbt->base, gbt);
+  }
+}
+
+grpc_binder_transport::grpc_binder_transport(
+    std::unique_ptr<grpc_binder::Binder> binder, bool is_client)
+    : is_client(is_client),
+      combiner(grpc_combiner_create()),
+      state_tracker(is_client ? "binder_transport_client"
+                              : "binder_transport_server"),
+      refs(1, nullptr) {
+  gpr_log(GPR_INFO, __func__);
+  base.vtable = get_vtable();
+  GRPC_CLOSURE_INIT(&accept_stream_closure, accept_stream_locked, this,
+                    nullptr);
+  transport_stream_receiver =
+      std::make_shared<grpc_binder::TransportStreamReceiverImpl>(
+          is_client, /*accept_stream_callback=*/[this] {
+            grpc_core::ExecCtx exec_ctx;
+            combiner->Run(&accept_stream_closure, GRPC_ERROR_NONE);
+          });
+  // WireReader holds a ref to grpc_binder_transport.
+  GRPC_BINDER_REF_TRANSPORT(this, "wire reader");
+  wire_reader = grpc_core::MakeOrphanable<grpc_binder::WireReaderImpl>(
+      transport_stream_receiver, is_client,
+      /*on_destruct_callback=*/[this] {
+        // Unref transport when destructed.
+        GRPC_BINDER_UNREF_TRANSPORT(this, "wire reader");
+      });
+  wire_writer = wire_reader->SetupTransport(std::move(binder));
+}
+
+grpc_binder_transport::~grpc_binder_transport() {
+  GRPC_COMBINER_UNREF(combiner, "binder_transport");
+}
+
+grpc_transport* grpc_create_binder_transport_client(
+    std::unique_ptr<grpc_binder::Binder> endpoint_binder) {
+  gpr_log(GPR_INFO, __func__);
+
+  grpc_binder_transport* t =
+      new grpc_binder_transport(std::move(endpoint_binder), /*is_client=*/true);
+
+  return &t->base;
+}
+
+grpc_transport* grpc_create_binder_transport_server(
+    std::unique_ptr<grpc_binder::Binder> client_binder) {
+  gpr_log(GPR_INFO, __func__);
+
+  grpc_binder_transport* t =
+      new grpc_binder_transport(std::move(client_binder), /*is_client=*/false);
+
+  return &t->base;
+}
diff --git a/src/core/ext/transport/binder/transport/binder_transport.h b/src/core/ext/transport/binder/transport/binder_transport.h
new file mode 100644 (file)
index 0000000..d7e141b
--- /dev/null
@@ -0,0 +1,88 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#ifndef GRPC_CORE_EXT_TRANSPORT_BINDER_TRANSPORT_BINDER_TRANSPORT_H
+#define GRPC_CORE_EXT_TRANSPORT_BINDER_TRANSPORT_BINDER_TRANSPORT_H
+
+#include <grpc/impl/codegen/port_platform.h>
+
+#include <memory>
+#include <string>
+#include <utility>
+#include <vector>
+
+#include "absl/container/flat_hash_map.h"
+
+#include <grpc/support/log.h>
+
+#include "src/core/ext/transport/binder/utils/transport_stream_receiver.h"
+#include "src/core/ext/transport/binder/wire_format/binder.h"
+#include "src/core/ext/transport/binder/wire_format/wire_reader.h"
+#include "src/core/ext/transport/binder/wire_format/wire_writer.h"
+#include "src/core/lib/iomgr/combiner.h"
+#include "src/core/lib/transport/transport.h"
+#include "src/core/lib/transport/transport_impl.h"
+
+struct grpc_binder_stream;
+
+// TODO(mingcl): Consider putting the struct in a namespace (Eventually this
+// depends on what style we want to follow)
+// TODO(mingcl): Decide casing for this class name. Should we use C-style class
+// name here or just go with C++ style?
+struct grpc_binder_transport {
+  explicit grpc_binder_transport(std::unique_ptr<grpc_binder::Binder> binder,
+                                 bool is_client);
+  ~grpc_binder_transport();
+
+  int NewStreamTxCode() {
+    // TODO(mingcl): Wrap around when all tx codes are used. "If we do detect a
+    // collision however, we will fail the new call with UNAVAILABLE, and shut
+    // down the transport gracefully."
+    GPR_ASSERT(next_free_tx_code <= LAST_CALL_TRANSACTION);
+    return next_free_tx_code++;
+  }
+
+  grpc_transport base; /* must be first */
+
+  std::shared_ptr<grpc_binder::TransportStreamReceiver>
+      transport_stream_receiver;
+  grpc_core::OrphanablePtr<grpc_binder::WireReader> wire_reader;
+  std::shared_ptr<grpc_binder::WireWriter> wire_writer;
+
+  bool is_client;
+  // A set of currently registered streams (the key is the stream ID).
+  absl::flat_hash_map<int, grpc_binder_stream*> registered_stream;
+  grpc_core::Combiner* combiner;
+
+  grpc_closure accept_stream_closure;
+
+  // The callback and the data for the callback when the stream is connected
+  // between client and server.
+  void (*accept_stream_fn)(void* user_data, grpc_transport* transport,
+                           const void* server_data) = nullptr;
+  void* accept_stream_user_data = nullptr;
+
+  grpc_core::ConnectivityStateTracker state_tracker;
+  grpc_core::RefCount refs;
+
+ private:
+  int next_free_tx_code = grpc_binder::kFirstCallId;
+};
+
+grpc_transport* grpc_create_binder_transport_client(
+    std::unique_ptr<grpc_binder::Binder> endpoint_binder);
+grpc_transport* grpc_create_binder_transport_server(
+    std::unique_ptr<grpc_binder::Binder> client_binder);
+
+#endif  // GRPC_CORE_EXT_TRANSPORT_BINDER_TRANSPORT_BINDER_TRANSPORT_H
index b76dd66..50e86a9 100644 (file)
@@ -18,6 +18,9 @@ licenses(["notice"])
 
 package(
     default_visibility = ["//visibility:public"],
+    features = [
+        "layering_check",
+    ],
 )
 
 grpc_cc_library(
@@ -30,13 +33,14 @@ grpc_cc_library(
         "transport_stream_receiver_impl.h",
     ],
     external_deps = [
+        "absl/status:statusor",
         "absl/strings",
         "absl/synchronization",
-        "absl/types:optional",
     ],
     deps = [
         "//:gpr",
         "//:gpr_base",
+        "//:gpr_platform",
         "//src/core/ext/transport/binder/wire_format:transaction",
     ],
 )
index b2917fc..1b306b1 100644 (file)
@@ -21,6 +21,8 @@
 #include <string>
 #include <vector>
 
+#include "absl/status/statusor.h"
+
 #include "src/core/ext/transport/binder/wire_format/transaction.h"
 
 namespace grpc_binder {
@@ -31,29 +33,37 @@ class TransportStreamReceiver {
  public:
   virtual ~TransportStreamReceiver() = default;
 
+  using InitialMetadataCallbackType =
+      std::function<void(absl::StatusOr<Metadata>)>;
+  using MessageDataCallbackType =
+      std::function<void(absl::StatusOr<std::string>)>;
+  using TrailingMetadataCallbackType =
+      std::function<void(absl::StatusOr<Metadata>, int)>;
+
   // Only handles single time invocation. Callback object will be deleted.
   // The callback should be valid until invocation or unregister.
-  virtual void RegisterRecvInitialMetadata(
-      StreamIdentifier id, std::function<void(const Metadata&)> cb) = 0;
-  // TODO(mingcl): Use string_view
-  virtual void RegisterRecvMessage(
-      StreamIdentifier id, std::function<void(const std::string&)> cb) = 0;
+  virtual void RegisterRecvInitialMetadata(StreamIdentifier id,
+                                           InitialMetadataCallbackType cb) = 0;
+  virtual void RegisterRecvMessage(StreamIdentifier id,
+                                   MessageDataCallbackType cb) = 0;
   virtual void RegisterRecvTrailingMetadata(
-      StreamIdentifier id, std::function<void(const Metadata&, int)> cb) = 0;
+      StreamIdentifier id, TrailingMetadataCallbackType cb) = 0;
 
-  // TODO(mingcl): Provide a way to unregister callback?
-
-  // TODO(mingcl): Figure out how to handle the case where there is no callback
-  // registered for the stream. For now, I don't see this case happening in
-  // unary calls. So we would probably just crash the program for now.
-  // For streaming calls it does happen, for now we simply queue them.
-  virtual void NotifyRecvInitialMetadata(StreamIdentifier id,
-                                         const Metadata& initial_metadata) = 0;
+  // For the following functions, the second arguments are the transaction
+  // result received from the lower level. If it is None, that means there's
+  // something wrong when receiving the corresponding transaction. In such case,
+  // we should cancel the gRPC callback as well.
+  virtual void NotifyRecvInitialMetadata(
+      StreamIdentifier id, absl::StatusOr<Metadata> initial_metadata) = 0;
   virtual void NotifyRecvMessage(StreamIdentifier id,
-                                 const std::string& message) = 0;
-  virtual void NotifyRecvTrailingMetadata(StreamIdentifier id,
-                                          const Metadata& trailing_metadata,
-                                          int status) = 0;
+                                 absl::StatusOr<std::string> message) = 0;
+  virtual void NotifyRecvTrailingMetadata(
+      StreamIdentifier id, absl::StatusOr<Metadata> trailing_metadata,
+      int status) = 0;
+  // Remove all entries associated with stream number `id`.
+  virtual void CancelStream(StreamIdentifier id) = 0;
+
+  static const absl::string_view kGrpcBinderTransportCancelledGracefully;
 };
 
 }  // namespace grpc_binder
index f58520b..1add6e7 100644 (file)
 
 #include "src/core/ext/transport/binder/utils/transport_stream_receiver_impl.h"
 
-#include <grpc/support/log.h>
-
 #include <functional>
 #include <string>
 #include <utility>
 
+#include <grpc/support/log.h>
+
 namespace grpc_binder {
+
+const absl::string_view
+    TransportStreamReceiver::kGrpcBinderTransportCancelledGracefully =
+        "grpc-binder-transport: cancelled gracefully";
+
 void TransportStreamReceiverImpl::RegisterRecvInitialMetadata(
-    StreamIdentifier id, std::function<void(const Metadata&)> cb) {
-  // TODO(mingcl): Don't lock the whole function
-  grpc_core::MutexLock l(&m_);
-  gpr_log(GPR_ERROR, "%s id = %d", __func__, id);
-  GPR_ASSERT(initial_metadata_cbs_.count(id) == 0);
-  auto iter = pending_initial_metadata_.find(id);
-  if (iter == pending_initial_metadata_.end()) {
-    initial_metadata_cbs_[id] = std::move(cb);
-  } else {
-    cb(iter->second.front());
-    iter->second.pop();
-    if (iter->second.empty()) {
-      pending_initial_metadata_.erase(iter);
+    StreamIdentifier id, InitialMetadataCallbackType cb) {
+  gpr_log(GPR_INFO, "%s id = %d is_client = %d", __func__, id, is_client_);
+  absl::StatusOr<Metadata> initial_metadata{};
+  {
+    grpc_core::MutexLock l(&m_);
+    GPR_ASSERT(initial_metadata_cbs_.count(id) == 0);
+    auto iter = pending_initial_metadata_.find(id);
+    if (iter == pending_initial_metadata_.end()) {
+      if (trailing_metadata_recvd_.count(id)) {
+        cb(absl::CancelledError(""));
+      } else {
+        initial_metadata_cbs_[id] = std::move(cb);
+      }
+      cb = nullptr;
+    } else {
+      initial_metadata = std::move(iter->second.front());
+      iter->second.pop();
+      if (iter->second.empty()) {
+        pending_initial_metadata_.erase(iter);
+      }
     }
   }
+  if (cb != nullptr) {
+    cb(std::move(initial_metadata));
+  }
 }
 
 void TransportStreamReceiverImpl::RegisterRecvMessage(
-    StreamIdentifier id, std::function<void(const std::string&)> cb) {
-  // TODO(mingcl): Don't lock the whole function
-  grpc_core::MutexLock l(&m_);
-  gpr_log(GPR_ERROR, "%s id = %d", __func__, id);
-  GPR_ASSERT(message_cbs_.count(id) == 0);
-  auto iter = pending_message_.find(id);
-  if (iter == pending_message_.end()) {
-    message_cbs_[id] = std::move(cb);
-  } else {
-    cb(iter->second.front());
-    iter->second.pop();
-    if (iter->second.empty()) {
-      pending_message_.erase(iter);
+    StreamIdentifier id, MessageDataCallbackType cb) {
+  gpr_log(GPR_INFO, "%s id = %d is_client = %d", __func__, id, is_client_);
+  absl::StatusOr<std::string> message{};
+  {
+    grpc_core::MutexLock l(&m_);
+    GPR_ASSERT(message_cbs_.count(id) == 0);
+    auto iter = pending_message_.find(id);
+    if (iter == pending_message_.end()) {
+      // If we'd already received trailing-metadata and there's no pending
+      // messages, cancel the callback.
+      if (trailing_metadata_recvd_.count(id)) {
+        cb(absl::CancelledError(
+            TransportStreamReceiver::kGrpcBinderTransportCancelledGracefully));
+      } else {
+        message_cbs_[id] = std::move(cb);
+      }
+      cb = nullptr;
+    } else {
+      // We'll still keep all pending messages received before the trailing
+      // metadata since they're issued before the end of stream, as promised by
+      // WireReader which keeps transactions commit in-order.
+      message = std::move(iter->second.front());
+      iter->second.pop();
+      if (iter->second.empty()) {
+        pending_message_.erase(iter);
+      }
     }
   }
+  if (cb != nullptr) {
+    cb(std::move(message));
+  }
 }
 
 void TransportStreamReceiverImpl::RegisterRecvTrailingMetadata(
-    StreamIdentifier id, std::function<void(const Metadata&, int)> cb) {
-  // TODO(mingcl): Don't lock the whole function
-  grpc_core::MutexLock l(&m_);
-  gpr_log(GPR_ERROR, "%s id = %d", __func__, id);
-  GPR_ASSERT(trailing_metadata_cbs_.count(id) == 0);
-  auto iter = pending_trailing_metadata_.find(id);
-  if (iter == pending_trailing_metadata_.end()) {
-    trailing_metadata_cbs_[id] = std::move(cb);
-  } else {
-    {
-      const auto& p = iter->second.front();
-      cb(p.first, p.second);
-    }
-    iter->second.pop();
-    if (iter->second.empty()) {
-      pending_trailing_metadata_.erase(iter);
+    StreamIdentifier id, TrailingMetadataCallbackType cb) {
+  gpr_log(GPR_INFO, "%s id = %d is_client = %d", __func__, id, is_client_);
+  std::pair<absl::StatusOr<Metadata>, int> trailing_metadata{};
+  {
+    grpc_core::MutexLock l(&m_);
+    GPR_ASSERT(trailing_metadata_cbs_.count(id) == 0);
+    auto iter = pending_trailing_metadata_.find(id);
+    if (iter == pending_trailing_metadata_.end()) {
+      trailing_metadata_cbs_[id] = std::move(cb);
+      cb = nullptr;
+    } else {
+      trailing_metadata = std::move(iter->second.front());
+      iter->second.pop();
+      if (iter->second.empty()) {
+        pending_trailing_metadata_.erase(iter);
+      }
     }
   }
+  if (cb != nullptr) {
+    cb(std::move(trailing_metadata.first), trailing_metadata.second);
+  }
 }
 
 void TransportStreamReceiverImpl::NotifyRecvInitialMetadata(
-    StreamIdentifier id, const Metadata& initial_metadata) {
-  gpr_log(GPR_ERROR, "%s id = %d", __func__, id);
-  std::function<void(const Metadata&)> cb;
+    StreamIdentifier id, absl::StatusOr<Metadata> initial_metadata) {
+  gpr_log(GPR_INFO, "%s id = %d is_client = %d", __func__, id, is_client_);
+  if (!is_client_ && accept_stream_callback_) {
+    accept_stream_callback_();
+  }
+  InitialMetadataCallbackType cb;
   {
     grpc_core::MutexLock l(&m_);
     auto iter = initial_metadata_cbs_.find(id);
@@ -91,18 +128,17 @@ void TransportStreamReceiverImpl::NotifyRecvInitialMetadata(
       cb = iter->second;
       initial_metadata_cbs_.erase(iter);
     } else {
-      pending_initial_metadata_[id].push(initial_metadata);
+      pending_initial_metadata_[id].push(std::move(initial_metadata));
+      return;
     }
   }
-  if (cb != nullptr) {
-    cb(initial_metadata);
-  }
+  cb(std::move(initial_metadata));
 }
 
 void TransportStreamReceiverImpl::NotifyRecvMessage(
-    StreamIdentifier id, const std::string& message) {
-  gpr_log(GPR_ERROR, "%s id = %d", __func__, id);
-  std::function<void(const std::string&)> cb;
+    StreamIdentifier id, absl::StatusOr<std::string> message) {
+  gpr_log(GPR_INFO, "%s id = %d is_client = %d", __func__, id, is_client_);
+  MessageDataCallbackType cb;
   {
     grpc_core::MutexLock l(&m_);
     auto iter = message_cbs_.find(id);
@@ -110,18 +146,23 @@ void TransportStreamReceiverImpl::NotifyRecvMessage(
       cb = iter->second;
       message_cbs_.erase(iter);
     } else {
-      pending_message_[id].push(message);
+      pending_message_[id].push(std::move(message));
+      return;
     }
   }
-  if (cb != nullptr) {
-    cb(message);
-  }
+  cb(std::move(message));
 }
 
 void TransportStreamReceiverImpl::NotifyRecvTrailingMetadata(
-    StreamIdentifier id, const Metadata& trailing_metadata, int status) {
-  gpr_log(GPR_ERROR, "%s id = %d", __func__, id);
-  std::function<void(const Metadata&, int)> cb;
+    StreamIdentifier id, absl::StatusOr<Metadata> trailing_metadata,
+    int status) {
+  // Trailing metadata mark the end of the stream. Since TransportStreamReceiver
+  // assumes in-order commitments of transactions and that trailing metadata is
+  // parsed after message data, we can safely cancel all upcoming callbacks of
+  // recv_message.
+  gpr_log(GPR_INFO, "%s id = %d is_client = %d", __func__, id, is_client_);
+  OnRecvTrailingMetadata(id);
+  TrailingMetadataCallbackType cb;
   {
     grpc_core::MutexLock l(&m_);
     auto iter = trailing_metadata_cbs_.find(id);
@@ -129,11 +170,83 @@ void TransportStreamReceiverImpl::NotifyRecvTrailingMetadata(
       cb = iter->second;
       trailing_metadata_cbs_.erase(iter);
     } else {
-      pending_trailing_metadata_[id].emplace(trailing_metadata, status);
+      pending_trailing_metadata_[id].emplace(std::move(trailing_metadata),
+                                             status);
+      return;
     }
   }
-  if (cb != nullptr) {
-    cb(trailing_metadata, status);
+  cb(std::move(trailing_metadata), status);
+}
+
+void TransportStreamReceiverImpl::CancelInitialMetadataCallback(
+    StreamIdentifier id, absl::Status error) {
+  InitialMetadataCallbackType callback = nullptr;
+  {
+    grpc_core::MutexLock l(&m_);
+    auto iter = initial_metadata_cbs_.find(id);
+    if (iter != initial_metadata_cbs_.end()) {
+      callback = std::move(iter->second);
+      initial_metadata_cbs_.erase(iter);
+    }
+  }
+  if (callback != nullptr) {
+    std::move(callback)(error);
+  }
+}
+
+void TransportStreamReceiverImpl::CancelMessageCallback(StreamIdentifier id,
+                                                        absl::Status error) {
+  MessageDataCallbackType callback = nullptr;
+  {
+    grpc_core::MutexLock l(&m_);
+    auto iter = message_cbs_.find(id);
+    if (iter != message_cbs_.end()) {
+      callback = std::move(iter->second);
+      message_cbs_.erase(iter);
+    }
   }
+  if (callback != nullptr) {
+    std::move(callback)(error);
+  }
+}
+
+void TransportStreamReceiverImpl::CancelTrailingMetadataCallback(
+    StreamIdentifier id, absl::Status error) {
+  TrailingMetadataCallbackType callback = nullptr;
+  {
+    grpc_core::MutexLock l(&m_);
+    auto iter = trailing_metadata_cbs_.find(id);
+    if (iter != trailing_metadata_cbs_.end()) {
+      callback = std::move(iter->second);
+      trailing_metadata_cbs_.erase(iter);
+    }
+  }
+  if (callback != nullptr) {
+    std::move(callback)(error, 0);
+  }
+}
+
+void TransportStreamReceiverImpl::OnRecvTrailingMetadata(StreamIdentifier id) {
+  gpr_log(GPR_INFO, "%s id = %d is_client = %d", __func__, id, is_client_);
+  m_.Lock();
+  trailing_metadata_recvd_.insert(id);
+  m_.Unlock();
+  CancelInitialMetadataCallback(id, absl::CancelledError(""));
+  CancelMessageCallback(
+      id,
+      absl::CancelledError(
+          TransportStreamReceiver::kGrpcBinderTransportCancelledGracefully));
+}
+
+void TransportStreamReceiverImpl::CancelStream(StreamIdentifier id) {
+  gpr_log(GPR_INFO, "%s id = %d is_client = %d", __func__, id, is_client_);
+  CancelInitialMetadataCallback(id, absl::CancelledError("Stream cancelled"));
+  CancelMessageCallback(id, absl::CancelledError("Stream cancelled"));
+  CancelTrailingMetadataCallback(id, absl::CancelledError("Stream cancelled"));
+  grpc_core::MutexLock l(&m_);
+  trailing_metadata_recvd_.erase(id);
+  pending_initial_metadata_.erase(id);
+  pending_message_.erase(id);
+  pending_trailing_metadata_.erase(id);
 }
 }  // namespace grpc_binder
index 4af94fd..2cf0355 100644 (file)
 #include <functional>
 #include <map>
 #include <queue>
+#include <set>
 #include <string>
 #include <vector>
 
-#include "absl/types/optional.h"
 #include "src/core/ext/transport/binder/utils/transport_stream_receiver.h"
 #include "src/core/lib/gprpp/sync.h"
 
@@ -32,27 +32,42 @@ namespace grpc_binder {
 // Routes the data received from transport to corresponding streams
 class TransportStreamReceiverImpl : public TransportStreamReceiver {
  public:
-  void RegisterRecvInitialMetadata(
-      StreamIdentifier id, std::function<void(const Metadata&)> cb) override;
+  explicit TransportStreamReceiverImpl(
+      bool is_client, std::function<void()> accept_stream_callback = nullptr)
+      : is_client_(is_client),
+        accept_stream_callback_(accept_stream_callback) {}
+  void RegisterRecvInitialMetadata(StreamIdentifier id,
+                                   InitialMetadataCallbackType cb) override;
   void RegisterRecvMessage(StreamIdentifier id,
-                           std::function<void(const std::string&)> cb) override;
-  void RegisterRecvTrailingMetadata(
-      StreamIdentifier id,
-      std::function<void(const Metadata&, int)> cb) override;
-  void NotifyRecvInitialMetadata(StreamIdentifier id,
-                                 const Metadata& initial_metadata) override;
+                           MessageDataCallbackType cb) override;
+  void RegisterRecvTrailingMetadata(StreamIdentifier id,
+                                    TrailingMetadataCallbackType cb) override;
+  void NotifyRecvInitialMetadata(
+      StreamIdentifier id, absl::StatusOr<Metadata> initial_metadata) override;
   void NotifyRecvMessage(StreamIdentifier id,
-                         const std::string& message) override;
+                         absl::StatusOr<std::string> message) override;
   void NotifyRecvTrailingMetadata(StreamIdentifier id,
-                                  const Metadata& trailing_metadata,
+                                  absl::StatusOr<Metadata> trailing_metadata,
                                   int status) override;
 
+  void CancelStream(StreamIdentifier id) override;
+
  private:
-  std::map<StreamIdentifier, std::function<void(const Metadata&)>>
-      initial_metadata_cbs_;
-  std::map<StreamIdentifier, std::function<void(const std::string&)>>
-      message_cbs_;
-  std::map<StreamIdentifier, std::function<void(const Metadata&, int)>>
+  // Trailing metadata marks the end of one-side of the stream. Thus, after
+  // receiving trailing metadata from the other-end, we know that there will
+  // never be in-coming message data anymore, and all recv_message callbacks
+  // (as well as recv_initial_metadata callback, if there's any) registered will
+  // never be satisfied. This function cancels all such callbacks gracefully
+  // (with GRPC_ERROR_NONE) to avoid being blocked waiting for them.
+  void OnRecvTrailingMetadata(StreamIdentifier id);
+
+  void CancelInitialMetadataCallback(StreamIdentifier id, absl::Status error);
+  void CancelMessageCallback(StreamIdentifier id, absl::Status error);
+  void CancelTrailingMetadataCallback(StreamIdentifier id, absl::Status error);
+
+  std::map<StreamIdentifier, InitialMetadataCallbackType> initial_metadata_cbs_;
+  std::map<StreamIdentifier, MessageDataCallbackType> message_cbs_;
+  std::map<StreamIdentifier, TrailingMetadataCallbackType>
       trailing_metadata_cbs_;
   // TODO(waynetu): Better thread safety design. For example, use separate
   // mutexes for different type of messages.
@@ -69,12 +84,28 @@ class TransportStreamReceiverImpl : public TransportStreamReceiver {
   // messages will be re-ordered by it. In such case, the queueing approach will
   // work fine. Refer to the TODO in WireWriterImpl::ProcessTransaction() at
   // wire_reader_impl.cc for detecting and resolving out-of-order transactions.
-  std::map<StreamIdentifier, std::queue<Metadata>> pending_initial_metadata_
-      ABSL_GUARDED_BY(m_);
-  std::map<StreamIdentifier, std::queue<std::string>> pending_message_
-      ABSL_GUARDED_BY(m_);
-  std::map<StreamIdentifier, std::queue<std::pair<Metadata, int>>>
+  //
+  // TODO(waynetu): Use absl::flat_hash_map.
+  std::map<StreamIdentifier, std::queue<absl::StatusOr<Metadata>>>
+      pending_initial_metadata_ ABSL_GUARDED_BY(m_);
+  std::map<StreamIdentifier, std::queue<absl::StatusOr<std::string>>>
+      pending_message_ ABSL_GUARDED_BY(m_);
+  std::map<StreamIdentifier,
+           std::queue<std::pair<absl::StatusOr<Metadata>, int>>>
       pending_trailing_metadata_ ABSL_GUARDED_BY(m_);
+  // Record whether or not the recv_message callbacks of a given stream is
+  // cancelled. Although we explicitly cancel the registered recv_message() in
+  // CancelRecvMessageCallbacksDueToTrailingMetadata(), there are chances that
+  // the registration comes "after" we receive trailing metadata. Therefore,
+  // when RegisterRecvMessage() gets called, we should check whether
+  // recv_message_cancelled_ contains the corresponding stream ID, and if so,
+  // directly cancel the callback gracefully without pending it.
+  std::set<StreamIdentifier> trailing_metadata_recvd_ ABSL_GUARDED_BY(m_);
+
+  bool is_client_;
+  // Called when receiving initial metadata to inform the server about a new
+  // stream.
+  std::function<void()> accept_stream_callback_;
 };
 }  // namespace grpc_binder
 
index 4e10134..dd57094 100644 (file)
@@ -18,6 +18,9 @@ licenses(["notice"])
 
 package(
     default_visibility = ["//visibility:public"],
+    features = [
+        "layering_check",
+    ],
 )
 
 grpc_cc_library(
@@ -34,6 +37,7 @@ grpc_cc_library(
     ],
     deps = [
         "//:gpr",
+        "//:gpr_platform",
     ],
 )
 
@@ -53,6 +57,8 @@ grpc_cc_library(
     ],
     deps = [
         "//:gpr",
+        "//:gpr_platform",
+        "//:orphanable",
     ],
 )
 
@@ -70,6 +76,8 @@ grpc_cc_library(
     ],
     deps = [
         ":binder",
+        ":wire_reader",
+        "//:gpr_platform",
     ],
 )
 
@@ -78,14 +86,15 @@ grpc_cc_library(
     srcs = ["wire_writer.cc"],
     hdrs = ["wire_writer.h"],
     external_deps = [
+        "absl/container:flat_hash_map",
         "absl/strings",
     ],
-    visibility = ["//visibility:public"],
     deps = [
         ":binder",
         ":transaction",
         "//:gpr",
         "//:gpr_base",
+        "//:gpr_platform",
     ],
 )
 
@@ -106,6 +115,8 @@ grpc_cc_library(
         ":binder",
         ":wire_writer",
         "//:gpr",
+        "//:gpr_platform",
+        "//:orphanable",
         "//src/core/ext/transport/binder/utils:transport_stream_receiver",
     ],
 )
index 6b0b68b..4a05fdd 100644 (file)
@@ -24,7 +24,9 @@
 
 #include "absl/status/status.h"
 #include "absl/strings/string_view.h"
+
 #include "src/core/ext/transport/binder/wire_format/binder_constants.h"
+#include "src/core/lib/gprpp/orphanable.h"
 
 namespace grpc_binder {
 
@@ -43,8 +45,10 @@ class WritableParcel {
  public:
   virtual ~WritableParcel() = default;
   virtual int32_t GetDataPosition() const = 0;
+  virtual int32_t GetDataSize() const = 0;
   virtual absl::Status SetDataPosition(int32_t pos) = 0;
   virtual absl::Status WriteInt32(int32_t data) = 0;
+  virtual absl::Status WriteInt64(int64_t data) = 0;
   virtual absl::Status WriteBinder(HasRawBinder* binder) = 0;
   virtual absl::Status WriteString(absl::string_view s) = 0;
   virtual absl::Status WriteByteArray(const int8_t* buffer, int32_t length) = 0;
@@ -64,7 +68,9 @@ class WritableParcel {
 class ReadableParcel {
  public:
   virtual ~ReadableParcel() = default;
+  virtual int32_t GetDataSize() const = 0;
   virtual absl::Status ReadInt32(int32_t* data) const = 0;
+  virtual absl::Status ReadInt64(int64_t* data) const = 0;
   virtual absl::Status ReadBinder(std::unique_ptr<Binder>* data) const = 0;
   // TODO(waynetu): Provide better interfaces.
   virtual absl::Status ReadByteArray(std::string* data) const = 0;
@@ -80,6 +86,8 @@ class TransactionReceiver : public HasRawBinder {
   ~TransactionReceiver() override = default;
 };
 
+class WireReader;
+
 class Binder : public HasRawBinder {
  public:
   ~Binder() override = default;
@@ -93,6 +101,7 @@ class Binder : public HasRawBinder {
 
   // TODO(waynetu): Can we decouple the receiver from the binder?
   virtual std::unique_ptr<TransactionReceiver> ConstructTxReceiver(
+      grpc_core::RefCountedPtr<WireReader> wire_reader_ref,
       TransactionReceiver::OnTransactCb transact_cb) const = 0;
 };
 
index 8045a0f..1df139b 100644 (file)
 
 #include <grpc/impl/codegen/port_platform.h>
 
-#include "src/core/ext/transport/binder/wire_format/binder_android.h"
-
-#if defined(ANDROID) || defined(__ANDROID__)
-
-#include <grpc/support/log.h>
+#ifdef GPR_SUPPORT_BINDER_TRANSPORT
 
 #include <map>
 
 #include "absl/memory/memory.h"
 #include "absl/strings/str_cat.h"
+
+#include <grpc/support/log.h>
+
+#include "src/core/ext/transport/binder/wire_format/binder_android.h"
 #include "src/core/lib/gprpp/sync.h"
 
+extern "C" {
+// TODO(mingcl): This function is introduced at API level 32 and is not
+// available in any NDK release yet. So we export it weakly so that we can use
+// it without triggering undefined reference error. Its purpose is to disable
+// header in Parcel to conform to the BinderChannel wire format.
+extern void AIBinder_Class_disableInterfaceTokenHeader(AIBinder_Class* clazz)
+    __attribute__((weak));
+// This is released in API level 31.
+extern int32_t AParcel_getDataSize(const AParcel* parcel) __attribute__((weak));
+}
+
+namespace grpc_binder {
 namespace {
 
-struct AtomicCallback {
-  explicit AtomicCallback(void* callback) : mu{}, callback(callback) {}
-  grpc_core::Mutex mu;
-  void* callback ABSL_GUARDED_BY(mu);
+struct BinderUserData {
+  explicit BinderUserData(grpc_core::RefCountedPtr<WireReader> wire_reader_ref,
+                          TransactionReceiver::OnTransactCb* callback)
+      : wire_reader_ref(wire_reader_ref), callback(callback) {}
+  grpc_core::RefCountedPtr<WireReader> wire_reader_ref;
+  TransactionReceiver::OnTransactCb* callback;
+};
+
+struct OnCreateArgs {
+  grpc_core::RefCountedPtr<WireReader> wire_reader_ref;
+  TransactionReceiver::OnTransactCb* callback;
 };
 
-void* f_onCreate_with_mutex(void* callback) {
-  return new AtomicCallback(callback);
+void* f_onCreate_userdata(void* data) {
+  auto* args = static_cast<OnCreateArgs*>(data);
+  return new BinderUserData(args->wire_reader_ref, args->callback);
+}
+
+void f_onDestroy_delete(void* data) {
+  auto* user_data = static_cast<BinderUserData*>(data);
+  delete user_data;
 }
 
-void* f_onCreate_noop(void* args) { return nullptr; }
-void f_onDestroy_noop(void* userData) {}
+void* f_onCreate_noop(void* /*args*/) { return nullptr; }
+void f_onDestroy_noop(void* /*userData*/) {}
 
 // TODO(mingcl): Consider if thread safety is a requirement here
 binder_status_t f_onTransact(AIBinder* binder, transaction_code_t code,
-                             const AParcel* in, AParcel* out) {
+                             const AParcel* in, AParcel* /*out*/) {
   gpr_log(GPR_INFO, __func__);
   gpr_log(GPR_INFO, "tx code = %u", code);
-  auto* user_data =
-      reinterpret_cast<AtomicCallback*>(AIBinder_getUserData(binder));
-  grpc_core::MutexLock lock(&user_data->mu);
 
-  // TODO(waynetu): What should be returned here?
-  if (!user_data->callback) return STATUS_OK;
-
-  auto* callback =
-      reinterpret_cast<grpc_binder::TransactionReceiver::OnTransactCb*>(
-          user_data->callback);
+  auto* user_data = static_cast<BinderUserData*>(AIBinder_getUserData(binder));
+  TransactionReceiver::OnTransactCb* callback = user_data->callback;
   // Wrap the parcel in a ReadableParcel.
-  std::unique_ptr<grpc_binder::ReadableParcel> output =
-      absl::make_unique<grpc_binder::ReadableParcelAndroid>(in);
+  std::unique_ptr<ReadableParcel> output =
+      absl::make_unique<ReadableParcelAndroid>(in);
   // The lock should be released "after" the callback finishes.
   absl::Status status = (*callback)(code, output.get());
-  return status.ok() ? STATUS_OK : STATUS_UNKNOWN_ERROR;
+  if (status.ok()) {
+    return STATUS_OK;
+  } else {
+    gpr_log(GPR_ERROR, "Callback failed: %s", status.ToString().c_str());
+    return STATUS_UNKNOWN_ERROR;
+  }
 }
 }  // namespace
 
-namespace grpc_binder {
-
 ndk::SpAIBinder FromJavaBinder(JNIEnv* jni_env, jobject binder) {
   return ndk::SpAIBinder(AIBinder_fromJavaBinder(jni_env, binder));
 }
 
-TransactionReceiverAndroid::TransactionReceiverAndroid(OnTransactCb transact_cb)
+TransactionReceiverAndroid::TransactionReceiverAndroid(
+    grpc_core::RefCountedPtr<WireReader> wire_reader_ref,
+    OnTransactCb transact_cb)
     : transact_cb_(transact_cb) {
   // TODO(mingcl): For now interface descriptor is always empty, figure out if
   // we want it to be something more meaningful (we can probably manually change
   // interface descriptor by modifying Java code's reply to
   // os.IBinder.INTERFACE_TRANSACTION)
   AIBinder_Class* aibinder_class = AIBinder_Class_define(
-      /*interfaceDescriptor=*/"", f_onCreate_with_mutex, f_onDestroy_noop,
+      /*interfaceDescriptor=*/"", f_onCreate_userdata, f_onDestroy_delete,
       f_onTransact);
 
+  if (AIBinder_Class_disableInterfaceTokenHeader) {
+    AIBinder_Class_disableInterfaceTokenHeader(aibinder_class);
+  } else {
+    // TODO(mingcl): Make this a fatal error
+    gpr_log(GPR_ERROR,
+            "AIBinder_Class_disableInterfaceTokenHeader remain unresolved. "
+            "This BinderTransport implementation contains header and is not "
+            "compatible with Java's implementation");
+  }
+
   // Pass the on-transact callback to the on-create function of the binder. The
   // on-create function equips the callback with a mutex and gives it to the
   // user data stored in the binder which can be retrieved later.
-  binder_ = AIBinder_new(aibinder_class, &transact_cb_);
+  // Also Ref() (called implicitly by the copy constructor of RefCountedPtr) the
+  // wire reader so that it would not be destructed during the callback
+  // invocation.
+  OnCreateArgs args;
+  args.wire_reader_ref = wire_reader_ref;
+  args.callback = &transact_cb_;
+  binder_ = AIBinder_new(aibinder_class, &args);
   GPR_ASSERT(binder_);
   gpr_log(GPR_INFO, "AIBinder_associateClass = %d",
           static_cast<int>(AIBinder_associateClass(binder_, aibinder_class)));
 }
 
 TransactionReceiverAndroid::~TransactionReceiverAndroid() {
-  auto* user_data =
-      reinterpret_cast<AtomicCallback*>(AIBinder_getUserData(binder_));
-  {
-    grpc_core::MutexLock lock(&user_data->mu);
-    // Set the callback to null so that future calls to on-trasact are awared
-    // that the transaction receiver had been deallocated.
-    user_data->callback = nullptr;
-  }
   // Release the binder.
   AIBinder_decStrong(binder_);
 }
 
 namespace {
 
-binder_status_t f_onTransact_noop(AIBinder* binder, transaction_code_t code,
-                                  const AParcel* in, AParcel* out) {
+binder_status_t f_onTransact_noop(AIBinder* /*binder*/,
+                                  transaction_code_t /*code*/,
+                                  const AParcel* /*in*/, AParcel* /*out*/) {
   return {};
 }
 
@@ -114,6 +146,17 @@ void AssociateWithNoopClass(AIBinder* binder) {
   // Need to associate class before using it
   AIBinder_Class* aibinder_class = AIBinder_Class_define(
       "", f_onCreate_noop, f_onDestroy_noop, f_onTransact_noop);
+
+  if (AIBinder_Class_disableInterfaceTokenHeader) {
+    AIBinder_Class_disableInterfaceTokenHeader(aibinder_class);
+  } else {
+    // TODO(mingcl): Make this a fatal error
+    gpr_log(GPR_ERROR,
+            "AIBinder_Class_disableInterfaceTokenHeader remain unresolved. "
+            "This BinderTransport implementation contains header and is not "
+            "compatible with Java's implementation");
+  }
+
   gpr_log(GPR_INFO, "AIBinder_associateClass = %d",
           static_cast<int>(AIBinder_associateClass(binder, aibinder_class)));
 }
@@ -143,14 +186,25 @@ absl::Status BinderAndroid::Transact(BinderTransportTxCode tx_code) {
 }
 
 std::unique_ptr<TransactionReceiver> BinderAndroid::ConstructTxReceiver(
+    grpc_core::RefCountedPtr<WireReader> wire_reader_ref,
     TransactionReceiver::OnTransactCb transact_cb) const {
-  return absl::make_unique<TransactionReceiverAndroid>(transact_cb);
+  return absl::make_unique<TransactionReceiverAndroid>(wire_reader_ref,
+                                                       transact_cb);
 }
 
 int32_t WritableParcelAndroid::GetDataPosition() const {
   return AParcel_getDataPosition(parcel_);
 }
 
+int32_t WritableParcelAndroid::GetDataSize() const {
+  if (AParcel_getDataSize) {
+    return AParcel_getDataSize(parcel_);
+  } else {
+    gpr_log(GPR_INFO, "[Warning] AParcel_getDataSize is not available");
+    return 0;
+  }
+}
+
 absl::Status WritableParcelAndroid::SetDataPosition(int32_t pos) {
   return AParcel_setDataPosition(parcel_, pos) == STATUS_OK
              ? absl::OkStatus()
@@ -163,6 +217,12 @@ absl::Status WritableParcelAndroid::WriteInt32(int32_t data) {
              : absl::InternalError("AParcel_writeInt32 failed");
 }
 
+absl::Status WritableParcelAndroid::WriteInt64(int64_t data) {
+  return AParcel_writeInt64(parcel_, data) == STATUS_OK
+             ? absl::OkStatus()
+             : absl::InternalError("AParcel_writeInt64 failed");
+}
+
 absl::Status WritableParcelAndroid::WriteBinder(HasRawBinder* binder) {
   return AParcel_writeStrongBinder(
              parcel_, reinterpret_cast<AIBinder*>(binder->GetRawBinder())) ==
@@ -184,12 +244,27 @@ absl::Status WritableParcelAndroid::WriteByteArray(const int8_t* buffer,
              : absl::InternalError("AParcel_writeByteArray failed");
 }
 
+int32_t ReadableParcelAndroid::GetDataSize() const {
+  if (AParcel_getDataSize) {
+    return AParcel_getDataSize(parcel_);
+  } else {
+    gpr_log(GPR_INFO, "[Warning] AParcel_getDataSize is not available");
+    return -1;
+  }
+}
+
 absl::Status ReadableParcelAndroid::ReadInt32(int32_t* data) const {
   return AParcel_readInt32(parcel_, data) == STATUS_OK
              ? absl::OkStatus()
              : absl::InternalError("AParcel_readInt32 failed");
 }
 
+absl::Status ReadableParcelAndroid::ReadInt64(int64_t* data) const {
+  return AParcel_readInt64(parcel_, data) == STATUS_OK
+             ? absl::OkStatus()
+             : absl::InternalError("AParcel_readInt64 failed");
+}
+
 absl::Status ReadableParcelAndroid::ReadBinder(
     std::unique_ptr<Binder>* data) const {
   AIBinder* binder;
@@ -208,7 +283,7 @@ bool byte_array_allocator(void* arrayData, int32_t length, int8_t** outBuffer) {
   tmp.resize(length);
   *reinterpret_cast<std::string*>(arrayData) = tmp;
   *outBuffer = reinterpret_cast<int8_t*>(
-      reinterpret_cast<std::string*>(arrayData)->data());
+      &(*reinterpret_cast<std::string*>(arrayData))[0]);
   return true;
 }
 
@@ -237,4 +312,4 @@ absl::Status ReadableParcelAndroid::ReadString(char data[111]) const {
 
 }  // namespace grpc_binder
 
-#endif  // defined(ANDROID) || defined(__ANDROID__)
+#endif  // GPR_SUPPORT_BINDER_TRANSPORT
index 7a87cab..46fcd53 100644 (file)
 #ifndef GRPC_CORE_EXT_TRANSPORT_BINDER_WIRE_FORMAT_BINDER_ANDROID_H
 #define GRPC_CORE_EXT_TRANSPORT_BINDER_WIRE_FORMAT_BINDER_ANDROID_H
 
-#if defined(ANDROID) || defined(__ANDROID__)
-
 #include <grpc/impl/codegen/port_platform.h>
 
+#ifdef GPR_SUPPORT_BINDER_TRANSPORT
+
 #include <android/binder_auto_utils.h>
 #include <android/binder_ibinder.h>
 #include <android/binder_ibinder_jni.h>
 #include <memory>
 
 #include "absl/memory/memory.h"
-#include "src/core/ext/transport/binder/wire_format/binder.h"
 
-// TODO(b/192208764): move this check to somewhere else
-#if __ANDROID_API__ < 29
-#error "We only support Android API level >= 29."
-#endif
+#include "src/core/ext/transport/binder/wire_format/binder.h"
+#include "src/core/ext/transport/binder/wire_format/wire_reader.h"
 
 namespace grpc_binder {
 
@@ -48,8 +45,10 @@ class WritableParcelAndroid final : public WritableParcel {
   ~WritableParcelAndroid() override = default;
 
   int32_t GetDataPosition() const override;
+  int32_t GetDataSize() const override;
   absl::Status SetDataPosition(int32_t pos) override;
   absl::Status WriteInt32(int32_t data) override;
+  absl::Status WriteInt64(int64_t data) override;
   absl::Status WriteBinder(HasRawBinder* binder) override;
   absl::Status WriteString(absl::string_view s) override;
   absl::Status WriteByteArray(const int8_t* buffer, int32_t length) override;
@@ -68,7 +67,9 @@ class ReadableParcelAndroid final : public ReadableParcel {
       : parcel_(const_cast<AParcel*>(parcel)) {}
   ~ReadableParcelAndroid() override = default;
 
+  int32_t GetDataSize() const override;
   absl::Status ReadInt32(int32_t* data) const override;
+  absl::Status ReadInt64(int64_t* data) const override;
   absl::Status ReadBinder(std::unique_ptr<Binder>* data) const override;
   absl::Status ReadByteArray(std::string* data) const override;
   // FIXME(waynetu): Fix the interface.
@@ -102,6 +103,7 @@ class BinderAndroid final : public Binder {
   };
 
   std::unique_ptr<TransactionReceiver> ConstructTxReceiver(
+      grpc_core::RefCountedPtr<WireReader> wire_reader_ref,
       TransactionReceiver::OnTransactCb transact_cb) const override;
 
  private:
@@ -112,7 +114,9 @@ class BinderAndroid final : public Binder {
 
 class TransactionReceiverAndroid final : public TransactionReceiver {
  public:
-  explicit TransactionReceiverAndroid(OnTransactCb transaction_cb);
+  TransactionReceiverAndroid(
+      grpc_core::RefCountedPtr<WireReader> wire_reader_ref,
+      OnTransactCb transaction_cb);
   ~TransactionReceiverAndroid() override;
   void* GetRawBinder() override { return binder_; }
 
@@ -123,6 +127,6 @@ class TransactionReceiverAndroid final : public TransactionReceiver {
 
 }  // namespace grpc_binder
 
-#endif  // defined(ANDROID) || defined(__ANDROID__)
+#endif /*GPR_SUPPORT_BINDER_TRANSPORT*/
 
 #endif  // GRPC_CORE_EXT_TRANSPORT_BINDER_WIRE_FORMAT_BINDER_ANDROID_H
index edf5b7e..a4ca49d 100644 (file)
 
 #include "src/core/ext/transport/binder/wire_format/binder_constants.h"
 
-#ifndef ANDROID
+#ifndef GPR_SUPPORT_BINDER_TRANSPORT
 
 const int FIRST_CALL_TRANSACTION = 0x00000001;
 const int LAST_CALL_TRANSACTION = 0x00FFFFFF;
 
-#endif  // ANDROID
+#endif  // GPR_SUPPORT_BINDER_TRANSPORT
 
 namespace grpc_binder {
 
index 1d102be..e17e6d5 100644 (file)
@@ -19,7 +19,7 @@
 
 #include "absl/base/attributes.h"
 
-#if defined(ANDROID) || defined(__ANDROID__)
+#ifdef GPR_SUPPORT_BINDER_TRANSPORT
 
 #include <android/binder_auto_utils.h>
 #include <android/binder_ibinder.h>
@@ -33,7 +33,7 @@ using transaction_code_t = uint32_t;
 ABSL_CONST_INIT extern const int FIRST_CALL_TRANSACTION;
 ABSL_CONST_INIT extern const int LAST_CALL_TRANSACTION;
 
-#endif  // defined(ANDROID) || defined(__ANDROID__)
+#endif  // GPR_SUPPORT_BINDER_TRANSPORT
 
 namespace grpc_binder {
 
index a9da9d5..aa16bce 100644 (file)
@@ -25,5 +25,6 @@ const int kFlagOutOfBandClose = 0x8;
 const int kFlagExpectSingleMessage = 0x10;
 const int kFlagStatusDescription = 0x20;
 const int kFlagMessageDataIsParcelable = 0x40;
+const int kFlagMessageDataIsPartial = 0x80;
 
 }  // namespace grpc_binder
index 74983b8..33e02a2 100644 (file)
 
 #include <grpc/impl/codegen/port_platform.h>
 
-#include <grpc/support/log.h>
-
 #include <string>
 #include <vector>
 
 #include "absl/strings/string_view.h"
 
+#include <grpc/support/log.h>
+
 namespace grpc_binder {
 
 ABSL_CONST_INIT extern const int kFlagPrefix;
@@ -33,13 +33,14 @@ ABSL_CONST_INIT extern const int kFlagOutOfBandClose;
 ABSL_CONST_INIT extern const int kFlagExpectSingleMessage;
 ABSL_CONST_INIT extern const int kFlagStatusDescription;
 ABSL_CONST_INIT extern const int kFlagMessageDataIsParcelable;
+ABSL_CONST_INIT extern const int kFlagMessageDataIsPartial;
 
 using Metadata = std::vector<std::pair<std::string, std::string>>;
 
 class Transaction {
  public:
-  Transaction(int tx_code, int seq_num, bool is_client)
-      : tx_code_(tx_code), seq_num_(seq_num), is_client_(is_client) {}
+  Transaction(int tx_code, bool is_client)
+      : tx_code_(tx_code), is_client_(is_client) {}
   // TODO(mingcl): Consider using string_view
   void SetPrefix(Metadata prefix_metadata) {
     prefix_metadata_ = prefix_metadata;
@@ -76,7 +77,6 @@ class Transaction {
   bool IsClient() const { return is_client_; }
   bool IsServer() const { return !is_client_; }
   int GetTxCode() const { return tx_code_; }
-  int GetSeqNum() const { return seq_num_; }
   int GetFlags() const { return flags_; }
 
   absl::string_view GetMethodRef() const { return method_ref_; }
@@ -87,7 +87,6 @@ class Transaction {
 
  private:
   int tx_code_;
-  int seq_num_;
   bool is_client_;
   Metadata prefix_metadata_;
   Metadata suffix_metadata_;
index 9857ed7..c6d944a 100644 (file)
 
 #include "src/core/ext/transport/binder/wire_format/binder.h"
 #include "src/core/ext/transport/binder/wire_format/wire_writer.h"
+#include "src/core/lib/gprpp/orphanable.h"
 
 namespace grpc_binder {
 
-class WireReader {
+class WireReader : public grpc_core::InternallyRefCounted<WireReader> {
  public:
-  virtual ~WireReader() = default;
-  virtual std::unique_ptr<WireWriter> SetupTransport(
+  ~WireReader() override = default;
+  virtual std::shared_ptr<WireWriter> SetupTransport(
       std::unique_ptr<Binder> endpoint_binder) = 0;
 };
 
index 793f73b..0c0d522 100644 (file)
@@ -16,8 +16,6 @@
 
 #include "src/core/ext/transport/binder/wire_format/wire_reader_impl.h"
 
-#include <grpc/support/log.h>
-
 #include <functional>
 #include <limits>
 #include <string>
@@ -26,6 +24,9 @@
 
 #include "absl/memory/memory.h"
 #include "absl/status/statusor.h"
+
+#include <grpc/support/log.h>
+
 #include "src/core/ext/transport/binder/utils/transport_stream_receiver.h"
 #include "src/core/ext/transport/binder/wire_format/binder.h"
 #include "src/core/ext/transport/binder/wire_format/wire_writer.h"
@@ -43,8 +44,11 @@ absl::StatusOr<Metadata> parse_metadata(const ReadableParcel* reader) {
   int num_header;
   RETURN_IF_ERROR(reader->ReadInt32(&num_header));
   gpr_log(GPR_INFO, "num_header = %d", num_header);
+  if (num_header < 0) {
+    return absl::InvalidArgumentError("num_header cannot be negative");
+  }
   std::vector<std::pair<std::string, std::string>> ret;
-  for (int i = 0; i != num_header; i++) {
+  for (int i = 0; i < num_header; i++) {
     int count;
     RETURN_IF_ERROR(reader->ReadInt32(&count));
     gpr_log(GPR_INFO, "count = %d", count);
@@ -56,7 +60,7 @@ absl::StatusOr<Metadata> parse_metadata(const ReadableParcel* reader) {
     std::string value{};
     if (count > 0) RETURN_IF_ERROR(reader->ReadByteArray(&value));
     gpr_log(GPR_INFO, "value = %s", value.c_str());
-    ret.push_back({key, value});
+    ret.emplace_back(key, value);
   }
   return ret;
 }
@@ -64,31 +68,46 @@ absl::StatusOr<Metadata> parse_metadata(const ReadableParcel* reader) {
 }  // namespace
 
 WireReaderImpl::WireReaderImpl(
-    TransportStreamReceiver* transport_stream_receiver, bool is_client)
-    : transport_stream_receiver_(transport_stream_receiver),
-      is_client_(is_client) {}
+    std::shared_ptr<TransportStreamReceiver> transport_stream_receiver,
+    bool is_client, std::function<void()> on_destruct_callback)
+    : transport_stream_receiver_(std::move(transport_stream_receiver)),
+      is_client_(is_client),
+      on_destruct_callback_(on_destruct_callback) {}
 
-WireReaderImpl::~WireReaderImpl() = default;
+WireReaderImpl::~WireReaderImpl() {
+  if (on_destruct_callback_) {
+    on_destruct_callback_();
+  }
+}
 
-std::unique_ptr<WireWriter> WireReaderImpl::SetupTransport(
+std::shared_ptr<WireWriter> WireReaderImpl::SetupTransport(
     std::unique_ptr<Binder> binder) {
+  gpr_log(GPR_INFO, "Setting up transport");
   if (!is_client_) {
-    gpr_log(GPR_ERROR, "Server-side SETUP_TRANSPORT is not implemented yet.");
-    return nullptr;
+    SendSetupTransport(binder.get());
+    {
+      grpc_core::MutexLock lock(&mu_);
+      connected_ = true;
+      wire_writer_ = std::make_shared<WireWriterImpl>(std::move(binder));
+    }
+    return wire_writer_;
+  } else {
+    SendSetupTransport(binder.get());
+    auto other_end_binder = RecvSetupTransport();
+    {
+      grpc_core::MutexLock lock(&mu_);
+      connected_ = true;
+      wire_writer_ =
+          std::make_shared<WireWriterImpl>(std::move(other_end_binder));
+    }
+    return wire_writer_;
   }
+}
 
-  gpr_log(GPR_INFO, "Setting up transport");
+void WireReaderImpl::SendSetupTransport(Binder* binder) {
   binder->Initialize();
   gpr_log(GPR_INFO, "prepare transaction = %d",
           binder->PrepareTransaction().ok());
-
-  // Only support client-side transport setup.
-  SendSetupTransport(binder.get());
-  RecvSetupTransport();
-  return absl::make_unique<WireWriterImpl>(std::move(other_end_binder_));
-}
-
-void WireReaderImpl::SendSetupTransport(Binder* binder) {
   WritableParcel* writable_parcel = binder->GetWritableParcel();
   gpr_log(GPR_INFO, "data position = %d", writable_parcel->GetDataPosition());
   // gpr_log(GPR_INFO, "set data position to 0 = %d",
@@ -101,7 +120,11 @@ void WireReaderImpl::SendSetupTransport(Binder* binder) {
   // The lifetime of the transaction receiver is the same as the wire writer's.
   // The transaction receiver is responsible for not calling the on-transact
   // callback when it's dead.
+  // Give TransactionReceiver a Ref() since WireReader cannot be destructed
+  // during callback execution. TransactionReceiver should make sure that the
+  // callback owns a Ref() when it's being invoked.
   tx_receiver_ = binder->ConstructTxReceiver(
+      /*wire_reader_ref=*/Ref(),
       [this](transaction_code_t code, const ReadableParcel* readable_parcel) {
         return this->ProcessTransaction(code, readable_parcel);
       });
@@ -113,12 +136,13 @@ void WireReaderImpl::SendSetupTransport(Binder* binder) {
           binder->Transact(BinderTransportTxCode::SETUP_TRANSPORT).ok());
 }
 
-void WireReaderImpl::RecvSetupTransport() {
+std::unique_ptr<Binder> WireReaderImpl::RecvSetupTransport() {
   // TODO(b/191941760): avoid blocking, handle wire_writer_noti lifetime
   // better
   gpr_log(GPR_INFO, "start waiting for noti");
   connection_noti_.WaitForNotification();
   gpr_log(GPR_INFO, "end waiting for noti");
+  return std::move(other_end_binder_);
 }
 
 absl::Status WireReaderImpl::ProcessTransaction(transaction_code_t code,
@@ -134,14 +158,26 @@ absl::Status WireReaderImpl::ProcessTransaction(transaction_code_t code,
                     BinderTransportTxCode::SETUP_TRANSPORT) &&
         code <= static_cast<transaction_code_t>(
                     BinderTransportTxCode::PING_RESPONSE))) {
-    gpr_log(GPR_ERROR,
+    gpr_log(GPR_INFO,
             "Received unknown control message. Shutdown transport gracefully.");
     // TODO(waynetu): Shutdown transport gracefully.
     return absl::OkStatus();
   }
 
+  grpc_core::MutexLock lock(&mu_);
+
+  if (BinderTransportTxCode(code) != BinderTransportTxCode::SETUP_TRANSPORT &&
+      !connected_) {
+    return absl::InvalidArgumentError("Transports not connected yet");
+  }
+
   switch (BinderTransportTxCode(code)) {
     case BinderTransportTxCode::SETUP_TRANSPORT: {
+      if (recvd_setup_transport_) {
+        return absl::InvalidArgumentError(
+            "Already received a SETUP_TRANSPORT request");
+      }
+      recvd_setup_transport_ = true;
       // int datasize;
       int version;
       // getDataSize not supported until 31
@@ -152,6 +188,9 @@ absl::Status WireReaderImpl::ProcessTransaction(transaction_code_t code,
       gpr_log(GPR_INFO, "version = %d", version);
       std::unique_ptr<Binder> binder{};
       RETURN_IF_ERROR(parcel->ReadBinder(&binder));
+      if (!binder) {
+        return absl::InternalError("Read NULL binder from the parcel");
+      }
       binder->Initialize();
       other_end_binder_ = std::move(binder);
       connection_noti_.Notify();
@@ -160,17 +199,20 @@ absl::Status WireReaderImpl::ProcessTransaction(transaction_code_t code,
     case BinderTransportTxCode::SHUTDOWN_TRANSPORT: {
       gpr_log(GPR_ERROR,
               "Received SHUTDOWN_TRANSPORT request but not implemented yet.");
-      GPR_ASSERT(false);
-      break;
+      return absl::UnimplementedError("SHUTDOWN_TRANSPORT");
     }
     case BinderTransportTxCode::ACKNOWLEDGE_BYTES: {
-      int num_bytes = -1;
-      RETURN_IF_ERROR(parcel->ReadInt32(&num_bytes));
-      gpr_log(GPR_INFO, "received acknowledge bytes = %d", num_bytes);
+      int64_t num_bytes = -1;
+      RETURN_IF_ERROR(parcel->ReadInt64(&num_bytes));
+      gpr_log(GPR_INFO, "received acknowledge bytes = %lld",
+              static_cast<long long>(num_bytes));
+      wire_writer_->OnAckReceived(num_bytes);
       break;
     }
     case BinderTransportTxCode::PING: {
-      GPR_ASSERT(!is_client_);
+      if (is_client_) {
+        return absl::FailedPreconditionError("Receive PING request in client");
+      }
       int ping_id = -1;
       RETURN_IF_ERROR(parcel->ReadInt32(&ping_id));
       gpr_log(GPR_INFO, "received ping id = %d", ping_id);
@@ -189,16 +231,66 @@ absl::Status WireReaderImpl::ProcessTransaction(transaction_code_t code,
 
 absl::Status WireReaderImpl::ProcessStreamingTransaction(
     transaction_code_t code, const ReadableParcel* parcel) {
+  grpc_core::MutexLock lock(&mu_);
+  if (!connected_) {
+    return absl::InvalidArgumentError("Transports not connected yet");
+  }
+
+  // Indicate which callbacks should be cancelled. It will be initialized as the
+  // flags the in-coming transaction carries, and when a particular callback is
+  // completed, the corresponding bit in cancellation_flag will be set to 0 so
+  // that we won't cancel it afterward.
+  int cancellation_flags = 0;
+  absl::Status status =
+      ProcessStreamingTransactionImpl(code, parcel, &cancellation_flags);
+  if (!status.ok()) {
+    gpr_log(GPR_ERROR, "Failed to process streaming transaction: %s",
+            status.ToString().c_str());
+    // Something went wrong when receiving transaction. Cancel failed requests.
+    if (cancellation_flags & kFlagPrefix) {
+      gpr_log(GPR_INFO, "cancelling initial metadata");
+      transport_stream_receiver_->NotifyRecvInitialMetadata(code, status);
+    }
+    if (cancellation_flags & kFlagMessageData) {
+      gpr_log(GPR_INFO, "cancelling message data");
+      transport_stream_receiver_->NotifyRecvMessage(code, status);
+    }
+    if (cancellation_flags & kFlagSuffix) {
+      gpr_log(GPR_INFO, "cancelling trailing metadata");
+      transport_stream_receiver_->NotifyRecvTrailingMetadata(code, status, 0);
+    }
+  }
+  if ((num_incoming_bytes_ - num_acknowledged_bytes_) >= kFlowControlAckBytes) {
+    GPR_ASSERT(wire_writer_);
+    absl::Status ack_status = wire_writer_->SendAck(num_incoming_bytes_);
+    if (status.ok()) {
+      status = ack_status;
+    }
+    num_acknowledged_bytes_ = num_incoming_bytes_;
+  }
+  return status;
+}
+
+absl::Status WireReaderImpl::ProcessStreamingTransactionImpl(
+    transaction_code_t code, const ReadableParcel* parcel,
+    int* cancellation_flags) {
+  GPR_ASSERT(cancellation_flags);
+  num_incoming_bytes_ += parcel->GetDataSize();
+
   int flags;
   RETURN_IF_ERROR(parcel->ReadInt32(&flags));
   gpr_log(GPR_INFO, "flags = %d", flags);
+  *cancellation_flags = flags;
 
   // Ignore in-coming transaction with flag = 0 to match with Java
   // implementation.
   // TODO(waynetu): Check with grpc-java team to see whether this is the
   // intended behavior.
   // TODO(waynetu): What should be returned here?
-  if (flags == 0) return absl::OkStatus();
+  if (flags == 0) {
+    gpr_log(GPR_INFO, "[WARNING] Receive empty transaction. Ignored.");
+    return absl::OkStatus();
+  }
 
   int status = flags >> 16;
   gpr_log(GPR_INFO, "status = %d", status);
@@ -212,9 +304,10 @@ absl::Status WireReaderImpl::ProcessStreamingTransaction(
   // out-of-order or missing transactions. WireReaderImpl should be fixed if
   // we indeed found such behavior.
   int32_t& expectation = expected_seq_num_[code];
-  // TODO(mingcl): Don't assert here
-  GPR_ASSERT(seq_num >= 0);
-  GPR_ASSERT(seq_num == expectation && "Interleaved sequence number");
+  if (seq_num < 0 || seq_num != expectation) {
+    // Unexpected sequence number.
+    return absl::InternalError("Unexpected sequence number");
+  }
   // TODO(waynetu): According to the protocol, "The sequence number will wrap
   // around to 0 if more than 2^31 messages are sent." For now we'll just
   // assert that it never reach such circumstances.
@@ -224,6 +317,7 @@ absl::Status WireReaderImpl::ProcessStreamingTransaction(
   gpr_log(GPR_INFO, "sequence number = %d", seq_num);
   if (flags & kFlagPrefix) {
     char method_ref[111];
+    memset(method_ref, 0, sizeof(method_ref));
     if (!is_client_) {
       RETURN_IF_ERROR(parcel->ReadString(method_ref));
     }
@@ -232,10 +326,12 @@ absl::Status WireReaderImpl::ProcessStreamingTransaction(
       return initial_metadata_or_error.status();
     }
     if (!is_client_) {
-      initial_metadata_or_error->emplace_back(":path", method_ref);
+      initial_metadata_or_error->emplace_back(":path",
+                                              std::string("/") + method_ref);
     }
     transport_stream_receiver_->NotifyRecvInitialMetadata(
         code, *initial_metadata_or_error);
+    *cancellation_flags &= ~kFlagPrefix;
   }
   if (flags & kFlagMessageData) {
     int count;
@@ -246,12 +342,19 @@ absl::Status WireReaderImpl::ProcessStreamingTransaction(
       RETURN_IF_ERROR(parcel->ReadByteArray(&msg_data));
     }
     gpr_log(GPR_INFO, "msg_data = %s", msg_data.c_str());
-    transport_stream_receiver_->NotifyRecvMessage(code, msg_data);
+    message_buffer_[code] += msg_data;
+    if ((flags & kFlagMessageDataIsPartial) == 0) {
+      std::string s = std::move(message_buffer_[code]);
+      message_buffer_.erase(code);
+      transport_stream_receiver_->NotifyRecvMessage(code, std::move(s));
+    }
+    *cancellation_flags &= ~kFlagMessageData;
   }
   if (flags & kFlagSuffix) {
     if (flags & kFlagStatusDescription) {
       // FLAG_STATUS_DESCRIPTION set
       char desc[111];
+      memset(desc, 0, sizeof(desc));
       RETURN_IF_ERROR(parcel->ReadString(desc));
       gpr_log(GPR_INFO, "description = %s", desc);
     }
@@ -265,7 +368,8 @@ absl::Status WireReaderImpl::ProcessStreamingTransaction(
       trailing_metadata = *trailing_metadata_or_error;
     }
     transport_stream_receiver_->NotifyRecvTrailingMetadata(
-        code, trailing_metadata, status);
+        code, std::move(trailing_metadata), status);
+    *cancellation_flags &= ~kFlagSuffix;
   }
   return absl::OkStatus();
 }
index 25e3914..db1f7d5 100644 (file)
@@ -22,6 +22,7 @@
 
 #include "absl/container/flat_hash_map.h"
 #include "absl/synchronization/notification.h"
+
 #include "src/core/ext/transport/binder/utils/transport_stream_receiver.h"
 #include "src/core/ext/transport/binder/wire_format/binder.h"
 #include "src/core/ext/transport/binder/wire_format/wire_reader.h"
@@ -31,44 +32,98 @@ namespace grpc_binder {
 
 class WireReaderImpl : public WireReader {
  public:
-  explicit WireReaderImpl(TransportStreamReceiver* transport_stream_receiver,
-                          bool is_client);
+  WireReaderImpl(
+      std::shared_ptr<TransportStreamReceiver> transport_stream_receiver,
+      bool is_client, std::function<void()> on_destruct_callback = nullptr);
   ~WireReaderImpl() override;
 
-  // Setup the transport between endpoint binders.
-  //
-  // The client and the server both call SetupTransport() when constructing
-  // transport.
-  //
-  // High-level overview of transaction setup:
-  // 0. Client obtain an |endpoint_binder| from the server.
-  // 1. Client creates a binder |client_binder| and hook its on-transaction
-  // callback to client's ProcessTransaction(). Client then sends
-  // |client_binder| through |endpoint_binder| to server.
-  // 2. Server receives |client_binder| via |endpoint_binder|.
-  // 3. Server creates a binder |server_binder| and hook its on-transaction
-  // callback to server's ProcessTransaction(). Server then sends
-  // |server_binder| through |client_binder| back to the client.
-  // 4. Client receives |server_binder| via |client_binder|'s on-transaction
-  // callback.
-  std::unique_ptr<WireWriter> SetupTransport(
-      std::unique_ptr<Binder> endpoint_binder) override;
+  void Orphan() override { Unref(); }
+
+  /// Setup the transport between endpoint binders.
+  ///
+  /// The client and the server both call SetupTransport() when constructing
+  /// transport.
+  ///
+  /// High-level overview of transaction setup:
+  /// 0. Client obtains an |endpoint_binder| from the server (in the Android
+  /// setting, this can be achieved by "binding" to the server APK).
+  /// 1. Client creates a binder |client_binder| and hook its on-transaction
+  /// callback to client's ProcessTransaction(). Client then sends
+  /// |client_binder| through |endpoint_binder| to server.
+  /// 2. Server receives |client_binder| via |endpoint_binder|.
+  /// 3. Server creates a binder |server_binder| and hook its on-transaction
+  /// callback to server's ProcessTransaction(). Server then sends
+  /// |server_binder| through |client_binder| back to the client.
+  /// 4. Client receives |server_binder| via |client_binder|'s on-transaction
+  /// callback.
+  ///
+  /// The parameter \p binder here means different things for client nad server.
+  /// For client, \p binder refers to |endpoint_binder|, and for server, \p
+  /// binder refers to |client_binder|. That is, for server-side transport
+  /// setup, we assume that the first half of SETUP_TRANSPORT (up to step 2) is
+  /// already done somewhere else (see test/end2end/binder_transport_test.cc for
+  /// how it's handled in the testing environment).
+  std::shared_ptr<WireWriter> SetupTransport(
+      std::unique_ptr<Binder> binder) override;
 
   absl::Status ProcessTransaction(transaction_code_t code,
                                   const ReadableParcel* parcel);
 
- private:
+  /// Send SETUP_TRANSPORT request through \p binder.
+  ///
+  /// This is the one half (for client it's the first half, and for server it's
+  /// the second) of the SETUP_TRANSPORT negotiation process. First, a new
+  /// binder is created. We take its "receiving" part and construct the
+  /// transaction receiver with it, and sends the "sending" part along with the
+  /// SETUP_TRANSPORT message through \p binder.
   void SendSetupTransport(Binder* binder);
-  void RecvSetupTransport();
+
+  /// Recv SETUP_TRANSPORT request.
+  ///
+  /// This is the other half of the SETUP_TRANSPORT process. We wait for
+  /// in-coming SETUP_TRANSPORT request with the "sending" part of a binder from
+  /// the other end. For client, the message is coming from the trasnaction
+  /// receiver we just constructed in SendSetupTransport(). For server, we
+  /// assume that this step is already completed.
+  // TODO(waynetu): In the testing environment, we still use this method (on
+  // another WireReader instance) for server-side transport setup, and thus it
+  // is marked as public. Try moving this method back to private, and hopefully
+  // we can also avoid moving |other_end_binder_| out in the implementation.
+  std::unique_ptr<Binder> RecvSetupTransport();
+
+ private:
   absl::Status ProcessStreamingTransaction(transaction_code_t code,
                                            const ReadableParcel* parcel);
+  absl::Status ProcessStreamingTransactionImpl(transaction_code_t code,
+                                               const ReadableParcel* parcel,
+                                               int* cancellation_flags)
+      ABSL_EXCLUSIVE_LOCKS_REQUIRED(mu_);
 
-  TransportStreamReceiver* transport_stream_receiver_;
+  std::shared_ptr<TransportStreamReceiver> transport_stream_receiver_;
   absl::Notification connection_noti_;
+  grpc_core::Mutex mu_;
+  bool connected_ ABSL_GUARDED_BY(mu_) = false;
+  bool recvd_setup_transport_ ABSL_GUARDED_BY(mu_) = false;
+  // NOTE: other_end_binder_ will be moved out when RecvSetupTransport() is
+  // called. Be cautious not to access it afterward.
   std::unique_ptr<Binder> other_end_binder_;
-  absl::flat_hash_map<transaction_code_t, int32_t> expected_seq_num_;
+  absl::flat_hash_map<transaction_code_t, int32_t> expected_seq_num_
+      ABSL_GUARDED_BY(mu_);
+  absl::flat_hash_map<transaction_code_t, std::string> message_buffer_
+      ABSL_GUARDED_BY(mu_);
   std::unique_ptr<TransactionReceiver> tx_receiver_;
   bool is_client_;
+  // When WireReaderImpl gets destructed, call on_destruct_callback_. This is
+  // mostly for decrementing the reference count of its transport.
+  std::function<void()> on_destruct_callback_;
+
+  // ACK every 16k bytes.
+  static constexpr int64_t kFlowControlAckBytes = 16 * 1024;
+  int64_t num_incoming_bytes_ ABSL_GUARDED_BY(mu_) = 0;
+  int64_t num_acknowledged_bytes_ ABSL_GUARDED_BY(mu_) = 0;
+
+  // Used to send ACK.
+  std::shared_ptr<WireWriter> wire_writer_;
 };
 
 }  // namespace grpc_binder
index 074baa9..3540941 100644 (file)
 
 #include "src/core/ext/transport/binder/wire_format/wire_writer.h"
 
-#include <grpc/support/log.h>
-
 #include <utility>
 
+#include <grpc/support/log.h>
+
 #define RETURN_IF_ERROR(expr)           \
   do {                                  \
     const absl::Status status = (expr); \
@@ -30,51 +30,152 @@ namespace grpc_binder {
 WireWriterImpl::WireWriterImpl(std::unique_ptr<Binder> binder)
     : binder_(std::move(binder)) {}
 
+absl::Status WireWriterImpl::WriteInitialMetadata(const Transaction& tx,
+                                                  WritableParcel* parcel) {
+  if (tx.IsClient()) {
+    // Only client sends method ref.
+    RETURN_IF_ERROR(parcel->WriteString(tx.GetMethodRef()));
+  }
+  RETURN_IF_ERROR(parcel->WriteInt32(tx.GetPrefixMetadata().size()));
+  for (const auto& md : tx.GetPrefixMetadata()) {
+    RETURN_IF_ERROR(parcel->WriteByteArrayWithLength(md.first));
+    RETURN_IF_ERROR(parcel->WriteByteArrayWithLength(md.second));
+  }
+  return absl::OkStatus();
+}
+
+absl::Status WireWriterImpl::WriteTrailingMetadata(const Transaction& tx,
+                                                   WritableParcel* parcel) {
+  if (tx.IsServer()) {
+    if (tx.GetFlags() & kFlagStatusDescription) {
+      RETURN_IF_ERROR(parcel->WriteString(tx.GetStatusDesc()));
+    }
+    RETURN_IF_ERROR(parcel->WriteInt32(tx.GetSuffixMetadata().size()));
+    for (const auto& md : tx.GetSuffixMetadata()) {
+      RETURN_IF_ERROR(parcel->WriteByteArrayWithLength(md.first));
+      RETURN_IF_ERROR(parcel->WriteByteArrayWithLength(md.second));
+    }
+  } else {
+    // client suffix currently is always empty according to the wireformat
+    if (!tx.GetSuffixMetadata().empty()) {
+      gpr_log(GPR_ERROR, "Got non-empty suffix metadata from client.");
+    }
+  }
+  return absl::OkStatus();
+}
+
+const int64_t WireWriterImpl::kBlockSize = 16 * 1024;
+const int64_t WireWriterImpl::kFlowControlWindowSize = 128 * 1024;
+
+bool WireWriterImpl::CanBeSentInOneTransaction(const Transaction& tx) const {
+  return (tx.GetFlags() & kFlagMessageData) == 0 ||
+         tx.GetMessageData().size() <= kBlockSize;
+}
+
+absl::Status WireWriterImpl::RpcCallFastPath(const Transaction& tx) {
+  int& seq = seq_num_[tx.GetTxCode()];
+  // Fast path: send data in one transaction.
+  RETURN_IF_ERROR(binder_->PrepareTransaction());
+  WritableParcel* parcel = binder_->GetWritableParcel();
+  RETURN_IF_ERROR(parcel->WriteInt32(tx.GetFlags()));
+  RETURN_IF_ERROR(parcel->WriteInt32(seq++));
+  if (tx.GetFlags() & kFlagPrefix) {
+    RETURN_IF_ERROR(WriteInitialMetadata(tx, parcel));
+  }
+  if (tx.GetFlags() & kFlagMessageData) {
+    RETURN_IF_ERROR(parcel->WriteByteArrayWithLength(tx.GetMessageData()));
+  }
+  if (tx.GetFlags() & kFlagSuffix) {
+    RETURN_IF_ERROR(WriteTrailingMetadata(tx, parcel));
+  }
+  // FIXME(waynetu): Construct BinderTransportTxCode from an arbitrary integer
+  // is an undefined behavior.
+  return binder_->Transact(BinderTransportTxCode(tx.GetTxCode()));
+}
+
+bool WireWriterImpl::WaitForAcknowledgement() {
+  if (num_outgoing_bytes_ < num_acknowledged_bytes_ + kFlowControlWindowSize) {
+    return true;
+  }
+  absl::Time deadline = absl::Now() + absl::Seconds(1);
+  do {
+    if (cv_.WaitWithDeadline(&mu_, deadline)) {
+      return false;
+    }
+    if (absl::Now() >= deadline) {
+      return false;
+    }
+  } while (num_outgoing_bytes_ >=
+           num_acknowledged_bytes_ + kFlowControlWindowSize);
+  return true;
+}
+
 absl::Status WireWriterImpl::RpcCall(const Transaction& tx) {
   // TODO(mingcl): check tx_code <= last call id
   grpc_core::MutexLock lock(&mu_);
   GPR_ASSERT(tx.GetTxCode() >= kFirstCallId);
-  RETURN_IF_ERROR(binder_->PrepareTransaction());
-  WritableParcel* parcel = binder_->GetWritableParcel();
-  {
-    //  fill parcel
-    RETURN_IF_ERROR(parcel->WriteInt32(tx.GetFlags()));
-    RETURN_IF_ERROR(parcel->WriteInt32(tx.GetSeqNum()));
-    if (tx.GetFlags() & kFlagPrefix) {
-      // prefix set
-      if (tx.IsClient()) {
-        // Only client sends method ref.
-        RETURN_IF_ERROR(parcel->WriteString(tx.GetMethodRef()));
+  if (CanBeSentInOneTransaction(tx)) {
+    return RpcCallFastPath(tx);
+  }
+  // Slow path: the message data is too large to fit in one transaction.
+  int& seq = seq_num_[tx.GetTxCode()];
+  int original_flags = tx.GetFlags();
+  GPR_ASSERT(original_flags & kFlagMessageData);
+  absl::string_view data = tx.GetMessageData();
+  size_t bytes_sent = 0;
+  while (bytes_sent < data.size()) {
+    if (!WaitForAcknowledgement()) {
+      return absl::InternalError("Timeout waiting for acknowledgement");
+    }
+    RETURN_IF_ERROR(binder_->PrepareTransaction());
+    WritableParcel* parcel = binder_->GetWritableParcel();
+    size_t size =
+        std::min(static_cast<size_t>(kBlockSize), data.size() - bytes_sent);
+    int flags = kFlagMessageData;
+    if (bytes_sent == 0) {
+      // This is the first transaction. Include initial metadata if there's any.
+      if (original_flags & kFlagPrefix) {
+        flags |= kFlagPrefix;
       }
-      RETURN_IF_ERROR(parcel->WriteInt32(tx.GetPrefixMetadata().size()));
-      for (const auto& md : tx.GetPrefixMetadata()) {
-        RETURN_IF_ERROR(parcel->WriteByteArrayWithLength(md.first));
-        RETURN_IF_ERROR(parcel->WriteByteArrayWithLength(md.second));
+    }
+    if (bytes_sent + kBlockSize >= data.size()) {
+      // This is the last transaction. Include trailing metadata if there's any.
+      if (original_flags & kFlagSuffix) {
+        flags |= kFlagSuffix;
       }
+    } else {
+      // There are more messages to send.
+      flags |= kFlagMessageDataIsPartial;
     }
-    if (tx.GetFlags() & kFlagMessageData) {
-      RETURN_IF_ERROR(parcel->WriteByteArrayWithLength(tx.GetMessageData()));
+    RETURN_IF_ERROR(parcel->WriteInt32(flags));
+    RETURN_IF_ERROR(parcel->WriteInt32(seq++));
+    if (flags & kFlagPrefix) {
+      RETURN_IF_ERROR(WriteInitialMetadata(tx, parcel));
     }
-    if (tx.GetFlags() & kFlagSuffix) {
-      if (tx.IsServer()) {
-        if (tx.GetFlags() & kFlagStatusDescription) {
-          RETURN_IF_ERROR(parcel->WriteString(tx.GetStatusDesc()));
-        }
-        RETURN_IF_ERROR(parcel->WriteInt32(tx.GetSuffixMetadata().size()));
-        for (const auto& md : tx.GetSuffixMetadata()) {
-          RETURN_IF_ERROR(parcel->WriteByteArrayWithLength(md.first));
-          RETURN_IF_ERROR(parcel->WriteByteArrayWithLength(md.second));
-        }
-      } else {
-        // client suffix currently is always empty according to the wireformat
-        if (!tx.GetSuffixMetadata().empty()) {
-          gpr_log(GPR_ERROR, "Got non-empty suffix metadata from client.");
-        }
-      }
+    RETURN_IF_ERROR(
+        parcel->WriteByteArrayWithLength(data.substr(bytes_sent, size)));
+    if (flags & kFlagSuffix) {
+      RETURN_IF_ERROR(WriteTrailingMetadata(tx, parcel));
     }
+    num_outgoing_bytes_ += parcel->GetDataSize();
+    RETURN_IF_ERROR(binder_->Transact(BinderTransportTxCode(tx.GetTxCode())));
+    bytes_sent += size;
   }
-  // FIXME(waynetu): Construct BinderTransportTxCode from an arbitrary integer
-  // is an undefined behavior.
-  return binder_->Transact(BinderTransportTxCode(tx.GetTxCode()));
+  return absl::OkStatus();
+}
+
+absl::Status WireWriterImpl::SendAck(int64_t num_bytes) {
+  grpc_core::MutexLock lock(&mu_);
+  RETURN_IF_ERROR(binder_->PrepareTransaction());
+  WritableParcel* parcel = binder_->GetWritableParcel();
+  RETURN_IF_ERROR(parcel->WriteInt64(num_bytes));
+  return binder_->Transact(BinderTransportTxCode::ACKNOWLEDGE_BYTES);
+}
+
+void WireWriterImpl::OnAckReceived(int64_t num_bytes) {
+  grpc_core::MutexLock lock(&mu_);
+  num_acknowledged_bytes_ = std::max(num_acknowledged_bytes_, num_bytes);
+  cv_.Signal();
 }
+
 }  // namespace grpc_binder
index 1f11745..765c6e6 100644 (file)
 
 #include <grpc/impl/codegen/port_platform.h>
 
-#include <grpc/support/log.h>
-
 #include <string>
 #include <vector>
 
+#include "absl/container/flat_hash_map.h"
+
 #include "src/core/ext/transport/binder/wire_format/binder.h"
 #include "src/core/ext/transport/binder/wire_format/transaction.h"
 #include "src/core/lib/gprpp/sync.h"
@@ -32,16 +32,51 @@ class WireWriter {
  public:
   virtual ~WireWriter() = default;
   virtual absl::Status RpcCall(const Transaction& call) = 0;
+  virtual absl::Status SendAck(int64_t num_bytes) = 0;
+  virtual void OnAckReceived(int64_t num_bytes) = 0;
 };
 
 class WireWriterImpl : public WireWriter {
  public:
   explicit WireWriterImpl(std::unique_ptr<Binder> binder);
   absl::Status RpcCall(const Transaction& tx) override;
+  absl::Status SendAck(int64_t num_bytes) override;
+  void OnAckReceived(int64_t num_bytes) override;
+
+  // Split long message into chunks of size 16k. This doesn't necessarily have
+  // to be the same as the flow control acknowledgement size, but it should not
+  // exceed 128k.
+  static const int64_t kBlockSize;
+  // Flow control allows sending at most 128k between acknowledgements.
+  static const int64_t kFlowControlWindowSize;
 
  private:
+  absl::Status WriteInitialMetadata(const Transaction& tx,
+                                    WritableParcel* parcel)
+      ABSL_EXCLUSIVE_LOCKS_REQUIRED(mu_);
+  absl::Status WriteTrailingMetadata(const Transaction& tx,
+                                     WritableParcel* parcel)
+      ABSL_EXCLUSIVE_LOCKS_REQUIRED(mu_);
+
+  bool CanBeSentInOneTransaction(const Transaction& tx) const;
+  absl::Status RpcCallFastPath(const Transaction& tx)
+      ABSL_EXCLUSIVE_LOCKS_REQUIRED(mu_);
+
+  // Wait for acknowledgement from the other side for a while (the timeout is
+  // currently set to 10ms for debugability). Returns true if we are able to
+  // proceed, and false otherwise.
+  //
+  // TODO(waynetu): Currently, RpcCall() will fail if we are blocked for 10ms.
+  // In the future, we should queue the transactions and release them later when
+  // acknowledgement comes.
+  bool WaitForAcknowledgement() ABSL_EXCLUSIVE_LOCKS_REQUIRED(mu_);
+
   grpc_core::Mutex mu_;
+  grpc_core::CondVar cv_;
   std::unique_ptr<Binder> binder_ ABSL_GUARDED_BY(mu_);
+  absl::flat_hash_map<int, int> seq_num_ ABSL_GUARDED_BY(mu_);
+  int64_t num_outgoing_bytes_ ABSL_GUARDED_BY(mu_) = 0;
+  int64_t num_acknowledged_bytes_ ABSL_GUARDED_BY(mu_) = 0;
 };
 
 }  // namespace grpc_binder
index 1fdab76..33f7627 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include <grpc/support/log.h>
 #include "src/core/ext/transport/chttp2/alpn/alpn.h"
 
+#include <grpc/support/log.h>
+
 #include "src/core/lib/gpr/useful.h"
 
 /* in order of preference */
index 8b3d5d7..96dd4eb 100644 (file)
 
 #include "src/core/ext/transport/chttp2/client/chttp2_connector.h"
 
-#include <grpc/grpc.h>
-
 #include <string.h>
 
+#include <grpc/grpc.h>
 #include <grpc/slice_buffer.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/string_util.h>
 
 #include "src/core/ext/filters/client_channel/connector.h"
-#include "src/core/ext/filters/client_channel/http_connect_handshaker.h"
 #include "src/core/ext/filters/client_channel/subchannel.h"
 #include "src/core/ext/transport/chttp2/transport/chttp2_transport.h"
+#include "src/core/lib/address_utils/sockaddr_utils.h"
 #include "src/core/lib/channel/channel_args.h"
 #include "src/core/lib/channel/handshaker.h"
-#include "src/core/lib/channel/handshaker_registry.h"
+#include "src/core/lib/config/core_configuration.h"
 #include "src/core/lib/iomgr/tcp_client.h"
 #include "src/core/lib/slice/slice_internal.h"
 
@@ -45,7 +44,12 @@ Chttp2Connector::Chttp2Connector() {
 }
 
 Chttp2Connector::~Chttp2Connector() {
-  if (endpoint_ != nullptr) grpc_endpoint_destroy(endpoint_);
+  if (resource_quota_ != nullptr) {
+    grpc_resource_quota_unref_internal(resource_quota_);
+  }
+  if (endpoint_ != nullptr) {
+    grpc_endpoint_destroy(endpoint_);
+  }
 }
 
 void Chttp2Connector::Connect(const Args& args, Result* result,
@@ -63,6 +67,11 @@ void Chttp2Connector::Connect(const Args& args, Result* result,
     connecting_ = true;
     GPR_ASSERT(endpoint_ == nullptr);
     ep = &endpoint_;
+    if (resource_quota_ != nullptr) {
+      grpc_resource_quota_unref_internal(resource_quota_);
+    }
+    resource_quota_ =
+        grpc_resource_quota_from_channel_args(args.channel_args, true);
   }
   // In some implementations, the closure can be flushed before
   // grpc_tcp_client_connect() returns, and since the closure requires access
@@ -71,8 +80,12 @@ void Chttp2Connector::Connect(const Args& args, Result* result,
   // grpc_tcp_client_connect() will fill endpoint_ with proper contents, and we
   // make sure that we still exist at that point by taking a ref.
   Ref().release();  // Ref held by callback.
-  grpc_tcp_client_connect(&connected_, ep, args.interested_parties,
-                          args.channel_args, &addr, args.deadline);
+  grpc_tcp_client_connect(
+      &connected_, ep,
+      grpc_slice_allocator_create(resource_quota_,
+                                  grpc_sockaddr_to_string(&addr, false),
+                                  args.channel_args),
+      args.interested_parties, args.channel_args, &addr, args.deadline);
 }
 
 void Chttp2Connector::Shutdown(grpc_error_handle error) {
@@ -120,9 +133,9 @@ void Chttp2Connector::Connected(void* arg, grpc_error_handle error) {
 
 void Chttp2Connector::StartHandshakeLocked() {
   handshake_mgr_ = MakeRefCounted<HandshakeManager>();
-  HandshakerRegistry::AddHandshakers(HANDSHAKER_CLIENT, args_.channel_args,
-                                     args_.interested_parties,
-                                     handshake_mgr_.get());
+  CoreConfiguration::Get().handshaker_registry().AddHandshakers(
+      HANDSHAKER_CLIENT, args_.channel_args, args_.interested_parties,
+      handshake_mgr_.get());
   grpc_endpoint_add_to_pollset_set(endpoint_, args_.interested_parties);
   handshake_mgr_->DoHandshake(endpoint_, args_.channel_args, args_.deadline,
                               nullptr /* acceptor */, OnHandshakeDone, this);
@@ -165,8 +178,12 @@ void Chttp2Connector::OnHandshakeDone(void* arg, grpc_error_handle error) {
       self->result_->Reset();
       NullThenSchedClosure(DEBUG_LOCATION, &self->notify_, error);
     } else if (args->endpoint != nullptr) {
-      self->result_->transport =
-          grpc_create_chttp2_transport(args->args, args->endpoint, true);
+      self->result_->transport = grpc_create_chttp2_transport(
+          args->args, args->endpoint, true,
+          grpc_resource_user_create(
+              self->resource_quota_,
+              absl::StrCat(grpc_endpoint_get_peer(args->endpoint),
+                           ":connector_transport")));
       self->result_->socket_node =
           grpc_chttp2_transport_get_socket_node(self->result_->transport);
       self->result_->channel_args = args->args;
index 59db078..5ed8ab4 100644 (file)
@@ -24,6 +24,7 @@
 #include "src/core/ext/filters/client_channel/connector.h"
 #include "src/core/lib/channel/handshaker.h"
 #include "src/core/lib/channel/handshaker_registry.h"
+#include "src/core/lib/iomgr/resource_quota.h"
 
 namespace grpc_core {
 
@@ -68,6 +69,7 @@ class Chttp2Connector : public SubchannelConnector {
   grpc_closure on_timeout_;
   absl::optional<grpc_error_handle> notify_error_;
   RefCountedPtr<HandshakeManager> handshake_mgr_;
+  grpc_resource_quota* resource_quota_ = nullptr;
 };
 
 }  // namespace grpc_core
index 58f2742..40b3f6d 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include <grpc/grpc.h>
-
 #include <string.h>
 
+#include <grpc/grpc.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/string_util.h>
 
@@ -68,7 +67,7 @@ grpc_channel* CreateChannel(const char* target, const grpc_channel_args* args,
   grpc_channel_args* new_args =
       grpc_channel_args_copy_and_add_and_remove(args, to_remove, 1, &arg, 1);
   grpc_channel* channel = grpc_channel_create(
-      target, new_args, GRPC_CLIENT_CHANNEL, nullptr, nullptr, error);
+      target, new_args, GRPC_CLIENT_CHANNEL, nullptr, nullptr, 0, error);
   grpc_channel_args_destroy(new_args);
   return channel;
 }
index 4ac3a24..db9d4d5 100644 (file)
@@ -49,17 +49,21 @@ grpc_channel* grpc_insecure_channel_create_from_fd(
 
   int flags = fcntl(fd, F_GETFL, 0);
   GPR_ASSERT(fcntl(fd, F_SETFL, flags | O_NONBLOCK) == 0);
-
+  grpc_resource_quota* resource_quota =
+      grpc_resource_quota_from_channel_args(args, true);
+  grpc_slice_allocator* allocator = grpc_slice_allocator_create(
+      resource_quota, "fd-client:endpoint", final_args);
   grpc_endpoint* client = grpc_tcp_client_create_from_fd(
-      grpc_fd_create(fd, "client", true), args, "fd-client");
-
-  grpc_transport* transport =
-      grpc_create_chttp2_transport(final_args, client, true);
+      grpc_fd_create(fd, "client", true), args, "fd-client", allocator);
+  grpc_transport* transport = grpc_create_chttp2_transport(
+      final_args, client, true,
+      grpc_resource_user_create(resource_quota, "fd-client:transport"));
+  grpc_resource_quota_unref_internal(resource_quota);
   GPR_ASSERT(transport);
   grpc_error_handle error = GRPC_ERROR_NONE;
   grpc_channel* channel =
       grpc_channel_create(target, final_args, GRPC_CLIENT_DIRECT_CHANNEL,
-                          transport, nullptr, &error);
+                          transport, nullptr, 0, &error);
   grpc_channel_args_destroy(final_args);
   if (channel != nullptr) {
     grpc_chttp2_transport_start_reading(transport, nullptr, nullptr, nullptr);
index 5b00098..e6fccf6 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include <grpc/grpc.h>
-
 #include <string.h>
 
+#include <grpc/grpc.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/string_util.h>
 
@@ -146,7 +145,7 @@ grpc_channel* CreateChannel(const char* target, const grpc_channel_args* args,
   grpc_channel_args* new_args =
       grpc_channel_args_copy_and_add_and_remove(args, to_remove, 1, &arg, 1);
   grpc_channel* channel = grpc_channel_create(
-      target, new_args, GRPC_CLIENT_CHANNEL, nullptr, nullptr, error);
+      target, new_args, GRPC_CLIENT_CHANNEL, nullptr, nullptr, 0, error);
   grpc_channel_args_destroy(new_args);
   return channel;
 }
index f37c377..8d330ae 100644 (file)
@@ -23,6 +23,7 @@
 #include <inttypes.h>
 #include <limits.h>
 #include <string.h>
+
 #include <vector>
 
 #include "absl/strings/match.h"
@@ -41,7 +42,7 @@
 #include "src/core/lib/address_utils/sockaddr_utils.h"
 #include "src/core/lib/channel/channel_args.h"
 #include "src/core/lib/channel/handshaker.h"
-#include "src/core/lib/channel/handshaker_registry.h"
+#include "src/core/lib/config/core_configuration.h"
 #include "src/core/lib/gprpp/ref_counted.h"
 #include "src/core/lib/gprpp/ref_counted_ptr.h"
 #include "src/core/lib/iomgr/endpoint.h"
@@ -72,7 +73,8 @@ class Chttp2ServerListener : public Server::ListenerInterface {
 
   // Do not instantiate directly.  Use one of the factory methods above.
   Chttp2ServerListener(Server* server, grpc_channel_args* args,
-                       Chttp2ServerArgsModifier args_modifier);
+                       Chttp2ServerArgsModifier args_modifier,
+                       grpc_resource_quota* resource_quota);
   ~Chttp2ServerListener() override;
 
   void Start(Server* server,
@@ -110,7 +112,8 @@ class Chttp2ServerListener : public Server::ListenerInterface {
       HandshakingState(RefCountedPtr<ActiveConnection> connection_ref,
                        grpc_pollset* accepting_pollset,
                        grpc_tcp_server_acceptor* acceptor,
-                       grpc_channel_args* args);
+                       grpc_channel_args* args,
+                       grpc_resource_user* channel_resource_user);
 
       ~HandshakingState() override;
 
@@ -136,11 +139,13 @@ class Chttp2ServerListener : public Server::ListenerInterface {
       grpc_closure on_timeout_ ABSL_GUARDED_BY(&connection_->mu_);
       grpc_closure on_receive_settings_ ABSL_GUARDED_BY(&connection_->mu_);
       grpc_pollset_set* const interested_parties_;
+      grpc_resource_user* channel_resource_user_;
     };
 
     ActiveConnection(grpc_pollset* accepting_pollset,
                      grpc_tcp_server_acceptor* acceptor,
-                     grpc_channel_args* args);
+                     grpc_channel_args* args,
+                     grpc_resource_user* channel_resource_user);
     ~ActiveConnection() override;
 
     void Orphan() override;
@@ -234,6 +239,7 @@ class Chttp2ServerListener : public Server::ListenerInterface {
   grpc_closure tcp_server_shutdown_complete_ ABSL_GUARDED_BY(mu_);
   grpc_closure* on_destroy_done_ ABSL_GUARDED_BY(mu_) = nullptr;
   RefCountedPtr<channelz::ListenSocketNode> channelz_listen_socket_;
+  grpc_resource_quota* resource_quota_;
 };
 
 //
@@ -305,21 +311,25 @@ grpc_millis GetConnectionDeadline(const grpc_channel_args* args) {
 Chttp2ServerListener::ActiveConnection::HandshakingState::HandshakingState(
     RefCountedPtr<ActiveConnection> connection_ref,
     grpc_pollset* accepting_pollset, grpc_tcp_server_acceptor* acceptor,
-    grpc_channel_args* args)
+    grpc_channel_args* args, grpc_resource_user* channel_resource_user)
     : connection_(std::move(connection_ref)),
       accepting_pollset_(accepting_pollset),
       acceptor_(acceptor),
       handshake_mgr_(MakeRefCounted<HandshakeManager>()),
       deadline_(GetConnectionDeadline(args)),
-      interested_parties_(grpc_pollset_set_create()) {
+      interested_parties_(grpc_pollset_set_create()),
+      channel_resource_user_(channel_resource_user) {
   grpc_pollset_set_add_pollset(interested_parties_, accepting_pollset_);
-  HandshakerRegistry::AddHandshakers(HANDSHAKER_SERVER, args,
-                                     interested_parties_, handshake_mgr_.get());
+  CoreConfiguration::Get().handshaker_registry().AddHandshakers(
+      HANDSHAKER_SERVER, args, interested_parties_, handshake_mgr_.get());
 }
 
 Chttp2ServerListener::ActiveConnection::HandshakingState::~HandshakingState() {
   grpc_pollset_set_del_pollset(interested_parties_, accepting_pollset_);
   grpc_pollset_set_destroy(interested_parties_);
+  if (channel_resource_user_ != nullptr) {
+    grpc_resource_user_unref(channel_resource_user_);
+  }
   gpr_free(acceptor_);
 }
 
@@ -380,16 +390,12 @@ void Chttp2ServerListener::ActiveConnection::HandshakingState::OnHandshakeDone(
   OrphanablePtr<HandshakingState> handshaking_state_ref;
   RefCountedPtr<HandshakeManager> handshake_mgr;
   bool cleanup_connection = false;
-  bool free_resource_quota = false;
-  grpc_resource_user* resource_user =
-      self->connection_->listener_->server_->default_resource_user();
   {
     MutexLock connection_lock(&self->connection_->mu_);
     if (error != GRPC_ERROR_NONE || self->connection_->shutdown_) {
       std::string error_str = grpc_error_std_string(error);
       gpr_log(GPR_DEBUG, "Handshaking failed: %s", error_str.c_str());
       cleanup_connection = true;
-      free_resource_quota = true;
       if (error == GRPC_ERROR_NONE && args->endpoint != nullptr) {
         // We were shut down or stopped serving after handshaking completed
         // successfully, so destroy the endpoint here.
@@ -409,12 +415,17 @@ void Chttp2ServerListener::ActiveConnection::HandshakingState::OnHandshakeDone(
       // code, so we can just clean up here without creating a transport.
       if (args->endpoint != nullptr) {
         grpc_transport* transport = grpc_create_chttp2_transport(
-            args->args, args->endpoint, false, resource_user);
+            args->args, args->endpoint, false,
+            grpc_resource_user_create(
+                self->connection_->listener_->resource_quota_,
+                absl::StrCat(grpc_endpoint_get_peer(args->endpoint),
+                             ":chttp2_server_transport")));
         grpc_error_handle channel_init_err =
             self->connection_->listener_->server_->SetupTransport(
                 transport, self->accepting_pollset_, args->args,
                 grpc_chttp2_transport_get_socket_node(transport),
-                resource_user);
+                self->channel_resource_user_, GRPC_RESOURCE_QUOTA_CHANNEL_SIZE);
+        self->channel_resource_user_ = nullptr;
         if (channel_init_err == GRPC_ERROR_NONE) {
           // Use notify_on_receive_settings callback to enforce the
           // handshake deadline.
@@ -462,12 +473,10 @@ void Chttp2ServerListener::ActiveConnection::HandshakingState::OnHandshakeDone(
           grpc_slice_buffer_destroy_internal(args->read_buffer);
           gpr_free(args->read_buffer);
           cleanup_connection = true;
-          free_resource_quota = true;
           grpc_channel_args_destroy(args->args);
         }
       } else {
         cleanup_connection = true;
-        free_resource_quota = true;
       }
     }
     // Since the handshake manager is done, the connection no longer needs to
@@ -480,8 +489,9 @@ void Chttp2ServerListener::ActiveConnection::HandshakingState::OnHandshakeDone(
   gpr_free(self->acceptor_);
   self->acceptor_ = nullptr;
   OrphanablePtr<ActiveConnection> connection;
-  if (free_resource_quota && resource_user != nullptr) {
-    grpc_resource_user_free(resource_user, GRPC_RESOURCE_QUOTA_CHANNEL_SIZE);
+  if (self->channel_resource_user_ != nullptr) {
+    grpc_resource_user_free(self->channel_resource_user_,
+                            GRPC_RESOURCE_QUOTA_CHANNEL_SIZE);
   }
   if (cleanup_connection) {
     MutexLock listener_lock(&self->connection_->listener_->mu_);
@@ -501,9 +511,9 @@ void Chttp2ServerListener::ActiveConnection::HandshakingState::OnHandshakeDone(
 
 Chttp2ServerListener::ActiveConnection::ActiveConnection(
     grpc_pollset* accepting_pollset, grpc_tcp_server_acceptor* acceptor,
-    grpc_channel_args* args)
+    grpc_channel_args* args, grpc_resource_user* channel_resource_user)
     : handshaking_state_(MakeOrphanable<HandshakingState>(
-          Ref(), accepting_pollset, acceptor, args)) {
+          Ref(), accepting_pollset, acceptor, args, channel_resource_user)) {
   GRPC_CLOSURE_INIT(&on_close_, ActiveConnection::OnClose, this,
                     grpc_schedule_on_exec_ctx);
 }
@@ -587,9 +597,14 @@ grpc_error_handle Chttp2ServerListener::Create(
   // easier without using goto.
   grpc_error_handle error = [&]() {
     // Create Chttp2ServerListener.
-    listener = new Chttp2ServerListener(server, args, args_modifier);
-    error = grpc_tcp_server_create(&listener->tcp_server_shutdown_complete_,
-                                   args, &listener->tcp_server_);
+    listener = new Chttp2ServerListener(
+        server, args, args_modifier,
+        grpc_resource_quota_from_channel_args(args, true));
+    grpc_resource_quota_ref_internal(listener->resource_quota_);
+    error = grpc_tcp_server_create(
+        &listener->tcp_server_shutdown_complete_, args,
+        grpc_slice_allocator_factory_create(listener->resource_quota_),
+        &listener->tcp_server_);
     if (error != GRPC_ERROR_NONE) return error;
     if (server->config_fetcher() != nullptr) {
       listener->resolved_address_ = *addr;
@@ -630,10 +645,14 @@ grpc_error_handle Chttp2ServerListener::Create(
 grpc_error_handle Chttp2ServerListener::CreateWithAcceptor(
     Server* server, const char* name, grpc_channel_args* args,
     Chttp2ServerArgsModifier args_modifier) {
-  Chttp2ServerListener* listener =
-      new Chttp2ServerListener(server, args, args_modifier);
+  Chttp2ServerListener* listener = new Chttp2ServerListener(
+      server, args, args_modifier,
+      grpc_resource_quota_from_channel_args(args, true));
+  grpc_resource_quota_ref_internal(listener->resource_quota_);
   grpc_error_handle error = grpc_tcp_server_create(
-      &listener->tcp_server_shutdown_complete_, args, &listener->tcp_server_);
+      &listener->tcp_server_shutdown_complete_, args,
+      grpc_slice_allocator_factory_create(listener->resource_quota_),
+      &listener->tcp_server_);
   if (error != GRPC_ERROR_NONE) {
     delete listener;
     return error;
@@ -648,8 +667,11 @@ grpc_error_handle Chttp2ServerListener::CreateWithAcceptor(
 
 Chttp2ServerListener::Chttp2ServerListener(
     Server* server, grpc_channel_args* args,
-    Chttp2ServerArgsModifier args_modifier)
-    : server_(server), args_modifier_(args_modifier), args_(args) {
+    Chttp2ServerArgsModifier args_modifier, grpc_resource_quota* resource_quota)
+    : server_(server),
+      args_modifier_(args_modifier),
+      args_(args),
+      resource_quota_(resource_quota) {
   GRPC_CLOSURE_INIT(&tcp_server_shutdown_complete_, TcpServerShutdownComplete,
                     this, grpc_schedule_on_exec_ctx);
 }
@@ -662,6 +684,7 @@ Chttp2ServerListener::~Chttp2ServerListener() {
     ExecCtx::Run(DEBUG_LOCATION, on_destroy_done_, GRPC_ERROR_NONE);
     ExecCtx::Get()->Flush();
   }
+  grpc_resource_quota_unref_internal(resource_quota_);
   grpc_channel_args_destroy(args_);
 }
 
@@ -730,8 +753,8 @@ void Chttp2ServerListener::OnAccept(void* arg, grpc_endpoint* tcp,
     if (!args_result.ok()) {
       gpr_log(GPR_DEBUG, "Closing connection: %s",
               args_result.status().ToString().c_str());
-      endpoint_cleanup(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-          args_result.status().ToString().c_str()));
+      endpoint_cleanup(
+          GRPC_ERROR_CREATE_FROM_CPP_STRING(args_result.status().ToString()));
       return;
     }
     grpc_error_handle error = GRPC_ERROR_NONE;
@@ -744,8 +767,11 @@ void Chttp2ServerListener::OnAccept(void* arg, grpc_endpoint* tcp,
       return;
     }
   }
-  auto connection =
-      MakeOrphanable<ActiveConnection>(accepting_pollset, acceptor, args);
+  grpc_resource_user* channel_resource_user = grpc_resource_user_create(
+      self->resource_quota_,
+      absl::StrCat(grpc_endpoint_get_peer(tcp), ":server_channel"));
+  auto connection = MakeOrphanable<ActiveConnection>(
+      accepting_pollset, acceptor, args, channel_resource_user);
   // We no longer own acceptor
   acceptor = nullptr;
   // Hold a ref to connection to allow starting handshake outside the
@@ -756,13 +782,10 @@ void Chttp2ServerListener::OnAccept(void* arg, grpc_endpoint* tcp,
     MutexLock lock(&self->mu_);
     // Shutdown the the connection if listener's stopped serving.
     if (!self->shutdown_ && self->is_serving_) {
-      grpc_resource_user* resource_user =
-          self->server_->default_resource_user();
-      if (resource_user != nullptr &&
-          !grpc_resource_user_safe_alloc(resource_user,
+      if (!grpc_resource_user_safe_alloc(channel_resource_user,
                                          GRPC_RESOURCE_QUOTA_CHANNEL_SIZE)) {
         gpr_log(
-            GPR_ERROR,
+            GPR_INFO,
             "Memory quota exhausted, rejecting connection, no handshaking.");
       } else {
         // This ref needs to be taken in the critical region after having made
index e00bc92..56588a3 100644 (file)
@@ -19,7 +19,6 @@
 #include <grpc/support/port_platform.h>
 
 #include <grpc/grpc.h>
-
 #include <grpc/support/log.h>
 
 #include "src/core/ext/transport/chttp2/server/chttp2_server.h"
index 836ade2..e47d8af 100644 (file)
@@ -45,14 +45,20 @@ void grpc_server_add_insecure_channel_from_fd(grpc_server* server,
 
   const grpc_channel_args* server_args = core_server->channel_args();
   std::string name = absl::StrCat("fd:", fd);
+  grpc_resource_quota* resource_quota =
+      grpc_resource_quota_create(name.c_str());
   grpc_endpoint* server_endpoint = grpc_tcp_create(
-      grpc_fd_create(fd, name.c_str(), true), server_args, name.c_str());
-
+      grpc_fd_create(fd, name.c_str(), true), server_args, name.c_str(),
+      grpc_slice_allocator_create(resource_quota, name, server_args));
   grpc_transport* transport = grpc_create_chttp2_transport(
-      server_args, server_endpoint, false /* is_client */);
-
-  grpc_error_handle error =
-      core_server->SetupTransport(transport, nullptr, server_args, nullptr);
+      server_args, server_endpoint, false /* is_client */,
+      grpc_resource_user_create(resource_quota,
+                                absl::StrCat(name, ":transport")));
+  grpc_error_handle error = core_server->SetupTransport(
+      transport, nullptr, server_args, nullptr,
+      grpc_resource_user_create(resource_quota,
+                                absl::StrCat(name, ":channel")));
+  grpc_resource_quota_unref_internal(resource_quota);
   if (error == GRPC_ERROR_NONE) {
     for (grpc_pollset* pollset : core_server->pollsets()) {
       grpc_endpoint_add_to_pollset(server_endpoint, pollset);
index f0a0eed..675e554 100644 (file)
@@ -27,7 +27,6 @@
 #include <grpc/support/log.h>
 
 #include "src/core/ext/transport/chttp2/server/chttp2_server.h"
-
 #include "src/core/ext/transport/chttp2/transport/chttp2_transport.h"
 #include "src/core/lib/channel/channel_args.h"
 #include "src/core/lib/channel/handshaker.h"
@@ -50,10 +49,9 @@ grpc_channel_args* ModifyArgsForConnection(grpc_channel_args* args,
   }
   auto security_connector = server_credentials->create_security_connector(args);
   if (security_connector == nullptr) {
-    *error = GRPC_ERROR_CREATE_FROM_COPIED_STRING(
+    *error = GRPC_ERROR_CREATE_FROM_CPP_STRING(
         absl::StrCat("Unable to create secure server with credentials of type ",
-                     server_credentials->type())
-            .c_str());
+                     server_credentials->type()));
     return args;
   }
   grpc_arg arg_to_add =
@@ -101,11 +99,9 @@ int grpc_server_add_secure_http2_port(grpc_server* server, const char* addr,
   } else {
     sc = creds->create_security_connector(nullptr);
     if (sc == nullptr) {
-      err = GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-          absl::StrCat(
-              "Unable to create secure server with credentials of type ",
-              creds->type())
-              .c_str());
+      err = GRPC_ERROR_CREATE_FROM_CPP_STRING(absl::StrCat(
+          "Unable to create secure server with credentials of type ",
+          creds->type()));
       goto done;
     }
     grpc_arg args_to_add[2];
index f8d5778..4be4cc2 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
+#include "src/core/ext/transport/chttp2/transport/bin_decoder.h"
+
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
-#include "src/core/ext/transport/chttp2/transport/bin_decoder.h"
+
 #include "src/core/lib/gpr/string.h"
 #include "src/core/lib/slice/slice_internal.h"
 #include "src/core/lib/slice/slice_string_helpers.h"
index 1cbca03..a2d6142 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include <grpc/slice.h>
 #include <stdbool.h>
 
+#include <grpc/slice.h>
+
 struct grpc_base64_decode_context {
   /* input/output: */
   const uint8_t* input_cur;
index ba39bbd..cd92f72 100644 (file)
@@ -23,6 +23,7 @@
 #include <string.h>
 
 #include <grpc/support/log.h>
+
 #include "src/core/ext/transport/chttp2/transport/huffsyms.h"
 
 static const char alphabet[] =
index 1daad25..05742ce 100644 (file)
 // limitations under the License.
 #include <grpc/support/port_platform.h>
 
-#include "grpc/event_engine/slice_allocator.h"
+#include "src/core/ext/transport/chttp2/transport/chttp2_slice_allocator.h"
 
 #include <functional>
 
 #include "absl/memory/memory.h"
 #include "absl/status/status.h"
 
-#include "src/core/ext/transport/chttp2/transport/chttp2_slice_allocator.h"
+#include <grpc/event_engine/slice_allocator.h>
+
 #include "src/core/lib/iomgr/resource_quota.h"
 
 namespace grpc_event_engine {
@@ -59,7 +60,7 @@ Chttp2SliceAllocatorFactory::~Chttp2SliceAllocatorFactory() {
 std::unique_ptr<SliceAllocator>
 Chttp2SliceAllocatorFactory::CreateSliceAllocator(absl::string_view peer_name) {
   return absl::make_unique<Chttp2SliceAllocator>(
-      grpc_resource_user_create(resource_quota_, peer_name.data()));
+      grpc_resource_user_create(resource_quota_, peer_name));
 }
 
 }  // namespace experimental
index 5e37b8e..01b7d77 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include "grpc/event_engine/slice_allocator.h"
-
 #include <functional>
 
 #include "absl/status/status.h"
 
+#include <grpc/event_engine/slice_allocator.h>
+
 #include "src/core/lib/iomgr/resource_quota.h"
 
 namespace grpc_event_engine {
index 1e980cf..80b1d31 100644 (file)
 
 #include "src/core/ext/transport/chttp2/transport/chttp2_transport.h"
 
+#include <inttypes.h>
+#include <limits.h>
+#include <math.h>
+#include <stdio.h>
+#include <string.h>
+
 #include "absl/strings/str_format.h"
 
 #include <grpc/slice_buffer.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
-#include <grpc/support/port_platform.h>
 #include <grpc/support/string_util.h>
-#include <inttypes.h>
-#include <limits.h>
-#include <math.h>
-#include <stdio.h>
-#include <string.h>
 
 #include "src/core/ext/transport/chttp2/transport/context_list.h"
 #include "src/core/ext/transport/chttp2/transport/frame_data.h"
@@ -204,7 +204,6 @@ grpc_chttp2_transport::~grpc_chttp2_transport() {
   grpc_slice_buffer_destroy_internal(&qbuf);
 
   grpc_slice_buffer_destroy_internal(&outbuf);
-  grpc_chttp2_hpack_compressor_destroy(&hpack_compressor);
 
   grpc_error_handle error =
       GRPC_ERROR_CREATE_FROM_STATIC_STRING("Transport destroyed");
@@ -280,8 +279,7 @@ static bool read_channel_args(grpc_chttp2_transport* t,
       const int value =
           grpc_channel_arg_get_integer(&channel_args->args[i], options);
       if (value >= 0) {
-        grpc_chttp2_hpack_compressor_set_max_usable_size(
-            &t->hpack_compressor, static_cast<uint32_t>(value));
+        t->hpack_compressor.SetMaxUsableSize(value);
       }
     } else if (0 == strcmp(channel_args->args[i].key,
                            GRPC_ARG_HTTP2_MAX_PINGS_WITHOUT_DATA)) {
@@ -474,7 +472,6 @@ grpc_chttp2_transport::grpc_chttp2_transport(
     grpc_slice_buffer_add(&outbuf, grpc_slice_from_copied_string(
                                        GRPC_CHTTP2_CLIENT_CONNECT_STRING));
   }
-  grpc_chttp2_hpack_compressor_init(&hpack_compressor);
   grpc_slice_buffer_init(&qbuf);
   // copy in initial settings to all setting sets
   size_t i;
@@ -538,6 +535,8 @@ grpc_chttp2_transport::grpc_chttp2_transport(
 static void destroy_transport_locked(void* tp, grpc_error_handle /*error*/) {
   grpc_chttp2_transport* t = static_cast<grpc_chttp2_transport*>(tp);
   t->destroying = 1;
+  grpc_resource_user_shutdown(t->resource_user);
+  grpc_resource_user_unref(t->resource_user);
   close_transport_locked(
       t, grpc_error_set_int(
              GRPC_ERROR_CREATE_FROM_STATIC_STRING("Transport destroyed"),
@@ -712,13 +711,10 @@ grpc_chttp2_stream::~grpc_chttp2_stream() {
   GRPC_ERROR_UNREF(read_closed_error);
   GRPC_ERROR_UNREF(write_closed_error);
   GRPC_ERROR_UNREF(byte_stream_error);
-
   flow_control.Destroy();
-
-  if (t->resource_user != nullptr) {
+  if (!t->is_client) {
     grpc_resource_user_free(t->resource_user, GRPC_RESOURCE_QUOTA_CALL_SIZE);
   }
-
   GRPC_CHTTP2_UNREF_TRANSPORT(t, "stream");
   grpc_core::ExecCtx::Run(DEBUG_LOCATION, destroy_stream_arg, GRPC_ERROR_NONE);
 }
@@ -770,10 +766,10 @@ grpc_chttp2_stream* grpc_chttp2_parsing_accept_stream(grpc_chttp2_transport* t,
   // Don't accept the stream if memory quota doesn't allow. Note that we should
   // simply refuse the stream here instead of canceling the stream after it's
   // accepted since the latter will create the call which costs much memory.
-  if (t->resource_user != nullptr &&
-      !grpc_resource_user_safe_alloc(t->resource_user,
+  GPR_ASSERT(t->resource_user != nullptr);
+  if (!grpc_resource_user_safe_alloc(t->resource_user,
                                      GRPC_RESOURCE_QUOTA_CALL_SIZE)) {
-    gpr_log(GPR_ERROR, "Memory exhausted, rejecting the stream.");
+    gpr_log(GPR_INFO, "Memory exhausted, rejecting the stream.");
     grpc_chttp2_add_rst_stream_to_next_write(t, id, GRPC_HTTP2_REFUSED_STREAM,
                                              nullptr);
     grpc_chttp2_initiate_write(t, GRPC_CHTTP2_INITIATE_WRITE_RST_STREAM);
@@ -1749,7 +1745,7 @@ void grpc_chttp2_ack_ping(grpc_chttp2_transport* t, uint64_t id) {
 
 static void send_goaway(grpc_chttp2_transport* t, grpc_error_handle error) {
   // We want to log this irrespective of whether http tracing is enabled
-  gpr_log(GPR_INFO, "%s: Sending goaway err=%s", t->peer_string.c_str(),
+  gpr_log(GPR_DEBUG, "%s: Sending goaway err=%s", t->peer_string.c_str(),
           grpc_error_std_string(error).c_str());
   t->sent_goaway_state = GRPC_CHTTP2_GOAWAY_SEND_SCHEDULED;
   grpc_http2_error_code http_error;
@@ -2353,8 +2349,8 @@ static void close_from_api(grpc_chttp2_transport* t, grpc_chttp2_stream* s,
 
   size_t msg_len = GRPC_SLICE_LENGTH(slice);
   GPR_ASSERT(msg_len <= UINT32_MAX);
-  uint32_t msg_len_len = GRPC_CHTTP2_VARINT_LENGTH((uint32_t)msg_len, 1);
-  message_pfx = GRPC_SLICE_MALLOC(14 + msg_len_len);
+  grpc_core::VarintWriter<1> msg_len_writer(msg_len);
+  message_pfx = GRPC_SLICE_MALLOC(14 + msg_len_writer.length());
   p = GRPC_SLICE_START_PTR(message_pfx);
   *p++ = 0x00; /* literal header, not indexed */
   *p++ = 12;   /* len(grpc-message) */
@@ -2370,8 +2366,8 @@ static void close_from_api(grpc_chttp2_transport* t, grpc_chttp2_stream* s,
   *p++ = 'a';
   *p++ = 'g';
   *p++ = 'e';
-  GRPC_CHTTP2_WRITE_VARINT((uint32_t)msg_len, 1, 0, p, (uint32_t)msg_len_len);
-  p += msg_len_len;
+  msg_len_writer.Write(0, p);
+  p += msg_len_writer.length();
   GPR_ASSERT(p == GRPC_SLICE_END_PTR(message_pfx));
   len += static_cast<uint32_t> GRPC_SLICE_LENGTH(message_pfx);
   len += static_cast<uint32_t>(msg_len);
@@ -3161,8 +3157,8 @@ static void post_benign_reclaimer(grpc_chttp2_transport* t) {
     GRPC_CHTTP2_REF_TRANSPORT(t, "benign_reclaimer");
     GRPC_CLOSURE_INIT(&t->benign_reclaimer_locked, benign_reclaimer, t,
                       grpc_schedule_on_exec_ctx);
-    grpc_resource_user_post_reclaimer(grpc_endpoint_get_resource_user(t->ep),
-                                      false, &t->benign_reclaimer_locked);
+    grpc_resource_user_post_reclaimer(t->resource_user, false,
+                                      &t->benign_reclaimer_locked);
   }
 }
 
@@ -3172,8 +3168,8 @@ static void post_destructive_reclaimer(grpc_chttp2_transport* t) {
     GRPC_CHTTP2_REF_TRANSPORT(t, "destructive_reclaimer");
     GRPC_CLOSURE_INIT(&t->destructive_reclaimer_locked, destructive_reclaimer,
                       t, grpc_schedule_on_exec_ctx);
-    grpc_resource_user_post_reclaimer(grpc_endpoint_get_resource_user(t->ep),
-                                      true, &t->destructive_reclaimer_locked);
+    grpc_resource_user_post_reclaimer(t->resource_user, true,
+                                      &t->destructive_reclaimer_locked);
   }
 }
 
@@ -3208,8 +3204,7 @@ static void benign_reclaimer_locked(void* arg, grpc_error_handle error) {
   }
   t->benign_reclaimer_registered = false;
   if (error != GRPC_ERROR_CANCELLED) {
-    grpc_resource_user_finish_reclamation(
-        grpc_endpoint_get_resource_user(t->ep));
+    grpc_resource_user_finish_reclamation(t->resource_user);
   }
   GRPC_CHTTP2_UNREF_TRANSPORT(t, "benign_reclaimer");
 }
@@ -3246,8 +3241,7 @@ static void destructive_reclaimer_locked(void* arg, grpc_error_handle error) {
     }
   }
   if (error != GRPC_ERROR_CANCELLED) {
-    grpc_resource_user_finish_reclamation(
-        grpc_endpoint_get_resource_user(t->ep));
+    grpc_resource_user_finish_reclamation(t->resource_user);
   }
   GRPC_CHTTP2_UNREF_TRANSPORT(t, "destructive_reclaimer");
 }
index a72d268..f68a55d 100644 (file)
@@ -34,9 +34,12 @@ extern grpc_core::DebugOnlyTraceFlag grpc_trace_chttp2_hpack_parser;
 
 extern bool g_flow_control_enabled;
 
+/// Creates a CHTTP2 Transport. This takes ownership of a \a resource_user ref
+/// from the caller; if the caller still needs the resource_user after creating
+/// a transport, the caller must take another ref.
 grpc_transport* grpc_create_chttp2_transport(
     const grpc_channel_args* channel_args, grpc_endpoint* ep, bool is_client,
-    grpc_resource_user* resource_user = nullptr);
+    grpc_resource_user* resource_user);
 
 grpc_core::RefCountedPtr<grpc_core::channelz::SocketNode>
 grpc_chttp2_transport_get_socket_node(grpc_transport* transport);
index 54ec87c..0e39ff1 100644 (file)
@@ -21,9 +21,8 @@
 
 #include <grpc/support/port_platform.h>
 
-#include "src/core/lib/iomgr/buffer_list.h"
-
 #include "src/core/ext/transport/chttp2/transport/internal.h"
+#include "src/core/lib/iomgr/buffer_list.h"
 
 namespace grpc_core {
 /** A list of RPC Contexts */
index 5f5e551..40abc24 100644 (file)
@@ -43,6 +43,8 @@ namespace chttp2 {
 TestOnlyTransportTargetWindowEstimatesMocker*
     g_test_only_transport_target_window_estimates_mocker;
 
+bool g_test_only_transport_flow_control_window_check;
+
 namespace {
 
 static constexpr const int kTracePadding = 30;
@@ -206,11 +208,9 @@ uint32_t TransportFlowControl::MaybeSendUpdate(bool writing_anyway) {
 grpc_error_handle TransportFlowControl::ValidateRecvData(
     int64_t incoming_frame_size) {
   if (incoming_frame_size > announced_window_) {
-    return GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-        absl::StrFormat("frame of size %" PRId64
-                        " overflows local window of %" PRId64,
-                        incoming_frame_size, announced_window_)
-            .c_str());
+    return GRPC_ERROR_CREATE_FROM_CPP_STRING(absl::StrFormat(
+        "frame of size %" PRId64 " overflows local window of %" PRId64,
+        incoming_frame_size, announced_window_));
   }
   return GRPC_ERROR_NONE;
 }
@@ -248,11 +248,9 @@ grpc_error_handle StreamFlowControl::RecvData(int64_t incoming_frame_size) {
               "See (for example) https://github.com/netty/netty/issues/6520.",
               incoming_frame_size, acked_stream_window, sent_stream_window);
     } else {
-      return GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-          absl::StrFormat("frame of size %" PRId64
-                          " overflows local window of %" PRId64,
-                          incoming_frame_size, acked_stream_window)
-              .c_str());
+      return GRPC_ERROR_CREATE_FROM_CPP_STRING(absl::StrFormat(
+          "frame of size %" PRId64 " overflows local window of %" PRId64,
+          incoming_frame_size, acked_stream_window));
     }
   }
 
@@ -264,6 +262,23 @@ grpc_error_handle StreamFlowControl::RecvData(int64_t incoming_frame_size) {
 
 uint32_t StreamFlowControl::MaybeSendUpdate() {
   FlowControlTrace trace("s updt sent", tfc_, this);
+  // If a recently sent settings frame caused the stream's flow control window
+  // to go in the negative (or < GRPC_HEADER_SIZE_IN_BYTES), update the delta if
+  // one of the following conditions is satisfied -
+  // 1) There is a pending byte_stream and higher layers have expressed interest
+  // in reading additional data through the invokation of `Next()` where the
+  // bytes are to be available asynchronously. 2) There is a pending
+  // recv_message op.
+  // In these cases, we want to make sure that bytes are still flowing.
+  if (local_window_delta_ < GRPC_HEADER_SIZE_IN_BYTES) {
+    if (s_->on_next != nullptr) {
+      GPR_DEBUG_ASSERT(s_->pending_byte_stream);
+      IncomingByteStreamUpdate(GRPC_HEADER_SIZE_IN_BYTES, 0);
+    } else if (s_->recv_message != nullptr) {
+      IncomingByteStreamUpdate(GRPC_HEADER_SIZE_IN_BYTES,
+                               s_->frame_storage.length);
+    }
+  }
   if (local_window_delta_ > announced_window_delta_) {
     uint32_t announce = static_cast<uint32_t> GPR_CLAMP(
         local_window_delta_ - announced_window_delta_, 0, kMaxWindowUpdateSize);
@@ -277,13 +292,10 @@ void StreamFlowControl::IncomingByteStreamUpdate(size_t max_size_hint,
                                                  size_t have_already) {
   FlowControlTrace trace("app st recv", tfc_, this);
   uint32_t max_recv_bytes;
-  uint32_t sent_init_window =
-      tfc_->transport()->settings[GRPC_SENT_SETTINGS]
-                                 [GRPC_CHTTP2_SETTINGS_INITIAL_WINDOW_SIZE];
 
   /* clamp max recv hint to an allowable size */
-  if (max_size_hint >= kMaxWindowUpdateSize - sent_init_window) {
-    max_recv_bytes = kMaxWindowUpdateSize - sent_init_window;
+  if (max_size_hint >= kMaxWindowDelta) {
+    max_recv_bytes = kMaxWindowDelta;
   } else {
     max_recv_bytes = static_cast<uint32_t>(max_size_hint);
   }
@@ -296,7 +308,12 @@ void StreamFlowControl::IncomingByteStreamUpdate(size_t max_size_hint,
   }
 
   /* add some small lookahead to keep pipelines flowing */
-  GPR_DEBUG_ASSERT(max_recv_bytes <= kMaxWindowUpdateSize - sent_init_window);
+  GPR_DEBUG_ASSERT(
+      max_recv_bytes <=
+      kMaxWindowUpdateSize -
+          tfc_->transport()
+              ->settings[GRPC_SENT_SETTINGS]
+                        [GRPC_CHTTP2_SETTINGS_INITIAL_WINDOW_SIZE]);
   if (local_window_delta_ < max_recv_bytes) {
     uint32_t add_max_recv_bytes =
         static_cast<uint32_t>(max_recv_bytes - local_window_delta_);
@@ -324,9 +341,8 @@ static double AdjustForMemoryPressure(grpc_resource_quota* quota,
 }
 
 double TransportFlowControl::TargetLogBdp() {
-  return AdjustForMemoryPressure(
-      grpc_resource_user_quota(grpc_endpoint_get_resource_user(t_->ep)),
-      1 + log2(bdp_estimator_.EstimateBdp()));
+  return AdjustForMemoryPressure(grpc_resource_user_quota(t_->resource_user),
+                                 1 + log2(bdp_estimator_.EstimateBdp()));
 }
 
 double TransportFlowControl::SmoothLogBdp(double value) {
@@ -365,10 +381,10 @@ FlowControlAction TransportFlowControl::PeriodicUpdate() {
                    ->ComputeNextTargetInitialWindowSizeFromPeriodicUpdate(
                        target_initial_window_size_ /* current target */);
     }
-    // Though initial window 'could' drop to 0, we keep the floor at 128
-    target_initial_window_size_ =
-        static_cast<int32_t> GPR_CLAMP(target, 128, INT32_MAX);
-
+    // Though initial window 'could' drop to 0, we keep the floor at
+    // kMinInitialWindowSize
+    target_initial_window_size_ = static_cast<int32_t> GPR_CLAMP(
+        target, kMinInitialWindowSize, kMaxInitialWindowSize);
     action.set_send_initial_window_update(
         DeltaUrgency(target_initial_window_size_,
                      GRPC_CHTTP2_SETTINGS_INITIAL_WINDOW_SIZE),
index b5dce2f..8f266e4 100644 (file)
@@ -47,10 +47,16 @@ static constexpr uint32_t kDefaultWindow = 65535;
 static constexpr int64_t kMaxWindow = static_cast<int64_t>((1u << 31) - 1);
 // TODO(ncteisen): Tune this
 static constexpr uint32_t kFrameSize = 1024 * 1024;
+static constexpr const uint32_t kMinInitialWindowSize = 128;
+static constexpr const uint32_t kMaxInitialWindowSize = (1u << 30);
+// The maximum per-stream flow control window delta to advertise.
+static constexpr const uint32_t kMaxWindowDelta = (1u << 20);
 
 class TransportFlowControl;
 class StreamFlowControl;
 
+extern bool g_test_only_transport_flow_control_window_check;
+
 // Encapsulates a collections of actions the transport needs to take with
 // regard to flow control. Each action comes with urgencies that tell the
 // transport how quickly the action must take place.
@@ -373,9 +379,9 @@ class StreamFlowControlBase {
   virtual void TestOnlyForceHugeWindow() {}
 
   // Getters
-  int64_t remote_window_delta() { return remote_window_delta_; }
-  int64_t local_window_delta() { return local_window_delta_; }
-  int64_t announced_window_delta() { return announced_window_delta_; }
+  int64_t remote_window_delta() const { return remote_window_delta_; }
+  int64_t local_window_delta() const { return local_window_delta_; }
+  int64_t announced_window_delta() const { return announced_window_delta_; }
 
  protected:
   friend class ::grpc::testing::TrickledCHTTP2;
index 0787968..88de467 100644 (file)
@@ -26,6 +26,7 @@
 
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
+
 #include "src/core/ext/transport/chttp2/transport/internal.h"
 #include "src/core/lib/gpr/string.h"
 #include "src/core/lib/gprpp/memory.h"
@@ -45,10 +46,10 @@ grpc_error_handle grpc_chttp2_data_parser_begin_frame(
     grpc_chttp2_data_parser* /*parser*/, uint8_t flags, uint32_t stream_id,
     grpc_chttp2_stream* s) {
   if (flags & ~GRPC_CHTTP2_DATA_FLAG_END_STREAM) {
-    return grpc_error_set_int(
-        GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-            absl::StrFormat("unsupported data flags: 0x%02x", flags).c_str()),
-        GRPC_ERROR_INT_STREAM_ID, static_cast<intptr_t>(stream_id));
+    return grpc_error_set_int(GRPC_ERROR_CREATE_FROM_CPP_STRING(absl::StrFormat(
+                                  "unsupported data flags: 0x%02x", flags)),
+                              GRPC_ERROR_INT_STREAM_ID,
+                              static_cast<intptr_t>(stream_id));
   }
 
   if (flags & GRPC_CHTTP2_DATA_FLAG_END_STREAM) {
@@ -128,9 +129,8 @@ grpc_error_handle grpc_deframe_unprocessed_incoming_frames(
             p->is_frame_compressed = true; /* GPR_TRUE */
             break;
           default:
-            p->error = GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-                absl::StrFormat("Bad GRPC frame type 0x%02x", p->frame_type)
-                    .c_str());
+            p->error = GRPC_ERROR_CREATE_FROM_CPP_STRING(
+                absl::StrFormat("Bad GRPC frame type 0x%02x", p->frame_type));
             p->error = grpc_error_set_int(p->error, GRPC_ERROR_INT_STREAM_ID,
                                           static_cast<intptr_t>(s->id));
             p->error = grpc_error_set_str(
index 5aa4a3e..6690e5f 100644 (file)
@@ -25,6 +25,7 @@
 
 #include <grpc/slice.h>
 #include <grpc/slice_buffer.h>
+
 #include "src/core/ext/transport/chttp2/transport/frame.h"
 #include "src/core/lib/transport/byte_stream.h"
 #include "src/core/lib/transport/transport.h"
index ebd499a..45f250f 100644 (file)
@@ -19,7 +19,6 @@
 #include <grpc/support/port_platform.h>
 
 #include "src/core/ext/transport/chttp2/transport/frame_goaway.h"
-#include "src/core/ext/transport/chttp2/transport/internal.h"
 
 #include <string.h>
 
@@ -28,6 +27,8 @@
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 
+#include "src/core/ext/transport/chttp2/transport/internal.h"
+
 void grpc_chttp2_goaway_parser_init(grpc_chttp2_goaway_parser* p) {
   p->debug_data = nullptr;
 }
@@ -39,8 +40,8 @@ void grpc_chttp2_goaway_parser_destroy(grpc_chttp2_goaway_parser* p) {
 grpc_error_handle grpc_chttp2_goaway_parser_begin_frame(
     grpc_chttp2_goaway_parser* p, uint32_t length, uint8_t /*flags*/) {
   if (length < 8) {
-    return GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-        absl::StrFormat("goaway frame too short (%d bytes)", length).c_str());
+    return GRPC_ERROR_CREATE_FROM_CPP_STRING(
+        absl::StrFormat("goaway frame too short (%d bytes)", length));
   }
 
   gpr_free(p->debug_data);
index 674f742..2ceb620 100644 (file)
@@ -23,6 +23,7 @@
 
 #include <grpc/slice.h>
 #include <grpc/slice_buffer.h>
+
 #include "src/core/ext/transport/chttp2/transport/frame.h"
 
 typedef enum {
index 9da4a72..ceee078 100644 (file)
@@ -19,7 +19,6 @@
 #include <grpc/support/port_platform.h>
 
 #include "src/core/ext/transport/chttp2/transport/frame_ping.h"
-#include "src/core/ext/transport/chttp2/transport/internal.h"
 
 #include <string.h>
 
@@ -28,6 +27,8 @@
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 
+#include "src/core/ext/transport/chttp2/transport/internal.h"
+
 static bool g_disable_ping_ack = false;
 
 grpc_slice grpc_chttp2_ping_create(uint8_t ack, uint64_t opaque_8bytes) {
@@ -58,9 +59,8 @@ grpc_slice grpc_chttp2_ping_create(uint8_t ack, uint64_t opaque_8bytes) {
 grpc_error_handle grpc_chttp2_ping_parser_begin_frame(
     grpc_chttp2_ping_parser* parser, uint32_t length, uint8_t flags) {
   if (flags & 0xfe || length != 8) {
-    return GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-        absl::StrFormat("invalid ping: length=%d, flags=%02x", length, flags)
-            .c_str());
+    return GRPC_ERROR_CREATE_FROM_CPP_STRING(
+        absl::StrFormat("invalid ping: length=%d, flags=%02x", length, flags));
   }
   parser->byte = 0;
   parser->is_ack = flags;
index 6b5318e..c878cff 100644 (file)
@@ -22,6 +22,7 @@
 #include <grpc/support/port_platform.h>
 
 #include <grpc/slice.h>
+
 #include "src/core/ext/transport/chttp2/transport/frame.h"
 
 struct grpc_chttp2_ping_parser {
index 03a7c61..57bf74b 100644 (file)
@@ -19,7 +19,6 @@
 #include <grpc/support/port_platform.h>
 
 #include "src/core/ext/transport/chttp2/transport/frame_rst_stream.h"
-#include "src/core/ext/transport/chttp2/transport/internal.h"
 
 #include "absl/strings/str_cat.h"
 #include "absl/strings/str_format.h"
@@ -28,6 +27,7 @@
 #include <grpc/support/log.h>
 
 #include "src/core/ext/transport/chttp2/transport/frame.h"
+#include "src/core/ext/transport/chttp2/transport/internal.h"
 #include "src/core/lib/gprpp/memory.h"
 #include "src/core/lib/transport/http2_errors.h"
 
@@ -71,10 +71,8 @@ void grpc_chttp2_add_rst_stream_to_next_write(
 grpc_error_handle grpc_chttp2_rst_stream_parser_begin_frame(
     grpc_chttp2_rst_stream_parser* parser, uint32_t length, uint8_t flags) {
   if (length != 4) {
-    return GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-        absl::StrFormat("invalid rst_stream: length=%d, flags=%02x", length,
-                        flags)
-            .c_str());
+    return GRPC_ERROR_CREATE_FROM_CPP_STRING(absl::StrFormat(
+        "invalid rst_stream: length=%d, flags=%02x", length, flags));
   }
   parser->byte = 0;
   return GRPC_ERROR_NONE;
index 865e74d..6581317 100644 (file)
@@ -22,6 +22,7 @@
 #include <grpc/support/port_platform.h>
 
 #include <grpc/slice.h>
+
 #include "src/core/ext/transport/chttp2/transport/frame.h"
 #include "src/core/lib/transport/transport.h"
 
index 35400d0..66b3118 100644 (file)
@@ -19,7 +19,6 @@
 #include <grpc/support/port_platform.h>
 
 #include "src/core/ext/transport/chttp2/transport/frame_settings.h"
-#include "src/core/ext/transport/chttp2/transport/internal.h"
 
 #include <string.h>
 
@@ -30,6 +29,7 @@
 
 #include "src/core/ext/transport/chttp2/transport/chttp2_transport.h"
 #include "src/core/ext/transport/chttp2/transport/frame.h"
+#include "src/core/ext/transport/chttp2/transport/internal.h"
 #include "src/core/lib/debug/trace.h"
 #include "src/core/lib/transport/http2_errors.h"
 
@@ -110,6 +110,22 @@ grpc_error_handle grpc_chttp2_settings_parser_begin_frame(
   }
 }
 
+namespace {
+
+void StreamFlowControlWindowCheck(void* user_data, uint32_t /* key */,
+                                  void* stream) {
+  bool* error = static_cast<bool*>(user_data);
+  grpc_chttp2_stream* s = static_cast<grpc_chttp2_stream*>(stream);
+  if ((s->t->settings[GRPC_PEER_SETTINGS]
+                     [GRPC_CHTTP2_SETTINGS_INITIAL_WINDOW_SIZE] +
+       s->t->initial_window_update + s->flow_control->remote_window_delta()) >
+      ((1u << 31) - 1)) {
+    *error = true;
+  }
+}
+
+}  // namespace
+
 grpc_error_handle grpc_chttp2_settings_parser_parse(void* p,
                                                     grpc_chttp2_transport* t,
                                                     grpc_chttp2_stream* /*s*/,
@@ -209,10 +225,8 @@ grpc_error_handle grpc_chttp2_settings_parser_parse(void* p,
                     t->last_new_stream_id, sp->error_value,
                     grpc_slice_from_static_string("HTTP2 settings error"),
                     &t->qbuf);
-                return GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-                    absl::StrFormat("invalid value %u passed for %s",
-                                    parser->value, sp->name)
-                        .c_str());
+                return GRPC_ERROR_CREATE_FROM_CPP_STRING(absl::StrFormat(
+                    "invalid value %u passed for %s", parser->value, sp->name));
             }
           }
           if (id == GRPC_CHTTP2_SETTINGS_INITIAL_WINDOW_SIZE &&
@@ -225,6 +239,23 @@ grpc_error_handle grpc_chttp2_settings_parser_parse(void* p,
                       t->is_client ? "cli" : "svr",
                       static_cast<int>(t->initial_window_update));
             }
+            if (grpc_core::chttp2::
+                    g_test_only_transport_flow_control_window_check) {
+              bool error = false;
+              if (parser->value > grpc_core::chttp2::kMaxInitialWindowSize ||
+                  parser->value < grpc_core::chttp2::kMinInitialWindowSize) {
+                error = true;
+              } else {
+                grpc_chttp2_stream_map_for_each(
+                    &t->stream_map, StreamFlowControlWindowCheck, &error);
+              }
+              if (error) {
+                grpc_chttp2_goaway_append(
+                    t->last_new_stream_id, sp->error_value,
+                    grpc_slice_from_static_string("HTTP2 settings error"),
+                    &t->qbuf);
+              }
+            }
           }
           parser->incoming_settings[id] = parser->value;
           if (GRPC_TRACE_FLAG_ENABLED(grpc_http_trace)) {
index 7268277..9ec116b 100644 (file)
@@ -22,6 +22,7 @@
 #include <grpc/support/port_platform.h>
 
 #include <grpc/slice.h>
+
 #include "src/core/ext/transport/chttp2/transport/frame.h"
 #include "src/core/ext/transport/chttp2/transport/http2_settings.h"
 
index 37e69ff..9763e81 100644 (file)
@@ -19,7 +19,6 @@
 #include <grpc/support/port_platform.h>
 
 #include "src/core/ext/transport/chttp2/transport/frame_window_update.h"
-#include "src/core/ext/transport/chttp2/transport/internal.h"
 
 #include "absl/strings/str_cat.h"
 #include "absl/strings/str_format.h"
@@ -27,6 +26,8 @@
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 
+#include "src/core/ext/transport/chttp2/transport/internal.h"
+
 grpc_slice grpc_chttp2_window_update_create(
     uint32_t id, uint32_t window_delta, grpc_transport_one_way_stats* stats) {
   static const size_t frame_size = 13;
@@ -56,10 +57,8 @@ grpc_slice grpc_chttp2_window_update_create(
 grpc_error_handle grpc_chttp2_window_update_parser_begin_frame(
     grpc_chttp2_window_update_parser* parser, uint32_t length, uint8_t flags) {
   if (flags || length != 4) {
-    return GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-        absl::StrFormat("invalid window update: length=%d, flags=%02x", length,
-                        flags)
-            .c_str());
+    return GRPC_ERROR_CREATE_FROM_CPP_STRING(absl::StrFormat(
+        "invalid window update: length=%d, flags=%02x", length, flags));
   }
   parser->byte = 0;
   parser->amount = 0;
@@ -89,14 +88,20 @@ grpc_error_handle grpc_chttp2_window_update_parser_parse(
     // top bit is reserved and must be ignored.
     uint32_t received_update = p->amount & 0x7fffffffu;
     if (received_update == 0) {
-      return GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-          absl::StrCat("invalid window update bytes: ", p->amount).c_str());
+      return GRPC_ERROR_CREATE_FROM_CPP_STRING(
+          absl::StrCat("invalid window update bytes: ", p->amount));
     }
     GPR_ASSERT(is_last);
 
     if (t->incoming_stream_id != 0) {
       if (s != nullptr) {
         s->flow_control->RecvUpdate(received_update);
+        if (grpc_core::chttp2::
+                g_test_only_transport_flow_control_window_check &&
+            s->flow_control->remote_window_delta() >
+                grpc_core::chttp2::kMaxWindowDelta) {
+          GPR_ASSERT(false);
+        }
         if (grpc_chttp2_list_remove_stalled_by_stream(t, s)) {
           grpc_chttp2_mark_stream_writable(t, s);
           grpc_chttp2_initiate_write(
index 5a07b9e..ea414d7 100644 (file)
@@ -22,6 +22,7 @@
 #include <grpc/support/port_platform.h>
 
 #include <grpc/slice.h>
+
 #include "src/core/ext/transport/chttp2/transport/frame.h"
 #include "src/core/lib/transport/transport.h"
 
diff --git a/src/core/ext/transport/chttp2/transport/hpack_constants.h b/src/core/ext/transport/chttp2/transport/hpack_constants.h
new file mode 100644 (file)
index 0000000..fb98917
--- /dev/null
@@ -0,0 +1,41 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#ifndef GRPC_CORE_EXT_TRANSPORT_CHTTP2_TRANSPORT_HPACK_CONSTANTS_H
+#define GRPC_CORE_EXT_TRANSPORT_CHTTP2_TRANSPORT_HPACK_CONSTANTS_H
+
+#include <grpc/impl/codegen/port_platform.h>
+
+#include <stdint.h>
+
+namespace grpc_core {
+namespace hpack_constants {
+// Per entry overhead bytes as per the spec
+static constexpr uint32_t kEntryOverhead = 32;
+// Initial table size as per the spec
+static constexpr uint32_t kInitialTableSize = 4096;
+
+// last index in the static table
+static constexpr uint32_t kLastStaticEntry = 61;
+
+static constexpr uint32_t EntriesForBytes(uint32_t bytes) noexcept {
+  return (bytes + kEntryOverhead - 1) / kEntryOverhead;
+}
+
+static constexpr uint32_t kInitialTableEntries =
+    EntriesForBytes(kInitialTableSize);
+}  // namespace hpack_constants
+}  // namespace grpc_core
+
+#endif  // GRPC_CORE_EXT_TRANSPORT_CHTTP2_TRANSPORT_HPACK_CONSTANTS_H
index cc1eba9..e455088 100644 (file)
  * TODO(murgatroid99): Remove this
  */
 #include <grpc/grpc.h>
-
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 
 #include "src/core/ext/transport/chttp2/transport/bin_encoder.h"
-#include "src/core/ext/transport/chttp2/transport/hpack_table.h"
+#include "src/core/ext/transport/chttp2/transport/hpack_utils.h"
 #include "src/core/ext/transport/chttp2/transport/varint.h"
 #include "src/core/lib/debug/stats.h"
 #include "src/core/lib/slice/slice_internal.h"
 #include "src/core/lib/transport/static_metadata.h"
 #include "src/core/lib/transport/timeout_encoding.h"
 
+namespace grpc_core {
+
 namespace {
-/* (Maybe-cuckoo) hpack encoder hash table implementation.
-
-   This hashtable implementation is a subset of a proper cuckoo hash; while we
-   have fallback cells that a value can be hashed to if the first cell is full,
-   we do not attempt to iteratively rearrange entries into backup cells to get
-   things to fit. Instead, if both a cell and the backup cell for a value are
-   occupied, the older existing entry is evicted.
-
-   Note that we can disable backup-cell picking by setting
-   GRPC_HPACK_ENCODER_USE_CUCKOO_HASH to 0. In that case, we simply evict an
-   existing entry rather than try to use a backup. Hence, "maybe-cuckoo."
-   TODO(arjunroy): Add unit tests for hashtable implementation. */
-#define GRPC_HPACK_ENCODER_USE_CUCKOO_HASH 1
-#define HASH_FRAGMENT_MASK (GRPC_CHTTP2_HPACKC_NUM_VALUES - 1)
-#define HASH_FRAGMENT_1(x) ((x)&HASH_FRAGMENT_MASK)
-#define HASH_FRAGMENT_2(x) \
-  (((x) >> GRPC_CHTTP2_HPACKC_NUM_VALUES_BITS) & HASH_FRAGMENT_MASK)
-#define HASH_FRAGMENT_3(x) \
-  (((x) >> (GRPC_CHTTP2_HPACKC_NUM_VALUES_BITS * 2)) & HASH_FRAGMENT_MASK)
-#define HASH_FRAGMENT_4(x) \
-  (((x) >> (GRPC_CHTTP2_HPACKC_NUM_VALUES_BITS * 3)) & HASH_FRAGMENT_MASK)
 
 /* don't consider adding anything bigger than this to the hpack table */
 constexpr size_t kMaxDecoderSpaceUsage = 512;
 constexpr size_t kDataFrameHeaderSize = 9;
-constexpr uint8_t kMaxFilterValue = 255;
-
-/* if the probability of this item being seen again is < 1/x then don't add
-   it to the table */
-#define ONE_ON_ADD_PROBABILITY (GRPC_CHTTP2_HPACKC_NUM_VALUES >> 1)
-/* The hpack index we encode over the wire. Meaningful to the hpack encoder and
-   parser on the remote end as well as HTTP2. *Not* the same as
-   HpackEncoderSlotHash, which is only meaningful to the hpack encoder
-   implementation (HpackEncoderSlotHash is used for the hashtable implementation
-   when mapping from metadata to HpackEncoderIndex. */
-typedef uint32_t HpackEncoderIndex;
-/* Internal-table bookkeeping (*not* the hpack index). */
-typedef uint32_t HpackEncoderSlotHash;
-
-struct SliceRefComparator {
-  typedef grpc_slice_refcount* Type;
-  static grpc_slice_refcount* Null() { return nullptr; }
-  static bool IsNull(const grpc_slice_refcount* sref) {
-    return sref == nullptr;
-  }
-  static bool Equals(const grpc_slice_refcount* s1,
-                     const grpc_slice_refcount* s2) {
-    return s1 == s2;
-  }
-  static void Ref(grpc_slice_refcount* sref) {
-    GPR_DEBUG_ASSERT(sref != nullptr);
-    sref->Ref();
-  }
-  static void Unref(grpc_slice_refcount* sref) {
-    GPR_DEBUG_ASSERT(sref != nullptr);
-    sref->Unref();
-  }
-};
 
-struct MetadataComparator {
-  typedef grpc_mdelem Type;
-  static grpc_mdelem Null() { return {0}; }
-  static bool IsNull(const grpc_mdelem md) { return md.payload == 0; }
-  static bool Equals(const grpc_mdelem md1, const grpc_mdelem md2) {
-    return md1.payload == md2.payload;
-  }
-  static void Ref(grpc_mdelem md) {
-    GPR_DEBUG_ASSERT(md.payload != 0);
-    GRPC_MDELEM_REF(md);
-  }
-  static void Unref(grpc_mdelem md) {
-    GPR_DEBUG_ASSERT(md.payload != 0);
-    GRPC_MDELEM_UNREF(md);
-  }
-};
-
-/* Index table management */
-template <typename Hashtable>
-static HpackEncoderIndex HpackIndex(const Hashtable* hashtable,
-                                    HpackEncoderSlotHash hash_index) {
-  return hashtable[hash_index].index;
-}
-
-template <typename ValueType, typename Hashtable>
-static const ValueType& GetEntry(const Hashtable* hashtable,
-                                 HpackEncoderSlotHash hash_index) {
-  return hashtable[hash_index].value;
-}
-
-template <typename Cmp, typename Hashtable>
-static bool TableEmptyAt(const Hashtable* hashtable,
-                         HpackEncoderSlotHash hash_index) {
-  return Cmp::Equals(hashtable[hash_index].value, Cmp::Null());
-}
-
-template <typename Cmp, typename Hashtable, typename ValueType>
-static bool Matches(const Hashtable* hashtable, const ValueType& value,
-                    HpackEncoderSlotHash hash_index) {
-  return Cmp::Equals(value, hashtable[hash_index].value);
-}
-
-template <typename Hashtable>
-static void UpdateIndex(Hashtable* hashtable, HpackEncoderSlotHash hash_index,
-                        HpackEncoderIndex hpack_index) {
-  hashtable[hash_index].index = hpack_index;
-}
-
-template <typename Hashtable, typename ValueType>
-static void SetIndex(Hashtable* hashtable, HpackEncoderSlotHash hash_index,
-                     const ValueType& value, HpackEncoderIndex hpack_index) {
-  hashtable[hash_index].value = value;
-  UpdateIndex(hashtable, hash_index, hpack_index);
-}
-
-template <typename Cmp, typename Hashtable, typename ValueType>
-static bool GetMatchingIndex(Hashtable* hashtable, const ValueType& value,
-                             uint32_t value_hash, HpackEncoderIndex* index) {
-  const HpackEncoderSlotHash cuckoo_first = HASH_FRAGMENT_2(value_hash);
-  if (Matches<Cmp>(hashtable, value, cuckoo_first)) {
-    *index = HpackIndex(hashtable, cuckoo_first);
-    return true;
-  }
-#if GRPC_HPACK_ENCODER_USE_CUCKOO_HASH
-  const HpackEncoderSlotHash cuckoo_second = HASH_FRAGMENT_3(value_hash);
-
-  if (Matches<Cmp>(hashtable, value, cuckoo_second)) {
-    *index = HpackIndex(hashtable, cuckoo_second);
-    return true;
-  }
-#endif
-  return false;
-}
-
-template <typename Cmp, typename Hashtable, typename ValueType>
-static ValueType ReplaceOlderIndex(Hashtable* hashtable, const ValueType& value,
-                                   HpackEncoderSlotHash hash_index_a,
-                                   HpackEncoderSlotHash hash_index_b,
-                                   HpackEncoderIndex new_index) {
-  const HpackEncoderIndex hpack_idx_a = hashtable[hash_index_a].index;
-  const HpackEncoderIndex hpack_idx_b = hashtable[hash_index_b].index;
-  const HpackEncoderSlotHash id =
-      hpack_idx_a < hpack_idx_b ? hash_index_a : hash_index_b;
-  ValueType old = GetEntry<typename Cmp::Type>(hashtable, id);
-  SetIndex(hashtable, id, value, new_index);
-  return old;
-}
-
-template <typename Cmp, typename Hashtable, typename ValueType>
-static void UpdateAddOrEvict(Hashtable hashtable, const ValueType& value,
-                             uint32_t value_hash, HpackEncoderIndex new_index) {
-  const HpackEncoderSlotHash cuckoo_first = HASH_FRAGMENT_2(value_hash);
-  if (Matches<Cmp>(hashtable, value, cuckoo_first)) {
-    UpdateIndex(hashtable, cuckoo_first, new_index);
-    return;
-  }
-  if (TableEmptyAt<Cmp>(hashtable, cuckoo_first)) {
-    Cmp::Ref(value);
-    SetIndex(hashtable, cuckoo_first, value, new_index);
-    return;
-  }
-#if GRPC_HPACK_ENCODER_USE_CUCKOO_HASH
-  const HpackEncoderSlotHash cuckoo_second = HASH_FRAGMENT_3(value_hash);
-  if (Matches<Cmp>(hashtable, value, cuckoo_second)) {
-    UpdateIndex(hashtable, cuckoo_second, new_index);
-    return;
-  }
-  Cmp::Ref(value);
-  if (TableEmptyAt<Cmp>(hashtable, cuckoo_second)) {
-    SetIndex(hashtable, cuckoo_second, value, new_index);
-    return;
-  }
-  Cmp::Unref(ReplaceOlderIndex<Cmp>(hashtable, value, cuckoo_first,
-                                    cuckoo_second, new_index));
-#else
-  ValueType old = GetEntry<typename Cmp::Type>(hashtable, cuckoo_first);
-  SetIndex(hashtable, cuckoo_first, value, new_index);
-  Cmp::Unref(old);
-#endif
-}
-
-/* halve all counts because an element reached max */
-static void HalveFilter(uint8_t /*idx*/, uint32_t* sum, uint8_t* elems) {
-  *sum = 0;
-  for (int i = 0; i < GRPC_CHTTP2_HPACKC_NUM_VALUES; i++) {
-    elems[i] /= 2;
-    (*sum) += elems[i];
-  }
-}
-
-/* increment a filter count, halve all counts if one element reaches max */
-static void IncrementFilter(uint8_t idx, uint32_t* sum, uint8_t* elems) {
-  elems[idx]++;
-  if (GPR_LIKELY(elems[idx] < kMaxFilterValue)) {
-    (*sum)++;
-  } else {
-    HalveFilter(idx, sum, elems);
-  }
-}
-
-static uint32_t UpdateHashtablePopularity(
-    grpc_chttp2_hpack_compressor* hpack_compressor, uint32_t elem_hash) {
-  const uint32_t popularity_hash = HASH_FRAGMENT_1(elem_hash);
-  IncrementFilter(popularity_hash, &hpack_compressor->filter_elems_sum,
-                  hpack_compressor->filter_elems);
-  return popularity_hash;
-}
-
-static bool CanAddToHashtable(grpc_chttp2_hpack_compressor* hpack_compressor,
-                              uint32_t popularity_hash) {
-  const bool can_add =
-      hpack_compressor->filter_elems[popularity_hash] >=
-      hpack_compressor->filter_elems_sum / ONE_ON_ADD_PROBABILITY;
-  return can_add;
-}
 } /* namespace */
 
-struct framer_state {
-  int is_first_frame;
-  /* number of bytes in 'output' when we started the frame - used to calculate
-     frame length */
-  size_t output_length_at_start_of_frame;
-  /* index (in output) of the header for the current frame */
-  size_t header_idx;
-#ifndef NDEBUG
-  /* have we seen a regular (non-colon-prefixed) header yet? */
-  uint8_t seen_regular_header;
-#endif
-  /* output stream id */
-  uint32_t stream_id;
-  grpc_slice_buffer* output;
-  grpc_transport_one_way_stats* stats;
-  /* maximum size of a frame */
-  size_t max_frame_size;
-  bool use_true_binary_metadata;
-  bool is_end_of_stream;
-};
 /* fills p (which is expected to be kDataFrameHeaderSize bytes long)
  * with a data frame header */
-static void fill_header(uint8_t* p, uint8_t type, uint32_t id, size_t len,
-                        uint8_t flags) {
+static void FillHeader(uint8_t* p, uint8_t type, uint32_t id, size_t len,
+                       uint8_t flags) {
   /* len is the current frame size (i.e. for the frame we're finishing).
      We finish a frame if:
      1) We called ensure_space(), (i.e. add_tiny_header_data()) and adding
-        'need_bytes' to the frame would cause us to exceed st->max_frame_size.
+        'need_bytes' to the frame would cause us to exceed max_frame_size.
      2) We called add_header_data, and adding the slice would cause us to exceed
-        st->max_frame_size.
+        max_frame_size.
      3) We're done encoding the header.
 
-     Thus, len is always <= st->max_frame_size.
-     st->max_frame_size is derived from GRPC_CHTTP2_SETTINGS_MAX_FRAME_SIZE,
+     Thus, len is always <= max_frame_size.
+     max_frame_size is derived from GRPC_CHTTP2_SETTINGS_MAX_FRAME_SIZE,
      which has a max allowable value of 16777215 (see chttp_transport.cc).
      Thus, the following assert can be a debug assert. */
   GPR_DEBUG_ASSERT(len < 16777316);
@@ -307,174 +79,123 @@ static void fill_header(uint8_t* p, uint8_t type, uint32_t id, size_t len,
   *p++ = static_cast<uint8_t>(id);
 }
 
-static size_t current_frame_size(framer_state* st) {
+size_t HPackCompressor::Framer::CurrentFrameSize() const {
   const size_t frame_size =
-      st->output->length - st->output_length_at_start_of_frame;
-  GPR_DEBUG_ASSERT(frame_size <= st->max_frame_size);
+      output_->length - prefix_.output_length_at_start_of_frame;
+  GPR_DEBUG_ASSERT(frame_size <= max_frame_size_);
   return frame_size;
 }
 
-/* finish a frame - fill in the previously reserved header */
-static void finish_frame(framer_state* st, int is_header_boundary) {
-  uint8_t type = 0xff;
-  type =
-      static_cast<uint8_t>(st->is_first_frame ? GRPC_CHTTP2_FRAME_HEADER
-                                              : GRPC_CHTTP2_FRAME_CONTINUATION);
-  uint8_t flags = 0xff;
-  /* per the HTTP/2 spec:
-       A HEADERS frame carries the END_STREAM flag that signals the end of a
-       stream. However, a HEADERS frame with the END_STREAM flag set can be
-       followed by CONTINUATION frames on the same stream. Logically, the
-       CONTINUATION frames are part of the HEADERS frame.
-     Thus, we add the END_STREAM flag to the HEADER frame (the first frame). */
-  flags = static_cast<uint8_t>(st->is_first_frame && st->is_end_of_stream
-                                   ? GRPC_CHTTP2_DATA_FLAG_END_STREAM
-                                   : 0);
-  /* per the HTTP/2 spec:
-       A HEADERS frame without the END_HEADERS flag set MUST be followed by
-       a CONTINUATION frame for the same stream.
-     Thus, we add the END_HEADER flag to the last frame. */
-  flags |= static_cast<uint8_t>(
-      is_header_boundary ? GRPC_CHTTP2_DATA_FLAG_END_HEADERS : 0);
-  fill_header(GRPC_SLICE_START_PTR(st->output->slices[st->header_idx]), type,
-              st->stream_id, current_frame_size(st), flags);
-  st->stats->framing_bytes += kDataFrameHeaderSize;
-  st->is_first_frame = 0;
-}
-
-/* begin a new frame: reserve off header space, remember how many bytes we'd
-   output before beginning */
-static void begin_frame(framer_state* st) {
+// finish a frame - fill in the previously reserved header
+void HPackCompressor::Framer::FinishFrame(bool is_header_boundary) {
+  const uint8_t type = is_first_frame_ ? GRPC_CHTTP2_FRAME_HEADER
+                                       : GRPC_CHTTP2_FRAME_CONTINUATION;
+  uint8_t flags = 0;
+  // per the HTTP/2 spec:
+  //   A HEADERS frame carries the END_STREAM flag that signals the end of a
+  //   stream. However, a HEADERS frame with the END_STREAM flag set can be
+  //   followed by CONTINUATION frames on the same stream. Logically, the
+  //   CONTINUATION frames are part of the HEADERS frame.
+  // Thus, we add the END_STREAM flag to the HEADER frame (the first frame).
+  if (is_first_frame_ && is_end_of_stream_) {
+    flags |= GRPC_CHTTP2_DATA_FLAG_END_STREAM;
+  }
+  // per the HTTP/2 spec:
+  //   A HEADERS frame without the END_HEADERS flag set MUST be followed by
+  //   a CONTINUATION frame for the same stream.
+  // Thus, we add the END_HEADER flag to the last frame.
+  if (is_header_boundary) {
+    flags |= GRPC_CHTTP2_DATA_FLAG_END_HEADERS;
+  }
+  FillHeader(GRPC_SLICE_START_PTR(output_->slices[prefix_.header_idx]), type,
+             stream_id_, CurrentFrameSize(), flags);
+  stats_->framing_bytes += kDataFrameHeaderSize;
+  is_first_frame_ = false;
+}
+
+// begin a new frame: reserve off header space, remember how many bytes we'd
+// output before beginning
+HPackCompressor::Framer::FramePrefix HPackCompressor::Framer::BeginFrame() {
   grpc_slice reserved;
   reserved.refcount = nullptr;
   reserved.data.inlined.length = kDataFrameHeaderSize;
-  st->header_idx = grpc_slice_buffer_add_indexed(st->output, reserved);
-  st->output_length_at_start_of_frame = st->output->length;
+  return FramePrefix{grpc_slice_buffer_add_indexed(output_, reserved),
+                     output_->length};
 }
 
-/* make sure that the current frame is of the type desired, and has sufficient
-   space to add at least about_to_add bytes -- finishes the current frame if
-   needed */
-static void ensure_space(framer_state* st, size_t need_bytes) {
-  if (GPR_LIKELY(current_frame_size(st) + need_bytes <= st->max_frame_size)) {
+// make sure that the current frame is of the type desired, and has sufficient
+// space to add at least about_to_add bytes -- finishes the current frame if
+// needed
+void HPackCompressor::Framer::EnsureSpace(size_t need_bytes) {
+  if (GPR_LIKELY(CurrentFrameSize() + need_bytes <= max_frame_size_)) {
     return;
   }
-  finish_frame(st, 0);
-  begin_frame(st);
+  FinishFrame(false);
+  prefix_ = BeginFrame();
 }
 
-static void add_header_data(framer_state* st, grpc_slice slice) {
-  size_t len = GRPC_SLICE_LENGTH(slice);
-  size_t remaining;
+void HPackCompressor::Framer::Add(grpc_slice slice) {
+  const size_t len = GRPC_SLICE_LENGTH(slice);
   if (len == 0) return;
-  remaining = st->max_frame_size - current_frame_size(st);
+  const size_t remaining = max_frame_size_ - CurrentFrameSize();
   if (len <= remaining) {
-    st->stats->header_bytes += len;
-    grpc_slice_buffer_add(st->output, slice);
+    stats_->header_bytes += len;
+    grpc_slice_buffer_add(output_, slice);
   } else {
-    st->stats->header_bytes += remaining;
-    grpc_slice_buffer_add(st->output, grpc_slice_split_head(&slice, remaining));
-    finish_frame(st, 0);
-    begin_frame(st);
-    add_header_data(st, slice);
+    stats_->header_bytes += remaining;
+    grpc_slice_buffer_add(output_, grpc_slice_split_head(&slice, remaining));
+    FinishFrame(false);
+    prefix_ = BeginFrame();
+    Add(slice);
   }
 }
 
-static uint8_t* add_tiny_header_data(framer_state* st, size_t len) {
-  ensure_space(st, len);
-  st->stats->header_bytes += len;
-  return grpc_slice_buffer_tiny_add(st->output, len);
-}
-
-static void evict_entry(grpc_chttp2_hpack_compressor* c) {
-  c->tail_remote_index++;
-  GPR_ASSERT(c->tail_remote_index > 0);
-  GPR_ASSERT(c->table_size >=
-             c->table_elem_size[c->tail_remote_index % c->cap_table_elems]);
-  GPR_ASSERT(c->table_elems > 0);
-  c->table_size = static_cast<uint16_t>(
-      c->table_size -
-      c->table_elem_size[c->tail_remote_index % c->cap_table_elems]);
-  c->table_elems--;
-}
-
-// Reserve space in table for the new element, evict entries if needed.
-// Return the new index of the element. Return 0 to indicate not adding to
-// table.
-static uint32_t prepare_space_for_new_elem(grpc_chttp2_hpack_compressor* c,
-                                           size_t elem_size) {
-  uint32_t new_index = c->tail_remote_index + c->table_elems + 1;
-  GPR_DEBUG_ASSERT(elem_size < 65536);
-
-  // TODO(arjunroy): Re-examine semantics
-  if (elem_size > c->max_table_size) {
-    while (c->table_size > 0) {
-      evict_entry(c);
-    }
-    return 0;
-  }
-
-  /* Reserve space for this element in the remote table: if this overflows
-     the current table, drop elements until it fits, matching the decompressor
-     algorithm */
-  while (c->table_size + elem_size > c->max_table_size) {
-    evict_entry(c);
-  }
-  GPR_ASSERT(c->table_elems < c->max_table_size);
-  c->table_elem_size[new_index % c->cap_table_elems] =
-      static_cast<uint16_t>(elem_size);
-  c->table_size = static_cast<uint16_t>(c->table_size + elem_size);
-  c->table_elems++;
-
-  return new_index;
+uint8_t* HPackCompressor::Framer::AddTiny(size_t len) {
+  EnsureSpace(len);
+  stats_->header_bytes += len;
+  return grpc_slice_buffer_tiny_add(output_, len);
 }
 
 // Add a key to the dynamic table. Both key and value will be added to table at
 // the decoder.
-static void AddKeyWithIndex(grpc_chttp2_hpack_compressor* c,
-                            grpc_slice_refcount* key_ref, uint32_t new_index,
-                            uint32_t key_hash) {
-  UpdateAddOrEvict<SliceRefComparator>(c->key_table.entries, key_ref, key_hash,
-                                       new_index);
+void HPackCompressor::AddKeyWithIndex(grpc_slice_refcount* key_ref,
+                                      uint32_t new_index, uint32_t key_hash) {
+  key_index_.Insert(KeySliceRef(key_ref, key_hash), new_index);
 }
 
 /* add an element to the decoder table */
-static void AddElemWithIndex(grpc_chttp2_hpack_compressor* c, grpc_mdelem elem,
-                             uint32_t new_index, uint32_t elem_hash,
-                             uint32_t key_hash) {
+void HPackCompressor::AddElemWithIndex(grpc_mdelem elem, uint32_t new_index,
+                                       uint32_t elem_hash, uint32_t key_hash) {
   GPR_DEBUG_ASSERT(GRPC_MDELEM_IS_INTERNED(elem));
-  UpdateAddOrEvict<MetadataComparator>(c->elem_table.entries, elem, elem_hash,
-                                       new_index);
-  AddKeyWithIndex(c, GRPC_MDKEY(elem).refcount, new_index, key_hash);
+  elem_index_.Insert(KeyElem(elem, elem_hash), new_index);
+  AddKeyWithIndex(GRPC_MDKEY(elem).refcount, new_index, key_hash);
 }
 
-static void add_elem(grpc_chttp2_hpack_compressor* c, grpc_mdelem elem,
-                     size_t elem_size, uint32_t elem_hash, uint32_t key_hash) {
-  uint32_t new_index = prepare_space_for_new_elem(c, elem_size);
+void HPackCompressor::AddElem(grpc_mdelem elem, size_t elem_size,
+                              uint32_t elem_hash, uint32_t key_hash) {
+  uint32_t new_index = table_.AllocateIndex(elem_size);
   if (new_index != 0) {
-    AddElemWithIndex(c, elem, new_index, elem_hash, key_hash);
+    AddElemWithIndex(elem, new_index, elem_hash, key_hash);
   }
 }
 
-static void add_key(grpc_chttp2_hpack_compressor* c, grpc_mdelem elem,
-                    size_t elem_size, uint32_t key_hash) {
-  uint32_t new_index = prepare_space_for_new_elem(c, elem_size);
+void HPackCompressor::AddKey(grpc_mdelem elem, size_t elem_size,
+                             uint32_t key_hash) {
+  uint32_t new_index = table_.AllocateIndex(elem_size);
   if (new_index != 0) {
-    AddKeyWithIndex(c, GRPC_MDKEY(elem).refcount, new_index, key_hash);
+    AddKeyWithIndex(GRPC_MDKEY(elem).refcount, new_index, key_hash);
   }
 }
 
-static void emit_indexed(grpc_chttp2_hpack_compressor* /*c*/,
-                         uint32_t elem_index, framer_state* st) {
+void HPackCompressor::Framer::EmitIndexed(uint32_t elem_index) {
   GRPC_STATS_INC_HPACK_SEND_INDEXED();
-  uint32_t len = GRPC_CHTTP2_VARINT_LENGTH(elem_index, 1);
-  GRPC_CHTTP2_WRITE_VARINT(elem_index, 1, 0x80, add_tiny_header_data(st, len),
-                           len);
+  VarintWriter<1> w(elem_index);
+  w.Write(0x80, AddTiny(w.length()));
 }
 
-struct wire_value {
-  wire_value(uint8_t huffman_prefix, bool insert_null_before_wire_value,
-             const grpc_slice& slice)
+struct WireValue {
+  WireValue(uint8_t huffman_prefix, bool insert_null_before_wire_value,
+            const grpc_slice& slice)
       : data(slice),
         huffman_prefix(huffman_prefix),
         insert_null_before_wire_value(insert_null_before_wire_value),
@@ -488,124 +209,131 @@ struct wire_value {
   const size_t length;
 };
 
-template <bool mdkey_definitely_interned>
-static wire_value get_wire_value(grpc_mdelem elem, bool true_binary_enabled) {
-  const bool is_bin_hdr =
-      mdkey_definitely_interned
-          ? grpc_is_refcounted_slice_binary_header(GRPC_MDKEY(elem))
-          : grpc_is_binary_header_internal(GRPC_MDKEY(elem));
-  const grpc_slice& value = GRPC_MDVALUE(elem);
+static WireValue GetWireValue(const grpc_slice& value, bool true_binary_enabled,
+                              bool is_bin_hdr) {
   if (is_bin_hdr) {
     if (true_binary_enabled) {
       GRPC_STATS_INC_HPACK_SEND_BINARY();
-      return wire_value(0x00, true, grpc_slice_ref_internal(value));
+      return WireValue(0x00, true, grpc_slice_ref_internal(value));
     } else {
       GRPC_STATS_INC_HPACK_SEND_BINARY_BASE64();
-      return wire_value(0x80, false,
-                        grpc_chttp2_base64_encode_and_huffman_compress(value));
+      return WireValue(0x80, false,
+                       grpc_chttp2_base64_encode_and_huffman_compress(value));
     }
   } else {
     /* TODO(ctiller): opportunistically compress non-binary headers */
     GRPC_STATS_INC_HPACK_SEND_UNCOMPRESSED();
-    return wire_value(0x00, false, grpc_slice_ref_internal(value));
+    return WireValue(0x00, false, grpc_slice_ref_internal(value));
   }
 }
 
-static uint32_t wire_value_length(const wire_value& v) {
-  GPR_DEBUG_ASSERT(v.length <= UINT32_MAX);
-  return static_cast<uint32_t>(v.length);
-}
+struct DefinitelyInterned {
+  static bool IsBinary(grpc_slice key) {
+    return grpc_is_refcounted_slice_binary_header(key);
+  }
+};
+struct UnsureIfInterned {
+  static bool IsBinary(grpc_slice key) {
+    return grpc_is_binary_header_internal(key);
+  }
+};
 
-namespace {
-enum class EmitLitHdrType { INC_IDX, NO_IDX };
-
-enum class EmitLitHdrVType { INC_IDX_V, NO_IDX_V };
-}  // namespace
-
-template <EmitLitHdrType type>
-static void emit_lithdr(grpc_chttp2_hpack_compressor* /*c*/, uint32_t key_index,
-                        grpc_mdelem elem, framer_state* st) {
-  switch (type) {
-    case EmitLitHdrType::INC_IDX:
-      GRPC_STATS_INC_HPACK_SEND_LITHDR_INCIDX();
-      break;
-    case EmitLitHdrType::NO_IDX:
-      GRPC_STATS_INC_HPACK_SEND_LITHDR_NOTIDX();
-      break;
+class StringValue {
+ public:
+  template <typename MetadataKeyType>
+  StringValue(MetadataKeyType, grpc_mdelem elem, bool use_true_binary_metadata)
+      : wire_value_(GetWireValue(GRPC_MDVALUE(elem), use_true_binary_metadata,
+                                 MetadataKeyType::IsBinary(GRPC_MDKEY(elem)))),
+        len_val_(wire_value_.length) {}
+
+  size_t prefix_length() const {
+    return len_val_.length() +
+           (wire_value_.insert_null_before_wire_value ? 1 : 0);
   }
-  const uint32_t len_pfx = type == EmitLitHdrType::INC_IDX
-                               ? GRPC_CHTTP2_VARINT_LENGTH(key_index, 2)
-                               : GRPC_CHTTP2_VARINT_LENGTH(key_index, 4);
-  const wire_value value =
-      get_wire_value<true>(elem, st->use_true_binary_metadata);
-  const uint32_t len_val = wire_value_length(value);
-  const uint32_t len_val_len = GRPC_CHTTP2_VARINT_LENGTH(len_val, 1);
-  GPR_DEBUG_ASSERT(len_pfx + len_val_len < GRPC_SLICE_INLINED_SIZE);
-  uint8_t* data = add_tiny_header_data(
-      st,
-      len_pfx + len_val_len + (value.insert_null_before_wire_value ? 1 : 0));
-  switch (type) {
-    case EmitLitHdrType::INC_IDX:
-      GRPC_CHTTP2_WRITE_VARINT(key_index, 2, 0x40, data, len_pfx);
-      break;
-    case EmitLitHdrType::NO_IDX:
-      GRPC_CHTTP2_WRITE_VARINT(key_index, 4, 0x00, data, len_pfx);
-      break;
+
+  void WritePrefix(uint8_t* prefix_data) {
+    len_val_.Write(wire_value_.huffman_prefix, prefix_data);
+    if (wire_value_.insert_null_before_wire_value) {
+      prefix_data[len_val_.length()] = 0;
+    }
   }
-  GRPC_CHTTP2_WRITE_VARINT(len_val, 1, value.huffman_prefix, &data[len_pfx],
-                           len_val_len);
-  if (value.insert_null_before_wire_value) {
-    data[len_pfx + len_val_len] = 0;
+
+  const grpc_slice& data() { return wire_value_.data; }
+
+ private:
+  WireValue wire_value_;
+  VarintWriter<1> len_val_;
+};
+
+class StringKey {
+ public:
+  explicit StringKey(grpc_slice key)
+      : key_(key), len_key_(GRPC_SLICE_LENGTH(key)) {}
+
+  size_t prefix_length() const { return 1 + len_key_.length(); }
+
+  void WritePrefix(uint8_t type, uint8_t* data) {
+    data[0] = type;
+    len_key_.Write(0x00, data + 1);
   }
-  add_header_data(st, value.data);
+
+  grpc_slice key() const { return key_; }
+
+ private:
+  grpc_slice key_;
+  VarintWriter<1> len_key_;
+};
+
+void HPackCompressor::Framer::EmitLitHdrIncIdx(uint32_t key_index,
+                                               grpc_mdelem elem) {
+  GRPC_STATS_INC_HPACK_SEND_LITHDR_INCIDX();
+  StringValue emit(DefinitelyInterned(), elem, use_true_binary_metadata_);
+  VarintWriter<2> key(key_index);
+  uint8_t* data = AddTiny(key.length() + emit.prefix_length());
+  key.Write(0x40, data);
+  emit.WritePrefix(data + key.length());
+  Add(emit.data());
+}
+
+void HPackCompressor::Framer::EmitLitHdrNotIdx(uint32_t key_index,
+                                               grpc_mdelem elem) {
+  GRPC_STATS_INC_HPACK_SEND_LITHDR_NOTIDX();
+  StringValue emit(DefinitelyInterned(), elem, use_true_binary_metadata_);
+  VarintWriter<4> key(key_index);
+  uint8_t* data = AddTiny(key.length() + emit.prefix_length());
+  key.Write(0x00, data);
+  emit.WritePrefix(data + key.length());
+  Add(emit.data());
+}
+
+void HPackCompressor::Framer::EmitLitHdrWithStringKeyIncIdx(grpc_mdelem elem) {
+  GRPC_STATS_INC_HPACK_SEND_LITHDR_INCIDX_V();
+  GRPC_STATS_INC_HPACK_SEND_UNCOMPRESSED();
+  StringKey key(GRPC_MDKEY(elem));
+  key.WritePrefix(0x40, AddTiny(key.prefix_length()));
+  Add(grpc_slice_ref_internal(key.key()));
+  StringValue emit(DefinitelyInterned(), elem, use_true_binary_metadata_);
+  emit.WritePrefix(AddTiny(emit.prefix_length()));
+  Add(emit.data());
 }
 
-template <EmitLitHdrVType type>
-static void emit_lithdr_v(grpc_chttp2_hpack_compressor* /*c*/, grpc_mdelem elem,
-                          framer_state* st) {
-  switch (type) {
-    case EmitLitHdrVType::INC_IDX_V:
-      GRPC_STATS_INC_HPACK_SEND_LITHDR_INCIDX_V();
-      break;
-    case EmitLitHdrVType::NO_IDX_V:
-      GRPC_STATS_INC_HPACK_SEND_LITHDR_NOTIDX_V();
-      break;
-  }
+void HPackCompressor::Framer::EmitLitHdrWithStringKeyNotIdx(grpc_mdelem elem) {
+  GRPC_STATS_INC_HPACK_SEND_LITHDR_NOTIDX_V();
   GRPC_STATS_INC_HPACK_SEND_UNCOMPRESSED();
-  const uint32_t len_key =
-      static_cast<uint32_t>(GRPC_SLICE_LENGTH(GRPC_MDKEY(elem)));
-  const wire_value value =
-      type == EmitLitHdrVType::INC_IDX_V
-          ? get_wire_value<true>(elem, st->use_true_binary_metadata)
-          : get_wire_value<false>(elem, st->use_true_binary_metadata);
-  const uint32_t len_val = wire_value_length(value);
-  const uint32_t len_key_len = GRPC_CHTTP2_VARINT_LENGTH(len_key, 1);
-  const uint32_t len_val_len = GRPC_CHTTP2_VARINT_LENGTH(len_val, 1);
-  GPR_DEBUG_ASSERT(len_key <= UINT32_MAX);
-  GPR_DEBUG_ASSERT(1 + len_key_len < GRPC_SLICE_INLINED_SIZE);
-  uint8_t* key_buf = add_tiny_header_data(st, 1 + len_key_len);
-  key_buf[0] = type == EmitLitHdrVType::INC_IDX_V ? 0x40 : 0x00;
-  GRPC_CHTTP2_WRITE_VARINT(len_key, 1, 0x00, &key_buf[1], len_key_len);
-  add_header_data(st, grpc_slice_ref_internal(GRPC_MDKEY(elem)));
-  uint8_t* value_buf = add_tiny_header_data(
-      st, len_val_len + (value.insert_null_before_wire_value ? 1 : 0));
-  GRPC_CHTTP2_WRITE_VARINT(len_val, 1, value.huffman_prefix, value_buf,
-                           len_val_len);
-  if (value.insert_null_before_wire_value) {
-    value_buf[len_val_len] = 0;
-  }
-  add_header_data(st, value.data);
+  StringKey key(GRPC_MDKEY(elem));
+  key.WritePrefix(0x00, AddTiny(key.prefix_length()));
+  Add(grpc_slice_ref_internal(key.key()));
+  StringValue emit(UnsureIfInterned(), elem, use_true_binary_metadata_);
+  emit.WritePrefix(AddTiny(emit.prefix_length()));
+  Add(emit.data());
 }
 
-static void emit_advertise_table_size_change(grpc_chttp2_hpack_compressor* c,
-                                             framer_state* st) {
-  uint32_t len = GRPC_CHTTP2_VARINT_LENGTH(c->max_table_size, 3);
-  GRPC_CHTTP2_WRITE_VARINT(c->max_table_size, 3, 0x20,
-                           add_tiny_header_data(st, len), len);
-  c->advertise_table_size_change = 0;
+void HPackCompressor::Framer::AdvertiseTableSizeChange() {
+  VarintWriter<3> w(compressor_->table_.max_size());
+  w.Write(0x20, AddTiny(w.length()));
 }
 
-static void GPR_ATTRIBUTE_NOINLINE hpack_enc_log(grpc_mdelem elem) {
+void HPackCompressor::Framer::Log(grpc_mdelem elem) {
   char* k = grpc_slice_to_c_string(GRPC_MDKEY(elem));
   char* v = nullptr;
   if (grpc_is_binary_header_internal(GRPC_MDKEY(elem))) {
@@ -623,11 +351,6 @@ static void GPR_ATTRIBUTE_NOINLINE hpack_enc_log(grpc_mdelem elem) {
   gpr_free(v);
 }
 
-static uint32_t dynidx(grpc_chttp2_hpack_compressor* c, uint32_t elem_index) {
-  return 1 + GRPC_CHTTP2_LAST_STATIC_ENTRY + c->tail_remote_index +
-         c->table_elems - elem_index;
-}
-
 struct EmitIndexedStatus {
   EmitIndexedStatus() = default;
   EmitIndexedStatus(uint32_t elem_hash, bool emitted, bool can_add)
@@ -637,264 +360,147 @@ struct EmitIndexedStatus {
   const bool can_add = false;
 };
 
-static EmitIndexedStatus maybe_emit_indexed(grpc_chttp2_hpack_compressor* c,
-                                            grpc_mdelem elem,
-                                            framer_state* st) {
-  const uint32_t elem_hash =
-      GRPC_MDELEM_STORAGE(elem) == GRPC_MDELEM_STORAGE_INTERNED
-          ? reinterpret_cast<grpc_core::InternedMetadata*>(
-                GRPC_MDELEM_DATA(elem))
-                ->hash()
-          : reinterpret_cast<grpc_core::StaticMetadata*>(GRPC_MDELEM_DATA(elem))
-                ->hash();
-  /* Update filter to see if we can perhaps add this elem. */
-  const uint32_t popularity_hash = UpdateHashtablePopularity(c, elem_hash);
-  /* is this elem currently in the decoders table? */
-  HpackEncoderIndex indices_key;
-  if (GetMatchingIndex<MetadataComparator>(c->elem_table.entries, elem,
-                                           elem_hash, &indices_key) &&
-      indices_key > c->tail_remote_index) {
-    emit_indexed(c, dynidx(c, indices_key), st);
-    return EmitIndexedStatus(elem_hash, true, false);
-  }
-  /* Didn't hit either cuckoo index, so no emit. */
-  return EmitIndexedStatus(elem_hash, false,
-                           CanAddToHashtable(c, popularity_hash));
-}
-
-static void emit_maybe_add(grpc_chttp2_hpack_compressor* c, grpc_mdelem elem,
-                           framer_state* st, uint32_t indices_key,
-                           bool should_add_elem, size_t decoder_space_usage,
-                           uint32_t elem_hash, uint32_t key_hash) {
-  if (should_add_elem) {
-    emit_lithdr<EmitLitHdrType::INC_IDX>(c, dynidx(c, indices_key), elem, st);
-    add_elem(c, elem, decoder_space_usage, elem_hash, key_hash);
-  } else {
-    emit_lithdr<EmitLitHdrType::NO_IDX>(c, dynidx(c, indices_key), elem, st);
-  }
-}
-
 /* encode an mdelem */
-static void hpack_enc(grpc_chttp2_hpack_compressor* c, grpc_mdelem elem,
-                      framer_state* st) {
+void HPackCompressor::Framer::EncodeDynamic(grpc_mdelem elem) {
   const grpc_slice& elem_key = GRPC_MDKEY(elem);
-  /* User-provided key len validated in grpc_validate_header_key_is_legal(). */
+  // User-provided key len validated in grpc_validate_header_key_is_legal().
   GPR_DEBUG_ASSERT(GRPC_SLICE_LENGTH(elem_key) > 0);
-  /* Header ordering: all reserved headers (prefixed with ':') must precede
-   * regular headers. This can be a debug assert, since:
-   * 1) User cannot give us ':' headers (grpc_validate_header_key_is_legal()).
-   * 2) grpc filters/core should be checked during debug builds. */
+  // Header ordering: all reserved headers (prefixed with ':') must precede
+  // regular headers. This can be a debug assert, since:
+  // 1) User cannot give us ':' headers (grpc_validate_header_key_is_legal()).
+  // 2) grpc filters/core should be checked during debug builds. */
 #ifndef NDEBUG
   if (GRPC_SLICE_START_PTR(elem_key)[0] != ':') { /* regular header */
-    st->seen_regular_header = 1;
+    seen_regular_header_ = true;
   } else {
     GPR_DEBUG_ASSERT(
-        st->seen_regular_header == 0 &&
+        !seen_regular_header_ &&
         "Reserved header (colon-prefixed) happening after regular ones.");
   }
 #endif
   if (GRPC_TRACE_FLAG_ENABLED(grpc_http_trace)) {
-    hpack_enc_log(elem);
+    Log(elem);
   }
   const bool elem_interned = GRPC_MDELEM_IS_INTERNED(elem);
   const bool key_interned = elem_interned || grpc_slice_is_interned(elem_key);
-  /* Key is not interned, emit literals. */
+  // Key is not interned, emit literals.
   if (!key_interned) {
-    emit_lithdr_v<EmitLitHdrVType::NO_IDX_V>(c, elem, st);
+    EmitLitHdrWithStringKeyNotIdx(elem);
     return;
   }
   /* Interned metadata => maybe already indexed. */
-  const EmitIndexedStatus ret =
-      elem_interned ? maybe_emit_indexed(c, elem, st) : EmitIndexedStatus();
-  if (ret.emitted) {
-    return;
+  uint32_t elem_hash = 0;
+  if (elem_interned) {
+    // Update filter to see if we can perhaps add this elem.
+    elem_hash = GRPC_MDELEM_STORAGE(elem) == GRPC_MDELEM_STORAGE_INTERNED
+                    ? reinterpret_cast<grpc_core::InternedMetadata*>(
+                          GRPC_MDELEM_DATA(elem))
+                          ->hash()
+                    : reinterpret_cast<grpc_core::StaticMetadata*>(
+                          GRPC_MDELEM_DATA(elem))
+                          ->hash();
+    bool can_add_to_hashtable =
+        compressor_->filter_elems_.AddElement(elem_hash % kNumFilterValues);
+    /* is this elem currently in the decoders table? */
+    auto indices_key =
+        compressor_->elem_index_.Lookup(KeyElem(elem, elem_hash));
+    if (indices_key.has_value() &&
+        compressor_->table_.ConvertableToDynamicIndex(*indices_key)) {
+      EmitIndexed(compressor_->table_.DynamicIndex(*indices_key));
+      return;
+    }
+    /* Didn't hit either cuckoo index, so no emit. */
+    if (!can_add_to_hashtable) elem_hash = 0;
   }
+
   /* should this elem be in the table? */
   const size_t decoder_space_usage =
-      grpc_chttp2_get_size_in_hpack_table(elem, st->use_true_binary_metadata);
+      grpc_core::MetadataSizeInHPackTable(elem, use_true_binary_metadata_);
   const bool decoder_space_available =
       decoder_space_usage < kMaxDecoderSpaceUsage;
   const bool should_add_elem =
-      elem_interned && decoder_space_available && ret.can_add;
-  const uint32_t elem_hash = ret.elem_hash;
+      elem_interned && decoder_space_available && elem_hash != 0;
   /* no hits for the elem... maybe there's a key? */
   const uint32_t key_hash = elem_key.refcount->Hash(elem_key);
-  HpackEncoderIndex indices_key;
-  if (GetMatchingIndex<SliceRefComparator>(
-          c->key_table.entries, elem_key.refcount, key_hash, &indices_key) &&
-      indices_key > c->tail_remote_index) {
-    emit_maybe_add(c, elem, st, indices_key, should_add_elem,
-                   decoder_space_usage, elem_hash, key_hash);
+  auto indices_key =
+      compressor_->key_index_.Lookup(KeySliceRef(elem_key.refcount, key_hash));
+  if (indices_key.has_value() &&
+      compressor_->table_.ConvertableToDynamicIndex(*indices_key)) {
+    if (should_add_elem) {
+      EmitLitHdrIncIdx(compressor_->table_.DynamicIndex(*indices_key), elem);
+      compressor_->AddElem(elem, decoder_space_usage, elem_hash, key_hash);
+    } else {
+      EmitLitHdrNotIdx(compressor_->table_.DynamicIndex(*indices_key), elem);
+    }
     return;
   }
   /* no elem, key in the table... fall back to literal emission */
   const bool should_add_key = !elem_interned && decoder_space_available;
   if (should_add_elem || should_add_key) {
-    emit_lithdr_v<EmitLitHdrVType::INC_IDX_V>(c, elem, st);
+    EmitLitHdrWithStringKeyIncIdx(elem);
   } else {
-    emit_lithdr_v<EmitLitHdrVType::NO_IDX_V>(c, elem, st);
+    EmitLitHdrWithStringKeyNotIdx(elem);
   }
   if (should_add_elem) {
-    add_elem(c, elem, decoder_space_usage, elem_hash, key_hash);
+    compressor_->AddElem(elem, decoder_space_usage, elem_hash, key_hash);
   } else if (should_add_key) {
-    add_key(c, elem, decoder_space_usage, key_hash);
+    compressor_->AddKey(elem, decoder_space_usage, key_hash);
   }
 }
 
-#define STRLEN_LIT(x) (sizeof(x) - 1)
-#define TIMEOUT_KEY "grpc-timeout"
-
-static void deadline_enc(grpc_chttp2_hpack_compressor* c, grpc_millis deadline,
-                         framer_state* st) {
+void HPackCompressor::Framer::EncodeDeadline(grpc_millis deadline) {
   char timeout_str[GRPC_HTTP2_TIMEOUT_ENCODE_MIN_BUFSIZE];
   grpc_mdelem mdelem;
   grpc_http2_encode_timeout(deadline - grpc_core::ExecCtx::Get()->Now(),
                             timeout_str);
   mdelem = grpc_mdelem_from_slices(
       GRPC_MDSTR_GRPC_TIMEOUT, grpc_core::UnmanagedMemorySlice(timeout_str));
-  hpack_enc(c, mdelem, st);
+  EncodeDynamic(mdelem);
   GRPC_MDELEM_UNREF(mdelem);
 }
 
-static uint32_t elems_for_bytes(uint32_t bytes) { return (bytes + 31) / 32; }
-
-void grpc_chttp2_hpack_compressor_init(grpc_chttp2_hpack_compressor* c) {
-  memset(c, 0, sizeof(*c));
-  c->max_table_size = GRPC_CHTTP2_HPACKC_INITIAL_TABLE_SIZE;
-  c->cap_table_elems = elems_for_bytes(c->max_table_size);
-  c->max_table_elems = c->cap_table_elems;
-  c->max_usable_size = GRPC_CHTTP2_HPACKC_INITIAL_TABLE_SIZE;
-  const size_t alloc_size = sizeof(*c->table_elem_size) * c->cap_table_elems;
-  c->table_elem_size = static_cast<uint16_t*>(gpr_malloc(alloc_size));
-  memset(c->table_elem_size, 0, alloc_size);
+void HPackCompressor::SetMaxUsableSize(uint32_t max_table_size) {
+  max_usable_size_ = max_table_size;
+  SetMaxTableSize(std::min(table_.max_size(), max_table_size));
 }
 
-void grpc_chttp2_hpack_compressor_destroy(grpc_chttp2_hpack_compressor* c) {
-  for (int i = 0; i < GRPC_CHTTP2_HPACKC_NUM_VALUES; i++) {
-    auto* const key = GetEntry<grpc_slice_refcount*>(c->key_table.entries, i);
-    if (key != nullptr) {
-      key->Unref();
+void HPackCompressor::SetMaxTableSize(uint32_t max_table_size) {
+  if (table_.SetMaxSize(std::min(max_usable_size_, max_table_size))) {
+    advertise_table_size_change_ = true;
+    if (GRPC_TRACE_FLAG_ENABLED(grpc_http_trace)) {
+      gpr_log(GPR_INFO, "set max table size from encoder to %d",
+              max_table_size);
     }
-    GRPC_MDELEM_UNREF(GetEntry<grpc_mdelem>(c->elem_table.entries, i));
   }
-  gpr_free(c->table_elem_size);
-}
-
-void grpc_chttp2_hpack_compressor_set_max_usable_size(
-    grpc_chttp2_hpack_compressor* c, uint32_t max_table_size) {
-  c->max_usable_size = max_table_size;
-  grpc_chttp2_hpack_compressor_set_max_table_size(
-      c, GPR_MIN(c->max_table_size, max_table_size));
 }
 
-static void rebuild_elems(grpc_chttp2_hpack_compressor* c, uint32_t new_cap) {
-  uint16_t* table_elem_size =
-      static_cast<uint16_t*>(gpr_malloc(sizeof(*table_elem_size) * new_cap));
-  uint32_t i;
-
-  memset(table_elem_size, 0, sizeof(*table_elem_size) * new_cap);
-  GPR_ASSERT(c->table_elems <= new_cap);
-
-  for (i = 0; i < c->table_elems; i++) {
-    uint32_t ofs = c->tail_remote_index + i + 1;
-    table_elem_size[ofs % new_cap] =
-        c->table_elem_size[ofs % c->cap_table_elems];
+HPackCompressor::Framer::Framer(const EncodeHeaderOptions& options,
+                                HPackCompressor* compressor,
+                                grpc_slice_buffer* output)
+    : max_frame_size_(options.max_frame_size),
+      use_true_binary_metadata_(options.use_true_binary_metadata),
+      is_end_of_stream_(options.is_end_of_stream),
+      stream_id_(options.stream_id),
+      output_(output),
+      stats_(options.stats),
+      compressor_(compressor),
+      prefix_(BeginFrame()) {
+  if (absl::exchange(compressor_->advertise_table_size_change_, false)) {
+    AdvertiseTableSizeChange();
   }
-
-  c->cap_table_elems = new_cap;
-  gpr_free(c->table_elem_size);
-  c->table_elem_size = table_elem_size;
 }
 
-void grpc_chttp2_hpack_compressor_set_max_table_size(
-    grpc_chttp2_hpack_compressor* c, uint32_t max_table_size) {
-  max_table_size = GPR_MIN(max_table_size, c->max_usable_size);
-  if (max_table_size == c->max_table_size) {
-    return;
-  }
-  while (c->table_size > 0 && c->table_size > max_table_size) {
-    evict_entry(c);
-  }
-  c->max_table_size = max_table_size;
-  c->max_table_elems = elems_for_bytes(max_table_size);
-  if (c->max_table_elems > c->cap_table_elems) {
-    rebuild_elems(c, GPR_MAX(c->max_table_elems, 2 * c->cap_table_elems));
-  } else if (c->max_table_elems < c->cap_table_elems / 3) {
-    uint32_t new_cap = GPR_MAX(c->max_table_elems, 16);
-    if (new_cap != c->cap_table_elems) {
-      rebuild_elems(c, new_cap);
+void HPackCompressor::Framer::Encode(grpc_mdelem md) {
+  if (GRPC_MDELEM_STORAGE(md) == GRPC_MDELEM_STORAGE_STATIC) {
+    const uintptr_t static_index =
+        reinterpret_cast<grpc_core::StaticMetadata*>(GRPC_MDELEM_DATA(md))
+            ->StaticIndex();
+    if (static_index < hpack_constants::kLastStaticEntry) {
+      EmitIndexed(static_cast<uint32_t>(static_index + 1));
+      return;
     }
   }
-  c->advertise_table_size_change = 1;
-  if (GRPC_TRACE_FLAG_ENABLED(grpc_http_trace)) {
-    gpr_log(GPR_INFO, "set max table size from encoder to %d", max_table_size);
-  }
+  EncodeDynamic(md);
 }
 
-void grpc_chttp2_encode_header(grpc_chttp2_hpack_compressor* c,
-                               grpc_mdelem** extra_headers,
-                               size_t extra_headers_size,
-                               grpc_metadata_batch* metadata,
-                               const grpc_encode_header_options* options,
-                               grpc_slice_buffer* outbuf) {
-  /* grpc_chttp2_encode_header is called by FlushInitial/TrailingMetadata in
-     writing.cc. Specifically, on streams returned by NextStream(), which
-     returns streams from the list GRPC_CHTTP2_LIST_WRITABLE. The only way to be
-     added to the list is via  grpc_chttp2_list_add_writable_stream(), which
-     validates that stream_id is not 0. So, this can be a debug assert. */
-  GPR_DEBUG_ASSERT(options->stream_id != 0);
-  framer_state st;
-#ifndef NDEBUG
-  st.seen_regular_header = 0;
-#endif
-  st.stream_id = options->stream_id;
-  st.output = outbuf;
-  st.is_first_frame = 1;
-  st.stats = options->stats;
-  st.max_frame_size = options->max_frame_size;
-  st.use_true_binary_metadata = options->use_true_binary_metadata;
-  st.is_end_of_stream = options->is_eof;
-
-  /* Encode a metadata batch; store the returned values, representing
-     a metadata element that needs to be unreffed back into the metadata
-     slot. THIS MAY NOT BE THE SAME ELEMENT (if a decoder table slot got
-     updated). After this loop, we'll do a batch unref of elements. */
-  begin_frame(&st);
-  if (c->advertise_table_size_change != 0) {
-    emit_advertise_table_size_change(c, &st);
-  }
-  for (size_t i = 0; i < extra_headers_size; ++i) {
-    grpc_mdelem md = *extra_headers[i];
-    const bool is_static =
-        GRPC_MDELEM_STORAGE(md) == GRPC_MDELEM_STORAGE_STATIC;
-    uintptr_t static_index;
-    if (is_static &&
-        (static_index =
-             reinterpret_cast<grpc_core::StaticMetadata*>(GRPC_MDELEM_DATA(md))
-                 ->StaticIndex()) < GRPC_CHTTP2_LAST_STATIC_ENTRY) {
-      emit_indexed(c, static_cast<uint32_t>(static_index + 1), &st);
-    } else {
-      hpack_enc(c, md, &st);
-    }
-  }
-  grpc_metadata_batch_assert_ok(metadata);
-  for (grpc_linked_mdelem* l = metadata->list.head; l; l = l->next) {
-    const bool is_static =
-        GRPC_MDELEM_STORAGE(l->md) == GRPC_MDELEM_STORAGE_STATIC;
-    uintptr_t static_index;
-    if (is_static &&
-        (static_index = reinterpret_cast<grpc_core::StaticMetadata*>(
-                            GRPC_MDELEM_DATA(l->md))
-                            ->StaticIndex()) < GRPC_CHTTP2_LAST_STATIC_ENTRY) {
-      emit_indexed(c, static_cast<uint32_t>(static_index + 1), &st);
-    } else {
-      hpack_enc(c, l->md, &st);
-    }
-  }
-  grpc_millis deadline = metadata->deadline;
-  if (deadline != GRPC_MILLIS_INF_FUTURE) {
-    deadline_enc(c, deadline, &st);
-  }
-
-  finish_frame(&st, 1);
-}
+}  // namespace grpc_core
index 5093f80..b2b4ee3 100644 (file)
 
 #include <grpc/slice.h>
 #include <grpc/slice_buffer.h>
+
 #include "src/core/ext/transport/chttp2/transport/frame.h"
+#include "src/core/ext/transport/chttp2/transport/hpack_encoder_index.h"
+#include "src/core/ext/transport/chttp2/transport/hpack_encoder_table.h"
+#include "src/core/ext/transport/chttp2/transport/popularity_count.h"
 #include "src/core/lib/transport/metadata.h"
 #include "src/core/lib/transport/metadata_batch.h"
 #include "src/core/lib/transport/transport.h"
 
-// This should be <= 8. We use 6 to save space.
-#define GRPC_CHTTP2_HPACKC_NUM_VALUES_BITS 6
-#define GRPC_CHTTP2_HPACKC_NUM_VALUES (1 << GRPC_CHTTP2_HPACKC_NUM_VALUES_BITS)
-/* initial table size, per spec */
-#define GRPC_CHTTP2_HPACKC_INITIAL_TABLE_SIZE 4096
-/* maximum table size we'll actually use */
-#define GRPC_CHTTP2_HPACKC_MAX_TABLE_SIZE (1024 * 1024)
-
 extern grpc_core::TraceFlag grpc_http_trace;
 
-struct grpc_chttp2_hpack_compressor {
-  uint32_t max_table_size;
-  uint32_t max_table_elems;
-  uint32_t cap_table_elems;
-  /** maximum number of bytes we'll use for the decode table (to guard against
-      peers ooming us by setting decode table size high) */
-  uint32_t max_usable_size;
-  /* one before the lowest usable table index */
-  uint32_t tail_remote_index;
-  uint32_t table_size;
-  uint32_t table_elems;
-  uint16_t* table_elem_size;
-  /** if non-zero, advertise to the decoder that we'll start using a table
-      of this size */
-  uint8_t advertise_table_size_change;
-
-  /* filter tables for elems: this tables provides an approximate
-     popularity count for particular hashes, and are used to determine whether
-     a new literal should be added to the compression table or not.
-     They track a single integer that counts how often a particular value has
-     been seen. When that count reaches max (255), all values are halved. */
-  uint32_t filter_elems_sum;
-  uint8_t filter_elems[GRPC_CHTTP2_HPACKC_NUM_VALUES];
-
-  /* entry tables for keys & elems: these tables track values that have been
-     seen and *may* be in the decompressor table */
-  struct {
-    struct {
-      grpc_mdelem value;
-      uint32_t index;
-    } entries[GRPC_CHTTP2_HPACKC_NUM_VALUES];
-  } elem_table; /* Metadata table management */
-  struct {
-    struct {
-      /* Only store the slice refcount - we do not need the byte buffer or
-         length of the slice since we only need to store a mapping between the
-         identity of the slice and the corresponding HPACK index. Since the
-         slice *must* be static or interned, the refcount is sufficient to
-         establish identity. */
-      grpc_slice_refcount* value;
-      uint32_t index;
-    } entries[GRPC_CHTTP2_HPACKC_NUM_VALUES];
-  } key_table; /* Key table management */
+namespace grpc_core {
+
+// Wrapper to take an array of mdelems and make them encodable
+class MetadataArray {
+ public:
+  MetadataArray(grpc_mdelem** elems, size_t count)
+      : elems_(elems), count_(count) {}
+
+  template <typename Encoder>
+  void Encode(Encoder* encoder) const {
+    for (size_t i = 0; i < count_; i++) {
+      encoder->Encode(*elems_[i]);
+    }
+  }
+
+ private:
+  grpc_mdelem** elems_;
+  size_t count_;
 };
 
-void grpc_chttp2_hpack_compressor_init(grpc_chttp2_hpack_compressor* c);
-void grpc_chttp2_hpack_compressor_destroy(grpc_chttp2_hpack_compressor* c);
-void grpc_chttp2_hpack_compressor_set_max_table_size(
-    grpc_chttp2_hpack_compressor* c, uint32_t max_table_size);
-void grpc_chttp2_hpack_compressor_set_max_usable_size(
-    grpc_chttp2_hpack_compressor* c, uint32_t max_table_size);
-
-struct grpc_encode_header_options {
-  uint32_t stream_id;
-  bool is_eof;
-  bool use_true_binary_metadata;
-  size_t max_frame_size;
-  grpc_transport_one_way_stats* stats;
+namespace metadata_detail {
+template <typename A, typename B>
+class ConcatMetadata {
+ public:
+  ConcatMetadata(const A& a, const B& b) : a_(a), b_(b) {}
+
+  template <typename Encoder>
+  void Encode(Encoder* encoder) const {
+    a_.Encode(encoder);
+    b_.Encode(encoder);
+  }
+
+ private:
+  const A& a_;
+  const B& b_;
 };
-void grpc_chttp2_encode_header(grpc_chttp2_hpack_compressor* c,
-                               grpc_mdelem** extra_headers,
-                               size_t extra_headers_size,
-                               grpc_metadata_batch* metadata,
-                               const grpc_encode_header_options* options,
-                               grpc_slice_buffer* outbuf);
+}  // namespace metadata_detail
+
+template <typename A, typename B>
+metadata_detail::ConcatMetadata<A, B> ConcatMetadata(const A& a, const B& b) {
+  return metadata_detail::ConcatMetadata<A, B>(a, b);
+}
+
+class HPackCompressor {
+ public:
+  HPackCompressor() = default;
+  ~HPackCompressor() = default;
+
+  // Maximum table size we'll actually use.
+  static constexpr uint32_t kMaxTableSize = 1024 * 1024;
+
+  void SetMaxTableSize(uint32_t max_table_size);
+  void SetMaxUsableSize(uint32_t max_table_size);
+
+  uint32_t test_only_table_size() const {
+    return table_.test_only_table_size();
+  }
+
+  struct EncodeHeaderOptions {
+    uint32_t stream_id;
+    bool is_end_of_stream;
+    bool use_true_binary_metadata;
+    size_t max_frame_size;
+    grpc_transport_one_way_stats* stats;
+  };
+
+  template <typename HeaderSet>
+  void EncodeHeaders(const EncodeHeaderOptions& options,
+                     const HeaderSet& headers, grpc_slice_buffer* output) {
+    Framer framer(options, this, output);
+    headers.Encode(&framer);
+  }
+
+  class Framer {
+   public:
+    Framer(const EncodeHeaderOptions& options, HPackCompressor* compressor,
+           grpc_slice_buffer* output);
+    ~Framer() { FinishFrame(true); }
+
+    Framer(const Framer&) = delete;
+    Framer& operator=(const Framer&) = delete;
+
+    void Encode(grpc_mdelem md);
+    void EncodeDeadline(grpc_millis deadline);
+
+   private:
+    struct FramePrefix {
+      // index (in output_) of the header for the frame
+      size_t header_idx;
+      // number of bytes in 'output' when we started the frame - used to
+      // calculate frame length
+      size_t output_length_at_start_of_frame;
+    };
+
+    FramePrefix BeginFrame();
+    void FinishFrame(bool is_header_boundary);
+    void EnsureSpace(size_t need_bytes);
+
+    void AdvertiseTableSizeChange();
+    void EmitIndexed(uint32_t index);
+    void EncodeDynamic(grpc_mdelem elem);
+    static GPR_ATTRIBUTE_NOINLINE void Log(grpc_mdelem elem);
+
+    void EmitLitHdrIncIdx(uint32_t key_index, grpc_mdelem elem);
+    void EmitLitHdrNotIdx(uint32_t key_index, grpc_mdelem elem);
+    void EmitLitHdrWithStringKeyIncIdx(grpc_mdelem elem);
+    void EmitLitHdrWithStringKeyNotIdx(grpc_mdelem elem);
+
+    size_t CurrentFrameSize() const;
+    void Add(grpc_slice slice);
+    uint8_t* AddTiny(size_t len);
+
+    // maximum size of a frame
+    const size_t max_frame_size_;
+    bool is_first_frame_ = true;
+    const bool use_true_binary_metadata_;
+    const bool is_end_of_stream_;
+    // output stream id
+    const uint32_t stream_id_;
+#ifndef NDEBUG
+    // have we seen a regular (non-colon-prefixed) header yet?
+    bool seen_regular_header_ = false;
+#endif
+    grpc_slice_buffer* const output_;
+    grpc_transport_one_way_stats* const stats_;
+    HPackCompressor* const compressor_;
+    FramePrefix prefix_;
+  };
+
+ private:
+  static constexpr size_t kNumFilterValues = 64;
+
+  void AddKeyWithIndex(grpc_slice_refcount* key_ref, uint32_t new_index,
+                       uint32_t key_hash);
+  void AddElemWithIndex(grpc_mdelem elem, uint32_t new_index,
+                        uint32_t elem_hash, uint32_t key_hash);
+  void AddElem(grpc_mdelem elem, size_t elem_size, uint32_t elem_hash,
+               uint32_t key_hash);
+  void AddKey(grpc_mdelem elem, size_t elem_size, uint32_t key_hash);
+
+  // maximum number of bytes we'll use for the decode table (to guard against
+  // peers ooming us by setting decode table size high)
+  uint32_t max_usable_size_ = hpack_constants::kInitialTableSize;
+  // if non-zero, advertise to the decoder that we'll start using a table
+  // of this size
+  bool advertise_table_size_change_ = false;
+  HPackEncoderTable table_;
+
+  // filter tables for elems: this tables provides an approximate
+  // popularity count for particular hashes, and are used to determine whether
+  // a new literal should be added to the compression table or not.
+  // They track a single integer that counts how often a particular value has
+  // been seen. When that count reaches max (255), all values are halved.
+  grpc_core::PopularityCount<kNumFilterValues> filter_elems_;
+
+  class KeyElem {
+   public:
+    class Stored {
+     public:
+      Stored() : elem_(GRPC_MDNULL) {}
+      explicit Stored(grpc_mdelem elem) : elem_(GRPC_MDELEM_REF(elem)) {}
+      Stored(const Stored& other) : elem_(GRPC_MDELEM_REF(other.elem_)) {}
+      Stored& operator=(Stored other) {
+        std::swap(elem_, other.elem_);
+        return *this;
+      }
+      ~Stored() { GRPC_MDELEM_UNREF(elem_); }
+
+      const grpc_mdelem& elem() const { return elem_; }
+
+      bool operator==(const Stored& other) const noexcept {
+        return elem_.payload == other.elem_.payload;
+      }
+
+     private:
+      grpc_mdelem elem_;
+    };
+
+    KeyElem(grpc_mdelem elem, uint32_t hash) : elem_(elem), hash_(hash) {}
+    KeyElem(const KeyElem&);
+    KeyElem& operator=(const KeyElem&);
+
+    uint32_t hash() const {
+      // TODO(ctiller): unify this with what's in the cc file when we move this
+      // code to c++
+      return hash_ >> 6;
+    }
+
+    Stored stored() const { return Stored(elem_); }
+
+    bool operator==(const Stored& stored) const noexcept {
+      return elem_.payload == stored.elem().payload;
+    }
+
+   private:
+    grpc_mdelem elem_;
+    uint32_t hash_;
+  };
+
+  class KeySliceRef {
+   public:
+    using Stored = grpc_core::RefCountedPtr<grpc_slice_refcount>;
+
+    KeySliceRef(grpc_slice_refcount* ref, uint32_t hash)
+        : ref_(ref), hash_(hash) {}
+    KeySliceRef(const KeySliceRef&) = delete;
+    KeySliceRef& operator=(const KeySliceRef&) = delete;
+
+    uint32_t hash() const {
+      // TODO(ctiller): unify this with what's in the cc file when we move this
+      // code to c++
+      return hash_ >> 6;
+    }
+
+    Stored stored() const {
+      ref_->Ref();
+      return Stored(ref_);
+    }
+
+    bool operator==(const Stored& stored) const noexcept {
+      return ref_ == stored.get();
+    }
+
+   private:
+    grpc_slice_refcount* ref_;
+    uint32_t hash_;
+  };
+
+  // entry tables for keys & elems: these tables track values that have been
+  // seen and *may* be in the decompressor table
+  grpc_core::HPackEncoderIndex<KeyElem, kNumFilterValues> elem_index_;
+  grpc_core::HPackEncoderIndex<KeySliceRef, kNumFilterValues> key_index_;
+};
+
+}  // namespace grpc_core
 
 #endif /* GRPC_CORE_EXT_TRANSPORT_CHTTP2_TRANSPORT_HPACK_ENCODER_H */
diff --git a/src/core/ext/transport/chttp2/transport/hpack_encoder_index.h b/src/core/ext/transport/chttp2/transport/hpack_encoder_index.h
new file mode 100644 (file)
index 0000000..232d3df
--- /dev/null
@@ -0,0 +1,107 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#ifndef GRPC_CORE_EXT_TRANSPORT_CHTTP2_TRANSPORT_HPACK_ENCODER_INDEX_H
+#define GRPC_CORE_EXT_TRANSPORT_CHTTP2_TRANSPORT_HPACK_ENCODER_INDEX_H
+
+#include <grpc/impl/codegen/port_platform.h>
+
+#include "absl/types/optional.h"
+
+namespace grpc_core {
+
+// A fixed size mapping of a key to a chronologically ordered index
+template <typename Key, size_t kNumEntries>
+class HPackEncoderIndex {
+ public:
+  using Index = uint32_t;
+
+  HPackEncoderIndex() : entries_{} {}
+
+  // If key exists in the table, update it to a new index.
+  // If it does not and there is an empty slot, add it to the index.
+  // Finally, if it does not and there is no empty slot, evict the oldest
+  // conflicting member.
+  void Insert(const Key& key, Index new_index) {
+    auto* const cuckoo_first = first_slot(key);
+    if (cuckoo_first->UpdateOrAdd(key, new_index)) return;
+    auto* const cuckoo_second = second_slot(key);
+    if (cuckoo_second->UpdateOrAdd(key, new_index)) return;
+    auto* const clobber = Older(cuckoo_first, cuckoo_second);
+    clobber->key = key.stored();
+    clobber->index = new_index;
+  }
+
+  // Lookup key and return its index, or return empty if it's not in this table.
+  absl::optional<Index> Lookup(const Key& key) {
+    auto* const cuckoo_first = first_slot(key);
+    if (key == cuckoo_first->key) return cuckoo_first->index;
+    auto* const cuckoo_second = second_slot(key);
+    if (key == cuckoo_second->key) return cuckoo_second->index;
+    return {};
+  }
+
+ private:
+  using StoredKey = typename Key::Stored;
+
+  // One entry in the index
+  struct Entry {
+    Entry() : key{}, index{} {};
+
+    StoredKey key;
+    Index index;
+
+    // Update this entry if it matches key, otherwise if it's empty add it.
+    // If neither happens, return false.
+    bool UpdateOrAdd(const Key& new_key, Index new_index) {
+      if (new_key == key) {
+        index = new_index;
+        return true;
+      } else if (key == StoredKey()) {
+        key = new_key.stored();
+        index = new_index;
+        return true;
+      } else {
+        return false;
+      }
+    }
+  };
+
+  static Entry* Older(Entry* a, Entry* b) {
+    if (a->index < b->index) {
+      return a;
+    } else {
+      return b;
+    }
+  }
+
+  // Return the first slot in which key could be stored.
+  Entry* first_slot(const Key& key) {
+    return &entries_[key.hash() % kNumEntries];
+  }
+
+  // Return the second slot in which key could be stored.
+  Entry* second_slot(const Key& key) {
+    return &entries_[(key.hash() / kNumEntries) % kNumEntries];
+  }
+
+  // Fixed size entry map.
+  // We store each key/value pair in two slots based on it's hash value.
+  // They can be evicted individually.
+  Entry entries_[kNumEntries];
+};
+
+}  // namespace grpc_core
+
+#endif  // GRPC_CORE_EXT_TRANSPORT_CHTTP2_TRANSPORT_HPACK_ENCODER_INDEX_H
diff --git a/src/core/ext/transport/chttp2/transport/hpack_encoder_table.cc b/src/core/ext/transport/chttp2/transport/hpack_encoder_table.cc
new file mode 100644 (file)
index 0000000..bfe152a
--- /dev/null
@@ -0,0 +1,86 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#include <grpc/support/port_platform.h>
+
+#include "src/core/ext/transport/chttp2/transport/hpack_encoder_table.h"
+
+#include <grpc/support/log.h>
+
+namespace grpc_core {
+
+uint32_t HPackEncoderTable::AllocateIndex(size_t element_size) {
+  uint32_t new_index = tail_remote_index_ + table_elems_ + 1;
+  GPR_DEBUG_ASSERT(element_size < 65536);
+
+  if (element_size > max_table_size_) {
+    while (table_size_ > 0) {
+      EvictOne();
+    }
+    return 0;
+  }
+
+  // Reserve space for this element in the remote table: if this overflows
+  // the current table, drop elements until it fits, matching the decompressor
+  // algorithm.
+  while (table_size_ + element_size > max_table_size_) {
+    EvictOne();
+  }
+  GPR_ASSERT(table_elems_ < elem_size_.size());
+  elem_size_[new_index % elem_size_.size()] =
+      static_cast<uint16_t>(element_size);
+  table_size_ += element_size;
+  table_elems_++;
+
+  return new_index;
+}
+
+bool HPackEncoderTable::SetMaxSize(uint32_t max_table_size) {
+  if (max_table_size == max_table_size_) {
+    return false;
+  }
+  while (table_size_ > 0 && table_size_ > max_table_size) {
+    EvictOne();
+  }
+  max_table_size_ = max_table_size;
+  const size_t max_table_elems =
+      hpack_constants::EntriesForBytes(max_table_size);
+  // TODO(ctiller): integrate with ResourceQuota to rebuild smaller when we can.
+  if (max_table_elems > elem_size_.size()) {
+    Rebuild(std::max(max_table_elems, 2 * elem_size_.size()));
+  }
+  return true;
+}
+
+void HPackEncoderTable::EvictOne() {
+  tail_remote_index_++;
+  GPR_ASSERT(tail_remote_index_ > 0);
+  GPR_ASSERT(table_elems_ > 0);
+  auto removing_size = elem_size_[tail_remote_index_ % elem_size_.size()];
+  GPR_ASSERT(table_size_ >= removing_size);
+  table_size_ -= removing_size;
+  table_elems_--;
+}
+
+void HPackEncoderTable::Rebuild(uint32_t capacity) {
+  decltype(elem_size_) new_elem_size(capacity);
+  GPR_ASSERT(table_elems_ <= capacity);
+  for (uint32_t i = 0; i < table_elems_; i++) {
+    uint32_t ofs = tail_remote_index_ + i + 1;
+    new_elem_size[ofs % capacity] = elem_size_[ofs % elem_size_.size()];
+  }
+  elem_size_.swap(new_elem_size);
+}
+
+}  // namespace grpc_core
diff --git a/src/core/ext/transport/chttp2/transport/hpack_encoder_table.h b/src/core/ext/transport/chttp2/transport/hpack_encoder_table.h
new file mode 100644 (file)
index 0000000..ca66923
--- /dev/null
@@ -0,0 +1,69 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#ifndef GRPC_CORE_EXT_TRANSPORT_CHTTP2_TRANSPORT_HPACK_ENCODER_TABLE_H
+#define GRPC_CORE_EXT_TRANSPORT_CHTTP2_TRANSPORT_HPACK_ENCODER_TABLE_H
+
+#include <grpc/support/port_platform.h>
+
+#include "absl/container/inlined_vector.h"
+
+#include "src/core/ext/transport/chttp2/transport/hpack_constants.h"
+
+namespace grpc_core {
+
+// Tracks the values available in the remote HPACK header table, and their
+// sizes.
+class HPackEncoderTable {
+ public:
+  HPackEncoderTable() : elem_size_(hpack_constants::kInitialTableEntries) {}
+
+  // Reserve space in table for the new element, evict entries if needed.
+  // Return the new index of the element. Return 0 to indicate not adding to
+  // table.
+  uint32_t AllocateIndex(size_t element_size);
+  // Set the maximum table size. Return true if it changed.
+  bool SetMaxSize(uint32_t max_table_size);
+  // Get the current max table size
+  uint32_t max_size() const { return max_table_size_; }
+  // Get the current table size
+  uint32_t test_only_table_size() const { return table_size_; }
+
+  // Convert an element index into a dynamic index
+  uint32_t DynamicIndex(uint32_t index) const {
+    return 1 + hpack_constants::kLastStaticEntry + tail_remote_index_ +
+           table_elems_ - index;
+  }
+  // Check if an element index is convertable to a dynamic index
+  bool ConvertableToDynamicIndex(uint32_t index) const {
+    return index > tail_remote_index_;
+  }
+
+ private:
+  void EvictOne();
+  void Rebuild(uint32_t capacity);
+
+  // one before the lowest usable table index
+  uint32_t tail_remote_index_ = 0;
+  uint32_t max_table_size_ = hpack_constants::kInitialTableSize;
+  uint32_t table_elems_ = 0;
+  uint32_t table_size_ = 0;
+  // The size of each element in the HPACK table.
+  absl::InlinedVector<uint16_t, hpack_constants::kInitialTableEntries>
+      elem_size_;
+};
+
+}  // namespace grpc_core
+
+#endif  // GRPC_CORE_EXT_TRANSPORT_CHTTP2_TRANSPORT_HPACK_ENCODER_TABLE_H
index 3d6e1aa..09681fa 100644 (file)
@@ -19,7 +19,6 @@
 #include <grpc/support/port_platform.h>
 
 #include "src/core/ext/transport/chttp2/transport/hpack_parser.h"
-#include "src/core/ext/transport/chttp2/transport/internal.h"
 
 #include <assert.h>
 #include <stddef.h>
 #include <grpc/support/log.h>
 
 #include "src/core/ext/transport/chttp2/transport/bin_encoder.h"
+#include "src/core/ext/transport/chttp2/transport/internal.h"
 #include "src/core/lib/debug/stats.h"
 #include "src/core/lib/gpr/string.h"
+#include "src/core/lib/gprpp/match.h"
 #include "src/core/lib/profiling/timers.h"
 #include "src/core/lib/slice/slice_internal.h"
 #include "src/core/lib/slice/slice_string_helpers.h"
@@ -52,20 +53,6 @@ namespace grpc_core {
 
 DebugOnlyTraceFlag grpc_trace_chttp2_hpack_parser(false, "chttp2_hpack_parser");
 
-/* How parsing works:
-
-   The parser object keeps track of a function pointer which represents the
-   current parse state.
-
-   Each time new bytes are presented, we call into the current state, which
-   recursively parses until all bytes in the given chunk are exhausted.
-
-   The parse state that terminates then saves its function pointer to be the
-   current state so that it can resume when more bytes are available.
-
-   It's expected that most optimizing compilers will turn this code into
-   a set of indirect jumps, and so not waste stack space. */
-
 /* state table for huffman decoding: given a state, gives an index/16 into
    next_sub_tbl. Taking that index and adding the value of the nibble being
    considered returns the next state.
@@ -464,1121 +451,877 @@ struct Base64InverseTable {
 static GRPC_HPACK_CONSTEXPR_VALUE Base64InverseTable kBase64InverseTable;
 }  // namespace
 
-void HPackParser::FinishFrame() {
-  sink_ = Sink();
-  dynamic_table_updates_allowed_ = 2;
-}
-
-void GPR_ATTRIBUTE_NOINLINE HPackParser::LogHeader(grpc_mdelem md) {
-  char* k = grpc_slice_to_c_string(GRPC_MDKEY(md));
-  char* v = nullptr;
-  if (grpc_is_binary_header_internal(GRPC_MDKEY(md))) {
-    v = grpc_dump_slice(GRPC_MDVALUE(md), GPR_DUMP_HEX);
-  } else {
-    v = grpc_slice_to_c_string(GRPC_MDVALUE(md));
+// Input tracks the current byte through the input data and provides it
+// via a simple stream interface.
+class HPackParser::Input {
+ public:
+  Input(grpc_slice_refcount* current_slice_refcount, const uint8_t* begin,
+        const uint8_t* end)
+      : current_slice_refcount_(current_slice_refcount),
+        begin_(begin),
+        end_(end),
+        frontier_(begin) {}
+
+  // If input is backed by a slice, retrieve its refcount. If not, return
+  // nullptr.
+  grpc_slice_refcount* slice_refcount() { return current_slice_refcount_; }
+
+  // Have we reached the end of input?
+  bool end_of_stream() const { return begin_ == end_; }
+  // How many bytes until end of input
+  size_t remaining() const { return end_ - begin_; }
+  // Current position, as a pointer
+  const uint8_t* cur_ptr() const { return begin_; }
+  // End position, as a pointer
+  const uint8_t* end_ptr() const { return end_; }
+  // Move read position forward by n, unchecked
+  void Advance(size_t n) { begin_ += n; }
+
+  // Retrieve the current character, or nullopt if end of stream
+  // Do not advance
+  absl::optional<uint8_t> peek() const {
+    if (end_of_stream()) {
+      return {};
+    }
+    return *begin_;
   }
-  gpr_log(
-      GPR_INFO,
-      "Decode: '%s: %s', elem_interned=%d [%d], k_interned=%d, v_interned=%d",
-      k, v, GRPC_MDELEM_IS_INTERNED(md), GRPC_MDELEM_STORAGE(md),
-      grpc_slice_is_interned(GRPC_MDKEY(md)),
-      grpc_slice_is_interned(GRPC_MDVALUE(md)));
-  gpr_free(k);
-  gpr_free(v);
-}
 
-/* emission helpers */
-template <HPackParser::TableAction action>
-grpc_error_handle HPackParser::FinishHeader(grpc_mdelem md) {
-  if (GRPC_TRACE_FLAG_ENABLED(grpc_trace_chttp2_hpack_parser)) {
-    LogHeader(md);
-  }
-  if (action == TableAction::kAddToTable) {
-    GPR_DEBUG_ASSERT(GRPC_MDELEM_STORAGE(md) == GRPC_MDELEM_STORAGE_INTERNED ||
-                     GRPC_MDELEM_STORAGE(md) == GRPC_MDELEM_STORAGE_STATIC);
-    grpc_error_handle err = grpc_chttp2_hptbl_add(&table_, md);
-    if (GPR_UNLIKELY(err != GRPC_ERROR_NONE)) return err;
+  // Retrieve and advance past the current character, or return nullopt if end
+  // of stream
+  absl::optional<uint8_t> Next() {
+    if (end_of_stream()) {
+      return UnexpectedEOF(absl::optional<uint8_t>());
+    }
+    return *begin_++;
   }
-  return sink_(md);
-}
 
-UnmanagedMemorySlice HPackParser::String::TakeExtern() {
-  UnmanagedMemorySlice s;
-  if (!copied_) {
-    GPR_DEBUG_ASSERT(!grpc_slice_is_interned(data_.referenced));
-    s = static_cast<UnmanagedMemorySlice&>(data_.referenced);
-    copied_ = true;
-    data_.referenced = UnmanagedMemorySlice();
-  } else {
-    s = UnmanagedMemorySlice(data_.copied.str, data_.copied.length);
+  // Helper to parse a varint delta on top of value, return nullopt on failure
+  // (setting error)
+  absl::optional<uint32_t> ParseVarint(uint32_t value) {
+    // TODO(ctiller): break out a variant of this when we know there are at
+    // least 5 bytes in input_
+    auto cur = Next();
+    if (!cur) return {};
+    value += *cur & 0x7f;
+    if ((*cur & 0x80) == 0) return value;
+
+    cur = Next();
+    if (!cur) return {};
+    value += (*cur & 0x7f) << 7;
+    if ((*cur & 0x80) == 0) return value;
+
+    cur = Next();
+    if (!cur) return {};
+    value += (*cur & 0x7f) << 14;
+    if ((*cur & 0x80) == 0) return value;
+
+    cur = Next();
+    if (!cur) return {};
+    value += (*cur & 0x7f) << 21;
+    if ((*cur & 0x80) == 0) return value;
+
+    cur = Next();
+    if (!cur) return {};
+    uint32_t c = (*cur) & 0x7f;
+    // We might overflow here, so we need to be a little careful about the
+    // addition
+    if (c > 0xf) return ParseVarintOutOfRange(value, *cur);
+    const uint32_t add = c << 28;
+    if (add > 0xffffffffu - value) {
+      return ParseVarintOutOfRange(value, *cur);
+    }
+    value += add;
+    if ((*cur & 0x80) == 0) return value;
+
+    // Spec weirdness: we can add an infinite stream of 0x80 at the end of a
+    // varint and still end up with a correctly encoded varint.
+    do {
+      cur = Next();
+      if (!cur.has_value()) return {};
+    } while (*cur == 0x80);
+
+    // BUT... the last byte needs to be 0x00 or we'll overflow dramatically!
+    if (*cur == 0) return value;
+    return ParseVarintOutOfRange(value, *cur);
   }
-  data_.copied.length = 0;
-  return s;
-}
 
-ManagedMemorySlice HPackParser::String::TakeIntern() {
-  ManagedMemorySlice s;
-  if (!copied_) {
-    s = ManagedMemorySlice(&data_.referenced);
-    grpc_slice_unref_internal(data_.referenced);
-    copied_ = true;
-    data_.referenced = grpc_empty_slice();
-  } else {
-    s = ManagedMemorySlice(data_.copied.str, data_.copied.length);
+  // Prefix for a string
+  struct StringPrefix {
+    // Number of bytes in input for string
+    uint32_t length;
+    // Is it huffman compressed
+    bool huff;
+  };
+
+  // Parse a string prefix
+  absl::optional<StringPrefix> ParseStringPrefix() {
+    auto cur = Next();
+    if (!cur.has_value()) return {};
+    // Huffman if the top bit is 1
+    const bool huff = (*cur & 0x80) != 0;
+    // String length
+    uint32_t strlen = (*cur & 0x7f);
+    if (strlen == 0x7f) {
+      // all ones ==> varint string length
+      auto v = ParseVarint(0x7f);
+      if (!v.has_value()) return {};
+      strlen = *v;
+    }
+    return StringPrefix{strlen, huff};
   }
-  data_.copied.length = 0;
-  return s;
-}
 
-grpc_error_handle HPackParser::parse_next(const uint8_t* cur,
-                                          const uint8_t* end) {
-  state_ = *next_state_++;
-  return (this->*state_)(cur, end);
-}
+  // Check if we saw an EOF.. must be verified before looking at TakeError
+  bool eof_error() const { return eof_error_; }
 
-/* begin parsing a header: all functionality is encoded into lookup tables
-   above */
-grpc_error_handle HPackParser::parse_begin(const uint8_t* cur,
-                                           const uint8_t* end) {
-  if (cur == end) {
-    state_ = &HPackParser::parse_begin;
-    return GRPC_ERROR_NONE;
+  // Extract the parse error, leaving the current error as NONE.
+  grpc_error_handle TakeError() {
+    grpc_error_handle out = error_;
+    error_ = GRPC_ERROR_NONE;
+    return out;
   }
 
-  switch (*cur >> 4) {
-      // Literal header not indexed.
-      // First byte format: 0000xxxx
-      // Where xxxx:
-      //   0000  - literal key
-      //   1111  - indexed key, varint encoded index
-      //   other - indexed key, inline encoded index
-    case 0:
-      switch (*cur & 0xf) {
-        case 0:  // literal key
-          return parse_lithdr_notidx_v(cur, end);
-        case 0xf:  // varint encoded key index
-          return parse_lithdr_notidx_x(cur, end);
-        default:  // inline encoded key index
-          return parse_lithdr_notidx(cur, end);
-      }
-      // Literal header never indexed.
-      // First byte format: 0001xxxx
-      // Where xxxx:
-      //   0000  - literal key
-      //   1111  - indexed key, varint encoded index
-      //   other - indexed key, inline encoded index
-    case 1:
-      switch (*cur & 0xf) {
-        case 0:  // literal key
-          return parse_lithdr_nvridx_v(cur, end);
-        case 0xf:  // varint encoded key index
-          return parse_lithdr_nvridx_x(cur, end);
-        default:  // inline encoded key index
-          return parse_lithdr_nvridx(cur, end);
-      }
-      // Update max table size.
-      // First byte format: 001xxxxx
-      // Where xxxxx:
-      //   11111 - max size is varint encoded
-      //   other - max size is stored inline
-    case 2:
-      // inline encoded max table size
-      return parse_max_tbl_size(cur, end);
-    case 3:
-      if (*cur == 0x3f) {
-        // varint encoded max table size
-        return parse_max_tbl_size_x(cur, end);
-      } else {
-        // inline encoded max table size
-        return parse_max_tbl_size(cur, end);
-      }
-      // Literal header with incremental indexing.
-      // First byte format: 01xxxxxx
-      // Where xxxxxx:
-      //   000000 - literal key
-      //   111111 - indexed key, varint encoded index
-      //   other  - indexed key, inline encoded index
-    case 4:
-      if (*cur == 0x40) {
-        // literal key
-        return parse_lithdr_incidx_v(cur, end);
-      }
-      ABSL_FALLTHROUGH_INTENDED;
-    case 5:
-    case 6:
-      // inline encoded key index
-      return parse_lithdr_incidx(cur, end);
-    case 7:
-      if (*cur == 0x7f) {
-        // varint encoded key index
-        return parse_lithdr_incidx_x(cur, end);
-      } else {
-        // inline encoded key index
-        return parse_lithdr_incidx(cur, end);
-      }
-      // Indexed Header Field Representation
-      // First byte format: 1xxxxxxx
-      // Where xxxxxxx:
-      //   0000000 - illegal
-      //   1111111 - varint encoded field index
-      //   other   - inline encoded field index
-    case 8:
-      if (*cur == 0x80) {
-        // illegal value.
-        return parse_illegal_op(cur, end);
-      }
-      ABSL_FALLTHROUGH_INTENDED;
-    case 9:
-    case 10:
-    case 11:
-    case 12:
-    case 13:
-    case 14:
-      // inline encoded field index
-      return parse_indexed_field(cur, end);
-    case 15:
-      if (*cur == 0xff) {
-        // varint encoded field index
-        return parse_indexed_field_x(cur, end);
-      } else {
-        // inline encoded field index
-        return parse_indexed_field(cur, end);
-      }
+  // Set the current error - allows the rest of the code not to need to pass
+  // around StatusOr<> which would be prohibitive here.
+  GPR_ATTRIBUTE_NOINLINE void SetError(grpc_error_handle error) {
+    if (error_ != GRPC_ERROR_NONE || eof_error_) {
+      GRPC_ERROR_UNREF(error);
+      return;
+    }
+    error_ = error;
+    begin_ = end_;
   }
-  GPR_UNREACHABLE_CODE(abort());
-}
 
-/* stream dependency and prioritization data: we just skip it */
-grpc_error_handle HPackParser::parse_stream_weight(const uint8_t* cur,
-                                                   const uint8_t* end) {
-  if (cur == end) {
-    state_ = &HPackParser::parse_stream_weight;
-    return GRPC_ERROR_NONE;
+  // If no error is set, set it to the value produced by error_factory.
+  // Return return_value unchanged.
+  template <typename F, typename T>
+  GPR_ATTRIBUTE_NOINLINE T MaybeSetErrorAndReturn(F error_factory,
+                                                  T return_value) {
+    if (error_ != GRPC_ERROR_NONE || eof_error_) return return_value;
+    error_ = error_factory();
+    begin_ = end_;
+    return return_value;
   }
 
-  return (this->*after_prioritization_)(cur + 1, end);
-}
-
-grpc_error_handle HPackParser::parse_stream_dep3(const uint8_t* cur,
-                                                 const uint8_t* end) {
-  if (cur == end) {
-    state_ = &HPackParser::parse_stream_dep3;
-    return GRPC_ERROR_NONE;
+  // Set the error to an unexpected eof, and return result (code golfed as this
+  // is a common case)
+  template <typename T>
+  T UnexpectedEOF(T return_value) {
+    if (error_ != GRPC_ERROR_NONE) return return_value;
+    eof_error_ = true;
+    return return_value;
   }
 
-  return parse_stream_weight(cur + 1, end);
-}
-
-grpc_error_handle HPackParser::parse_stream_dep2(const uint8_t* cur,
-                                                 const uint8_t* end) {
-  if (cur == end) {
-    state_ = &HPackParser::parse_stream_dep2;
-    return GRPC_ERROR_NONE;
+  // Update the frontier - signifies we've successfully parsed another element
+  void UpdateFrontier() { frontier_ = begin_; }
+
+  // Get the frontier - for buffering should we fail due to eof
+  const uint8_t* frontier() const { return frontier_; }
+
+ private:
+  // Helper to set the error to out of range for ParseVarint
+  absl::optional<uint32_t> ParseVarintOutOfRange(uint32_t value,
+                                                 uint8_t last_byte) {
+    return MaybeSetErrorAndReturn(
+        [value, last_byte] {
+          return GRPC_ERROR_CREATE_FROM_CPP_STRING(absl::StrFormat(
+              "integer overflow in hpack integer decoding: have 0x%08x, "
+              "got byte 0x%02x on byte 5",
+              value, last_byte));
+        },
+        absl::optional<uint32_t>());
   }
 
-  return parse_stream_dep3(cur + 1, end);
-}
+  // Refcount if we are backed by a slice
+  grpc_slice_refcount* current_slice_refcount_;
+  // Current input point
+  const uint8_t* begin_;
+  // End of stream point
+  const uint8_t* const end_;
+  // Frontier denotes the first byte past successfully processed input
+  const uint8_t* frontier_;
+  // Current error
+  grpc_error_handle error_ = GRPC_ERROR_NONE;
+  // If the error was EOF, we flag it here..
+  bool eof_error_ = false;
+};
 
-grpc_error_handle HPackParser::parse_stream_dep1(const uint8_t* cur,
-                                                 const uint8_t* end) {
-  if (cur == end) {
-    state_ = &HPackParser::parse_stream_dep1;
-    return GRPC_ERROR_NONE;
+// Helper to parse a string and turn it into a slice with appropriate memory
+// management characteristics
+class HPackParser::String {
+ public:
+  // Helper to specify a string should be internalized
+  struct Intern {};
+  // Helper to specify a string should be externalized
+  struct Extern {};
+
+ private:
+  // Forward declare take functions... we'll need them in the public interface
+  UnmanagedMemorySlice Take(Extern);
+  ManagedMemorySlice Take(Intern);
+
+ public:
+  // If a String is a Slice then unref
+  ~String() {
+    if (auto* p = absl::get_if<grpc_slice>(&value_)) {
+      grpc_slice_unref_internal(*p);
+    }
   }
 
-  return parse_stream_dep2(cur + 1, end);
-}
-
-grpc_error_handle HPackParser::parse_stream_dep0(const uint8_t* cur,
-                                                 const uint8_t* end) {
-  if (cur == end) {
-    state_ = &HPackParser::parse_stream_dep0;
-    return GRPC_ERROR_NONE;
+  // Take the value and leave this empty
+  // Use Intern/Extern to choose memory management
+  template <typename T>
+  auto Take() -> decltype(this->Take(T())) {
+    return Take(T());
   }
 
-  return parse_stream_dep1(cur + 1, end);
-}
-
-grpc_error_handle HPackParser::InvalidHPackIndexError() {
-  return grpc_error_set_int(
-      grpc_error_set_int(
-          GRPC_ERROR_CREATE_FROM_STATIC_STRING("Invalid HPACK index received"),
-          GRPC_ERROR_INT_INDEX, static_cast<intptr_t>(index_)),
-      GRPC_ERROR_INT_SIZE, static_cast<intptr_t>(table_.num_ents));
-}
-
-/* emit an indexed field; jumps to begin the next field on completion */
-grpc_error_handle HPackParser::finish_indexed_field(const uint8_t* cur,
-                                                    const uint8_t* end) {
-  grpc_mdelem md = grpc_chttp2_hptbl_lookup<true>(&table_, index_);
-  if (GPR_UNLIKELY(GRPC_MDISNULL(md))) {
-    return InvalidHPackIndexError();
+  String(const String&) = delete;
+  String& operator=(const String&) = delete;
+  String(String&& other) noexcept : value_(std::move(other.value_)) {
+    other.value_ = absl::Span<const uint8_t>();
   }
-  GRPC_STATS_INC_HPACK_RECV_INDEXED();
-  grpc_error_handle err = FinishHeader<TableAction::kOmitFromTable>(md);
-  if (GPR_UNLIKELY(err != GRPC_ERROR_NONE)) return err;
-  return parse_begin(cur, end);
-}
-
-/* parse an indexed field with index < 127 */
-grpc_error_handle HPackParser::parse_indexed_field(const uint8_t* cur,
-                                                   const uint8_t* end) {
-  dynamic_table_updates_allowed_ = 0;
-  index_ = (*cur) & 0x7f;
-  md_for_index_.payload = 0; /* Invalidate cached md when index changes. */
-  return finish_indexed_field(cur + 1, end);
-}
-
-/* parse an indexed field with index >= 127 */
-grpc_error_handle HPackParser::parse_indexed_field_x(const uint8_t* cur,
-                                                     const uint8_t* end) {
-  static const State and_then[] = {&HPackParser::finish_indexed_field};
-  dynamic_table_updates_allowed_ = 0;
-  next_state_ = and_then;
-  index_ = 0x7f;
-  md_for_index_.payload = 0; /* Invalidate cached md when index changes. */
-  parsing_.value = &index_;
-  return parse_value0(cur + 1, end);
-}
-
-/* When finishing with a header, get the cached md element for this index.
-   This is set in parse_value_string(). We ensure (in debug mode) that the
-   cached metadata corresponds with the index we are examining. */
-grpc_mdelem HPackParser::GetPrecomputedMDForIndex() {
-  GPR_DEBUG_ASSERT(md_for_index_.payload != 0);
-  GPR_DEBUG_ASSERT(static_cast<int64_t>(index_) == precomputed_md_index_);
-  grpc_mdelem md = md_for_index_;
-  GPR_DEBUG_ASSERT(!GRPC_MDISNULL(md)); /* handled in string parsing */
-  md_for_index_.payload = 0; /* Invalidate cached md when index changes. */
-#ifndef NDEBUG
-  precomputed_md_index_ = -1;
-#endif
-  return md;
-}
-
-static const grpc_core::ManagedMemorySlice& get_indexed_key(grpc_mdelem md) {
-  GPR_DEBUG_ASSERT(GRPC_MDELEM_IS_INTERNED(md));
-  return static_cast<const grpc_core::ManagedMemorySlice&>(
-      grpc_slice_ref_internal(GRPC_MDKEY(md)));
-}
-
-/* finish a literal header with incremental indexing */
-grpc_error_handle HPackParser::finish_lithdr_incidx(const uint8_t* cur,
-                                                    const uint8_t* end) {
-  GRPC_STATS_INC_HPACK_RECV_LITHDR_INCIDX();
-  grpc_mdelem md = GetPrecomputedMDForIndex();
-  grpc_error_handle err = FinishHeader<TableAction::kAddToTable>(
-      grpc_mdelem_from_slices(get_indexed_key(md), value_.TakeIntern()));
-  if (err != GRPC_ERROR_NONE) return parse_error(cur, end, err);
-  return parse_begin(cur, end);
-}
-
-/* finish a literal header with incremental indexing with no index */
-grpc_error_handle HPackParser::finish_lithdr_incidx_v(const uint8_t* cur,
-                                                      const uint8_t* end) {
-  GRPC_STATS_INC_HPACK_RECV_LITHDR_INCIDX_V();
-  grpc_error_handle err = FinishHeader<TableAction::kAddToTable>(
-      grpc_mdelem_from_slices(key_.TakeIntern(), value_.TakeIntern()));
-  if (err != GRPC_ERROR_NONE) return parse_error(cur, end, err);
-  return parse_begin(cur, end);
-}
-
-/* parse a literal header with incremental indexing; index < 63 */
-grpc_error_handle HPackParser::parse_lithdr_incidx(const uint8_t* cur,
-                                                   const uint8_t* end) {
-  static const State and_then[] = {
-      &HPackParser::parse_value_string_with_indexed_key,
-      &HPackParser::finish_lithdr_incidx};
-  dynamic_table_updates_allowed_ = 0;
-  next_state_ = and_then;
-  index_ = (*cur) & 0x3f;
-  md_for_index_.payload = 0; /* Invalidate cached md when index changes. */
-  return parse_string_prefix(cur + 1, end);
-}
-
-/* parse a literal header with incremental indexing; index >= 63 */
-grpc_error_handle HPackParser::parse_lithdr_incidx_x(const uint8_t* cur,
-                                                     const uint8_t* end) {
-  static const State and_then[] = {
-      &HPackParser::parse_string_prefix,
-      &HPackParser::parse_value_string_with_indexed_key,
-      &HPackParser::finish_lithdr_incidx};
-  dynamic_table_updates_allowed_ = 0;
-  next_state_ = and_then;
-  index_ = 0x3f;
-  md_for_index_.payload = 0; /* Invalidate cached md when index changes. */
-  parsing_.value = &index_;
-  return parse_value0(cur + 1, end);
-}
-
-/* parse a literal header with incremental indexing; index = 0 */
-grpc_error_handle HPackParser::parse_lithdr_incidx_v(const uint8_t* cur,
-                                                     const uint8_t* end) {
-  static const State and_then[] = {
-      &HPackParser::parse_key_string, &HPackParser::parse_string_prefix,
-      &HPackParser::parse_value_string_with_literal_key,
-      &HPackParser::finish_lithdr_incidx_v};
-  dynamic_table_updates_allowed_ = 0;
-  next_state_ = and_then;
-  return parse_string_prefix(cur + 1, end);
-}
-
-/* finish a literal header without incremental indexing */
-grpc_error_handle HPackParser::finish_lithdr_notidx(const uint8_t* cur,
-                                                    const uint8_t* end) {
-  GRPC_STATS_INC_HPACK_RECV_LITHDR_NOTIDX();
-  grpc_mdelem md = GetPrecomputedMDForIndex();
-  grpc_error_handle err = FinishHeader<TableAction::kOmitFromTable>(
-      grpc_mdelem_from_slices(get_indexed_key(md), value_.TakeExtern()));
-  if (err != GRPC_ERROR_NONE) return parse_error(cur, end, err);
-  return parse_begin(cur, end);
-}
-
-/* finish a literal header without incremental indexing with index = 0 */
-grpc_error_handle HPackParser::finish_lithdr_notidx_v(const uint8_t* cur,
-                                                      const uint8_t* end) {
-  GRPC_STATS_INC_HPACK_RECV_LITHDR_NOTIDX_V();
-  grpc_error_handle err = FinishHeader<TableAction::kOmitFromTable>(
-      grpc_mdelem_from_slices(key_.TakeIntern(), value_.TakeExtern()));
-  if (err != GRPC_ERROR_NONE) return parse_error(cur, end, err);
-  return parse_begin(cur, end);
-}
-
-/* parse a literal header without incremental indexing; index < 15 */
-grpc_error_handle HPackParser::parse_lithdr_notidx(const uint8_t* cur,
-                                                   const uint8_t* end) {
-  static const State and_then[] = {
-      &HPackParser::parse_value_string_with_indexed_key,
-      &HPackParser::finish_lithdr_notidx};
-  dynamic_table_updates_allowed_ = 0;
-  next_state_ = and_then;
-  index_ = (*cur) & 0xf;
-  md_for_index_.payload = 0; /* Invalidate cached md when index changes. */
-  return parse_string_prefix(cur + 1, end);
-}
-
-/* parse a literal header without incremental indexing; index >= 15 */
-grpc_error_handle HPackParser::parse_lithdr_notidx_x(const uint8_t* cur,
-                                                     const uint8_t* end) {
-  static const State and_then[] = {
-      &HPackParser::parse_string_prefix,
-      &HPackParser::parse_value_string_with_indexed_key,
-      &HPackParser::finish_lithdr_notidx};
-  dynamic_table_updates_allowed_ = 0;
-  next_state_ = and_then;
-  index_ = 0xf;
-  md_for_index_.payload = 0; /* Invalidate cached md when index changes. */
-  parsing_.value = &index_;
-  return parse_value0(cur + 1, end);
-}
-
-/* parse a literal header without incremental indexing; index == 0 */
-grpc_error_handle HPackParser::parse_lithdr_notidx_v(const uint8_t* cur,
-                                                     const uint8_t* end) {
-  static const State and_then[] = {
-      &HPackParser::parse_key_string, &HPackParser::parse_string_prefix,
-      &HPackParser::parse_value_string_with_literal_key,
-      &HPackParser::finish_lithdr_notidx_v};
-  dynamic_table_updates_allowed_ = 0;
-  next_state_ = and_then;
-  return parse_string_prefix(cur + 1, end);
-}
-
-/* finish a literal header that is never indexed */
-grpc_error_handle HPackParser::finish_lithdr_nvridx(const uint8_t* cur,
-                                                    const uint8_t* end) {
-  GRPC_STATS_INC_HPACK_RECV_LITHDR_NVRIDX();
-  grpc_mdelem md = GetPrecomputedMDForIndex();
-  grpc_error_handle err = FinishHeader<TableAction::kOmitFromTable>(
-      grpc_mdelem_from_slices(get_indexed_key(md), value_.TakeExtern()));
-  if (err != GRPC_ERROR_NONE) return parse_error(cur, end, err);
-  return parse_begin(cur, end);
-}
-
-/* finish a literal header that is never indexed with an extra value */
-grpc_error_handle HPackParser::finish_lithdr_nvridx_v(const uint8_t* cur,
-                                                      const uint8_t* end) {
-  GRPC_STATS_INC_HPACK_RECV_LITHDR_NVRIDX_V();
-  grpc_error_handle err = FinishHeader<TableAction::kOmitFromTable>(
-      grpc_mdelem_from_slices(key_.TakeIntern(), value_.TakeExtern()));
-  if (err != GRPC_ERROR_NONE) return parse_error(cur, end, err);
-  return parse_begin(cur, end);
-}
-
-/* parse a literal header that is never indexed; index < 15 */
-grpc_error_handle HPackParser::parse_lithdr_nvridx(const uint8_t* cur,
-                                                   const uint8_t* end) {
-  static const State and_then[] = {
-      &HPackParser::parse_value_string_with_indexed_key,
-      &HPackParser::finish_lithdr_nvridx};
-  dynamic_table_updates_allowed_ = 0;
-  next_state_ = and_then;
-  index_ = (*cur) & 0xf;
-  md_for_index_.payload = 0; /* Invalidate cached md when index changes. */
-  return parse_string_prefix(cur + 1, end);
-}
-
-/* parse a literal header that is never indexed; index >= 15 */
-grpc_error_handle HPackParser::parse_lithdr_nvridx_x(const uint8_t* cur,
-                                                     const uint8_t* end) {
-  static const State and_then[] = {
-      &HPackParser::parse_string_prefix,
-      &HPackParser::parse_value_string_with_indexed_key,
-      &HPackParser::finish_lithdr_nvridx};
-  dynamic_table_updates_allowed_ = 0;
-  next_state_ = and_then;
-  index_ = 0xf;
-  md_for_index_.payload = 0; /* Invalidate cached md when index changes. */
-  parsing_.value = &index_;
-  return parse_value0(cur + 1, end);
-}
-
-/* parse a literal header that is never indexed; index == 0 */
-grpc_error_handle HPackParser::parse_lithdr_nvridx_v(const uint8_t* cur,
-                                                     const uint8_t* end) {
-  static const State and_then[] = {
-      &HPackParser::parse_key_string, &HPackParser::parse_string_prefix,
-      &HPackParser::parse_value_string_with_literal_key,
-      &HPackParser::finish_lithdr_nvridx_v};
-  dynamic_table_updates_allowed_ = 0;
-  next_state_ = and_then;
-  return parse_string_prefix(cur + 1, end);
-}
-
-/* finish parsing a max table size change */
-grpc_error_handle HPackParser::finish_max_tbl_size(const uint8_t* cur,
-                                                   const uint8_t* end) {
-  if (GRPC_TRACE_FLAG_ENABLED(grpc_trace_chttp2_hpack_parser)) {
-    gpr_log(GPR_INFO, "MAX TABLE SIZE: %d", index_);
+  String& operator=(String&& other) noexcept {
+    value_ = std::move(other.value_);
+    other.value_ = absl::Span<const uint8_t>();
+    return *this;
   }
-  grpc_error_handle err =
-      grpc_chttp2_hptbl_set_current_table_size(&table_, index_);
-  if (err != GRPC_ERROR_NONE) return parse_error(cur, end, err);
-  return parse_begin(cur, end);
-}
 
-/* parse a max table size change, max size < 15 */
-grpc_error_handle HPackParser::parse_max_tbl_size(const uint8_t* cur,
-                                                  const uint8_t* end) {
-  if (dynamic_table_updates_allowed_ == 0) {
-    return parse_error(
-        cur, end,
-        GRPC_ERROR_CREATE_FROM_STATIC_STRING(
-            "More than two max table size changes in a single frame"));
+  // Parse a non-binary string
+  static absl::optional<String> Parse(Input* input) {
+    auto pfx = input->ParseStringPrefix();
+    if (!pfx.has_value()) return {};
+    if (pfx->huff) {
+      // Huffman coded
+      std::vector<uint8_t> output;
+      auto v = ParseHuff(input, pfx->length,
+                         [&output](uint8_t c) { output.push_back(c); });
+      if (!v) return {};
+      return String(std::move(output));
+    }
+    return ParseUncompressed(input, pfx->length);
   }
-  dynamic_table_updates_allowed_--;
-  index_ = (*cur) & 0x1f;
-  md_for_index_.payload = 0; /* Invalidate cached md when index changes. */
-  return finish_max_tbl_size(cur + 1, end);
-}
 
-/* parse a max table size change, max size >= 15 */
-grpc_error_handle HPackParser::parse_max_tbl_size_x(const uint8_t* cur,
-                                                    const uint8_t* end) {
-  static const State and_then[] = {&HPackParser::finish_max_tbl_size};
-  if (dynamic_table_updates_allowed_ == 0) {
-    return parse_error(
-        cur, end,
-        GRPC_ERROR_CREATE_FROM_STATIC_STRING(
-            "More than two max table size changes in a single frame"));
+  // Parse a binary string
+  static absl::optional<String> ParseBinary(Input* input) {
+    auto pfx = input->ParseStringPrefix();
+    if (!pfx.has_value()) return {};
+    if (!pfx->huff) {
+      if (pfx->length > 0 && input->peek() == 0) {
+        // 'true-binary'
+        input->Advance(1);
+        return ParseUncompressed(input, pfx->length - 1);
+      }
+      // Base64 encoded... pull out the string, then unbase64 it
+      auto base64 = ParseUncompressed(input, pfx->length);
+      if (!base64.has_value()) return {};
+      return Unbase64(input, std::move(*base64));
+    } else {
+      // Huffman encoded...
+      std::vector<uint8_t> decompressed;
+      // State here says either we don't know if it's base64 or binary, or we do
+      // and what is it.
+      enum class State { kUnsure, kBinary, kBase64 };
+      State state = State::kUnsure;
+      auto decompressed_ok =
+          ParseHuff(input, pfx->length, [&state, &decompressed](uint8_t c) {
+            if (state == State::kUnsure) {
+              // First byte... if it's zero it's binary
+              if (c == 0) {
+                // Save the type, and skip the zero
+                state = State::kBinary;
+                return;
+              } else {
+                // Flag base64, store this value
+                state = State::kBase64;
+              }
+            }
+            // Non-first byte, or base64 first byte
+            decompressed.push_back(c);
+          });
+      if (!decompressed_ok) return {};
+      switch (state) {
+        case State::kUnsure:
+          // No bytes, empty span
+          return String(absl::Span<const uint8_t>());
+        case State::kBinary:
+          // Binary, we're done
+          return String(std::move(decompressed));
+        case State::kBase64:
+          // Base64 - unpack it
+          return Unbase64(input, String(std::move(decompressed)));
+      }
+      GPR_UNREACHABLE_CODE(abort(););
+    }
   }
-  dynamic_table_updates_allowed_--;
-  next_state_ = and_then;
-  index_ = 0x1f;
-  md_for_index_.payload = 0; /* Invalidate cached md when index changes. */
-  parsing_.value = &index_;
-  return parse_value0(cur + 1, end);
-}
 
-/* a parse error: jam the parse state into parse_error, and return error */
-grpc_error_handle HPackParser::parse_error(const uint8_t* /*cur*/,
-                                           const uint8_t* /*end*/,
-                                           grpc_error_handle err) {
-  GPR_ASSERT(err != GRPC_ERROR_NONE);
-  if (last_error_ == GRPC_ERROR_NONE) {
-    last_error_ = GRPC_ERROR_REF(err);
+ private:
+  void AppendBytes(const uint8_t* data, size_t length);
+  explicit String(std::vector<uint8_t> v) : value_(std::move(v)) {}
+  explicit String(absl::Span<const uint8_t> v) : value_(v) {}
+  String(grpc_slice_refcount* r, const uint8_t* begin, const uint8_t* end)
+      : value_(MakeSlice(r, begin, end)) {}
+
+  // Given a refcount and a byte range, make a slice
+  static grpc_slice MakeSlice(grpc_slice_refcount* r, const uint8_t* begin,
+                              const uint8_t* end) {
+    grpc_slice out;
+    out.refcount = r;
+    r->Ref();
+    out.data.refcounted.bytes = const_cast<uint8_t*>(begin);
+    out.data.refcounted.length = end - begin;
+    return out;
   }
-  state_ = &HPackParser::still_parse_error;
-  return err;
-}
 
-grpc_error_handle HPackParser::still_parse_error(const uint8_t* /*cur*/,
-                                                 const uint8_t* /*end*/) {
-  return GRPC_ERROR_REF(last_error_);
-}
-
-grpc_error_handle HPackParser::parse_illegal_op(const uint8_t* cur,
-                                                const uint8_t* end) {
-  GPR_ASSERT(cur != end);
-  grpc_error_handle err = GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-      absl::StrCat("Illegal hpack op code ", *cur).c_str());
-  return parse_error(cur, end, err);
-}
-
-/* parse the 1st byte of a varint into parsing_.value
-   no overflow is possible */
-grpc_error_handle HPackParser::parse_value0(const uint8_t* cur,
-                                            const uint8_t* end) {
-  if (cur == end) {
-    state_ = &HPackParser::parse_value0;
-    return GRPC_ERROR_NONE;
+  // Parse some huffman encoded bytes, using output(uint8_t b) to emit each
+  // decoded byte.
+  template <typename Out>
+  static bool ParseHuff(Input* input, uint32_t length, Out output) {
+    GRPC_STATS_INC_HPACK_RECV_HUFFMAN();
+    int16_t state = 0;
+    // Parse one half byte... we leverage some lookup tables to keep the logic
+    // here really simple.
+    auto nibble = [&output, &state](uint8_t nibble) {
+      int16_t emit = emit_sub_tbl[16 * emit_tbl[state] + nibble];
+      int16_t next = next_sub_tbl[16 * next_tbl[state] + nibble];
+      if (emit != -1) {
+        if (emit >= 0 && emit < 256) {
+          output(static_cast<uint8_t>(emit));
+        } else {
+          assert(emit == 256);
+        }
+      }
+      state = next;
+    };
+    // If there's insufficient bytes remaining, return now.
+    if (input->remaining() < length) {
+      return input->UnexpectedEOF(false);
+    }
+    // Grab the byte range, and iterate through it.
+    const uint8_t* p = input->cur_ptr();
+    input->Advance(length);
+    for (uint32_t i = 0; i < length; i++) {
+      nibble(p[i] >> 4);
+      nibble(p[i] & 0xf);
+    }
+    return true;
   }
 
-  *parsing_.value += (*cur) & 0x7f;
-
-  if ((*cur) & 0x80) {
-    return parse_value1(cur + 1, end);
-  } else {
-    return parse_next(cur + 1, end);
+  // Parse some uncompressed string bytes.
+  static absl::optional<String> ParseUncompressed(Input* input,
+                                                  uint32_t length) {
+    GRPC_STATS_INC_HPACK_RECV_UNCOMPRESSED();
+    // Check there's enough bytes
+    if (input->remaining() < length) {
+      return input->UnexpectedEOF(absl::optional<String>());
+    }
+    auto* refcount = input->slice_refcount();
+    auto* p = input->cur_ptr();
+    input->Advance(length);
+    if (refcount != nullptr) {
+      return String(refcount, p, p + length);
+    } else {
+      return String(absl::Span<const uint8_t>(p, length));
+    }
   }
-}
 
-/* parse the 2nd byte of a varint into parsing_.value
-   no overflow is possible */
-grpc_error_handle HPackParser::parse_value1(const uint8_t* cur,
-                                            const uint8_t* end) {
-  if (cur == end) {
-    state_ = &HPackParser::parse_value1;
-    return GRPC_ERROR_NONE;
+  // Turn base64 encoded bytes into not base64 encoded bytes.
+  // Only takes input to set an error on failure.
+  static absl::optional<String> Unbase64(Input* input, String s) {
+    auto v = Match(
+        s.value_,
+        [](const grpc_slice& slice) {
+          return Unbase64Loop(GRPC_SLICE_START_PTR(slice),
+                              GRPC_SLICE_END_PTR(slice));
+        },
+        [](absl::Span<const uint8_t> span) {
+          return Unbase64Loop(span.begin(), span.end());
+        },
+        [](const std::vector<uint8_t>& vec) {
+          return Unbase64Loop(vec.data(), vec.data() + vec.size());
+        });
+    if (!v.has_value()) {
+      return input->MaybeSetErrorAndReturn(
+          [] {
+            return GRPC_ERROR_CREATE_FROM_STATIC_STRING(
+                "illegal base64 encoding");
+          },
+          absl::optional<String>());
+    }
+    return String(std::move(*v));
   }
 
-  *parsing_.value += ((static_cast<uint32_t>(*cur)) & 0x7f) << 7;
-
-  if ((*cur) & 0x80) {
-    return parse_value2(cur + 1, end);
-  } else {
-    return parse_next(cur + 1, end);
-  }
-}
+  // Main loop for Unbase64
+  static absl::optional<std::vector<uint8_t>> Unbase64Loop(const uint8_t* cur,
+                                                           const uint8_t* end) {
+    while (cur != end && end[-1] == '=') {
+      --end;
+    }
 
-/* parse the 3rd byte of a varint into parsing_.value
-   no overflow is possible */
-grpc_error_handle HPackParser::parse_value2(const uint8_t* cur,
-                                            const uint8_t* end) {
-  if (cur == end) {
-    state_ = &HPackParser::parse_value2;
-    return GRPC_ERROR_NONE;
-  }
+    std::vector<uint8_t> out;
+    out.reserve(3 * (end - cur) / 4 + 3);
 
-  *parsing_.value += ((static_cast<uint32_t>(*cur)) & 0x7f) << 14;
+    // Decode 4 bytes at a time while we can
+    while (end - cur >= 4) {
+      uint32_t bits = kBase64InverseTable.table[*cur];
+      if (bits > 63) return {};
+      uint32_t buffer = bits << 18;
+      ++cur;
 
-  if ((*cur) & 0x80) {
-    return parse_value3(cur + 1, end);
-  } else {
-    return parse_next(cur + 1, end);
-  }
-}
+      bits = kBase64InverseTable.table[*cur];
+      if (bits > 63) return {};
+      buffer |= bits << 12;
+      ++cur;
 
-/* parse the 4th byte of a varint into parsing_.value
-   no overflow is possible */
-grpc_error_handle HPackParser::parse_value3(const uint8_t* cur,
-                                            const uint8_t* end) {
-  if (cur == end) {
-    state_ = &HPackParser::parse_value3;
-    return GRPC_ERROR_NONE;
-  }
+      bits = kBase64InverseTable.table[*cur];
+      if (bits > 63) return {};
+      buffer |= bits << 6;
+      ++cur;
 
-  *parsing_.value += ((static_cast<uint32_t>(*cur)) & 0x7f) << 21;
+      bits = kBase64InverseTable.table[*cur];
+      if (bits > 63) return {};
+      buffer |= bits;
+      ++cur;
 
-  if ((*cur) & 0x80) {
-    return parse_value4(cur + 1, end);
-  } else {
-    return parse_next(cur + 1, end);
-  }
-}
+      out.insert(out.end(), {static_cast<uint8_t>(buffer >> 16),
+                             static_cast<uint8_t>(buffer >> 8),
+                             static_cast<uint8_t>(buffer)});
+    }
+    // Deal with the last 0, 1, 2, or 3 bytes.
+    switch (end - cur) {
+      case 0:
+        return out;
+      case 1:
+        return {};
+      case 2: {
+        uint32_t bits = kBase64InverseTable.table[*cur];
+        if (bits > 63) return {};
+        uint32_t buffer = bits << 18;
 
-/* parse the 5th byte of a varint into parsing_.value
-   depending on the byte, we may overflow, and care must be taken */
-grpc_error_handle HPackParser::parse_value4(const uint8_t* cur,
-                                            const uint8_t* end) {
-  uint8_t c;
-  uint32_t cur_value;
-  uint32_t add_value;
+        ++cur;
+        bits = kBase64InverseTable.table[*cur];
+        if (bits > 63) return {};
+        buffer |= bits << 12;
 
-  if (cur == end) {
-    state_ = &HPackParser::parse_value4;
-    return GRPC_ERROR_NONE;
-  }
+        if (buffer & 0xffff) return {};
+        out.push_back(static_cast<uint8_t>(buffer >> 16));
+        return out;
+      }
+      case 3: {
+        uint32_t bits = kBase64InverseTable.table[*cur];
+        if (bits > 63) return {};
+        uint32_t buffer = bits << 18;
 
-  c = (*cur) & 0x7f;
-  if (c > 0xf) {
-    goto error;
-  }
+        ++cur;
+        bits = kBase64InverseTable.table[*cur];
+        if (bits > 63) return {};
+        buffer |= bits << 12;
 
-  cur_value = *parsing_.value;
-  add_value = (static_cast<uint32_t>(c)) << 28;
-  if (add_value > 0xffffffffu - cur_value) {
-    goto error;
-  }
+        ++cur;
+        bits = kBase64InverseTable.table[*cur];
+        if (bits > 63) return {};
+        buffer |= bits << 6;
 
-  *parsing_.value = cur_value + add_value;
+        ++cur;
+        if (buffer & 0xff) return {};
+        out.push_back(static_cast<uint8_t>(buffer >> 16));
+        out.push_back(static_cast<uint8_t>(buffer >> 8));
+        return out;
+      }
+    }
 
-  if ((*cur) & 0x80) {
-    return parse_value5up(cur + 1, end);
-  } else {
-    return parse_next(cur + 1, end);
+    GPR_UNREACHABLE_CODE(return out;);
   }
 
-error:
-  grpc_error_handle err = GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-      absl::StrFormat(
-          "integer overflow in hpack integer decoding: have 0x%08x, "
-          "got byte 0x%02x on byte 5",
-          *parsing_.value, *cur)
-          .c_str());
-  return parse_error(cur, end, err);
-}
+  absl::variant<grpc_slice, absl::Span<const uint8_t>, std::vector<uint8_t>>
+      value_;
+};
 
-/* parse any trailing bytes in a varint: it's possible to append an arbitrary
-   number of 0x80's and not affect the value - a zero will terminate - and
-   anything else will overflow */
-grpc_error_handle HPackParser::parse_value5up(const uint8_t* cur,
-                                              const uint8_t* end) {
-  while (cur != end && *cur == 0x80) {
-    ++cur;
+// Parser parses one frame + continuations worth of headers.
+class HPackParser::Parser {
+ public:
+  Parser(Input* input, HPackParser::Sink* sink, HPackTable* table,
+         uint8_t* dynamic_table_updates_allowed)
+      : input_(input),
+        sink_(sink),
+        table_(table),
+        dynamic_table_updates_allowed_(dynamic_table_updates_allowed) {}
+
+  // Skip any priority bits, or return false on failure
+  bool SkipPriority() {
+    if (input_->remaining() < 5) return input_->UnexpectedEOF(false);
+    input_->Advance(5);
+    return true;
   }
 
-  if (cur == end) {
-    state_ = &HPackParser::parse_value5up;
-    return GRPC_ERROR_NONE;
+  bool Parse() {
+    auto cur = *input_->Next();
+    switch (cur >> 4) {
+        // Literal header not indexed - First byte format: 0000xxxx
+        // Literal header never indexed - First byte format: 0001xxxx
+        // Where xxxx:
+        //   0000  - literal key
+        //   1111  - indexed key, varint encoded index
+        //   other - indexed key, inline encoded index
+      case 0:
+      case 1:
+        switch (cur & 0xf) {
+          case 0:  // literal key
+            return FinishHeader<TableAction::kOmitFromTable>(
+                ParseLiteralKey<String::Extern>());
+          case 0xf:  // varint encoded key index
+            return FinishHeader<TableAction::kOmitFromTable>(
+                ParseVarIdxKey<String::Extern>(0xf));
+          default:  // inline encoded key index
+            return FinishHeader<TableAction::kOmitFromTable>(
+                ParseIdxKey<String::Extern>(cur & 0xf));
+        }
+        // Update max table size.
+        // First byte format: 001xxxxx
+        // Where xxxxx:
+        //   11111 - max size is varint encoded
+        //   other - max size is stored inline
+      case 2:
+        // inline encoded max table size
+        return FinishMaxTableSize(cur & 0x1f);
+      case 3:
+        if (cur == 0x3f) {
+          // varint encoded max table size
+          return FinishMaxTableSize(input_->ParseVarint(0x1f));
+        } else {
+          // inline encoded max table size
+          return FinishMaxTableSize(cur & 0x1f);
+        }
+        // Literal header with incremental indexing.
+        // First byte format: 01xxxxxx
+        // Where xxxxxx:
+        //   000000 - literal key
+        //   111111 - indexed key, varint encoded index
+        //   other  - indexed key, inline encoded index
+      case 4:
+        if (cur == 0x40) {
+          // literal key
+          return FinishHeader<TableAction::kAddToTable>(
+              ParseLiteralKey<String::Intern>());
+        }
+        ABSL_FALLTHROUGH_INTENDED;
+      case 5:
+      case 6:
+        // inline encoded key index
+        return FinishHeader<TableAction::kAddToTable>(
+            ParseIdxKey<String::Intern>(cur & 0x3f));
+      case 7:
+        if (cur == 0x7f) {
+          // varint encoded key index
+          return FinishHeader<TableAction::kAddToTable>(
+              ParseVarIdxKey<String::Intern>(0x3f));
+        } else {
+          // inline encoded key index
+          return FinishHeader<TableAction::kAddToTable>(
+              ParseIdxKey<String::Intern>(cur & 0x3f));
+        }
+        // Indexed Header Field Representation
+        // First byte format: 1xxxxxxx
+        // Where xxxxxxx:
+        //   0000000 - illegal
+        //   1111111 - varint encoded field index
+        //   other   - inline encoded field index
+      case 8:
+        if (cur == 0x80) {
+          // illegal value.
+          return input_->MaybeSetErrorAndReturn(
+              [] {
+                return GRPC_ERROR_CREATE_FROM_STATIC_STRING(
+                    "Illegal hpack op code");
+              },
+              false);
+        }
+        ABSL_FALLTHROUGH_INTENDED;
+      case 9:
+      case 10:
+      case 11:
+      case 12:
+      case 13:
+      case 14:
+        // inline encoded field index
+        return FinishIndexed(cur & 0x7f);
+      case 15:
+        if (cur == 0xff) {
+          // varint encoded field index
+          return FinishIndexed(input_->ParseVarint(0x7f));
+        } else {
+          // inline encoded field index
+          return FinishIndexed(cur & 0x7f);
+        }
+    }
+    GPR_UNREACHABLE_CODE(abort());
   }
 
-  if (*cur == 0) {
-    return parse_next(cur + 1, end);
+ private:
+  void GPR_ATTRIBUTE_NOINLINE LogHeader(grpc_mdelem md) {
+    char* k = grpc_slice_to_c_string(GRPC_MDKEY(md));
+    char* v = nullptr;
+    if (grpc_is_binary_header_internal(GRPC_MDKEY(md))) {
+      v = grpc_dump_slice(GRPC_MDVALUE(md), GPR_DUMP_HEX);
+    } else {
+      v = grpc_slice_to_c_string(GRPC_MDVALUE(md));
+    }
+    gpr_log(
+        GPR_INFO,
+        "Decode: '%s: %s', elem_interned=%d [%d], k_interned=%d, v_interned=%d",
+        k, v, GRPC_MDELEM_IS_INTERNED(md), GRPC_MDELEM_STORAGE(md),
+        grpc_slice_is_interned(GRPC_MDKEY(md)),
+        grpc_slice_is_interned(GRPC_MDVALUE(md)));
+    gpr_free(k);
+    gpr_free(v);
   }
 
-  grpc_error_handle err = GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-      absl::StrFormat(
-          "integer overflow in hpack integer decoding: have 0x%08x, "
-          "got byte 0x%02x sometime after byte 5",
-          *parsing_.value, *cur)
-          .c_str());
-  return parse_error(cur, end, err);
-}
-
-/* parse a string prefix */
-grpc_error_handle HPackParser::parse_string_prefix(const uint8_t* cur,
-                                                   const uint8_t* end) {
-  if (cur == end) {
-    state_ = &HPackParser::parse_string_prefix;
-    return GRPC_ERROR_NONE;
+  // During FinishHeader, how should the header be treated in the hpack table
+  enum class TableAction {
+    // Add to the table
+    kAddToTable,
+    // Do not add to the table
+    kOmitFromTable,
+  };
+
+  template <TableAction action>
+  bool FinishHeader(grpc_mdelem md) {
+    // Allow higher code to just pass in failures ... simplifies things a bit.
+    if (GRPC_MDISNULL(md)) return false;
+    // Log if desired
+    if (GRPC_TRACE_FLAG_ENABLED(grpc_trace_chttp2_hpack_parser)) {
+      LogHeader(md);
+    }
+    // Add to the hpack table if needed
+    if (action == TableAction::kAddToTable) {
+      GPR_DEBUG_ASSERT(GRPC_MDELEM_STORAGE(md) ==
+                           GRPC_MDELEM_STORAGE_INTERNED ||
+                       GRPC_MDELEM_STORAGE(md) == GRPC_MDELEM_STORAGE_STATIC);
+      grpc_error_handle err = table_->Add(md);
+      if (GPR_UNLIKELY(err != GRPC_ERROR_NONE)) {
+        input_->SetError(err);
+        return false;
+      };
+    }
+    // Pass up to the transport
+    grpc_error_handle err = (*sink_)(md);
+    if (GPR_UNLIKELY(err != GRPC_ERROR_NONE)) {
+      input_->SetError(err);
+      return false;
+    }
+    return true;
   }
 
-  strlen_ = (*cur) & 0x7f;
-  huff_ = (*cur) >> 7;
-  if (strlen_ == 0x7f) {
-    parsing_.value = &strlen_;
-    return parse_value0(cur + 1, end);
-  } else {
-    return parse_next(cur + 1, end);
+  // Parse a string encoded key and a string encoded value
+  template <typename TakeValueType>
+  grpc_mdelem ParseLiteralKey() {
+    auto key = String::Parse(input_);
+    if (!key.has_value()) return GRPC_MDNULL;
+    auto key_slice = key->Take<String::Intern>();
+    auto value = ParseValueString(key_slice);
+    if (GPR_UNLIKELY(!value.has_value())) {
+      grpc_slice_unref_internal(key_slice);
+      return GRPC_MDNULL;
+    }
+    return grpc_mdelem_from_slices(key_slice, value->Take<TakeValueType>());
   }
-}
 
-/* append some bytes to a string */
-void HPackParser::String::AppendBytes(const uint8_t* data, size_t length) {
-  if (length == 0) return;
-  if (length + data_.copied.length > data_.copied.capacity) {
-    GPR_ASSERT(data_.copied.length + length <= UINT32_MAX);
-    data_.copied.capacity = static_cast<uint32_t>(data_.copied.length + length);
-    data_.copied.str = static_cast<char*>(
-        gpr_realloc(data_.copied.str, data_.copied.capacity));
+  // Parse an index encoded key and a string encoded value
+  template <typename TakeValueType>
+  grpc_mdelem ParseIdxKey(uint32_t index) {
+    auto elem = table_->Peek(index);
+    if (GPR_UNLIKELY(GRPC_MDISNULL(elem))) {
+      return InvalidHPackIndexError(index, elem);
+    }
+    GPR_DEBUG_ASSERT(GRPC_MDELEM_IS_INTERNED(elem));
+    auto value = ParseValueString(GRPC_MDKEY(elem));
+    if (GPR_UNLIKELY(!value.has_value())) return GRPC_MDNULL;
+    return grpc_mdelem_from_slices(
+        static_cast<const ManagedMemorySlice&>(
+            grpc_slice_ref_internal(GRPC_MDKEY(elem))),
+        value->Take<TakeValueType>());
   }
-  memcpy(data_.copied.str + data_.copied.length, data, length);
-  GPR_ASSERT(length <= UINT32_MAX - data_.copied.length);
-  data_.copied.length += static_cast<uint32_t>(length);
-}
 
-grpc_error_handle HPackParser::AppendString(const uint8_t* cur,
-                                            const uint8_t* end) {
-  String* str = parsing_.str;
-  uint32_t bits;
-  uint8_t decoded[3];
-  switch (binary_) {
-    case BinaryState::kNotBinary:
-      str->AppendBytes(cur, static_cast<size_t>(end - cur));
-      return GRPC_ERROR_NONE;
-    case BinaryState::kBinaryBegin:
-      if (cur == end) {
-        binary_ = BinaryState::kBinaryBegin;
-        return GRPC_ERROR_NONE;
-      }
-      if (*cur == 0) {
-        /* 'true-binary' case */
-        ++cur;
-        binary_ = BinaryState::kNotBinary;
-        GRPC_STATS_INC_HPACK_RECV_BINARY();
-        str->AppendBytes(cur, static_cast<size_t>(end - cur));
-        return GRPC_ERROR_NONE;
-      }
-      GRPC_STATS_INC_HPACK_RECV_BINARY_BASE64();
-    b64_byte0:
-      ABSL_FALLTHROUGH_INTENDED;
-    case BinaryState::kBase64Byte0:
-      if (cur == end) {
-        binary_ = BinaryState::kBase64Byte0;
-        return GRPC_ERROR_NONE;
-      }
-      bits = kBase64InverseTable.table[*cur];
-      ++cur;
-      if (bits == 255) {
-        return parse_error(
-            cur, end,
-            GRPC_ERROR_CREATE_FROM_STATIC_STRING("Illegal base64 character"));
-      } else if (bits == 64) {
-        goto b64_byte0;
-      }
-      base64_buffer_ = bits << 18;
-    b64_byte1:
-      ABSL_FALLTHROUGH_INTENDED;
-    case BinaryState::kBase64Byte1:
-      if (cur == end) {
-        binary_ = BinaryState::kBase64Byte1;
-        return GRPC_ERROR_NONE;
-      }
-      bits = kBase64InverseTable.table[*cur];
-      ++cur;
-      if (bits == 255) {
-        return parse_error(
-            cur, end,
-            GRPC_ERROR_CREATE_FROM_STATIC_STRING("Illegal base64 character"));
-      } else if (bits == 64) {
-        goto b64_byte1;
-      }
-      base64_buffer_ |= bits << 12;
-    b64_byte2:
-      ABSL_FALLTHROUGH_INTENDED;
-    case BinaryState::kBase64Byte2:
-      if (cur == end) {
-        binary_ = BinaryState::kBase64Byte2;
-        return GRPC_ERROR_NONE;
-      }
-      bits = kBase64InverseTable.table[*cur];
-      ++cur;
-      if (bits == 255) {
-        return parse_error(
-            cur, end,
-            GRPC_ERROR_CREATE_FROM_STATIC_STRING("Illegal base64 character"));
-      } else if (bits == 64) {
-        goto b64_byte2;
-      }
-      base64_buffer_ |= bits << 6;
-    b64_byte3:
-      ABSL_FALLTHROUGH_INTENDED;
-    case BinaryState::kBase64Byte3:
-      if (cur == end) {
-        binary_ = BinaryState::kBase64Byte3;
-        return GRPC_ERROR_NONE;
-      }
-      bits = kBase64InverseTable.table[*cur];
-      ++cur;
-      if (bits == 255) {
-        return parse_error(
-            cur, end,
-            GRPC_ERROR_CREATE_FROM_STATIC_STRING("Illegal base64 character"));
-      } else if (bits == 64) {
-        goto b64_byte3;
-      }
-      base64_buffer_ |= bits;
-      bits = base64_buffer_;
-      decoded[0] = static_cast<uint8_t>(bits >> 16);
-      decoded[1] = static_cast<uint8_t>(bits >> 8);
-      decoded[2] = static_cast<uint8_t>(bits);
-      str->AppendBytes(decoded, 3);
-      goto b64_byte0;
+  // Parse a varint index encoded key and a string encoded value
+  template <typename TakeValueType>
+  grpc_mdelem ParseVarIdxKey(uint32_t offset) {
+    auto index = input_->ParseVarint(offset);
+    if (GPR_UNLIKELY(!index.has_value())) return GRPC_MDNULL;
+    return ParseIdxKey<TakeValueType>(*index);
   }
-  GPR_UNREACHABLE_CODE(return parse_error(
-      cur, end,
-      GRPC_ERROR_CREATE_FROM_STATIC_STRING("Should never reach here")));
-}
 
-grpc_error_handle HPackParser::finish_str(const uint8_t* cur,
-                                          const uint8_t* end) {
-  uint8_t decoded[2];
-  uint32_t bits;
-  String* str = parsing_.str;
-  switch (binary_) {
-    case BinaryState::kNotBinary:
-      break;
-    case BinaryState::kBinaryBegin:
-      break;
-    case BinaryState::kBase64Byte0:
-      break;
-    case BinaryState::kBase64Byte1:
-      return parse_error(cur, end,
-                         GRPC_ERROR_CREATE_FROM_STATIC_STRING(
-                             "illegal base64 encoding")); /* illegal encoding */
-    case BinaryState::kBase64Byte2:
-      bits = base64_buffer_;
-      if (bits & 0xffff) {
-        grpc_error_handle err = GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-            absl::StrFormat("trailing bits in base64 encoding: 0x%04x",
-                            bits & 0xffff)
-                .c_str());
-        return parse_error(cur, end, err);
-      }
-      decoded[0] = static_cast<uint8_t>(bits >> 16);
-      str->AppendBytes(decoded, 1);
-      break;
-    case BinaryState::kBase64Byte3:
-      bits = base64_buffer_;
-      if (bits & 0xff) {
-        grpc_error_handle err = GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-            absl::StrFormat("trailing bits in base64 encoding: 0x%02x",
-                            bits & 0xff)
-                .c_str());
-        return parse_error(cur, end, err);
-      }
-      decoded[0] = static_cast<uint8_t>(bits >> 16);
-      decoded[1] = static_cast<uint8_t>(bits >> 8);
-      str->AppendBytes(decoded, 2);
-      break;
-  }
-  return GRPC_ERROR_NONE;
-}
-
-/* decode a nibble from a huffman encoded stream */
-grpc_error_handle HPackParser::AppendHuffNibble(uint8_t nibble) {
-  int16_t emit = emit_sub_tbl[16 * emit_tbl[huff_state_] + nibble];
-  int16_t next = next_sub_tbl[16 * next_tbl[huff_state_] + nibble];
-  if (emit != -1) {
-    if (emit >= 0 && emit < 256) {
-      uint8_t c = static_cast<uint8_t>(emit);
-      grpc_error_handle err = AppendString(&c, (&c) + 1);
-      if (err != GRPC_ERROR_NONE) return err;
+  // Parse a string, figuring out if it's binary or not by the key name.
+  template <typename SliceType>
+  absl::optional<String> ParseValueString(const SliceType& key) {
+    if (grpc_is_refcounted_slice_binary_header(key)) {
+      return String::ParseBinary(input_);
     } else {
-      assert(emit == 256);
+      return String::Parse(input_);
     }
   }
-  huff_state_ = next;
-  return GRPC_ERROR_NONE;
-}
 
-/* decode full bytes from a huffman encoded stream */
-grpc_error_handle HPackParser::AppendHuffBytes(const uint8_t* cur,
-                                               const uint8_t* end) {
-  for (; cur != end; ++cur) {
-    grpc_error_handle err = AppendHuffNibble(*cur >> 4);
-    if (err != GRPC_ERROR_NONE) return parse_error(cur, end, err);
-    err = AppendHuffNibble(*cur & 0xf);
-    if (err != GRPC_ERROR_NONE) return parse_error(cur, end, err);
+  // Emit an indexed field
+  bool FinishIndexed(absl::optional<uint32_t> index) {
+    *dynamic_table_updates_allowed_ = 0;
+    if (!index.has_value()) return false;
+    grpc_mdelem md = table_->Fetch(*index);
+    if (GPR_UNLIKELY(GRPC_MDISNULL(md))) {
+      return InvalidHPackIndexError(*index, false);
+    }
+    GRPC_STATS_INC_HPACK_RECV_INDEXED();
+    return FinishHeader<TableAction::kOmitFromTable>(md);
   }
-  return GRPC_ERROR_NONE;
-}
 
-/* decode some string bytes based on the current decoding mode
-   (huffman or not) */
-grpc_error_handle HPackParser::AppendStrBytes(const uint8_t* cur,
-                                              const uint8_t* end) {
-  if (huff_) {
-    return AppendHuffBytes(cur, end);
-  } else {
-    return AppendString(cur, end);
+  // finish parsing a max table size change
+  bool FinishMaxTableSize(absl::optional<uint32_t> size) {
+    if (!size.has_value()) return false;
+    if (*dynamic_table_updates_allowed_ == 0) {
+      return input_->MaybeSetErrorAndReturn(
+          [] {
+            return GRPC_ERROR_CREATE_FROM_STATIC_STRING(
+                "More than two max table size changes in a single frame");
+          },
+          false);
+    }
+    (*dynamic_table_updates_allowed_)--;
+    if (GRPC_TRACE_FLAG_ENABLED(grpc_trace_chttp2_hpack_parser)) {
+      gpr_log(GPR_INFO, "MAX TABLE SIZE: %d", *size);
+    }
+    grpc_error_handle err = table_->SetCurrentTableSize(*size);
+    if (err != GRPC_ERROR_NONE) {
+      input_->SetError(err);
+      return false;
+    }
+    return true;
   }
-}
 
-/* parse a string - tries to do large chunks at a time */
-grpc_error_handle HPackParser::parse_string(const uint8_t* cur,
-                                            const uint8_t* end) {
-  size_t remaining = strlen_ - strgot_;
-  size_t given = static_cast<size_t>(end - cur);
-  if (remaining <= given) {
-    grpc_error_handle err = AppendStrBytes(cur, cur + remaining);
-    if (err != GRPC_ERROR_NONE) return parse_error(cur, end, err);
-    err = finish_str(cur + remaining, end);
-    if (err != GRPC_ERROR_NONE) return parse_error(cur, end, err);
-    return parse_next(cur + remaining, end);
-  } else {
-    grpc_error_handle err = AppendStrBytes(cur, cur + given);
-    if (err != GRPC_ERROR_NONE) return parse_error(cur, end, err);
-    GPR_ASSERT(given <= UINT32_MAX - strgot_);
-    strgot_ += static_cast<uint32_t>(given);
-    state_ = &HPackParser::parse_string;
-    return GRPC_ERROR_NONE;
+  // Set an invalid hpack index error if no error has been set. Returns result
+  // unmodified.
+  template <typename R>
+  R InvalidHPackIndexError(uint32_t index, R result) {
+    return input_->MaybeSetErrorAndReturn(
+        [this, index] {
+          return grpc_error_set_int(
+              grpc_error_set_int(GRPC_ERROR_CREATE_FROM_STATIC_STRING(
+                                     "Invalid HPACK index received"),
+                                 GRPC_ERROR_INT_INDEX,
+                                 static_cast<intptr_t>(index)),
+              GRPC_ERROR_INT_SIZE,
+              static_cast<intptr_t>(this->table_->num_entries()));
+        },
+        result);
   }
-}
 
-/* begin parsing a string - performs setup, calls parse_string */
-grpc_error_handle HPackParser::begin_parse_string(const uint8_t* cur,
-                                                  const uint8_t* end,
-                                                  BinaryState binary,
-                                                  HPackParser::String* str) {
-  if (!huff_ && binary == BinaryState::kNotBinary &&
-      static_cast<uint32_t>(end - cur) >= strlen_ &&
-      current_slice_refcount_ != nullptr) {
-    GRPC_STATS_INC_HPACK_RECV_UNCOMPRESSED();
-    str->copied_ = false;
-    str->data_.referenced.refcount = current_slice_refcount_;
-    str->data_.referenced.data.refcounted.bytes = const_cast<uint8_t*>(cur);
-    str->data_.referenced.data.refcounted.length = strlen_;
-    grpc_slice_ref_internal(str->data_.referenced);
-    return parse_next(cur + strlen_, end);
-  }
-  strgot_ = 0;
-  str->copied_ = true;
-  str->data_.copied.length = 0;
-  parsing_.str = str;
-  huff_state_ = 0;
-  binary_ = binary;
-  switch (binary_) {
-    case BinaryState::kNotBinary:
-      if (huff_) {
-        GRPC_STATS_INC_HPACK_RECV_HUFFMAN();
-      } else {
-        GRPC_STATS_INC_HPACK_RECV_UNCOMPRESSED();
-      }
-      break;
-    case BinaryState::kBinaryBegin:
-      /* stats incremented later: don't know true binary or not */
-      break;
-    default:
-      abort();
-  }
-  return parse_string(cur, end);
-}
+  Input* input_;
+  HPackParser::Sink* sink_;
+  HPackTable* const table_;
+  uint8_t* dynamic_table_updates_allowed_;
+};
 
-/* parse the key string */
-grpc_error_handle HPackParser::parse_key_string(const uint8_t* cur,
-                                                const uint8_t* end) {
-  return begin_parse_string(cur, end, BinaryState::kNotBinary, &key_);
+UnmanagedMemorySlice HPackParser::String::Take(Extern) {
+  auto s = Match(
+      value_,
+      [](const grpc_slice& slice) {
+        GPR_DEBUG_ASSERT(!grpc_slice_is_interned(slice));
+        return static_cast<const UnmanagedMemorySlice&>(slice);
+      },
+      [](absl::Span<const uint8_t> span) {
+        return UnmanagedMemorySlice(
+            reinterpret_cast<char*>(const_cast<uint8_t*>(span.begin())),
+            span.size());
+      },
+      [](const std::vector<uint8_t>& v) {
+        return UnmanagedMemorySlice(reinterpret_cast<const char*>(v.data()),
+                                    v.size());
+      });
+  value_ = absl::Span<const uint8_t>();
+  return s;
 }
 
-/* check if a key represents a binary header or not */
-
-bool HPackParser::IsBinaryLiteralHeader() {
-  /* We know that either argument here is a reference counter slice.
-   * 1. If it is a grpc_core::StaticSlice, the refcount is set to kNoopRefcount.
-   * 2. If it's key_.data.referenced, then key_.copied was set to false,
-   *    which occurs in begin_parse_string() - where the refcount is set to
-   *    current_slice_refcount_, which is not null. */
-  return grpc_is_refcounted_slice_binary_header(
-      key_.copied_ ? grpc_core::ExternallyManagedSlice(key_.data_.copied.str,
-                                                       key_.data_.copied.length)
-                   : key_.data_.referenced);
+ManagedMemorySlice HPackParser::String::Take(Intern) {
+  auto s = Match(
+      value_,
+      [](const grpc_slice& slice) {
+        ManagedMemorySlice s(&slice);
+        grpc_slice_unref_internal(slice);
+        return s;
+      },
+      [](absl::Span<const uint8_t> span) {
+        return ManagedMemorySlice(
+            reinterpret_cast<char*>(const_cast<uint8_t*>(span.data())),
+            span.size());
+      },
+      [](const std::vector<uint8_t>& v) {
+        return ManagedMemorySlice(reinterpret_cast<const char*>(v.data()),
+                                  v.size());
+      });
+  value_ = absl::Span<const uint8_t>();
+  return s;
 }
 
-/* Cache the metadata for the given index during initial parsing. This avoids a
-   pointless recomputation of the metadata when finishing a header. We read the
-   cached value in get_precomputed_md_for_idx(). */
-void HPackParser::SetPrecomputedMDIndex(grpc_mdelem md) {
-  GPR_DEBUG_ASSERT(md_for_index_.payload == 0);
-  GPR_DEBUG_ASSERT(precomputed_md_index_ == -1);
-  md_for_index_ = md;
-#ifndef NDEBUG
-  precomputed_md_index_ = index_;
-#endif
-}
+/* PUBLIC INTERFACE */
 
-/* Determines if a metadata element key associated with the current parser index
-   is a binary indexed header during string parsing. We'll need to revisit this
-   metadata when we're done parsing, so we cache the metadata for this index
-   here using set_precomputed_md_idx(). */
-grpc_error_handle HPackParser::IsBinaryIndexedHeader(bool* is) {
-  grpc_mdelem elem = grpc_chttp2_hptbl_lookup(&table_, index_);
-  if (GPR_UNLIKELY(GRPC_MDISNULL(elem))) {
-    return InvalidHPackIndexError();
-  }
-  /* We know that GRPC_MDKEY(elem) points to a reference counted slice since:
-   * 1. elem was a result of grpc_chttp2_hptbl_lookup
-   * 2. An item in this table is either static (see entries with
-   *    index < GRPC_CHTTP2_LAST_STATIC_ENTRY or added via
-   *    grpc_chttp2_hptbl_add).
-   * 3. If added via grpc_chttp2_hptbl_add, the entry is either static or
-   *    interned.
-   * 4. Both static and interned element slices have non-null refcounts. */
-  *is = grpc_is_refcounted_slice_binary_header(GRPC_MDKEY(elem));
-  SetPrecomputedMDIndex(elem);
-  return GRPC_ERROR_NONE;
-}
+HPackParser::HPackParser() = default;
 
-/* parse the value string */
-grpc_error_handle HPackParser::parse_value_string(const uint8_t* cur,
-                                                  const uint8_t* end,
-                                                  bool is_binary) {
-  return begin_parse_string(
-      cur, end, is_binary ? BinaryState::kBinaryBegin : BinaryState::kNotBinary,
-      &value_);
-}
+HPackParser::~HPackParser() = default;
 
-grpc_error_handle HPackParser::parse_value_string_with_indexed_key(
-    const uint8_t* cur, const uint8_t* end) {
-  bool is_binary = false;
-  grpc_error_handle err = IsBinaryIndexedHeader(&is_binary);
-  if (err != GRPC_ERROR_NONE) return parse_error(cur, end, err);
-  return parse_value_string(cur, end, is_binary);
+void HPackParser::BeginFrame(Sink sink, Boundary boundary, Priority priority) {
+  sink_ = std::move(sink);
+  boundary_ = boundary;
+  priority_ = priority;
+  dynamic_table_updates_allowed_ = 2;
 }
 
-grpc_error_handle HPackParser::parse_value_string_with_literal_key(
-    const uint8_t* cur, const uint8_t* end) {
-  return parse_value_string(cur, end, IsBinaryLiteralHeader());
+grpc_error_handle HPackParser::Parse(const grpc_slice& slice, bool is_last) {
+  if (GPR_UNLIKELY(!unparsed_bytes_.empty())) {
+    std::vector<uint8_t> buffer = std::move(unparsed_bytes_);
+    buffer.insert(buffer.end(), GRPC_SLICE_START_PTR(slice),
+                  GRPC_SLICE_END_PTR(slice));
+    return ParseInput(
+        Input(nullptr, buffer.data(), buffer.data() + buffer.size()), is_last);
+  }
+  return ParseInput(Input(slice.refcount, GRPC_SLICE_START_PTR(slice),
+                          GRPC_SLICE_END_PTR(slice)),
+                    is_last);
 }
 
-/* PUBLIC INTERFACE */
-
-HPackParser::HPackParser() {
-  state_ = &HPackParser::parse_begin;
-  key_.data_.referenced = grpc_empty_slice();
-  key_.data_.copied.str = nullptr;
-  key_.data_.copied.capacity = 0;
-  key_.data_.copied.length = 0;
-  value_.data_.referenced = grpc_empty_slice();
-  value_.data_.copied.str = nullptr;
-  value_.data_.copied.capacity = 0;
-  value_.data_.copied.length = 0;
-  /* Cached metadata for the current index the parser is handling. This is set
-     to 0 initially, invalidated when the index changes, and invalidated when it
-     is read (by get_precomputed_md_for_idx()). It is set during string parsing,
-     by set_precomputed_md_idx() - which is called by parse_value_string().
-     The goal here is to avoid recomputing the metadata for the index when
-     finishing with a header as well as the initial parse. */
-  md_for_index_.payload = 0;
-#ifndef NDEBUG
-  /* In debug mode, this ensures that the cached metadata we're reading is in
-   * fact correct for the index we are examining. */
-  precomputed_md_index_ = -1;
-#endif
-  dynamic_table_updates_allowed_ = 2;
-  last_error_ = GRPC_ERROR_NONE;
+grpc_error_handle HPackParser::ParseInput(Input input, bool is_last) {
+  if (ParseInputInner(&input)) {
+    return GRPC_ERROR_NONE;
+  }
+  if (input.eof_error()) {
+    if (GPR_UNLIKELY(is_last && is_boundary())) {
+      return GRPC_ERROR_CREATE_FROM_STATIC_STRING(
+          "Incomplete header at the end of a header/continuation sequence");
+    }
+    unparsed_bytes_ = std::vector<uint8_t>(input.frontier(), input.end_ptr());
+    return GRPC_ERROR_NONE;
+  }
+  return input.TakeError();
 }
 
-void HPackParser::BeginFrame(Sink sink, Boundary boundary, Priority priority) {
-  sink_ = std::move(sink);
-  boundary_ = boundary;
-  switch (priority) {
-    case Priority::Included:
-      after_prioritization_ = state_;
-      state_ = &HPackParser::parse_stream_dep0;
-      break;
+bool HPackParser::ParseInputInner(Input* input) {
+  switch (priority_) {
     case Priority::None:
       break;
+    case Priority::Included: {
+      if (input->remaining() < 5) return input->UnexpectedEOF(false);
+      input->Advance(5);
+      input->UpdateFrontier();
+      priority_ = Priority::None;
+    }
   }
-}
-
-HPackParser::~HPackParser() {
-  grpc_chttp2_hptbl_destroy(&table_);
-  GRPC_ERROR_UNREF(last_error_);
-  grpc_slice_unref_internal(key_.data_.referenced);
-  grpc_slice_unref_internal(value_.data_.referenced);
-  gpr_free(key_.data_.copied.str);
-  gpr_free(value_.data_.copied.str);
-}
-
-grpc_error_handle HPackParser::Parse(const grpc_slice& slice) {
-/* max number of bytes to parse at a time... limits call stack depth on
- * compilers without TCO */
-#define MAX_PARSE_LENGTH 1024
-  current_slice_refcount_ = slice.refcount;
-  const uint8_t* start = GRPC_SLICE_START_PTR(slice);
-  const uint8_t* end = GRPC_SLICE_END_PTR(slice);
-  grpc_error_handle error = GRPC_ERROR_NONE;
-  while (start != end && error == GRPC_ERROR_NONE) {
-    const uint8_t* target = start + GPR_MIN(MAX_PARSE_LENGTH, end - start);
-    error = (this->*state_)(start, target);
-    start = target;
+  while (!input->end_of_stream()) {
+    if (GPR_UNLIKELY(
+            !Parser(input, &sink_, &table_, &dynamic_table_updates_allowed_)
+                 .Parse())) {
+      return false;
+    }
+    input->UpdateFrontier();
   }
-  current_slice_refcount_ = nullptr;
-  return error;
+  return true;
 }
 
+void HPackParser::FinishFrame() { sink_ = Sink(); }
+
 }  // namespace grpc_core
 
 // TODO(ctiller): this serves as an eviction notice for the remainder of this
@@ -1630,15 +1373,11 @@ grpc_error_handle grpc_chttp2_header_parser_parse(void* hpack_parser,
   if (s != nullptr) {
     s->stats.incoming.header_bytes += GRPC_SLICE_LENGTH(slice);
   }
-  grpc_error_handle error = parser->Parse(slice);
+  grpc_error_handle error = parser->Parse(slice, is_last != 0);
   if (error != GRPC_ERROR_NONE) {
     return error;
   }
   if (is_last) {
-    if (parser->is_boundary() && !parser->is_in_begin_state()) {
-      return GRPC_ERROR_CREATE_FROM_STATIC_STRING(
-          "end of header frame not aligned with a hpack record boundary");
-    }
     /* need to check for null stream: this can occur if we receive an invalid
        stream id on a header */
     if (s != nullptr) {
index 01fb833..0ae7413 100644 (file)
 #include <stddef.h>
 
 #include "src/core/ext/transport/chttp2/transport/frame.h"
-#include "src/core/ext/transport/chttp2/transport/hpack_table.h"
+#include "src/core/ext/transport/chttp2/transport/hpack_parser_table.h"
 #include "src/core/lib/transport/metadata.h"
 
 namespace grpc_core {
 
+// Top level interface for parsing a sequence of header, continuation frames.
 class HPackParser {
  public:
-  enum class Boundary { None, EndOfHeaders, EndOfStream };
-  enum class Priority { None, Included };
+  // What kind of stream boundary is provided by this frame?
+  enum class Boundary : uint8_t {
+    // More continuations are expected
+    None,
+    // This marks the end of headers, so data frames should follow
+    EndOfHeaders,
+    // This marks the end of headers *and* the end of the stream
+    EndOfStream
+  };
+  // What kind of priority is represented in the next frame
+  enum class Priority : uint8_t {
+    // No priority field
+    None,
+    // Yes there's a priority field
+    Included
+  };
 
   // User specified structure called for each received header.
   using Sink = std::function<grpc_error_handle(grpc_mdelem)>;
@@ -40,189 +55,53 @@ class HPackParser {
   HPackParser();
   ~HPackParser();
 
+  // Non-copyable/movable
   HPackParser(const HPackParser&) = delete;
   HPackParser& operator=(const HPackParser&) = delete;
 
+  // Begin parsing a new frame
+  // Sink receives each parsed header,
   void BeginFrame(Sink sink, Boundary boundary, Priority priority);
+  // Change the header sink mid parse
   void ResetSink(Sink sink) { sink_ = std::move(sink); }
-  grpc_error_handle Parse(const grpc_slice& slice);
+  // Parse one slice worth of data
+  grpc_error_handle Parse(const grpc_slice& slice, bool is_last);
+  // Reset state ready for the next BeginFrame
   void FinishFrame();
 
-  grpc_chttp2_hptbl* hpack_table() { return &table_; }
+  // Retrieve the associated hpack table (for tests, debugging)
+  HPackTable* hpack_table() { return &table_; }
+  // Is the current frame a boundary of some sort
   bool is_boundary() const { return boundary_ != Boundary::None; }
+  // Is the current frame the end of a stream
   bool is_eof() const { return boundary_ == Boundary::EndOfStream; }
-  bool is_in_begin_state() const { return state_ == &HPackParser::parse_begin; }
 
  private:
-  enum class BinaryState {
-    kNotBinary,
-    kBinaryBegin,
-    kBase64Byte0,
-    kBase64Byte1,
-    kBase64Byte2,
-    kBase64Byte3,
-  };
-
-  struct String {
-    bool copied_;
-    struct {
-      grpc_slice referenced;
-      struct {
-        char* str;
-        uint32_t length;
-        uint32_t capacity;
-      } copied;
-    } data_;
-
-    UnmanagedMemorySlice TakeExtern();
-    ManagedMemorySlice TakeIntern();
-    void AppendBytes(const uint8_t* data, size_t length);
-  };
-
-  using State = grpc_error_handle (HPackParser::*)(const uint8_t* beg,
-                                                   const uint8_t* end);
-
-  // Forward declarations for parsing states.
-  // These are keeping their old (C-style) names until a future refactor where
-  // they will be eliminated.
-  grpc_error_handle parse_next(const uint8_t* cur, const uint8_t* end);
-  grpc_error_handle parse_begin(const uint8_t* cur, const uint8_t* end);
-  grpc_error_handle parse_error(const uint8_t* cur, const uint8_t* end,
-                                grpc_error_handle error);
-  grpc_error_handle still_parse_error(const uint8_t* cur, const uint8_t* end);
-  grpc_error_handle parse_illegal_op(const uint8_t* cur, const uint8_t* end);
-
-  grpc_error_handle parse_string_prefix(const uint8_t* cur, const uint8_t* end);
-  grpc_error_handle parse_key_string(const uint8_t* cur, const uint8_t* end);
-  grpc_error_handle parse_value_string(const uint8_t* cur, const uint8_t* end,
-                                       bool is_binary);
-  grpc_error_handle parse_value_string_with_indexed_key(const uint8_t* cur,
-                                                        const uint8_t* end);
-  grpc_error_handle parse_value_string_with_literal_key(const uint8_t* cur,
-                                                        const uint8_t* end);
-  grpc_error_handle parse_stream_weight(const uint8_t* cur, const uint8_t* end);
-  grpc_error_handle parse_value0(const uint8_t* cur, const uint8_t* end);
-  grpc_error_handle parse_value1(const uint8_t* cur, const uint8_t* end);
-  grpc_error_handle parse_value2(const uint8_t* cur, const uint8_t* end);
-  grpc_error_handle parse_value3(const uint8_t* cur, const uint8_t* end);
-  grpc_error_handle parse_value4(const uint8_t* cur, const uint8_t* end);
-  grpc_error_handle parse_value5up(const uint8_t* cur, const uint8_t* end);
-  grpc_error_handle parse_stream_dep0(const uint8_t* cur, const uint8_t* end);
-  grpc_error_handle parse_stream_dep1(const uint8_t* cur, const uint8_t* end);
-  grpc_error_handle parse_stream_dep2(const uint8_t* cur, const uint8_t* end);
-  grpc_error_handle parse_stream_dep3(const uint8_t* cur, const uint8_t* end);
-
-  grpc_error_handle parse_indexed_field(const uint8_t* cur, const uint8_t* end);
-  grpc_error_handle parse_indexed_field_x(const uint8_t* cur,
-                                          const uint8_t* end);
-  grpc_error_handle parse_lithdr_incidx(const uint8_t* cur, const uint8_t* end);
-  grpc_error_handle parse_lithdr_incidx_x(const uint8_t* cur,
-                                          const uint8_t* end);
-  grpc_error_handle parse_lithdr_incidx_v(const uint8_t* cur,
-                                          const uint8_t* end);
-  grpc_error_handle parse_lithdr_notidx(const uint8_t* cur, const uint8_t* end);
-  grpc_error_handle parse_lithdr_notidx_x(const uint8_t* cur,
-                                          const uint8_t* end);
-  grpc_error_handle parse_lithdr_notidx_v(const uint8_t* cur,
-                                          const uint8_t* end);
-  grpc_error_handle parse_lithdr_nvridx(const uint8_t* cur, const uint8_t* end);
-  grpc_error_handle parse_lithdr_nvridx_x(const uint8_t* cur,
-                                          const uint8_t* end);
-  grpc_error_handle parse_lithdr_nvridx_v(const uint8_t* cur,
-                                          const uint8_t* end);
-  grpc_error_handle parse_max_tbl_size(const uint8_t* cur, const uint8_t* end);
-  grpc_error_handle parse_max_tbl_size_x(const uint8_t* cur,
-                                         const uint8_t* end);
-  grpc_error_handle parse_string(const uint8_t* cur, const uint8_t* end);
-  grpc_error_handle begin_parse_string(const uint8_t* cur, const uint8_t* end,
-                                       BinaryState binary, String* str);
-
-  grpc_error_handle finish_indexed_field(const uint8_t* cur,
-                                         const uint8_t* end);
-  grpc_error_handle finish_lithdr_incidx(const uint8_t* cur,
-                                         const uint8_t* end);
-  grpc_error_handle finish_lithdr_incidx_v(const uint8_t* cur,
-                                           const uint8_t* end);
-  grpc_error_handle finish_lithdr_notidx(const uint8_t* cur,
-                                         const uint8_t* end);
-  grpc_error_handle finish_lithdr_notidx_v(const uint8_t* cur,
-                                           const uint8_t* end);
-  grpc_error_handle finish_lithdr_nvridx(const uint8_t* cur,
-                                         const uint8_t* end);
-  grpc_error_handle finish_lithdr_nvridx_v(const uint8_t* cur,
-                                           const uint8_t* end);
-  grpc_error_handle finish_max_tbl_size(const uint8_t* cur, const uint8_t* end);
-  grpc_error_handle finish_str(const uint8_t* cur, const uint8_t* end);
-
-  enum class TableAction {
-    kAddToTable,
-    kOmitFromTable,
-  };
-
-  GPR_ATTRIBUTE_NOINLINE grpc_error_handle InvalidHPackIndexError();
-  GPR_ATTRIBUTE_NOINLINE void LogHeader(grpc_mdelem md);
-  grpc_error_handle AddHeaderToTable(grpc_mdelem md);
-  template <TableAction table_action>
-  grpc_error_handle FinishHeader(grpc_mdelem md);
-
-  grpc_mdelem GetPrecomputedMDForIndex();
-  void SetPrecomputedMDIndex(grpc_mdelem md);
-  bool IsBinaryLiteralHeader();
-  grpc_error_handle IsBinaryIndexedHeader(bool* is);
+  // Helper classes: see implementation
+  class Parser;
+  class Input;
+  class String;
 
-  grpc_error_handle AppendString(const uint8_t* cur, const uint8_t* end);
-  grpc_error_handle AppendHuffNibble(uint8_t nibble);
-  grpc_error_handle AppendHuffBytes(const uint8_t* cur, const uint8_t* end);
-  grpc_error_handle AppendStrBytes(const uint8_t* cur, const uint8_t* end);
+  grpc_error_handle ParseInput(Input input, bool is_last);
+  bool ParseInputInner(Input* input);
 
+  // Callback per header received
   Sink sink_;
-  grpc_error_handle last_error_;
-
-  // current parse state - or a function that implements it
-  State state_;
-  // future states dependent on the opening op code
-  const State* next_state_;
-  // what to do after skipping prioritization data
-  State after_prioritization_;
-  // the refcount of the slice that we're currently parsing
-  grpc_slice_refcount* current_slice_refcount_;
-  // the value we're currently parsing
-  union {
-    uint32_t* value;
-    String* str;
-  } parsing_;
-  // string parameters for each chunk
-  String key_;
-  String value_;
-  // parsed index
-  uint32_t index_;
-  // When we parse a value string, we determine the metadata element for a
-  // specific index, which we need again when we're finishing up with that
-  // header. To avoid calculating the metadata element for that index a second
-  // time at that stage, we cache (and invalidate) the element here.
-  grpc_mdelem md_for_index_;
-#ifndef NDEBUG
-  int64_t precomputed_md_index_;
-#endif
-  // length of source bytes for the currently parsing string
-  uint32_t strlen_;
-  // number of source bytes read for the currently parsing string
-  uint32_t strgot_;
-  // huffman decoding state
-  int16_t huff_state_;
-  // is the string being decoded binary?
-  BinaryState binary_;
-  // is the current string huffman encoded?
-  bool huff_;
-  // is a dynamic table update allowed?
-  uint8_t dynamic_table_updates_allowed_;
-  // set by higher layers, used by grpc_chttp2_header_parser_parse to signal
-  // it should append a metadata boundary at the end of frame
+
+  // Bytes that could not be parsed last parsing round
+  std::vector<uint8_t> unparsed_bytes_;
+  // Buffer kind of boundary
+  // TODO(ctiller): see if we can move this argument to Parse, and avoid
+  // buffering.
   Boundary boundary_;
-  uint32_t base64_buffer_;
+  // Buffer priority
+  // TODO(ctiller): see if we can move this argument to Parse, and avoid
+  // buffering.
+  Priority priority_;
+  uint8_t dynamic_table_updates_allowed_;
 
   // hpack table
-  grpc_chttp2_hptbl table_;
+  HPackTable table_;
 };
 
 }  // namespace grpc_core
diff --git a/src/core/ext/transport/chttp2/transport/hpack_parser_table.cc b/src/core/ext/transport/chttp2/transport/hpack_parser_table.cc
new file mode 100644 (file)
index 0000000..151fb29
--- /dev/null
@@ -0,0 +1,159 @@
+/*
+ *
+ * Copyright 2015 gRPC authors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ *
+ */
+
+#include <grpc/support/port_platform.h>
+
+#include "src/core/ext/transport/chttp2/transport/hpack_parser_table.h"
+
+#include <assert.h>
+#include <string.h>
+
+#include "absl/strings/str_format.h"
+
+#include <grpc/support/alloc.h>
+#include <grpc/support/log.h>
+
+#include "src/core/lib/debug/trace.h"
+#include "src/core/lib/gpr/murmur_hash.h"
+#include "src/core/lib/slice/slice_internal.h"
+#include "src/core/lib/surface/validate_metadata.h"
+#include "src/core/lib/transport/static_metadata.h"
+
+extern grpc_core::TraceFlag grpc_http_trace;
+
+namespace grpc_core {
+
+HPackTable::HPackTable() = default;
+
+HPackTable::~HPackTable() {
+  for (size_t i = 0; i < num_entries_; i++) {
+    GRPC_MDELEM_UNREF(entries_[(first_entry_ + i) % entries_.size()]);
+  }
+}
+
+/* Evict one element from the table */
+void HPackTable::EvictOne() {
+  grpc_mdelem first_entry = entries_[first_entry_];
+  size_t elem_bytes = GRPC_SLICE_LENGTH(GRPC_MDKEY(first_entry)) +
+                      GRPC_SLICE_LENGTH(GRPC_MDVALUE(first_entry)) +
+                      hpack_constants::kEntryOverhead;
+  GPR_ASSERT(elem_bytes <= mem_used_);
+  mem_used_ -= static_cast<uint32_t>(elem_bytes);
+  first_entry_ = ((first_entry_ + 1) % entries_.size());
+  num_entries_--;
+  GRPC_MDELEM_UNREF(first_entry);
+}
+
+void HPackTable::Rebuild(uint32_t new_cap) {
+  EntriesVec entries;
+  entries.resize(new_cap);
+  for (size_t i = 0; i < num_entries_; i++) {
+    entries[i] = entries_[(first_entry_ + i) % entries_.size()];
+  }
+  first_entry_ = 0;
+  entries_.swap(entries);
+}
+
+void HPackTable::SetMaxBytes(uint32_t max_bytes) {
+  if (max_bytes_ == max_bytes) {
+    return;
+  }
+  if (GRPC_TRACE_FLAG_ENABLED(grpc_http_trace)) {
+    gpr_log(GPR_INFO, "Update hpack parser max size to %d", max_bytes);
+  }
+  while (mem_used_ > max_bytes) {
+    EvictOne();
+  }
+  max_bytes_ = max_bytes;
+}
+
+grpc_error_handle HPackTable::SetCurrentTableSize(uint32_t bytes) {
+  if (current_table_bytes_ == bytes) {
+    return GRPC_ERROR_NONE;
+  }
+  if (bytes > max_bytes_) {
+    return GRPC_ERROR_CREATE_FROM_CPP_STRING(absl::StrFormat(
+        "Attempt to make hpack table %d bytes when max is %d bytes", bytes,
+        max_bytes_));
+  }
+  if (GRPC_TRACE_FLAG_ENABLED(grpc_http_trace)) {
+    gpr_log(GPR_INFO, "Update hpack parser table size to %d", bytes);
+  }
+  while (mem_used_ > bytes) {
+    EvictOne();
+  }
+  current_table_bytes_ = bytes;
+  max_entries_ = hpack_constants::EntriesForBytes(bytes);
+  if (max_entries_ > entries_.size()) {
+    Rebuild(max_entries_);
+  } else if (max_entries_ < entries_.size() / 3) {
+    // TODO(ctiller): move to resource quota system, only shrink under memory
+    // pressure
+    uint32_t new_cap =
+        std::max(max_entries_, static_cast<uint32_t>(kInlineEntries));
+    if (new_cap != entries_.size()) {
+      Rebuild(new_cap);
+    }
+  }
+  return GRPC_ERROR_NONE;
+}
+
+grpc_error_handle HPackTable::Add(grpc_mdelem md) {
+  /* determine how many bytes of buffer this entry represents */
+  size_t elem_bytes = GRPC_SLICE_LENGTH(GRPC_MDKEY(md)) +
+                      GRPC_SLICE_LENGTH(GRPC_MDVALUE(md)) +
+                      hpack_constants::kEntryOverhead;
+
+  if (current_table_bytes_ > max_bytes_) {
+    return GRPC_ERROR_CREATE_FROM_CPP_STRING(absl::StrFormat(
+        "HPACK max table size reduced to %d but not reflected by hpack "
+        "stream (still at %d)",
+        max_bytes_, current_table_bytes_));
+  }
+
+  // we can't add elements bigger than the max table size
+  if (elem_bytes > current_table_bytes_) {
+    // HPACK draft 10 section 4.4 states:
+    // If the size of the new entry is less than or equal to the maximum
+    // size, that entry is added to the table.  It is not an error to
+    // attempt to add an entry that is larger than the maximum size; an
+    // attempt to add an entry larger than the entire table causes
+    // the table to be emptied of all existing entries, and results in an
+    // empty table.
+    while (num_entries_) {
+      EvictOne();
+    }
+    return GRPC_ERROR_NONE;
+  }
+
+  // evict entries to ensure no overflow
+  while (elem_bytes > static_cast<size_t>(current_table_bytes_) - mem_used_) {
+    EvictOne();
+  }
+
+  // copy the finalized entry in
+  entries_[(first_entry_ + num_entries_) % entries_.size()] =
+      GRPC_MDELEM_REF(md);
+
+  // update accounting values
+  num_entries_++;
+  mem_used_ += static_cast<uint32_t>(elem_bytes);
+  return GRPC_ERROR_NONE;
+}
+
+}  // namespace grpc_core
diff --git a/src/core/ext/transport/chttp2/transport/hpack_parser_table.h b/src/core/ext/transport/chttp2/transport/hpack_parser_table.h
new file mode 100644 (file)
index 0000000..c1bdf6b
--- /dev/null
@@ -0,0 +1,130 @@
+/*
+ *
+ * Copyright 2015 gRPC authors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ *
+ */
+
+#ifndef GRPC_CORE_EXT_TRANSPORT_CHTTP2_TRANSPORT_HPACK_PARSER_TABLE_H
+#define GRPC_CORE_EXT_TRANSPORT_CHTTP2_TRANSPORT_HPACK_PARSER_TABLE_H
+
+#include <grpc/support/port_platform.h>
+
+#include <grpc/slice.h>
+
+#include "src/core/ext/transport/chttp2/transport/hpack_constants.h"
+#include "src/core/lib/gprpp/memory.h"
+#include "src/core/lib/iomgr/error.h"
+#include "src/core/lib/transport/metadata.h"
+#include "src/core/lib/transport/static_metadata.h"
+
+namespace grpc_core {
+
+// HPACK header table
+class HPackTable {
+ public:
+  HPackTable();
+  ~HPackTable();
+
+  HPackTable(const HPackTable&);
+  HPackTable& operator=(const HPackTable&);
+
+  void SetMaxBytes(uint32_t max_bytes);
+  grpc_error_handle SetCurrentTableSize(uint32_t bytes);
+
+  // Lookup, but don't ref.
+  grpc_mdelem Peek(uint32_t index) const { return Lookup<false>(index); }
+  // Lookup, taking a ref if found.
+  grpc_mdelem Fetch(uint32_t index) const { return Lookup<true>(index); }
+
+  // add a table entry to the index
+  grpc_error_handle Add(grpc_mdelem md) GRPC_MUST_USE_RESULT;
+
+  // Current entry count in the table.
+  uint32_t num_entries() const { return num_entries_; }
+
+ private:
+  enum { kInlineEntries = hpack_constants::kInitialTableEntries };
+  using EntriesVec = absl::InlinedVector<grpc_mdelem, kInlineEntries>;
+
+  /* lookup a table entry based on its hpack index */
+  template <bool take_ref>
+  grpc_mdelem Lookup(uint32_t index) const {
+    // Static table comes first, just return an entry from it.
+    // NB: This imposes the constraint that the first
+    // GRPC_CHTTP2_LAST_STATIC_ENTRY entries in the core static metadata table
+    // must follow the hpack standard. If that changes, we *must* not rely on
+    // reading the core static metadata table here; at that point we'd need our
+    // own singleton static metadata in the correct order.
+    if (index <= hpack_constants::kLastStaticEntry) {
+      return grpc_static_mdelem_manifested()[index - 1];
+    } else {
+      return LookupDynamic<take_ref>(index);
+    }
+  }
+
+  template <bool take_ref>
+  grpc_mdelem LookupDynamic(uint32_t index) const {
+    // Not static - find the value in the list of valid entries
+    const uint32_t tbl_index = index - (hpack_constants::kLastStaticEntry + 1);
+    if (tbl_index < num_entries_) {
+      uint32_t offset =
+          (num_entries_ - 1u - tbl_index + first_entry_) % entries_.size();
+      grpc_mdelem md = entries_[offset];
+      if (take_ref) {
+        GRPC_MDELEM_REF(md);
+      }
+      return md;
+    }
+    // Invalid entry: return error
+    return GRPC_MDNULL;
+  }
+
+  void EvictOne();
+  void Rebuild(uint32_t new_cap);
+
+  // The first used entry in ents.
+  uint32_t first_entry_ = 0;
+  // How many entries are in the table.
+  uint32_t num_entries_ = 0;
+  // The amount of memory used by the table, according to the hpack algorithm
+  uint32_t mem_used_ = 0;
+  // The max memory allowed to be used by the table, according to the hpack
+  // algorithm.
+  uint32_t max_bytes_ = hpack_constants::kInitialTableSize;
+  // The currently agreed size of the table, according to the hpack algorithm.
+  uint32_t current_table_bytes_ = hpack_constants::kInitialTableSize;
+  // Maximum number of entries we could possibly fit in the table, given defined
+  // overheads.
+  uint32_t max_entries_ = hpack_constants::kInitialTableEntries;
+  // HPack table entries
+  EntriesVec entries_{hpack_constants::kInitialTableEntries};
+};
+
+}  // namespace grpc_core
+
+/* Returns the static hpack table index that corresponds to /a elem. Returns 0
+  if /a elem is not statically stored or if it is not in the static hpack
+  table */
+inline uintptr_t grpc_chttp2_get_static_hpack_table_index(grpc_mdelem md) {
+  uintptr_t index =
+      reinterpret_cast<grpc_core::StaticMetadata*>(GRPC_MDELEM_DATA(md)) -
+      grpc_static_mdelem_table();
+  if (index < grpc_core::hpack_constants::kLastStaticEntry) {
+    return index + 1;  // Hpack static metadata element indices start at 1
+  }
+  return 0;
+}
+
+#endif /* GRPC_CORE_EXT_TRANSPORT_CHTTP2_TRANSPORT_HPACK_PARSER_TABLE_H */
diff --git a/src/core/ext/transport/chttp2/transport/hpack_table.cc b/src/core/ext/transport/chttp2/transport/hpack_table.cc
deleted file mode 100644 (file)
index 696176b..0000000
+++ /dev/null
@@ -1,243 +0,0 @@
-/*
- *
- * Copyright 2015 gRPC authors.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- *
- */
-
-#include <grpc/support/port_platform.h>
-
-#include "src/core/ext/transport/chttp2/transport/hpack_table.h"
-
-#include <assert.h>
-#include <string.h>
-
-#include "absl/strings/str_format.h"
-
-#include <grpc/support/alloc.h>
-#include <grpc/support/log.h>
-
-#include "src/core/lib/debug/trace.h"
-#include "src/core/lib/gpr/murmur_hash.h"
-#include "src/core/lib/slice/slice_internal.h"
-#include "src/core/lib/surface/validate_metadata.h"
-#include "src/core/lib/transport/static_metadata.h"
-
-extern grpc_core::TraceFlag grpc_http_trace;
-
-void grpc_chttp2_hptbl_destroy(grpc_chttp2_hptbl* tbl) {
-  size_t i;
-  for (i = 0; i < tbl->num_ents; i++) {
-    GRPC_MDELEM_UNREF(tbl->ents[(tbl->first_ent + i) % tbl->cap_entries]);
-  }
-  gpr_free(tbl->ents);
-  tbl->ents = nullptr;
-}
-
-template <bool take_ref>
-static grpc_mdelem lookup_dynamic_index(const grpc_chttp2_hptbl* tbl,
-                                        uint32_t tbl_index) {
-  /* Not static - find the value in the list of valid entries */
-  tbl_index -= (GRPC_CHTTP2_LAST_STATIC_ENTRY + 1);
-  if (tbl_index < tbl->num_ents) {
-    uint32_t offset =
-        (tbl->num_ents - 1u - tbl_index + tbl->first_ent) % tbl->cap_entries;
-    grpc_mdelem md = tbl->ents[offset];
-    if (take_ref) {
-      GRPC_MDELEM_REF(md);
-    }
-    return md;
-  }
-  /* Invalid entry: return error */
-  return GRPC_MDNULL;
-}
-
-grpc_mdelem grpc_chttp2_hptbl_lookup_dynamic_index(const grpc_chttp2_hptbl* tbl,
-                                                   uint32_t tbl_index) {
-  return lookup_dynamic_index<false>(tbl, tbl_index);
-}
-
-grpc_mdelem grpc_chttp2_hptbl_lookup_ref_dynamic_index(
-    const grpc_chttp2_hptbl* tbl, uint32_t tbl_index) {
-  return lookup_dynamic_index<true>(tbl, tbl_index);
-}
-
-/* Evict one element from the table */
-static void evict1(grpc_chttp2_hptbl* tbl) {
-  grpc_mdelem first_ent = tbl->ents[tbl->first_ent];
-  size_t elem_bytes = GRPC_SLICE_LENGTH(GRPC_MDKEY(first_ent)) +
-                      GRPC_SLICE_LENGTH(GRPC_MDVALUE(first_ent)) +
-                      GRPC_CHTTP2_HPACK_ENTRY_OVERHEAD;
-  GPR_ASSERT(elem_bytes <= tbl->mem_used);
-  tbl->mem_used -= static_cast<uint32_t>(elem_bytes);
-  tbl->first_ent = ((tbl->first_ent + 1) % tbl->cap_entries);
-  tbl->num_ents--;
-  GRPC_MDELEM_UNREF(first_ent);
-}
-
-static void rebuild_ents(grpc_chttp2_hptbl* tbl, uint32_t new_cap) {
-  grpc_mdelem* ents =
-      static_cast<grpc_mdelem*>(gpr_malloc(sizeof(*ents) * new_cap));
-  uint32_t i;
-
-  for (i = 0; i < tbl->num_ents; i++) {
-    ents[i] = tbl->ents[(tbl->first_ent + i) % tbl->cap_entries];
-  }
-  gpr_free(tbl->ents);
-  tbl->ents = ents;
-  tbl->cap_entries = new_cap;
-  tbl->first_ent = 0;
-}
-
-void grpc_chttp2_hptbl_set_max_bytes(grpc_chttp2_hptbl* tbl,
-                                     uint32_t max_bytes) {
-  if (tbl->max_bytes == max_bytes) {
-    return;
-  }
-  if (GRPC_TRACE_FLAG_ENABLED(grpc_http_trace)) {
-    gpr_log(GPR_INFO, "Update hpack parser max size to %d", max_bytes);
-  }
-  while (tbl->mem_used > max_bytes) {
-    evict1(tbl);
-  }
-  tbl->max_bytes = max_bytes;
-}
-
-grpc_error_handle grpc_chttp2_hptbl_set_current_table_size(
-    grpc_chttp2_hptbl* tbl, uint32_t bytes) {
-  if (tbl->current_table_bytes == bytes) {
-    return GRPC_ERROR_NONE;
-  }
-  if (bytes > tbl->max_bytes) {
-    return GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-        absl::StrFormat(
-            "Attempt to make hpack table %d bytes when max is %d bytes", bytes,
-            tbl->max_bytes)
-            .c_str());
-  }
-  if (GRPC_TRACE_FLAG_ENABLED(grpc_http_trace)) {
-    gpr_log(GPR_INFO, "Update hpack parser table size to %d", bytes);
-  }
-  while (tbl->mem_used > bytes) {
-    evict1(tbl);
-  }
-  tbl->current_table_bytes = bytes;
-  tbl->max_entries = grpc_chttp2_hptbl::entries_for_bytes(bytes);
-  if (tbl->max_entries > tbl->cap_entries) {
-    rebuild_ents(tbl, GPR_MAX(tbl->max_entries, 2 * tbl->cap_entries));
-  } else if (tbl->max_entries < tbl->cap_entries / 3) {
-    uint32_t new_cap = GPR_MAX(tbl->max_entries, 16u);
-    if (new_cap != tbl->cap_entries) {
-      rebuild_ents(tbl, new_cap);
-    }
-  }
-  return GRPC_ERROR_NONE;
-}
-
-grpc_error_handle grpc_chttp2_hptbl_add(grpc_chttp2_hptbl* tbl,
-                                        grpc_mdelem md) {
-  /* determine how many bytes of buffer this entry represents */
-  size_t elem_bytes = GRPC_SLICE_LENGTH(GRPC_MDKEY(md)) +
-                      GRPC_SLICE_LENGTH(GRPC_MDVALUE(md)) +
-                      GRPC_CHTTP2_HPACK_ENTRY_OVERHEAD;
-
-  if (tbl->current_table_bytes > tbl->max_bytes) {
-    return GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-        absl::StrFormat(
-            "HPACK max table size reduced to %d but not reflected by hpack "
-            "stream (still at %d)",
-            tbl->max_bytes, tbl->current_table_bytes)
-            .c_str());
-  }
-
-  /* we can't add elements bigger than the max table size */
-  if (elem_bytes > tbl->current_table_bytes) {
-    /* HPACK draft 10 section 4.4 states:
-     * If the size of the new entry is less than or equal to the maximum
-     * size, that entry is added to the table.  It is not an error to
-     * attempt to add an entry that is larger than the maximum size; an
-     * attempt to add an entry larger than the entire table causes
-     * the table
-     * to be emptied of all existing entries, and results in an
-     * empty table.
-     */
-    while (tbl->num_ents) {
-      evict1(tbl);
-    }
-    return GRPC_ERROR_NONE;
-  }
-
-  /* evict entries to ensure no overflow */
-  while (elem_bytes >
-         static_cast<size_t>(tbl->current_table_bytes) - tbl->mem_used) {
-    evict1(tbl);
-  }
-
-  /* copy the finalized entry in */
-  tbl->ents[(tbl->first_ent + tbl->num_ents) % tbl->cap_entries] =
-      GRPC_MDELEM_REF(md);
-
-  /* update accounting values */
-  tbl->num_ents++;
-  tbl->mem_used += static_cast<uint32_t>(elem_bytes);
-  return GRPC_ERROR_NONE;
-}
-
-grpc_chttp2_hptbl_find_result grpc_chttp2_hptbl_find(
-    const grpc_chttp2_hptbl* tbl, grpc_mdelem md) {
-  grpc_chttp2_hptbl_find_result r = {0, 0};
-  uint32_t i;
-
-  /* See if the string is in the static table */
-  for (i = 0; i < GRPC_CHTTP2_LAST_STATIC_ENTRY; i++) {
-    grpc_mdelem ent = grpc_static_mdelem_manifested()[i];
-    if (!grpc_slice_eq(GRPC_MDKEY(md), GRPC_MDKEY(ent))) continue;
-    r.index = i + 1u;
-    r.has_value = grpc_slice_eq(GRPC_MDVALUE(md), GRPC_MDVALUE(ent));
-    if (r.has_value) return r;
-  }
-
-  /* Scan the dynamic table */
-  for (i = 0; i < tbl->num_ents; i++) {
-    uint32_t idx = static_cast<uint32_t>(tbl->num_ents - i +
-                                         GRPC_CHTTP2_LAST_STATIC_ENTRY);
-    grpc_mdelem ent = tbl->ents[(tbl->first_ent + i) % tbl->cap_entries];
-    if (!grpc_slice_eq(GRPC_MDKEY(md), GRPC_MDKEY(ent))) continue;
-    r.index = idx;
-    r.has_value = grpc_slice_eq(GRPC_MDVALUE(md), GRPC_MDVALUE(ent));
-    if (r.has_value) return r;
-  }
-
-  return r;
-}
-
-static size_t get_base64_encoded_size(size_t raw_length) {
-  static const uint8_t tail_xtra[3] = {0, 2, 3};
-  return raw_length / 3 * 4 + tail_xtra[raw_length % 3];
-}
-
-size_t grpc_chttp2_get_size_in_hpack_table(grpc_mdelem elem,
-                                           bool use_true_binary_metadata) {
-  const uint8_t* key_buf = GRPC_SLICE_START_PTR(GRPC_MDKEY(elem));
-  size_t key_len = GRPC_SLICE_LENGTH(GRPC_MDKEY(elem));
-  size_t overhead_and_key = 32 + key_len;
-  size_t value_len = GRPC_SLICE_LENGTH(GRPC_MDVALUE(elem));
-  if (grpc_key_is_binary_header(key_buf, key_len)) {
-    return overhead_and_key + (use_true_binary_metadata
-                                   ? value_len + 1
-                                   : get_base64_encoded_size(value_len));
-  } else {
-    return overhead_and_key + value_len;
-  }
-}
diff --git a/src/core/ext/transport/chttp2/transport/hpack_table.h b/src/core/ext/transport/chttp2/transport/hpack_table.h
deleted file mode 100644 (file)
index 14a7793..0000000
+++ /dev/null
@@ -1,148 +0,0 @@
-/*
- *
- * Copyright 2015 gRPC authors.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- *
- */
-
-#ifndef GRPC_CORE_EXT_TRANSPORT_CHTTP2_TRANSPORT_HPACK_TABLE_H
-#define GRPC_CORE_EXT_TRANSPORT_CHTTP2_TRANSPORT_HPACK_TABLE_H
-
-#include <grpc/support/port_platform.h>
-
-#include <grpc/slice.h>
-#include "src/core/lib/gprpp/memory.h"
-#include "src/core/lib/iomgr/error.h"
-#include "src/core/lib/transport/metadata.h"
-#include "src/core/lib/transport/static_metadata.h"
-
-/* HPACK header table */
-
-/* last index in the static table */
-#define GRPC_CHTTP2_LAST_STATIC_ENTRY 61
-
-/* Initial table size as per the spec */
-#define GRPC_CHTTP2_INITIAL_HPACK_TABLE_SIZE 4096
-/* Maximum table size that we'll use */
-#define GRPC_CHTTP2_MAX_HPACK_TABLE_SIZE GRPC_CHTTP2_INITIAL_HPACK_TABLE_SIZE
-/* Per entry overhead bytes as per the spec */
-#define GRPC_CHTTP2_HPACK_ENTRY_OVERHEAD 32
-#if 0
-/* Maximum number of entries we could possibly fit in the table, given defined
-   overheads */
-#define GRPC_CHTTP2_MAX_TABLE_COUNT                                            \
-  ((GRPC_CHTTP2_MAX_HPACK_TABLE_SIZE + GRPC_CHTTP2_HPACK_ENTRY_OVERHEAD - 1) / \
-   GRPC_CHTTP2_HPACK_ENTRY_OVERHEAD)
-#endif
-
-/* hpack decoder table */
-struct grpc_chttp2_hptbl {
-  static uint32_t entries_for_bytes(uint32_t bytes) {
-    return (bytes + GRPC_CHTTP2_HPACK_ENTRY_OVERHEAD - 1) /
-           GRPC_CHTTP2_HPACK_ENTRY_OVERHEAD;
-  }
-  static constexpr uint32_t kInitialCapacity =
-      (GRPC_CHTTP2_INITIAL_HPACK_TABLE_SIZE + GRPC_CHTTP2_HPACK_ENTRY_OVERHEAD -
-       1) /
-      GRPC_CHTTP2_HPACK_ENTRY_OVERHEAD;
-
-  grpc_chttp2_hptbl() {
-    GPR_DEBUG_ASSERT(!ents);
-    constexpr uint32_t AllocSize = sizeof(*ents) * kInitialCapacity;
-    ents = static_cast<grpc_mdelem*>(gpr_malloc(AllocSize));
-    memset(ents, 0, AllocSize);
-  }
-
-  /* the first used entry in ents */
-  uint32_t first_ent = 0;
-  /* how many entries are in the table */
-  uint32_t num_ents = 0;
-  /* the amount of memory used by the table, according to the hpack algorithm */
-  uint32_t mem_used = 0;
-  /* the max memory allowed to be used by the table, according to the hpack
-     algorithm */
-  uint32_t max_bytes = GRPC_CHTTP2_INITIAL_HPACK_TABLE_SIZE;
-  /* the currently agreed size of the table, according to the hpack algorithm */
-  uint32_t current_table_bytes = GRPC_CHTTP2_INITIAL_HPACK_TABLE_SIZE;
-  /* Maximum number of entries we could possibly fit in the table, given defined
-     overheads */
-  uint32_t max_entries = kInitialCapacity;
-  /* Number of entries allocated in ents */
-  uint32_t cap_entries = kInitialCapacity;
-  /* a circular buffer of headers - this is stored in the opposite order to
-     what hpack specifies, in order to simplify table management a little...
-     meaning lookups need to SUBTRACT from the end position */
-  grpc_mdelem* ents = nullptr;
-};
-
-void grpc_chttp2_hptbl_destroy(grpc_chttp2_hptbl* tbl);
-void grpc_chttp2_hptbl_set_max_bytes(grpc_chttp2_hptbl* tbl,
-                                     uint32_t max_bytes);
-grpc_error_handle grpc_chttp2_hptbl_set_current_table_size(
-    grpc_chttp2_hptbl* tbl, uint32_t bytes);
-
-/* lookup a table entry based on its hpack index */
-grpc_mdelem grpc_chttp2_hptbl_lookup_dynamic_index(const grpc_chttp2_hptbl* tbl,
-                                                   uint32_t tbl_index);
-grpc_mdelem grpc_chttp2_hptbl_lookup_ref_dynamic_index(
-    const grpc_chttp2_hptbl* tbl, uint32_t tbl_index);
-template <bool take_ref = false>
-inline grpc_mdelem grpc_chttp2_hptbl_lookup(const grpc_chttp2_hptbl* tbl,
-                                            uint32_t index) {
-  /* Static table comes first, just return an entry from it.
-     NB: This imposes the constraint that the first
-     GRPC_CHTTP2_LAST_STATIC_ENTRY entries in the core static metadata table
-     must follow the hpack standard. If that changes, we *must* not rely on
-     reading the core static metadata table here; at that point we'd need our
-     own singleton static metadata in the correct order. */
-  if (index <= GRPC_CHTTP2_LAST_STATIC_ENTRY) {
-    return grpc_static_mdelem_manifested()[index - 1];
-  } else {
-    if (take_ref) {
-      return grpc_chttp2_hptbl_lookup_ref_dynamic_index(tbl, index);
-    } else {
-      return grpc_chttp2_hptbl_lookup_dynamic_index(tbl, index);
-    }
-  }
-}
-/* add a table entry to the index */
-grpc_error_handle grpc_chttp2_hptbl_add(grpc_chttp2_hptbl* tbl,
-                                        grpc_mdelem md) GRPC_MUST_USE_RESULT;
-
-size_t grpc_chttp2_get_size_in_hpack_table(grpc_mdelem elem,
-                                           bool use_true_binary_metadata);
-
-/* Returns the static hpack table index that corresponds to /a elem. Returns 0
-  if /a elem is not statically stored or if it is not in the static hpack
-  table */
-inline uintptr_t grpc_chttp2_get_static_hpack_table_index(grpc_mdelem md) {
-  uintptr_t index =
-      reinterpret_cast<grpc_core::StaticMetadata*>(GRPC_MDELEM_DATA(md)) -
-      grpc_static_mdelem_table();
-  if (index < GRPC_CHTTP2_LAST_STATIC_ENTRY) {
-    return index + 1;  // Hpack static metadata element indices start at 1
-  }
-  return 0;
-}
-
-/* Find a key/value pair in the table... returns the index in the table of the
-   most similar entry, or 0 if the value was not found */
-struct grpc_chttp2_hptbl_find_result {
-  uint32_t index;
-  int has_value;
-};
-grpc_chttp2_hptbl_find_result grpc_chttp2_hptbl_find(
-    const grpc_chttp2_hptbl* tbl, grpc_mdelem md);
-
-#endif /* GRPC_CORE_EXT_TRANSPORT_CHTTP2_TRANSPORT_HPACK_TABLE_H */
diff --git a/src/core/ext/transport/chttp2/transport/hpack_utils.cc b/src/core/ext/transport/chttp2/transport/hpack_utils.cc
new file mode 100644 (file)
index 0000000..fb1d2cb
--- /dev/null
@@ -0,0 +1,46 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#include <grpc/support/port_platform.h>
+
+#include "src/core/ext/transport/chttp2/transport/hpack_utils.h"
+
+#include "src/core/lib/surface/validate_metadata.h"
+
+namespace grpc_core {
+
+namespace {
+size_t Base64EncodedSize(size_t raw_length) {
+  static constexpr uint8_t tail_xtra[3] = {0, 2, 3};
+  return raw_length / 3 * 4 + tail_xtra[raw_length % 3];
+}
+}  // namespace
+
+// Return the size occupied by some metadata in the HPACK table.
+size_t MetadataSizeInHPackTable(grpc_mdelem elem,
+                                bool use_true_binary_metadata) {
+  const uint8_t* key_buf = GRPC_SLICE_START_PTR(GRPC_MDKEY(elem));
+  size_t key_len = GRPC_SLICE_LENGTH(GRPC_MDKEY(elem));
+  size_t overhead_and_key = 32 + key_len;
+  size_t value_len = GRPC_SLICE_LENGTH(GRPC_MDVALUE(elem));
+  if (grpc_key_is_binary_header(key_buf, key_len)) {
+    return overhead_and_key + (use_true_binary_metadata
+                                   ? value_len + 1
+                                   : Base64EncodedSize(value_len));
+  } else {
+    return overhead_and_key + value_len;
+  }
+}
+
+}  // namespace grpc_core
diff --git a/src/core/ext/transport/chttp2/transport/hpack_utils.h b/src/core/ext/transport/chttp2/transport/hpack_utils.h
new file mode 100644 (file)
index 0000000..a1c9baa
--- /dev/null
@@ -0,0 +1,30 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#ifndef GRPC_CORE_EXT_TRANSPORT_CHTTP2_TRANSPORT_HPACK_UTILS_H
+#define GRPC_CORE_EXT_TRANSPORT_CHTTP2_TRANSPORT_HPACK_UTILS_H
+
+#include <grpc/support/port_platform.h>
+
+#include "src/core/lib/transport/metadata.h"
+
+namespace grpc_core {
+
+// Return the size occupied by some metadata in the HPACK table.
+size_t MetadataSizeInHPackTable(grpc_mdelem elem,
+                                bool use_true_binary_metadata);
+
+}  // namespace grpc_core
+
+#endif  // GRPC_CORE_EXT_TRANSPORT_CHTTP2_TRANSPORT_HPACK_UTILS_H
index 361b7b7..c803d79 100644 (file)
 
 #include <string.h>
 
-#include "src/core/ext/transport/chttp2/transport/internal.h"
-
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 
+#include "src/core/ext/transport/chttp2/transport/internal.h"
+
 grpc_error_handle grpc_chttp2_incoming_metadata_buffer_add(
     grpc_chttp2_incoming_metadata_buffer* buffer, grpc_mdelem elem) {
   buffer->size += GRPC_MDELEM_LENGTH(elem);
index 53d7f56..ddf8ea2 100644 (file)
@@ -345,7 +345,7 @@ struct grpc_chttp2_transport {
   /** data to write now */
   grpc_slice_buffer outbuf;
   /** hpack encoding */
-  grpc_chttp2_hpack_compressor hpack_compressor;
+  grpc_core::HPackCompressor hpack_compressor;
   /** is this a client? */
   bool is_client;
 
@@ -555,7 +555,7 @@ struct grpc_chttp2_stream {
   grpc_metadata_batch* recv_initial_metadata;
   grpc_closure* recv_initial_metadata_ready = nullptr;
   bool* trailing_metadata_available = nullptr;
-  grpc_core::OrphanablePtr<grpc_core::ByteStream>* recv_message;
+  grpc_core::OrphanablePtr<grpc_core::ByteStream>* recv_message = nullptr;
   bool* call_failed_before_recv_message = nullptr;
   grpc_closure* recv_message_ready = nullptr;
   grpc_metadata_batch* recv_trailing_metadata;
index 5d91335..aa2765c 100644 (file)
@@ -18,8 +18,6 @@
 
 #include <grpc/support/port_platform.h>
 
-#include "src/core/ext/transport/chttp2/transport/internal.h"
-
 #include <string.h>
 
 #include "absl/strings/str_cat.h"
@@ -28,6 +26,7 @@
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 
+#include "src/core/ext/transport/chttp2/transport/internal.h"
 #include "src/core/lib/profiling/timers.h"
 #include "src/core/lib/slice/slice_string_helpers.h"
 #include "src/core/lib/slice/slice_utils.h"
@@ -91,15 +90,13 @@ grpc_error_handle grpc_chttp2_perform_read(grpc_chttp2_transport* t,
     case GRPC_DTS_CLIENT_PREFIX_23:
       while (cur != end && t->deframe_state != GRPC_DTS_FH_0) {
         if (*cur != GRPC_CHTTP2_CLIENT_CONNECT_STRING[t->deframe_state]) {
-          return GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-              absl::StrFormat(
-                  "Connect string mismatch: expected '%c' (%d) got '%c' (%d) "
-                  "at byte %d",
-                  GRPC_CHTTP2_CLIENT_CONNECT_STRING[t->deframe_state],
-                  static_cast<int>(static_cast<uint8_t>(
-                      GRPC_CHTTP2_CLIENT_CONNECT_STRING[t->deframe_state])),
-                  *cur, static_cast<int>(*cur), t->deframe_state)
-                  .c_str());
+          return GRPC_ERROR_CREATE_FROM_CPP_STRING(absl::StrFormat(
+              "Connect string mismatch: expected '%c' (%d) got '%c' (%d) "
+              "at byte %d",
+              GRPC_CHTTP2_CLIENT_CONNECT_STRING[t->deframe_state],
+              static_cast<int>(static_cast<uint8_t>(
+                  GRPC_CHTTP2_CLIENT_CONNECT_STRING[t->deframe_state])),
+              *cur, static_cast<int>(*cur), t->deframe_state));
         }
         ++cur;
         // NOLINTNEXTLINE(bugprone-misplaced-widening-cast)
@@ -198,12 +195,11 @@ grpc_error_handle grpc_chttp2_perform_read(grpc_chttp2_transport* t,
                  t->incoming_frame_size >
                      t->settings[GRPC_ACKED_SETTINGS]
                                 [GRPC_CHTTP2_SETTINGS_MAX_FRAME_SIZE]) {
-        return GRPC_ERROR_CREATE_FROM_COPIED_STRING(
+        return GRPC_ERROR_CREATE_FROM_CPP_STRING(
             absl::StrFormat("Frame size %d is larger than max frame size %d",
                             t->incoming_frame_size,
                             t->settings[GRPC_ACKED_SETTINGS]
-                                       [GRPC_CHTTP2_SETTINGS_MAX_FRAME_SIZE])
-                .c_str());
+                                       [GRPC_CHTTP2_SETTINGS_MAX_FRAME_SIZE]));
       }
       if (++cur == end) {
         return GRPC_ERROR_NONE;
@@ -257,27 +253,22 @@ grpc_error_handle grpc_chttp2_perform_read(grpc_chttp2_transport* t,
 static grpc_error_handle init_frame_parser(grpc_chttp2_transport* t) {
   if (t->is_first_frame &&
       t->incoming_frame_type != GRPC_CHTTP2_FRAME_SETTINGS) {
-    return GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-        absl::StrCat(
-            "Expected SETTINGS frame as the first frame, got frame type ",
-            t->incoming_frame_type)
-            .c_str());
+    return GRPC_ERROR_CREATE_FROM_CPP_STRING(absl::StrCat(
+        "Expected SETTINGS frame as the first frame, got frame type ",
+        t->incoming_frame_type));
   }
   t->is_first_frame = false;
   if (t->expect_continuation_stream_id != 0) {
     if (t->incoming_frame_type != GRPC_CHTTP2_FRAME_CONTINUATION) {
-      return GRPC_ERROR_CREATE_FROM_COPIED_STRING(
+      return GRPC_ERROR_CREATE_FROM_CPP_STRING(
           absl::StrFormat("Expected CONTINUATION frame, got frame type %02x",
-                          t->incoming_frame_type)
-              .c_str());
+                          t->incoming_frame_type));
     }
     if (t->expect_continuation_stream_id != t->incoming_stream_id) {
-      return GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-          absl::StrFormat(
-              "Expected CONTINUATION frame for grpc_chttp2_stream %08x, got "
-              "grpc_chttp2_stream %08x",
-              t->expect_continuation_stream_id, t->incoming_stream_id)
-              .c_str());
+      return GRPC_ERROR_CREATE_FROM_CPP_STRING(absl::StrFormat(
+          "Expected CONTINUATION frame for grpc_chttp2_stream %08x, got "
+          "grpc_chttp2_stream %08x",
+          t->expect_continuation_stream_id, t->incoming_stream_id));
     }
     return init_header_frame_parser(t, 1);
   }
@@ -767,8 +758,7 @@ static grpc_error_handle init_settings_frame_parser(grpc_chttp2_transport* t) {
   if (t->incoming_frame_flags & GRPC_CHTTP2_FLAG_ACK) {
     memcpy(t->settings[GRPC_ACKED_SETTINGS], t->settings[GRPC_SENT_SETTINGS],
            GRPC_CHTTP2_NUM_SETTINGS * sizeof(uint32_t));
-    grpc_chttp2_hptbl_set_max_bytes(
-        t->hpack_parser.hpack_table(),
+    t->hpack_parser.hpack_table()->SetMaxBytes(
         t->settings[GRPC_ACKED_SETTINGS]
                    [GRPC_CHTTP2_SETTINGS_HEADER_TABLE_SIZE]);
     t->sent_local_settings = false;
diff --git a/src/core/ext/transport/chttp2/transport/popularity_count.h b/src/core/ext/transport/chttp2/transport/popularity_count.h
new file mode 100644 (file)
index 0000000..1e2c28e
--- /dev/null
@@ -0,0 +1,60 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#ifndef GRPC_CORE_EXT_TRANSPORT_CHTTP2_TRANSPORT_POPULARITY_COUNT_H
+#define GRPC_CORE_EXT_TRANSPORT_CHTTP2_TRANSPORT_POPULARITY_COUNT_H
+
+#include <grpc/impl/codegen/port_platform.h>
+
+namespace grpc_core {
+
+// filter tables for elems: this tables provides an approximate
+// popularity count for particular hashes, and are used to determine whether
+// a new literal should be added to the compression table or not.
+// They track a single integer that counts how often a particular value has
+// been seen. When that count reaches max (255), all values are halved. */
+template <uint8_t kElems>
+class PopularityCount {
+ public:
+  PopularityCount() : sum_{0}, elems_{} {}
+
+  // increment a filter count, halve all counts if one element reaches max
+  // return true if this element seems to be popular, false otherwise
+  bool AddElement(uint8_t idx) {
+    elems_[idx]++;
+    if (GPR_LIKELY(elems_[idx] < 255)) {
+      sum_++;
+    } else {
+      HalveFilter();
+    }
+    return elems_[idx] >= 2 * sum_ / kElems;
+  }
+
+ private:
+  // halve all counts because an element reached max
+  void HalveFilter() {
+    sum_ = 0;
+    for (int i = 0; i < kElems; i++) {
+      elems_[i] /= 2;
+      sum_ += elems_[i];
+    }
+  }
+
+  uint32_t sum_;
+  uint8_t elems_[kElems];
+};
+
+}  // namespace grpc_core
+
+#endif /* GRPC_CORE_EXT_TRANSPORT_CHTTP2_TRANSPORT_POPULARITY_COUNT_H */
index db79899..9c3c3e6 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
+#include <grpc/support/log.h>
+
 #include "src/core/ext/transport/chttp2/transport/chttp2_transport.h"
 #include "src/core/ext/transport/chttp2/transport/internal.h"
 
-#include <grpc/support/log.h>
-
 static const char* stream_list_id_string(grpc_chttp2_stream_list_id id) {
   switch (id) {
     case GRPC_CHTTP2_LIST_WRITABLE:
index 0d414eb..6478235 100644 (file)
@@ -22,7 +22,9 @@
 
 #include "absl/base/attributes.h"
 
-uint32_t grpc_chttp2_hpack_varint_length(uint32_t tail_value) {
+namespace grpc_core {
+
+uint32_t VarintLength(uint32_t tail_value) {
   if (tail_value < (1 << 7)) {
     return 2;
   } else if (tail_value < (1 << 14)) {
@@ -36,8 +38,8 @@ uint32_t grpc_chttp2_hpack_varint_length(uint32_t tail_value) {
   }
 }
 
-void grpc_chttp2_hpack_write_varint_tail(uint32_t tail_value, uint8_t* target,
-                                         uint32_t tail_length) {
+void VarintWriteTail(uint32_t tail_value, uint8_t* target,
+                     uint32_t tail_length) {
   switch (tail_length) {
     case 5:
       target[4] = static_cast<uint8_t>((tail_value >> 28) | 0x80);
@@ -56,3 +58,5 @@ void grpc_chttp2_hpack_write_varint_tail(uint32_t tail_value, uint8_t* target,
   }
   target[tail_length - 1] &= 0x7f;
 }
+
+}  // namespace grpc_core
index 5a2b670..d4ba487 100644 (file)
 
 /* Helpers for hpack varint encoding */
 
+namespace grpc_core {
+
+/* maximum value that can be bitpacked with the opcode if the opcode has a
+   prefix of length prefix_bits */
+constexpr uint32_t MaxInVarintPrefix(uint8_t prefix_bits) {
+  return (1 << (8 - prefix_bits)) - 1;
+}
+
 /* length of a value that needs varint tail encoding (it's bigger than can be
    bitpacked into the opcode byte) - returned value includes the length of the
    opcode byte */
-uint32_t grpc_chttp2_hpack_varint_length(uint32_t tail_value);
+uint32_t VarintLength(uint32_t tail_value);
+void VarintWriteTail(uint32_t tail_value, uint8_t* target,
+                     uint32_t tail_length);
 
-void grpc_chttp2_hpack_write_varint_tail(uint32_t tail_value, uint8_t* target,
-                                         uint32_t tail_length);
+template <uint8_t kPrefixBits>
+class VarintWriter {
+ public:
+  static constexpr uint32_t kMaxInPrefix = MaxInVarintPrefix(kPrefixBits);
 
-/* maximum value that can be bitpacked with the opcode if the opcode has a
-   prefix
-   of length prefix_bits */
-#define GRPC_CHTTP2_MAX_IN_PREFIX(prefix_bits) \
-  ((uint32_t)((1 << (8 - (prefix_bits))) - 1))
-
-/* length required to bitpack a value */
-#define GRPC_CHTTP2_VARINT_LENGTH(n, prefix_bits) \
-  ((n) < GRPC_CHTTP2_MAX_IN_PREFIX(prefix_bits)   \
-       ? 1u                                       \
-       : grpc_chttp2_hpack_varint_length(         \
-             (n)-GRPC_CHTTP2_MAX_IN_PREFIX(prefix_bits)))
-
-#define GRPC_CHTTP2_WRITE_VARINT(n, prefix_bits, prefix_or, target, length)   \
-  do {                                                                        \
-    uint8_t* tgt = target;                                                    \
-    if ((length) == 1u) {                                                     \
-      (tgt)[0] = (uint8_t)((prefix_or) | (n));                                \
-    } else {                                                                  \
-      (tgt)[0] =                                                              \
-          (prefix_or) | (uint8_t)GRPC_CHTTP2_MAX_IN_PREFIX(prefix_bits);      \
-      grpc_chttp2_hpack_write_varint_tail(                                    \
-          (n)-GRPC_CHTTP2_MAX_IN_PREFIX(prefix_bits), (tgt) + 1, (length)-1); \
-    }                                                                         \
-  } while (0)
+  explicit VarintWriter(uint32_t value)
+      : value_(value),
+        length_(value < kMaxInPrefix ? 1 : VarintLength(value - kMaxInPrefix)) {
+  }
+
+  uint32_t value() const { return value_; }
+  uint32_t length() const { return length_; }
+
+  void Write(uint8_t prefix, uint8_t* target) const {
+    if (length_ == 1) {
+      target[0] = prefix | value_;
+    } else {
+      target[0] = prefix | kMaxInPrefix;
+      VarintWriteTail(value_ - kMaxInPrefix, target + 1, length_ - 1);
+    }
+  }
+
+ private:
+  const uint32_t value_;
+  // length required to bitpack value_
+  const uint32_t length_;
+};
+
+}  // namespace grpc_core
 
 #endif /* GRPC_CORE_EXT_TRANSPORT_CHTTP2_TRANSPORT_VARINT_H */
index e34856c..ccd6944 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include "src/core/ext/transport/chttp2/transport/chttp2_transport.h"
-#include "src/core/ext/transport/chttp2/transport/context_list.h"
-#include "src/core/ext/transport/chttp2/transport/internal.h"
-
 #include <limits.h>
 
 #include <grpc/support/log.h>
 
+#include "src/core/ext/transport/chttp2/transport/chttp2_transport.h"
+#include "src/core/ext/transport/chttp2/transport/context_list.h"
+#include "src/core/ext/transport/chttp2/transport/internal.h"
 #include "src/core/lib/compression/stream_compression.h"
 #include "src/core/lib/debug/stats.h"
 #include "src/core/lib/profiling/timers.h"
@@ -259,8 +258,7 @@ class WriteContext {
   }
 
   void EnactHpackSettings() {
-    grpc_chttp2_hpack_compressor_set_max_table_size(
-        &t_->hpack_compressor,
+    t_->hpack_compressor.SetMaxTableSize(
         t_->settings[GRPC_PEER_SETTINGS]
                     [GRPC_CHTTP2_SETTINGS_HEADER_TABLE_SIZE]);
   }
@@ -457,18 +455,20 @@ class StreamWriteContext {
         is_default_initial_metadata(s_->send_initial_metadata)) {
       ConvertInitialMetadataToTrailingMetadata();
     } else {
-      grpc_encode_header_options hopt = {
-          s_->id,  // stream_id
-          false,   // is_eof
-          t_->settings[GRPC_PEER_SETTINGS]
+      t_->hpack_compressor.EncodeHeaders(
+          grpc_core::HPackCompressor::EncodeHeaderOptions{
+              s_->id,  // stream_id
+              false,   // is_eof
+              t_->settings
+                      [GRPC_PEER_SETTINGS]
                       [GRPC_CHTTP2_SETTINGS_GRPC_ALLOW_TRUE_BINARY_METADATA] !=
-              0,  // use_true_binary_metadata
-          t_->settings[GRPC_PEER_SETTINGS]
-                      [GRPC_CHTTP2_SETTINGS_MAX_FRAME_SIZE],  // max_frame_size
-          &s_->stats.outgoing                                 // stats
-      };
-      grpc_chttp2_encode_header(&t_->hpack_compressor, nullptr, 0,
-                                s_->send_initial_metadata, &hopt, &t_->outbuf);
+                  0,  // use_true_binary_metadata
+              t_->settings
+                  [GRPC_PEER_SETTINGS]
+                  [GRPC_CHTTP2_SETTINGS_MAX_FRAME_SIZE],  // max_frame_size
+              &s_->stats.outgoing                         // stats
+          },
+          *s_->send_initial_metadata, &t_->outbuf);
       grpc_chttp2_reset_ping_clock(t_);
       write_context_->IncInitialMetadataWrites();
     }
@@ -565,18 +565,22 @@ class StreamWriteContext {
       grpc_chttp2_encode_data(s_->id, &s_->flow_controlled_buffer, 0, true,
                               &s_->stats.outgoing, &t_->outbuf);
     } else {
-      grpc_encode_header_options hopt = {
-          s_->id, true,
-          t_->settings[GRPC_PEER_SETTINGS]
+      t_->hpack_compressor.EncodeHeaders(
+          grpc_core::HPackCompressor::EncodeHeaderOptions{
+              s_->id, true,
+              t_->settings
+                      [GRPC_PEER_SETTINGS]
                       [GRPC_CHTTP2_SETTINGS_GRPC_ALLOW_TRUE_BINARY_METADATA] !=
-              0,
-
-          t_->settings[GRPC_PEER_SETTINGS][GRPC_CHTTP2_SETTINGS_MAX_FRAME_SIZE],
-          &s_->stats.outgoing};
-      grpc_chttp2_encode_header(&t_->hpack_compressor,
-                                extra_headers_for_trailing_metadata_,
-                                num_extra_headers_for_trailing_metadata_,
-                                s_->send_trailing_metadata, &hopt, &t_->outbuf);
+                  0,
+              t_->settings[GRPC_PEER_SETTINGS]
+                          [GRPC_CHTTP2_SETTINGS_MAX_FRAME_SIZE],
+              &s_->stats.outgoing},
+          grpc_core::ConcatMetadata(
+              grpc_core::MetadataArray(
+                  extra_headers_for_trailing_metadata_,
+                  num_extra_headers_for_trailing_metadata_),
+              *s_->send_trailing_metadata),
+          &t_->outbuf);
     }
     write_context_->IncTrailingMetadataWrites();
     grpc_chttp2_reset_ping_clock(t_);
index c3fc256..b379a4d 100644 (file)
 
 #include <grpc/impl/codegen/port_platform.h>
 
+#include "src/core/ext/transport/cronet/client/secure/cronet_channel_create.h"
+
 #include <stdio.h>
 #include <string.h>
 
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 
-#include "src/core/ext/transport/cronet/client/secure/cronet_channel_create.h"
 #include "src/core/ext/transport/cronet/transport/cronet_transport.h"
 #include "src/core/lib/surface/channel.h"
 #include "src/core/lib/transport/transport_impl.h"
@@ -58,8 +59,8 @@ GRPCAPI grpc_channel* grpc_cronet_secure_channel_create(
       grpc_create_cronet_transport(engine, target, new_args, reserved);
 
   grpc_core::ExecCtx exec_ctx;
-  grpc_channel* channel =
-      grpc_channel_create(target, new_args, GRPC_CLIENT_DIRECT_CHANNEL, ct);
+  grpc_channel* channel = grpc_channel_create(
+      target, new_args, GRPC_CLIENT_DIRECT_CHANNEL, ct, nullptr, 0, nullptr);
   grpc_channel_args_destroy(new_args);
   return channel;
 }
index 3063d06..0499112 100644 (file)
@@ -23,10 +23,10 @@ library, so we can build it in all environments */
 
 #include <stdbool.h>
 
-#include <grpc/support/log.h>
-
 #include "third_party/objective_c/Cronet/bidirectional_stream_c.h"
 
+#include <grpc/support/log.h>
+
 #ifdef GRPC_COMPILE_WITH_CRONET
 /* link with the real CRONET library in the build system */
 #else
index 9c047b3..fcf1115 100644 (file)
@@ -304,7 +304,6 @@ const char* cronet_net_error_as_string(cronet_net_error_code net_error) {
       return "CRONET_NET_ERROR_ENCODING_CONVERSION_FAILED";
     case CRONET_NET_ERROR_UNRECOGNIZED_FTP_DIRECTORY_LISTING_FORMAT:
       return "CRONET_NET_ERROR_UNRECOGNIZED_FTP_DIRECTORY_LISTING_FORMAT";
-      return "CRONET_NET_ERROR_INVALID_SPDY_STREAM";
     case CRONET_NET_ERROR_NO_SUPPORTED_PROXIES:
       return "CRONET_NET_ERROR_NO_SUPPORTED_PROXIES";
     case CRONET_NET_ERROR_HTTP2_PROTOCOL_ERROR:
@@ -339,7 +338,6 @@ const char* cronet_net_error_as_string(cronet_net_error_code net_error) {
       return "CRONET_NET_ERROR_HTTP2_SERVER_REFUSED_STREAM";
     case CRONET_NET_ERROR_HTTP2_PING_FAILED:
       return "CRONET_NET_ERROR_HTTP2_PING_FAILED";
-      return "CRONET_NET_ERROR_PIPELINE_EVICTION";
     case CRONET_NET_ERROR_CONTENT_LENGTH_MISMATCH:
       return "CRONET_NET_ERROR_CONTENT_LENGTH_MISMATCH";
     case CRONET_NET_ERROR_INCOMPLETE_CHUNKED_ENCODING:
@@ -350,7 +348,6 @@ const char* cronet_net_error_as_string(cronet_net_error_code net_error) {
       return "CRONET_NET_ERROR_RESPONSE_HEADERS_TRUNCATED";
     case CRONET_NET_ERROR_QUIC_HANDSHAKE_FAILED:
       return "CRONET_NET_ERROR_QUIC_HANDSHAKE_FAILED";
-      return "CRONET_NET_ERROR_REQUEST_FOR_SECURE_RESOURCE_OVER_INSECURE_QUIC";
     case CRONET_NET_ERROR_HTTP2_INADEQUATE_TRANSPORT_SECURITY:
       return "CRONET_NET_ERROR_HTTP2_INADEQUATE_TRANSPORT_SECURITY";
     case CRONET_NET_ERROR_HTTP2_FLOW_CONTROL_ERROR:
@@ -367,7 +364,6 @@ const char* cronet_net_error_as_string(cronet_net_error_code net_error) {
       return "CRONET_NET_ERROR_PROXY_HTTP_1_1_REQUIRED";
     case CRONET_NET_ERROR_PAC_SCRIPT_TERMINATED:
       return "CRONET_NET_ERROR_PAC_SCRIPT_TERMINATED";
-      return "CRONET_NET_ERROR_TEMPORARY_BACKOFF";
     case CRONET_NET_ERROR_INVALID_HTTP_RESPONSE:
       return "CRONET_NET_ERROR_INVALID_HTTP_RESPONSE";
     case CRONET_NET_ERROR_CONTENT_DECODING_INIT_FAILED:
@@ -522,6 +518,4 @@ grpc_status_code cronet_net_error_to_grpc_error(
     default:
       return GRPC_STATUS_UNAVAILABLE;
   }
-
-  return GRPC_STATUS_UNAVAILABLE;
 }
index 061b2e0..9b2ca6f 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
+#include "src/core/ext/transport/cronet/transport/cronet_transport.h"
+
 #include <string.h>
 
 #include <string>
 
 #include "absl/strings/str_cat.h"
 #include "absl/strings/str_format.h"
+#include "third_party/objective_c/Cronet/bidirectional_stream_c.h"
 
 #include <grpc/slice_buffer.h>
 #include <grpc/support/alloc.h>
@@ -33,7 +36,6 @@
 #include "src/core/ext/transport/chttp2/transport/bin_encoder.h"
 #include "src/core/ext/transport/chttp2/transport/incoming_metadata.h"
 #include "src/core/ext/transport/cronet/transport/cronet_status.h"
-#include "src/core/ext/transport/cronet/transport/cronet_transport.h"
 #include "src/core/lib/debug/trace.h"
 #include "src/core/lib/gpr/string.h"
 #include "src/core/lib/gprpp/manual_constructor.h"
@@ -48,8 +50,6 @@
 #include "src/core/lib/transport/timeout_encoding.h"
 #include "src/core/lib/transport/transport_impl.h"
 
-#include "third_party/objective_c/Cronet/bidirectional_stream_c.h"
-
 #define GRPC_HEADER_SIZE_IN_BYTES 5
 #define GRPC_FLUSH_READ_SIZE 4096
 
@@ -309,13 +309,10 @@ static void read_grpc_header(stream_obj* s) {
 static grpc_error_handle make_error_with_desc(int error_code,
                                               int cronet_internal_error_code,
                                               const char* desc) {
-  std::string error_message =
-      absl::StrFormat("Cronet error code:%d, Cronet error detail:%s",
-                      cronet_internal_error_code, desc);
-  grpc_error_handle error =
-      GRPC_ERROR_CREATE_FROM_COPIED_STRING(error_message.c_str());
-  error = grpc_error_set_int(error, GRPC_ERROR_INT_GRPC_STATUS, error_code);
-  return error;
+  return grpc_error_set_int(GRPC_ERROR_CREATE_FROM_CPP_STRING(absl::StrFormat(
+                                "Cronet error code:%d, Cronet error detail:%s",
+                                cronet_internal_error_code, desc)),
+                            GRPC_ERROR_INT_GRPC_STATUS, error_code);
 }
 
 inline op_and_state::op_and_state(stream_obj* s,
index 0abc2b3..bbe62e5 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
+#include "src/core/ext/transport/inproc/inproc_transport.h"
+
+#include <string.h>
+
 #include <grpc/support/alloc.h>
 #include <grpc/support/string_util.h>
 #include <grpc/support/sync.h>
 #include <grpc/support/time.h>
-#include <string.h>
-#include "src/core/ext/transport/inproc/inproc_transport.h"
+
 #include "src/core/lib/channel/channel_args.h"
 #include "src/core/lib/gprpp/manual_constructor.h"
 #include "src/core/lib/slice/slice_internal.h"
@@ -1290,7 +1293,6 @@ grpc_channel* grpc_inproc_channel_create(grpc_server* server,
   const grpc_channel_args* server_args = grpc_channel_args_copy_and_remove(
       server->core_server->channel_args(), args_to_remove,
       GPR_ARRAY_SIZE(args_to_remove));
-
   // Add a default authority channel argument for the client
   grpc_arg default_authority_arg;
   default_authority_arg.type = GRPC_ARG_STRING;
@@ -1311,7 +1313,7 @@ grpc_channel* grpc_inproc_channel_create(grpc_server* server,
   if (error == GRPC_ERROR_NONE) {
     channel =
         grpc_channel_create("inproc", client_args, GRPC_CLIENT_DIRECT_CHANNEL,
-                            client_transport, nullptr, &error);
+                            client_transport, nullptr, 0, &error);
     if (error != GRPC_ERROR_NONE) {
       GPR_ASSERT(!channel);
       gpr_log(GPR_ERROR, "Failed to create client channel: %s",
index d230ccb..8db5543 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/admin/v3/config_dump.upb.h"
 #include "envoy/config/bootstrap/v3/bootstrap.upb.h"
 #include "google/protobuf/any.upb.h"
@@ -22,13 +22,13 @@ static const upb_msglayout *const envoy_admin_v3_ConfigDump_submsgs[1] = {
 };
 
 static const upb_msglayout_field envoy_admin_v3_ConfigDump__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 11, 3},
+  {1, UPB_SIZE(0, 0), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout envoy_admin_v3_ConfigDump_msginit = {
   &envoy_admin_v3_ConfigDump_submsgs[0],
   &envoy_admin_v3_ConfigDump__fields[0],
-  UPB_SIZE(8, 8), 1, false, 255,
+  UPB_SIZE(8, 8), 1, false, 1, 255,
 };
 
 static const upb_msglayout *const envoy_admin_v3_UpdateFailureState_submsgs[2] = {
@@ -37,16 +37,16 @@ static const upb_msglayout *const envoy_admin_v3_UpdateFailureState_submsgs[2] =
 };
 
 static const upb_msglayout_field envoy_admin_v3_UpdateFailureState__fields[4] = {
-  {1, UPB_SIZE(20, 40), 1, 0, 11, 1},
-  {2, UPB_SIZE(24, 48), 2, 1, 11, 1},
-  {3, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {4, UPB_SIZE(12, 24), 0, 0, 9, 1},
+  {1, UPB_SIZE(20, 40), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(24, 48), 2, 1, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(12, 24), 0, 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_admin_v3_UpdateFailureState_msginit = {
   &envoy_admin_v3_UpdateFailureState_submsgs[0],
   &envoy_admin_v3_UpdateFailureState__fields[0],
-  UPB_SIZE(32, 64), 4, false, 255,
+  UPB_SIZE(32, 64), 4, false, 4, 255,
 };
 
 static const upb_msglayout *const envoy_admin_v3_BootstrapConfigDump_submsgs[2] = {
@@ -55,14 +55,14 @@ static const upb_msglayout *const envoy_admin_v3_BootstrapConfigDump_submsgs[2]
 };
 
 static const upb_msglayout_field envoy_admin_v3_BootstrapConfigDump__fields[2] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
-  {2, UPB_SIZE(8, 16), 2, 1, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 2, 1, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_admin_v3_BootstrapConfigDump_msginit = {
   &envoy_admin_v3_BootstrapConfigDump_submsgs[0],
   &envoy_admin_v3_BootstrapConfigDump__fields[0],
-  UPB_SIZE(16, 24), 2, false, 255,
+  UPB_SIZE(16, 24), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_admin_v3_ListenersConfigDump_submsgs[2] = {
@@ -71,15 +71,15 @@ static const upb_msglayout *const envoy_admin_v3_ListenersConfigDump_submsgs[2]
 };
 
 static const upb_msglayout_field envoy_admin_v3_ListenersConfigDump__fields[3] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {2, UPB_SIZE(8, 16), 0, 1, 11, 3},
-  {3, UPB_SIZE(12, 24), 0, 0, 11, 3},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 0, 1, 11, _UPB_MODE_ARRAY},
+  {3, UPB_SIZE(12, 24), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout envoy_admin_v3_ListenersConfigDump_msginit = {
   &envoy_admin_v3_ListenersConfigDump_submsgs[0],
   &envoy_admin_v3_ListenersConfigDump__fields[0],
-  UPB_SIZE(16, 32), 3, false, 255,
+  UPB_SIZE(16, 32), 3, false, 3, 255,
 };
 
 static const upb_msglayout *const envoy_admin_v3_ListenersConfigDump_StaticListener_submsgs[2] = {
@@ -88,14 +88,14 @@ static const upb_msglayout *const envoy_admin_v3_ListenersConfigDump_StaticListe
 };
 
 static const upb_msglayout_field envoy_admin_v3_ListenersConfigDump_StaticListener__fields[2] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
-  {2, UPB_SIZE(8, 16), 2, 1, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 2, 1, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_admin_v3_ListenersConfigDump_StaticListener_msginit = {
   &envoy_admin_v3_ListenersConfigDump_StaticListener_submsgs[0],
   &envoy_admin_v3_ListenersConfigDump_StaticListener__fields[0],
-  UPB_SIZE(16, 24), 2, false, 255,
+  UPB_SIZE(16, 24), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_admin_v3_ListenersConfigDump_DynamicListenerState_submsgs[2] = {
@@ -104,15 +104,15 @@ static const upb_msglayout *const envoy_admin_v3_ListenersConfigDump_DynamicList
 };
 
 static const upb_msglayout_field envoy_admin_v3_ListenersConfigDump_DynamicListenerState__fields[3] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(12, 24), 1, 0, 11, 1},
-  {3, UPB_SIZE(16, 32), 2, 1, 11, 1},
+  {1, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(12, 24), 1, 0, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(16, 32), 2, 1, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_admin_v3_ListenersConfigDump_DynamicListenerState_msginit = {
   &envoy_admin_v3_ListenersConfigDump_DynamicListenerState_submsgs[0],
   &envoy_admin_v3_ListenersConfigDump_DynamicListenerState__fields[0],
-  UPB_SIZE(24, 48), 3, false, 255,
+  UPB_SIZE(24, 48), 3, false, 3, 255,
 };
 
 static const upb_msglayout *const envoy_admin_v3_ListenersConfigDump_DynamicListener_submsgs[2] = {
@@ -121,18 +121,18 @@ static const upb_msglayout *const envoy_admin_v3_ListenersConfigDump_DynamicList
 };
 
 static const upb_msglayout_field envoy_admin_v3_ListenersConfigDump_DynamicListener__fields[6] = {
-  {1, UPB_SIZE(8, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(16, 24), 1, 0, 11, 1},
-  {3, UPB_SIZE(20, 32), 2, 0, 11, 1},
-  {4, UPB_SIZE(24, 40), 3, 0, 11, 1},
-  {5, UPB_SIZE(28, 48), 4, 1, 11, 1},
-  {6, UPB_SIZE(4, 4), 0, 0, 14, 1},
+  {1, UPB_SIZE(8, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(16, 24), 1, 0, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(20, 32), 2, 0, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(24, 40), 3, 0, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(28, 48), 4, 1, 11, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(4, 4), 0, 0, 14, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_admin_v3_ListenersConfigDump_DynamicListener_msginit = {
   &envoy_admin_v3_ListenersConfigDump_DynamicListener_submsgs[0],
   &envoy_admin_v3_ListenersConfigDump_DynamicListener__fields[0],
-  UPB_SIZE(32, 64), 6, false, 255,
+  UPB_SIZE(32, 64), 6, false, 6, 255,
 };
 
 static const upb_msglayout *const envoy_admin_v3_ClustersConfigDump_submsgs[2] = {
@@ -141,16 +141,16 @@ static const upb_msglayout *const envoy_admin_v3_ClustersConfigDump_submsgs[2] =
 };
 
 static const upb_msglayout_field envoy_admin_v3_ClustersConfigDump__fields[4] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {2, UPB_SIZE(8, 16), 0, 1, 11, 3},
-  {3, UPB_SIZE(12, 24), 0, 0, 11, 3},
-  {4, UPB_SIZE(16, 32), 0, 0, 11, 3},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 0, 1, 11, _UPB_MODE_ARRAY},
+  {3, UPB_SIZE(12, 24), 0, 0, 11, _UPB_MODE_ARRAY},
+  {4, UPB_SIZE(16, 32), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout envoy_admin_v3_ClustersConfigDump_msginit = {
   &envoy_admin_v3_ClustersConfigDump_submsgs[0],
   &envoy_admin_v3_ClustersConfigDump__fields[0],
-  UPB_SIZE(24, 48), 4, false, 255,
+  UPB_SIZE(24, 48), 4, false, 4, 255,
 };
 
 static const upb_msglayout *const envoy_admin_v3_ClustersConfigDump_StaticCluster_submsgs[2] = {
@@ -159,14 +159,14 @@ static const upb_msglayout *const envoy_admin_v3_ClustersConfigDump_StaticCluste
 };
 
 static const upb_msglayout_field envoy_admin_v3_ClustersConfigDump_StaticCluster__fields[2] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
-  {2, UPB_SIZE(8, 16), 2, 1, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 2, 1, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_admin_v3_ClustersConfigDump_StaticCluster_msginit = {
   &envoy_admin_v3_ClustersConfigDump_StaticCluster_submsgs[0],
   &envoy_admin_v3_ClustersConfigDump_StaticCluster__fields[0],
-  UPB_SIZE(16, 24), 2, false, 255,
+  UPB_SIZE(16, 24), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_admin_v3_ClustersConfigDump_DynamicCluster_submsgs[3] = {
@@ -176,17 +176,17 @@ static const upb_msglayout *const envoy_admin_v3_ClustersConfigDump_DynamicClust
 };
 
 static const upb_msglayout_field envoy_admin_v3_ClustersConfigDump_DynamicCluster__fields[5] = {
-  {1, UPB_SIZE(8, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(16, 24), 1, 1, 11, 1},
-  {3, UPB_SIZE(20, 32), 2, 2, 11, 1},
-  {4, UPB_SIZE(24, 40), 3, 0, 11, 1},
-  {5, UPB_SIZE(4, 4), 0, 0, 14, 1},
+  {1, UPB_SIZE(8, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(16, 24), 1, 1, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(20, 32), 2, 2, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(24, 40), 3, 0, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(4, 4), 0, 0, 14, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_admin_v3_ClustersConfigDump_DynamicCluster_msginit = {
   &envoy_admin_v3_ClustersConfigDump_DynamicCluster_submsgs[0],
   &envoy_admin_v3_ClustersConfigDump_DynamicCluster__fields[0],
-  UPB_SIZE(32, 48), 5, false, 255,
+  UPB_SIZE(32, 48), 5, false, 5, 255,
 };
 
 static const upb_msglayout *const envoy_admin_v3_RoutesConfigDump_submsgs[2] = {
@@ -195,14 +195,14 @@ static const upb_msglayout *const envoy_admin_v3_RoutesConfigDump_submsgs[2] = {
 };
 
 static const upb_msglayout_field envoy_admin_v3_RoutesConfigDump__fields[2] = {
-  {2, UPB_SIZE(0, 0), 0, 1, 11, 3},
-  {3, UPB_SIZE(4, 8), 0, 0, 11, 3},
+  {2, UPB_SIZE(0, 0), 0, 1, 11, _UPB_MODE_ARRAY},
+  {3, UPB_SIZE(4, 8), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout envoy_admin_v3_RoutesConfigDump_msginit = {
   &envoy_admin_v3_RoutesConfigDump_submsgs[0],
   &envoy_admin_v3_RoutesConfigDump__fields[0],
-  UPB_SIZE(8, 16), 2, false, 255,
+  UPB_SIZE(8, 16), 2, false, 0, 255,
 };
 
 static const upb_msglayout *const envoy_admin_v3_RoutesConfigDump_StaticRouteConfig_submsgs[2] = {
@@ -211,14 +211,14 @@ static const upb_msglayout *const envoy_admin_v3_RoutesConfigDump_StaticRouteCon
 };
 
 static const upb_msglayout_field envoy_admin_v3_RoutesConfigDump_StaticRouteConfig__fields[2] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
-  {2, UPB_SIZE(8, 16), 2, 1, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 2, 1, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_admin_v3_RoutesConfigDump_StaticRouteConfig_msginit = {
   &envoy_admin_v3_RoutesConfigDump_StaticRouteConfig_submsgs[0],
   &envoy_admin_v3_RoutesConfigDump_StaticRouteConfig__fields[0],
-  UPB_SIZE(16, 24), 2, false, 255,
+  UPB_SIZE(16, 24), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_admin_v3_RoutesConfigDump_DynamicRouteConfig_submsgs[3] = {
@@ -228,17 +228,17 @@ static const upb_msglayout *const envoy_admin_v3_RoutesConfigDump_DynamicRouteCo
 };
 
 static const upb_msglayout_field envoy_admin_v3_RoutesConfigDump_DynamicRouteConfig__fields[5] = {
-  {1, UPB_SIZE(8, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(16, 24), 1, 1, 11, 1},
-  {3, UPB_SIZE(20, 32), 2, 2, 11, 1},
-  {4, UPB_SIZE(24, 40), 3, 0, 11, 1},
-  {5, UPB_SIZE(4, 4), 0, 0, 14, 1},
+  {1, UPB_SIZE(8, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(16, 24), 1, 1, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(20, 32), 2, 2, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(24, 40), 3, 0, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(4, 4), 0, 0, 14, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_admin_v3_RoutesConfigDump_DynamicRouteConfig_msginit = {
   &envoy_admin_v3_RoutesConfigDump_DynamicRouteConfig_submsgs[0],
   &envoy_admin_v3_RoutesConfigDump_DynamicRouteConfig__fields[0],
-  UPB_SIZE(32, 48), 5, false, 255,
+  UPB_SIZE(32, 48), 5, false, 5, 255,
 };
 
 static const upb_msglayout *const envoy_admin_v3_ScopedRoutesConfigDump_submsgs[2] = {
@@ -247,14 +247,14 @@ static const upb_msglayout *const envoy_admin_v3_ScopedRoutesConfigDump_submsgs[
 };
 
 static const upb_msglayout_field envoy_admin_v3_ScopedRoutesConfigDump__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 1, 11, 3},
-  {2, UPB_SIZE(4, 8), 0, 0, 11, 3},
+  {1, UPB_SIZE(0, 0), 0, 1, 11, _UPB_MODE_ARRAY},
+  {2, UPB_SIZE(4, 8), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout envoy_admin_v3_ScopedRoutesConfigDump_msginit = {
   &envoy_admin_v3_ScopedRoutesConfigDump_submsgs[0],
   &envoy_admin_v3_ScopedRoutesConfigDump__fields[0],
-  UPB_SIZE(8, 16), 2, false, 255,
+  UPB_SIZE(8, 16), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_admin_v3_ScopedRoutesConfigDump_InlineScopedRouteConfigs_submsgs[2] = {
@@ -263,15 +263,15 @@ static const upb_msglayout *const envoy_admin_v3_ScopedRoutesConfigDump_InlineSc
 };
 
 static const upb_msglayout_field envoy_admin_v3_ScopedRoutesConfigDump_InlineScopedRouteConfigs__fields[3] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(16, 32), 0, 0, 11, 3},
-  {3, UPB_SIZE(12, 24), 1, 1, 11, 1},
+  {1, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(16, 32), 0, 0, 11, _UPB_MODE_ARRAY},
+  {3, UPB_SIZE(12, 24), 1, 1, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_admin_v3_ScopedRoutesConfigDump_InlineScopedRouteConfigs_msginit = {
   &envoy_admin_v3_ScopedRoutesConfigDump_InlineScopedRouteConfigs_submsgs[0],
   &envoy_admin_v3_ScopedRoutesConfigDump_InlineScopedRouteConfigs__fields[0],
-  UPB_SIZE(24, 48), 3, false, 255,
+  UPB_SIZE(24, 48), 3, false, 3, 255,
 };
 
 static const upb_msglayout *const envoy_admin_v3_ScopedRoutesConfigDump_DynamicScopedRouteConfigs_submsgs[3] = {
@@ -281,18 +281,18 @@ static const upb_msglayout *const envoy_admin_v3_ScopedRoutesConfigDump_DynamicS
 };
 
 static const upb_msglayout_field envoy_admin_v3_ScopedRoutesConfigDump_DynamicScopedRouteConfigs__fields[6] = {
-  {1, UPB_SIZE(8, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(16, 24), 0, 0, 9, 1},
-  {3, UPB_SIZE(32, 56), 0, 1, 11, 3},
-  {4, UPB_SIZE(24, 40), 1, 2, 11, 1},
-  {5, UPB_SIZE(28, 48), 2, 0, 11, 1},
-  {6, UPB_SIZE(4, 4), 0, 0, 14, 1},
+  {1, UPB_SIZE(8, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(16, 24), 0, 0, 9, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(32, 56), 0, 1, 11, _UPB_MODE_ARRAY},
+  {4, UPB_SIZE(24, 40), 1, 2, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(28, 48), 2, 0, 11, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(4, 4), 0, 0, 14, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_admin_v3_ScopedRoutesConfigDump_DynamicScopedRouteConfigs_msginit = {
   &envoy_admin_v3_ScopedRoutesConfigDump_DynamicScopedRouteConfigs_submsgs[0],
   &envoy_admin_v3_ScopedRoutesConfigDump_DynamicScopedRouteConfigs__fields[0],
-  UPB_SIZE(40, 64), 6, false, 255,
+  UPB_SIZE(40, 64), 6, false, 6, 255,
 };
 
 static const upb_msglayout *const envoy_admin_v3_SecretsConfigDump_submsgs[2] = {
@@ -301,15 +301,15 @@ static const upb_msglayout *const envoy_admin_v3_SecretsConfigDump_submsgs[2] =
 };
 
 static const upb_msglayout_field envoy_admin_v3_SecretsConfigDump__fields[3] = {
-  {1, UPB_SIZE(0, 0), 0, 1, 11, 3},
-  {2, UPB_SIZE(4, 8), 0, 0, 11, 3},
-  {3, UPB_SIZE(8, 16), 0, 0, 11, 3},
+  {1, UPB_SIZE(0, 0), 0, 1, 11, _UPB_MODE_ARRAY},
+  {2, UPB_SIZE(4, 8), 0, 0, 11, _UPB_MODE_ARRAY},
+  {3, UPB_SIZE(8, 16), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout envoy_admin_v3_SecretsConfigDump_msginit = {
   &envoy_admin_v3_SecretsConfigDump_submsgs[0],
   &envoy_admin_v3_SecretsConfigDump__fields[0],
-  UPB_SIZE(16, 24), 3, false, 255,
+  UPB_SIZE(16, 24), 3, false, 3, 255,
 };
 
 static const upb_msglayout *const envoy_admin_v3_SecretsConfigDump_DynamicSecret_submsgs[3] = {
@@ -319,18 +319,18 @@ static const upb_msglayout *const envoy_admin_v3_SecretsConfigDump_DynamicSecret
 };
 
 static const upb_msglayout_field envoy_admin_v3_SecretsConfigDump_DynamicSecret__fields[6] = {
-  {1, UPB_SIZE(8, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(16, 24), 0, 0, 9, 1},
-  {3, UPB_SIZE(24, 40), 1, 2, 11, 1},
-  {4, UPB_SIZE(28, 48), 2, 1, 11, 1},
-  {5, UPB_SIZE(32, 56), 3, 0, 11, 1},
-  {6, UPB_SIZE(4, 4), 0, 0, 14, 1},
+  {1, UPB_SIZE(8, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(16, 24), 0, 0, 9, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(24, 40), 1, 2, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(28, 48), 2, 1, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(32, 56), 3, 0, 11, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(4, 4), 0, 0, 14, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_admin_v3_SecretsConfigDump_DynamicSecret_msginit = {
   &envoy_admin_v3_SecretsConfigDump_DynamicSecret_submsgs[0],
   &envoy_admin_v3_SecretsConfigDump_DynamicSecret__fields[0],
-  UPB_SIZE(40, 64), 6, false, 255,
+  UPB_SIZE(40, 64), 6, false, 6, 255,
 };
 
 static const upb_msglayout *const envoy_admin_v3_SecretsConfigDump_StaticSecret_submsgs[2] = {
@@ -339,15 +339,15 @@ static const upb_msglayout *const envoy_admin_v3_SecretsConfigDump_StaticSecret_
 };
 
 static const upb_msglayout_field envoy_admin_v3_SecretsConfigDump_StaticSecret__fields[3] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(12, 24), 1, 1, 11, 1},
-  {3, UPB_SIZE(16, 32), 2, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(12, 24), 1, 1, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(16, 32), 2, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_admin_v3_SecretsConfigDump_StaticSecret_msginit = {
   &envoy_admin_v3_SecretsConfigDump_StaticSecret_submsgs[0],
   &envoy_admin_v3_SecretsConfigDump_StaticSecret__fields[0],
-  UPB_SIZE(24, 48), 3, false, 255,
+  UPB_SIZE(24, 48), 3, false, 3, 255,
 };
 
 static const upb_msglayout *const envoy_admin_v3_EndpointsConfigDump_submsgs[2] = {
@@ -356,14 +356,14 @@ static const upb_msglayout *const envoy_admin_v3_EndpointsConfigDump_submsgs[2]
 };
 
 static const upb_msglayout_field envoy_admin_v3_EndpointsConfigDump__fields[2] = {
-  {2, UPB_SIZE(0, 0), 0, 1, 11, 3},
-  {3, UPB_SIZE(4, 8), 0, 0, 11, 3},
+  {2, UPB_SIZE(0, 0), 0, 1, 11, _UPB_MODE_ARRAY},
+  {3, UPB_SIZE(4, 8), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout envoy_admin_v3_EndpointsConfigDump_msginit = {
   &envoy_admin_v3_EndpointsConfigDump_submsgs[0],
   &envoy_admin_v3_EndpointsConfigDump__fields[0],
-  UPB_SIZE(8, 16), 2, false, 255,
+  UPB_SIZE(8, 16), 2, false, 0, 255,
 };
 
 static const upb_msglayout *const envoy_admin_v3_EndpointsConfigDump_StaticEndpointConfig_submsgs[2] = {
@@ -372,14 +372,14 @@ static const upb_msglayout *const envoy_admin_v3_EndpointsConfigDump_StaticEndpo
 };
 
 static const upb_msglayout_field envoy_admin_v3_EndpointsConfigDump_StaticEndpointConfig__fields[2] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
-  {2, UPB_SIZE(8, 16), 2, 1, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 2, 1, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_admin_v3_EndpointsConfigDump_StaticEndpointConfig_msginit = {
   &envoy_admin_v3_EndpointsConfigDump_StaticEndpointConfig_submsgs[0],
   &envoy_admin_v3_EndpointsConfigDump_StaticEndpointConfig__fields[0],
-  UPB_SIZE(16, 24), 2, false, 255,
+  UPB_SIZE(16, 24), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_admin_v3_EndpointsConfigDump_DynamicEndpointConfig_submsgs[3] = {
@@ -389,17 +389,17 @@ static const upb_msglayout *const envoy_admin_v3_EndpointsConfigDump_DynamicEndp
 };
 
 static const upb_msglayout_field envoy_admin_v3_EndpointsConfigDump_DynamicEndpointConfig__fields[5] = {
-  {1, UPB_SIZE(8, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(16, 24), 1, 1, 11, 1},
-  {3, UPB_SIZE(20, 32), 2, 2, 11, 1},
-  {4, UPB_SIZE(24, 40), 3, 0, 11, 1},
-  {5, UPB_SIZE(4, 4), 0, 0, 14, 1},
+  {1, UPB_SIZE(8, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(16, 24), 1, 1, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(20, 32), 2, 2, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(24, 40), 3, 0, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(4, 4), 0, 0, 14, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_admin_v3_EndpointsConfigDump_DynamicEndpointConfig_msginit = {
   &envoy_admin_v3_EndpointsConfigDump_DynamicEndpointConfig_submsgs[0],
   &envoy_admin_v3_EndpointsConfigDump_DynamicEndpointConfig__fields[0],
-  UPB_SIZE(32, 48), 5, false, 255,
+  UPB_SIZE(32, 48), 5, false, 5, 255,
 };
 
 #include "upb/port_undef.inc"
index 6f117c6..db9fe28 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_ADMIN_V3_CONFIG_DUMP_PROTO_UPB_H_
 #define ENVOY_ADMIN_V3_CONFIG_DUMP_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -110,13 +110,19 @@ UPB_INLINE envoy_admin_v3_ConfigDump *envoy_admin_v3_ConfigDump_new(upb_arena *a
 UPB_INLINE envoy_admin_v3_ConfigDump *envoy_admin_v3_ConfigDump_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_admin_v3_ConfigDump *ret = envoy_admin_v3_ConfigDump_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_admin_v3_ConfigDump_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_admin_v3_ConfigDump_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_admin_v3_ConfigDump *envoy_admin_v3_ConfigDump_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_admin_v3_ConfigDump *ret = envoy_admin_v3_ConfigDump_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_admin_v3_ConfigDump_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_admin_v3_ConfigDump_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_admin_v3_ConfigDump_serialize(const envoy_admin_v3_ConfigDump *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_admin_v3_ConfigDump_msginit, arena, len);
@@ -147,13 +153,19 @@ UPB_INLINE envoy_admin_v3_UpdateFailureState *envoy_admin_v3_UpdateFailureState_
 UPB_INLINE envoy_admin_v3_UpdateFailureState *envoy_admin_v3_UpdateFailureState_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_admin_v3_UpdateFailureState *ret = envoy_admin_v3_UpdateFailureState_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_admin_v3_UpdateFailureState_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_admin_v3_UpdateFailureState_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_admin_v3_UpdateFailureState *envoy_admin_v3_UpdateFailureState_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_admin_v3_UpdateFailureState *ret = envoy_admin_v3_UpdateFailureState_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_admin_v3_UpdateFailureState_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_admin_v3_UpdateFailureState_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_admin_v3_UpdateFailureState_serialize(const envoy_admin_v3_UpdateFailureState *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_admin_v3_UpdateFailureState_msginit, arena, len);
@@ -207,13 +219,19 @@ UPB_INLINE envoy_admin_v3_BootstrapConfigDump *envoy_admin_v3_BootstrapConfigDum
 UPB_INLINE envoy_admin_v3_BootstrapConfigDump *envoy_admin_v3_BootstrapConfigDump_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_admin_v3_BootstrapConfigDump *ret = envoy_admin_v3_BootstrapConfigDump_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_admin_v3_BootstrapConfigDump_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_admin_v3_BootstrapConfigDump_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_admin_v3_BootstrapConfigDump *envoy_admin_v3_BootstrapConfigDump_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_admin_v3_BootstrapConfigDump *ret = envoy_admin_v3_BootstrapConfigDump_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_admin_v3_BootstrapConfigDump_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_admin_v3_BootstrapConfigDump_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_admin_v3_BootstrapConfigDump_serialize(const envoy_admin_v3_BootstrapConfigDump *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_admin_v3_BootstrapConfigDump_msginit, arena, len);
@@ -259,13 +277,19 @@ UPB_INLINE envoy_admin_v3_ListenersConfigDump *envoy_admin_v3_ListenersConfigDum
 UPB_INLINE envoy_admin_v3_ListenersConfigDump *envoy_admin_v3_ListenersConfigDump_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_admin_v3_ListenersConfigDump *ret = envoy_admin_v3_ListenersConfigDump_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_admin_v3_ListenersConfigDump_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_admin_v3_ListenersConfigDump_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_admin_v3_ListenersConfigDump *envoy_admin_v3_ListenersConfigDump_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_admin_v3_ListenersConfigDump *ret = envoy_admin_v3_ListenersConfigDump_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_admin_v3_ListenersConfigDump_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_admin_v3_ListenersConfigDump_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_admin_v3_ListenersConfigDump_serialize(const envoy_admin_v3_ListenersConfigDump *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_admin_v3_ListenersConfigDump_msginit, arena, len);
@@ -315,13 +339,19 @@ UPB_INLINE envoy_admin_v3_ListenersConfigDump_StaticListener *envoy_admin_v3_Lis
 UPB_INLINE envoy_admin_v3_ListenersConfigDump_StaticListener *envoy_admin_v3_ListenersConfigDump_StaticListener_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_admin_v3_ListenersConfigDump_StaticListener *ret = envoy_admin_v3_ListenersConfigDump_StaticListener_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_admin_v3_ListenersConfigDump_StaticListener_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_admin_v3_ListenersConfigDump_StaticListener_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_admin_v3_ListenersConfigDump_StaticListener *envoy_admin_v3_ListenersConfigDump_StaticListener_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_admin_v3_ListenersConfigDump_StaticListener *ret = envoy_admin_v3_ListenersConfigDump_StaticListener_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_admin_v3_ListenersConfigDump_StaticListener_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_admin_v3_ListenersConfigDump_StaticListener_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_admin_v3_ListenersConfigDump_StaticListener_serialize(const envoy_admin_v3_ListenersConfigDump_StaticListener *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_admin_v3_ListenersConfigDump_StaticListener_msginit, arena, len);
@@ -367,13 +397,19 @@ UPB_INLINE envoy_admin_v3_ListenersConfigDump_DynamicListenerState *envoy_admin_
 UPB_INLINE envoy_admin_v3_ListenersConfigDump_DynamicListenerState *envoy_admin_v3_ListenersConfigDump_DynamicListenerState_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_admin_v3_ListenersConfigDump_DynamicListenerState *ret = envoy_admin_v3_ListenersConfigDump_DynamicListenerState_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_admin_v3_ListenersConfigDump_DynamicListenerState_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_admin_v3_ListenersConfigDump_DynamicListenerState_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_admin_v3_ListenersConfigDump_DynamicListenerState *envoy_admin_v3_ListenersConfigDump_DynamicListenerState_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_admin_v3_ListenersConfigDump_DynamicListenerState *ret = envoy_admin_v3_ListenersConfigDump_DynamicListenerState_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_admin_v3_ListenersConfigDump_DynamicListenerState_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_admin_v3_ListenersConfigDump_DynamicListenerState_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_admin_v3_ListenersConfigDump_DynamicListenerState_serialize(const envoy_admin_v3_ListenersConfigDump_DynamicListenerState *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_admin_v3_ListenersConfigDump_DynamicListenerState_msginit, arena, len);
@@ -423,13 +459,19 @@ UPB_INLINE envoy_admin_v3_ListenersConfigDump_DynamicListener *envoy_admin_v3_Li
 UPB_INLINE envoy_admin_v3_ListenersConfigDump_DynamicListener *envoy_admin_v3_ListenersConfigDump_DynamicListener_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_admin_v3_ListenersConfigDump_DynamicListener *ret = envoy_admin_v3_ListenersConfigDump_DynamicListener_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_admin_v3_ListenersConfigDump_DynamicListener_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_admin_v3_ListenersConfigDump_DynamicListener_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_admin_v3_ListenersConfigDump_DynamicListener *envoy_admin_v3_ListenersConfigDump_DynamicListener_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_admin_v3_ListenersConfigDump_DynamicListener *ret = envoy_admin_v3_ListenersConfigDump_DynamicListener_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_admin_v3_ListenersConfigDump_DynamicListener_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_admin_v3_ListenersConfigDump_DynamicListener_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_admin_v3_ListenersConfigDump_DynamicListener_serialize(const envoy_admin_v3_ListenersConfigDump_DynamicListener *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_admin_v3_ListenersConfigDump_DynamicListener_msginit, arena, len);
@@ -513,13 +555,19 @@ UPB_INLINE envoy_admin_v3_ClustersConfigDump *envoy_admin_v3_ClustersConfigDump_
 UPB_INLINE envoy_admin_v3_ClustersConfigDump *envoy_admin_v3_ClustersConfigDump_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_admin_v3_ClustersConfigDump *ret = envoy_admin_v3_ClustersConfigDump_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_admin_v3_ClustersConfigDump_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_admin_v3_ClustersConfigDump_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_admin_v3_ClustersConfigDump *envoy_admin_v3_ClustersConfigDump_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_admin_v3_ClustersConfigDump *ret = envoy_admin_v3_ClustersConfigDump_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_admin_v3_ClustersConfigDump_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_admin_v3_ClustersConfigDump_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_admin_v3_ClustersConfigDump_serialize(const envoy_admin_v3_ClustersConfigDump *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_admin_v3_ClustersConfigDump_msginit, arena, len);
@@ -584,13 +632,19 @@ UPB_INLINE envoy_admin_v3_ClustersConfigDump_StaticCluster *envoy_admin_v3_Clust
 UPB_INLINE envoy_admin_v3_ClustersConfigDump_StaticCluster *envoy_admin_v3_ClustersConfigDump_StaticCluster_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_admin_v3_ClustersConfigDump_StaticCluster *ret = envoy_admin_v3_ClustersConfigDump_StaticCluster_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_admin_v3_ClustersConfigDump_StaticCluster_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_admin_v3_ClustersConfigDump_StaticCluster_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_admin_v3_ClustersConfigDump_StaticCluster *envoy_admin_v3_ClustersConfigDump_StaticCluster_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_admin_v3_ClustersConfigDump_StaticCluster *ret = envoy_admin_v3_ClustersConfigDump_StaticCluster_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_admin_v3_ClustersConfigDump_StaticCluster_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_admin_v3_ClustersConfigDump_StaticCluster_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_admin_v3_ClustersConfigDump_StaticCluster_serialize(const envoy_admin_v3_ClustersConfigDump_StaticCluster *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_admin_v3_ClustersConfigDump_StaticCluster_msginit, arena, len);
@@ -636,13 +690,19 @@ UPB_INLINE envoy_admin_v3_ClustersConfigDump_DynamicCluster *envoy_admin_v3_Clus
 UPB_INLINE envoy_admin_v3_ClustersConfigDump_DynamicCluster *envoy_admin_v3_ClustersConfigDump_DynamicCluster_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_admin_v3_ClustersConfigDump_DynamicCluster *ret = envoy_admin_v3_ClustersConfigDump_DynamicCluster_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_admin_v3_ClustersConfigDump_DynamicCluster_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_admin_v3_ClustersConfigDump_DynamicCluster_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_admin_v3_ClustersConfigDump_DynamicCluster *envoy_admin_v3_ClustersConfigDump_DynamicCluster_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_admin_v3_ClustersConfigDump_DynamicCluster *ret = envoy_admin_v3_ClustersConfigDump_DynamicCluster_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_admin_v3_ClustersConfigDump_DynamicCluster_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_admin_v3_ClustersConfigDump_DynamicCluster_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_admin_v3_ClustersConfigDump_DynamicCluster_serialize(const envoy_admin_v3_ClustersConfigDump_DynamicCluster *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_admin_v3_ClustersConfigDump_DynamicCluster_msginit, arena, len);
@@ -711,13 +771,19 @@ UPB_INLINE envoy_admin_v3_RoutesConfigDump *envoy_admin_v3_RoutesConfigDump_new(
 UPB_INLINE envoy_admin_v3_RoutesConfigDump *envoy_admin_v3_RoutesConfigDump_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_admin_v3_RoutesConfigDump *ret = envoy_admin_v3_RoutesConfigDump_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_admin_v3_RoutesConfigDump_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_admin_v3_RoutesConfigDump_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_admin_v3_RoutesConfigDump *envoy_admin_v3_RoutesConfigDump_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_admin_v3_RoutesConfigDump *ret = envoy_admin_v3_RoutesConfigDump_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_admin_v3_RoutesConfigDump_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_admin_v3_RoutesConfigDump_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_admin_v3_RoutesConfigDump_serialize(const envoy_admin_v3_RoutesConfigDump *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_admin_v3_RoutesConfigDump_msginit, arena, len);
@@ -763,13 +829,19 @@ UPB_INLINE envoy_admin_v3_RoutesConfigDump_StaticRouteConfig *envoy_admin_v3_Rou
 UPB_INLINE envoy_admin_v3_RoutesConfigDump_StaticRouteConfig *envoy_admin_v3_RoutesConfigDump_StaticRouteConfig_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_admin_v3_RoutesConfigDump_StaticRouteConfig *ret = envoy_admin_v3_RoutesConfigDump_StaticRouteConfig_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_admin_v3_RoutesConfigDump_StaticRouteConfig_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_admin_v3_RoutesConfigDump_StaticRouteConfig_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_admin_v3_RoutesConfigDump_StaticRouteConfig *envoy_admin_v3_RoutesConfigDump_StaticRouteConfig_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_admin_v3_RoutesConfigDump_StaticRouteConfig *ret = envoy_admin_v3_RoutesConfigDump_StaticRouteConfig_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_admin_v3_RoutesConfigDump_StaticRouteConfig_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_admin_v3_RoutesConfigDump_StaticRouteConfig_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_admin_v3_RoutesConfigDump_StaticRouteConfig_serialize(const envoy_admin_v3_RoutesConfigDump_StaticRouteConfig *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_admin_v3_RoutesConfigDump_StaticRouteConfig_msginit, arena, len);
@@ -815,13 +887,19 @@ UPB_INLINE envoy_admin_v3_RoutesConfigDump_DynamicRouteConfig *envoy_admin_v3_Ro
 UPB_INLINE envoy_admin_v3_RoutesConfigDump_DynamicRouteConfig *envoy_admin_v3_RoutesConfigDump_DynamicRouteConfig_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_admin_v3_RoutesConfigDump_DynamicRouteConfig *ret = envoy_admin_v3_RoutesConfigDump_DynamicRouteConfig_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_admin_v3_RoutesConfigDump_DynamicRouteConfig_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_admin_v3_RoutesConfigDump_DynamicRouteConfig_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_admin_v3_RoutesConfigDump_DynamicRouteConfig *envoy_admin_v3_RoutesConfigDump_DynamicRouteConfig_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_admin_v3_RoutesConfigDump_DynamicRouteConfig *ret = envoy_admin_v3_RoutesConfigDump_DynamicRouteConfig_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_admin_v3_RoutesConfigDump_DynamicRouteConfig_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_admin_v3_RoutesConfigDump_DynamicRouteConfig_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_admin_v3_RoutesConfigDump_DynamicRouteConfig_serialize(const envoy_admin_v3_RoutesConfigDump_DynamicRouteConfig *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_admin_v3_RoutesConfigDump_DynamicRouteConfig_msginit, arena, len);
@@ -890,13 +968,19 @@ UPB_INLINE envoy_admin_v3_ScopedRoutesConfigDump *envoy_admin_v3_ScopedRoutesCon
 UPB_INLINE envoy_admin_v3_ScopedRoutesConfigDump *envoy_admin_v3_ScopedRoutesConfigDump_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_admin_v3_ScopedRoutesConfigDump *ret = envoy_admin_v3_ScopedRoutesConfigDump_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_admin_v3_ScopedRoutesConfigDump_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_admin_v3_ScopedRoutesConfigDump_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_admin_v3_ScopedRoutesConfigDump *envoy_admin_v3_ScopedRoutesConfigDump_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_admin_v3_ScopedRoutesConfigDump *ret = envoy_admin_v3_ScopedRoutesConfigDump_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_admin_v3_ScopedRoutesConfigDump_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_admin_v3_ScopedRoutesConfigDump_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_admin_v3_ScopedRoutesConfigDump_serialize(const envoy_admin_v3_ScopedRoutesConfigDump *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_admin_v3_ScopedRoutesConfigDump_msginit, arena, len);
@@ -942,13 +1026,19 @@ UPB_INLINE envoy_admin_v3_ScopedRoutesConfigDump_InlineScopedRouteConfigs *envoy
 UPB_INLINE envoy_admin_v3_ScopedRoutesConfigDump_InlineScopedRouteConfigs *envoy_admin_v3_ScopedRoutesConfigDump_InlineScopedRouteConfigs_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_admin_v3_ScopedRoutesConfigDump_InlineScopedRouteConfigs *ret = envoy_admin_v3_ScopedRoutesConfigDump_InlineScopedRouteConfigs_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_admin_v3_ScopedRoutesConfigDump_InlineScopedRouteConfigs_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_admin_v3_ScopedRoutesConfigDump_InlineScopedRouteConfigs_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_admin_v3_ScopedRoutesConfigDump_InlineScopedRouteConfigs *envoy_admin_v3_ScopedRoutesConfigDump_InlineScopedRouteConfigs_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_admin_v3_ScopedRoutesConfigDump_InlineScopedRouteConfigs *ret = envoy_admin_v3_ScopedRoutesConfigDump_InlineScopedRouteConfigs_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_admin_v3_ScopedRoutesConfigDump_InlineScopedRouteConfigs_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_admin_v3_ScopedRoutesConfigDump_InlineScopedRouteConfigs_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_admin_v3_ScopedRoutesConfigDump_InlineScopedRouteConfigs_serialize(const envoy_admin_v3_ScopedRoutesConfigDump_InlineScopedRouteConfigs *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_admin_v3_ScopedRoutesConfigDump_InlineScopedRouteConfigs_msginit, arena, len);
@@ -998,13 +1088,19 @@ UPB_INLINE envoy_admin_v3_ScopedRoutesConfigDump_DynamicScopedRouteConfigs *envo
 UPB_INLINE envoy_admin_v3_ScopedRoutesConfigDump_DynamicScopedRouteConfigs *envoy_admin_v3_ScopedRoutesConfigDump_DynamicScopedRouteConfigs_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_admin_v3_ScopedRoutesConfigDump_DynamicScopedRouteConfigs *ret = envoy_admin_v3_ScopedRoutesConfigDump_DynamicScopedRouteConfigs_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_admin_v3_ScopedRoutesConfigDump_DynamicScopedRouteConfigs_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_admin_v3_ScopedRoutesConfigDump_DynamicScopedRouteConfigs_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_admin_v3_ScopedRoutesConfigDump_DynamicScopedRouteConfigs *envoy_admin_v3_ScopedRoutesConfigDump_DynamicScopedRouteConfigs_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_admin_v3_ScopedRoutesConfigDump_DynamicScopedRouteConfigs *ret = envoy_admin_v3_ScopedRoutesConfigDump_DynamicScopedRouteConfigs_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_admin_v3_ScopedRoutesConfigDump_DynamicScopedRouteConfigs_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_admin_v3_ScopedRoutesConfigDump_DynamicScopedRouteConfigs_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_admin_v3_ScopedRoutesConfigDump_DynamicScopedRouteConfigs_serialize(const envoy_admin_v3_ScopedRoutesConfigDump_DynamicScopedRouteConfigs *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_admin_v3_ScopedRoutesConfigDump_DynamicScopedRouteConfigs_msginit, arena, len);
@@ -1077,13 +1173,19 @@ UPB_INLINE envoy_admin_v3_SecretsConfigDump *envoy_admin_v3_SecretsConfigDump_ne
 UPB_INLINE envoy_admin_v3_SecretsConfigDump *envoy_admin_v3_SecretsConfigDump_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_admin_v3_SecretsConfigDump *ret = envoy_admin_v3_SecretsConfigDump_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_admin_v3_SecretsConfigDump_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_admin_v3_SecretsConfigDump_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_admin_v3_SecretsConfigDump *envoy_admin_v3_SecretsConfigDump_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_admin_v3_SecretsConfigDump *ret = envoy_admin_v3_SecretsConfigDump_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_admin_v3_SecretsConfigDump_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_admin_v3_SecretsConfigDump_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_admin_v3_SecretsConfigDump_serialize(const envoy_admin_v3_SecretsConfigDump *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_admin_v3_SecretsConfigDump_msginit, arena, len);
@@ -1144,13 +1246,19 @@ UPB_INLINE envoy_admin_v3_SecretsConfigDump_DynamicSecret *envoy_admin_v3_Secret
 UPB_INLINE envoy_admin_v3_SecretsConfigDump_DynamicSecret *envoy_admin_v3_SecretsConfigDump_DynamicSecret_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_admin_v3_SecretsConfigDump_DynamicSecret *ret = envoy_admin_v3_SecretsConfigDump_DynamicSecret_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_admin_v3_SecretsConfigDump_DynamicSecret_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_admin_v3_SecretsConfigDump_DynamicSecret_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_admin_v3_SecretsConfigDump_DynamicSecret *envoy_admin_v3_SecretsConfigDump_DynamicSecret_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_admin_v3_SecretsConfigDump_DynamicSecret *ret = envoy_admin_v3_SecretsConfigDump_DynamicSecret_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_admin_v3_SecretsConfigDump_DynamicSecret_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_admin_v3_SecretsConfigDump_DynamicSecret_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_admin_v3_SecretsConfigDump_DynamicSecret_serialize(const envoy_admin_v3_SecretsConfigDump_DynamicSecret *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_admin_v3_SecretsConfigDump_DynamicSecret_msginit, arena, len);
@@ -1223,13 +1331,19 @@ UPB_INLINE envoy_admin_v3_SecretsConfigDump_StaticSecret *envoy_admin_v3_Secrets
 UPB_INLINE envoy_admin_v3_SecretsConfigDump_StaticSecret *envoy_admin_v3_SecretsConfigDump_StaticSecret_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_admin_v3_SecretsConfigDump_StaticSecret *ret = envoy_admin_v3_SecretsConfigDump_StaticSecret_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_admin_v3_SecretsConfigDump_StaticSecret_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_admin_v3_SecretsConfigDump_StaticSecret_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_admin_v3_SecretsConfigDump_StaticSecret *envoy_admin_v3_SecretsConfigDump_StaticSecret_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_admin_v3_SecretsConfigDump_StaticSecret *ret = envoy_admin_v3_SecretsConfigDump_StaticSecret_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_admin_v3_SecretsConfigDump_StaticSecret_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_admin_v3_SecretsConfigDump_StaticSecret_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_admin_v3_SecretsConfigDump_StaticSecret_serialize(const envoy_admin_v3_SecretsConfigDump_StaticSecret *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_admin_v3_SecretsConfigDump_StaticSecret_msginit, arena, len);
@@ -1279,13 +1393,19 @@ UPB_INLINE envoy_admin_v3_EndpointsConfigDump *envoy_admin_v3_EndpointsConfigDum
 UPB_INLINE envoy_admin_v3_EndpointsConfigDump *envoy_admin_v3_EndpointsConfigDump_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_admin_v3_EndpointsConfigDump *ret = envoy_admin_v3_EndpointsConfigDump_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_admin_v3_EndpointsConfigDump_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_admin_v3_EndpointsConfigDump_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_admin_v3_EndpointsConfigDump *envoy_admin_v3_EndpointsConfigDump_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_admin_v3_EndpointsConfigDump *ret = envoy_admin_v3_EndpointsConfigDump_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_admin_v3_EndpointsConfigDump_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_admin_v3_EndpointsConfigDump_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_admin_v3_EndpointsConfigDump_serialize(const envoy_admin_v3_EndpointsConfigDump *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_admin_v3_EndpointsConfigDump_msginit, arena, len);
@@ -1331,13 +1451,19 @@ UPB_INLINE envoy_admin_v3_EndpointsConfigDump_StaticEndpointConfig *envoy_admin_
 UPB_INLINE envoy_admin_v3_EndpointsConfigDump_StaticEndpointConfig *envoy_admin_v3_EndpointsConfigDump_StaticEndpointConfig_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_admin_v3_EndpointsConfigDump_StaticEndpointConfig *ret = envoy_admin_v3_EndpointsConfigDump_StaticEndpointConfig_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_admin_v3_EndpointsConfigDump_StaticEndpointConfig_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_admin_v3_EndpointsConfigDump_StaticEndpointConfig_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_admin_v3_EndpointsConfigDump_StaticEndpointConfig *envoy_admin_v3_EndpointsConfigDump_StaticEndpointConfig_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_admin_v3_EndpointsConfigDump_StaticEndpointConfig *ret = envoy_admin_v3_EndpointsConfigDump_StaticEndpointConfig_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_admin_v3_EndpointsConfigDump_StaticEndpointConfig_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_admin_v3_EndpointsConfigDump_StaticEndpointConfig_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_admin_v3_EndpointsConfigDump_StaticEndpointConfig_serialize(const envoy_admin_v3_EndpointsConfigDump_StaticEndpointConfig *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_admin_v3_EndpointsConfigDump_StaticEndpointConfig_msginit, arena, len);
@@ -1383,13 +1509,19 @@ UPB_INLINE envoy_admin_v3_EndpointsConfigDump_DynamicEndpointConfig *envoy_admin
 UPB_INLINE envoy_admin_v3_EndpointsConfigDump_DynamicEndpointConfig *envoy_admin_v3_EndpointsConfigDump_DynamicEndpointConfig_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_admin_v3_EndpointsConfigDump_DynamicEndpointConfig *ret = envoy_admin_v3_EndpointsConfigDump_DynamicEndpointConfig_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_admin_v3_EndpointsConfigDump_DynamicEndpointConfig_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_admin_v3_EndpointsConfigDump_DynamicEndpointConfig_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_admin_v3_EndpointsConfigDump_DynamicEndpointConfig *envoy_admin_v3_EndpointsConfigDump_DynamicEndpointConfig_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_admin_v3_EndpointsConfigDump_DynamicEndpointConfig *ret = envoy_admin_v3_EndpointsConfigDump_DynamicEndpointConfig_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_admin_v3_EndpointsConfigDump_DynamicEndpointConfig_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_admin_v3_EndpointsConfigDump_DynamicEndpointConfig_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_admin_v3_EndpointsConfigDump_DynamicEndpointConfig_serialize(const envoy_admin_v3_EndpointsConfigDump_DynamicEndpointConfig *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_admin_v3_EndpointsConfigDump_DynamicEndpointConfig_msginit, arena, len);
index 007de31..c3aaa11 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/annotations/deprecation.upb.h"
 #include "google/protobuf/descriptor.upb.h"
 
index 1478843..c6ccf28 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_ANNOTATIONS_DEPRECATION_PROTO_UPB_H_
 #define ENVOY_ANNOTATIONS_DEPRECATION_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
index 8f1877d..2f605df 100644 (file)
@@ -7,20 +7,20 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/annotations/resource.upb.h"
 #include "google/protobuf/descriptor.upb.h"
 
 #include "upb/port_def.inc"
 
 static const upb_msglayout_field envoy_annotations_ResourceAnnotation__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_annotations_ResourceAnnotation_msginit = {
   NULL,
   &envoy_annotations_ResourceAnnotation__fields[0],
-  UPB_SIZE(8, 16), 1, false, 255,
+  UPB_SIZE(8, 16), 1, false, 1, 255,
 };
 
 #include "upb/port_undef.inc"
index 534eef3..4ba34ce 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_ANNOTATIONS_RESOURCE_PROTO_UPB_H_
 #define ENVOY_ANNOTATIONS_RESOURCE_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -33,13 +33,19 @@ UPB_INLINE envoy_annotations_ResourceAnnotation *envoy_annotations_ResourceAnnot
 UPB_INLINE envoy_annotations_ResourceAnnotation *envoy_annotations_ResourceAnnotation_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_annotations_ResourceAnnotation *ret = envoy_annotations_ResourceAnnotation_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_annotations_ResourceAnnotation_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_annotations_ResourceAnnotation_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_annotations_ResourceAnnotation *envoy_annotations_ResourceAnnotation_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_annotations_ResourceAnnotation *ret = envoy_annotations_ResourceAnnotation_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_annotations_ResourceAnnotation_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_annotations_ResourceAnnotation_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_annotations_ResourceAnnotation_serialize(const envoy_annotations_ResourceAnnotation *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_annotations_ResourceAnnotation_msginit, arena, len);
index fa6dcbc..579a297 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/config/accesslog/v3/accesslog.upb.h"
 #include "envoy/config/core/v3/base.upb.h"
 #include "envoy/config/route/v3/route_components.upb.h"
@@ -27,15 +27,15 @@ static const upb_msglayout *const envoy_config_accesslog_v3_AccessLog_submsgs[2]
 };
 
 static const upb_msglayout_field envoy_config_accesslog_v3_AccessLog__fields[3] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(12, 24), 1, 0, 11, 1},
-  {4, UPB_SIZE(16, 32), UPB_SIZE(-21, -41), 1, 11, 1},
+  {1, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(12, 24), 1, 0, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(16, 32), UPB_SIZE(-21, -41), 1, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_accesslog_v3_AccessLog_msginit = {
   &envoy_config_accesslog_v3_AccessLog_submsgs[0],
   &envoy_config_accesslog_v3_AccessLog__fields[0],
-  UPB_SIZE(24, 48), 3, false, 255,
+  UPB_SIZE(24, 48), 3, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_config_accesslog_v3_AccessLogFilter_submsgs[12] = {
@@ -54,24 +54,24 @@ static const upb_msglayout *const envoy_config_accesslog_v3_AccessLogFilter_subm
 };
 
 static const upb_msglayout_field envoy_config_accesslog_v3_AccessLogFilter__fields[12] = {
-  {1, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 10, 11, 1},
-  {2, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 1, 11, 1},
-  {3, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 6, 11, 1},
-  {4, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 11, 11, 1},
-  {5, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 9, 11, 1},
-  {6, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 11, 1},
-  {7, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 7, 11, 1},
-  {8, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 4, 11, 1},
-  {9, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 8, 11, 1},
-  {10, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 3, 11, 1},
-  {11, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 2, 11, 1},
-  {12, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 5, 11, 1},
+  {1, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 10, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 1, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 6, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 11, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 9, 11, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 11, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 7, 11, _UPB_MODE_SCALAR},
+  {8, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 4, 11, _UPB_MODE_SCALAR},
+  {9, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 8, 11, _UPB_MODE_SCALAR},
+  {10, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 3, 11, _UPB_MODE_SCALAR},
+  {11, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 2, 11, _UPB_MODE_SCALAR},
+  {12, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 5, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_accesslog_v3_AccessLogFilter_msginit = {
   &envoy_config_accesslog_v3_AccessLogFilter_submsgs[0],
   &envoy_config_accesslog_v3_AccessLogFilter__fields[0],
-  UPB_SIZE(8, 16), 12, false, 255,
+  UPB_SIZE(8, 16), 12, false, 12, 255,
 };
 
 static const upb_msglayout *const envoy_config_accesslog_v3_ComparisonFilter_submsgs[1] = {
@@ -79,14 +79,14 @@ static const upb_msglayout *const envoy_config_accesslog_v3_ComparisonFilter_sub
 };
 
 static const upb_msglayout_field envoy_config_accesslog_v3_ComparisonFilter__fields[2] = {
-  {1, UPB_SIZE(4, 4), 0, 0, 14, 1},
-  {2, UPB_SIZE(8, 8), 1, 0, 11, 1},
+  {1, UPB_SIZE(4, 4), 0, 0, 14, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 8), 1, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_accesslog_v3_ComparisonFilter_msginit = {
   &envoy_config_accesslog_v3_ComparisonFilter_submsgs[0],
   &envoy_config_accesslog_v3_ComparisonFilter__fields[0],
-  UPB_SIZE(16, 16), 2, false, 255,
+  UPB_SIZE(16, 16), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_config_accesslog_v3_StatusCodeFilter_submsgs[1] = {
@@ -94,13 +94,13 @@ static const upb_msglayout *const envoy_config_accesslog_v3_StatusCodeFilter_sub
 };
 
 static const upb_msglayout_field envoy_config_accesslog_v3_StatusCodeFilter__fields[1] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_accesslog_v3_StatusCodeFilter_msginit = {
   &envoy_config_accesslog_v3_StatusCodeFilter_submsgs[0],
   &envoy_config_accesslog_v3_StatusCodeFilter__fields[0],
-  UPB_SIZE(8, 16), 1, false, 255,
+  UPB_SIZE(8, 16), 1, false, 1, 255,
 };
 
 static const upb_msglayout *const envoy_config_accesslog_v3_DurationFilter_submsgs[1] = {
@@ -108,25 +108,25 @@ static const upb_msglayout *const envoy_config_accesslog_v3_DurationFilter_subms
 };
 
 static const upb_msglayout_field envoy_config_accesslog_v3_DurationFilter__fields[1] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_accesslog_v3_DurationFilter_msginit = {
   &envoy_config_accesslog_v3_DurationFilter_submsgs[0],
   &envoy_config_accesslog_v3_DurationFilter__fields[0],
-  UPB_SIZE(8, 16), 1, false, 255,
+  UPB_SIZE(8, 16), 1, false, 1, 255,
 };
 
 const upb_msglayout envoy_config_accesslog_v3_NotHealthCheckFilter_msginit = {
   NULL,
   NULL,
-  UPB_SIZE(0, 0), 0, false, 255,
+  UPB_SIZE(0, 0), 0, false, 0, 255,
 };
 
 const upb_msglayout envoy_config_accesslog_v3_TraceableFilter_msginit = {
   NULL,
   NULL,
-  UPB_SIZE(0, 0), 0, false, 255,
+  UPB_SIZE(0, 0), 0, false, 0, 255,
 };
 
 static const upb_msglayout *const envoy_config_accesslog_v3_RuntimeFilter_submsgs[1] = {
@@ -134,15 +134,15 @@ static const upb_msglayout *const envoy_config_accesslog_v3_RuntimeFilter_submsg
 };
 
 static const upb_msglayout_field envoy_config_accesslog_v3_RuntimeFilter__fields[3] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(12, 24), 1, 0, 11, 1},
-  {3, UPB_SIZE(1, 1), 0, 0, 8, 1},
+  {1, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(12, 24), 1, 0, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(1, 1), 0, 0, 8, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_accesslog_v3_RuntimeFilter_msginit = {
   &envoy_config_accesslog_v3_RuntimeFilter_submsgs[0],
   &envoy_config_accesslog_v3_RuntimeFilter__fields[0],
-  UPB_SIZE(16, 32), 3, false, 255,
+  UPB_SIZE(16, 32), 3, false, 3, 255,
 };
 
 static const upb_msglayout *const envoy_config_accesslog_v3_AndFilter_submsgs[1] = {
@@ -150,13 +150,13 @@ static const upb_msglayout *const envoy_config_accesslog_v3_AndFilter_submsgs[1]
 };
 
 static const upb_msglayout_field envoy_config_accesslog_v3_AndFilter__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 11, 3},
+  {1, UPB_SIZE(0, 0), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout envoy_config_accesslog_v3_AndFilter_msginit = {
   &envoy_config_accesslog_v3_AndFilter_submsgs[0],
   &envoy_config_accesslog_v3_AndFilter__fields[0],
-  UPB_SIZE(8, 8), 1, false, 255,
+  UPB_SIZE(8, 8), 1, false, 1, 255,
 };
 
 static const upb_msglayout *const envoy_config_accesslog_v3_OrFilter_submsgs[1] = {
@@ -164,13 +164,13 @@ static const upb_msglayout *const envoy_config_accesslog_v3_OrFilter_submsgs[1]
 };
 
 static const upb_msglayout_field envoy_config_accesslog_v3_OrFilter__fields[1] = {
-  {2, UPB_SIZE(0, 0), 0, 0, 11, 3},
+  {2, UPB_SIZE(0, 0), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout envoy_config_accesslog_v3_OrFilter_msginit = {
   &envoy_config_accesslog_v3_OrFilter_submsgs[0],
   &envoy_config_accesslog_v3_OrFilter__fields[0],
-  UPB_SIZE(8, 8), 1, false, 255,
+  UPB_SIZE(8, 8), 1, false, 0, 255,
 };
 
 static const upb_msglayout *const envoy_config_accesslog_v3_HeaderFilter_submsgs[1] = {
@@ -178,34 +178,34 @@ static const upb_msglayout *const envoy_config_accesslog_v3_HeaderFilter_submsgs
 };
 
 static const upb_msglayout_field envoy_config_accesslog_v3_HeaderFilter__fields[1] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_accesslog_v3_HeaderFilter_msginit = {
   &envoy_config_accesslog_v3_HeaderFilter_submsgs[0],
   &envoy_config_accesslog_v3_HeaderFilter__fields[0],
-  UPB_SIZE(8, 16), 1, false, 255,
+  UPB_SIZE(8, 16), 1, false, 1, 255,
 };
 
 static const upb_msglayout_field envoy_config_accesslog_v3_ResponseFlagFilter__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 3},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout envoy_config_accesslog_v3_ResponseFlagFilter_msginit = {
   NULL,
   &envoy_config_accesslog_v3_ResponseFlagFilter__fields[0],
-  UPB_SIZE(8, 8), 1, false, 255,
+  UPB_SIZE(8, 8), 1, false, 1, 255,
 };
 
 static const upb_msglayout_field envoy_config_accesslog_v3_GrpcStatusFilter__fields[2] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 14, _UPB_LABEL_PACKED},
-  {2, UPB_SIZE(0, 0), 0, 0, 8, 1},
+  {1, UPB_SIZE(4, 8), 0, 0, 14, _UPB_MODE_ARRAY | _UPB_MODE_IS_PACKED},
+  {2, UPB_SIZE(0, 0), 0, 0, 8, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_accesslog_v3_GrpcStatusFilter_msginit = {
   NULL,
   &envoy_config_accesslog_v3_GrpcStatusFilter__fields[0],
-  UPB_SIZE(8, 16), 2, false, 255,
+  UPB_SIZE(8, 16), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_config_accesslog_v3_MetadataFilter_submsgs[2] = {
@@ -214,14 +214,14 @@ static const upb_msglayout *const envoy_config_accesslog_v3_MetadataFilter_subms
 };
 
 static const upb_msglayout_field envoy_config_accesslog_v3_MetadataFilter__fields[2] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
-  {2, UPB_SIZE(8, 16), 2, 1, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 2, 1, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_accesslog_v3_MetadataFilter_msginit = {
   &envoy_config_accesslog_v3_MetadataFilter_submsgs[0],
   &envoy_config_accesslog_v3_MetadataFilter__fields[0],
-  UPB_SIZE(16, 24), 2, false, 255,
+  UPB_SIZE(16, 24), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_config_accesslog_v3_ExtensionFilter_submsgs[1] = {
@@ -229,14 +229,14 @@ static const upb_msglayout *const envoy_config_accesslog_v3_ExtensionFilter_subm
 };
 
 static const upb_msglayout_field envoy_config_accesslog_v3_ExtensionFilter__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {3, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 0, 11, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_accesslog_v3_ExtensionFilter_msginit = {
   &envoy_config_accesslog_v3_ExtensionFilter_submsgs[0],
   &envoy_config_accesslog_v3_ExtensionFilter__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 1, 255,
 };
 
 #include "upb/port_undef.inc"
index 8e33c86..34eba0d 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_CONFIG_ACCESSLOG_V3_ACCESSLOG_PROTO_UPB_H_
 #define ENVOY_CONFIG_ACCESSLOG_V3_ACCESSLOG_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -113,13 +113,19 @@ UPB_INLINE envoy_config_accesslog_v3_AccessLog *envoy_config_accesslog_v3_Access
 UPB_INLINE envoy_config_accesslog_v3_AccessLog *envoy_config_accesslog_v3_AccessLog_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_accesslog_v3_AccessLog *ret = envoy_config_accesslog_v3_AccessLog_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_accesslog_v3_AccessLog_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_accesslog_v3_AccessLog_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_accesslog_v3_AccessLog *envoy_config_accesslog_v3_AccessLog_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_accesslog_v3_AccessLog *ret = envoy_config_accesslog_v3_AccessLog_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_accesslog_v3_AccessLog_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_accesslog_v3_AccessLog_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_accesslog_v3_AccessLog_serialize(const envoy_config_accesslog_v3_AccessLog *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_accesslog_v3_AccessLog_msginit, arena, len);
@@ -174,13 +180,19 @@ UPB_INLINE envoy_config_accesslog_v3_AccessLogFilter *envoy_config_accesslog_v3_
 UPB_INLINE envoy_config_accesslog_v3_AccessLogFilter *envoy_config_accesslog_v3_AccessLogFilter_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_accesslog_v3_AccessLogFilter *ret = envoy_config_accesslog_v3_AccessLogFilter_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_accesslog_v3_AccessLogFilter_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_accesslog_v3_AccessLogFilter_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_accesslog_v3_AccessLogFilter *envoy_config_accesslog_v3_AccessLogFilter_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_accesslog_v3_AccessLogFilter *ret = envoy_config_accesslog_v3_AccessLogFilter_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_accesslog_v3_AccessLogFilter_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_accesslog_v3_AccessLogFilter_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_accesslog_v3_AccessLogFilter_serialize(const envoy_config_accesslog_v3_AccessLogFilter *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_accesslog_v3_AccessLogFilter_msginit, arena, len);
@@ -381,13 +393,19 @@ UPB_INLINE envoy_config_accesslog_v3_ComparisonFilter *envoy_config_accesslog_v3
 UPB_INLINE envoy_config_accesslog_v3_ComparisonFilter *envoy_config_accesslog_v3_ComparisonFilter_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_accesslog_v3_ComparisonFilter *ret = envoy_config_accesslog_v3_ComparisonFilter_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_accesslog_v3_ComparisonFilter_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_accesslog_v3_ComparisonFilter_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_accesslog_v3_ComparisonFilter *envoy_config_accesslog_v3_ComparisonFilter_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_accesslog_v3_ComparisonFilter *ret = envoy_config_accesslog_v3_ComparisonFilter_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_accesslog_v3_ComparisonFilter_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_accesslog_v3_ComparisonFilter_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_accesslog_v3_ComparisonFilter_serialize(const envoy_config_accesslog_v3_ComparisonFilter *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_accesslog_v3_ComparisonFilter_msginit, arena, len);
@@ -422,13 +440,19 @@ UPB_INLINE envoy_config_accesslog_v3_StatusCodeFilter *envoy_config_accesslog_v3
 UPB_INLINE envoy_config_accesslog_v3_StatusCodeFilter *envoy_config_accesslog_v3_StatusCodeFilter_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_accesslog_v3_StatusCodeFilter *ret = envoy_config_accesslog_v3_StatusCodeFilter_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_accesslog_v3_StatusCodeFilter_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_accesslog_v3_StatusCodeFilter_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_accesslog_v3_StatusCodeFilter *envoy_config_accesslog_v3_StatusCodeFilter_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_accesslog_v3_StatusCodeFilter *ret = envoy_config_accesslog_v3_StatusCodeFilter_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_accesslog_v3_StatusCodeFilter_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_accesslog_v3_StatusCodeFilter_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_accesslog_v3_StatusCodeFilter_serialize(const envoy_config_accesslog_v3_StatusCodeFilter *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_accesslog_v3_StatusCodeFilter_msginit, arena, len);
@@ -459,13 +483,19 @@ UPB_INLINE envoy_config_accesslog_v3_DurationFilter *envoy_config_accesslog_v3_D
 UPB_INLINE envoy_config_accesslog_v3_DurationFilter *envoy_config_accesslog_v3_DurationFilter_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_accesslog_v3_DurationFilter *ret = envoy_config_accesslog_v3_DurationFilter_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_accesslog_v3_DurationFilter_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_accesslog_v3_DurationFilter_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_accesslog_v3_DurationFilter *envoy_config_accesslog_v3_DurationFilter_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_accesslog_v3_DurationFilter *ret = envoy_config_accesslog_v3_DurationFilter_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_accesslog_v3_DurationFilter_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_accesslog_v3_DurationFilter_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_accesslog_v3_DurationFilter_serialize(const envoy_config_accesslog_v3_DurationFilter *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_accesslog_v3_DurationFilter_msginit, arena, len);
@@ -496,13 +526,19 @@ UPB_INLINE envoy_config_accesslog_v3_NotHealthCheckFilter *envoy_config_accesslo
 UPB_INLINE envoy_config_accesslog_v3_NotHealthCheckFilter *envoy_config_accesslog_v3_NotHealthCheckFilter_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_accesslog_v3_NotHealthCheckFilter *ret = envoy_config_accesslog_v3_NotHealthCheckFilter_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_accesslog_v3_NotHealthCheckFilter_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_accesslog_v3_NotHealthCheckFilter_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_accesslog_v3_NotHealthCheckFilter *envoy_config_accesslog_v3_NotHealthCheckFilter_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_accesslog_v3_NotHealthCheckFilter *ret = envoy_config_accesslog_v3_NotHealthCheckFilter_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_accesslog_v3_NotHealthCheckFilter_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_accesslog_v3_NotHealthCheckFilter_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_accesslog_v3_NotHealthCheckFilter_serialize(const envoy_config_accesslog_v3_NotHealthCheckFilter *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_accesslog_v3_NotHealthCheckFilter_msginit, arena, len);
@@ -518,13 +554,19 @@ UPB_INLINE envoy_config_accesslog_v3_TraceableFilter *envoy_config_accesslog_v3_
 UPB_INLINE envoy_config_accesslog_v3_TraceableFilter *envoy_config_accesslog_v3_TraceableFilter_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_accesslog_v3_TraceableFilter *ret = envoy_config_accesslog_v3_TraceableFilter_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_accesslog_v3_TraceableFilter_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_accesslog_v3_TraceableFilter_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_accesslog_v3_TraceableFilter *envoy_config_accesslog_v3_TraceableFilter_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_accesslog_v3_TraceableFilter *ret = envoy_config_accesslog_v3_TraceableFilter_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_accesslog_v3_TraceableFilter_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_accesslog_v3_TraceableFilter_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_accesslog_v3_TraceableFilter_serialize(const envoy_config_accesslog_v3_TraceableFilter *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_accesslog_v3_TraceableFilter_msginit, arena, len);
@@ -540,13 +582,19 @@ UPB_INLINE envoy_config_accesslog_v3_RuntimeFilter *envoy_config_accesslog_v3_Ru
 UPB_INLINE envoy_config_accesslog_v3_RuntimeFilter *envoy_config_accesslog_v3_RuntimeFilter_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_accesslog_v3_RuntimeFilter *ret = envoy_config_accesslog_v3_RuntimeFilter_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_accesslog_v3_RuntimeFilter_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_accesslog_v3_RuntimeFilter_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_accesslog_v3_RuntimeFilter *envoy_config_accesslog_v3_RuntimeFilter_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_accesslog_v3_RuntimeFilter *ret = envoy_config_accesslog_v3_RuntimeFilter_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_accesslog_v3_RuntimeFilter_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_accesslog_v3_RuntimeFilter_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_accesslog_v3_RuntimeFilter_serialize(const envoy_config_accesslog_v3_RuntimeFilter *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_accesslog_v3_RuntimeFilter_msginit, arena, len);
@@ -585,13 +633,19 @@ UPB_INLINE envoy_config_accesslog_v3_AndFilter *envoy_config_accesslog_v3_AndFil
 UPB_INLINE envoy_config_accesslog_v3_AndFilter *envoy_config_accesslog_v3_AndFilter_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_accesslog_v3_AndFilter *ret = envoy_config_accesslog_v3_AndFilter_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_accesslog_v3_AndFilter_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_accesslog_v3_AndFilter_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_accesslog_v3_AndFilter *envoy_config_accesslog_v3_AndFilter_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_accesslog_v3_AndFilter *ret = envoy_config_accesslog_v3_AndFilter_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_accesslog_v3_AndFilter_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_accesslog_v3_AndFilter_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_accesslog_v3_AndFilter_serialize(const envoy_config_accesslog_v3_AndFilter *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_accesslog_v3_AndFilter_msginit, arena, len);
@@ -622,13 +676,19 @@ UPB_INLINE envoy_config_accesslog_v3_OrFilter *envoy_config_accesslog_v3_OrFilte
 UPB_INLINE envoy_config_accesslog_v3_OrFilter *envoy_config_accesslog_v3_OrFilter_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_accesslog_v3_OrFilter *ret = envoy_config_accesslog_v3_OrFilter_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_accesslog_v3_OrFilter_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_accesslog_v3_OrFilter_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_accesslog_v3_OrFilter *envoy_config_accesslog_v3_OrFilter_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_accesslog_v3_OrFilter *ret = envoy_config_accesslog_v3_OrFilter_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_accesslog_v3_OrFilter_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_accesslog_v3_OrFilter_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_accesslog_v3_OrFilter_serialize(const envoy_config_accesslog_v3_OrFilter *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_accesslog_v3_OrFilter_msginit, arena, len);
@@ -659,13 +719,19 @@ UPB_INLINE envoy_config_accesslog_v3_HeaderFilter *envoy_config_accesslog_v3_Hea
 UPB_INLINE envoy_config_accesslog_v3_HeaderFilter *envoy_config_accesslog_v3_HeaderFilter_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_accesslog_v3_HeaderFilter *ret = envoy_config_accesslog_v3_HeaderFilter_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_accesslog_v3_HeaderFilter_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_accesslog_v3_HeaderFilter_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_accesslog_v3_HeaderFilter *envoy_config_accesslog_v3_HeaderFilter_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_accesslog_v3_HeaderFilter *ret = envoy_config_accesslog_v3_HeaderFilter_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_accesslog_v3_HeaderFilter_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_accesslog_v3_HeaderFilter_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_accesslog_v3_HeaderFilter_serialize(const envoy_config_accesslog_v3_HeaderFilter *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_accesslog_v3_HeaderFilter_msginit, arena, len);
@@ -696,13 +762,19 @@ UPB_INLINE envoy_config_accesslog_v3_ResponseFlagFilter *envoy_config_accesslog_
 UPB_INLINE envoy_config_accesslog_v3_ResponseFlagFilter *envoy_config_accesslog_v3_ResponseFlagFilter_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_accesslog_v3_ResponseFlagFilter *ret = envoy_config_accesslog_v3_ResponseFlagFilter_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_accesslog_v3_ResponseFlagFilter_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_accesslog_v3_ResponseFlagFilter_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_accesslog_v3_ResponseFlagFilter *envoy_config_accesslog_v3_ResponseFlagFilter_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_accesslog_v3_ResponseFlagFilter *ret = envoy_config_accesslog_v3_ResponseFlagFilter_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_accesslog_v3_ResponseFlagFilter_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_accesslog_v3_ResponseFlagFilter_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_accesslog_v3_ResponseFlagFilter_serialize(const envoy_config_accesslog_v3_ResponseFlagFilter *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_accesslog_v3_ResponseFlagFilter_msginit, arena, len);
@@ -729,13 +801,19 @@ UPB_INLINE envoy_config_accesslog_v3_GrpcStatusFilter *envoy_config_accesslog_v3
 UPB_INLINE envoy_config_accesslog_v3_GrpcStatusFilter *envoy_config_accesslog_v3_GrpcStatusFilter_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_accesslog_v3_GrpcStatusFilter *ret = envoy_config_accesslog_v3_GrpcStatusFilter_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_accesslog_v3_GrpcStatusFilter_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_accesslog_v3_GrpcStatusFilter_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_accesslog_v3_GrpcStatusFilter *envoy_config_accesslog_v3_GrpcStatusFilter_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_accesslog_v3_GrpcStatusFilter *ret = envoy_config_accesslog_v3_GrpcStatusFilter_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_accesslog_v3_GrpcStatusFilter_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_accesslog_v3_GrpcStatusFilter_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_accesslog_v3_GrpcStatusFilter_serialize(const envoy_config_accesslog_v3_GrpcStatusFilter *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_accesslog_v3_GrpcStatusFilter_msginit, arena, len);
@@ -766,13 +844,19 @@ UPB_INLINE envoy_config_accesslog_v3_MetadataFilter *envoy_config_accesslog_v3_M
 UPB_INLINE envoy_config_accesslog_v3_MetadataFilter *envoy_config_accesslog_v3_MetadataFilter_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_accesslog_v3_MetadataFilter *ret = envoy_config_accesslog_v3_MetadataFilter_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_accesslog_v3_MetadataFilter_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_accesslog_v3_MetadataFilter_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_accesslog_v3_MetadataFilter *envoy_config_accesslog_v3_MetadataFilter_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_accesslog_v3_MetadataFilter *ret = envoy_config_accesslog_v3_MetadataFilter_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_accesslog_v3_MetadataFilter_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_accesslog_v3_MetadataFilter_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_accesslog_v3_MetadataFilter_serialize(const envoy_config_accesslog_v3_MetadataFilter *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_accesslog_v3_MetadataFilter_msginit, arena, len);
@@ -818,13 +902,19 @@ UPB_INLINE envoy_config_accesslog_v3_ExtensionFilter *envoy_config_accesslog_v3_
 UPB_INLINE envoy_config_accesslog_v3_ExtensionFilter *envoy_config_accesslog_v3_ExtensionFilter_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_accesslog_v3_ExtensionFilter *ret = envoy_config_accesslog_v3_ExtensionFilter_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_accesslog_v3_ExtensionFilter_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_accesslog_v3_ExtensionFilter_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_accesslog_v3_ExtensionFilter *envoy_config_accesslog_v3_ExtensionFilter_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_accesslog_v3_ExtensionFilter *ret = envoy_config_accesslog_v3_ExtensionFilter_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_accesslog_v3_ExtensionFilter_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_accesslog_v3_ExtensionFilter_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_accesslog_v3_ExtensionFilter_serialize(const envoy_config_accesslog_v3_ExtensionFilter *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_accesslog_v3_ExtensionFilter_msginit, arena, len);
index 153cbc6..5b72a4c 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/config/bootstrap/v3/bootstrap.upb.h"
 #include "envoy/config/accesslog/v3/accesslog.upb.h"
 #include "envoy/config/cluster/v3/cluster.upb.h"
@@ -61,42 +61,42 @@ static const upb_msglayout *const envoy_config_bootstrap_v3_Bootstrap_submsgs[21
 };
 
 static const upb_msglayout_field envoy_config_bootstrap_v3_Bootstrap__fields[30] = {
-  {1, UPB_SIZE(32, 56), 1, 13, 11, 1},
-  {2, UPB_SIZE(36, 64), 2, 3, 11, 1},
-  {3, UPB_SIZE(40, 72), 3, 2, 11, 1},
-  {4, UPB_SIZE(44, 80), 4, 4, 11, 1},
-  {5, UPB_SIZE(8, 8), 0, 0, 9, 1},
-  {6, UPB_SIZE(100, 192), 0, 16, 11, 3},
-  {7, UPB_SIZE(48, 88), 5, 19, 11, 1},
-  {8, UPB_SIZE(52, 96), 6, 8, 11, 1},
-  {9, UPB_SIZE(56, 104), 7, 18, 11, 1},
-  {12, UPB_SIZE(60, 112), 8, 0, 11, 1},
-  {13, UPB_SIZE(64, 120), 9, 15, 11, 1},
-  {14, UPB_SIZE(68, 128), 10, 10, 11, 1},
-  {15, UPB_SIZE(72, 136), 11, 17, 11, 1},
-  {16, UPB_SIZE(3, 3), 0, 0, 8, 1},
-  {17, UPB_SIZE(76, 144), 12, 7, 11, 1},
-  {18, UPB_SIZE(16, 24), 0, 0, 9, 1},
-  {19, UPB_SIZE(80, 152), 13, 20, 11, 1},
-  {20, UPB_SIZE(4, 4), 0, 0, 8, 1},
-  {21, UPB_SIZE(104, 200), 0, 14, 11, 3},
-  {22, UPB_SIZE(108, 208), 0, 11, 11, 3},
-  {23, UPB_SIZE(84, 160), 14, 11, 11, 1},
-  {24, UPB_SIZE(24, 40), 0, 0, 9, 1},
-  {25, UPB_SIZE(112, 216), 0, 1, 11, _UPB_LABEL_MAP},
-  {26, UPB_SIZE(116, 224), 0, 0, 9, 3},
-  {27, UPB_SIZE(88, 168), 15, 9, 11, 1},
-  {28, UPB_SIZE(120, 232), 0, 6, 11, 3},
-  {29, UPB_SIZE(128, 248), UPB_SIZE(-133, -253), 0, 8, 1},
-  {30, UPB_SIZE(92, 176), 16, 12, 11, 1},
-  {31, UPB_SIZE(96, 184), 17, 14, 11, 1},
-  {32, UPB_SIZE(124, 240), 0, 5, 11, 3},
+  {1, UPB_SIZE(32, 56), 1, 13, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(36, 64), 2, 3, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(40, 72), 3, 2, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(44, 80), 4, 4, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(8, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(100, 192), 0, 16, 11, _UPB_MODE_ARRAY},
+  {7, UPB_SIZE(48, 88), 5, 19, 11, _UPB_MODE_SCALAR},
+  {8, UPB_SIZE(52, 96), 6, 8, 11, _UPB_MODE_SCALAR},
+  {9, UPB_SIZE(56, 104), 7, 18, 11, _UPB_MODE_SCALAR},
+  {12, UPB_SIZE(60, 112), 8, 0, 11, _UPB_MODE_SCALAR},
+  {13, UPB_SIZE(64, 120), 9, 15, 11, _UPB_MODE_SCALAR},
+  {14, UPB_SIZE(68, 128), 10, 10, 11, _UPB_MODE_SCALAR},
+  {15, UPB_SIZE(72, 136), 11, 17, 11, _UPB_MODE_SCALAR},
+  {16, UPB_SIZE(3, 3), 0, 0, 8, _UPB_MODE_SCALAR},
+  {17, UPB_SIZE(76, 144), 12, 7, 11, _UPB_MODE_SCALAR},
+  {18, UPB_SIZE(16, 24), 0, 0, 9, _UPB_MODE_SCALAR},
+  {19, UPB_SIZE(80, 152), 13, 20, 11, _UPB_MODE_SCALAR},
+  {20, UPB_SIZE(4, 4), 0, 0, 8, _UPB_MODE_SCALAR},
+  {21, UPB_SIZE(104, 200), 0, 14, 11, _UPB_MODE_ARRAY},
+  {22, UPB_SIZE(108, 208), 0, 11, 11, _UPB_MODE_ARRAY},
+  {23, UPB_SIZE(84, 160), 14, 11, 11, _UPB_MODE_SCALAR},
+  {24, UPB_SIZE(24, 40), 0, 0, 9, _UPB_MODE_SCALAR},
+  {25, UPB_SIZE(112, 216), 0, 1, 11, _UPB_MODE_MAP},
+  {26, UPB_SIZE(116, 224), 0, 0, 9, _UPB_MODE_ARRAY},
+  {27, UPB_SIZE(88, 168), 15, 9, 11, _UPB_MODE_SCALAR},
+  {28, UPB_SIZE(120, 232), 0, 6, 11, _UPB_MODE_ARRAY},
+  {29, UPB_SIZE(128, 248), UPB_SIZE(-133, -253), 0, 8, _UPB_MODE_SCALAR},
+  {30, UPB_SIZE(92, 176), 16, 12, 11, _UPB_MODE_SCALAR},
+  {31, UPB_SIZE(96, 184), 17, 14, 11, _UPB_MODE_SCALAR},
+  {32, UPB_SIZE(124, 240), 0, 5, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout envoy_config_bootstrap_v3_Bootstrap_msginit = {
   &envoy_config_bootstrap_v3_Bootstrap_submsgs[0],
   &envoy_config_bootstrap_v3_Bootstrap__fields[0],
-  UPB_SIZE(136, 256), 30, false, 255,
+  UPB_SIZE(136, 256), 30, false, 9, 255,
 };
 
 static const upb_msglayout *const envoy_config_bootstrap_v3_Bootstrap_StaticResources_submsgs[3] = {
@@ -106,15 +106,15 @@ static const upb_msglayout *const envoy_config_bootstrap_v3_Bootstrap_StaticReso
 };
 
 static const upb_msglayout_field envoy_config_bootstrap_v3_Bootstrap_StaticResources__fields[3] = {
-  {1, UPB_SIZE(0, 0), 0, 1, 11, 3},
-  {2, UPB_SIZE(4, 8), 0, 0, 11, 3},
-  {3, UPB_SIZE(8, 16), 0, 2, 11, 3},
+  {1, UPB_SIZE(0, 0), 0, 1, 11, _UPB_MODE_ARRAY},
+  {2, UPB_SIZE(4, 8), 0, 0, 11, _UPB_MODE_ARRAY},
+  {3, UPB_SIZE(8, 16), 0, 2, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout envoy_config_bootstrap_v3_Bootstrap_StaticResources_msginit = {
   &envoy_config_bootstrap_v3_Bootstrap_StaticResources_submsgs[0],
   &envoy_config_bootstrap_v3_Bootstrap_StaticResources__fields[0],
-  UPB_SIZE(16, 24), 3, false, 255,
+  UPB_SIZE(16, 24), 3, false, 3, 255,
 };
 
 static const upb_msglayout *const envoy_config_bootstrap_v3_Bootstrap_DynamicResources_submsgs[2] = {
@@ -123,17 +123,17 @@ static const upb_msglayout *const envoy_config_bootstrap_v3_Bootstrap_DynamicRes
 };
 
 static const upb_msglayout_field envoy_config_bootstrap_v3_Bootstrap_DynamicResources__fields[5] = {
-  {1, UPB_SIZE(20, 40), 1, 1, 11, 1},
-  {2, UPB_SIZE(24, 48), 2, 1, 11, 1},
-  {3, UPB_SIZE(28, 56), 3, 0, 11, 1},
-  {5, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {6, UPB_SIZE(12, 24), 0, 0, 9, 1},
+  {1, UPB_SIZE(20, 40), 1, 1, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(24, 48), 2, 1, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(28, 56), 3, 0, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(12, 24), 0, 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_bootstrap_v3_Bootstrap_DynamicResources_msginit = {
   &envoy_config_bootstrap_v3_Bootstrap_DynamicResources_submsgs[0],
   &envoy_config_bootstrap_v3_Bootstrap_DynamicResources__fields[0],
-  UPB_SIZE(32, 64), 5, false, 255,
+  UPB_SIZE(32, 64), 5, false, 3, 255,
 };
 
 static const upb_msglayout *const envoy_config_bootstrap_v3_Bootstrap_CertificateProviderInstancesEntry_submsgs[1] = {
@@ -141,14 +141,14 @@ static const upb_msglayout *const envoy_config_bootstrap_v3_Bootstrap_Certificat
 };
 
 static const upb_msglayout_field envoy_config_bootstrap_v3_Bootstrap_CertificateProviderInstancesEntry__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {2, UPB_SIZE(8, 16), 0, 0, 11, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 0, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_bootstrap_v3_Bootstrap_CertificateProviderInstancesEntry_msginit = {
   &envoy_config_bootstrap_v3_Bootstrap_CertificateProviderInstancesEntry_submsgs[0],
   &envoy_config_bootstrap_v3_Bootstrap_CertificateProviderInstancesEntry__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_config_bootstrap_v3_Admin_submsgs[3] = {
@@ -158,17 +158,17 @@ static const upb_msglayout *const envoy_config_bootstrap_v3_Admin_submsgs[3] = {
 };
 
 static const upb_msglayout_field envoy_config_bootstrap_v3_Admin__fields[5] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(12, 24), 0, 0, 9, 1},
-  {3, UPB_SIZE(20, 40), 1, 1, 11, 1},
-  {4, UPB_SIZE(24, 48), 0, 2, 11, 3},
-  {5, UPB_SIZE(28, 56), 0, 0, 11, 3},
+  {1, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(12, 24), 0, 0, 9, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(20, 40), 1, 1, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(24, 48), 0, 2, 11, _UPB_MODE_ARRAY},
+  {5, UPB_SIZE(28, 56), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout envoy_config_bootstrap_v3_Admin_msginit = {
   &envoy_config_bootstrap_v3_Admin_submsgs[0],
   &envoy_config_bootstrap_v3_Admin__fields[0],
-  UPB_SIZE(32, 64), 5, false, 255,
+  UPB_SIZE(32, 64), 5, false, 5, 255,
 };
 
 static const upb_msglayout *const envoy_config_bootstrap_v3_ClusterManager_submsgs[3] = {
@@ -178,16 +178,16 @@ static const upb_msglayout *const envoy_config_bootstrap_v3_ClusterManager_subms
 };
 
 static const upb_msglayout_field envoy_config_bootstrap_v3_ClusterManager__fields[4] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(12, 24), 1, 0, 11, 1},
-  {3, UPB_SIZE(16, 32), 2, 2, 11, 1},
-  {4, UPB_SIZE(20, 40), 3, 1, 11, 1},
+  {1, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(12, 24), 1, 0, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(16, 32), 2, 2, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(20, 40), 3, 1, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_bootstrap_v3_ClusterManager_msginit = {
   &envoy_config_bootstrap_v3_ClusterManager_submsgs[0],
   &envoy_config_bootstrap_v3_ClusterManager__fields[0],
-  UPB_SIZE(24, 48), 4, false, 255,
+  UPB_SIZE(24, 48), 4, false, 4, 255,
 };
 
 static const upb_msglayout *const envoy_config_bootstrap_v3_ClusterManager_OutlierDetection_submsgs[1] = {
@@ -195,14 +195,14 @@ static const upb_msglayout *const envoy_config_bootstrap_v3_ClusterManager_Outli
 };
 
 static const upb_msglayout_field envoy_config_bootstrap_v3_ClusterManager_OutlierDetection__fields[2] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(12, 24), 1, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(12, 24), 1, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_bootstrap_v3_ClusterManager_OutlierDetection_msginit = {
   &envoy_config_bootstrap_v3_ClusterManager_OutlierDetection_submsgs[0],
   &envoy_config_bootstrap_v3_ClusterManager_OutlierDetection__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_config_bootstrap_v3_Watchdogs_submsgs[1] = {
@@ -210,14 +210,14 @@ static const upb_msglayout *const envoy_config_bootstrap_v3_Watchdogs_submsgs[1]
 };
 
 static const upb_msglayout_field envoy_config_bootstrap_v3_Watchdogs__fields[2] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
-  {2, UPB_SIZE(8, 16), 2, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 2, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_bootstrap_v3_Watchdogs_msginit = {
   &envoy_config_bootstrap_v3_Watchdogs_submsgs[0],
   &envoy_config_bootstrap_v3_Watchdogs__fields[0],
-  UPB_SIZE(16, 24), 2, false, 255,
+  UPB_SIZE(16, 24), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_config_bootstrap_v3_Watchdog_submsgs[3] = {
@@ -227,19 +227,19 @@ static const upb_msglayout *const envoy_config_bootstrap_v3_Watchdog_submsgs[3]
 };
 
 static const upb_msglayout_field envoy_config_bootstrap_v3_Watchdog__fields[7] = {
-  {1, UPB_SIZE(4, 8), 1, 2, 11, 1},
-  {2, UPB_SIZE(8, 16), 2, 2, 11, 1},
-  {3, UPB_SIZE(12, 24), 3, 2, 11, 1},
-  {4, UPB_SIZE(16, 32), 4, 2, 11, 1},
-  {5, UPB_SIZE(20, 40), 5, 1, 11, 1},
-  {6, UPB_SIZE(24, 48), 6, 2, 11, 1},
-  {7, UPB_SIZE(28, 56), 0, 0, 11, 3},
+  {1, UPB_SIZE(4, 8), 1, 2, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 2, 2, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(12, 24), 3, 2, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(16, 32), 4, 2, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(20, 40), 5, 1, 11, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(24, 48), 6, 2, 11, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(28, 56), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout envoy_config_bootstrap_v3_Watchdog_msginit = {
   &envoy_config_bootstrap_v3_Watchdog_submsgs[0],
   &envoy_config_bootstrap_v3_Watchdog__fields[0],
-  UPB_SIZE(32, 64), 7, false, 255,
+  UPB_SIZE(32, 64), 7, false, 7, 255,
 };
 
 static const upb_msglayout *const envoy_config_bootstrap_v3_Watchdog_WatchdogAction_submsgs[1] = {
@@ -247,14 +247,14 @@ static const upb_msglayout *const envoy_config_bootstrap_v3_Watchdog_WatchdogAct
 };
 
 static const upb_msglayout_field envoy_config_bootstrap_v3_Watchdog_WatchdogAction__fields[2] = {
-  {1, UPB_SIZE(8, 8), 1, 0, 11, 1},
-  {2, UPB_SIZE(4, 4), 0, 0, 14, 1},
+  {1, UPB_SIZE(8, 8), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(4, 4), 0, 0, 14, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_bootstrap_v3_Watchdog_WatchdogAction_msginit = {
   &envoy_config_bootstrap_v3_Watchdog_WatchdogAction_submsgs[0],
   &envoy_config_bootstrap_v3_Watchdog_WatchdogAction__fields[0],
-  UPB_SIZE(16, 16), 2, false, 255,
+  UPB_SIZE(16, 16), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_config_bootstrap_v3_FatalAction_submsgs[1] = {
@@ -262,13 +262,13 @@ static const upb_msglayout *const envoy_config_bootstrap_v3_FatalAction_submsgs[
 };
 
 static const upb_msglayout_field envoy_config_bootstrap_v3_FatalAction__fields[1] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_bootstrap_v3_FatalAction_msginit = {
   &envoy_config_bootstrap_v3_FatalAction_submsgs[0],
   &envoy_config_bootstrap_v3_FatalAction__fields[0],
-  UPB_SIZE(8, 16), 1, false, 255,
+  UPB_SIZE(8, 16), 1, false, 1, 255,
 };
 
 static const upb_msglayout *const envoy_config_bootstrap_v3_Runtime_submsgs[1] = {
@@ -276,16 +276,16 @@ static const upb_msglayout *const envoy_config_bootstrap_v3_Runtime_submsgs[1] =
 };
 
 static const upb_msglayout_field envoy_config_bootstrap_v3_Runtime__fields[4] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(12, 24), 0, 0, 9, 1},
-  {3, UPB_SIZE(20, 40), 0, 0, 9, 1},
-  {4, UPB_SIZE(28, 56), 1, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(12, 24), 0, 0, 9, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(20, 40), 0, 0, 9, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(28, 56), 1, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_bootstrap_v3_Runtime_msginit = {
   &envoy_config_bootstrap_v3_Runtime_submsgs[0],
   &envoy_config_bootstrap_v3_Runtime__fields[0],
-  UPB_SIZE(32, 64), 4, false, 255,
+  UPB_SIZE(32, 64), 4, false, 4, 255,
 };
 
 static const upb_msglayout *const envoy_config_bootstrap_v3_RuntimeLayer_submsgs[4] = {
@@ -296,35 +296,35 @@ static const upb_msglayout *const envoy_config_bootstrap_v3_RuntimeLayer_submsgs
 };
 
 static const upb_msglayout_field envoy_config_bootstrap_v3_RuntimeLayer__fields[5] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {2, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 3, 11, 1},
-  {3, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 1, 11, 1},
-  {4, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 0, 11, 1},
-  {5, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 2, 11, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 3, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 1, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 0, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 2, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_bootstrap_v3_RuntimeLayer_msginit = {
   &envoy_config_bootstrap_v3_RuntimeLayer_submsgs[0],
   &envoy_config_bootstrap_v3_RuntimeLayer__fields[0],
-  UPB_SIZE(16, 32), 5, false, 255,
+  UPB_SIZE(16, 32), 5, false, 5, 255,
 };
 
 static const upb_msglayout_field envoy_config_bootstrap_v3_RuntimeLayer_DiskLayer__fields[3] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(0, 0), 0, 0, 8, 1},
-  {3, UPB_SIZE(12, 24), 0, 0, 9, 1},
+  {1, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(0, 0), 0, 0, 8, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(12, 24), 0, 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_bootstrap_v3_RuntimeLayer_DiskLayer_msginit = {
   NULL,
   &envoy_config_bootstrap_v3_RuntimeLayer_DiskLayer__fields[0],
-  UPB_SIZE(24, 48), 3, false, 255,
+  UPB_SIZE(24, 48), 3, false, 3, 255,
 };
 
 const upb_msglayout envoy_config_bootstrap_v3_RuntimeLayer_AdminLayer_msginit = {
   NULL,
   NULL,
-  UPB_SIZE(0, 0), 0, false, 255,
+  UPB_SIZE(0, 0), 0, false, 0, 255,
 };
 
 static const upb_msglayout *const envoy_config_bootstrap_v3_RuntimeLayer_RtdsLayer_submsgs[1] = {
@@ -332,14 +332,14 @@ static const upb_msglayout *const envoy_config_bootstrap_v3_RuntimeLayer_RtdsLay
 };
 
 static const upb_msglayout_field envoy_config_bootstrap_v3_RuntimeLayer_RtdsLayer__fields[2] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(12, 24), 1, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(12, 24), 1, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_bootstrap_v3_RuntimeLayer_RtdsLayer_msginit = {
   &envoy_config_bootstrap_v3_RuntimeLayer_RtdsLayer_submsgs[0],
   &envoy_config_bootstrap_v3_RuntimeLayer_RtdsLayer__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_config_bootstrap_v3_LayeredRuntime_submsgs[1] = {
@@ -347,24 +347,24 @@ static const upb_msglayout *const envoy_config_bootstrap_v3_LayeredRuntime_subms
 };
 
 static const upb_msglayout_field envoy_config_bootstrap_v3_LayeredRuntime__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 11, 3},
+  {1, UPB_SIZE(0, 0), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout envoy_config_bootstrap_v3_LayeredRuntime_msginit = {
   &envoy_config_bootstrap_v3_LayeredRuntime_submsgs[0],
   &envoy_config_bootstrap_v3_LayeredRuntime__fields[0],
-  UPB_SIZE(8, 8), 1, false, 255,
+  UPB_SIZE(8, 8), 1, false, 1, 255,
 };
 
 static const upb_msglayout_field envoy_config_bootstrap_v3_CustomInlineHeader__fields[2] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(0, 0), 0, 0, 14, 1},
+  {1, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(0, 0), 0, 0, 14, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_bootstrap_v3_CustomInlineHeader_msginit = {
   NULL,
   &envoy_config_bootstrap_v3_CustomInlineHeader__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 #include "upb/port_undef.inc"
index 21152f2..33a9b2c 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_CONFIG_BOOTSTRAP_V3_BOOTSTRAP_PROTO_UPB_H_
 #define ENVOY_CONFIG_BOOTSTRAP_V3_BOOTSTRAP_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -141,13 +141,19 @@ UPB_INLINE envoy_config_bootstrap_v3_Bootstrap *envoy_config_bootstrap_v3_Bootst
 UPB_INLINE envoy_config_bootstrap_v3_Bootstrap *envoy_config_bootstrap_v3_Bootstrap_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_bootstrap_v3_Bootstrap *ret = envoy_config_bootstrap_v3_Bootstrap_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_Bootstrap_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_Bootstrap_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_bootstrap_v3_Bootstrap *envoy_config_bootstrap_v3_Bootstrap_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_bootstrap_v3_Bootstrap *ret = envoy_config_bootstrap_v3_Bootstrap_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_Bootstrap_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_Bootstrap_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_bootstrap_v3_Bootstrap_serialize(const envoy_config_bootstrap_v3_Bootstrap *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_bootstrap_v3_Bootstrap_msginit, arena, len);
@@ -543,13 +549,19 @@ UPB_INLINE envoy_config_bootstrap_v3_Bootstrap_StaticResources *envoy_config_boo
 UPB_INLINE envoy_config_bootstrap_v3_Bootstrap_StaticResources *envoy_config_bootstrap_v3_Bootstrap_StaticResources_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_bootstrap_v3_Bootstrap_StaticResources *ret = envoy_config_bootstrap_v3_Bootstrap_StaticResources_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_Bootstrap_StaticResources_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_Bootstrap_StaticResources_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_bootstrap_v3_Bootstrap_StaticResources *envoy_config_bootstrap_v3_Bootstrap_StaticResources_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_bootstrap_v3_Bootstrap_StaticResources *ret = envoy_config_bootstrap_v3_Bootstrap_StaticResources_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_Bootstrap_StaticResources_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_Bootstrap_StaticResources_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_bootstrap_v3_Bootstrap_StaticResources_serialize(const envoy_config_bootstrap_v3_Bootstrap_StaticResources *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_bootstrap_v3_Bootstrap_StaticResources_msginit, arena, len);
@@ -610,13 +622,19 @@ UPB_INLINE envoy_config_bootstrap_v3_Bootstrap_DynamicResources *envoy_config_bo
 UPB_INLINE envoy_config_bootstrap_v3_Bootstrap_DynamicResources *envoy_config_bootstrap_v3_Bootstrap_DynamicResources_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_bootstrap_v3_Bootstrap_DynamicResources *ret = envoy_config_bootstrap_v3_Bootstrap_DynamicResources_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_Bootstrap_DynamicResources_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_Bootstrap_DynamicResources_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_bootstrap_v3_Bootstrap_DynamicResources *envoy_config_bootstrap_v3_Bootstrap_DynamicResources_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_bootstrap_v3_Bootstrap_DynamicResources *ret = envoy_config_bootstrap_v3_Bootstrap_DynamicResources_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_Bootstrap_DynamicResources_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_Bootstrap_DynamicResources_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_bootstrap_v3_Bootstrap_DynamicResources_serialize(const envoy_config_bootstrap_v3_Bootstrap_DynamicResources *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_bootstrap_v3_Bootstrap_DynamicResources_msginit, arena, len);
@@ -703,13 +721,19 @@ UPB_INLINE envoy_config_bootstrap_v3_Admin *envoy_config_bootstrap_v3_Admin_new(
 UPB_INLINE envoy_config_bootstrap_v3_Admin *envoy_config_bootstrap_v3_Admin_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_bootstrap_v3_Admin *ret = envoy_config_bootstrap_v3_Admin_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_Admin_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_Admin_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_bootstrap_v3_Admin *envoy_config_bootstrap_v3_Admin_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_bootstrap_v3_Admin *ret = envoy_config_bootstrap_v3_Admin_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_Admin_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_Admin_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_bootstrap_v3_Admin_serialize(const envoy_config_bootstrap_v3_Admin *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_bootstrap_v3_Admin_msginit, arena, len);
@@ -778,13 +802,19 @@ UPB_INLINE envoy_config_bootstrap_v3_ClusterManager *envoy_config_bootstrap_v3_C
 UPB_INLINE envoy_config_bootstrap_v3_ClusterManager *envoy_config_bootstrap_v3_ClusterManager_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_bootstrap_v3_ClusterManager *ret = envoy_config_bootstrap_v3_ClusterManager_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_ClusterManager_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_ClusterManager_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_bootstrap_v3_ClusterManager *envoy_config_bootstrap_v3_ClusterManager_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_bootstrap_v3_ClusterManager *ret = envoy_config_bootstrap_v3_ClusterManager_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_ClusterManager_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_ClusterManager_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_bootstrap_v3_ClusterManager_serialize(const envoy_config_bootstrap_v3_ClusterManager *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_bootstrap_v3_ClusterManager_msginit, arena, len);
@@ -849,13 +879,19 @@ UPB_INLINE envoy_config_bootstrap_v3_ClusterManager_OutlierDetection *envoy_conf
 UPB_INLINE envoy_config_bootstrap_v3_ClusterManager_OutlierDetection *envoy_config_bootstrap_v3_ClusterManager_OutlierDetection_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_bootstrap_v3_ClusterManager_OutlierDetection *ret = envoy_config_bootstrap_v3_ClusterManager_OutlierDetection_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_ClusterManager_OutlierDetection_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_ClusterManager_OutlierDetection_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_bootstrap_v3_ClusterManager_OutlierDetection *envoy_config_bootstrap_v3_ClusterManager_OutlierDetection_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_bootstrap_v3_ClusterManager_OutlierDetection *ret = envoy_config_bootstrap_v3_ClusterManager_OutlierDetection_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_ClusterManager_OutlierDetection_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_ClusterManager_OutlierDetection_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_bootstrap_v3_ClusterManager_OutlierDetection_serialize(const envoy_config_bootstrap_v3_ClusterManager_OutlierDetection *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_bootstrap_v3_ClusterManager_OutlierDetection_msginit, arena, len);
@@ -890,13 +926,19 @@ UPB_INLINE envoy_config_bootstrap_v3_Watchdogs *envoy_config_bootstrap_v3_Watchd
 UPB_INLINE envoy_config_bootstrap_v3_Watchdogs *envoy_config_bootstrap_v3_Watchdogs_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_bootstrap_v3_Watchdogs *ret = envoy_config_bootstrap_v3_Watchdogs_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_Watchdogs_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_Watchdogs_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_bootstrap_v3_Watchdogs *envoy_config_bootstrap_v3_Watchdogs_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_bootstrap_v3_Watchdogs *ret = envoy_config_bootstrap_v3_Watchdogs_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_Watchdogs_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_Watchdogs_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_bootstrap_v3_Watchdogs_serialize(const envoy_config_bootstrap_v3_Watchdogs *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_bootstrap_v3_Watchdogs_msginit, arena, len);
@@ -942,13 +984,19 @@ UPB_INLINE envoy_config_bootstrap_v3_Watchdog *envoy_config_bootstrap_v3_Watchdo
 UPB_INLINE envoy_config_bootstrap_v3_Watchdog *envoy_config_bootstrap_v3_Watchdog_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_bootstrap_v3_Watchdog *ret = envoy_config_bootstrap_v3_Watchdog_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_Watchdog_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_Watchdog_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_bootstrap_v3_Watchdog *envoy_config_bootstrap_v3_Watchdog_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_bootstrap_v3_Watchdog *ret = envoy_config_bootstrap_v3_Watchdog_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_Watchdog_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_Watchdog_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_bootstrap_v3_Watchdog_serialize(const envoy_config_bootstrap_v3_Watchdog *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_bootstrap_v3_Watchdog_msginit, arena, len);
@@ -1069,13 +1117,19 @@ UPB_INLINE envoy_config_bootstrap_v3_Watchdog_WatchdogAction *envoy_config_boots
 UPB_INLINE envoy_config_bootstrap_v3_Watchdog_WatchdogAction *envoy_config_bootstrap_v3_Watchdog_WatchdogAction_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_bootstrap_v3_Watchdog_WatchdogAction *ret = envoy_config_bootstrap_v3_Watchdog_WatchdogAction_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_Watchdog_WatchdogAction_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_Watchdog_WatchdogAction_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_bootstrap_v3_Watchdog_WatchdogAction *envoy_config_bootstrap_v3_Watchdog_WatchdogAction_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_bootstrap_v3_Watchdog_WatchdogAction *ret = envoy_config_bootstrap_v3_Watchdog_WatchdogAction_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_Watchdog_WatchdogAction_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_Watchdog_WatchdogAction_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_bootstrap_v3_Watchdog_WatchdogAction_serialize(const envoy_config_bootstrap_v3_Watchdog_WatchdogAction *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_bootstrap_v3_Watchdog_WatchdogAction_msginit, arena, len);
@@ -1110,13 +1164,19 @@ UPB_INLINE envoy_config_bootstrap_v3_FatalAction *envoy_config_bootstrap_v3_Fata
 UPB_INLINE envoy_config_bootstrap_v3_FatalAction *envoy_config_bootstrap_v3_FatalAction_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_bootstrap_v3_FatalAction *ret = envoy_config_bootstrap_v3_FatalAction_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_FatalAction_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_FatalAction_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_bootstrap_v3_FatalAction *envoy_config_bootstrap_v3_FatalAction_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_bootstrap_v3_FatalAction *ret = envoy_config_bootstrap_v3_FatalAction_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_FatalAction_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_FatalAction_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_bootstrap_v3_FatalAction_serialize(const envoy_config_bootstrap_v3_FatalAction *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_bootstrap_v3_FatalAction_msginit, arena, len);
@@ -1147,13 +1207,19 @@ UPB_INLINE envoy_config_bootstrap_v3_Runtime *envoy_config_bootstrap_v3_Runtime_
 UPB_INLINE envoy_config_bootstrap_v3_Runtime *envoy_config_bootstrap_v3_Runtime_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_bootstrap_v3_Runtime *ret = envoy_config_bootstrap_v3_Runtime_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_Runtime_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_Runtime_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_bootstrap_v3_Runtime *envoy_config_bootstrap_v3_Runtime_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_bootstrap_v3_Runtime *ret = envoy_config_bootstrap_v3_Runtime_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_Runtime_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_Runtime_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_bootstrap_v3_Runtime_serialize(const envoy_config_bootstrap_v3_Runtime *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_bootstrap_v3_Runtime_msginit, arena, len);
@@ -1196,13 +1262,19 @@ UPB_INLINE envoy_config_bootstrap_v3_RuntimeLayer *envoy_config_bootstrap_v3_Run
 UPB_INLINE envoy_config_bootstrap_v3_RuntimeLayer *envoy_config_bootstrap_v3_RuntimeLayer_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_bootstrap_v3_RuntimeLayer *ret = envoy_config_bootstrap_v3_RuntimeLayer_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_RuntimeLayer_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_RuntimeLayer_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_bootstrap_v3_RuntimeLayer *envoy_config_bootstrap_v3_RuntimeLayer_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_bootstrap_v3_RuntimeLayer *ret = envoy_config_bootstrap_v3_RuntimeLayer_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_RuntimeLayer_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_RuntimeLayer_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_bootstrap_v3_RuntimeLayer_serialize(const envoy_config_bootstrap_v3_RuntimeLayer *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_bootstrap_v3_RuntimeLayer_msginit, arena, len);
@@ -1287,13 +1359,19 @@ UPB_INLINE envoy_config_bootstrap_v3_RuntimeLayer_DiskLayer *envoy_config_bootst
 UPB_INLINE envoy_config_bootstrap_v3_RuntimeLayer_DiskLayer *envoy_config_bootstrap_v3_RuntimeLayer_DiskLayer_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_bootstrap_v3_RuntimeLayer_DiskLayer *ret = envoy_config_bootstrap_v3_RuntimeLayer_DiskLayer_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_RuntimeLayer_DiskLayer_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_RuntimeLayer_DiskLayer_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_bootstrap_v3_RuntimeLayer_DiskLayer *envoy_config_bootstrap_v3_RuntimeLayer_DiskLayer_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_bootstrap_v3_RuntimeLayer_DiskLayer *ret = envoy_config_bootstrap_v3_RuntimeLayer_DiskLayer_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_RuntimeLayer_DiskLayer_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_RuntimeLayer_DiskLayer_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_bootstrap_v3_RuntimeLayer_DiskLayer_serialize(const envoy_config_bootstrap_v3_RuntimeLayer_DiskLayer *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_bootstrap_v3_RuntimeLayer_DiskLayer_msginit, arena, len);
@@ -1321,13 +1399,19 @@ UPB_INLINE envoy_config_bootstrap_v3_RuntimeLayer_AdminLayer *envoy_config_boots
 UPB_INLINE envoy_config_bootstrap_v3_RuntimeLayer_AdminLayer *envoy_config_bootstrap_v3_RuntimeLayer_AdminLayer_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_bootstrap_v3_RuntimeLayer_AdminLayer *ret = envoy_config_bootstrap_v3_RuntimeLayer_AdminLayer_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_RuntimeLayer_AdminLayer_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_RuntimeLayer_AdminLayer_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_bootstrap_v3_RuntimeLayer_AdminLayer *envoy_config_bootstrap_v3_RuntimeLayer_AdminLayer_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_bootstrap_v3_RuntimeLayer_AdminLayer *ret = envoy_config_bootstrap_v3_RuntimeLayer_AdminLayer_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_RuntimeLayer_AdminLayer_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_RuntimeLayer_AdminLayer_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_bootstrap_v3_RuntimeLayer_AdminLayer_serialize(const envoy_config_bootstrap_v3_RuntimeLayer_AdminLayer *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_bootstrap_v3_RuntimeLayer_AdminLayer_msginit, arena, len);
@@ -1343,13 +1427,19 @@ UPB_INLINE envoy_config_bootstrap_v3_RuntimeLayer_RtdsLayer *envoy_config_bootst
 UPB_INLINE envoy_config_bootstrap_v3_RuntimeLayer_RtdsLayer *envoy_config_bootstrap_v3_RuntimeLayer_RtdsLayer_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_bootstrap_v3_RuntimeLayer_RtdsLayer *ret = envoy_config_bootstrap_v3_RuntimeLayer_RtdsLayer_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_RuntimeLayer_RtdsLayer_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_RuntimeLayer_RtdsLayer_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_bootstrap_v3_RuntimeLayer_RtdsLayer *envoy_config_bootstrap_v3_RuntimeLayer_RtdsLayer_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_bootstrap_v3_RuntimeLayer_RtdsLayer *ret = envoy_config_bootstrap_v3_RuntimeLayer_RtdsLayer_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_RuntimeLayer_RtdsLayer_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_RuntimeLayer_RtdsLayer_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_bootstrap_v3_RuntimeLayer_RtdsLayer_serialize(const envoy_config_bootstrap_v3_RuntimeLayer_RtdsLayer *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_bootstrap_v3_RuntimeLayer_RtdsLayer_msginit, arena, len);
@@ -1384,13 +1474,19 @@ UPB_INLINE envoy_config_bootstrap_v3_LayeredRuntime *envoy_config_bootstrap_v3_L
 UPB_INLINE envoy_config_bootstrap_v3_LayeredRuntime *envoy_config_bootstrap_v3_LayeredRuntime_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_bootstrap_v3_LayeredRuntime *ret = envoy_config_bootstrap_v3_LayeredRuntime_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_LayeredRuntime_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_LayeredRuntime_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_bootstrap_v3_LayeredRuntime *envoy_config_bootstrap_v3_LayeredRuntime_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_bootstrap_v3_LayeredRuntime *ret = envoy_config_bootstrap_v3_LayeredRuntime_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_LayeredRuntime_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_LayeredRuntime_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_bootstrap_v3_LayeredRuntime_serialize(const envoy_config_bootstrap_v3_LayeredRuntime *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_bootstrap_v3_LayeredRuntime_msginit, arena, len);
@@ -1421,13 +1517,19 @@ UPB_INLINE envoy_config_bootstrap_v3_CustomInlineHeader *envoy_config_bootstrap_
 UPB_INLINE envoy_config_bootstrap_v3_CustomInlineHeader *envoy_config_bootstrap_v3_CustomInlineHeader_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_bootstrap_v3_CustomInlineHeader *ret = envoy_config_bootstrap_v3_CustomInlineHeader_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_CustomInlineHeader_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_CustomInlineHeader_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_bootstrap_v3_CustomInlineHeader *envoy_config_bootstrap_v3_CustomInlineHeader_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_bootstrap_v3_CustomInlineHeader *ret = envoy_config_bootstrap_v3_CustomInlineHeader_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_CustomInlineHeader_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_bootstrap_v3_CustomInlineHeader_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_bootstrap_v3_CustomInlineHeader_serialize(const envoy_config_bootstrap_v3_CustomInlineHeader *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_bootstrap_v3_CustomInlineHeader_msginit, arena, len);
index b3f086d..8d85e0d 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/config/cluster/v3/circuit_breaker.upb.h"
 #include "envoy/config/core/v3/base.upb.h"
 #include "envoy/type/v3/percent.upb.h"
@@ -23,13 +23,13 @@ static const upb_msglayout *const envoy_config_cluster_v3_CircuitBreakers_submsg
 };
 
 static const upb_msglayout_field envoy_config_cluster_v3_CircuitBreakers__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 11, 3},
+  {1, UPB_SIZE(0, 0), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout envoy_config_cluster_v3_CircuitBreakers_msginit = {
   &envoy_config_cluster_v3_CircuitBreakers_submsgs[0],
   &envoy_config_cluster_v3_CircuitBreakers__fields[0],
-  UPB_SIZE(8, 8), 1, false, 255,
+  UPB_SIZE(8, 8), 1, false, 1, 255,
 };
 
 static const upb_msglayout *const envoy_config_cluster_v3_CircuitBreakers_Thresholds_submsgs[2] = {
@@ -38,20 +38,20 @@ static const upb_msglayout *const envoy_config_cluster_v3_CircuitBreakers_Thresh
 };
 
 static const upb_msglayout_field envoy_config_cluster_v3_CircuitBreakers_Thresholds__fields[8] = {
-  {1, UPB_SIZE(4, 4), 0, 0, 14, 1},
-  {2, UPB_SIZE(12, 16), 1, 1, 11, 1},
-  {3, UPB_SIZE(16, 24), 2, 1, 11, 1},
-  {4, UPB_SIZE(20, 32), 3, 1, 11, 1},
-  {5, UPB_SIZE(24, 40), 4, 1, 11, 1},
-  {6, UPB_SIZE(8, 8), 0, 0, 8, 1},
-  {7, UPB_SIZE(28, 48), 5, 1, 11, 1},
-  {8, UPB_SIZE(32, 56), 6, 0, 11, 1},
+  {1, UPB_SIZE(4, 4), 0, 0, 14, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(12, 16), 1, 1, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(16, 24), 2, 1, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(20, 32), 3, 1, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(24, 40), 4, 1, 11, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(8, 8), 0, 0, 8, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(28, 48), 5, 1, 11, _UPB_MODE_SCALAR},
+  {8, UPB_SIZE(32, 56), 6, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_cluster_v3_CircuitBreakers_Thresholds_msginit = {
   &envoy_config_cluster_v3_CircuitBreakers_Thresholds_submsgs[0],
   &envoy_config_cluster_v3_CircuitBreakers_Thresholds__fields[0],
-  UPB_SIZE(40, 64), 8, false, 255,
+  UPB_SIZE(40, 64), 8, false, 8, 255,
 };
 
 static const upb_msglayout *const envoy_config_cluster_v3_CircuitBreakers_Thresholds_RetryBudget_submsgs[2] = {
@@ -60,14 +60,14 @@ static const upb_msglayout *const envoy_config_cluster_v3_CircuitBreakers_Thresh
 };
 
 static const upb_msglayout_field envoy_config_cluster_v3_CircuitBreakers_Thresholds_RetryBudget__fields[2] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
-  {2, UPB_SIZE(8, 16), 2, 1, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 2, 1, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_cluster_v3_CircuitBreakers_Thresholds_RetryBudget_msginit = {
   &envoy_config_cluster_v3_CircuitBreakers_Thresholds_RetryBudget_submsgs[0],
   &envoy_config_cluster_v3_CircuitBreakers_Thresholds_RetryBudget__fields[0],
-  UPB_SIZE(16, 24), 2, false, 255,
+  UPB_SIZE(16, 24), 2, false, 2, 255,
 };
 
 #include "upb/port_undef.inc"
index 8d60996..4d89a70 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_CONFIG_CLUSTER_V3_CIRCUIT_BREAKER_PROTO_UPB_H_
 #define ENVOY_CONFIG_CLUSTER_V3_CIRCUIT_BREAKER_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -43,13 +43,19 @@ UPB_INLINE envoy_config_cluster_v3_CircuitBreakers *envoy_config_cluster_v3_Circ
 UPB_INLINE envoy_config_cluster_v3_CircuitBreakers *envoy_config_cluster_v3_CircuitBreakers_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_cluster_v3_CircuitBreakers *ret = envoy_config_cluster_v3_CircuitBreakers_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_cluster_v3_CircuitBreakers_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_cluster_v3_CircuitBreakers_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_cluster_v3_CircuitBreakers *envoy_config_cluster_v3_CircuitBreakers_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_cluster_v3_CircuitBreakers *ret = envoy_config_cluster_v3_CircuitBreakers_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_cluster_v3_CircuitBreakers_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_cluster_v3_CircuitBreakers_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_cluster_v3_CircuitBreakers_serialize(const envoy_config_cluster_v3_CircuitBreakers *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_cluster_v3_CircuitBreakers_msginit, arena, len);
@@ -80,13 +86,19 @@ UPB_INLINE envoy_config_cluster_v3_CircuitBreakers_Thresholds *envoy_config_clus
 UPB_INLINE envoy_config_cluster_v3_CircuitBreakers_Thresholds *envoy_config_cluster_v3_CircuitBreakers_Thresholds_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_cluster_v3_CircuitBreakers_Thresholds *ret = envoy_config_cluster_v3_CircuitBreakers_Thresholds_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_cluster_v3_CircuitBreakers_Thresholds_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_cluster_v3_CircuitBreakers_Thresholds_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_cluster_v3_CircuitBreakers_Thresholds *envoy_config_cluster_v3_CircuitBreakers_Thresholds_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_cluster_v3_CircuitBreakers_Thresholds *ret = envoy_config_cluster_v3_CircuitBreakers_Thresholds_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_cluster_v3_CircuitBreakers_Thresholds_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_cluster_v3_CircuitBreakers_Thresholds_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_cluster_v3_CircuitBreakers_Thresholds_serialize(const envoy_config_cluster_v3_CircuitBreakers_Thresholds *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_cluster_v3_CircuitBreakers_Thresholds_msginit, arena, len);
@@ -200,13 +212,19 @@ UPB_INLINE envoy_config_cluster_v3_CircuitBreakers_Thresholds_RetryBudget *envoy
 UPB_INLINE envoy_config_cluster_v3_CircuitBreakers_Thresholds_RetryBudget *envoy_config_cluster_v3_CircuitBreakers_Thresholds_RetryBudget_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_cluster_v3_CircuitBreakers_Thresholds_RetryBudget *ret = envoy_config_cluster_v3_CircuitBreakers_Thresholds_RetryBudget_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_cluster_v3_CircuitBreakers_Thresholds_RetryBudget_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_cluster_v3_CircuitBreakers_Thresholds_RetryBudget_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_cluster_v3_CircuitBreakers_Thresholds_RetryBudget *envoy_config_cluster_v3_CircuitBreakers_Thresholds_RetryBudget_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_cluster_v3_CircuitBreakers_Thresholds_RetryBudget *ret = envoy_config_cluster_v3_CircuitBreakers_Thresholds_RetryBudget_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_cluster_v3_CircuitBreakers_Thresholds_RetryBudget_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_cluster_v3_CircuitBreakers_Thresholds_RetryBudget_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_cluster_v3_CircuitBreakers_Thresholds_RetryBudget_serialize(const envoy_config_cluster_v3_CircuitBreakers_Thresholds_RetryBudget *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_cluster_v3_CircuitBreakers_Thresholds_RetryBudget_msginit, arena, len);
index 1d7e992..003330c 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/config/cluster/v3/cluster.upb.h"
 #include "envoy/config/cluster/v3/circuit_breaker.upb.h"
 #include "envoy/config/cluster/v3/filter.upb.h"
@@ -40,13 +40,13 @@ static const upb_msglayout *const envoy_config_cluster_v3_ClusterCollection_subm
 };
 
 static const upb_msglayout_field envoy_config_cluster_v3_ClusterCollection__fields[1] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_cluster_v3_ClusterCollection_msginit = {
   &envoy_config_cluster_v3_ClusterCollection_submsgs[0],
   &envoy_config_cluster_v3_ClusterCollection__fields[0],
-  UPB_SIZE(8, 16), 1, false, 255,
+  UPB_SIZE(8, 16), 1, false, 1, 255,
 };
 
 static const upb_msglayout *const envoy_config_cluster_v3_Cluster_submsgs[34] = {
@@ -87,62 +87,62 @@ static const upb_msglayout *const envoy_config_cluster_v3_Cluster_submsgs[34] =
 };
 
 static const upb_msglayout_field envoy_config_cluster_v3_Cluster__fields[50] = {
-  {1, UPB_SIZE(24, 24), 0, 0, 9, 1},
-  {2, UPB_SIZE(172, 320), UPB_SIZE(-177, -329), 0, 14, 1},
-  {3, UPB_SIZE(40, 56), 1, 3, 11, 1},
-  {4, UPB_SIZE(44, 64), 2, 32, 11, 1},
-  {5, UPB_SIZE(48, 72), 3, 33, 11, 1},
-  {6, UPB_SIZE(4, 4), 0, 0, 14, 1},
-  {8, UPB_SIZE(152, 280), 0, 22, 11, 3},
-  {9, UPB_SIZE(52, 80), 4, 33, 11, 1},
-  {10, UPB_SIZE(56, 88), 5, 0, 11, 1},
-  {13, UPB_SIZE(60, 96), 6, 23, 11, 1},
-  {14, UPB_SIZE(64, 104), 7, 24, 11, 1},
-  {16, UPB_SIZE(68, 112), 8, 32, 11, 1},
-  {17, UPB_SIZE(8, 8), 0, 0, 14, 1},
-  {18, UPB_SIZE(156, 288), 0, 18, 11, 3},
-  {19, UPB_SIZE(72, 120), 9, 15, 11, 1},
-  {20, UPB_SIZE(76, 128), 10, 32, 11, 1},
-  {21, UPB_SIZE(80, 136), 11, 19, 11, 1},
-  {22, UPB_SIZE(84, 144), 12, 4, 11, 1},
-  {23, UPB_SIZE(180, 336), UPB_SIZE(-185, -345), 10, 11, 1},
-  {24, UPB_SIZE(88, 152), 13, 27, 11, 1},
-  {25, UPB_SIZE(92, 160), 14, 26, 11, 1},
-  {26, UPB_SIZE(12, 12), 0, 0, 14, 1},
-  {27, UPB_SIZE(96, 168), 15, 1, 11, 1},
-  {28, UPB_SIZE(32, 40), 0, 0, 9, 1},
-  {29, UPB_SIZE(100, 176), 16, 25, 11, 1},
-  {30, UPB_SIZE(104, 184), 17, 17, 11, 1},
-  {31, UPB_SIZE(16, 16), 0, 0, 8, 1},
-  {32, UPB_SIZE(17, 17), 0, 0, 8, 1},
-  {33, UPB_SIZE(108, 192), 18, 30, 11, 1},
-  {34, UPB_SIZE(180, 336), UPB_SIZE(-185, -345), 7, 11, 1},
-  {36, UPB_SIZE(160, 296), 0, 12, 11, _UPB_LABEL_MAP},
-  {37, UPB_SIZE(180, 336), UPB_SIZE(-185, -345), 5, 11, 1},
-  {38, UPB_SIZE(172, 320), UPB_SIZE(-177, -329), 2, 11, 1},
-  {39, UPB_SIZE(18, 18), 0, 0, 8, 1},
-  {40, UPB_SIZE(164, 304), 0, 13, 11, 3},
-  {41, UPB_SIZE(112, 200), 19, 14, 11, 1},
-  {42, UPB_SIZE(116, 208), 20, 20, 11, 1},
-  {43, UPB_SIZE(168, 312), 0, 11, 11, 3},
-  {44, UPB_SIZE(120, 216), 21, 9, 11, 1},
-  {45, UPB_SIZE(19, 19), 0, 0, 8, 1},
-  {46, UPB_SIZE(124, 224), 22, 29, 11, 1},
-  {47, UPB_SIZE(20, 20), 0, 0, 8, 1},
-  {48, UPB_SIZE(128, 232), 23, 28, 11, 1},
-  {49, UPB_SIZE(132, 240), 24, 16, 11, 1},
-  {50, UPB_SIZE(136, 248), 25, 8, 11, 1},
-  {51, UPB_SIZE(21, 21), 0, 0, 8, 1},
-  {52, UPB_SIZE(180, 336), UPB_SIZE(-185, -345), 6, 11, 1},
-  {53, UPB_SIZE(140, 256), 26, 21, 11, 1},
-  {54, UPB_SIZE(144, 264), 27, 31, 11, 1},
-  {55, UPB_SIZE(148, 272), 28, 28, 11, 1},
+  {1, UPB_SIZE(24, 24), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(172, 320), UPB_SIZE(-177, -329), 0, 14, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(40, 56), 1, 3, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(44, 64), 2, 32, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(48, 72), 3, 33, 11, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(4, 4), 0, 0, 14, _UPB_MODE_SCALAR},
+  {8, UPB_SIZE(152, 280), 0, 22, 11, _UPB_MODE_ARRAY},
+  {9, UPB_SIZE(52, 80), 4, 33, 11, _UPB_MODE_SCALAR},
+  {10, UPB_SIZE(56, 88), 5, 0, 11, _UPB_MODE_SCALAR},
+  {13, UPB_SIZE(60, 96), 6, 23, 11, _UPB_MODE_SCALAR},
+  {14, UPB_SIZE(64, 104), 7, 24, 11, _UPB_MODE_SCALAR},
+  {16, UPB_SIZE(68, 112), 8, 32, 11, _UPB_MODE_SCALAR},
+  {17, UPB_SIZE(8, 8), 0, 0, 14, _UPB_MODE_SCALAR},
+  {18, UPB_SIZE(156, 288), 0, 18, 11, _UPB_MODE_ARRAY},
+  {19, UPB_SIZE(72, 120), 9, 15, 11, _UPB_MODE_SCALAR},
+  {20, UPB_SIZE(76, 128), 10, 32, 11, _UPB_MODE_SCALAR},
+  {21, UPB_SIZE(80, 136), 11, 19, 11, _UPB_MODE_SCALAR},
+  {22, UPB_SIZE(84, 144), 12, 4, 11, _UPB_MODE_SCALAR},
+  {23, UPB_SIZE(180, 336), UPB_SIZE(-185, -345), 10, 11, _UPB_MODE_SCALAR},
+  {24, UPB_SIZE(88, 152), 13, 27, 11, _UPB_MODE_SCALAR},
+  {25, UPB_SIZE(92, 160), 14, 26, 11, _UPB_MODE_SCALAR},
+  {26, UPB_SIZE(12, 12), 0, 0, 14, _UPB_MODE_SCALAR},
+  {27, UPB_SIZE(96, 168), 15, 1, 11, _UPB_MODE_SCALAR},
+  {28, UPB_SIZE(32, 40), 0, 0, 9, _UPB_MODE_SCALAR},
+  {29, UPB_SIZE(100, 176), 16, 25, 11, _UPB_MODE_SCALAR},
+  {30, UPB_SIZE(104, 184), 17, 17, 11, _UPB_MODE_SCALAR},
+  {31, UPB_SIZE(16, 16), 0, 0, 8, _UPB_MODE_SCALAR},
+  {32, UPB_SIZE(17, 17), 0, 0, 8, _UPB_MODE_SCALAR},
+  {33, UPB_SIZE(108, 192), 18, 30, 11, _UPB_MODE_SCALAR},
+  {34, UPB_SIZE(180, 336), UPB_SIZE(-185, -345), 7, 11, _UPB_MODE_SCALAR},
+  {36, UPB_SIZE(160, 296), 0, 12, 11, _UPB_MODE_MAP},
+  {37, UPB_SIZE(180, 336), UPB_SIZE(-185, -345), 5, 11, _UPB_MODE_SCALAR},
+  {38, UPB_SIZE(172, 320), UPB_SIZE(-177, -329), 2, 11, _UPB_MODE_SCALAR},
+  {39, UPB_SIZE(18, 18), 0, 0, 8, _UPB_MODE_SCALAR},
+  {40, UPB_SIZE(164, 304), 0, 13, 11, _UPB_MODE_ARRAY},
+  {41, UPB_SIZE(112, 200), 19, 14, 11, _UPB_MODE_SCALAR},
+  {42, UPB_SIZE(116, 208), 20, 20, 11, _UPB_MODE_SCALAR},
+  {43, UPB_SIZE(168, 312), 0, 11, 11, _UPB_MODE_ARRAY},
+  {44, UPB_SIZE(120, 216), 21, 9, 11, _UPB_MODE_SCALAR},
+  {45, UPB_SIZE(19, 19), 0, 0, 8, _UPB_MODE_SCALAR},
+  {46, UPB_SIZE(124, 224), 22, 29, 11, _UPB_MODE_SCALAR},
+  {47, UPB_SIZE(20, 20), 0, 0, 8, _UPB_MODE_SCALAR},
+  {48, UPB_SIZE(128, 232), 23, 28, 11, _UPB_MODE_SCALAR},
+  {49, UPB_SIZE(132, 240), 24, 16, 11, _UPB_MODE_SCALAR},
+  {50, UPB_SIZE(136, 248), 25, 8, 11, _UPB_MODE_SCALAR},
+  {51, UPB_SIZE(21, 21), 0, 0, 8, _UPB_MODE_SCALAR},
+  {52, UPB_SIZE(180, 336), UPB_SIZE(-185, -345), 6, 11, _UPB_MODE_SCALAR},
+  {53, UPB_SIZE(140, 256), 26, 21, 11, _UPB_MODE_SCALAR},
+  {54, UPB_SIZE(144, 264), 27, 31, 11, _UPB_MODE_SCALAR},
+  {55, UPB_SIZE(148, 272), 28, 28, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_cluster_v3_Cluster_msginit = {
   &envoy_config_cluster_v3_Cluster_submsgs[0],
   &envoy_config_cluster_v3_Cluster__fields[0],
-  UPB_SIZE(192, 352), 50, false, 255,
+  UPB_SIZE(192, 352), 50, false, 6, 255,
 };
 
 static const upb_msglayout *const envoy_config_cluster_v3_Cluster_TransportSocketMatch_submsgs[2] = {
@@ -151,15 +151,15 @@ static const upb_msglayout *const envoy_config_cluster_v3_Cluster_TransportSocke
 };
 
 static const upb_msglayout_field envoy_config_cluster_v3_Cluster_TransportSocketMatch__fields[3] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(12, 24), 1, 1, 11, 1},
-  {3, UPB_SIZE(16, 32), 2, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(12, 24), 1, 1, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(16, 32), 2, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_cluster_v3_Cluster_TransportSocketMatch_msginit = {
   &envoy_config_cluster_v3_Cluster_TransportSocketMatch_submsgs[0],
   &envoy_config_cluster_v3_Cluster_TransportSocketMatch__fields[0],
-  UPB_SIZE(24, 48), 3, false, 255,
+  UPB_SIZE(24, 48), 3, false, 3, 255,
 };
 
 static const upb_msglayout *const envoy_config_cluster_v3_Cluster_CustomClusterType_submsgs[1] = {
@@ -167,14 +167,14 @@ static const upb_msglayout *const envoy_config_cluster_v3_Cluster_CustomClusterT
 };
 
 static const upb_msglayout_field envoy_config_cluster_v3_Cluster_CustomClusterType__fields[2] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(12, 24), 1, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(12, 24), 1, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_cluster_v3_Cluster_CustomClusterType_msginit = {
   &envoy_config_cluster_v3_Cluster_CustomClusterType_submsgs[0],
   &envoy_config_cluster_v3_Cluster_CustomClusterType__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_config_cluster_v3_Cluster_EdsClusterConfig_submsgs[1] = {
@@ -182,14 +182,14 @@ static const upb_msglayout *const envoy_config_cluster_v3_Cluster_EdsClusterConf
 };
 
 static const upb_msglayout_field envoy_config_cluster_v3_Cluster_EdsClusterConfig__fields[2] = {
-  {1, UPB_SIZE(12, 24), 1, 0, 11, 1},
-  {2, UPB_SIZE(4, 8), 0, 0, 9, 1},
+  {1, UPB_SIZE(12, 24), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_cluster_v3_Cluster_EdsClusterConfig_msginit = {
   &envoy_config_cluster_v3_Cluster_EdsClusterConfig_submsgs[0],
   &envoy_config_cluster_v3_Cluster_EdsClusterConfig__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_config_cluster_v3_Cluster_LbSubsetConfig_submsgs[2] = {
@@ -198,32 +198,32 @@ static const upb_msglayout *const envoy_config_cluster_v3_Cluster_LbSubsetConfig
 };
 
 static const upb_msglayout_field envoy_config_cluster_v3_Cluster_LbSubsetConfig__fields[7] = {
-  {1, UPB_SIZE(4, 4), 0, 0, 14, 1},
-  {2, UPB_SIZE(12, 16), 1, 1, 11, 1},
-  {3, UPB_SIZE(16, 24), 0, 0, 11, 3},
-  {4, UPB_SIZE(8, 8), 0, 0, 8, 1},
-  {5, UPB_SIZE(9, 9), 0, 0, 8, 1},
-  {6, UPB_SIZE(10, 10), 0, 0, 8, 1},
-  {7, UPB_SIZE(11, 11), 0, 0, 8, 1},
+  {1, UPB_SIZE(4, 4), 0, 0, 14, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(12, 16), 1, 1, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(16, 24), 0, 0, 11, _UPB_MODE_ARRAY},
+  {4, UPB_SIZE(8, 8), 0, 0, 8, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(9, 9), 0, 0, 8, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(10, 10), 0, 0, 8, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(11, 11), 0, 0, 8, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_cluster_v3_Cluster_LbSubsetConfig_msginit = {
   &envoy_config_cluster_v3_Cluster_LbSubsetConfig_submsgs[0],
   &envoy_config_cluster_v3_Cluster_LbSubsetConfig__fields[0],
-  UPB_SIZE(24, 32), 7, false, 255,
+  UPB_SIZE(24, 32), 7, false, 7, 255,
 };
 
 static const upb_msglayout_field envoy_config_cluster_v3_Cluster_LbSubsetConfig_LbSubsetSelector__fields[4] = {
-  {1, UPB_SIZE(8, 8), 0, 0, 9, 3},
-  {2, UPB_SIZE(0, 0), 0, 0, 14, 1},
-  {3, UPB_SIZE(12, 16), 0, 0, 9, 3},
-  {4, UPB_SIZE(4, 4), 0, 0, 8, 1},
+  {1, UPB_SIZE(8, 8), 0, 0, 9, _UPB_MODE_ARRAY},
+  {2, UPB_SIZE(0, 0), 0, 0, 14, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(12, 16), 0, 0, 9, _UPB_MODE_ARRAY},
+  {4, UPB_SIZE(4, 4), 0, 0, 8, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_cluster_v3_Cluster_LbSubsetConfig_LbSubsetSelector_msginit = {
   NULL,
   &envoy_config_cluster_v3_Cluster_LbSubsetConfig_LbSubsetSelector__fields[0],
-  UPB_SIZE(16, 24), 4, false, 255,
+  UPB_SIZE(16, 24), 4, false, 4, 255,
 };
 
 static const upb_msglayout *const envoy_config_cluster_v3_Cluster_LeastRequestLbConfig_submsgs[2] = {
@@ -232,14 +232,14 @@ static const upb_msglayout *const envoy_config_cluster_v3_Cluster_LeastRequestLb
 };
 
 static const upb_msglayout_field envoy_config_cluster_v3_Cluster_LeastRequestLbConfig__fields[2] = {
-  {1, UPB_SIZE(4, 8), 1, 1, 11, 1},
-  {2, UPB_SIZE(8, 16), 2, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 1, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 2, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_cluster_v3_Cluster_LeastRequestLbConfig_msginit = {
   &envoy_config_cluster_v3_Cluster_LeastRequestLbConfig_submsgs[0],
   &envoy_config_cluster_v3_Cluster_LeastRequestLbConfig__fields[0],
-  UPB_SIZE(16, 24), 2, false, 255,
+  UPB_SIZE(16, 24), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_config_cluster_v3_Cluster_RingHashLbConfig_submsgs[1] = {
@@ -247,15 +247,15 @@ static const upb_msglayout *const envoy_config_cluster_v3_Cluster_RingHashLbConf
 };
 
 static const upb_msglayout_field envoy_config_cluster_v3_Cluster_RingHashLbConfig__fields[3] = {
-  {1, UPB_SIZE(8, 8), 1, 0, 11, 1},
-  {3, UPB_SIZE(4, 4), 0, 0, 14, 1},
-  {4, UPB_SIZE(12, 16), 2, 0, 11, 1},
+  {1, UPB_SIZE(8, 8), 1, 0, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(4, 4), 0, 0, 14, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(12, 16), 2, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_cluster_v3_Cluster_RingHashLbConfig_msginit = {
   &envoy_config_cluster_v3_Cluster_RingHashLbConfig_submsgs[0],
   &envoy_config_cluster_v3_Cluster_RingHashLbConfig__fields[0],
-  UPB_SIZE(16, 24), 3, false, 255,
+  UPB_SIZE(16, 24), 3, false, 1, 255,
 };
 
 static const upb_msglayout *const envoy_config_cluster_v3_Cluster_MaglevLbConfig_submsgs[1] = {
@@ -263,23 +263,23 @@ static const upb_msglayout *const envoy_config_cluster_v3_Cluster_MaglevLbConfig
 };
 
 static const upb_msglayout_field envoy_config_cluster_v3_Cluster_MaglevLbConfig__fields[1] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_cluster_v3_Cluster_MaglevLbConfig_msginit = {
   &envoy_config_cluster_v3_Cluster_MaglevLbConfig_submsgs[0],
   &envoy_config_cluster_v3_Cluster_MaglevLbConfig__fields[0],
-  UPB_SIZE(8, 16), 1, false, 255,
+  UPB_SIZE(8, 16), 1, false, 1, 255,
 };
 
 static const upb_msglayout_field envoy_config_cluster_v3_Cluster_OriginalDstLbConfig__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 8, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 8, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_cluster_v3_Cluster_OriginalDstLbConfig_msginit = {
   NULL,
   &envoy_config_cluster_v3_Cluster_OriginalDstLbConfig__fields[0],
-  UPB_SIZE(8, 8), 1, false, 255,
+  UPB_SIZE(8, 8), 1, false, 1, 255,
 };
 
 static const upb_msglayout *const envoy_config_cluster_v3_Cluster_CommonLbConfig_submsgs[5] = {
@@ -291,19 +291,19 @@ static const upb_msglayout *const envoy_config_cluster_v3_Cluster_CommonLbConfig
 };
 
 static const upb_msglayout_field envoy_config_cluster_v3_Cluster_CommonLbConfig__fields[7] = {
-  {1, UPB_SIZE(4, 8), 1, 3, 11, 1},
-  {2, UPB_SIZE(16, 32), UPB_SIZE(-21, -41), 2, 11, 1},
-  {3, UPB_SIZE(16, 32), UPB_SIZE(-21, -41), 1, 11, 1},
-  {4, UPB_SIZE(8, 16), 2, 4, 11, 1},
-  {5, UPB_SIZE(1, 1), 0, 0, 8, 1},
-  {6, UPB_SIZE(2, 2), 0, 0, 8, 1},
-  {7, UPB_SIZE(12, 24), 3, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 3, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(16, 32), UPB_SIZE(-21, -41), 2, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(16, 32), UPB_SIZE(-21, -41), 1, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(8, 16), 2, 4, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(1, 1), 0, 0, 8, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(2, 2), 0, 0, 8, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(12, 24), 3, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_cluster_v3_Cluster_CommonLbConfig_msginit = {
   &envoy_config_cluster_v3_Cluster_CommonLbConfig_submsgs[0],
   &envoy_config_cluster_v3_Cluster_CommonLbConfig__fields[0],
-  UPB_SIZE(24, 48), 7, false, 255,
+  UPB_SIZE(24, 48), 7, false, 7, 255,
 };
 
 static const upb_msglayout *const envoy_config_cluster_v3_Cluster_CommonLbConfig_ZoneAwareLbConfig_submsgs[2] = {
@@ -312,21 +312,21 @@ static const upb_msglayout *const envoy_config_cluster_v3_Cluster_CommonLbConfig
 };
 
 static const upb_msglayout_field envoy_config_cluster_v3_Cluster_CommonLbConfig_ZoneAwareLbConfig__fields[3] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
-  {2, UPB_SIZE(8, 16), 2, 1, 11, 1},
-  {3, UPB_SIZE(1, 1), 0, 0, 8, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 2, 1, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(1, 1), 0, 0, 8, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_cluster_v3_Cluster_CommonLbConfig_ZoneAwareLbConfig_msginit = {
   &envoy_config_cluster_v3_Cluster_CommonLbConfig_ZoneAwareLbConfig_submsgs[0],
   &envoy_config_cluster_v3_Cluster_CommonLbConfig_ZoneAwareLbConfig__fields[0],
-  UPB_SIZE(16, 24), 3, false, 255,
+  UPB_SIZE(16, 24), 3, false, 3, 255,
 };
 
 const upb_msglayout envoy_config_cluster_v3_Cluster_CommonLbConfig_LocalityWeightedLbConfig_msginit = {
   NULL,
   NULL,
-  UPB_SIZE(0, 0), 0, false, 255,
+  UPB_SIZE(0, 0), 0, false, 0, 255,
 };
 
 static const upb_msglayout *const envoy_config_cluster_v3_Cluster_CommonLbConfig_ConsistentHashingLbConfig_submsgs[1] = {
@@ -334,14 +334,14 @@ static const upb_msglayout *const envoy_config_cluster_v3_Cluster_CommonLbConfig
 };
 
 static const upb_msglayout_field envoy_config_cluster_v3_Cluster_CommonLbConfig_ConsistentHashingLbConfig__fields[2] = {
-  {1, UPB_SIZE(1, 1), 0, 0, 8, 1},
-  {2, UPB_SIZE(4, 8), 1, 0, 11, 1},
+  {1, UPB_SIZE(1, 1), 0, 0, 8, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_cluster_v3_Cluster_CommonLbConfig_ConsistentHashingLbConfig_msginit = {
   &envoy_config_cluster_v3_Cluster_CommonLbConfig_ConsistentHashingLbConfig_submsgs[0],
   &envoy_config_cluster_v3_Cluster_CommonLbConfig_ConsistentHashingLbConfig__fields[0],
-  UPB_SIZE(8, 16), 2, false, 255,
+  UPB_SIZE(8, 16), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_config_cluster_v3_Cluster_RefreshRate_submsgs[1] = {
@@ -349,14 +349,14 @@ static const upb_msglayout *const envoy_config_cluster_v3_Cluster_RefreshRate_su
 };
 
 static const upb_msglayout_field envoy_config_cluster_v3_Cluster_RefreshRate__fields[2] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
-  {2, UPB_SIZE(8, 16), 2, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 2, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_cluster_v3_Cluster_RefreshRate_msginit = {
   &envoy_config_cluster_v3_Cluster_RefreshRate_submsgs[0],
   &envoy_config_cluster_v3_Cluster_RefreshRate__fields[0],
-  UPB_SIZE(16, 24), 2, false, 255,
+  UPB_SIZE(16, 24), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_config_cluster_v3_Cluster_PreconnectPolicy_submsgs[1] = {
@@ -364,14 +364,14 @@ static const upb_msglayout *const envoy_config_cluster_v3_Cluster_PreconnectPoli
 };
 
 static const upb_msglayout_field envoy_config_cluster_v3_Cluster_PreconnectPolicy__fields[2] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
-  {2, UPB_SIZE(8, 16), 2, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 2, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_cluster_v3_Cluster_PreconnectPolicy_msginit = {
   &envoy_config_cluster_v3_Cluster_PreconnectPolicy_submsgs[0],
   &envoy_config_cluster_v3_Cluster_PreconnectPolicy__fields[0],
-  UPB_SIZE(16, 24), 2, false, 255,
+  UPB_SIZE(16, 24), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_config_cluster_v3_Cluster_TypedExtensionProtocolOptionsEntry_submsgs[1] = {
@@ -379,14 +379,14 @@ static const upb_msglayout *const envoy_config_cluster_v3_Cluster_TypedExtension
 };
 
 static const upb_msglayout_field envoy_config_cluster_v3_Cluster_TypedExtensionProtocolOptionsEntry__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {2, UPB_SIZE(8, 16), 0, 0, 11, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 0, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_cluster_v3_Cluster_TypedExtensionProtocolOptionsEntry_msginit = {
   &envoy_config_cluster_v3_Cluster_TypedExtensionProtocolOptionsEntry_submsgs[0],
   &envoy_config_cluster_v3_Cluster_TypedExtensionProtocolOptionsEntry__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_config_cluster_v3_LoadBalancingPolicy_submsgs[1] = {
@@ -394,28 +394,27 @@ static const upb_msglayout *const envoy_config_cluster_v3_LoadBalancingPolicy_su
 };
 
 static const upb_msglayout_field envoy_config_cluster_v3_LoadBalancingPolicy__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 11, 3},
+  {1, UPB_SIZE(0, 0), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout envoy_config_cluster_v3_LoadBalancingPolicy_msginit = {
   &envoy_config_cluster_v3_LoadBalancingPolicy_submsgs[0],
   &envoy_config_cluster_v3_LoadBalancingPolicy__fields[0],
-  UPB_SIZE(8, 8), 1, false, 255,
+  UPB_SIZE(8, 8), 1, false, 1, 255,
 };
 
 static const upb_msglayout *const envoy_config_cluster_v3_LoadBalancingPolicy_Policy_submsgs[1] = {
-  &google_protobuf_Any_msginit,
+  &envoy_config_core_v3_TypedExtensionConfig_msginit,
 };
 
-static const upb_msglayout_field envoy_config_cluster_v3_LoadBalancingPolicy_Policy__fields[2] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {3, UPB_SIZE(12, 24), 1, 0, 11, 1},
+static const upb_msglayout_field envoy_config_cluster_v3_LoadBalancingPolicy_Policy__fields[1] = {
+  {4, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_cluster_v3_LoadBalancingPolicy_Policy_msginit = {
   &envoy_config_cluster_v3_LoadBalancingPolicy_Policy_submsgs[0],
   &envoy_config_cluster_v3_LoadBalancingPolicy_Policy__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(8, 16), 1, false, 0, 255,
 };
 
 static const upb_msglayout *const envoy_config_cluster_v3_UpstreamBindConfig_submsgs[1] = {
@@ -423,13 +422,13 @@ static const upb_msglayout *const envoy_config_cluster_v3_UpstreamBindConfig_sub
 };
 
 static const upb_msglayout_field envoy_config_cluster_v3_UpstreamBindConfig__fields[1] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_cluster_v3_UpstreamBindConfig_msginit = {
   &envoy_config_cluster_v3_UpstreamBindConfig_submsgs[0],
   &envoy_config_cluster_v3_UpstreamBindConfig__fields[0],
-  UPB_SIZE(8, 16), 1, false, 255,
+  UPB_SIZE(8, 16), 1, false, 1, 255,
 };
 
 static const upb_msglayout *const envoy_config_cluster_v3_UpstreamConnectionOptions_submsgs[1] = {
@@ -437,24 +436,24 @@ static const upb_msglayout *const envoy_config_cluster_v3_UpstreamConnectionOpti
 };
 
 static const upb_msglayout_field envoy_config_cluster_v3_UpstreamConnectionOptions__fields[1] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_cluster_v3_UpstreamConnectionOptions_msginit = {
   &envoy_config_cluster_v3_UpstreamConnectionOptions_submsgs[0],
   &envoy_config_cluster_v3_UpstreamConnectionOptions__fields[0],
-  UPB_SIZE(8, 16), 1, false, 255,
+  UPB_SIZE(8, 16), 1, false, 1, 255,
 };
 
 static const upb_msglayout_field envoy_config_cluster_v3_TrackClusterStats__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 8, 1},
-  {2, UPB_SIZE(1, 1), 0, 0, 8, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 8, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(1, 1), 0, 0, 8, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_cluster_v3_TrackClusterStats_msginit = {
   NULL,
   &envoy_config_cluster_v3_TrackClusterStats__fields[0],
-  UPB_SIZE(8, 8), 2, false, 255,
+  UPB_SIZE(8, 8), 2, false, 2, 255,
 };
 
 #include "upb/port_undef.inc"
index 84feca0..293ded8 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_CONFIG_CLUSTER_V3_CLUSTER_PROTO_UPB_H_
 #define ENVOY_CONFIG_CLUSTER_V3_CLUSTER_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -201,13 +201,19 @@ UPB_INLINE envoy_config_cluster_v3_ClusterCollection *envoy_config_cluster_v3_Cl
 UPB_INLINE envoy_config_cluster_v3_ClusterCollection *envoy_config_cluster_v3_ClusterCollection_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_cluster_v3_ClusterCollection *ret = envoy_config_cluster_v3_ClusterCollection_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_cluster_v3_ClusterCollection_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_cluster_v3_ClusterCollection_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_cluster_v3_ClusterCollection *envoy_config_cluster_v3_ClusterCollection_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_cluster_v3_ClusterCollection *ret = envoy_config_cluster_v3_ClusterCollection_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_cluster_v3_ClusterCollection_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_cluster_v3_ClusterCollection_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_cluster_v3_ClusterCollection_serialize(const envoy_config_cluster_v3_ClusterCollection *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_cluster_v3_ClusterCollection_msginit, arena, len);
@@ -238,13 +244,19 @@ UPB_INLINE envoy_config_cluster_v3_Cluster *envoy_config_cluster_v3_Cluster_new(
 UPB_INLINE envoy_config_cluster_v3_Cluster *envoy_config_cluster_v3_Cluster_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_cluster_v3_Cluster *ret = envoy_config_cluster_v3_Cluster_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_cluster_v3_Cluster *envoy_config_cluster_v3_Cluster_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_cluster_v3_Cluster *ret = envoy_config_cluster_v3_Cluster_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_cluster_v3_Cluster_serialize(const envoy_config_cluster_v3_Cluster *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_cluster_v3_Cluster_msginit, arena, len);
@@ -883,13 +895,19 @@ UPB_INLINE envoy_config_cluster_v3_Cluster_TransportSocketMatch *envoy_config_cl
 UPB_INLINE envoy_config_cluster_v3_Cluster_TransportSocketMatch *envoy_config_cluster_v3_Cluster_TransportSocketMatch_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_cluster_v3_Cluster_TransportSocketMatch *ret = envoy_config_cluster_v3_Cluster_TransportSocketMatch_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_TransportSocketMatch_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_TransportSocketMatch_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_cluster_v3_Cluster_TransportSocketMatch *envoy_config_cluster_v3_Cluster_TransportSocketMatch_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_cluster_v3_Cluster_TransportSocketMatch *ret = envoy_config_cluster_v3_Cluster_TransportSocketMatch_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_TransportSocketMatch_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_TransportSocketMatch_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_cluster_v3_Cluster_TransportSocketMatch_serialize(const envoy_config_cluster_v3_Cluster_TransportSocketMatch *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_cluster_v3_Cluster_TransportSocketMatch_msginit, arena, len);
@@ -939,13 +957,19 @@ UPB_INLINE envoy_config_cluster_v3_Cluster_CustomClusterType *envoy_config_clust
 UPB_INLINE envoy_config_cluster_v3_Cluster_CustomClusterType *envoy_config_cluster_v3_Cluster_CustomClusterType_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_cluster_v3_Cluster_CustomClusterType *ret = envoy_config_cluster_v3_Cluster_CustomClusterType_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_CustomClusterType_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_CustomClusterType_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_cluster_v3_Cluster_CustomClusterType *envoy_config_cluster_v3_Cluster_CustomClusterType_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_cluster_v3_Cluster_CustomClusterType *ret = envoy_config_cluster_v3_Cluster_CustomClusterType_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_CustomClusterType_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_CustomClusterType_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_cluster_v3_Cluster_CustomClusterType_serialize(const envoy_config_cluster_v3_Cluster_CustomClusterType *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_cluster_v3_Cluster_CustomClusterType_msginit, arena, len);
@@ -980,13 +1004,19 @@ UPB_INLINE envoy_config_cluster_v3_Cluster_EdsClusterConfig *envoy_config_cluste
 UPB_INLINE envoy_config_cluster_v3_Cluster_EdsClusterConfig *envoy_config_cluster_v3_Cluster_EdsClusterConfig_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_cluster_v3_Cluster_EdsClusterConfig *ret = envoy_config_cluster_v3_Cluster_EdsClusterConfig_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_EdsClusterConfig_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_EdsClusterConfig_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_cluster_v3_Cluster_EdsClusterConfig *envoy_config_cluster_v3_Cluster_EdsClusterConfig_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_cluster_v3_Cluster_EdsClusterConfig *ret = envoy_config_cluster_v3_Cluster_EdsClusterConfig_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_EdsClusterConfig_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_EdsClusterConfig_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_cluster_v3_Cluster_EdsClusterConfig_serialize(const envoy_config_cluster_v3_Cluster_EdsClusterConfig *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_cluster_v3_Cluster_EdsClusterConfig_msginit, arena, len);
@@ -1021,13 +1051,19 @@ UPB_INLINE envoy_config_cluster_v3_Cluster_LbSubsetConfig *envoy_config_cluster_
 UPB_INLINE envoy_config_cluster_v3_Cluster_LbSubsetConfig *envoy_config_cluster_v3_Cluster_LbSubsetConfig_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_cluster_v3_Cluster_LbSubsetConfig *ret = envoy_config_cluster_v3_Cluster_LbSubsetConfig_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_LbSubsetConfig_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_LbSubsetConfig_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_cluster_v3_Cluster_LbSubsetConfig *envoy_config_cluster_v3_Cluster_LbSubsetConfig_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_cluster_v3_Cluster_LbSubsetConfig *ret = envoy_config_cluster_v3_Cluster_LbSubsetConfig_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_LbSubsetConfig_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_LbSubsetConfig_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_cluster_v3_Cluster_LbSubsetConfig_serialize(const envoy_config_cluster_v3_Cluster_LbSubsetConfig *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_cluster_v3_Cluster_LbSubsetConfig_msginit, arena, len);
@@ -1093,13 +1129,19 @@ UPB_INLINE envoy_config_cluster_v3_Cluster_LbSubsetConfig_LbSubsetSelector *envo
 UPB_INLINE envoy_config_cluster_v3_Cluster_LbSubsetConfig_LbSubsetSelector *envoy_config_cluster_v3_Cluster_LbSubsetConfig_LbSubsetSelector_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_cluster_v3_Cluster_LbSubsetConfig_LbSubsetSelector *ret = envoy_config_cluster_v3_Cluster_LbSubsetConfig_LbSubsetSelector_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_LbSubsetConfig_LbSubsetSelector_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_LbSubsetConfig_LbSubsetSelector_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_cluster_v3_Cluster_LbSubsetConfig_LbSubsetSelector *envoy_config_cluster_v3_Cluster_LbSubsetConfig_LbSubsetSelector_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_cluster_v3_Cluster_LbSubsetConfig_LbSubsetSelector *ret = envoy_config_cluster_v3_Cluster_LbSubsetConfig_LbSubsetSelector_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_LbSubsetConfig_LbSubsetSelector_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_LbSubsetConfig_LbSubsetSelector_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_cluster_v3_Cluster_LbSubsetConfig_LbSubsetSelector_serialize(const envoy_config_cluster_v3_Cluster_LbSubsetConfig_LbSubsetSelector *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_cluster_v3_Cluster_LbSubsetConfig_LbSubsetSelector_msginit, arena, len);
@@ -1145,13 +1187,19 @@ UPB_INLINE envoy_config_cluster_v3_Cluster_LeastRequestLbConfig *envoy_config_cl
 UPB_INLINE envoy_config_cluster_v3_Cluster_LeastRequestLbConfig *envoy_config_cluster_v3_Cluster_LeastRequestLbConfig_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_cluster_v3_Cluster_LeastRequestLbConfig *ret = envoy_config_cluster_v3_Cluster_LeastRequestLbConfig_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_LeastRequestLbConfig_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_LeastRequestLbConfig_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_cluster_v3_Cluster_LeastRequestLbConfig *envoy_config_cluster_v3_Cluster_LeastRequestLbConfig_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_cluster_v3_Cluster_LeastRequestLbConfig *ret = envoy_config_cluster_v3_Cluster_LeastRequestLbConfig_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_LeastRequestLbConfig_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_LeastRequestLbConfig_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_cluster_v3_Cluster_LeastRequestLbConfig_serialize(const envoy_config_cluster_v3_Cluster_LeastRequestLbConfig *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_cluster_v3_Cluster_LeastRequestLbConfig_msginit, arena, len);
@@ -1197,13 +1245,19 @@ UPB_INLINE envoy_config_cluster_v3_Cluster_RingHashLbConfig *envoy_config_cluste
 UPB_INLINE envoy_config_cluster_v3_Cluster_RingHashLbConfig *envoy_config_cluster_v3_Cluster_RingHashLbConfig_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_cluster_v3_Cluster_RingHashLbConfig *ret = envoy_config_cluster_v3_Cluster_RingHashLbConfig_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_RingHashLbConfig_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_RingHashLbConfig_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_cluster_v3_Cluster_RingHashLbConfig *envoy_config_cluster_v3_Cluster_RingHashLbConfig_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_cluster_v3_Cluster_RingHashLbConfig *ret = envoy_config_cluster_v3_Cluster_RingHashLbConfig_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_RingHashLbConfig_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_RingHashLbConfig_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_cluster_v3_Cluster_RingHashLbConfig_serialize(const envoy_config_cluster_v3_Cluster_RingHashLbConfig *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_cluster_v3_Cluster_RingHashLbConfig_msginit, arena, len);
@@ -1253,13 +1307,19 @@ UPB_INLINE envoy_config_cluster_v3_Cluster_MaglevLbConfig *envoy_config_cluster_
 UPB_INLINE envoy_config_cluster_v3_Cluster_MaglevLbConfig *envoy_config_cluster_v3_Cluster_MaglevLbConfig_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_cluster_v3_Cluster_MaglevLbConfig *ret = envoy_config_cluster_v3_Cluster_MaglevLbConfig_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_MaglevLbConfig_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_MaglevLbConfig_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_cluster_v3_Cluster_MaglevLbConfig *envoy_config_cluster_v3_Cluster_MaglevLbConfig_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_cluster_v3_Cluster_MaglevLbConfig *ret = envoy_config_cluster_v3_Cluster_MaglevLbConfig_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_MaglevLbConfig_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_MaglevLbConfig_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_cluster_v3_Cluster_MaglevLbConfig_serialize(const envoy_config_cluster_v3_Cluster_MaglevLbConfig *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_cluster_v3_Cluster_MaglevLbConfig_msginit, arena, len);
@@ -1290,13 +1350,19 @@ UPB_INLINE envoy_config_cluster_v3_Cluster_OriginalDstLbConfig *envoy_config_clu
 UPB_INLINE envoy_config_cluster_v3_Cluster_OriginalDstLbConfig *envoy_config_cluster_v3_Cluster_OriginalDstLbConfig_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_cluster_v3_Cluster_OriginalDstLbConfig *ret = envoy_config_cluster_v3_Cluster_OriginalDstLbConfig_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_OriginalDstLbConfig_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_OriginalDstLbConfig_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_cluster_v3_Cluster_OriginalDstLbConfig *envoy_config_cluster_v3_Cluster_OriginalDstLbConfig_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_cluster_v3_Cluster_OriginalDstLbConfig *ret = envoy_config_cluster_v3_Cluster_OriginalDstLbConfig_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_OriginalDstLbConfig_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_OriginalDstLbConfig_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_cluster_v3_Cluster_OriginalDstLbConfig_serialize(const envoy_config_cluster_v3_Cluster_OriginalDstLbConfig *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_cluster_v3_Cluster_OriginalDstLbConfig_msginit, arena, len);
@@ -1316,13 +1382,19 @@ UPB_INLINE envoy_config_cluster_v3_Cluster_CommonLbConfig *envoy_config_cluster_
 UPB_INLINE envoy_config_cluster_v3_Cluster_CommonLbConfig *envoy_config_cluster_v3_Cluster_CommonLbConfig_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_cluster_v3_Cluster_CommonLbConfig *ret = envoy_config_cluster_v3_Cluster_CommonLbConfig_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_CommonLbConfig_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_CommonLbConfig_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_cluster_v3_Cluster_CommonLbConfig *envoy_config_cluster_v3_Cluster_CommonLbConfig_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_cluster_v3_Cluster_CommonLbConfig *ret = envoy_config_cluster_v3_Cluster_CommonLbConfig_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_CommonLbConfig_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_CommonLbConfig_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_cluster_v3_Cluster_CommonLbConfig_serialize(const envoy_config_cluster_v3_Cluster_CommonLbConfig *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_cluster_v3_Cluster_CommonLbConfig_msginit, arena, len);
@@ -1426,13 +1498,19 @@ UPB_INLINE envoy_config_cluster_v3_Cluster_CommonLbConfig_ZoneAwareLbConfig *env
 UPB_INLINE envoy_config_cluster_v3_Cluster_CommonLbConfig_ZoneAwareLbConfig *envoy_config_cluster_v3_Cluster_CommonLbConfig_ZoneAwareLbConfig_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_cluster_v3_Cluster_CommonLbConfig_ZoneAwareLbConfig *ret = envoy_config_cluster_v3_Cluster_CommonLbConfig_ZoneAwareLbConfig_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_CommonLbConfig_ZoneAwareLbConfig_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_CommonLbConfig_ZoneAwareLbConfig_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_cluster_v3_Cluster_CommonLbConfig_ZoneAwareLbConfig *envoy_config_cluster_v3_Cluster_CommonLbConfig_ZoneAwareLbConfig_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_cluster_v3_Cluster_CommonLbConfig_ZoneAwareLbConfig *ret = envoy_config_cluster_v3_Cluster_CommonLbConfig_ZoneAwareLbConfig_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_CommonLbConfig_ZoneAwareLbConfig_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_CommonLbConfig_ZoneAwareLbConfig_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_cluster_v3_Cluster_CommonLbConfig_ZoneAwareLbConfig_serialize(const envoy_config_cluster_v3_Cluster_CommonLbConfig_ZoneAwareLbConfig *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_cluster_v3_Cluster_CommonLbConfig_ZoneAwareLbConfig_msginit, arena, len);
@@ -1482,13 +1560,19 @@ UPB_INLINE envoy_config_cluster_v3_Cluster_CommonLbConfig_LocalityWeightedLbConf
 UPB_INLINE envoy_config_cluster_v3_Cluster_CommonLbConfig_LocalityWeightedLbConfig *envoy_config_cluster_v3_Cluster_CommonLbConfig_LocalityWeightedLbConfig_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_cluster_v3_Cluster_CommonLbConfig_LocalityWeightedLbConfig *ret = envoy_config_cluster_v3_Cluster_CommonLbConfig_LocalityWeightedLbConfig_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_CommonLbConfig_LocalityWeightedLbConfig_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_CommonLbConfig_LocalityWeightedLbConfig_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_cluster_v3_Cluster_CommonLbConfig_LocalityWeightedLbConfig *envoy_config_cluster_v3_Cluster_CommonLbConfig_LocalityWeightedLbConfig_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_cluster_v3_Cluster_CommonLbConfig_LocalityWeightedLbConfig *ret = envoy_config_cluster_v3_Cluster_CommonLbConfig_LocalityWeightedLbConfig_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_CommonLbConfig_LocalityWeightedLbConfig_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_CommonLbConfig_LocalityWeightedLbConfig_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_cluster_v3_Cluster_CommonLbConfig_LocalityWeightedLbConfig_serialize(const envoy_config_cluster_v3_Cluster_CommonLbConfig_LocalityWeightedLbConfig *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_cluster_v3_Cluster_CommonLbConfig_LocalityWeightedLbConfig_msginit, arena, len);
@@ -1504,13 +1588,19 @@ UPB_INLINE envoy_config_cluster_v3_Cluster_CommonLbConfig_ConsistentHashingLbCon
 UPB_INLINE envoy_config_cluster_v3_Cluster_CommonLbConfig_ConsistentHashingLbConfig *envoy_config_cluster_v3_Cluster_CommonLbConfig_ConsistentHashingLbConfig_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_cluster_v3_Cluster_CommonLbConfig_ConsistentHashingLbConfig *ret = envoy_config_cluster_v3_Cluster_CommonLbConfig_ConsistentHashingLbConfig_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_CommonLbConfig_ConsistentHashingLbConfig_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_CommonLbConfig_ConsistentHashingLbConfig_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_cluster_v3_Cluster_CommonLbConfig_ConsistentHashingLbConfig *envoy_config_cluster_v3_Cluster_CommonLbConfig_ConsistentHashingLbConfig_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_cluster_v3_Cluster_CommonLbConfig_ConsistentHashingLbConfig *ret = envoy_config_cluster_v3_Cluster_CommonLbConfig_ConsistentHashingLbConfig_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_CommonLbConfig_ConsistentHashingLbConfig_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_CommonLbConfig_ConsistentHashingLbConfig_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_cluster_v3_Cluster_CommonLbConfig_ConsistentHashingLbConfig_serialize(const envoy_config_cluster_v3_Cluster_CommonLbConfig_ConsistentHashingLbConfig *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_cluster_v3_Cluster_CommonLbConfig_ConsistentHashingLbConfig_msginit, arena, len);
@@ -1545,13 +1635,19 @@ UPB_INLINE envoy_config_cluster_v3_Cluster_RefreshRate *envoy_config_cluster_v3_
 UPB_INLINE envoy_config_cluster_v3_Cluster_RefreshRate *envoy_config_cluster_v3_Cluster_RefreshRate_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_cluster_v3_Cluster_RefreshRate *ret = envoy_config_cluster_v3_Cluster_RefreshRate_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_RefreshRate_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_RefreshRate_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_cluster_v3_Cluster_RefreshRate *envoy_config_cluster_v3_Cluster_RefreshRate_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_cluster_v3_Cluster_RefreshRate *ret = envoy_config_cluster_v3_Cluster_RefreshRate_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_RefreshRate_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_RefreshRate_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_cluster_v3_Cluster_RefreshRate_serialize(const envoy_config_cluster_v3_Cluster_RefreshRate *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_cluster_v3_Cluster_RefreshRate_msginit, arena, len);
@@ -1597,13 +1693,19 @@ UPB_INLINE envoy_config_cluster_v3_Cluster_PreconnectPolicy *envoy_config_cluste
 UPB_INLINE envoy_config_cluster_v3_Cluster_PreconnectPolicy *envoy_config_cluster_v3_Cluster_PreconnectPolicy_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_cluster_v3_Cluster_PreconnectPolicy *ret = envoy_config_cluster_v3_Cluster_PreconnectPolicy_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_PreconnectPolicy_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_PreconnectPolicy_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_cluster_v3_Cluster_PreconnectPolicy *envoy_config_cluster_v3_Cluster_PreconnectPolicy_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_cluster_v3_Cluster_PreconnectPolicy *ret = envoy_config_cluster_v3_Cluster_PreconnectPolicy_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_PreconnectPolicy_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_cluster_v3_Cluster_PreconnectPolicy_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_cluster_v3_Cluster_PreconnectPolicy_serialize(const envoy_config_cluster_v3_Cluster_PreconnectPolicy *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_cluster_v3_Cluster_PreconnectPolicy_msginit, arena, len);
@@ -1667,13 +1769,19 @@ UPB_INLINE envoy_config_cluster_v3_LoadBalancingPolicy *envoy_config_cluster_v3_
 UPB_INLINE envoy_config_cluster_v3_LoadBalancingPolicy *envoy_config_cluster_v3_LoadBalancingPolicy_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_cluster_v3_LoadBalancingPolicy *ret = envoy_config_cluster_v3_LoadBalancingPolicy_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_cluster_v3_LoadBalancingPolicy_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_cluster_v3_LoadBalancingPolicy_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_cluster_v3_LoadBalancingPolicy *envoy_config_cluster_v3_LoadBalancingPolicy_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_cluster_v3_LoadBalancingPolicy *ret = envoy_config_cluster_v3_LoadBalancingPolicy_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_cluster_v3_LoadBalancingPolicy_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_cluster_v3_LoadBalancingPolicy_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_cluster_v3_LoadBalancingPolicy_serialize(const envoy_config_cluster_v3_LoadBalancingPolicy *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_cluster_v3_LoadBalancingPolicy_msginit, arena, len);
@@ -1704,35 +1812,37 @@ UPB_INLINE envoy_config_cluster_v3_LoadBalancingPolicy_Policy *envoy_config_clus
 UPB_INLINE envoy_config_cluster_v3_LoadBalancingPolicy_Policy *envoy_config_cluster_v3_LoadBalancingPolicy_Policy_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_cluster_v3_LoadBalancingPolicy_Policy *ret = envoy_config_cluster_v3_LoadBalancingPolicy_Policy_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_cluster_v3_LoadBalancingPolicy_Policy_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_cluster_v3_LoadBalancingPolicy_Policy_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_cluster_v3_LoadBalancingPolicy_Policy *envoy_config_cluster_v3_LoadBalancingPolicy_Policy_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_cluster_v3_LoadBalancingPolicy_Policy *ret = envoy_config_cluster_v3_LoadBalancingPolicy_Policy_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_cluster_v3_LoadBalancingPolicy_Policy_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_cluster_v3_LoadBalancingPolicy_Policy_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_cluster_v3_LoadBalancingPolicy_Policy_serialize(const envoy_config_cluster_v3_LoadBalancingPolicy_Policy *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_cluster_v3_LoadBalancingPolicy_Policy_msginit, arena, len);
 }
 
-UPB_INLINE upb_strview envoy_config_cluster_v3_LoadBalancingPolicy_Policy_name(const envoy_config_cluster_v3_LoadBalancingPolicy_Policy *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(4, 8), upb_strview); }
-UPB_INLINE bool envoy_config_cluster_v3_LoadBalancingPolicy_Policy_has_typed_config(const envoy_config_cluster_v3_LoadBalancingPolicy_Policy *msg) { return _upb_hasbit(msg, 1); }
-UPB_INLINE const struct google_protobuf_Any* envoy_config_cluster_v3_LoadBalancingPolicy_Policy_typed_config(const envoy_config_cluster_v3_LoadBalancingPolicy_Policy *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(12, 24), const struct google_protobuf_Any*); }
+UPB_INLINE bool envoy_config_cluster_v3_LoadBalancingPolicy_Policy_has_typed_extension_config(const envoy_config_cluster_v3_LoadBalancingPolicy_Policy *msg) { return _upb_hasbit(msg, 1); }
+UPB_INLINE const struct envoy_config_core_v3_TypedExtensionConfig* envoy_config_cluster_v3_LoadBalancingPolicy_Policy_typed_extension_config(const envoy_config_cluster_v3_LoadBalancingPolicy_Policy *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(4, 8), const struct envoy_config_core_v3_TypedExtensionConfig*); }
 
-UPB_INLINE void envoy_config_cluster_v3_LoadBalancingPolicy_Policy_set_name(envoy_config_cluster_v3_LoadBalancingPolicy_Policy *msg, upb_strview value) {
-  *UPB_PTR_AT(msg, UPB_SIZE(4, 8), upb_strview) = value;
-}
-UPB_INLINE void envoy_config_cluster_v3_LoadBalancingPolicy_Policy_set_typed_config(envoy_config_cluster_v3_LoadBalancingPolicy_Policy *msg, struct google_protobuf_Any* value) {
+UPB_INLINE void envoy_config_cluster_v3_LoadBalancingPolicy_Policy_set_typed_extension_config(envoy_config_cluster_v3_LoadBalancingPolicy_Policy *msg, struct envoy_config_core_v3_TypedExtensionConfig* value) {
   _upb_sethas(msg, 1);
-  *UPB_PTR_AT(msg, UPB_SIZE(12, 24), struct google_protobuf_Any*) = value;
+  *UPB_PTR_AT(msg, UPB_SIZE(4, 8), struct envoy_config_core_v3_TypedExtensionConfig*) = value;
 }
-UPB_INLINE struct google_protobuf_Any* envoy_config_cluster_v3_LoadBalancingPolicy_Policy_mutable_typed_config(envoy_config_cluster_v3_LoadBalancingPolicy_Policy *msg, upb_arena *arena) {
-  struct google_protobuf_Any* sub = (struct google_protobuf_Any*)envoy_config_cluster_v3_LoadBalancingPolicy_Policy_typed_config(msg);
+UPB_INLINE struct envoy_config_core_v3_TypedExtensionConfig* envoy_config_cluster_v3_LoadBalancingPolicy_Policy_mutable_typed_extension_config(envoy_config_cluster_v3_LoadBalancingPolicy_Policy *msg, upb_arena *arena) {
+  struct envoy_config_core_v3_TypedExtensionConfig* sub = (struct envoy_config_core_v3_TypedExtensionConfig*)envoy_config_cluster_v3_LoadBalancingPolicy_Policy_typed_extension_config(msg);
   if (sub == NULL) {
-    sub = (struct google_protobuf_Any*)_upb_msg_new(&google_protobuf_Any_msginit, arena);
+    sub = (struct envoy_config_core_v3_TypedExtensionConfig*)_upb_msg_new(&envoy_config_core_v3_TypedExtensionConfig_msginit, arena);
     if (!sub) return NULL;
-    envoy_config_cluster_v3_LoadBalancingPolicy_Policy_set_typed_config(msg, sub);
+    envoy_config_cluster_v3_LoadBalancingPolicy_Policy_set_typed_extension_config(msg, sub);
   }
   return sub;
 }
@@ -1745,13 +1855,19 @@ UPB_INLINE envoy_config_cluster_v3_UpstreamBindConfig *envoy_config_cluster_v3_U
 UPB_INLINE envoy_config_cluster_v3_UpstreamBindConfig *envoy_config_cluster_v3_UpstreamBindConfig_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_cluster_v3_UpstreamBindConfig *ret = envoy_config_cluster_v3_UpstreamBindConfig_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_cluster_v3_UpstreamBindConfig_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_cluster_v3_UpstreamBindConfig_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_cluster_v3_UpstreamBindConfig *envoy_config_cluster_v3_UpstreamBindConfig_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_cluster_v3_UpstreamBindConfig *ret = envoy_config_cluster_v3_UpstreamBindConfig_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_cluster_v3_UpstreamBindConfig_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_cluster_v3_UpstreamBindConfig_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_cluster_v3_UpstreamBindConfig_serialize(const envoy_config_cluster_v3_UpstreamBindConfig *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_cluster_v3_UpstreamBindConfig_msginit, arena, len);
@@ -1782,13 +1898,19 @@ UPB_INLINE envoy_config_cluster_v3_UpstreamConnectionOptions *envoy_config_clust
 UPB_INLINE envoy_config_cluster_v3_UpstreamConnectionOptions *envoy_config_cluster_v3_UpstreamConnectionOptions_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_cluster_v3_UpstreamConnectionOptions *ret = envoy_config_cluster_v3_UpstreamConnectionOptions_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_cluster_v3_UpstreamConnectionOptions_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_cluster_v3_UpstreamConnectionOptions_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_cluster_v3_UpstreamConnectionOptions *envoy_config_cluster_v3_UpstreamConnectionOptions_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_cluster_v3_UpstreamConnectionOptions *ret = envoy_config_cluster_v3_UpstreamConnectionOptions_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_cluster_v3_UpstreamConnectionOptions_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_cluster_v3_UpstreamConnectionOptions_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_cluster_v3_UpstreamConnectionOptions_serialize(const envoy_config_cluster_v3_UpstreamConnectionOptions *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_cluster_v3_UpstreamConnectionOptions_msginit, arena, len);
@@ -1819,13 +1941,19 @@ UPB_INLINE envoy_config_cluster_v3_TrackClusterStats *envoy_config_cluster_v3_Tr
 UPB_INLINE envoy_config_cluster_v3_TrackClusterStats *envoy_config_cluster_v3_TrackClusterStats_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_cluster_v3_TrackClusterStats *ret = envoy_config_cluster_v3_TrackClusterStats_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_cluster_v3_TrackClusterStats_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_cluster_v3_TrackClusterStats_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_cluster_v3_TrackClusterStats *envoy_config_cluster_v3_TrackClusterStats_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_cluster_v3_TrackClusterStats *ret = envoy_config_cluster_v3_TrackClusterStats_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_cluster_v3_TrackClusterStats_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_cluster_v3_TrackClusterStats_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_cluster_v3_TrackClusterStats_serialize(const envoy_config_cluster_v3_TrackClusterStats *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_cluster_v3_TrackClusterStats_msginit, arena, len);
index 1423014..7c02e7a 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/config/cluster/v3/filter.upb.h"
 #include "google/protobuf/any.upb.h"
 #include "udpa/annotations/status.upb.h"
@@ -21,14 +21,14 @@ static const upb_msglayout *const envoy_config_cluster_v3_Filter_submsgs[1] = {
 };
 
 static const upb_msglayout_field envoy_config_cluster_v3_Filter__fields[2] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(12, 24), 1, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(12, 24), 1, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_cluster_v3_Filter_msginit = {
   &envoy_config_cluster_v3_Filter_submsgs[0],
   &envoy_config_cluster_v3_Filter__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 #include "upb/port_undef.inc"
index 1850b2a..36356fb 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_CONFIG_CLUSTER_V3_FILTER_PROTO_UPB_H_
 #define ENVOY_CONFIG_CLUSTER_V3_FILTER_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -35,13 +35,19 @@ UPB_INLINE envoy_config_cluster_v3_Filter *envoy_config_cluster_v3_Filter_new(up
 UPB_INLINE envoy_config_cluster_v3_Filter *envoy_config_cluster_v3_Filter_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_cluster_v3_Filter *ret = envoy_config_cluster_v3_Filter_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_cluster_v3_Filter_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_cluster_v3_Filter_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_cluster_v3_Filter *envoy_config_cluster_v3_Filter_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_cluster_v3_Filter *ret = envoy_config_cluster_v3_Filter_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_cluster_v3_Filter_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_cluster_v3_Filter_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_cluster_v3_Filter_serialize(const envoy_config_cluster_v3_Filter *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_cluster_v3_Filter_msginit, arena, len);
index f90563f..3092f86 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/config/cluster/v3/outlier_detection.upb.h"
 #include "google/protobuf/duration.upb.h"
 #include "google/protobuf/wrappers.upb.h"
@@ -23,33 +23,33 @@ static const upb_msglayout *const envoy_config_cluster_v3_OutlierDetection_subms
 };
 
 static const upb_msglayout_field envoy_config_cluster_v3_OutlierDetection__fields[21] = {
-  {1, UPB_SIZE(4, 8), 1, 1, 11, 1},
-  {2, UPB_SIZE(8, 16), 2, 0, 11, 1},
-  {3, UPB_SIZE(12, 24), 3, 0, 11, 1},
-  {4, UPB_SIZE(16, 32), 4, 1, 11, 1},
-  {5, UPB_SIZE(20, 40), 5, 1, 11, 1},
-  {6, UPB_SIZE(24, 48), 6, 1, 11, 1},
-  {7, UPB_SIZE(28, 56), 7, 1, 11, 1},
-  {8, UPB_SIZE(32, 64), 8, 1, 11, 1},
-  {9, UPB_SIZE(36, 72), 9, 1, 11, 1},
-  {10, UPB_SIZE(40, 80), 10, 1, 11, 1},
-  {11, UPB_SIZE(44, 88), 11, 1, 11, 1},
-  {12, UPB_SIZE(3, 3), 0, 0, 8, 1},
-  {13, UPB_SIZE(48, 96), 12, 1, 11, 1},
-  {14, UPB_SIZE(52, 104), 13, 1, 11, 1},
-  {15, UPB_SIZE(56, 112), 14, 1, 11, 1},
-  {16, UPB_SIZE(60, 120), 15, 1, 11, 1},
-  {17, UPB_SIZE(64, 128), 16, 1, 11, 1},
-  {18, UPB_SIZE(68, 136), 17, 1, 11, 1},
-  {19, UPB_SIZE(72, 144), 18, 1, 11, 1},
-  {20, UPB_SIZE(76, 152), 19, 1, 11, 1},
-  {21, UPB_SIZE(80, 160), 20, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 1, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 2, 0, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(12, 24), 3, 0, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(16, 32), 4, 1, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(20, 40), 5, 1, 11, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(24, 48), 6, 1, 11, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(28, 56), 7, 1, 11, _UPB_MODE_SCALAR},
+  {8, UPB_SIZE(32, 64), 8, 1, 11, _UPB_MODE_SCALAR},
+  {9, UPB_SIZE(36, 72), 9, 1, 11, _UPB_MODE_SCALAR},
+  {10, UPB_SIZE(40, 80), 10, 1, 11, _UPB_MODE_SCALAR},
+  {11, UPB_SIZE(44, 88), 11, 1, 11, _UPB_MODE_SCALAR},
+  {12, UPB_SIZE(3, 3), 0, 0, 8, _UPB_MODE_SCALAR},
+  {13, UPB_SIZE(48, 96), 12, 1, 11, _UPB_MODE_SCALAR},
+  {14, UPB_SIZE(52, 104), 13, 1, 11, _UPB_MODE_SCALAR},
+  {15, UPB_SIZE(56, 112), 14, 1, 11, _UPB_MODE_SCALAR},
+  {16, UPB_SIZE(60, 120), 15, 1, 11, _UPB_MODE_SCALAR},
+  {17, UPB_SIZE(64, 128), 16, 1, 11, _UPB_MODE_SCALAR},
+  {18, UPB_SIZE(68, 136), 17, 1, 11, _UPB_MODE_SCALAR},
+  {19, UPB_SIZE(72, 144), 18, 1, 11, _UPB_MODE_SCALAR},
+  {20, UPB_SIZE(76, 152), 19, 1, 11, _UPB_MODE_SCALAR},
+  {21, UPB_SIZE(80, 160), 20, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_cluster_v3_OutlierDetection_msginit = {
   &envoy_config_cluster_v3_OutlierDetection_submsgs[0],
   &envoy_config_cluster_v3_OutlierDetection__fields[0],
-  UPB_SIZE(88, 168), 21, false, 255,
+  UPB_SIZE(88, 168), 21, false, 21, 255,
 };
 
 #include "upb/port_undef.inc"
index 70b7623..9da074f 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_CONFIG_CLUSTER_V3_OUTLIER_DETECTION_PROTO_UPB_H_
 #define ENVOY_CONFIG_CLUSTER_V3_OUTLIER_DETECTION_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -37,13 +37,19 @@ UPB_INLINE envoy_config_cluster_v3_OutlierDetection *envoy_config_cluster_v3_Out
 UPB_INLINE envoy_config_cluster_v3_OutlierDetection *envoy_config_cluster_v3_OutlierDetection_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_cluster_v3_OutlierDetection *ret = envoy_config_cluster_v3_OutlierDetection_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_cluster_v3_OutlierDetection_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_cluster_v3_OutlierDetection_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_cluster_v3_OutlierDetection *envoy_config_cluster_v3_OutlierDetection_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_cluster_v3_OutlierDetection *ret = envoy_config_cluster_v3_OutlierDetection_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_cluster_v3_OutlierDetection_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_cluster_v3_OutlierDetection_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_cluster_v3_OutlierDetection_serialize(const envoy_config_cluster_v3_OutlierDetection *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_cluster_v3_OutlierDetection_msginit, arena, len);
index 048fc05..457e1ea 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/config/core/v3/address.upb.h"
 #include "envoy/config/core/v3/socket_option.upb.h"
 #include "google/protobuf/wrappers.upb.h"
 #include "upb/port_def.inc"
 
 static const upb_msglayout_field envoy_config_core_v3_Pipe__fields[2] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(0, 0), 0, 0, 13, 1},
+  {1, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(0, 0), 0, 0, 13, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_Pipe_msginit = {
   NULL,
   &envoy_config_core_v3_Pipe__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout_field envoy_config_core_v3_EnvoyInternalAddress__fields[1] = {
-  {1, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 9, 1},
+  {1, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_EnvoyInternalAddress_msginit = {
   NULL,
   &envoy_config_core_v3_EnvoyInternalAddress__fields[0],
-  UPB_SIZE(16, 32), 1, false, 255,
+  UPB_SIZE(16, 32), 1, false, 1, 255,
 };
 
 static const upb_msglayout_field envoy_config_core_v3_SocketAddress__fields[6] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 14, 1},
-  {2, UPB_SIZE(8, 8), 0, 0, 9, 1},
-  {3, UPB_SIZE(24, 40), UPB_SIZE(-33, -57), 0, 13, 1},
-  {4, UPB_SIZE(24, 40), UPB_SIZE(-33, -57), 0, 9, 1},
-  {5, UPB_SIZE(16, 24), 0, 0, 9, 1},
-  {6, UPB_SIZE(4, 4), 0, 0, 8, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 14, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(24, 40), UPB_SIZE(-33, -57), 0, 13, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(24, 40), UPB_SIZE(-33, -57), 0, 9, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(16, 24), 0, 0, 9, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(4, 4), 0, 0, 8, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_SocketAddress_msginit = {
   NULL,
   &envoy_config_core_v3_SocketAddress__fields[0],
-  UPB_SIZE(40, 64), 6, false, 255,
+  UPB_SIZE(40, 64), 6, false, 6, 255,
 };
 
 static const upb_msglayout *const envoy_config_core_v3_TcpKeepalive_submsgs[1] = {
@@ -58,15 +58,15 @@ static const upb_msglayout *const envoy_config_core_v3_TcpKeepalive_submsgs[1] =
 };
 
 static const upb_msglayout_field envoy_config_core_v3_TcpKeepalive__fields[3] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
-  {2, UPB_SIZE(8, 16), 2, 0, 11, 1},
-  {3, UPB_SIZE(12, 24), 3, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 2, 0, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(12, 24), 3, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_TcpKeepalive_msginit = {
   &envoy_config_core_v3_TcpKeepalive_submsgs[0],
   &envoy_config_core_v3_TcpKeepalive__fields[0],
-  UPB_SIZE(16, 32), 3, false, 255,
+  UPB_SIZE(16, 32), 3, false, 3, 255,
 };
 
 static const upb_msglayout *const envoy_config_core_v3_BindConfig_submsgs[3] = {
@@ -76,15 +76,15 @@ static const upb_msglayout *const envoy_config_core_v3_BindConfig_submsgs[3] = {
 };
 
 static const upb_msglayout_field envoy_config_core_v3_BindConfig__fields[3] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
-  {2, UPB_SIZE(8, 16), 2, 2, 11, 1},
-  {3, UPB_SIZE(12, 24), 0, 1, 11, 3},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 2, 2, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(12, 24), 0, 1, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout envoy_config_core_v3_BindConfig_msginit = {
   &envoy_config_core_v3_BindConfig_submsgs[0],
   &envoy_config_core_v3_BindConfig__fields[0],
-  UPB_SIZE(16, 32), 3, false, 255,
+  UPB_SIZE(16, 32), 3, false, 3, 255,
 };
 
 static const upb_msglayout *const envoy_config_core_v3_Address_submsgs[3] = {
@@ -94,15 +94,15 @@ static const upb_msglayout *const envoy_config_core_v3_Address_submsgs[3] = {
 };
 
 static const upb_msglayout_field envoy_config_core_v3_Address__fields[3] = {
-  {1, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 2, 11, 1},
-  {2, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 1, 11, 1},
-  {3, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 11, 1},
+  {1, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 2, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 1, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_Address_msginit = {
   &envoy_config_core_v3_Address_submsgs[0],
   &envoy_config_core_v3_Address__fields[0],
-  UPB_SIZE(8, 16), 3, false, 255,
+  UPB_SIZE(8, 16), 3, false, 3, 255,
 };
 
 static const upb_msglayout *const envoy_config_core_v3_CidrRange_submsgs[1] = {
@@ -110,14 +110,14 @@ static const upb_msglayout *const envoy_config_core_v3_CidrRange_submsgs[1] = {
 };
 
 static const upb_msglayout_field envoy_config_core_v3_CidrRange__fields[2] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(12, 24), 1, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(12, 24), 1, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_CidrRange_msginit = {
   &envoy_config_core_v3_CidrRange_submsgs[0],
   &envoy_config_core_v3_CidrRange__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 #include "upb/port_undef.inc"
index c8fdbee..cab78ba 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_CONFIG_CORE_V3_ADDRESS_PROTO_UPB_H_
 #define ENVOY_CONFIG_CORE_V3_ADDRESS_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -62,13 +62,19 @@ UPB_INLINE envoy_config_core_v3_Pipe *envoy_config_core_v3_Pipe_new(upb_arena *a
 UPB_INLINE envoy_config_core_v3_Pipe *envoy_config_core_v3_Pipe_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_Pipe *ret = envoy_config_core_v3_Pipe_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_Pipe_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_Pipe_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_Pipe *envoy_config_core_v3_Pipe_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_Pipe *ret = envoy_config_core_v3_Pipe_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_Pipe_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_Pipe_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_Pipe_serialize(const envoy_config_core_v3_Pipe *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_Pipe_msginit, arena, len);
@@ -92,13 +98,19 @@ UPB_INLINE envoy_config_core_v3_EnvoyInternalAddress *envoy_config_core_v3_Envoy
 UPB_INLINE envoy_config_core_v3_EnvoyInternalAddress *envoy_config_core_v3_EnvoyInternalAddress_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_EnvoyInternalAddress *ret = envoy_config_core_v3_EnvoyInternalAddress_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_EnvoyInternalAddress_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_EnvoyInternalAddress_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_EnvoyInternalAddress *envoy_config_core_v3_EnvoyInternalAddress_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_EnvoyInternalAddress *ret = envoy_config_core_v3_EnvoyInternalAddress_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_EnvoyInternalAddress_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_EnvoyInternalAddress_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_EnvoyInternalAddress_serialize(const envoy_config_core_v3_EnvoyInternalAddress *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_EnvoyInternalAddress_msginit, arena, len);
@@ -125,13 +137,19 @@ UPB_INLINE envoy_config_core_v3_SocketAddress *envoy_config_core_v3_SocketAddres
 UPB_INLINE envoy_config_core_v3_SocketAddress *envoy_config_core_v3_SocketAddress_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_SocketAddress *ret = envoy_config_core_v3_SocketAddress_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_SocketAddress_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_SocketAddress_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_SocketAddress *envoy_config_core_v3_SocketAddress_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_SocketAddress *ret = envoy_config_core_v3_SocketAddress_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_SocketAddress_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_SocketAddress_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_SocketAddress_serialize(const envoy_config_core_v3_SocketAddress *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_SocketAddress_msginit, arena, len);
@@ -180,13 +198,19 @@ UPB_INLINE envoy_config_core_v3_TcpKeepalive *envoy_config_core_v3_TcpKeepalive_
 UPB_INLINE envoy_config_core_v3_TcpKeepalive *envoy_config_core_v3_TcpKeepalive_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_TcpKeepalive *ret = envoy_config_core_v3_TcpKeepalive_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_TcpKeepalive_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_TcpKeepalive_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_TcpKeepalive *envoy_config_core_v3_TcpKeepalive_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_TcpKeepalive *ret = envoy_config_core_v3_TcpKeepalive_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_TcpKeepalive_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_TcpKeepalive_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_TcpKeepalive_serialize(const envoy_config_core_v3_TcpKeepalive *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_TcpKeepalive_msginit, arena, len);
@@ -247,13 +271,19 @@ UPB_INLINE envoy_config_core_v3_BindConfig *envoy_config_core_v3_BindConfig_new(
 UPB_INLINE envoy_config_core_v3_BindConfig *envoy_config_core_v3_BindConfig_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_BindConfig *ret = envoy_config_core_v3_BindConfig_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_BindConfig_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_BindConfig_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_BindConfig *envoy_config_core_v3_BindConfig_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_BindConfig *ret = envoy_config_core_v3_BindConfig_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_BindConfig_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_BindConfig_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_BindConfig_serialize(const envoy_config_core_v3_BindConfig *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_BindConfig_msginit, arena, len);
@@ -314,13 +344,19 @@ UPB_INLINE envoy_config_core_v3_Address *envoy_config_core_v3_Address_new(upb_ar
 UPB_INLINE envoy_config_core_v3_Address *envoy_config_core_v3_Address_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_Address *ret = envoy_config_core_v3_Address_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_Address_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_Address_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_Address *envoy_config_core_v3_Address_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_Address *ret = envoy_config_core_v3_Address_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_Address_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_Address_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_Address_serialize(const envoy_config_core_v3_Address *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_Address_msginit, arena, len);
@@ -386,13 +422,19 @@ UPB_INLINE envoy_config_core_v3_CidrRange *envoy_config_core_v3_CidrRange_new(up
 UPB_INLINE envoy_config_core_v3_CidrRange *envoy_config_core_v3_CidrRange_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_CidrRange *ret = envoy_config_core_v3_CidrRange_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_CidrRange_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_CidrRange_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_CidrRange *envoy_config_core_v3_CidrRange_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_CidrRange *ret = envoy_config_core_v3_CidrRange_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_CidrRange_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_CidrRange_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_CidrRange_serialize(const envoy_config_core_v3_CidrRange *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_CidrRange_msginit, arena, len);
index 8e1174d..95c1b37 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/config/core/v3/backoff.upb.h"
 #include "google/protobuf/duration.upb.h"
 #include "udpa/annotations/status.upb.h"
@@ -21,14 +21,14 @@ static const upb_msglayout *const envoy_config_core_v3_BackoffStrategy_submsgs[1
 };
 
 static const upb_msglayout_field envoy_config_core_v3_BackoffStrategy__fields[2] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
-  {2, UPB_SIZE(8, 16), 2, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 2, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_BackoffStrategy_msginit = {
   &envoy_config_core_v3_BackoffStrategy_submsgs[0],
   &envoy_config_core_v3_BackoffStrategy__fields[0],
-  UPB_SIZE(16, 24), 2, false, 255,
+  UPB_SIZE(16, 24), 2, false, 2, 255,
 };
 
 #include "upb/port_undef.inc"
index 3601c66..3711df0 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_CONFIG_CORE_V3_BACKOFF_PROTO_UPB_H_
 #define ENVOY_CONFIG_CORE_V3_BACKOFF_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -35,13 +35,19 @@ UPB_INLINE envoy_config_core_v3_BackoffStrategy *envoy_config_core_v3_BackoffStr
 UPB_INLINE envoy_config_core_v3_BackoffStrategy *envoy_config_core_v3_BackoffStrategy_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_BackoffStrategy *ret = envoy_config_core_v3_BackoffStrategy_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_BackoffStrategy_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_BackoffStrategy_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_BackoffStrategy *envoy_config_core_v3_BackoffStrategy_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_BackoffStrategy *ret = envoy_config_core_v3_BackoffStrategy_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_BackoffStrategy_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_BackoffStrategy_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_BackoffStrategy_serialize(const envoy_config_core_v3_BackoffStrategy *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_BackoffStrategy_msginit, arena, len);
index e534377..cfb9327 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/config/core/v3/base.upb.h"
 #include "envoy/config/core/v3/address.upb.h"
 #include "envoy/config/core/v3/backoff.upb.h"
 #include "upb/port_def.inc"
 
 static const upb_msglayout_field envoy_config_core_v3_Locality__fields[3] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {2, UPB_SIZE(8, 16), 0, 0, 9, 1},
-  {3, UPB_SIZE(16, 32), 0, 0, 9, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 0, 0, 9, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(16, 32), 0, 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_Locality_msginit = {
   NULL,
   &envoy_config_core_v3_Locality__fields[0],
-  UPB_SIZE(24, 48), 3, false, 255,
+  UPB_SIZE(24, 48), 3, false, 3, 255,
 };
 
 static const upb_msglayout *const envoy_config_core_v3_BuildVersion_submsgs[2] = {
@@ -44,14 +44,14 @@ static const upb_msglayout *const envoy_config_core_v3_BuildVersion_submsgs[2] =
 };
 
 static const upb_msglayout_field envoy_config_core_v3_BuildVersion__fields[2] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
-  {2, UPB_SIZE(8, 16), 2, 1, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 2, 1, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_BuildVersion_msginit = {
   &envoy_config_core_v3_BuildVersion_submsgs[0],
   &envoy_config_core_v3_BuildVersion__fields[0],
-  UPB_SIZE(16, 24), 2, false, 255,
+  UPB_SIZE(16, 24), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_config_core_v3_Extension_submsgs[1] = {
@@ -59,17 +59,17 @@ static const upb_msglayout *const envoy_config_core_v3_Extension_submsgs[1] = {
 };
 
 static const upb_msglayout_field envoy_config_core_v3_Extension__fields[5] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(12, 24), 0, 0, 9, 1},
-  {3, UPB_SIZE(20, 40), 0, 0, 9, 1},
-  {4, UPB_SIZE(28, 56), 1, 0, 11, 1},
-  {5, UPB_SIZE(1, 1), 0, 0, 8, 1},
+  {1, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(12, 24), 0, 0, 9, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(20, 40), 0, 0, 9, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(28, 56), 1, 0, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(1, 1), 0, 0, 8, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_Extension_msginit = {
   &envoy_config_core_v3_Extension_submsgs[0],
   &envoy_config_core_v3_Extension__fields[0],
-  UPB_SIZE(32, 64), 5, false, 255,
+  UPB_SIZE(32, 64), 5, false, 5, 255,
 };
 
 static const upb_msglayout *const envoy_config_core_v3_Node_submsgs[6] = {
@@ -82,23 +82,23 @@ static const upb_msglayout *const envoy_config_core_v3_Node_submsgs[6] = {
 };
 
 static const upb_msglayout_field envoy_config_core_v3_Node__fields[11] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(12, 24), 0, 0, 9, 1},
-  {3, UPB_SIZE(28, 56), 1, 5, 11, 1},
-  {4, UPB_SIZE(32, 64), 2, 3, 11, 1},
-  {6, UPB_SIZE(20, 40), 0, 0, 9, 1},
-  {7, UPB_SIZE(52, 104), UPB_SIZE(-61, -121), 0, 9, 1},
-  {8, UPB_SIZE(52, 104), UPB_SIZE(-61, -121), 1, 11, 1},
-  {9, UPB_SIZE(36, 72), 0, 2, 11, 3},
-  {10, UPB_SIZE(40, 80), 0, 0, 9, 3},
-  {11, UPB_SIZE(44, 88), 0, 0, 11, 3},
-  {12, UPB_SIZE(48, 96), 0, 4, 11, _UPB_LABEL_MAP},
+  {1, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(12, 24), 0, 0, 9, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(28, 56), 1, 5, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(32, 64), 2, 3, 11, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(20, 40), 0, 0, 9, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(52, 104), UPB_SIZE(-61, -121), 0, 9, _UPB_MODE_SCALAR},
+  {8, UPB_SIZE(52, 104), UPB_SIZE(-61, -121), 1, 11, _UPB_MODE_SCALAR},
+  {9, UPB_SIZE(36, 72), 0, 2, 11, _UPB_MODE_ARRAY},
+  {10, UPB_SIZE(40, 80), 0, 0, 9, _UPB_MODE_ARRAY},
+  {11, UPB_SIZE(44, 88), 0, 0, 11, _UPB_MODE_ARRAY},
+  {12, UPB_SIZE(48, 96), 0, 4, 11, _UPB_MODE_MAP},
 };
 
 const upb_msglayout envoy_config_core_v3_Node_msginit = {
   &envoy_config_core_v3_Node_submsgs[0],
   &envoy_config_core_v3_Node__fields[0],
-  UPB_SIZE(64, 128), 11, false, 255,
+  UPB_SIZE(64, 128), 11, false, 4, 255,
 };
 
 static const upb_msglayout *const envoy_config_core_v3_Node_DynamicParametersEntry_submsgs[1] = {
@@ -106,14 +106,14 @@ static const upb_msglayout *const envoy_config_core_v3_Node_DynamicParametersEnt
 };
 
 static const upb_msglayout_field envoy_config_core_v3_Node_DynamicParametersEntry__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {2, UPB_SIZE(8, 16), 0, 0, 11, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 0, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_Node_DynamicParametersEntry_msginit = {
   &envoy_config_core_v3_Node_DynamicParametersEntry_submsgs[0],
   &envoy_config_core_v3_Node_DynamicParametersEntry__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_config_core_v3_Metadata_submsgs[2] = {
@@ -122,14 +122,14 @@ static const upb_msglayout *const envoy_config_core_v3_Metadata_submsgs[2] = {
 };
 
 static const upb_msglayout_field envoy_config_core_v3_Metadata__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 11, _UPB_LABEL_MAP},
-  {2, UPB_SIZE(4, 8), 0, 1, 11, _UPB_LABEL_MAP},
+  {1, UPB_SIZE(0, 0), 0, 0, 11, _UPB_MODE_MAP},
+  {2, UPB_SIZE(4, 8), 0, 1, 11, _UPB_MODE_MAP},
 };
 
 const upb_msglayout envoy_config_core_v3_Metadata_msginit = {
   &envoy_config_core_v3_Metadata_submsgs[0],
   &envoy_config_core_v3_Metadata__fields[0],
-  UPB_SIZE(8, 16), 2, false, 255,
+  UPB_SIZE(8, 16), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_config_core_v3_Metadata_FilterMetadataEntry_submsgs[1] = {
@@ -137,14 +137,14 @@ static const upb_msglayout *const envoy_config_core_v3_Metadata_FilterMetadataEn
 };
 
 static const upb_msglayout_field envoy_config_core_v3_Metadata_FilterMetadataEntry__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {2, UPB_SIZE(8, 16), 0, 0, 11, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 0, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_Metadata_FilterMetadataEntry_msginit = {
   &envoy_config_core_v3_Metadata_FilterMetadataEntry_submsgs[0],
   &envoy_config_core_v3_Metadata_FilterMetadataEntry__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_config_core_v3_Metadata_TypedFilterMetadataEntry_submsgs[1] = {
@@ -152,25 +152,25 @@ static const upb_msglayout *const envoy_config_core_v3_Metadata_TypedFilterMetad
 };
 
 static const upb_msglayout_field envoy_config_core_v3_Metadata_TypedFilterMetadataEntry__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {2, UPB_SIZE(8, 16), 0, 0, 11, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 0, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_Metadata_TypedFilterMetadataEntry_msginit = {
   &envoy_config_core_v3_Metadata_TypedFilterMetadataEntry_submsgs[0],
   &envoy_config_core_v3_Metadata_TypedFilterMetadataEntry__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout_field envoy_config_core_v3_RuntimeUInt32__fields[2] = {
-  {2, UPB_SIZE(0, 0), 0, 0, 13, 1},
-  {3, UPB_SIZE(4, 8), 0, 0, 9, 1},
+  {2, UPB_SIZE(0, 0), 0, 0, 13, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_RuntimeUInt32_msginit = {
   NULL,
   &envoy_config_core_v3_RuntimeUInt32__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 0, 255,
 };
 
 static const upb_msglayout *const envoy_config_core_v3_RuntimePercent_submsgs[1] = {
@@ -178,25 +178,25 @@ static const upb_msglayout *const envoy_config_core_v3_RuntimePercent_submsgs[1]
 };
 
 static const upb_msglayout_field envoy_config_core_v3_RuntimePercent__fields[2] = {
-  {1, UPB_SIZE(12, 24), 1, 0, 11, 1},
-  {2, UPB_SIZE(4, 8), 0, 0, 9, 1},
+  {1, UPB_SIZE(12, 24), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_RuntimePercent_msginit = {
   &envoy_config_core_v3_RuntimePercent_submsgs[0],
   &envoy_config_core_v3_RuntimePercent__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout_field envoy_config_core_v3_RuntimeDouble__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 1, 1},
-  {2, UPB_SIZE(8, 8), 0, 0, 9, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 1, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 8), 0, 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_RuntimeDouble_msginit = {
   NULL,
   &envoy_config_core_v3_RuntimeDouble__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_config_core_v3_RuntimeFeatureFlag_submsgs[1] = {
@@ -204,25 +204,25 @@ static const upb_msglayout *const envoy_config_core_v3_RuntimeFeatureFlag_submsg
 };
 
 static const upb_msglayout_field envoy_config_core_v3_RuntimeFeatureFlag__fields[2] = {
-  {1, UPB_SIZE(12, 24), 1, 0, 11, 1},
-  {2, UPB_SIZE(4, 8), 0, 0, 9, 1},
+  {1, UPB_SIZE(12, 24), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_RuntimeFeatureFlag_msginit = {
   &envoy_config_core_v3_RuntimeFeatureFlag_submsgs[0],
   &envoy_config_core_v3_RuntimeFeatureFlag__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout_field envoy_config_core_v3_HeaderValue__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {2, UPB_SIZE(8, 16), 0, 0, 9, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 0, 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_HeaderValue_msginit = {
   NULL,
   &envoy_config_core_v3_HeaderValue__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_config_core_v3_HeaderValueOption_submsgs[2] = {
@@ -231,14 +231,14 @@ static const upb_msglayout *const envoy_config_core_v3_HeaderValueOption_submsgs
 };
 
 static const upb_msglayout_field envoy_config_core_v3_HeaderValueOption__fields[2] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
-  {2, UPB_SIZE(8, 16), 2, 1, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 2, 1, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_HeaderValueOption_msginit = {
   &envoy_config_core_v3_HeaderValueOption_submsgs[0],
   &envoy_config_core_v3_HeaderValueOption__fields[0],
-  UPB_SIZE(16, 24), 2, false, 255,
+  UPB_SIZE(16, 24), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_config_core_v3_HeaderMap_submsgs[1] = {
@@ -246,35 +246,35 @@ static const upb_msglayout *const envoy_config_core_v3_HeaderMap_submsgs[1] = {
 };
 
 static const upb_msglayout_field envoy_config_core_v3_HeaderMap__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 11, 3},
+  {1, UPB_SIZE(0, 0), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout envoy_config_core_v3_HeaderMap_msginit = {
   &envoy_config_core_v3_HeaderMap_submsgs[0],
   &envoy_config_core_v3_HeaderMap__fields[0],
-  UPB_SIZE(8, 8), 1, false, 255,
+  UPB_SIZE(8, 8), 1, false, 1, 255,
 };
 
 static const upb_msglayout_field envoy_config_core_v3_WatchedDirectory__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_WatchedDirectory_msginit = {
   NULL,
   &envoy_config_core_v3_WatchedDirectory__fields[0],
-  UPB_SIZE(8, 16), 1, false, 255,
+  UPB_SIZE(8, 16), 1, false, 1, 255,
 };
 
 static const upb_msglayout_field envoy_config_core_v3_DataSource__fields[3] = {
-  {1, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 9, 1},
-  {2, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 12, 1},
-  {3, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 9, 1},
+  {1, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 12, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_DataSource_msginit = {
   NULL,
   &envoy_config_core_v3_DataSource__fields[0],
-  UPB_SIZE(16, 32), 3, false, 255,
+  UPB_SIZE(16, 32), 3, false, 3, 255,
 };
 
 static const upb_msglayout *const envoy_config_core_v3_RetryPolicy_submsgs[2] = {
@@ -283,14 +283,14 @@ static const upb_msglayout *const envoy_config_core_v3_RetryPolicy_submsgs[2] =
 };
 
 static const upb_msglayout_field envoy_config_core_v3_RetryPolicy__fields[2] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
-  {2, UPB_SIZE(8, 16), 2, 1, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 2, 1, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_RetryPolicy_msginit = {
   &envoy_config_core_v3_RetryPolicy_submsgs[0],
   &envoy_config_core_v3_RetryPolicy__fields[0],
-  UPB_SIZE(16, 24), 2, false, 255,
+  UPB_SIZE(16, 24), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_config_core_v3_RemoteDataSource_submsgs[2] = {
@@ -299,15 +299,15 @@ static const upb_msglayout *const envoy_config_core_v3_RemoteDataSource_submsgs[
 };
 
 static const upb_msglayout_field envoy_config_core_v3_RemoteDataSource__fields[3] = {
-  {1, UPB_SIZE(12, 24), 1, 0, 11, 1},
-  {2, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {3, UPB_SIZE(16, 32), 2, 1, 11, 1},
+  {1, UPB_SIZE(12, 24), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(16, 32), 2, 1, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_RemoteDataSource_msginit = {
   &envoy_config_core_v3_RemoteDataSource_submsgs[0],
   &envoy_config_core_v3_RemoteDataSource__fields[0],
-  UPB_SIZE(24, 48), 3, false, 255,
+  UPB_SIZE(24, 48), 3, false, 3, 255,
 };
 
 static const upb_msglayout *const envoy_config_core_v3_AsyncDataSource_submsgs[2] = {
@@ -316,14 +316,14 @@ static const upb_msglayout *const envoy_config_core_v3_AsyncDataSource_submsgs[2
 };
 
 static const upb_msglayout_field envoy_config_core_v3_AsyncDataSource__fields[2] = {
-  {1, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 11, 1},
-  {2, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 1, 11, 1},
+  {1, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 1, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_AsyncDataSource_msginit = {
   &envoy_config_core_v3_AsyncDataSource_submsgs[0],
   &envoy_config_core_v3_AsyncDataSource__fields[0],
-  UPB_SIZE(8, 16), 2, false, 255,
+  UPB_SIZE(8, 16), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_config_core_v3_TransportSocket_submsgs[1] = {
@@ -331,14 +331,14 @@ static const upb_msglayout *const envoy_config_core_v3_TransportSocket_submsgs[1
 };
 
 static const upb_msglayout_field envoy_config_core_v3_TransportSocket__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {3, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 0, 11, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_TransportSocket_msginit = {
   &envoy_config_core_v3_TransportSocket_submsgs[0],
   &envoy_config_core_v3_TransportSocket__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 1, 255,
 };
 
 static const upb_msglayout *const envoy_config_core_v3_RuntimeFractionalPercent_submsgs[1] = {
@@ -346,24 +346,24 @@ static const upb_msglayout *const envoy_config_core_v3_RuntimeFractionalPercent_
 };
 
 static const upb_msglayout_field envoy_config_core_v3_RuntimeFractionalPercent__fields[2] = {
-  {1, UPB_SIZE(12, 24), 1, 0, 11, 1},
-  {2, UPB_SIZE(4, 8), 0, 0, 9, 1},
+  {1, UPB_SIZE(12, 24), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_RuntimeFractionalPercent_msginit = {
   &envoy_config_core_v3_RuntimeFractionalPercent_submsgs[0],
   &envoy_config_core_v3_RuntimeFractionalPercent__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout_field envoy_config_core_v3_ControlPlane__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_ControlPlane_msginit = {
   NULL,
   &envoy_config_core_v3_ControlPlane__fields[0],
-  UPB_SIZE(8, 16), 1, false, 255,
+  UPB_SIZE(8, 16), 1, false, 1, 255,
 };
 
 #include "upb/port_undef.inc"
index 043c0b9..8d36c96 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_CONFIG_CORE_V3_BASE_PROTO_UPB_H_
 #define ENVOY_CONFIG_CORE_V3_BASE_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -145,13 +145,19 @@ UPB_INLINE envoy_config_core_v3_Locality *envoy_config_core_v3_Locality_new(upb_
 UPB_INLINE envoy_config_core_v3_Locality *envoy_config_core_v3_Locality_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_Locality *ret = envoy_config_core_v3_Locality_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_Locality_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_Locality_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_Locality *envoy_config_core_v3_Locality_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_Locality *ret = envoy_config_core_v3_Locality_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_Locality_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_Locality_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_Locality_serialize(const envoy_config_core_v3_Locality *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_Locality_msginit, arena, len);
@@ -179,13 +185,19 @@ UPB_INLINE envoy_config_core_v3_BuildVersion *envoy_config_core_v3_BuildVersion_
 UPB_INLINE envoy_config_core_v3_BuildVersion *envoy_config_core_v3_BuildVersion_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_BuildVersion *ret = envoy_config_core_v3_BuildVersion_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_BuildVersion_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_BuildVersion_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_BuildVersion *envoy_config_core_v3_BuildVersion_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_BuildVersion *ret = envoy_config_core_v3_BuildVersion_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_BuildVersion_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_BuildVersion_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_BuildVersion_serialize(const envoy_config_core_v3_BuildVersion *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_BuildVersion_msginit, arena, len);
@@ -231,13 +243,19 @@ UPB_INLINE envoy_config_core_v3_Extension *envoy_config_core_v3_Extension_new(up
 UPB_INLINE envoy_config_core_v3_Extension *envoy_config_core_v3_Extension_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_Extension *ret = envoy_config_core_v3_Extension_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_Extension_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_Extension_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_Extension *envoy_config_core_v3_Extension_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_Extension *ret = envoy_config_core_v3_Extension_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_Extension_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_Extension_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_Extension_serialize(const envoy_config_core_v3_Extension *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_Extension_msginit, arena, len);
@@ -284,13 +302,19 @@ UPB_INLINE envoy_config_core_v3_Node *envoy_config_core_v3_Node_new(upb_arena *a
 UPB_INLINE envoy_config_core_v3_Node *envoy_config_core_v3_Node_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_Node *ret = envoy_config_core_v3_Node_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_Node_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_Node_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_Node *envoy_config_core_v3_Node_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_Node *ret = envoy_config_core_v3_Node_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_Node_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_Node_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_Node_serialize(const envoy_config_core_v3_Node *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_Node_msginit, arena, len);
@@ -441,13 +465,19 @@ UPB_INLINE envoy_config_core_v3_Metadata *envoy_config_core_v3_Metadata_new(upb_
 UPB_INLINE envoy_config_core_v3_Metadata *envoy_config_core_v3_Metadata_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_Metadata *ret = envoy_config_core_v3_Metadata_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_Metadata_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_Metadata_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_Metadata *envoy_config_core_v3_Metadata_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_Metadata *ret = envoy_config_core_v3_Metadata_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_Metadata_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_Metadata_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_Metadata_serialize(const envoy_config_core_v3_Metadata *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_Metadata_msginit, arena, len);
@@ -515,13 +545,19 @@ UPB_INLINE envoy_config_core_v3_RuntimeUInt32 *envoy_config_core_v3_RuntimeUInt3
 UPB_INLINE envoy_config_core_v3_RuntimeUInt32 *envoy_config_core_v3_RuntimeUInt32_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_RuntimeUInt32 *ret = envoy_config_core_v3_RuntimeUInt32_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_RuntimeUInt32_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_RuntimeUInt32_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_RuntimeUInt32 *envoy_config_core_v3_RuntimeUInt32_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_RuntimeUInt32 *ret = envoy_config_core_v3_RuntimeUInt32_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_RuntimeUInt32_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_RuntimeUInt32_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_RuntimeUInt32_serialize(const envoy_config_core_v3_RuntimeUInt32 *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_RuntimeUInt32_msginit, arena, len);
@@ -545,13 +581,19 @@ UPB_INLINE envoy_config_core_v3_RuntimePercent *envoy_config_core_v3_RuntimePerc
 UPB_INLINE envoy_config_core_v3_RuntimePercent *envoy_config_core_v3_RuntimePercent_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_RuntimePercent *ret = envoy_config_core_v3_RuntimePercent_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_RuntimePercent_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_RuntimePercent_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_RuntimePercent *envoy_config_core_v3_RuntimePercent_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_RuntimePercent *ret = envoy_config_core_v3_RuntimePercent_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_RuntimePercent_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_RuntimePercent_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_RuntimePercent_serialize(const envoy_config_core_v3_RuntimePercent *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_RuntimePercent_msginit, arena, len);
@@ -586,13 +628,19 @@ UPB_INLINE envoy_config_core_v3_RuntimeDouble *envoy_config_core_v3_RuntimeDoubl
 UPB_INLINE envoy_config_core_v3_RuntimeDouble *envoy_config_core_v3_RuntimeDouble_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_RuntimeDouble *ret = envoy_config_core_v3_RuntimeDouble_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_RuntimeDouble_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_RuntimeDouble_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_RuntimeDouble *envoy_config_core_v3_RuntimeDouble_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_RuntimeDouble *ret = envoy_config_core_v3_RuntimeDouble_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_RuntimeDouble_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_RuntimeDouble_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_RuntimeDouble_serialize(const envoy_config_core_v3_RuntimeDouble *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_RuntimeDouble_msginit, arena, len);
@@ -616,13 +664,19 @@ UPB_INLINE envoy_config_core_v3_RuntimeFeatureFlag *envoy_config_core_v3_Runtime
 UPB_INLINE envoy_config_core_v3_RuntimeFeatureFlag *envoy_config_core_v3_RuntimeFeatureFlag_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_RuntimeFeatureFlag *ret = envoy_config_core_v3_RuntimeFeatureFlag_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_RuntimeFeatureFlag_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_RuntimeFeatureFlag_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_RuntimeFeatureFlag *envoy_config_core_v3_RuntimeFeatureFlag_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_RuntimeFeatureFlag *ret = envoy_config_core_v3_RuntimeFeatureFlag_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_RuntimeFeatureFlag_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_RuntimeFeatureFlag_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_RuntimeFeatureFlag_serialize(const envoy_config_core_v3_RuntimeFeatureFlag *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_RuntimeFeatureFlag_msginit, arena, len);
@@ -657,13 +711,19 @@ UPB_INLINE envoy_config_core_v3_HeaderValue *envoy_config_core_v3_HeaderValue_ne
 UPB_INLINE envoy_config_core_v3_HeaderValue *envoy_config_core_v3_HeaderValue_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_HeaderValue *ret = envoy_config_core_v3_HeaderValue_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_HeaderValue_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_HeaderValue_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_HeaderValue *envoy_config_core_v3_HeaderValue_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_HeaderValue *ret = envoy_config_core_v3_HeaderValue_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_HeaderValue_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_HeaderValue_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_HeaderValue_serialize(const envoy_config_core_v3_HeaderValue *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_HeaderValue_msginit, arena, len);
@@ -687,13 +747,19 @@ UPB_INLINE envoy_config_core_v3_HeaderValueOption *envoy_config_core_v3_HeaderVa
 UPB_INLINE envoy_config_core_v3_HeaderValueOption *envoy_config_core_v3_HeaderValueOption_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_HeaderValueOption *ret = envoy_config_core_v3_HeaderValueOption_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_HeaderValueOption_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_HeaderValueOption_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_HeaderValueOption *envoy_config_core_v3_HeaderValueOption_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_HeaderValueOption *ret = envoy_config_core_v3_HeaderValueOption_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_HeaderValueOption_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_HeaderValueOption_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_HeaderValueOption_serialize(const envoy_config_core_v3_HeaderValueOption *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_HeaderValueOption_msginit, arena, len);
@@ -739,13 +805,19 @@ UPB_INLINE envoy_config_core_v3_HeaderMap *envoy_config_core_v3_HeaderMap_new(up
 UPB_INLINE envoy_config_core_v3_HeaderMap *envoy_config_core_v3_HeaderMap_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_HeaderMap *ret = envoy_config_core_v3_HeaderMap_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_HeaderMap_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_HeaderMap_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_HeaderMap *envoy_config_core_v3_HeaderMap_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_HeaderMap *ret = envoy_config_core_v3_HeaderMap_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_HeaderMap_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_HeaderMap_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_HeaderMap_serialize(const envoy_config_core_v3_HeaderMap *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_HeaderMap_msginit, arena, len);
@@ -776,13 +848,19 @@ UPB_INLINE envoy_config_core_v3_WatchedDirectory *envoy_config_core_v3_WatchedDi
 UPB_INLINE envoy_config_core_v3_WatchedDirectory *envoy_config_core_v3_WatchedDirectory_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_WatchedDirectory *ret = envoy_config_core_v3_WatchedDirectory_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_WatchedDirectory_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_WatchedDirectory_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_WatchedDirectory *envoy_config_core_v3_WatchedDirectory_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_WatchedDirectory *ret = envoy_config_core_v3_WatchedDirectory_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_WatchedDirectory_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_WatchedDirectory_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_WatchedDirectory_serialize(const envoy_config_core_v3_WatchedDirectory *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_WatchedDirectory_msginit, arena, len);
@@ -802,13 +880,19 @@ UPB_INLINE envoy_config_core_v3_DataSource *envoy_config_core_v3_DataSource_new(
 UPB_INLINE envoy_config_core_v3_DataSource *envoy_config_core_v3_DataSource_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_DataSource *ret = envoy_config_core_v3_DataSource_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_DataSource_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_DataSource_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_DataSource *envoy_config_core_v3_DataSource_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_DataSource *ret = envoy_config_core_v3_DataSource_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_DataSource_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_DataSource_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_DataSource_serialize(const envoy_config_core_v3_DataSource *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_DataSource_msginit, arena, len);
@@ -847,13 +931,19 @@ UPB_INLINE envoy_config_core_v3_RetryPolicy *envoy_config_core_v3_RetryPolicy_ne
 UPB_INLINE envoy_config_core_v3_RetryPolicy *envoy_config_core_v3_RetryPolicy_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_RetryPolicy *ret = envoy_config_core_v3_RetryPolicy_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_RetryPolicy_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_RetryPolicy_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_RetryPolicy *envoy_config_core_v3_RetryPolicy_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_RetryPolicy *ret = envoy_config_core_v3_RetryPolicy_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_RetryPolicy_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_RetryPolicy_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_RetryPolicy_serialize(const envoy_config_core_v3_RetryPolicy *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_RetryPolicy_msginit, arena, len);
@@ -899,13 +989,19 @@ UPB_INLINE envoy_config_core_v3_RemoteDataSource *envoy_config_core_v3_RemoteDat
 UPB_INLINE envoy_config_core_v3_RemoteDataSource *envoy_config_core_v3_RemoteDataSource_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_RemoteDataSource *ret = envoy_config_core_v3_RemoteDataSource_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_RemoteDataSource_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_RemoteDataSource_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_RemoteDataSource *envoy_config_core_v3_RemoteDataSource_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_RemoteDataSource *ret = envoy_config_core_v3_RemoteDataSource_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_RemoteDataSource_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_RemoteDataSource_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_RemoteDataSource_serialize(const envoy_config_core_v3_RemoteDataSource *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_RemoteDataSource_msginit, arena, len);
@@ -955,13 +1051,19 @@ UPB_INLINE envoy_config_core_v3_AsyncDataSource *envoy_config_core_v3_AsyncDataS
 UPB_INLINE envoy_config_core_v3_AsyncDataSource *envoy_config_core_v3_AsyncDataSource_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_AsyncDataSource *ret = envoy_config_core_v3_AsyncDataSource_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_AsyncDataSource_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_AsyncDataSource_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_AsyncDataSource *envoy_config_core_v3_AsyncDataSource_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_AsyncDataSource *ret = envoy_config_core_v3_AsyncDataSource_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_AsyncDataSource_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_AsyncDataSource_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_AsyncDataSource_serialize(const envoy_config_core_v3_AsyncDataSource *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_AsyncDataSource_msginit, arena, len);
@@ -1012,13 +1114,19 @@ UPB_INLINE envoy_config_core_v3_TransportSocket *envoy_config_core_v3_TransportS
 UPB_INLINE envoy_config_core_v3_TransportSocket *envoy_config_core_v3_TransportSocket_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_TransportSocket *ret = envoy_config_core_v3_TransportSocket_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_TransportSocket_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_TransportSocket_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_TransportSocket *envoy_config_core_v3_TransportSocket_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_TransportSocket *ret = envoy_config_core_v3_TransportSocket_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_TransportSocket_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_TransportSocket_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_TransportSocket_serialize(const envoy_config_core_v3_TransportSocket *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_TransportSocket_msginit, arena, len);
@@ -1058,13 +1166,19 @@ UPB_INLINE envoy_config_core_v3_RuntimeFractionalPercent *envoy_config_core_v3_R
 UPB_INLINE envoy_config_core_v3_RuntimeFractionalPercent *envoy_config_core_v3_RuntimeFractionalPercent_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_RuntimeFractionalPercent *ret = envoy_config_core_v3_RuntimeFractionalPercent_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_RuntimeFractionalPercent_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_RuntimeFractionalPercent_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_RuntimeFractionalPercent *envoy_config_core_v3_RuntimeFractionalPercent_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_RuntimeFractionalPercent *ret = envoy_config_core_v3_RuntimeFractionalPercent_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_RuntimeFractionalPercent_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_RuntimeFractionalPercent_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_RuntimeFractionalPercent_serialize(const envoy_config_core_v3_RuntimeFractionalPercent *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_RuntimeFractionalPercent_msginit, arena, len);
@@ -1099,13 +1213,19 @@ UPB_INLINE envoy_config_core_v3_ControlPlane *envoy_config_core_v3_ControlPlane_
 UPB_INLINE envoy_config_core_v3_ControlPlane *envoy_config_core_v3_ControlPlane_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_ControlPlane *ret = envoy_config_core_v3_ControlPlane_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_ControlPlane_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_ControlPlane_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_ControlPlane *envoy_config_core_v3_ControlPlane_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_ControlPlane *ret = envoy_config_core_v3_ControlPlane_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_ControlPlane_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_ControlPlane_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_ControlPlane_serialize(const envoy_config_core_v3_ControlPlane *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_ControlPlane_msginit, arena, len);
index 30a2e75..91daff7 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/config/core/v3/config_source.upb.h"
 #include "envoy/config/core/v3/grpc_service.upb.h"
 #include "google/protobuf/duration.upb.h"
@@ -27,36 +27,36 @@ static const upb_msglayout *const envoy_config_core_v3_ApiConfigSource_submsgs[3
 };
 
 static const upb_msglayout_field envoy_config_core_v3_ApiConfigSource__fields[8] = {
-  {1, UPB_SIZE(4, 4), 0, 0, 14, 1},
-  {2, UPB_SIZE(28, 40), 0, 0, 9, 3},
-  {3, UPB_SIZE(16, 16), 1, 2, 11, 1},
-  {4, UPB_SIZE(32, 48), 0, 0, 11, 3},
-  {5, UPB_SIZE(20, 24), 2, 2, 11, 1},
-  {6, UPB_SIZE(24, 32), 3, 1, 11, 1},
-  {7, UPB_SIZE(12, 12), 0, 0, 8, 1},
-  {8, UPB_SIZE(8, 8), 0, 0, 14, 1},
+  {1, UPB_SIZE(4, 4), 0, 0, 14, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(28, 40), 0, 0, 9, _UPB_MODE_ARRAY},
+  {3, UPB_SIZE(16, 16), 1, 2, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(32, 48), 0, 0, 11, _UPB_MODE_ARRAY},
+  {5, UPB_SIZE(20, 24), 2, 2, 11, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(24, 32), 3, 1, 11, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(12, 12), 0, 0, 8, _UPB_MODE_SCALAR},
+  {8, UPB_SIZE(8, 8), 0, 0, 14, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_ApiConfigSource_msginit = {
   &envoy_config_core_v3_ApiConfigSource_submsgs[0],
   &envoy_config_core_v3_ApiConfigSource__fields[0],
-  UPB_SIZE(40, 56), 8, false, 255,
+  UPB_SIZE(40, 56), 8, false, 8, 255,
 };
 
 const upb_msglayout envoy_config_core_v3_AggregatedConfigSource_msginit = {
   NULL,
   NULL,
-  UPB_SIZE(0, 0), 0, false, 255,
+  UPB_SIZE(0, 0), 0, false, 0, 255,
 };
 
 static const upb_msglayout_field envoy_config_core_v3_SelfConfigSource__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 14, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 14, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_SelfConfigSource_msginit = {
   NULL,
   &envoy_config_core_v3_SelfConfigSource__fields[0],
-  UPB_SIZE(8, 8), 1, false, 255,
+  UPB_SIZE(8, 8), 1, false, 1, 255,
 };
 
 static const upb_msglayout *const envoy_config_core_v3_RateLimitSettings_submsgs[2] = {
@@ -65,14 +65,14 @@ static const upb_msglayout *const envoy_config_core_v3_RateLimitSettings_submsgs
 };
 
 static const upb_msglayout_field envoy_config_core_v3_RateLimitSettings__fields[2] = {
-  {1, UPB_SIZE(4, 8), 1, 1, 11, 1},
-  {2, UPB_SIZE(8, 16), 2, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 1, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 2, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_RateLimitSettings_msginit = {
   &envoy_config_core_v3_RateLimitSettings_submsgs[0],
   &envoy_config_core_v3_RateLimitSettings__fields[0],
-  UPB_SIZE(16, 24), 2, false, 255,
+  UPB_SIZE(16, 24), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_config_core_v3_ConfigSource_submsgs[5] = {
@@ -84,19 +84,19 @@ static const upb_msglayout *const envoy_config_core_v3_ConfigSource_submsgs[5] =
 };
 
 static const upb_msglayout_field envoy_config_core_v3_ConfigSource__fields[7] = {
-  {1, UPB_SIZE(16, 24), UPB_SIZE(-25, -41), 0, 9, 1},
-  {2, UPB_SIZE(16, 24), UPB_SIZE(-25, -41), 1, 11, 1},
-  {3, UPB_SIZE(16, 24), UPB_SIZE(-25, -41), 0, 11, 1},
-  {4, UPB_SIZE(8, 8), 1, 3, 11, 1},
-  {5, UPB_SIZE(16, 24), UPB_SIZE(-25, -41), 2, 11, 1},
-  {6, UPB_SIZE(4, 4), 0, 0, 14, 1},
-  {7, UPB_SIZE(12, 16), 0, 4, 11, 3},
+  {1, UPB_SIZE(16, 24), UPB_SIZE(-25, -41), 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(16, 24), UPB_SIZE(-25, -41), 1, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(16, 24), UPB_SIZE(-25, -41), 0, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(8, 8), 1, 3, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(16, 24), UPB_SIZE(-25, -41), 2, 11, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(4, 4), 0, 0, 14, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(12, 16), 0, 4, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout envoy_config_core_v3_ConfigSource_msginit = {
   &envoy_config_core_v3_ConfigSource_submsgs[0],
   &envoy_config_core_v3_ConfigSource__fields[0],
-  UPB_SIZE(32, 48), 7, false, 255,
+  UPB_SIZE(32, 48), 7, false, 7, 255,
 };
 
 #include "upb/port_undef.inc"
index 1fc8534..3388402 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_CONFIG_CORE_V3_CONFIG_SOURCE_PROTO_UPB_H_
 #define ENVOY_CONFIG_CORE_V3_CONFIG_SOURCE_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -70,13 +70,19 @@ UPB_INLINE envoy_config_core_v3_ApiConfigSource *envoy_config_core_v3_ApiConfigS
 UPB_INLINE envoy_config_core_v3_ApiConfigSource *envoy_config_core_v3_ApiConfigSource_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_ApiConfigSource *ret = envoy_config_core_v3_ApiConfigSource_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_ApiConfigSource_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_ApiConfigSource_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_ApiConfigSource *envoy_config_core_v3_ApiConfigSource_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_ApiConfigSource *ret = envoy_config_core_v3_ApiConfigSource_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_ApiConfigSource_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_ApiConfigSource_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_ApiConfigSource_serialize(const envoy_config_core_v3_ApiConfigSource *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_ApiConfigSource_msginit, arena, len);
@@ -175,13 +181,19 @@ UPB_INLINE envoy_config_core_v3_AggregatedConfigSource *envoy_config_core_v3_Agg
 UPB_INLINE envoy_config_core_v3_AggregatedConfigSource *envoy_config_core_v3_AggregatedConfigSource_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_AggregatedConfigSource *ret = envoy_config_core_v3_AggregatedConfigSource_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_AggregatedConfigSource_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_AggregatedConfigSource_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_AggregatedConfigSource *envoy_config_core_v3_AggregatedConfigSource_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_AggregatedConfigSource *ret = envoy_config_core_v3_AggregatedConfigSource_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_AggregatedConfigSource_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_AggregatedConfigSource_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_AggregatedConfigSource_serialize(const envoy_config_core_v3_AggregatedConfigSource *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_AggregatedConfigSource_msginit, arena, len);
@@ -197,13 +209,19 @@ UPB_INLINE envoy_config_core_v3_SelfConfigSource *envoy_config_core_v3_SelfConfi
 UPB_INLINE envoy_config_core_v3_SelfConfigSource *envoy_config_core_v3_SelfConfigSource_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_SelfConfigSource *ret = envoy_config_core_v3_SelfConfigSource_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_SelfConfigSource_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_SelfConfigSource_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_SelfConfigSource *envoy_config_core_v3_SelfConfigSource_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_SelfConfigSource *ret = envoy_config_core_v3_SelfConfigSource_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_SelfConfigSource_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_SelfConfigSource_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_SelfConfigSource_serialize(const envoy_config_core_v3_SelfConfigSource *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_SelfConfigSource_msginit, arena, len);
@@ -223,13 +241,19 @@ UPB_INLINE envoy_config_core_v3_RateLimitSettings *envoy_config_core_v3_RateLimi
 UPB_INLINE envoy_config_core_v3_RateLimitSettings *envoy_config_core_v3_RateLimitSettings_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_RateLimitSettings *ret = envoy_config_core_v3_RateLimitSettings_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_RateLimitSettings_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_RateLimitSettings_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_RateLimitSettings *envoy_config_core_v3_RateLimitSettings_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_RateLimitSettings *ret = envoy_config_core_v3_RateLimitSettings_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_RateLimitSettings_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_RateLimitSettings_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_RateLimitSettings_serialize(const envoy_config_core_v3_RateLimitSettings *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_RateLimitSettings_msginit, arena, len);
@@ -275,13 +299,19 @@ UPB_INLINE envoy_config_core_v3_ConfigSource *envoy_config_core_v3_ConfigSource_
 UPB_INLINE envoy_config_core_v3_ConfigSource *envoy_config_core_v3_ConfigSource_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_ConfigSource *ret = envoy_config_core_v3_ConfigSource_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_ConfigSource_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_ConfigSource_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_ConfigSource *envoy_config_core_v3_ConfigSource_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_ConfigSource *ret = envoy_config_core_v3_ConfigSource_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_ConfigSource_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_ConfigSource_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_ConfigSource_serialize(const envoy_config_core_v3_ConfigSource *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_ConfigSource_msginit, arena, len);
index 3f89247..9de7ac7 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/config/core/v3/event_service_config.upb.h"
 #include "envoy/config/core/v3/grpc_service.upb.h"
 #include "udpa/annotations/status.upb.h"
@@ -21,13 +21,13 @@ static const upb_msglayout *const envoy_config_core_v3_EventServiceConfig_submsg
 };
 
 static const upb_msglayout_field envoy_config_core_v3_EventServiceConfig__fields[1] = {
-  {1, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 11, 1},
+  {1, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_EventServiceConfig_msginit = {
   &envoy_config_core_v3_EventServiceConfig_submsgs[0],
   &envoy_config_core_v3_EventServiceConfig__fields[0],
-  UPB_SIZE(8, 16), 1, false, 255,
+  UPB_SIZE(8, 16), 1, false, 1, 255,
 };
 
 #include "upb/port_undef.inc"
index 3069f4c..25ae45e 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_CONFIG_CORE_V3_EVENT_SERVICE_CONFIG_PROTO_UPB_H_
 #define ENVOY_CONFIG_CORE_V3_EVENT_SERVICE_CONFIG_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -35,13 +35,19 @@ UPB_INLINE envoy_config_core_v3_EventServiceConfig *envoy_config_core_v3_EventSe
 UPB_INLINE envoy_config_core_v3_EventServiceConfig *envoy_config_core_v3_EventServiceConfig_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_EventServiceConfig *ret = envoy_config_core_v3_EventServiceConfig_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_EventServiceConfig_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_EventServiceConfig_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_EventServiceConfig *envoy_config_core_v3_EventServiceConfig_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_EventServiceConfig *ret = envoy_config_core_v3_EventServiceConfig_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_EventServiceConfig_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_EventServiceConfig_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_EventServiceConfig_serialize(const envoy_config_core_v3_EventServiceConfig *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_EventServiceConfig_msginit, arena, len);
index 47b8b32..beea24a 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/config/core/v3/extension.upb.h"
 #include "envoy/config/core/v3/config_source.upb.h"
 #include "google/protobuf/any.upb.h"
@@ -21,14 +21,14 @@ static const upb_msglayout *const envoy_config_core_v3_TypedExtensionConfig_subm
 };
 
 static const upb_msglayout_field envoy_config_core_v3_TypedExtensionConfig__fields[2] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(12, 24), 1, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(12, 24), 1, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_TypedExtensionConfig_msginit = {
   &envoy_config_core_v3_TypedExtensionConfig_submsgs[0],
   &envoy_config_core_v3_TypedExtensionConfig__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_config_core_v3_ExtensionConfigSource_submsgs[2] = {
@@ -37,16 +37,16 @@ static const upb_msglayout *const envoy_config_core_v3_ExtensionConfigSource_sub
 };
 
 static const upb_msglayout_field envoy_config_core_v3_ExtensionConfigSource__fields[4] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
-  {2, UPB_SIZE(8, 16), 2, 1, 11, 1},
-  {3, UPB_SIZE(1, 1), 0, 0, 8, 1},
-  {4, UPB_SIZE(12, 24), 0, 0, 9, 3},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 2, 1, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(1, 1), 0, 0, 8, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(12, 24), 0, 0, 9, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout envoy_config_core_v3_ExtensionConfigSource_msginit = {
   &envoy_config_core_v3_ExtensionConfigSource_submsgs[0],
   &envoy_config_core_v3_ExtensionConfigSource__fields[0],
-  UPB_SIZE(16, 32), 4, false, 255,
+  UPB_SIZE(16, 32), 4, false, 4, 255,
 };
 
 #include "upb/port_undef.inc"
index 8499bfc..613689c 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_CONFIG_CORE_V3_EXTENSION_PROTO_UPB_H_
 #define ENVOY_CONFIG_CORE_V3_EXTENSION_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -40,13 +40,19 @@ UPB_INLINE envoy_config_core_v3_TypedExtensionConfig *envoy_config_core_v3_Typed
 UPB_INLINE envoy_config_core_v3_TypedExtensionConfig *envoy_config_core_v3_TypedExtensionConfig_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_TypedExtensionConfig *ret = envoy_config_core_v3_TypedExtensionConfig_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_TypedExtensionConfig_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_TypedExtensionConfig_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_TypedExtensionConfig *envoy_config_core_v3_TypedExtensionConfig_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_TypedExtensionConfig *ret = envoy_config_core_v3_TypedExtensionConfig_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_TypedExtensionConfig_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_TypedExtensionConfig_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_TypedExtensionConfig_serialize(const envoy_config_core_v3_TypedExtensionConfig *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_TypedExtensionConfig_msginit, arena, len);
@@ -81,13 +87,19 @@ UPB_INLINE envoy_config_core_v3_ExtensionConfigSource *envoy_config_core_v3_Exte
 UPB_INLINE envoy_config_core_v3_ExtensionConfigSource *envoy_config_core_v3_ExtensionConfigSource_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_ExtensionConfigSource *ret = envoy_config_core_v3_ExtensionConfigSource_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_ExtensionConfigSource_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_ExtensionConfigSource_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_ExtensionConfigSource *envoy_config_core_v3_ExtensionConfigSource_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_ExtensionConfigSource *ret = envoy_config_core_v3_ExtensionConfigSource_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_ExtensionConfigSource_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_ExtensionConfigSource_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_ExtensionConfigSource_serialize(const envoy_config_core_v3_ExtensionConfigSource *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_ExtensionConfigSource_msginit, arena, len);
index b2e99df..478c5ac 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/config/core/v3/grpc_service.upb.h"
 #include "envoy/config/core/v3/base.upb.h"
 #include "google/protobuf/any.upb.h"
@@ -30,27 +30,27 @@ static const upb_msglayout *const envoy_config_core_v3_GrpcService_submsgs[4] =
 };
 
 static const upb_msglayout_field envoy_config_core_v3_GrpcService__fields[4] = {
-  {1, UPB_SIZE(12, 24), UPB_SIZE(-17, -33), 0, 11, 1},
-  {2, UPB_SIZE(12, 24), UPB_SIZE(-17, -33), 1, 11, 1},
-  {3, UPB_SIZE(4, 8), 1, 3, 11, 1},
-  {5, UPB_SIZE(8, 16), 0, 2, 11, 3},
+  {1, UPB_SIZE(12, 24), UPB_SIZE(-17, -33), 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(12, 24), UPB_SIZE(-17, -33), 1, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(4, 8), 1, 3, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(8, 16), 0, 2, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout envoy_config_core_v3_GrpcService_msginit = {
   &envoy_config_core_v3_GrpcService_submsgs[0],
   &envoy_config_core_v3_GrpcService__fields[0],
-  UPB_SIZE(24, 40), 4, false, 255,
+  UPB_SIZE(24, 40), 4, false, 3, 255,
 };
 
 static const upb_msglayout_field envoy_config_core_v3_GrpcService_EnvoyGrpc__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {2, UPB_SIZE(8, 16), 0, 0, 9, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 0, 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_GrpcService_EnvoyGrpc_msginit = {
   NULL,
   &envoy_config_core_v3_GrpcService_EnvoyGrpc__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_config_core_v3_GrpcService_GoogleGrpc_submsgs[5] = {
@@ -62,20 +62,20 @@ static const upb_msglayout *const envoy_config_core_v3_GrpcService_GoogleGrpc_su
 };
 
 static const upb_msglayout_field envoy_config_core_v3_GrpcService_GoogleGrpc__fields[8] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(28, 56), 1, 2, 11, 1},
-  {3, UPB_SIZE(44, 88), 0, 0, 11, 3},
-  {4, UPB_SIZE(12, 24), 0, 0, 9, 1},
-  {5, UPB_SIZE(20, 40), 0, 0, 9, 1},
-  {6, UPB_SIZE(32, 64), 2, 3, 11, 1},
-  {7, UPB_SIZE(36, 72), 3, 4, 11, 1},
-  {8, UPB_SIZE(40, 80), 4, 1, 11, 1},
+  {1, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(28, 56), 1, 2, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(44, 88), 0, 0, 11, _UPB_MODE_ARRAY},
+  {4, UPB_SIZE(12, 24), 0, 0, 9, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(20, 40), 0, 0, 9, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(32, 64), 2, 3, 11, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(36, 72), 3, 4, 11, _UPB_MODE_SCALAR},
+  {8, UPB_SIZE(40, 80), 4, 1, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_GrpcService_GoogleGrpc_msginit = {
   &envoy_config_core_v3_GrpcService_GoogleGrpc_submsgs[0],
   &envoy_config_core_v3_GrpcService_GoogleGrpc__fields[0],
-  UPB_SIZE(48, 96), 8, false, 255,
+  UPB_SIZE(48, 96), 8, false, 8, 255,
 };
 
 static const upb_msglayout *const envoy_config_core_v3_GrpcService_GoogleGrpc_SslCredentials_submsgs[1] = {
@@ -83,21 +83,21 @@ static const upb_msglayout *const envoy_config_core_v3_GrpcService_GoogleGrpc_Ss
 };
 
 static const upb_msglayout_field envoy_config_core_v3_GrpcService_GoogleGrpc_SslCredentials__fields[3] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
-  {2, UPB_SIZE(8, 16), 2, 0, 11, 1},
-  {3, UPB_SIZE(12, 24), 3, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 2, 0, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(12, 24), 3, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_GrpcService_GoogleGrpc_SslCredentials_msginit = {
   &envoy_config_core_v3_GrpcService_GoogleGrpc_SslCredentials_submsgs[0],
   &envoy_config_core_v3_GrpcService_GoogleGrpc_SslCredentials__fields[0],
-  UPB_SIZE(16, 32), 3, false, 255,
+  UPB_SIZE(16, 32), 3, false, 3, 255,
 };
 
 const upb_msglayout envoy_config_core_v3_GrpcService_GoogleGrpc_GoogleLocalCredentials_msginit = {
   NULL,
   NULL,
-  UPB_SIZE(0, 0), 0, false, 255,
+  UPB_SIZE(0, 0), 0, false, 0, 255,
 };
 
 static const upb_msglayout *const envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelCredentials_submsgs[3] = {
@@ -107,15 +107,15 @@ static const upb_msglayout *const envoy_config_core_v3_GrpcService_GoogleGrpc_Ch
 };
 
 static const upb_msglayout_field envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelCredentials__fields[3] = {
-  {1, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 1, 11, 1},
-  {2, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 2, 11, 1},
-  {3, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 11, 1},
+  {1, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 1, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 2, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelCredentials_msginit = {
   &envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelCredentials_submsgs[0],
   &envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelCredentials__fields[0],
-  UPB_SIZE(8, 16), 3, false, 255,
+  UPB_SIZE(8, 16), 3, false, 3, 255,
 };
 
 static const upb_msglayout *const envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_submsgs[5] = {
@@ -127,41 +127,41 @@ static const upb_msglayout *const envoy_config_core_v3_GrpcService_GoogleGrpc_Ca
 };
 
 static const upb_msglayout_field envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials__fields[7] = {
-  {1, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 9, 1},
-  {2, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 4, 11, 1},
-  {3, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 9, 1},
-  {4, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 2, 11, 1},
-  {5, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 11, 1},
-  {6, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 1, 11, 1},
-  {7, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 3, 11, 1},
+  {1, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 4, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 9, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 2, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 11, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 1, 11, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 3, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_msginit = {
   &envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_submsgs[0],
   &envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials__fields[0],
-  UPB_SIZE(16, 32), 7, false, 255,
+  UPB_SIZE(16, 32), 7, false, 7, 255,
 };
 
 static const upb_msglayout_field envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_ServiceAccountJWTAccessCredentials__fields[2] = {
-  {1, UPB_SIZE(8, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(0, 0), 0, 0, 4, 1},
+  {1, UPB_SIZE(8, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(0, 0), 0, 0, 4, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_ServiceAccountJWTAccessCredentials_msginit = {
   NULL,
   &envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_ServiceAccountJWTAccessCredentials__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout_field envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_GoogleIAMCredentials__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {2, UPB_SIZE(8, 16), 0, 0, 9, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 0, 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_GoogleIAMCredentials_msginit = {
   NULL,
   &envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_GoogleIAMCredentials__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_MetadataCredentialsFromPlugin_submsgs[1] = {
@@ -169,32 +169,32 @@ static const upb_msglayout *const envoy_config_core_v3_GrpcService_GoogleGrpc_Ca
 };
 
 static const upb_msglayout_field envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_MetadataCredentialsFromPlugin__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {3, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 0, 11, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_MetadataCredentialsFromPlugin_msginit = {
   &envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_MetadataCredentialsFromPlugin_submsgs[0],
   &envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_MetadataCredentialsFromPlugin__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 1, 255,
 };
 
 static const upb_msglayout_field envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_StsService__fields[9] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {2, UPB_SIZE(8, 16), 0, 0, 9, 1},
-  {3, UPB_SIZE(16, 32), 0, 0, 9, 1},
-  {4, UPB_SIZE(24, 48), 0, 0, 9, 1},
-  {5, UPB_SIZE(32, 64), 0, 0, 9, 1},
-  {6, UPB_SIZE(40, 80), 0, 0, 9, 1},
-  {7, UPB_SIZE(48, 96), 0, 0, 9, 1},
-  {8, UPB_SIZE(56, 112), 0, 0, 9, 1},
-  {9, UPB_SIZE(64, 128), 0, 0, 9, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 0, 0, 9, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(16, 32), 0, 0, 9, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(24, 48), 0, 0, 9, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(32, 64), 0, 0, 9, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(40, 80), 0, 0, 9, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(48, 96), 0, 0, 9, _UPB_MODE_SCALAR},
+  {8, UPB_SIZE(56, 112), 0, 0, 9, _UPB_MODE_SCALAR},
+  {9, UPB_SIZE(64, 128), 0, 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_StsService_msginit = {
   NULL,
   &envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_StsService__fields[0],
-  UPB_SIZE(72, 144), 9, false, 255,
+  UPB_SIZE(72, 144), 9, false, 9, 255,
 };
 
 static const upb_msglayout *const envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelArgs_submsgs[1] = {
@@ -202,24 +202,24 @@ static const upb_msglayout *const envoy_config_core_v3_GrpcService_GoogleGrpc_Ch
 };
 
 static const upb_msglayout_field envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelArgs__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 11, _UPB_LABEL_MAP},
+  {1, UPB_SIZE(0, 0), 0, 0, 11, _UPB_MODE_MAP},
 };
 
 const upb_msglayout envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelArgs_msginit = {
   &envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelArgs_submsgs[0],
   &envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelArgs__fields[0],
-  UPB_SIZE(8, 8), 1, false, 255,
+  UPB_SIZE(8, 8), 1, false, 1, 255,
 };
 
 static const upb_msglayout_field envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelArgs_Value__fields[2] = {
-  {1, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 9, 1},
-  {2, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 3, 1},
+  {1, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 3, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelArgs_Value_msginit = {
   NULL,
   &envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelArgs_Value__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelArgs_ArgsEntry_submsgs[1] = {
@@ -227,14 +227,14 @@ static const upb_msglayout *const envoy_config_core_v3_GrpcService_GoogleGrpc_Ch
 };
 
 static const upb_msglayout_field envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelArgs_ArgsEntry__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {2, UPB_SIZE(8, 16), 0, 0, 11, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 0, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelArgs_ArgsEntry_msginit = {
   &envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelArgs_ArgsEntry_submsgs[0],
   &envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelArgs_ArgsEntry__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 #include "upb/port_undef.inc"
index dd9913d..a59bdf0 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_CONFIG_CORE_V3_GRPC_SERVICE_PROTO_UPB_H_
 #define ENVOY_CONFIG_CORE_V3_GRPC_SERVICE_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -86,13 +86,19 @@ UPB_INLINE envoy_config_core_v3_GrpcService *envoy_config_core_v3_GrpcService_ne
 UPB_INLINE envoy_config_core_v3_GrpcService *envoy_config_core_v3_GrpcService_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_GrpcService *ret = envoy_config_core_v3_GrpcService_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_GrpcService_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_GrpcService_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_GrpcService *envoy_config_core_v3_GrpcService_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_GrpcService *ret = envoy_config_core_v3_GrpcService_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_GrpcService_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_GrpcService_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_GrpcService_serialize(const envoy_config_core_v3_GrpcService *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_GrpcService_msginit, arena, len);
@@ -173,13 +179,19 @@ UPB_INLINE envoy_config_core_v3_GrpcService_EnvoyGrpc *envoy_config_core_v3_Grpc
 UPB_INLINE envoy_config_core_v3_GrpcService_EnvoyGrpc *envoy_config_core_v3_GrpcService_EnvoyGrpc_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_GrpcService_EnvoyGrpc *ret = envoy_config_core_v3_GrpcService_EnvoyGrpc_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_GrpcService_EnvoyGrpc_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_GrpcService_EnvoyGrpc_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_GrpcService_EnvoyGrpc *envoy_config_core_v3_GrpcService_EnvoyGrpc_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_GrpcService_EnvoyGrpc *ret = envoy_config_core_v3_GrpcService_EnvoyGrpc_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_GrpcService_EnvoyGrpc_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_GrpcService_EnvoyGrpc_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_GrpcService_EnvoyGrpc_serialize(const envoy_config_core_v3_GrpcService_EnvoyGrpc *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_GrpcService_EnvoyGrpc_msginit, arena, len);
@@ -203,13 +215,19 @@ UPB_INLINE envoy_config_core_v3_GrpcService_GoogleGrpc *envoy_config_core_v3_Grp
 UPB_INLINE envoy_config_core_v3_GrpcService_GoogleGrpc *envoy_config_core_v3_GrpcService_GoogleGrpc_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_GrpcService_GoogleGrpc *ret = envoy_config_core_v3_GrpcService_GoogleGrpc_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_GrpcService_GoogleGrpc_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_GrpcService_GoogleGrpc_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_GrpcService_GoogleGrpc *envoy_config_core_v3_GrpcService_GoogleGrpc_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_GrpcService_GoogleGrpc *ret = envoy_config_core_v3_GrpcService_GoogleGrpc_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_GrpcService_GoogleGrpc_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_GrpcService_GoogleGrpc_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_GrpcService_GoogleGrpc_serialize(const envoy_config_core_v3_GrpcService_GoogleGrpc *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_GrpcService_GoogleGrpc_msginit, arena, len);
@@ -312,13 +330,19 @@ UPB_INLINE envoy_config_core_v3_GrpcService_GoogleGrpc_SslCredentials *envoy_con
 UPB_INLINE envoy_config_core_v3_GrpcService_GoogleGrpc_SslCredentials *envoy_config_core_v3_GrpcService_GoogleGrpc_SslCredentials_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_GrpcService_GoogleGrpc_SslCredentials *ret = envoy_config_core_v3_GrpcService_GoogleGrpc_SslCredentials_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_GrpcService_GoogleGrpc_SslCredentials_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_GrpcService_GoogleGrpc_SslCredentials_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_GrpcService_GoogleGrpc_SslCredentials *envoy_config_core_v3_GrpcService_GoogleGrpc_SslCredentials_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_GrpcService_GoogleGrpc_SslCredentials *ret = envoy_config_core_v3_GrpcService_GoogleGrpc_SslCredentials_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_GrpcService_GoogleGrpc_SslCredentials_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_GrpcService_GoogleGrpc_SslCredentials_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_GrpcService_GoogleGrpc_SslCredentials_serialize(const envoy_config_core_v3_GrpcService_GoogleGrpc_SslCredentials *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_GrpcService_GoogleGrpc_SslCredentials_msginit, arena, len);
@@ -379,13 +403,19 @@ UPB_INLINE envoy_config_core_v3_GrpcService_GoogleGrpc_GoogleLocalCredentials *e
 UPB_INLINE envoy_config_core_v3_GrpcService_GoogleGrpc_GoogleLocalCredentials *envoy_config_core_v3_GrpcService_GoogleGrpc_GoogleLocalCredentials_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_GrpcService_GoogleGrpc_GoogleLocalCredentials *ret = envoy_config_core_v3_GrpcService_GoogleGrpc_GoogleLocalCredentials_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_GrpcService_GoogleGrpc_GoogleLocalCredentials_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_GrpcService_GoogleGrpc_GoogleLocalCredentials_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_GrpcService_GoogleGrpc_GoogleLocalCredentials *envoy_config_core_v3_GrpcService_GoogleGrpc_GoogleLocalCredentials_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_GrpcService_GoogleGrpc_GoogleLocalCredentials *ret = envoy_config_core_v3_GrpcService_GoogleGrpc_GoogleLocalCredentials_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_GrpcService_GoogleGrpc_GoogleLocalCredentials_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_GrpcService_GoogleGrpc_GoogleLocalCredentials_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_GrpcService_GoogleGrpc_GoogleLocalCredentials_serialize(const envoy_config_core_v3_GrpcService_GoogleGrpc_GoogleLocalCredentials *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_GrpcService_GoogleGrpc_GoogleLocalCredentials_msginit, arena, len);
@@ -401,13 +431,19 @@ UPB_INLINE envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelCredentials *envoy
 UPB_INLINE envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelCredentials *envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelCredentials_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelCredentials *ret = envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelCredentials_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelCredentials_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelCredentials_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelCredentials *envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelCredentials_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelCredentials *ret = envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelCredentials_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelCredentials_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelCredentials_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelCredentials_serialize(const envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelCredentials *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelCredentials_msginit, arena, len);
@@ -473,13 +509,19 @@ UPB_INLINE envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials *envoy_co
 UPB_INLINE envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials *envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials *ret = envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials *envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials *ret = envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_serialize(const envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_msginit, arena, len);
@@ -587,13 +629,19 @@ UPB_INLINE envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_ServiceAc
 UPB_INLINE envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_ServiceAccountJWTAccessCredentials *envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_ServiceAccountJWTAccessCredentials_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_ServiceAccountJWTAccessCredentials *ret = envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_ServiceAccountJWTAccessCredentials_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_ServiceAccountJWTAccessCredentials_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_ServiceAccountJWTAccessCredentials_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_ServiceAccountJWTAccessCredentials *envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_ServiceAccountJWTAccessCredentials_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_ServiceAccountJWTAccessCredentials *ret = envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_ServiceAccountJWTAccessCredentials_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_ServiceAccountJWTAccessCredentials_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_ServiceAccountJWTAccessCredentials_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_ServiceAccountJWTAccessCredentials_serialize(const envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_ServiceAccountJWTAccessCredentials *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_ServiceAccountJWTAccessCredentials_msginit, arena, len);
@@ -617,13 +665,19 @@ UPB_INLINE envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_GoogleIAM
 UPB_INLINE envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_GoogleIAMCredentials *envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_GoogleIAMCredentials_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_GoogleIAMCredentials *ret = envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_GoogleIAMCredentials_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_GoogleIAMCredentials_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_GoogleIAMCredentials_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_GoogleIAMCredentials *envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_GoogleIAMCredentials_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_GoogleIAMCredentials *ret = envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_GoogleIAMCredentials_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_GoogleIAMCredentials_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_GoogleIAMCredentials_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_GoogleIAMCredentials_serialize(const envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_GoogleIAMCredentials *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_GoogleIAMCredentials_msginit, arena, len);
@@ -647,13 +701,19 @@ UPB_INLINE envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_MetadataC
 UPB_INLINE envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_MetadataCredentialsFromPlugin *envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_MetadataCredentialsFromPlugin_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_MetadataCredentialsFromPlugin *ret = envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_MetadataCredentialsFromPlugin_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_MetadataCredentialsFromPlugin_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_MetadataCredentialsFromPlugin_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_MetadataCredentialsFromPlugin *envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_MetadataCredentialsFromPlugin_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_MetadataCredentialsFromPlugin *ret = envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_MetadataCredentialsFromPlugin_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_MetadataCredentialsFromPlugin_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_MetadataCredentialsFromPlugin_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_MetadataCredentialsFromPlugin_serialize(const envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_MetadataCredentialsFromPlugin *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_MetadataCredentialsFromPlugin_msginit, arena, len);
@@ -693,13 +753,19 @@ UPB_INLINE envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_StsServic
 UPB_INLINE envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_StsService *envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_StsService_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_StsService *ret = envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_StsService_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_StsService_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_StsService_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_StsService *envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_StsService_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_StsService *ret = envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_StsService_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_StsService_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_StsService_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_StsService_serialize(const envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_StsService *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_GrpcService_GoogleGrpc_CallCredentials_StsService_msginit, arena, len);
@@ -751,13 +817,19 @@ UPB_INLINE envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelArgs *envoy_config
 UPB_INLINE envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelArgs *envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelArgs_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelArgs *ret = envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelArgs_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelArgs_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelArgs_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelArgs *envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelArgs_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelArgs *ret = envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelArgs_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelArgs_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelArgs_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelArgs_serialize(const envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelArgs *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelArgs_msginit, arena, len);
@@ -781,13 +853,19 @@ UPB_INLINE envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelArgs_Value *envoy_
 UPB_INLINE envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelArgs_Value *envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelArgs_Value_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelArgs_Value *ret = envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelArgs_Value_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelArgs_Value_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelArgs_Value_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelArgs_Value *envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelArgs_Value_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelArgs_Value *ret = envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelArgs_Value_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelArgs_Value_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelArgs_Value_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelArgs_Value_serialize(const envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelArgs_Value *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_GrpcService_GoogleGrpc_ChannelArgs_Value_msginit, arena, len);
index b0a5a64..a1cb228 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/config/core/v3/health_check.upb.h"
 #include "envoy/config/core/v3/base.upb.h"
 #include "envoy/config/core/v3/event_service_config.upb.h"
@@ -38,46 +38,46 @@ static const upb_msglayout *const envoy_config_core_v3_HealthCheck_submsgs[10] =
 };
 
 static const upb_msglayout_field envoy_config_core_v3_HealthCheck__fields[23] = {
-  {1, UPB_SIZE(20, 32), 1, 7, 11, 1},
-  {2, UPB_SIZE(24, 40), 2, 7, 11, 1},
-  {3, UPB_SIZE(28, 48), 3, 7, 11, 1},
-  {4, UPB_SIZE(32, 56), 4, 9, 11, 1},
-  {5, UPB_SIZE(36, 64), 5, 9, 11, 1},
-  {6, UPB_SIZE(40, 72), 6, 9, 11, 1},
-  {7, UPB_SIZE(44, 80), 7, 6, 11, 1},
-  {8, UPB_SIZE(84, 160), UPB_SIZE(-89, -169), 3, 11, 1},
-  {9, UPB_SIZE(84, 160), UPB_SIZE(-89, -169), 4, 11, 1},
-  {11, UPB_SIZE(84, 160), UPB_SIZE(-89, -169), 2, 11, 1},
-  {12, UPB_SIZE(48, 88), 8, 7, 11, 1},
-  {13, UPB_SIZE(84, 160), UPB_SIZE(-89, -169), 1, 11, 1},
-  {14, UPB_SIZE(52, 96), 9, 7, 11, 1},
-  {15, UPB_SIZE(56, 104), 10, 7, 11, 1},
-  {16, UPB_SIZE(60, 112), 11, 7, 11, 1},
-  {17, UPB_SIZE(12, 16), 0, 0, 9, 1},
-  {18, UPB_SIZE(4, 4), 0, 0, 13, 1},
-  {19, UPB_SIZE(8, 8), 0, 0, 8, 1},
-  {20, UPB_SIZE(64, 120), 12, 7, 11, 1},
-  {21, UPB_SIZE(68, 128), 13, 5, 11, 1},
-  {22, UPB_SIZE(72, 136), 14, 0, 11, 1},
-  {23, UPB_SIZE(76, 144), 15, 8, 11, 1},
-  {24, UPB_SIZE(80, 152), 16, 7, 11, 1},
+  {1, UPB_SIZE(20, 32), 1, 7, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(24, 40), 2, 7, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(28, 48), 3, 7, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(32, 56), 4, 9, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(36, 64), 5, 9, 11, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(40, 72), 6, 9, 11, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(44, 80), 7, 6, 11, _UPB_MODE_SCALAR},
+  {8, UPB_SIZE(84, 160), UPB_SIZE(-89, -169), 3, 11, _UPB_MODE_SCALAR},
+  {9, UPB_SIZE(84, 160), UPB_SIZE(-89, -169), 4, 11, _UPB_MODE_SCALAR},
+  {11, UPB_SIZE(84, 160), UPB_SIZE(-89, -169), 2, 11, _UPB_MODE_SCALAR},
+  {12, UPB_SIZE(48, 88), 8, 7, 11, _UPB_MODE_SCALAR},
+  {13, UPB_SIZE(84, 160), UPB_SIZE(-89, -169), 1, 11, _UPB_MODE_SCALAR},
+  {14, UPB_SIZE(52, 96), 9, 7, 11, _UPB_MODE_SCALAR},
+  {15, UPB_SIZE(56, 104), 10, 7, 11, _UPB_MODE_SCALAR},
+  {16, UPB_SIZE(60, 112), 11, 7, 11, _UPB_MODE_SCALAR},
+  {17, UPB_SIZE(12, 16), 0, 0, 9, _UPB_MODE_SCALAR},
+  {18, UPB_SIZE(4, 4), 0, 0, 13, _UPB_MODE_SCALAR},
+  {19, UPB_SIZE(8, 8), 0, 0, 8, _UPB_MODE_SCALAR},
+  {20, UPB_SIZE(64, 120), 12, 7, 11, _UPB_MODE_SCALAR},
+  {21, UPB_SIZE(68, 128), 13, 5, 11, _UPB_MODE_SCALAR},
+  {22, UPB_SIZE(72, 136), 14, 0, 11, _UPB_MODE_SCALAR},
+  {23, UPB_SIZE(76, 144), 15, 8, 11, _UPB_MODE_SCALAR},
+  {24, UPB_SIZE(80, 152), 16, 7, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_HealthCheck_msginit = {
   &envoy_config_core_v3_HealthCheck_submsgs[0],
   &envoy_config_core_v3_HealthCheck__fields[0],
-  UPB_SIZE(96, 176), 23, false, 255,
+  UPB_SIZE(96, 176), 23, false, 9, 255,
 };
 
 static const upb_msglayout_field envoy_config_core_v3_HealthCheck_Payload__fields[2] = {
-  {1, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 9, 1},
-  {2, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 12, 1},
+  {1, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 12, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_HealthCheck_Payload_msginit = {
   NULL,
   &envoy_config_core_v3_HealthCheck_Payload__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_config_core_v3_HealthCheck_HttpHealthCheck_submsgs[4] = {
@@ -88,21 +88,21 @@ static const upb_msglayout *const envoy_config_core_v3_HealthCheck_HttpHealthChe
 };
 
 static const upb_msglayout_field envoy_config_core_v3_HealthCheck_HttpHealthCheck__fields[9] = {
-  {1, UPB_SIZE(8, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(16, 24), 0, 0, 9, 1},
-  {3, UPB_SIZE(24, 40), 1, 1, 11, 1},
-  {4, UPB_SIZE(28, 48), 2, 1, 11, 1},
-  {6, UPB_SIZE(36, 64), 0, 0, 11, 3},
-  {8, UPB_SIZE(40, 72), 0, 0, 9, 3},
-  {9, UPB_SIZE(44, 80), 0, 3, 11, 3},
-  {10, UPB_SIZE(4, 4), 0, 0, 14, 1},
-  {11, UPB_SIZE(32, 56), 3, 2, 11, 1},
+  {1, UPB_SIZE(8, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(16, 24), 0, 0, 9, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(24, 40), 1, 1, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(28, 48), 2, 1, 11, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(36, 64), 0, 0, 11, _UPB_MODE_ARRAY},
+  {8, UPB_SIZE(40, 72), 0, 0, 9, _UPB_MODE_ARRAY},
+  {9, UPB_SIZE(44, 80), 0, 3, 11, _UPB_MODE_ARRAY},
+  {10, UPB_SIZE(4, 4), 0, 0, 14, _UPB_MODE_SCALAR},
+  {11, UPB_SIZE(32, 56), 3, 2, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_HealthCheck_HttpHealthCheck_msginit = {
   &envoy_config_core_v3_HealthCheck_HttpHealthCheck_submsgs[0],
   &envoy_config_core_v3_HealthCheck_HttpHealthCheck__fields[0],
-  UPB_SIZE(48, 96), 9, false, 255,
+  UPB_SIZE(48, 96), 9, false, 4, 255,
 };
 
 static const upb_msglayout *const envoy_config_core_v3_HealthCheck_TcpHealthCheck_submsgs[1] = {
@@ -110,35 +110,35 @@ static const upb_msglayout *const envoy_config_core_v3_HealthCheck_TcpHealthChec
 };
 
 static const upb_msglayout_field envoy_config_core_v3_HealthCheck_TcpHealthCheck__fields[2] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
-  {2, UPB_SIZE(8, 16), 0, 0, 11, 3},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout envoy_config_core_v3_HealthCheck_TcpHealthCheck_msginit = {
   &envoy_config_core_v3_HealthCheck_TcpHealthCheck_submsgs[0],
   &envoy_config_core_v3_HealthCheck_TcpHealthCheck__fields[0],
-  UPB_SIZE(16, 24), 2, false, 255,
+  UPB_SIZE(16, 24), 2, false, 2, 255,
 };
 
 static const upb_msglayout_field envoy_config_core_v3_HealthCheck_RedisHealthCheck__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_HealthCheck_RedisHealthCheck_msginit = {
   NULL,
   &envoy_config_core_v3_HealthCheck_RedisHealthCheck__fields[0],
-  UPB_SIZE(8, 16), 1, false, 255,
+  UPB_SIZE(8, 16), 1, false, 1, 255,
 };
 
 static const upb_msglayout_field envoy_config_core_v3_HealthCheck_GrpcHealthCheck__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {2, UPB_SIZE(8, 16), 0, 0, 9, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 0, 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_HealthCheck_GrpcHealthCheck_msginit = {
   NULL,
   &envoy_config_core_v3_HealthCheck_GrpcHealthCheck__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_config_core_v3_HealthCheck_CustomHealthCheck_submsgs[1] = {
@@ -146,24 +146,24 @@ static const upb_msglayout *const envoy_config_core_v3_HealthCheck_CustomHealthC
 };
 
 static const upb_msglayout_field envoy_config_core_v3_HealthCheck_CustomHealthCheck__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {3, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 0, 11, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_HealthCheck_CustomHealthCheck_msginit = {
   &envoy_config_core_v3_HealthCheck_CustomHealthCheck_submsgs[0],
   &envoy_config_core_v3_HealthCheck_CustomHealthCheck__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 1, 255,
 };
 
 static const upb_msglayout_field envoy_config_core_v3_HealthCheck_TlsOptions__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 3},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout envoy_config_core_v3_HealthCheck_TlsOptions_msginit = {
   NULL,
   &envoy_config_core_v3_HealthCheck_TlsOptions__fields[0],
-  UPB_SIZE(8, 8), 1, false, 255,
+  UPB_SIZE(8, 8), 1, false, 1, 255,
 };
 
 #include "upb/port_undef.inc"
index e4a803a..cc8b0f0 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_CONFIG_CORE_V3_HEALTH_CHECK_PROTO_UPB_H_
 #define ENVOY_CONFIG_CORE_V3_HEALTH_CHECK_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -81,13 +81,19 @@ UPB_INLINE envoy_config_core_v3_HealthCheck *envoy_config_core_v3_HealthCheck_ne
 UPB_INLINE envoy_config_core_v3_HealthCheck *envoy_config_core_v3_HealthCheck_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_HealthCheck *ret = envoy_config_core_v3_HealthCheck_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_HealthCheck_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_HealthCheck_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_HealthCheck *envoy_config_core_v3_HealthCheck_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_HealthCheck *ret = envoy_config_core_v3_HealthCheck_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_HealthCheck_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_HealthCheck_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_HealthCheck_serialize(const envoy_config_core_v3_HealthCheck *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_HealthCheck_msginit, arena, len);
@@ -420,13 +426,19 @@ UPB_INLINE envoy_config_core_v3_HealthCheck_Payload *envoy_config_core_v3_Health
 UPB_INLINE envoy_config_core_v3_HealthCheck_Payload *envoy_config_core_v3_HealthCheck_Payload_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_HealthCheck_Payload *ret = envoy_config_core_v3_HealthCheck_Payload_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_HealthCheck_Payload_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_HealthCheck_Payload_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_HealthCheck_Payload *envoy_config_core_v3_HealthCheck_Payload_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_HealthCheck_Payload *ret = envoy_config_core_v3_HealthCheck_Payload_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_HealthCheck_Payload_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_HealthCheck_Payload_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_HealthCheck_Payload_serialize(const envoy_config_core_v3_HealthCheck_Payload *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_HealthCheck_Payload_msginit, arena, len);
@@ -459,13 +471,19 @@ UPB_INLINE envoy_config_core_v3_HealthCheck_HttpHealthCheck *envoy_config_core_v
 UPB_INLINE envoy_config_core_v3_HealthCheck_HttpHealthCheck *envoy_config_core_v3_HealthCheck_HttpHealthCheck_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_HealthCheck_HttpHealthCheck *ret = envoy_config_core_v3_HealthCheck_HttpHealthCheck_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_HealthCheck_HttpHealthCheck_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_HealthCheck_HttpHealthCheck_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_HealthCheck_HttpHealthCheck *envoy_config_core_v3_HealthCheck_HttpHealthCheck_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_HealthCheck_HttpHealthCheck *ret = envoy_config_core_v3_HealthCheck_HttpHealthCheck_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_HealthCheck_HttpHealthCheck_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_HealthCheck_HttpHealthCheck_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_HealthCheck_HttpHealthCheck_serialize(const envoy_config_core_v3_HealthCheck_HttpHealthCheck *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_HealthCheck_HttpHealthCheck_msginit, arena, len);
@@ -579,13 +597,19 @@ UPB_INLINE envoy_config_core_v3_HealthCheck_TcpHealthCheck *envoy_config_core_v3
 UPB_INLINE envoy_config_core_v3_HealthCheck_TcpHealthCheck *envoy_config_core_v3_HealthCheck_TcpHealthCheck_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_HealthCheck_TcpHealthCheck *ret = envoy_config_core_v3_HealthCheck_TcpHealthCheck_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_HealthCheck_TcpHealthCheck_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_HealthCheck_TcpHealthCheck_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_HealthCheck_TcpHealthCheck *envoy_config_core_v3_HealthCheck_TcpHealthCheck_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_HealthCheck_TcpHealthCheck *ret = envoy_config_core_v3_HealthCheck_TcpHealthCheck_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_HealthCheck_TcpHealthCheck_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_HealthCheck_TcpHealthCheck_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_HealthCheck_TcpHealthCheck_serialize(const envoy_config_core_v3_HealthCheck_TcpHealthCheck *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_HealthCheck_TcpHealthCheck_msginit, arena, len);
@@ -631,13 +655,19 @@ UPB_INLINE envoy_config_core_v3_HealthCheck_RedisHealthCheck *envoy_config_core_
 UPB_INLINE envoy_config_core_v3_HealthCheck_RedisHealthCheck *envoy_config_core_v3_HealthCheck_RedisHealthCheck_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_HealthCheck_RedisHealthCheck *ret = envoy_config_core_v3_HealthCheck_RedisHealthCheck_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_HealthCheck_RedisHealthCheck_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_HealthCheck_RedisHealthCheck_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_HealthCheck_RedisHealthCheck *envoy_config_core_v3_HealthCheck_RedisHealthCheck_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_HealthCheck_RedisHealthCheck *ret = envoy_config_core_v3_HealthCheck_RedisHealthCheck_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_HealthCheck_RedisHealthCheck_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_HealthCheck_RedisHealthCheck_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_HealthCheck_RedisHealthCheck_serialize(const envoy_config_core_v3_HealthCheck_RedisHealthCheck *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_HealthCheck_RedisHealthCheck_msginit, arena, len);
@@ -657,13 +687,19 @@ UPB_INLINE envoy_config_core_v3_HealthCheck_GrpcHealthCheck *envoy_config_core_v
 UPB_INLINE envoy_config_core_v3_HealthCheck_GrpcHealthCheck *envoy_config_core_v3_HealthCheck_GrpcHealthCheck_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_HealthCheck_GrpcHealthCheck *ret = envoy_config_core_v3_HealthCheck_GrpcHealthCheck_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_HealthCheck_GrpcHealthCheck_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_HealthCheck_GrpcHealthCheck_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_HealthCheck_GrpcHealthCheck *envoy_config_core_v3_HealthCheck_GrpcHealthCheck_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_HealthCheck_GrpcHealthCheck *ret = envoy_config_core_v3_HealthCheck_GrpcHealthCheck_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_HealthCheck_GrpcHealthCheck_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_HealthCheck_GrpcHealthCheck_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_HealthCheck_GrpcHealthCheck_serialize(const envoy_config_core_v3_HealthCheck_GrpcHealthCheck *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_HealthCheck_GrpcHealthCheck_msginit, arena, len);
@@ -687,13 +723,19 @@ UPB_INLINE envoy_config_core_v3_HealthCheck_CustomHealthCheck *envoy_config_core
 UPB_INLINE envoy_config_core_v3_HealthCheck_CustomHealthCheck *envoy_config_core_v3_HealthCheck_CustomHealthCheck_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_HealthCheck_CustomHealthCheck *ret = envoy_config_core_v3_HealthCheck_CustomHealthCheck_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_HealthCheck_CustomHealthCheck_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_HealthCheck_CustomHealthCheck_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_HealthCheck_CustomHealthCheck *envoy_config_core_v3_HealthCheck_CustomHealthCheck_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_HealthCheck_CustomHealthCheck *ret = envoy_config_core_v3_HealthCheck_CustomHealthCheck_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_HealthCheck_CustomHealthCheck_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_HealthCheck_CustomHealthCheck_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_HealthCheck_CustomHealthCheck_serialize(const envoy_config_core_v3_HealthCheck_CustomHealthCheck *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_HealthCheck_CustomHealthCheck_msginit, arena, len);
@@ -733,13 +775,19 @@ UPB_INLINE envoy_config_core_v3_HealthCheck_TlsOptions *envoy_config_core_v3_Hea
 UPB_INLINE envoy_config_core_v3_HealthCheck_TlsOptions *envoy_config_core_v3_HealthCheck_TlsOptions_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_HealthCheck_TlsOptions *ret = envoy_config_core_v3_HealthCheck_TlsOptions_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_HealthCheck_TlsOptions_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_HealthCheck_TlsOptions_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_HealthCheck_TlsOptions *envoy_config_core_v3_HealthCheck_TlsOptions_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_HealthCheck_TlsOptions *ret = envoy_config_core_v3_HealthCheck_TlsOptions_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_HealthCheck_TlsOptions_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_HealthCheck_TlsOptions_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_HealthCheck_TlsOptions_serialize(const envoy_config_core_v3_HealthCheck_TlsOptions *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_HealthCheck_TlsOptions_msginit, arena, len);
index c39ebef..840f6a8 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/config/core/v3/http_uri.upb.h"
 #include "google/protobuf/duration.upb.h"
 #include "udpa/annotations/status.upb.h"
@@ -21,15 +21,15 @@ static const upb_msglayout *const envoy_config_core_v3_HttpUri_submsgs[1] = {
 };
 
 static const upb_msglayout_field envoy_config_core_v3_HttpUri__fields[3] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(16, 32), UPB_SIZE(-25, -49), 0, 9, 1},
-  {3, UPB_SIZE(12, 24), 1, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(16, 32), UPB_SIZE(-25, -49), 0, 9, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(12, 24), 1, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_HttpUri_msginit = {
   &envoy_config_core_v3_HttpUri_submsgs[0],
   &envoy_config_core_v3_HttpUri__fields[0],
-  UPB_SIZE(32, 64), 3, false, 255,
+  UPB_SIZE(32, 64), 3, false, 3, 255,
 };
 
 #include "upb/port_undef.inc"
index c49eec1..3cb1ba2 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_CONFIG_CORE_V3_HTTP_URI_PROTO_UPB_H_
 #define ENVOY_CONFIG_CORE_V3_HTTP_URI_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -35,13 +35,19 @@ UPB_INLINE envoy_config_core_v3_HttpUri *envoy_config_core_v3_HttpUri_new(upb_ar
 UPB_INLINE envoy_config_core_v3_HttpUri *envoy_config_core_v3_HttpUri_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_HttpUri *ret = envoy_config_core_v3_HttpUri_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_HttpUri_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_HttpUri_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_HttpUri *envoy_config_core_v3_HttpUri_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_HttpUri *ret = envoy_config_core_v3_HttpUri_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_HttpUri_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_HttpUri_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_HttpUri_serialize(const envoy_config_core_v3_HttpUri *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_HttpUri_msginit, arena, len);
index 827de06..b1f1cd0 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/config/core/v3/protocol.upb.h"
 #include "envoy/config/core/v3/extension.upb.h"
 #include "envoy/type/v3/percent.upb.h"
@@ -23,7 +23,7 @@
 const upb_msglayout envoy_config_core_v3_TcpProtocolOptions_msginit = {
   NULL,
   NULL,
-  UPB_SIZE(0, 0), 0, false, 255,
+  UPB_SIZE(0, 0), 0, false, 0, 255,
 };
 
 static const upb_msglayout *const envoy_config_core_v3_QuicProtocolOptions_submsgs[1] = {
@@ -31,26 +31,26 @@ static const upb_msglayout *const envoy_config_core_v3_QuicProtocolOptions_subms
 };
 
 static const upb_msglayout_field envoy_config_core_v3_QuicProtocolOptions__fields[3] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
-  {2, UPB_SIZE(8, 16), 2, 0, 11, 1},
-  {3, UPB_SIZE(12, 24), 3, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 2, 0, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(12, 24), 3, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_QuicProtocolOptions_msginit = {
   &envoy_config_core_v3_QuicProtocolOptions_submsgs[0],
   &envoy_config_core_v3_QuicProtocolOptions__fields[0],
-  UPB_SIZE(16, 32), 3, false, 255,
+  UPB_SIZE(16, 32), 3, false, 3, 255,
 };
 
 static const upb_msglayout_field envoy_config_core_v3_UpstreamHttpProtocolOptions__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 8, 1},
-  {2, UPB_SIZE(1, 1), 0, 0, 8, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 8, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(1, 1), 0, 0, 8, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_UpstreamHttpProtocolOptions_msginit = {
   NULL,
   &envoy_config_core_v3_UpstreamHttpProtocolOptions__fields[0],
-  UPB_SIZE(8, 8), 2, false, 255,
+  UPB_SIZE(8, 8), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_config_core_v3_AlternateProtocolsCacheOptions_submsgs[1] = {
@@ -58,14 +58,14 @@ static const upb_msglayout *const envoy_config_core_v3_AlternateProtocolsCacheOp
 };
 
 static const upb_msglayout_field envoy_config_core_v3_AlternateProtocolsCacheOptions__fields[2] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(12, 24), 1, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(12, 24), 1, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_AlternateProtocolsCacheOptions_msginit = {
   &envoy_config_core_v3_AlternateProtocolsCacheOptions_submsgs[0],
   &envoy_config_core_v3_AlternateProtocolsCacheOptions__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_config_core_v3_HttpProtocolOptions_submsgs[2] = {
@@ -74,18 +74,18 @@ static const upb_msglayout *const envoy_config_core_v3_HttpProtocolOptions_subms
 };
 
 static const upb_msglayout_field envoy_config_core_v3_HttpProtocolOptions__fields[6] = {
-  {1, UPB_SIZE(8, 8), 1, 0, 11, 1},
-  {2, UPB_SIZE(12, 16), 2, 1, 11, 1},
-  {3, UPB_SIZE(16, 24), 3, 0, 11, 1},
-  {4, UPB_SIZE(20, 32), 4, 0, 11, 1},
-  {5, UPB_SIZE(4, 4), 0, 0, 14, 1},
-  {6, UPB_SIZE(24, 40), 5, 1, 11, 1},
+  {1, UPB_SIZE(8, 8), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(12, 16), 2, 1, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(16, 24), 3, 0, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(20, 32), 4, 0, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(4, 4), 0, 0, 14, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(24, 40), 5, 1, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_HttpProtocolOptions_msginit = {
   &envoy_config_core_v3_HttpProtocolOptions_submsgs[0],
   &envoy_config_core_v3_HttpProtocolOptions__fields[0],
-  UPB_SIZE(32, 48), 6, false, 255,
+  UPB_SIZE(32, 48), 6, false, 6, 255,
 };
 
 static const upb_msglayout *const envoy_config_core_v3_Http1ProtocolOptions_submsgs[2] = {
@@ -94,19 +94,19 @@ static const upb_msglayout *const envoy_config_core_v3_Http1ProtocolOptions_subm
 };
 
 static const upb_msglayout_field envoy_config_core_v3_Http1ProtocolOptions__fields[7] = {
-  {1, UPB_SIZE(12, 24), 1, 1, 11, 1},
-  {2, UPB_SIZE(1, 1), 0, 0, 8, 1},
-  {3, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {4, UPB_SIZE(16, 32), 2, 0, 11, 1},
-  {5, UPB_SIZE(2, 2), 0, 0, 8, 1},
-  {6, UPB_SIZE(3, 3), 0, 0, 8, 1},
-  {7, UPB_SIZE(20, 40), 3, 1, 11, 1},
+  {1, UPB_SIZE(12, 24), 1, 1, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(1, 1), 0, 0, 8, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(16, 32), 2, 0, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(2, 2), 0, 0, 8, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(3, 3), 0, 0, 8, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(20, 40), 3, 1, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_Http1ProtocolOptions_msginit = {
   &envoy_config_core_v3_Http1ProtocolOptions_submsgs[0],
   &envoy_config_core_v3_Http1ProtocolOptions__fields[0],
-  UPB_SIZE(24, 48), 7, false, 255,
+  UPB_SIZE(24, 48), 7, false, 7, 255,
 };
 
 static const upb_msglayout *const envoy_config_core_v3_Http1ProtocolOptions_HeaderKeyFormat_submsgs[2] = {
@@ -115,20 +115,20 @@ static const upb_msglayout *const envoy_config_core_v3_Http1ProtocolOptions_Head
 };
 
 static const upb_msglayout_field envoy_config_core_v3_Http1ProtocolOptions_HeaderKeyFormat__fields[2] = {
-  {1, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 11, 1},
-  {8, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 1, 11, 1},
+  {1, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 11, _UPB_MODE_SCALAR},
+  {8, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 1, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_Http1ProtocolOptions_HeaderKeyFormat_msginit = {
   &envoy_config_core_v3_Http1ProtocolOptions_HeaderKeyFormat_submsgs[0],
   &envoy_config_core_v3_Http1ProtocolOptions_HeaderKeyFormat__fields[0],
-  UPB_SIZE(8, 16), 2, false, 255,
+  UPB_SIZE(8, 16), 2, false, 1, 255,
 };
 
 const upb_msglayout envoy_config_core_v3_Http1ProtocolOptions_HeaderKeyFormat_ProperCaseWords_msginit = {
   NULL,
   NULL,
-  UPB_SIZE(0, 0), 0, false, 255,
+  UPB_SIZE(0, 0), 0, false, 0, 255,
 };
 
 static const upb_msglayout *const envoy_config_core_v3_KeepaliveSettings_submsgs[2] = {
@@ -137,16 +137,16 @@ static const upb_msglayout *const envoy_config_core_v3_KeepaliveSettings_submsgs
 };
 
 static const upb_msglayout_field envoy_config_core_v3_KeepaliveSettings__fields[4] = {
-  {1, UPB_SIZE(4, 8), 1, 1, 11, 1},
-  {2, UPB_SIZE(8, 16), 2, 1, 11, 1},
-  {3, UPB_SIZE(12, 24), 3, 0, 11, 1},
-  {4, UPB_SIZE(16, 32), 4, 1, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 1, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 2, 1, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(12, 24), 3, 0, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(16, 32), 4, 1, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_KeepaliveSettings_msginit = {
   &envoy_config_core_v3_KeepaliveSettings_submsgs[0],
   &envoy_config_core_v3_KeepaliveSettings__fields[0],
-  UPB_SIZE(24, 40), 4, false, 255,
+  UPB_SIZE(24, 40), 4, false, 4, 255,
 };
 
 static const upb_msglayout *const envoy_config_core_v3_Http2ProtocolOptions_submsgs[4] = {
@@ -157,27 +157,27 @@ static const upb_msglayout *const envoy_config_core_v3_Http2ProtocolOptions_subm
 };
 
 static const upb_msglayout_field envoy_config_core_v3_Http2ProtocolOptions__fields[15] = {
-  {1, UPB_SIZE(8, 8), 1, 3, 11, 1},
-  {2, UPB_SIZE(12, 16), 2, 3, 11, 1},
-  {3, UPB_SIZE(16, 24), 3, 3, 11, 1},
-  {4, UPB_SIZE(20, 32), 4, 3, 11, 1},
-  {5, UPB_SIZE(2, 2), 0, 0, 8, 1},
-  {6, UPB_SIZE(3, 3), 0, 0, 8, 1},
-  {7, UPB_SIZE(24, 40), 5, 3, 11, 1},
-  {8, UPB_SIZE(28, 48), 6, 3, 11, 1},
-  {9, UPB_SIZE(32, 56), 7, 3, 11, 1},
-  {10, UPB_SIZE(36, 64), 8, 3, 11, 1},
-  {11, UPB_SIZE(40, 72), 9, 3, 11, 1},
-  {12, UPB_SIZE(4, 4), 0, 0, 8, 1},
-  {13, UPB_SIZE(52, 96), 0, 0, 11, 3},
-  {14, UPB_SIZE(44, 80), 10, 2, 11, 1},
-  {15, UPB_SIZE(48, 88), 11, 1, 11, 1},
+  {1, UPB_SIZE(8, 8), 1, 3, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(12, 16), 2, 3, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(16, 24), 3, 3, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(20, 32), 4, 3, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(2, 2), 0, 0, 8, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(3, 3), 0, 0, 8, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(24, 40), 5, 3, 11, _UPB_MODE_SCALAR},
+  {8, UPB_SIZE(28, 48), 6, 3, 11, _UPB_MODE_SCALAR},
+  {9, UPB_SIZE(32, 56), 7, 3, 11, _UPB_MODE_SCALAR},
+  {10, UPB_SIZE(36, 64), 8, 3, 11, _UPB_MODE_SCALAR},
+  {11, UPB_SIZE(40, 72), 9, 3, 11, _UPB_MODE_SCALAR},
+  {12, UPB_SIZE(4, 4), 0, 0, 8, _UPB_MODE_SCALAR},
+  {13, UPB_SIZE(52, 96), 0, 0, 11, _UPB_MODE_ARRAY},
+  {14, UPB_SIZE(44, 80), 10, 2, 11, _UPB_MODE_SCALAR},
+  {15, UPB_SIZE(48, 88), 11, 1, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_Http2ProtocolOptions_msginit = {
   &envoy_config_core_v3_Http2ProtocolOptions_submsgs[0],
   &envoy_config_core_v3_Http2ProtocolOptions__fields[0],
-  UPB_SIZE(56, 104), 15, false, 255,
+  UPB_SIZE(56, 104), 15, false, 15, 255,
 };
 
 static const upb_msglayout *const envoy_config_core_v3_Http2ProtocolOptions_SettingsParameter_submsgs[1] = {
@@ -185,14 +185,14 @@ static const upb_msglayout *const envoy_config_core_v3_Http2ProtocolOptions_Sett
 };
 
 static const upb_msglayout_field envoy_config_core_v3_Http2ProtocolOptions_SettingsParameter__fields[2] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
-  {2, UPB_SIZE(8, 16), 2, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 2, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_Http2ProtocolOptions_SettingsParameter_msginit = {
   &envoy_config_core_v3_Http2ProtocolOptions_SettingsParameter_submsgs[0],
   &envoy_config_core_v3_Http2ProtocolOptions_SettingsParameter__fields[0],
-  UPB_SIZE(16, 24), 2, false, 255,
+  UPB_SIZE(16, 24), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_config_core_v3_GrpcProtocolOptions_submsgs[1] = {
@@ -200,13 +200,13 @@ static const upb_msglayout *const envoy_config_core_v3_GrpcProtocolOptions_subms
 };
 
 static const upb_msglayout_field envoy_config_core_v3_GrpcProtocolOptions__fields[1] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_GrpcProtocolOptions_msginit = {
   &envoy_config_core_v3_GrpcProtocolOptions_submsgs[0],
   &envoy_config_core_v3_GrpcProtocolOptions__fields[0],
-  UPB_SIZE(8, 16), 1, false, 255,
+  UPB_SIZE(8, 16), 1, false, 1, 255,
 };
 
 static const upb_msglayout *const envoy_config_core_v3_Http3ProtocolOptions_submsgs[2] = {
@@ -215,24 +215,24 @@ static const upb_msglayout *const envoy_config_core_v3_Http3ProtocolOptions_subm
 };
 
 static const upb_msglayout_field envoy_config_core_v3_Http3ProtocolOptions__fields[2] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
-  {2, UPB_SIZE(8, 16), 2, 1, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 2, 1, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_Http3ProtocolOptions_msginit = {
   &envoy_config_core_v3_Http3ProtocolOptions_submsgs[0],
   &envoy_config_core_v3_Http3ProtocolOptions__fields[0],
-  UPB_SIZE(16, 24), 2, false, 255,
+  UPB_SIZE(16, 24), 2, false, 2, 255,
 };
 
 static const upb_msglayout_field envoy_config_core_v3_SchemeHeaderTransformation__fields[1] = {
-  {1, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 9, 1},
+  {1, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_SchemeHeaderTransformation_msginit = {
   NULL,
   &envoy_config_core_v3_SchemeHeaderTransformation__fields[0],
-  UPB_SIZE(16, 32), 1, false, 255,
+  UPB_SIZE(16, 32), 1, false, 1, 255,
 };
 
 #include "upb/port_undef.inc"
index 8b277ef..891459b 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_CONFIG_CORE_V3_PROTOCOL_PROTO_UPB_H_
 #define ENVOY_CONFIG_CORE_V3_PROTOCOL_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -88,13 +88,19 @@ UPB_INLINE envoy_config_core_v3_TcpProtocolOptions *envoy_config_core_v3_TcpProt
 UPB_INLINE envoy_config_core_v3_TcpProtocolOptions *envoy_config_core_v3_TcpProtocolOptions_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_TcpProtocolOptions *ret = envoy_config_core_v3_TcpProtocolOptions_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_TcpProtocolOptions_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_TcpProtocolOptions_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_TcpProtocolOptions *envoy_config_core_v3_TcpProtocolOptions_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_TcpProtocolOptions *ret = envoy_config_core_v3_TcpProtocolOptions_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_TcpProtocolOptions_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_TcpProtocolOptions_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_TcpProtocolOptions_serialize(const envoy_config_core_v3_TcpProtocolOptions *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_TcpProtocolOptions_msginit, arena, len);
@@ -110,13 +116,19 @@ UPB_INLINE envoy_config_core_v3_QuicProtocolOptions *envoy_config_core_v3_QuicPr
 UPB_INLINE envoy_config_core_v3_QuicProtocolOptions *envoy_config_core_v3_QuicProtocolOptions_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_QuicProtocolOptions *ret = envoy_config_core_v3_QuicProtocolOptions_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_QuicProtocolOptions_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_QuicProtocolOptions_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_QuicProtocolOptions *envoy_config_core_v3_QuicProtocolOptions_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_QuicProtocolOptions *ret = envoy_config_core_v3_QuicProtocolOptions_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_QuicProtocolOptions_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_QuicProtocolOptions_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_QuicProtocolOptions_serialize(const envoy_config_core_v3_QuicProtocolOptions *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_QuicProtocolOptions_msginit, arena, len);
@@ -177,13 +189,19 @@ UPB_INLINE envoy_config_core_v3_UpstreamHttpProtocolOptions *envoy_config_core_v
 UPB_INLINE envoy_config_core_v3_UpstreamHttpProtocolOptions *envoy_config_core_v3_UpstreamHttpProtocolOptions_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_UpstreamHttpProtocolOptions *ret = envoy_config_core_v3_UpstreamHttpProtocolOptions_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_UpstreamHttpProtocolOptions_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_UpstreamHttpProtocolOptions_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_UpstreamHttpProtocolOptions *envoy_config_core_v3_UpstreamHttpProtocolOptions_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_UpstreamHttpProtocolOptions *ret = envoy_config_core_v3_UpstreamHttpProtocolOptions_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_UpstreamHttpProtocolOptions_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_UpstreamHttpProtocolOptions_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_UpstreamHttpProtocolOptions_serialize(const envoy_config_core_v3_UpstreamHttpProtocolOptions *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_UpstreamHttpProtocolOptions_msginit, arena, len);
@@ -207,13 +225,19 @@ UPB_INLINE envoy_config_core_v3_AlternateProtocolsCacheOptions *envoy_config_cor
 UPB_INLINE envoy_config_core_v3_AlternateProtocolsCacheOptions *envoy_config_core_v3_AlternateProtocolsCacheOptions_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_AlternateProtocolsCacheOptions *ret = envoy_config_core_v3_AlternateProtocolsCacheOptions_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_AlternateProtocolsCacheOptions_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_AlternateProtocolsCacheOptions_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_AlternateProtocolsCacheOptions *envoy_config_core_v3_AlternateProtocolsCacheOptions_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_AlternateProtocolsCacheOptions *ret = envoy_config_core_v3_AlternateProtocolsCacheOptions_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_AlternateProtocolsCacheOptions_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_AlternateProtocolsCacheOptions_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_AlternateProtocolsCacheOptions_serialize(const envoy_config_core_v3_AlternateProtocolsCacheOptions *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_AlternateProtocolsCacheOptions_msginit, arena, len);
@@ -248,13 +272,19 @@ UPB_INLINE envoy_config_core_v3_HttpProtocolOptions *envoy_config_core_v3_HttpPr
 UPB_INLINE envoy_config_core_v3_HttpProtocolOptions *envoy_config_core_v3_HttpProtocolOptions_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_HttpProtocolOptions *ret = envoy_config_core_v3_HttpProtocolOptions_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_HttpProtocolOptions_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_HttpProtocolOptions_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_HttpProtocolOptions *envoy_config_core_v3_HttpProtocolOptions_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_HttpProtocolOptions *ret = envoy_config_core_v3_HttpProtocolOptions_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_HttpProtocolOptions_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_HttpProtocolOptions_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_HttpProtocolOptions_serialize(const envoy_config_core_v3_HttpProtocolOptions *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_HttpProtocolOptions_msginit, arena, len);
@@ -349,13 +379,19 @@ UPB_INLINE envoy_config_core_v3_Http1ProtocolOptions *envoy_config_core_v3_Http1
 UPB_INLINE envoy_config_core_v3_Http1ProtocolOptions *envoy_config_core_v3_Http1ProtocolOptions_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_Http1ProtocolOptions *ret = envoy_config_core_v3_Http1ProtocolOptions_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_Http1ProtocolOptions_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_Http1ProtocolOptions_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_Http1ProtocolOptions *envoy_config_core_v3_Http1ProtocolOptions_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_Http1ProtocolOptions *ret = envoy_config_core_v3_Http1ProtocolOptions_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_Http1ProtocolOptions_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_Http1ProtocolOptions_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_Http1ProtocolOptions_serialize(const envoy_config_core_v3_Http1ProtocolOptions *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_Http1ProtocolOptions_msginit, arena, len);
@@ -432,13 +468,19 @@ UPB_INLINE envoy_config_core_v3_Http1ProtocolOptions_HeaderKeyFormat *envoy_conf
 UPB_INLINE envoy_config_core_v3_Http1ProtocolOptions_HeaderKeyFormat *envoy_config_core_v3_Http1ProtocolOptions_HeaderKeyFormat_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_Http1ProtocolOptions_HeaderKeyFormat *ret = envoy_config_core_v3_Http1ProtocolOptions_HeaderKeyFormat_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_Http1ProtocolOptions_HeaderKeyFormat_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_Http1ProtocolOptions_HeaderKeyFormat_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_Http1ProtocolOptions_HeaderKeyFormat *envoy_config_core_v3_Http1ProtocolOptions_HeaderKeyFormat_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_Http1ProtocolOptions_HeaderKeyFormat *ret = envoy_config_core_v3_Http1ProtocolOptions_HeaderKeyFormat_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_Http1ProtocolOptions_HeaderKeyFormat_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_Http1ProtocolOptions_HeaderKeyFormat_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_Http1ProtocolOptions_HeaderKeyFormat_serialize(const envoy_config_core_v3_Http1ProtocolOptions_HeaderKeyFormat *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_Http1ProtocolOptions_HeaderKeyFormat_msginit, arena, len);
@@ -489,13 +531,19 @@ UPB_INLINE envoy_config_core_v3_Http1ProtocolOptions_HeaderKeyFormat_ProperCaseW
 UPB_INLINE envoy_config_core_v3_Http1ProtocolOptions_HeaderKeyFormat_ProperCaseWords *envoy_config_core_v3_Http1ProtocolOptions_HeaderKeyFormat_ProperCaseWords_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_Http1ProtocolOptions_HeaderKeyFormat_ProperCaseWords *ret = envoy_config_core_v3_Http1ProtocolOptions_HeaderKeyFormat_ProperCaseWords_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_Http1ProtocolOptions_HeaderKeyFormat_ProperCaseWords_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_Http1ProtocolOptions_HeaderKeyFormat_ProperCaseWords_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_Http1ProtocolOptions_HeaderKeyFormat_ProperCaseWords *envoy_config_core_v3_Http1ProtocolOptions_HeaderKeyFormat_ProperCaseWords_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_Http1ProtocolOptions_HeaderKeyFormat_ProperCaseWords *ret = envoy_config_core_v3_Http1ProtocolOptions_HeaderKeyFormat_ProperCaseWords_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_Http1ProtocolOptions_HeaderKeyFormat_ProperCaseWords_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_Http1ProtocolOptions_HeaderKeyFormat_ProperCaseWords_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_Http1ProtocolOptions_HeaderKeyFormat_ProperCaseWords_serialize(const envoy_config_core_v3_Http1ProtocolOptions_HeaderKeyFormat_ProperCaseWords *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_Http1ProtocolOptions_HeaderKeyFormat_ProperCaseWords_msginit, arena, len);
@@ -511,13 +559,19 @@ UPB_INLINE envoy_config_core_v3_KeepaliveSettings *envoy_config_core_v3_Keepaliv
 UPB_INLINE envoy_config_core_v3_KeepaliveSettings *envoy_config_core_v3_KeepaliveSettings_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_KeepaliveSettings *ret = envoy_config_core_v3_KeepaliveSettings_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_KeepaliveSettings_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_KeepaliveSettings_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_KeepaliveSettings *envoy_config_core_v3_KeepaliveSettings_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_KeepaliveSettings *ret = envoy_config_core_v3_KeepaliveSettings_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_KeepaliveSettings_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_KeepaliveSettings_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_KeepaliveSettings_serialize(const envoy_config_core_v3_KeepaliveSettings *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_KeepaliveSettings_msginit, arena, len);
@@ -593,13 +647,19 @@ UPB_INLINE envoy_config_core_v3_Http2ProtocolOptions *envoy_config_core_v3_Http2
 UPB_INLINE envoy_config_core_v3_Http2ProtocolOptions *envoy_config_core_v3_Http2ProtocolOptions_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_Http2ProtocolOptions *ret = envoy_config_core_v3_Http2ProtocolOptions_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_Http2ProtocolOptions_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_Http2ProtocolOptions_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_Http2ProtocolOptions *envoy_config_core_v3_Http2ProtocolOptions_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_Http2ProtocolOptions *ret = envoy_config_core_v3_Http2ProtocolOptions_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_Http2ProtocolOptions_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_Http2ProtocolOptions_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_Http2ProtocolOptions_serialize(const envoy_config_core_v3_Http2ProtocolOptions *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_Http2ProtocolOptions_msginit, arena, len);
@@ -807,13 +867,19 @@ UPB_INLINE envoy_config_core_v3_Http2ProtocolOptions_SettingsParameter *envoy_co
 UPB_INLINE envoy_config_core_v3_Http2ProtocolOptions_SettingsParameter *envoy_config_core_v3_Http2ProtocolOptions_SettingsParameter_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_Http2ProtocolOptions_SettingsParameter *ret = envoy_config_core_v3_Http2ProtocolOptions_SettingsParameter_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_Http2ProtocolOptions_SettingsParameter_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_Http2ProtocolOptions_SettingsParameter_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_Http2ProtocolOptions_SettingsParameter *envoy_config_core_v3_Http2ProtocolOptions_SettingsParameter_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_Http2ProtocolOptions_SettingsParameter *ret = envoy_config_core_v3_Http2ProtocolOptions_SettingsParameter_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_Http2ProtocolOptions_SettingsParameter_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_Http2ProtocolOptions_SettingsParameter_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_Http2ProtocolOptions_SettingsParameter_serialize(const envoy_config_core_v3_Http2ProtocolOptions_SettingsParameter *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_Http2ProtocolOptions_SettingsParameter_msginit, arena, len);
@@ -859,13 +925,19 @@ UPB_INLINE envoy_config_core_v3_GrpcProtocolOptions *envoy_config_core_v3_GrpcPr
 UPB_INLINE envoy_config_core_v3_GrpcProtocolOptions *envoy_config_core_v3_GrpcProtocolOptions_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_GrpcProtocolOptions *ret = envoy_config_core_v3_GrpcProtocolOptions_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_GrpcProtocolOptions_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_GrpcProtocolOptions_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_GrpcProtocolOptions *envoy_config_core_v3_GrpcProtocolOptions_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_GrpcProtocolOptions *ret = envoy_config_core_v3_GrpcProtocolOptions_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_GrpcProtocolOptions_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_GrpcProtocolOptions_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_GrpcProtocolOptions_serialize(const envoy_config_core_v3_GrpcProtocolOptions *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_GrpcProtocolOptions_msginit, arena, len);
@@ -896,13 +968,19 @@ UPB_INLINE envoy_config_core_v3_Http3ProtocolOptions *envoy_config_core_v3_Http3
 UPB_INLINE envoy_config_core_v3_Http3ProtocolOptions *envoy_config_core_v3_Http3ProtocolOptions_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_Http3ProtocolOptions *ret = envoy_config_core_v3_Http3ProtocolOptions_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_Http3ProtocolOptions_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_Http3ProtocolOptions_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_Http3ProtocolOptions *envoy_config_core_v3_Http3ProtocolOptions_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_Http3ProtocolOptions *ret = envoy_config_core_v3_Http3ProtocolOptions_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_Http3ProtocolOptions_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_Http3ProtocolOptions_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_Http3ProtocolOptions_serialize(const envoy_config_core_v3_Http3ProtocolOptions *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_Http3ProtocolOptions_msginit, arena, len);
@@ -948,13 +1026,19 @@ UPB_INLINE envoy_config_core_v3_SchemeHeaderTransformation *envoy_config_core_v3
 UPB_INLINE envoy_config_core_v3_SchemeHeaderTransformation *envoy_config_core_v3_SchemeHeaderTransformation_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_SchemeHeaderTransformation *ret = envoy_config_core_v3_SchemeHeaderTransformation_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_SchemeHeaderTransformation_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_SchemeHeaderTransformation_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_SchemeHeaderTransformation *envoy_config_core_v3_SchemeHeaderTransformation_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_SchemeHeaderTransformation *ret = envoy_config_core_v3_SchemeHeaderTransformation_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_SchemeHeaderTransformation_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_SchemeHeaderTransformation_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_SchemeHeaderTransformation_serialize(const envoy_config_core_v3_SchemeHeaderTransformation *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_SchemeHeaderTransformation_msginit, arena, len);
index 4c56e07..2cf1da3 100644 (file)
@@ -7,20 +7,20 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/config/core/v3/proxy_protocol.upb.h"
 #include "udpa/annotations/status.upb.h"
 
 #include "upb/port_def.inc"
 
 static const upb_msglayout_field envoy_config_core_v3_ProxyProtocolConfig__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 14, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 14, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_ProxyProtocolConfig_msginit = {
   NULL,
   &envoy_config_core_v3_ProxyProtocolConfig__fields[0],
-  UPB_SIZE(8, 8), 1, false, 255,
+  UPB_SIZE(8, 8), 1, false, 1, 255,
 };
 
 #include "upb/port_undef.inc"
index bd56a64..934ea95 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_CONFIG_CORE_V3_PROXY_PROTOCOL_PROTO_UPB_H_
 #define ENVOY_CONFIG_CORE_V3_PROXY_PROTOCOL_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -38,13 +38,19 @@ UPB_INLINE envoy_config_core_v3_ProxyProtocolConfig *envoy_config_core_v3_ProxyP
 UPB_INLINE envoy_config_core_v3_ProxyProtocolConfig *envoy_config_core_v3_ProxyProtocolConfig_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_ProxyProtocolConfig *ret = envoy_config_core_v3_ProxyProtocolConfig_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_ProxyProtocolConfig_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_ProxyProtocolConfig_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_ProxyProtocolConfig *envoy_config_core_v3_ProxyProtocolConfig_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_ProxyProtocolConfig *ret = envoy_config_core_v3_ProxyProtocolConfig_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_ProxyProtocolConfig_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_ProxyProtocolConfig_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_ProxyProtocolConfig_serialize(const envoy_config_core_v3_ProxyProtocolConfig *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_ProxyProtocolConfig_msginit, arena, len);
index 66b8a4e..7712482 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/config/core/v3/resolver.upb.h"
 #include "envoy/config/core/v3/address.upb.h"
 #include "udpa/annotations/status.upb.h"
 #include "upb/port_def.inc"
 
 static const upb_msglayout_field envoy_config_core_v3_DnsResolverOptions__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 8, 1},
-  {2, UPB_SIZE(1, 1), 0, 0, 8, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 8, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(1, 1), 0, 0, 8, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_DnsResolverOptions_msginit = {
   NULL,
   &envoy_config_core_v3_DnsResolverOptions__fields[0],
-  UPB_SIZE(8, 8), 2, false, 255,
+  UPB_SIZE(8, 8), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_config_core_v3_DnsResolutionConfig_submsgs[2] = {
@@ -32,14 +32,14 @@ static const upb_msglayout *const envoy_config_core_v3_DnsResolutionConfig_subms
 };
 
 static const upb_msglayout_field envoy_config_core_v3_DnsResolutionConfig__fields[2] = {
-  {1, UPB_SIZE(8, 16), 0, 0, 11, 3},
-  {2, UPB_SIZE(4, 8), 1, 1, 11, 1},
+  {1, UPB_SIZE(8, 16), 0, 0, 11, _UPB_MODE_ARRAY},
+  {2, UPB_SIZE(4, 8), 1, 1, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_DnsResolutionConfig_msginit = {
   &envoy_config_core_v3_DnsResolutionConfig_submsgs[0],
   &envoy_config_core_v3_DnsResolutionConfig__fields[0],
-  UPB_SIZE(16, 24), 2, false, 255,
+  UPB_SIZE(16, 24), 2, false, 2, 255,
 };
 
 #include "upb/port_undef.inc"
index c86e29e..e5afe57 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_CONFIG_CORE_V3_RESOLVER_PROTO_UPB_H_
 #define ENVOY_CONFIG_CORE_V3_RESOLVER_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -38,13 +38,19 @@ UPB_INLINE envoy_config_core_v3_DnsResolverOptions *envoy_config_core_v3_DnsReso
 UPB_INLINE envoy_config_core_v3_DnsResolverOptions *envoy_config_core_v3_DnsResolverOptions_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_DnsResolverOptions *ret = envoy_config_core_v3_DnsResolverOptions_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_DnsResolverOptions_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_DnsResolverOptions_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_DnsResolverOptions *envoy_config_core_v3_DnsResolverOptions_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_DnsResolverOptions *ret = envoy_config_core_v3_DnsResolverOptions_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_DnsResolverOptions_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_DnsResolverOptions_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_DnsResolverOptions_serialize(const envoy_config_core_v3_DnsResolverOptions *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_DnsResolverOptions_msginit, arena, len);
@@ -68,13 +74,19 @@ UPB_INLINE envoy_config_core_v3_DnsResolutionConfig *envoy_config_core_v3_DnsRes
 UPB_INLINE envoy_config_core_v3_DnsResolutionConfig *envoy_config_core_v3_DnsResolutionConfig_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_DnsResolutionConfig *ret = envoy_config_core_v3_DnsResolutionConfig_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_DnsResolutionConfig_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_DnsResolutionConfig_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_DnsResolutionConfig *envoy_config_core_v3_DnsResolutionConfig_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_DnsResolutionConfig *ret = envoy_config_core_v3_DnsResolutionConfig_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_DnsResolutionConfig_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_DnsResolutionConfig_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_DnsResolutionConfig_serialize(const envoy_config_core_v3_DnsResolutionConfig *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_DnsResolutionConfig_msginit, arena, len);
index d4c2ea1..b90e52d 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/config/core/v3/socket_option.upb.h"
 #include "udpa/annotations/status.upb.h"
 #include "udpa/annotations/versioning.upb.h"
 #include "upb/port_def.inc"
 
 static const upb_msglayout_field envoy_config_core_v3_SocketOption__fields[6] = {
-  {1, UPB_SIZE(20, 24), 0, 0, 9, 1},
-  {2, UPB_SIZE(0, 0), 0, 0, 3, 1},
-  {3, UPB_SIZE(8, 8), 0, 0, 3, 1},
-  {4, UPB_SIZE(32, 40), UPB_SIZE(-41, -57), 0, 3, 1},
-  {5, UPB_SIZE(32, 40), UPB_SIZE(-41, -57), 0, 12, 1},
-  {6, UPB_SIZE(16, 16), 0, 0, 14, 1},
+  {1, UPB_SIZE(20, 24), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(0, 0), 0, 0, 3, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(8, 8), 0, 0, 3, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(32, 40), UPB_SIZE(-41, -57), 0, 3, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(32, 40), UPB_SIZE(-41, -57), 0, 12, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(16, 16), 0, 0, 14, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_SocketOption_msginit = {
   NULL,
   &envoy_config_core_v3_SocketOption__fields[0],
-  UPB_SIZE(48, 64), 6, false, 255,
+  UPB_SIZE(48, 64), 6, false, 6, 255,
 };
 
 #include "upb/port_undef.inc"
index 0347443..1437814 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_CONFIG_CORE_V3_SOCKET_OPTION_PROTO_UPB_H_
 #define ENVOY_CONFIG_CORE_V3_SOCKET_OPTION_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -39,13 +39,19 @@ UPB_INLINE envoy_config_core_v3_SocketOption *envoy_config_core_v3_SocketOption_
 UPB_INLINE envoy_config_core_v3_SocketOption *envoy_config_core_v3_SocketOption_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_SocketOption *ret = envoy_config_core_v3_SocketOption_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_SocketOption_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_SocketOption_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_SocketOption *envoy_config_core_v3_SocketOption_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_SocketOption *ret = envoy_config_core_v3_SocketOption_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_SocketOption_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_SocketOption_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_SocketOption_serialize(const envoy_config_core_v3_SocketOption *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_SocketOption_msginit, arena, len);
index 17c9261..cd4c6d2 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/config/core/v3/substitution_format_string.upb.h"
 #include "envoy/config/core/v3/base.upb.h"
 #include "envoy/config/core/v3/extension.upb.h"
@@ -25,18 +25,18 @@ static const upb_msglayout *const envoy_config_core_v3_SubstitutionFormatString_
 };
 
 static const upb_msglayout_field envoy_config_core_v3_SubstitutionFormatString__fields[6] = {
-  {1, UPB_SIZE(16, 32), UPB_SIZE(-25, -49), 0, 9, 1},
-  {2, UPB_SIZE(16, 32), UPB_SIZE(-25, -49), 2, 11, 1},
-  {3, UPB_SIZE(0, 0), 0, 0, 8, 1},
-  {4, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {5, UPB_SIZE(16, 32), UPB_SIZE(-25, -49), 0, 11, 1},
-  {6, UPB_SIZE(12, 24), 0, 1, 11, 3},
+  {1, UPB_SIZE(16, 32), UPB_SIZE(-25, -49), 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(16, 32), UPB_SIZE(-25, -49), 2, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(0, 0), 0, 0, 8, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(16, 32), UPB_SIZE(-25, -49), 0, 11, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(12, 24), 0, 1, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout envoy_config_core_v3_SubstitutionFormatString_msginit = {
   &envoy_config_core_v3_SubstitutionFormatString_submsgs[0],
   &envoy_config_core_v3_SubstitutionFormatString__fields[0],
-  UPB_SIZE(32, 64), 6, false, 255,
+  UPB_SIZE(32, 64), 6, false, 6, 255,
 };
 
 #include "upb/port_undef.inc"
index 3f450e9..be910ee 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_CONFIG_CORE_V3_SUBSTITUTION_FORMAT_STRING_PROTO_UPB_H_
 #define ENVOY_CONFIG_CORE_V3_SUBSTITUTION_FORMAT_STRING_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -39,13 +39,19 @@ UPB_INLINE envoy_config_core_v3_SubstitutionFormatString *envoy_config_core_v3_S
 UPB_INLINE envoy_config_core_v3_SubstitutionFormatString *envoy_config_core_v3_SubstitutionFormatString_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_SubstitutionFormatString *ret = envoy_config_core_v3_SubstitutionFormatString_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_SubstitutionFormatString_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_SubstitutionFormatString_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_SubstitutionFormatString *envoy_config_core_v3_SubstitutionFormatString_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_SubstitutionFormatString *ret = envoy_config_core_v3_SubstitutionFormatString_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_SubstitutionFormatString_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_SubstitutionFormatString_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_SubstitutionFormatString_serialize(const envoy_config_core_v3_SubstitutionFormatString *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_SubstitutionFormatString_msginit, arena, len);
index cd01106..33bc133 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/config/core/v3/udp_socket_config.upb.h"
 #include "google/protobuf/wrappers.upb.h"
 #include "udpa/annotations/status.upb.h"
@@ -21,14 +21,14 @@ static const upb_msglayout *const envoy_config_core_v3_UdpSocketConfig_submsgs[2
 };
 
 static const upb_msglayout_field envoy_config_core_v3_UdpSocketConfig__fields[2] = {
-  {1, UPB_SIZE(4, 8), 1, 1, 11, 1},
-  {2, UPB_SIZE(8, 16), 2, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 1, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 2, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_core_v3_UdpSocketConfig_msginit = {
   &envoy_config_core_v3_UdpSocketConfig_submsgs[0],
   &envoy_config_core_v3_UdpSocketConfig__fields[0],
-  UPB_SIZE(16, 24), 2, false, 255,
+  UPB_SIZE(16, 24), 2, false, 2, 255,
 };
 
 #include "upb/port_undef.inc"
index e61e18d..b8ab961 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_CONFIG_CORE_V3_UDP_SOCKET_CONFIG_PROTO_UPB_H_
 #define ENVOY_CONFIG_CORE_V3_UDP_SOCKET_CONFIG_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -37,13 +37,19 @@ UPB_INLINE envoy_config_core_v3_UdpSocketConfig *envoy_config_core_v3_UdpSocketC
 UPB_INLINE envoy_config_core_v3_UdpSocketConfig *envoy_config_core_v3_UdpSocketConfig_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_core_v3_UdpSocketConfig *ret = envoy_config_core_v3_UdpSocketConfig_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_UdpSocketConfig_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_core_v3_UdpSocketConfig_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_core_v3_UdpSocketConfig *envoy_config_core_v3_UdpSocketConfig_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_core_v3_UdpSocketConfig *ret = envoy_config_core_v3_UdpSocketConfig_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_UdpSocketConfig_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_core_v3_UdpSocketConfig_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_core_v3_UdpSocketConfig_serialize(const envoy_config_core_v3_UdpSocketConfig *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_core_v3_UdpSocketConfig_msginit, arena, len);
index 3f9c789..ea8353e 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/config/endpoint/v3/endpoint.upb.h"
 #include "envoy/config/endpoint/v3/endpoint_components.upb.h"
 #include "envoy/type/v3/percent.upb.h"
@@ -26,16 +26,16 @@ static const upb_msglayout *const envoy_config_endpoint_v3_ClusterLoadAssignment
 };
 
 static const upb_msglayout_field envoy_config_endpoint_v3_ClusterLoadAssignment__fields[4] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(16, 32), 0, 2, 11, 3},
-  {4, UPB_SIZE(12, 24), 1, 1, 11, 1},
-  {5, UPB_SIZE(20, 40), 0, 0, 11, _UPB_LABEL_MAP},
+  {1, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(16, 32), 0, 2, 11, _UPB_MODE_ARRAY},
+  {4, UPB_SIZE(12, 24), 1, 1, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(20, 40), 0, 0, 11, _UPB_MODE_MAP},
 };
 
 const upb_msglayout envoy_config_endpoint_v3_ClusterLoadAssignment_msginit = {
   &envoy_config_endpoint_v3_ClusterLoadAssignment_submsgs[0],
   &envoy_config_endpoint_v3_ClusterLoadAssignment__fields[0],
-  UPB_SIZE(24, 48), 4, false, 255,
+  UPB_SIZE(24, 48), 4, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_config_endpoint_v3_ClusterLoadAssignment_Policy_submsgs[3] = {
@@ -45,15 +45,15 @@ static const upb_msglayout *const envoy_config_endpoint_v3_ClusterLoadAssignment
 };
 
 static const upb_msglayout_field envoy_config_endpoint_v3_ClusterLoadAssignment_Policy__fields[3] = {
-  {2, UPB_SIZE(12, 24), 0, 0, 11, 3},
-  {3, UPB_SIZE(4, 8), 1, 2, 11, 1},
-  {4, UPB_SIZE(8, 16), 2, 1, 11, 1},
+  {2, UPB_SIZE(12, 24), 0, 0, 11, _UPB_MODE_ARRAY},
+  {3, UPB_SIZE(4, 8), 1, 2, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(8, 16), 2, 1, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_endpoint_v3_ClusterLoadAssignment_Policy_msginit = {
   &envoy_config_endpoint_v3_ClusterLoadAssignment_Policy_submsgs[0],
   &envoy_config_endpoint_v3_ClusterLoadAssignment_Policy__fields[0],
-  UPB_SIZE(16, 32), 3, false, 255,
+  UPB_SIZE(16, 32), 3, false, 0, 255,
 };
 
 static const upb_msglayout *const envoy_config_endpoint_v3_ClusterLoadAssignment_Policy_DropOverload_submsgs[1] = {
@@ -61,14 +61,14 @@ static const upb_msglayout *const envoy_config_endpoint_v3_ClusterLoadAssignment
 };
 
 static const upb_msglayout_field envoy_config_endpoint_v3_ClusterLoadAssignment_Policy_DropOverload__fields[2] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(12, 24), 1, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(12, 24), 1, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_endpoint_v3_ClusterLoadAssignment_Policy_DropOverload_msginit = {
   &envoy_config_endpoint_v3_ClusterLoadAssignment_Policy_DropOverload_submsgs[0],
   &envoy_config_endpoint_v3_ClusterLoadAssignment_Policy_DropOverload__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_config_endpoint_v3_ClusterLoadAssignment_NamedEndpointsEntry_submsgs[1] = {
@@ -76,14 +76,14 @@ static const upb_msglayout *const envoy_config_endpoint_v3_ClusterLoadAssignment
 };
 
 static const upb_msglayout_field envoy_config_endpoint_v3_ClusterLoadAssignment_NamedEndpointsEntry__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {2, UPB_SIZE(8, 16), 0, 0, 11, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 0, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_endpoint_v3_ClusterLoadAssignment_NamedEndpointsEntry_msginit = {
   &envoy_config_endpoint_v3_ClusterLoadAssignment_NamedEndpointsEntry_submsgs[0],
   &envoy_config_endpoint_v3_ClusterLoadAssignment_NamedEndpointsEntry__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 #include "upb/port_undef.inc"
index c89e4a4..b787ab6 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_CONFIG_ENDPOINT_V3_ENDPOINT_PROTO_UPB_H_
 #define ENVOY_CONFIG_ENDPOINT_V3_ENDPOINT_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -52,13 +52,19 @@ UPB_INLINE envoy_config_endpoint_v3_ClusterLoadAssignment *envoy_config_endpoint
 UPB_INLINE envoy_config_endpoint_v3_ClusterLoadAssignment *envoy_config_endpoint_v3_ClusterLoadAssignment_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_endpoint_v3_ClusterLoadAssignment *ret = envoy_config_endpoint_v3_ClusterLoadAssignment_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_endpoint_v3_ClusterLoadAssignment_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_endpoint_v3_ClusterLoadAssignment_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_endpoint_v3_ClusterLoadAssignment *envoy_config_endpoint_v3_ClusterLoadAssignment_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_endpoint_v3_ClusterLoadAssignment *ret = envoy_config_endpoint_v3_ClusterLoadAssignment_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_endpoint_v3_ClusterLoadAssignment_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_endpoint_v3_ClusterLoadAssignment_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_endpoint_v3_ClusterLoadAssignment_serialize(const envoy_config_endpoint_v3_ClusterLoadAssignment *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_endpoint_v3_ClusterLoadAssignment_msginit, arena, len);
@@ -116,13 +122,19 @@ UPB_INLINE envoy_config_endpoint_v3_ClusterLoadAssignment_Policy *envoy_config_e
 UPB_INLINE envoy_config_endpoint_v3_ClusterLoadAssignment_Policy *envoy_config_endpoint_v3_ClusterLoadAssignment_Policy_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_endpoint_v3_ClusterLoadAssignment_Policy *ret = envoy_config_endpoint_v3_ClusterLoadAssignment_Policy_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_endpoint_v3_ClusterLoadAssignment_Policy_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_endpoint_v3_ClusterLoadAssignment_Policy_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_endpoint_v3_ClusterLoadAssignment_Policy *envoy_config_endpoint_v3_ClusterLoadAssignment_Policy_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_endpoint_v3_ClusterLoadAssignment_Policy *ret = envoy_config_endpoint_v3_ClusterLoadAssignment_Policy_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_endpoint_v3_ClusterLoadAssignment_Policy_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_endpoint_v3_ClusterLoadAssignment_Policy_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_endpoint_v3_ClusterLoadAssignment_Policy_serialize(const envoy_config_endpoint_v3_ClusterLoadAssignment_Policy *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_endpoint_v3_ClusterLoadAssignment_Policy_msginit, arena, len);
@@ -183,13 +195,19 @@ UPB_INLINE envoy_config_endpoint_v3_ClusterLoadAssignment_Policy_DropOverload *e
 UPB_INLINE envoy_config_endpoint_v3_ClusterLoadAssignment_Policy_DropOverload *envoy_config_endpoint_v3_ClusterLoadAssignment_Policy_DropOverload_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_endpoint_v3_ClusterLoadAssignment_Policy_DropOverload *ret = envoy_config_endpoint_v3_ClusterLoadAssignment_Policy_DropOverload_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_endpoint_v3_ClusterLoadAssignment_Policy_DropOverload_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_endpoint_v3_ClusterLoadAssignment_Policy_DropOverload_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_endpoint_v3_ClusterLoadAssignment_Policy_DropOverload *envoy_config_endpoint_v3_ClusterLoadAssignment_Policy_DropOverload_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_endpoint_v3_ClusterLoadAssignment_Policy_DropOverload *ret = envoy_config_endpoint_v3_ClusterLoadAssignment_Policy_DropOverload_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_endpoint_v3_ClusterLoadAssignment_Policy_DropOverload_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_endpoint_v3_ClusterLoadAssignment_Policy_DropOverload_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_endpoint_v3_ClusterLoadAssignment_Policy_DropOverload_serialize(const envoy_config_endpoint_v3_ClusterLoadAssignment_Policy_DropOverload *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_endpoint_v3_ClusterLoadAssignment_Policy_DropOverload_msginit, arena, len);
index f12e49b..20642ea 100644 (file)
@@ -7,12 +7,14 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/config/endpoint/v3/endpoint_components.upb.h"
 #include "envoy/config/core/v3/address.upb.h"
 #include "envoy/config/core/v3/base.upb.h"
+#include "envoy/config/core/v3/config_source.upb.h"
 #include "envoy/config/core/v3/health_check.upb.h"
 #include "google/protobuf/wrappers.upb.h"
+#include "udpa/annotations/migrate.upb.h"
 #include "udpa/annotations/status.upb.h"
 #include "udpa/annotations/versioning.upb.h"
 #include "validate/validate.upb.h"
@@ -25,26 +27,26 @@ static const upb_msglayout *const envoy_config_endpoint_v3_Endpoint_submsgs[2] =
 };
 
 static const upb_msglayout_field envoy_config_endpoint_v3_Endpoint__fields[3] = {
-  {1, UPB_SIZE(12, 24), 1, 0, 11, 1},
-  {2, UPB_SIZE(16, 32), 2, 1, 11, 1},
-  {3, UPB_SIZE(4, 8), 0, 0, 9, 1},
+  {1, UPB_SIZE(12, 24), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(16, 32), 2, 1, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_endpoint_v3_Endpoint_msginit = {
   &envoy_config_endpoint_v3_Endpoint_submsgs[0],
   &envoy_config_endpoint_v3_Endpoint__fields[0],
-  UPB_SIZE(24, 48), 3, false, 255,
+  UPB_SIZE(24, 48), 3, false, 3, 255,
 };
 
 static const upb_msglayout_field envoy_config_endpoint_v3_Endpoint_HealthCheckConfig__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 13, 1},
-  {2, UPB_SIZE(4, 8), 0, 0, 9, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 13, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_endpoint_v3_Endpoint_HealthCheckConfig_msginit = {
   NULL,
   &envoy_config_endpoint_v3_Endpoint_HealthCheckConfig__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_config_endpoint_v3_LbEndpoint_submsgs[3] = {
@@ -54,37 +56,70 @@ static const upb_msglayout *const envoy_config_endpoint_v3_LbEndpoint_submsgs[3]
 };
 
 static const upb_msglayout_field envoy_config_endpoint_v3_LbEndpoint__fields[5] = {
-  {1, UPB_SIZE(16, 24), UPB_SIZE(-25, -41), 1, 11, 1},
-  {2, UPB_SIZE(4, 4), 0, 0, 14, 1},
-  {3, UPB_SIZE(8, 8), 1, 0, 11, 1},
-  {4, UPB_SIZE(12, 16), 2, 2, 11, 1},
-  {5, UPB_SIZE(16, 24), UPB_SIZE(-25, -41), 0, 9, 1},
+  {1, UPB_SIZE(16, 24), UPB_SIZE(-25, -41), 1, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(4, 4), 0, 0, 14, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(8, 8), 1, 0, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(12, 16), 2, 2, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(16, 24), UPB_SIZE(-25, -41), 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_endpoint_v3_LbEndpoint_msginit = {
   &envoy_config_endpoint_v3_LbEndpoint_submsgs[0],
   &envoy_config_endpoint_v3_LbEndpoint__fields[0],
-  UPB_SIZE(32, 48), 5, false, 255,
+  UPB_SIZE(32, 48), 5, false, 5, 255,
 };
 
-static const upb_msglayout *const envoy_config_endpoint_v3_LocalityLbEndpoints_submsgs[3] = {
+static const upb_msglayout *const envoy_config_endpoint_v3_LedsClusterLocalityConfig_submsgs[1] = {
+  &envoy_config_core_v3_ConfigSource_msginit,
+};
+
+static const upb_msglayout_field envoy_config_endpoint_v3_LedsClusterLocalityConfig__fields[2] = {
+  {1, UPB_SIZE(12, 24), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+};
+
+const upb_msglayout envoy_config_endpoint_v3_LedsClusterLocalityConfig_msginit = {
+  &envoy_config_endpoint_v3_LedsClusterLocalityConfig_submsgs[0],
+  &envoy_config_endpoint_v3_LedsClusterLocalityConfig__fields[0],
+  UPB_SIZE(16, 32), 2, false, 2, 255,
+};
+
+static const upb_msglayout *const envoy_config_endpoint_v3_LocalityLbEndpoints_submsgs[5] = {
   &envoy_config_core_v3_Locality_msginit,
   &envoy_config_endpoint_v3_LbEndpoint_msginit,
+  &envoy_config_endpoint_v3_LedsClusterLocalityConfig_msginit,
+  &envoy_config_endpoint_v3_LocalityLbEndpoints_LbEndpointList_msginit,
   &google_protobuf_UInt32Value_msginit,
 };
 
-static const upb_msglayout_field envoy_config_endpoint_v3_LocalityLbEndpoints__fields[5] = {
-  {1, UPB_SIZE(8, 8), 1, 0, 11, 1},
-  {2, UPB_SIZE(20, 32), 0, 1, 11, 3},
-  {3, UPB_SIZE(12, 16), 2, 2, 11, 1},
-  {5, UPB_SIZE(4, 4), 0, 0, 13, 1},
-  {6, UPB_SIZE(16, 24), 3, 2, 11, 1},
+static const upb_msglayout_field envoy_config_endpoint_v3_LocalityLbEndpoints__fields[7] = {
+  {1, UPB_SIZE(8, 8), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(20, 32), 0, 1, 11, _UPB_MODE_ARRAY},
+  {3, UPB_SIZE(12, 16), 2, 4, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(4, 4), 0, 0, 13, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(16, 24), 3, 4, 11, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(24, 40), UPB_SIZE(-29, -49), 3, 11, _UPB_MODE_SCALAR},
+  {8, UPB_SIZE(24, 40), UPB_SIZE(-29, -49), 2, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_endpoint_v3_LocalityLbEndpoints_msginit = {
   &envoy_config_endpoint_v3_LocalityLbEndpoints_submsgs[0],
   &envoy_config_endpoint_v3_LocalityLbEndpoints__fields[0],
-  UPB_SIZE(24, 40), 5, false, 255,
+  UPB_SIZE(32, 56), 7, false, 3, 255,
+};
+
+static const upb_msglayout *const envoy_config_endpoint_v3_LocalityLbEndpoints_LbEndpointList_submsgs[1] = {
+  &envoy_config_endpoint_v3_LbEndpoint_msginit,
+};
+
+static const upb_msglayout_field envoy_config_endpoint_v3_LocalityLbEndpoints_LbEndpointList__fields[1] = {
+  {1, UPB_SIZE(0, 0), 0, 0, 11, _UPB_MODE_ARRAY},
+};
+
+const upb_msglayout envoy_config_endpoint_v3_LocalityLbEndpoints_LbEndpointList_msginit = {
+  &envoy_config_endpoint_v3_LocalityLbEndpoints_LbEndpointList_submsgs[0],
+  &envoy_config_endpoint_v3_LocalityLbEndpoints_LbEndpointList__fields[0],
+  UPB_SIZE(8, 8), 1, false, 1, 255,
 };
 
 #include "upb/port_undef.inc"
index b6ad981..152c1d1 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_CONFIG_ENDPOINT_V3_ENDPOINT_COMPONENTS_PROTO_UPB_H_
 #define ENVOY_CONFIG_ENDPOINT_V3_ENDPOINT_COMPONENTS_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -23,20 +23,28 @@ extern "C" {
 struct envoy_config_endpoint_v3_Endpoint;
 struct envoy_config_endpoint_v3_Endpoint_HealthCheckConfig;
 struct envoy_config_endpoint_v3_LbEndpoint;
+struct envoy_config_endpoint_v3_LedsClusterLocalityConfig;
 struct envoy_config_endpoint_v3_LocalityLbEndpoints;
+struct envoy_config_endpoint_v3_LocalityLbEndpoints_LbEndpointList;
 typedef struct envoy_config_endpoint_v3_Endpoint envoy_config_endpoint_v3_Endpoint;
 typedef struct envoy_config_endpoint_v3_Endpoint_HealthCheckConfig envoy_config_endpoint_v3_Endpoint_HealthCheckConfig;
 typedef struct envoy_config_endpoint_v3_LbEndpoint envoy_config_endpoint_v3_LbEndpoint;
+typedef struct envoy_config_endpoint_v3_LedsClusterLocalityConfig envoy_config_endpoint_v3_LedsClusterLocalityConfig;
 typedef struct envoy_config_endpoint_v3_LocalityLbEndpoints envoy_config_endpoint_v3_LocalityLbEndpoints;
+typedef struct envoy_config_endpoint_v3_LocalityLbEndpoints_LbEndpointList envoy_config_endpoint_v3_LocalityLbEndpoints_LbEndpointList;
 extern const upb_msglayout envoy_config_endpoint_v3_Endpoint_msginit;
 extern const upb_msglayout envoy_config_endpoint_v3_Endpoint_HealthCheckConfig_msginit;
 extern const upb_msglayout envoy_config_endpoint_v3_LbEndpoint_msginit;
+extern const upb_msglayout envoy_config_endpoint_v3_LedsClusterLocalityConfig_msginit;
 extern const upb_msglayout envoy_config_endpoint_v3_LocalityLbEndpoints_msginit;
+extern const upb_msglayout envoy_config_endpoint_v3_LocalityLbEndpoints_LbEndpointList_msginit;
 struct envoy_config_core_v3_Address;
+struct envoy_config_core_v3_ConfigSource;
 struct envoy_config_core_v3_Locality;
 struct envoy_config_core_v3_Metadata;
 struct google_protobuf_UInt32Value;
 extern const upb_msglayout envoy_config_core_v3_Address_msginit;
+extern const upb_msglayout envoy_config_core_v3_ConfigSource_msginit;
 extern const upb_msglayout envoy_config_core_v3_Locality_msginit;
 extern const upb_msglayout envoy_config_core_v3_Metadata_msginit;
 extern const upb_msglayout google_protobuf_UInt32Value_msginit;
@@ -50,13 +58,19 @@ UPB_INLINE envoy_config_endpoint_v3_Endpoint *envoy_config_endpoint_v3_Endpoint_
 UPB_INLINE envoy_config_endpoint_v3_Endpoint *envoy_config_endpoint_v3_Endpoint_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_endpoint_v3_Endpoint *ret = envoy_config_endpoint_v3_Endpoint_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_endpoint_v3_Endpoint_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_endpoint_v3_Endpoint_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_endpoint_v3_Endpoint *envoy_config_endpoint_v3_Endpoint_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_endpoint_v3_Endpoint *ret = envoy_config_endpoint_v3_Endpoint_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_endpoint_v3_Endpoint_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_endpoint_v3_Endpoint_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_endpoint_v3_Endpoint_serialize(const envoy_config_endpoint_v3_Endpoint *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_endpoint_v3_Endpoint_msginit, arena, len);
@@ -106,13 +120,19 @@ UPB_INLINE envoy_config_endpoint_v3_Endpoint_HealthCheckConfig *envoy_config_end
 UPB_INLINE envoy_config_endpoint_v3_Endpoint_HealthCheckConfig *envoy_config_endpoint_v3_Endpoint_HealthCheckConfig_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_endpoint_v3_Endpoint_HealthCheckConfig *ret = envoy_config_endpoint_v3_Endpoint_HealthCheckConfig_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_endpoint_v3_Endpoint_HealthCheckConfig_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_endpoint_v3_Endpoint_HealthCheckConfig_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_endpoint_v3_Endpoint_HealthCheckConfig *envoy_config_endpoint_v3_Endpoint_HealthCheckConfig_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_endpoint_v3_Endpoint_HealthCheckConfig *ret = envoy_config_endpoint_v3_Endpoint_HealthCheckConfig_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_endpoint_v3_Endpoint_HealthCheckConfig_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_endpoint_v3_Endpoint_HealthCheckConfig_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_endpoint_v3_Endpoint_HealthCheckConfig_serialize(const envoy_config_endpoint_v3_Endpoint_HealthCheckConfig *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_endpoint_v3_Endpoint_HealthCheckConfig_msginit, arena, len);
@@ -136,13 +156,19 @@ UPB_INLINE envoy_config_endpoint_v3_LbEndpoint *envoy_config_endpoint_v3_LbEndpo
 UPB_INLINE envoy_config_endpoint_v3_LbEndpoint *envoy_config_endpoint_v3_LbEndpoint_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_endpoint_v3_LbEndpoint *ret = envoy_config_endpoint_v3_LbEndpoint_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_endpoint_v3_LbEndpoint_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_endpoint_v3_LbEndpoint_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_endpoint_v3_LbEndpoint *envoy_config_endpoint_v3_LbEndpoint_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_endpoint_v3_LbEndpoint *ret = envoy_config_endpoint_v3_LbEndpoint_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_endpoint_v3_LbEndpoint_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_endpoint_v3_LbEndpoint_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_endpoint_v3_LbEndpoint_serialize(const envoy_config_endpoint_v3_LbEndpoint *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_endpoint_v3_LbEndpoint_msginit, arena, len);
@@ -210,6 +236,53 @@ UPB_INLINE void envoy_config_endpoint_v3_LbEndpoint_set_endpoint_name(envoy_conf
   UPB_WRITE_ONEOF(msg, upb_strview, UPB_SIZE(16, 24), value, UPB_SIZE(24, 40), 5);
 }
 
+/* envoy.config.endpoint.v3.LedsClusterLocalityConfig */
+
+UPB_INLINE envoy_config_endpoint_v3_LedsClusterLocalityConfig *envoy_config_endpoint_v3_LedsClusterLocalityConfig_new(upb_arena *arena) {
+  return (envoy_config_endpoint_v3_LedsClusterLocalityConfig *)_upb_msg_new(&envoy_config_endpoint_v3_LedsClusterLocalityConfig_msginit, arena);
+}
+UPB_INLINE envoy_config_endpoint_v3_LedsClusterLocalityConfig *envoy_config_endpoint_v3_LedsClusterLocalityConfig_parse(const char *buf, size_t size,
+                        upb_arena *arena) {
+  envoy_config_endpoint_v3_LedsClusterLocalityConfig *ret = envoy_config_endpoint_v3_LedsClusterLocalityConfig_new(arena);
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_endpoint_v3_LedsClusterLocalityConfig_msginit, arena)) return NULL;
+  return ret;
+}
+UPB_INLINE envoy_config_endpoint_v3_LedsClusterLocalityConfig *envoy_config_endpoint_v3_LedsClusterLocalityConfig_parse_ex(const char *buf, size_t size,
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
+  envoy_config_endpoint_v3_LedsClusterLocalityConfig *ret = envoy_config_endpoint_v3_LedsClusterLocalityConfig_new(arena);
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_endpoint_v3_LedsClusterLocalityConfig_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
+}
+UPB_INLINE char *envoy_config_endpoint_v3_LedsClusterLocalityConfig_serialize(const envoy_config_endpoint_v3_LedsClusterLocalityConfig *msg, upb_arena *arena, size_t *len) {
+  return upb_encode(msg, &envoy_config_endpoint_v3_LedsClusterLocalityConfig_msginit, arena, len);
+}
+
+UPB_INLINE bool envoy_config_endpoint_v3_LedsClusterLocalityConfig_has_leds_config(const envoy_config_endpoint_v3_LedsClusterLocalityConfig *msg) { return _upb_hasbit(msg, 1); }
+UPB_INLINE const struct envoy_config_core_v3_ConfigSource* envoy_config_endpoint_v3_LedsClusterLocalityConfig_leds_config(const envoy_config_endpoint_v3_LedsClusterLocalityConfig *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(12, 24), const struct envoy_config_core_v3_ConfigSource*); }
+UPB_INLINE upb_strview envoy_config_endpoint_v3_LedsClusterLocalityConfig_leds_collection_name(const envoy_config_endpoint_v3_LedsClusterLocalityConfig *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(4, 8), upb_strview); }
+
+UPB_INLINE void envoy_config_endpoint_v3_LedsClusterLocalityConfig_set_leds_config(envoy_config_endpoint_v3_LedsClusterLocalityConfig *msg, struct envoy_config_core_v3_ConfigSource* value) {
+  _upb_sethas(msg, 1);
+  *UPB_PTR_AT(msg, UPB_SIZE(12, 24), struct envoy_config_core_v3_ConfigSource*) = value;
+}
+UPB_INLINE struct envoy_config_core_v3_ConfigSource* envoy_config_endpoint_v3_LedsClusterLocalityConfig_mutable_leds_config(envoy_config_endpoint_v3_LedsClusterLocalityConfig *msg, upb_arena *arena) {
+  struct envoy_config_core_v3_ConfigSource* sub = (struct envoy_config_core_v3_ConfigSource*)envoy_config_endpoint_v3_LedsClusterLocalityConfig_leds_config(msg);
+  if (sub == NULL) {
+    sub = (struct envoy_config_core_v3_ConfigSource*)_upb_msg_new(&envoy_config_core_v3_ConfigSource_msginit, arena);
+    if (!sub) return NULL;
+    envoy_config_endpoint_v3_LedsClusterLocalityConfig_set_leds_config(msg, sub);
+  }
+  return sub;
+}
+UPB_INLINE void envoy_config_endpoint_v3_LedsClusterLocalityConfig_set_leds_collection_name(envoy_config_endpoint_v3_LedsClusterLocalityConfig *msg, upb_strview value) {
+  *UPB_PTR_AT(msg, UPB_SIZE(4, 8), upb_strview) = value;
+}
+
 /* envoy.config.endpoint.v3.LocalityLbEndpoints */
 
 UPB_INLINE envoy_config_endpoint_v3_LocalityLbEndpoints *envoy_config_endpoint_v3_LocalityLbEndpoints_new(upb_arena *arena) {
@@ -218,18 +291,31 @@ UPB_INLINE envoy_config_endpoint_v3_LocalityLbEndpoints *envoy_config_endpoint_v
 UPB_INLINE envoy_config_endpoint_v3_LocalityLbEndpoints *envoy_config_endpoint_v3_LocalityLbEndpoints_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_endpoint_v3_LocalityLbEndpoints *ret = envoy_config_endpoint_v3_LocalityLbEndpoints_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_endpoint_v3_LocalityLbEndpoints_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_endpoint_v3_LocalityLbEndpoints_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_endpoint_v3_LocalityLbEndpoints *envoy_config_endpoint_v3_LocalityLbEndpoints_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_endpoint_v3_LocalityLbEndpoints *ret = envoy_config_endpoint_v3_LocalityLbEndpoints_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_endpoint_v3_LocalityLbEndpoints_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_endpoint_v3_LocalityLbEndpoints_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_endpoint_v3_LocalityLbEndpoints_serialize(const envoy_config_endpoint_v3_LocalityLbEndpoints *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_endpoint_v3_LocalityLbEndpoints_msginit, arena, len);
 }
 
+typedef enum {
+  envoy_config_endpoint_v3_LocalityLbEndpoints_lb_config_load_balancer_endpoints = 7,
+  envoy_config_endpoint_v3_LocalityLbEndpoints_lb_config_leds_cluster_locality_config = 8,
+  envoy_config_endpoint_v3_LocalityLbEndpoints_lb_config_NOT_SET = 0
+} envoy_config_endpoint_v3_LocalityLbEndpoints_lb_config_oneofcases;
+UPB_INLINE envoy_config_endpoint_v3_LocalityLbEndpoints_lb_config_oneofcases envoy_config_endpoint_v3_LocalityLbEndpoints_lb_config_case(const envoy_config_endpoint_v3_LocalityLbEndpoints* msg) { return (envoy_config_endpoint_v3_LocalityLbEndpoints_lb_config_oneofcases)*UPB_PTR_AT(msg, UPB_SIZE(28, 48), int32_t); }
+
 UPB_INLINE bool envoy_config_endpoint_v3_LocalityLbEndpoints_has_locality(const envoy_config_endpoint_v3_LocalityLbEndpoints *msg) { return _upb_hasbit(msg, 1); }
 UPB_INLINE const struct envoy_config_core_v3_Locality* envoy_config_endpoint_v3_LocalityLbEndpoints_locality(const envoy_config_endpoint_v3_LocalityLbEndpoints *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(8, 8), const struct envoy_config_core_v3_Locality*); }
 UPB_INLINE bool envoy_config_endpoint_v3_LocalityLbEndpoints_has_lb_endpoints(const envoy_config_endpoint_v3_LocalityLbEndpoints *msg) { return _upb_has_submsg_nohasbit(msg, UPB_SIZE(20, 32)); }
@@ -239,6 +325,10 @@ UPB_INLINE const struct google_protobuf_UInt32Value* envoy_config_endpoint_v3_Lo
 UPB_INLINE uint32_t envoy_config_endpoint_v3_LocalityLbEndpoints_priority(const envoy_config_endpoint_v3_LocalityLbEndpoints *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(4, 4), uint32_t); }
 UPB_INLINE bool envoy_config_endpoint_v3_LocalityLbEndpoints_has_proximity(const envoy_config_endpoint_v3_LocalityLbEndpoints *msg) { return _upb_hasbit(msg, 3); }
 UPB_INLINE const struct google_protobuf_UInt32Value* envoy_config_endpoint_v3_LocalityLbEndpoints_proximity(const envoy_config_endpoint_v3_LocalityLbEndpoints *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(16, 24), const struct google_protobuf_UInt32Value*); }
+UPB_INLINE bool envoy_config_endpoint_v3_LocalityLbEndpoints_has_load_balancer_endpoints(const envoy_config_endpoint_v3_LocalityLbEndpoints *msg) { return _upb_getoneofcase(msg, UPB_SIZE(28, 48)) == 7; }
+UPB_INLINE const envoy_config_endpoint_v3_LocalityLbEndpoints_LbEndpointList* envoy_config_endpoint_v3_LocalityLbEndpoints_load_balancer_endpoints(const envoy_config_endpoint_v3_LocalityLbEndpoints *msg) { return UPB_READ_ONEOF(msg, const envoy_config_endpoint_v3_LocalityLbEndpoints_LbEndpointList*, UPB_SIZE(24, 40), UPB_SIZE(28, 48), 7, NULL); }
+UPB_INLINE bool envoy_config_endpoint_v3_LocalityLbEndpoints_has_leds_cluster_locality_config(const envoy_config_endpoint_v3_LocalityLbEndpoints *msg) { return _upb_getoneofcase(msg, UPB_SIZE(28, 48)) == 8; }
+UPB_INLINE const envoy_config_endpoint_v3_LedsClusterLocalityConfig* envoy_config_endpoint_v3_LocalityLbEndpoints_leds_cluster_locality_config(const envoy_config_endpoint_v3_LocalityLbEndpoints *msg) { return UPB_READ_ONEOF(msg, const envoy_config_endpoint_v3_LedsClusterLocalityConfig*, UPB_SIZE(24, 40), UPB_SIZE(28, 48), 8, NULL); }
 
 UPB_INLINE void envoy_config_endpoint_v3_LocalityLbEndpoints_set_locality(envoy_config_endpoint_v3_LocalityLbEndpoints *msg, struct envoy_config_core_v3_Locality* value) {
   _upb_sethas(msg, 1);
@@ -295,6 +385,73 @@ UPB_INLINE struct google_protobuf_UInt32Value* envoy_config_endpoint_v3_Locality
   }
   return sub;
 }
+UPB_INLINE void envoy_config_endpoint_v3_LocalityLbEndpoints_set_load_balancer_endpoints(envoy_config_endpoint_v3_LocalityLbEndpoints *msg, envoy_config_endpoint_v3_LocalityLbEndpoints_LbEndpointList* value) {
+  UPB_WRITE_ONEOF(msg, envoy_config_endpoint_v3_LocalityLbEndpoints_LbEndpointList*, UPB_SIZE(24, 40), value, UPB_SIZE(28, 48), 7);
+}
+UPB_INLINE struct envoy_config_endpoint_v3_LocalityLbEndpoints_LbEndpointList* envoy_config_endpoint_v3_LocalityLbEndpoints_mutable_load_balancer_endpoints(envoy_config_endpoint_v3_LocalityLbEndpoints *msg, upb_arena *arena) {
+  struct envoy_config_endpoint_v3_LocalityLbEndpoints_LbEndpointList* sub = (struct envoy_config_endpoint_v3_LocalityLbEndpoints_LbEndpointList*)envoy_config_endpoint_v3_LocalityLbEndpoints_load_balancer_endpoints(msg);
+  if (sub == NULL) {
+    sub = (struct envoy_config_endpoint_v3_LocalityLbEndpoints_LbEndpointList*)_upb_msg_new(&envoy_config_endpoint_v3_LocalityLbEndpoints_LbEndpointList_msginit, arena);
+    if (!sub) return NULL;
+    envoy_config_endpoint_v3_LocalityLbEndpoints_set_load_balancer_endpoints(msg, sub);
+  }
+  return sub;
+}
+UPB_INLINE void envoy_config_endpoint_v3_LocalityLbEndpoints_set_leds_cluster_locality_config(envoy_config_endpoint_v3_LocalityLbEndpoints *msg, envoy_config_endpoint_v3_LedsClusterLocalityConfig* value) {
+  UPB_WRITE_ONEOF(msg, envoy_config_endpoint_v3_LedsClusterLocalityConfig*, UPB_SIZE(24, 40), value, UPB_SIZE(28, 48), 8);
+}
+UPB_INLINE struct envoy_config_endpoint_v3_LedsClusterLocalityConfig* envoy_config_endpoint_v3_LocalityLbEndpoints_mutable_leds_cluster_locality_config(envoy_config_endpoint_v3_LocalityLbEndpoints *msg, upb_arena *arena) {
+  struct envoy_config_endpoint_v3_LedsClusterLocalityConfig* sub = (struct envoy_config_endpoint_v3_LedsClusterLocalityConfig*)envoy_config_endpoint_v3_LocalityLbEndpoints_leds_cluster_locality_config(msg);
+  if (sub == NULL) {
+    sub = (struct envoy_config_endpoint_v3_LedsClusterLocalityConfig*)_upb_msg_new(&envoy_config_endpoint_v3_LedsClusterLocalityConfig_msginit, arena);
+    if (!sub) return NULL;
+    envoy_config_endpoint_v3_LocalityLbEndpoints_set_leds_cluster_locality_config(msg, sub);
+  }
+  return sub;
+}
+
+/* envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList */
+
+UPB_INLINE envoy_config_endpoint_v3_LocalityLbEndpoints_LbEndpointList *envoy_config_endpoint_v3_LocalityLbEndpoints_LbEndpointList_new(upb_arena *arena) {
+  return (envoy_config_endpoint_v3_LocalityLbEndpoints_LbEndpointList *)_upb_msg_new(&envoy_config_endpoint_v3_LocalityLbEndpoints_LbEndpointList_msginit, arena);
+}
+UPB_INLINE envoy_config_endpoint_v3_LocalityLbEndpoints_LbEndpointList *envoy_config_endpoint_v3_LocalityLbEndpoints_LbEndpointList_parse(const char *buf, size_t size,
+                        upb_arena *arena) {
+  envoy_config_endpoint_v3_LocalityLbEndpoints_LbEndpointList *ret = envoy_config_endpoint_v3_LocalityLbEndpoints_LbEndpointList_new(arena);
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_endpoint_v3_LocalityLbEndpoints_LbEndpointList_msginit, arena)) return NULL;
+  return ret;
+}
+UPB_INLINE envoy_config_endpoint_v3_LocalityLbEndpoints_LbEndpointList *envoy_config_endpoint_v3_LocalityLbEndpoints_LbEndpointList_parse_ex(const char *buf, size_t size,
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
+  envoy_config_endpoint_v3_LocalityLbEndpoints_LbEndpointList *ret = envoy_config_endpoint_v3_LocalityLbEndpoints_LbEndpointList_new(arena);
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_endpoint_v3_LocalityLbEndpoints_LbEndpointList_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
+}
+UPB_INLINE char *envoy_config_endpoint_v3_LocalityLbEndpoints_LbEndpointList_serialize(const envoy_config_endpoint_v3_LocalityLbEndpoints_LbEndpointList *msg, upb_arena *arena, size_t *len) {
+  return upb_encode(msg, &envoy_config_endpoint_v3_LocalityLbEndpoints_LbEndpointList_msginit, arena, len);
+}
+
+UPB_INLINE bool envoy_config_endpoint_v3_LocalityLbEndpoints_LbEndpointList_has_lb_endpoints(const envoy_config_endpoint_v3_LocalityLbEndpoints_LbEndpointList *msg) { return _upb_has_submsg_nohasbit(msg, UPB_SIZE(0, 0)); }
+UPB_INLINE const envoy_config_endpoint_v3_LbEndpoint* const* envoy_config_endpoint_v3_LocalityLbEndpoints_LbEndpointList_lb_endpoints(const envoy_config_endpoint_v3_LocalityLbEndpoints_LbEndpointList *msg, size_t *len) { return (const envoy_config_endpoint_v3_LbEndpoint* const*)_upb_array_accessor(msg, UPB_SIZE(0, 0), len); }
+
+UPB_INLINE envoy_config_endpoint_v3_LbEndpoint** envoy_config_endpoint_v3_LocalityLbEndpoints_LbEndpointList_mutable_lb_endpoints(envoy_config_endpoint_v3_LocalityLbEndpoints_LbEndpointList *msg, size_t *len) {
+  return (envoy_config_endpoint_v3_LbEndpoint**)_upb_array_mutable_accessor(msg, UPB_SIZE(0, 0), len);
+}
+UPB_INLINE envoy_config_endpoint_v3_LbEndpoint** envoy_config_endpoint_v3_LocalityLbEndpoints_LbEndpointList_resize_lb_endpoints(envoy_config_endpoint_v3_LocalityLbEndpoints_LbEndpointList *msg, size_t len, upb_arena *arena) {
+  return (envoy_config_endpoint_v3_LbEndpoint**)_upb_array_resize_accessor2(msg, UPB_SIZE(0, 0), len, UPB_SIZE(2, 3), arena);
+}
+UPB_INLINE struct envoy_config_endpoint_v3_LbEndpoint* envoy_config_endpoint_v3_LocalityLbEndpoints_LbEndpointList_add_lb_endpoints(envoy_config_endpoint_v3_LocalityLbEndpoints_LbEndpointList *msg, upb_arena *arena) {
+  struct envoy_config_endpoint_v3_LbEndpoint* sub = (struct envoy_config_endpoint_v3_LbEndpoint*)_upb_msg_new(&envoy_config_endpoint_v3_LbEndpoint_msginit, arena);
+  bool ok = _upb_array_append_accessor2(
+      msg, UPB_SIZE(0, 0), UPB_SIZE(2, 3), &sub, arena);
+  if (!ok) return NULL;
+  return sub;
+}
 
 #ifdef __cplusplus
 }  /* extern "C" */
index 560826e..303f91e 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/config/endpoint/v3/load_report.upb.h"
 #include "envoy/config/core/v3/address.upb.h"
 #include "envoy/config/core/v3/base.upb.h"
@@ -26,20 +26,20 @@ static const upb_msglayout *const envoy_config_endpoint_v3_UpstreamLocalityStats
 };
 
 static const upb_msglayout_field envoy_config_endpoint_v3_UpstreamLocalityStats__fields[8] = {
-  {1, UPB_SIZE(44, 48), 1, 0, 11, 1},
-  {2, UPB_SIZE(8, 8), 0, 0, 4, 1},
-  {3, UPB_SIZE(16, 16), 0, 0, 4, 1},
-  {4, UPB_SIZE(24, 24), 0, 0, 4, 1},
-  {5, UPB_SIZE(48, 56), 0, 1, 11, 3},
-  {6, UPB_SIZE(40, 40), 0, 0, 13, 1},
-  {7, UPB_SIZE(52, 64), 0, 2, 11, 3},
-  {8, UPB_SIZE(32, 32), 0, 0, 4, 1},
+  {1, UPB_SIZE(44, 48), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 8), 0, 0, 4, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(16, 16), 0, 0, 4, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(24, 24), 0, 0, 4, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(48, 56), 0, 1, 11, _UPB_MODE_ARRAY},
+  {6, UPB_SIZE(40, 40), 0, 0, 13, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(52, 64), 0, 2, 11, _UPB_MODE_ARRAY},
+  {8, UPB_SIZE(32, 32), 0, 0, 4, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_endpoint_v3_UpstreamLocalityStats_msginit = {
   &envoy_config_endpoint_v3_UpstreamLocalityStats_submsgs[0],
   &envoy_config_endpoint_v3_UpstreamLocalityStats__fields[0],
-  UPB_SIZE(56, 72), 8, false, 255,
+  UPB_SIZE(56, 72), 8, false, 8, 255,
 };
 
 static const upb_msglayout *const envoy_config_endpoint_v3_UpstreamEndpointStats_submsgs[3] = {
@@ -49,31 +49,31 @@ static const upb_msglayout *const envoy_config_endpoint_v3_UpstreamEndpointStats
 };
 
 static const upb_msglayout_field envoy_config_endpoint_v3_UpstreamEndpointStats__fields[7] = {
-  {1, UPB_SIZE(40, 40), 1, 0, 11, 1},
-  {2, UPB_SIZE(8, 8), 0, 0, 4, 1},
-  {3, UPB_SIZE(16, 16), 0, 0, 4, 1},
-  {4, UPB_SIZE(24, 24), 0, 0, 4, 1},
-  {5, UPB_SIZE(48, 56), 0, 1, 11, 3},
-  {6, UPB_SIZE(44, 48), 2, 2, 11, 1},
-  {7, UPB_SIZE(32, 32), 0, 0, 4, 1},
+  {1, UPB_SIZE(40, 40), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 8), 0, 0, 4, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(16, 16), 0, 0, 4, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(24, 24), 0, 0, 4, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(48, 56), 0, 1, 11, _UPB_MODE_ARRAY},
+  {6, UPB_SIZE(44, 48), 2, 2, 11, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(32, 32), 0, 0, 4, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_endpoint_v3_UpstreamEndpointStats_msginit = {
   &envoy_config_endpoint_v3_UpstreamEndpointStats_submsgs[0],
   &envoy_config_endpoint_v3_UpstreamEndpointStats__fields[0],
-  UPB_SIZE(56, 64), 7, false, 255,
+  UPB_SIZE(56, 64), 7, false, 7, 255,
 };
 
 static const upb_msglayout_field envoy_config_endpoint_v3_EndpointLoadMetricStats__fields[3] = {
-  {1, UPB_SIZE(16, 16), 0, 0, 9, 1},
-  {2, UPB_SIZE(0, 0), 0, 0, 4, 1},
-  {3, UPB_SIZE(8, 8), 0, 0, 1, 1},
+  {1, UPB_SIZE(16, 16), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(0, 0), 0, 0, 4, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(8, 8), 0, 0, 1, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_endpoint_v3_EndpointLoadMetricStats_msginit = {
   NULL,
   &envoy_config_endpoint_v3_EndpointLoadMetricStats__fields[0],
-  UPB_SIZE(24, 32), 3, false, 255,
+  UPB_SIZE(24, 32), 3, false, 3, 255,
 };
 
 static const upb_msglayout *const envoy_config_endpoint_v3_ClusterStats_submsgs[3] = {
@@ -83,29 +83,29 @@ static const upb_msglayout *const envoy_config_endpoint_v3_ClusterStats_submsgs[
 };
 
 static const upb_msglayout_field envoy_config_endpoint_v3_ClusterStats__fields[6] = {
-  {1, UPB_SIZE(16, 16), 0, 0, 9, 1},
-  {2, UPB_SIZE(36, 56), 0, 1, 11, 3},
-  {3, UPB_SIZE(8, 8), 0, 0, 4, 1},
-  {4, UPB_SIZE(32, 48), 1, 2, 11, 1},
-  {5, UPB_SIZE(40, 64), 0, 0, 11, 3},
-  {6, UPB_SIZE(24, 32), 0, 0, 9, 1},
+  {1, UPB_SIZE(16, 16), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(36, 56), 0, 1, 11, _UPB_MODE_ARRAY},
+  {3, UPB_SIZE(8, 8), 0, 0, 4, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(32, 48), 1, 2, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(40, 64), 0, 0, 11, _UPB_MODE_ARRAY},
+  {6, UPB_SIZE(24, 32), 0, 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_endpoint_v3_ClusterStats_msginit = {
   &envoy_config_endpoint_v3_ClusterStats_submsgs[0],
   &envoy_config_endpoint_v3_ClusterStats__fields[0],
-  UPB_SIZE(48, 80), 6, false, 255,
+  UPB_SIZE(48, 80), 6, false, 6, 255,
 };
 
 static const upb_msglayout_field envoy_config_endpoint_v3_ClusterStats_DroppedRequests__fields[2] = {
-  {1, UPB_SIZE(8, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(0, 0), 0, 0, 4, 1},
+  {1, UPB_SIZE(8, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(0, 0), 0, 0, 4, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_endpoint_v3_ClusterStats_DroppedRequests_msginit = {
   NULL,
   &envoy_config_endpoint_v3_ClusterStats_DroppedRequests__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 #include "upb/port_undef.inc"
index d986e18..0819b4a 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_CONFIG_ENDPOINT_V3_LOAD_REPORT_PROTO_UPB_H_
 #define ENVOY_CONFIG_ENDPOINT_V3_LOAD_REPORT_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -53,13 +53,19 @@ UPB_INLINE envoy_config_endpoint_v3_UpstreamLocalityStats *envoy_config_endpoint
 UPB_INLINE envoy_config_endpoint_v3_UpstreamLocalityStats *envoy_config_endpoint_v3_UpstreamLocalityStats_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_endpoint_v3_UpstreamLocalityStats *ret = envoy_config_endpoint_v3_UpstreamLocalityStats_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_endpoint_v3_UpstreamLocalityStats_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_endpoint_v3_UpstreamLocalityStats_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_endpoint_v3_UpstreamLocalityStats *envoy_config_endpoint_v3_UpstreamLocalityStats_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_endpoint_v3_UpstreamLocalityStats *ret = envoy_config_endpoint_v3_UpstreamLocalityStats_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_endpoint_v3_UpstreamLocalityStats_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_endpoint_v3_UpstreamLocalityStats_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_endpoint_v3_UpstreamLocalityStats_serialize(const envoy_config_endpoint_v3_UpstreamLocalityStats *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_endpoint_v3_UpstreamLocalityStats_msginit, arena, len);
@@ -140,13 +146,19 @@ UPB_INLINE envoy_config_endpoint_v3_UpstreamEndpointStats *envoy_config_endpoint
 UPB_INLINE envoy_config_endpoint_v3_UpstreamEndpointStats *envoy_config_endpoint_v3_UpstreamEndpointStats_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_endpoint_v3_UpstreamEndpointStats *ret = envoy_config_endpoint_v3_UpstreamEndpointStats_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_endpoint_v3_UpstreamEndpointStats_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_endpoint_v3_UpstreamEndpointStats_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_endpoint_v3_UpstreamEndpointStats *envoy_config_endpoint_v3_UpstreamEndpointStats_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_endpoint_v3_UpstreamEndpointStats *ret = envoy_config_endpoint_v3_UpstreamEndpointStats_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_endpoint_v3_UpstreamEndpointStats_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_endpoint_v3_UpstreamEndpointStats_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_endpoint_v3_UpstreamEndpointStats_serialize(const envoy_config_endpoint_v3_UpstreamEndpointStats *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_endpoint_v3_UpstreamEndpointStats_msginit, arena, len);
@@ -223,13 +235,19 @@ UPB_INLINE envoy_config_endpoint_v3_EndpointLoadMetricStats *envoy_config_endpoi
 UPB_INLINE envoy_config_endpoint_v3_EndpointLoadMetricStats *envoy_config_endpoint_v3_EndpointLoadMetricStats_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_endpoint_v3_EndpointLoadMetricStats *ret = envoy_config_endpoint_v3_EndpointLoadMetricStats_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_endpoint_v3_EndpointLoadMetricStats_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_endpoint_v3_EndpointLoadMetricStats_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_endpoint_v3_EndpointLoadMetricStats *envoy_config_endpoint_v3_EndpointLoadMetricStats_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_endpoint_v3_EndpointLoadMetricStats *ret = envoy_config_endpoint_v3_EndpointLoadMetricStats_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_endpoint_v3_EndpointLoadMetricStats_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_endpoint_v3_EndpointLoadMetricStats_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_endpoint_v3_EndpointLoadMetricStats_serialize(const envoy_config_endpoint_v3_EndpointLoadMetricStats *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_endpoint_v3_EndpointLoadMetricStats_msginit, arena, len);
@@ -257,13 +275,19 @@ UPB_INLINE envoy_config_endpoint_v3_ClusterStats *envoy_config_endpoint_v3_Clust
 UPB_INLINE envoy_config_endpoint_v3_ClusterStats *envoy_config_endpoint_v3_ClusterStats_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_endpoint_v3_ClusterStats *ret = envoy_config_endpoint_v3_ClusterStats_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_endpoint_v3_ClusterStats_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_endpoint_v3_ClusterStats_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_endpoint_v3_ClusterStats *envoy_config_endpoint_v3_ClusterStats_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_endpoint_v3_ClusterStats *ret = envoy_config_endpoint_v3_ClusterStats_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_endpoint_v3_ClusterStats_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_endpoint_v3_ClusterStats_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_endpoint_v3_ClusterStats_serialize(const envoy_config_endpoint_v3_ClusterStats *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_endpoint_v3_ClusterStats_msginit, arena, len);
@@ -336,13 +360,19 @@ UPB_INLINE envoy_config_endpoint_v3_ClusterStats_DroppedRequests *envoy_config_e
 UPB_INLINE envoy_config_endpoint_v3_ClusterStats_DroppedRequests *envoy_config_endpoint_v3_ClusterStats_DroppedRequests_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_endpoint_v3_ClusterStats_DroppedRequests *ret = envoy_config_endpoint_v3_ClusterStats_DroppedRequests_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_endpoint_v3_ClusterStats_DroppedRequests_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_endpoint_v3_ClusterStats_DroppedRequests_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_endpoint_v3_ClusterStats_DroppedRequests *envoy_config_endpoint_v3_ClusterStats_DroppedRequests_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_endpoint_v3_ClusterStats_DroppedRequests *ret = envoy_config_endpoint_v3_ClusterStats_DroppedRequests_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_endpoint_v3_ClusterStats_DroppedRequests_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_endpoint_v3_ClusterStats_DroppedRequests_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_endpoint_v3_ClusterStats_DroppedRequests_serialize(const envoy_config_endpoint_v3_ClusterStats_DroppedRequests *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_endpoint_v3_ClusterStats_DroppedRequests_msginit, arena, len);
index e016fff..0c19654 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/config/listener/v3/api_listener.upb.h"
 #include "google/protobuf/any.upb.h"
 #include "udpa/annotations/status.upb.h"
@@ -20,13 +20,13 @@ static const upb_msglayout *const envoy_config_listener_v3_ApiListener_submsgs[1
 };
 
 static const upb_msglayout_field envoy_config_listener_v3_ApiListener__fields[1] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_listener_v3_ApiListener_msginit = {
   &envoy_config_listener_v3_ApiListener_submsgs[0],
   &envoy_config_listener_v3_ApiListener__fields[0],
-  UPB_SIZE(8, 16), 1, false, 255,
+  UPB_SIZE(8, 16), 1, false, 1, 255,
 };
 
 #include "upb/port_undef.inc"
index 9d1372b..ba821ff 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_CONFIG_LISTENER_V3_API_LISTENER_PROTO_UPB_H_
 #define ENVOY_CONFIG_LISTENER_V3_API_LISTENER_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -35,13 +35,19 @@ UPB_INLINE envoy_config_listener_v3_ApiListener *envoy_config_listener_v3_ApiLis
 UPB_INLINE envoy_config_listener_v3_ApiListener *envoy_config_listener_v3_ApiListener_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_listener_v3_ApiListener *ret = envoy_config_listener_v3_ApiListener_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_listener_v3_ApiListener_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_listener_v3_ApiListener_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_listener_v3_ApiListener *envoy_config_listener_v3_ApiListener_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_listener_v3_ApiListener *ret = envoy_config_listener_v3_ApiListener_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_listener_v3_ApiListener_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_listener_v3_ApiListener_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_listener_v3_ApiListener_serialize(const envoy_config_listener_v3_ApiListener *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_listener_v3_ApiListener_msginit, arena, len);
index a75126b..ad006ed 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/config/listener/v3/listener.upb.h"
 #include "envoy/config/accesslog/v3/accesslog.upb.h"
 #include "envoy/config/core/v3/address.upb.h"
@@ -32,13 +32,13 @@ static const upb_msglayout *const envoy_config_listener_v3_ListenerCollection_su
 };
 
 static const upb_msglayout_field envoy_config_listener_v3_ListenerCollection__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 11, 3},
+  {1, UPB_SIZE(0, 0), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout envoy_config_listener_v3_ListenerCollection_msginit = {
   &envoy_config_listener_v3_ListenerCollection_submsgs[0],
   &envoy_config_listener_v3_ListenerCollection__fields[0],
-  UPB_SIZE(8, 8), 1, false, 255,
+  UPB_SIZE(8, 8), 1, false, 1, 255,
 };
 
 static const upb_msglayout *const envoy_config_listener_v3_Listener_submsgs[14] = {
@@ -59,39 +59,39 @@ static const upb_msglayout *const envoy_config_listener_v3_Listener_submsgs[14]
 };
 
 static const upb_msglayout_field envoy_config_listener_v3_Listener__fields[27] = {
-  {1, UPB_SIZE(16, 16), 0, 0, 9, 1},
-  {2, UPB_SIZE(32, 48), 1, 1, 11, 1},
-  {3, UPB_SIZE(96, 176), 0, 5, 11, 3},
-  {4, UPB_SIZE(36, 56), 2, 11, 11, 1},
-  {5, UPB_SIZE(40, 64), 3, 13, 11, 1},
-  {6, UPB_SIZE(44, 72), 4, 2, 11, 1},
-  {7, UPB_SIZE(48, 80), 5, 7, 11, 1},
-  {8, UPB_SIZE(4, 4), 0, 0, 14, 1},
-  {9, UPB_SIZE(100, 184), 0, 9, 11, 3},
-  {10, UPB_SIZE(52, 88), 6, 11, 11, 1},
-  {11, UPB_SIZE(56, 96), 7, 11, 11, 1},
-  {12, UPB_SIZE(60, 104), 8, 13, 11, 1},
-  {13, UPB_SIZE(104, 192), 0, 3, 11, 3},
-  {15, UPB_SIZE(64, 112), 9, 12, 11, 1},
-  {16, UPB_SIZE(8, 8), 0, 0, 14, 1},
-  {17, UPB_SIZE(12, 12), 0, 0, 8, 1},
-  {18, UPB_SIZE(68, 120), 10, 10, 11, 1},
-  {19, UPB_SIZE(72, 128), 11, 4, 11, 1},
-  {20, UPB_SIZE(76, 136), 12, 6, 11, 1},
-  {21, UPB_SIZE(13, 13), 0, 0, 8, 1},
-  {22, UPB_SIZE(108, 200), 0, 0, 11, 3},
-  {24, UPB_SIZE(80, 144), 13, 13, 11, 1},
-  {25, UPB_SIZE(84, 152), 14, 5, 11, 1},
-  {26, UPB_SIZE(88, 160), 15, 11, 11, 1},
-  {27, UPB_SIZE(112, 208), UPB_SIZE(-117, -217), 8, 11, 1},
-  {28, UPB_SIZE(24, 32), 0, 0, 9, 1},
-  {29, UPB_SIZE(92, 168), 16, 11, 11, 1},
+  {1, UPB_SIZE(16, 16), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(32, 48), 1, 1, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(96, 176), 0, 5, 11, _UPB_MODE_ARRAY},
+  {4, UPB_SIZE(36, 56), 2, 11, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(40, 64), 3, 13, 11, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(44, 72), 4, 2, 11, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(48, 80), 5, 7, 11, _UPB_MODE_SCALAR},
+  {8, UPB_SIZE(4, 4), 0, 0, 14, _UPB_MODE_SCALAR},
+  {9, UPB_SIZE(100, 184), 0, 9, 11, _UPB_MODE_ARRAY},
+  {10, UPB_SIZE(52, 88), 6, 11, 11, _UPB_MODE_SCALAR},
+  {11, UPB_SIZE(56, 96), 7, 11, 11, _UPB_MODE_SCALAR},
+  {12, UPB_SIZE(60, 104), 8, 13, 11, _UPB_MODE_SCALAR},
+  {13, UPB_SIZE(104, 192), 0, 3, 11, _UPB_MODE_ARRAY},
+  {15, UPB_SIZE(64, 112), 9, 12, 11, _UPB_MODE_SCALAR},
+  {16, UPB_SIZE(8, 8), 0, 0, 14, _UPB_MODE_SCALAR},
+  {17, UPB_SIZE(12, 12), 0, 0, 8, _UPB_MODE_SCALAR},
+  {18, UPB_SIZE(68, 120), 10, 10, 11, _UPB_MODE_SCALAR},
+  {19, UPB_SIZE(72, 128), 11, 4, 11, _UPB_MODE_SCALAR},
+  {20, UPB_SIZE(76, 136), 12, 6, 11, _UPB_MODE_SCALAR},
+  {21, UPB_SIZE(13, 13), 0, 0, 8, _UPB_MODE_SCALAR},
+  {22, UPB_SIZE(108, 200), 0, 0, 11, _UPB_MODE_ARRAY},
+  {24, UPB_SIZE(80, 144), 13, 13, 11, _UPB_MODE_SCALAR},
+  {25, UPB_SIZE(84, 152), 14, 5, 11, _UPB_MODE_SCALAR},
+  {26, UPB_SIZE(88, 160), 15, 11, 11, _UPB_MODE_SCALAR},
+  {27, UPB_SIZE(112, 208), UPB_SIZE(-117, -217), 8, 11, _UPB_MODE_SCALAR},
+  {28, UPB_SIZE(24, 32), 0, 0, 9, _UPB_MODE_SCALAR},
+  {29, UPB_SIZE(92, 168), 16, 11, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_listener_v3_Listener_msginit = {
   &envoy_config_listener_v3_Listener_submsgs[0],
   &envoy_config_listener_v3_Listener__fields[0],
-  UPB_SIZE(120, 224), 27, false, 255,
+  UPB_SIZE(120, 224), 27, false, 13, 255,
 };
 
 static const upb_msglayout *const envoy_config_listener_v3_Listener_DeprecatedV1_submsgs[1] = {
@@ -99,13 +99,13 @@ static const upb_msglayout *const envoy_config_listener_v3_Listener_DeprecatedV1
 };
 
 static const upb_msglayout_field envoy_config_listener_v3_Listener_DeprecatedV1__fields[1] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_listener_v3_Listener_DeprecatedV1_msginit = {
   &envoy_config_listener_v3_Listener_DeprecatedV1_submsgs[0],
   &envoy_config_listener_v3_Listener_DeprecatedV1__fields[0],
-  UPB_SIZE(8, 16), 1, false, 255,
+  UPB_SIZE(8, 16), 1, false, 1, 255,
 };
 
 static const upb_msglayout *const envoy_config_listener_v3_Listener_ConnectionBalanceConfig_submsgs[1] = {
@@ -113,25 +113,25 @@ static const upb_msglayout *const envoy_config_listener_v3_Listener_ConnectionBa
 };
 
 static const upb_msglayout_field envoy_config_listener_v3_Listener_ConnectionBalanceConfig__fields[1] = {
-  {1, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 11, 1},
+  {1, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_listener_v3_Listener_ConnectionBalanceConfig_msginit = {
   &envoy_config_listener_v3_Listener_ConnectionBalanceConfig_submsgs[0],
   &envoy_config_listener_v3_Listener_ConnectionBalanceConfig__fields[0],
-  UPB_SIZE(8, 16), 1, false, 255,
+  UPB_SIZE(8, 16), 1, false, 1, 255,
 };
 
 const upb_msglayout envoy_config_listener_v3_Listener_ConnectionBalanceConfig_ExactBalance_msginit = {
   NULL,
   NULL,
-  UPB_SIZE(0, 0), 0, false, 255,
+  UPB_SIZE(0, 0), 0, false, 0, 255,
 };
 
 const upb_msglayout envoy_config_listener_v3_Listener_InternalListenerConfig_msginit = {
   NULL,
   NULL,
-  UPB_SIZE(0, 0), 0, false, 255,
+  UPB_SIZE(0, 0), 0, false, 0, 255,
 };
 
 #include "upb/port_undef.inc"
index 56a7f7c..3842168 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_CONFIG_LISTENER_V3_LISTENER_PROTO_UPB_H_
 #define ENVOY_CONFIG_LISTENER_V3_LISTENER_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -77,13 +77,19 @@ UPB_INLINE envoy_config_listener_v3_ListenerCollection *envoy_config_listener_v3
 UPB_INLINE envoy_config_listener_v3_ListenerCollection *envoy_config_listener_v3_ListenerCollection_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_listener_v3_ListenerCollection *ret = envoy_config_listener_v3_ListenerCollection_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_listener_v3_ListenerCollection_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_listener_v3_ListenerCollection_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_listener_v3_ListenerCollection *envoy_config_listener_v3_ListenerCollection_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_listener_v3_ListenerCollection *ret = envoy_config_listener_v3_ListenerCollection_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_listener_v3_ListenerCollection_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_listener_v3_ListenerCollection_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_listener_v3_ListenerCollection_serialize(const envoy_config_listener_v3_ListenerCollection *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_listener_v3_ListenerCollection_msginit, arena, len);
@@ -114,13 +120,19 @@ UPB_INLINE envoy_config_listener_v3_Listener *envoy_config_listener_v3_Listener_
 UPB_INLINE envoy_config_listener_v3_Listener *envoy_config_listener_v3_Listener_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_listener_v3_Listener *ret = envoy_config_listener_v3_Listener_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_listener_v3_Listener_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_listener_v3_Listener_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_listener_v3_Listener *envoy_config_listener_v3_Listener_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_listener_v3_Listener *ret = envoy_config_listener_v3_Listener_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_listener_v3_Listener_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_listener_v3_Listener_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_listener_v3_Listener_serialize(const envoy_config_listener_v3_Listener *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_listener_v3_Listener_msginit, arena, len);
@@ -480,13 +492,19 @@ UPB_INLINE envoy_config_listener_v3_Listener_DeprecatedV1 *envoy_config_listener
 UPB_INLINE envoy_config_listener_v3_Listener_DeprecatedV1 *envoy_config_listener_v3_Listener_DeprecatedV1_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_listener_v3_Listener_DeprecatedV1 *ret = envoy_config_listener_v3_Listener_DeprecatedV1_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_listener_v3_Listener_DeprecatedV1_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_listener_v3_Listener_DeprecatedV1_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_listener_v3_Listener_DeprecatedV1 *envoy_config_listener_v3_Listener_DeprecatedV1_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_listener_v3_Listener_DeprecatedV1 *ret = envoy_config_listener_v3_Listener_DeprecatedV1_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_listener_v3_Listener_DeprecatedV1_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_listener_v3_Listener_DeprecatedV1_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_listener_v3_Listener_DeprecatedV1_serialize(const envoy_config_listener_v3_Listener_DeprecatedV1 *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_listener_v3_Listener_DeprecatedV1_msginit, arena, len);
@@ -517,13 +535,19 @@ UPB_INLINE envoy_config_listener_v3_Listener_ConnectionBalanceConfig *envoy_conf
 UPB_INLINE envoy_config_listener_v3_Listener_ConnectionBalanceConfig *envoy_config_listener_v3_Listener_ConnectionBalanceConfig_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_listener_v3_Listener_ConnectionBalanceConfig *ret = envoy_config_listener_v3_Listener_ConnectionBalanceConfig_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_listener_v3_Listener_ConnectionBalanceConfig_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_listener_v3_Listener_ConnectionBalanceConfig_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_listener_v3_Listener_ConnectionBalanceConfig *envoy_config_listener_v3_Listener_ConnectionBalanceConfig_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_listener_v3_Listener_ConnectionBalanceConfig *ret = envoy_config_listener_v3_Listener_ConnectionBalanceConfig_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_listener_v3_Listener_ConnectionBalanceConfig_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_listener_v3_Listener_ConnectionBalanceConfig_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_listener_v3_Listener_ConnectionBalanceConfig_serialize(const envoy_config_listener_v3_Listener_ConnectionBalanceConfig *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_listener_v3_Listener_ConnectionBalanceConfig_msginit, arena, len);
@@ -559,13 +583,19 @@ UPB_INLINE envoy_config_listener_v3_Listener_ConnectionBalanceConfig_ExactBalanc
 UPB_INLINE envoy_config_listener_v3_Listener_ConnectionBalanceConfig_ExactBalance *envoy_config_listener_v3_Listener_ConnectionBalanceConfig_ExactBalance_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_listener_v3_Listener_ConnectionBalanceConfig_ExactBalance *ret = envoy_config_listener_v3_Listener_ConnectionBalanceConfig_ExactBalance_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_listener_v3_Listener_ConnectionBalanceConfig_ExactBalance_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_listener_v3_Listener_ConnectionBalanceConfig_ExactBalance_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_listener_v3_Listener_ConnectionBalanceConfig_ExactBalance *envoy_config_listener_v3_Listener_ConnectionBalanceConfig_ExactBalance_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_listener_v3_Listener_ConnectionBalanceConfig_ExactBalance *ret = envoy_config_listener_v3_Listener_ConnectionBalanceConfig_ExactBalance_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_listener_v3_Listener_ConnectionBalanceConfig_ExactBalance_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_listener_v3_Listener_ConnectionBalanceConfig_ExactBalance_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_listener_v3_Listener_ConnectionBalanceConfig_ExactBalance_serialize(const envoy_config_listener_v3_Listener_ConnectionBalanceConfig_ExactBalance *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_listener_v3_Listener_ConnectionBalanceConfig_ExactBalance_msginit, arena, len);
@@ -581,13 +611,19 @@ UPB_INLINE envoy_config_listener_v3_Listener_InternalListenerConfig *envoy_confi
 UPB_INLINE envoy_config_listener_v3_Listener_InternalListenerConfig *envoy_config_listener_v3_Listener_InternalListenerConfig_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_listener_v3_Listener_InternalListenerConfig *ret = envoy_config_listener_v3_Listener_InternalListenerConfig_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_listener_v3_Listener_InternalListenerConfig_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_listener_v3_Listener_InternalListenerConfig_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_listener_v3_Listener_InternalListenerConfig *envoy_config_listener_v3_Listener_InternalListenerConfig_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_listener_v3_Listener_InternalListenerConfig *ret = envoy_config_listener_v3_Listener_InternalListenerConfig_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_listener_v3_Listener_InternalListenerConfig_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_listener_v3_Listener_InternalListenerConfig_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_listener_v3_Listener_InternalListenerConfig_serialize(const envoy_config_listener_v3_Listener_InternalListenerConfig *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_listener_v3_Listener_InternalListenerConfig_msginit, arena, len);
index e31eab4..dda5ed7 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/config/listener/v3/listener_components.upb.h"
 #include "envoy/config/core/v3/address.upb.h"
 #include "envoy/config/core/v3/base.upb.h"
@@ -29,15 +29,15 @@ static const upb_msglayout *const envoy_config_listener_v3_Filter_submsgs[2] = {
 };
 
 static const upb_msglayout_field envoy_config_listener_v3_Filter__fields[3] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {4, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 1, 11, 1},
-  {5, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 0, 11, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 1, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_listener_v3_Filter_msginit = {
   &envoy_config_listener_v3_Filter_submsgs[0],
   &envoy_config_listener_v3_Filter__fields[0],
-  UPB_SIZE(16, 32), 3, false, 255,
+  UPB_SIZE(16, 32), 3, false, 1, 255,
 };
 
 static const upb_msglayout *const envoy_config_listener_v3_FilterChainMatch_submsgs[2] = {
@@ -46,23 +46,23 @@ static const upb_msglayout *const envoy_config_listener_v3_FilterChainMatch_subm
 };
 
 static const upb_msglayout_field envoy_config_listener_v3_FilterChainMatch__fields[11] = {
-  {3, UPB_SIZE(32, 56), 0, 0, 11, 3},
-  {4, UPB_SIZE(8, 8), 0, 0, 9, 1},
-  {5, UPB_SIZE(24, 40), 1, 1, 11, 1},
-  {6, UPB_SIZE(36, 64), 0, 0, 11, 3},
-  {7, UPB_SIZE(40, 72), 0, 0, 13, _UPB_LABEL_PACKED},
-  {8, UPB_SIZE(28, 48), 2, 1, 11, 1},
-  {9, UPB_SIZE(16, 24), 0, 0, 9, 1},
-  {10, UPB_SIZE(44, 80), 0, 0, 9, 3},
-  {11, UPB_SIZE(48, 88), 0, 0, 9, 3},
-  {12, UPB_SIZE(4, 4), 0, 0, 14, 1},
-  {13, UPB_SIZE(52, 96), 0, 0, 11, 3},
+  {3, UPB_SIZE(32, 56), 0, 0, 11, _UPB_MODE_ARRAY},
+  {4, UPB_SIZE(8, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(24, 40), 1, 1, 11, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(36, 64), 0, 0, 11, _UPB_MODE_ARRAY},
+  {7, UPB_SIZE(40, 72), 0, 0, 13, _UPB_MODE_ARRAY | _UPB_MODE_IS_PACKED},
+  {8, UPB_SIZE(28, 48), 2, 1, 11, _UPB_MODE_SCALAR},
+  {9, UPB_SIZE(16, 24), 0, 0, 9, _UPB_MODE_SCALAR},
+  {10, UPB_SIZE(44, 80), 0, 0, 9, _UPB_MODE_ARRAY},
+  {11, UPB_SIZE(48, 88), 0, 0, 9, _UPB_MODE_ARRAY},
+  {12, UPB_SIZE(4, 4), 0, 0, 14, _UPB_MODE_SCALAR},
+  {13, UPB_SIZE(52, 96), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout envoy_config_listener_v3_FilterChainMatch_msginit = {
   &envoy_config_listener_v3_FilterChainMatch_submsgs[0],
   &envoy_config_listener_v3_FilterChainMatch__fields[0],
-  UPB_SIZE(56, 112), 11, false, 255,
+  UPB_SIZE(56, 112), 11, false, 0, 255,
 };
 
 static const upb_msglayout *const envoy_config_listener_v3_FilterChain_submsgs[7] = {
@@ -76,20 +76,20 @@ static const upb_msglayout *const envoy_config_listener_v3_FilterChain_submsgs[7
 };
 
 static const upb_msglayout_field envoy_config_listener_v3_FilterChain__fields[8] = {
-  {1, UPB_SIZE(12, 24), 1, 4, 11, 1},
-  {3, UPB_SIZE(36, 72), 0, 2, 11, 3},
-  {4, UPB_SIZE(16, 32), 2, 5, 11, 1},
-  {5, UPB_SIZE(20, 40), 3, 0, 11, 1},
-  {6, UPB_SIZE(24, 48), 4, 1, 11, 1},
-  {7, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {8, UPB_SIZE(28, 56), 5, 3, 11, 1},
-  {9, UPB_SIZE(32, 64), 6, 6, 11, 1},
+  {1, UPB_SIZE(12, 24), 1, 4, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(36, 72), 0, 2, 11, _UPB_MODE_ARRAY},
+  {4, UPB_SIZE(16, 32), 2, 5, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(20, 40), 3, 0, 11, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(24, 48), 4, 1, 11, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {8, UPB_SIZE(28, 56), 5, 3, 11, _UPB_MODE_SCALAR},
+  {9, UPB_SIZE(32, 64), 6, 6, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_listener_v3_FilterChain_msginit = {
   &envoy_config_listener_v3_FilterChain_submsgs[0],
   &envoy_config_listener_v3_FilterChain__fields[0],
-  UPB_SIZE(40, 80), 8, false, 255,
+  UPB_SIZE(40, 80), 8, false, 1, 255,
 };
 
 static const upb_msglayout *const envoy_config_listener_v3_FilterChain_OnDemandConfiguration_submsgs[1] = {
@@ -97,13 +97,13 @@ static const upb_msglayout *const envoy_config_listener_v3_FilterChain_OnDemandC
 };
 
 static const upb_msglayout_field envoy_config_listener_v3_FilterChain_OnDemandConfiguration__fields[1] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_listener_v3_FilterChain_OnDemandConfiguration_msginit = {
   &envoy_config_listener_v3_FilterChain_OnDemandConfiguration_submsgs[0],
   &envoy_config_listener_v3_FilterChain_OnDemandConfiguration__fields[0],
-  UPB_SIZE(8, 16), 1, false, 255,
+  UPB_SIZE(8, 16), 1, false, 1, 255,
 };
 
 static const upb_msglayout *const envoy_config_listener_v3_ListenerFilterChainMatchPredicate_submsgs[3] = {
@@ -113,17 +113,17 @@ static const upb_msglayout *const envoy_config_listener_v3_ListenerFilterChainMa
 };
 
 static const upb_msglayout_field envoy_config_listener_v3_ListenerFilterChainMatchPredicate__fields[5] = {
-  {1, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 1, 11, 1},
-  {2, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 1, 11, 1},
-  {3, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 11, 1},
-  {4, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 8, 1},
-  {5, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 2, 11, 1},
+  {1, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 1, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 1, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 8, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 2, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_listener_v3_ListenerFilterChainMatchPredicate_msginit = {
   &envoy_config_listener_v3_ListenerFilterChainMatchPredicate_submsgs[0],
   &envoy_config_listener_v3_ListenerFilterChainMatchPredicate__fields[0],
-  UPB_SIZE(8, 16), 5, false, 255,
+  UPB_SIZE(8, 16), 5, false, 5, 255,
 };
 
 static const upb_msglayout *const envoy_config_listener_v3_ListenerFilterChainMatchPredicate_MatchSet_submsgs[1] = {
@@ -131,13 +131,13 @@ static const upb_msglayout *const envoy_config_listener_v3_ListenerFilterChainMa
 };
 
 static const upb_msglayout_field envoy_config_listener_v3_ListenerFilterChainMatchPredicate_MatchSet__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 11, 3},
+  {1, UPB_SIZE(0, 0), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout envoy_config_listener_v3_ListenerFilterChainMatchPredicate_MatchSet_msginit = {
   &envoy_config_listener_v3_ListenerFilterChainMatchPredicate_MatchSet_submsgs[0],
   &envoy_config_listener_v3_ListenerFilterChainMatchPredicate_MatchSet__fields[0],
-  UPB_SIZE(8, 8), 1, false, 255,
+  UPB_SIZE(8, 8), 1, false, 1, 255,
 };
 
 static const upb_msglayout *const envoy_config_listener_v3_ListenerFilter_submsgs[2] = {
@@ -146,15 +146,15 @@ static const upb_msglayout *const envoy_config_listener_v3_ListenerFilter_submsg
 };
 
 static const upb_msglayout_field envoy_config_listener_v3_ListenerFilter__fields[3] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {3, UPB_SIZE(16, 32), UPB_SIZE(-21, -41), 1, 11, 1},
-  {4, UPB_SIZE(12, 24), 1, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(16, 32), UPB_SIZE(-21, -41), 1, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(12, 24), 1, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_listener_v3_ListenerFilter_msginit = {
   &envoy_config_listener_v3_ListenerFilter_submsgs[0],
   &envoy_config_listener_v3_ListenerFilter__fields[0],
-  UPB_SIZE(24, 48), 3, false, 255,
+  UPB_SIZE(24, 48), 3, false, 1, 255,
 };
 
 #include "upb/port_undef.inc"
index f8ff808..17afbdc 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_CONFIG_LISTENER_V3_LISTENER_COMPONENTS_PROTO_UPB_H_
 #define ENVOY_CONFIG_LISTENER_V3_LISTENER_COMPONENTS_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -75,13 +75,19 @@ UPB_INLINE envoy_config_listener_v3_Filter *envoy_config_listener_v3_Filter_new(
 UPB_INLINE envoy_config_listener_v3_Filter *envoy_config_listener_v3_Filter_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_listener_v3_Filter *ret = envoy_config_listener_v3_Filter_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_listener_v3_Filter_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_listener_v3_Filter_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_listener_v3_Filter *envoy_config_listener_v3_Filter_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_listener_v3_Filter *ret = envoy_config_listener_v3_Filter_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_listener_v3_Filter_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_listener_v3_Filter_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_listener_v3_Filter_serialize(const envoy_config_listener_v3_Filter *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_listener_v3_Filter_msginit, arena, len);
@@ -136,13 +142,19 @@ UPB_INLINE envoy_config_listener_v3_FilterChainMatch *envoy_config_listener_v3_F
 UPB_INLINE envoy_config_listener_v3_FilterChainMatch *envoy_config_listener_v3_FilterChainMatch_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_listener_v3_FilterChainMatch *ret = envoy_config_listener_v3_FilterChainMatch_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_listener_v3_FilterChainMatch_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_listener_v3_FilterChainMatch_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_listener_v3_FilterChainMatch *envoy_config_listener_v3_FilterChainMatch_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_listener_v3_FilterChainMatch *ret = envoy_config_listener_v3_FilterChainMatch_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_listener_v3_FilterChainMatch_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_listener_v3_FilterChainMatch_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_listener_v3_FilterChainMatch_serialize(const envoy_config_listener_v3_FilterChainMatch *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_listener_v3_FilterChainMatch_msginit, arena, len);
@@ -278,13 +290,19 @@ UPB_INLINE envoy_config_listener_v3_FilterChain *envoy_config_listener_v3_Filter
 UPB_INLINE envoy_config_listener_v3_FilterChain *envoy_config_listener_v3_FilterChain_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_listener_v3_FilterChain *ret = envoy_config_listener_v3_FilterChain_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_listener_v3_FilterChain_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_listener_v3_FilterChain_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_listener_v3_FilterChain *envoy_config_listener_v3_FilterChain_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_listener_v3_FilterChain *ret = envoy_config_listener_v3_FilterChain_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_listener_v3_FilterChain_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_listener_v3_FilterChain_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_listener_v3_FilterChain_serialize(const envoy_config_listener_v3_FilterChain *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_listener_v3_FilterChain_msginit, arena, len);
@@ -409,13 +427,19 @@ UPB_INLINE envoy_config_listener_v3_FilterChain_OnDemandConfiguration *envoy_con
 UPB_INLINE envoy_config_listener_v3_FilterChain_OnDemandConfiguration *envoy_config_listener_v3_FilterChain_OnDemandConfiguration_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_listener_v3_FilterChain_OnDemandConfiguration *ret = envoy_config_listener_v3_FilterChain_OnDemandConfiguration_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_listener_v3_FilterChain_OnDemandConfiguration_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_listener_v3_FilterChain_OnDemandConfiguration_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_listener_v3_FilterChain_OnDemandConfiguration *envoy_config_listener_v3_FilterChain_OnDemandConfiguration_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_listener_v3_FilterChain_OnDemandConfiguration *ret = envoy_config_listener_v3_FilterChain_OnDemandConfiguration_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_listener_v3_FilterChain_OnDemandConfiguration_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_listener_v3_FilterChain_OnDemandConfiguration_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_listener_v3_FilterChain_OnDemandConfiguration_serialize(const envoy_config_listener_v3_FilterChain_OnDemandConfiguration *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_listener_v3_FilterChain_OnDemandConfiguration_msginit, arena, len);
@@ -446,13 +470,19 @@ UPB_INLINE envoy_config_listener_v3_ListenerFilterChainMatchPredicate *envoy_con
 UPB_INLINE envoy_config_listener_v3_ListenerFilterChainMatchPredicate *envoy_config_listener_v3_ListenerFilterChainMatchPredicate_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_listener_v3_ListenerFilterChainMatchPredicate *ret = envoy_config_listener_v3_ListenerFilterChainMatchPredicate_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_listener_v3_ListenerFilterChainMatchPredicate_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_listener_v3_ListenerFilterChainMatchPredicate_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_listener_v3_ListenerFilterChainMatchPredicate *envoy_config_listener_v3_ListenerFilterChainMatchPredicate_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_listener_v3_ListenerFilterChainMatchPredicate *ret = envoy_config_listener_v3_ListenerFilterChainMatchPredicate_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_listener_v3_ListenerFilterChainMatchPredicate_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_listener_v3_ListenerFilterChainMatchPredicate_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_listener_v3_ListenerFilterChainMatchPredicate_serialize(const envoy_config_listener_v3_ListenerFilterChainMatchPredicate *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_listener_v3_ListenerFilterChainMatchPredicate_msginit, arena, len);
@@ -539,13 +569,19 @@ UPB_INLINE envoy_config_listener_v3_ListenerFilterChainMatchPredicate_MatchSet *
 UPB_INLINE envoy_config_listener_v3_ListenerFilterChainMatchPredicate_MatchSet *envoy_config_listener_v3_ListenerFilterChainMatchPredicate_MatchSet_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_listener_v3_ListenerFilterChainMatchPredicate_MatchSet *ret = envoy_config_listener_v3_ListenerFilterChainMatchPredicate_MatchSet_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_listener_v3_ListenerFilterChainMatchPredicate_MatchSet_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_listener_v3_ListenerFilterChainMatchPredicate_MatchSet_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_listener_v3_ListenerFilterChainMatchPredicate_MatchSet *envoy_config_listener_v3_ListenerFilterChainMatchPredicate_MatchSet_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_listener_v3_ListenerFilterChainMatchPredicate_MatchSet *ret = envoy_config_listener_v3_ListenerFilterChainMatchPredicate_MatchSet_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_listener_v3_ListenerFilterChainMatchPredicate_MatchSet_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_listener_v3_ListenerFilterChainMatchPredicate_MatchSet_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_listener_v3_ListenerFilterChainMatchPredicate_MatchSet_serialize(const envoy_config_listener_v3_ListenerFilterChainMatchPredicate_MatchSet *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_listener_v3_ListenerFilterChainMatchPredicate_MatchSet_msginit, arena, len);
@@ -576,13 +612,19 @@ UPB_INLINE envoy_config_listener_v3_ListenerFilter *envoy_config_listener_v3_Lis
 UPB_INLINE envoy_config_listener_v3_ListenerFilter *envoy_config_listener_v3_ListenerFilter_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_listener_v3_ListenerFilter *ret = envoy_config_listener_v3_ListenerFilter_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_listener_v3_ListenerFilter_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_listener_v3_ListenerFilter_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_listener_v3_ListenerFilter *envoy_config_listener_v3_ListenerFilter_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_listener_v3_ListenerFilter *ret = envoy_config_listener_v3_ListenerFilter_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_listener_v3_ListenerFilter_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_listener_v3_ListenerFilter_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_listener_v3_ListenerFilter_serialize(const envoy_config_listener_v3_ListenerFilter *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_listener_v3_ListenerFilter_msginit, arena, len);
index 5ecd130..7e3cdb0 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/config/listener/v3/quic_config.upb.h"
 #include "envoy/config/core/v3/base.upb.h"
 #include "envoy/config/core/v3/extension.upb.h"
@@ -29,19 +29,19 @@ static const upb_msglayout *const envoy_config_listener_v3_QuicProtocolOptions_s
 };
 
 static const upb_msglayout_field envoy_config_listener_v3_QuicProtocolOptions__fields[7] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
-  {2, UPB_SIZE(8, 16), 2, 3, 11, 1},
-  {3, UPB_SIZE(12, 24), 3, 3, 11, 1},
-  {4, UPB_SIZE(16, 32), 4, 1, 11, 1},
-  {5, UPB_SIZE(20, 40), 5, 4, 11, 1},
-  {6, UPB_SIZE(24, 48), 6, 2, 11, 1},
-  {7, UPB_SIZE(28, 56), 7, 2, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 2, 3, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(12, 24), 3, 3, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(16, 32), 4, 1, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(20, 40), 5, 4, 11, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(24, 48), 6, 2, 11, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(28, 56), 7, 2, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_listener_v3_QuicProtocolOptions_msginit = {
   &envoy_config_listener_v3_QuicProtocolOptions_submsgs[0],
   &envoy_config_listener_v3_QuicProtocolOptions__fields[0],
-  UPB_SIZE(32, 64), 7, false, 255,
+  UPB_SIZE(32, 64), 7, false, 7, 255,
 };
 
 #include "upb/port_undef.inc"
index a2fb916..8a0f954 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_CONFIG_LISTENER_V3_QUIC_CONFIG_PROTO_UPB_H_
 #define ENVOY_CONFIG_LISTENER_V3_QUIC_CONFIG_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -43,13 +43,19 @@ UPB_INLINE envoy_config_listener_v3_QuicProtocolOptions *envoy_config_listener_v
 UPB_INLINE envoy_config_listener_v3_QuicProtocolOptions *envoy_config_listener_v3_QuicProtocolOptions_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_listener_v3_QuicProtocolOptions *ret = envoy_config_listener_v3_QuicProtocolOptions_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_listener_v3_QuicProtocolOptions_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_listener_v3_QuicProtocolOptions_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_listener_v3_QuicProtocolOptions *envoy_config_listener_v3_QuicProtocolOptions_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_listener_v3_QuicProtocolOptions *ret = envoy_config_listener_v3_QuicProtocolOptions_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_listener_v3_QuicProtocolOptions_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_listener_v3_QuicProtocolOptions_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_listener_v3_QuicProtocolOptions_serialize(const envoy_config_listener_v3_QuicProtocolOptions *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_listener_v3_QuicProtocolOptions_msginit, arena, len);
index 14dcdbf..b34cac3 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/config/listener/v3/udp_listener_config.upb.h"
 #include "envoy/config/core/v3/udp_socket_config.upb.h"
 #include "envoy/config/listener/v3/quic_config.upb.h"
@@ -22,20 +22,20 @@ static const upb_msglayout *const envoy_config_listener_v3_UdpListenerConfig_sub
 };
 
 static const upb_msglayout_field envoy_config_listener_v3_UdpListenerConfig__fields[2] = {
-  {5, UPB_SIZE(4, 8), 1, 0, 11, 1},
-  {7, UPB_SIZE(8, 16), 2, 1, 11, 1},
+  {5, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(8, 16), 2, 1, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_listener_v3_UdpListenerConfig_msginit = {
   &envoy_config_listener_v3_UdpListenerConfig_submsgs[0],
   &envoy_config_listener_v3_UdpListenerConfig__fields[0],
-  UPB_SIZE(16, 24), 2, false, 255,
+  UPB_SIZE(16, 24), 2, false, 0, 255,
 };
 
 const upb_msglayout envoy_config_listener_v3_ActiveRawUdpListenerConfig_msginit = {
   NULL,
   NULL,
-  UPB_SIZE(0, 0), 0, false, 255,
+  UPB_SIZE(0, 0), 0, false, 0, 255,
 };
 
 #include "upb/port_undef.inc"
index 7dc472d..0f28467 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_CONFIG_LISTENER_V3_UDP_LISTENER_CONFIG_PROTO_UPB_H_
 #define ENVOY_CONFIG_LISTENER_V3_UDP_LISTENER_CONFIG_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -40,13 +40,19 @@ UPB_INLINE envoy_config_listener_v3_UdpListenerConfig *envoy_config_listener_v3_
 UPB_INLINE envoy_config_listener_v3_UdpListenerConfig *envoy_config_listener_v3_UdpListenerConfig_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_listener_v3_UdpListenerConfig *ret = envoy_config_listener_v3_UdpListenerConfig_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_listener_v3_UdpListenerConfig_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_listener_v3_UdpListenerConfig_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_listener_v3_UdpListenerConfig *envoy_config_listener_v3_UdpListenerConfig_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_listener_v3_UdpListenerConfig *ret = envoy_config_listener_v3_UdpListenerConfig_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_listener_v3_UdpListenerConfig_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_listener_v3_UdpListenerConfig_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_listener_v3_UdpListenerConfig_serialize(const envoy_config_listener_v3_UdpListenerConfig *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_listener_v3_UdpListenerConfig_msginit, arena, len);
@@ -92,13 +98,19 @@ UPB_INLINE envoy_config_listener_v3_ActiveRawUdpListenerConfig *envoy_config_lis
 UPB_INLINE envoy_config_listener_v3_ActiveRawUdpListenerConfig *envoy_config_listener_v3_ActiveRawUdpListenerConfig_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_listener_v3_ActiveRawUdpListenerConfig *ret = envoy_config_listener_v3_ActiveRawUdpListenerConfig_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_listener_v3_ActiveRawUdpListenerConfig_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_listener_v3_ActiveRawUdpListenerConfig_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_listener_v3_ActiveRawUdpListenerConfig *envoy_config_listener_v3_ActiveRawUdpListenerConfig_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_listener_v3_ActiveRawUdpListenerConfig *ret = envoy_config_listener_v3_ActiveRawUdpListenerConfig_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_listener_v3_ActiveRawUdpListenerConfig_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_listener_v3_ActiveRawUdpListenerConfig_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_listener_v3_ActiveRawUdpListenerConfig_serialize(const envoy_config_listener_v3_ActiveRawUdpListenerConfig *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_listener_v3_ActiveRawUdpListenerConfig_msginit, arena, len);
index 26d00f1..d92cf58 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/config/metrics/v3/stats.upb.h"
 #include "envoy/config/core/v3/address.upb.h"
 #include "envoy/type/matcher/v3/string.upb.h"
@@ -24,14 +24,14 @@ static const upb_msglayout *const envoy_config_metrics_v3_StatsSink_submsgs[1] =
 };
 
 static const upb_msglayout_field envoy_config_metrics_v3_StatsSink__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {3, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 0, 11, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_metrics_v3_StatsSink_msginit = {
   &envoy_config_metrics_v3_StatsSink_submsgs[0],
   &envoy_config_metrics_v3_StatsSink__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 1, 255,
 };
 
 static const upb_msglayout *const envoy_config_metrics_v3_StatsConfig_submsgs[4] = {
@@ -42,16 +42,16 @@ static const upb_msglayout *const envoy_config_metrics_v3_StatsConfig_submsgs[4]
 };
 
 static const upb_msglayout_field envoy_config_metrics_v3_StatsConfig__fields[4] = {
-  {1, UPB_SIZE(12, 24), 0, 2, 11, 3},
-  {2, UPB_SIZE(4, 8), 1, 3, 11, 1},
-  {3, UPB_SIZE(8, 16), 2, 1, 11, 1},
-  {4, UPB_SIZE(16, 32), 0, 0, 11, 3},
+  {1, UPB_SIZE(12, 24), 0, 2, 11, _UPB_MODE_ARRAY},
+  {2, UPB_SIZE(4, 8), 1, 3, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(8, 16), 2, 1, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(16, 32), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout envoy_config_metrics_v3_StatsConfig_msginit = {
   &envoy_config_metrics_v3_StatsConfig_submsgs[0],
   &envoy_config_metrics_v3_StatsConfig__fields[0],
-  UPB_SIZE(24, 40), 4, false, 255,
+  UPB_SIZE(24, 40), 4, false, 4, 255,
 };
 
 static const upb_msglayout *const envoy_config_metrics_v3_StatsMatcher_submsgs[1] = {
@@ -59,27 +59,27 @@ static const upb_msglayout *const envoy_config_metrics_v3_StatsMatcher_submsgs[1
 };
 
 static const upb_msglayout_field envoy_config_metrics_v3_StatsMatcher__fields[3] = {
-  {1, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 8, 1},
-  {2, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 11, 1},
-  {3, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 11, 1},
+  {1, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 8, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_metrics_v3_StatsMatcher_msginit = {
   &envoy_config_metrics_v3_StatsMatcher_submsgs[0],
   &envoy_config_metrics_v3_StatsMatcher__fields[0],
-  UPB_SIZE(8, 16), 3, false, 255,
+  UPB_SIZE(8, 16), 3, false, 3, 255,
 };
 
 static const upb_msglayout_field envoy_config_metrics_v3_TagSpecifier__fields[3] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {2, UPB_SIZE(8, 16), UPB_SIZE(-17, -33), 0, 9, 1},
-  {3, UPB_SIZE(8, 16), UPB_SIZE(-17, -33), 0, 9, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), UPB_SIZE(-17, -33), 0, 9, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(8, 16), UPB_SIZE(-17, -33), 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_metrics_v3_TagSpecifier_msginit = {
   NULL,
   &envoy_config_metrics_v3_TagSpecifier__fields[0],
-  UPB_SIZE(24, 48), 3, false, 255,
+  UPB_SIZE(24, 48), 3, false, 3, 255,
 };
 
 static const upb_msglayout *const envoy_config_metrics_v3_HistogramBucketSettings_submsgs[1] = {
@@ -87,14 +87,14 @@ static const upb_msglayout *const envoy_config_metrics_v3_HistogramBucketSetting
 };
 
 static const upb_msglayout_field envoy_config_metrics_v3_HistogramBucketSettings__fields[2] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
-  {2, UPB_SIZE(8, 16), 0, 0, 1, _UPB_LABEL_PACKED},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 0, 0, 1, _UPB_MODE_ARRAY | _UPB_MODE_IS_PACKED},
 };
 
 const upb_msglayout envoy_config_metrics_v3_HistogramBucketSettings_msginit = {
   &envoy_config_metrics_v3_HistogramBucketSettings_submsgs[0],
   &envoy_config_metrics_v3_HistogramBucketSettings__fields[0],
-  UPB_SIZE(16, 24), 2, false, 255,
+  UPB_SIZE(16, 24), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_config_metrics_v3_StatsdSink_submsgs[1] = {
@@ -102,15 +102,15 @@ static const upb_msglayout *const envoy_config_metrics_v3_StatsdSink_submsgs[1]
 };
 
 static const upb_msglayout_field envoy_config_metrics_v3_StatsdSink__fields[3] = {
-  {1, UPB_SIZE(8, 16), UPB_SIZE(-17, -33), 0, 11, 1},
-  {2, UPB_SIZE(8, 16), UPB_SIZE(-17, -33), 0, 9, 1},
-  {3, UPB_SIZE(0, 0), 0, 0, 9, 1},
+  {1, UPB_SIZE(8, 16), UPB_SIZE(-17, -33), 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), UPB_SIZE(-17, -33), 0, 9, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_metrics_v3_StatsdSink_msginit = {
   &envoy_config_metrics_v3_StatsdSink_submsgs[0],
   &envoy_config_metrics_v3_StatsdSink__fields[0],
-  UPB_SIZE(24, 48), 3, false, 255,
+  UPB_SIZE(24, 48), 3, false, 3, 255,
 };
 
 static const upb_msglayout *const envoy_config_metrics_v3_DogStatsdSink_submsgs[2] = {
@@ -119,25 +119,25 @@ static const upb_msglayout *const envoy_config_metrics_v3_DogStatsdSink_submsgs[
 };
 
 static const upb_msglayout_field envoy_config_metrics_v3_DogStatsdSink__fields[3] = {
-  {1, UPB_SIZE(16, 32), UPB_SIZE(-21, -41), 0, 11, 1},
-  {3, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {4, UPB_SIZE(12, 24), 1, 1, 11, 1},
+  {1, UPB_SIZE(16, 32), UPB_SIZE(-21, -41), 0, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(12, 24), 1, 1, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_metrics_v3_DogStatsdSink_msginit = {
   &envoy_config_metrics_v3_DogStatsdSink_submsgs[0],
   &envoy_config_metrics_v3_DogStatsdSink__fields[0],
-  UPB_SIZE(24, 48), 3, false, 255,
+  UPB_SIZE(24, 48), 3, false, 1, 255,
 };
 
 static const upb_msglayout_field envoy_config_metrics_v3_HystrixSink__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 3, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 3, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_metrics_v3_HystrixSink_msginit = {
   NULL,
   &envoy_config_metrics_v3_HystrixSink__fields[0],
-  UPB_SIZE(8, 8), 1, false, 255,
+  UPB_SIZE(8, 8), 1, false, 1, 255,
 };
 
 #include "upb/port_undef.inc"
index dab0415..4172af8 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_CONFIG_METRICS_V3_STATS_PROTO_UPB_H_
 #define ENVOY_CONFIG_METRICS_V3_STATS_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -66,13 +66,19 @@ UPB_INLINE envoy_config_metrics_v3_StatsSink *envoy_config_metrics_v3_StatsSink_
 UPB_INLINE envoy_config_metrics_v3_StatsSink *envoy_config_metrics_v3_StatsSink_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_metrics_v3_StatsSink *ret = envoy_config_metrics_v3_StatsSink_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_metrics_v3_StatsSink_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_metrics_v3_StatsSink_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_metrics_v3_StatsSink *envoy_config_metrics_v3_StatsSink_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_metrics_v3_StatsSink *ret = envoy_config_metrics_v3_StatsSink_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_metrics_v3_StatsSink_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_metrics_v3_StatsSink_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_metrics_v3_StatsSink_serialize(const envoy_config_metrics_v3_StatsSink *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_metrics_v3_StatsSink_msginit, arena, len);
@@ -112,13 +118,19 @@ UPB_INLINE envoy_config_metrics_v3_StatsConfig *envoy_config_metrics_v3_StatsCon
 UPB_INLINE envoy_config_metrics_v3_StatsConfig *envoy_config_metrics_v3_StatsConfig_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_metrics_v3_StatsConfig *ret = envoy_config_metrics_v3_StatsConfig_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_metrics_v3_StatsConfig_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_metrics_v3_StatsConfig_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_metrics_v3_StatsConfig *envoy_config_metrics_v3_StatsConfig_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_metrics_v3_StatsConfig *ret = envoy_config_metrics_v3_StatsConfig_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_metrics_v3_StatsConfig_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_metrics_v3_StatsConfig_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_metrics_v3_StatsConfig_serialize(const envoy_config_metrics_v3_StatsConfig *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_metrics_v3_StatsConfig_msginit, arena, len);
@@ -194,13 +206,19 @@ UPB_INLINE envoy_config_metrics_v3_StatsMatcher *envoy_config_metrics_v3_StatsMa
 UPB_INLINE envoy_config_metrics_v3_StatsMatcher *envoy_config_metrics_v3_StatsMatcher_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_metrics_v3_StatsMatcher *ret = envoy_config_metrics_v3_StatsMatcher_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_metrics_v3_StatsMatcher_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_metrics_v3_StatsMatcher_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_metrics_v3_StatsMatcher *envoy_config_metrics_v3_StatsMatcher_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_metrics_v3_StatsMatcher *ret = envoy_config_metrics_v3_StatsMatcher_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_metrics_v3_StatsMatcher_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_metrics_v3_StatsMatcher_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_metrics_v3_StatsMatcher_serialize(const envoy_config_metrics_v3_StatsMatcher *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_metrics_v3_StatsMatcher_msginit, arena, len);
@@ -257,13 +275,19 @@ UPB_INLINE envoy_config_metrics_v3_TagSpecifier *envoy_config_metrics_v3_TagSpec
 UPB_INLINE envoy_config_metrics_v3_TagSpecifier *envoy_config_metrics_v3_TagSpecifier_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_metrics_v3_TagSpecifier *ret = envoy_config_metrics_v3_TagSpecifier_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_metrics_v3_TagSpecifier_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_metrics_v3_TagSpecifier_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_metrics_v3_TagSpecifier *envoy_config_metrics_v3_TagSpecifier_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_metrics_v3_TagSpecifier *ret = envoy_config_metrics_v3_TagSpecifier_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_metrics_v3_TagSpecifier_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_metrics_v3_TagSpecifier_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_metrics_v3_TagSpecifier_serialize(const envoy_config_metrics_v3_TagSpecifier *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_metrics_v3_TagSpecifier_msginit, arena, len);
@@ -300,13 +324,19 @@ UPB_INLINE envoy_config_metrics_v3_HistogramBucketSettings *envoy_config_metrics
 UPB_INLINE envoy_config_metrics_v3_HistogramBucketSettings *envoy_config_metrics_v3_HistogramBucketSettings_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_metrics_v3_HistogramBucketSettings *ret = envoy_config_metrics_v3_HistogramBucketSettings_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_metrics_v3_HistogramBucketSettings_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_metrics_v3_HistogramBucketSettings_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_metrics_v3_HistogramBucketSettings *envoy_config_metrics_v3_HistogramBucketSettings_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_metrics_v3_HistogramBucketSettings *ret = envoy_config_metrics_v3_HistogramBucketSettings_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_metrics_v3_HistogramBucketSettings_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_metrics_v3_HistogramBucketSettings_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_metrics_v3_HistogramBucketSettings_serialize(const envoy_config_metrics_v3_HistogramBucketSettings *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_metrics_v3_HistogramBucketSettings_msginit, arena, len);
@@ -348,13 +378,19 @@ UPB_INLINE envoy_config_metrics_v3_StatsdSink *envoy_config_metrics_v3_StatsdSin
 UPB_INLINE envoy_config_metrics_v3_StatsdSink *envoy_config_metrics_v3_StatsdSink_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_metrics_v3_StatsdSink *ret = envoy_config_metrics_v3_StatsdSink_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_metrics_v3_StatsdSink_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_metrics_v3_StatsdSink_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_metrics_v3_StatsdSink *envoy_config_metrics_v3_StatsdSink_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_metrics_v3_StatsdSink *ret = envoy_config_metrics_v3_StatsdSink_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_metrics_v3_StatsdSink_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_metrics_v3_StatsdSink_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_metrics_v3_StatsdSink_serialize(const envoy_config_metrics_v3_StatsdSink *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_metrics_v3_StatsdSink_msginit, arena, len);
@@ -400,13 +436,19 @@ UPB_INLINE envoy_config_metrics_v3_DogStatsdSink *envoy_config_metrics_v3_DogSta
 UPB_INLINE envoy_config_metrics_v3_DogStatsdSink *envoy_config_metrics_v3_DogStatsdSink_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_metrics_v3_DogStatsdSink *ret = envoy_config_metrics_v3_DogStatsdSink_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_metrics_v3_DogStatsdSink_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_metrics_v3_DogStatsdSink_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_metrics_v3_DogStatsdSink *envoy_config_metrics_v3_DogStatsdSink_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_metrics_v3_DogStatsdSink *ret = envoy_config_metrics_v3_DogStatsdSink_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_metrics_v3_DogStatsdSink_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_metrics_v3_DogStatsdSink_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_metrics_v3_DogStatsdSink_serialize(const envoy_config_metrics_v3_DogStatsdSink *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_metrics_v3_DogStatsdSink_msginit, arena, len);
@@ -461,13 +503,19 @@ UPB_INLINE envoy_config_metrics_v3_HystrixSink *envoy_config_metrics_v3_HystrixS
 UPB_INLINE envoy_config_metrics_v3_HystrixSink *envoy_config_metrics_v3_HystrixSink_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_metrics_v3_HystrixSink *ret = envoy_config_metrics_v3_HystrixSink_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_metrics_v3_HystrixSink_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_metrics_v3_HystrixSink_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_metrics_v3_HystrixSink *envoy_config_metrics_v3_HystrixSink_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_metrics_v3_HystrixSink *ret = envoy_config_metrics_v3_HystrixSink_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_metrics_v3_HystrixSink_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_metrics_v3_HystrixSink_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_metrics_v3_HystrixSink_serialize(const envoy_config_metrics_v3_HystrixSink *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_metrics_v3_HystrixSink_msginit, arena, len);
index a306e71..d83c470 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/config/overload/v3/overload.upb.h"
 #include "envoy/type/v3/percent.upb.h"
 #include "google/protobuf/any.upb.h"
@@ -23,35 +23,35 @@ static const upb_msglayout *const envoy_config_overload_v3_ResourceMonitor_subms
 };
 
 static const upb_msglayout_field envoy_config_overload_v3_ResourceMonitor__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {3, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 0, 11, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_overload_v3_ResourceMonitor_msginit = {
   &envoy_config_overload_v3_ResourceMonitor_submsgs[0],
   &envoy_config_overload_v3_ResourceMonitor__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 1, 255,
 };
 
 static const upb_msglayout_field envoy_config_overload_v3_ThresholdTrigger__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 1, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 1, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_overload_v3_ThresholdTrigger_msginit = {
   NULL,
   &envoy_config_overload_v3_ThresholdTrigger__fields[0],
-  UPB_SIZE(8, 8), 1, false, 255,
+  UPB_SIZE(8, 8), 1, false, 1, 255,
 };
 
 static const upb_msglayout_field envoy_config_overload_v3_ScaledTrigger__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 1, 1},
-  {2, UPB_SIZE(8, 8), 0, 0, 1, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 1, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 8), 0, 0, 1, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_overload_v3_ScaledTrigger_msginit = {
   NULL,
   &envoy_config_overload_v3_ScaledTrigger__fields[0],
-  UPB_SIZE(16, 16), 2, false, 255,
+  UPB_SIZE(16, 16), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_config_overload_v3_Trigger_submsgs[2] = {
@@ -60,15 +60,15 @@ static const upb_msglayout *const envoy_config_overload_v3_Trigger_submsgs[2] =
 };
 
 static const upb_msglayout_field envoy_config_overload_v3_Trigger__fields[3] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {2, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 1, 11, 1},
-  {3, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 0, 11, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 1, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_overload_v3_Trigger_msginit = {
   &envoy_config_overload_v3_Trigger_submsgs[0],
   &envoy_config_overload_v3_Trigger__fields[0],
-  UPB_SIZE(16, 32), 3, false, 255,
+  UPB_SIZE(16, 32), 3, false, 3, 255,
 };
 
 static const upb_msglayout *const envoy_config_overload_v3_ScaleTimersOverloadActionConfig_submsgs[1] = {
@@ -76,13 +76,13 @@ static const upb_msglayout *const envoy_config_overload_v3_ScaleTimersOverloadAc
 };
 
 static const upb_msglayout_field envoy_config_overload_v3_ScaleTimersOverloadActionConfig__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 11, 3},
+  {1, UPB_SIZE(0, 0), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout envoy_config_overload_v3_ScaleTimersOverloadActionConfig_msginit = {
   &envoy_config_overload_v3_ScaleTimersOverloadActionConfig_submsgs[0],
   &envoy_config_overload_v3_ScaleTimersOverloadActionConfig__fields[0],
-  UPB_SIZE(8, 8), 1, false, 255,
+  UPB_SIZE(8, 8), 1, false, 1, 255,
 };
 
 static const upb_msglayout *const envoy_config_overload_v3_ScaleTimersOverloadActionConfig_ScaleTimer_submsgs[2] = {
@@ -91,15 +91,15 @@ static const upb_msglayout *const envoy_config_overload_v3_ScaleTimersOverloadAc
 };
 
 static const upb_msglayout_field envoy_config_overload_v3_ScaleTimersOverloadActionConfig_ScaleTimer__fields[3] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 14, 1},
-  {2, UPB_SIZE(4, 8), UPB_SIZE(-9, -17), 1, 11, 1},
-  {3, UPB_SIZE(4, 8), UPB_SIZE(-9, -17), 0, 11, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 14, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(4, 8), UPB_SIZE(-9, -17), 1, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(4, 8), UPB_SIZE(-9, -17), 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_overload_v3_ScaleTimersOverloadActionConfig_ScaleTimer_msginit = {
   &envoy_config_overload_v3_ScaleTimersOverloadActionConfig_ScaleTimer_submsgs[0],
   &envoy_config_overload_v3_ScaleTimersOverloadActionConfig_ScaleTimer__fields[0],
-  UPB_SIZE(16, 24), 3, false, 255,
+  UPB_SIZE(16, 24), 3, false, 3, 255,
 };
 
 static const upb_msglayout *const envoy_config_overload_v3_OverloadAction_submsgs[2] = {
@@ -108,33 +108,45 @@ static const upb_msglayout *const envoy_config_overload_v3_OverloadAction_submsg
 };
 
 static const upb_msglayout_field envoy_config_overload_v3_OverloadAction__fields[3] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(16, 32), 0, 0, 11, 3},
-  {3, UPB_SIZE(12, 24), 1, 1, 11, 1},
+  {1, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(16, 32), 0, 0, 11, _UPB_MODE_ARRAY},
+  {3, UPB_SIZE(12, 24), 1, 1, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_overload_v3_OverloadAction_msginit = {
   &envoy_config_overload_v3_OverloadAction_submsgs[0],
   &envoy_config_overload_v3_OverloadAction__fields[0],
-  UPB_SIZE(24, 48), 3, false, 255,
+  UPB_SIZE(24, 48), 3, false, 3, 255,
 };
 
-static const upb_msglayout *const envoy_config_overload_v3_OverloadManager_submsgs[3] = {
+static const upb_msglayout_field envoy_config_overload_v3_BufferFactoryConfig__fields[1] = {
+  {1, UPB_SIZE(0, 0), 0, 0, 13, _UPB_MODE_SCALAR},
+};
+
+const upb_msglayout envoy_config_overload_v3_BufferFactoryConfig_msginit = {
+  NULL,
+  &envoy_config_overload_v3_BufferFactoryConfig__fields[0],
+  UPB_SIZE(8, 8), 1, false, 1, 255,
+};
+
+static const upb_msglayout *const envoy_config_overload_v3_OverloadManager_submsgs[4] = {
+  &envoy_config_overload_v3_BufferFactoryConfig_msginit,
   &envoy_config_overload_v3_OverloadAction_msginit,
   &envoy_config_overload_v3_ResourceMonitor_msginit,
   &google_protobuf_Duration_msginit,
 };
 
-static const upb_msglayout_field envoy_config_overload_v3_OverloadManager__fields[3] = {
-  {1, UPB_SIZE(4, 8), 1, 2, 11, 1},
-  {2, UPB_SIZE(8, 16), 0, 1, 11, 3},
-  {3, UPB_SIZE(12, 24), 0, 0, 11, 3},
+static const upb_msglayout_field envoy_config_overload_v3_OverloadManager__fields[4] = {
+  {1, UPB_SIZE(4, 8), 1, 3, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(12, 24), 0, 2, 11, _UPB_MODE_ARRAY},
+  {3, UPB_SIZE(16, 32), 0, 1, 11, _UPB_MODE_ARRAY},
+  {4, UPB_SIZE(8, 16), 2, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_overload_v3_OverloadManager_msginit = {
   &envoy_config_overload_v3_OverloadManager_submsgs[0],
   &envoy_config_overload_v3_OverloadManager__fields[0],
-  UPB_SIZE(16, 32), 3, false, 255,
+  UPB_SIZE(24, 40), 4, false, 4, 255,
 };
 
 #include "upb/port_undef.inc"
index d800aa9..c6abedb 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_CONFIG_OVERLOAD_V3_OVERLOAD_PROTO_UPB_H_
 #define ENVOY_CONFIG_OVERLOAD_V3_OVERLOAD_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -27,6 +27,7 @@ struct envoy_config_overload_v3_Trigger;
 struct envoy_config_overload_v3_ScaleTimersOverloadActionConfig;
 struct envoy_config_overload_v3_ScaleTimersOverloadActionConfig_ScaleTimer;
 struct envoy_config_overload_v3_OverloadAction;
+struct envoy_config_overload_v3_BufferFactoryConfig;
 struct envoy_config_overload_v3_OverloadManager;
 typedef struct envoy_config_overload_v3_ResourceMonitor envoy_config_overload_v3_ResourceMonitor;
 typedef struct envoy_config_overload_v3_ThresholdTrigger envoy_config_overload_v3_ThresholdTrigger;
@@ -35,6 +36,7 @@ typedef struct envoy_config_overload_v3_Trigger envoy_config_overload_v3_Trigger
 typedef struct envoy_config_overload_v3_ScaleTimersOverloadActionConfig envoy_config_overload_v3_ScaleTimersOverloadActionConfig;
 typedef struct envoy_config_overload_v3_ScaleTimersOverloadActionConfig_ScaleTimer envoy_config_overload_v3_ScaleTimersOverloadActionConfig_ScaleTimer;
 typedef struct envoy_config_overload_v3_OverloadAction envoy_config_overload_v3_OverloadAction;
+typedef struct envoy_config_overload_v3_BufferFactoryConfig envoy_config_overload_v3_BufferFactoryConfig;
 typedef struct envoy_config_overload_v3_OverloadManager envoy_config_overload_v3_OverloadManager;
 extern const upb_msglayout envoy_config_overload_v3_ResourceMonitor_msginit;
 extern const upb_msglayout envoy_config_overload_v3_ThresholdTrigger_msginit;
@@ -43,6 +45,7 @@ extern const upb_msglayout envoy_config_overload_v3_Trigger_msginit;
 extern const upb_msglayout envoy_config_overload_v3_ScaleTimersOverloadActionConfig_msginit;
 extern const upb_msglayout envoy_config_overload_v3_ScaleTimersOverloadActionConfig_ScaleTimer_msginit;
 extern const upb_msglayout envoy_config_overload_v3_OverloadAction_msginit;
+extern const upb_msglayout envoy_config_overload_v3_BufferFactoryConfig_msginit;
 extern const upb_msglayout envoy_config_overload_v3_OverloadManager_msginit;
 struct envoy_type_v3_Percent;
 struct google_protobuf_Any;
@@ -67,13 +70,19 @@ UPB_INLINE envoy_config_overload_v3_ResourceMonitor *envoy_config_overload_v3_Re
 UPB_INLINE envoy_config_overload_v3_ResourceMonitor *envoy_config_overload_v3_ResourceMonitor_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_overload_v3_ResourceMonitor *ret = envoy_config_overload_v3_ResourceMonitor_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_overload_v3_ResourceMonitor_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_overload_v3_ResourceMonitor_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_overload_v3_ResourceMonitor *envoy_config_overload_v3_ResourceMonitor_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_overload_v3_ResourceMonitor *ret = envoy_config_overload_v3_ResourceMonitor_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_overload_v3_ResourceMonitor_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_overload_v3_ResourceMonitor_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_overload_v3_ResourceMonitor_serialize(const envoy_config_overload_v3_ResourceMonitor *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_overload_v3_ResourceMonitor_msginit, arena, len);
@@ -113,13 +122,19 @@ UPB_INLINE envoy_config_overload_v3_ThresholdTrigger *envoy_config_overload_v3_T
 UPB_INLINE envoy_config_overload_v3_ThresholdTrigger *envoy_config_overload_v3_ThresholdTrigger_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_overload_v3_ThresholdTrigger *ret = envoy_config_overload_v3_ThresholdTrigger_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_overload_v3_ThresholdTrigger_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_overload_v3_ThresholdTrigger_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_overload_v3_ThresholdTrigger *envoy_config_overload_v3_ThresholdTrigger_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_overload_v3_ThresholdTrigger *ret = envoy_config_overload_v3_ThresholdTrigger_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_overload_v3_ThresholdTrigger_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_overload_v3_ThresholdTrigger_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_overload_v3_ThresholdTrigger_serialize(const envoy_config_overload_v3_ThresholdTrigger *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_overload_v3_ThresholdTrigger_msginit, arena, len);
@@ -139,13 +154,19 @@ UPB_INLINE envoy_config_overload_v3_ScaledTrigger *envoy_config_overload_v3_Scal
 UPB_INLINE envoy_config_overload_v3_ScaledTrigger *envoy_config_overload_v3_ScaledTrigger_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_overload_v3_ScaledTrigger *ret = envoy_config_overload_v3_ScaledTrigger_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_overload_v3_ScaledTrigger_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_overload_v3_ScaledTrigger_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_overload_v3_ScaledTrigger *envoy_config_overload_v3_ScaledTrigger_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_overload_v3_ScaledTrigger *ret = envoy_config_overload_v3_ScaledTrigger_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_overload_v3_ScaledTrigger_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_overload_v3_ScaledTrigger_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_overload_v3_ScaledTrigger_serialize(const envoy_config_overload_v3_ScaledTrigger *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_overload_v3_ScaledTrigger_msginit, arena, len);
@@ -169,13 +190,19 @@ UPB_INLINE envoy_config_overload_v3_Trigger *envoy_config_overload_v3_Trigger_ne
 UPB_INLINE envoy_config_overload_v3_Trigger *envoy_config_overload_v3_Trigger_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_overload_v3_Trigger *ret = envoy_config_overload_v3_Trigger_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_overload_v3_Trigger_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_overload_v3_Trigger_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_overload_v3_Trigger *envoy_config_overload_v3_Trigger_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_overload_v3_Trigger *ret = envoy_config_overload_v3_Trigger_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_overload_v3_Trigger_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_overload_v3_Trigger_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_overload_v3_Trigger_serialize(const envoy_config_overload_v3_Trigger *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_overload_v3_Trigger_msginit, arena, len);
@@ -230,13 +257,19 @@ UPB_INLINE envoy_config_overload_v3_ScaleTimersOverloadActionConfig *envoy_confi
 UPB_INLINE envoy_config_overload_v3_ScaleTimersOverloadActionConfig *envoy_config_overload_v3_ScaleTimersOverloadActionConfig_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_overload_v3_ScaleTimersOverloadActionConfig *ret = envoy_config_overload_v3_ScaleTimersOverloadActionConfig_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_overload_v3_ScaleTimersOverloadActionConfig_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_overload_v3_ScaleTimersOverloadActionConfig_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_overload_v3_ScaleTimersOverloadActionConfig *envoy_config_overload_v3_ScaleTimersOverloadActionConfig_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_overload_v3_ScaleTimersOverloadActionConfig *ret = envoy_config_overload_v3_ScaleTimersOverloadActionConfig_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_overload_v3_ScaleTimersOverloadActionConfig_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_overload_v3_ScaleTimersOverloadActionConfig_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_overload_v3_ScaleTimersOverloadActionConfig_serialize(const envoy_config_overload_v3_ScaleTimersOverloadActionConfig *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_overload_v3_ScaleTimersOverloadActionConfig_msginit, arena, len);
@@ -267,13 +300,19 @@ UPB_INLINE envoy_config_overload_v3_ScaleTimersOverloadActionConfig_ScaleTimer *
 UPB_INLINE envoy_config_overload_v3_ScaleTimersOverloadActionConfig_ScaleTimer *envoy_config_overload_v3_ScaleTimersOverloadActionConfig_ScaleTimer_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_overload_v3_ScaleTimersOverloadActionConfig_ScaleTimer *ret = envoy_config_overload_v3_ScaleTimersOverloadActionConfig_ScaleTimer_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_overload_v3_ScaleTimersOverloadActionConfig_ScaleTimer_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_overload_v3_ScaleTimersOverloadActionConfig_ScaleTimer_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_overload_v3_ScaleTimersOverloadActionConfig_ScaleTimer *envoy_config_overload_v3_ScaleTimersOverloadActionConfig_ScaleTimer_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_overload_v3_ScaleTimersOverloadActionConfig_ScaleTimer *ret = envoy_config_overload_v3_ScaleTimersOverloadActionConfig_ScaleTimer_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_overload_v3_ScaleTimersOverloadActionConfig_ScaleTimer_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_overload_v3_ScaleTimersOverloadActionConfig_ScaleTimer_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_overload_v3_ScaleTimersOverloadActionConfig_ScaleTimer_serialize(const envoy_config_overload_v3_ScaleTimersOverloadActionConfig_ScaleTimer *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_overload_v3_ScaleTimersOverloadActionConfig_ScaleTimer_msginit, arena, len);
@@ -328,13 +367,19 @@ UPB_INLINE envoy_config_overload_v3_OverloadAction *envoy_config_overload_v3_Ove
 UPB_INLINE envoy_config_overload_v3_OverloadAction *envoy_config_overload_v3_OverloadAction_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_overload_v3_OverloadAction *ret = envoy_config_overload_v3_OverloadAction_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_overload_v3_OverloadAction_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_overload_v3_OverloadAction_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_overload_v3_OverloadAction *envoy_config_overload_v3_OverloadAction_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_overload_v3_OverloadAction *ret = envoy_config_overload_v3_OverloadAction_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_overload_v3_OverloadAction_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_overload_v3_OverloadAction_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_overload_v3_OverloadAction_serialize(const envoy_config_overload_v3_OverloadAction *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_overload_v3_OverloadAction_msginit, arena, len);
@@ -376,6 +421,38 @@ UPB_INLINE struct google_protobuf_Any* envoy_config_overload_v3_OverloadAction_m
   return sub;
 }
 
+/* envoy.config.overload.v3.BufferFactoryConfig */
+
+UPB_INLINE envoy_config_overload_v3_BufferFactoryConfig *envoy_config_overload_v3_BufferFactoryConfig_new(upb_arena *arena) {
+  return (envoy_config_overload_v3_BufferFactoryConfig *)_upb_msg_new(&envoy_config_overload_v3_BufferFactoryConfig_msginit, arena);
+}
+UPB_INLINE envoy_config_overload_v3_BufferFactoryConfig *envoy_config_overload_v3_BufferFactoryConfig_parse(const char *buf, size_t size,
+                        upb_arena *arena) {
+  envoy_config_overload_v3_BufferFactoryConfig *ret = envoy_config_overload_v3_BufferFactoryConfig_new(arena);
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_overload_v3_BufferFactoryConfig_msginit, arena)) return NULL;
+  return ret;
+}
+UPB_INLINE envoy_config_overload_v3_BufferFactoryConfig *envoy_config_overload_v3_BufferFactoryConfig_parse_ex(const char *buf, size_t size,
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
+  envoy_config_overload_v3_BufferFactoryConfig *ret = envoy_config_overload_v3_BufferFactoryConfig_new(arena);
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_overload_v3_BufferFactoryConfig_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
+}
+UPB_INLINE char *envoy_config_overload_v3_BufferFactoryConfig_serialize(const envoy_config_overload_v3_BufferFactoryConfig *msg, upb_arena *arena, size_t *len) {
+  return upb_encode(msg, &envoy_config_overload_v3_BufferFactoryConfig_msginit, arena, len);
+}
+
+UPB_INLINE uint32_t envoy_config_overload_v3_BufferFactoryConfig_minimum_account_to_track_power_of_two(const envoy_config_overload_v3_BufferFactoryConfig *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(0, 0), uint32_t); }
+
+UPB_INLINE void envoy_config_overload_v3_BufferFactoryConfig_set_minimum_account_to_track_power_of_two(envoy_config_overload_v3_BufferFactoryConfig *msg, uint32_t value) {
+  *UPB_PTR_AT(msg, UPB_SIZE(0, 0), uint32_t) = value;
+}
+
 /* envoy.config.overload.v3.OverloadManager */
 
 UPB_INLINE envoy_config_overload_v3_OverloadManager *envoy_config_overload_v3_OverloadManager_new(upb_arena *arena) {
@@ -384,13 +461,19 @@ UPB_INLINE envoy_config_overload_v3_OverloadManager *envoy_config_overload_v3_Ov
 UPB_INLINE envoy_config_overload_v3_OverloadManager *envoy_config_overload_v3_OverloadManager_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_overload_v3_OverloadManager *ret = envoy_config_overload_v3_OverloadManager_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_overload_v3_OverloadManager_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_overload_v3_OverloadManager_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_overload_v3_OverloadManager *envoy_config_overload_v3_OverloadManager_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_overload_v3_OverloadManager *ret = envoy_config_overload_v3_OverloadManager_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_overload_v3_OverloadManager_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_overload_v3_OverloadManager_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_overload_v3_OverloadManager_serialize(const envoy_config_overload_v3_OverloadManager *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_overload_v3_OverloadManager_msginit, arena, len);
@@ -398,10 +481,12 @@ UPB_INLINE char *envoy_config_overload_v3_OverloadManager_serialize(const envoy_
 
 UPB_INLINE bool envoy_config_overload_v3_OverloadManager_has_refresh_interval(const envoy_config_overload_v3_OverloadManager *msg) { return _upb_hasbit(msg, 1); }
 UPB_INLINE const struct google_protobuf_Duration* envoy_config_overload_v3_OverloadManager_refresh_interval(const envoy_config_overload_v3_OverloadManager *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(4, 8), const struct google_protobuf_Duration*); }
-UPB_INLINE bool envoy_config_overload_v3_OverloadManager_has_resource_monitors(const envoy_config_overload_v3_OverloadManager *msg) { return _upb_has_submsg_nohasbit(msg, UPB_SIZE(8, 16)); }
-UPB_INLINE const envoy_config_overload_v3_ResourceMonitor* const* envoy_config_overload_v3_OverloadManager_resource_monitors(const envoy_config_overload_v3_OverloadManager *msg, size_t *len) { return (const envoy_config_overload_v3_ResourceMonitor* const*)_upb_array_accessor(msg, UPB_SIZE(8, 16), len); }
-UPB_INLINE bool envoy_config_overload_v3_OverloadManager_has_actions(const envoy_config_overload_v3_OverloadManager *msg) { return _upb_has_submsg_nohasbit(msg, UPB_SIZE(12, 24)); }
-UPB_INLINE const envoy_config_overload_v3_OverloadAction* const* envoy_config_overload_v3_OverloadManager_actions(const envoy_config_overload_v3_OverloadManager *msg, size_t *len) { return (const envoy_config_overload_v3_OverloadAction* const*)_upb_array_accessor(msg, UPB_SIZE(12, 24), len); }
+UPB_INLINE bool envoy_config_overload_v3_OverloadManager_has_resource_monitors(const envoy_config_overload_v3_OverloadManager *msg) { return _upb_has_submsg_nohasbit(msg, UPB_SIZE(12, 24)); }
+UPB_INLINE const envoy_config_overload_v3_ResourceMonitor* const* envoy_config_overload_v3_OverloadManager_resource_monitors(const envoy_config_overload_v3_OverloadManager *msg, size_t *len) { return (const envoy_config_overload_v3_ResourceMonitor* const*)_upb_array_accessor(msg, UPB_SIZE(12, 24), len); }
+UPB_INLINE bool envoy_config_overload_v3_OverloadManager_has_actions(const envoy_config_overload_v3_OverloadManager *msg) { return _upb_has_submsg_nohasbit(msg, UPB_SIZE(16, 32)); }
+UPB_INLINE const envoy_config_overload_v3_OverloadAction* const* envoy_config_overload_v3_OverloadManager_actions(const envoy_config_overload_v3_OverloadManager *msg, size_t *len) { return (const envoy_config_overload_v3_OverloadAction* const*)_upb_array_accessor(msg, UPB_SIZE(16, 32), len); }
+UPB_INLINE bool envoy_config_overload_v3_OverloadManager_has_buffer_factory_config(const envoy_config_overload_v3_OverloadManager *msg) { return _upb_hasbit(msg, 2); }
+UPB_INLINE const envoy_config_overload_v3_BufferFactoryConfig* envoy_config_overload_v3_OverloadManager_buffer_factory_config(const envoy_config_overload_v3_OverloadManager *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(8, 16), const envoy_config_overload_v3_BufferFactoryConfig*); }
 
 UPB_INLINE void envoy_config_overload_v3_OverloadManager_set_refresh_interval(envoy_config_overload_v3_OverloadManager *msg, struct google_protobuf_Duration* value) {
   _upb_sethas(msg, 1);
@@ -417,31 +502,44 @@ UPB_INLINE struct google_protobuf_Duration* envoy_config_overload_v3_OverloadMan
   return sub;
 }
 UPB_INLINE envoy_config_overload_v3_ResourceMonitor** envoy_config_overload_v3_OverloadManager_mutable_resource_monitors(envoy_config_overload_v3_OverloadManager *msg, size_t *len) {
-  return (envoy_config_overload_v3_ResourceMonitor**)_upb_array_mutable_accessor(msg, UPB_SIZE(8, 16), len);
+  return (envoy_config_overload_v3_ResourceMonitor**)_upb_array_mutable_accessor(msg, UPB_SIZE(12, 24), len);
 }
 UPB_INLINE envoy_config_overload_v3_ResourceMonitor** envoy_config_overload_v3_OverloadManager_resize_resource_monitors(envoy_config_overload_v3_OverloadManager *msg, size_t len, upb_arena *arena) {
-  return (envoy_config_overload_v3_ResourceMonitor**)_upb_array_resize_accessor2(msg, UPB_SIZE(8, 16), len, UPB_SIZE(2, 3), arena);
+  return (envoy_config_overload_v3_ResourceMonitor**)_upb_array_resize_accessor2(msg, UPB_SIZE(12, 24), len, UPB_SIZE(2, 3), arena);
 }
 UPB_INLINE struct envoy_config_overload_v3_ResourceMonitor* envoy_config_overload_v3_OverloadManager_add_resource_monitors(envoy_config_overload_v3_OverloadManager *msg, upb_arena *arena) {
   struct envoy_config_overload_v3_ResourceMonitor* sub = (struct envoy_config_overload_v3_ResourceMonitor*)_upb_msg_new(&envoy_config_overload_v3_ResourceMonitor_msginit, arena);
   bool ok = _upb_array_append_accessor2(
-      msg, UPB_SIZE(8, 16), UPB_SIZE(2, 3), &sub, arena);
+      msg, UPB_SIZE(12, 24), UPB_SIZE(2, 3), &sub, arena);
   if (!ok) return NULL;
   return sub;
 }
 UPB_INLINE envoy_config_overload_v3_OverloadAction** envoy_config_overload_v3_OverloadManager_mutable_actions(envoy_config_overload_v3_OverloadManager *msg, size_t *len) {
-  return (envoy_config_overload_v3_OverloadAction**)_upb_array_mutable_accessor(msg, UPB_SIZE(12, 24), len);
+  return (envoy_config_overload_v3_OverloadAction**)_upb_array_mutable_accessor(msg, UPB_SIZE(16, 32), len);
 }
 UPB_INLINE envoy_config_overload_v3_OverloadAction** envoy_config_overload_v3_OverloadManager_resize_actions(envoy_config_overload_v3_OverloadManager *msg, size_t len, upb_arena *arena) {
-  return (envoy_config_overload_v3_OverloadAction**)_upb_array_resize_accessor2(msg, UPB_SIZE(12, 24), len, UPB_SIZE(2, 3), arena);
+  return (envoy_config_overload_v3_OverloadAction**)_upb_array_resize_accessor2(msg, UPB_SIZE(16, 32), len, UPB_SIZE(2, 3), arena);
 }
 UPB_INLINE struct envoy_config_overload_v3_OverloadAction* envoy_config_overload_v3_OverloadManager_add_actions(envoy_config_overload_v3_OverloadManager *msg, upb_arena *arena) {
   struct envoy_config_overload_v3_OverloadAction* sub = (struct envoy_config_overload_v3_OverloadAction*)_upb_msg_new(&envoy_config_overload_v3_OverloadAction_msginit, arena);
   bool ok = _upb_array_append_accessor2(
-      msg, UPB_SIZE(12, 24), UPB_SIZE(2, 3), &sub, arena);
+      msg, UPB_SIZE(16, 32), UPB_SIZE(2, 3), &sub, arena);
   if (!ok) return NULL;
   return sub;
 }
+UPB_INLINE void envoy_config_overload_v3_OverloadManager_set_buffer_factory_config(envoy_config_overload_v3_OverloadManager *msg, envoy_config_overload_v3_BufferFactoryConfig* value) {
+  _upb_sethas(msg, 2);
+  *UPB_PTR_AT(msg, UPB_SIZE(8, 16), envoy_config_overload_v3_BufferFactoryConfig*) = value;
+}
+UPB_INLINE struct envoy_config_overload_v3_BufferFactoryConfig* envoy_config_overload_v3_OverloadManager_mutable_buffer_factory_config(envoy_config_overload_v3_OverloadManager *msg, upb_arena *arena) {
+  struct envoy_config_overload_v3_BufferFactoryConfig* sub = (struct envoy_config_overload_v3_BufferFactoryConfig*)envoy_config_overload_v3_OverloadManager_buffer_factory_config(msg);
+  if (sub == NULL) {
+    sub = (struct envoy_config_overload_v3_BufferFactoryConfig*)_upb_msg_new(&envoy_config_overload_v3_BufferFactoryConfig_msginit, arena);
+    if (!sub) return NULL;
+    envoy_config_overload_v3_OverloadManager_set_buffer_factory_config(msg, sub);
+  }
+  return sub;
+}
 
 #ifdef __cplusplus
 }  /* extern "C" */
index d4c81d1..d92b08e 100644 (file)
@@ -7,13 +7,14 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/config/rbac/v3/rbac.upb.h"
 #include "envoy/config/core/v3/address.upb.h"
 #include "envoy/config/route/v3/route_components.upb.h"
 #include "envoy/type/matcher/v3/metadata.upb.h"
 #include "envoy/type/matcher/v3/path.upb.h"
 #include "envoy/type/matcher/v3/string.upb.h"
+#include "envoy/type/v3/range.upb.h"
 #include "google/api/expr/v1alpha1/checked.upb.h"
 #include "google/api/expr/v1alpha1/syntax.upb.h"
 #include "envoy/annotations/deprecation.upb.h"
@@ -29,14 +30,14 @@ static const upb_msglayout *const envoy_config_rbac_v3_RBAC_submsgs[1] = {
 };
 
 static const upb_msglayout_field envoy_config_rbac_v3_RBAC__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 14, 1},
-  {2, UPB_SIZE(4, 8), 0, 0, 11, _UPB_LABEL_MAP},
+  {1, UPB_SIZE(0, 0), 0, 0, 14, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(4, 8), 0, 0, 11, _UPB_MODE_MAP},
 };
 
 const upb_msglayout envoy_config_rbac_v3_RBAC_msginit = {
   &envoy_config_rbac_v3_RBAC_submsgs[0],
   &envoy_config_rbac_v3_RBAC__fields[0],
-  UPB_SIZE(8, 16), 2, false, 255,
+  UPB_SIZE(8, 16), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_config_rbac_v3_RBAC_PoliciesEntry_submsgs[1] = {
@@ -44,14 +45,14 @@ static const upb_msglayout *const envoy_config_rbac_v3_RBAC_PoliciesEntry_submsg
 };
 
 static const upb_msglayout_field envoy_config_rbac_v3_RBAC_PoliciesEntry__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {2, UPB_SIZE(8, 16), 0, 0, 11, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 0, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_rbac_v3_RBAC_PoliciesEntry_msginit = {
   &envoy_config_rbac_v3_RBAC_PoliciesEntry_submsgs[0],
   &envoy_config_rbac_v3_RBAC_PoliciesEntry__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_config_rbac_v3_Policy_submsgs[4] = {
@@ -62,19 +63,19 @@ static const upb_msglayout *const envoy_config_rbac_v3_Policy_submsgs[4] = {
 };
 
 static const upb_msglayout_field envoy_config_rbac_v3_Policy__fields[4] = {
-  {1, UPB_SIZE(12, 24), 0, 0, 11, 3},
-  {2, UPB_SIZE(16, 32), 0, 1, 11, 3},
-  {3, UPB_SIZE(4, 8), 1, 3, 11, 1},
-  {4, UPB_SIZE(8, 16), 2, 2, 11, 1},
+  {1, UPB_SIZE(12, 24), 0, 0, 11, _UPB_MODE_ARRAY},
+  {2, UPB_SIZE(16, 32), 0, 1, 11, _UPB_MODE_ARRAY},
+  {3, UPB_SIZE(4, 8), 1, 3, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(8, 16), 2, 2, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_rbac_v3_Policy_msginit = {
   &envoy_config_rbac_v3_Policy_submsgs[0],
   &envoy_config_rbac_v3_Policy__fields[0],
-  UPB_SIZE(24, 40), 4, false, 255,
+  UPB_SIZE(24, 40), 4, false, 4, 255,
 };
 
-static const upb_msglayout *const envoy_config_rbac_v3_Permission_submsgs[7] = {
+static const upb_msglayout *const envoy_config_rbac_v3_Permission_submsgs[8] = {
   &envoy_config_core_v3_CidrRange_msginit,
   &envoy_config_rbac_v3_Permission_msginit,
   &envoy_config_rbac_v3_Permission_Set_msginit,
@@ -82,25 +83,27 @@ static const upb_msglayout *const envoy_config_rbac_v3_Permission_submsgs[7] = {
   &envoy_type_matcher_v3_MetadataMatcher_msginit,
   &envoy_type_matcher_v3_PathMatcher_msginit,
   &envoy_type_matcher_v3_StringMatcher_msginit,
+  &envoy_type_v3_Int32Range_msginit,
 };
 
-static const upb_msglayout_field envoy_config_rbac_v3_Permission__fields[10] = {
-  {1, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 2, 11, 1},
-  {2, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 2, 11, 1},
-  {3, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 8, 1},
-  {4, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 3, 11, 1},
-  {5, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 11, 1},
-  {6, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 13, 1},
-  {7, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 4, 11, 1},
-  {8, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 1, 11, 1},
-  {9, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 6, 11, 1},
-  {10, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 5, 11, 1},
+static const upb_msglayout_field envoy_config_rbac_v3_Permission__fields[11] = {
+  {1, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 2, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 2, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 8, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 3, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 11, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 13, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 4, 11, _UPB_MODE_SCALAR},
+  {8, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 1, 11, _UPB_MODE_SCALAR},
+  {9, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 6, 11, _UPB_MODE_SCALAR},
+  {10, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 5, 11, _UPB_MODE_SCALAR},
+  {11, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 7, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_rbac_v3_Permission_msginit = {
   &envoy_config_rbac_v3_Permission_submsgs[0],
   &envoy_config_rbac_v3_Permission__fields[0],
-  UPB_SIZE(8, 16), 10, false, 255,
+  UPB_SIZE(8, 16), 11, false, 11, 255,
 };
 
 static const upb_msglayout *const envoy_config_rbac_v3_Permission_Set_submsgs[1] = {
@@ -108,13 +111,13 @@ static const upb_msglayout *const envoy_config_rbac_v3_Permission_Set_submsgs[1]
 };
 
 static const upb_msglayout_field envoy_config_rbac_v3_Permission_Set__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 11, 3},
+  {1, UPB_SIZE(0, 0), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout envoy_config_rbac_v3_Permission_Set_msginit = {
   &envoy_config_rbac_v3_Permission_Set_submsgs[0],
   &envoy_config_rbac_v3_Permission_Set__fields[0],
-  UPB_SIZE(8, 8), 1, false, 255,
+  UPB_SIZE(8, 8), 1, false, 1, 255,
 };
 
 static const upb_msglayout *const envoy_config_rbac_v3_Principal_submsgs[7] = {
@@ -128,23 +131,23 @@ static const upb_msglayout *const envoy_config_rbac_v3_Principal_submsgs[7] = {
 };
 
 static const upb_msglayout_field envoy_config_rbac_v3_Principal__fields[11] = {
-  {1, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 3, 11, 1},
-  {2, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 3, 11, 1},
-  {3, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 8, 1},
-  {4, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 2, 11, 1},
-  {5, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 11, 1},
-  {6, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 4, 11, 1},
-  {7, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 5, 11, 1},
-  {8, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 1, 11, 1},
-  {9, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 6, 11, 1},
-  {10, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 11, 1},
-  {11, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 11, 1},
+  {1, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 3, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 3, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 8, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 2, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 11, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 4, 11, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 5, 11, _UPB_MODE_SCALAR},
+  {8, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 1, 11, _UPB_MODE_SCALAR},
+  {9, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 6, 11, _UPB_MODE_SCALAR},
+  {10, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 11, _UPB_MODE_SCALAR},
+  {11, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_rbac_v3_Principal_msginit = {
   &envoy_config_rbac_v3_Principal_submsgs[0],
   &envoy_config_rbac_v3_Principal__fields[0],
-  UPB_SIZE(8, 16), 11, false, 255,
+  UPB_SIZE(8, 16), 11, false, 11, 255,
 };
 
 static const upb_msglayout *const envoy_config_rbac_v3_Principal_Set_submsgs[1] = {
@@ -152,13 +155,13 @@ static const upb_msglayout *const envoy_config_rbac_v3_Principal_Set_submsgs[1]
 };
 
 static const upb_msglayout_field envoy_config_rbac_v3_Principal_Set__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 11, 3},
+  {1, UPB_SIZE(0, 0), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout envoy_config_rbac_v3_Principal_Set_msginit = {
   &envoy_config_rbac_v3_Principal_Set_submsgs[0],
   &envoy_config_rbac_v3_Principal_Set__fields[0],
-  UPB_SIZE(8, 8), 1, false, 255,
+  UPB_SIZE(8, 8), 1, false, 1, 255,
 };
 
 static const upb_msglayout *const envoy_config_rbac_v3_Principal_Authenticated_submsgs[1] = {
@@ -166,13 +169,13 @@ static const upb_msglayout *const envoy_config_rbac_v3_Principal_Authenticated_s
 };
 
 static const upb_msglayout_field envoy_config_rbac_v3_Principal_Authenticated__fields[1] = {
-  {2, UPB_SIZE(4, 8), 1, 0, 11, 1},
+  {2, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_rbac_v3_Principal_Authenticated_msginit = {
   &envoy_config_rbac_v3_Principal_Authenticated_submsgs[0],
   &envoy_config_rbac_v3_Principal_Authenticated__fields[0],
-  UPB_SIZE(8, 16), 1, false, 255,
+  UPB_SIZE(8, 16), 1, false, 0, 255,
 };
 
 #include "upb/port_undef.inc"
index befa31f..89b54d9 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_CONFIG_RBAC_V3_RBAC_PROTO_UPB_H_
 #define ENVOY_CONFIG_RBAC_V3_RBAC_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -49,6 +49,7 @@ struct envoy_config_route_v3_HeaderMatcher;
 struct envoy_type_matcher_v3_MetadataMatcher;
 struct envoy_type_matcher_v3_PathMatcher;
 struct envoy_type_matcher_v3_StringMatcher;
+struct envoy_type_v3_Int32Range;
 struct google_api_expr_v1alpha1_CheckedExpr;
 struct google_api_expr_v1alpha1_Expr;
 extern const upb_msglayout envoy_config_core_v3_CidrRange_msginit;
@@ -56,6 +57,7 @@ extern const upb_msglayout envoy_config_route_v3_HeaderMatcher_msginit;
 extern const upb_msglayout envoy_type_matcher_v3_MetadataMatcher_msginit;
 extern const upb_msglayout envoy_type_matcher_v3_PathMatcher_msginit;
 extern const upb_msglayout envoy_type_matcher_v3_StringMatcher_msginit;
+extern const upb_msglayout envoy_type_v3_Int32Range_msginit;
 extern const upb_msglayout google_api_expr_v1alpha1_CheckedExpr_msginit;
 extern const upb_msglayout google_api_expr_v1alpha1_Expr_msginit;
 
@@ -74,13 +76,19 @@ UPB_INLINE envoy_config_rbac_v3_RBAC *envoy_config_rbac_v3_RBAC_new(upb_arena *a
 UPB_INLINE envoy_config_rbac_v3_RBAC *envoy_config_rbac_v3_RBAC_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_rbac_v3_RBAC *ret = envoy_config_rbac_v3_RBAC_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_rbac_v3_RBAC_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_rbac_v3_RBAC_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_rbac_v3_RBAC *envoy_config_rbac_v3_RBAC_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_rbac_v3_RBAC *ret = envoy_config_rbac_v3_RBAC_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_rbac_v3_RBAC_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_rbac_v3_RBAC_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_rbac_v3_RBAC_serialize(const envoy_config_rbac_v3_RBAC *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_rbac_v3_RBAC_msginit, arena, len);
@@ -126,13 +134,19 @@ UPB_INLINE envoy_config_rbac_v3_Policy *envoy_config_rbac_v3_Policy_new(upb_aren
 UPB_INLINE envoy_config_rbac_v3_Policy *envoy_config_rbac_v3_Policy_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_rbac_v3_Policy *ret = envoy_config_rbac_v3_Policy_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_rbac_v3_Policy_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_rbac_v3_Policy_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_rbac_v3_Policy *envoy_config_rbac_v3_Policy_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_rbac_v3_Policy *ret = envoy_config_rbac_v3_Policy_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_rbac_v3_Policy_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_rbac_v3_Policy_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_rbac_v3_Policy_serialize(const envoy_config_rbac_v3_Policy *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_rbac_v3_Policy_msginit, arena, len);
@@ -208,13 +222,19 @@ UPB_INLINE envoy_config_rbac_v3_Permission *envoy_config_rbac_v3_Permission_new(
 UPB_INLINE envoy_config_rbac_v3_Permission *envoy_config_rbac_v3_Permission_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_rbac_v3_Permission *ret = envoy_config_rbac_v3_Permission_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_rbac_v3_Permission_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_rbac_v3_Permission_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_rbac_v3_Permission *envoy_config_rbac_v3_Permission_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_rbac_v3_Permission *ret = envoy_config_rbac_v3_Permission_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_rbac_v3_Permission_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_rbac_v3_Permission_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_rbac_v3_Permission_serialize(const envoy_config_rbac_v3_Permission *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_rbac_v3_Permission_msginit, arena, len);
@@ -228,6 +248,7 @@ typedef enum {
   envoy_config_rbac_v3_Permission_rule_url_path = 10,
   envoy_config_rbac_v3_Permission_rule_destination_ip = 5,
   envoy_config_rbac_v3_Permission_rule_destination_port = 6,
+  envoy_config_rbac_v3_Permission_rule_destination_port_range = 11,
   envoy_config_rbac_v3_Permission_rule_metadata = 7,
   envoy_config_rbac_v3_Permission_rule_not_rule = 8,
   envoy_config_rbac_v3_Permission_rule_requested_server_name = 9,
@@ -255,6 +276,8 @@ UPB_INLINE bool envoy_config_rbac_v3_Permission_has_requested_server_name(const
 UPB_INLINE const struct envoy_type_matcher_v3_StringMatcher* envoy_config_rbac_v3_Permission_requested_server_name(const envoy_config_rbac_v3_Permission *msg) { return UPB_READ_ONEOF(msg, const struct envoy_type_matcher_v3_StringMatcher*, UPB_SIZE(0, 0), UPB_SIZE(4, 8), 9, NULL); }
 UPB_INLINE bool envoy_config_rbac_v3_Permission_has_url_path(const envoy_config_rbac_v3_Permission *msg) { return _upb_getoneofcase(msg, UPB_SIZE(4, 8)) == 10; }
 UPB_INLINE const struct envoy_type_matcher_v3_PathMatcher* envoy_config_rbac_v3_Permission_url_path(const envoy_config_rbac_v3_Permission *msg) { return UPB_READ_ONEOF(msg, const struct envoy_type_matcher_v3_PathMatcher*, UPB_SIZE(0, 0), UPB_SIZE(4, 8), 10, NULL); }
+UPB_INLINE bool envoy_config_rbac_v3_Permission_has_destination_port_range(const envoy_config_rbac_v3_Permission *msg) { return _upb_getoneofcase(msg, UPB_SIZE(4, 8)) == 11; }
+UPB_INLINE const struct envoy_type_v3_Int32Range* envoy_config_rbac_v3_Permission_destination_port_range(const envoy_config_rbac_v3_Permission *msg) { return UPB_READ_ONEOF(msg, const struct envoy_type_v3_Int32Range*, UPB_SIZE(0, 0), UPB_SIZE(4, 8), 11, NULL); }
 
 UPB_INLINE void envoy_config_rbac_v3_Permission_set_and_rules(envoy_config_rbac_v3_Permission *msg, envoy_config_rbac_v3_Permission_Set* value) {
   UPB_WRITE_ONEOF(msg, envoy_config_rbac_v3_Permission_Set*, UPB_SIZE(0, 0), value, UPB_SIZE(4, 8), 1);
@@ -358,6 +381,18 @@ UPB_INLINE struct envoy_type_matcher_v3_PathMatcher* envoy_config_rbac_v3_Permis
   }
   return sub;
 }
+UPB_INLINE void envoy_config_rbac_v3_Permission_set_destination_port_range(envoy_config_rbac_v3_Permission *msg, struct envoy_type_v3_Int32Range* value) {
+  UPB_WRITE_ONEOF(msg, struct envoy_type_v3_Int32Range*, UPB_SIZE(0, 0), value, UPB_SIZE(4, 8), 11);
+}
+UPB_INLINE struct envoy_type_v3_Int32Range* envoy_config_rbac_v3_Permission_mutable_destination_port_range(envoy_config_rbac_v3_Permission *msg, upb_arena *arena) {
+  struct envoy_type_v3_Int32Range* sub = (struct envoy_type_v3_Int32Range*)envoy_config_rbac_v3_Permission_destination_port_range(msg);
+  if (sub == NULL) {
+    sub = (struct envoy_type_v3_Int32Range*)_upb_msg_new(&envoy_type_v3_Int32Range_msginit, arena);
+    if (!sub) return NULL;
+    envoy_config_rbac_v3_Permission_set_destination_port_range(msg, sub);
+  }
+  return sub;
+}
 
 /* envoy.config.rbac.v3.Permission.Set */
 
@@ -367,13 +402,19 @@ UPB_INLINE envoy_config_rbac_v3_Permission_Set *envoy_config_rbac_v3_Permission_
 UPB_INLINE envoy_config_rbac_v3_Permission_Set *envoy_config_rbac_v3_Permission_Set_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_rbac_v3_Permission_Set *ret = envoy_config_rbac_v3_Permission_Set_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_rbac_v3_Permission_Set_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_rbac_v3_Permission_Set_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_rbac_v3_Permission_Set *envoy_config_rbac_v3_Permission_Set_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_rbac_v3_Permission_Set *ret = envoy_config_rbac_v3_Permission_Set_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_rbac_v3_Permission_Set_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_rbac_v3_Permission_Set_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_rbac_v3_Permission_Set_serialize(const envoy_config_rbac_v3_Permission_Set *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_rbac_v3_Permission_Set_msginit, arena, len);
@@ -404,13 +445,19 @@ UPB_INLINE envoy_config_rbac_v3_Principal *envoy_config_rbac_v3_Principal_new(up
 UPB_INLINE envoy_config_rbac_v3_Principal *envoy_config_rbac_v3_Principal_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_rbac_v3_Principal *ret = envoy_config_rbac_v3_Principal_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_rbac_v3_Principal_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_rbac_v3_Principal_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_rbac_v3_Principal *envoy_config_rbac_v3_Principal_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_rbac_v3_Principal *ret = envoy_config_rbac_v3_Principal_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_rbac_v3_Principal_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_rbac_v3_Principal_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_rbac_v3_Principal_serialize(const envoy_config_rbac_v3_Principal *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_rbac_v3_Principal_msginit, arena, len);
@@ -587,13 +634,19 @@ UPB_INLINE envoy_config_rbac_v3_Principal_Set *envoy_config_rbac_v3_Principal_Se
 UPB_INLINE envoy_config_rbac_v3_Principal_Set *envoy_config_rbac_v3_Principal_Set_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_rbac_v3_Principal_Set *ret = envoy_config_rbac_v3_Principal_Set_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_rbac_v3_Principal_Set_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_rbac_v3_Principal_Set_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_rbac_v3_Principal_Set *envoy_config_rbac_v3_Principal_Set_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_rbac_v3_Principal_Set *ret = envoy_config_rbac_v3_Principal_Set_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_rbac_v3_Principal_Set_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_rbac_v3_Principal_Set_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_rbac_v3_Principal_Set_serialize(const envoy_config_rbac_v3_Principal_Set *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_rbac_v3_Principal_Set_msginit, arena, len);
@@ -624,13 +677,19 @@ UPB_INLINE envoy_config_rbac_v3_Principal_Authenticated *envoy_config_rbac_v3_Pr
 UPB_INLINE envoy_config_rbac_v3_Principal_Authenticated *envoy_config_rbac_v3_Principal_Authenticated_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_rbac_v3_Principal_Authenticated *ret = envoy_config_rbac_v3_Principal_Authenticated_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_rbac_v3_Principal_Authenticated_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_rbac_v3_Principal_Authenticated_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_rbac_v3_Principal_Authenticated *envoy_config_rbac_v3_Principal_Authenticated_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_rbac_v3_Principal_Authenticated *ret = envoy_config_rbac_v3_Principal_Authenticated_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_rbac_v3_Principal_Authenticated_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_rbac_v3_Principal_Authenticated_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_rbac_v3_Principal_Authenticated_serialize(const envoy_config_rbac_v3_Principal_Authenticated *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_rbac_v3_Principal_Authenticated_msginit, arena, len);
index d82eb1d..4bd3447 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/config/route/v3/route.upb.h"
 #include "envoy/config/core/v3/base.upb.h"
 #include "envoy/config/core/v3/config_source.upb.h"
@@ -30,24 +30,24 @@ static const upb_msglayout *const envoy_config_route_v3_RouteConfiguration_subms
 };
 
 static const upb_msglayout_field envoy_config_route_v3_RouteConfiguration__fields[12] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(24, 48), 0, 3, 11, 3},
-  {3, UPB_SIZE(28, 56), 0, 0, 9, 3},
-  {4, UPB_SIZE(32, 64), 0, 0, 11, 3},
-  {5, UPB_SIZE(36, 72), 0, 0, 9, 3},
-  {6, UPB_SIZE(40, 80), 0, 0, 11, 3},
-  {7, UPB_SIZE(12, 24), 1, 4, 11, 1},
-  {8, UPB_SIZE(44, 88), 0, 0, 9, 3},
-  {9, UPB_SIZE(16, 32), 2, 2, 11, 1},
-  {10, UPB_SIZE(1, 1), 0, 0, 8, 1},
-  {11, UPB_SIZE(20, 40), 3, 5, 11, 1},
-  {12, UPB_SIZE(48, 96), 0, 1, 11, 3},
+  {1, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(24, 48), 0, 3, 11, _UPB_MODE_ARRAY},
+  {3, UPB_SIZE(28, 56), 0, 0, 9, _UPB_MODE_ARRAY},
+  {4, UPB_SIZE(32, 64), 0, 0, 11, _UPB_MODE_ARRAY},
+  {5, UPB_SIZE(36, 72), 0, 0, 9, _UPB_MODE_ARRAY},
+  {6, UPB_SIZE(40, 80), 0, 0, 11, _UPB_MODE_ARRAY},
+  {7, UPB_SIZE(12, 24), 1, 4, 11, _UPB_MODE_SCALAR},
+  {8, UPB_SIZE(44, 88), 0, 0, 9, _UPB_MODE_ARRAY},
+  {9, UPB_SIZE(16, 32), 2, 2, 11, _UPB_MODE_SCALAR},
+  {10, UPB_SIZE(1, 1), 0, 0, 8, _UPB_MODE_SCALAR},
+  {11, UPB_SIZE(20, 40), 3, 5, 11, _UPB_MODE_SCALAR},
+  {12, UPB_SIZE(48, 96), 0, 1, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout envoy_config_route_v3_RouteConfiguration_msginit = {
   &envoy_config_route_v3_RouteConfiguration_submsgs[0],
   &envoy_config_route_v3_RouteConfiguration__fields[0],
-  UPB_SIZE(56, 112), 12, false, 255,
+  UPB_SIZE(56, 112), 12, false, 12, 255,
 };
 
 static const upb_msglayout *const envoy_config_route_v3_ClusterSpecifierPlugin_submsgs[1] = {
@@ -55,13 +55,13 @@ static const upb_msglayout *const envoy_config_route_v3_ClusterSpecifierPlugin_s
 };
 
 static const upb_msglayout_field envoy_config_route_v3_ClusterSpecifierPlugin__fields[1] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_route_v3_ClusterSpecifierPlugin_msginit = {
   &envoy_config_route_v3_ClusterSpecifierPlugin_submsgs[0],
   &envoy_config_route_v3_ClusterSpecifierPlugin__fields[0],
-  UPB_SIZE(8, 16), 1, false, 255,
+  UPB_SIZE(8, 16), 1, false, 1, 255,
 };
 
 static const upb_msglayout *const envoy_config_route_v3_Vhds_submsgs[1] = {
@@ -69,13 +69,13 @@ static const upb_msglayout *const envoy_config_route_v3_Vhds_submsgs[1] = {
 };
 
 static const upb_msglayout_field envoy_config_route_v3_Vhds__fields[1] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_route_v3_Vhds_msginit = {
   &envoy_config_route_v3_Vhds_submsgs[0],
   &envoy_config_route_v3_Vhds__fields[0],
-  UPB_SIZE(8, 16), 1, false, 255,
+  UPB_SIZE(8, 16), 1, false, 1, 255,
 };
 
 #include "upb/port_undef.inc"
index af2ed7e..c9127c4 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_CONFIG_ROUTE_V3_ROUTE_PROTO_UPB_H_
 #define ENVOY_CONFIG_ROUTE_V3_ROUTE_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -51,13 +51,19 @@ UPB_INLINE envoy_config_route_v3_RouteConfiguration *envoy_config_route_v3_Route
 UPB_INLINE envoy_config_route_v3_RouteConfiguration *envoy_config_route_v3_RouteConfiguration_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_route_v3_RouteConfiguration *ret = envoy_config_route_v3_RouteConfiguration_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_route_v3_RouteConfiguration_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_route_v3_RouteConfiguration_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_route_v3_RouteConfiguration *envoy_config_route_v3_RouteConfiguration_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_route_v3_RouteConfiguration *ret = envoy_config_route_v3_RouteConfiguration_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_route_v3_RouteConfiguration_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_route_v3_RouteConfiguration_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_route_v3_RouteConfiguration_serialize(const envoy_config_route_v3_RouteConfiguration *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_route_v3_RouteConfiguration_msginit, arena, len);
@@ -219,13 +225,19 @@ UPB_INLINE envoy_config_route_v3_ClusterSpecifierPlugin *envoy_config_route_v3_C
 UPB_INLINE envoy_config_route_v3_ClusterSpecifierPlugin *envoy_config_route_v3_ClusterSpecifierPlugin_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_route_v3_ClusterSpecifierPlugin *ret = envoy_config_route_v3_ClusterSpecifierPlugin_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_route_v3_ClusterSpecifierPlugin_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_route_v3_ClusterSpecifierPlugin_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_route_v3_ClusterSpecifierPlugin *envoy_config_route_v3_ClusterSpecifierPlugin_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_route_v3_ClusterSpecifierPlugin *ret = envoy_config_route_v3_ClusterSpecifierPlugin_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_route_v3_ClusterSpecifierPlugin_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_route_v3_ClusterSpecifierPlugin_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_route_v3_ClusterSpecifierPlugin_serialize(const envoy_config_route_v3_ClusterSpecifierPlugin *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_route_v3_ClusterSpecifierPlugin_msginit, arena, len);
@@ -256,13 +268,19 @@ UPB_INLINE envoy_config_route_v3_Vhds *envoy_config_route_v3_Vhds_new(upb_arena
 UPB_INLINE envoy_config_route_v3_Vhds *envoy_config_route_v3_Vhds_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_route_v3_Vhds *ret = envoy_config_route_v3_Vhds_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_route_v3_Vhds_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_route_v3_Vhds_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_route_v3_Vhds *envoy_config_route_v3_Vhds_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_route_v3_Vhds *ret = envoy_config_route_v3_Vhds_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_route_v3_Vhds_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_route_v3_Vhds_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_route_v3_Vhds_serialize(const envoy_config_route_v3_Vhds *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_route_v3_Vhds_msginit, arena, len);
index ca05b29..79962b1 100644 (file)
@@ -7,11 +7,12 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/config/route/v3/route_components.upb.h"
 #include "envoy/config/core/v3/base.upb.h"
 #include "envoy/config/core/v3/extension.upb.h"
 #include "envoy/config/core/v3/proxy_protocol.upb.h"
+#include "envoy/type/matcher/v3/metadata.upb.h"
 #include "envoy/type/matcher/v3/regex.upb.h"
 #include "envoy/type/matcher/v3/string.upb.h"
 #include "envoy/type/metadata/v3/metadata.upb.h"
@@ -43,30 +44,30 @@ static const upb_msglayout *const envoy_config_route_v3_VirtualHost_submsgs[10]
 };
 
 static const upb_msglayout_field envoy_config_route_v3_VirtualHost__fields[18] = {
-  {1, UPB_SIZE(12, 16), 0, 0, 9, 1},
-  {2, UPB_SIZE(40, 72), 0, 0, 9, 3},
-  {3, UPB_SIZE(44, 80), 0, 5, 11, 3},
-  {4, UPB_SIZE(4, 4), 0, 0, 14, 1},
-  {5, UPB_SIZE(48, 88), 0, 6, 11, 3},
-  {6, UPB_SIZE(52, 96), 0, 3, 11, 3},
-  {7, UPB_SIZE(56, 104), 0, 0, 11, 3},
-  {8, UPB_SIZE(20, 32), 1, 1, 11, 1},
-  {10, UPB_SIZE(60, 112), 0, 0, 11, 3},
-  {11, UPB_SIZE(64, 120), 0, 0, 9, 3},
-  {13, UPB_SIZE(68, 128), 0, 0, 9, 3},
-  {14, UPB_SIZE(8, 8), 0, 0, 8, 1},
-  {15, UPB_SIZE(72, 136), 0, 7, 11, _UPB_LABEL_MAP},
-  {16, UPB_SIZE(24, 40), 2, 4, 11, 1},
-  {17, UPB_SIZE(28, 48), 3, 2, 11, 1},
-  {18, UPB_SIZE(32, 56), 4, 9, 11, 1},
-  {19, UPB_SIZE(9, 9), 0, 0, 8, 1},
-  {20, UPB_SIZE(36, 64), 5, 8, 11, 1},
+  {1, UPB_SIZE(12, 16), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(40, 72), 0, 0, 9, _UPB_MODE_ARRAY},
+  {3, UPB_SIZE(44, 80), 0, 5, 11, _UPB_MODE_ARRAY},
+  {4, UPB_SIZE(4, 4), 0, 0, 14, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(48, 88), 0, 6, 11, _UPB_MODE_ARRAY},
+  {6, UPB_SIZE(52, 96), 0, 3, 11, _UPB_MODE_ARRAY},
+  {7, UPB_SIZE(56, 104), 0, 0, 11, _UPB_MODE_ARRAY},
+  {8, UPB_SIZE(20, 32), 1, 1, 11, _UPB_MODE_SCALAR},
+  {10, UPB_SIZE(60, 112), 0, 0, 11, _UPB_MODE_ARRAY},
+  {11, UPB_SIZE(64, 120), 0, 0, 9, _UPB_MODE_ARRAY},
+  {13, UPB_SIZE(68, 128), 0, 0, 9, _UPB_MODE_ARRAY},
+  {14, UPB_SIZE(8, 8), 0, 0, 8, _UPB_MODE_SCALAR},
+  {15, UPB_SIZE(72, 136), 0, 7, 11, _UPB_MODE_MAP},
+  {16, UPB_SIZE(24, 40), 2, 4, 11, _UPB_MODE_SCALAR},
+  {17, UPB_SIZE(28, 48), 3, 2, 11, _UPB_MODE_SCALAR},
+  {18, UPB_SIZE(32, 56), 4, 9, 11, _UPB_MODE_SCALAR},
+  {19, UPB_SIZE(9, 9), 0, 0, 8, _UPB_MODE_SCALAR},
+  {20, UPB_SIZE(36, 64), 5, 8, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_route_v3_VirtualHost_msginit = {
   &envoy_config_route_v3_VirtualHost_submsgs[0],
   &envoy_config_route_v3_VirtualHost__fields[0],
-  UPB_SIZE(80, 144), 18, false, 255,
+  UPB_SIZE(80, 144), 18, false, 8, 255,
 };
 
 static const upb_msglayout *const envoy_config_route_v3_VirtualHost_TypedPerFilterConfigEntry_submsgs[1] = {
@@ -74,14 +75,14 @@ static const upb_msglayout *const envoy_config_route_v3_VirtualHost_TypedPerFilt
 };
 
 static const upb_msglayout_field envoy_config_route_v3_VirtualHost_TypedPerFilterConfigEntry__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {2, UPB_SIZE(8, 16), 0, 0, 11, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 0, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_route_v3_VirtualHost_TypedPerFilterConfigEntry_msginit = {
   &envoy_config_route_v3_VirtualHost_TypedPerFilterConfigEntry_submsgs[0],
   &envoy_config_route_v3_VirtualHost_TypedPerFilterConfigEntry__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_config_route_v3_FilterAction_submsgs[1] = {
@@ -89,13 +90,13 @@ static const upb_msglayout *const envoy_config_route_v3_FilterAction_submsgs[1]
 };
 
 static const upb_msglayout_field envoy_config_route_v3_FilterAction__fields[1] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_route_v3_FilterAction_msginit = {
   &envoy_config_route_v3_FilterAction_submsgs[0],
   &envoy_config_route_v3_FilterAction__fields[0],
-  UPB_SIZE(8, 16), 1, false, 255,
+  UPB_SIZE(8, 16), 1, false, 1, 255,
 };
 
 static const upb_msglayout *const envoy_config_route_v3_Route_submsgs[12] = {
@@ -114,28 +115,28 @@ static const upb_msglayout *const envoy_config_route_v3_Route_submsgs[12] = {
 };
 
 static const upb_msglayout_field envoy_config_route_v3_Route__fields[16] = {
-  {1, UPB_SIZE(12, 24), 1, 9, 11, 1},
-  {2, UPB_SIZE(52, 104), UPB_SIZE(-57, -113), 8, 11, 1},
-  {3, UPB_SIZE(52, 104), UPB_SIZE(-57, -113), 6, 11, 1},
-  {4, UPB_SIZE(16, 32), 2, 1, 11, 1},
-  {5, UPB_SIZE(20, 40), 3, 2, 11, 1},
-  {7, UPB_SIZE(52, 104), UPB_SIZE(-57, -113), 3, 11, 1},
-  {9, UPB_SIZE(32, 64), 0, 0, 11, 3},
-  {10, UPB_SIZE(36, 72), 0, 0, 11, 3},
-  {11, UPB_SIZE(40, 80), 0, 0, 9, 3},
-  {12, UPB_SIZE(44, 88), 0, 0, 9, 3},
-  {13, UPB_SIZE(48, 96), 0, 7, 11, _UPB_LABEL_MAP},
-  {14, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {15, UPB_SIZE(24, 48), 4, 10, 11, 1},
-  {16, UPB_SIZE(28, 56), 5, 11, 11, 1},
-  {17, UPB_SIZE(52, 104), UPB_SIZE(-57, -113), 4, 11, 1},
-  {18, UPB_SIZE(52, 104), UPB_SIZE(-57, -113), 5, 11, 1},
+  {1, UPB_SIZE(12, 24), 1, 9, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(52, 104), UPB_SIZE(-57, -113), 8, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(52, 104), UPB_SIZE(-57, -113), 6, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(16, 32), 2, 1, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(20, 40), 3, 2, 11, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(52, 104), UPB_SIZE(-57, -113), 3, 11, _UPB_MODE_SCALAR},
+  {9, UPB_SIZE(32, 64), 0, 0, 11, _UPB_MODE_ARRAY},
+  {10, UPB_SIZE(36, 72), 0, 0, 11, _UPB_MODE_ARRAY},
+  {11, UPB_SIZE(40, 80), 0, 0, 9, _UPB_MODE_ARRAY},
+  {12, UPB_SIZE(44, 88), 0, 0, 9, _UPB_MODE_ARRAY},
+  {13, UPB_SIZE(48, 96), 0, 7, 11, _UPB_MODE_MAP},
+  {14, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {15, UPB_SIZE(24, 48), 4, 10, 11, _UPB_MODE_SCALAR},
+  {16, UPB_SIZE(28, 56), 5, 11, 11, _UPB_MODE_SCALAR},
+  {17, UPB_SIZE(52, 104), UPB_SIZE(-57, -113), 4, 11, _UPB_MODE_SCALAR},
+  {18, UPB_SIZE(52, 104), UPB_SIZE(-57, -113), 5, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_route_v3_Route_msginit = {
   &envoy_config_route_v3_Route_submsgs[0],
   &envoy_config_route_v3_Route__fields[0],
-  UPB_SIZE(64, 128), 16, false, 255,
+  UPB_SIZE(64, 128), 16, false, 5, 255,
 };
 
 static const upb_msglayout *const envoy_config_route_v3_Route_TypedPerFilterConfigEntry_submsgs[1] = {
@@ -143,14 +144,14 @@ static const upb_msglayout *const envoy_config_route_v3_Route_TypedPerFilterConf
 };
 
 static const upb_msglayout_field envoy_config_route_v3_Route_TypedPerFilterConfigEntry__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {2, UPB_SIZE(8, 16), 0, 0, 11, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 0, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_route_v3_Route_TypedPerFilterConfigEntry_msginit = {
   &envoy_config_route_v3_Route_TypedPerFilterConfigEntry_submsgs[0],
   &envoy_config_route_v3_Route_TypedPerFilterConfigEntry__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_config_route_v3_WeightedCluster_submsgs[2] = {
@@ -159,15 +160,15 @@ static const upb_msglayout *const envoy_config_route_v3_WeightedCluster_submsgs[
 };
 
 static const upb_msglayout_field envoy_config_route_v3_WeightedCluster__fields[3] = {
-  {1, UPB_SIZE(16, 32), 0, 0, 11, 3},
-  {2, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {3, UPB_SIZE(12, 24), 1, 1, 11, 1},
+  {1, UPB_SIZE(16, 32), 0, 0, 11, _UPB_MODE_ARRAY},
+  {2, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(12, 24), 1, 1, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_route_v3_WeightedCluster_msginit = {
   &envoy_config_route_v3_WeightedCluster_submsgs[0],
   &envoy_config_route_v3_WeightedCluster__fields[0],
-  UPB_SIZE(24, 48), 3, false, 255,
+  UPB_SIZE(24, 48), 3, false, 3, 255,
 };
 
 static const upb_msglayout *const envoy_config_route_v3_WeightedCluster_ClusterWeight_submsgs[4] = {
@@ -177,22 +178,23 @@ static const upb_msglayout *const envoy_config_route_v3_WeightedCluster_ClusterW
   &google_protobuf_UInt32Value_msginit,
 };
 
-static const upb_msglayout_field envoy_config_route_v3_WeightedCluster_ClusterWeight__fields[9] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(12, 24), 1, 3, 11, 1},
-  {3, UPB_SIZE(16, 32), 2, 1, 11, 1},
-  {4, UPB_SIZE(20, 40), 0, 0, 11, 3},
-  {5, UPB_SIZE(24, 48), 0, 0, 11, 3},
-  {6, UPB_SIZE(28, 56), 0, 0, 9, 3},
-  {9, UPB_SIZE(32, 64), 0, 0, 9, 3},
-  {10, UPB_SIZE(36, 72), 0, 2, 11, _UPB_LABEL_MAP},
-  {11, UPB_SIZE(40, 80), UPB_SIZE(-49, -97), 0, 9, 1},
+static const upb_msglayout_field envoy_config_route_v3_WeightedCluster_ClusterWeight__fields[10] = {
+  {1, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(20, 40), 1, 3, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(24, 48), 2, 1, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(28, 56), 0, 0, 11, _UPB_MODE_ARRAY},
+  {5, UPB_SIZE(32, 64), 0, 0, 11, _UPB_MODE_ARRAY},
+  {6, UPB_SIZE(36, 72), 0, 0, 9, _UPB_MODE_ARRAY},
+  {9, UPB_SIZE(40, 80), 0, 0, 9, _UPB_MODE_ARRAY},
+  {10, UPB_SIZE(44, 88), 0, 2, 11, _UPB_MODE_MAP},
+  {11, UPB_SIZE(48, 96), UPB_SIZE(-57, -113), 0, 9, _UPB_MODE_SCALAR},
+  {12, UPB_SIZE(12, 24), 0, 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_route_v3_WeightedCluster_ClusterWeight_msginit = {
   &envoy_config_route_v3_WeightedCluster_ClusterWeight_submsgs[0],
   &envoy_config_route_v3_WeightedCluster_ClusterWeight__fields[0],
-  UPB_SIZE(56, 112), 9, false, 255,
+  UPB_SIZE(64, 128), 10, false, 6, 255,
 };
 
 static const upb_msglayout *const envoy_config_route_v3_WeightedCluster_ClusterWeight_TypedPerFilterConfigEntry_submsgs[1] = {
@@ -200,50 +202,52 @@ static const upb_msglayout *const envoy_config_route_v3_WeightedCluster_ClusterW
 };
 
 static const upb_msglayout_field envoy_config_route_v3_WeightedCluster_ClusterWeight_TypedPerFilterConfigEntry__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {2, UPB_SIZE(8, 16), 0, 0, 11, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 0, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_route_v3_WeightedCluster_ClusterWeight_TypedPerFilterConfigEntry_msginit = {
   &envoy_config_route_v3_WeightedCluster_ClusterWeight_TypedPerFilterConfigEntry_submsgs[0],
   &envoy_config_route_v3_WeightedCluster_ClusterWeight_TypedPerFilterConfigEntry__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
-static const upb_msglayout *const envoy_config_route_v3_RouteMatch_submsgs[8] = {
+static const upb_msglayout *const envoy_config_route_v3_RouteMatch_submsgs[9] = {
   &envoy_config_core_v3_RuntimeFractionalPercent_msginit,
   &envoy_config_route_v3_HeaderMatcher_msginit,
   &envoy_config_route_v3_QueryParameterMatcher_msginit,
   &envoy_config_route_v3_RouteMatch_ConnectMatcher_msginit,
   &envoy_config_route_v3_RouteMatch_GrpcRouteMatchOptions_msginit,
   &envoy_config_route_v3_RouteMatch_TlsContextMatchOptions_msginit,
+  &envoy_type_matcher_v3_MetadataMatcher_msginit,
   &envoy_type_matcher_v3_RegexMatcher_msginit,
   &google_protobuf_BoolValue_msginit,
 };
 
-static const upb_msglayout_field envoy_config_route_v3_RouteMatch__fields[10] = {
-  {1, UPB_SIZE(28, 56), UPB_SIZE(-37, -73), 0, 9, 1},
-  {2, UPB_SIZE(28, 56), UPB_SIZE(-37, -73), 0, 9, 1},
-  {4, UPB_SIZE(4, 8), 1, 7, 11, 1},
-  {6, UPB_SIZE(20, 40), 0, 1, 11, 3},
-  {7, UPB_SIZE(24, 48), 0, 2, 11, 3},
-  {8, UPB_SIZE(8, 16), 2, 4, 11, 1},
-  {9, UPB_SIZE(12, 24), 3, 0, 11, 1},
-  {10, UPB_SIZE(28, 56), UPB_SIZE(-37, -73), 6, 11, 1},
-  {11, UPB_SIZE(16, 32), 4, 5, 11, 1},
-  {12, UPB_SIZE(28, 56), UPB_SIZE(-37, -73), 3, 11, 1},
+static const upb_msglayout_field envoy_config_route_v3_RouteMatch__fields[11] = {
+  {1, UPB_SIZE(32, 64), UPB_SIZE(-41, -81), 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(32, 64), UPB_SIZE(-41, -81), 0, 9, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(4, 8), 1, 8, 11, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(20, 40), 0, 1, 11, _UPB_MODE_ARRAY},
+  {7, UPB_SIZE(24, 48), 0, 2, 11, _UPB_MODE_ARRAY},
+  {8, UPB_SIZE(8, 16), 2, 4, 11, _UPB_MODE_SCALAR},
+  {9, UPB_SIZE(12, 24), 3, 0, 11, _UPB_MODE_SCALAR},
+  {10, UPB_SIZE(32, 64), UPB_SIZE(-41, -81), 7, 11, _UPB_MODE_SCALAR},
+  {11, UPB_SIZE(16, 32), 4, 5, 11, _UPB_MODE_SCALAR},
+  {12, UPB_SIZE(32, 64), UPB_SIZE(-41, -81), 3, 11, _UPB_MODE_SCALAR},
+  {13, UPB_SIZE(28, 56), 0, 6, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout envoy_config_route_v3_RouteMatch_msginit = {
   &envoy_config_route_v3_RouteMatch_submsgs[0],
   &envoy_config_route_v3_RouteMatch__fields[0],
-  UPB_SIZE(40, 80), 10, false, 255,
+  UPB_SIZE(48, 96), 11, false, 2, 255,
 };
 
 const upb_msglayout envoy_config_route_v3_RouteMatch_GrpcRouteMatchOptions_msginit = {
   NULL,
   NULL,
-  UPB_SIZE(0, 0), 0, false, 255,
+  UPB_SIZE(0, 0), 0, false, 0, 255,
 };
 
 static const upb_msglayout *const envoy_config_route_v3_RouteMatch_TlsContextMatchOptions_submsgs[1] = {
@@ -251,20 +255,20 @@ static const upb_msglayout *const envoy_config_route_v3_RouteMatch_TlsContextMat
 };
 
 static const upb_msglayout_field envoy_config_route_v3_RouteMatch_TlsContextMatchOptions__fields[2] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
-  {2, UPB_SIZE(8, 16), 2, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 2, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_route_v3_RouteMatch_TlsContextMatchOptions_msginit = {
   &envoy_config_route_v3_RouteMatch_TlsContextMatchOptions_submsgs[0],
   &envoy_config_route_v3_RouteMatch_TlsContextMatchOptions__fields[0],
-  UPB_SIZE(16, 24), 2, false, 255,
+  UPB_SIZE(16, 24), 2, false, 2, 255,
 };
 
 const upb_msglayout envoy_config_route_v3_RouteMatch_ConnectMatcher_msginit = {
   NULL,
   NULL,
-  UPB_SIZE(0, 0), 0, false, 255,
+  UPB_SIZE(0, 0), 0, false, 0, 255,
 };
 
 static const upb_msglayout *const envoy_config_route_v3_CorsPolicy_submsgs[3] = {
@@ -274,20 +278,20 @@ static const upb_msglayout *const envoy_config_route_v3_CorsPolicy_submsgs[3] =
 };
 
 static const upb_msglayout_field envoy_config_route_v3_CorsPolicy__fields[8] = {
-  {2, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {3, UPB_SIZE(12, 24), 0, 0, 9, 1},
-  {4, UPB_SIZE(20, 40), 0, 0, 9, 1},
-  {5, UPB_SIZE(28, 56), 0, 0, 9, 1},
-  {6, UPB_SIZE(36, 72), 1, 2, 11, 1},
-  {9, UPB_SIZE(48, 96), UPB_SIZE(-53, -105), 0, 11, 1},
-  {10, UPB_SIZE(40, 80), 2, 0, 11, 1},
-  {11, UPB_SIZE(44, 88), 0, 1, 11, 3},
+  {2, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(12, 24), 0, 0, 9, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(20, 40), 0, 0, 9, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(28, 56), 0, 0, 9, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(36, 72), 1, 2, 11, _UPB_MODE_SCALAR},
+  {9, UPB_SIZE(48, 96), UPB_SIZE(-53, -105), 0, 11, _UPB_MODE_SCALAR},
+  {10, UPB_SIZE(40, 80), 2, 0, 11, _UPB_MODE_SCALAR},
+  {11, UPB_SIZE(44, 88), 0, 1, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout envoy_config_route_v3_CorsPolicy_msginit = {
   &envoy_config_route_v3_CorsPolicy_submsgs[0],
   &envoy_config_route_v3_CorsPolicy__fields[0],
-  UPB_SIZE(56, 112), 8, false, 255,
+  UPB_SIZE(56, 112), 8, false, 0, 255,
 };
 
 static const upb_msglayout *const envoy_config_route_v3_RouteAction_submsgs[16] = {
@@ -310,42 +314,42 @@ static const upb_msglayout *const envoy_config_route_v3_RouteAction_submsgs[16]
 };
 
 static const upb_msglayout_field envoy_config_route_v3_RouteAction__fields[30] = {
-  {1, UPB_SIZE(96, 176), UPB_SIZE(-105, -193), 0, 9, 1},
-  {2, UPB_SIZE(96, 176), UPB_SIZE(-105, -193), 0, 9, 1},
-  {3, UPB_SIZE(96, 176), UPB_SIZE(-105, -193), 10, 11, 1},
-  {4, UPB_SIZE(24, 32), 1, 0, 11, 1},
-  {5, UPB_SIZE(16, 16), 0, 0, 9, 1},
-  {6, UPB_SIZE(108, 200), UPB_SIZE(-117, -217), 0, 9, 1},
-  {7, UPB_SIZE(108, 200), UPB_SIZE(-117, -217), 13, 11, 1},
-  {8, UPB_SIZE(28, 40), 2, 14, 11, 1},
-  {9, UPB_SIZE(32, 48), 3, 5, 11, 1},
-  {11, UPB_SIZE(4, 4), 0, 0, 14, 1},
-  {13, UPB_SIZE(80, 144), 0, 4, 11, 3},
-  {14, UPB_SIZE(36, 56), 4, 13, 11, 1},
-  {15, UPB_SIZE(84, 152), 0, 6, 11, 3},
-  {17, UPB_SIZE(40, 64), 5, 1, 11, 1},
-  {20, UPB_SIZE(8, 8), 0, 0, 14, 1},
-  {23, UPB_SIZE(44, 72), 6, 14, 11, 1},
-  {24, UPB_SIZE(48, 80), 7, 14, 11, 1},
-  {25, UPB_SIZE(88, 160), 0, 9, 11, 3},
-  {26, UPB_SIZE(12, 12), 0, 0, 14, 1},
-  {27, UPB_SIZE(52, 88), 8, 2, 11, 1},
-  {28, UPB_SIZE(56, 96), 9, 14, 11, 1},
-  {29, UPB_SIZE(108, 200), UPB_SIZE(-117, -217), 0, 9, 1},
-  {30, UPB_SIZE(92, 168), 0, 8, 11, 3},
-  {31, UPB_SIZE(60, 104), 10, 15, 11, 1},
-  {32, UPB_SIZE(64, 112), 11, 11, 11, 1},
-  {33, UPB_SIZE(68, 120), 12, 12, 11, 1},
-  {34, UPB_SIZE(72, 128), 13, 3, 11, 1},
-  {35, UPB_SIZE(108, 200), UPB_SIZE(-117, -217), 11, 11, 1},
-  {36, UPB_SIZE(76, 136), 14, 7, 11, 1},
-  {37, UPB_SIZE(96, 176), UPB_SIZE(-105, -193), 0, 9, 1},
+  {1, UPB_SIZE(96, 176), UPB_SIZE(-105, -193), 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(96, 176), UPB_SIZE(-105, -193), 0, 9, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(96, 176), UPB_SIZE(-105, -193), 10, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(24, 32), 1, 0, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(16, 16), 0, 0, 9, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(108, 200), UPB_SIZE(-117, -217), 0, 9, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(108, 200), UPB_SIZE(-117, -217), 13, 11, _UPB_MODE_SCALAR},
+  {8, UPB_SIZE(28, 40), 2, 14, 11, _UPB_MODE_SCALAR},
+  {9, UPB_SIZE(32, 48), 3, 5, 11, _UPB_MODE_SCALAR},
+  {11, UPB_SIZE(4, 4), 0, 0, 14, _UPB_MODE_SCALAR},
+  {13, UPB_SIZE(80, 144), 0, 4, 11, _UPB_MODE_ARRAY},
+  {14, UPB_SIZE(36, 56), 4, 13, 11, _UPB_MODE_SCALAR},
+  {15, UPB_SIZE(84, 152), 0, 6, 11, _UPB_MODE_ARRAY},
+  {17, UPB_SIZE(40, 64), 5, 1, 11, _UPB_MODE_SCALAR},
+  {20, UPB_SIZE(8, 8), 0, 0, 14, _UPB_MODE_SCALAR},
+  {23, UPB_SIZE(44, 72), 6, 14, 11, _UPB_MODE_SCALAR},
+  {24, UPB_SIZE(48, 80), 7, 14, 11, _UPB_MODE_SCALAR},
+  {25, UPB_SIZE(88, 160), 0, 9, 11, _UPB_MODE_ARRAY},
+  {26, UPB_SIZE(12, 12), 0, 0, 14, _UPB_MODE_SCALAR},
+  {27, UPB_SIZE(52, 88), 8, 2, 11, _UPB_MODE_SCALAR},
+  {28, UPB_SIZE(56, 96), 9, 14, 11, _UPB_MODE_SCALAR},
+  {29, UPB_SIZE(108, 200), UPB_SIZE(-117, -217), 0, 9, _UPB_MODE_SCALAR},
+  {30, UPB_SIZE(92, 168), 0, 8, 11, _UPB_MODE_ARRAY},
+  {31, UPB_SIZE(60, 104), 10, 15, 11, _UPB_MODE_SCALAR},
+  {32, UPB_SIZE(64, 112), 11, 11, 11, _UPB_MODE_SCALAR},
+  {33, UPB_SIZE(68, 120), 12, 12, 11, _UPB_MODE_SCALAR},
+  {34, UPB_SIZE(72, 128), 13, 3, 11, _UPB_MODE_SCALAR},
+  {35, UPB_SIZE(108, 200), UPB_SIZE(-117, -217), 11, 11, _UPB_MODE_SCALAR},
+  {36, UPB_SIZE(76, 136), 14, 7, 11, _UPB_MODE_SCALAR},
+  {37, UPB_SIZE(96, 176), UPB_SIZE(-105, -193), 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_route_v3_RouteAction_msginit = {
   &envoy_config_route_v3_RouteAction_submsgs[0],
   &envoy_config_route_v3_RouteAction__fields[0],
-  UPB_SIZE(120, 224), 30, false, 255,
+  UPB_SIZE(120, 224), 30, false, 9, 255,
 };
 
 static const upb_msglayout *const envoy_config_route_v3_RouteAction_RequestMirrorPolicy_submsgs[2] = {
@@ -354,15 +358,15 @@ static const upb_msglayout *const envoy_config_route_v3_RouteAction_RequestMirro
 };
 
 static const upb_msglayout_field envoy_config_route_v3_RouteAction_RequestMirrorPolicy__fields[3] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {3, UPB_SIZE(12, 24), 1, 0, 11, 1},
-  {4, UPB_SIZE(16, 32), 2, 1, 11, 1},
+  {1, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(12, 24), 1, 0, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(16, 32), 2, 1, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_route_v3_RouteAction_RequestMirrorPolicy_msginit = {
   &envoy_config_route_v3_RouteAction_RequestMirrorPolicy_submsgs[0],
   &envoy_config_route_v3_RouteAction_RequestMirrorPolicy__fields[0],
-  UPB_SIZE(24, 48), 3, false, 255,
+  UPB_SIZE(24, 48), 3, false, 1, 255,
 };
 
 static const upb_msglayout *const envoy_config_route_v3_RouteAction_HashPolicy_submsgs[5] = {
@@ -374,18 +378,18 @@ static const upb_msglayout *const envoy_config_route_v3_RouteAction_HashPolicy_s
 };
 
 static const upb_msglayout_field envoy_config_route_v3_RouteAction_HashPolicy__fields[6] = {
-  {1, UPB_SIZE(4, 8), UPB_SIZE(-9, -17), 3, 11, 1},
-  {2, UPB_SIZE(4, 8), UPB_SIZE(-9, -17), 1, 11, 1},
-  {3, UPB_SIZE(4, 8), UPB_SIZE(-9, -17), 0, 11, 1},
-  {4, UPB_SIZE(0, 0), 0, 0, 8, 1},
-  {5, UPB_SIZE(4, 8), UPB_SIZE(-9, -17), 4, 11, 1},
-  {6, UPB_SIZE(4, 8), UPB_SIZE(-9, -17), 2, 11, 1},
+  {1, UPB_SIZE(4, 8), UPB_SIZE(-9, -17), 3, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(4, 8), UPB_SIZE(-9, -17), 1, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(4, 8), UPB_SIZE(-9, -17), 0, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(0, 0), 0, 0, 8, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(4, 8), UPB_SIZE(-9, -17), 4, 11, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(4, 8), UPB_SIZE(-9, -17), 2, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_route_v3_RouteAction_HashPolicy_msginit = {
   &envoy_config_route_v3_RouteAction_HashPolicy_submsgs[0],
   &envoy_config_route_v3_RouteAction_HashPolicy__fields[0],
-  UPB_SIZE(16, 24), 6, false, 255,
+  UPB_SIZE(16, 24), 6, false, 6, 255,
 };
 
 static const upb_msglayout *const envoy_config_route_v3_RouteAction_HashPolicy_Header_submsgs[1] = {
@@ -393,14 +397,14 @@ static const upb_msglayout *const envoy_config_route_v3_RouteAction_HashPolicy_H
 };
 
 static const upb_msglayout_field envoy_config_route_v3_RouteAction_HashPolicy_Header__fields[2] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(12, 24), 1, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(12, 24), 1, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_route_v3_RouteAction_HashPolicy_Header_msginit = {
   &envoy_config_route_v3_RouteAction_HashPolicy_Header_submsgs[0],
   &envoy_config_route_v3_RouteAction_HashPolicy_Header__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_config_route_v3_RouteAction_HashPolicy_Cookie_submsgs[1] = {
@@ -408,45 +412,45 @@ static const upb_msglayout *const envoy_config_route_v3_RouteAction_HashPolicy_C
 };
 
 static const upb_msglayout_field envoy_config_route_v3_RouteAction_HashPolicy_Cookie__fields[3] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(20, 40), 1, 0, 11, 1},
-  {3, UPB_SIZE(12, 24), 0, 0, 9, 1},
+  {1, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(20, 40), 1, 0, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(12, 24), 0, 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_route_v3_RouteAction_HashPolicy_Cookie_msginit = {
   &envoy_config_route_v3_RouteAction_HashPolicy_Cookie_submsgs[0],
   &envoy_config_route_v3_RouteAction_HashPolicy_Cookie__fields[0],
-  UPB_SIZE(24, 48), 3, false, 255,
+  UPB_SIZE(24, 48), 3, false, 3, 255,
 };
 
 static const upb_msglayout_field envoy_config_route_v3_RouteAction_HashPolicy_ConnectionProperties__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 8, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 8, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_route_v3_RouteAction_HashPolicy_ConnectionProperties_msginit = {
   NULL,
   &envoy_config_route_v3_RouteAction_HashPolicy_ConnectionProperties__fields[0],
-  UPB_SIZE(8, 8), 1, false, 255,
+  UPB_SIZE(8, 8), 1, false, 1, 255,
 };
 
 static const upb_msglayout_field envoy_config_route_v3_RouteAction_HashPolicy_QueryParameter__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_route_v3_RouteAction_HashPolicy_QueryParameter_msginit = {
   NULL,
   &envoy_config_route_v3_RouteAction_HashPolicy_QueryParameter__fields[0],
-  UPB_SIZE(8, 16), 1, false, 255,
+  UPB_SIZE(8, 16), 1, false, 1, 255,
 };
 
 static const upb_msglayout_field envoy_config_route_v3_RouteAction_HashPolicy_FilterState__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_route_v3_RouteAction_HashPolicy_FilterState_msginit = {
   NULL,
   &envoy_config_route_v3_RouteAction_HashPolicy_FilterState__fields[0],
-  UPB_SIZE(8, 16), 1, false, 255,
+  UPB_SIZE(8, 16), 1, false, 1, 255,
 };
 
 static const upb_msglayout *const envoy_config_route_v3_RouteAction_UpgradeConfig_submsgs[2] = {
@@ -455,15 +459,15 @@ static const upb_msglayout *const envoy_config_route_v3_RouteAction_UpgradeConfi
 };
 
 static const upb_msglayout_field envoy_config_route_v3_RouteAction_UpgradeConfig__fields[3] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(12, 24), 1, 1, 11, 1},
-  {3, UPB_SIZE(16, 32), 2, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(12, 24), 1, 1, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(16, 32), 2, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_route_v3_RouteAction_UpgradeConfig_msginit = {
   &envoy_config_route_v3_RouteAction_UpgradeConfig_submsgs[0],
   &envoy_config_route_v3_RouteAction_UpgradeConfig__fields[0],
-  UPB_SIZE(24, 48), 3, false, 255,
+  UPB_SIZE(24, 48), 3, false, 3, 255,
 };
 
 static const upb_msglayout *const envoy_config_route_v3_RouteAction_UpgradeConfig_ConnectConfig_submsgs[1] = {
@@ -471,14 +475,14 @@ static const upb_msglayout *const envoy_config_route_v3_RouteAction_UpgradeConfi
 };
 
 static const upb_msglayout_field envoy_config_route_v3_RouteAction_UpgradeConfig_ConnectConfig__fields[2] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
-  {2, UPB_SIZE(1, 1), 0, 0, 8, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(1, 1), 0, 0, 8, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_route_v3_RouteAction_UpgradeConfig_ConnectConfig_msginit = {
   &envoy_config_route_v3_RouteAction_UpgradeConfig_ConnectConfig_submsgs[0],
   &envoy_config_route_v3_RouteAction_UpgradeConfig_ConnectConfig__fields[0],
-  UPB_SIZE(8, 16), 2, false, 255,
+  UPB_SIZE(8, 16), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_config_route_v3_RouteAction_MaxStreamDuration_submsgs[1] = {
@@ -486,15 +490,15 @@ static const upb_msglayout *const envoy_config_route_v3_RouteAction_MaxStreamDur
 };
 
 static const upb_msglayout_field envoy_config_route_v3_RouteAction_MaxStreamDuration__fields[3] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
-  {2, UPB_SIZE(8, 16), 2, 0, 11, 1},
-  {3, UPB_SIZE(12, 24), 3, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 2, 0, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(12, 24), 3, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_route_v3_RouteAction_MaxStreamDuration_msginit = {
   &envoy_config_route_v3_RouteAction_MaxStreamDuration_submsgs[0],
   &envoy_config_route_v3_RouteAction_MaxStreamDuration__fields[0],
-  UPB_SIZE(16, 32), 3, false, 255,
+  UPB_SIZE(16, 32), 3, false, 3, 255,
 };
 
 static const upb_msglayout *const envoy_config_route_v3_RetryPolicy_submsgs[7] = {
@@ -508,23 +512,23 @@ static const upb_msglayout *const envoy_config_route_v3_RetryPolicy_submsgs[7] =
 };
 
 static const upb_msglayout_field envoy_config_route_v3_RetryPolicy__fields[11] = {
-  {1, UPB_SIZE(16, 16), 0, 0, 9, 1},
-  {2, UPB_SIZE(24, 32), 1, 6, 11, 1},
-  {3, UPB_SIZE(28, 40), 2, 5, 11, 1},
-  {4, UPB_SIZE(32, 48), 3, 4, 11, 1},
-  {5, UPB_SIZE(44, 72), 0, 3, 11, 3},
-  {6, UPB_SIZE(8, 8), 0, 0, 3, 1},
-  {7, UPB_SIZE(48, 80), 0, 0, 13, _UPB_LABEL_PACKED},
-  {8, UPB_SIZE(36, 56), 4, 2, 11, 1},
-  {9, UPB_SIZE(52, 88), 0, 0, 11, 3},
-  {10, UPB_SIZE(56, 96), 0, 0, 11, 3},
-  {11, UPB_SIZE(40, 64), 5, 1, 11, 1},
+  {1, UPB_SIZE(16, 16), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(24, 32), 1, 6, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(28, 40), 2, 5, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(32, 48), 3, 4, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(44, 72), 0, 3, 11, _UPB_MODE_ARRAY},
+  {6, UPB_SIZE(8, 8), 0, 0, 3, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(48, 80), 0, 0, 13, _UPB_MODE_ARRAY | _UPB_MODE_IS_PACKED},
+  {8, UPB_SIZE(36, 56), 4, 2, 11, _UPB_MODE_SCALAR},
+  {9, UPB_SIZE(52, 88), 0, 0, 11, _UPB_MODE_ARRAY},
+  {10, UPB_SIZE(56, 96), 0, 0, 11, _UPB_MODE_ARRAY},
+  {11, UPB_SIZE(40, 64), 5, 1, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_route_v3_RetryPolicy_msginit = {
   &envoy_config_route_v3_RetryPolicy_submsgs[0],
   &envoy_config_route_v3_RetryPolicy__fields[0],
-  UPB_SIZE(64, 112), 11, false, 255,
+  UPB_SIZE(64, 112), 11, false, 11, 255,
 };
 
 static const upb_msglayout *const envoy_config_route_v3_RetryPolicy_RetryPriority_submsgs[1] = {
@@ -532,14 +536,14 @@ static const upb_msglayout *const envoy_config_route_v3_RetryPolicy_RetryPriorit
 };
 
 static const upb_msglayout_field envoy_config_route_v3_RetryPolicy_RetryPriority__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {3, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 0, 11, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_route_v3_RetryPolicy_RetryPriority_msginit = {
   &envoy_config_route_v3_RetryPolicy_RetryPriority_submsgs[0],
   &envoy_config_route_v3_RetryPolicy_RetryPriority__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 1, 255,
 };
 
 static const upb_msglayout *const envoy_config_route_v3_RetryPolicy_RetryHostPredicate_submsgs[1] = {
@@ -547,14 +551,14 @@ static const upb_msglayout *const envoy_config_route_v3_RetryPolicy_RetryHostPre
 };
 
 static const upb_msglayout_field envoy_config_route_v3_RetryPolicy_RetryHostPredicate__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {3, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 0, 11, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_route_v3_RetryPolicy_RetryHostPredicate_msginit = {
   &envoy_config_route_v3_RetryPolicy_RetryHostPredicate_submsgs[0],
   &envoy_config_route_v3_RetryPolicy_RetryHostPredicate__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 1, 255,
 };
 
 static const upb_msglayout *const envoy_config_route_v3_RetryPolicy_RetryBackOff_submsgs[1] = {
@@ -562,25 +566,25 @@ static const upb_msglayout *const envoy_config_route_v3_RetryPolicy_RetryBackOff
 };
 
 static const upb_msglayout_field envoy_config_route_v3_RetryPolicy_RetryBackOff__fields[2] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
-  {2, UPB_SIZE(8, 16), 2, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 2, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_route_v3_RetryPolicy_RetryBackOff_msginit = {
   &envoy_config_route_v3_RetryPolicy_RetryBackOff_submsgs[0],
   &envoy_config_route_v3_RetryPolicy_RetryBackOff__fields[0],
-  UPB_SIZE(16, 24), 2, false, 255,
+  UPB_SIZE(16, 24), 2, false, 2, 255,
 };
 
 static const upb_msglayout_field envoy_config_route_v3_RetryPolicy_ResetHeader__fields[2] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(0, 0), 0, 0, 14, 1},
+  {1, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(0, 0), 0, 0, 14, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_route_v3_RetryPolicy_ResetHeader_msginit = {
   NULL,
   &envoy_config_route_v3_RetryPolicy_ResetHeader__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_config_route_v3_RetryPolicy_RateLimitedRetryBackOff_submsgs[2] = {
@@ -589,14 +593,14 @@ static const upb_msglayout *const envoy_config_route_v3_RetryPolicy_RateLimitedR
 };
 
 static const upb_msglayout_field envoy_config_route_v3_RetryPolicy_RateLimitedRetryBackOff__fields[2] = {
-  {1, UPB_SIZE(8, 16), 0, 0, 11, 3},
-  {2, UPB_SIZE(4, 8), 1, 1, 11, 1},
+  {1, UPB_SIZE(8, 16), 0, 0, 11, _UPB_MODE_ARRAY},
+  {2, UPB_SIZE(4, 8), 1, 1, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_route_v3_RetryPolicy_RateLimitedRetryBackOff_msginit = {
   &envoy_config_route_v3_RetryPolicy_RateLimitedRetryBackOff_submsgs[0],
   &envoy_config_route_v3_RetryPolicy_RateLimitedRetryBackOff__fields[0],
-  UPB_SIZE(16, 24), 2, false, 255,
+  UPB_SIZE(16, 24), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_config_route_v3_HedgePolicy_submsgs[2] = {
@@ -605,15 +609,15 @@ static const upb_msglayout *const envoy_config_route_v3_HedgePolicy_submsgs[2] =
 };
 
 static const upb_msglayout_field envoy_config_route_v3_HedgePolicy__fields[3] = {
-  {1, UPB_SIZE(4, 8), 1, 1, 11, 1},
-  {2, UPB_SIZE(8, 16), 2, 0, 11, 1},
-  {3, UPB_SIZE(1, 1), 0, 0, 8, 1},
+  {1, UPB_SIZE(4, 8), 1, 1, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 2, 0, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(1, 1), 0, 0, 8, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_route_v3_HedgePolicy_msginit = {
   &envoy_config_route_v3_HedgePolicy_submsgs[0],
   &envoy_config_route_v3_HedgePolicy__fields[0],
-  UPB_SIZE(16, 24), 3, false, 255,
+  UPB_SIZE(16, 24), 3, false, 3, 255,
 };
 
 static const upb_msglayout *const envoy_config_route_v3_RedirectAction_submsgs[1] = {
@@ -621,21 +625,21 @@ static const upb_msglayout *const envoy_config_route_v3_RedirectAction_submsgs[1
 };
 
 static const upb_msglayout_field envoy_config_route_v3_RedirectAction__fields[9] = {
-  {1, UPB_SIZE(12, 16), 0, 0, 9, 1},
-  {2, UPB_SIZE(20, 32), UPB_SIZE(-29, -49), 0, 9, 1},
-  {3, UPB_SIZE(0, 0), 0, 0, 14, 1},
-  {4, UPB_SIZE(32, 56), UPB_SIZE(-41, -73), 0, 8, 1},
-  {5, UPB_SIZE(20, 32), UPB_SIZE(-29, -49), 0, 9, 1},
-  {6, UPB_SIZE(8, 8), 0, 0, 8, 1},
-  {7, UPB_SIZE(32, 56), UPB_SIZE(-41, -73), 0, 9, 1},
-  {8, UPB_SIZE(4, 4), 0, 0, 13, 1},
-  {9, UPB_SIZE(20, 32), UPB_SIZE(-29, -49), 0, 11, 1},
+  {1, UPB_SIZE(12, 16), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(20, 32), UPB_SIZE(-29, -49), 0, 9, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(0, 0), 0, 0, 14, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(32, 56), UPB_SIZE(-41, -73), 0, 8, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(20, 32), UPB_SIZE(-29, -49), 0, 9, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(8, 8), 0, 0, 8, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(32, 56), UPB_SIZE(-41, -73), 0, 9, _UPB_MODE_SCALAR},
+  {8, UPB_SIZE(4, 4), 0, 0, 13, _UPB_MODE_SCALAR},
+  {9, UPB_SIZE(20, 32), UPB_SIZE(-29, -49), 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_route_v3_RedirectAction_msginit = {
   &envoy_config_route_v3_RedirectAction_submsgs[0],
   &envoy_config_route_v3_RedirectAction__fields[0],
-  UPB_SIZE(48, 80), 9, false, 255,
+  UPB_SIZE(48, 80), 9, false, 9, 255,
 };
 
 static const upb_msglayout *const envoy_config_route_v3_DirectResponseAction_submsgs[1] = {
@@ -643,20 +647,20 @@ static const upb_msglayout *const envoy_config_route_v3_DirectResponseAction_sub
 };
 
 static const upb_msglayout_field envoy_config_route_v3_DirectResponseAction__fields[2] = {
-  {1, UPB_SIZE(4, 4), 0, 0, 13, 1},
-  {2, UPB_SIZE(8, 8), 1, 0, 11, 1},
+  {1, UPB_SIZE(4, 4), 0, 0, 13, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 8), 1, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_route_v3_DirectResponseAction_msginit = {
   &envoy_config_route_v3_DirectResponseAction_submsgs[0],
   &envoy_config_route_v3_DirectResponseAction__fields[0],
-  UPB_SIZE(16, 16), 2, false, 255,
+  UPB_SIZE(16, 16), 2, false, 2, 255,
 };
 
 const upb_msglayout envoy_config_route_v3_NonForwardingAction_msginit = {
   NULL,
   NULL,
-  UPB_SIZE(0, 0), 0, false, 255,
+  UPB_SIZE(0, 0), 0, false, 0, 255,
 };
 
 static const upb_msglayout *const envoy_config_route_v3_Decorator_submsgs[1] = {
@@ -664,14 +668,14 @@ static const upb_msglayout *const envoy_config_route_v3_Decorator_submsgs[1] = {
 };
 
 static const upb_msglayout_field envoy_config_route_v3_Decorator__fields[2] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(12, 24), 1, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(12, 24), 1, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_route_v3_Decorator_msginit = {
   &envoy_config_route_v3_Decorator_submsgs[0],
   &envoy_config_route_v3_Decorator__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_config_route_v3_Tracing_submsgs[2] = {
@@ -680,16 +684,16 @@ static const upb_msglayout *const envoy_config_route_v3_Tracing_submsgs[2] = {
 };
 
 static const upb_msglayout_field envoy_config_route_v3_Tracing__fields[4] = {
-  {1, UPB_SIZE(4, 8), 1, 1, 11, 1},
-  {2, UPB_SIZE(8, 16), 2, 1, 11, 1},
-  {3, UPB_SIZE(12, 24), 3, 1, 11, 1},
-  {4, UPB_SIZE(16, 32), 0, 0, 11, 3},
+  {1, UPB_SIZE(4, 8), 1, 1, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 2, 1, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(12, 24), 3, 1, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(16, 32), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout envoy_config_route_v3_Tracing_msginit = {
   &envoy_config_route_v3_Tracing_submsgs[0],
   &envoy_config_route_v3_Tracing__fields[0],
-  UPB_SIZE(24, 40), 4, false, 255,
+  UPB_SIZE(24, 40), 4, false, 4, 255,
 };
 
 static const upb_msglayout *const envoy_config_route_v3_VirtualCluster_submsgs[1] = {
@@ -697,14 +701,14 @@ static const upb_msglayout *const envoy_config_route_v3_VirtualCluster_submsgs[1
 };
 
 static const upb_msglayout_field envoy_config_route_v3_VirtualCluster__fields[2] = {
-  {2, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {4, UPB_SIZE(8, 16), 0, 0, 11, 3},
+  {2, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(8, 16), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout envoy_config_route_v3_VirtualCluster_msginit = {
   &envoy_config_route_v3_VirtualCluster_submsgs[0],
   &envoy_config_route_v3_VirtualCluster__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 0, 255,
 };
 
 static const upb_msglayout *const envoy_config_route_v3_RateLimit_submsgs[3] = {
@@ -714,16 +718,16 @@ static const upb_msglayout *const envoy_config_route_v3_RateLimit_submsgs[3] = {
 };
 
 static const upb_msglayout_field envoy_config_route_v3_RateLimit__fields[4] = {
-  {1, UPB_SIZE(12, 24), 1, 2, 11, 1},
-  {2, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {3, UPB_SIZE(20, 40), 0, 0, 11, 3},
-  {4, UPB_SIZE(16, 32), 2, 1, 11, 1},
+  {1, UPB_SIZE(12, 24), 1, 2, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(20, 40), 0, 0, 11, _UPB_MODE_ARRAY},
+  {4, UPB_SIZE(16, 32), 2, 1, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_route_v3_RateLimit_msginit = {
   &envoy_config_route_v3_RateLimit_submsgs[0],
   &envoy_config_route_v3_RateLimit__fields[0],
-  UPB_SIZE(24, 48), 4, false, 255,
+  UPB_SIZE(24, 48), 4, false, 4, 255,
 };
 
 static const upb_msglayout *const envoy_config_route_v3_RateLimit_Action_submsgs[9] = {
@@ -739,62 +743,62 @@ static const upb_msglayout *const envoy_config_route_v3_RateLimit_Action_submsgs
 };
 
 static const upb_msglayout_field envoy_config_route_v3_RateLimit_Action__fields[9] = {
-  {1, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 8, 11, 1},
-  {2, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 1, 11, 1},
-  {3, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 7, 11, 1},
-  {4, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 6, 11, 1},
-  {5, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 3, 11, 1},
-  {6, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 4, 11, 1},
-  {7, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 2, 11, 1},
-  {8, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 5, 11, 1},
-  {9, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 11, 1},
+  {1, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 8, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 1, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 7, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 6, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 3, 11, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 4, 11, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 2, 11, _UPB_MODE_SCALAR},
+  {8, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 5, 11, _UPB_MODE_SCALAR},
+  {9, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_route_v3_RateLimit_Action_msginit = {
   &envoy_config_route_v3_RateLimit_Action_submsgs[0],
   &envoy_config_route_v3_RateLimit_Action__fields[0],
-  UPB_SIZE(8, 16), 9, false, 255,
+  UPB_SIZE(8, 16), 9, false, 9, 255,
 };
 
 const upb_msglayout envoy_config_route_v3_RateLimit_Action_SourceCluster_msginit = {
   NULL,
   NULL,
-  UPB_SIZE(0, 0), 0, false, 255,
+  UPB_SIZE(0, 0), 0, false, 0, 255,
 };
 
 const upb_msglayout envoy_config_route_v3_RateLimit_Action_DestinationCluster_msginit = {
   NULL,
   NULL,
-  UPB_SIZE(0, 0), 0, false, 255,
+  UPB_SIZE(0, 0), 0, false, 0, 255,
 };
 
 static const upb_msglayout_field envoy_config_route_v3_RateLimit_Action_RequestHeaders__fields[3] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(12, 24), 0, 0, 9, 1},
-  {3, UPB_SIZE(0, 0), 0, 0, 8, 1},
+  {1, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(12, 24), 0, 0, 9, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(0, 0), 0, 0, 8, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_route_v3_RateLimit_Action_RequestHeaders_msginit = {
   NULL,
   &envoy_config_route_v3_RateLimit_Action_RequestHeaders__fields[0],
-  UPB_SIZE(24, 48), 3, false, 255,
+  UPB_SIZE(24, 48), 3, false, 3, 255,
 };
 
 const upb_msglayout envoy_config_route_v3_RateLimit_Action_RemoteAddress_msginit = {
   NULL,
   NULL,
-  UPB_SIZE(0, 0), 0, false, 255,
+  UPB_SIZE(0, 0), 0, false, 0, 255,
 };
 
 static const upb_msglayout_field envoy_config_route_v3_RateLimit_Action_GenericKey__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {2, UPB_SIZE(8, 16), 0, 0, 9, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 0, 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_route_v3_RateLimit_Action_GenericKey_msginit = {
   NULL,
   &envoy_config_route_v3_RateLimit_Action_GenericKey__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_config_route_v3_RateLimit_Action_HeaderValueMatch_submsgs[2] = {
@@ -803,15 +807,15 @@ static const upb_msglayout *const envoy_config_route_v3_RateLimit_Action_HeaderV
 };
 
 static const upb_msglayout_field envoy_config_route_v3_RateLimit_Action_HeaderValueMatch__fields[3] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(12, 24), 1, 1, 11, 1},
-  {3, UPB_SIZE(16, 32), 0, 0, 11, 3},
+  {1, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(12, 24), 1, 1, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(16, 32), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout envoy_config_route_v3_RateLimit_Action_HeaderValueMatch_msginit = {
   &envoy_config_route_v3_RateLimit_Action_HeaderValueMatch_submsgs[0],
   &envoy_config_route_v3_RateLimit_Action_HeaderValueMatch__fields[0],
-  UPB_SIZE(24, 48), 3, false, 255,
+  UPB_SIZE(24, 48), 3, false, 3, 255,
 };
 
 static const upb_msglayout *const envoy_config_route_v3_RateLimit_Action_DynamicMetaData_submsgs[1] = {
@@ -819,15 +823,15 @@ static const upb_msglayout *const envoy_config_route_v3_RateLimit_Action_Dynamic
 };
 
 static const upb_msglayout_field envoy_config_route_v3_RateLimit_Action_DynamicMetaData__fields[3] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(20, 40), 1, 0, 11, 1},
-  {3, UPB_SIZE(12, 24), 0, 0, 9, 1},
+  {1, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(20, 40), 1, 0, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(12, 24), 0, 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_route_v3_RateLimit_Action_DynamicMetaData_msginit = {
   &envoy_config_route_v3_RateLimit_Action_DynamicMetaData_submsgs[0],
   &envoy_config_route_v3_RateLimit_Action_DynamicMetaData__fields[0],
-  UPB_SIZE(24, 48), 3, false, 255,
+  UPB_SIZE(24, 48), 3, false, 3, 255,
 };
 
 static const upb_msglayout *const envoy_config_route_v3_RateLimit_Action_MetaData_submsgs[1] = {
@@ -835,16 +839,16 @@ static const upb_msglayout *const envoy_config_route_v3_RateLimit_Action_MetaDat
 };
 
 static const upb_msglayout_field envoy_config_route_v3_RateLimit_Action_MetaData__fields[4] = {
-  {1, UPB_SIZE(8, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(24, 40), 1, 0, 11, 1},
-  {3, UPB_SIZE(16, 24), 0, 0, 9, 1},
-  {4, UPB_SIZE(4, 4), 0, 0, 14, 1},
+  {1, UPB_SIZE(8, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(24, 40), 1, 0, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(16, 24), 0, 0, 9, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(4, 4), 0, 0, 14, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_route_v3_RateLimit_Action_MetaData_msginit = {
   &envoy_config_route_v3_RateLimit_Action_MetaData_submsgs[0],
   &envoy_config_route_v3_RateLimit_Action_MetaData__fields[0],
-  UPB_SIZE(32, 48), 4, false, 255,
+  UPB_SIZE(32, 48), 4, false, 4, 255,
 };
 
 static const upb_msglayout *const envoy_config_route_v3_RateLimit_Override_submsgs[1] = {
@@ -852,13 +856,13 @@ static const upb_msglayout *const envoy_config_route_v3_RateLimit_Override_subms
 };
 
 static const upb_msglayout_field envoy_config_route_v3_RateLimit_Override__fields[1] = {
-  {1, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 11, 1},
+  {1, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_route_v3_RateLimit_Override_msginit = {
   &envoy_config_route_v3_RateLimit_Override_submsgs[0],
   &envoy_config_route_v3_RateLimit_Override__fields[0],
-  UPB_SIZE(8, 16), 1, false, 255,
+  UPB_SIZE(8, 16), 1, false, 1, 255,
 };
 
 static const upb_msglayout *const envoy_config_route_v3_RateLimit_Override_DynamicMetadata_submsgs[1] = {
@@ -866,13 +870,13 @@ static const upb_msglayout *const envoy_config_route_v3_RateLimit_Override_Dynam
 };
 
 static const upb_msglayout_field envoy_config_route_v3_RateLimit_Override_DynamicMetadata__fields[1] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_route_v3_RateLimit_Override_DynamicMetadata_msginit = {
   &envoy_config_route_v3_RateLimit_Override_DynamicMetadata_submsgs[0],
   &envoy_config_route_v3_RateLimit_Override_DynamicMetadata__fields[0],
-  UPB_SIZE(8, 16), 1, false, 255,
+  UPB_SIZE(8, 16), 1, false, 1, 255,
 };
 
 static const upb_msglayout *const envoy_config_route_v3_HeaderMatcher_submsgs[3] = {
@@ -882,22 +886,22 @@ static const upb_msglayout *const envoy_config_route_v3_HeaderMatcher_submsgs[3]
 };
 
 static const upb_msglayout_field envoy_config_route_v3_HeaderMatcher__fields[10] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {4, UPB_SIZE(12, 24), UPB_SIZE(-21, -41), 0, 9, 1},
-  {6, UPB_SIZE(12, 24), UPB_SIZE(-21, -41), 2, 11, 1},
-  {7, UPB_SIZE(12, 24), UPB_SIZE(-21, -41), 0, 8, 1},
-  {8, UPB_SIZE(0, 0), 0, 0, 8, 1},
-  {9, UPB_SIZE(12, 24), UPB_SIZE(-21, -41), 0, 9, 1},
-  {10, UPB_SIZE(12, 24), UPB_SIZE(-21, -41), 0, 9, 1},
-  {11, UPB_SIZE(12, 24), UPB_SIZE(-21, -41), 0, 11, 1},
-  {12, UPB_SIZE(12, 24), UPB_SIZE(-21, -41), 0, 9, 1},
-  {13, UPB_SIZE(12, 24), UPB_SIZE(-21, -41), 1, 11, 1},
+  {1, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(12, 24), UPB_SIZE(-21, -41), 0, 9, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(12, 24), UPB_SIZE(-21, -41), 2, 11, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(12, 24), UPB_SIZE(-21, -41), 0, 8, _UPB_MODE_SCALAR},
+  {8, UPB_SIZE(0, 0), 0, 0, 8, _UPB_MODE_SCALAR},
+  {9, UPB_SIZE(12, 24), UPB_SIZE(-21, -41), 0, 9, _UPB_MODE_SCALAR},
+  {10, UPB_SIZE(12, 24), UPB_SIZE(-21, -41), 0, 9, _UPB_MODE_SCALAR},
+  {11, UPB_SIZE(12, 24), UPB_SIZE(-21, -41), 0, 11, _UPB_MODE_SCALAR},
+  {12, UPB_SIZE(12, 24), UPB_SIZE(-21, -41), 0, 9, _UPB_MODE_SCALAR},
+  {13, UPB_SIZE(12, 24), UPB_SIZE(-21, -41), 1, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_route_v3_HeaderMatcher_msginit = {
   &envoy_config_route_v3_HeaderMatcher_submsgs[0],
   &envoy_config_route_v3_HeaderMatcher__fields[0],
-  UPB_SIZE(24, 48), 10, false, 255,
+  UPB_SIZE(24, 48), 10, false, 1, 255,
 };
 
 static const upb_msglayout *const envoy_config_route_v3_QueryParameterMatcher_submsgs[1] = {
@@ -905,15 +909,15 @@ static const upb_msglayout *const envoy_config_route_v3_QueryParameterMatcher_su
 };
 
 static const upb_msglayout_field envoy_config_route_v3_QueryParameterMatcher__fields[3] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {5, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 0, 11, 1},
-  {6, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 0, 8, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 0, 11, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 0, 8, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_route_v3_QueryParameterMatcher_msginit = {
   &envoy_config_route_v3_QueryParameterMatcher_submsgs[0],
   &envoy_config_route_v3_QueryParameterMatcher__fields[0],
-  UPB_SIZE(16, 32), 3, false, 255,
+  UPB_SIZE(16, 32), 3, false, 1, 255,
 };
 
 static const upb_msglayout *const envoy_config_route_v3_InternalRedirectPolicy_submsgs[2] = {
@@ -922,16 +926,16 @@ static const upb_msglayout *const envoy_config_route_v3_InternalRedirectPolicy_s
 };
 
 static const upb_msglayout_field envoy_config_route_v3_InternalRedirectPolicy__fields[4] = {
-  {1, UPB_SIZE(4, 8), 1, 1, 11, 1},
-  {2, UPB_SIZE(8, 16), 0, 0, 13, _UPB_LABEL_PACKED},
-  {3, UPB_SIZE(12, 24), 0, 0, 11, 3},
-  {4, UPB_SIZE(1, 1), 0, 0, 8, 1},
+  {1, UPB_SIZE(4, 8), 1, 1, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 0, 0, 13, _UPB_MODE_ARRAY | _UPB_MODE_IS_PACKED},
+  {3, UPB_SIZE(12, 24), 0, 0, 11, _UPB_MODE_ARRAY},
+  {4, UPB_SIZE(1, 1), 0, 0, 8, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_route_v3_InternalRedirectPolicy_msginit = {
   &envoy_config_route_v3_InternalRedirectPolicy_submsgs[0],
   &envoy_config_route_v3_InternalRedirectPolicy__fields[0],
-  UPB_SIZE(16, 32), 4, false, 255,
+  UPB_SIZE(16, 32), 4, false, 4, 255,
 };
 
 static const upb_msglayout *const envoy_config_route_v3_FilterConfig_submsgs[1] = {
@@ -939,14 +943,14 @@ static const upb_msglayout *const envoy_config_route_v3_FilterConfig_submsgs[1]
 };
 
 static const upb_msglayout_field envoy_config_route_v3_FilterConfig__fields[2] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
-  {2, UPB_SIZE(1, 1), 0, 0, 8, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(1, 1), 0, 0, 8, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_route_v3_FilterConfig_msginit = {
   &envoy_config_route_v3_FilterConfig_submsgs[0],
   &envoy_config_route_v3_FilterConfig__fields[0],
-  UPB_SIZE(8, 16), 2, false, 255,
+  UPB_SIZE(8, 16), 2, false, 2, 255,
 };
 
 #include "upb/port_undef.inc"
index f01e359..095088e 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_CONFIG_ROUTE_V3_ROUTE_COMPONENTS_PROTO_UPB_H_
 #define ENVOY_CONFIG_ROUTE_V3_ROUTE_COMPONENTS_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -185,6 +185,7 @@ struct envoy_config_core_v3_Metadata;
 struct envoy_config_core_v3_ProxyProtocolConfig;
 struct envoy_config_core_v3_RuntimeFractionalPercent;
 struct envoy_config_core_v3_TypedExtensionConfig;
+struct envoy_type_matcher_v3_MetadataMatcher;
 struct envoy_type_matcher_v3_RegexMatchAndSubstitute;
 struct envoy_type_matcher_v3_RegexMatcher;
 struct envoy_type_matcher_v3_StringMatcher;
@@ -202,6 +203,7 @@ extern const upb_msglayout envoy_config_core_v3_Metadata_msginit;
 extern const upb_msglayout envoy_config_core_v3_ProxyProtocolConfig_msginit;
 extern const upb_msglayout envoy_config_core_v3_RuntimeFractionalPercent_msginit;
 extern const upb_msglayout envoy_config_core_v3_TypedExtensionConfig_msginit;
+extern const upb_msglayout envoy_type_matcher_v3_MetadataMatcher_msginit;
 extern const upb_msglayout envoy_type_matcher_v3_RegexMatchAndSubstitute_msginit;
 extern const upb_msglayout envoy_type_matcher_v3_RegexMatcher_msginit;
 extern const upb_msglayout envoy_type_matcher_v3_StringMatcher_msginit;
@@ -257,13 +259,19 @@ UPB_INLINE envoy_config_route_v3_VirtualHost *envoy_config_route_v3_VirtualHost_
 UPB_INLINE envoy_config_route_v3_VirtualHost *envoy_config_route_v3_VirtualHost_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_route_v3_VirtualHost *ret = envoy_config_route_v3_VirtualHost_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_route_v3_VirtualHost_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_route_v3_VirtualHost_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_route_v3_VirtualHost *envoy_config_route_v3_VirtualHost_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_route_v3_VirtualHost *ret = envoy_config_route_v3_VirtualHost_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_route_v3_VirtualHost_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_route_v3_VirtualHost_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_route_v3_VirtualHost_serialize(const envoy_config_route_v3_VirtualHost *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_route_v3_VirtualHost_msginit, arena, len);
@@ -504,13 +512,19 @@ UPB_INLINE envoy_config_route_v3_FilterAction *envoy_config_route_v3_FilterActio
 UPB_INLINE envoy_config_route_v3_FilterAction *envoy_config_route_v3_FilterAction_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_route_v3_FilterAction *ret = envoy_config_route_v3_FilterAction_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_route_v3_FilterAction_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_route_v3_FilterAction_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_route_v3_FilterAction *envoy_config_route_v3_FilterAction_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_route_v3_FilterAction *ret = envoy_config_route_v3_FilterAction_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_route_v3_FilterAction_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_route_v3_FilterAction_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_route_v3_FilterAction_serialize(const envoy_config_route_v3_FilterAction *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_route_v3_FilterAction_msginit, arena, len);
@@ -541,13 +555,19 @@ UPB_INLINE envoy_config_route_v3_Route *envoy_config_route_v3_Route_new(upb_aren
 UPB_INLINE envoy_config_route_v3_Route *envoy_config_route_v3_Route_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_route_v3_Route *ret = envoy_config_route_v3_Route_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_route_v3_Route_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_route_v3_Route_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_route_v3_Route *envoy_config_route_v3_Route_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_route_v3_Route *ret = envoy_config_route_v3_Route_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_route_v3_Route_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_route_v3_Route_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_route_v3_Route_serialize(const envoy_config_route_v3_Route *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_route_v3_Route_msginit, arena, len);
@@ -800,13 +820,19 @@ UPB_INLINE envoy_config_route_v3_WeightedCluster *envoy_config_route_v3_Weighted
 UPB_INLINE envoy_config_route_v3_WeightedCluster *envoy_config_route_v3_WeightedCluster_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_route_v3_WeightedCluster *ret = envoy_config_route_v3_WeightedCluster_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_route_v3_WeightedCluster_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_route_v3_WeightedCluster_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_route_v3_WeightedCluster *envoy_config_route_v3_WeightedCluster_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_route_v3_WeightedCluster *ret = envoy_config_route_v3_WeightedCluster_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_route_v3_WeightedCluster_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_route_v3_WeightedCluster_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_route_v3_WeightedCluster_serialize(const envoy_config_route_v3_WeightedCluster *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_route_v3_WeightedCluster_msginit, arena, len);
@@ -856,13 +882,19 @@ UPB_INLINE envoy_config_route_v3_WeightedCluster_ClusterWeight *envoy_config_rou
 UPB_INLINE envoy_config_route_v3_WeightedCluster_ClusterWeight *envoy_config_route_v3_WeightedCluster_ClusterWeight_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_route_v3_WeightedCluster_ClusterWeight *ret = envoy_config_route_v3_WeightedCluster_ClusterWeight_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_route_v3_WeightedCluster_ClusterWeight_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_route_v3_WeightedCluster_ClusterWeight_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_route_v3_WeightedCluster_ClusterWeight *envoy_config_route_v3_WeightedCluster_ClusterWeight_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_route_v3_WeightedCluster_ClusterWeight *ret = envoy_config_route_v3_WeightedCluster_ClusterWeight_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_route_v3_WeightedCluster_ClusterWeight_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_route_v3_WeightedCluster_ClusterWeight_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_route_v3_WeightedCluster_ClusterWeight_serialize(const envoy_config_route_v3_WeightedCluster_ClusterWeight *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_route_v3_WeightedCluster_ClusterWeight_msginit, arena, len);
@@ -872,32 +904,33 @@ typedef enum {
   envoy_config_route_v3_WeightedCluster_ClusterWeight_host_rewrite_specifier_host_rewrite_literal = 11,
   envoy_config_route_v3_WeightedCluster_ClusterWeight_host_rewrite_specifier_NOT_SET = 0
 } envoy_config_route_v3_WeightedCluster_ClusterWeight_host_rewrite_specifier_oneofcases;
-UPB_INLINE envoy_config_route_v3_WeightedCluster_ClusterWeight_host_rewrite_specifier_oneofcases envoy_config_route_v3_WeightedCluster_ClusterWeight_host_rewrite_specifier_case(const envoy_config_route_v3_WeightedCluster_ClusterWeight* msg) { return (envoy_config_route_v3_WeightedCluster_ClusterWeight_host_rewrite_specifier_oneofcases)*UPB_PTR_AT(msg, UPB_SIZE(48, 96), int32_t); }
+UPB_INLINE envoy_config_route_v3_WeightedCluster_ClusterWeight_host_rewrite_specifier_oneofcases envoy_config_route_v3_WeightedCluster_ClusterWeight_host_rewrite_specifier_case(const envoy_config_route_v3_WeightedCluster_ClusterWeight* msg) { return (envoy_config_route_v3_WeightedCluster_ClusterWeight_host_rewrite_specifier_oneofcases)*UPB_PTR_AT(msg, UPB_SIZE(56, 112), int32_t); }
 
 UPB_INLINE upb_strview envoy_config_route_v3_WeightedCluster_ClusterWeight_name(const envoy_config_route_v3_WeightedCluster_ClusterWeight *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(4, 8), upb_strview); }
 UPB_INLINE bool envoy_config_route_v3_WeightedCluster_ClusterWeight_has_weight(const envoy_config_route_v3_WeightedCluster_ClusterWeight *msg) { return _upb_hasbit(msg, 1); }
-UPB_INLINE const struct google_protobuf_UInt32Value* envoy_config_route_v3_WeightedCluster_ClusterWeight_weight(const envoy_config_route_v3_WeightedCluster_ClusterWeight *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(12, 24), const struct google_protobuf_UInt32Value*); }
+UPB_INLINE const struct google_protobuf_UInt32Value* envoy_config_route_v3_WeightedCluster_ClusterWeight_weight(const envoy_config_route_v3_WeightedCluster_ClusterWeight *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(20, 40), const struct google_protobuf_UInt32Value*); }
 UPB_INLINE bool envoy_config_route_v3_WeightedCluster_ClusterWeight_has_metadata_match(const envoy_config_route_v3_WeightedCluster_ClusterWeight *msg) { return _upb_hasbit(msg, 2); }
-UPB_INLINE const struct envoy_config_core_v3_Metadata* envoy_config_route_v3_WeightedCluster_ClusterWeight_metadata_match(const envoy_config_route_v3_WeightedCluster_ClusterWeight *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(16, 32), const struct envoy_config_core_v3_Metadata*); }
-UPB_INLINE bool envoy_config_route_v3_WeightedCluster_ClusterWeight_has_request_headers_to_add(const envoy_config_route_v3_WeightedCluster_ClusterWeight *msg) { return _upb_has_submsg_nohasbit(msg, UPB_SIZE(20, 40)); }
-UPB_INLINE const struct envoy_config_core_v3_HeaderValueOption* const* envoy_config_route_v3_WeightedCluster_ClusterWeight_request_headers_to_add(const envoy_config_route_v3_WeightedCluster_ClusterWeight *msg, size_t *len) { return (const struct envoy_config_core_v3_HeaderValueOption* const*)_upb_array_accessor(msg, UPB_SIZE(20, 40), len); }
-UPB_INLINE bool envoy_config_route_v3_WeightedCluster_ClusterWeight_has_response_headers_to_add(const envoy_config_route_v3_WeightedCluster_ClusterWeight *msg) { return _upb_has_submsg_nohasbit(msg, UPB_SIZE(24, 48)); }
-UPB_INLINE const struct envoy_config_core_v3_HeaderValueOption* const* envoy_config_route_v3_WeightedCluster_ClusterWeight_response_headers_to_add(const envoy_config_route_v3_WeightedCluster_ClusterWeight *msg, size_t *len) { return (const struct envoy_config_core_v3_HeaderValueOption* const*)_upb_array_accessor(msg, UPB_SIZE(24, 48), len); }
-UPB_INLINE upb_strview const* envoy_config_route_v3_WeightedCluster_ClusterWeight_response_headers_to_remove(const envoy_config_route_v3_WeightedCluster_ClusterWeight *msg, size_t *len) { return (upb_strview const*)_upb_array_accessor(msg, UPB_SIZE(28, 56), len); }
-UPB_INLINE upb_strview const* envoy_config_route_v3_WeightedCluster_ClusterWeight_request_headers_to_remove(const envoy_config_route_v3_WeightedCluster_ClusterWeight *msg, size_t *len) { return (upb_strview const*)_upb_array_accessor(msg, UPB_SIZE(32, 64), len); }
-UPB_INLINE bool envoy_config_route_v3_WeightedCluster_ClusterWeight_has_typed_per_filter_config(const envoy_config_route_v3_WeightedCluster_ClusterWeight *msg) { return _upb_has_submsg_nohasbit(msg, UPB_SIZE(36, 72)); }
-UPB_INLINE size_t envoy_config_route_v3_WeightedCluster_ClusterWeight_typed_per_filter_config_size(const envoy_config_route_v3_WeightedCluster_ClusterWeight *msg) {return _upb_msg_map_size(msg, UPB_SIZE(36, 72)); }
-UPB_INLINE bool envoy_config_route_v3_WeightedCluster_ClusterWeight_typed_per_filter_config_get(const envoy_config_route_v3_WeightedCluster_ClusterWeight *msg, upb_strview key, struct google_protobuf_Any* *val) { return _upb_msg_map_get(msg, UPB_SIZE(36, 72), &key, 0, val, sizeof(*val)); }
-UPB_INLINE const envoy_config_route_v3_WeightedCluster_ClusterWeight_TypedPerFilterConfigEntry* envoy_config_route_v3_WeightedCluster_ClusterWeight_typed_per_filter_config_next(const envoy_config_route_v3_WeightedCluster_ClusterWeight *msg, size_t* iter) { return (const envoy_config_route_v3_WeightedCluster_ClusterWeight_TypedPerFilterConfigEntry*)_upb_msg_map_next(msg, UPB_SIZE(36, 72), iter); }
-UPB_INLINE bool envoy_config_route_v3_WeightedCluster_ClusterWeight_has_host_rewrite_literal(const envoy_config_route_v3_WeightedCluster_ClusterWeight *msg) { return _upb_getoneofcase(msg, UPB_SIZE(48, 96)) == 11; }
-UPB_INLINE upb_strview envoy_config_route_v3_WeightedCluster_ClusterWeight_host_rewrite_literal(const envoy_config_route_v3_WeightedCluster_ClusterWeight *msg) { return UPB_READ_ONEOF(msg, upb_strview, UPB_SIZE(40, 80), UPB_SIZE(48, 96), 11, upb_strview_make("", strlen(""))); }
+UPB_INLINE const struct envoy_config_core_v3_Metadata* envoy_config_route_v3_WeightedCluster_ClusterWeight_metadata_match(const envoy_config_route_v3_WeightedCluster_ClusterWeight *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(24, 48), const struct envoy_config_core_v3_Metadata*); }
+UPB_INLINE bool envoy_config_route_v3_WeightedCluster_ClusterWeight_has_request_headers_to_add(const envoy_config_route_v3_WeightedCluster_ClusterWeight *msg) { return _upb_has_submsg_nohasbit(msg, UPB_SIZE(28, 56)); }
+UPB_INLINE const struct envoy_config_core_v3_HeaderValueOption* const* envoy_config_route_v3_WeightedCluster_ClusterWeight_request_headers_to_add(const envoy_config_route_v3_WeightedCluster_ClusterWeight *msg, size_t *len) { return (const struct envoy_config_core_v3_HeaderValueOption* const*)_upb_array_accessor(msg, UPB_SIZE(28, 56), len); }
+UPB_INLINE bool envoy_config_route_v3_WeightedCluster_ClusterWeight_has_response_headers_to_add(const envoy_config_route_v3_WeightedCluster_ClusterWeight *msg) { return _upb_has_submsg_nohasbit(msg, UPB_SIZE(32, 64)); }
+UPB_INLINE const struct envoy_config_core_v3_HeaderValueOption* const* envoy_config_route_v3_WeightedCluster_ClusterWeight_response_headers_to_add(const envoy_config_route_v3_WeightedCluster_ClusterWeight *msg, size_t *len) { return (const struct envoy_config_core_v3_HeaderValueOption* const*)_upb_array_accessor(msg, UPB_SIZE(32, 64), len); }
+UPB_INLINE upb_strview const* envoy_config_route_v3_WeightedCluster_ClusterWeight_response_headers_to_remove(const envoy_config_route_v3_WeightedCluster_ClusterWeight *msg, size_t *len) { return (upb_strview const*)_upb_array_accessor(msg, UPB_SIZE(36, 72), len); }
+UPB_INLINE upb_strview const* envoy_config_route_v3_WeightedCluster_ClusterWeight_request_headers_to_remove(const envoy_config_route_v3_WeightedCluster_ClusterWeight *msg, size_t *len) { return (upb_strview const*)_upb_array_accessor(msg, UPB_SIZE(40, 80), len); }
+UPB_INLINE bool envoy_config_route_v3_WeightedCluster_ClusterWeight_has_typed_per_filter_config(const envoy_config_route_v3_WeightedCluster_ClusterWeight *msg) { return _upb_has_submsg_nohasbit(msg, UPB_SIZE(44, 88)); }
+UPB_INLINE size_t envoy_config_route_v3_WeightedCluster_ClusterWeight_typed_per_filter_config_size(const envoy_config_route_v3_WeightedCluster_ClusterWeight *msg) {return _upb_msg_map_size(msg, UPB_SIZE(44, 88)); }
+UPB_INLINE bool envoy_config_route_v3_WeightedCluster_ClusterWeight_typed_per_filter_config_get(const envoy_config_route_v3_WeightedCluster_ClusterWeight *msg, upb_strview key, struct google_protobuf_Any* *val) { return _upb_msg_map_get(msg, UPB_SIZE(44, 88), &key, 0, val, sizeof(*val)); }
+UPB_INLINE const envoy_config_route_v3_WeightedCluster_ClusterWeight_TypedPerFilterConfigEntry* envoy_config_route_v3_WeightedCluster_ClusterWeight_typed_per_filter_config_next(const envoy_config_route_v3_WeightedCluster_ClusterWeight *msg, size_t* iter) { return (const envoy_config_route_v3_WeightedCluster_ClusterWeight_TypedPerFilterConfigEntry*)_upb_msg_map_next(msg, UPB_SIZE(44, 88), iter); }
+UPB_INLINE bool envoy_config_route_v3_WeightedCluster_ClusterWeight_has_host_rewrite_literal(const envoy_config_route_v3_WeightedCluster_ClusterWeight *msg) { return _upb_getoneofcase(msg, UPB_SIZE(56, 112)) == 11; }
+UPB_INLINE upb_strview envoy_config_route_v3_WeightedCluster_ClusterWeight_host_rewrite_literal(const envoy_config_route_v3_WeightedCluster_ClusterWeight *msg) { return UPB_READ_ONEOF(msg, upb_strview, UPB_SIZE(48, 96), UPB_SIZE(56, 112), 11, upb_strview_make("", strlen(""))); }
+UPB_INLINE upb_strview envoy_config_route_v3_WeightedCluster_ClusterWeight_cluster_header(const envoy_config_route_v3_WeightedCluster_ClusterWeight *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(12, 24), upb_strview); }
 
 UPB_INLINE void envoy_config_route_v3_WeightedCluster_ClusterWeight_set_name(envoy_config_route_v3_WeightedCluster_ClusterWeight *msg, upb_strview value) {
   *UPB_PTR_AT(msg, UPB_SIZE(4, 8), upb_strview) = value;
 }
 UPB_INLINE void envoy_config_route_v3_WeightedCluster_ClusterWeight_set_weight(envoy_config_route_v3_WeightedCluster_ClusterWeight *msg, struct google_protobuf_UInt32Value* value) {
   _upb_sethas(msg, 1);
-  *UPB_PTR_AT(msg, UPB_SIZE(12, 24), struct google_protobuf_UInt32Value*) = value;
+  *UPB_PTR_AT(msg, UPB_SIZE(20, 40), struct google_protobuf_UInt32Value*) = value;
 }
 UPB_INLINE struct google_protobuf_UInt32Value* envoy_config_route_v3_WeightedCluster_ClusterWeight_mutable_weight(envoy_config_route_v3_WeightedCluster_ClusterWeight *msg, upb_arena *arena) {
   struct google_protobuf_UInt32Value* sub = (struct google_protobuf_UInt32Value*)envoy_config_route_v3_WeightedCluster_ClusterWeight_weight(msg);
@@ -910,7 +943,7 @@ UPB_INLINE struct google_protobuf_UInt32Value* envoy_config_route_v3_WeightedClu
 }
 UPB_INLINE void envoy_config_route_v3_WeightedCluster_ClusterWeight_set_metadata_match(envoy_config_route_v3_WeightedCluster_ClusterWeight *msg, struct envoy_config_core_v3_Metadata* value) {
   _upb_sethas(msg, 2);
-  *UPB_PTR_AT(msg, UPB_SIZE(16, 32), struct envoy_config_core_v3_Metadata*) = value;
+  *UPB_PTR_AT(msg, UPB_SIZE(24, 48), struct envoy_config_core_v3_Metadata*) = value;
 }
 UPB_INLINE struct envoy_config_core_v3_Metadata* envoy_config_route_v3_WeightedCluster_ClusterWeight_mutable_metadata_match(envoy_config_route_v3_WeightedCluster_ClusterWeight *msg, upb_arena *arena) {
   struct envoy_config_core_v3_Metadata* sub = (struct envoy_config_core_v3_Metadata*)envoy_config_route_v3_WeightedCluster_ClusterWeight_metadata_match(msg);
@@ -922,57 +955,60 @@ UPB_INLINE struct envoy_config_core_v3_Metadata* envoy_config_route_v3_WeightedC
   return sub;
 }
 UPB_INLINE struct envoy_config_core_v3_HeaderValueOption** envoy_config_route_v3_WeightedCluster_ClusterWeight_mutable_request_headers_to_add(envoy_config_route_v3_WeightedCluster_ClusterWeight *msg, size_t *len) {
-  return (struct envoy_config_core_v3_HeaderValueOption**)_upb_array_mutable_accessor(msg, UPB_SIZE(20, 40), len);
+  return (struct envoy_config_core_v3_HeaderValueOption**)_upb_array_mutable_accessor(msg, UPB_SIZE(28, 56), len);
 }
 UPB_INLINE struct envoy_config_core_v3_HeaderValueOption** envoy_config_route_v3_WeightedCluster_ClusterWeight_resize_request_headers_to_add(envoy_config_route_v3_WeightedCluster_ClusterWeight *msg, size_t len, upb_arena *arena) {
-  return (struct envoy_config_core_v3_HeaderValueOption**)_upb_array_resize_accessor2(msg, UPB_SIZE(20, 40), len, UPB_SIZE(2, 3), arena);
+  return (struct envoy_config_core_v3_HeaderValueOption**)_upb_array_resize_accessor2(msg, UPB_SIZE(28, 56), len, UPB_SIZE(2, 3), arena);
 }
 UPB_INLINE struct envoy_config_core_v3_HeaderValueOption* envoy_config_route_v3_WeightedCluster_ClusterWeight_add_request_headers_to_add(envoy_config_route_v3_WeightedCluster_ClusterWeight *msg, upb_arena *arena) {
   struct envoy_config_core_v3_HeaderValueOption* sub = (struct envoy_config_core_v3_HeaderValueOption*)_upb_msg_new(&envoy_config_core_v3_HeaderValueOption_msginit, arena);
   bool ok = _upb_array_append_accessor2(
-      msg, UPB_SIZE(20, 40), UPB_SIZE(2, 3), &sub, arena);
+      msg, UPB_SIZE(28, 56), UPB_SIZE(2, 3), &sub, arena);
   if (!ok) return NULL;
   return sub;
 }
 UPB_INLINE struct envoy_config_core_v3_HeaderValueOption** envoy_config_route_v3_WeightedCluster_ClusterWeight_mutable_response_headers_to_add(envoy_config_route_v3_WeightedCluster_ClusterWeight *msg, size_t *len) {
-  return (struct envoy_config_core_v3_HeaderValueOption**)_upb_array_mutable_accessor(msg, UPB_SIZE(24, 48), len);
+  return (struct envoy_config_core_v3_HeaderValueOption**)_upb_array_mutable_accessor(msg, UPB_SIZE(32, 64), len);
 }
 UPB_INLINE struct envoy_config_core_v3_HeaderValueOption** envoy_config_route_v3_WeightedCluster_ClusterWeight_resize_response_headers_to_add(envoy_config_route_v3_WeightedCluster_ClusterWeight *msg, size_t len, upb_arena *arena) {
-  return (struct envoy_config_core_v3_HeaderValueOption**)_upb_array_resize_accessor2(msg, UPB_SIZE(24, 48), len, UPB_SIZE(2, 3), arena);
+  return (struct envoy_config_core_v3_HeaderValueOption**)_upb_array_resize_accessor2(msg, UPB_SIZE(32, 64), len, UPB_SIZE(2, 3), arena);
 }
 UPB_INLINE struct envoy_config_core_v3_HeaderValueOption* envoy_config_route_v3_WeightedCluster_ClusterWeight_add_response_headers_to_add(envoy_config_route_v3_WeightedCluster_ClusterWeight *msg, upb_arena *arena) {
   struct envoy_config_core_v3_HeaderValueOption* sub = (struct envoy_config_core_v3_HeaderValueOption*)_upb_msg_new(&envoy_config_core_v3_HeaderValueOption_msginit, arena);
   bool ok = _upb_array_append_accessor2(
-      msg, UPB_SIZE(24, 48), UPB_SIZE(2, 3), &sub, arena);
+      msg, UPB_SIZE(32, 64), UPB_SIZE(2, 3), &sub, arena);
   if (!ok) return NULL;
   return sub;
 }
 UPB_INLINE upb_strview* envoy_config_route_v3_WeightedCluster_ClusterWeight_mutable_response_headers_to_remove(envoy_config_route_v3_WeightedCluster_ClusterWeight *msg, size_t *len) {
-  return (upb_strview*)_upb_array_mutable_accessor(msg, UPB_SIZE(28, 56), len);
+  return (upb_strview*)_upb_array_mutable_accessor(msg, UPB_SIZE(36, 72), len);
 }
 UPB_INLINE upb_strview* envoy_config_route_v3_WeightedCluster_ClusterWeight_resize_response_headers_to_remove(envoy_config_route_v3_WeightedCluster_ClusterWeight *msg, size_t len, upb_arena *arena) {
-  return (upb_strview*)_upb_array_resize_accessor2(msg, UPB_SIZE(28, 56), len, UPB_SIZE(3, 4), arena);
+  return (upb_strview*)_upb_array_resize_accessor2(msg, UPB_SIZE(36, 72), len, UPB_SIZE(3, 4), arena);
 }
 UPB_INLINE bool envoy_config_route_v3_WeightedCluster_ClusterWeight_add_response_headers_to_remove(envoy_config_route_v3_WeightedCluster_ClusterWeight *msg, upb_strview val, upb_arena *arena) {
-  return _upb_array_append_accessor2(msg, UPB_SIZE(28, 56), UPB_SIZE(3, 4), &val,
+  return _upb_array_append_accessor2(msg, UPB_SIZE(36, 72), UPB_SIZE(3, 4), &val,
       arena);
 }
 UPB_INLINE upb_strview* envoy_config_route_v3_WeightedCluster_ClusterWeight_mutable_request_headers_to_remove(envoy_config_route_v3_WeightedCluster_ClusterWeight *msg, size_t *len) {
-  return (upb_strview*)_upb_array_mutable_accessor(msg, UPB_SIZE(32, 64), len);
+  return (upb_strview*)_upb_array_mutable_accessor(msg, UPB_SIZE(40, 80), len);
 }
 UPB_INLINE upb_strview* envoy_config_route_v3_WeightedCluster_ClusterWeight_resize_request_headers_to_remove(envoy_config_route_v3_WeightedCluster_ClusterWeight *msg, size_t len, upb_arena *arena) {
-  return (upb_strview*)_upb_array_resize_accessor2(msg, UPB_SIZE(32, 64), len, UPB_SIZE(3, 4), arena);
+  return (upb_strview*)_upb_array_resize_accessor2(msg, UPB_SIZE(40, 80), len, UPB_SIZE(3, 4), arena);
 }
 UPB_INLINE bool envoy_config_route_v3_WeightedCluster_ClusterWeight_add_request_headers_to_remove(envoy_config_route_v3_WeightedCluster_ClusterWeight *msg, upb_strview val, upb_arena *arena) {
-  return _upb_array_append_accessor2(msg, UPB_SIZE(32, 64), UPB_SIZE(3, 4), &val,
+  return _upb_array_append_accessor2(msg, UPB_SIZE(40, 80), UPB_SIZE(3, 4), &val,
       arena);
 }
-UPB_INLINE void envoy_config_route_v3_WeightedCluster_ClusterWeight_typed_per_filter_config_clear(envoy_config_route_v3_WeightedCluster_ClusterWeight *msg) { _upb_msg_map_clear(msg, UPB_SIZE(36, 72)); }
-UPB_INLINE bool envoy_config_route_v3_WeightedCluster_ClusterWeight_typed_per_filter_config_set(envoy_config_route_v3_WeightedCluster_ClusterWeight *msg, upb_strview key, struct google_protobuf_Any* val, upb_arena *a) { return _upb_msg_map_set(msg, UPB_SIZE(36, 72), &key, 0, &val, sizeof(val), a); }
-UPB_INLINE bool envoy_config_route_v3_WeightedCluster_ClusterWeight_typed_per_filter_config_delete(envoy_config_route_v3_WeightedCluster_ClusterWeight *msg, upb_strview key) { return _upb_msg_map_delete(msg, UPB_SIZE(36, 72), &key, 0); }
-UPB_INLINE envoy_config_route_v3_WeightedCluster_ClusterWeight_TypedPerFilterConfigEntry* envoy_config_route_v3_WeightedCluster_ClusterWeight_typed_per_filter_config_nextmutable(envoy_config_route_v3_WeightedCluster_ClusterWeight *msg, size_t* iter) { return (envoy_config_route_v3_WeightedCluster_ClusterWeight_TypedPerFilterConfigEntry*)_upb_msg_map_next(msg, UPB_SIZE(36, 72), iter); }
+UPB_INLINE void envoy_config_route_v3_WeightedCluster_ClusterWeight_typed_per_filter_config_clear(envoy_config_route_v3_WeightedCluster_ClusterWeight *msg) { _upb_msg_map_clear(msg, UPB_SIZE(44, 88)); }
+UPB_INLINE bool envoy_config_route_v3_WeightedCluster_ClusterWeight_typed_per_filter_config_set(envoy_config_route_v3_WeightedCluster_ClusterWeight *msg, upb_strview key, struct google_protobuf_Any* val, upb_arena *a) { return _upb_msg_map_set(msg, UPB_SIZE(44, 88), &key, 0, &val, sizeof(val), a); }
+UPB_INLINE bool envoy_config_route_v3_WeightedCluster_ClusterWeight_typed_per_filter_config_delete(envoy_config_route_v3_WeightedCluster_ClusterWeight *msg, upb_strview key) { return _upb_msg_map_delete(msg, UPB_SIZE(44, 88), &key, 0); }
+UPB_INLINE envoy_config_route_v3_WeightedCluster_ClusterWeight_TypedPerFilterConfigEntry* envoy_config_route_v3_WeightedCluster_ClusterWeight_typed_per_filter_config_nextmutable(envoy_config_route_v3_WeightedCluster_ClusterWeight *msg, size_t* iter) { return (envoy_config_route_v3_WeightedCluster_ClusterWeight_TypedPerFilterConfigEntry*)_upb_msg_map_next(msg, UPB_SIZE(44, 88), iter); }
 UPB_INLINE void envoy_config_route_v3_WeightedCluster_ClusterWeight_set_host_rewrite_literal(envoy_config_route_v3_WeightedCluster_ClusterWeight *msg, upb_strview value) {
-  UPB_WRITE_ONEOF(msg, upb_strview, UPB_SIZE(40, 80), value, UPB_SIZE(48, 96), 11);
+  UPB_WRITE_ONEOF(msg, upb_strview, UPB_SIZE(48, 96), value, UPB_SIZE(56, 112), 11);
+}
+UPB_INLINE void envoy_config_route_v3_WeightedCluster_ClusterWeight_set_cluster_header(envoy_config_route_v3_WeightedCluster_ClusterWeight *msg, upb_strview value) {
+  *UPB_PTR_AT(msg, UPB_SIZE(12, 24), upb_strview) = value;
 }
 
 /* envoy.config.route.v3.WeightedCluster.ClusterWeight.TypedPerFilterConfigEntry */
@@ -1001,13 +1037,19 @@ UPB_INLINE envoy_config_route_v3_RouteMatch *envoy_config_route_v3_RouteMatch_ne
 UPB_INLINE envoy_config_route_v3_RouteMatch *envoy_config_route_v3_RouteMatch_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_route_v3_RouteMatch *ret = envoy_config_route_v3_RouteMatch_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_route_v3_RouteMatch_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_route_v3_RouteMatch_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_route_v3_RouteMatch *envoy_config_route_v3_RouteMatch_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_route_v3_RouteMatch *ret = envoy_config_route_v3_RouteMatch_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_route_v3_RouteMatch_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_route_v3_RouteMatch_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_route_v3_RouteMatch_serialize(const envoy_config_route_v3_RouteMatch *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_route_v3_RouteMatch_msginit, arena, len);
@@ -1020,12 +1062,12 @@ typedef enum {
   envoy_config_route_v3_RouteMatch_path_specifier_connect_matcher = 12,
   envoy_config_route_v3_RouteMatch_path_specifier_NOT_SET = 0
 } envoy_config_route_v3_RouteMatch_path_specifier_oneofcases;
-UPB_INLINE envoy_config_route_v3_RouteMatch_path_specifier_oneofcases envoy_config_route_v3_RouteMatch_path_specifier_case(const envoy_config_route_v3_RouteMatch* msg) { return (envoy_config_route_v3_RouteMatch_path_specifier_oneofcases)*UPB_PTR_AT(msg, UPB_SIZE(36, 72), int32_t); }
+UPB_INLINE envoy_config_route_v3_RouteMatch_path_specifier_oneofcases envoy_config_route_v3_RouteMatch_path_specifier_case(const envoy_config_route_v3_RouteMatch* msg) { return (envoy_config_route_v3_RouteMatch_path_specifier_oneofcases)*UPB_PTR_AT(msg, UPB_SIZE(40, 80), int32_t); }
 
-UPB_INLINE bool envoy_config_route_v3_RouteMatch_has_prefix(const envoy_config_route_v3_RouteMatch *msg) { return _upb_getoneofcase(msg, UPB_SIZE(36, 72)) == 1; }
-UPB_INLINE upb_strview envoy_config_route_v3_RouteMatch_prefix(const envoy_config_route_v3_RouteMatch *msg) { return UPB_READ_ONEOF(msg, upb_strview, UPB_SIZE(28, 56), UPB_SIZE(36, 72), 1, upb_strview_make("", strlen(""))); }
-UPB_INLINE bool envoy_config_route_v3_RouteMatch_has_path(const envoy_config_route_v3_RouteMatch *msg) { return _upb_getoneofcase(msg, UPB_SIZE(36, 72)) == 2; }
-UPB_INLINE upb_strview envoy_config_route_v3_RouteMatch_path(const envoy_config_route_v3_RouteMatch *msg) { return UPB_READ_ONEOF(msg, upb_strview, UPB_SIZE(28, 56), UPB_SIZE(36, 72), 2, upb_strview_make("", strlen(""))); }
+UPB_INLINE bool envoy_config_route_v3_RouteMatch_has_prefix(const envoy_config_route_v3_RouteMatch *msg) { return _upb_getoneofcase(msg, UPB_SIZE(40, 80)) == 1; }
+UPB_INLINE upb_strview envoy_config_route_v3_RouteMatch_prefix(const envoy_config_route_v3_RouteMatch *msg) { return UPB_READ_ONEOF(msg, upb_strview, UPB_SIZE(32, 64), UPB_SIZE(40, 80), 1, upb_strview_make("", strlen(""))); }
+UPB_INLINE bool envoy_config_route_v3_RouteMatch_has_path(const envoy_config_route_v3_RouteMatch *msg) { return _upb_getoneofcase(msg, UPB_SIZE(40, 80)) == 2; }
+UPB_INLINE upb_strview envoy_config_route_v3_RouteMatch_path(const envoy_config_route_v3_RouteMatch *msg) { return UPB_READ_ONEOF(msg, upb_strview, UPB_SIZE(32, 64), UPB_SIZE(40, 80), 2, upb_strview_make("", strlen(""))); }
 UPB_INLINE bool envoy_config_route_v3_RouteMatch_has_case_sensitive(const envoy_config_route_v3_RouteMatch *msg) { return _upb_hasbit(msg, 1); }
 UPB_INLINE const struct google_protobuf_BoolValue* envoy_config_route_v3_RouteMatch_case_sensitive(const envoy_config_route_v3_RouteMatch *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(4, 8), const struct google_protobuf_BoolValue*); }
 UPB_INLINE bool envoy_config_route_v3_RouteMatch_has_headers(const envoy_config_route_v3_RouteMatch *msg) { return _upb_has_submsg_nohasbit(msg, UPB_SIZE(20, 40)); }
@@ -1036,18 +1078,20 @@ UPB_INLINE bool envoy_config_route_v3_RouteMatch_has_grpc(const envoy_config_rou
 UPB_INLINE const envoy_config_route_v3_RouteMatch_GrpcRouteMatchOptions* envoy_config_route_v3_RouteMatch_grpc(const envoy_config_route_v3_RouteMatch *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(8, 16), const envoy_config_route_v3_RouteMatch_GrpcRouteMatchOptions*); }
 UPB_INLINE bool envoy_config_route_v3_RouteMatch_has_runtime_fraction(const envoy_config_route_v3_RouteMatch *msg) { return _upb_hasbit(msg, 3); }
 UPB_INLINE const struct envoy_config_core_v3_RuntimeFractionalPercent* envoy_config_route_v3_RouteMatch_runtime_fraction(const envoy_config_route_v3_RouteMatch *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(12, 24), const struct envoy_config_core_v3_RuntimeFractionalPercent*); }
-UPB_INLINE bool envoy_config_route_v3_RouteMatch_has_safe_regex(const envoy_config_route_v3_RouteMatch *msg) { return _upb_getoneofcase(msg, UPB_SIZE(36, 72)) == 10; }
-UPB_INLINE const struct envoy_type_matcher_v3_RegexMatcher* envoy_config_route_v3_RouteMatch_safe_regex(const envoy_config_route_v3_RouteMatch *msg) { return UPB_READ_ONEOF(msg, const struct envoy_type_matcher_v3_RegexMatcher*, UPB_SIZE(28, 56), UPB_SIZE(36, 72), 10, NULL); }
+UPB_INLINE bool envoy_config_route_v3_RouteMatch_has_safe_regex(const envoy_config_route_v3_RouteMatch *msg) { return _upb_getoneofcase(msg, UPB_SIZE(40, 80)) == 10; }
+UPB_INLINE const struct envoy_type_matcher_v3_RegexMatcher* envoy_config_route_v3_RouteMatch_safe_regex(const envoy_config_route_v3_RouteMatch *msg) { return UPB_READ_ONEOF(msg, const struct envoy_type_matcher_v3_RegexMatcher*, UPB_SIZE(32, 64), UPB_SIZE(40, 80), 10, NULL); }
 UPB_INLINE bool envoy_config_route_v3_RouteMatch_has_tls_context(const envoy_config_route_v3_RouteMatch *msg) { return _upb_hasbit(msg, 4); }
 UPB_INLINE const envoy_config_route_v3_RouteMatch_TlsContextMatchOptions* envoy_config_route_v3_RouteMatch_tls_context(const envoy_config_route_v3_RouteMatch *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(16, 32), const envoy_config_route_v3_RouteMatch_TlsContextMatchOptions*); }
-UPB_INLINE bool envoy_config_route_v3_RouteMatch_has_connect_matcher(const envoy_config_route_v3_RouteMatch *msg) { return _upb_getoneofcase(msg, UPB_SIZE(36, 72)) == 12; }
-UPB_INLINE const envoy_config_route_v3_RouteMatch_ConnectMatcher* envoy_config_route_v3_RouteMatch_connect_matcher(const envoy_config_route_v3_RouteMatch *msg) { return UPB_READ_ONEOF(msg, const envoy_config_route_v3_RouteMatch_ConnectMatcher*, UPB_SIZE(28, 56), UPB_SIZE(36, 72), 12, NULL); }
+UPB_INLINE bool envoy_config_route_v3_RouteMatch_has_connect_matcher(const envoy_config_route_v3_RouteMatch *msg) { return _upb_getoneofcase(msg, UPB_SIZE(40, 80)) == 12; }
+UPB_INLINE const envoy_config_route_v3_RouteMatch_ConnectMatcher* envoy_config_route_v3_RouteMatch_connect_matcher(const envoy_config_route_v3_RouteMatch *msg) { return UPB_READ_ONEOF(msg, const envoy_config_route_v3_RouteMatch_ConnectMatcher*, UPB_SIZE(32, 64), UPB_SIZE(40, 80), 12, NULL); }
+UPB_INLINE bool envoy_config_route_v3_RouteMatch_has_dynamic_metadata(const envoy_config_route_v3_RouteMatch *msg) { return _upb_has_submsg_nohasbit(msg, UPB_SIZE(28, 56)); }
+UPB_INLINE const struct envoy_type_matcher_v3_MetadataMatcher* const* envoy_config_route_v3_RouteMatch_dynamic_metadata(const envoy_config_route_v3_RouteMatch *msg, size_t *len) { return (const struct envoy_type_matcher_v3_MetadataMatcher* const*)_upb_array_accessor(msg, UPB_SIZE(28, 56), len); }
 
 UPB_INLINE void envoy_config_route_v3_RouteMatch_set_prefix(envoy_config_route_v3_RouteMatch *msg, upb_strview value) {
-  UPB_WRITE_ONEOF(msg, upb_strview, UPB_SIZE(28, 56), value, UPB_SIZE(36, 72), 1);
+  UPB_WRITE_ONEOF(msg, upb_strview, UPB_SIZE(32, 64), value, UPB_SIZE(40, 80), 1);
 }
 UPB_INLINE void envoy_config_route_v3_RouteMatch_set_path(envoy_config_route_v3_RouteMatch *msg, upb_strview value) {
-  UPB_WRITE_ONEOF(msg, upb_strview, UPB_SIZE(28, 56), value, UPB_SIZE(36, 72), 2);
+  UPB_WRITE_ONEOF(msg, upb_strview, UPB_SIZE(32, 64), value, UPB_SIZE(40, 80), 2);
 }
 UPB_INLINE void envoy_config_route_v3_RouteMatch_set_case_sensitive(envoy_config_route_v3_RouteMatch *msg, struct google_protobuf_BoolValue* value) {
   _upb_sethas(msg, 1);
@@ -1115,7 +1159,7 @@ UPB_INLINE struct envoy_config_core_v3_RuntimeFractionalPercent* envoy_config_ro
   return sub;
 }
 UPB_INLINE void envoy_config_route_v3_RouteMatch_set_safe_regex(envoy_config_route_v3_RouteMatch *msg, struct envoy_type_matcher_v3_RegexMatcher* value) {
-  UPB_WRITE_ONEOF(msg, struct envoy_type_matcher_v3_RegexMatcher*, UPB_SIZE(28, 56), value, UPB_SIZE(36, 72), 10);
+  UPB_WRITE_ONEOF(msg, struct envoy_type_matcher_v3_RegexMatcher*, UPB_SIZE(32, 64), value, UPB_SIZE(40, 80), 10);
 }
 UPB_INLINE struct envoy_type_matcher_v3_RegexMatcher* envoy_config_route_v3_RouteMatch_mutable_safe_regex(envoy_config_route_v3_RouteMatch *msg, upb_arena *arena) {
   struct envoy_type_matcher_v3_RegexMatcher* sub = (struct envoy_type_matcher_v3_RegexMatcher*)envoy_config_route_v3_RouteMatch_safe_regex(msg);
@@ -1140,7 +1184,7 @@ UPB_INLINE struct envoy_config_route_v3_RouteMatch_TlsContextMatchOptions* envoy
   return sub;
 }
 UPB_INLINE void envoy_config_route_v3_RouteMatch_set_connect_matcher(envoy_config_route_v3_RouteMatch *msg, envoy_config_route_v3_RouteMatch_ConnectMatcher* value) {
-  UPB_WRITE_ONEOF(msg, envoy_config_route_v3_RouteMatch_ConnectMatcher*, UPB_SIZE(28, 56), value, UPB_SIZE(36, 72), 12);
+  UPB_WRITE_ONEOF(msg, envoy_config_route_v3_RouteMatch_ConnectMatcher*, UPB_SIZE(32, 64), value, UPB_SIZE(40, 80), 12);
 }
 UPB_INLINE struct envoy_config_route_v3_RouteMatch_ConnectMatcher* envoy_config_route_v3_RouteMatch_mutable_connect_matcher(envoy_config_route_v3_RouteMatch *msg, upb_arena *arena) {
   struct envoy_config_route_v3_RouteMatch_ConnectMatcher* sub = (struct envoy_config_route_v3_RouteMatch_ConnectMatcher*)envoy_config_route_v3_RouteMatch_connect_matcher(msg);
@@ -1151,6 +1195,19 @@ UPB_INLINE struct envoy_config_route_v3_RouteMatch_ConnectMatcher* envoy_config_
   }
   return sub;
 }
+UPB_INLINE struct envoy_type_matcher_v3_MetadataMatcher** envoy_config_route_v3_RouteMatch_mutable_dynamic_metadata(envoy_config_route_v3_RouteMatch *msg, size_t *len) {
+  return (struct envoy_type_matcher_v3_MetadataMatcher**)_upb_array_mutable_accessor(msg, UPB_SIZE(28, 56), len);
+}
+UPB_INLINE struct envoy_type_matcher_v3_MetadataMatcher** envoy_config_route_v3_RouteMatch_resize_dynamic_metadata(envoy_config_route_v3_RouteMatch *msg, size_t len, upb_arena *arena) {
+  return (struct envoy_type_matcher_v3_MetadataMatcher**)_upb_array_resize_accessor2(msg, UPB_SIZE(28, 56), len, UPB_SIZE(2, 3), arena);
+}
+UPB_INLINE struct envoy_type_matcher_v3_MetadataMatcher* envoy_config_route_v3_RouteMatch_add_dynamic_metadata(envoy_config_route_v3_RouteMatch *msg, upb_arena *arena) {
+  struct envoy_type_matcher_v3_MetadataMatcher* sub = (struct envoy_type_matcher_v3_MetadataMatcher*)_upb_msg_new(&envoy_type_matcher_v3_MetadataMatcher_msginit, arena);
+  bool ok = _upb_array_append_accessor2(
+      msg, UPB_SIZE(28, 56), UPB_SIZE(2, 3), &sub, arena);
+  if (!ok) return NULL;
+  return sub;
+}
 
 /* envoy.config.route.v3.RouteMatch.GrpcRouteMatchOptions */
 
@@ -1160,13 +1217,19 @@ UPB_INLINE envoy_config_route_v3_RouteMatch_GrpcRouteMatchOptions *envoy_config_
 UPB_INLINE envoy_config_route_v3_RouteMatch_GrpcRouteMatchOptions *envoy_config_route_v3_RouteMatch_GrpcRouteMatchOptions_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_route_v3_RouteMatch_GrpcRouteMatchOptions *ret = envoy_config_route_v3_RouteMatch_GrpcRouteMatchOptions_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_route_v3_RouteMatch_GrpcRouteMatchOptions_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_route_v3_RouteMatch_GrpcRouteMatchOptions_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_route_v3_RouteMatch_GrpcRouteMatchOptions *envoy_config_route_v3_RouteMatch_GrpcRouteMatchOptions_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_route_v3_RouteMatch_GrpcRouteMatchOptions *ret = envoy_config_route_v3_RouteMatch_GrpcRouteMatchOptions_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_route_v3_RouteMatch_GrpcRouteMatchOptions_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_route_v3_RouteMatch_GrpcRouteMatchOptions_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_route_v3_RouteMatch_GrpcRouteMatchOptions_serialize(const envoy_config_route_v3_RouteMatch_GrpcRouteMatchOptions *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_route_v3_RouteMatch_GrpcRouteMatchOptions_msginit, arena, len);
@@ -1182,13 +1245,19 @@ UPB_INLINE envoy_config_route_v3_RouteMatch_TlsContextMatchOptions *envoy_config
 UPB_INLINE envoy_config_route_v3_RouteMatch_TlsContextMatchOptions *envoy_config_route_v3_RouteMatch_TlsContextMatchOptions_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_route_v3_RouteMatch_TlsContextMatchOptions *ret = envoy_config_route_v3_RouteMatch_TlsContextMatchOptions_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_route_v3_RouteMatch_TlsContextMatchOptions_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_route_v3_RouteMatch_TlsContextMatchOptions_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_route_v3_RouteMatch_TlsContextMatchOptions *envoy_config_route_v3_RouteMatch_TlsContextMatchOptions_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_route_v3_RouteMatch_TlsContextMatchOptions *ret = envoy_config_route_v3_RouteMatch_TlsContextMatchOptions_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_route_v3_RouteMatch_TlsContextMatchOptions_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_route_v3_RouteMatch_TlsContextMatchOptions_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_route_v3_RouteMatch_TlsContextMatchOptions_serialize(const envoy_config_route_v3_RouteMatch_TlsContextMatchOptions *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_route_v3_RouteMatch_TlsContextMatchOptions_msginit, arena, len);
@@ -1234,13 +1303,19 @@ UPB_INLINE envoy_config_route_v3_RouteMatch_ConnectMatcher *envoy_config_route_v
 UPB_INLINE envoy_config_route_v3_RouteMatch_ConnectMatcher *envoy_config_route_v3_RouteMatch_ConnectMatcher_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_route_v3_RouteMatch_ConnectMatcher *ret = envoy_config_route_v3_RouteMatch_ConnectMatcher_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_route_v3_RouteMatch_ConnectMatcher_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_route_v3_RouteMatch_ConnectMatcher_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_route_v3_RouteMatch_ConnectMatcher *envoy_config_route_v3_RouteMatch_ConnectMatcher_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_route_v3_RouteMatch_ConnectMatcher *ret = envoy_config_route_v3_RouteMatch_ConnectMatcher_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_route_v3_RouteMatch_ConnectMatcher_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_route_v3_RouteMatch_ConnectMatcher_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_route_v3_RouteMatch_ConnectMatcher_serialize(const envoy_config_route_v3_RouteMatch_ConnectMatcher *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_route_v3_RouteMatch_ConnectMatcher_msginit, arena, len);
@@ -1256,13 +1331,19 @@ UPB_INLINE envoy_config_route_v3_CorsPolicy *envoy_config_route_v3_CorsPolicy_ne
 UPB_INLINE envoy_config_route_v3_CorsPolicy *envoy_config_route_v3_CorsPolicy_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_route_v3_CorsPolicy *ret = envoy_config_route_v3_CorsPolicy_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_route_v3_CorsPolicy_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_route_v3_CorsPolicy_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_route_v3_CorsPolicy *envoy_config_route_v3_CorsPolicy_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_route_v3_CorsPolicy *ret = envoy_config_route_v3_CorsPolicy_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_route_v3_CorsPolicy_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_route_v3_CorsPolicy_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_route_v3_CorsPolicy_serialize(const envoy_config_route_v3_CorsPolicy *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_route_v3_CorsPolicy_msginit, arena, len);
@@ -1359,13 +1440,19 @@ UPB_INLINE envoy_config_route_v3_RouteAction *envoy_config_route_v3_RouteAction_
 UPB_INLINE envoy_config_route_v3_RouteAction *envoy_config_route_v3_RouteAction_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_route_v3_RouteAction *ret = envoy_config_route_v3_RouteAction_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_route_v3_RouteAction_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_route_v3_RouteAction_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_route_v3_RouteAction *envoy_config_route_v3_RouteAction_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_route_v3_RouteAction *ret = envoy_config_route_v3_RouteAction_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_route_v3_RouteAction_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_route_v3_RouteAction_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_route_v3_RouteAction_serialize(const envoy_config_route_v3_RouteAction *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_route_v3_RouteAction_msginit, arena, len);
@@ -1752,13 +1839,19 @@ UPB_INLINE envoy_config_route_v3_RouteAction_RequestMirrorPolicy *envoy_config_r
 UPB_INLINE envoy_config_route_v3_RouteAction_RequestMirrorPolicy *envoy_config_route_v3_RouteAction_RequestMirrorPolicy_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_route_v3_RouteAction_RequestMirrorPolicy *ret = envoy_config_route_v3_RouteAction_RequestMirrorPolicy_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_route_v3_RouteAction_RequestMirrorPolicy_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_route_v3_RouteAction_RequestMirrorPolicy_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_route_v3_RouteAction_RequestMirrorPolicy *envoy_config_route_v3_RouteAction_RequestMirrorPolicy_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_route_v3_RouteAction_RequestMirrorPolicy *ret = envoy_config_route_v3_RouteAction_RequestMirrorPolicy_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_route_v3_RouteAction_RequestMirrorPolicy_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_route_v3_RouteAction_RequestMirrorPolicy_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_route_v3_RouteAction_RequestMirrorPolicy_serialize(const envoy_config_route_v3_RouteAction_RequestMirrorPolicy *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_route_v3_RouteAction_RequestMirrorPolicy_msginit, arena, len);
@@ -1808,13 +1901,19 @@ UPB_INLINE envoy_config_route_v3_RouteAction_HashPolicy *envoy_config_route_v3_R
 UPB_INLINE envoy_config_route_v3_RouteAction_HashPolicy *envoy_config_route_v3_RouteAction_HashPolicy_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_route_v3_RouteAction_HashPolicy *ret = envoy_config_route_v3_RouteAction_HashPolicy_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_route_v3_RouteAction_HashPolicy_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_route_v3_RouteAction_HashPolicy_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_route_v3_RouteAction_HashPolicy *envoy_config_route_v3_RouteAction_HashPolicy_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_route_v3_RouteAction_HashPolicy *ret = envoy_config_route_v3_RouteAction_HashPolicy_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_route_v3_RouteAction_HashPolicy_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_route_v3_RouteAction_HashPolicy_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_route_v3_RouteAction_HashPolicy_serialize(const envoy_config_route_v3_RouteAction_HashPolicy *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_route_v3_RouteAction_HashPolicy_msginit, arena, len);
@@ -1914,13 +2013,19 @@ UPB_INLINE envoy_config_route_v3_RouteAction_HashPolicy_Header *envoy_config_rou
 UPB_INLINE envoy_config_route_v3_RouteAction_HashPolicy_Header *envoy_config_route_v3_RouteAction_HashPolicy_Header_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_route_v3_RouteAction_HashPolicy_Header *ret = envoy_config_route_v3_RouteAction_HashPolicy_Header_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_route_v3_RouteAction_HashPolicy_Header_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_route_v3_RouteAction_HashPolicy_Header_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_route_v3_RouteAction_HashPolicy_Header *envoy_config_route_v3_RouteAction_HashPolicy_Header_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_route_v3_RouteAction_HashPolicy_Header *ret = envoy_config_route_v3_RouteAction_HashPolicy_Header_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_route_v3_RouteAction_HashPolicy_Header_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_route_v3_RouteAction_HashPolicy_Header_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_route_v3_RouteAction_HashPolicy_Header_serialize(const envoy_config_route_v3_RouteAction_HashPolicy_Header *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_route_v3_RouteAction_HashPolicy_Header_msginit, arena, len);
@@ -1955,13 +2060,19 @@ UPB_INLINE envoy_config_route_v3_RouteAction_HashPolicy_Cookie *envoy_config_rou
 UPB_INLINE envoy_config_route_v3_RouteAction_HashPolicy_Cookie *envoy_config_route_v3_RouteAction_HashPolicy_Cookie_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_route_v3_RouteAction_HashPolicy_Cookie *ret = envoy_config_route_v3_RouteAction_HashPolicy_Cookie_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_route_v3_RouteAction_HashPolicy_Cookie_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_route_v3_RouteAction_HashPolicy_Cookie_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_route_v3_RouteAction_HashPolicy_Cookie *envoy_config_route_v3_RouteAction_HashPolicy_Cookie_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_route_v3_RouteAction_HashPolicy_Cookie *ret = envoy_config_route_v3_RouteAction_HashPolicy_Cookie_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_route_v3_RouteAction_HashPolicy_Cookie_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_route_v3_RouteAction_HashPolicy_Cookie_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_route_v3_RouteAction_HashPolicy_Cookie_serialize(const envoy_config_route_v3_RouteAction_HashPolicy_Cookie *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_route_v3_RouteAction_HashPolicy_Cookie_msginit, arena, len);
@@ -2000,13 +2111,19 @@ UPB_INLINE envoy_config_route_v3_RouteAction_HashPolicy_ConnectionProperties *en
 UPB_INLINE envoy_config_route_v3_RouteAction_HashPolicy_ConnectionProperties *envoy_config_route_v3_RouteAction_HashPolicy_ConnectionProperties_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_route_v3_RouteAction_HashPolicy_ConnectionProperties *ret = envoy_config_route_v3_RouteAction_HashPolicy_ConnectionProperties_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_route_v3_RouteAction_HashPolicy_ConnectionProperties_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_route_v3_RouteAction_HashPolicy_ConnectionProperties_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_route_v3_RouteAction_HashPolicy_ConnectionProperties *envoy_config_route_v3_RouteAction_HashPolicy_ConnectionProperties_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_route_v3_RouteAction_HashPolicy_ConnectionProperties *ret = envoy_config_route_v3_RouteAction_HashPolicy_ConnectionProperties_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_route_v3_RouteAction_HashPolicy_ConnectionProperties_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_route_v3_RouteAction_HashPolicy_ConnectionProperties_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_route_v3_RouteAction_HashPolicy_ConnectionProperties_serialize(const envoy_config_route_v3_RouteAction_HashPolicy_ConnectionProperties *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_route_v3_RouteAction_HashPolicy_ConnectionProperties_msginit, arena, len);
@@ -2026,13 +2143,19 @@ UPB_INLINE envoy_config_route_v3_RouteAction_HashPolicy_QueryParameter *envoy_co
 UPB_INLINE envoy_config_route_v3_RouteAction_HashPolicy_QueryParameter *envoy_config_route_v3_RouteAction_HashPolicy_QueryParameter_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_route_v3_RouteAction_HashPolicy_QueryParameter *ret = envoy_config_route_v3_RouteAction_HashPolicy_QueryParameter_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_route_v3_RouteAction_HashPolicy_QueryParameter_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_route_v3_RouteAction_HashPolicy_QueryParameter_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_route_v3_RouteAction_HashPolicy_QueryParameter *envoy_config_route_v3_RouteAction_HashPolicy_QueryParameter_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_route_v3_RouteAction_HashPolicy_QueryParameter *ret = envoy_config_route_v3_RouteAction_HashPolicy_QueryParameter_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_route_v3_RouteAction_HashPolicy_QueryParameter_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_route_v3_RouteAction_HashPolicy_QueryParameter_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_route_v3_RouteAction_HashPolicy_QueryParameter_serialize(const envoy_config_route_v3_RouteAction_HashPolicy_QueryParameter *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_route_v3_RouteAction_HashPolicy_QueryParameter_msginit, arena, len);
@@ -2052,13 +2175,19 @@ UPB_INLINE envoy_config_route_v3_RouteAction_HashPolicy_FilterState *envoy_confi
 UPB_INLINE envoy_config_route_v3_RouteAction_HashPolicy_FilterState *envoy_config_route_v3_RouteAction_HashPolicy_FilterState_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_route_v3_RouteAction_HashPolicy_FilterState *ret = envoy_config_route_v3_RouteAction_HashPolicy_FilterState_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_route_v3_RouteAction_HashPolicy_FilterState_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_route_v3_RouteAction_HashPolicy_FilterState_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_route_v3_RouteAction_HashPolicy_FilterState *envoy_config_route_v3_RouteAction_HashPolicy_FilterState_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_route_v3_RouteAction_HashPolicy_FilterState *ret = envoy_config_route_v3_RouteAction_HashPolicy_FilterState_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_route_v3_RouteAction_HashPolicy_FilterState_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_route_v3_RouteAction_HashPolicy_FilterState_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_route_v3_RouteAction_HashPolicy_FilterState_serialize(const envoy_config_route_v3_RouteAction_HashPolicy_FilterState *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_route_v3_RouteAction_HashPolicy_FilterState_msginit, arena, len);
@@ -2078,13 +2207,19 @@ UPB_INLINE envoy_config_route_v3_RouteAction_UpgradeConfig *envoy_config_route_v
 UPB_INLINE envoy_config_route_v3_RouteAction_UpgradeConfig *envoy_config_route_v3_RouteAction_UpgradeConfig_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_route_v3_RouteAction_UpgradeConfig *ret = envoy_config_route_v3_RouteAction_UpgradeConfig_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_route_v3_RouteAction_UpgradeConfig_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_route_v3_RouteAction_UpgradeConfig_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_route_v3_RouteAction_UpgradeConfig *envoy_config_route_v3_RouteAction_UpgradeConfig_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_route_v3_RouteAction_UpgradeConfig *ret = envoy_config_route_v3_RouteAction_UpgradeConfig_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_route_v3_RouteAction_UpgradeConfig_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_route_v3_RouteAction_UpgradeConfig_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_route_v3_RouteAction_UpgradeConfig_serialize(const envoy_config_route_v3_RouteAction_UpgradeConfig *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_route_v3_RouteAction_UpgradeConfig_msginit, arena, len);
@@ -2134,13 +2269,19 @@ UPB_INLINE envoy_config_route_v3_RouteAction_UpgradeConfig_ConnectConfig *envoy_
 UPB_INLINE envoy_config_route_v3_RouteAction_UpgradeConfig_ConnectConfig *envoy_config_route_v3_RouteAction_UpgradeConfig_ConnectConfig_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_route_v3_RouteAction_UpgradeConfig_ConnectConfig *ret = envoy_config_route_v3_RouteAction_UpgradeConfig_ConnectConfig_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_route_v3_RouteAction_UpgradeConfig_ConnectConfig_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_route_v3_RouteAction_UpgradeConfig_ConnectConfig_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_route_v3_RouteAction_UpgradeConfig_ConnectConfig *envoy_config_route_v3_RouteAction_UpgradeConfig_ConnectConfig_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_route_v3_RouteAction_UpgradeConfig_ConnectConfig *ret = envoy_config_route_v3_RouteAction_UpgradeConfig_ConnectConfig_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_route_v3_RouteAction_UpgradeConfig_ConnectConfig_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_route_v3_RouteAction_UpgradeConfig_ConnectConfig_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_route_v3_RouteAction_UpgradeConfig_ConnectConfig_serialize(const envoy_config_route_v3_RouteAction_UpgradeConfig_ConnectConfig *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_route_v3_RouteAction_UpgradeConfig_ConnectConfig_msginit, arena, len);
@@ -2175,13 +2316,19 @@ UPB_INLINE envoy_config_route_v3_RouteAction_MaxStreamDuration *envoy_config_rou
 UPB_INLINE envoy_config_route_v3_RouteAction_MaxStreamDuration *envoy_config_route_v3_RouteAction_MaxStreamDuration_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_route_v3_RouteAction_MaxStreamDuration *ret = envoy_config_route_v3_RouteAction_MaxStreamDuration_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_route_v3_RouteAction_MaxStreamDuration_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_route_v3_RouteAction_MaxStreamDuration_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_route_v3_RouteAction_MaxStreamDuration *envoy_config_route_v3_RouteAction_MaxStreamDuration_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_route_v3_RouteAction_MaxStreamDuration *ret = envoy_config_route_v3_RouteAction_MaxStreamDuration_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_route_v3_RouteAction_MaxStreamDuration_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_route_v3_RouteAction_MaxStreamDuration_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_route_v3_RouteAction_MaxStreamDuration_serialize(const envoy_config_route_v3_RouteAction_MaxStreamDuration *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_route_v3_RouteAction_MaxStreamDuration_msginit, arena, len);
@@ -2242,13 +2389,19 @@ UPB_INLINE envoy_config_route_v3_RetryPolicy *envoy_config_route_v3_RetryPolicy_
 UPB_INLINE envoy_config_route_v3_RetryPolicy *envoy_config_route_v3_RetryPolicy_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_route_v3_RetryPolicy *ret = envoy_config_route_v3_RetryPolicy_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_route_v3_RetryPolicy_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_route_v3_RetryPolicy_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_route_v3_RetryPolicy *envoy_config_route_v3_RetryPolicy_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_route_v3_RetryPolicy *ret = envoy_config_route_v3_RetryPolicy_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_route_v3_RetryPolicy_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_route_v3_RetryPolicy_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_route_v3_RetryPolicy_serialize(const envoy_config_route_v3_RetryPolicy *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_route_v3_RetryPolicy_msginit, arena, len);
@@ -2403,13 +2556,19 @@ UPB_INLINE envoy_config_route_v3_RetryPolicy_RetryPriority *envoy_config_route_v
 UPB_INLINE envoy_config_route_v3_RetryPolicy_RetryPriority *envoy_config_route_v3_RetryPolicy_RetryPriority_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_route_v3_RetryPolicy_RetryPriority *ret = envoy_config_route_v3_RetryPolicy_RetryPriority_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_route_v3_RetryPolicy_RetryPriority_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_route_v3_RetryPolicy_RetryPriority_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_route_v3_RetryPolicy_RetryPriority *envoy_config_route_v3_RetryPolicy_RetryPriority_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_route_v3_RetryPolicy_RetryPriority *ret = envoy_config_route_v3_RetryPolicy_RetryPriority_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_route_v3_RetryPolicy_RetryPriority_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_route_v3_RetryPolicy_RetryPriority_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_route_v3_RetryPolicy_RetryPriority_serialize(const envoy_config_route_v3_RetryPolicy_RetryPriority *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_route_v3_RetryPolicy_RetryPriority_msginit, arena, len);
@@ -2449,13 +2608,19 @@ UPB_INLINE envoy_config_route_v3_RetryPolicy_RetryHostPredicate *envoy_config_ro
 UPB_INLINE envoy_config_route_v3_RetryPolicy_RetryHostPredicate *envoy_config_route_v3_RetryPolicy_RetryHostPredicate_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_route_v3_RetryPolicy_RetryHostPredicate *ret = envoy_config_route_v3_RetryPolicy_RetryHostPredicate_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_route_v3_RetryPolicy_RetryHostPredicate_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_route_v3_RetryPolicy_RetryHostPredicate_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_route_v3_RetryPolicy_RetryHostPredicate *envoy_config_route_v3_RetryPolicy_RetryHostPredicate_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_route_v3_RetryPolicy_RetryHostPredicate *ret = envoy_config_route_v3_RetryPolicy_RetryHostPredicate_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_route_v3_RetryPolicy_RetryHostPredicate_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_route_v3_RetryPolicy_RetryHostPredicate_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_route_v3_RetryPolicy_RetryHostPredicate_serialize(const envoy_config_route_v3_RetryPolicy_RetryHostPredicate *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_route_v3_RetryPolicy_RetryHostPredicate_msginit, arena, len);
@@ -2495,13 +2660,19 @@ UPB_INLINE envoy_config_route_v3_RetryPolicy_RetryBackOff *envoy_config_route_v3
 UPB_INLINE envoy_config_route_v3_RetryPolicy_RetryBackOff *envoy_config_route_v3_RetryPolicy_RetryBackOff_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_route_v3_RetryPolicy_RetryBackOff *ret = envoy_config_route_v3_RetryPolicy_RetryBackOff_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_route_v3_RetryPolicy_RetryBackOff_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_route_v3_RetryPolicy_RetryBackOff_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_route_v3_RetryPolicy_RetryBackOff *envoy_config_route_v3_RetryPolicy_RetryBackOff_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_route_v3_RetryPolicy_RetryBackOff *ret = envoy_config_route_v3_RetryPolicy_RetryBackOff_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_route_v3_RetryPolicy_RetryBackOff_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_route_v3_RetryPolicy_RetryBackOff_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_route_v3_RetryPolicy_RetryBackOff_serialize(const envoy_config_route_v3_RetryPolicy_RetryBackOff *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_route_v3_RetryPolicy_RetryBackOff_msginit, arena, len);
@@ -2547,13 +2718,19 @@ UPB_INLINE envoy_config_route_v3_RetryPolicy_ResetHeader *envoy_config_route_v3_
 UPB_INLINE envoy_config_route_v3_RetryPolicy_ResetHeader *envoy_config_route_v3_RetryPolicy_ResetHeader_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_route_v3_RetryPolicy_ResetHeader *ret = envoy_config_route_v3_RetryPolicy_ResetHeader_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_route_v3_RetryPolicy_ResetHeader_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_route_v3_RetryPolicy_ResetHeader_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_route_v3_RetryPolicy_ResetHeader *envoy_config_route_v3_RetryPolicy_ResetHeader_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_route_v3_RetryPolicy_ResetHeader *ret = envoy_config_route_v3_RetryPolicy_ResetHeader_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_route_v3_RetryPolicy_ResetHeader_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_route_v3_RetryPolicy_ResetHeader_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_route_v3_RetryPolicy_ResetHeader_serialize(const envoy_config_route_v3_RetryPolicy_ResetHeader *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_route_v3_RetryPolicy_ResetHeader_msginit, arena, len);
@@ -2577,13 +2754,19 @@ UPB_INLINE envoy_config_route_v3_RetryPolicy_RateLimitedRetryBackOff *envoy_conf
 UPB_INLINE envoy_config_route_v3_RetryPolicy_RateLimitedRetryBackOff *envoy_config_route_v3_RetryPolicy_RateLimitedRetryBackOff_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_route_v3_RetryPolicy_RateLimitedRetryBackOff *ret = envoy_config_route_v3_RetryPolicy_RateLimitedRetryBackOff_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_route_v3_RetryPolicy_RateLimitedRetryBackOff_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_route_v3_RetryPolicy_RateLimitedRetryBackOff_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_route_v3_RetryPolicy_RateLimitedRetryBackOff *envoy_config_route_v3_RetryPolicy_RateLimitedRetryBackOff_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_route_v3_RetryPolicy_RateLimitedRetryBackOff *ret = envoy_config_route_v3_RetryPolicy_RateLimitedRetryBackOff_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_route_v3_RetryPolicy_RateLimitedRetryBackOff_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_route_v3_RetryPolicy_RateLimitedRetryBackOff_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_route_v3_RetryPolicy_RateLimitedRetryBackOff_serialize(const envoy_config_route_v3_RetryPolicy_RateLimitedRetryBackOff *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_route_v3_RetryPolicy_RateLimitedRetryBackOff_msginit, arena, len);
@@ -2629,13 +2812,19 @@ UPB_INLINE envoy_config_route_v3_HedgePolicy *envoy_config_route_v3_HedgePolicy_
 UPB_INLINE envoy_config_route_v3_HedgePolicy *envoy_config_route_v3_HedgePolicy_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_route_v3_HedgePolicy *ret = envoy_config_route_v3_HedgePolicy_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_route_v3_HedgePolicy_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_route_v3_HedgePolicy_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_route_v3_HedgePolicy *envoy_config_route_v3_HedgePolicy_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_route_v3_HedgePolicy *ret = envoy_config_route_v3_HedgePolicy_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_route_v3_HedgePolicy_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_route_v3_HedgePolicy_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_route_v3_HedgePolicy_serialize(const envoy_config_route_v3_HedgePolicy *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_route_v3_HedgePolicy_msginit, arena, len);
@@ -2685,13 +2874,19 @@ UPB_INLINE envoy_config_route_v3_RedirectAction *envoy_config_route_v3_RedirectA
 UPB_INLINE envoy_config_route_v3_RedirectAction *envoy_config_route_v3_RedirectAction_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_route_v3_RedirectAction *ret = envoy_config_route_v3_RedirectAction_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_route_v3_RedirectAction_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_route_v3_RedirectAction_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_route_v3_RedirectAction *envoy_config_route_v3_RedirectAction_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_route_v3_RedirectAction *ret = envoy_config_route_v3_RedirectAction_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_route_v3_RedirectAction_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_route_v3_RedirectAction_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_route_v3_RedirectAction_serialize(const envoy_config_route_v3_RedirectAction *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_route_v3_RedirectAction_msginit, arena, len);
@@ -2772,13 +2967,19 @@ UPB_INLINE envoy_config_route_v3_DirectResponseAction *envoy_config_route_v3_Dir
 UPB_INLINE envoy_config_route_v3_DirectResponseAction *envoy_config_route_v3_DirectResponseAction_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_route_v3_DirectResponseAction *ret = envoy_config_route_v3_DirectResponseAction_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_route_v3_DirectResponseAction_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_route_v3_DirectResponseAction_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_route_v3_DirectResponseAction *envoy_config_route_v3_DirectResponseAction_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_route_v3_DirectResponseAction *ret = envoy_config_route_v3_DirectResponseAction_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_route_v3_DirectResponseAction_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_route_v3_DirectResponseAction_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_route_v3_DirectResponseAction_serialize(const envoy_config_route_v3_DirectResponseAction *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_route_v3_DirectResponseAction_msginit, arena, len);
@@ -2813,13 +3014,19 @@ UPB_INLINE envoy_config_route_v3_NonForwardingAction *envoy_config_route_v3_NonF
 UPB_INLINE envoy_config_route_v3_NonForwardingAction *envoy_config_route_v3_NonForwardingAction_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_route_v3_NonForwardingAction *ret = envoy_config_route_v3_NonForwardingAction_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_route_v3_NonForwardingAction_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_route_v3_NonForwardingAction_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_route_v3_NonForwardingAction *envoy_config_route_v3_NonForwardingAction_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_route_v3_NonForwardingAction *ret = envoy_config_route_v3_NonForwardingAction_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_route_v3_NonForwardingAction_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_route_v3_NonForwardingAction_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_route_v3_NonForwardingAction_serialize(const envoy_config_route_v3_NonForwardingAction *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_route_v3_NonForwardingAction_msginit, arena, len);
@@ -2835,13 +3042,19 @@ UPB_INLINE envoy_config_route_v3_Decorator *envoy_config_route_v3_Decorator_new(
 UPB_INLINE envoy_config_route_v3_Decorator *envoy_config_route_v3_Decorator_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_route_v3_Decorator *ret = envoy_config_route_v3_Decorator_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_route_v3_Decorator_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_route_v3_Decorator_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_route_v3_Decorator *envoy_config_route_v3_Decorator_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_route_v3_Decorator *ret = envoy_config_route_v3_Decorator_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_route_v3_Decorator_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_route_v3_Decorator_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_route_v3_Decorator_serialize(const envoy_config_route_v3_Decorator *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_route_v3_Decorator_msginit, arena, len);
@@ -2876,13 +3089,19 @@ UPB_INLINE envoy_config_route_v3_Tracing *envoy_config_route_v3_Tracing_new(upb_
 UPB_INLINE envoy_config_route_v3_Tracing *envoy_config_route_v3_Tracing_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_route_v3_Tracing *ret = envoy_config_route_v3_Tracing_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_route_v3_Tracing_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_route_v3_Tracing_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_route_v3_Tracing *envoy_config_route_v3_Tracing_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_route_v3_Tracing *ret = envoy_config_route_v3_Tracing_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_route_v3_Tracing_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_route_v3_Tracing_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_route_v3_Tracing_serialize(const envoy_config_route_v3_Tracing *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_route_v3_Tracing_msginit, arena, len);
@@ -2958,13 +3177,19 @@ UPB_INLINE envoy_config_route_v3_VirtualCluster *envoy_config_route_v3_VirtualCl
 UPB_INLINE envoy_config_route_v3_VirtualCluster *envoy_config_route_v3_VirtualCluster_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_route_v3_VirtualCluster *ret = envoy_config_route_v3_VirtualCluster_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_route_v3_VirtualCluster_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_route_v3_VirtualCluster_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_route_v3_VirtualCluster *envoy_config_route_v3_VirtualCluster_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_route_v3_VirtualCluster *ret = envoy_config_route_v3_VirtualCluster_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_route_v3_VirtualCluster_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_route_v3_VirtualCluster_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_route_v3_VirtualCluster_serialize(const envoy_config_route_v3_VirtualCluster *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_route_v3_VirtualCluster_msginit, arena, len);
@@ -2999,13 +3224,19 @@ UPB_INLINE envoy_config_route_v3_RateLimit *envoy_config_route_v3_RateLimit_new(
 UPB_INLINE envoy_config_route_v3_RateLimit *envoy_config_route_v3_RateLimit_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_route_v3_RateLimit *ret = envoy_config_route_v3_RateLimit_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_route_v3_RateLimit_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_route_v3_RateLimit_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_route_v3_RateLimit *envoy_config_route_v3_RateLimit_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_route_v3_RateLimit *ret = envoy_config_route_v3_RateLimit_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_route_v3_RateLimit_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_route_v3_RateLimit_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_route_v3_RateLimit_serialize(const envoy_config_route_v3_RateLimit *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_route_v3_RateLimit_msginit, arena, len);
@@ -3070,13 +3301,19 @@ UPB_INLINE envoy_config_route_v3_RateLimit_Action *envoy_config_route_v3_RateLim
 UPB_INLINE envoy_config_route_v3_RateLimit_Action *envoy_config_route_v3_RateLimit_Action_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_route_v3_RateLimit_Action *ret = envoy_config_route_v3_RateLimit_Action_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_route_v3_RateLimit_Action_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_route_v3_RateLimit_Action_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_route_v3_RateLimit_Action *envoy_config_route_v3_RateLimit_Action_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_route_v3_RateLimit_Action *ret = envoy_config_route_v3_RateLimit_Action_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_route_v3_RateLimit_Action_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_route_v3_RateLimit_Action_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_route_v3_RateLimit_Action_serialize(const envoy_config_route_v3_RateLimit_Action *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_route_v3_RateLimit_Action_msginit, arena, len);
@@ -3232,13 +3469,19 @@ UPB_INLINE envoy_config_route_v3_RateLimit_Action_SourceCluster *envoy_config_ro
 UPB_INLINE envoy_config_route_v3_RateLimit_Action_SourceCluster *envoy_config_route_v3_RateLimit_Action_SourceCluster_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_route_v3_RateLimit_Action_SourceCluster *ret = envoy_config_route_v3_RateLimit_Action_SourceCluster_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_route_v3_RateLimit_Action_SourceCluster_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_route_v3_RateLimit_Action_SourceCluster_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_route_v3_RateLimit_Action_SourceCluster *envoy_config_route_v3_RateLimit_Action_SourceCluster_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_route_v3_RateLimit_Action_SourceCluster *ret = envoy_config_route_v3_RateLimit_Action_SourceCluster_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_route_v3_RateLimit_Action_SourceCluster_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_route_v3_RateLimit_Action_SourceCluster_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_route_v3_RateLimit_Action_SourceCluster_serialize(const envoy_config_route_v3_RateLimit_Action_SourceCluster *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_route_v3_RateLimit_Action_SourceCluster_msginit, arena, len);
@@ -3254,13 +3497,19 @@ UPB_INLINE envoy_config_route_v3_RateLimit_Action_DestinationCluster *envoy_conf
 UPB_INLINE envoy_config_route_v3_RateLimit_Action_DestinationCluster *envoy_config_route_v3_RateLimit_Action_DestinationCluster_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_route_v3_RateLimit_Action_DestinationCluster *ret = envoy_config_route_v3_RateLimit_Action_DestinationCluster_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_route_v3_RateLimit_Action_DestinationCluster_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_route_v3_RateLimit_Action_DestinationCluster_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_route_v3_RateLimit_Action_DestinationCluster *envoy_config_route_v3_RateLimit_Action_DestinationCluster_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_route_v3_RateLimit_Action_DestinationCluster *ret = envoy_config_route_v3_RateLimit_Action_DestinationCluster_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_route_v3_RateLimit_Action_DestinationCluster_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_route_v3_RateLimit_Action_DestinationCluster_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_route_v3_RateLimit_Action_DestinationCluster_serialize(const envoy_config_route_v3_RateLimit_Action_DestinationCluster *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_route_v3_RateLimit_Action_DestinationCluster_msginit, arena, len);
@@ -3276,13 +3525,19 @@ UPB_INLINE envoy_config_route_v3_RateLimit_Action_RequestHeaders *envoy_config_r
 UPB_INLINE envoy_config_route_v3_RateLimit_Action_RequestHeaders *envoy_config_route_v3_RateLimit_Action_RequestHeaders_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_route_v3_RateLimit_Action_RequestHeaders *ret = envoy_config_route_v3_RateLimit_Action_RequestHeaders_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_route_v3_RateLimit_Action_RequestHeaders_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_route_v3_RateLimit_Action_RequestHeaders_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_route_v3_RateLimit_Action_RequestHeaders *envoy_config_route_v3_RateLimit_Action_RequestHeaders_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_route_v3_RateLimit_Action_RequestHeaders *ret = envoy_config_route_v3_RateLimit_Action_RequestHeaders_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_route_v3_RateLimit_Action_RequestHeaders_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_route_v3_RateLimit_Action_RequestHeaders_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_route_v3_RateLimit_Action_RequestHeaders_serialize(const envoy_config_route_v3_RateLimit_Action_RequestHeaders *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_route_v3_RateLimit_Action_RequestHeaders_msginit, arena, len);
@@ -3310,13 +3565,19 @@ UPB_INLINE envoy_config_route_v3_RateLimit_Action_RemoteAddress *envoy_config_ro
 UPB_INLINE envoy_config_route_v3_RateLimit_Action_RemoteAddress *envoy_config_route_v3_RateLimit_Action_RemoteAddress_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_route_v3_RateLimit_Action_RemoteAddress *ret = envoy_config_route_v3_RateLimit_Action_RemoteAddress_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_route_v3_RateLimit_Action_RemoteAddress_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_route_v3_RateLimit_Action_RemoteAddress_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_route_v3_RateLimit_Action_RemoteAddress *envoy_config_route_v3_RateLimit_Action_RemoteAddress_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_route_v3_RateLimit_Action_RemoteAddress *ret = envoy_config_route_v3_RateLimit_Action_RemoteAddress_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_route_v3_RateLimit_Action_RemoteAddress_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_route_v3_RateLimit_Action_RemoteAddress_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_route_v3_RateLimit_Action_RemoteAddress_serialize(const envoy_config_route_v3_RateLimit_Action_RemoteAddress *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_route_v3_RateLimit_Action_RemoteAddress_msginit, arena, len);
@@ -3332,13 +3593,19 @@ UPB_INLINE envoy_config_route_v3_RateLimit_Action_GenericKey *envoy_config_route
 UPB_INLINE envoy_config_route_v3_RateLimit_Action_GenericKey *envoy_config_route_v3_RateLimit_Action_GenericKey_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_route_v3_RateLimit_Action_GenericKey *ret = envoy_config_route_v3_RateLimit_Action_GenericKey_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_route_v3_RateLimit_Action_GenericKey_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_route_v3_RateLimit_Action_GenericKey_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_route_v3_RateLimit_Action_GenericKey *envoy_config_route_v3_RateLimit_Action_GenericKey_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_route_v3_RateLimit_Action_GenericKey *ret = envoy_config_route_v3_RateLimit_Action_GenericKey_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_route_v3_RateLimit_Action_GenericKey_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_route_v3_RateLimit_Action_GenericKey_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_route_v3_RateLimit_Action_GenericKey_serialize(const envoy_config_route_v3_RateLimit_Action_GenericKey *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_route_v3_RateLimit_Action_GenericKey_msginit, arena, len);
@@ -3362,13 +3629,19 @@ UPB_INLINE envoy_config_route_v3_RateLimit_Action_HeaderValueMatch *envoy_config
 UPB_INLINE envoy_config_route_v3_RateLimit_Action_HeaderValueMatch *envoy_config_route_v3_RateLimit_Action_HeaderValueMatch_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_route_v3_RateLimit_Action_HeaderValueMatch *ret = envoy_config_route_v3_RateLimit_Action_HeaderValueMatch_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_route_v3_RateLimit_Action_HeaderValueMatch_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_route_v3_RateLimit_Action_HeaderValueMatch_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_route_v3_RateLimit_Action_HeaderValueMatch *envoy_config_route_v3_RateLimit_Action_HeaderValueMatch_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_route_v3_RateLimit_Action_HeaderValueMatch *ret = envoy_config_route_v3_RateLimit_Action_HeaderValueMatch_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_route_v3_RateLimit_Action_HeaderValueMatch_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_route_v3_RateLimit_Action_HeaderValueMatch_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_route_v3_RateLimit_Action_HeaderValueMatch_serialize(const envoy_config_route_v3_RateLimit_Action_HeaderValueMatch *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_route_v3_RateLimit_Action_HeaderValueMatch_msginit, arena, len);
@@ -3418,13 +3691,19 @@ UPB_INLINE envoy_config_route_v3_RateLimit_Action_DynamicMetaData *envoy_config_
 UPB_INLINE envoy_config_route_v3_RateLimit_Action_DynamicMetaData *envoy_config_route_v3_RateLimit_Action_DynamicMetaData_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_route_v3_RateLimit_Action_DynamicMetaData *ret = envoy_config_route_v3_RateLimit_Action_DynamicMetaData_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_route_v3_RateLimit_Action_DynamicMetaData_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_route_v3_RateLimit_Action_DynamicMetaData_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_route_v3_RateLimit_Action_DynamicMetaData *envoy_config_route_v3_RateLimit_Action_DynamicMetaData_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_route_v3_RateLimit_Action_DynamicMetaData *ret = envoy_config_route_v3_RateLimit_Action_DynamicMetaData_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_route_v3_RateLimit_Action_DynamicMetaData_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_route_v3_RateLimit_Action_DynamicMetaData_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_route_v3_RateLimit_Action_DynamicMetaData_serialize(const envoy_config_route_v3_RateLimit_Action_DynamicMetaData *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_route_v3_RateLimit_Action_DynamicMetaData_msginit, arena, len);
@@ -3463,13 +3742,19 @@ UPB_INLINE envoy_config_route_v3_RateLimit_Action_MetaData *envoy_config_route_v
 UPB_INLINE envoy_config_route_v3_RateLimit_Action_MetaData *envoy_config_route_v3_RateLimit_Action_MetaData_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_route_v3_RateLimit_Action_MetaData *ret = envoy_config_route_v3_RateLimit_Action_MetaData_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_route_v3_RateLimit_Action_MetaData_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_route_v3_RateLimit_Action_MetaData_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_route_v3_RateLimit_Action_MetaData *envoy_config_route_v3_RateLimit_Action_MetaData_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_route_v3_RateLimit_Action_MetaData *ret = envoy_config_route_v3_RateLimit_Action_MetaData_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_route_v3_RateLimit_Action_MetaData_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_route_v3_RateLimit_Action_MetaData_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_route_v3_RateLimit_Action_MetaData_serialize(const envoy_config_route_v3_RateLimit_Action_MetaData *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_route_v3_RateLimit_Action_MetaData_msginit, arena, len);
@@ -3512,13 +3797,19 @@ UPB_INLINE envoy_config_route_v3_RateLimit_Override *envoy_config_route_v3_RateL
 UPB_INLINE envoy_config_route_v3_RateLimit_Override *envoy_config_route_v3_RateLimit_Override_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_route_v3_RateLimit_Override *ret = envoy_config_route_v3_RateLimit_Override_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_route_v3_RateLimit_Override_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_route_v3_RateLimit_Override_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_route_v3_RateLimit_Override *envoy_config_route_v3_RateLimit_Override_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_route_v3_RateLimit_Override *ret = envoy_config_route_v3_RateLimit_Override_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_route_v3_RateLimit_Override_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_route_v3_RateLimit_Override_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_route_v3_RateLimit_Override_serialize(const envoy_config_route_v3_RateLimit_Override *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_route_v3_RateLimit_Override_msginit, arena, len);
@@ -3554,13 +3845,19 @@ UPB_INLINE envoy_config_route_v3_RateLimit_Override_DynamicMetadata *envoy_confi
 UPB_INLINE envoy_config_route_v3_RateLimit_Override_DynamicMetadata *envoy_config_route_v3_RateLimit_Override_DynamicMetadata_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_route_v3_RateLimit_Override_DynamicMetadata *ret = envoy_config_route_v3_RateLimit_Override_DynamicMetadata_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_route_v3_RateLimit_Override_DynamicMetadata_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_route_v3_RateLimit_Override_DynamicMetadata_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_route_v3_RateLimit_Override_DynamicMetadata *envoy_config_route_v3_RateLimit_Override_DynamicMetadata_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_route_v3_RateLimit_Override_DynamicMetadata *ret = envoy_config_route_v3_RateLimit_Override_DynamicMetadata_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_route_v3_RateLimit_Override_DynamicMetadata_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_route_v3_RateLimit_Override_DynamicMetadata_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_route_v3_RateLimit_Override_DynamicMetadata_serialize(const envoy_config_route_v3_RateLimit_Override_DynamicMetadata *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_route_v3_RateLimit_Override_DynamicMetadata_msginit, arena, len);
@@ -3591,13 +3888,19 @@ UPB_INLINE envoy_config_route_v3_HeaderMatcher *envoy_config_route_v3_HeaderMatc
 UPB_INLINE envoy_config_route_v3_HeaderMatcher *envoy_config_route_v3_HeaderMatcher_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_route_v3_HeaderMatcher *ret = envoy_config_route_v3_HeaderMatcher_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_route_v3_HeaderMatcher_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_route_v3_HeaderMatcher_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_route_v3_HeaderMatcher *envoy_config_route_v3_HeaderMatcher_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_route_v3_HeaderMatcher *ret = envoy_config_route_v3_HeaderMatcher_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_route_v3_HeaderMatcher_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_route_v3_HeaderMatcher_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_route_v3_HeaderMatcher_serialize(const envoy_config_route_v3_HeaderMatcher *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_route_v3_HeaderMatcher_msginit, arena, len);
@@ -3701,13 +4004,19 @@ UPB_INLINE envoy_config_route_v3_QueryParameterMatcher *envoy_config_route_v3_Qu
 UPB_INLINE envoy_config_route_v3_QueryParameterMatcher *envoy_config_route_v3_QueryParameterMatcher_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_route_v3_QueryParameterMatcher *ret = envoy_config_route_v3_QueryParameterMatcher_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_route_v3_QueryParameterMatcher_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_route_v3_QueryParameterMatcher_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_route_v3_QueryParameterMatcher *envoy_config_route_v3_QueryParameterMatcher_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_route_v3_QueryParameterMatcher *ret = envoy_config_route_v3_QueryParameterMatcher_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_route_v3_QueryParameterMatcher_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_route_v3_QueryParameterMatcher_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_route_v3_QueryParameterMatcher_serialize(const envoy_config_route_v3_QueryParameterMatcher *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_route_v3_QueryParameterMatcher_msginit, arena, len);
@@ -3753,13 +4062,19 @@ UPB_INLINE envoy_config_route_v3_InternalRedirectPolicy *envoy_config_route_v3_I
 UPB_INLINE envoy_config_route_v3_InternalRedirectPolicy *envoy_config_route_v3_InternalRedirectPolicy_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_route_v3_InternalRedirectPolicy *ret = envoy_config_route_v3_InternalRedirectPolicy_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_route_v3_InternalRedirectPolicy_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_route_v3_InternalRedirectPolicy_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_route_v3_InternalRedirectPolicy *envoy_config_route_v3_InternalRedirectPolicy_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_route_v3_InternalRedirectPolicy *ret = envoy_config_route_v3_InternalRedirectPolicy_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_route_v3_InternalRedirectPolicy_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_route_v3_InternalRedirectPolicy_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_route_v3_InternalRedirectPolicy_serialize(const envoy_config_route_v3_InternalRedirectPolicy *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_route_v3_InternalRedirectPolicy_msginit, arena, len);
@@ -3820,13 +4135,19 @@ UPB_INLINE envoy_config_route_v3_FilterConfig *envoy_config_route_v3_FilterConfi
 UPB_INLINE envoy_config_route_v3_FilterConfig *envoy_config_route_v3_FilterConfig_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_route_v3_FilterConfig *ret = envoy_config_route_v3_FilterConfig_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_route_v3_FilterConfig_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_route_v3_FilterConfig_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_route_v3_FilterConfig *envoy_config_route_v3_FilterConfig_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_route_v3_FilterConfig *ret = envoy_config_route_v3_FilterConfig_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_route_v3_FilterConfig_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_route_v3_FilterConfig_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_route_v3_FilterConfig_serialize(const envoy_config_route_v3_FilterConfig *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_route_v3_FilterConfig_msginit, arena, len);
index 301441e..6553b0d 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/config/route/v3/scoped_route.upb.h"
 #include "udpa/annotations/status.upb.h"
 #include "udpa/annotations/versioning.upb.h"
@@ -20,16 +20,16 @@ static const upb_msglayout *const envoy_config_route_v3_ScopedRouteConfiguration
 };
 
 static const upb_msglayout_field envoy_config_route_v3_ScopedRouteConfiguration__fields[4] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(12, 24), 0, 0, 9, 1},
-  {3, UPB_SIZE(20, 40), 1, 0, 11, 1},
-  {4, UPB_SIZE(1, 1), 0, 0, 8, 1},
+  {1, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(12, 24), 0, 0, 9, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(20, 40), 1, 0, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(1, 1), 0, 0, 8, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_route_v3_ScopedRouteConfiguration_msginit = {
   &envoy_config_route_v3_ScopedRouteConfiguration_submsgs[0],
   &envoy_config_route_v3_ScopedRouteConfiguration__fields[0],
-  UPB_SIZE(24, 48), 4, false, 255,
+  UPB_SIZE(24, 48), 4, false, 4, 255,
 };
 
 static const upb_msglayout *const envoy_config_route_v3_ScopedRouteConfiguration_Key_submsgs[1] = {
@@ -37,23 +37,23 @@ static const upb_msglayout *const envoy_config_route_v3_ScopedRouteConfiguration
 };
 
 static const upb_msglayout_field envoy_config_route_v3_ScopedRouteConfiguration_Key__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 11, 3},
+  {1, UPB_SIZE(0, 0), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout envoy_config_route_v3_ScopedRouteConfiguration_Key_msginit = {
   &envoy_config_route_v3_ScopedRouteConfiguration_Key_submsgs[0],
   &envoy_config_route_v3_ScopedRouteConfiguration_Key__fields[0],
-  UPB_SIZE(8, 8), 1, false, 255,
+  UPB_SIZE(8, 8), 1, false, 1, 255,
 };
 
 static const upb_msglayout_field envoy_config_route_v3_ScopedRouteConfiguration_Key_Fragment__fields[1] = {
-  {1, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 9, 1},
+  {1, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_route_v3_ScopedRouteConfiguration_Key_Fragment_msginit = {
   NULL,
   &envoy_config_route_v3_ScopedRouteConfiguration_Key_Fragment__fields[0],
-  UPB_SIZE(16, 32), 1, false, 255,
+  UPB_SIZE(16, 32), 1, false, 1, 255,
 };
 
 #include "upb/port_undef.inc"
index 72d1622..83b7656 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_CONFIG_ROUTE_V3_SCOPED_ROUTE_PROTO_UPB_H_
 #define ENVOY_CONFIG_ROUTE_V3_SCOPED_ROUTE_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -39,13 +39,19 @@ UPB_INLINE envoy_config_route_v3_ScopedRouteConfiguration *envoy_config_route_v3
 UPB_INLINE envoy_config_route_v3_ScopedRouteConfiguration *envoy_config_route_v3_ScopedRouteConfiguration_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_route_v3_ScopedRouteConfiguration *ret = envoy_config_route_v3_ScopedRouteConfiguration_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_route_v3_ScopedRouteConfiguration_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_route_v3_ScopedRouteConfiguration_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_route_v3_ScopedRouteConfiguration *envoy_config_route_v3_ScopedRouteConfiguration_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_route_v3_ScopedRouteConfiguration *ret = envoy_config_route_v3_ScopedRouteConfiguration_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_route_v3_ScopedRouteConfiguration_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_route_v3_ScopedRouteConfiguration_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_route_v3_ScopedRouteConfiguration_serialize(const envoy_config_route_v3_ScopedRouteConfiguration *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_route_v3_ScopedRouteConfiguration_msginit, arena, len);
@@ -88,13 +94,19 @@ UPB_INLINE envoy_config_route_v3_ScopedRouteConfiguration_Key *envoy_config_rout
 UPB_INLINE envoy_config_route_v3_ScopedRouteConfiguration_Key *envoy_config_route_v3_ScopedRouteConfiguration_Key_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_route_v3_ScopedRouteConfiguration_Key *ret = envoy_config_route_v3_ScopedRouteConfiguration_Key_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_route_v3_ScopedRouteConfiguration_Key_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_route_v3_ScopedRouteConfiguration_Key_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_route_v3_ScopedRouteConfiguration_Key *envoy_config_route_v3_ScopedRouteConfiguration_Key_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_route_v3_ScopedRouteConfiguration_Key *ret = envoy_config_route_v3_ScopedRouteConfiguration_Key_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_route_v3_ScopedRouteConfiguration_Key_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_route_v3_ScopedRouteConfiguration_Key_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_route_v3_ScopedRouteConfiguration_Key_serialize(const envoy_config_route_v3_ScopedRouteConfiguration_Key *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_route_v3_ScopedRouteConfiguration_Key_msginit, arena, len);
@@ -125,13 +137,19 @@ UPB_INLINE envoy_config_route_v3_ScopedRouteConfiguration_Key_Fragment *envoy_co
 UPB_INLINE envoy_config_route_v3_ScopedRouteConfiguration_Key_Fragment *envoy_config_route_v3_ScopedRouteConfiguration_Key_Fragment_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_route_v3_ScopedRouteConfiguration_Key_Fragment *ret = envoy_config_route_v3_ScopedRouteConfiguration_Key_Fragment_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_route_v3_ScopedRouteConfiguration_Key_Fragment_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_route_v3_ScopedRouteConfiguration_Key_Fragment_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_route_v3_ScopedRouteConfiguration_Key_Fragment *envoy_config_route_v3_ScopedRouteConfiguration_Key_Fragment_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_route_v3_ScopedRouteConfiguration_Key_Fragment *ret = envoy_config_route_v3_ScopedRouteConfiguration_Key_Fragment_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_route_v3_ScopedRouteConfiguration_Key_Fragment_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_route_v3_ScopedRouteConfiguration_Key_Fragment_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_route_v3_ScopedRouteConfiguration_Key_Fragment_serialize(const envoy_config_route_v3_ScopedRouteConfiguration_Key_Fragment *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_route_v3_ScopedRouteConfiguration_Key_Fragment_msginit, arena, len);
index 52cb6b7..a22b939 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/config/trace/v3/http_tracer.upb.h"
 #include "google/protobuf/any.upb.h"
 #include "udpa/annotations/status.upb.h"
@@ -21,13 +21,13 @@ static const upb_msglayout *const envoy_config_trace_v3_Tracing_submsgs[1] = {
 };
 
 static const upb_msglayout_field envoy_config_trace_v3_Tracing__fields[1] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_trace_v3_Tracing_msginit = {
   &envoy_config_trace_v3_Tracing_submsgs[0],
   &envoy_config_trace_v3_Tracing__fields[0],
-  UPB_SIZE(8, 16), 1, false, 255,
+  UPB_SIZE(8, 16), 1, false, 1, 255,
 };
 
 static const upb_msglayout *const envoy_config_trace_v3_Tracing_Http_submsgs[1] = {
@@ -35,14 +35,14 @@ static const upb_msglayout *const envoy_config_trace_v3_Tracing_Http_submsgs[1]
 };
 
 static const upb_msglayout_field envoy_config_trace_v3_Tracing_Http__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {3, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 0, 11, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_config_trace_v3_Tracing_Http_msginit = {
   &envoy_config_trace_v3_Tracing_Http_submsgs[0],
   &envoy_config_trace_v3_Tracing_Http__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 1, 255,
 };
 
 #include "upb/port_undef.inc"
index 21240fa..fdba74a 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_CONFIG_TRACE_V3_HTTP_TRACER_PROTO_UPB_H_
 #define ENVOY_CONFIG_TRACE_V3_HTTP_TRACER_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -38,13 +38,19 @@ UPB_INLINE envoy_config_trace_v3_Tracing *envoy_config_trace_v3_Tracing_new(upb_
 UPB_INLINE envoy_config_trace_v3_Tracing *envoy_config_trace_v3_Tracing_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_trace_v3_Tracing *ret = envoy_config_trace_v3_Tracing_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_trace_v3_Tracing_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_trace_v3_Tracing_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_trace_v3_Tracing *envoy_config_trace_v3_Tracing_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_trace_v3_Tracing *ret = envoy_config_trace_v3_Tracing_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_trace_v3_Tracing_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_trace_v3_Tracing_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_trace_v3_Tracing_serialize(const envoy_config_trace_v3_Tracing *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_trace_v3_Tracing_msginit, arena, len);
@@ -75,13 +81,19 @@ UPB_INLINE envoy_config_trace_v3_Tracing_Http *envoy_config_trace_v3_Tracing_Htt
 UPB_INLINE envoy_config_trace_v3_Tracing_Http *envoy_config_trace_v3_Tracing_Http_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_config_trace_v3_Tracing_Http *ret = envoy_config_trace_v3_Tracing_Http_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_config_trace_v3_Tracing_Http_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_config_trace_v3_Tracing_Http_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_config_trace_v3_Tracing_Http *envoy_config_trace_v3_Tracing_Http_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_config_trace_v3_Tracing_Http *ret = envoy_config_trace_v3_Tracing_Http_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_config_trace_v3_Tracing_Http_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_config_trace_v3_Tracing_Http_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_config_trace_v3_Tracing_Http_serialize(const envoy_config_trace_v3_Tracing_Http *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_config_trace_v3_Tracing_Http_msginit, arena, len);
index 308e8b5..57a0f17 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/extensions/clusters/aggregate/v3/cluster.upb.h"
 #include "udpa/annotations/status.upb.h"
 #include "udpa/annotations/versioning.upb.h"
 #include "upb/port_def.inc"
 
 static const upb_msglayout_field envoy_extensions_clusters_aggregate_v3_ClusterConfig__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 3},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout envoy_extensions_clusters_aggregate_v3_ClusterConfig_msginit = {
   NULL,
   &envoy_extensions_clusters_aggregate_v3_ClusterConfig__fields[0],
-  UPB_SIZE(8, 8), 1, false, 255,
+  UPB_SIZE(8, 8), 1, false, 1, 255,
 };
 
 #include "upb/port_undef.inc"
index ffa4ccb..cb61c5b 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_EXTENSIONS_CLUSTERS_AGGREGATE_V3_CLUSTER_PROTO_UPB_H_
 #define ENVOY_EXTENSIONS_CLUSTERS_AGGREGATE_V3_CLUSTER_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -33,13 +33,19 @@ UPB_INLINE envoy_extensions_clusters_aggregate_v3_ClusterConfig *envoy_extension
 UPB_INLINE envoy_extensions_clusters_aggregate_v3_ClusterConfig *envoy_extensions_clusters_aggregate_v3_ClusterConfig_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_extensions_clusters_aggregate_v3_ClusterConfig *ret = envoy_extensions_clusters_aggregate_v3_ClusterConfig_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_extensions_clusters_aggregate_v3_ClusterConfig_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_extensions_clusters_aggregate_v3_ClusterConfig_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_extensions_clusters_aggregate_v3_ClusterConfig *envoy_extensions_clusters_aggregate_v3_ClusterConfig_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_extensions_clusters_aggregate_v3_ClusterConfig *ret = envoy_extensions_clusters_aggregate_v3_ClusterConfig_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_extensions_clusters_aggregate_v3_ClusterConfig_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_extensions_clusters_aggregate_v3_ClusterConfig_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_extensions_clusters_aggregate_v3_ClusterConfig_serialize(const envoy_extensions_clusters_aggregate_v3_ClusterConfig *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_extensions_clusters_aggregate_v3_ClusterConfig_msginit, arena, len);
index 5f92b8d..58e0ddf 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/extensions/filters/common/fault/v3/fault.upb.h"
 #include "envoy/type/v3/percent.upb.h"
 #include "google/protobuf/duration.upb.h"
@@ -24,21 +24,21 @@ static const upb_msglayout *const envoy_extensions_filters_common_fault_v3_Fault
 };
 
 static const upb_msglayout_field envoy_extensions_filters_common_fault_v3_FaultDelay__fields[3] = {
-  {3, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 2, 11, 1},
-  {4, UPB_SIZE(4, 8), 1, 1, 11, 1},
-  {5, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 0, 11, 1},
+  {3, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 2, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(4, 8), 1, 1, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_extensions_filters_common_fault_v3_FaultDelay_msginit = {
   &envoy_extensions_filters_common_fault_v3_FaultDelay_submsgs[0],
   &envoy_extensions_filters_common_fault_v3_FaultDelay__fields[0],
-  UPB_SIZE(16, 32), 3, false, 255,
+  UPB_SIZE(16, 32), 3, false, 0, 255,
 };
 
 const upb_msglayout envoy_extensions_filters_common_fault_v3_FaultDelay_HeaderDelay_msginit = {
   NULL,
   NULL,
-  UPB_SIZE(0, 0), 0, false, 255,
+  UPB_SIZE(0, 0), 0, false, 0, 255,
 };
 
 static const upb_msglayout *const envoy_extensions_filters_common_fault_v3_FaultRateLimit_submsgs[3] = {
@@ -48,31 +48,31 @@ static const upb_msglayout *const envoy_extensions_filters_common_fault_v3_Fault
 };
 
 static const upb_msglayout_field envoy_extensions_filters_common_fault_v3_FaultRateLimit__fields[3] = {
-  {1, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 0, 11, 1},
-  {2, UPB_SIZE(4, 8), 1, 2, 11, 1},
-  {3, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 1, 11, 1},
+  {1, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(4, 8), 1, 2, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 1, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_extensions_filters_common_fault_v3_FaultRateLimit_msginit = {
   &envoy_extensions_filters_common_fault_v3_FaultRateLimit_submsgs[0],
   &envoy_extensions_filters_common_fault_v3_FaultRateLimit__fields[0],
-  UPB_SIZE(16, 32), 3, false, 255,
+  UPB_SIZE(16, 32), 3, false, 3, 255,
 };
 
 static const upb_msglayout_field envoy_extensions_filters_common_fault_v3_FaultRateLimit_FixedLimit__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 4, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 4, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_extensions_filters_common_fault_v3_FaultRateLimit_FixedLimit_msginit = {
   NULL,
   &envoy_extensions_filters_common_fault_v3_FaultRateLimit_FixedLimit__fields[0],
-  UPB_SIZE(8, 8), 1, false, 255,
+  UPB_SIZE(8, 8), 1, false, 1, 255,
 };
 
 const upb_msglayout envoy_extensions_filters_common_fault_v3_FaultRateLimit_HeaderLimit_msginit = {
   NULL,
   NULL,
-  UPB_SIZE(0, 0), 0, false, 255,
+  UPB_SIZE(0, 0), 0, false, 0, 255,
 };
 
 #include "upb/port_undef.inc"
index 8c60917..d20e41a 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_EXTENSIONS_FILTERS_COMMON_FAULT_V3_FAULT_PROTO_UPB_H_
 #define ENVOY_EXTENSIONS_FILTERS_COMMON_FAULT_V3_FAULT_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -53,13 +53,19 @@ UPB_INLINE envoy_extensions_filters_common_fault_v3_FaultDelay *envoy_extensions
 UPB_INLINE envoy_extensions_filters_common_fault_v3_FaultDelay *envoy_extensions_filters_common_fault_v3_FaultDelay_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_extensions_filters_common_fault_v3_FaultDelay *ret = envoy_extensions_filters_common_fault_v3_FaultDelay_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_extensions_filters_common_fault_v3_FaultDelay_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_extensions_filters_common_fault_v3_FaultDelay_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_extensions_filters_common_fault_v3_FaultDelay *envoy_extensions_filters_common_fault_v3_FaultDelay_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_extensions_filters_common_fault_v3_FaultDelay *ret = envoy_extensions_filters_common_fault_v3_FaultDelay_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_extensions_filters_common_fault_v3_FaultDelay_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_extensions_filters_common_fault_v3_FaultDelay_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_extensions_filters_common_fault_v3_FaultDelay_serialize(const envoy_extensions_filters_common_fault_v3_FaultDelay *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_extensions_filters_common_fault_v3_FaultDelay_msginit, arena, len);
@@ -125,13 +131,19 @@ UPB_INLINE envoy_extensions_filters_common_fault_v3_FaultDelay_HeaderDelay *envo
 UPB_INLINE envoy_extensions_filters_common_fault_v3_FaultDelay_HeaderDelay *envoy_extensions_filters_common_fault_v3_FaultDelay_HeaderDelay_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_extensions_filters_common_fault_v3_FaultDelay_HeaderDelay *ret = envoy_extensions_filters_common_fault_v3_FaultDelay_HeaderDelay_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_extensions_filters_common_fault_v3_FaultDelay_HeaderDelay_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_extensions_filters_common_fault_v3_FaultDelay_HeaderDelay_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_extensions_filters_common_fault_v3_FaultDelay_HeaderDelay *envoy_extensions_filters_common_fault_v3_FaultDelay_HeaderDelay_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_extensions_filters_common_fault_v3_FaultDelay_HeaderDelay *ret = envoy_extensions_filters_common_fault_v3_FaultDelay_HeaderDelay_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_extensions_filters_common_fault_v3_FaultDelay_HeaderDelay_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_extensions_filters_common_fault_v3_FaultDelay_HeaderDelay_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_extensions_filters_common_fault_v3_FaultDelay_HeaderDelay_serialize(const envoy_extensions_filters_common_fault_v3_FaultDelay_HeaderDelay *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_extensions_filters_common_fault_v3_FaultDelay_HeaderDelay_msginit, arena, len);
@@ -147,13 +159,19 @@ UPB_INLINE envoy_extensions_filters_common_fault_v3_FaultRateLimit *envoy_extens
 UPB_INLINE envoy_extensions_filters_common_fault_v3_FaultRateLimit *envoy_extensions_filters_common_fault_v3_FaultRateLimit_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_extensions_filters_common_fault_v3_FaultRateLimit *ret = envoy_extensions_filters_common_fault_v3_FaultRateLimit_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_extensions_filters_common_fault_v3_FaultRateLimit_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_extensions_filters_common_fault_v3_FaultRateLimit_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_extensions_filters_common_fault_v3_FaultRateLimit *envoy_extensions_filters_common_fault_v3_FaultRateLimit_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_extensions_filters_common_fault_v3_FaultRateLimit *ret = envoy_extensions_filters_common_fault_v3_FaultRateLimit_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_extensions_filters_common_fault_v3_FaultRateLimit_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_extensions_filters_common_fault_v3_FaultRateLimit_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_extensions_filters_common_fault_v3_FaultRateLimit_serialize(const envoy_extensions_filters_common_fault_v3_FaultRateLimit *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_extensions_filters_common_fault_v3_FaultRateLimit_msginit, arena, len);
@@ -219,13 +237,19 @@ UPB_INLINE envoy_extensions_filters_common_fault_v3_FaultRateLimit_FixedLimit *e
 UPB_INLINE envoy_extensions_filters_common_fault_v3_FaultRateLimit_FixedLimit *envoy_extensions_filters_common_fault_v3_FaultRateLimit_FixedLimit_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_extensions_filters_common_fault_v3_FaultRateLimit_FixedLimit *ret = envoy_extensions_filters_common_fault_v3_FaultRateLimit_FixedLimit_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_extensions_filters_common_fault_v3_FaultRateLimit_FixedLimit_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_extensions_filters_common_fault_v3_FaultRateLimit_FixedLimit_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_extensions_filters_common_fault_v3_FaultRateLimit_FixedLimit *envoy_extensions_filters_common_fault_v3_FaultRateLimit_FixedLimit_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_extensions_filters_common_fault_v3_FaultRateLimit_FixedLimit *ret = envoy_extensions_filters_common_fault_v3_FaultRateLimit_FixedLimit_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_extensions_filters_common_fault_v3_FaultRateLimit_FixedLimit_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_extensions_filters_common_fault_v3_FaultRateLimit_FixedLimit_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_extensions_filters_common_fault_v3_FaultRateLimit_FixedLimit_serialize(const envoy_extensions_filters_common_fault_v3_FaultRateLimit_FixedLimit *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_extensions_filters_common_fault_v3_FaultRateLimit_FixedLimit_msginit, arena, len);
@@ -245,13 +269,19 @@ UPB_INLINE envoy_extensions_filters_common_fault_v3_FaultRateLimit_HeaderLimit *
 UPB_INLINE envoy_extensions_filters_common_fault_v3_FaultRateLimit_HeaderLimit *envoy_extensions_filters_common_fault_v3_FaultRateLimit_HeaderLimit_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_extensions_filters_common_fault_v3_FaultRateLimit_HeaderLimit *ret = envoy_extensions_filters_common_fault_v3_FaultRateLimit_HeaderLimit_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_extensions_filters_common_fault_v3_FaultRateLimit_HeaderLimit_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_extensions_filters_common_fault_v3_FaultRateLimit_HeaderLimit_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_extensions_filters_common_fault_v3_FaultRateLimit_HeaderLimit *envoy_extensions_filters_common_fault_v3_FaultRateLimit_HeaderLimit_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_extensions_filters_common_fault_v3_FaultRateLimit_HeaderLimit *ret = envoy_extensions_filters_common_fault_v3_FaultRateLimit_HeaderLimit_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_extensions_filters_common_fault_v3_FaultRateLimit_HeaderLimit_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_extensions_filters_common_fault_v3_FaultRateLimit_HeaderLimit_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_extensions_filters_common_fault_v3_FaultRateLimit_HeaderLimit_serialize(const envoy_extensions_filters_common_fault_v3_FaultRateLimit_HeaderLimit *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_extensions_filters_common_fault_v3_FaultRateLimit_HeaderLimit_msginit, arena, len);
index e363a2c..d2eaa40 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/extensions/filters/http/fault/v3/fault.upb.h"
 #include "envoy/config/route/v3/route_components.upb.h"
 #include "envoy/extensions/filters/common/fault/v3/fault.upb.h"
@@ -25,22 +25,22 @@ static const upb_msglayout *const envoy_extensions_filters_http_fault_v3_FaultAb
 };
 
 static const upb_msglayout_field envoy_extensions_filters_http_fault_v3_FaultAbort__fields[4] = {
-  {2, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 0, 13, 1},
-  {3, UPB_SIZE(4, 8), 1, 1, 11, 1},
-  {4, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 0, 11, 1},
-  {5, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 0, 13, 1},
+  {2, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 0, 13, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(4, 8), 1, 1, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 0, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 0, 13, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_extensions_filters_http_fault_v3_FaultAbort_msginit = {
   &envoy_extensions_filters_http_fault_v3_FaultAbort_submsgs[0],
   &envoy_extensions_filters_http_fault_v3_FaultAbort__fields[0],
-  UPB_SIZE(16, 32), 4, false, 255,
+  UPB_SIZE(16, 32), 4, false, 0, 255,
 };
 
 const upb_msglayout envoy_extensions_filters_http_fault_v3_FaultAbort_HeaderAbort_msginit = {
   NULL,
   NULL,
-  UPB_SIZE(0, 0), 0, false, 255,
+  UPB_SIZE(0, 0), 0, false, 0, 255,
 };
 
 static const upb_msglayout *const envoy_extensions_filters_http_fault_v3_HTTPFault_submsgs[5] = {
@@ -52,27 +52,27 @@ static const upb_msglayout *const envoy_extensions_filters_http_fault_v3_HTTPFau
 };
 
 static const upb_msglayout_field envoy_extensions_filters_http_fault_v3_HTTPFault__fields[15] = {
-  {1, UPB_SIZE(68, 136), 1, 1, 11, 1},
-  {2, UPB_SIZE(72, 144), 2, 3, 11, 1},
-  {3, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {4, UPB_SIZE(84, 168), 0, 0, 11, 3},
-  {5, UPB_SIZE(88, 176), 0, 0, 9, 3},
-  {6, UPB_SIZE(76, 152), 3, 4, 11, 1},
-  {7, UPB_SIZE(80, 160), 4, 2, 11, 1},
-  {8, UPB_SIZE(12, 24), 0, 0, 9, 1},
-  {9, UPB_SIZE(20, 40), 0, 0, 9, 1},
-  {10, UPB_SIZE(28, 56), 0, 0, 9, 1},
-  {11, UPB_SIZE(36, 72), 0, 0, 9, 1},
-  {12, UPB_SIZE(44, 88), 0, 0, 9, 1},
-  {13, UPB_SIZE(52, 104), 0, 0, 9, 1},
-  {14, UPB_SIZE(60, 120), 0, 0, 9, 1},
-  {15, UPB_SIZE(1, 1), 0, 0, 8, 1},
+  {1, UPB_SIZE(68, 136), 1, 1, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(72, 144), 2, 3, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(84, 168), 0, 0, 11, _UPB_MODE_ARRAY},
+  {5, UPB_SIZE(88, 176), 0, 0, 9, _UPB_MODE_ARRAY},
+  {6, UPB_SIZE(76, 152), 3, 4, 11, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(80, 160), 4, 2, 11, _UPB_MODE_SCALAR},
+  {8, UPB_SIZE(12, 24), 0, 0, 9, _UPB_MODE_SCALAR},
+  {9, UPB_SIZE(20, 40), 0, 0, 9, _UPB_MODE_SCALAR},
+  {10, UPB_SIZE(28, 56), 0, 0, 9, _UPB_MODE_SCALAR},
+  {11, UPB_SIZE(36, 72), 0, 0, 9, _UPB_MODE_SCALAR},
+  {12, UPB_SIZE(44, 88), 0, 0, 9, _UPB_MODE_SCALAR},
+  {13, UPB_SIZE(52, 104), 0, 0, 9, _UPB_MODE_SCALAR},
+  {14, UPB_SIZE(60, 120), 0, 0, 9, _UPB_MODE_SCALAR},
+  {15, UPB_SIZE(1, 1), 0, 0, 8, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_extensions_filters_http_fault_v3_HTTPFault_msginit = {
   &envoy_extensions_filters_http_fault_v3_HTTPFault_submsgs[0],
   &envoy_extensions_filters_http_fault_v3_HTTPFault__fields[0],
-  UPB_SIZE(96, 192), 15, false, 255,
+  UPB_SIZE(96, 192), 15, false, 15, 255,
 };
 
 #include "upb/port_undef.inc"
index 08e71d4..f5c45dc 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_EXTENSIONS_FILTERS_HTTP_FAULT_V3_FAULT_PROTO_UPB_H_
 #define ENVOY_EXTENSIONS_FILTERS_HTTP_FAULT_V3_FAULT_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -49,13 +49,19 @@ UPB_INLINE envoy_extensions_filters_http_fault_v3_FaultAbort *envoy_extensions_f
 UPB_INLINE envoy_extensions_filters_http_fault_v3_FaultAbort *envoy_extensions_filters_http_fault_v3_FaultAbort_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_extensions_filters_http_fault_v3_FaultAbort *ret = envoy_extensions_filters_http_fault_v3_FaultAbort_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_extensions_filters_http_fault_v3_FaultAbort_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_extensions_filters_http_fault_v3_FaultAbort_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_extensions_filters_http_fault_v3_FaultAbort *envoy_extensions_filters_http_fault_v3_FaultAbort_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_extensions_filters_http_fault_v3_FaultAbort *ret = envoy_extensions_filters_http_fault_v3_FaultAbort_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_extensions_filters_http_fault_v3_FaultAbort_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_extensions_filters_http_fault_v3_FaultAbort_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_extensions_filters_http_fault_v3_FaultAbort_serialize(const envoy_extensions_filters_http_fault_v3_FaultAbort *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_extensions_filters_http_fault_v3_FaultAbort_msginit, arena, len);
@@ -118,13 +124,19 @@ UPB_INLINE envoy_extensions_filters_http_fault_v3_FaultAbort_HeaderAbort *envoy_
 UPB_INLINE envoy_extensions_filters_http_fault_v3_FaultAbort_HeaderAbort *envoy_extensions_filters_http_fault_v3_FaultAbort_HeaderAbort_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_extensions_filters_http_fault_v3_FaultAbort_HeaderAbort *ret = envoy_extensions_filters_http_fault_v3_FaultAbort_HeaderAbort_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_extensions_filters_http_fault_v3_FaultAbort_HeaderAbort_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_extensions_filters_http_fault_v3_FaultAbort_HeaderAbort_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_extensions_filters_http_fault_v3_FaultAbort_HeaderAbort *envoy_extensions_filters_http_fault_v3_FaultAbort_HeaderAbort_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_extensions_filters_http_fault_v3_FaultAbort_HeaderAbort *ret = envoy_extensions_filters_http_fault_v3_FaultAbort_HeaderAbort_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_extensions_filters_http_fault_v3_FaultAbort_HeaderAbort_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_extensions_filters_http_fault_v3_FaultAbort_HeaderAbort_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_extensions_filters_http_fault_v3_FaultAbort_HeaderAbort_serialize(const envoy_extensions_filters_http_fault_v3_FaultAbort_HeaderAbort *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_extensions_filters_http_fault_v3_FaultAbort_HeaderAbort_msginit, arena, len);
@@ -140,13 +152,19 @@ UPB_INLINE envoy_extensions_filters_http_fault_v3_HTTPFault *envoy_extensions_fi
 UPB_INLINE envoy_extensions_filters_http_fault_v3_HTTPFault *envoy_extensions_filters_http_fault_v3_HTTPFault_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_extensions_filters_http_fault_v3_HTTPFault *ret = envoy_extensions_filters_http_fault_v3_HTTPFault_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_extensions_filters_http_fault_v3_HTTPFault_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_extensions_filters_http_fault_v3_HTTPFault_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_extensions_filters_http_fault_v3_HTTPFault *envoy_extensions_filters_http_fault_v3_HTTPFault_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_extensions_filters_http_fault_v3_HTTPFault *ret = envoy_extensions_filters_http_fault_v3_HTTPFault_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_extensions_filters_http_fault_v3_HTTPFault_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_extensions_filters_http_fault_v3_HTTPFault_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_extensions_filters_http_fault_v3_HTTPFault_serialize(const envoy_extensions_filters_http_fault_v3_HTTPFault *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_extensions_filters_http_fault_v3_HTTPFault_msginit, arena, len);
index b69c2cd..e8a1462 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/extensions/filters/http/router/v3/router.upb.h"
 #include "envoy/config/accesslog/v3/accesslog.upb.h"
 #include "google/protobuf/wrappers.upb.h"
@@ -23,19 +23,19 @@ static const upb_msglayout *const envoy_extensions_filters_http_router_v3_Router
 };
 
 static const upb_msglayout_field envoy_extensions_filters_http_router_v3_Router__fields[7] = {
-  {1, UPB_SIZE(8, 8), 1, 1, 11, 1},
-  {2, UPB_SIZE(1, 1), 0, 0, 8, 1},
-  {3, UPB_SIZE(12, 16), 0, 0, 11, 3},
-  {4, UPB_SIZE(2, 2), 0, 0, 8, 1},
-  {5, UPB_SIZE(16, 24), 0, 0, 9, 3},
-  {6, UPB_SIZE(3, 3), 0, 0, 8, 1},
-  {7, UPB_SIZE(4, 4), 0, 0, 8, 1},
+  {1, UPB_SIZE(8, 8), 1, 1, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(1, 1), 0, 0, 8, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(12, 16), 0, 0, 11, _UPB_MODE_ARRAY},
+  {4, UPB_SIZE(2, 2), 0, 0, 8, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(16, 24), 0, 0, 9, _UPB_MODE_ARRAY},
+  {6, UPB_SIZE(3, 3), 0, 0, 8, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(4, 4), 0, 0, 8, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_extensions_filters_http_router_v3_Router_msginit = {
   &envoy_extensions_filters_http_router_v3_Router_submsgs[0],
   &envoy_extensions_filters_http_router_v3_Router__fields[0],
-  UPB_SIZE(24, 32), 7, false, 255,
+  UPB_SIZE(24, 32), 7, false, 7, 255,
 };
 
 #include "upb/port_undef.inc"
index 7174b6c..57100fb 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_EXTENSIONS_FILTERS_HTTP_ROUTER_V3_ROUTER_PROTO_UPB_H_
 #define ENVOY_EXTENSIONS_FILTERS_HTTP_ROUTER_V3_ROUTER_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -37,13 +37,19 @@ UPB_INLINE envoy_extensions_filters_http_router_v3_Router *envoy_extensions_filt
 UPB_INLINE envoy_extensions_filters_http_router_v3_Router *envoy_extensions_filters_http_router_v3_Router_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_extensions_filters_http_router_v3_Router *ret = envoy_extensions_filters_http_router_v3_Router_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_extensions_filters_http_router_v3_Router_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_extensions_filters_http_router_v3_Router_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_extensions_filters_http_router_v3_Router *envoy_extensions_filters_http_router_v3_Router_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_extensions_filters_http_router_v3_Router *ret = envoy_extensions_filters_http_router_v3_Router_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_extensions_filters_http_router_v3_Router_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_extensions_filters_http_router_v3_Router_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_extensions_filters_http_router_v3_Router_serialize(const envoy_extensions_filters_http_router_v3_Router *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_extensions_filters_http_router_v3_Router_msginit, arena, len);
index 26db63b..c8846ca 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/extensions/filters/network/http_connection_manager/v3/http_connection_manager.upb.h"
 #include "envoy/config/accesslog/v3/accesslog.upb.h"
 #include "envoy/config/core/v3/base.upb.h"
@@ -24,7 +24,6 @@
 #include "google/protobuf/any.upb.h"
 #include "google/protobuf/duration.upb.h"
 #include "google/protobuf/wrappers.upb.h"
-#include "envoy/annotations/deprecation.upb.h"
 #include "udpa/annotations/migrate.upb.h"
 #include "udpa/annotations/security.upb.h"
 #include "udpa/annotations/status.upb.h"
@@ -58,58 +57,58 @@ static const upb_msglayout *const envoy_extensions_filters_network_http_connecti
 };
 
 static const upb_msglayout_field envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager__fields[46] = {
-  {1, UPB_SIZE(4, 4), 0, 0, 14, 1},
-  {2, UPB_SIZE(32, 32), 0, 0, 9, 1},
-  {3, UPB_SIZE(160, 288), UPB_SIZE(-165, -297), 15, 11, 1},
-  {4, UPB_SIZE(160, 288), UPB_SIZE(-165, -297), 7, 11, 1},
-  {5, UPB_SIZE(144, 256), 0, 13, 11, 3},
-  {6, UPB_SIZE(56, 80), 1, 18, 11, 1},
-  {7, UPB_SIZE(60, 88), 2, 11, 11, 1},
-  {8, UPB_SIZE(64, 96), 3, 1, 11, 1},
-  {9, UPB_SIZE(68, 104), 4, 2, 11, 1},
-  {10, UPB_SIZE(40, 48), 0, 0, 9, 1},
-  {12, UPB_SIZE(72, 112), 5, 19, 11, 1},
-  {13, UPB_SIZE(148, 264), 0, 0, 11, 3},
-  {14, UPB_SIZE(76, 120), 6, 18, 11, 1},
-  {15, UPB_SIZE(80, 128), 7, 18, 11, 1},
-  {16, UPB_SIZE(8, 8), 0, 0, 14, 1},
-  {17, UPB_SIZE(84, 136), 8, 10, 11, 1},
-  {18, UPB_SIZE(24, 24), 0, 0, 8, 1},
-  {19, UPB_SIZE(20, 20), 0, 0, 13, 1},
-  {20, UPB_SIZE(25, 25), 0, 0, 8, 1},
-  {21, UPB_SIZE(26, 26), 0, 0, 8, 1},
-  {22, UPB_SIZE(48, 64), 0, 0, 9, 1},
-  {23, UPB_SIZE(152, 272), 0, 12, 11, 3},
-  {24, UPB_SIZE(88, 144), 9, 19, 11, 1},
-  {25, UPB_SIZE(92, 152), 10, 8, 11, 1},
-  {26, UPB_SIZE(96, 160), 11, 19, 11, 1},
-  {28, UPB_SIZE(100, 168), 12, 19, 11, 1},
-  {29, UPB_SIZE(104, 176), 13, 20, 11, 1},
-  {30, UPB_SIZE(108, 184), 14, 18, 11, 1},
-  {31, UPB_SIZE(160, 288), UPB_SIZE(-165, -297), 17, 11, 1},
-  {32, UPB_SIZE(27, 27), 0, 0, 8, 1},
-  {33, UPB_SIZE(28, 28), 0, 0, 8, 1},
-  {34, UPB_SIZE(12, 12), 0, 0, 14, 1},
-  {35, UPB_SIZE(112, 192), 15, 4, 11, 1},
-  {36, UPB_SIZE(116, 200), 16, 16, 11, 1},
-  {37, UPB_SIZE(29, 29), 0, 0, 8, 1},
-  {38, UPB_SIZE(120, 208), 17, 14, 11, 1},
-  {39, UPB_SIZE(30, 30), 0, 0, 8, 1},
-  {40, UPB_SIZE(124, 216), 18, 18, 11, 1},
-  {41, UPB_SIZE(128, 224), 19, 19, 11, 1},
-  {42, UPB_SIZE(168, 300), UPB_SIZE(-173, -305), 0, 8, 1},
-  {43, UPB_SIZE(132, 232), 20, 9, 11, 1},
-  {44, UPB_SIZE(136, 240), 21, 3, 11, 1},
-  {45, UPB_SIZE(16, 16), 0, 0, 14, 1},
-  {46, UPB_SIZE(156, 280), 0, 6, 11, 3},
-  {47, UPB_SIZE(31, 31), 0, 0, 8, 1},
-  {48, UPB_SIZE(140, 248), 22, 5, 11, 1},
+  {1, UPB_SIZE(4, 4), 0, 0, 14, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(32, 32), 0, 0, 9, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(160, 288), UPB_SIZE(-165, -297), 15, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(160, 288), UPB_SIZE(-165, -297), 7, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(144, 256), 0, 13, 11, _UPB_MODE_ARRAY},
+  {6, UPB_SIZE(56, 80), 1, 18, 11, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(60, 88), 2, 11, 11, _UPB_MODE_SCALAR},
+  {8, UPB_SIZE(64, 96), 3, 1, 11, _UPB_MODE_SCALAR},
+  {9, UPB_SIZE(68, 104), 4, 2, 11, _UPB_MODE_SCALAR},
+  {10, UPB_SIZE(40, 48), 0, 0, 9, _UPB_MODE_SCALAR},
+  {12, UPB_SIZE(72, 112), 5, 19, 11, _UPB_MODE_SCALAR},
+  {13, UPB_SIZE(148, 264), 0, 0, 11, _UPB_MODE_ARRAY},
+  {14, UPB_SIZE(76, 120), 6, 18, 11, _UPB_MODE_SCALAR},
+  {15, UPB_SIZE(80, 128), 7, 18, 11, _UPB_MODE_SCALAR},
+  {16, UPB_SIZE(8, 8), 0, 0, 14, _UPB_MODE_SCALAR},
+  {17, UPB_SIZE(84, 136), 8, 10, 11, _UPB_MODE_SCALAR},
+  {18, UPB_SIZE(24, 24), 0, 0, 8, _UPB_MODE_SCALAR},
+  {19, UPB_SIZE(20, 20), 0, 0, 13, _UPB_MODE_SCALAR},
+  {20, UPB_SIZE(25, 25), 0, 0, 8, _UPB_MODE_SCALAR},
+  {21, UPB_SIZE(26, 26), 0, 0, 8, _UPB_MODE_SCALAR},
+  {22, UPB_SIZE(48, 64), 0, 0, 9, _UPB_MODE_SCALAR},
+  {23, UPB_SIZE(152, 272), 0, 12, 11, _UPB_MODE_ARRAY},
+  {24, UPB_SIZE(88, 144), 9, 19, 11, _UPB_MODE_SCALAR},
+  {25, UPB_SIZE(92, 152), 10, 8, 11, _UPB_MODE_SCALAR},
+  {26, UPB_SIZE(96, 160), 11, 19, 11, _UPB_MODE_SCALAR},
+  {28, UPB_SIZE(100, 168), 12, 19, 11, _UPB_MODE_SCALAR},
+  {29, UPB_SIZE(104, 176), 13, 20, 11, _UPB_MODE_SCALAR},
+  {30, UPB_SIZE(108, 184), 14, 18, 11, _UPB_MODE_SCALAR},
+  {31, UPB_SIZE(160, 288), UPB_SIZE(-165, -297), 17, 11, _UPB_MODE_SCALAR},
+  {32, UPB_SIZE(27, 27), 0, 0, 8, _UPB_MODE_SCALAR},
+  {33, UPB_SIZE(28, 28), 0, 0, 8, _UPB_MODE_SCALAR},
+  {34, UPB_SIZE(12, 12), 0, 0, 14, _UPB_MODE_SCALAR},
+  {35, UPB_SIZE(112, 192), 15, 4, 11, _UPB_MODE_SCALAR},
+  {36, UPB_SIZE(116, 200), 16, 16, 11, _UPB_MODE_SCALAR},
+  {37, UPB_SIZE(29, 29), 0, 0, 8, _UPB_MODE_SCALAR},
+  {38, UPB_SIZE(120, 208), 17, 14, 11, _UPB_MODE_SCALAR},
+  {39, UPB_SIZE(30, 30), 0, 0, 8, _UPB_MODE_SCALAR},
+  {40, UPB_SIZE(124, 216), 18, 18, 11, _UPB_MODE_SCALAR},
+  {41, UPB_SIZE(128, 224), 19, 19, 11, _UPB_MODE_SCALAR},
+  {42, UPB_SIZE(168, 300), UPB_SIZE(-173, -305), 0, 8, _UPB_MODE_SCALAR},
+  {43, UPB_SIZE(132, 232), 20, 9, 11, _UPB_MODE_SCALAR},
+  {44, UPB_SIZE(136, 240), 21, 3, 11, _UPB_MODE_SCALAR},
+  {45, UPB_SIZE(16, 16), 0, 0, 14, _UPB_MODE_SCALAR},
+  {46, UPB_SIZE(156, 280), 0, 6, 11, _UPB_MODE_ARRAY},
+  {47, UPB_SIZE(31, 31), 0, 0, 8, _UPB_MODE_SCALAR},
+  {48, UPB_SIZE(140, 248), 22, 5, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_msginit = {
   &envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_submsgs[0],
   &envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager__fields[0],
-  UPB_SIZE(176, 320), 46, false, 255,
+  UPB_SIZE(176, 320), 46, false, 10, 255,
 };
 
 static const upb_msglayout *const envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_Tracing_submsgs[4] = {
@@ -120,29 +119,29 @@ static const upb_msglayout *const envoy_extensions_filters_network_http_connecti
 };
 
 static const upb_msglayout_field envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_Tracing__fields[7] = {
-  {3, UPB_SIZE(4, 8), 1, 2, 11, 1},
-  {4, UPB_SIZE(8, 16), 2, 2, 11, 1},
-  {5, UPB_SIZE(12, 24), 3, 2, 11, 1},
-  {6, UPB_SIZE(1, 1), 0, 0, 8, 1},
-  {7, UPB_SIZE(16, 32), 4, 3, 11, 1},
-  {8, UPB_SIZE(24, 48), 0, 1, 11, 3},
-  {9, UPB_SIZE(20, 40), 5, 0, 11, 1},
+  {3, UPB_SIZE(4, 8), 1, 2, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(8, 16), 2, 2, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(12, 24), 3, 2, 11, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(1, 1), 0, 0, 8, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(16, 32), 4, 3, 11, _UPB_MODE_SCALAR},
+  {8, UPB_SIZE(24, 48), 0, 1, 11, _UPB_MODE_ARRAY},
+  {9, UPB_SIZE(20, 40), 5, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_Tracing_msginit = {
   &envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_Tracing_submsgs[0],
   &envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_Tracing__fields[0],
-  UPB_SIZE(32, 56), 7, false, 255,
+  UPB_SIZE(32, 56), 7, false, 0, 255,
 };
 
 static const upb_msglayout_field envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_InternalAddressConfig__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 8, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 8, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_InternalAddressConfig_msginit = {
   NULL,
   &envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_InternalAddressConfig__fields[0],
-  UPB_SIZE(8, 8), 1, false, 255,
+  UPB_SIZE(8, 8), 1, false, 1, 255,
 };
 
 static const upb_msglayout *const envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_SetCurrentClientCertDetails_submsgs[1] = {
@@ -150,17 +149,17 @@ static const upb_msglayout *const envoy_extensions_filters_network_http_connecti
 };
 
 static const upb_msglayout_field envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_SetCurrentClientCertDetails__fields[5] = {
-  {1, UPB_SIZE(8, 8), 1, 0, 11, 1},
-  {3, UPB_SIZE(1, 1), 0, 0, 8, 1},
-  {4, UPB_SIZE(2, 2), 0, 0, 8, 1},
-  {5, UPB_SIZE(3, 3), 0, 0, 8, 1},
-  {6, UPB_SIZE(4, 4), 0, 0, 8, 1},
+  {1, UPB_SIZE(8, 8), 1, 0, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(1, 1), 0, 0, 8, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(2, 2), 0, 0, 8, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(3, 3), 0, 0, 8, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(4, 4), 0, 0, 8, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_SetCurrentClientCertDetails_msginit = {
   &envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_SetCurrentClientCertDetails_submsgs[0],
   &envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_SetCurrentClientCertDetails__fields[0],
-  UPB_SIZE(16, 16), 5, false, 255,
+  UPB_SIZE(16, 16), 5, false, 1, 255,
 };
 
 static const upb_msglayout *const envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_UpgradeConfig_submsgs[2] = {
@@ -169,15 +168,15 @@ static const upb_msglayout *const envoy_extensions_filters_network_http_connecti
 };
 
 static const upb_msglayout_field envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_UpgradeConfig__fields[3] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(16, 32), 0, 0, 11, 3},
-  {3, UPB_SIZE(12, 24), 1, 1, 11, 1},
+  {1, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(16, 32), 0, 0, 11, _UPB_MODE_ARRAY},
+  {3, UPB_SIZE(12, 24), 1, 1, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_UpgradeConfig_msginit = {
   &envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_UpgradeConfig_submsgs[0],
   &envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_UpgradeConfig__fields[0],
-  UPB_SIZE(24, 48), 3, false, 255,
+  UPB_SIZE(24, 48), 3, false, 3, 255,
 };
 
 static const upb_msglayout *const envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_PathNormalizationOptions_submsgs[1] = {
@@ -185,14 +184,14 @@ static const upb_msglayout *const envoy_extensions_filters_network_http_connecti
 };
 
 static const upb_msglayout_field envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_PathNormalizationOptions__fields[2] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
-  {2, UPB_SIZE(8, 16), 2, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 2, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_PathNormalizationOptions_msginit = {
   &envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_PathNormalizationOptions_submsgs[0],
   &envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_PathNormalizationOptions__fields[0],
-  UPB_SIZE(16, 24), 2, false, 255,
+  UPB_SIZE(16, 24), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_extensions_filters_network_http_connection_manager_v3_LocalReplyConfig_submsgs[2] = {
@@ -201,14 +200,14 @@ static const upb_msglayout *const envoy_extensions_filters_network_http_connecti
 };
 
 static const upb_msglayout_field envoy_extensions_filters_network_http_connection_manager_v3_LocalReplyConfig__fields[2] = {
-  {1, UPB_SIZE(8, 16), 0, 1, 11, 3},
-  {2, UPB_SIZE(4, 8), 1, 0, 11, 1},
+  {1, UPB_SIZE(8, 16), 0, 1, 11, _UPB_MODE_ARRAY},
+  {2, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_extensions_filters_network_http_connection_manager_v3_LocalReplyConfig_msginit = {
   &envoy_extensions_filters_network_http_connection_manager_v3_LocalReplyConfig_submsgs[0],
   &envoy_extensions_filters_network_http_connection_manager_v3_LocalReplyConfig__fields[0],
-  UPB_SIZE(16, 24), 2, false, 255,
+  UPB_SIZE(16, 24), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_extensions_filters_network_http_connection_manager_v3_ResponseMapper_submsgs[5] = {
@@ -220,17 +219,17 @@ static const upb_msglayout *const envoy_extensions_filters_network_http_connecti
 };
 
 static const upb_msglayout_field envoy_extensions_filters_network_http_connection_manager_v3_ResponseMapper__fields[5] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
-  {2, UPB_SIZE(8, 16), 2, 4, 11, 1},
-  {3, UPB_SIZE(12, 24), 3, 1, 11, 1},
-  {4, UPB_SIZE(16, 32), 4, 3, 11, 1},
-  {5, UPB_SIZE(20, 40), 0, 2, 11, 3},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 2, 4, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(12, 24), 3, 1, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(16, 32), 4, 3, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(20, 40), 0, 2, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout envoy_extensions_filters_network_http_connection_manager_v3_ResponseMapper_msginit = {
   &envoy_extensions_filters_network_http_connection_manager_v3_ResponseMapper_submsgs[0],
   &envoy_extensions_filters_network_http_connection_manager_v3_ResponseMapper__fields[0],
-  UPB_SIZE(24, 48), 5, false, 255,
+  UPB_SIZE(24, 48), 5, false, 5, 255,
 };
 
 static const upb_msglayout *const envoy_extensions_filters_network_http_connection_manager_v3_Rds_submsgs[1] = {
@@ -238,14 +237,14 @@ static const upb_msglayout *const envoy_extensions_filters_network_http_connecti
 };
 
 static const upb_msglayout_field envoy_extensions_filters_network_http_connection_manager_v3_Rds__fields[2] = {
-  {1, UPB_SIZE(12, 24), 1, 0, 11, 1},
-  {2, UPB_SIZE(4, 8), 0, 0, 9, 1},
+  {1, UPB_SIZE(12, 24), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_extensions_filters_network_http_connection_manager_v3_Rds_msginit = {
   &envoy_extensions_filters_network_http_connection_manager_v3_Rds_submsgs[0],
   &envoy_extensions_filters_network_http_connection_manager_v3_Rds__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_extensions_filters_network_http_connection_manager_v3_ScopedRouteConfigurationsList_submsgs[1] = {
@@ -253,13 +252,13 @@ static const upb_msglayout *const envoy_extensions_filters_network_http_connecti
 };
 
 static const upb_msglayout_field envoy_extensions_filters_network_http_connection_manager_v3_ScopedRouteConfigurationsList__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 11, 3},
+  {1, UPB_SIZE(0, 0), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout envoy_extensions_filters_network_http_connection_manager_v3_ScopedRouteConfigurationsList_msginit = {
   &envoy_extensions_filters_network_http_connection_manager_v3_ScopedRouteConfigurationsList_submsgs[0],
   &envoy_extensions_filters_network_http_connection_manager_v3_ScopedRouteConfigurationsList__fields[0],
-  UPB_SIZE(8, 8), 1, false, 255,
+  UPB_SIZE(8, 8), 1, false, 1, 255,
 };
 
 static const upb_msglayout *const envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_submsgs[4] = {
@@ -270,17 +269,17 @@ static const upb_msglayout *const envoy_extensions_filters_network_http_connecti
 };
 
 static const upb_msglayout_field envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes__fields[5] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(12, 24), 1, 3, 11, 1},
-  {3, UPB_SIZE(16, 32), 2, 0, 11, 1},
-  {4, UPB_SIZE(20, 40), UPB_SIZE(-25, -49), 2, 11, 1},
-  {5, UPB_SIZE(20, 40), UPB_SIZE(-25, -49), 1, 11, 1},
+  {1, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(12, 24), 1, 3, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(16, 32), 2, 0, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(20, 40), UPB_SIZE(-25, -49), 2, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(20, 40), UPB_SIZE(-25, -49), 1, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_msginit = {
   &envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_submsgs[0],
   &envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes__fields[0],
-  UPB_SIZE(32, 64), 5, false, 255,
+  UPB_SIZE(32, 64), 5, false, 5, 255,
 };
 
 static const upb_msglayout *const envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_submsgs[1] = {
@@ -288,13 +287,13 @@ static const upb_msglayout *const envoy_extensions_filters_network_http_connecti
 };
 
 static const upb_msglayout_field envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 11, 3},
+  {1, UPB_SIZE(0, 0), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_msginit = {
   &envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_submsgs[0],
   &envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder__fields[0],
-  UPB_SIZE(8, 8), 1, false, 255,
+  UPB_SIZE(8, 8), 1, false, 1, 255,
 };
 
 static const upb_msglayout *const envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_FragmentBuilder_submsgs[1] = {
@@ -302,13 +301,13 @@ static const upb_msglayout *const envoy_extensions_filters_network_http_connecti
 };
 
 static const upb_msglayout_field envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_FragmentBuilder__fields[1] = {
-  {1, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 11, 1},
+  {1, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_FragmentBuilder_msginit = {
   &envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_FragmentBuilder_submsgs[0],
   &envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_FragmentBuilder__fields[0],
-  UPB_SIZE(8, 16), 1, false, 255,
+  UPB_SIZE(8, 16), 1, false, 1, 255,
 };
 
 static const upb_msglayout *const envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_FragmentBuilder_HeaderValueExtractor_submsgs[1] = {
@@ -316,27 +315,27 @@ static const upb_msglayout *const envoy_extensions_filters_network_http_connecti
 };
 
 static const upb_msglayout_field envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_FragmentBuilder_HeaderValueExtractor__fields[4] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {2, UPB_SIZE(8, 16), 0, 0, 9, 1},
-  {3, UPB_SIZE(16, 32), UPB_SIZE(-21, -41), 0, 13, 1},
-  {4, UPB_SIZE(16, 32), UPB_SIZE(-21, -41), 0, 11, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 0, 0, 9, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(16, 32), UPB_SIZE(-21, -41), 0, 13, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(16, 32), UPB_SIZE(-21, -41), 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_FragmentBuilder_HeaderValueExtractor_msginit = {
   &envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_FragmentBuilder_HeaderValueExtractor_submsgs[0],
   &envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_FragmentBuilder_HeaderValueExtractor__fields[0],
-  UPB_SIZE(24, 48), 4, false, 255,
+  UPB_SIZE(24, 48), 4, false, 4, 255,
 };
 
 static const upb_msglayout_field envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_FragmentBuilder_HeaderValueExtractor_KvElement__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {2, UPB_SIZE(8, 16), 0, 0, 9, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 0, 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_FragmentBuilder_HeaderValueExtractor_KvElement_msginit = {
   NULL,
   &envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_FragmentBuilder_HeaderValueExtractor_KvElement__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_extensions_filters_network_http_connection_manager_v3_ScopedRds_submsgs[1] = {
@@ -344,14 +343,14 @@ static const upb_msglayout *const envoy_extensions_filters_network_http_connecti
 };
 
 static const upb_msglayout_field envoy_extensions_filters_network_http_connection_manager_v3_ScopedRds__fields[2] = {
-  {1, UPB_SIZE(12, 24), 1, 0, 11, 1},
-  {2, UPB_SIZE(4, 8), 0, 0, 9, 1},
+  {1, UPB_SIZE(12, 24), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_extensions_filters_network_http_connection_manager_v3_ScopedRds_msginit = {
   &envoy_extensions_filters_network_http_connection_manager_v3_ScopedRds_submsgs[0],
   &envoy_extensions_filters_network_http_connection_manager_v3_ScopedRds__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_extensions_filters_network_http_connection_manager_v3_HttpFilter_submsgs[2] = {
@@ -360,16 +359,16 @@ static const upb_msglayout *const envoy_extensions_filters_network_http_connecti
 };
 
 static const upb_msglayout_field envoy_extensions_filters_network_http_connection_manager_v3_HttpFilter__fields[4] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {4, UPB_SIZE(12, 24), UPB_SIZE(-17, -33), 1, 11, 1},
-  {5, UPB_SIZE(12, 24), UPB_SIZE(-17, -33), 0, 11, 1},
-  {6, UPB_SIZE(0, 0), 0, 0, 8, 1},
+  {1, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(12, 24), UPB_SIZE(-17, -33), 1, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(12, 24), UPB_SIZE(-17, -33), 0, 11, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(0, 0), 0, 0, 8, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_extensions_filters_network_http_connection_manager_v3_HttpFilter_msginit = {
   &envoy_extensions_filters_network_http_connection_manager_v3_HttpFilter_submsgs[0],
   &envoy_extensions_filters_network_http_connection_manager_v3_HttpFilter__fields[0],
-  UPB_SIZE(24, 48), 4, false, 255,
+  UPB_SIZE(24, 48), 4, false, 1, 255,
 };
 
 static const upb_msglayout *const envoy_extensions_filters_network_http_connection_manager_v3_RequestIDExtension_submsgs[1] = {
@@ -377,13 +376,13 @@ static const upb_msglayout *const envoy_extensions_filters_network_http_connecti
 };
 
 static const upb_msglayout_field envoy_extensions_filters_network_http_connection_manager_v3_RequestIDExtension__fields[1] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_extensions_filters_network_http_connection_manager_v3_RequestIDExtension_msginit = {
   &envoy_extensions_filters_network_http_connection_manager_v3_RequestIDExtension_submsgs[0],
   &envoy_extensions_filters_network_http_connection_manager_v3_RequestIDExtension__fields[0],
-  UPB_SIZE(8, 16), 1, false, 255,
+  UPB_SIZE(8, 16), 1, false, 1, 255,
 };
 
 static const upb_msglayout *const envoy_extensions_filters_network_http_connection_manager_v3_EnvoyMobileHttpConnectionManager_submsgs[1] = {
@@ -391,13 +390,13 @@ static const upb_msglayout *const envoy_extensions_filters_network_http_connecti
 };
 
 static const upb_msglayout_field envoy_extensions_filters_network_http_connection_manager_v3_EnvoyMobileHttpConnectionManager__fields[1] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_extensions_filters_network_http_connection_manager_v3_EnvoyMobileHttpConnectionManager_msginit = {
   &envoy_extensions_filters_network_http_connection_manager_v3_EnvoyMobileHttpConnectionManager_submsgs[0],
   &envoy_extensions_filters_network_http_connection_manager_v3_EnvoyMobileHttpConnectionManager__fields[0],
-  UPB_SIZE(8, 16), 1, false, 255,
+  UPB_SIZE(8, 16), 1, false, 1, 255,
 };
 
 #include "upb/port_undef.inc"
index 3695e2a..a331e53 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_EXTENSIONS_FILTERS_NETWORK_HTTP_CONNECTION_MANAGER_V3_HTTP_CONNECTION_MANAGER_PROTO_UPB_H_
 #define ENVOY_EXTENSIONS_FILTERS_NETWORK_HTTP_CONNECTION_MANAGER_V3_HTTP_CONNECTION_MANAGER_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -167,13 +167,19 @@ UPB_INLINE envoy_extensions_filters_network_http_connection_manager_v3_HttpConne
 UPB_INLINE envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager *envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager *ret = envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager *envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager *ret = envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_serialize(const envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_msginit, arena, len);
@@ -704,13 +710,19 @@ UPB_INLINE envoy_extensions_filters_network_http_connection_manager_v3_HttpConne
 UPB_INLINE envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_Tracing *envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_Tracing_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_Tracing *ret = envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_Tracing_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_Tracing_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_Tracing_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_Tracing *envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_Tracing_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_Tracing *ret = envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_Tracing_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_Tracing_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_Tracing_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_Tracing_serialize(const envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_Tracing *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_Tracing_msginit, arena, len);
@@ -820,13 +832,19 @@ UPB_INLINE envoy_extensions_filters_network_http_connection_manager_v3_HttpConne
 UPB_INLINE envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_InternalAddressConfig *envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_InternalAddressConfig_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_InternalAddressConfig *ret = envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_InternalAddressConfig_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_InternalAddressConfig_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_InternalAddressConfig_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_InternalAddressConfig *envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_InternalAddressConfig_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_InternalAddressConfig *ret = envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_InternalAddressConfig_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_InternalAddressConfig_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_InternalAddressConfig_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_InternalAddressConfig_serialize(const envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_InternalAddressConfig *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_InternalAddressConfig_msginit, arena, len);
@@ -846,13 +864,19 @@ UPB_INLINE envoy_extensions_filters_network_http_connection_manager_v3_HttpConne
 UPB_INLINE envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_SetCurrentClientCertDetails *envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_SetCurrentClientCertDetails_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_SetCurrentClientCertDetails *ret = envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_SetCurrentClientCertDetails_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_SetCurrentClientCertDetails_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_SetCurrentClientCertDetails_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_SetCurrentClientCertDetails *envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_SetCurrentClientCertDetails_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_SetCurrentClientCertDetails *ret = envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_SetCurrentClientCertDetails_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_SetCurrentClientCertDetails_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_SetCurrentClientCertDetails_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_SetCurrentClientCertDetails_serialize(const envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_SetCurrentClientCertDetails *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_SetCurrentClientCertDetails_msginit, arena, len);
@@ -899,13 +923,19 @@ UPB_INLINE envoy_extensions_filters_network_http_connection_manager_v3_HttpConne
 UPB_INLINE envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_UpgradeConfig *envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_UpgradeConfig_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_UpgradeConfig *ret = envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_UpgradeConfig_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_UpgradeConfig_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_UpgradeConfig_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_UpgradeConfig *envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_UpgradeConfig_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_UpgradeConfig *ret = envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_UpgradeConfig_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_UpgradeConfig_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_UpgradeConfig_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_UpgradeConfig_serialize(const envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_UpgradeConfig *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_UpgradeConfig_msginit, arena, len);
@@ -955,13 +985,19 @@ UPB_INLINE envoy_extensions_filters_network_http_connection_manager_v3_HttpConne
 UPB_INLINE envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_PathNormalizationOptions *envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_PathNormalizationOptions_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_PathNormalizationOptions *ret = envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_PathNormalizationOptions_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_PathNormalizationOptions_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_PathNormalizationOptions_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_PathNormalizationOptions *envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_PathNormalizationOptions_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_PathNormalizationOptions *ret = envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_PathNormalizationOptions_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_PathNormalizationOptions_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_PathNormalizationOptions_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_PathNormalizationOptions_serialize(const envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_PathNormalizationOptions *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_PathNormalizationOptions_msginit, arena, len);
@@ -1007,13 +1043,19 @@ UPB_INLINE envoy_extensions_filters_network_http_connection_manager_v3_LocalRepl
 UPB_INLINE envoy_extensions_filters_network_http_connection_manager_v3_LocalReplyConfig *envoy_extensions_filters_network_http_connection_manager_v3_LocalReplyConfig_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_extensions_filters_network_http_connection_manager_v3_LocalReplyConfig *ret = envoy_extensions_filters_network_http_connection_manager_v3_LocalReplyConfig_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_LocalReplyConfig_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_LocalReplyConfig_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_extensions_filters_network_http_connection_manager_v3_LocalReplyConfig *envoy_extensions_filters_network_http_connection_manager_v3_LocalReplyConfig_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_extensions_filters_network_http_connection_manager_v3_LocalReplyConfig *ret = envoy_extensions_filters_network_http_connection_manager_v3_LocalReplyConfig_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_LocalReplyConfig_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_LocalReplyConfig_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_extensions_filters_network_http_connection_manager_v3_LocalReplyConfig_serialize(const envoy_extensions_filters_network_http_connection_manager_v3_LocalReplyConfig *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_extensions_filters_network_http_connection_manager_v3_LocalReplyConfig_msginit, arena, len);
@@ -1059,13 +1101,19 @@ UPB_INLINE envoy_extensions_filters_network_http_connection_manager_v3_ResponseM
 UPB_INLINE envoy_extensions_filters_network_http_connection_manager_v3_ResponseMapper *envoy_extensions_filters_network_http_connection_manager_v3_ResponseMapper_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_extensions_filters_network_http_connection_manager_v3_ResponseMapper *ret = envoy_extensions_filters_network_http_connection_manager_v3_ResponseMapper_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_ResponseMapper_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_ResponseMapper_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_extensions_filters_network_http_connection_manager_v3_ResponseMapper *envoy_extensions_filters_network_http_connection_manager_v3_ResponseMapper_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_extensions_filters_network_http_connection_manager_v3_ResponseMapper *ret = envoy_extensions_filters_network_http_connection_manager_v3_ResponseMapper_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_ResponseMapper_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_ResponseMapper_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_extensions_filters_network_http_connection_manager_v3_ResponseMapper_serialize(const envoy_extensions_filters_network_http_connection_manager_v3_ResponseMapper *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_extensions_filters_network_http_connection_manager_v3_ResponseMapper_msginit, arena, len);
@@ -1156,13 +1204,19 @@ UPB_INLINE envoy_extensions_filters_network_http_connection_manager_v3_Rds *envo
 UPB_INLINE envoy_extensions_filters_network_http_connection_manager_v3_Rds *envoy_extensions_filters_network_http_connection_manager_v3_Rds_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_extensions_filters_network_http_connection_manager_v3_Rds *ret = envoy_extensions_filters_network_http_connection_manager_v3_Rds_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_Rds_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_Rds_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_extensions_filters_network_http_connection_manager_v3_Rds *envoy_extensions_filters_network_http_connection_manager_v3_Rds_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_extensions_filters_network_http_connection_manager_v3_Rds *ret = envoy_extensions_filters_network_http_connection_manager_v3_Rds_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_Rds_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_Rds_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_extensions_filters_network_http_connection_manager_v3_Rds_serialize(const envoy_extensions_filters_network_http_connection_manager_v3_Rds *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_extensions_filters_network_http_connection_manager_v3_Rds_msginit, arena, len);
@@ -1197,13 +1251,19 @@ UPB_INLINE envoy_extensions_filters_network_http_connection_manager_v3_ScopedRou
 UPB_INLINE envoy_extensions_filters_network_http_connection_manager_v3_ScopedRouteConfigurationsList *envoy_extensions_filters_network_http_connection_manager_v3_ScopedRouteConfigurationsList_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_extensions_filters_network_http_connection_manager_v3_ScopedRouteConfigurationsList *ret = envoy_extensions_filters_network_http_connection_manager_v3_ScopedRouteConfigurationsList_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_ScopedRouteConfigurationsList_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_ScopedRouteConfigurationsList_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_extensions_filters_network_http_connection_manager_v3_ScopedRouteConfigurationsList *envoy_extensions_filters_network_http_connection_manager_v3_ScopedRouteConfigurationsList_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_extensions_filters_network_http_connection_manager_v3_ScopedRouteConfigurationsList *ret = envoy_extensions_filters_network_http_connection_manager_v3_ScopedRouteConfigurationsList_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_ScopedRouteConfigurationsList_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_ScopedRouteConfigurationsList_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_extensions_filters_network_http_connection_manager_v3_ScopedRouteConfigurationsList_serialize(const envoy_extensions_filters_network_http_connection_manager_v3_ScopedRouteConfigurationsList *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_extensions_filters_network_http_connection_manager_v3_ScopedRouteConfigurationsList_msginit, arena, len);
@@ -1234,13 +1294,19 @@ UPB_INLINE envoy_extensions_filters_network_http_connection_manager_v3_ScopedRou
 UPB_INLINE envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes *envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes *ret = envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes *envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes *ret = envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_serialize(const envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_msginit, arena, len);
@@ -1325,13 +1391,19 @@ UPB_INLINE envoy_extensions_filters_network_http_connection_manager_v3_ScopedRou
 UPB_INLINE envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder *envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder *ret = envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder *envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder *ret = envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_serialize(const envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_msginit, arena, len);
@@ -1362,13 +1434,19 @@ UPB_INLINE envoy_extensions_filters_network_http_connection_manager_v3_ScopedRou
 UPB_INLINE envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_FragmentBuilder *envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_FragmentBuilder_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_FragmentBuilder *ret = envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_FragmentBuilder_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_FragmentBuilder_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_FragmentBuilder_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_FragmentBuilder *envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_FragmentBuilder_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_FragmentBuilder *ret = envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_FragmentBuilder_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_FragmentBuilder_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_FragmentBuilder_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_FragmentBuilder_serialize(const envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_FragmentBuilder *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_FragmentBuilder_msginit, arena, len);
@@ -1404,13 +1482,19 @@ UPB_INLINE envoy_extensions_filters_network_http_connection_manager_v3_ScopedRou
 UPB_INLINE envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_FragmentBuilder_HeaderValueExtractor *envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_FragmentBuilder_HeaderValueExtractor_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_FragmentBuilder_HeaderValueExtractor *ret = envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_FragmentBuilder_HeaderValueExtractor_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_FragmentBuilder_HeaderValueExtractor_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_FragmentBuilder_HeaderValueExtractor_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_FragmentBuilder_HeaderValueExtractor *envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_FragmentBuilder_HeaderValueExtractor_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_FragmentBuilder_HeaderValueExtractor *ret = envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_FragmentBuilder_HeaderValueExtractor_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_FragmentBuilder_HeaderValueExtractor_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_FragmentBuilder_HeaderValueExtractor_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_FragmentBuilder_HeaderValueExtractor_serialize(const envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_FragmentBuilder_HeaderValueExtractor *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_FragmentBuilder_HeaderValueExtractor_msginit, arena, len);
@@ -1460,13 +1544,19 @@ UPB_INLINE envoy_extensions_filters_network_http_connection_manager_v3_ScopedRou
 UPB_INLINE envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_FragmentBuilder_HeaderValueExtractor_KvElement *envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_FragmentBuilder_HeaderValueExtractor_KvElement_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_FragmentBuilder_HeaderValueExtractor_KvElement *ret = envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_FragmentBuilder_HeaderValueExtractor_KvElement_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_FragmentBuilder_HeaderValueExtractor_KvElement_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_FragmentBuilder_HeaderValueExtractor_KvElement_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_FragmentBuilder_HeaderValueExtractor_KvElement *envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_FragmentBuilder_HeaderValueExtractor_KvElement_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_FragmentBuilder_HeaderValueExtractor_KvElement *ret = envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_FragmentBuilder_HeaderValueExtractor_KvElement_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_FragmentBuilder_HeaderValueExtractor_KvElement_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_FragmentBuilder_HeaderValueExtractor_KvElement_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_FragmentBuilder_HeaderValueExtractor_KvElement_serialize(const envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_FragmentBuilder_HeaderValueExtractor_KvElement *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_extensions_filters_network_http_connection_manager_v3_ScopedRoutes_ScopeKeyBuilder_FragmentBuilder_HeaderValueExtractor_KvElement_msginit, arena, len);
@@ -1490,13 +1580,19 @@ UPB_INLINE envoy_extensions_filters_network_http_connection_manager_v3_ScopedRds
 UPB_INLINE envoy_extensions_filters_network_http_connection_manager_v3_ScopedRds *envoy_extensions_filters_network_http_connection_manager_v3_ScopedRds_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_extensions_filters_network_http_connection_manager_v3_ScopedRds *ret = envoy_extensions_filters_network_http_connection_manager_v3_ScopedRds_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_ScopedRds_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_ScopedRds_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_extensions_filters_network_http_connection_manager_v3_ScopedRds *envoy_extensions_filters_network_http_connection_manager_v3_ScopedRds_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_extensions_filters_network_http_connection_manager_v3_ScopedRds *ret = envoy_extensions_filters_network_http_connection_manager_v3_ScopedRds_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_ScopedRds_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_ScopedRds_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_extensions_filters_network_http_connection_manager_v3_ScopedRds_serialize(const envoy_extensions_filters_network_http_connection_manager_v3_ScopedRds *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_extensions_filters_network_http_connection_manager_v3_ScopedRds_msginit, arena, len);
@@ -1531,13 +1627,19 @@ UPB_INLINE envoy_extensions_filters_network_http_connection_manager_v3_HttpFilte
 UPB_INLINE envoy_extensions_filters_network_http_connection_manager_v3_HttpFilter *envoy_extensions_filters_network_http_connection_manager_v3_HttpFilter_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_extensions_filters_network_http_connection_manager_v3_HttpFilter *ret = envoy_extensions_filters_network_http_connection_manager_v3_HttpFilter_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_HttpFilter_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_HttpFilter_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_extensions_filters_network_http_connection_manager_v3_HttpFilter *envoy_extensions_filters_network_http_connection_manager_v3_HttpFilter_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_extensions_filters_network_http_connection_manager_v3_HttpFilter *ret = envoy_extensions_filters_network_http_connection_manager_v3_HttpFilter_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_HttpFilter_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_HttpFilter_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_extensions_filters_network_http_connection_manager_v3_HttpFilter_serialize(const envoy_extensions_filters_network_http_connection_manager_v3_HttpFilter *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_extensions_filters_network_http_connection_manager_v3_HttpFilter_msginit, arena, len);
@@ -1596,13 +1698,19 @@ UPB_INLINE envoy_extensions_filters_network_http_connection_manager_v3_RequestID
 UPB_INLINE envoy_extensions_filters_network_http_connection_manager_v3_RequestIDExtension *envoy_extensions_filters_network_http_connection_manager_v3_RequestIDExtension_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_extensions_filters_network_http_connection_manager_v3_RequestIDExtension *ret = envoy_extensions_filters_network_http_connection_manager_v3_RequestIDExtension_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_RequestIDExtension_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_RequestIDExtension_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_extensions_filters_network_http_connection_manager_v3_RequestIDExtension *envoy_extensions_filters_network_http_connection_manager_v3_RequestIDExtension_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_extensions_filters_network_http_connection_manager_v3_RequestIDExtension *ret = envoy_extensions_filters_network_http_connection_manager_v3_RequestIDExtension_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_RequestIDExtension_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_RequestIDExtension_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_extensions_filters_network_http_connection_manager_v3_RequestIDExtension_serialize(const envoy_extensions_filters_network_http_connection_manager_v3_RequestIDExtension *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_extensions_filters_network_http_connection_manager_v3_RequestIDExtension_msginit, arena, len);
@@ -1633,13 +1741,19 @@ UPB_INLINE envoy_extensions_filters_network_http_connection_manager_v3_EnvoyMobi
 UPB_INLINE envoy_extensions_filters_network_http_connection_manager_v3_EnvoyMobileHttpConnectionManager *envoy_extensions_filters_network_http_connection_manager_v3_EnvoyMobileHttpConnectionManager_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_extensions_filters_network_http_connection_manager_v3_EnvoyMobileHttpConnectionManager *ret = envoy_extensions_filters_network_http_connection_manager_v3_EnvoyMobileHttpConnectionManager_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_EnvoyMobileHttpConnectionManager_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_EnvoyMobileHttpConnectionManager_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_extensions_filters_network_http_connection_manager_v3_EnvoyMobileHttpConnectionManager *envoy_extensions_filters_network_http_connection_manager_v3_EnvoyMobileHttpConnectionManager_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_extensions_filters_network_http_connection_manager_v3_EnvoyMobileHttpConnectionManager *ret = envoy_extensions_filters_network_http_connection_manager_v3_EnvoyMobileHttpConnectionManager_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_EnvoyMobileHttpConnectionManager_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_extensions_filters_network_http_connection_manager_v3_EnvoyMobileHttpConnectionManager_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_extensions_filters_network_http_connection_manager_v3_EnvoyMobileHttpConnectionManager_serialize(const envoy_extensions_filters_network_http_connection_manager_v3_EnvoyMobileHttpConnectionManager *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_extensions_filters_network_http_connection_manager_v3_EnvoyMobileHttpConnectionManager_msginit, arena, len);
index 44d63a4..daf1765 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/extensions/transport_sockets/tls/v3/cert.upb.h"
 #include "envoy/extensions/transport_sockets/tls/v3/common.upb.h"
 #include "envoy/extensions/transport_sockets/tls/v3/secret.upb.h"
index f1b24af..0b4d12f 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_EXTENSIONS_TRANSPORT_SOCKETS_TLS_V3_CERT_PROTO_UPB_H_
 #define ENVOY_EXTENSIONS_TRANSPORT_SOCKETS_TLS_V3_CERT_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
index 6bd4e8d..218d14f 100644 (file)
@@ -7,13 +7,14 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/extensions/transport_sockets/tls/v3/common.upb.h"
 #include "envoy/config/core/v3/base.upb.h"
 #include "envoy/config/core/v3/extension.upb.h"
 #include "envoy/type/matcher/v3/string.upb.h"
 #include "google/protobuf/any.upb.h"
 #include "google/protobuf/wrappers.upb.h"
+#include "udpa/annotations/migrate.upb.h"
 #include "udpa/annotations/sensitive.upb.h"
 #include "udpa/annotations/status.upb.h"
 #include "udpa/annotations/versioning.upb.h"
 #include "upb/port_def.inc"
 
 static const upb_msglayout_field envoy_extensions_transport_sockets_tls_v3_TlsParameters__fields[4] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 14, 1},
-  {2, UPB_SIZE(4, 4), 0, 0, 14, 1},
-  {3, UPB_SIZE(8, 8), 0, 0, 9, 3},
-  {4, UPB_SIZE(12, 16), 0, 0, 9, 3},
+  {1, UPB_SIZE(0, 0), 0, 0, 14, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(4, 4), 0, 0, 14, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(8, 8), 0, 0, 9, _UPB_MODE_ARRAY},
+  {4, UPB_SIZE(12, 16), 0, 0, 9, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout envoy_extensions_transport_sockets_tls_v3_TlsParameters_msginit = {
   NULL,
   &envoy_extensions_transport_sockets_tls_v3_TlsParameters__fields[0],
-  UPB_SIZE(16, 24), 4, false, 255,
+  UPB_SIZE(16, 24), 4, false, 4, 255,
 };
 
 static const upb_msglayout *const envoy_extensions_transport_sockets_tls_v3_PrivateKeyProvider_submsgs[1] = {
@@ -39,14 +40,14 @@ static const upb_msglayout *const envoy_extensions_transport_sockets_tls_v3_Priv
 };
 
 static const upb_msglayout_field envoy_extensions_transport_sockets_tls_v3_PrivateKeyProvider__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {3, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 0, 11, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_extensions_transport_sockets_tls_v3_PrivateKeyProvider_msginit = {
   &envoy_extensions_transport_sockets_tls_v3_PrivateKeyProvider_submsgs[0],
   &envoy_extensions_transport_sockets_tls_v3_PrivateKeyProvider__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 1, 255,
 };
 
 static const upb_msglayout *const envoy_extensions_transport_sockets_tls_v3_TlsCertificate_submsgs[3] = {
@@ -56,19 +57,19 @@ static const upb_msglayout *const envoy_extensions_transport_sockets_tls_v3_TlsC
 };
 
 static const upb_msglayout_field envoy_extensions_transport_sockets_tls_v3_TlsCertificate__fields[7] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
-  {2, UPB_SIZE(8, 16), 2, 0, 11, 1},
-  {3, UPB_SIZE(12, 24), 3, 0, 11, 1},
-  {4, UPB_SIZE(16, 32), 4, 0, 11, 1},
-  {5, UPB_SIZE(28, 56), 0, 0, 11, 3},
-  {6, UPB_SIZE(20, 40), 5, 2, 11, 1},
-  {7, UPB_SIZE(24, 48), 6, 1, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 2, 0, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(12, 24), 3, 0, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(16, 32), 4, 0, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(28, 56), 0, 0, 11, _UPB_MODE_ARRAY},
+  {6, UPB_SIZE(20, 40), 5, 2, 11, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(24, 48), 6, 1, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_extensions_transport_sockets_tls_v3_TlsCertificate_msginit = {
   &envoy_extensions_transport_sockets_tls_v3_TlsCertificate_submsgs[0],
   &envoy_extensions_transport_sockets_tls_v3_TlsCertificate__fields[0],
-  UPB_SIZE(32, 64), 7, false, 255,
+  UPB_SIZE(32, 64), 7, false, 7, 255,
 };
 
 static const upb_msglayout *const envoy_extensions_transport_sockets_tls_v3_TlsSessionTicketKeys_submsgs[1] = {
@@ -76,40 +77,53 @@ static const upb_msglayout *const envoy_extensions_transport_sockets_tls_v3_TlsS
 };
 
 static const upb_msglayout_field envoy_extensions_transport_sockets_tls_v3_TlsSessionTicketKeys__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 11, 3},
+  {1, UPB_SIZE(0, 0), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout envoy_extensions_transport_sockets_tls_v3_TlsSessionTicketKeys_msginit = {
   &envoy_extensions_transport_sockets_tls_v3_TlsSessionTicketKeys_submsgs[0],
   &envoy_extensions_transport_sockets_tls_v3_TlsSessionTicketKeys__fields[0],
-  UPB_SIZE(8, 8), 1, false, 255,
+  UPB_SIZE(8, 8), 1, false, 1, 255,
 };
 
-static const upb_msglayout *const envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_submsgs[5] = {
+static const upb_msglayout_field envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance__fields[2] = {
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 0, 0, 9, _UPB_MODE_SCALAR},
+};
+
+const upb_msglayout envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance_msginit = {
+  NULL,
+  &envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance__fields[0],
+  UPB_SIZE(16, 32), 2, false, 2, 255,
+};
+
+static const upb_msglayout *const envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_submsgs[6] = {
   &envoy_config_core_v3_DataSource_msginit,
   &envoy_config_core_v3_TypedExtensionConfig_msginit,
   &envoy_config_core_v3_WatchedDirectory_msginit,
+  &envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance_msginit,
   &envoy_type_matcher_v3_StringMatcher_msginit,
   &google_protobuf_BoolValue_msginit,
 };
 
-static const upb_msglayout_field envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext__fields[10] = {
-  {1, UPB_SIZE(12, 16), 1, 0, 11, 1},
-  {2, UPB_SIZE(32, 56), 0, 0, 9, 3},
-  {3, UPB_SIZE(36, 64), 0, 0, 9, 3},
-  {6, UPB_SIZE(16, 24), 2, 4, 11, 1},
-  {7, UPB_SIZE(20, 32), 3, 0, 11, 1},
-  {8, UPB_SIZE(8, 8), 0, 0, 8, 1},
-  {9, UPB_SIZE(40, 72), 0, 3, 11, 3},
-  {10, UPB_SIZE(4, 4), 0, 0, 14, 1},
-  {11, UPB_SIZE(24, 40), 4, 2, 11, 1},
-  {12, UPB_SIZE(28, 48), 5, 1, 11, 1},
+static const upb_msglayout_field envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext__fields[11] = {
+  {1, UPB_SIZE(12, 16), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(36, 64), 0, 0, 9, _UPB_MODE_ARRAY},
+  {3, UPB_SIZE(40, 72), 0, 0, 9, _UPB_MODE_ARRAY},
+  {6, UPB_SIZE(16, 24), 2, 5, 11, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(20, 32), 3, 0, 11, _UPB_MODE_SCALAR},
+  {8, UPB_SIZE(8, 8), 0, 0, 8, _UPB_MODE_SCALAR},
+  {9, UPB_SIZE(44, 80), 0, 4, 11, _UPB_MODE_ARRAY},
+  {10, UPB_SIZE(4, 4), 0, 0, 14, _UPB_MODE_SCALAR},
+  {11, UPB_SIZE(24, 40), 4, 2, 11, _UPB_MODE_SCALAR},
+  {12, UPB_SIZE(28, 48), 5, 1, 11, _UPB_MODE_SCALAR},
+  {13, UPB_SIZE(32, 56), 6, 3, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_msginit = {
   &envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_submsgs[0],
   &envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext__fields[0],
-  UPB_SIZE(48, 80), 10, false, 255,
+  UPB_SIZE(48, 88), 11, false, 3, 255,
 };
 
 #include "upb/port_undef.inc"
index e85f14b..acf1b33 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_EXTENSIONS_TRANSPORT_SOCKETS_TLS_V3_COMMON_PROTO_UPB_H_
 #define ENVOY_EXTENSIONS_TRANSPORT_SOCKETS_TLS_V3_COMMON_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -24,16 +24,19 @@ struct envoy_extensions_transport_sockets_tls_v3_TlsParameters;
 struct envoy_extensions_transport_sockets_tls_v3_PrivateKeyProvider;
 struct envoy_extensions_transport_sockets_tls_v3_TlsCertificate;
 struct envoy_extensions_transport_sockets_tls_v3_TlsSessionTicketKeys;
+struct envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance;
 struct envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext;
 typedef struct envoy_extensions_transport_sockets_tls_v3_TlsParameters envoy_extensions_transport_sockets_tls_v3_TlsParameters;
 typedef struct envoy_extensions_transport_sockets_tls_v3_PrivateKeyProvider envoy_extensions_transport_sockets_tls_v3_PrivateKeyProvider;
 typedef struct envoy_extensions_transport_sockets_tls_v3_TlsCertificate envoy_extensions_transport_sockets_tls_v3_TlsCertificate;
 typedef struct envoy_extensions_transport_sockets_tls_v3_TlsSessionTicketKeys envoy_extensions_transport_sockets_tls_v3_TlsSessionTicketKeys;
+typedef struct envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance;
 typedef struct envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext;
 extern const upb_msglayout envoy_extensions_transport_sockets_tls_v3_TlsParameters_msginit;
 extern const upb_msglayout envoy_extensions_transport_sockets_tls_v3_PrivateKeyProvider_msginit;
 extern const upb_msglayout envoy_extensions_transport_sockets_tls_v3_TlsCertificate_msginit;
 extern const upb_msglayout envoy_extensions_transport_sockets_tls_v3_TlsSessionTicketKeys_msginit;
+extern const upb_msglayout envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance_msginit;
 extern const upb_msglayout envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_msginit;
 struct envoy_config_core_v3_DataSource;
 struct envoy_config_core_v3_TypedExtensionConfig;
@@ -70,13 +73,19 @@ UPB_INLINE envoy_extensions_transport_sockets_tls_v3_TlsParameters *envoy_extens
 UPB_INLINE envoy_extensions_transport_sockets_tls_v3_TlsParameters *envoy_extensions_transport_sockets_tls_v3_TlsParameters_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_extensions_transport_sockets_tls_v3_TlsParameters *ret = envoy_extensions_transport_sockets_tls_v3_TlsParameters_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_extensions_transport_sockets_tls_v3_TlsParameters_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_extensions_transport_sockets_tls_v3_TlsParameters_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_extensions_transport_sockets_tls_v3_TlsParameters *envoy_extensions_transport_sockets_tls_v3_TlsParameters_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_extensions_transport_sockets_tls_v3_TlsParameters *ret = envoy_extensions_transport_sockets_tls_v3_TlsParameters_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_extensions_transport_sockets_tls_v3_TlsParameters_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_extensions_transport_sockets_tls_v3_TlsParameters_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_extensions_transport_sockets_tls_v3_TlsParameters_serialize(const envoy_extensions_transport_sockets_tls_v3_TlsParameters *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_extensions_transport_sockets_tls_v3_TlsParameters_msginit, arena, len);
@@ -122,13 +131,19 @@ UPB_INLINE envoy_extensions_transport_sockets_tls_v3_PrivateKeyProvider *envoy_e
 UPB_INLINE envoy_extensions_transport_sockets_tls_v3_PrivateKeyProvider *envoy_extensions_transport_sockets_tls_v3_PrivateKeyProvider_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_extensions_transport_sockets_tls_v3_PrivateKeyProvider *ret = envoy_extensions_transport_sockets_tls_v3_PrivateKeyProvider_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_extensions_transport_sockets_tls_v3_PrivateKeyProvider_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_extensions_transport_sockets_tls_v3_PrivateKeyProvider_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_extensions_transport_sockets_tls_v3_PrivateKeyProvider *envoy_extensions_transport_sockets_tls_v3_PrivateKeyProvider_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_extensions_transport_sockets_tls_v3_PrivateKeyProvider *ret = envoy_extensions_transport_sockets_tls_v3_PrivateKeyProvider_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_extensions_transport_sockets_tls_v3_PrivateKeyProvider_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_extensions_transport_sockets_tls_v3_PrivateKeyProvider_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_extensions_transport_sockets_tls_v3_PrivateKeyProvider_serialize(const envoy_extensions_transport_sockets_tls_v3_PrivateKeyProvider *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_extensions_transport_sockets_tls_v3_PrivateKeyProvider_msginit, arena, len);
@@ -168,13 +183,19 @@ UPB_INLINE envoy_extensions_transport_sockets_tls_v3_TlsCertificate *envoy_exten
 UPB_INLINE envoy_extensions_transport_sockets_tls_v3_TlsCertificate *envoy_extensions_transport_sockets_tls_v3_TlsCertificate_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_extensions_transport_sockets_tls_v3_TlsCertificate *ret = envoy_extensions_transport_sockets_tls_v3_TlsCertificate_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_extensions_transport_sockets_tls_v3_TlsCertificate_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_extensions_transport_sockets_tls_v3_TlsCertificate_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_extensions_transport_sockets_tls_v3_TlsCertificate *envoy_extensions_transport_sockets_tls_v3_TlsCertificate_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_extensions_transport_sockets_tls_v3_TlsCertificate *ret = envoy_extensions_transport_sockets_tls_v3_TlsCertificate_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_extensions_transport_sockets_tls_v3_TlsCertificate_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_extensions_transport_sockets_tls_v3_TlsCertificate_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_extensions_transport_sockets_tls_v3_TlsCertificate_serialize(const envoy_extensions_transport_sockets_tls_v3_TlsCertificate *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_extensions_transport_sockets_tls_v3_TlsCertificate_msginit, arena, len);
@@ -295,13 +316,19 @@ UPB_INLINE envoy_extensions_transport_sockets_tls_v3_TlsSessionTicketKeys *envoy
 UPB_INLINE envoy_extensions_transport_sockets_tls_v3_TlsSessionTicketKeys *envoy_extensions_transport_sockets_tls_v3_TlsSessionTicketKeys_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_extensions_transport_sockets_tls_v3_TlsSessionTicketKeys *ret = envoy_extensions_transport_sockets_tls_v3_TlsSessionTicketKeys_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_extensions_transport_sockets_tls_v3_TlsSessionTicketKeys_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_extensions_transport_sockets_tls_v3_TlsSessionTicketKeys_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_extensions_transport_sockets_tls_v3_TlsSessionTicketKeys *envoy_extensions_transport_sockets_tls_v3_TlsSessionTicketKeys_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_extensions_transport_sockets_tls_v3_TlsSessionTicketKeys *ret = envoy_extensions_transport_sockets_tls_v3_TlsSessionTicketKeys_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_extensions_transport_sockets_tls_v3_TlsSessionTicketKeys_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_extensions_transport_sockets_tls_v3_TlsSessionTicketKeys_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_extensions_transport_sockets_tls_v3_TlsSessionTicketKeys_serialize(const envoy_extensions_transport_sockets_tls_v3_TlsSessionTicketKeys *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_extensions_transport_sockets_tls_v3_TlsSessionTicketKeys_msginit, arena, len);
@@ -324,6 +351,42 @@ UPB_INLINE struct envoy_config_core_v3_DataSource* envoy_extensions_transport_so
   return sub;
 }
 
+/* envoy.extensions.transport_sockets.tls.v3.CertificateProviderPluginInstance */
+
+UPB_INLINE envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance *envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance_new(upb_arena *arena) {
+  return (envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance *)_upb_msg_new(&envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance_msginit, arena);
+}
+UPB_INLINE envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance *envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance_parse(const char *buf, size_t size,
+                        upb_arena *arena) {
+  envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance *ret = envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance_new(arena);
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance_msginit, arena)) return NULL;
+  return ret;
+}
+UPB_INLINE envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance *envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance_parse_ex(const char *buf, size_t size,
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
+  envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance *ret = envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance_new(arena);
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
+}
+UPB_INLINE char *envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance_serialize(const envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance *msg, upb_arena *arena, size_t *len) {
+  return upb_encode(msg, &envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance_msginit, arena, len);
+}
+
+UPB_INLINE upb_strview envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance_instance_name(const envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(0, 0), upb_strview); }
+UPB_INLINE upb_strview envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance_certificate_name(const envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(8, 16), upb_strview); }
+
+UPB_INLINE void envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance_set_instance_name(envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance *msg, upb_strview value) {
+  *UPB_PTR_AT(msg, UPB_SIZE(0, 0), upb_strview) = value;
+}
+UPB_INLINE void envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance_set_certificate_name(envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance *msg, upb_strview value) {
+  *UPB_PTR_AT(msg, UPB_SIZE(8, 16), upb_strview) = value;
+}
+
 /* envoy.extensions.transport_sockets.tls.v3.CertificateValidationContext */
 
 UPB_INLINE envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext *envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_new(upb_arena *arena) {
@@ -332,13 +395,19 @@ UPB_INLINE envoy_extensions_transport_sockets_tls_v3_CertificateValidationContex
 UPB_INLINE envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext *envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext *ret = envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext *envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext *ret = envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_serialize(const envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_msginit, arena, len);
@@ -346,20 +415,22 @@ UPB_INLINE char *envoy_extensions_transport_sockets_tls_v3_CertificateValidation
 
 UPB_INLINE bool envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_has_trusted_ca(const envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext *msg) { return _upb_hasbit(msg, 1); }
 UPB_INLINE const struct envoy_config_core_v3_DataSource* envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_trusted_ca(const envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(12, 16), const struct envoy_config_core_v3_DataSource*); }
-UPB_INLINE upb_strview const* envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_verify_certificate_hash(const envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext *msg, size_t *len) { return (upb_strview const*)_upb_array_accessor(msg, UPB_SIZE(32, 56), len); }
-UPB_INLINE upb_strview const* envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_verify_certificate_spki(const envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext *msg, size_t *len) { return (upb_strview const*)_upb_array_accessor(msg, UPB_SIZE(36, 64), len); }
+UPB_INLINE upb_strview const* envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_verify_certificate_hash(const envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext *msg, size_t *len) { return (upb_strview const*)_upb_array_accessor(msg, UPB_SIZE(36, 64), len); }
+UPB_INLINE upb_strview const* envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_verify_certificate_spki(const envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext *msg, size_t *len) { return (upb_strview const*)_upb_array_accessor(msg, UPB_SIZE(40, 72), len); }
 UPB_INLINE bool envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_has_require_signed_certificate_timestamp(const envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext *msg) { return _upb_hasbit(msg, 2); }
 UPB_INLINE const struct google_protobuf_BoolValue* envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_require_signed_certificate_timestamp(const envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(16, 24), const struct google_protobuf_BoolValue*); }
 UPB_INLINE bool envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_has_crl(const envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext *msg) { return _upb_hasbit(msg, 3); }
 UPB_INLINE const struct envoy_config_core_v3_DataSource* envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_crl(const envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(20, 32), const struct envoy_config_core_v3_DataSource*); }
 UPB_INLINE bool envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_allow_expired_certificate(const envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(8, 8), bool); }
-UPB_INLINE bool envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_has_match_subject_alt_names(const envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext *msg) { return _upb_has_submsg_nohasbit(msg, UPB_SIZE(40, 72)); }
-UPB_INLINE const struct envoy_type_matcher_v3_StringMatcher* const* envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_match_subject_alt_names(const envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext *msg, size_t *len) { return (const struct envoy_type_matcher_v3_StringMatcher* const*)_upb_array_accessor(msg, UPB_SIZE(40, 72), len); }
+UPB_INLINE bool envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_has_match_subject_alt_names(const envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext *msg) { return _upb_has_submsg_nohasbit(msg, UPB_SIZE(44, 80)); }
+UPB_INLINE const struct envoy_type_matcher_v3_StringMatcher* const* envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_match_subject_alt_names(const envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext *msg, size_t *len) { return (const struct envoy_type_matcher_v3_StringMatcher* const*)_upb_array_accessor(msg, UPB_SIZE(44, 80), len); }
 UPB_INLINE int32_t envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_trust_chain_verification(const envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(4, 4), int32_t); }
 UPB_INLINE bool envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_has_watched_directory(const envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext *msg) { return _upb_hasbit(msg, 4); }
 UPB_INLINE const struct envoy_config_core_v3_WatchedDirectory* envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_watched_directory(const envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(24, 40), const struct envoy_config_core_v3_WatchedDirectory*); }
 UPB_INLINE bool envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_has_custom_validator_config(const envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext *msg) { return _upb_hasbit(msg, 5); }
 UPB_INLINE const struct envoy_config_core_v3_TypedExtensionConfig* envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_custom_validator_config(const envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(28, 48), const struct envoy_config_core_v3_TypedExtensionConfig*); }
+UPB_INLINE bool envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_has_ca_certificate_provider_instance(const envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext *msg) { return _upb_hasbit(msg, 6); }
+UPB_INLINE const envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance* envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_ca_certificate_provider_instance(const envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(32, 56), const envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance*); }
 
 UPB_INLINE void envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_set_trusted_ca(envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext *msg, struct envoy_config_core_v3_DataSource* value) {
   _upb_sethas(msg, 1);
@@ -375,23 +446,23 @@ UPB_INLINE struct envoy_config_core_v3_DataSource* envoy_extensions_transport_so
   return sub;
 }
 UPB_INLINE upb_strview* envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_mutable_verify_certificate_hash(envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext *msg, size_t *len) {
-  return (upb_strview*)_upb_array_mutable_accessor(msg, UPB_SIZE(32, 56), len);
+  return (upb_strview*)_upb_array_mutable_accessor(msg, UPB_SIZE(36, 64), len);
 }
 UPB_INLINE upb_strview* envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_resize_verify_certificate_hash(envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext *msg, size_t len, upb_arena *arena) {
-  return (upb_strview*)_upb_array_resize_accessor2(msg, UPB_SIZE(32, 56), len, UPB_SIZE(3, 4), arena);
+  return (upb_strview*)_upb_array_resize_accessor2(msg, UPB_SIZE(36, 64), len, UPB_SIZE(3, 4), arena);
 }
 UPB_INLINE bool envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_add_verify_certificate_hash(envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext *msg, upb_strview val, upb_arena *arena) {
-  return _upb_array_append_accessor2(msg, UPB_SIZE(32, 56), UPB_SIZE(3, 4), &val,
+  return _upb_array_append_accessor2(msg, UPB_SIZE(36, 64), UPB_SIZE(3, 4), &val,
       arena);
 }
 UPB_INLINE upb_strview* envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_mutable_verify_certificate_spki(envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext *msg, size_t *len) {
-  return (upb_strview*)_upb_array_mutable_accessor(msg, UPB_SIZE(36, 64), len);
+  return (upb_strview*)_upb_array_mutable_accessor(msg, UPB_SIZE(40, 72), len);
 }
 UPB_INLINE upb_strview* envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_resize_verify_certificate_spki(envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext *msg, size_t len, upb_arena *arena) {
-  return (upb_strview*)_upb_array_resize_accessor2(msg, UPB_SIZE(36, 64), len, UPB_SIZE(3, 4), arena);
+  return (upb_strview*)_upb_array_resize_accessor2(msg, UPB_SIZE(40, 72), len, UPB_SIZE(3, 4), arena);
 }
 UPB_INLINE bool envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_add_verify_certificate_spki(envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext *msg, upb_strview val, upb_arena *arena) {
-  return _upb_array_append_accessor2(msg, UPB_SIZE(36, 64), UPB_SIZE(3, 4), &val,
+  return _upb_array_append_accessor2(msg, UPB_SIZE(40, 72), UPB_SIZE(3, 4), &val,
       arena);
 }
 UPB_INLINE void envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_set_require_signed_certificate_timestamp(envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext *msg, struct google_protobuf_BoolValue* value) {
@@ -424,15 +495,15 @@ UPB_INLINE void envoy_extensions_transport_sockets_tls_v3_CertificateValidationC
   *UPB_PTR_AT(msg, UPB_SIZE(8, 8), bool) = value;
 }
 UPB_INLINE struct envoy_type_matcher_v3_StringMatcher** envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_mutable_match_subject_alt_names(envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext *msg, size_t *len) {
-  return (struct envoy_type_matcher_v3_StringMatcher**)_upb_array_mutable_accessor(msg, UPB_SIZE(40, 72), len);
+  return (struct envoy_type_matcher_v3_StringMatcher**)_upb_array_mutable_accessor(msg, UPB_SIZE(44, 80), len);
 }
 UPB_INLINE struct envoy_type_matcher_v3_StringMatcher** envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_resize_match_subject_alt_names(envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext *msg, size_t len, upb_arena *arena) {
-  return (struct envoy_type_matcher_v3_StringMatcher**)_upb_array_resize_accessor2(msg, UPB_SIZE(40, 72), len, UPB_SIZE(2, 3), arena);
+  return (struct envoy_type_matcher_v3_StringMatcher**)_upb_array_resize_accessor2(msg, UPB_SIZE(44, 80), len, UPB_SIZE(2, 3), arena);
 }
 UPB_INLINE struct envoy_type_matcher_v3_StringMatcher* envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_add_match_subject_alt_names(envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext *msg, upb_arena *arena) {
   struct envoy_type_matcher_v3_StringMatcher* sub = (struct envoy_type_matcher_v3_StringMatcher*)_upb_msg_new(&envoy_type_matcher_v3_StringMatcher_msginit, arena);
   bool ok = _upb_array_append_accessor2(
-      msg, UPB_SIZE(40, 72), UPB_SIZE(2, 3), &sub, arena);
+      msg, UPB_SIZE(44, 80), UPB_SIZE(2, 3), &sub, arena);
   if (!ok) return NULL;
   return sub;
 }
@@ -465,6 +536,19 @@ UPB_INLINE struct envoy_config_core_v3_TypedExtensionConfig* envoy_extensions_tr
   }
   return sub;
 }
+UPB_INLINE void envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_set_ca_certificate_provider_instance(envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext *msg, envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance* value) {
+  _upb_sethas(msg, 6);
+  *UPB_PTR_AT(msg, UPB_SIZE(32, 56), envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance*) = value;
+}
+UPB_INLINE struct envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance* envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_mutable_ca_certificate_provider_instance(envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext *msg, upb_arena *arena) {
+  struct envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance* sub = (struct envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance*)envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_ca_certificate_provider_instance(msg);
+  if (sub == NULL) {
+    sub = (struct envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance*)_upb_msg_new(&envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance_msginit, arena);
+    if (!sub) return NULL;
+    envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_set_ca_certificate_provider_instance(msg, sub);
+  }
+  return sub;
+}
 
 #ifdef __cplusplus
 }  /* extern "C" */
index 6717a17..9b0410c 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/extensions/transport_sockets/tls/v3/secret.upb.h"
 #include "envoy/config/core/v3/base.upb.h"
 #include "envoy/config/core/v3/config_source.upb.h"
@@ -24,13 +24,13 @@ static const upb_msglayout *const envoy_extensions_transport_sockets_tls_v3_Gene
 };
 
 static const upb_msglayout_field envoy_extensions_transport_sockets_tls_v3_GenericSecret__fields[1] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_extensions_transport_sockets_tls_v3_GenericSecret_msginit = {
   &envoy_extensions_transport_sockets_tls_v3_GenericSecret_submsgs[0],
   &envoy_extensions_transport_sockets_tls_v3_GenericSecret__fields[0],
-  UPB_SIZE(8, 16), 1, false, 255,
+  UPB_SIZE(8, 16), 1, false, 1, 255,
 };
 
 static const upb_msglayout *const envoy_extensions_transport_sockets_tls_v3_SdsSecretConfig_submsgs[1] = {
@@ -38,14 +38,14 @@ static const upb_msglayout *const envoy_extensions_transport_sockets_tls_v3_SdsS
 };
 
 static const upb_msglayout_field envoy_extensions_transport_sockets_tls_v3_SdsSecretConfig__fields[2] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(12, 24), 1, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(12, 24), 1, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_extensions_transport_sockets_tls_v3_SdsSecretConfig_msginit = {
   &envoy_extensions_transport_sockets_tls_v3_SdsSecretConfig_submsgs[0],
   &envoy_extensions_transport_sockets_tls_v3_SdsSecretConfig__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_extensions_transport_sockets_tls_v3_Secret_submsgs[4] = {
@@ -56,17 +56,17 @@ static const upb_msglayout *const envoy_extensions_transport_sockets_tls_v3_Secr
 };
 
 static const upb_msglayout_field envoy_extensions_transport_sockets_tls_v3_Secret__fields[5] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {2, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 2, 11, 1},
-  {3, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 3, 11, 1},
-  {4, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 0, 11, 1},
-  {5, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 1, 11, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 2, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 3, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 0, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 1, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_extensions_transport_sockets_tls_v3_Secret_msginit = {
   &envoy_extensions_transport_sockets_tls_v3_Secret_submsgs[0],
   &envoy_extensions_transport_sockets_tls_v3_Secret__fields[0],
-  UPB_SIZE(16, 32), 5, false, 255,
+  UPB_SIZE(16, 32), 5, false, 5, 255,
 };
 
 #include "upb/port_undef.inc"
index c576e0a..07d2e11 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_EXTENSIONS_TRANSPORT_SOCKETS_TLS_V3_SECRET_PROTO_UPB_H_
 #define ENVOY_EXTENSIONS_TRANSPORT_SOCKETS_TLS_V3_SECRET_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -49,13 +49,19 @@ UPB_INLINE envoy_extensions_transport_sockets_tls_v3_GenericSecret *envoy_extens
 UPB_INLINE envoy_extensions_transport_sockets_tls_v3_GenericSecret *envoy_extensions_transport_sockets_tls_v3_GenericSecret_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_extensions_transport_sockets_tls_v3_GenericSecret *ret = envoy_extensions_transport_sockets_tls_v3_GenericSecret_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_extensions_transport_sockets_tls_v3_GenericSecret_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_extensions_transport_sockets_tls_v3_GenericSecret_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_extensions_transport_sockets_tls_v3_GenericSecret *envoy_extensions_transport_sockets_tls_v3_GenericSecret_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_extensions_transport_sockets_tls_v3_GenericSecret *ret = envoy_extensions_transport_sockets_tls_v3_GenericSecret_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_extensions_transport_sockets_tls_v3_GenericSecret_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_extensions_transport_sockets_tls_v3_GenericSecret_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_extensions_transport_sockets_tls_v3_GenericSecret_serialize(const envoy_extensions_transport_sockets_tls_v3_GenericSecret *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_extensions_transport_sockets_tls_v3_GenericSecret_msginit, arena, len);
@@ -86,13 +92,19 @@ UPB_INLINE envoy_extensions_transport_sockets_tls_v3_SdsSecretConfig *envoy_exte
 UPB_INLINE envoy_extensions_transport_sockets_tls_v3_SdsSecretConfig *envoy_extensions_transport_sockets_tls_v3_SdsSecretConfig_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_extensions_transport_sockets_tls_v3_SdsSecretConfig *ret = envoy_extensions_transport_sockets_tls_v3_SdsSecretConfig_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_extensions_transport_sockets_tls_v3_SdsSecretConfig_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_extensions_transport_sockets_tls_v3_SdsSecretConfig_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_extensions_transport_sockets_tls_v3_SdsSecretConfig *envoy_extensions_transport_sockets_tls_v3_SdsSecretConfig_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_extensions_transport_sockets_tls_v3_SdsSecretConfig *ret = envoy_extensions_transport_sockets_tls_v3_SdsSecretConfig_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_extensions_transport_sockets_tls_v3_SdsSecretConfig_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_extensions_transport_sockets_tls_v3_SdsSecretConfig_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_extensions_transport_sockets_tls_v3_SdsSecretConfig_serialize(const envoy_extensions_transport_sockets_tls_v3_SdsSecretConfig *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_extensions_transport_sockets_tls_v3_SdsSecretConfig_msginit, arena, len);
@@ -127,13 +139,19 @@ UPB_INLINE envoy_extensions_transport_sockets_tls_v3_Secret *envoy_extensions_tr
 UPB_INLINE envoy_extensions_transport_sockets_tls_v3_Secret *envoy_extensions_transport_sockets_tls_v3_Secret_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_extensions_transport_sockets_tls_v3_Secret *ret = envoy_extensions_transport_sockets_tls_v3_Secret_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_extensions_transport_sockets_tls_v3_Secret_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_extensions_transport_sockets_tls_v3_Secret_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_extensions_transport_sockets_tls_v3_Secret *envoy_extensions_transport_sockets_tls_v3_Secret_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_extensions_transport_sockets_tls_v3_Secret *ret = envoy_extensions_transport_sockets_tls_v3_Secret_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_extensions_transport_sockets_tls_v3_Secret_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_extensions_transport_sockets_tls_v3_Secret_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_extensions_transport_sockets_tls_v3_Secret_serialize(const envoy_extensions_transport_sockets_tls_v3_Secret *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_extensions_transport_sockets_tls_v3_Secret_msginit, arena, len);
index ad5494c..4aaa964 100644 (file)
@@ -7,14 +7,14 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/extensions/transport_sockets/tls/v3/tls.upb.h"
 #include "envoy/config/core/v3/extension.upb.h"
 #include "envoy/extensions/transport_sockets/tls/v3/common.upb.h"
 #include "envoy/extensions/transport_sockets/tls/v3/secret.upb.h"
 #include "google/protobuf/duration.upb.h"
 #include "google/protobuf/wrappers.upb.h"
-#include "udpa/annotations/migrate.upb.h"
+#include "envoy/annotations/deprecation.upb.h"
 #include "udpa/annotations/status.upb.h"
 #include "udpa/annotations/versioning.upb.h"
 #include "validate/validate.upb.h"
@@ -27,16 +27,16 @@ static const upb_msglayout *const envoy_extensions_transport_sockets_tls_v3_Upst
 };
 
 static const upb_msglayout_field envoy_extensions_transport_sockets_tls_v3_UpstreamTlsContext__fields[4] = {
-  {1, UPB_SIZE(12, 24), 1, 0, 11, 1},
-  {2, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {3, UPB_SIZE(1, 1), 0, 0, 8, 1},
-  {4, UPB_SIZE(16, 32), 2, 1, 11, 1},
+  {1, UPB_SIZE(12, 24), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(1, 1), 0, 0, 8, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(16, 32), 2, 1, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_extensions_transport_sockets_tls_v3_UpstreamTlsContext_msginit = {
   &envoy_extensions_transport_sockets_tls_v3_UpstreamTlsContext_submsgs[0],
   &envoy_extensions_transport_sockets_tls_v3_UpstreamTlsContext__fields[0],
-  UPB_SIZE(24, 48), 4, false, 255,
+  UPB_SIZE(24, 48), 4, false, 4, 255,
 };
 
 static const upb_msglayout *const envoy_extensions_transport_sockets_tls_v3_DownstreamTlsContext_submsgs[5] = {
@@ -48,24 +48,25 @@ static const upb_msglayout *const envoy_extensions_transport_sockets_tls_v3_Down
 };
 
 static const upb_msglayout_field envoy_extensions_transport_sockets_tls_v3_DownstreamTlsContext__fields[8] = {
-  {1, UPB_SIZE(8, 8), 1, 0, 11, 1},
-  {2, UPB_SIZE(12, 16), 2, 3, 11, 1},
-  {3, UPB_SIZE(16, 24), 3, 3, 11, 1},
-  {4, UPB_SIZE(24, 40), UPB_SIZE(-29, -49), 2, 11, 1},
-  {5, UPB_SIZE(24, 40), UPB_SIZE(-29, -49), 1, 11, 1},
-  {6, UPB_SIZE(20, 32), 4, 4, 11, 1},
-  {7, UPB_SIZE(24, 40), UPB_SIZE(-29, -49), 0, 8, 1},
-  {8, UPB_SIZE(4, 4), 0, 0, 14, 1},
+  {1, UPB_SIZE(8, 8), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(12, 16), 2, 3, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(16, 24), 3, 3, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(24, 40), UPB_SIZE(-29, -49), 2, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(24, 40), UPB_SIZE(-29, -49), 1, 11, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(20, 32), 4, 4, 11, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(24, 40), UPB_SIZE(-29, -49), 0, 8, _UPB_MODE_SCALAR},
+  {8, UPB_SIZE(4, 4), 0, 0, 14, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_extensions_transport_sockets_tls_v3_DownstreamTlsContext_msginit = {
   &envoy_extensions_transport_sockets_tls_v3_DownstreamTlsContext_submsgs[0],
   &envoy_extensions_transport_sockets_tls_v3_DownstreamTlsContext__fields[0],
-  UPB_SIZE(32, 56), 8, false, 255,
+  UPB_SIZE(32, 56), 8, false, 8, 255,
 };
 
-static const upb_msglayout *const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_submsgs[8] = {
+static const upb_msglayout *const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_submsgs[9] = {
   &envoy_config_core_v3_TypedExtensionConfig_msginit,
+  &envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance_msginit,
   &envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_msginit,
   &envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProvider_msginit,
   &envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProviderInstance_msginit,
@@ -75,25 +76,26 @@ static const upb_msglayout *const envoy_extensions_transport_sockets_tls_v3_Comm
   &envoy_extensions_transport_sockets_tls_v3_TlsParameters_msginit,
 };
 
-static const upb_msglayout_field envoy_extensions_transport_sockets_tls_v3_CommonTlsContext__fields[12] = {
-  {1, UPB_SIZE(4, 8), 1, 7, 11, 1},
-  {2, UPB_SIZE(20, 40), 0, 6, 11, 3},
-  {3, UPB_SIZE(32, 64), UPB_SIZE(-37, -73), 1, 11, 1},
-  {4, UPB_SIZE(24, 48), 0, 0, 9, 3},
-  {6, UPB_SIZE(28, 56), 0, 5, 11, 3},
-  {7, UPB_SIZE(32, 64), UPB_SIZE(-37, -73), 5, 11, 1},
-  {8, UPB_SIZE(32, 64), UPB_SIZE(-37, -73), 4, 11, 1},
-  {9, UPB_SIZE(8, 16), 2, 2, 11, 1},
-  {10, UPB_SIZE(32, 64), UPB_SIZE(-37, -73), 2, 11, 1},
-  {11, UPB_SIZE(12, 24), 3, 3, 11, 1},
-  {12, UPB_SIZE(32, 64), UPB_SIZE(-37, -73), 3, 11, 1},
-  {13, UPB_SIZE(16, 32), 4, 0, 11, 1},
+static const upb_msglayout_field envoy_extensions_transport_sockets_tls_v3_CommonTlsContext__fields[13] = {
+  {1, UPB_SIZE(4, 8), 1, 8, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(24, 48), 0, 7, 11, _UPB_MODE_ARRAY},
+  {3, UPB_SIZE(36, 72), UPB_SIZE(-41, -81), 2, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(28, 56), 0, 0, 9, _UPB_MODE_ARRAY},
+  {6, UPB_SIZE(32, 64), 0, 6, 11, _UPB_MODE_ARRAY},
+  {7, UPB_SIZE(36, 72), UPB_SIZE(-41, -81), 6, 11, _UPB_MODE_SCALAR},
+  {8, UPB_SIZE(36, 72), UPB_SIZE(-41, -81), 5, 11, _UPB_MODE_SCALAR},
+  {9, UPB_SIZE(8, 16), 2, 3, 11, _UPB_MODE_SCALAR},
+  {10, UPB_SIZE(36, 72), UPB_SIZE(-41, -81), 3, 11, _UPB_MODE_SCALAR},
+  {11, UPB_SIZE(12, 24), 3, 4, 11, _UPB_MODE_SCALAR},
+  {12, UPB_SIZE(36, 72), UPB_SIZE(-41, -81), 4, 11, _UPB_MODE_SCALAR},
+  {13, UPB_SIZE(16, 32), 4, 0, 11, _UPB_MODE_SCALAR},
+  {14, UPB_SIZE(20, 40), 5, 1, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_msginit = {
   &envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_submsgs[0],
   &envoy_extensions_transport_sockets_tls_v3_CommonTlsContext__fields[0],
-  UPB_SIZE(40, 80), 12, false, 255,
+  UPB_SIZE(48, 88), 13, false, 4, 255,
 };
 
 static const upb_msglayout *const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProvider_submsgs[1] = {
@@ -101,25 +103,25 @@ static const upb_msglayout *const envoy_extensions_transport_sockets_tls_v3_Comm
 };
 
 static const upb_msglayout_field envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProvider__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {2, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 0, 11, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProvider_msginit = {
   &envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProvider_submsgs[0],
   &envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProvider__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout_field envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProviderInstance__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {2, UPB_SIZE(8, 16), 0, 0, 9, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 0, 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProviderInstance_msginit = {
   NULL,
   &envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProviderInstance__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CombinedCertificateValidationContext_submsgs[4] = {
@@ -130,16 +132,16 @@ static const upb_msglayout *const envoy_extensions_transport_sockets_tls_v3_Comm
 };
 
 static const upb_msglayout_field envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CombinedCertificateValidationContext__fields[4] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
-  {2, UPB_SIZE(8, 16), 2, 3, 11, 1},
-  {3, UPB_SIZE(12, 24), 3, 1, 11, 1},
-  {4, UPB_SIZE(16, 32), 4, 2, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 2, 3, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(12, 24), 3, 1, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(16, 32), 4, 2, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CombinedCertificateValidationContext_msginit = {
   &envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CombinedCertificateValidationContext_submsgs[0],
   &envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CombinedCertificateValidationContext__fields[0],
-  UPB_SIZE(24, 40), 4, false, 255,
+  UPB_SIZE(24, 40), 4, false, 4, 255,
 };
 
 #include "upb/port_undef.inc"
index 8a8ba90..f106275 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_EXTENSIONS_TRANSPORT_SOCKETS_TLS_V3_TLS_PROTO_UPB_H_
 #define ENVOY_EXTENSIONS_TRANSPORT_SOCKETS_TLS_V3_TLS_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -39,6 +39,7 @@ extern const upb_msglayout envoy_extensions_transport_sockets_tls_v3_CommonTlsCo
 extern const upb_msglayout envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProviderInstance_msginit;
 extern const upb_msglayout envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CombinedCertificateValidationContext_msginit;
 struct envoy_config_core_v3_TypedExtensionConfig;
+struct envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance;
 struct envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext;
 struct envoy_extensions_transport_sockets_tls_v3_SdsSecretConfig;
 struct envoy_extensions_transport_sockets_tls_v3_TlsCertificate;
@@ -48,6 +49,7 @@ struct google_protobuf_BoolValue;
 struct google_protobuf_Duration;
 struct google_protobuf_UInt32Value;
 extern const upb_msglayout envoy_config_core_v3_TypedExtensionConfig_msginit;
+extern const upb_msglayout envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance_msginit;
 extern const upb_msglayout envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_msginit;
 extern const upb_msglayout envoy_extensions_transport_sockets_tls_v3_SdsSecretConfig_msginit;
 extern const upb_msglayout envoy_extensions_transport_sockets_tls_v3_TlsCertificate_msginit;
@@ -72,13 +74,19 @@ UPB_INLINE envoy_extensions_transport_sockets_tls_v3_UpstreamTlsContext *envoy_e
 UPB_INLINE envoy_extensions_transport_sockets_tls_v3_UpstreamTlsContext *envoy_extensions_transport_sockets_tls_v3_UpstreamTlsContext_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_extensions_transport_sockets_tls_v3_UpstreamTlsContext *ret = envoy_extensions_transport_sockets_tls_v3_UpstreamTlsContext_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_extensions_transport_sockets_tls_v3_UpstreamTlsContext_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_extensions_transport_sockets_tls_v3_UpstreamTlsContext_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_extensions_transport_sockets_tls_v3_UpstreamTlsContext *envoy_extensions_transport_sockets_tls_v3_UpstreamTlsContext_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_extensions_transport_sockets_tls_v3_UpstreamTlsContext *ret = envoy_extensions_transport_sockets_tls_v3_UpstreamTlsContext_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_extensions_transport_sockets_tls_v3_UpstreamTlsContext_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_extensions_transport_sockets_tls_v3_UpstreamTlsContext_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_extensions_transport_sockets_tls_v3_UpstreamTlsContext_serialize(const envoy_extensions_transport_sockets_tls_v3_UpstreamTlsContext *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_extensions_transport_sockets_tls_v3_UpstreamTlsContext_msginit, arena, len);
@@ -132,13 +140,19 @@ UPB_INLINE envoy_extensions_transport_sockets_tls_v3_DownstreamTlsContext *envoy
 UPB_INLINE envoy_extensions_transport_sockets_tls_v3_DownstreamTlsContext *envoy_extensions_transport_sockets_tls_v3_DownstreamTlsContext_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_extensions_transport_sockets_tls_v3_DownstreamTlsContext *ret = envoy_extensions_transport_sockets_tls_v3_DownstreamTlsContext_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_extensions_transport_sockets_tls_v3_DownstreamTlsContext_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_extensions_transport_sockets_tls_v3_DownstreamTlsContext_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_extensions_transport_sockets_tls_v3_DownstreamTlsContext *envoy_extensions_transport_sockets_tls_v3_DownstreamTlsContext_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_extensions_transport_sockets_tls_v3_DownstreamTlsContext *ret = envoy_extensions_transport_sockets_tls_v3_DownstreamTlsContext_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_extensions_transport_sockets_tls_v3_DownstreamTlsContext_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_extensions_transport_sockets_tls_v3_DownstreamTlsContext_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_extensions_transport_sockets_tls_v3_DownstreamTlsContext_serialize(const envoy_extensions_transport_sockets_tls_v3_DownstreamTlsContext *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_extensions_transport_sockets_tls_v3_DownstreamTlsContext_msginit, arena, len);
@@ -259,13 +273,19 @@ UPB_INLINE envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *envoy_ext
 UPB_INLINE envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *ret = envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *ret = envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_serialize(const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_msginit, arena, len);
@@ -279,31 +299,33 @@ typedef enum {
   envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_validation_context_type_validation_context_certificate_provider_instance = 12,
   envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_validation_context_type_NOT_SET = 0
 } envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_validation_context_type_oneofcases;
-UPB_INLINE envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_validation_context_type_oneofcases envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_validation_context_type_case(const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext* msg) { return (envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_validation_context_type_oneofcases)*UPB_PTR_AT(msg, UPB_SIZE(36, 72), int32_t); }
+UPB_INLINE envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_validation_context_type_oneofcases envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_validation_context_type_case(const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext* msg) { return (envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_validation_context_type_oneofcases)*UPB_PTR_AT(msg, UPB_SIZE(40, 80), int32_t); }
 
 UPB_INLINE bool envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_has_tls_params(const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg) { return _upb_hasbit(msg, 1); }
 UPB_INLINE const struct envoy_extensions_transport_sockets_tls_v3_TlsParameters* envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_tls_params(const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(4, 8), const struct envoy_extensions_transport_sockets_tls_v3_TlsParameters*); }
-UPB_INLINE bool envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_has_tls_certificates(const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg) { return _upb_has_submsg_nohasbit(msg, UPB_SIZE(20, 40)); }
-UPB_INLINE const struct envoy_extensions_transport_sockets_tls_v3_TlsCertificate* const* envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_tls_certificates(const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg, size_t *len) { return (const struct envoy_extensions_transport_sockets_tls_v3_TlsCertificate* const*)_upb_array_accessor(msg, UPB_SIZE(20, 40), len); }
-UPB_INLINE bool envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_has_validation_context(const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg) { return _upb_getoneofcase(msg, UPB_SIZE(36, 72)) == 3; }
-UPB_INLINE const struct envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext* envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_validation_context(const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg) { return UPB_READ_ONEOF(msg, const struct envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext*, UPB_SIZE(32, 64), UPB_SIZE(36, 72), 3, NULL); }
-UPB_INLINE upb_strview const* envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_alpn_protocols(const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg, size_t *len) { return (upb_strview const*)_upb_array_accessor(msg, UPB_SIZE(24, 48), len); }
-UPB_INLINE bool envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_has_tls_certificate_sds_secret_configs(const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg) { return _upb_has_submsg_nohasbit(msg, UPB_SIZE(28, 56)); }
-UPB_INLINE const struct envoy_extensions_transport_sockets_tls_v3_SdsSecretConfig* const* envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_tls_certificate_sds_secret_configs(const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg, size_t *len) { return (const struct envoy_extensions_transport_sockets_tls_v3_SdsSecretConfig* const*)_upb_array_accessor(msg, UPB_SIZE(28, 56), len); }
-UPB_INLINE bool envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_has_validation_context_sds_secret_config(const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg) { return _upb_getoneofcase(msg, UPB_SIZE(36, 72)) == 7; }
-UPB_INLINE const struct envoy_extensions_transport_sockets_tls_v3_SdsSecretConfig* envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_validation_context_sds_secret_config(const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg) { return UPB_READ_ONEOF(msg, const struct envoy_extensions_transport_sockets_tls_v3_SdsSecretConfig*, UPB_SIZE(32, 64), UPB_SIZE(36, 72), 7, NULL); }
-UPB_INLINE bool envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_has_combined_validation_context(const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg) { return _upb_getoneofcase(msg, UPB_SIZE(36, 72)) == 8; }
-UPB_INLINE const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CombinedCertificateValidationContext* envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_combined_validation_context(const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg) { return UPB_READ_ONEOF(msg, const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CombinedCertificateValidationContext*, UPB_SIZE(32, 64), UPB_SIZE(36, 72), 8, NULL); }
+UPB_INLINE bool envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_has_tls_certificates(const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg) { return _upb_has_submsg_nohasbit(msg, UPB_SIZE(24, 48)); }
+UPB_INLINE const struct envoy_extensions_transport_sockets_tls_v3_TlsCertificate* const* envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_tls_certificates(const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg, size_t *len) { return (const struct envoy_extensions_transport_sockets_tls_v3_TlsCertificate* const*)_upb_array_accessor(msg, UPB_SIZE(24, 48), len); }
+UPB_INLINE bool envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_has_validation_context(const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg) { return _upb_getoneofcase(msg, UPB_SIZE(40, 80)) == 3; }
+UPB_INLINE const struct envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext* envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_validation_context(const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg) { return UPB_READ_ONEOF(msg, const struct envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext*, UPB_SIZE(36, 72), UPB_SIZE(40, 80), 3, NULL); }
+UPB_INLINE upb_strview const* envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_alpn_protocols(const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg, size_t *len) { return (upb_strview const*)_upb_array_accessor(msg, UPB_SIZE(28, 56), len); }
+UPB_INLINE bool envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_has_tls_certificate_sds_secret_configs(const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg) { return _upb_has_submsg_nohasbit(msg, UPB_SIZE(32, 64)); }
+UPB_INLINE const struct envoy_extensions_transport_sockets_tls_v3_SdsSecretConfig* const* envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_tls_certificate_sds_secret_configs(const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg, size_t *len) { return (const struct envoy_extensions_transport_sockets_tls_v3_SdsSecretConfig* const*)_upb_array_accessor(msg, UPB_SIZE(32, 64), len); }
+UPB_INLINE bool envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_has_validation_context_sds_secret_config(const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg) { return _upb_getoneofcase(msg, UPB_SIZE(40, 80)) == 7; }
+UPB_INLINE const struct envoy_extensions_transport_sockets_tls_v3_SdsSecretConfig* envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_validation_context_sds_secret_config(const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg) { return UPB_READ_ONEOF(msg, const struct envoy_extensions_transport_sockets_tls_v3_SdsSecretConfig*, UPB_SIZE(36, 72), UPB_SIZE(40, 80), 7, NULL); }
+UPB_INLINE bool envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_has_combined_validation_context(const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg) { return _upb_getoneofcase(msg, UPB_SIZE(40, 80)) == 8; }
+UPB_INLINE const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CombinedCertificateValidationContext* envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_combined_validation_context(const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg) { return UPB_READ_ONEOF(msg, const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CombinedCertificateValidationContext*, UPB_SIZE(36, 72), UPB_SIZE(40, 80), 8, NULL); }
 UPB_INLINE bool envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_has_tls_certificate_certificate_provider(const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg) { return _upb_hasbit(msg, 2); }
 UPB_INLINE const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProvider* envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_tls_certificate_certificate_provider(const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(8, 16), const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProvider*); }
-UPB_INLINE bool envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_has_validation_context_certificate_provider(const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg) { return _upb_getoneofcase(msg, UPB_SIZE(36, 72)) == 10; }
-UPB_INLINE const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProvider* envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_validation_context_certificate_provider(const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg) { return UPB_READ_ONEOF(msg, const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProvider*, UPB_SIZE(32, 64), UPB_SIZE(36, 72), 10, NULL); }
+UPB_INLINE bool envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_has_validation_context_certificate_provider(const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg) { return _upb_getoneofcase(msg, UPB_SIZE(40, 80)) == 10; }
+UPB_INLINE const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProvider* envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_validation_context_certificate_provider(const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg) { return UPB_READ_ONEOF(msg, const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProvider*, UPB_SIZE(36, 72), UPB_SIZE(40, 80), 10, NULL); }
 UPB_INLINE bool envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_has_tls_certificate_certificate_provider_instance(const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg) { return _upb_hasbit(msg, 3); }
 UPB_INLINE const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProviderInstance* envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_tls_certificate_certificate_provider_instance(const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(12, 24), const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProviderInstance*); }
-UPB_INLINE bool envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_has_validation_context_certificate_provider_instance(const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg) { return _upb_getoneofcase(msg, UPB_SIZE(36, 72)) == 12; }
-UPB_INLINE const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProviderInstance* envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_validation_context_certificate_provider_instance(const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg) { return UPB_READ_ONEOF(msg, const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProviderInstance*, UPB_SIZE(32, 64), UPB_SIZE(36, 72), 12, NULL); }
+UPB_INLINE bool envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_has_validation_context_certificate_provider_instance(const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg) { return _upb_getoneofcase(msg, UPB_SIZE(40, 80)) == 12; }
+UPB_INLINE const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProviderInstance* envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_validation_context_certificate_provider_instance(const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg) { return UPB_READ_ONEOF(msg, const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProviderInstance*, UPB_SIZE(36, 72), UPB_SIZE(40, 80), 12, NULL); }
 UPB_INLINE bool envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_has_custom_handshaker(const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg) { return _upb_hasbit(msg, 4); }
 UPB_INLINE const struct envoy_config_core_v3_TypedExtensionConfig* envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_custom_handshaker(const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(16, 32), const struct envoy_config_core_v3_TypedExtensionConfig*); }
+UPB_INLINE bool envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_has_tls_certificate_provider_instance(const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg) { return _upb_hasbit(msg, 5); }
+UPB_INLINE const struct envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance* envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_tls_certificate_provider_instance(const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(20, 40), const struct envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance*); }
 
 UPB_INLINE void envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_set_tls_params(envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg, struct envoy_extensions_transport_sockets_tls_v3_TlsParameters* value) {
   _upb_sethas(msg, 1);
@@ -319,20 +341,20 @@ UPB_INLINE struct envoy_extensions_transport_sockets_tls_v3_TlsParameters* envoy
   return sub;
 }
 UPB_INLINE struct envoy_extensions_transport_sockets_tls_v3_TlsCertificate** envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_mutable_tls_certificates(envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg, size_t *len) {
-  return (struct envoy_extensions_transport_sockets_tls_v3_TlsCertificate**)_upb_array_mutable_accessor(msg, UPB_SIZE(20, 40), len);
+  return (struct envoy_extensions_transport_sockets_tls_v3_TlsCertificate**)_upb_array_mutable_accessor(msg, UPB_SIZE(24, 48), len);
 }
 UPB_INLINE struct envoy_extensions_transport_sockets_tls_v3_TlsCertificate** envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_resize_tls_certificates(envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg, size_t len, upb_arena *arena) {
-  return (struct envoy_extensions_transport_sockets_tls_v3_TlsCertificate**)_upb_array_resize_accessor2(msg, UPB_SIZE(20, 40), len, UPB_SIZE(2, 3), arena);
+  return (struct envoy_extensions_transport_sockets_tls_v3_TlsCertificate**)_upb_array_resize_accessor2(msg, UPB_SIZE(24, 48), len, UPB_SIZE(2, 3), arena);
 }
 UPB_INLINE struct envoy_extensions_transport_sockets_tls_v3_TlsCertificate* envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_add_tls_certificates(envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg, upb_arena *arena) {
   struct envoy_extensions_transport_sockets_tls_v3_TlsCertificate* sub = (struct envoy_extensions_transport_sockets_tls_v3_TlsCertificate*)_upb_msg_new(&envoy_extensions_transport_sockets_tls_v3_TlsCertificate_msginit, arena);
   bool ok = _upb_array_append_accessor2(
-      msg, UPB_SIZE(20, 40), UPB_SIZE(2, 3), &sub, arena);
+      msg, UPB_SIZE(24, 48), UPB_SIZE(2, 3), &sub, arena);
   if (!ok) return NULL;
   return sub;
 }
 UPB_INLINE void envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_set_validation_context(envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg, struct envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext* value) {
-  UPB_WRITE_ONEOF(msg, struct envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext*, UPB_SIZE(32, 64), value, UPB_SIZE(36, 72), 3);
+  UPB_WRITE_ONEOF(msg, struct envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext*, UPB_SIZE(36, 72), value, UPB_SIZE(40, 80), 3);
 }
 UPB_INLINE struct envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext* envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_mutable_validation_context(envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg, upb_arena *arena) {
   struct envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext* sub = (struct envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext*)envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_validation_context(msg);
@@ -344,30 +366,30 @@ UPB_INLINE struct envoy_extensions_transport_sockets_tls_v3_CertificateValidatio
   return sub;
 }
 UPB_INLINE upb_strview* envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_mutable_alpn_protocols(envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg, size_t *len) {
-  return (upb_strview*)_upb_array_mutable_accessor(msg, UPB_SIZE(24, 48), len);
+  return (upb_strview*)_upb_array_mutable_accessor(msg, UPB_SIZE(28, 56), len);
 }
 UPB_INLINE upb_strview* envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_resize_alpn_protocols(envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg, size_t len, upb_arena *arena) {
-  return (upb_strview*)_upb_array_resize_accessor2(msg, UPB_SIZE(24, 48), len, UPB_SIZE(3, 4), arena);
+  return (upb_strview*)_upb_array_resize_accessor2(msg, UPB_SIZE(28, 56), len, UPB_SIZE(3, 4), arena);
 }
 UPB_INLINE bool envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_add_alpn_protocols(envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg, upb_strview val, upb_arena *arena) {
-  return _upb_array_append_accessor2(msg, UPB_SIZE(24, 48), UPB_SIZE(3, 4), &val,
+  return _upb_array_append_accessor2(msg, UPB_SIZE(28, 56), UPB_SIZE(3, 4), &val,
       arena);
 }
 UPB_INLINE struct envoy_extensions_transport_sockets_tls_v3_SdsSecretConfig** envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_mutable_tls_certificate_sds_secret_configs(envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg, size_t *len) {
-  return (struct envoy_extensions_transport_sockets_tls_v3_SdsSecretConfig**)_upb_array_mutable_accessor(msg, UPB_SIZE(28, 56), len);
+  return (struct envoy_extensions_transport_sockets_tls_v3_SdsSecretConfig**)_upb_array_mutable_accessor(msg, UPB_SIZE(32, 64), len);
 }
 UPB_INLINE struct envoy_extensions_transport_sockets_tls_v3_SdsSecretConfig** envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_resize_tls_certificate_sds_secret_configs(envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg, size_t len, upb_arena *arena) {
-  return (struct envoy_extensions_transport_sockets_tls_v3_SdsSecretConfig**)_upb_array_resize_accessor2(msg, UPB_SIZE(28, 56), len, UPB_SIZE(2, 3), arena);
+  return (struct envoy_extensions_transport_sockets_tls_v3_SdsSecretConfig**)_upb_array_resize_accessor2(msg, UPB_SIZE(32, 64), len, UPB_SIZE(2, 3), arena);
 }
 UPB_INLINE struct envoy_extensions_transport_sockets_tls_v3_SdsSecretConfig* envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_add_tls_certificate_sds_secret_configs(envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg, upb_arena *arena) {
   struct envoy_extensions_transport_sockets_tls_v3_SdsSecretConfig* sub = (struct envoy_extensions_transport_sockets_tls_v3_SdsSecretConfig*)_upb_msg_new(&envoy_extensions_transport_sockets_tls_v3_SdsSecretConfig_msginit, arena);
   bool ok = _upb_array_append_accessor2(
-      msg, UPB_SIZE(28, 56), UPB_SIZE(2, 3), &sub, arena);
+      msg, UPB_SIZE(32, 64), UPB_SIZE(2, 3), &sub, arena);
   if (!ok) return NULL;
   return sub;
 }
 UPB_INLINE void envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_set_validation_context_sds_secret_config(envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg, struct envoy_extensions_transport_sockets_tls_v3_SdsSecretConfig* value) {
-  UPB_WRITE_ONEOF(msg, struct envoy_extensions_transport_sockets_tls_v3_SdsSecretConfig*, UPB_SIZE(32, 64), value, UPB_SIZE(36, 72), 7);
+  UPB_WRITE_ONEOF(msg, struct envoy_extensions_transport_sockets_tls_v3_SdsSecretConfig*, UPB_SIZE(36, 72), value, UPB_SIZE(40, 80), 7);
 }
 UPB_INLINE struct envoy_extensions_transport_sockets_tls_v3_SdsSecretConfig* envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_mutable_validation_context_sds_secret_config(envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg, upb_arena *arena) {
   struct envoy_extensions_transport_sockets_tls_v3_SdsSecretConfig* sub = (struct envoy_extensions_transport_sockets_tls_v3_SdsSecretConfig*)envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_validation_context_sds_secret_config(msg);
@@ -379,7 +401,7 @@ UPB_INLINE struct envoy_extensions_transport_sockets_tls_v3_SdsSecretConfig* env
   return sub;
 }
 UPB_INLINE void envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_set_combined_validation_context(envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg, envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CombinedCertificateValidationContext* value) {
-  UPB_WRITE_ONEOF(msg, envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CombinedCertificateValidationContext*, UPB_SIZE(32, 64), value, UPB_SIZE(36, 72), 8);
+  UPB_WRITE_ONEOF(msg, envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CombinedCertificateValidationContext*, UPB_SIZE(36, 72), value, UPB_SIZE(40, 80), 8);
 }
 UPB_INLINE struct envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CombinedCertificateValidationContext* envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_mutable_combined_validation_context(envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg, upb_arena *arena) {
   struct envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CombinedCertificateValidationContext* sub = (struct envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CombinedCertificateValidationContext*)envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_combined_validation_context(msg);
@@ -404,7 +426,7 @@ UPB_INLINE struct envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_Cer
   return sub;
 }
 UPB_INLINE void envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_set_validation_context_certificate_provider(envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg, envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProvider* value) {
-  UPB_WRITE_ONEOF(msg, envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProvider*, UPB_SIZE(32, 64), value, UPB_SIZE(36, 72), 10);
+  UPB_WRITE_ONEOF(msg, envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProvider*, UPB_SIZE(36, 72), value, UPB_SIZE(40, 80), 10);
 }
 UPB_INLINE struct envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProvider* envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_mutable_validation_context_certificate_provider(envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg, upb_arena *arena) {
   struct envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProvider* sub = (struct envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProvider*)envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_validation_context_certificate_provider(msg);
@@ -429,7 +451,7 @@ UPB_INLINE struct envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_Cer
   return sub;
 }
 UPB_INLINE void envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_set_validation_context_certificate_provider_instance(envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg, envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProviderInstance* value) {
-  UPB_WRITE_ONEOF(msg, envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProviderInstance*, UPB_SIZE(32, 64), value, UPB_SIZE(36, 72), 12);
+  UPB_WRITE_ONEOF(msg, envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProviderInstance*, UPB_SIZE(36, 72), value, UPB_SIZE(40, 80), 12);
 }
 UPB_INLINE struct envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProviderInstance* envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_mutable_validation_context_certificate_provider_instance(envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg, upb_arena *arena) {
   struct envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProviderInstance* sub = (struct envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProviderInstance*)envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_validation_context_certificate_provider_instance(msg);
@@ -453,6 +475,19 @@ UPB_INLINE struct envoy_config_core_v3_TypedExtensionConfig* envoy_extensions_tr
   }
   return sub;
 }
+UPB_INLINE void envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_set_tls_certificate_provider_instance(envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg, struct envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance* value) {
+  _upb_sethas(msg, 5);
+  *UPB_PTR_AT(msg, UPB_SIZE(20, 40), struct envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance*) = value;
+}
+UPB_INLINE struct envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance* envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_mutable_tls_certificate_provider_instance(envoy_extensions_transport_sockets_tls_v3_CommonTlsContext *msg, upb_arena *arena) {
+  struct envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance* sub = (struct envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance*)envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_tls_certificate_provider_instance(msg);
+  if (sub == NULL) {
+    sub = (struct envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance*)_upb_msg_new(&envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance_msginit, arena);
+    if (!sub) return NULL;
+    envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_set_tls_certificate_provider_instance(msg, sub);
+  }
+  return sub;
+}
 
 /* envoy.extensions.transport_sockets.tls.v3.CommonTlsContext.CertificateProvider */
 
@@ -462,13 +497,19 @@ UPB_INLINE envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_Certificat
 UPB_INLINE envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProvider *envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProvider_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProvider *ret = envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProvider_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProvider_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProvider_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProvider *envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProvider_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProvider *ret = envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProvider_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProvider_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProvider_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProvider_serialize(const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProvider *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProvider_msginit, arena, len);
@@ -508,13 +549,19 @@ UPB_INLINE envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_Certificat
 UPB_INLINE envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProviderInstance *envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProviderInstance_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProviderInstance *ret = envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProviderInstance_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProviderInstance_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProviderInstance_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProviderInstance *envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProviderInstance_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProviderInstance *ret = envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProviderInstance_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProviderInstance_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProviderInstance_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProviderInstance_serialize(const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProviderInstance *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProviderInstance_msginit, arena, len);
@@ -538,13 +585,19 @@ UPB_INLINE envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CombinedCe
 UPB_INLINE envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CombinedCertificateValidationContext *envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CombinedCertificateValidationContext_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CombinedCertificateValidationContext *ret = envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CombinedCertificateValidationContext_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CombinedCertificateValidationContext_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CombinedCertificateValidationContext_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CombinedCertificateValidationContext *envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CombinedCertificateValidationContext_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CombinedCertificateValidationContext *ret = envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CombinedCertificateValidationContext_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CombinedCertificateValidationContext_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CombinedCertificateValidationContext_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CombinedCertificateValidationContext_serialize(const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CombinedCertificateValidationContext *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CombinedCertificateValidationContext_msginit, arena, len);
index cc8dcc4..737242b 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/service/cluster/v3/cds.upb.h"
 #include "envoy/service/discovery/v3/discovery.upb.h"
 #include "google/api/annotations.upb.h"
@@ -20,7 +20,7 @@
 const upb_msglayout envoy_service_cluster_v3_CdsDummy_msginit = {
   NULL,
   NULL,
-  UPB_SIZE(0, 0), 0, false, 255,
+  UPB_SIZE(0, 0), 0, false, 0, 255,
 };
 
 #include "upb/port_undef.inc"
index 86fa302..e716c68 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_SERVICE_CLUSTER_V3_CDS_PROTO_UPB_H_
 #define ENVOY_SERVICE_CLUSTER_V3_CDS_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -33,13 +33,19 @@ UPB_INLINE envoy_service_cluster_v3_CdsDummy *envoy_service_cluster_v3_CdsDummy_
 UPB_INLINE envoy_service_cluster_v3_CdsDummy *envoy_service_cluster_v3_CdsDummy_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_service_cluster_v3_CdsDummy *ret = envoy_service_cluster_v3_CdsDummy_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_service_cluster_v3_CdsDummy_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_service_cluster_v3_CdsDummy_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_service_cluster_v3_CdsDummy *envoy_service_cluster_v3_CdsDummy_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_service_cluster_v3_CdsDummy *ret = envoy_service_cluster_v3_CdsDummy_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_service_cluster_v3_CdsDummy_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_service_cluster_v3_CdsDummy_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_service_cluster_v3_CdsDummy_serialize(const envoy_service_cluster_v3_CdsDummy *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_service_cluster_v3_CdsDummy_msginit, arena, len);
index 7fb8ac9..f7535f7 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/service/discovery/v3/ads.upb.h"
 #include "envoy/service/discovery/v3/discovery.upb.h"
 #include "udpa/annotations/status.upb.h"
@@ -18,7 +18,7 @@
 const upb_msglayout envoy_service_discovery_v3_AdsDummy_msginit = {
   NULL,
   NULL,
-  UPB_SIZE(0, 0), 0, false, 255,
+  UPB_SIZE(0, 0), 0, false, 0, 255,
 };
 
 #include "upb/port_undef.inc"
index 0d26bd9..d2ed589 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_SERVICE_DISCOVERY_V3_ADS_PROTO_UPB_H_
 #define ENVOY_SERVICE_DISCOVERY_V3_ADS_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -33,13 +33,19 @@ UPB_INLINE envoy_service_discovery_v3_AdsDummy *envoy_service_discovery_v3_AdsDu
 UPB_INLINE envoy_service_discovery_v3_AdsDummy *envoy_service_discovery_v3_AdsDummy_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_service_discovery_v3_AdsDummy *ret = envoy_service_discovery_v3_AdsDummy_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_service_discovery_v3_AdsDummy_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_service_discovery_v3_AdsDummy_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_service_discovery_v3_AdsDummy *envoy_service_discovery_v3_AdsDummy_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_service_discovery_v3_AdsDummy *ret = envoy_service_discovery_v3_AdsDummy_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_service_discovery_v3_AdsDummy_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_service_discovery_v3_AdsDummy_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_service_discovery_v3_AdsDummy_serialize(const envoy_service_discovery_v3_AdsDummy *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_service_discovery_v3_AdsDummy_msginit, arena, len);
index a5b6ac4..2479527 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/service/discovery/v3/discovery.upb.h"
 #include "envoy/config/core/v3/base.upb.h"
 #include "google/protobuf/any.upb.h"
@@ -24,18 +24,18 @@ static const upb_msglayout *const envoy_service_discovery_v3_DiscoveryRequest_su
 };
 
 static const upb_msglayout_field envoy_service_discovery_v3_DiscoveryRequest__fields[6] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(28, 56), 1, 0, 11, 1},
-  {3, UPB_SIZE(36, 72), 0, 0, 9, 3},
-  {4, UPB_SIZE(12, 24), 0, 0, 9, 1},
-  {5, UPB_SIZE(20, 40), 0, 0, 9, 1},
-  {6, UPB_SIZE(32, 64), 2, 1, 11, 1},
+  {1, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(28, 56), 1, 0, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(36, 72), 0, 0, 9, _UPB_MODE_ARRAY},
+  {4, UPB_SIZE(12, 24), 0, 0, 9, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(20, 40), 0, 0, 9, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(32, 64), 2, 1, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_service_discovery_v3_DiscoveryRequest_msginit = {
   &envoy_service_discovery_v3_DiscoveryRequest_submsgs[0],
   &envoy_service_discovery_v3_DiscoveryRequest__fields[0],
-  UPB_SIZE(40, 80), 6, false, 255,
+  UPB_SIZE(40, 80), 6, false, 6, 255,
 };
 
 static const upb_msglayout *const envoy_service_discovery_v3_DiscoveryResponse_submsgs[2] = {
@@ -44,18 +44,18 @@ static const upb_msglayout *const envoy_service_discovery_v3_DiscoveryResponse_s
 };
 
 static const upb_msglayout_field envoy_service_discovery_v3_DiscoveryResponse__fields[6] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(32, 64), 0, 1, 11, 3},
-  {3, UPB_SIZE(1, 1), 0, 0, 8, 1},
-  {4, UPB_SIZE(12, 24), 0, 0, 9, 1},
-  {5, UPB_SIZE(20, 40), 0, 0, 9, 1},
-  {6, UPB_SIZE(28, 56), 1, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(32, 64), 0, 1, 11, _UPB_MODE_ARRAY},
+  {3, UPB_SIZE(1, 1), 0, 0, 8, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(12, 24), 0, 0, 9, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(20, 40), 0, 0, 9, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(28, 56), 1, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_service_discovery_v3_DiscoveryResponse_msginit = {
   &envoy_service_discovery_v3_DiscoveryResponse_submsgs[0],
   &envoy_service_discovery_v3_DiscoveryResponse__fields[0],
-  UPB_SIZE(40, 80), 6, false, 255,
+  UPB_SIZE(40, 80), 6, false, 6, 255,
 };
 
 static const upb_msglayout *const envoy_service_discovery_v3_DeltaDiscoveryRequest_submsgs[3] = {
@@ -65,30 +65,30 @@ static const upb_msglayout *const envoy_service_discovery_v3_DeltaDiscoveryReque
 };
 
 static const upb_msglayout_field envoy_service_discovery_v3_DeltaDiscoveryRequest__fields[7] = {
-  {1, UPB_SIZE(20, 40), 1, 0, 11, 1},
-  {2, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {3, UPB_SIZE(28, 56), 0, 0, 9, 3},
-  {4, UPB_SIZE(32, 64), 0, 0, 9, 3},
-  {5, UPB_SIZE(36, 72), 0, 1, 11, _UPB_LABEL_MAP},
-  {6, UPB_SIZE(12, 24), 0, 0, 9, 1},
-  {7, UPB_SIZE(24, 48), 2, 2, 11, 1},
+  {1, UPB_SIZE(20, 40), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(28, 56), 0, 0, 9, _UPB_MODE_ARRAY},
+  {4, UPB_SIZE(32, 64), 0, 0, 9, _UPB_MODE_ARRAY},
+  {5, UPB_SIZE(36, 72), 0, 1, 11, _UPB_MODE_MAP},
+  {6, UPB_SIZE(12, 24), 0, 0, 9, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(24, 48), 2, 2, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_service_discovery_v3_DeltaDiscoveryRequest_msginit = {
   &envoy_service_discovery_v3_DeltaDiscoveryRequest_submsgs[0],
   &envoy_service_discovery_v3_DeltaDiscoveryRequest__fields[0],
-  UPB_SIZE(40, 80), 7, false, 255,
+  UPB_SIZE(40, 80), 7, false, 7, 255,
 };
 
 static const upb_msglayout_field envoy_service_discovery_v3_DeltaDiscoveryRequest_InitialResourceVersionsEntry__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {2, UPB_SIZE(8, 16), 0, 0, 9, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 0, 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_service_discovery_v3_DeltaDiscoveryRequest_InitialResourceVersionsEntry_msginit = {
   NULL,
   &envoy_service_discovery_v3_DeltaDiscoveryRequest_InitialResourceVersionsEntry__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_service_discovery_v3_DeltaDiscoveryResponse_submsgs[2] = {
@@ -97,18 +97,18 @@ static const upb_msglayout *const envoy_service_discovery_v3_DeltaDiscoveryRespo
 };
 
 static const upb_msglayout_field envoy_service_discovery_v3_DeltaDiscoveryResponse__fields[6] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(32, 64), 0, 1, 11, 3},
-  {4, UPB_SIZE(12, 24), 0, 0, 9, 1},
-  {5, UPB_SIZE(20, 40), 0, 0, 9, 1},
-  {6, UPB_SIZE(36, 72), 0, 0, 9, 3},
-  {7, UPB_SIZE(28, 56), 1, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(32, 64), 0, 1, 11, _UPB_MODE_ARRAY},
+  {4, UPB_SIZE(12, 24), 0, 0, 9, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(20, 40), 0, 0, 9, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(36, 72), 0, 0, 9, _UPB_MODE_ARRAY},
+  {7, UPB_SIZE(28, 56), 1, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_service_discovery_v3_DeltaDiscoveryResponse_msginit = {
   &envoy_service_discovery_v3_DeltaDiscoveryResponse_submsgs[0],
   &envoy_service_discovery_v3_DeltaDiscoveryResponse__fields[0],
-  UPB_SIZE(40, 80), 6, false, 255,
+  UPB_SIZE(40, 80), 6, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_service_discovery_v3_Resource_submsgs[3] = {
@@ -118,28 +118,28 @@ static const upb_msglayout *const envoy_service_discovery_v3_Resource_submsgs[3]
 };
 
 static const upb_msglayout_field envoy_service_discovery_v3_Resource__fields[6] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(20, 40), 1, 1, 11, 1},
-  {3, UPB_SIZE(12, 24), 0, 0, 9, 1},
-  {4, UPB_SIZE(32, 64), 0, 0, 9, 3},
-  {6, UPB_SIZE(24, 48), 2, 2, 11, 1},
-  {7, UPB_SIZE(28, 56), 3, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(20, 40), 1, 1, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(12, 24), 0, 0, 9, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(32, 64), 0, 0, 9, _UPB_MODE_ARRAY},
+  {6, UPB_SIZE(24, 48), 2, 2, 11, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(28, 56), 3, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_service_discovery_v3_Resource_msginit = {
   &envoy_service_discovery_v3_Resource_submsgs[0],
   &envoy_service_discovery_v3_Resource__fields[0],
-  UPB_SIZE(40, 80), 6, false, 255,
+  UPB_SIZE(40, 80), 6, false, 4, 255,
 };
 
 static const upb_msglayout_field envoy_service_discovery_v3_Resource_CacheControl__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 8, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 8, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_service_discovery_v3_Resource_CacheControl_msginit = {
   NULL,
   &envoy_service_discovery_v3_Resource_CacheControl__fields[0],
-  UPB_SIZE(8, 8), 1, false, 255,
+  UPB_SIZE(8, 8), 1, false, 1, 255,
 };
 
 #include "upb/port_undef.inc"
index def2787..105e033 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_SERVICE_DISCOVERY_V3_DISCOVERY_PROTO_UPB_H_
 #define ENVOY_SERVICE_DISCOVERY_V3_DISCOVERY_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -61,13 +61,19 @@ UPB_INLINE envoy_service_discovery_v3_DiscoveryRequest *envoy_service_discovery_
 UPB_INLINE envoy_service_discovery_v3_DiscoveryRequest *envoy_service_discovery_v3_DiscoveryRequest_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_service_discovery_v3_DiscoveryRequest *ret = envoy_service_discovery_v3_DiscoveryRequest_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_service_discovery_v3_DiscoveryRequest_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_service_discovery_v3_DiscoveryRequest_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_service_discovery_v3_DiscoveryRequest *envoy_service_discovery_v3_DiscoveryRequest_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_service_discovery_v3_DiscoveryRequest *ret = envoy_service_discovery_v3_DiscoveryRequest_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_service_discovery_v3_DiscoveryRequest_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_service_discovery_v3_DiscoveryRequest_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_service_discovery_v3_DiscoveryRequest_serialize(const envoy_service_discovery_v3_DiscoveryRequest *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_service_discovery_v3_DiscoveryRequest_msginit, arena, len);
@@ -136,13 +142,19 @@ UPB_INLINE envoy_service_discovery_v3_DiscoveryResponse *envoy_service_discovery
 UPB_INLINE envoy_service_discovery_v3_DiscoveryResponse *envoy_service_discovery_v3_DiscoveryResponse_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_service_discovery_v3_DiscoveryResponse *ret = envoy_service_discovery_v3_DiscoveryResponse_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_service_discovery_v3_DiscoveryResponse_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_service_discovery_v3_DiscoveryResponse_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_service_discovery_v3_DiscoveryResponse *envoy_service_discovery_v3_DiscoveryResponse_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_service_discovery_v3_DiscoveryResponse *ret = envoy_service_discovery_v3_DiscoveryResponse_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_service_discovery_v3_DiscoveryResponse_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_service_discovery_v3_DiscoveryResponse_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_service_discovery_v3_DiscoveryResponse_serialize(const envoy_service_discovery_v3_DiscoveryResponse *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_service_discovery_v3_DiscoveryResponse_msginit, arena, len);
@@ -204,13 +216,19 @@ UPB_INLINE envoy_service_discovery_v3_DeltaDiscoveryRequest *envoy_service_disco
 UPB_INLINE envoy_service_discovery_v3_DeltaDiscoveryRequest *envoy_service_discovery_v3_DeltaDiscoveryRequest_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_service_discovery_v3_DeltaDiscoveryRequest *ret = envoy_service_discovery_v3_DeltaDiscoveryRequest_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_service_discovery_v3_DeltaDiscoveryRequest_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_service_discovery_v3_DeltaDiscoveryRequest_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_service_discovery_v3_DeltaDiscoveryRequest *envoy_service_discovery_v3_DeltaDiscoveryRequest_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_service_discovery_v3_DeltaDiscoveryRequest *ret = envoy_service_discovery_v3_DeltaDiscoveryRequest_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_service_discovery_v3_DeltaDiscoveryRequest_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_service_discovery_v3_DeltaDiscoveryRequest_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_service_discovery_v3_DeltaDiscoveryRequest_serialize(const envoy_service_discovery_v3_DeltaDiscoveryRequest *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_service_discovery_v3_DeltaDiscoveryRequest_msginit, arena, len);
@@ -311,13 +329,19 @@ UPB_INLINE envoy_service_discovery_v3_DeltaDiscoveryResponse *envoy_service_disc
 UPB_INLINE envoy_service_discovery_v3_DeltaDiscoveryResponse *envoy_service_discovery_v3_DeltaDiscoveryResponse_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_service_discovery_v3_DeltaDiscoveryResponse *ret = envoy_service_discovery_v3_DeltaDiscoveryResponse_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_service_discovery_v3_DeltaDiscoveryResponse_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_service_discovery_v3_DeltaDiscoveryResponse_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_service_discovery_v3_DeltaDiscoveryResponse *envoy_service_discovery_v3_DeltaDiscoveryResponse_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_service_discovery_v3_DeltaDiscoveryResponse *ret = envoy_service_discovery_v3_DeltaDiscoveryResponse_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_service_discovery_v3_DeltaDiscoveryResponse_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_service_discovery_v3_DeltaDiscoveryResponse_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_service_discovery_v3_DeltaDiscoveryResponse_serialize(const envoy_service_discovery_v3_DeltaDiscoveryResponse *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_service_discovery_v3_DeltaDiscoveryResponse_msginit, arena, len);
@@ -386,13 +410,19 @@ UPB_INLINE envoy_service_discovery_v3_Resource *envoy_service_discovery_v3_Resou
 UPB_INLINE envoy_service_discovery_v3_Resource *envoy_service_discovery_v3_Resource_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_service_discovery_v3_Resource *ret = envoy_service_discovery_v3_Resource_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_service_discovery_v3_Resource_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_service_discovery_v3_Resource_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_service_discovery_v3_Resource *envoy_service_discovery_v3_Resource_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_service_discovery_v3_Resource *ret = envoy_service_discovery_v3_Resource_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_service_discovery_v3_Resource_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_service_discovery_v3_Resource_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_service_discovery_v3_Resource_serialize(const envoy_service_discovery_v3_Resource *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_service_discovery_v3_Resource_msginit, arena, len);
@@ -472,13 +502,19 @@ UPB_INLINE envoy_service_discovery_v3_Resource_CacheControl *envoy_service_disco
 UPB_INLINE envoy_service_discovery_v3_Resource_CacheControl *envoy_service_discovery_v3_Resource_CacheControl_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_service_discovery_v3_Resource_CacheControl *ret = envoy_service_discovery_v3_Resource_CacheControl_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_service_discovery_v3_Resource_CacheControl_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_service_discovery_v3_Resource_CacheControl_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_service_discovery_v3_Resource_CacheControl *envoy_service_discovery_v3_Resource_CacheControl_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_service_discovery_v3_Resource_CacheControl *ret = envoy_service_discovery_v3_Resource_CacheControl_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_service_discovery_v3_Resource_CacheControl_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_service_discovery_v3_Resource_CacheControl_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_service_discovery_v3_Resource_CacheControl_serialize(const envoy_service_discovery_v3_Resource_CacheControl *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_service_discovery_v3_Resource_CacheControl_msginit, arena, len);
index 0af0480..7ceb472 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/service/endpoint/v3/eds.upb.h"
 #include "envoy/service/discovery/v3/discovery.upb.h"
 #include "google/api/annotations.upb.h"
@@ -20,7 +20,7 @@
 const upb_msglayout envoy_service_endpoint_v3_EdsDummy_msginit = {
   NULL,
   NULL,
-  UPB_SIZE(0, 0), 0, false, 255,
+  UPB_SIZE(0, 0), 0, false, 0, 255,
 };
 
 #include "upb/port_undef.inc"
index 1b1fd3d..565f669 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_SERVICE_ENDPOINT_V3_EDS_PROTO_UPB_H_
 #define ENVOY_SERVICE_ENDPOINT_V3_EDS_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -33,13 +33,19 @@ UPB_INLINE envoy_service_endpoint_v3_EdsDummy *envoy_service_endpoint_v3_EdsDumm
 UPB_INLINE envoy_service_endpoint_v3_EdsDummy *envoy_service_endpoint_v3_EdsDummy_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_service_endpoint_v3_EdsDummy *ret = envoy_service_endpoint_v3_EdsDummy_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_service_endpoint_v3_EdsDummy_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_service_endpoint_v3_EdsDummy_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_service_endpoint_v3_EdsDummy *envoy_service_endpoint_v3_EdsDummy_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_service_endpoint_v3_EdsDummy *ret = envoy_service_endpoint_v3_EdsDummy_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_service_endpoint_v3_EdsDummy_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_service_endpoint_v3_EdsDummy_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_service_endpoint_v3_EdsDummy_serialize(const envoy_service_endpoint_v3_EdsDummy *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_service_endpoint_v3_EdsDummy_msginit, arena, len);
index 404bfa4..87b6909 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/service/listener/v3/lds.upb.h"
 #include "envoy/service/discovery/v3/discovery.upb.h"
 #include "google/api/annotations.upb.h"
@@ -20,7 +20,7 @@
 const upb_msglayout envoy_service_listener_v3_LdsDummy_msginit = {
   NULL,
   NULL,
-  UPB_SIZE(0, 0), 0, false, 255,
+  UPB_SIZE(0, 0), 0, false, 0, 255,
 };
 
 #include "upb/port_undef.inc"
index 9b8988c..1a20545 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_SERVICE_LISTENER_V3_LDS_PROTO_UPB_H_
 #define ENVOY_SERVICE_LISTENER_V3_LDS_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -33,13 +33,19 @@ UPB_INLINE envoy_service_listener_v3_LdsDummy *envoy_service_listener_v3_LdsDumm
 UPB_INLINE envoy_service_listener_v3_LdsDummy *envoy_service_listener_v3_LdsDummy_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_service_listener_v3_LdsDummy *ret = envoy_service_listener_v3_LdsDummy_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_service_listener_v3_LdsDummy_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_service_listener_v3_LdsDummy_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_service_listener_v3_LdsDummy *envoy_service_listener_v3_LdsDummy_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_service_listener_v3_LdsDummy *ret = envoy_service_listener_v3_LdsDummy_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_service_listener_v3_LdsDummy_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_service_listener_v3_LdsDummy_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_service_listener_v3_LdsDummy_serialize(const envoy_service_listener_v3_LdsDummy *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_service_listener_v3_LdsDummy_msginit, arena, len);
index 68fe078..679b3c3 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/service/load_stats/v3/lrs.upb.h"
 #include "envoy/config/core/v3/base.upb.h"
 #include "envoy/config/endpoint/v3/load_report.upb.h"
@@ -23,14 +23,14 @@ static const upb_msglayout *const envoy_service_load_stats_v3_LoadStatsRequest_s
 };
 
 static const upb_msglayout_field envoy_service_load_stats_v3_LoadStatsRequest__fields[2] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
-  {2, UPB_SIZE(8, 16), 0, 1, 11, 3},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 0, 1, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout envoy_service_load_stats_v3_LoadStatsRequest_msginit = {
   &envoy_service_load_stats_v3_LoadStatsRequest_submsgs[0],
   &envoy_service_load_stats_v3_LoadStatsRequest__fields[0],
-  UPB_SIZE(16, 24), 2, false, 255,
+  UPB_SIZE(16, 24), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_service_load_stats_v3_LoadStatsResponse_submsgs[1] = {
@@ -38,16 +38,16 @@ static const upb_msglayout *const envoy_service_load_stats_v3_LoadStatsResponse_
 };
 
 static const upb_msglayout_field envoy_service_load_stats_v3_LoadStatsResponse__fields[4] = {
-  {1, UPB_SIZE(8, 16), 0, 0, 9, 3},
-  {2, UPB_SIZE(4, 8), 1, 0, 11, 1},
-  {3, UPB_SIZE(1, 1), 0, 0, 8, 1},
-  {4, UPB_SIZE(2, 2), 0, 0, 8, 1},
+  {1, UPB_SIZE(8, 16), 0, 0, 9, _UPB_MODE_ARRAY},
+  {2, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(1, 1), 0, 0, 8, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(2, 2), 0, 0, 8, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_service_load_stats_v3_LoadStatsResponse_msginit = {
   &envoy_service_load_stats_v3_LoadStatsResponse_submsgs[0],
   &envoy_service_load_stats_v3_LoadStatsResponse__fields[0],
-  UPB_SIZE(16, 24), 4, false, 255,
+  UPB_SIZE(16, 24), 4, false, 4, 255,
 };
 
 #include "upb/port_undef.inc"
index f74a023..5146f49 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_SERVICE_LOAD_STATS_V3_LRS_PROTO_UPB_H_
 #define ENVOY_SERVICE_LOAD_STATS_V3_LRS_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -42,13 +42,19 @@ UPB_INLINE envoy_service_load_stats_v3_LoadStatsRequest *envoy_service_load_stat
 UPB_INLINE envoy_service_load_stats_v3_LoadStatsRequest *envoy_service_load_stats_v3_LoadStatsRequest_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_service_load_stats_v3_LoadStatsRequest *ret = envoy_service_load_stats_v3_LoadStatsRequest_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_service_load_stats_v3_LoadStatsRequest_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_service_load_stats_v3_LoadStatsRequest_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_service_load_stats_v3_LoadStatsRequest *envoy_service_load_stats_v3_LoadStatsRequest_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_service_load_stats_v3_LoadStatsRequest *ret = envoy_service_load_stats_v3_LoadStatsRequest_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_service_load_stats_v3_LoadStatsRequest_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_service_load_stats_v3_LoadStatsRequest_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_service_load_stats_v3_LoadStatsRequest_serialize(const envoy_service_load_stats_v3_LoadStatsRequest *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_service_load_stats_v3_LoadStatsRequest_msginit, arena, len);
@@ -94,13 +100,19 @@ UPB_INLINE envoy_service_load_stats_v3_LoadStatsResponse *envoy_service_load_sta
 UPB_INLINE envoy_service_load_stats_v3_LoadStatsResponse *envoy_service_load_stats_v3_LoadStatsResponse_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_service_load_stats_v3_LoadStatsResponse *ret = envoy_service_load_stats_v3_LoadStatsResponse_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_service_load_stats_v3_LoadStatsResponse_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_service_load_stats_v3_LoadStatsResponse_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_service_load_stats_v3_LoadStatsResponse *envoy_service_load_stats_v3_LoadStatsResponse_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_service_load_stats_v3_LoadStatsResponse *ret = envoy_service_load_stats_v3_LoadStatsResponse_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_service_load_stats_v3_LoadStatsResponse_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_service_load_stats_v3_LoadStatsResponse_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_service_load_stats_v3_LoadStatsResponse_serialize(const envoy_service_load_stats_v3_LoadStatsResponse *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_service_load_stats_v3_LoadStatsResponse_msginit, arena, len);
index 07d17f6..3723455 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/service/route/v3/rds.upb.h"
 #include "envoy/service/discovery/v3/discovery.upb.h"
 #include "google/api/annotations.upb.h"
@@ -20,7 +20,7 @@
 const upb_msglayout envoy_service_route_v3_RdsDummy_msginit = {
   NULL,
   NULL,
-  UPB_SIZE(0, 0), 0, false, 255,
+  UPB_SIZE(0, 0), 0, false, 0, 255,
 };
 
 #include "upb/port_undef.inc"
index 40a6d42..20eeb8b 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_SERVICE_ROUTE_V3_RDS_PROTO_UPB_H_
 #define ENVOY_SERVICE_ROUTE_V3_RDS_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -33,13 +33,19 @@ UPB_INLINE envoy_service_route_v3_RdsDummy *envoy_service_route_v3_RdsDummy_new(
 UPB_INLINE envoy_service_route_v3_RdsDummy *envoy_service_route_v3_RdsDummy_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_service_route_v3_RdsDummy *ret = envoy_service_route_v3_RdsDummy_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_service_route_v3_RdsDummy_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_service_route_v3_RdsDummy_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_service_route_v3_RdsDummy *envoy_service_route_v3_RdsDummy_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_service_route_v3_RdsDummy *ret = envoy_service_route_v3_RdsDummy_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_service_route_v3_RdsDummy_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_service_route_v3_RdsDummy_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_service_route_v3_RdsDummy_serialize(const envoy_service_route_v3_RdsDummy *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_service_route_v3_RdsDummy_msginit, arena, len);
index 6dbaa81..01e3110 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/service/route/v3/srds.upb.h"
 #include "envoy/service/discovery/v3/discovery.upb.h"
 #include "google/api/annotations.upb.h"
@@ -20,7 +20,7 @@
 const upb_msglayout envoy_service_route_v3_SrdsDummy_msginit = {
   NULL,
   NULL,
-  UPB_SIZE(0, 0), 0, false, 255,
+  UPB_SIZE(0, 0), 0, false, 0, 255,
 };
 
 #include "upb/port_undef.inc"
index e86154b..a8486d5 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_SERVICE_ROUTE_V3_SRDS_PROTO_UPB_H_
 #define ENVOY_SERVICE_ROUTE_V3_SRDS_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -33,13 +33,19 @@ UPB_INLINE envoy_service_route_v3_SrdsDummy *envoy_service_route_v3_SrdsDummy_ne
 UPB_INLINE envoy_service_route_v3_SrdsDummy *envoy_service_route_v3_SrdsDummy_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_service_route_v3_SrdsDummy *ret = envoy_service_route_v3_SrdsDummy_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_service_route_v3_SrdsDummy_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_service_route_v3_SrdsDummy_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_service_route_v3_SrdsDummy *envoy_service_route_v3_SrdsDummy_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_service_route_v3_SrdsDummy *ret = envoy_service_route_v3_SrdsDummy_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_service_route_v3_SrdsDummy_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_service_route_v3_SrdsDummy_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_service_route_v3_SrdsDummy_serialize(const envoy_service_route_v3_SrdsDummy *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_service_route_v3_SrdsDummy_msginit, arena, len);
index fa36211..dae701e 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/service/status/v3/csds.upb.h"
 #include "envoy/admin/v3/config_dump.upb.h"
 #include "envoy/config/core/v3/base.upb.h"
@@ -27,14 +27,14 @@ static const upb_msglayout *const envoy_service_status_v3_ClientStatusRequest_su
 };
 
 static const upb_msglayout_field envoy_service_status_v3_ClientStatusRequest__fields[2] = {
-  {1, UPB_SIZE(8, 16), 0, 1, 11, 3},
-  {2, UPB_SIZE(4, 8), 1, 0, 11, 1},
+  {1, UPB_SIZE(8, 16), 0, 1, 11, _UPB_MODE_ARRAY},
+  {2, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_service_status_v3_ClientStatusRequest_msginit = {
   &envoy_service_status_v3_ClientStatusRequest_submsgs[0],
   &envoy_service_status_v3_ClientStatusRequest__fields[0],
-  UPB_SIZE(16, 24), 2, false, 255,
+  UPB_SIZE(16, 24), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_service_status_v3_PerXdsConfig_submsgs[5] = {
@@ -46,19 +46,19 @@ static const upb_msglayout *const envoy_service_status_v3_PerXdsConfig_submsgs[5
 };
 
 static const upb_msglayout_field envoy_service_status_v3_PerXdsConfig__fields[7] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 14, 1},
-  {2, UPB_SIZE(8, 8), UPB_SIZE(-13, -17), 2, 11, 1},
-  {3, UPB_SIZE(8, 8), UPB_SIZE(-13, -17), 0, 11, 1},
-  {4, UPB_SIZE(8, 8), UPB_SIZE(-13, -17), 3, 11, 1},
-  {5, UPB_SIZE(8, 8), UPB_SIZE(-13, -17), 4, 11, 1},
-  {6, UPB_SIZE(8, 8), UPB_SIZE(-13, -17), 1, 11, 1},
-  {7, UPB_SIZE(4, 4), 0, 0, 14, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 14, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 8), UPB_SIZE(-13, -17), 2, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(8, 8), UPB_SIZE(-13, -17), 0, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(8, 8), UPB_SIZE(-13, -17), 3, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(8, 8), UPB_SIZE(-13, -17), 4, 11, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(8, 8), UPB_SIZE(-13, -17), 1, 11, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(4, 4), 0, 0, 14, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_service_status_v3_PerXdsConfig_msginit = {
   &envoy_service_status_v3_PerXdsConfig_submsgs[0],
   &envoy_service_status_v3_PerXdsConfig__fields[0],
-  UPB_SIZE(16, 24), 7, false, 255,
+  UPB_SIZE(16, 24), 7, false, 7, 255,
 };
 
 static const upb_msglayout *const envoy_service_status_v3_ClientConfig_submsgs[3] = {
@@ -68,15 +68,15 @@ static const upb_msglayout *const envoy_service_status_v3_ClientConfig_submsgs[3
 };
 
 static const upb_msglayout_field envoy_service_status_v3_ClientConfig__fields[3] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
-  {2, UPB_SIZE(8, 16), 0, 2, 11, 3},
-  {3, UPB_SIZE(12, 24), 0, 1, 11, 3},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 0, 2, 11, _UPB_MODE_ARRAY},
+  {3, UPB_SIZE(12, 24), 0, 1, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout envoy_service_status_v3_ClientConfig_msginit = {
   &envoy_service_status_v3_ClientConfig_submsgs[0],
   &envoy_service_status_v3_ClientConfig__fields[0],
-  UPB_SIZE(16, 32), 3, false, 255,
+  UPB_SIZE(16, 32), 3, false, 3, 255,
 };
 
 static const upb_msglayout *const envoy_service_status_v3_ClientConfig_GenericXdsConfig_submsgs[3] = {
@@ -86,21 +86,21 @@ static const upb_msglayout *const envoy_service_status_v3_ClientConfig_GenericXd
 };
 
 static const upb_msglayout_field envoy_service_status_v3_ClientConfig_GenericXdsConfig__fields[9] = {
-  {1, UPB_SIZE(16, 16), 0, 0, 9, 1},
-  {2, UPB_SIZE(24, 32), 0, 0, 9, 1},
-  {3, UPB_SIZE(32, 48), 0, 0, 9, 1},
-  {4, UPB_SIZE(40, 64), 1, 1, 11, 1},
-  {5, UPB_SIZE(44, 72), 2, 2, 11, 1},
-  {6, UPB_SIZE(4, 4), 0, 0, 14, 1},
-  {7, UPB_SIZE(8, 8), 0, 0, 14, 1},
-  {8, UPB_SIZE(48, 80), 3, 0, 11, 1},
-  {9, UPB_SIZE(12, 12), 0, 0, 8, 1},
+  {1, UPB_SIZE(16, 16), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(24, 32), 0, 0, 9, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(32, 48), 0, 0, 9, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(40, 64), 1, 1, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(44, 72), 2, 2, 11, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(4, 4), 0, 0, 14, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(8, 8), 0, 0, 14, _UPB_MODE_SCALAR},
+  {8, UPB_SIZE(48, 80), 3, 0, 11, _UPB_MODE_SCALAR},
+  {9, UPB_SIZE(12, 12), 0, 0, 8, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_service_status_v3_ClientConfig_GenericXdsConfig_msginit = {
   &envoy_service_status_v3_ClientConfig_GenericXdsConfig_submsgs[0],
   &envoy_service_status_v3_ClientConfig_GenericXdsConfig__fields[0],
-  UPB_SIZE(56, 96), 9, false, 255,
+  UPB_SIZE(56, 96), 9, false, 9, 255,
 };
 
 static const upb_msglayout *const envoy_service_status_v3_ClientStatusResponse_submsgs[1] = {
@@ -108,13 +108,13 @@ static const upb_msglayout *const envoy_service_status_v3_ClientStatusResponse_s
 };
 
 static const upb_msglayout_field envoy_service_status_v3_ClientStatusResponse__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 11, 3},
+  {1, UPB_SIZE(0, 0), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout envoy_service_status_v3_ClientStatusResponse_msginit = {
   &envoy_service_status_v3_ClientStatusResponse_submsgs[0],
   &envoy_service_status_v3_ClientStatusResponse__fields[0],
-  UPB_SIZE(8, 8), 1, false, 255,
+  UPB_SIZE(8, 8), 1, false, 1, 255,
 };
 
 #include "upb/port_undef.inc"
index ffc61cd..56b6047 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_SERVICE_STATUS_V3_CSDS_PROTO_UPB_H_
 #define ENVOY_SERVICE_STATUS_V3_CSDS_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -80,13 +80,19 @@ UPB_INLINE envoy_service_status_v3_ClientStatusRequest *envoy_service_status_v3_
 UPB_INLINE envoy_service_status_v3_ClientStatusRequest *envoy_service_status_v3_ClientStatusRequest_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_service_status_v3_ClientStatusRequest *ret = envoy_service_status_v3_ClientStatusRequest_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_service_status_v3_ClientStatusRequest_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_service_status_v3_ClientStatusRequest_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_service_status_v3_ClientStatusRequest *envoy_service_status_v3_ClientStatusRequest_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_service_status_v3_ClientStatusRequest *ret = envoy_service_status_v3_ClientStatusRequest_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_service_status_v3_ClientStatusRequest_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_service_status_v3_ClientStatusRequest_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_service_status_v3_ClientStatusRequest_serialize(const envoy_service_status_v3_ClientStatusRequest *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_service_status_v3_ClientStatusRequest_msginit, arena, len);
@@ -132,13 +138,19 @@ UPB_INLINE envoy_service_status_v3_PerXdsConfig *envoy_service_status_v3_PerXdsC
 UPB_INLINE envoy_service_status_v3_PerXdsConfig *envoy_service_status_v3_PerXdsConfig_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_service_status_v3_PerXdsConfig *ret = envoy_service_status_v3_PerXdsConfig_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_service_status_v3_PerXdsConfig_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_service_status_v3_PerXdsConfig_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_service_status_v3_PerXdsConfig *envoy_service_status_v3_PerXdsConfig_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_service_status_v3_PerXdsConfig *ret = envoy_service_status_v3_PerXdsConfig_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_service_status_v3_PerXdsConfig_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_service_status_v3_PerXdsConfig_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_service_status_v3_PerXdsConfig_serialize(const envoy_service_status_v3_PerXdsConfig *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_service_status_v3_PerXdsConfig_msginit, arena, len);
@@ -242,13 +254,19 @@ UPB_INLINE envoy_service_status_v3_ClientConfig *envoy_service_status_v3_ClientC
 UPB_INLINE envoy_service_status_v3_ClientConfig *envoy_service_status_v3_ClientConfig_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_service_status_v3_ClientConfig *ret = envoy_service_status_v3_ClientConfig_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_service_status_v3_ClientConfig_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_service_status_v3_ClientConfig_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_service_status_v3_ClientConfig *envoy_service_status_v3_ClientConfig_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_service_status_v3_ClientConfig *ret = envoy_service_status_v3_ClientConfig_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_service_status_v3_ClientConfig_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_service_status_v3_ClientConfig_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_service_status_v3_ClientConfig_serialize(const envoy_service_status_v3_ClientConfig *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_service_status_v3_ClientConfig_msginit, arena, len);
@@ -309,13 +327,19 @@ UPB_INLINE envoy_service_status_v3_ClientConfig_GenericXdsConfig *envoy_service_
 UPB_INLINE envoy_service_status_v3_ClientConfig_GenericXdsConfig *envoy_service_status_v3_ClientConfig_GenericXdsConfig_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_service_status_v3_ClientConfig_GenericXdsConfig *ret = envoy_service_status_v3_ClientConfig_GenericXdsConfig_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_service_status_v3_ClientConfig_GenericXdsConfig_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_service_status_v3_ClientConfig_GenericXdsConfig_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_service_status_v3_ClientConfig_GenericXdsConfig *envoy_service_status_v3_ClientConfig_GenericXdsConfig_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_service_status_v3_ClientConfig_GenericXdsConfig *ret = envoy_service_status_v3_ClientConfig_GenericXdsConfig_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_service_status_v3_ClientConfig_GenericXdsConfig_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_service_status_v3_ClientConfig_GenericXdsConfig_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_service_status_v3_ClientConfig_GenericXdsConfig_serialize(const envoy_service_status_v3_ClientConfig_GenericXdsConfig *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_service_status_v3_ClientConfig_GenericXdsConfig_msginit, arena, len);
@@ -400,13 +424,19 @@ UPB_INLINE envoy_service_status_v3_ClientStatusResponse *envoy_service_status_v3
 UPB_INLINE envoy_service_status_v3_ClientStatusResponse *envoy_service_status_v3_ClientStatusResponse_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_service_status_v3_ClientStatusResponse *ret = envoy_service_status_v3_ClientStatusResponse_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_service_status_v3_ClientStatusResponse_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_service_status_v3_ClientStatusResponse_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_service_status_v3_ClientStatusResponse *envoy_service_status_v3_ClientStatusResponse_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_service_status_v3_ClientStatusResponse *ret = envoy_service_status_v3_ClientStatusResponse_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_service_status_v3_ClientStatusResponse_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_service_status_v3_ClientStatusResponse_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_service_status_v3_ClientStatusResponse_serialize(const envoy_service_status_v3_ClientStatusResponse *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_service_status_v3_ClientStatusResponse_msginit, arena, len);
index 77d6d9a..f3e2dc9 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/type/http/v3/path_transformation.upb.h"
 #include "udpa/annotations/status.upb.h"
 #include "validate/validate.upb.h"
@@ -19,13 +19,13 @@ static const upb_msglayout *const envoy_type_http_v3_PathTransformation_submsgs[
 };
 
 static const upb_msglayout_field envoy_type_http_v3_PathTransformation__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 11, 3},
+  {1, UPB_SIZE(0, 0), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout envoy_type_http_v3_PathTransformation_msginit = {
   &envoy_type_http_v3_PathTransformation_submsgs[0],
   &envoy_type_http_v3_PathTransformation__fields[0],
-  UPB_SIZE(8, 8), 1, false, 255,
+  UPB_SIZE(8, 8), 1, false, 1, 255,
 };
 
 static const upb_msglayout *const envoy_type_http_v3_PathTransformation_Operation_submsgs[2] = {
@@ -34,26 +34,26 @@ static const upb_msglayout *const envoy_type_http_v3_PathTransformation_Operatio
 };
 
 static const upb_msglayout_field envoy_type_http_v3_PathTransformation_Operation__fields[2] = {
-  {2, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 1, 11, 1},
-  {3, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 11, 1},
+  {2, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 1, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_type_http_v3_PathTransformation_Operation_msginit = {
   &envoy_type_http_v3_PathTransformation_Operation_submsgs[0],
   &envoy_type_http_v3_PathTransformation_Operation__fields[0],
-  UPB_SIZE(8, 16), 2, false, 255,
+  UPB_SIZE(8, 16), 2, false, 0, 255,
 };
 
 const upb_msglayout envoy_type_http_v3_PathTransformation_Operation_NormalizePathRFC3986_msginit = {
   NULL,
   NULL,
-  UPB_SIZE(0, 0), 0, false, 255,
+  UPB_SIZE(0, 0), 0, false, 0, 255,
 };
 
 const upb_msglayout envoy_type_http_v3_PathTransformation_Operation_MergeSlashes_msginit = {
   NULL,
   NULL,
-  UPB_SIZE(0, 0), 0, false, 255,
+  UPB_SIZE(0, 0), 0, false, 0, 255,
 };
 
 #include "upb/port_undef.inc"
index 2aa3159..725573e 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_TYPE_HTTP_V3_PATH_TRANSFORMATION_PROTO_UPB_H_
 #define ENVOY_TYPE_HTTP_V3_PATH_TRANSFORMATION_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -42,13 +42,19 @@ UPB_INLINE envoy_type_http_v3_PathTransformation *envoy_type_http_v3_PathTransfo
 UPB_INLINE envoy_type_http_v3_PathTransformation *envoy_type_http_v3_PathTransformation_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_type_http_v3_PathTransformation *ret = envoy_type_http_v3_PathTransformation_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_type_http_v3_PathTransformation_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_type_http_v3_PathTransformation_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_type_http_v3_PathTransformation *envoy_type_http_v3_PathTransformation_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_type_http_v3_PathTransformation *ret = envoy_type_http_v3_PathTransformation_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_type_http_v3_PathTransformation_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_type_http_v3_PathTransformation_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_type_http_v3_PathTransformation_serialize(const envoy_type_http_v3_PathTransformation *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_type_http_v3_PathTransformation_msginit, arena, len);
@@ -79,13 +85,19 @@ UPB_INLINE envoy_type_http_v3_PathTransformation_Operation *envoy_type_http_v3_P
 UPB_INLINE envoy_type_http_v3_PathTransformation_Operation *envoy_type_http_v3_PathTransformation_Operation_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_type_http_v3_PathTransformation_Operation *ret = envoy_type_http_v3_PathTransformation_Operation_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_type_http_v3_PathTransformation_Operation_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_type_http_v3_PathTransformation_Operation_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_type_http_v3_PathTransformation_Operation *envoy_type_http_v3_PathTransformation_Operation_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_type_http_v3_PathTransformation_Operation *ret = envoy_type_http_v3_PathTransformation_Operation_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_type_http_v3_PathTransformation_Operation_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_type_http_v3_PathTransformation_Operation_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_type_http_v3_PathTransformation_Operation_serialize(const envoy_type_http_v3_PathTransformation_Operation *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_type_http_v3_PathTransformation_Operation_msginit, arena, len);
@@ -136,13 +148,19 @@ UPB_INLINE envoy_type_http_v3_PathTransformation_Operation_NormalizePathRFC3986
 UPB_INLINE envoy_type_http_v3_PathTransformation_Operation_NormalizePathRFC3986 *envoy_type_http_v3_PathTransformation_Operation_NormalizePathRFC3986_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_type_http_v3_PathTransformation_Operation_NormalizePathRFC3986 *ret = envoy_type_http_v3_PathTransformation_Operation_NormalizePathRFC3986_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_type_http_v3_PathTransformation_Operation_NormalizePathRFC3986_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_type_http_v3_PathTransformation_Operation_NormalizePathRFC3986_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_type_http_v3_PathTransformation_Operation_NormalizePathRFC3986 *envoy_type_http_v3_PathTransformation_Operation_NormalizePathRFC3986_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_type_http_v3_PathTransformation_Operation_NormalizePathRFC3986 *ret = envoy_type_http_v3_PathTransformation_Operation_NormalizePathRFC3986_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_type_http_v3_PathTransformation_Operation_NormalizePathRFC3986_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_type_http_v3_PathTransformation_Operation_NormalizePathRFC3986_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_type_http_v3_PathTransformation_Operation_NormalizePathRFC3986_serialize(const envoy_type_http_v3_PathTransformation_Operation_NormalizePathRFC3986 *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_type_http_v3_PathTransformation_Operation_NormalizePathRFC3986_msginit, arena, len);
@@ -158,13 +176,19 @@ UPB_INLINE envoy_type_http_v3_PathTransformation_Operation_MergeSlashes *envoy_t
 UPB_INLINE envoy_type_http_v3_PathTransformation_Operation_MergeSlashes *envoy_type_http_v3_PathTransformation_Operation_MergeSlashes_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_type_http_v3_PathTransformation_Operation_MergeSlashes *ret = envoy_type_http_v3_PathTransformation_Operation_MergeSlashes_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_type_http_v3_PathTransformation_Operation_MergeSlashes_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_type_http_v3_PathTransformation_Operation_MergeSlashes_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_type_http_v3_PathTransformation_Operation_MergeSlashes *envoy_type_http_v3_PathTransformation_Operation_MergeSlashes_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_type_http_v3_PathTransformation_Operation_MergeSlashes *ret = envoy_type_http_v3_PathTransformation_Operation_MergeSlashes_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_type_http_v3_PathTransformation_Operation_MergeSlashes_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_type_http_v3_PathTransformation_Operation_MergeSlashes_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_type_http_v3_PathTransformation_Operation_MergeSlashes_serialize(const envoy_type_http_v3_PathTransformation_Operation_MergeSlashes *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_type_http_v3_PathTransformation_Operation_MergeSlashes_msginit, arena, len);
index 7fdf5b9..75849ca 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/type/matcher/v3/metadata.upb.h"
 #include "envoy/type/matcher/v3/value.upb.h"
 #include "udpa/annotations/status.upb.h"
@@ -21,26 +21,27 @@ static const upb_msglayout *const envoy_type_matcher_v3_MetadataMatcher_submsgs[
   &envoy_type_matcher_v3_ValueMatcher_msginit,
 };
 
-static const upb_msglayout_field envoy_type_matcher_v3_MetadataMatcher__fields[3] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(16, 32), 0, 0, 11, 3},
-  {3, UPB_SIZE(12, 24), 1, 1, 11, 1},
+static const upb_msglayout_field envoy_type_matcher_v3_MetadataMatcher__fields[4] = {
+  {1, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(16, 32), 0, 0, 11, _UPB_MODE_ARRAY},
+  {3, UPB_SIZE(12, 24), 1, 1, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(1, 1), 0, 0, 8, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_type_matcher_v3_MetadataMatcher_msginit = {
   &envoy_type_matcher_v3_MetadataMatcher_submsgs[0],
   &envoy_type_matcher_v3_MetadataMatcher__fields[0],
-  UPB_SIZE(24, 48), 3, false, 255,
+  UPB_SIZE(24, 48), 4, false, 4, 255,
 };
 
 static const upb_msglayout_field envoy_type_matcher_v3_MetadataMatcher_PathSegment__fields[1] = {
-  {1, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 9, 1},
+  {1, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_type_matcher_v3_MetadataMatcher_PathSegment_msginit = {
   NULL,
   &envoy_type_matcher_v3_MetadataMatcher_PathSegment__fields[0],
-  UPB_SIZE(16, 32), 1, false, 255,
+  UPB_SIZE(16, 32), 1, false, 1, 255,
 };
 
 #include "upb/port_undef.inc"
index a7f17c1..4d0dede 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_TYPE_MATCHER_V3_METADATA_PROTO_UPB_H_
 #define ENVOY_TYPE_MATCHER_V3_METADATA_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -38,13 +38,19 @@ UPB_INLINE envoy_type_matcher_v3_MetadataMatcher *envoy_type_matcher_v3_Metadata
 UPB_INLINE envoy_type_matcher_v3_MetadataMatcher *envoy_type_matcher_v3_MetadataMatcher_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_type_matcher_v3_MetadataMatcher *ret = envoy_type_matcher_v3_MetadataMatcher_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_type_matcher_v3_MetadataMatcher_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_type_matcher_v3_MetadataMatcher_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_type_matcher_v3_MetadataMatcher *envoy_type_matcher_v3_MetadataMatcher_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_type_matcher_v3_MetadataMatcher *ret = envoy_type_matcher_v3_MetadataMatcher_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_type_matcher_v3_MetadataMatcher_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_type_matcher_v3_MetadataMatcher_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_type_matcher_v3_MetadataMatcher_serialize(const envoy_type_matcher_v3_MetadataMatcher *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_type_matcher_v3_MetadataMatcher_msginit, arena, len);
@@ -55,6 +61,7 @@ UPB_INLINE bool envoy_type_matcher_v3_MetadataMatcher_has_path(const envoy_type_
 UPB_INLINE const envoy_type_matcher_v3_MetadataMatcher_PathSegment* const* envoy_type_matcher_v3_MetadataMatcher_path(const envoy_type_matcher_v3_MetadataMatcher *msg, size_t *len) { return (const envoy_type_matcher_v3_MetadataMatcher_PathSegment* const*)_upb_array_accessor(msg, UPB_SIZE(16, 32), len); }
 UPB_INLINE bool envoy_type_matcher_v3_MetadataMatcher_has_value(const envoy_type_matcher_v3_MetadataMatcher *msg) { return _upb_hasbit(msg, 1); }
 UPB_INLINE const struct envoy_type_matcher_v3_ValueMatcher* envoy_type_matcher_v3_MetadataMatcher_value(const envoy_type_matcher_v3_MetadataMatcher *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(12, 24), const struct envoy_type_matcher_v3_ValueMatcher*); }
+UPB_INLINE bool envoy_type_matcher_v3_MetadataMatcher_invert(const envoy_type_matcher_v3_MetadataMatcher *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(1, 1), bool); }
 
 UPB_INLINE void envoy_type_matcher_v3_MetadataMatcher_set_filter(envoy_type_matcher_v3_MetadataMatcher *msg, upb_strview value) {
   *UPB_PTR_AT(msg, UPB_SIZE(4, 8), upb_strview) = value;
@@ -85,6 +92,9 @@ UPB_INLINE struct envoy_type_matcher_v3_ValueMatcher* envoy_type_matcher_v3_Meta
   }
   return sub;
 }
+UPB_INLINE void envoy_type_matcher_v3_MetadataMatcher_set_invert(envoy_type_matcher_v3_MetadataMatcher *msg, bool value) {
+  *UPB_PTR_AT(msg, UPB_SIZE(1, 1), bool) = value;
+}
 
 /* envoy.type.matcher.v3.MetadataMatcher.PathSegment */
 
@@ -94,13 +104,19 @@ UPB_INLINE envoy_type_matcher_v3_MetadataMatcher_PathSegment *envoy_type_matcher
 UPB_INLINE envoy_type_matcher_v3_MetadataMatcher_PathSegment *envoy_type_matcher_v3_MetadataMatcher_PathSegment_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_type_matcher_v3_MetadataMatcher_PathSegment *ret = envoy_type_matcher_v3_MetadataMatcher_PathSegment_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_type_matcher_v3_MetadataMatcher_PathSegment_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_type_matcher_v3_MetadataMatcher_PathSegment_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_type_matcher_v3_MetadataMatcher_PathSegment *envoy_type_matcher_v3_MetadataMatcher_PathSegment_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_type_matcher_v3_MetadataMatcher_PathSegment *ret = envoy_type_matcher_v3_MetadataMatcher_PathSegment_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_type_matcher_v3_MetadataMatcher_PathSegment_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_type_matcher_v3_MetadataMatcher_PathSegment_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_type_matcher_v3_MetadataMatcher_PathSegment_serialize(const envoy_type_matcher_v3_MetadataMatcher_PathSegment *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_type_matcher_v3_MetadataMatcher_PathSegment_msginit, arena, len);
index 8ef51fb..3ae84d4 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/type/matcher/v3/node.upb.h"
 #include "envoy/type/matcher/v3/string.upb.h"
 #include "envoy/type/matcher/v3/struct.upb.h"
@@ -22,14 +22,14 @@ static const upb_msglayout *const envoy_type_matcher_v3_NodeMatcher_submsgs[2] =
 };
 
 static const upb_msglayout_field envoy_type_matcher_v3_NodeMatcher__fields[2] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
-  {2, UPB_SIZE(8, 16), 0, 1, 11, 3},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 0, 1, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout envoy_type_matcher_v3_NodeMatcher_msginit = {
   &envoy_type_matcher_v3_NodeMatcher_submsgs[0],
   &envoy_type_matcher_v3_NodeMatcher__fields[0],
-  UPB_SIZE(16, 24), 2, false, 255,
+  UPB_SIZE(16, 24), 2, false, 2, 255,
 };
 
 #include "upb/port_undef.inc"
index 94e2257..78873ad 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_TYPE_MATCHER_V3_NODE_PROTO_UPB_H_
 #define ENVOY_TYPE_MATCHER_V3_NODE_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -37,13 +37,19 @@ UPB_INLINE envoy_type_matcher_v3_NodeMatcher *envoy_type_matcher_v3_NodeMatcher_
 UPB_INLINE envoy_type_matcher_v3_NodeMatcher *envoy_type_matcher_v3_NodeMatcher_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_type_matcher_v3_NodeMatcher *ret = envoy_type_matcher_v3_NodeMatcher_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_type_matcher_v3_NodeMatcher_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_type_matcher_v3_NodeMatcher_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_type_matcher_v3_NodeMatcher *envoy_type_matcher_v3_NodeMatcher_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_type_matcher_v3_NodeMatcher *ret = envoy_type_matcher_v3_NodeMatcher_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_type_matcher_v3_NodeMatcher_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_type_matcher_v3_NodeMatcher_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_type_matcher_v3_NodeMatcher_serialize(const envoy_type_matcher_v3_NodeMatcher *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_type_matcher_v3_NodeMatcher_msginit, arena, len);
index 516755b..cb116d0 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/type/matcher/v3/number.upb.h"
 #include "envoy/type/v3/range.upb.h"
 #include "udpa/annotations/status.upb.h"
@@ -21,14 +21,14 @@ static const upb_msglayout *const envoy_type_matcher_v3_DoubleMatcher_submsgs[1]
 };
 
 static const upb_msglayout_field envoy_type_matcher_v3_DoubleMatcher__fields[2] = {
-  {1, UPB_SIZE(0, 0), UPB_SIZE(-9, -9), 0, 11, 1},
-  {2, UPB_SIZE(0, 0), UPB_SIZE(-9, -9), 0, 1, 1},
+  {1, UPB_SIZE(0, 0), UPB_SIZE(-9, -9), 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(0, 0), UPB_SIZE(-9, -9), 0, 1, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_type_matcher_v3_DoubleMatcher_msginit = {
   &envoy_type_matcher_v3_DoubleMatcher_submsgs[0],
   &envoy_type_matcher_v3_DoubleMatcher__fields[0],
-  UPB_SIZE(16, 16), 2, false, 255,
+  UPB_SIZE(16, 16), 2, false, 2, 255,
 };
 
 #include "upb/port_undef.inc"
index ebca303..1a4c145 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_TYPE_MATCHER_V3_NUMBER_PROTO_UPB_H_
 #define ENVOY_TYPE_MATCHER_V3_NUMBER_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -35,13 +35,19 @@ UPB_INLINE envoy_type_matcher_v3_DoubleMatcher *envoy_type_matcher_v3_DoubleMatc
 UPB_INLINE envoy_type_matcher_v3_DoubleMatcher *envoy_type_matcher_v3_DoubleMatcher_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_type_matcher_v3_DoubleMatcher *ret = envoy_type_matcher_v3_DoubleMatcher_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_type_matcher_v3_DoubleMatcher_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_type_matcher_v3_DoubleMatcher_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_type_matcher_v3_DoubleMatcher *envoy_type_matcher_v3_DoubleMatcher_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_type_matcher_v3_DoubleMatcher *ret = envoy_type_matcher_v3_DoubleMatcher_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_type_matcher_v3_DoubleMatcher_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_type_matcher_v3_DoubleMatcher_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_type_matcher_v3_DoubleMatcher_serialize(const envoy_type_matcher_v3_DoubleMatcher *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_type_matcher_v3_DoubleMatcher_msginit, arena, len);
index caef339..822084c 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/type/matcher/v3/path.upb.h"
 #include "envoy/type/matcher/v3/string.upb.h"
 #include "udpa/annotations/status.upb.h"
@@ -21,13 +21,13 @@ static const upb_msglayout *const envoy_type_matcher_v3_PathMatcher_submsgs[1] =
 };
 
 static const upb_msglayout_field envoy_type_matcher_v3_PathMatcher__fields[1] = {
-  {1, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 11, 1},
+  {1, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_type_matcher_v3_PathMatcher_msginit = {
   &envoy_type_matcher_v3_PathMatcher_submsgs[0],
   &envoy_type_matcher_v3_PathMatcher__fields[0],
-  UPB_SIZE(8, 16), 1, false, 255,
+  UPB_SIZE(8, 16), 1, false, 1, 255,
 };
 
 #include "upb/port_undef.inc"
index defbcf0..1c0e40b 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_TYPE_MATCHER_V3_PATH_PROTO_UPB_H_
 #define ENVOY_TYPE_MATCHER_V3_PATH_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -35,13 +35,19 @@ UPB_INLINE envoy_type_matcher_v3_PathMatcher *envoy_type_matcher_v3_PathMatcher_
 UPB_INLINE envoy_type_matcher_v3_PathMatcher *envoy_type_matcher_v3_PathMatcher_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_type_matcher_v3_PathMatcher *ret = envoy_type_matcher_v3_PathMatcher_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_type_matcher_v3_PathMatcher_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_type_matcher_v3_PathMatcher_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_type_matcher_v3_PathMatcher *envoy_type_matcher_v3_PathMatcher_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_type_matcher_v3_PathMatcher *ret = envoy_type_matcher_v3_PathMatcher_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_type_matcher_v3_PathMatcher_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_type_matcher_v3_PathMatcher_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_type_matcher_v3_PathMatcher_serialize(const envoy_type_matcher_v3_PathMatcher *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_type_matcher_v3_PathMatcher_msginit, arena, len);
index d7d645a..115fa08 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/type/matcher/v3/regex.upb.h"
 #include "google/protobuf/wrappers.upb.h"
 #include "envoy/annotations/deprecation.upb.h"
@@ -22,14 +22,14 @@ static const upb_msglayout *const envoy_type_matcher_v3_RegexMatcher_submsgs[1]
 };
 
 static const upb_msglayout_field envoy_type_matcher_v3_RegexMatcher__fields[2] = {
-  {1, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 0, 11, 1},
-  {2, UPB_SIZE(0, 0), 0, 0, 9, 1},
+  {1, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_type_matcher_v3_RegexMatcher_msginit = {
   &envoy_type_matcher_v3_RegexMatcher_submsgs[0],
   &envoy_type_matcher_v3_RegexMatcher__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_type_matcher_v3_RegexMatcher_GoogleRE2_submsgs[1] = {
@@ -37,13 +37,13 @@ static const upb_msglayout *const envoy_type_matcher_v3_RegexMatcher_GoogleRE2_s
 };
 
 static const upb_msglayout_field envoy_type_matcher_v3_RegexMatcher_GoogleRE2__fields[1] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_type_matcher_v3_RegexMatcher_GoogleRE2_msginit = {
   &envoy_type_matcher_v3_RegexMatcher_GoogleRE2_submsgs[0],
   &envoy_type_matcher_v3_RegexMatcher_GoogleRE2__fields[0],
-  UPB_SIZE(8, 16), 1, false, 255,
+  UPB_SIZE(8, 16), 1, false, 1, 255,
 };
 
 static const upb_msglayout *const envoy_type_matcher_v3_RegexMatchAndSubstitute_submsgs[1] = {
@@ -51,14 +51,14 @@ static const upb_msglayout *const envoy_type_matcher_v3_RegexMatchAndSubstitute_
 };
 
 static const upb_msglayout_field envoy_type_matcher_v3_RegexMatchAndSubstitute__fields[2] = {
-  {1, UPB_SIZE(12, 24), 1, 0, 11, 1},
-  {2, UPB_SIZE(4, 8), 0, 0, 9, 1},
+  {1, UPB_SIZE(12, 24), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_type_matcher_v3_RegexMatchAndSubstitute_msginit = {
   &envoy_type_matcher_v3_RegexMatchAndSubstitute_submsgs[0],
   &envoy_type_matcher_v3_RegexMatchAndSubstitute__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 #include "upb/port_undef.inc"
index 5e00d13..ce7d14e 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_TYPE_MATCHER_V3_REGEX_PROTO_UPB_H_
 #define ENVOY_TYPE_MATCHER_V3_REGEX_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -41,13 +41,19 @@ UPB_INLINE envoy_type_matcher_v3_RegexMatcher *envoy_type_matcher_v3_RegexMatche
 UPB_INLINE envoy_type_matcher_v3_RegexMatcher *envoy_type_matcher_v3_RegexMatcher_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_type_matcher_v3_RegexMatcher *ret = envoy_type_matcher_v3_RegexMatcher_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_type_matcher_v3_RegexMatcher_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_type_matcher_v3_RegexMatcher_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_type_matcher_v3_RegexMatcher *envoy_type_matcher_v3_RegexMatcher_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_type_matcher_v3_RegexMatcher *ret = envoy_type_matcher_v3_RegexMatcher_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_type_matcher_v3_RegexMatcher_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_type_matcher_v3_RegexMatcher_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_type_matcher_v3_RegexMatcher_serialize(const envoy_type_matcher_v3_RegexMatcher *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_type_matcher_v3_RegexMatcher_msginit, arena, len);
@@ -87,13 +93,19 @@ UPB_INLINE envoy_type_matcher_v3_RegexMatcher_GoogleRE2 *envoy_type_matcher_v3_R
 UPB_INLINE envoy_type_matcher_v3_RegexMatcher_GoogleRE2 *envoy_type_matcher_v3_RegexMatcher_GoogleRE2_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_type_matcher_v3_RegexMatcher_GoogleRE2 *ret = envoy_type_matcher_v3_RegexMatcher_GoogleRE2_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_type_matcher_v3_RegexMatcher_GoogleRE2_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_type_matcher_v3_RegexMatcher_GoogleRE2_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_type_matcher_v3_RegexMatcher_GoogleRE2 *envoy_type_matcher_v3_RegexMatcher_GoogleRE2_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_type_matcher_v3_RegexMatcher_GoogleRE2 *ret = envoy_type_matcher_v3_RegexMatcher_GoogleRE2_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_type_matcher_v3_RegexMatcher_GoogleRE2_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_type_matcher_v3_RegexMatcher_GoogleRE2_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_type_matcher_v3_RegexMatcher_GoogleRE2_serialize(const envoy_type_matcher_v3_RegexMatcher_GoogleRE2 *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_type_matcher_v3_RegexMatcher_GoogleRE2_msginit, arena, len);
@@ -124,13 +136,19 @@ UPB_INLINE envoy_type_matcher_v3_RegexMatchAndSubstitute *envoy_type_matcher_v3_
 UPB_INLINE envoy_type_matcher_v3_RegexMatchAndSubstitute *envoy_type_matcher_v3_RegexMatchAndSubstitute_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_type_matcher_v3_RegexMatchAndSubstitute *ret = envoy_type_matcher_v3_RegexMatchAndSubstitute_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_type_matcher_v3_RegexMatchAndSubstitute_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_type_matcher_v3_RegexMatchAndSubstitute_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_type_matcher_v3_RegexMatchAndSubstitute *envoy_type_matcher_v3_RegexMatchAndSubstitute_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_type_matcher_v3_RegexMatchAndSubstitute *ret = envoy_type_matcher_v3_RegexMatchAndSubstitute_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_type_matcher_v3_RegexMatchAndSubstitute_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_type_matcher_v3_RegexMatchAndSubstitute_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_type_matcher_v3_RegexMatchAndSubstitute_serialize(const envoy_type_matcher_v3_RegexMatchAndSubstitute *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_type_matcher_v3_RegexMatchAndSubstitute_msginit, arena, len);
index e84e4f7..a0c367d 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/type/matcher/v3/string.upb.h"
 #include "envoy/type/matcher/v3/regex.upb.h"
 #include "udpa/annotations/status.upb.h"
@@ -21,18 +21,18 @@ static const upb_msglayout *const envoy_type_matcher_v3_StringMatcher_submsgs[1]
 };
 
 static const upb_msglayout_field envoy_type_matcher_v3_StringMatcher__fields[6] = {
-  {1, UPB_SIZE(4, 8), UPB_SIZE(-13, -25), 0, 9, 1},
-  {2, UPB_SIZE(4, 8), UPB_SIZE(-13, -25), 0, 9, 1},
-  {3, UPB_SIZE(4, 8), UPB_SIZE(-13, -25), 0, 9, 1},
-  {5, UPB_SIZE(4, 8), UPB_SIZE(-13, -25), 0, 11, 1},
-  {6, UPB_SIZE(0, 0), 0, 0, 8, 1},
-  {7, UPB_SIZE(4, 8), UPB_SIZE(-13, -25), 0, 9, 1},
+  {1, UPB_SIZE(4, 8), UPB_SIZE(-13, -25), 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(4, 8), UPB_SIZE(-13, -25), 0, 9, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(4, 8), UPB_SIZE(-13, -25), 0, 9, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(4, 8), UPB_SIZE(-13, -25), 0, 11, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(0, 0), 0, 0, 8, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(4, 8), UPB_SIZE(-13, -25), 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_type_matcher_v3_StringMatcher_msginit = {
   &envoy_type_matcher_v3_StringMatcher_submsgs[0],
   &envoy_type_matcher_v3_StringMatcher__fields[0],
-  UPB_SIZE(16, 32), 6, false, 255,
+  UPB_SIZE(16, 32), 6, false, 3, 255,
 };
 
 static const upb_msglayout *const envoy_type_matcher_v3_ListStringMatcher_submsgs[1] = {
@@ -40,13 +40,13 @@ static const upb_msglayout *const envoy_type_matcher_v3_ListStringMatcher_submsg
 };
 
 static const upb_msglayout_field envoy_type_matcher_v3_ListStringMatcher__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 11, 3},
+  {1, UPB_SIZE(0, 0), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout envoy_type_matcher_v3_ListStringMatcher_msginit = {
   &envoy_type_matcher_v3_ListStringMatcher_submsgs[0],
   &envoy_type_matcher_v3_ListStringMatcher__fields[0],
-  UPB_SIZE(8, 8), 1, false, 255,
+  UPB_SIZE(8, 8), 1, false, 1, 255,
 };
 
 #include "upb/port_undef.inc"
index 4bce450..05313a2 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_TYPE_MATCHER_V3_STRING_PROTO_UPB_H_
 #define ENVOY_TYPE_MATCHER_V3_STRING_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -38,13 +38,19 @@ UPB_INLINE envoy_type_matcher_v3_StringMatcher *envoy_type_matcher_v3_StringMatc
 UPB_INLINE envoy_type_matcher_v3_StringMatcher *envoy_type_matcher_v3_StringMatcher_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_type_matcher_v3_StringMatcher *ret = envoy_type_matcher_v3_StringMatcher_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_type_matcher_v3_StringMatcher_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_type_matcher_v3_StringMatcher_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_type_matcher_v3_StringMatcher *envoy_type_matcher_v3_StringMatcher_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_type_matcher_v3_StringMatcher *ret = envoy_type_matcher_v3_StringMatcher_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_type_matcher_v3_StringMatcher_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_type_matcher_v3_StringMatcher_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_type_matcher_v3_StringMatcher_serialize(const envoy_type_matcher_v3_StringMatcher *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_type_matcher_v3_StringMatcher_msginit, arena, len);
@@ -108,13 +114,19 @@ UPB_INLINE envoy_type_matcher_v3_ListStringMatcher *envoy_type_matcher_v3_ListSt
 UPB_INLINE envoy_type_matcher_v3_ListStringMatcher *envoy_type_matcher_v3_ListStringMatcher_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_type_matcher_v3_ListStringMatcher *ret = envoy_type_matcher_v3_ListStringMatcher_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_type_matcher_v3_ListStringMatcher_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_type_matcher_v3_ListStringMatcher_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_type_matcher_v3_ListStringMatcher *envoy_type_matcher_v3_ListStringMatcher_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_type_matcher_v3_ListStringMatcher *ret = envoy_type_matcher_v3_ListStringMatcher_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_type_matcher_v3_ListStringMatcher_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_type_matcher_v3_ListStringMatcher_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_type_matcher_v3_ListStringMatcher_serialize(const envoy_type_matcher_v3_ListStringMatcher *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_type_matcher_v3_ListStringMatcher_msginit, arena, len);
index 05ea6a3..7fef886 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/type/matcher/v3/struct.upb.h"
 #include "envoy/type/matcher/v3/value.upb.h"
 #include "udpa/annotations/status.upb.h"
@@ -22,24 +22,24 @@ static const upb_msglayout *const envoy_type_matcher_v3_StructMatcher_submsgs[2]
 };
 
 static const upb_msglayout_field envoy_type_matcher_v3_StructMatcher__fields[2] = {
-  {2, UPB_SIZE(8, 16), 0, 0, 11, 3},
-  {3, UPB_SIZE(4, 8), 1, 1, 11, 1},
+  {2, UPB_SIZE(8, 16), 0, 0, 11, _UPB_MODE_ARRAY},
+  {3, UPB_SIZE(4, 8), 1, 1, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_type_matcher_v3_StructMatcher_msginit = {
   &envoy_type_matcher_v3_StructMatcher_submsgs[0],
   &envoy_type_matcher_v3_StructMatcher__fields[0],
-  UPB_SIZE(16, 24), 2, false, 255,
+  UPB_SIZE(16, 24), 2, false, 0, 255,
 };
 
 static const upb_msglayout_field envoy_type_matcher_v3_StructMatcher_PathSegment__fields[1] = {
-  {1, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 9, 1},
+  {1, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_type_matcher_v3_StructMatcher_PathSegment_msginit = {
   NULL,
   &envoy_type_matcher_v3_StructMatcher_PathSegment__fields[0],
-  UPB_SIZE(16, 32), 1, false, 255,
+  UPB_SIZE(16, 32), 1, false, 1, 255,
 };
 
 #include "upb/port_undef.inc"
index 53e5213..a7939b7 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_TYPE_MATCHER_V3_STRUCT_PROTO_UPB_H_
 #define ENVOY_TYPE_MATCHER_V3_STRUCT_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -38,13 +38,19 @@ UPB_INLINE envoy_type_matcher_v3_StructMatcher *envoy_type_matcher_v3_StructMatc
 UPB_INLINE envoy_type_matcher_v3_StructMatcher *envoy_type_matcher_v3_StructMatcher_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_type_matcher_v3_StructMatcher *ret = envoy_type_matcher_v3_StructMatcher_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_type_matcher_v3_StructMatcher_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_type_matcher_v3_StructMatcher_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_type_matcher_v3_StructMatcher *envoy_type_matcher_v3_StructMatcher_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_type_matcher_v3_StructMatcher *ret = envoy_type_matcher_v3_StructMatcher_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_type_matcher_v3_StructMatcher_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_type_matcher_v3_StructMatcher_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_type_matcher_v3_StructMatcher_serialize(const envoy_type_matcher_v3_StructMatcher *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_type_matcher_v3_StructMatcher_msginit, arena, len);
@@ -90,13 +96,19 @@ UPB_INLINE envoy_type_matcher_v3_StructMatcher_PathSegment *envoy_type_matcher_v
 UPB_INLINE envoy_type_matcher_v3_StructMatcher_PathSegment *envoy_type_matcher_v3_StructMatcher_PathSegment_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_type_matcher_v3_StructMatcher_PathSegment *ret = envoy_type_matcher_v3_StructMatcher_PathSegment_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_type_matcher_v3_StructMatcher_PathSegment_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_type_matcher_v3_StructMatcher_PathSegment_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_type_matcher_v3_StructMatcher_PathSegment *envoy_type_matcher_v3_StructMatcher_PathSegment_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_type_matcher_v3_StructMatcher_PathSegment *ret = envoy_type_matcher_v3_StructMatcher_PathSegment_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_type_matcher_v3_StructMatcher_PathSegment_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_type_matcher_v3_StructMatcher_PathSegment_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_type_matcher_v3_StructMatcher_PathSegment_serialize(const envoy_type_matcher_v3_StructMatcher_PathSegment *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_type_matcher_v3_StructMatcher_PathSegment_msginit, arena, len);
index 0195307..5f28e35 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/type/matcher/v3/value.upb.h"
 #include "envoy/type/matcher/v3/number.upb.h"
 #include "envoy/type/matcher/v3/string.upb.h"
@@ -25,24 +25,24 @@ static const upb_msglayout *const envoy_type_matcher_v3_ValueMatcher_submsgs[4]
 };
 
 static const upb_msglayout_field envoy_type_matcher_v3_ValueMatcher__fields[6] = {
-  {1, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 3, 11, 1},
-  {2, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 11, 1},
-  {3, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 2, 11, 1},
-  {4, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 8, 1},
-  {5, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 8, 1},
-  {6, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 1, 11, 1},
+  {1, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 3, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 2, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 8, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 8, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 1, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_type_matcher_v3_ValueMatcher_msginit = {
   &envoy_type_matcher_v3_ValueMatcher_submsgs[0],
   &envoy_type_matcher_v3_ValueMatcher__fields[0],
-  UPB_SIZE(8, 16), 6, false, 255,
+  UPB_SIZE(8, 16), 6, false, 6, 255,
 };
 
 const upb_msglayout envoy_type_matcher_v3_ValueMatcher_NullMatch_msginit = {
   NULL,
   NULL,
-  UPB_SIZE(0, 0), 0, false, 255,
+  UPB_SIZE(0, 0), 0, false, 0, 255,
 };
 
 static const upb_msglayout *const envoy_type_matcher_v3_ListMatcher_submsgs[1] = {
@@ -50,13 +50,13 @@ static const upb_msglayout *const envoy_type_matcher_v3_ListMatcher_submsgs[1] =
 };
 
 static const upb_msglayout_field envoy_type_matcher_v3_ListMatcher__fields[1] = {
-  {1, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 11, 1},
+  {1, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_type_matcher_v3_ListMatcher_msginit = {
   &envoy_type_matcher_v3_ListMatcher_submsgs[0],
   &envoy_type_matcher_v3_ListMatcher__fields[0],
-  UPB_SIZE(8, 16), 1, false, 255,
+  UPB_SIZE(8, 16), 1, false, 1, 255,
 };
 
 #include "upb/port_undef.inc"
index dc44445..0310b45 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_TYPE_MATCHER_V3_VALUE_PROTO_UPB_H_
 #define ENVOY_TYPE_MATCHER_V3_VALUE_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -43,13 +43,19 @@ UPB_INLINE envoy_type_matcher_v3_ValueMatcher *envoy_type_matcher_v3_ValueMatche
 UPB_INLINE envoy_type_matcher_v3_ValueMatcher *envoy_type_matcher_v3_ValueMatcher_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_type_matcher_v3_ValueMatcher *ret = envoy_type_matcher_v3_ValueMatcher_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_type_matcher_v3_ValueMatcher_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_type_matcher_v3_ValueMatcher_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_type_matcher_v3_ValueMatcher *envoy_type_matcher_v3_ValueMatcher_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_type_matcher_v3_ValueMatcher *ret = envoy_type_matcher_v3_ValueMatcher_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_type_matcher_v3_ValueMatcher_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_type_matcher_v3_ValueMatcher_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_type_matcher_v3_ValueMatcher_serialize(const envoy_type_matcher_v3_ValueMatcher *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_type_matcher_v3_ValueMatcher_msginit, arena, len);
@@ -142,13 +148,19 @@ UPB_INLINE envoy_type_matcher_v3_ValueMatcher_NullMatch *envoy_type_matcher_v3_V
 UPB_INLINE envoy_type_matcher_v3_ValueMatcher_NullMatch *envoy_type_matcher_v3_ValueMatcher_NullMatch_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_type_matcher_v3_ValueMatcher_NullMatch *ret = envoy_type_matcher_v3_ValueMatcher_NullMatch_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_type_matcher_v3_ValueMatcher_NullMatch_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_type_matcher_v3_ValueMatcher_NullMatch_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_type_matcher_v3_ValueMatcher_NullMatch *envoy_type_matcher_v3_ValueMatcher_NullMatch_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_type_matcher_v3_ValueMatcher_NullMatch *ret = envoy_type_matcher_v3_ValueMatcher_NullMatch_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_type_matcher_v3_ValueMatcher_NullMatch_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_type_matcher_v3_ValueMatcher_NullMatch_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_type_matcher_v3_ValueMatcher_NullMatch_serialize(const envoy_type_matcher_v3_ValueMatcher_NullMatch *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_type_matcher_v3_ValueMatcher_NullMatch_msginit, arena, len);
@@ -164,13 +176,19 @@ UPB_INLINE envoy_type_matcher_v3_ListMatcher *envoy_type_matcher_v3_ListMatcher_
 UPB_INLINE envoy_type_matcher_v3_ListMatcher *envoy_type_matcher_v3_ListMatcher_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_type_matcher_v3_ListMatcher *ret = envoy_type_matcher_v3_ListMatcher_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_type_matcher_v3_ListMatcher_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_type_matcher_v3_ListMatcher_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_type_matcher_v3_ListMatcher *envoy_type_matcher_v3_ListMatcher_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_type_matcher_v3_ListMatcher *ret = envoy_type_matcher_v3_ListMatcher_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_type_matcher_v3_ListMatcher_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_type_matcher_v3_ListMatcher_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_type_matcher_v3_ListMatcher_serialize(const envoy_type_matcher_v3_ListMatcher *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_type_matcher_v3_ListMatcher_msginit, arena, len);
index e692eda..33174f9 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/type/metadata/v3/metadata.upb.h"
 #include "udpa/annotations/status.upb.h"
 #include "udpa/annotations/versioning.upb.h"
@@ -20,24 +20,24 @@ static const upb_msglayout *const envoy_type_metadata_v3_MetadataKey_submsgs[1]
 };
 
 static const upb_msglayout_field envoy_type_metadata_v3_MetadataKey__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {2, UPB_SIZE(8, 16), 0, 0, 11, 3},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout envoy_type_metadata_v3_MetadataKey_msginit = {
   &envoy_type_metadata_v3_MetadataKey_submsgs[0],
   &envoy_type_metadata_v3_MetadataKey__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout_field envoy_type_metadata_v3_MetadataKey_PathSegment__fields[1] = {
-  {1, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 9, 1},
+  {1, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_type_metadata_v3_MetadataKey_PathSegment_msginit = {
   NULL,
   &envoy_type_metadata_v3_MetadataKey_PathSegment__fields[0],
-  UPB_SIZE(16, 32), 1, false, 255,
+  UPB_SIZE(16, 32), 1, false, 1, 255,
 };
 
 static const upb_msglayout *const envoy_type_metadata_v3_MetadataKind_submsgs[4] = {
@@ -48,40 +48,40 @@ static const upb_msglayout *const envoy_type_metadata_v3_MetadataKind_submsgs[4]
 };
 
 static const upb_msglayout_field envoy_type_metadata_v3_MetadataKind__fields[4] = {
-  {1, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 2, 11, 1},
-  {2, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 3, 11, 1},
-  {3, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 11, 1},
-  {4, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 1, 11, 1},
+  {1, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 2, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 3, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 1, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_type_metadata_v3_MetadataKind_msginit = {
   &envoy_type_metadata_v3_MetadataKind_submsgs[0],
   &envoy_type_metadata_v3_MetadataKind__fields[0],
-  UPB_SIZE(8, 16), 4, false, 255,
+  UPB_SIZE(8, 16), 4, false, 4, 255,
 };
 
 const upb_msglayout envoy_type_metadata_v3_MetadataKind_Request_msginit = {
   NULL,
   NULL,
-  UPB_SIZE(0, 0), 0, false, 255,
+  UPB_SIZE(0, 0), 0, false, 0, 255,
 };
 
 const upb_msglayout envoy_type_metadata_v3_MetadataKind_Route_msginit = {
   NULL,
   NULL,
-  UPB_SIZE(0, 0), 0, false, 255,
+  UPB_SIZE(0, 0), 0, false, 0, 255,
 };
 
 const upb_msglayout envoy_type_metadata_v3_MetadataKind_Cluster_msginit = {
   NULL,
   NULL,
-  UPB_SIZE(0, 0), 0, false, 255,
+  UPB_SIZE(0, 0), 0, false, 0, 255,
 };
 
 const upb_msglayout envoy_type_metadata_v3_MetadataKind_Host_msginit = {
   NULL,
   NULL,
-  UPB_SIZE(0, 0), 0, false, 255,
+  UPB_SIZE(0, 0), 0, false, 0, 255,
 };
 
 #include "upb/port_undef.inc"
index 83ac93c..48a0da1 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_TYPE_METADATA_V3_METADATA_PROTO_UPB_H_
 #define ENVOY_TYPE_METADATA_V3_METADATA_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -51,13 +51,19 @@ UPB_INLINE envoy_type_metadata_v3_MetadataKey *envoy_type_metadata_v3_MetadataKe
 UPB_INLINE envoy_type_metadata_v3_MetadataKey *envoy_type_metadata_v3_MetadataKey_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_type_metadata_v3_MetadataKey *ret = envoy_type_metadata_v3_MetadataKey_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_type_metadata_v3_MetadataKey_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_type_metadata_v3_MetadataKey_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_type_metadata_v3_MetadataKey *envoy_type_metadata_v3_MetadataKey_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_type_metadata_v3_MetadataKey *ret = envoy_type_metadata_v3_MetadataKey_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_type_metadata_v3_MetadataKey_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_type_metadata_v3_MetadataKey_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_type_metadata_v3_MetadataKey_serialize(const envoy_type_metadata_v3_MetadataKey *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_type_metadata_v3_MetadataKey_msginit, arena, len);
@@ -92,13 +98,19 @@ UPB_INLINE envoy_type_metadata_v3_MetadataKey_PathSegment *envoy_type_metadata_v
 UPB_INLINE envoy_type_metadata_v3_MetadataKey_PathSegment *envoy_type_metadata_v3_MetadataKey_PathSegment_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_type_metadata_v3_MetadataKey_PathSegment *ret = envoy_type_metadata_v3_MetadataKey_PathSegment_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_type_metadata_v3_MetadataKey_PathSegment_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_type_metadata_v3_MetadataKey_PathSegment_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_type_metadata_v3_MetadataKey_PathSegment *envoy_type_metadata_v3_MetadataKey_PathSegment_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_type_metadata_v3_MetadataKey_PathSegment *ret = envoy_type_metadata_v3_MetadataKey_PathSegment_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_type_metadata_v3_MetadataKey_PathSegment_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_type_metadata_v3_MetadataKey_PathSegment_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_type_metadata_v3_MetadataKey_PathSegment_serialize(const envoy_type_metadata_v3_MetadataKey_PathSegment *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_type_metadata_v3_MetadataKey_PathSegment_msginit, arena, len);
@@ -125,13 +137,19 @@ UPB_INLINE envoy_type_metadata_v3_MetadataKind *envoy_type_metadata_v3_MetadataK
 UPB_INLINE envoy_type_metadata_v3_MetadataKind *envoy_type_metadata_v3_MetadataKind_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_type_metadata_v3_MetadataKind *ret = envoy_type_metadata_v3_MetadataKind_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_type_metadata_v3_MetadataKind_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_type_metadata_v3_MetadataKind_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_type_metadata_v3_MetadataKind *envoy_type_metadata_v3_MetadataKind_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_type_metadata_v3_MetadataKind *ret = envoy_type_metadata_v3_MetadataKind_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_type_metadata_v3_MetadataKind_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_type_metadata_v3_MetadataKind_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_type_metadata_v3_MetadataKind_serialize(const envoy_type_metadata_v3_MetadataKind *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_type_metadata_v3_MetadataKind_msginit, arena, len);
@@ -212,13 +230,19 @@ UPB_INLINE envoy_type_metadata_v3_MetadataKind_Request *envoy_type_metadata_v3_M
 UPB_INLINE envoy_type_metadata_v3_MetadataKind_Request *envoy_type_metadata_v3_MetadataKind_Request_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_type_metadata_v3_MetadataKind_Request *ret = envoy_type_metadata_v3_MetadataKind_Request_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_type_metadata_v3_MetadataKind_Request_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_type_metadata_v3_MetadataKind_Request_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_type_metadata_v3_MetadataKind_Request *envoy_type_metadata_v3_MetadataKind_Request_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_type_metadata_v3_MetadataKind_Request *ret = envoy_type_metadata_v3_MetadataKind_Request_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_type_metadata_v3_MetadataKind_Request_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_type_metadata_v3_MetadataKind_Request_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_type_metadata_v3_MetadataKind_Request_serialize(const envoy_type_metadata_v3_MetadataKind_Request *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_type_metadata_v3_MetadataKind_Request_msginit, arena, len);
@@ -234,13 +258,19 @@ UPB_INLINE envoy_type_metadata_v3_MetadataKind_Route *envoy_type_metadata_v3_Met
 UPB_INLINE envoy_type_metadata_v3_MetadataKind_Route *envoy_type_metadata_v3_MetadataKind_Route_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_type_metadata_v3_MetadataKind_Route *ret = envoy_type_metadata_v3_MetadataKind_Route_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_type_metadata_v3_MetadataKind_Route_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_type_metadata_v3_MetadataKind_Route_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_type_metadata_v3_MetadataKind_Route *envoy_type_metadata_v3_MetadataKind_Route_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_type_metadata_v3_MetadataKind_Route *ret = envoy_type_metadata_v3_MetadataKind_Route_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_type_metadata_v3_MetadataKind_Route_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_type_metadata_v3_MetadataKind_Route_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_type_metadata_v3_MetadataKind_Route_serialize(const envoy_type_metadata_v3_MetadataKind_Route *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_type_metadata_v3_MetadataKind_Route_msginit, arena, len);
@@ -256,13 +286,19 @@ UPB_INLINE envoy_type_metadata_v3_MetadataKind_Cluster *envoy_type_metadata_v3_M
 UPB_INLINE envoy_type_metadata_v3_MetadataKind_Cluster *envoy_type_metadata_v3_MetadataKind_Cluster_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_type_metadata_v3_MetadataKind_Cluster *ret = envoy_type_metadata_v3_MetadataKind_Cluster_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_type_metadata_v3_MetadataKind_Cluster_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_type_metadata_v3_MetadataKind_Cluster_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_type_metadata_v3_MetadataKind_Cluster *envoy_type_metadata_v3_MetadataKind_Cluster_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_type_metadata_v3_MetadataKind_Cluster *ret = envoy_type_metadata_v3_MetadataKind_Cluster_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_type_metadata_v3_MetadataKind_Cluster_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_type_metadata_v3_MetadataKind_Cluster_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_type_metadata_v3_MetadataKind_Cluster_serialize(const envoy_type_metadata_v3_MetadataKind_Cluster *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_type_metadata_v3_MetadataKind_Cluster_msginit, arena, len);
@@ -278,13 +314,19 @@ UPB_INLINE envoy_type_metadata_v3_MetadataKind_Host *envoy_type_metadata_v3_Meta
 UPB_INLINE envoy_type_metadata_v3_MetadataKind_Host *envoy_type_metadata_v3_MetadataKind_Host_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_type_metadata_v3_MetadataKind_Host *ret = envoy_type_metadata_v3_MetadataKind_Host_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_type_metadata_v3_MetadataKind_Host_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_type_metadata_v3_MetadataKind_Host_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_type_metadata_v3_MetadataKind_Host *envoy_type_metadata_v3_MetadataKind_Host_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_type_metadata_v3_MetadataKind_Host *ret = envoy_type_metadata_v3_MetadataKind_Host_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_type_metadata_v3_MetadataKind_Host_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_type_metadata_v3_MetadataKind_Host_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_type_metadata_v3_MetadataKind_Host_serialize(const envoy_type_metadata_v3_MetadataKind_Host *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_type_metadata_v3_MetadataKind_Host_msginit, arena, len);
index fa53e43..c4cb3b2 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/type/tracing/v3/custom_tag.upb.h"
 #include "envoy/type/metadata/v3/metadata.upb.h"
 #include "udpa/annotations/status.upb.h"
@@ -24,49 +24,49 @@ static const upb_msglayout *const envoy_type_tracing_v3_CustomTag_submsgs[4] = {
 };
 
 static const upb_msglayout_field envoy_type_tracing_v3_CustomTag__fields[5] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {2, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 2, 11, 1},
-  {3, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 0, 11, 1},
-  {4, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 1, 11, 1},
-  {5, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 3, 11, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 2, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 0, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 1, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 3, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_type_tracing_v3_CustomTag_msginit = {
   &envoy_type_tracing_v3_CustomTag_submsgs[0],
   &envoy_type_tracing_v3_CustomTag__fields[0],
-  UPB_SIZE(16, 32), 5, false, 255,
+  UPB_SIZE(16, 32), 5, false, 5, 255,
 };
 
 static const upb_msglayout_field envoy_type_tracing_v3_CustomTag_Literal__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_type_tracing_v3_CustomTag_Literal_msginit = {
   NULL,
   &envoy_type_tracing_v3_CustomTag_Literal__fields[0],
-  UPB_SIZE(8, 16), 1, false, 255,
+  UPB_SIZE(8, 16), 1, false, 1, 255,
 };
 
 static const upb_msglayout_field envoy_type_tracing_v3_CustomTag_Environment__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {2, UPB_SIZE(8, 16), 0, 0, 9, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 0, 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_type_tracing_v3_CustomTag_Environment_msginit = {
   NULL,
   &envoy_type_tracing_v3_CustomTag_Environment__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout_field envoy_type_tracing_v3_CustomTag_Header__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {2, UPB_SIZE(8, 16), 0, 0, 9, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 0, 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_type_tracing_v3_CustomTag_Header_msginit = {
   NULL,
   &envoy_type_tracing_v3_CustomTag_Header__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const envoy_type_tracing_v3_CustomTag_Metadata_submsgs[2] = {
@@ -75,15 +75,15 @@ static const upb_msglayout *const envoy_type_tracing_v3_CustomTag_Metadata_subms
 };
 
 static const upb_msglayout_field envoy_type_tracing_v3_CustomTag_Metadata__fields[3] = {
-  {1, UPB_SIZE(12, 24), 1, 1, 11, 1},
-  {2, UPB_SIZE(16, 32), 2, 0, 11, 1},
-  {3, UPB_SIZE(4, 8), 0, 0, 9, 1},
+  {1, UPB_SIZE(12, 24), 1, 1, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(16, 32), 2, 0, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_type_tracing_v3_CustomTag_Metadata_msginit = {
   &envoy_type_tracing_v3_CustomTag_Metadata_submsgs[0],
   &envoy_type_tracing_v3_CustomTag_Metadata__fields[0],
-  UPB_SIZE(24, 48), 3, false, 255,
+  UPB_SIZE(24, 48), 3, false, 3, 255,
 };
 
 #include "upb/port_undef.inc"
index 666ed7b..b382c54 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_TYPE_TRACING_V3_CUSTOM_TAG_PROTO_UPB_H_
 #define ENVOY_TYPE_TRACING_V3_CUSTOM_TAG_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -49,13 +49,19 @@ UPB_INLINE envoy_type_tracing_v3_CustomTag *envoy_type_tracing_v3_CustomTag_new(
 UPB_INLINE envoy_type_tracing_v3_CustomTag *envoy_type_tracing_v3_CustomTag_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_type_tracing_v3_CustomTag *ret = envoy_type_tracing_v3_CustomTag_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_type_tracing_v3_CustomTag_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_type_tracing_v3_CustomTag_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_type_tracing_v3_CustomTag *envoy_type_tracing_v3_CustomTag_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_type_tracing_v3_CustomTag *ret = envoy_type_tracing_v3_CustomTag_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_type_tracing_v3_CustomTag_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_type_tracing_v3_CustomTag_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_type_tracing_v3_CustomTag_serialize(const envoy_type_tracing_v3_CustomTag *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_type_tracing_v3_CustomTag_msginit, arena, len);
@@ -140,13 +146,19 @@ UPB_INLINE envoy_type_tracing_v3_CustomTag_Literal *envoy_type_tracing_v3_Custom
 UPB_INLINE envoy_type_tracing_v3_CustomTag_Literal *envoy_type_tracing_v3_CustomTag_Literal_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_type_tracing_v3_CustomTag_Literal *ret = envoy_type_tracing_v3_CustomTag_Literal_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_type_tracing_v3_CustomTag_Literal_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_type_tracing_v3_CustomTag_Literal_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_type_tracing_v3_CustomTag_Literal *envoy_type_tracing_v3_CustomTag_Literal_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_type_tracing_v3_CustomTag_Literal *ret = envoy_type_tracing_v3_CustomTag_Literal_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_type_tracing_v3_CustomTag_Literal_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_type_tracing_v3_CustomTag_Literal_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_type_tracing_v3_CustomTag_Literal_serialize(const envoy_type_tracing_v3_CustomTag_Literal *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_type_tracing_v3_CustomTag_Literal_msginit, arena, len);
@@ -166,13 +178,19 @@ UPB_INLINE envoy_type_tracing_v3_CustomTag_Environment *envoy_type_tracing_v3_Cu
 UPB_INLINE envoy_type_tracing_v3_CustomTag_Environment *envoy_type_tracing_v3_CustomTag_Environment_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_type_tracing_v3_CustomTag_Environment *ret = envoy_type_tracing_v3_CustomTag_Environment_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_type_tracing_v3_CustomTag_Environment_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_type_tracing_v3_CustomTag_Environment_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_type_tracing_v3_CustomTag_Environment *envoy_type_tracing_v3_CustomTag_Environment_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_type_tracing_v3_CustomTag_Environment *ret = envoy_type_tracing_v3_CustomTag_Environment_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_type_tracing_v3_CustomTag_Environment_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_type_tracing_v3_CustomTag_Environment_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_type_tracing_v3_CustomTag_Environment_serialize(const envoy_type_tracing_v3_CustomTag_Environment *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_type_tracing_v3_CustomTag_Environment_msginit, arena, len);
@@ -196,13 +214,19 @@ UPB_INLINE envoy_type_tracing_v3_CustomTag_Header *envoy_type_tracing_v3_CustomT
 UPB_INLINE envoy_type_tracing_v3_CustomTag_Header *envoy_type_tracing_v3_CustomTag_Header_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_type_tracing_v3_CustomTag_Header *ret = envoy_type_tracing_v3_CustomTag_Header_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_type_tracing_v3_CustomTag_Header_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_type_tracing_v3_CustomTag_Header_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_type_tracing_v3_CustomTag_Header *envoy_type_tracing_v3_CustomTag_Header_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_type_tracing_v3_CustomTag_Header *ret = envoy_type_tracing_v3_CustomTag_Header_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_type_tracing_v3_CustomTag_Header_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_type_tracing_v3_CustomTag_Header_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_type_tracing_v3_CustomTag_Header_serialize(const envoy_type_tracing_v3_CustomTag_Header *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_type_tracing_v3_CustomTag_Header_msginit, arena, len);
@@ -226,13 +250,19 @@ UPB_INLINE envoy_type_tracing_v3_CustomTag_Metadata *envoy_type_tracing_v3_Custo
 UPB_INLINE envoy_type_tracing_v3_CustomTag_Metadata *envoy_type_tracing_v3_CustomTag_Metadata_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_type_tracing_v3_CustomTag_Metadata *ret = envoy_type_tracing_v3_CustomTag_Metadata_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_type_tracing_v3_CustomTag_Metadata_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_type_tracing_v3_CustomTag_Metadata_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_type_tracing_v3_CustomTag_Metadata *envoy_type_tracing_v3_CustomTag_Metadata_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_type_tracing_v3_CustomTag_Metadata *ret = envoy_type_tracing_v3_CustomTag_Metadata_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_type_tracing_v3_CustomTag_Metadata_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_type_tracing_v3_CustomTag_Metadata_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_type_tracing_v3_CustomTag_Metadata_serialize(const envoy_type_tracing_v3_CustomTag_Metadata *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_type_tracing_v3_CustomTag_Metadata_msginit, arena, len);
index c4a03ae..753363b 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/type/v3/http.upb.h"
 #include "udpa/annotations/status.upb.h"
 
index 25b033f..3464038 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_TYPE_V3_HTTP_PROTO_UPB_H_
 #define ENVOY_TYPE_V3_HTTP_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
index 9e4a87c..5ef8700 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/type/v3/percent.upb.h"
 #include "udpa/annotations/status.upb.h"
 #include "udpa/annotations/versioning.upb.h"
 #include "upb/port_def.inc"
 
 static const upb_msglayout_field envoy_type_v3_Percent__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 1, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 1, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_type_v3_Percent_msginit = {
   NULL,
   &envoy_type_v3_Percent__fields[0],
-  UPB_SIZE(8, 8), 1, false, 255,
+  UPB_SIZE(8, 8), 1, false, 1, 255,
 };
 
 static const upb_msglayout_field envoy_type_v3_FractionalPercent__fields[2] = {
-  {1, UPB_SIZE(4, 4), 0, 0, 13, 1},
-  {2, UPB_SIZE(0, 0), 0, 0, 14, 1},
+  {1, UPB_SIZE(4, 4), 0, 0, 13, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(0, 0), 0, 0, 14, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_type_v3_FractionalPercent_msginit = {
   NULL,
   &envoy_type_v3_FractionalPercent__fields[0],
-  UPB_SIZE(8, 8), 2, false, 255,
+  UPB_SIZE(8, 8), 2, false, 2, 255,
 };
 
 #include "upb/port_undef.inc"
index 6155e23..3c2f7a0 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_TYPE_V3_PERCENT_PROTO_UPB_H_
 #define ENVOY_TYPE_V3_PERCENT_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -42,13 +42,19 @@ UPB_INLINE envoy_type_v3_Percent *envoy_type_v3_Percent_new(upb_arena *arena) {
 UPB_INLINE envoy_type_v3_Percent *envoy_type_v3_Percent_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_type_v3_Percent *ret = envoy_type_v3_Percent_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_type_v3_Percent_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_type_v3_Percent_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_type_v3_Percent *envoy_type_v3_Percent_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_type_v3_Percent *ret = envoy_type_v3_Percent_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_type_v3_Percent_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_type_v3_Percent_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_type_v3_Percent_serialize(const envoy_type_v3_Percent *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_type_v3_Percent_msginit, arena, len);
@@ -68,13 +74,19 @@ UPB_INLINE envoy_type_v3_FractionalPercent *envoy_type_v3_FractionalPercent_new(
 UPB_INLINE envoy_type_v3_FractionalPercent *envoy_type_v3_FractionalPercent_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_type_v3_FractionalPercent *ret = envoy_type_v3_FractionalPercent_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_type_v3_FractionalPercent_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_type_v3_FractionalPercent_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_type_v3_FractionalPercent *envoy_type_v3_FractionalPercent_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_type_v3_FractionalPercent *ret = envoy_type_v3_FractionalPercent_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_type_v3_FractionalPercent_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_type_v3_FractionalPercent_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_type_v3_FractionalPercent_serialize(const envoy_type_v3_FractionalPercent *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_type_v3_FractionalPercent_msginit, arena, len);
index e4222be..717fccd 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/type/v3/range.upb.h"
 #include "udpa/annotations/status.upb.h"
 #include "udpa/annotations/versioning.upb.h"
 #include "upb/port_def.inc"
 
 static const upb_msglayout_field envoy_type_v3_Int64Range__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 3, 1},
-  {2, UPB_SIZE(8, 8), 0, 0, 3, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 3, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 8), 0, 0, 3, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_type_v3_Int64Range_msginit = {
   NULL,
   &envoy_type_v3_Int64Range__fields[0],
-  UPB_SIZE(16, 16), 2, false, 255,
+  UPB_SIZE(16, 16), 2, false, 2, 255,
 };
 
 static const upb_msglayout_field envoy_type_v3_Int32Range__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 5, 1},
-  {2, UPB_SIZE(4, 4), 0, 0, 5, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 5, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(4, 4), 0, 0, 5, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_type_v3_Int32Range_msginit = {
   NULL,
   &envoy_type_v3_Int32Range__fields[0],
-  UPB_SIZE(8, 8), 2, false, 255,
+  UPB_SIZE(8, 8), 2, false, 2, 255,
 };
 
 static const upb_msglayout_field envoy_type_v3_DoubleRange__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 1, 1},
-  {2, UPB_SIZE(8, 8), 0, 0, 1, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 1, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 8), 0, 0, 1, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_type_v3_DoubleRange_msginit = {
   NULL,
   &envoy_type_v3_DoubleRange__fields[0],
-  UPB_SIZE(16, 16), 2, false, 255,
+  UPB_SIZE(16, 16), 2, false, 2, 255,
 };
 
 #include "upb/port_undef.inc"
index 9ff396d..32afd9a 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_TYPE_V3_RANGE_PROTO_UPB_H_
 #define ENVOY_TYPE_V3_RANGE_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -39,13 +39,19 @@ UPB_INLINE envoy_type_v3_Int64Range *envoy_type_v3_Int64Range_new(upb_arena *are
 UPB_INLINE envoy_type_v3_Int64Range *envoy_type_v3_Int64Range_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_type_v3_Int64Range *ret = envoy_type_v3_Int64Range_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_type_v3_Int64Range_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_type_v3_Int64Range_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_type_v3_Int64Range *envoy_type_v3_Int64Range_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_type_v3_Int64Range *ret = envoy_type_v3_Int64Range_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_type_v3_Int64Range_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_type_v3_Int64Range_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_type_v3_Int64Range_serialize(const envoy_type_v3_Int64Range *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_type_v3_Int64Range_msginit, arena, len);
@@ -69,13 +75,19 @@ UPB_INLINE envoy_type_v3_Int32Range *envoy_type_v3_Int32Range_new(upb_arena *are
 UPB_INLINE envoy_type_v3_Int32Range *envoy_type_v3_Int32Range_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_type_v3_Int32Range *ret = envoy_type_v3_Int32Range_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_type_v3_Int32Range_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_type_v3_Int32Range_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_type_v3_Int32Range *envoy_type_v3_Int32Range_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_type_v3_Int32Range *ret = envoy_type_v3_Int32Range_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_type_v3_Int32Range_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_type_v3_Int32Range_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_type_v3_Int32Range_serialize(const envoy_type_v3_Int32Range *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_type_v3_Int32Range_msginit, arena, len);
@@ -99,13 +111,19 @@ UPB_INLINE envoy_type_v3_DoubleRange *envoy_type_v3_DoubleRange_new(upb_arena *a
 UPB_INLINE envoy_type_v3_DoubleRange *envoy_type_v3_DoubleRange_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_type_v3_DoubleRange *ret = envoy_type_v3_DoubleRange_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_type_v3_DoubleRange_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_type_v3_DoubleRange_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_type_v3_DoubleRange *envoy_type_v3_DoubleRange_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_type_v3_DoubleRange *ret = envoy_type_v3_DoubleRange_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_type_v3_DoubleRange_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_type_v3_DoubleRange_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_type_v3_DoubleRange_serialize(const envoy_type_v3_DoubleRange *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_type_v3_DoubleRange_msginit, arena, len);
index 8984ac7..94e7cb8 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "envoy/type/v3/semantic_version.upb.h"
 #include "udpa/annotations/status.upb.h"
 #include "udpa/annotations/versioning.upb.h"
 #include "upb/port_def.inc"
 
 static const upb_msglayout_field envoy_type_v3_SemanticVersion__fields[3] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 13, 1},
-  {2, UPB_SIZE(4, 4), 0, 0, 13, 1},
-  {3, UPB_SIZE(8, 8), 0, 0, 13, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 13, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(4, 4), 0, 0, 13, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(8, 8), 0, 0, 13, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout envoy_type_v3_SemanticVersion_msginit = {
   NULL,
   &envoy_type_v3_SemanticVersion__fields[0],
-  UPB_SIZE(16, 16), 3, false, 255,
+  UPB_SIZE(16, 16), 3, false, 3, 255,
 };
 
 #include "upb/port_undef.inc"
index e1dd329..e06a6bb 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef ENVOY_TYPE_V3_SEMANTIC_VERSION_PROTO_UPB_H_
 #define ENVOY_TYPE_V3_SEMANTIC_VERSION_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -33,13 +33,19 @@ UPB_INLINE envoy_type_v3_SemanticVersion *envoy_type_v3_SemanticVersion_new(upb_
 UPB_INLINE envoy_type_v3_SemanticVersion *envoy_type_v3_SemanticVersion_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   envoy_type_v3_SemanticVersion *ret = envoy_type_v3_SemanticVersion_new(arena);
-  return (ret && upb_decode(buf, size, ret, &envoy_type_v3_SemanticVersion_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &envoy_type_v3_SemanticVersion_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE envoy_type_v3_SemanticVersion *envoy_type_v3_SemanticVersion_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   envoy_type_v3_SemanticVersion *ret = envoy_type_v3_SemanticVersion_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &envoy_type_v3_SemanticVersion_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &envoy_type_v3_SemanticVersion_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *envoy_type_v3_SemanticVersion_serialize(const envoy_type_v3_SemanticVersion *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &envoy_type_v3_SemanticVersion_msginit, arena, len);
index a1385cc..d21b094 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "google/api/annotations.upb.h"
 #include "google/api/http.upb.h"
 #include "google/protobuf/descriptor.upb.h"
index fcbe640..0295fbb 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef GOOGLE_API_ANNOTATIONS_PROTO_UPB_H_
 #define GOOGLE_API_ANNOTATIONS_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
index 16fd52a..e24ce3a 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "google/api/expr/v1alpha1/checked.upb.h"
 #include "google/api/expr/v1alpha1/syntax.upb.h"
 #include "google/protobuf/empty.upb.h"
@@ -23,16 +23,16 @@ static const upb_msglayout *const google_api_expr_v1alpha1_CheckedExpr_submsgs[4
 };
 
 static const upb_msglayout_field google_api_expr_v1alpha1_CheckedExpr__fields[4] = {
-  {2, UPB_SIZE(12, 24), 0, 0, 11, _UPB_LABEL_MAP},
-  {3, UPB_SIZE(16, 32), 0, 1, 11, _UPB_LABEL_MAP},
-  {4, UPB_SIZE(4, 8), 1, 2, 11, 1},
-  {5, UPB_SIZE(8, 16), 2, 3, 11, 1},
+  {2, UPB_SIZE(12, 24), 0, 0, 11, _UPB_MODE_MAP},
+  {3, UPB_SIZE(16, 32), 0, 1, 11, _UPB_MODE_MAP},
+  {4, UPB_SIZE(4, 8), 1, 2, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(8, 16), 2, 3, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_api_expr_v1alpha1_CheckedExpr_msginit = {
   &google_api_expr_v1alpha1_CheckedExpr_submsgs[0],
   &google_api_expr_v1alpha1_CheckedExpr__fields[0],
-  UPB_SIZE(24, 40), 4, false, 255,
+  UPB_SIZE(24, 40), 4, false, 0, 255,
 };
 
 static const upb_msglayout *const google_api_expr_v1alpha1_CheckedExpr_ReferenceMapEntry_submsgs[1] = {
@@ -40,14 +40,14 @@ static const upb_msglayout *const google_api_expr_v1alpha1_CheckedExpr_Reference
 };
 
 static const upb_msglayout_field google_api_expr_v1alpha1_CheckedExpr_ReferenceMapEntry__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 3, 1},
-  {2, UPB_SIZE(8, 16), 0, 0, 11, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 3, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 0, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_api_expr_v1alpha1_CheckedExpr_ReferenceMapEntry_msginit = {
   &google_api_expr_v1alpha1_CheckedExpr_ReferenceMapEntry_submsgs[0],
   &google_api_expr_v1alpha1_CheckedExpr_ReferenceMapEntry__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const google_api_expr_v1alpha1_CheckedExpr_TypeMapEntry_submsgs[1] = {
@@ -55,14 +55,14 @@ static const upb_msglayout *const google_api_expr_v1alpha1_CheckedExpr_TypeMapEn
 };
 
 static const upb_msglayout_field google_api_expr_v1alpha1_CheckedExpr_TypeMapEntry__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 3, 1},
-  {2, UPB_SIZE(8, 16), 0, 0, 11, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 3, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 0, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_api_expr_v1alpha1_CheckedExpr_TypeMapEntry_msginit = {
   &google_api_expr_v1alpha1_CheckedExpr_TypeMapEntry_submsgs[0],
   &google_api_expr_v1alpha1_CheckedExpr_TypeMapEntry__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const google_api_expr_v1alpha1_Type_submsgs[6] = {
@@ -75,25 +75,25 @@ static const upb_msglayout *const google_api_expr_v1alpha1_Type_submsgs[6] = {
 };
 
 static const upb_msglayout_field google_api_expr_v1alpha1_Type__fields[13] = {
-  {1, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 5, 11, 1},
-  {2, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 14, 1},
-  {3, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 14, 1},
-  {4, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 14, 1},
-  {5, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 14, 1},
-  {6, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 3, 11, 1},
-  {7, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 4, 11, 1},
-  {8, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 2, 11, 1},
-  {9, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 9, 1},
-  {10, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 9, 1},
-  {11, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 11, 1},
-  {12, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 5, 11, 1},
-  {14, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 1, 11, 1},
+  {1, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 5, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 14, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 14, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 14, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 14, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 3, 11, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 4, 11, _UPB_MODE_SCALAR},
+  {8, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 2, 11, _UPB_MODE_SCALAR},
+  {9, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 9, _UPB_MODE_SCALAR},
+  {10, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 9, _UPB_MODE_SCALAR},
+  {11, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 11, _UPB_MODE_SCALAR},
+  {12, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 5, 11, _UPB_MODE_SCALAR},
+  {14, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 1, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_api_expr_v1alpha1_Type_msginit = {
   &google_api_expr_v1alpha1_Type_submsgs[0],
   &google_api_expr_v1alpha1_Type__fields[0],
-  UPB_SIZE(16, 32), 13, false, 255,
+  UPB_SIZE(16, 32), 13, false, 12, 255,
 };
 
 static const upb_msglayout *const google_api_expr_v1alpha1_Type_ListType_submsgs[1] = {
@@ -101,13 +101,13 @@ static const upb_msglayout *const google_api_expr_v1alpha1_Type_ListType_submsgs
 };
 
 static const upb_msglayout_field google_api_expr_v1alpha1_Type_ListType__fields[1] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_api_expr_v1alpha1_Type_ListType_msginit = {
   &google_api_expr_v1alpha1_Type_ListType_submsgs[0],
   &google_api_expr_v1alpha1_Type_ListType__fields[0],
-  UPB_SIZE(8, 16), 1, false, 255,
+  UPB_SIZE(8, 16), 1, false, 1, 255,
 };
 
 static const upb_msglayout *const google_api_expr_v1alpha1_Type_MapType_submsgs[1] = {
@@ -115,14 +115,14 @@ static const upb_msglayout *const google_api_expr_v1alpha1_Type_MapType_submsgs[
 };
 
 static const upb_msglayout_field google_api_expr_v1alpha1_Type_MapType__fields[2] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
-  {2, UPB_SIZE(8, 16), 2, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 2, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_api_expr_v1alpha1_Type_MapType_msginit = {
   &google_api_expr_v1alpha1_Type_MapType_submsgs[0],
   &google_api_expr_v1alpha1_Type_MapType__fields[0],
-  UPB_SIZE(16, 24), 2, false, 255,
+  UPB_SIZE(16, 24), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const google_api_expr_v1alpha1_Type_FunctionType_submsgs[1] = {
@@ -130,14 +130,14 @@ static const upb_msglayout *const google_api_expr_v1alpha1_Type_FunctionType_sub
 };
 
 static const upb_msglayout_field google_api_expr_v1alpha1_Type_FunctionType__fields[2] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
-  {2, UPB_SIZE(8, 16), 0, 0, 11, 3},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout google_api_expr_v1alpha1_Type_FunctionType_msginit = {
   &google_api_expr_v1alpha1_Type_FunctionType_submsgs[0],
   &google_api_expr_v1alpha1_Type_FunctionType__fields[0],
-  UPB_SIZE(16, 24), 2, false, 255,
+  UPB_SIZE(16, 24), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const google_api_expr_v1alpha1_Type_AbstractType_submsgs[1] = {
@@ -145,14 +145,14 @@ static const upb_msglayout *const google_api_expr_v1alpha1_Type_AbstractType_sub
 };
 
 static const upb_msglayout_field google_api_expr_v1alpha1_Type_AbstractType__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {2, UPB_SIZE(8, 16), 0, 0, 11, 3},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout google_api_expr_v1alpha1_Type_AbstractType_msginit = {
   &google_api_expr_v1alpha1_Type_AbstractType_submsgs[0],
   &google_api_expr_v1alpha1_Type_AbstractType__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const google_api_expr_v1alpha1_Decl_submsgs[2] = {
@@ -161,15 +161,15 @@ static const upb_msglayout *const google_api_expr_v1alpha1_Decl_submsgs[2] = {
 };
 
 static const upb_msglayout_field google_api_expr_v1alpha1_Decl__fields[3] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {2, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 1, 11, 1},
-  {3, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 0, 11, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 1, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_api_expr_v1alpha1_Decl_msginit = {
   &google_api_expr_v1alpha1_Decl_submsgs[0],
   &google_api_expr_v1alpha1_Decl__fields[0],
-  UPB_SIZE(16, 32), 3, false, 255,
+  UPB_SIZE(16, 32), 3, false, 3, 255,
 };
 
 static const upb_msglayout *const google_api_expr_v1alpha1_Decl_IdentDecl_submsgs[2] = {
@@ -178,15 +178,15 @@ static const upb_msglayout *const google_api_expr_v1alpha1_Decl_IdentDecl_submsg
 };
 
 static const upb_msglayout_field google_api_expr_v1alpha1_Decl_IdentDecl__fields[3] = {
-  {1, UPB_SIZE(12, 24), 1, 1, 11, 1},
-  {2, UPB_SIZE(16, 32), 2, 0, 11, 1},
-  {3, UPB_SIZE(4, 8), 0, 0, 9, 1},
+  {1, UPB_SIZE(12, 24), 1, 1, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(16, 32), 2, 0, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_api_expr_v1alpha1_Decl_IdentDecl_msginit = {
   &google_api_expr_v1alpha1_Decl_IdentDecl_submsgs[0],
   &google_api_expr_v1alpha1_Decl_IdentDecl__fields[0],
-  UPB_SIZE(24, 48), 3, false, 255,
+  UPB_SIZE(24, 48), 3, false, 3, 255,
 };
 
 static const upb_msglayout *const google_api_expr_v1alpha1_Decl_FunctionDecl_submsgs[1] = {
@@ -194,13 +194,13 @@ static const upb_msglayout *const google_api_expr_v1alpha1_Decl_FunctionDecl_sub
 };
 
 static const upb_msglayout_field google_api_expr_v1alpha1_Decl_FunctionDecl__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 11, 3},
+  {1, UPB_SIZE(0, 0), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout google_api_expr_v1alpha1_Decl_FunctionDecl_msginit = {
   &google_api_expr_v1alpha1_Decl_FunctionDecl_submsgs[0],
   &google_api_expr_v1alpha1_Decl_FunctionDecl__fields[0],
-  UPB_SIZE(8, 8), 1, false, 255,
+  UPB_SIZE(8, 8), 1, false, 1, 255,
 };
 
 static const upb_msglayout *const google_api_expr_v1alpha1_Decl_FunctionDecl_Overload_submsgs[1] = {
@@ -208,18 +208,18 @@ static const upb_msglayout *const google_api_expr_v1alpha1_Decl_FunctionDecl_Ove
 };
 
 static const upb_msglayout_field google_api_expr_v1alpha1_Decl_FunctionDecl_Overload__fields[6] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(24, 48), 0, 0, 11, 3},
-  {3, UPB_SIZE(28, 56), 0, 0, 9, 3},
-  {4, UPB_SIZE(20, 40), 1, 0, 11, 1},
-  {5, UPB_SIZE(1, 1), 0, 0, 8, 1},
-  {6, UPB_SIZE(12, 24), 0, 0, 9, 1},
+  {1, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(24, 48), 0, 0, 11, _UPB_MODE_ARRAY},
+  {3, UPB_SIZE(28, 56), 0, 0, 9, _UPB_MODE_ARRAY},
+  {4, UPB_SIZE(20, 40), 1, 0, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(1, 1), 0, 0, 8, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(12, 24), 0, 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_api_expr_v1alpha1_Decl_FunctionDecl_Overload_msginit = {
   &google_api_expr_v1alpha1_Decl_FunctionDecl_Overload_submsgs[0],
   &google_api_expr_v1alpha1_Decl_FunctionDecl_Overload__fields[0],
-  UPB_SIZE(32, 64), 6, false, 255,
+  UPB_SIZE(32, 64), 6, false, 6, 255,
 };
 
 static const upb_msglayout *const google_api_expr_v1alpha1_Reference_submsgs[1] = {
@@ -227,15 +227,15 @@ static const upb_msglayout *const google_api_expr_v1alpha1_Reference_submsgs[1]
 };
 
 static const upb_msglayout_field google_api_expr_v1alpha1_Reference__fields[3] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {3, UPB_SIZE(16, 32), 0, 0, 9, 3},
-  {4, UPB_SIZE(12, 24), 1, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(16, 32), 0, 0, 9, _UPB_MODE_ARRAY},
+  {4, UPB_SIZE(12, 24), 1, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_api_expr_v1alpha1_Reference_msginit = {
   &google_api_expr_v1alpha1_Reference_submsgs[0],
   &google_api_expr_v1alpha1_Reference__fields[0],
-  UPB_SIZE(24, 48), 3, false, 255,
+  UPB_SIZE(24, 48), 3, false, 1, 255,
 };
 
 #include "upb/port_undef.inc"
index 43a88f7..8520b5a 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef GOOGLE_API_EXPR_V1ALPHA1_CHECKED_PROTO_UPB_H_
 #define GOOGLE_API_EXPR_V1ALPHA1_CHECKED_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -94,13 +94,19 @@ UPB_INLINE google_api_expr_v1alpha1_CheckedExpr *google_api_expr_v1alpha1_Checke
 UPB_INLINE google_api_expr_v1alpha1_CheckedExpr *google_api_expr_v1alpha1_CheckedExpr_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_api_expr_v1alpha1_CheckedExpr *ret = google_api_expr_v1alpha1_CheckedExpr_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_api_expr_v1alpha1_CheckedExpr_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_api_expr_v1alpha1_CheckedExpr_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_api_expr_v1alpha1_CheckedExpr *google_api_expr_v1alpha1_CheckedExpr_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_api_expr_v1alpha1_CheckedExpr *ret = google_api_expr_v1alpha1_CheckedExpr_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_api_expr_v1alpha1_CheckedExpr_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_api_expr_v1alpha1_CheckedExpr_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_api_expr_v1alpha1_CheckedExpr_serialize(const google_api_expr_v1alpha1_CheckedExpr *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_api_expr_v1alpha1_CheckedExpr_msginit, arena, len);
@@ -198,13 +204,19 @@ UPB_INLINE google_api_expr_v1alpha1_Type *google_api_expr_v1alpha1_Type_new(upb_
 UPB_INLINE google_api_expr_v1alpha1_Type *google_api_expr_v1alpha1_Type_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_api_expr_v1alpha1_Type *ret = google_api_expr_v1alpha1_Type_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Type_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Type_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_api_expr_v1alpha1_Type *google_api_expr_v1alpha1_Type_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_api_expr_v1alpha1_Type *ret = google_api_expr_v1alpha1_Type_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Type_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Type_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_api_expr_v1alpha1_Type_serialize(const google_api_expr_v1alpha1_Type *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_api_expr_v1alpha1_Type_msginit, arena, len);
@@ -366,13 +378,19 @@ UPB_INLINE google_api_expr_v1alpha1_Type_ListType *google_api_expr_v1alpha1_Type
 UPB_INLINE google_api_expr_v1alpha1_Type_ListType *google_api_expr_v1alpha1_Type_ListType_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_api_expr_v1alpha1_Type_ListType *ret = google_api_expr_v1alpha1_Type_ListType_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Type_ListType_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Type_ListType_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_api_expr_v1alpha1_Type_ListType *google_api_expr_v1alpha1_Type_ListType_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_api_expr_v1alpha1_Type_ListType *ret = google_api_expr_v1alpha1_Type_ListType_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Type_ListType_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Type_ListType_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_api_expr_v1alpha1_Type_ListType_serialize(const google_api_expr_v1alpha1_Type_ListType *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_api_expr_v1alpha1_Type_ListType_msginit, arena, len);
@@ -403,13 +421,19 @@ UPB_INLINE google_api_expr_v1alpha1_Type_MapType *google_api_expr_v1alpha1_Type_
 UPB_INLINE google_api_expr_v1alpha1_Type_MapType *google_api_expr_v1alpha1_Type_MapType_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_api_expr_v1alpha1_Type_MapType *ret = google_api_expr_v1alpha1_Type_MapType_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Type_MapType_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Type_MapType_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_api_expr_v1alpha1_Type_MapType *google_api_expr_v1alpha1_Type_MapType_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_api_expr_v1alpha1_Type_MapType *ret = google_api_expr_v1alpha1_Type_MapType_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Type_MapType_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Type_MapType_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_api_expr_v1alpha1_Type_MapType_serialize(const google_api_expr_v1alpha1_Type_MapType *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_api_expr_v1alpha1_Type_MapType_msginit, arena, len);
@@ -455,13 +479,19 @@ UPB_INLINE google_api_expr_v1alpha1_Type_FunctionType *google_api_expr_v1alpha1_
 UPB_INLINE google_api_expr_v1alpha1_Type_FunctionType *google_api_expr_v1alpha1_Type_FunctionType_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_api_expr_v1alpha1_Type_FunctionType *ret = google_api_expr_v1alpha1_Type_FunctionType_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Type_FunctionType_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Type_FunctionType_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_api_expr_v1alpha1_Type_FunctionType *google_api_expr_v1alpha1_Type_FunctionType_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_api_expr_v1alpha1_Type_FunctionType *ret = google_api_expr_v1alpha1_Type_FunctionType_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Type_FunctionType_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Type_FunctionType_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_api_expr_v1alpha1_Type_FunctionType_serialize(const google_api_expr_v1alpha1_Type_FunctionType *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_api_expr_v1alpha1_Type_FunctionType_msginit, arena, len);
@@ -507,13 +537,19 @@ UPB_INLINE google_api_expr_v1alpha1_Type_AbstractType *google_api_expr_v1alpha1_
 UPB_INLINE google_api_expr_v1alpha1_Type_AbstractType *google_api_expr_v1alpha1_Type_AbstractType_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_api_expr_v1alpha1_Type_AbstractType *ret = google_api_expr_v1alpha1_Type_AbstractType_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Type_AbstractType_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Type_AbstractType_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_api_expr_v1alpha1_Type_AbstractType *google_api_expr_v1alpha1_Type_AbstractType_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_api_expr_v1alpha1_Type_AbstractType *ret = google_api_expr_v1alpha1_Type_AbstractType_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Type_AbstractType_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Type_AbstractType_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_api_expr_v1alpha1_Type_AbstractType_serialize(const google_api_expr_v1alpha1_Type_AbstractType *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_api_expr_v1alpha1_Type_AbstractType_msginit, arena, len);
@@ -548,13 +584,19 @@ UPB_INLINE google_api_expr_v1alpha1_Decl *google_api_expr_v1alpha1_Decl_new(upb_
 UPB_INLINE google_api_expr_v1alpha1_Decl *google_api_expr_v1alpha1_Decl_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_api_expr_v1alpha1_Decl *ret = google_api_expr_v1alpha1_Decl_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Decl_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Decl_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_api_expr_v1alpha1_Decl *google_api_expr_v1alpha1_Decl_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_api_expr_v1alpha1_Decl *ret = google_api_expr_v1alpha1_Decl_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Decl_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Decl_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_api_expr_v1alpha1_Decl_serialize(const google_api_expr_v1alpha1_Decl *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_api_expr_v1alpha1_Decl_msginit, arena, len);
@@ -609,13 +651,19 @@ UPB_INLINE google_api_expr_v1alpha1_Decl_IdentDecl *google_api_expr_v1alpha1_Dec
 UPB_INLINE google_api_expr_v1alpha1_Decl_IdentDecl *google_api_expr_v1alpha1_Decl_IdentDecl_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_api_expr_v1alpha1_Decl_IdentDecl *ret = google_api_expr_v1alpha1_Decl_IdentDecl_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Decl_IdentDecl_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Decl_IdentDecl_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_api_expr_v1alpha1_Decl_IdentDecl *google_api_expr_v1alpha1_Decl_IdentDecl_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_api_expr_v1alpha1_Decl_IdentDecl *ret = google_api_expr_v1alpha1_Decl_IdentDecl_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Decl_IdentDecl_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Decl_IdentDecl_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_api_expr_v1alpha1_Decl_IdentDecl_serialize(const google_api_expr_v1alpha1_Decl_IdentDecl *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_api_expr_v1alpha1_Decl_IdentDecl_msginit, arena, len);
@@ -665,13 +713,19 @@ UPB_INLINE google_api_expr_v1alpha1_Decl_FunctionDecl *google_api_expr_v1alpha1_
 UPB_INLINE google_api_expr_v1alpha1_Decl_FunctionDecl *google_api_expr_v1alpha1_Decl_FunctionDecl_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_api_expr_v1alpha1_Decl_FunctionDecl *ret = google_api_expr_v1alpha1_Decl_FunctionDecl_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Decl_FunctionDecl_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Decl_FunctionDecl_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_api_expr_v1alpha1_Decl_FunctionDecl *google_api_expr_v1alpha1_Decl_FunctionDecl_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_api_expr_v1alpha1_Decl_FunctionDecl *ret = google_api_expr_v1alpha1_Decl_FunctionDecl_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Decl_FunctionDecl_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Decl_FunctionDecl_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_api_expr_v1alpha1_Decl_FunctionDecl_serialize(const google_api_expr_v1alpha1_Decl_FunctionDecl *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_api_expr_v1alpha1_Decl_FunctionDecl_msginit, arena, len);
@@ -702,13 +756,19 @@ UPB_INLINE google_api_expr_v1alpha1_Decl_FunctionDecl_Overload *google_api_expr_
 UPB_INLINE google_api_expr_v1alpha1_Decl_FunctionDecl_Overload *google_api_expr_v1alpha1_Decl_FunctionDecl_Overload_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_api_expr_v1alpha1_Decl_FunctionDecl_Overload *ret = google_api_expr_v1alpha1_Decl_FunctionDecl_Overload_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Decl_FunctionDecl_Overload_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Decl_FunctionDecl_Overload_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_api_expr_v1alpha1_Decl_FunctionDecl_Overload *google_api_expr_v1alpha1_Decl_FunctionDecl_Overload_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_api_expr_v1alpha1_Decl_FunctionDecl_Overload *ret = google_api_expr_v1alpha1_Decl_FunctionDecl_Overload_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Decl_FunctionDecl_Overload_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Decl_FunctionDecl_Overload_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_api_expr_v1alpha1_Decl_FunctionDecl_Overload_serialize(const google_api_expr_v1alpha1_Decl_FunctionDecl_Overload *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_api_expr_v1alpha1_Decl_FunctionDecl_Overload_msginit, arena, len);
@@ -777,13 +837,19 @@ UPB_INLINE google_api_expr_v1alpha1_Reference *google_api_expr_v1alpha1_Referenc
 UPB_INLINE google_api_expr_v1alpha1_Reference *google_api_expr_v1alpha1_Reference_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_api_expr_v1alpha1_Reference *ret = google_api_expr_v1alpha1_Reference_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Reference_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Reference_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_api_expr_v1alpha1_Reference *google_api_expr_v1alpha1_Reference_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_api_expr_v1alpha1_Reference *ret = google_api_expr_v1alpha1_Reference_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Reference_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Reference_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_api_expr_v1alpha1_Reference_serialize(const google_api_expr_v1alpha1_Reference *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_api_expr_v1alpha1_Reference_msginit, arena, len);
index 4bbf575..c32d934 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "google/api/expr/v1alpha1/syntax.upb.h"
 #include "google/protobuf/duration.upb.h"
 #include "google/protobuf/struct.upb.h"
@@ -21,14 +21,14 @@ static const upb_msglayout *const google_api_expr_v1alpha1_ParsedExpr_submsgs[2]
 };
 
 static const upb_msglayout_field google_api_expr_v1alpha1_ParsedExpr__fields[2] = {
-  {2, UPB_SIZE(4, 8), 1, 0, 11, 1},
-  {3, UPB_SIZE(8, 16), 2, 1, 11, 1},
+  {2, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(8, 16), 2, 1, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_api_expr_v1alpha1_ParsedExpr_msginit = {
   &google_api_expr_v1alpha1_ParsedExpr_submsgs[0],
   &google_api_expr_v1alpha1_ParsedExpr__fields[0],
-  UPB_SIZE(16, 24), 2, false, 255,
+  UPB_SIZE(16, 24), 2, false, 0, 255,
 };
 
 static const upb_msglayout *const google_api_expr_v1alpha1_Expr_submsgs[7] = {
@@ -42,30 +42,30 @@ static const upb_msglayout *const google_api_expr_v1alpha1_Expr_submsgs[7] = {
 };
 
 static const upb_msglayout_field google_api_expr_v1alpha1_Expr__fields[8] = {
-  {2, UPB_SIZE(0, 0), 0, 0, 3, 1},
-  {3, UPB_SIZE(8, 8), UPB_SIZE(-13, -17), 0, 11, 1},
-  {4, UPB_SIZE(8, 8), UPB_SIZE(-13, -17), 5, 11, 1},
-  {5, UPB_SIZE(8, 8), UPB_SIZE(-13, -17), 6, 11, 1},
-  {6, UPB_SIZE(8, 8), UPB_SIZE(-13, -17), 1, 11, 1},
-  {7, UPB_SIZE(8, 8), UPB_SIZE(-13, -17), 3, 11, 1},
-  {8, UPB_SIZE(8, 8), UPB_SIZE(-13, -17), 4, 11, 1},
-  {9, UPB_SIZE(8, 8), UPB_SIZE(-13, -17), 2, 11, 1},
+  {2, UPB_SIZE(0, 0), 0, 0, 3, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(8, 8), UPB_SIZE(-13, -17), 0, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(8, 8), UPB_SIZE(-13, -17), 5, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(8, 8), UPB_SIZE(-13, -17), 6, 11, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(8, 8), UPB_SIZE(-13, -17), 1, 11, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(8, 8), UPB_SIZE(-13, -17), 3, 11, _UPB_MODE_SCALAR},
+  {8, UPB_SIZE(8, 8), UPB_SIZE(-13, -17), 4, 11, _UPB_MODE_SCALAR},
+  {9, UPB_SIZE(8, 8), UPB_SIZE(-13, -17), 2, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_api_expr_v1alpha1_Expr_msginit = {
   &google_api_expr_v1alpha1_Expr_submsgs[0],
   &google_api_expr_v1alpha1_Expr__fields[0],
-  UPB_SIZE(16, 24), 8, false, 255,
+  UPB_SIZE(16, 24), 8, false, 0, 255,
 };
 
 static const upb_msglayout_field google_api_expr_v1alpha1_Expr_Ident__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_api_expr_v1alpha1_Expr_Ident_msginit = {
   NULL,
   &google_api_expr_v1alpha1_Expr_Ident__fields[0],
-  UPB_SIZE(8, 16), 1, false, 255,
+  UPB_SIZE(8, 16), 1, false, 1, 255,
 };
 
 static const upb_msglayout *const google_api_expr_v1alpha1_Expr_Select_submsgs[1] = {
@@ -73,15 +73,15 @@ static const upb_msglayout *const google_api_expr_v1alpha1_Expr_Select_submsgs[1
 };
 
 static const upb_msglayout_field google_api_expr_v1alpha1_Expr_Select__fields[3] = {
-  {1, UPB_SIZE(12, 24), 1, 0, 11, 1},
-  {2, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {3, UPB_SIZE(1, 1), 0, 0, 8, 1},
+  {1, UPB_SIZE(12, 24), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(1, 1), 0, 0, 8, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_api_expr_v1alpha1_Expr_Select_msginit = {
   &google_api_expr_v1alpha1_Expr_Select_submsgs[0],
   &google_api_expr_v1alpha1_Expr_Select__fields[0],
-  UPB_SIZE(16, 32), 3, false, 255,
+  UPB_SIZE(16, 32), 3, false, 3, 255,
 };
 
 static const upb_msglayout *const google_api_expr_v1alpha1_Expr_Call_submsgs[1] = {
@@ -89,15 +89,15 @@ static const upb_msglayout *const google_api_expr_v1alpha1_Expr_Call_submsgs[1]
 };
 
 static const upb_msglayout_field google_api_expr_v1alpha1_Expr_Call__fields[3] = {
-  {1, UPB_SIZE(12, 24), 1, 0, 11, 1},
-  {2, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {3, UPB_SIZE(16, 32), 0, 0, 11, 3},
+  {1, UPB_SIZE(12, 24), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(16, 32), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout google_api_expr_v1alpha1_Expr_Call_msginit = {
   &google_api_expr_v1alpha1_Expr_Call_submsgs[0],
   &google_api_expr_v1alpha1_Expr_Call__fields[0],
-  UPB_SIZE(24, 48), 3, false, 255,
+  UPB_SIZE(24, 48), 3, false, 3, 255,
 };
 
 static const upb_msglayout *const google_api_expr_v1alpha1_Expr_CreateList_submsgs[1] = {
@@ -105,13 +105,13 @@ static const upb_msglayout *const google_api_expr_v1alpha1_Expr_CreateList_subms
 };
 
 static const upb_msglayout_field google_api_expr_v1alpha1_Expr_CreateList__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 11, 3},
+  {1, UPB_SIZE(0, 0), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout google_api_expr_v1alpha1_Expr_CreateList_msginit = {
   &google_api_expr_v1alpha1_Expr_CreateList_submsgs[0],
   &google_api_expr_v1alpha1_Expr_CreateList__fields[0],
-  UPB_SIZE(8, 8), 1, false, 255,
+  UPB_SIZE(8, 8), 1, false, 1, 255,
 };
 
 static const upb_msglayout *const google_api_expr_v1alpha1_Expr_CreateStruct_submsgs[1] = {
@@ -119,14 +119,14 @@ static const upb_msglayout *const google_api_expr_v1alpha1_Expr_CreateStruct_sub
 };
 
 static const upb_msglayout_field google_api_expr_v1alpha1_Expr_CreateStruct__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {2, UPB_SIZE(8, 16), 0, 0, 11, 3},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout google_api_expr_v1alpha1_Expr_CreateStruct_msginit = {
   &google_api_expr_v1alpha1_Expr_CreateStruct_submsgs[0],
   &google_api_expr_v1alpha1_Expr_CreateStruct__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const google_api_expr_v1alpha1_Expr_CreateStruct_Entry_submsgs[1] = {
@@ -134,16 +134,16 @@ static const upb_msglayout *const google_api_expr_v1alpha1_Expr_CreateStruct_Ent
 };
 
 static const upb_msglayout_field google_api_expr_v1alpha1_Expr_CreateStruct_Entry__fields[4] = {
-  {1, UPB_SIZE(8, 8), 0, 0, 3, 1},
-  {2, UPB_SIZE(20, 24), UPB_SIZE(-29, -41), 0, 9, 1},
-  {3, UPB_SIZE(20, 24), UPB_SIZE(-29, -41), 0, 11, 1},
-  {4, UPB_SIZE(16, 16), 1, 0, 11, 1},
+  {1, UPB_SIZE(8, 8), 0, 0, 3, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(20, 24), UPB_SIZE(-29, -41), 0, 9, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(20, 24), UPB_SIZE(-29, -41), 0, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(16, 16), 1, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_api_expr_v1alpha1_Expr_CreateStruct_Entry_msginit = {
   &google_api_expr_v1alpha1_Expr_CreateStruct_Entry_submsgs[0],
   &google_api_expr_v1alpha1_Expr_CreateStruct_Entry__fields[0],
-  UPB_SIZE(32, 48), 4, false, 255,
+  UPB_SIZE(32, 48), 4, false, 4, 255,
 };
 
 static const upb_msglayout *const google_api_expr_v1alpha1_Expr_Comprehension_submsgs[1] = {
@@ -151,19 +151,19 @@ static const upb_msglayout *const google_api_expr_v1alpha1_Expr_Comprehension_su
 };
 
 static const upb_msglayout_field google_api_expr_v1alpha1_Expr_Comprehension__fields[7] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(20, 40), 1, 0, 11, 1},
-  {3, UPB_SIZE(12, 24), 0, 0, 9, 1},
-  {4, UPB_SIZE(24, 48), 2, 0, 11, 1},
-  {5, UPB_SIZE(28, 56), 3, 0, 11, 1},
-  {6, UPB_SIZE(32, 64), 4, 0, 11, 1},
-  {7, UPB_SIZE(36, 72), 5, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(20, 40), 1, 0, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(12, 24), 0, 0, 9, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(24, 48), 2, 0, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(28, 56), 3, 0, 11, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(32, 64), 4, 0, 11, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(36, 72), 5, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_api_expr_v1alpha1_Expr_Comprehension_msginit = {
   &google_api_expr_v1alpha1_Expr_Comprehension_submsgs[0],
   &google_api_expr_v1alpha1_Expr_Comprehension__fields[0],
-  UPB_SIZE(40, 80), 7, false, 255,
+  UPB_SIZE(40, 80), 7, false, 7, 255,
 };
 
 static const upb_msglayout *const google_api_expr_v1alpha1_Constant_submsgs[2] = {
@@ -172,21 +172,21 @@ static const upb_msglayout *const google_api_expr_v1alpha1_Constant_submsgs[2] =
 };
 
 static const upb_msglayout_field google_api_expr_v1alpha1_Constant__fields[9] = {
-  {1, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 14, 1},
-  {2, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 8, 1},
-  {3, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 3, 1},
-  {4, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 4, 1},
-  {5, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 1, 1},
-  {6, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 9, 1},
-  {7, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 12, 1},
-  {8, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 11, 1},
-  {9, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 1, 11, 1},
+  {1, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 14, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 8, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 3, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 4, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 1, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 9, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 12, _UPB_MODE_SCALAR},
+  {8, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 11, _UPB_MODE_SCALAR},
+  {9, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 1, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_api_expr_v1alpha1_Constant_msginit = {
   &google_api_expr_v1alpha1_Constant_submsgs[0],
   &google_api_expr_v1alpha1_Constant__fields[0],
-  UPB_SIZE(16, 32), 9, false, 255,
+  UPB_SIZE(16, 32), 9, false, 9, 255,
 };
 
 static const upb_msglayout *const google_api_expr_v1alpha1_SourceInfo_submsgs[2] = {
@@ -195,28 +195,28 @@ static const upb_msglayout *const google_api_expr_v1alpha1_SourceInfo_submsgs[2]
 };
 
 static const upb_msglayout_field google_api_expr_v1alpha1_SourceInfo__fields[5] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {2, UPB_SIZE(8, 16), 0, 0, 9, 1},
-  {3, UPB_SIZE(16, 32), 0, 0, 5, _UPB_LABEL_PACKED},
-  {4, UPB_SIZE(20, 40), 0, 1, 11, _UPB_LABEL_MAP},
-  {5, UPB_SIZE(24, 48), 0, 0, 11, _UPB_LABEL_MAP},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 0, 0, 9, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(16, 32), 0, 0, 5, _UPB_MODE_ARRAY | _UPB_MODE_IS_PACKED},
+  {4, UPB_SIZE(20, 40), 0, 1, 11, _UPB_MODE_MAP},
+  {5, UPB_SIZE(24, 48), 0, 0, 11, _UPB_MODE_MAP},
 };
 
 const upb_msglayout google_api_expr_v1alpha1_SourceInfo_msginit = {
   &google_api_expr_v1alpha1_SourceInfo_submsgs[0],
   &google_api_expr_v1alpha1_SourceInfo__fields[0],
-  UPB_SIZE(32, 64), 5, false, 255,
+  UPB_SIZE(32, 64), 5, false, 5, 255,
 };
 
 static const upb_msglayout_field google_api_expr_v1alpha1_SourceInfo_PositionsEntry__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 3, 1},
-  {2, UPB_SIZE(8, 16), 0, 0, 5, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 3, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 0, 0, 5, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_api_expr_v1alpha1_SourceInfo_PositionsEntry_msginit = {
   NULL,
   &google_api_expr_v1alpha1_SourceInfo_PositionsEntry__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const google_api_expr_v1alpha1_SourceInfo_MacroCallsEntry_submsgs[1] = {
@@ -224,27 +224,27 @@ static const upb_msglayout *const google_api_expr_v1alpha1_SourceInfo_MacroCalls
 };
 
 static const upb_msglayout_field google_api_expr_v1alpha1_SourceInfo_MacroCallsEntry__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 3, 1},
-  {2, UPB_SIZE(8, 16), 0, 0, 11, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 3, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 0, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_api_expr_v1alpha1_SourceInfo_MacroCallsEntry_msginit = {
   &google_api_expr_v1alpha1_SourceInfo_MacroCallsEntry_submsgs[0],
   &google_api_expr_v1alpha1_SourceInfo_MacroCallsEntry__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout_field google_api_expr_v1alpha1_SourcePosition__fields[4] = {
-  {1, UPB_SIZE(12, 16), 0, 0, 9, 1},
-  {2, UPB_SIZE(0, 0), 0, 0, 5, 1},
-  {3, UPB_SIZE(4, 4), 0, 0, 5, 1},
-  {4, UPB_SIZE(8, 8), 0, 0, 5, 1},
+  {1, UPB_SIZE(12, 16), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(0, 0), 0, 0, 5, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(4, 4), 0, 0, 5, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(8, 8), 0, 0, 5, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_api_expr_v1alpha1_SourcePosition_msginit = {
   NULL,
   &google_api_expr_v1alpha1_SourcePosition__fields[0],
-  UPB_SIZE(24, 32), 4, false, 255,
+  UPB_SIZE(24, 32), 4, false, 4, 255,
 };
 
 #include "upb/port_undef.inc"
index ffa7925..3460224 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef GOOGLE_API_EXPR_V1ALPHA1_SYNTAX_PROTO_UPB_H_
 #define GOOGLE_API_EXPR_V1ALPHA1_SYNTAX_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -76,13 +76,19 @@ UPB_INLINE google_api_expr_v1alpha1_ParsedExpr *google_api_expr_v1alpha1_ParsedE
 UPB_INLINE google_api_expr_v1alpha1_ParsedExpr *google_api_expr_v1alpha1_ParsedExpr_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_api_expr_v1alpha1_ParsedExpr *ret = google_api_expr_v1alpha1_ParsedExpr_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_api_expr_v1alpha1_ParsedExpr_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_api_expr_v1alpha1_ParsedExpr_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_api_expr_v1alpha1_ParsedExpr *google_api_expr_v1alpha1_ParsedExpr_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_api_expr_v1alpha1_ParsedExpr *ret = google_api_expr_v1alpha1_ParsedExpr_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_api_expr_v1alpha1_ParsedExpr_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_api_expr_v1alpha1_ParsedExpr_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_api_expr_v1alpha1_ParsedExpr_serialize(const google_api_expr_v1alpha1_ParsedExpr *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_api_expr_v1alpha1_ParsedExpr_msginit, arena, len);
@@ -128,13 +134,19 @@ UPB_INLINE google_api_expr_v1alpha1_Expr *google_api_expr_v1alpha1_Expr_new(upb_
 UPB_INLINE google_api_expr_v1alpha1_Expr *google_api_expr_v1alpha1_Expr_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_api_expr_v1alpha1_Expr *ret = google_api_expr_v1alpha1_Expr_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Expr_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Expr_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_api_expr_v1alpha1_Expr *google_api_expr_v1alpha1_Expr_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_api_expr_v1alpha1_Expr *ret = google_api_expr_v1alpha1_Expr_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Expr_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Expr_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_api_expr_v1alpha1_Expr_serialize(const google_api_expr_v1alpha1_Expr *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_api_expr_v1alpha1_Expr_msginit, arena, len);
@@ -264,13 +276,19 @@ UPB_INLINE google_api_expr_v1alpha1_Expr_Ident *google_api_expr_v1alpha1_Expr_Id
 UPB_INLINE google_api_expr_v1alpha1_Expr_Ident *google_api_expr_v1alpha1_Expr_Ident_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_api_expr_v1alpha1_Expr_Ident *ret = google_api_expr_v1alpha1_Expr_Ident_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Expr_Ident_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Expr_Ident_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_api_expr_v1alpha1_Expr_Ident *google_api_expr_v1alpha1_Expr_Ident_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_api_expr_v1alpha1_Expr_Ident *ret = google_api_expr_v1alpha1_Expr_Ident_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Expr_Ident_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Expr_Ident_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_api_expr_v1alpha1_Expr_Ident_serialize(const google_api_expr_v1alpha1_Expr_Ident *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_api_expr_v1alpha1_Expr_Ident_msginit, arena, len);
@@ -290,13 +308,19 @@ UPB_INLINE google_api_expr_v1alpha1_Expr_Select *google_api_expr_v1alpha1_Expr_S
 UPB_INLINE google_api_expr_v1alpha1_Expr_Select *google_api_expr_v1alpha1_Expr_Select_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_api_expr_v1alpha1_Expr_Select *ret = google_api_expr_v1alpha1_Expr_Select_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Expr_Select_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Expr_Select_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_api_expr_v1alpha1_Expr_Select *google_api_expr_v1alpha1_Expr_Select_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_api_expr_v1alpha1_Expr_Select *ret = google_api_expr_v1alpha1_Expr_Select_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Expr_Select_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Expr_Select_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_api_expr_v1alpha1_Expr_Select_serialize(const google_api_expr_v1alpha1_Expr_Select *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_api_expr_v1alpha1_Expr_Select_msginit, arena, len);
@@ -335,13 +359,19 @@ UPB_INLINE google_api_expr_v1alpha1_Expr_Call *google_api_expr_v1alpha1_Expr_Cal
 UPB_INLINE google_api_expr_v1alpha1_Expr_Call *google_api_expr_v1alpha1_Expr_Call_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_api_expr_v1alpha1_Expr_Call *ret = google_api_expr_v1alpha1_Expr_Call_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Expr_Call_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Expr_Call_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_api_expr_v1alpha1_Expr_Call *google_api_expr_v1alpha1_Expr_Call_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_api_expr_v1alpha1_Expr_Call *ret = google_api_expr_v1alpha1_Expr_Call_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Expr_Call_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Expr_Call_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_api_expr_v1alpha1_Expr_Call_serialize(const google_api_expr_v1alpha1_Expr_Call *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_api_expr_v1alpha1_Expr_Call_msginit, arena, len);
@@ -391,13 +421,19 @@ UPB_INLINE google_api_expr_v1alpha1_Expr_CreateList *google_api_expr_v1alpha1_Ex
 UPB_INLINE google_api_expr_v1alpha1_Expr_CreateList *google_api_expr_v1alpha1_Expr_CreateList_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_api_expr_v1alpha1_Expr_CreateList *ret = google_api_expr_v1alpha1_Expr_CreateList_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Expr_CreateList_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Expr_CreateList_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_api_expr_v1alpha1_Expr_CreateList *google_api_expr_v1alpha1_Expr_CreateList_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_api_expr_v1alpha1_Expr_CreateList *ret = google_api_expr_v1alpha1_Expr_CreateList_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Expr_CreateList_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Expr_CreateList_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_api_expr_v1alpha1_Expr_CreateList_serialize(const google_api_expr_v1alpha1_Expr_CreateList *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_api_expr_v1alpha1_Expr_CreateList_msginit, arena, len);
@@ -428,13 +464,19 @@ UPB_INLINE google_api_expr_v1alpha1_Expr_CreateStruct *google_api_expr_v1alpha1_
 UPB_INLINE google_api_expr_v1alpha1_Expr_CreateStruct *google_api_expr_v1alpha1_Expr_CreateStruct_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_api_expr_v1alpha1_Expr_CreateStruct *ret = google_api_expr_v1alpha1_Expr_CreateStruct_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Expr_CreateStruct_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Expr_CreateStruct_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_api_expr_v1alpha1_Expr_CreateStruct *google_api_expr_v1alpha1_Expr_CreateStruct_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_api_expr_v1alpha1_Expr_CreateStruct *ret = google_api_expr_v1alpha1_Expr_CreateStruct_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Expr_CreateStruct_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Expr_CreateStruct_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_api_expr_v1alpha1_Expr_CreateStruct_serialize(const google_api_expr_v1alpha1_Expr_CreateStruct *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_api_expr_v1alpha1_Expr_CreateStruct_msginit, arena, len);
@@ -469,13 +511,19 @@ UPB_INLINE google_api_expr_v1alpha1_Expr_CreateStruct_Entry *google_api_expr_v1a
 UPB_INLINE google_api_expr_v1alpha1_Expr_CreateStruct_Entry *google_api_expr_v1alpha1_Expr_CreateStruct_Entry_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_api_expr_v1alpha1_Expr_CreateStruct_Entry *ret = google_api_expr_v1alpha1_Expr_CreateStruct_Entry_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Expr_CreateStruct_Entry_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Expr_CreateStruct_Entry_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_api_expr_v1alpha1_Expr_CreateStruct_Entry *google_api_expr_v1alpha1_Expr_CreateStruct_Entry_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_api_expr_v1alpha1_Expr_CreateStruct_Entry *ret = google_api_expr_v1alpha1_Expr_CreateStruct_Entry_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Expr_CreateStruct_Entry_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Expr_CreateStruct_Entry_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_api_expr_v1alpha1_Expr_CreateStruct_Entry_serialize(const google_api_expr_v1alpha1_Expr_CreateStruct_Entry *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_api_expr_v1alpha1_Expr_CreateStruct_Entry_msginit, arena, len);
@@ -536,13 +584,19 @@ UPB_INLINE google_api_expr_v1alpha1_Expr_Comprehension *google_api_expr_v1alpha1
 UPB_INLINE google_api_expr_v1alpha1_Expr_Comprehension *google_api_expr_v1alpha1_Expr_Comprehension_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_api_expr_v1alpha1_Expr_Comprehension *ret = google_api_expr_v1alpha1_Expr_Comprehension_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Expr_Comprehension_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Expr_Comprehension_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_api_expr_v1alpha1_Expr_Comprehension *google_api_expr_v1alpha1_Expr_Comprehension_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_api_expr_v1alpha1_Expr_Comprehension *ret = google_api_expr_v1alpha1_Expr_Comprehension_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Expr_Comprehension_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Expr_Comprehension_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_api_expr_v1alpha1_Expr_Comprehension_serialize(const google_api_expr_v1alpha1_Expr_Comprehension *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_api_expr_v1alpha1_Expr_Comprehension_msginit, arena, len);
@@ -641,13 +695,19 @@ UPB_INLINE google_api_expr_v1alpha1_Constant *google_api_expr_v1alpha1_Constant_
 UPB_INLINE google_api_expr_v1alpha1_Constant *google_api_expr_v1alpha1_Constant_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_api_expr_v1alpha1_Constant *ret = google_api_expr_v1alpha1_Constant_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Constant_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Constant_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_api_expr_v1alpha1_Constant *google_api_expr_v1alpha1_Constant_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_api_expr_v1alpha1_Constant *ret = google_api_expr_v1alpha1_Constant_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Constant_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_api_expr_v1alpha1_Constant_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_api_expr_v1alpha1_Constant_serialize(const google_api_expr_v1alpha1_Constant *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_api_expr_v1alpha1_Constant_msginit, arena, len);
@@ -740,13 +800,19 @@ UPB_INLINE google_api_expr_v1alpha1_SourceInfo *google_api_expr_v1alpha1_SourceI
 UPB_INLINE google_api_expr_v1alpha1_SourceInfo *google_api_expr_v1alpha1_SourceInfo_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_api_expr_v1alpha1_SourceInfo *ret = google_api_expr_v1alpha1_SourceInfo_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_api_expr_v1alpha1_SourceInfo_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_api_expr_v1alpha1_SourceInfo_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_api_expr_v1alpha1_SourceInfo *google_api_expr_v1alpha1_SourceInfo_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_api_expr_v1alpha1_SourceInfo *ret = google_api_expr_v1alpha1_SourceInfo_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_api_expr_v1alpha1_SourceInfo_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_api_expr_v1alpha1_SourceInfo_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_api_expr_v1alpha1_SourceInfo_serialize(const google_api_expr_v1alpha1_SourceInfo *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_api_expr_v1alpha1_SourceInfo_msginit, arena, len);
@@ -832,13 +898,19 @@ UPB_INLINE google_api_expr_v1alpha1_SourcePosition *google_api_expr_v1alpha1_Sou
 UPB_INLINE google_api_expr_v1alpha1_SourcePosition *google_api_expr_v1alpha1_SourcePosition_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_api_expr_v1alpha1_SourcePosition *ret = google_api_expr_v1alpha1_SourcePosition_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_api_expr_v1alpha1_SourcePosition_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_api_expr_v1alpha1_SourcePosition_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_api_expr_v1alpha1_SourcePosition *google_api_expr_v1alpha1_SourcePosition_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_api_expr_v1alpha1_SourcePosition *ret = google_api_expr_v1alpha1_SourcePosition_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_api_expr_v1alpha1_SourcePosition_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_api_expr_v1alpha1_SourcePosition_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_api_expr_v1alpha1_SourcePosition_serialize(const google_api_expr_v1alpha1_SourcePosition *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_api_expr_v1alpha1_SourcePosition_msginit, arena, len);
index f17613a..d064f6e 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "google/api/http.upb.h"
 
 #include "upb/port_def.inc"
@@ -17,14 +17,14 @@ static const upb_msglayout *const google_api_Http_submsgs[1] = {
 };
 
 static const upb_msglayout_field google_api_Http__fields[2] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 11, 3},
-  {2, UPB_SIZE(0, 0), 0, 0, 8, 1},
+  {1, UPB_SIZE(4, 8), 0, 0, 11, _UPB_MODE_ARRAY},
+  {2, UPB_SIZE(0, 0), 0, 0, 8, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_api_Http_msginit = {
   &google_api_Http_submsgs[0],
   &google_api_Http__fields[0],
-  UPB_SIZE(8, 16), 2, false, 255,
+  UPB_SIZE(8, 16), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const google_api_HttpRule_submsgs[2] = {
@@ -33,33 +33,33 @@ static const upb_msglayout *const google_api_HttpRule_submsgs[2] = {
 };
 
 static const upb_msglayout_field google_api_HttpRule__fields[10] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {2, UPB_SIZE(28, 56), UPB_SIZE(-37, -73), 0, 9, 1},
-  {3, UPB_SIZE(28, 56), UPB_SIZE(-37, -73), 0, 9, 1},
-  {4, UPB_SIZE(28, 56), UPB_SIZE(-37, -73), 0, 9, 1},
-  {5, UPB_SIZE(28, 56), UPB_SIZE(-37, -73), 0, 9, 1},
-  {6, UPB_SIZE(28, 56), UPB_SIZE(-37, -73), 0, 9, 1},
-  {7, UPB_SIZE(8, 16), 0, 0, 9, 1},
-  {8, UPB_SIZE(28, 56), UPB_SIZE(-37, -73), 0, 11, 1},
-  {11, UPB_SIZE(24, 48), 0, 1, 11, 3},
-  {12, UPB_SIZE(16, 32), 0, 0, 9, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(28, 56), UPB_SIZE(-37, -73), 0, 9, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(28, 56), UPB_SIZE(-37, -73), 0, 9, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(28, 56), UPB_SIZE(-37, -73), 0, 9, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(28, 56), UPB_SIZE(-37, -73), 0, 9, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(28, 56), UPB_SIZE(-37, -73), 0, 9, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(8, 16), 0, 0, 9, _UPB_MODE_SCALAR},
+  {8, UPB_SIZE(28, 56), UPB_SIZE(-37, -73), 0, 11, _UPB_MODE_SCALAR},
+  {11, UPB_SIZE(24, 48), 0, 1, 11, _UPB_MODE_ARRAY},
+  {12, UPB_SIZE(16, 32), 0, 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_api_HttpRule_msginit = {
   &google_api_HttpRule_submsgs[0],
   &google_api_HttpRule__fields[0],
-  UPB_SIZE(40, 80), 10, false, 255,
+  UPB_SIZE(40, 80), 10, false, 8, 255,
 };
 
 static const upb_msglayout_field google_api_CustomHttpPattern__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {2, UPB_SIZE(8, 16), 0, 0, 9, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 0, 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_api_CustomHttpPattern_msginit = {
   NULL,
   &google_api_CustomHttpPattern__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 #include "upb/port_undef.inc"
index ed4e6d1..b0745b9 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef GOOGLE_API_HTTP_PROTO_UPB_H_
 #define GOOGLE_API_HTTP_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -39,13 +39,19 @@ UPB_INLINE google_api_Http *google_api_Http_new(upb_arena *arena) {
 UPB_INLINE google_api_Http *google_api_Http_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_api_Http *ret = google_api_Http_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_api_Http_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_api_Http_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_api_Http *google_api_Http_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_api_Http *ret = google_api_Http_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_api_Http_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_api_Http_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_api_Http_serialize(const google_api_Http *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_api_Http_msginit, arena, len);
@@ -80,13 +86,19 @@ UPB_INLINE google_api_HttpRule *google_api_HttpRule_new(upb_arena *arena) {
 UPB_INLINE google_api_HttpRule *google_api_HttpRule_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_api_HttpRule *ret = google_api_HttpRule_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_api_HttpRule_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_api_HttpRule_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_api_HttpRule *google_api_HttpRule_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_api_HttpRule *ret = google_api_HttpRule_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_api_HttpRule_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_api_HttpRule_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_api_HttpRule_serialize(const google_api_HttpRule *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_api_HttpRule_msginit, arena, len);
@@ -179,13 +191,19 @@ UPB_INLINE google_api_CustomHttpPattern *google_api_CustomHttpPattern_new(upb_ar
 UPB_INLINE google_api_CustomHttpPattern *google_api_CustomHttpPattern_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_api_CustomHttpPattern *ret = google_api_CustomHttpPattern_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_api_CustomHttpPattern_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_api_CustomHttpPattern_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_api_CustomHttpPattern *google_api_CustomHttpPattern_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_api_CustomHttpPattern *ret = google_api_CustomHttpPattern_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_api_CustomHttpPattern_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_api_CustomHttpPattern_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_api_CustomHttpPattern_serialize(const google_api_CustomHttpPattern *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_api_CustomHttpPattern_msginit, arena, len);
index 93eaa60..bdf0dc0 100644 (file)
@@ -7,20 +7,20 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "google/protobuf/any.upb.h"
 
 #include "upb/port_def.inc"
 
 static const upb_msglayout_field google_protobuf_Any__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {2, UPB_SIZE(8, 16), 0, 0, 12, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 0, 0, 12, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_protobuf_Any_msginit = {
   NULL,
   &google_protobuf_Any__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 #include "upb/port_undef.inc"
index 2bd44f7..ca6a7a0 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef GOOGLE_PROTOBUF_ANY_PROTO_UPB_H_
 #define GOOGLE_PROTOBUF_ANY_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -33,13 +33,19 @@ UPB_INLINE google_protobuf_Any *google_protobuf_Any_new(upb_arena *arena) {
 UPB_INLINE google_protobuf_Any *google_protobuf_Any_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_Any *ret = google_protobuf_Any_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_Any_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_Any_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_Any *google_protobuf_Any_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_Any *ret = google_protobuf_Any_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_Any_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_Any_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_Any_serialize(const google_protobuf_Any *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_Any_msginit, arena, len);
index 339fafa..a6b9af9 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "google/protobuf/descriptor.upb.h"
 
 #include "upb/port_def.inc"
@@ -17,13 +17,13 @@ static const upb_msglayout *const google_protobuf_FileDescriptorSet_submsgs[1] =
 };
 
 static const upb_msglayout_field google_protobuf_FileDescriptorSet__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 11, 3},
+  {1, UPB_SIZE(0, 0), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout google_protobuf_FileDescriptorSet_msginit = {
   &google_protobuf_FileDescriptorSet_submsgs[0],
   &google_protobuf_FileDescriptorSet__fields[0],
-  UPB_SIZE(8, 8), 1, false, 255,
+  UPB_SIZE(8, 8), 1, false, 1, 255,
 };
 
 static const upb_msglayout *const google_protobuf_FileDescriptorProto_submsgs[6] = {
@@ -36,24 +36,24 @@ static const upb_msglayout *const google_protobuf_FileDescriptorProto_submsgs[6]
 };
 
 static const upb_msglayout_field google_protobuf_FileDescriptorProto__fields[12] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 12, 1},
-  {2, UPB_SIZE(12, 24), 2, 0, 12, 1},
-  {3, UPB_SIZE(36, 72), 0, 0, 12, 3},
-  {4, UPB_SIZE(40, 80), 0, 0, 11, 3},
-  {5, UPB_SIZE(44, 88), 0, 1, 11, 3},
-  {6, UPB_SIZE(48, 96), 0, 4, 11, 3},
-  {7, UPB_SIZE(52, 104), 0, 2, 11, 3},
-  {8, UPB_SIZE(28, 56), 3, 3, 11, 1},
-  {9, UPB_SIZE(32, 64), 4, 5, 11, 1},
-  {10, UPB_SIZE(56, 112), 0, 0, 5, 3},
-  {11, UPB_SIZE(60, 120), 0, 0, 5, 3},
-  {12, UPB_SIZE(20, 40), 5, 0, 12, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 12, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(12, 24), 2, 0, 12, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(36, 72), 0, 0, 12, _UPB_MODE_ARRAY},
+  {4, UPB_SIZE(40, 80), 0, 0, 11, _UPB_MODE_ARRAY},
+  {5, UPB_SIZE(44, 88), 0, 1, 11, _UPB_MODE_ARRAY},
+  {6, UPB_SIZE(48, 96), 0, 4, 11, _UPB_MODE_ARRAY},
+  {7, UPB_SIZE(52, 104), 0, 2, 11, _UPB_MODE_ARRAY},
+  {8, UPB_SIZE(28, 56), 3, 3, 11, _UPB_MODE_SCALAR},
+  {9, UPB_SIZE(32, 64), 4, 5, 11, _UPB_MODE_SCALAR},
+  {10, UPB_SIZE(56, 112), 0, 0, 5, _UPB_MODE_ARRAY},
+  {11, UPB_SIZE(60, 120), 0, 0, 5, _UPB_MODE_ARRAY},
+  {12, UPB_SIZE(20, 40), 5, 0, 12, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_protobuf_FileDescriptorProto_msginit = {
   &google_protobuf_FileDescriptorProto_submsgs[0],
   &google_protobuf_FileDescriptorProto__fields[0],
-  UPB_SIZE(64, 128), 12, false, 255,
+  UPB_SIZE(64, 128), 12, false, 12, 255,
 };
 
 static const upb_msglayout *const google_protobuf_DescriptorProto_submsgs[7] = {
@@ -67,22 +67,22 @@ static const upb_msglayout *const google_protobuf_DescriptorProto_submsgs[7] = {
 };
 
 static const upb_msglayout_field google_protobuf_DescriptorProto__fields[10] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 12, 1},
-  {2, UPB_SIZE(16, 32), 0, 4, 11, 3},
-  {3, UPB_SIZE(20, 40), 0, 0, 11, 3},
-  {4, UPB_SIZE(24, 48), 0, 3, 11, 3},
-  {5, UPB_SIZE(28, 56), 0, 1, 11, 3},
-  {6, UPB_SIZE(32, 64), 0, 4, 11, 3},
-  {7, UPB_SIZE(12, 24), 2, 5, 11, 1},
-  {8, UPB_SIZE(36, 72), 0, 6, 11, 3},
-  {9, UPB_SIZE(40, 80), 0, 2, 11, 3},
-  {10, UPB_SIZE(44, 88), 0, 0, 12, 3},
+  {1, UPB_SIZE(4, 8), 1, 0, 12, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(16, 32), 0, 4, 11, _UPB_MODE_ARRAY},
+  {3, UPB_SIZE(20, 40), 0, 0, 11, _UPB_MODE_ARRAY},
+  {4, UPB_SIZE(24, 48), 0, 3, 11, _UPB_MODE_ARRAY},
+  {5, UPB_SIZE(28, 56), 0, 1, 11, _UPB_MODE_ARRAY},
+  {6, UPB_SIZE(32, 64), 0, 4, 11, _UPB_MODE_ARRAY},
+  {7, UPB_SIZE(12, 24), 2, 5, 11, _UPB_MODE_SCALAR},
+  {8, UPB_SIZE(36, 72), 0, 6, 11, _UPB_MODE_ARRAY},
+  {9, UPB_SIZE(40, 80), 0, 2, 11, _UPB_MODE_ARRAY},
+  {10, UPB_SIZE(44, 88), 0, 0, 12, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout google_protobuf_DescriptorProto_msginit = {
   &google_protobuf_DescriptorProto_submsgs[0],
   &google_protobuf_DescriptorProto__fields[0],
-  UPB_SIZE(48, 96), 10, false, 255,
+  UPB_SIZE(48, 96), 10, false, 10, 255,
 };
 
 static const upb_msglayout *const google_protobuf_DescriptorProto_ExtensionRange_submsgs[1] = {
@@ -90,26 +90,26 @@ static const upb_msglayout *const google_protobuf_DescriptorProto_ExtensionRange
 };
 
 static const upb_msglayout_field google_protobuf_DescriptorProto_ExtensionRange__fields[3] = {
-  {1, UPB_SIZE(4, 4), 1, 0, 5, 1},
-  {2, UPB_SIZE(8, 8), 2, 0, 5, 1},
-  {3, UPB_SIZE(12, 16), 3, 0, 11, 1},
+  {1, UPB_SIZE(4, 4), 1, 0, 5, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 8), 2, 0, 5, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(12, 16), 3, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_protobuf_DescriptorProto_ExtensionRange_msginit = {
   &google_protobuf_DescriptorProto_ExtensionRange_submsgs[0],
   &google_protobuf_DescriptorProto_ExtensionRange__fields[0],
-  UPB_SIZE(16, 24), 3, false, 255,
+  UPB_SIZE(16, 24), 3, false, 3, 255,
 };
 
 static const upb_msglayout_field google_protobuf_DescriptorProto_ReservedRange__fields[2] = {
-  {1, UPB_SIZE(4, 4), 1, 0, 5, 1},
-  {2, UPB_SIZE(8, 8), 2, 0, 5, 1},
+  {1, UPB_SIZE(4, 4), 1, 0, 5, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 8), 2, 0, 5, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_protobuf_DescriptorProto_ReservedRange_msginit = {
   NULL,
   &google_protobuf_DescriptorProto_ReservedRange__fields[0],
-  UPB_SIZE(16, 16), 2, false, 255,
+  UPB_SIZE(16, 16), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const google_protobuf_ExtensionRangeOptions_submsgs[1] = {
@@ -117,13 +117,13 @@ static const upb_msglayout *const google_protobuf_ExtensionRangeOptions_submsgs[
 };
 
 static const upb_msglayout_field google_protobuf_ExtensionRangeOptions__fields[1] = {
-  {999, UPB_SIZE(0, 0), 0, 0, 11, 3},
+  {999, UPB_SIZE(0, 0), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout google_protobuf_ExtensionRangeOptions_msginit = {
   &google_protobuf_ExtensionRangeOptions_submsgs[0],
   &google_protobuf_ExtensionRangeOptions__fields[0],
-  UPB_SIZE(8, 8), 1, false, 255,
+  UPB_SIZE(8, 8), 1, false, 0, 255,
 };
 
 static const upb_msglayout *const google_protobuf_FieldDescriptorProto_submsgs[1] = {
@@ -131,23 +131,23 @@ static const upb_msglayout *const google_protobuf_FieldDescriptorProto_submsgs[1
 };
 
 static const upb_msglayout_field google_protobuf_FieldDescriptorProto__fields[11] = {
-  {1, UPB_SIZE(24, 24), 1, 0, 12, 1},
-  {2, UPB_SIZE(32, 40), 2, 0, 12, 1},
-  {3, UPB_SIZE(12, 12), 3, 0, 5, 1},
-  {4, UPB_SIZE(4, 4), 4, 0, 14, 1},
-  {5, UPB_SIZE(8, 8), 5, 0, 14, 1},
-  {6, UPB_SIZE(40, 56), 6, 0, 12, 1},
-  {7, UPB_SIZE(48, 72), 7, 0, 12, 1},
-  {8, UPB_SIZE(64, 104), 8, 0, 11, 1},
-  {9, UPB_SIZE(16, 16), 9, 0, 5, 1},
-  {10, UPB_SIZE(56, 88), 10, 0, 12, 1},
-  {17, UPB_SIZE(20, 20), 11, 0, 8, 1},
+  {1, UPB_SIZE(24, 24), 1, 0, 12, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(32, 40), 2, 0, 12, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(12, 12), 3, 0, 5, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(4, 4), 4, 0, 14, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(8, 8), 5, 0, 14, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(40, 56), 6, 0, 12, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(48, 72), 7, 0, 12, _UPB_MODE_SCALAR},
+  {8, UPB_SIZE(64, 104), 8, 0, 11, _UPB_MODE_SCALAR},
+  {9, UPB_SIZE(16, 16), 9, 0, 5, _UPB_MODE_SCALAR},
+  {10, UPB_SIZE(56, 88), 10, 0, 12, _UPB_MODE_SCALAR},
+  {17, UPB_SIZE(20, 20), 11, 0, 8, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_protobuf_FieldDescriptorProto_msginit = {
   &google_protobuf_FieldDescriptorProto_submsgs[0],
   &google_protobuf_FieldDescriptorProto__fields[0],
-  UPB_SIZE(72, 112), 11, false, 255,
+  UPB_SIZE(72, 112), 11, false, 10, 255,
 };
 
 static const upb_msglayout *const google_protobuf_OneofDescriptorProto_submsgs[1] = {
@@ -155,14 +155,14 @@ static const upb_msglayout *const google_protobuf_OneofDescriptorProto_submsgs[1
 };
 
 static const upb_msglayout_field google_protobuf_OneofDescriptorProto__fields[2] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 12, 1},
-  {2, UPB_SIZE(12, 24), 2, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 12, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(12, 24), 2, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_protobuf_OneofDescriptorProto_msginit = {
   &google_protobuf_OneofDescriptorProto_submsgs[0],
   &google_protobuf_OneofDescriptorProto__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const google_protobuf_EnumDescriptorProto_submsgs[3] = {
@@ -172,28 +172,28 @@ static const upb_msglayout *const google_protobuf_EnumDescriptorProto_submsgs[3]
 };
 
 static const upb_msglayout_field google_protobuf_EnumDescriptorProto__fields[5] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 12, 1},
-  {2, UPB_SIZE(16, 32), 0, 2, 11, 3},
-  {3, UPB_SIZE(12, 24), 2, 1, 11, 1},
-  {4, UPB_SIZE(20, 40), 0, 0, 11, 3},
-  {5, UPB_SIZE(24, 48), 0, 0, 12, 3},
+  {1, UPB_SIZE(4, 8), 1, 0, 12, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(16, 32), 0, 2, 11, _UPB_MODE_ARRAY},
+  {3, UPB_SIZE(12, 24), 2, 1, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(20, 40), 0, 0, 11, _UPB_MODE_ARRAY},
+  {5, UPB_SIZE(24, 48), 0, 0, 12, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout google_protobuf_EnumDescriptorProto_msginit = {
   &google_protobuf_EnumDescriptorProto_submsgs[0],
   &google_protobuf_EnumDescriptorProto__fields[0],
-  UPB_SIZE(32, 64), 5, false, 255,
+  UPB_SIZE(32, 64), 5, false, 5, 255,
 };
 
 static const upb_msglayout_field google_protobuf_EnumDescriptorProto_EnumReservedRange__fields[2] = {
-  {1, UPB_SIZE(4, 4), 1, 0, 5, 1},
-  {2, UPB_SIZE(8, 8), 2, 0, 5, 1},
+  {1, UPB_SIZE(4, 4), 1, 0, 5, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 8), 2, 0, 5, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_protobuf_EnumDescriptorProto_EnumReservedRange_msginit = {
   NULL,
   &google_protobuf_EnumDescriptorProto_EnumReservedRange__fields[0],
-  UPB_SIZE(16, 16), 2, false, 255,
+  UPB_SIZE(16, 16), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const google_protobuf_EnumValueDescriptorProto_submsgs[1] = {
@@ -201,15 +201,15 @@ static const upb_msglayout *const google_protobuf_EnumValueDescriptorProto_subms
 };
 
 static const upb_msglayout_field google_protobuf_EnumValueDescriptorProto__fields[3] = {
-  {1, UPB_SIZE(8, 8), 1, 0, 12, 1},
-  {2, UPB_SIZE(4, 4), 2, 0, 5, 1},
-  {3, UPB_SIZE(16, 24), 3, 0, 11, 1},
+  {1, UPB_SIZE(8, 8), 1, 0, 12, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(4, 4), 2, 0, 5, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(16, 24), 3, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_protobuf_EnumValueDescriptorProto_msginit = {
   &google_protobuf_EnumValueDescriptorProto_submsgs[0],
   &google_protobuf_EnumValueDescriptorProto__fields[0],
-  UPB_SIZE(24, 32), 3, false, 255,
+  UPB_SIZE(24, 32), 3, false, 3, 255,
 };
 
 static const upb_msglayout *const google_protobuf_ServiceDescriptorProto_submsgs[2] = {
@@ -218,15 +218,15 @@ static const upb_msglayout *const google_protobuf_ServiceDescriptorProto_submsgs
 };
 
 static const upb_msglayout_field google_protobuf_ServiceDescriptorProto__fields[3] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 12, 1},
-  {2, UPB_SIZE(16, 32), 0, 0, 11, 3},
-  {3, UPB_SIZE(12, 24), 2, 1, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 12, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(16, 32), 0, 0, 11, _UPB_MODE_ARRAY},
+  {3, UPB_SIZE(12, 24), 2, 1, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_protobuf_ServiceDescriptorProto_msginit = {
   &google_protobuf_ServiceDescriptorProto_submsgs[0],
   &google_protobuf_ServiceDescriptorProto__fields[0],
-  UPB_SIZE(24, 48), 3, false, 255,
+  UPB_SIZE(24, 48), 3, false, 3, 255,
 };
 
 static const upb_msglayout *const google_protobuf_MethodDescriptorProto_submsgs[1] = {
@@ -234,18 +234,18 @@ static const upb_msglayout *const google_protobuf_MethodDescriptorProto_submsgs[
 };
 
 static const upb_msglayout_field google_protobuf_MethodDescriptorProto__fields[6] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 12, 1},
-  {2, UPB_SIZE(12, 24), 2, 0, 12, 1},
-  {3, UPB_SIZE(20, 40), 3, 0, 12, 1},
-  {4, UPB_SIZE(28, 56), 4, 0, 11, 1},
-  {5, UPB_SIZE(1, 1), 5, 0, 8, 1},
-  {6, UPB_SIZE(2, 2), 6, 0, 8, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 12, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(12, 24), 2, 0, 12, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(20, 40), 3, 0, 12, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(28, 56), 4, 0, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(1, 1), 5, 0, 8, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(2, 2), 6, 0, 8, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_protobuf_MethodDescriptorProto_msginit = {
   &google_protobuf_MethodDescriptorProto_submsgs[0],
   &google_protobuf_MethodDescriptorProto__fields[0],
-  UPB_SIZE(32, 64), 6, false, 255,
+  UPB_SIZE(32, 64), 6, false, 6, 255,
 };
 
 static const upb_msglayout *const google_protobuf_FileOptions_submsgs[1] = {
@@ -253,33 +253,33 @@ static const upb_msglayout *const google_protobuf_FileOptions_submsgs[1] = {
 };
 
 static const upb_msglayout_field google_protobuf_FileOptions__fields[21] = {
-  {1, UPB_SIZE(20, 24), 1, 0, 12, 1},
-  {8, UPB_SIZE(28, 40), 2, 0, 12, 1},
-  {9, UPB_SIZE(4, 4), 3, 0, 14, 1},
-  {10, UPB_SIZE(8, 8), 4, 0, 8, 1},
-  {11, UPB_SIZE(36, 56), 5, 0, 12, 1},
-  {16, UPB_SIZE(9, 9), 6, 0, 8, 1},
-  {17, UPB_SIZE(10, 10), 7, 0, 8, 1},
-  {18, UPB_SIZE(11, 11), 8, 0, 8, 1},
-  {20, UPB_SIZE(12, 12), 9, 0, 8, 1},
-  {23, UPB_SIZE(13, 13), 10, 0, 8, 1},
-  {27, UPB_SIZE(14, 14), 11, 0, 8, 1},
-  {31, UPB_SIZE(15, 15), 12, 0, 8, 1},
-  {36, UPB_SIZE(44, 72), 13, 0, 12, 1},
-  {37, UPB_SIZE(52, 88), 14, 0, 12, 1},
-  {39, UPB_SIZE(60, 104), 15, 0, 12, 1},
-  {40, UPB_SIZE(68, 120), 16, 0, 12, 1},
-  {41, UPB_SIZE(76, 136), 17, 0, 12, 1},
-  {42, UPB_SIZE(16, 16), 18, 0, 8, 1},
-  {44, UPB_SIZE(84, 152), 19, 0, 12, 1},
-  {45, UPB_SIZE(92, 168), 20, 0, 12, 1},
-  {999, UPB_SIZE(100, 184), 0, 0, 11, 3},
+  {1, UPB_SIZE(20, 24), 1, 0, 12, _UPB_MODE_SCALAR},
+  {8, UPB_SIZE(28, 40), 2, 0, 12, _UPB_MODE_SCALAR},
+  {9, UPB_SIZE(4, 4), 3, 0, 14, _UPB_MODE_SCALAR},
+  {10, UPB_SIZE(8, 8), 4, 0, 8, _UPB_MODE_SCALAR},
+  {11, UPB_SIZE(36, 56), 5, 0, 12, _UPB_MODE_SCALAR},
+  {16, UPB_SIZE(9, 9), 6, 0, 8, _UPB_MODE_SCALAR},
+  {17, UPB_SIZE(10, 10), 7, 0, 8, _UPB_MODE_SCALAR},
+  {18, UPB_SIZE(11, 11), 8, 0, 8, _UPB_MODE_SCALAR},
+  {20, UPB_SIZE(12, 12), 9, 0, 8, _UPB_MODE_SCALAR},
+  {23, UPB_SIZE(13, 13), 10, 0, 8, _UPB_MODE_SCALAR},
+  {27, UPB_SIZE(14, 14), 11, 0, 8, _UPB_MODE_SCALAR},
+  {31, UPB_SIZE(15, 15), 12, 0, 8, _UPB_MODE_SCALAR},
+  {36, UPB_SIZE(44, 72), 13, 0, 12, _UPB_MODE_SCALAR},
+  {37, UPB_SIZE(52, 88), 14, 0, 12, _UPB_MODE_SCALAR},
+  {39, UPB_SIZE(60, 104), 15, 0, 12, _UPB_MODE_SCALAR},
+  {40, UPB_SIZE(68, 120), 16, 0, 12, _UPB_MODE_SCALAR},
+  {41, UPB_SIZE(76, 136), 17, 0, 12, _UPB_MODE_SCALAR},
+  {42, UPB_SIZE(16, 16), 18, 0, 8, _UPB_MODE_SCALAR},
+  {44, UPB_SIZE(84, 152), 19, 0, 12, _UPB_MODE_SCALAR},
+  {45, UPB_SIZE(92, 168), 20, 0, 12, _UPB_MODE_SCALAR},
+  {999, UPB_SIZE(100, 184), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout google_protobuf_FileOptions_msginit = {
   &google_protobuf_FileOptions_submsgs[0],
   &google_protobuf_FileOptions__fields[0],
-  UPB_SIZE(104, 192), 21, false, 255,
+  UPB_SIZE(104, 192), 21, false, 1, 255,
 };
 
 static const upb_msglayout *const google_protobuf_MessageOptions_submsgs[1] = {
@@ -287,17 +287,17 @@ static const upb_msglayout *const google_protobuf_MessageOptions_submsgs[1] = {
 };
 
 static const upb_msglayout_field google_protobuf_MessageOptions__fields[5] = {
-  {1, UPB_SIZE(1, 1), 1, 0, 8, 1},
-  {2, UPB_SIZE(2, 2), 2, 0, 8, 1},
-  {3, UPB_SIZE(3, 3), 3, 0, 8, 1},
-  {7, UPB_SIZE(4, 4), 4, 0, 8, 1},
-  {999, UPB_SIZE(8, 8), 0, 0, 11, 3},
+  {1, UPB_SIZE(1, 1), 1, 0, 8, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(2, 2), 2, 0, 8, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(3, 3), 3, 0, 8, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(4, 4), 4, 0, 8, _UPB_MODE_SCALAR},
+  {999, UPB_SIZE(8, 8), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout google_protobuf_MessageOptions_msginit = {
   &google_protobuf_MessageOptions_submsgs[0],
   &google_protobuf_MessageOptions__fields[0],
-  UPB_SIZE(16, 16), 5, false, 255,
+  UPB_SIZE(16, 16), 5, false, 3, 255,
 };
 
 static const upb_msglayout *const google_protobuf_FieldOptions_submsgs[1] = {
@@ -305,19 +305,19 @@ static const upb_msglayout *const google_protobuf_FieldOptions_submsgs[1] = {
 };
 
 static const upb_msglayout_field google_protobuf_FieldOptions__fields[7] = {
-  {1, UPB_SIZE(4, 4), 1, 0, 14, 1},
-  {2, UPB_SIZE(12, 12), 2, 0, 8, 1},
-  {3, UPB_SIZE(13, 13), 3, 0, 8, 1},
-  {5, UPB_SIZE(14, 14), 4, 0, 8, 1},
-  {6, UPB_SIZE(8, 8), 5, 0, 14, 1},
-  {10, UPB_SIZE(15, 15), 6, 0, 8, 1},
-  {999, UPB_SIZE(16, 16), 0, 0, 11, 3},
+  {1, UPB_SIZE(4, 4), 1, 0, 14, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(12, 12), 2, 0, 8, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(13, 13), 3, 0, 8, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(14, 14), 4, 0, 8, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(8, 8), 5, 0, 14, _UPB_MODE_SCALAR},
+  {10, UPB_SIZE(15, 15), 6, 0, 8, _UPB_MODE_SCALAR},
+  {999, UPB_SIZE(16, 16), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout google_protobuf_FieldOptions_msginit = {
   &google_protobuf_FieldOptions_submsgs[0],
   &google_protobuf_FieldOptions__fields[0],
-  UPB_SIZE(24, 24), 7, false, 255,
+  UPB_SIZE(24, 24), 7, false, 3, 255,
 };
 
 static const upb_msglayout *const google_protobuf_OneofOptions_submsgs[1] = {
@@ -325,13 +325,13 @@ static const upb_msglayout *const google_protobuf_OneofOptions_submsgs[1] = {
 };
 
 static const upb_msglayout_field google_protobuf_OneofOptions__fields[1] = {
-  {999, UPB_SIZE(0, 0), 0, 0, 11, 3},
+  {999, UPB_SIZE(0, 0), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout google_protobuf_OneofOptions_msginit = {
   &google_protobuf_OneofOptions_submsgs[0],
   &google_protobuf_OneofOptions__fields[0],
-  UPB_SIZE(8, 8), 1, false, 255,
+  UPB_SIZE(8, 8), 1, false, 0, 255,
 };
 
 static const upb_msglayout *const google_protobuf_EnumOptions_submsgs[1] = {
@@ -339,15 +339,15 @@ static const upb_msglayout *const google_protobuf_EnumOptions_submsgs[1] = {
 };
 
 static const upb_msglayout_field google_protobuf_EnumOptions__fields[3] = {
-  {2, UPB_SIZE(1, 1), 1, 0, 8, 1},
-  {3, UPB_SIZE(2, 2), 2, 0, 8, 1},
-  {999, UPB_SIZE(4, 8), 0, 0, 11, 3},
+  {2, UPB_SIZE(1, 1), 1, 0, 8, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(2, 2), 2, 0, 8, _UPB_MODE_SCALAR},
+  {999, UPB_SIZE(4, 8), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout google_protobuf_EnumOptions_msginit = {
   &google_protobuf_EnumOptions_submsgs[0],
   &google_protobuf_EnumOptions__fields[0],
-  UPB_SIZE(8, 16), 3, false, 255,
+  UPB_SIZE(8, 16), 3, false, 0, 255,
 };
 
 static const upb_msglayout *const google_protobuf_EnumValueOptions_submsgs[1] = {
@@ -355,14 +355,14 @@ static const upb_msglayout *const google_protobuf_EnumValueOptions_submsgs[1] =
 };
 
 static const upb_msglayout_field google_protobuf_EnumValueOptions__fields[2] = {
-  {1, UPB_SIZE(1, 1), 1, 0, 8, 1},
-  {999, UPB_SIZE(4, 8), 0, 0, 11, 3},
+  {1, UPB_SIZE(1, 1), 1, 0, 8, _UPB_MODE_SCALAR},
+  {999, UPB_SIZE(4, 8), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout google_protobuf_EnumValueOptions_msginit = {
   &google_protobuf_EnumValueOptions_submsgs[0],
   &google_protobuf_EnumValueOptions__fields[0],
-  UPB_SIZE(8, 16), 2, false, 255,
+  UPB_SIZE(8, 16), 2, false, 1, 255,
 };
 
 static const upb_msglayout *const google_protobuf_ServiceOptions_submsgs[1] = {
@@ -370,14 +370,14 @@ static const upb_msglayout *const google_protobuf_ServiceOptions_submsgs[1] = {
 };
 
 static const upb_msglayout_field google_protobuf_ServiceOptions__fields[2] = {
-  {33, UPB_SIZE(1, 1), 1, 0, 8, 1},
-  {999, UPB_SIZE(4, 8), 0, 0, 11, 3},
+  {33, UPB_SIZE(1, 1), 1, 0, 8, _UPB_MODE_SCALAR},
+  {999, UPB_SIZE(4, 8), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout google_protobuf_ServiceOptions_msginit = {
   &google_protobuf_ServiceOptions_submsgs[0],
   &google_protobuf_ServiceOptions__fields[0],
-  UPB_SIZE(8, 16), 2, false, 255,
+  UPB_SIZE(8, 16), 2, false, 0, 255,
 };
 
 static const upb_msglayout *const google_protobuf_MethodOptions_submsgs[1] = {
@@ -385,15 +385,15 @@ static const upb_msglayout *const google_protobuf_MethodOptions_submsgs[1] = {
 };
 
 static const upb_msglayout_field google_protobuf_MethodOptions__fields[3] = {
-  {33, UPB_SIZE(8, 8), 1, 0, 8, 1},
-  {34, UPB_SIZE(4, 4), 2, 0, 14, 1},
-  {999, UPB_SIZE(12, 16), 0, 0, 11, 3},
+  {33, UPB_SIZE(8, 8), 1, 0, 8, _UPB_MODE_SCALAR},
+  {34, UPB_SIZE(4, 4), 2, 0, 14, _UPB_MODE_SCALAR},
+  {999, UPB_SIZE(12, 16), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout google_protobuf_MethodOptions_msginit = {
   &google_protobuf_MethodOptions_submsgs[0],
   &google_protobuf_MethodOptions__fields[0],
-  UPB_SIZE(16, 24), 3, false, 255,
+  UPB_SIZE(16, 24), 3, false, 0, 255,
 };
 
 static const upb_msglayout *const google_protobuf_UninterpretedOption_submsgs[1] = {
@@ -401,30 +401,30 @@ static const upb_msglayout *const google_protobuf_UninterpretedOption_submsgs[1]
 };
 
 static const upb_msglayout_field google_protobuf_UninterpretedOption__fields[7] = {
-  {2, UPB_SIZE(56, 80), 0, 0, 11, 3},
-  {3, UPB_SIZE(32, 32), 1, 0, 12, 1},
-  {4, UPB_SIZE(8, 8), 2, 0, 4, 1},
-  {5, UPB_SIZE(16, 16), 3, 0, 3, 1},
-  {6, UPB_SIZE(24, 24), 4, 0, 1, 1},
-  {7, UPB_SIZE(40, 48), 5, 0, 12, 1},
-  {8, UPB_SIZE(48, 64), 6, 0, 12, 1},
+  {2, UPB_SIZE(56, 80), 0, 0, 11, _UPB_MODE_ARRAY},
+  {3, UPB_SIZE(32, 32), 1, 0, 12, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(8, 8), 2, 0, 4, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(16, 16), 3, 0, 3, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(24, 24), 4, 0, 1, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(40, 48), 5, 0, 12, _UPB_MODE_SCALAR},
+  {8, UPB_SIZE(48, 64), 6, 0, 12, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_protobuf_UninterpretedOption_msginit = {
   &google_protobuf_UninterpretedOption_submsgs[0],
   &google_protobuf_UninterpretedOption__fields[0],
-  UPB_SIZE(64, 96), 7, false, 255,
+  UPB_SIZE(64, 96), 7, false, 0, 255,
 };
 
 static const upb_msglayout_field google_protobuf_UninterpretedOption_NamePart__fields[2] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 12, 2},
-  {2, UPB_SIZE(1, 1), 2, 0, 8, 2},
+  {1, UPB_SIZE(4, 8), 1, 0, 12, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(1, 1), 2, 0, 8, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_protobuf_UninterpretedOption_NamePart_msginit = {
   NULL,
   &google_protobuf_UninterpretedOption_NamePart__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const google_protobuf_SourceCodeInfo_submsgs[1] = {
@@ -432,27 +432,27 @@ static const upb_msglayout *const google_protobuf_SourceCodeInfo_submsgs[1] = {
 };
 
 static const upb_msglayout_field google_protobuf_SourceCodeInfo__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 11, 3},
+  {1, UPB_SIZE(0, 0), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout google_protobuf_SourceCodeInfo_msginit = {
   &google_protobuf_SourceCodeInfo_submsgs[0],
   &google_protobuf_SourceCodeInfo__fields[0],
-  UPB_SIZE(8, 8), 1, false, 255,
+  UPB_SIZE(8, 8), 1, false, 1, 255,
 };
 
 static const upb_msglayout_field google_protobuf_SourceCodeInfo_Location__fields[5] = {
-  {1, UPB_SIZE(20, 40), 0, 0, 5, _UPB_LABEL_PACKED},
-  {2, UPB_SIZE(24, 48), 0, 0, 5, _UPB_LABEL_PACKED},
-  {3, UPB_SIZE(4, 8), 1, 0, 12, 1},
-  {4, UPB_SIZE(12, 24), 2, 0, 12, 1},
-  {6, UPB_SIZE(28, 56), 0, 0, 12, 3},
+  {1, UPB_SIZE(20, 40), 0, 0, 5, _UPB_MODE_ARRAY | _UPB_MODE_IS_PACKED},
+  {2, UPB_SIZE(24, 48), 0, 0, 5, _UPB_MODE_ARRAY | _UPB_MODE_IS_PACKED},
+  {3, UPB_SIZE(4, 8), 1, 0, 12, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(12, 24), 2, 0, 12, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(28, 56), 0, 0, 12, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout google_protobuf_SourceCodeInfo_Location_msginit = {
   NULL,
   &google_protobuf_SourceCodeInfo_Location__fields[0],
-  UPB_SIZE(32, 64), 5, false, 255,
+  UPB_SIZE(32, 64), 5, false, 4, 255,
 };
 
 static const upb_msglayout *const google_protobuf_GeneratedCodeInfo_submsgs[1] = {
@@ -460,26 +460,26 @@ static const upb_msglayout *const google_protobuf_GeneratedCodeInfo_submsgs[1] =
 };
 
 static const upb_msglayout_field google_protobuf_GeneratedCodeInfo__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 11, 3},
+  {1, UPB_SIZE(0, 0), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout google_protobuf_GeneratedCodeInfo_msginit = {
   &google_protobuf_GeneratedCodeInfo_submsgs[0],
   &google_protobuf_GeneratedCodeInfo__fields[0],
-  UPB_SIZE(8, 8), 1, false, 255,
+  UPB_SIZE(8, 8), 1, false, 1, 255,
 };
 
 static const upb_msglayout_field google_protobuf_GeneratedCodeInfo_Annotation__fields[4] = {
-  {1, UPB_SIZE(20, 32), 0, 0, 5, _UPB_LABEL_PACKED},
-  {2, UPB_SIZE(12, 16), 1, 0, 12, 1},
-  {3, UPB_SIZE(4, 4), 2, 0, 5, 1},
-  {4, UPB_SIZE(8, 8), 3, 0, 5, 1},
+  {1, UPB_SIZE(20, 32), 0, 0, 5, _UPB_MODE_ARRAY | _UPB_MODE_IS_PACKED},
+  {2, UPB_SIZE(12, 16), 1, 0, 12, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(4, 4), 2, 0, 5, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(8, 8), 3, 0, 5, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_protobuf_GeneratedCodeInfo_Annotation_msginit = {
   NULL,
   &google_protobuf_GeneratedCodeInfo_Annotation__fields[0],
-  UPB_SIZE(24, 48), 4, false, 255,
+  UPB_SIZE(24, 48), 4, false, 4, 255,
 };
 
 #include "upb/port_undef.inc"
index a8ed71a..4767b3a 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef GOOGLE_PROTOBUF_DESCRIPTOR_PROTO_UPB_H_
 #define GOOGLE_PROTOBUF_DESCRIPTOR_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -162,13 +162,19 @@ UPB_INLINE google_protobuf_FileDescriptorSet *google_protobuf_FileDescriptorSet_
 UPB_INLINE google_protobuf_FileDescriptorSet *google_protobuf_FileDescriptorSet_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_FileDescriptorSet *ret = google_protobuf_FileDescriptorSet_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_FileDescriptorSet_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_FileDescriptorSet_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_FileDescriptorSet *google_protobuf_FileDescriptorSet_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_FileDescriptorSet *ret = google_protobuf_FileDescriptorSet_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_FileDescriptorSet_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_FileDescriptorSet_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_FileDescriptorSet_serialize(const google_protobuf_FileDescriptorSet *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_FileDescriptorSet_msginit, arena, len);
@@ -199,13 +205,19 @@ UPB_INLINE google_protobuf_FileDescriptorProto *google_protobuf_FileDescriptorPr
 UPB_INLINE google_protobuf_FileDescriptorProto *google_protobuf_FileDescriptorProto_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_FileDescriptorProto *ret = google_protobuf_FileDescriptorProto_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_FileDescriptorProto_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_FileDescriptorProto_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_FileDescriptorProto *google_protobuf_FileDescriptorProto_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_FileDescriptorProto *ret = google_protobuf_FileDescriptorProto_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_FileDescriptorProto_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_FileDescriptorProto_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_FileDescriptorProto_serialize(const google_protobuf_FileDescriptorProto *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_FileDescriptorProto_msginit, arena, len);
@@ -362,13 +374,19 @@ UPB_INLINE google_protobuf_DescriptorProto *google_protobuf_DescriptorProto_new(
 UPB_INLINE google_protobuf_DescriptorProto *google_protobuf_DescriptorProto_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_DescriptorProto *ret = google_protobuf_DescriptorProto_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_DescriptorProto_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_DescriptorProto_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_DescriptorProto *google_protobuf_DescriptorProto_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_DescriptorProto *ret = google_protobuf_DescriptorProto_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_DescriptorProto_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_DescriptorProto_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_DescriptorProto_serialize(const google_protobuf_DescriptorProto *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_DescriptorProto_msginit, arena, len);
@@ -521,13 +539,19 @@ UPB_INLINE google_protobuf_DescriptorProto_ExtensionRange *google_protobuf_Descr
 UPB_INLINE google_protobuf_DescriptorProto_ExtensionRange *google_protobuf_DescriptorProto_ExtensionRange_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_DescriptorProto_ExtensionRange *ret = google_protobuf_DescriptorProto_ExtensionRange_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_DescriptorProto_ExtensionRange_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_DescriptorProto_ExtensionRange_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_DescriptorProto_ExtensionRange *google_protobuf_DescriptorProto_ExtensionRange_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_DescriptorProto_ExtensionRange *ret = google_protobuf_DescriptorProto_ExtensionRange_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_DescriptorProto_ExtensionRange_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_DescriptorProto_ExtensionRange_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_DescriptorProto_ExtensionRange_serialize(const google_protobuf_DescriptorProto_ExtensionRange *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_DescriptorProto_ExtensionRange_msginit, arena, len);
@@ -570,13 +594,19 @@ UPB_INLINE google_protobuf_DescriptorProto_ReservedRange *google_protobuf_Descri
 UPB_INLINE google_protobuf_DescriptorProto_ReservedRange *google_protobuf_DescriptorProto_ReservedRange_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_DescriptorProto_ReservedRange *ret = google_protobuf_DescriptorProto_ReservedRange_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_DescriptorProto_ReservedRange_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_DescriptorProto_ReservedRange_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_DescriptorProto_ReservedRange *google_protobuf_DescriptorProto_ReservedRange_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_DescriptorProto_ReservedRange *ret = google_protobuf_DescriptorProto_ReservedRange_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_DescriptorProto_ReservedRange_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_DescriptorProto_ReservedRange_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_DescriptorProto_ReservedRange_serialize(const google_protobuf_DescriptorProto_ReservedRange *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_DescriptorProto_ReservedRange_msginit, arena, len);
@@ -604,13 +634,19 @@ UPB_INLINE google_protobuf_ExtensionRangeOptions *google_protobuf_ExtensionRange
 UPB_INLINE google_protobuf_ExtensionRangeOptions *google_protobuf_ExtensionRangeOptions_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_ExtensionRangeOptions *ret = google_protobuf_ExtensionRangeOptions_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_ExtensionRangeOptions_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_ExtensionRangeOptions_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_ExtensionRangeOptions *google_protobuf_ExtensionRangeOptions_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_ExtensionRangeOptions *ret = google_protobuf_ExtensionRangeOptions_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_ExtensionRangeOptions_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_ExtensionRangeOptions_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_ExtensionRangeOptions_serialize(const google_protobuf_ExtensionRangeOptions *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_ExtensionRangeOptions_msginit, arena, len);
@@ -641,13 +677,19 @@ UPB_INLINE google_protobuf_FieldDescriptorProto *google_protobuf_FieldDescriptor
 UPB_INLINE google_protobuf_FieldDescriptorProto *google_protobuf_FieldDescriptorProto_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_FieldDescriptorProto *ret = google_protobuf_FieldDescriptorProto_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_FieldDescriptorProto_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_FieldDescriptorProto_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_FieldDescriptorProto *google_protobuf_FieldDescriptorProto_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_FieldDescriptorProto *ret = google_protobuf_FieldDescriptorProto_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_FieldDescriptorProto_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_FieldDescriptorProto_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_FieldDescriptorProto_serialize(const google_protobuf_FieldDescriptorProto *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_FieldDescriptorProto_msginit, arena, len);
@@ -738,13 +780,19 @@ UPB_INLINE google_protobuf_OneofDescriptorProto *google_protobuf_OneofDescriptor
 UPB_INLINE google_protobuf_OneofDescriptorProto *google_protobuf_OneofDescriptorProto_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_OneofDescriptorProto *ret = google_protobuf_OneofDescriptorProto_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_OneofDescriptorProto_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_OneofDescriptorProto_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_OneofDescriptorProto *google_protobuf_OneofDescriptorProto_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_OneofDescriptorProto *ret = google_protobuf_OneofDescriptorProto_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_OneofDescriptorProto_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_OneofDescriptorProto_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_OneofDescriptorProto_serialize(const google_protobuf_OneofDescriptorProto *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_OneofDescriptorProto_msginit, arena, len);
@@ -781,13 +829,19 @@ UPB_INLINE google_protobuf_EnumDescriptorProto *google_protobuf_EnumDescriptorPr
 UPB_INLINE google_protobuf_EnumDescriptorProto *google_protobuf_EnumDescriptorProto_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_EnumDescriptorProto *ret = google_protobuf_EnumDescriptorProto_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_EnumDescriptorProto_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_EnumDescriptorProto_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_EnumDescriptorProto *google_protobuf_EnumDescriptorProto_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_EnumDescriptorProto *ret = google_protobuf_EnumDescriptorProto_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_EnumDescriptorProto_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_EnumDescriptorProto_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_EnumDescriptorProto_serialize(const google_protobuf_EnumDescriptorProto *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_EnumDescriptorProto_msginit, arena, len);
@@ -865,13 +919,19 @@ UPB_INLINE google_protobuf_EnumDescriptorProto_EnumReservedRange *google_protobu
 UPB_INLINE google_protobuf_EnumDescriptorProto_EnumReservedRange *google_protobuf_EnumDescriptorProto_EnumReservedRange_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_EnumDescriptorProto_EnumReservedRange *ret = google_protobuf_EnumDescriptorProto_EnumReservedRange_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_EnumDescriptorProto_EnumReservedRange_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_EnumDescriptorProto_EnumReservedRange_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_EnumDescriptorProto_EnumReservedRange *google_protobuf_EnumDescriptorProto_EnumReservedRange_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_EnumDescriptorProto_EnumReservedRange *ret = google_protobuf_EnumDescriptorProto_EnumReservedRange_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_EnumDescriptorProto_EnumReservedRange_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_EnumDescriptorProto_EnumReservedRange_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_EnumDescriptorProto_EnumReservedRange_serialize(const google_protobuf_EnumDescriptorProto_EnumReservedRange *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_EnumDescriptorProto_EnumReservedRange_msginit, arena, len);
@@ -899,13 +959,19 @@ UPB_INLINE google_protobuf_EnumValueDescriptorProto *google_protobuf_EnumValueDe
 UPB_INLINE google_protobuf_EnumValueDescriptorProto *google_protobuf_EnumValueDescriptorProto_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_EnumValueDescriptorProto *ret = google_protobuf_EnumValueDescriptorProto_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_EnumValueDescriptorProto_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_EnumValueDescriptorProto_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_EnumValueDescriptorProto *google_protobuf_EnumValueDescriptorProto_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_EnumValueDescriptorProto *ret = google_protobuf_EnumValueDescriptorProto_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_EnumValueDescriptorProto_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_EnumValueDescriptorProto_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_EnumValueDescriptorProto_serialize(const google_protobuf_EnumValueDescriptorProto *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_EnumValueDescriptorProto_msginit, arena, len);
@@ -948,13 +1014,19 @@ UPB_INLINE google_protobuf_ServiceDescriptorProto *google_protobuf_ServiceDescri
 UPB_INLINE google_protobuf_ServiceDescriptorProto *google_protobuf_ServiceDescriptorProto_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_ServiceDescriptorProto *ret = google_protobuf_ServiceDescriptorProto_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_ServiceDescriptorProto_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_ServiceDescriptorProto_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_ServiceDescriptorProto *google_protobuf_ServiceDescriptorProto_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_ServiceDescriptorProto *ret = google_protobuf_ServiceDescriptorProto_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_ServiceDescriptorProto_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_ServiceDescriptorProto_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_ServiceDescriptorProto_serialize(const google_protobuf_ServiceDescriptorProto *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_ServiceDescriptorProto_msginit, arena, len);
@@ -1006,13 +1078,19 @@ UPB_INLINE google_protobuf_MethodDescriptorProto *google_protobuf_MethodDescript
 UPB_INLINE google_protobuf_MethodDescriptorProto *google_protobuf_MethodDescriptorProto_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_MethodDescriptorProto *ret = google_protobuf_MethodDescriptorProto_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_MethodDescriptorProto_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_MethodDescriptorProto_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_MethodDescriptorProto *google_protobuf_MethodDescriptorProto_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_MethodDescriptorProto *ret = google_protobuf_MethodDescriptorProto_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_MethodDescriptorProto_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_MethodDescriptorProto_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_MethodDescriptorProto_serialize(const google_protobuf_MethodDescriptorProto *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_MethodDescriptorProto_msginit, arena, len);
@@ -1073,13 +1151,19 @@ UPB_INLINE google_protobuf_FileOptions *google_protobuf_FileOptions_new(upb_aren
 UPB_INLINE google_protobuf_FileOptions *google_protobuf_FileOptions_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_FileOptions *ret = google_protobuf_FileOptions_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_FileOptions_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_FileOptions_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_FileOptions *google_protobuf_FileOptions_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_FileOptions *ret = google_protobuf_FileOptions_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_FileOptions_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_FileOptions_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_FileOptions_serialize(const google_protobuf_FileOptions *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_FileOptions_msginit, arena, len);
@@ -1230,13 +1314,19 @@ UPB_INLINE google_protobuf_MessageOptions *google_protobuf_MessageOptions_new(up
 UPB_INLINE google_protobuf_MessageOptions *google_protobuf_MessageOptions_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_MessageOptions *ret = google_protobuf_MessageOptions_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_MessageOptions_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_MessageOptions_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_MessageOptions *google_protobuf_MessageOptions_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_MessageOptions *ret = google_protobuf_MessageOptions_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_MessageOptions_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_MessageOptions_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_MessageOptions_serialize(const google_protobuf_MessageOptions *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_MessageOptions_msginit, arena, len);
@@ -1291,13 +1381,19 @@ UPB_INLINE google_protobuf_FieldOptions *google_protobuf_FieldOptions_new(upb_ar
 UPB_INLINE google_protobuf_FieldOptions *google_protobuf_FieldOptions_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_FieldOptions *ret = google_protobuf_FieldOptions_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_FieldOptions_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_FieldOptions_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_FieldOptions *google_protobuf_FieldOptions_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_FieldOptions *ret = google_protobuf_FieldOptions_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_FieldOptions_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_FieldOptions_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_FieldOptions_serialize(const google_protobuf_FieldOptions *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_FieldOptions_msginit, arena, len);
@@ -1364,13 +1460,19 @@ UPB_INLINE google_protobuf_OneofOptions *google_protobuf_OneofOptions_new(upb_ar
 UPB_INLINE google_protobuf_OneofOptions *google_protobuf_OneofOptions_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_OneofOptions *ret = google_protobuf_OneofOptions_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_OneofOptions_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_OneofOptions_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_OneofOptions *google_protobuf_OneofOptions_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_OneofOptions *ret = google_protobuf_OneofOptions_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_OneofOptions_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_OneofOptions_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_OneofOptions_serialize(const google_protobuf_OneofOptions *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_OneofOptions_msginit, arena, len);
@@ -1401,13 +1503,19 @@ UPB_INLINE google_protobuf_EnumOptions *google_protobuf_EnumOptions_new(upb_aren
 UPB_INLINE google_protobuf_EnumOptions *google_protobuf_EnumOptions_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_EnumOptions *ret = google_protobuf_EnumOptions_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_EnumOptions_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_EnumOptions_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_EnumOptions *google_protobuf_EnumOptions_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_EnumOptions *ret = google_protobuf_EnumOptions_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_EnumOptions_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_EnumOptions_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_EnumOptions_serialize(const google_protobuf_EnumOptions *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_EnumOptions_msginit, arena, len);
@@ -1450,13 +1558,19 @@ UPB_INLINE google_protobuf_EnumValueOptions *google_protobuf_EnumValueOptions_ne
 UPB_INLINE google_protobuf_EnumValueOptions *google_protobuf_EnumValueOptions_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_EnumValueOptions *ret = google_protobuf_EnumValueOptions_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_EnumValueOptions_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_EnumValueOptions_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_EnumValueOptions *google_protobuf_EnumValueOptions_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_EnumValueOptions *ret = google_protobuf_EnumValueOptions_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_EnumValueOptions_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_EnumValueOptions_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_EnumValueOptions_serialize(const google_protobuf_EnumValueOptions *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_EnumValueOptions_msginit, arena, len);
@@ -1493,13 +1607,19 @@ UPB_INLINE google_protobuf_ServiceOptions *google_protobuf_ServiceOptions_new(up
 UPB_INLINE google_protobuf_ServiceOptions *google_protobuf_ServiceOptions_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_ServiceOptions *ret = google_protobuf_ServiceOptions_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_ServiceOptions_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_ServiceOptions_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_ServiceOptions *google_protobuf_ServiceOptions_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_ServiceOptions *ret = google_protobuf_ServiceOptions_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_ServiceOptions_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_ServiceOptions_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_ServiceOptions_serialize(const google_protobuf_ServiceOptions *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_ServiceOptions_msginit, arena, len);
@@ -1536,13 +1656,19 @@ UPB_INLINE google_protobuf_MethodOptions *google_protobuf_MethodOptions_new(upb_
 UPB_INLINE google_protobuf_MethodOptions *google_protobuf_MethodOptions_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_MethodOptions *ret = google_protobuf_MethodOptions_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_MethodOptions_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_MethodOptions_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_MethodOptions *google_protobuf_MethodOptions_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_MethodOptions *ret = google_protobuf_MethodOptions_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_MethodOptions_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_MethodOptions_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_MethodOptions_serialize(const google_protobuf_MethodOptions *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_MethodOptions_msginit, arena, len);
@@ -1585,13 +1711,19 @@ UPB_INLINE google_protobuf_UninterpretedOption *google_protobuf_UninterpretedOpt
 UPB_INLINE google_protobuf_UninterpretedOption *google_protobuf_UninterpretedOption_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_UninterpretedOption *ret = google_protobuf_UninterpretedOption_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_UninterpretedOption_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_UninterpretedOption_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_UninterpretedOption *google_protobuf_UninterpretedOption_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_UninterpretedOption *ret = google_protobuf_UninterpretedOption_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_UninterpretedOption_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_UninterpretedOption_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_UninterpretedOption_serialize(const google_protobuf_UninterpretedOption *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_UninterpretedOption_msginit, arena, len);
@@ -1658,13 +1790,19 @@ UPB_INLINE google_protobuf_UninterpretedOption_NamePart *google_protobuf_Uninter
 UPB_INLINE google_protobuf_UninterpretedOption_NamePart *google_protobuf_UninterpretedOption_NamePart_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_UninterpretedOption_NamePart *ret = google_protobuf_UninterpretedOption_NamePart_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_UninterpretedOption_NamePart_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_UninterpretedOption_NamePart_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_UninterpretedOption_NamePart *google_protobuf_UninterpretedOption_NamePart_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_UninterpretedOption_NamePart *ret = google_protobuf_UninterpretedOption_NamePart_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_UninterpretedOption_NamePart_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_UninterpretedOption_NamePart_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_UninterpretedOption_NamePart_serialize(const google_protobuf_UninterpretedOption_NamePart *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_UninterpretedOption_NamePart_msginit, arena, len);
@@ -1692,13 +1830,19 @@ UPB_INLINE google_protobuf_SourceCodeInfo *google_protobuf_SourceCodeInfo_new(up
 UPB_INLINE google_protobuf_SourceCodeInfo *google_protobuf_SourceCodeInfo_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_SourceCodeInfo *ret = google_protobuf_SourceCodeInfo_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_SourceCodeInfo_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_SourceCodeInfo_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_SourceCodeInfo *google_protobuf_SourceCodeInfo_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_SourceCodeInfo *ret = google_protobuf_SourceCodeInfo_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_SourceCodeInfo_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_SourceCodeInfo_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_SourceCodeInfo_serialize(const google_protobuf_SourceCodeInfo *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_SourceCodeInfo_msginit, arena, len);
@@ -1729,13 +1873,19 @@ UPB_INLINE google_protobuf_SourceCodeInfo_Location *google_protobuf_SourceCodeIn
 UPB_INLINE google_protobuf_SourceCodeInfo_Location *google_protobuf_SourceCodeInfo_Location_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_SourceCodeInfo_Location *ret = google_protobuf_SourceCodeInfo_Location_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_SourceCodeInfo_Location_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_SourceCodeInfo_Location_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_SourceCodeInfo_Location *google_protobuf_SourceCodeInfo_Location_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_SourceCodeInfo_Location *ret = google_protobuf_SourceCodeInfo_Location_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_SourceCodeInfo_Location_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_SourceCodeInfo_Location_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_SourceCodeInfo_Location_serialize(const google_protobuf_SourceCodeInfo_Location *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_SourceCodeInfo_Location_msginit, arena, len);
@@ -1796,13 +1946,19 @@ UPB_INLINE google_protobuf_GeneratedCodeInfo *google_protobuf_GeneratedCodeInfo_
 UPB_INLINE google_protobuf_GeneratedCodeInfo *google_protobuf_GeneratedCodeInfo_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_GeneratedCodeInfo *ret = google_protobuf_GeneratedCodeInfo_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_GeneratedCodeInfo_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_GeneratedCodeInfo_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_GeneratedCodeInfo *google_protobuf_GeneratedCodeInfo_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_GeneratedCodeInfo *ret = google_protobuf_GeneratedCodeInfo_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_GeneratedCodeInfo_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_GeneratedCodeInfo_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_GeneratedCodeInfo_serialize(const google_protobuf_GeneratedCodeInfo *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_GeneratedCodeInfo_msginit, arena, len);
@@ -1833,13 +1989,19 @@ UPB_INLINE google_protobuf_GeneratedCodeInfo_Annotation *google_protobuf_Generat
 UPB_INLINE google_protobuf_GeneratedCodeInfo_Annotation *google_protobuf_GeneratedCodeInfo_Annotation_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_GeneratedCodeInfo_Annotation *ret = google_protobuf_GeneratedCodeInfo_Annotation_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_GeneratedCodeInfo_Annotation_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_GeneratedCodeInfo_Annotation_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_GeneratedCodeInfo_Annotation *google_protobuf_GeneratedCodeInfo_Annotation_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_GeneratedCodeInfo_Annotation *ret = google_protobuf_GeneratedCodeInfo_Annotation_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_GeneratedCodeInfo_Annotation_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_GeneratedCodeInfo_Annotation_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_GeneratedCodeInfo_Annotation_serialize(const google_protobuf_GeneratedCodeInfo_Annotation *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_GeneratedCodeInfo_Annotation_msginit, arena, len);
index 03d463a..9382942 100644 (file)
@@ -7,20 +7,20 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "google/protobuf/duration.upb.h"
 
 #include "upb/port_def.inc"
 
 static const upb_msglayout_field google_protobuf_Duration__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 3, 1},
-  {2, UPB_SIZE(8, 8), 0, 0, 5, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 3, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 8), 0, 0, 5, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_protobuf_Duration_msginit = {
   NULL,
   &google_protobuf_Duration__fields[0],
-  UPB_SIZE(16, 16), 2, false, 255,
+  UPB_SIZE(16, 16), 2, false, 2, 255,
 };
 
 #include "upb/port_undef.inc"
index 4692fd7..1b65ee0 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef GOOGLE_PROTOBUF_DURATION_PROTO_UPB_H_
 #define GOOGLE_PROTOBUF_DURATION_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -33,13 +33,19 @@ UPB_INLINE google_protobuf_Duration *google_protobuf_Duration_new(upb_arena *are
 UPB_INLINE google_protobuf_Duration *google_protobuf_Duration_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_Duration *ret = google_protobuf_Duration_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_Duration_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_Duration_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_Duration *google_protobuf_Duration_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_Duration *ret = google_protobuf_Duration_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_Duration_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_Duration_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_Duration_serialize(const google_protobuf_Duration *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_Duration_msginit, arena, len);
index f634b2b..7e483e5 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "google/protobuf/empty.upb.h"
 
 #include "upb/port_def.inc"
@@ -15,7 +15,7 @@
 const upb_msglayout google_protobuf_Empty_msginit = {
   NULL,
   NULL,
-  UPB_SIZE(0, 0), 0, false, 255,
+  UPB_SIZE(0, 0), 0, false, 0, 255,
 };
 
 #include "upb/port_undef.inc"
index 9202b83..1046eb1 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef GOOGLE_PROTOBUF_EMPTY_PROTO_UPB_H_
 #define GOOGLE_PROTOBUF_EMPTY_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -33,13 +33,19 @@ UPB_INLINE google_protobuf_Empty *google_protobuf_Empty_new(upb_arena *arena) {
 UPB_INLINE google_protobuf_Empty *google_protobuf_Empty_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_Empty *ret = google_protobuf_Empty_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_Empty_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_Empty_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_Empty *google_protobuf_Empty_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_Empty *ret = google_protobuf_Empty_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_Empty_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_Empty_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_Empty_serialize(const google_protobuf_Empty *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_Empty_msginit, arena, len);
index 04b9167..a49f986 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "google/protobuf/struct.upb.h"
 
 #include "upb/port_def.inc"
@@ -17,13 +17,13 @@ static const upb_msglayout *const google_protobuf_Struct_submsgs[1] = {
 };
 
 static const upb_msglayout_field google_protobuf_Struct__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 11, _UPB_LABEL_MAP},
+  {1, UPB_SIZE(0, 0), 0, 0, 11, _UPB_MODE_MAP},
 };
 
 const upb_msglayout google_protobuf_Struct_msginit = {
   &google_protobuf_Struct_submsgs[0],
   &google_protobuf_Struct__fields[0],
-  UPB_SIZE(8, 8), 1, false, 255,
+  UPB_SIZE(8, 8), 1, false, 1, 255,
 };
 
 static const upb_msglayout *const google_protobuf_Struct_FieldsEntry_submsgs[1] = {
@@ -31,14 +31,14 @@ static const upb_msglayout *const google_protobuf_Struct_FieldsEntry_submsgs[1]
 };
 
 static const upb_msglayout_field google_protobuf_Struct_FieldsEntry__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {2, UPB_SIZE(8, 16), 0, 0, 11, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 0, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_protobuf_Struct_FieldsEntry_msginit = {
   &google_protobuf_Struct_FieldsEntry_submsgs[0],
   &google_protobuf_Struct_FieldsEntry__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const google_protobuf_Value_submsgs[2] = {
@@ -47,18 +47,18 @@ static const upb_msglayout *const google_protobuf_Value_submsgs[2] = {
 };
 
 static const upb_msglayout_field google_protobuf_Value__fields[6] = {
-  {1, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 14, 1},
-  {2, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 1, 1},
-  {3, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 9, 1},
-  {4, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 8, 1},
-  {5, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 1, 11, 1},
-  {6, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 11, 1},
+  {1, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 14, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 1, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 9, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 8, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 1, 11, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_protobuf_Value_msginit = {
   &google_protobuf_Value_submsgs[0],
   &google_protobuf_Value__fields[0],
-  UPB_SIZE(16, 32), 6, false, 255,
+  UPB_SIZE(16, 32), 6, false, 6, 255,
 };
 
 static const upb_msglayout *const google_protobuf_ListValue_submsgs[1] = {
@@ -66,13 +66,13 @@ static const upb_msglayout *const google_protobuf_ListValue_submsgs[1] = {
 };
 
 static const upb_msglayout_field google_protobuf_ListValue__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 11, 3},
+  {1, UPB_SIZE(0, 0), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout google_protobuf_ListValue_msginit = {
   &google_protobuf_ListValue_submsgs[0],
   &google_protobuf_ListValue__fields[0],
-  UPB_SIZE(8, 8), 1, false, 255,
+  UPB_SIZE(8, 8), 1, false, 1, 255,
 };
 
 #include "upb/port_undef.inc"
index 29fec82..c33a36f 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef GOOGLE_PROTOBUF_STRUCT_PROTO_UPB_H_
 #define GOOGLE_PROTOBUF_STRUCT_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -46,13 +46,19 @@ UPB_INLINE google_protobuf_Struct *google_protobuf_Struct_new(upb_arena *arena)
 UPB_INLINE google_protobuf_Struct *google_protobuf_Struct_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_Struct *ret = google_protobuf_Struct_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_Struct_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_Struct_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_Struct *google_protobuf_Struct_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_Struct *ret = google_protobuf_Struct_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_Struct_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_Struct_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_Struct_serialize(const google_protobuf_Struct *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_Struct_msginit, arena, len);
@@ -94,13 +100,19 @@ UPB_INLINE google_protobuf_Value *google_protobuf_Value_new(upb_arena *arena) {
 UPB_INLINE google_protobuf_Value *google_protobuf_Value_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_Value *ret = google_protobuf_Value_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_Value_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_Value_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_Value *google_protobuf_Value_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_Value *ret = google_protobuf_Value_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_Value_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_Value_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_Value_serialize(const google_protobuf_Value *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_Value_msginit, arena, len);
@@ -175,13 +187,19 @@ UPB_INLINE google_protobuf_ListValue *google_protobuf_ListValue_new(upb_arena *a
 UPB_INLINE google_protobuf_ListValue *google_protobuf_ListValue_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_ListValue *ret = google_protobuf_ListValue_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_ListValue_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_ListValue_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_ListValue *google_protobuf_ListValue_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_ListValue *ret = google_protobuf_ListValue_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_ListValue_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_ListValue_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_ListValue_serialize(const google_protobuf_ListValue *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_ListValue_msginit, arena, len);
index 718ce3b..574c633 100644 (file)
@@ -7,20 +7,20 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "google/protobuf/timestamp.upb.h"
 
 #include "upb/port_def.inc"
 
 static const upb_msglayout_field google_protobuf_Timestamp__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 3, 1},
-  {2, UPB_SIZE(8, 8), 0, 0, 5, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 3, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 8), 0, 0, 5, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_protobuf_Timestamp_msginit = {
   NULL,
   &google_protobuf_Timestamp__fields[0],
-  UPB_SIZE(16, 16), 2, false, 255,
+  UPB_SIZE(16, 16), 2, false, 2, 255,
 };
 
 #include "upb/port_undef.inc"
index 31c1145..058d90b 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef GOOGLE_PROTOBUF_TIMESTAMP_PROTO_UPB_H_
 #define GOOGLE_PROTOBUF_TIMESTAMP_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -33,13 +33,19 @@ UPB_INLINE google_protobuf_Timestamp *google_protobuf_Timestamp_new(upb_arena *a
 UPB_INLINE google_protobuf_Timestamp *google_protobuf_Timestamp_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_Timestamp *ret = google_protobuf_Timestamp_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_Timestamp_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_Timestamp_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_Timestamp *google_protobuf_Timestamp_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_Timestamp *ret = google_protobuf_Timestamp_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_Timestamp_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_Timestamp_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_Timestamp_serialize(const google_protobuf_Timestamp *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_Timestamp_msginit, arena, len);
index aabc174..cf926df 100644 (file)
@@ -7,99 +7,99 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "google/protobuf/wrappers.upb.h"
 
 #include "upb/port_def.inc"
 
 static const upb_msglayout_field google_protobuf_DoubleValue__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 1, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 1, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_protobuf_DoubleValue_msginit = {
   NULL,
   &google_protobuf_DoubleValue__fields[0],
-  UPB_SIZE(8, 8), 1, false, 255,
+  UPB_SIZE(8, 8), 1, false, 1, 255,
 };
 
 static const upb_msglayout_field google_protobuf_FloatValue__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 2, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 2, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_protobuf_FloatValue_msginit = {
   NULL,
   &google_protobuf_FloatValue__fields[0],
-  UPB_SIZE(8, 8), 1, false, 255,
+  UPB_SIZE(8, 8), 1, false, 1, 255,
 };
 
 static const upb_msglayout_field google_protobuf_Int64Value__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 3, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 3, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_protobuf_Int64Value_msginit = {
   NULL,
   &google_protobuf_Int64Value__fields[0],
-  UPB_SIZE(8, 8), 1, false, 255,
+  UPB_SIZE(8, 8), 1, false, 1, 255,
 };
 
 static const upb_msglayout_field google_protobuf_UInt64Value__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 4, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 4, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_protobuf_UInt64Value_msginit = {
   NULL,
   &google_protobuf_UInt64Value__fields[0],
-  UPB_SIZE(8, 8), 1, false, 255,
+  UPB_SIZE(8, 8), 1, false, 1, 255,
 };
 
 static const upb_msglayout_field google_protobuf_Int32Value__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 5, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 5, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_protobuf_Int32Value_msginit = {
   NULL,
   &google_protobuf_Int32Value__fields[0],
-  UPB_SIZE(8, 8), 1, false, 255,
+  UPB_SIZE(8, 8), 1, false, 1, 255,
 };
 
 static const upb_msglayout_field google_protobuf_UInt32Value__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 13, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 13, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_protobuf_UInt32Value_msginit = {
   NULL,
   &google_protobuf_UInt32Value__fields[0],
-  UPB_SIZE(8, 8), 1, false, 255,
+  UPB_SIZE(8, 8), 1, false, 1, 255,
 };
 
 static const upb_msglayout_field google_protobuf_BoolValue__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 8, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 8, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_protobuf_BoolValue_msginit = {
   NULL,
   &google_protobuf_BoolValue__fields[0],
-  UPB_SIZE(8, 8), 1, false, 255,
+  UPB_SIZE(8, 8), 1, false, 1, 255,
 };
 
 static const upb_msglayout_field google_protobuf_StringValue__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_protobuf_StringValue_msginit = {
   NULL,
   &google_protobuf_StringValue__fields[0],
-  UPB_SIZE(8, 16), 1, false, 255,
+  UPB_SIZE(8, 16), 1, false, 1, 255,
 };
 
 static const upb_msglayout_field google_protobuf_BytesValue__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 12, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 12, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_protobuf_BytesValue_msginit = {
   NULL,
   &google_protobuf_BytesValue__fields[0],
-  UPB_SIZE(8, 16), 1, false, 255,
+  UPB_SIZE(8, 16), 1, false, 1, 255,
 };
 
 #include "upb/port_undef.inc"
index c184b80..356bae6 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef GOOGLE_PROTOBUF_WRAPPERS_PROTO_UPB_H_
 #define GOOGLE_PROTOBUF_WRAPPERS_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -57,13 +57,19 @@ UPB_INLINE google_protobuf_DoubleValue *google_protobuf_DoubleValue_new(upb_aren
 UPB_INLINE google_protobuf_DoubleValue *google_protobuf_DoubleValue_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_DoubleValue *ret = google_protobuf_DoubleValue_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_DoubleValue_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_DoubleValue_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_DoubleValue *google_protobuf_DoubleValue_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_DoubleValue *ret = google_protobuf_DoubleValue_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_DoubleValue_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_DoubleValue_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_DoubleValue_serialize(const google_protobuf_DoubleValue *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_DoubleValue_msginit, arena, len);
@@ -83,13 +89,19 @@ UPB_INLINE google_protobuf_FloatValue *google_protobuf_FloatValue_new(upb_arena
 UPB_INLINE google_protobuf_FloatValue *google_protobuf_FloatValue_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_FloatValue *ret = google_protobuf_FloatValue_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_FloatValue_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_FloatValue_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_FloatValue *google_protobuf_FloatValue_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_FloatValue *ret = google_protobuf_FloatValue_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_FloatValue_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_FloatValue_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_FloatValue_serialize(const google_protobuf_FloatValue *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_FloatValue_msginit, arena, len);
@@ -109,13 +121,19 @@ UPB_INLINE google_protobuf_Int64Value *google_protobuf_Int64Value_new(upb_arena
 UPB_INLINE google_protobuf_Int64Value *google_protobuf_Int64Value_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_Int64Value *ret = google_protobuf_Int64Value_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_Int64Value_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_Int64Value_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_Int64Value *google_protobuf_Int64Value_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_Int64Value *ret = google_protobuf_Int64Value_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_Int64Value_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_Int64Value_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_Int64Value_serialize(const google_protobuf_Int64Value *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_Int64Value_msginit, arena, len);
@@ -135,13 +153,19 @@ UPB_INLINE google_protobuf_UInt64Value *google_protobuf_UInt64Value_new(upb_aren
 UPB_INLINE google_protobuf_UInt64Value *google_protobuf_UInt64Value_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_UInt64Value *ret = google_protobuf_UInt64Value_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_UInt64Value_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_UInt64Value_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_UInt64Value *google_protobuf_UInt64Value_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_UInt64Value *ret = google_protobuf_UInt64Value_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_UInt64Value_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_UInt64Value_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_UInt64Value_serialize(const google_protobuf_UInt64Value *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_UInt64Value_msginit, arena, len);
@@ -161,13 +185,19 @@ UPB_INLINE google_protobuf_Int32Value *google_protobuf_Int32Value_new(upb_arena
 UPB_INLINE google_protobuf_Int32Value *google_protobuf_Int32Value_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_Int32Value *ret = google_protobuf_Int32Value_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_Int32Value_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_Int32Value_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_Int32Value *google_protobuf_Int32Value_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_Int32Value *ret = google_protobuf_Int32Value_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_Int32Value_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_Int32Value_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_Int32Value_serialize(const google_protobuf_Int32Value *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_Int32Value_msginit, arena, len);
@@ -187,13 +217,19 @@ UPB_INLINE google_protobuf_UInt32Value *google_protobuf_UInt32Value_new(upb_aren
 UPB_INLINE google_protobuf_UInt32Value *google_protobuf_UInt32Value_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_UInt32Value *ret = google_protobuf_UInt32Value_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_UInt32Value_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_UInt32Value_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_UInt32Value *google_protobuf_UInt32Value_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_UInt32Value *ret = google_protobuf_UInt32Value_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_UInt32Value_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_UInt32Value_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_UInt32Value_serialize(const google_protobuf_UInt32Value *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_UInt32Value_msginit, arena, len);
@@ -213,13 +249,19 @@ UPB_INLINE google_protobuf_BoolValue *google_protobuf_BoolValue_new(upb_arena *a
 UPB_INLINE google_protobuf_BoolValue *google_protobuf_BoolValue_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_BoolValue *ret = google_protobuf_BoolValue_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_BoolValue_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_BoolValue_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_BoolValue *google_protobuf_BoolValue_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_BoolValue *ret = google_protobuf_BoolValue_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_BoolValue_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_BoolValue_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_BoolValue_serialize(const google_protobuf_BoolValue *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_BoolValue_msginit, arena, len);
@@ -239,13 +281,19 @@ UPB_INLINE google_protobuf_StringValue *google_protobuf_StringValue_new(upb_aren
 UPB_INLINE google_protobuf_StringValue *google_protobuf_StringValue_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_StringValue *ret = google_protobuf_StringValue_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_StringValue_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_StringValue_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_StringValue *google_protobuf_StringValue_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_StringValue *ret = google_protobuf_StringValue_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_StringValue_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_StringValue_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_StringValue_serialize(const google_protobuf_StringValue *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_StringValue_msginit, arena, len);
@@ -265,13 +313,19 @@ UPB_INLINE google_protobuf_BytesValue *google_protobuf_BytesValue_new(upb_arena
 UPB_INLINE google_protobuf_BytesValue *google_protobuf_BytesValue_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_BytesValue *ret = google_protobuf_BytesValue_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_BytesValue_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_BytesValue_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_BytesValue *google_protobuf_BytesValue_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_BytesValue *ret = google_protobuf_BytesValue_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_BytesValue_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_BytesValue_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_BytesValue_serialize(const google_protobuf_BytesValue *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_BytesValue_msginit, arena, len);
index e276a0d..365fd50 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "google/rpc/status.upb.h"
 #include "google/protobuf/any.upb.h"
 
@@ -18,15 +18,15 @@ static const upb_msglayout *const google_rpc_Status_submsgs[1] = {
 };
 
 static const upb_msglayout_field google_rpc_Status__fields[3] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 5, 1},
-  {2, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {3, UPB_SIZE(12, 24), 0, 0, 11, 3},
+  {1, UPB_SIZE(0, 0), 0, 0, 5, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(12, 24), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout google_rpc_Status_msginit = {
   &google_rpc_Status_submsgs[0],
   &google_rpc_Status__fields[0],
-  UPB_SIZE(16, 32), 3, false, 255,
+  UPB_SIZE(16, 32), 3, false, 3, 255,
 };
 
 #include "upb/port_undef.inc"
index 4cc29b3..32031f4 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef GOOGLE_RPC_STATUS_PROTO_UPB_H_
 #define GOOGLE_RPC_STATUS_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -35,13 +35,19 @@ UPB_INLINE google_rpc_Status *google_rpc_Status_new(upb_arena *arena) {
 UPB_INLINE google_rpc_Status *google_rpc_Status_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_rpc_Status *ret = google_rpc_Status_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_rpc_Status_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_rpc_Status_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_rpc_Status *google_rpc_Status_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_rpc_Status *ret = google_rpc_Status_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_rpc_Status_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_rpc_Status_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_rpc_Status_serialize(const google_rpc_Status *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_rpc_Status_msginit, arena, len);
index 8b6de3f..adf57dc 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "src/proto/grpc/gcp/altscontext.upb.h"
 #include "src/proto/grpc/gcp/transport_security_common.upb.h"
 
@@ -19,30 +19,30 @@ static const upb_msglayout *const grpc_gcp_AltsContext_submsgs[2] = {
 };
 
 static const upb_msglayout_field grpc_gcp_AltsContext__fields[7] = {
-  {1, UPB_SIZE(8, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(16, 24), 0, 0, 9, 1},
-  {3, UPB_SIZE(4, 4), 0, 0, 14, 1},
-  {4, UPB_SIZE(24, 40), 0, 0, 9, 1},
-  {5, UPB_SIZE(32, 56), 0, 0, 9, 1},
-  {6, UPB_SIZE(40, 72), 1, 1, 11, 1},
-  {7, UPB_SIZE(44, 80), 0, 0, 11, _UPB_LABEL_MAP},
+  {1, UPB_SIZE(8, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(16, 24), 0, 0, 9, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(4, 4), 0, 0, 14, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(24, 40), 0, 0, 9, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(32, 56), 0, 0, 9, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(40, 72), 1, 1, 11, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(44, 80), 0, 0, 11, _UPB_MODE_MAP},
 };
 
 const upb_msglayout grpc_gcp_AltsContext_msginit = {
   &grpc_gcp_AltsContext_submsgs[0],
   &grpc_gcp_AltsContext__fields[0],
-  UPB_SIZE(48, 96), 7, false, 255,
+  UPB_SIZE(48, 96), 7, false, 7, 255,
 };
 
 static const upb_msglayout_field grpc_gcp_AltsContext_PeerAttributesEntry__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {2, UPB_SIZE(8, 16), 0, 0, 9, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 0, 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout grpc_gcp_AltsContext_PeerAttributesEntry_msginit = {
   NULL,
   &grpc_gcp_AltsContext_PeerAttributesEntry__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 #include "upb/port_undef.inc"
index 3a91b53..da1b96c 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef SRC_PROTO_GRPC_GCP_ALTSCONTEXT_PROTO_UPB_H_
 #define SRC_PROTO_GRPC_GCP_ALTSCONTEXT_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -38,13 +38,19 @@ UPB_INLINE grpc_gcp_AltsContext *grpc_gcp_AltsContext_new(upb_arena *arena) {
 UPB_INLINE grpc_gcp_AltsContext *grpc_gcp_AltsContext_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   grpc_gcp_AltsContext *ret = grpc_gcp_AltsContext_new(arena);
-  return (ret && upb_decode(buf, size, ret, &grpc_gcp_AltsContext_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &grpc_gcp_AltsContext_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE grpc_gcp_AltsContext *grpc_gcp_AltsContext_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   grpc_gcp_AltsContext *ret = grpc_gcp_AltsContext_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &grpc_gcp_AltsContext_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &grpc_gcp_AltsContext_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *grpc_gcp_AltsContext_serialize(const grpc_gcp_AltsContext *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &grpc_gcp_AltsContext_msginit, arena, len);
index 998f2d8..05eea6e 100644 (file)
@@ -7,22 +7,22 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "src/proto/grpc/gcp/handshaker.upb.h"
 #include "src/proto/grpc/gcp/transport_security_common.upb.h"
 
 #include "upb/port_def.inc"
 
 static const upb_msglayout_field grpc_gcp_Endpoint__fields[3] = {
-  {1, UPB_SIZE(8, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(4, 4), 0, 0, 5, 1},
-  {3, UPB_SIZE(0, 0), 0, 0, 14, 1},
+  {1, UPB_SIZE(8, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(4, 4), 0, 0, 5, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(0, 0), 0, 0, 14, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout grpc_gcp_Endpoint_msginit = {
   NULL,
   &grpc_gcp_Endpoint__fields[0],
-  UPB_SIZE(16, 32), 3, false, 255,
+  UPB_SIZE(16, 32), 3, false, 3, 255,
 };
 
 static const upb_msglayout *const grpc_gcp_Identity_submsgs[1] = {
@@ -30,26 +30,26 @@ static const upb_msglayout *const grpc_gcp_Identity_submsgs[1] = {
 };
 
 static const upb_msglayout_field grpc_gcp_Identity__fields[3] = {
-  {1, UPB_SIZE(4, 8), UPB_SIZE(-13, -25), 0, 9, 1},
-  {2, UPB_SIZE(4, 8), UPB_SIZE(-13, -25), 0, 9, 1},
-  {3, UPB_SIZE(0, 0), 0, 0, 11, _UPB_LABEL_MAP},
+  {1, UPB_SIZE(4, 8), UPB_SIZE(-13, -25), 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(4, 8), UPB_SIZE(-13, -25), 0, 9, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(0, 0), 0, 0, 11, _UPB_MODE_MAP},
 };
 
 const upb_msglayout grpc_gcp_Identity_msginit = {
   &grpc_gcp_Identity_submsgs[0],
   &grpc_gcp_Identity__fields[0],
-  UPB_SIZE(16, 32), 3, false, 255,
+  UPB_SIZE(16, 32), 3, false, 3, 255,
 };
 
 static const upb_msglayout_field grpc_gcp_Identity_AttributesEntry__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {2, UPB_SIZE(8, 16), 0, 0, 9, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 0, 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout grpc_gcp_Identity_AttributesEntry_msginit = {
   NULL,
   &grpc_gcp_Identity_AttributesEntry__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const grpc_gcp_StartClientHandshakeReq_submsgs[3] = {
@@ -59,22 +59,22 @@ static const upb_msglayout *const grpc_gcp_StartClientHandshakeReq_submsgs[3] =
 };
 
 static const upb_msglayout_field grpc_gcp_StartClientHandshakeReq__fields[10] = {
-  {1, UPB_SIZE(4, 4), 0, 0, 14, 1},
-  {2, UPB_SIZE(36, 64), 0, 0, 9, 3},
-  {3, UPB_SIZE(40, 72), 0, 0, 9, 3},
-  {4, UPB_SIZE(44, 80), 0, 1, 11, 3},
-  {5, UPB_SIZE(20, 32), 1, 1, 11, 1},
-  {6, UPB_SIZE(24, 40), 2, 0, 11, 1},
-  {7, UPB_SIZE(28, 48), 3, 0, 11, 1},
-  {8, UPB_SIZE(12, 16), 0, 0, 9, 1},
-  {9, UPB_SIZE(32, 56), 4, 2, 11, 1},
-  {10, UPB_SIZE(8, 8), 0, 0, 13, 1},
+  {1, UPB_SIZE(4, 4), 0, 0, 14, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(36, 64), 0, 0, 9, _UPB_MODE_ARRAY},
+  {3, UPB_SIZE(40, 72), 0, 0, 9, _UPB_MODE_ARRAY},
+  {4, UPB_SIZE(44, 80), 0, 1, 11, _UPB_MODE_ARRAY},
+  {5, UPB_SIZE(20, 32), 1, 1, 11, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(24, 40), 2, 0, 11, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(28, 48), 3, 0, 11, _UPB_MODE_SCALAR},
+  {8, UPB_SIZE(12, 16), 0, 0, 9, _UPB_MODE_SCALAR},
+  {9, UPB_SIZE(32, 56), 4, 2, 11, _UPB_MODE_SCALAR},
+  {10, UPB_SIZE(8, 8), 0, 0, 13, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout grpc_gcp_StartClientHandshakeReq_msginit = {
   &grpc_gcp_StartClientHandshakeReq_submsgs[0],
   &grpc_gcp_StartClientHandshakeReq__fields[0],
-  UPB_SIZE(48, 96), 10, false, 255,
+  UPB_SIZE(48, 96), 10, false, 10, 255,
 };
 
 static const upb_msglayout *const grpc_gcp_ServerHandshakeParameters_submsgs[1] = {
@@ -82,14 +82,14 @@ static const upb_msglayout *const grpc_gcp_ServerHandshakeParameters_submsgs[1]
 };
 
 static const upb_msglayout_field grpc_gcp_ServerHandshakeParameters__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 3},
-  {2, UPB_SIZE(4, 8), 0, 0, 11, 3},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_ARRAY},
+  {2, UPB_SIZE(4, 8), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout grpc_gcp_ServerHandshakeParameters_msginit = {
   &grpc_gcp_ServerHandshakeParameters_submsgs[0],
   &grpc_gcp_ServerHandshakeParameters__fields[0],
-  UPB_SIZE(8, 16), 2, false, 255,
+  UPB_SIZE(8, 16), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const grpc_gcp_StartServerHandshakeReq_submsgs[3] = {
@@ -99,19 +99,19 @@ static const upb_msglayout *const grpc_gcp_StartServerHandshakeReq_submsgs[3] =
 };
 
 static const upb_msglayout_field grpc_gcp_StartServerHandshakeReq__fields[7] = {
-  {1, UPB_SIZE(28, 48), 0, 0, 9, 3},
-  {2, UPB_SIZE(32, 56), 0, 2, 11, _UPB_LABEL_MAP},
-  {3, UPB_SIZE(8, 8), 0, 0, 12, 1},
-  {4, UPB_SIZE(16, 24), 1, 0, 11, 1},
-  {5, UPB_SIZE(20, 32), 2, 0, 11, 1},
-  {6, UPB_SIZE(24, 40), 3, 1, 11, 1},
-  {7, UPB_SIZE(4, 4), 0, 0, 13, 1},
+  {1, UPB_SIZE(28, 48), 0, 0, 9, _UPB_MODE_ARRAY},
+  {2, UPB_SIZE(32, 56), 0, 2, 11, _UPB_MODE_MAP},
+  {3, UPB_SIZE(8, 8), 0, 0, 12, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(16, 24), 1, 0, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(20, 32), 2, 0, 11, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(24, 40), 3, 1, 11, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(4, 4), 0, 0, 13, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout grpc_gcp_StartServerHandshakeReq_msginit = {
   &grpc_gcp_StartServerHandshakeReq_submsgs[0],
   &grpc_gcp_StartServerHandshakeReq__fields[0],
-  UPB_SIZE(40, 64), 7, false, 255,
+  UPB_SIZE(40, 64), 7, false, 7, 255,
 };
 
 static const upb_msglayout *const grpc_gcp_StartServerHandshakeReq_HandshakeParametersEntry_submsgs[1] = {
@@ -119,24 +119,24 @@ static const upb_msglayout *const grpc_gcp_StartServerHandshakeReq_HandshakePara
 };
 
 static const upb_msglayout_field grpc_gcp_StartServerHandshakeReq_HandshakeParametersEntry__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 5, 1},
-  {2, UPB_SIZE(8, 16), 0, 0, 11, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 5, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 0, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout grpc_gcp_StartServerHandshakeReq_HandshakeParametersEntry_msginit = {
   &grpc_gcp_StartServerHandshakeReq_HandshakeParametersEntry_submsgs[0],
   &grpc_gcp_StartServerHandshakeReq_HandshakeParametersEntry__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout_field grpc_gcp_NextHandshakeMessageReq__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 12, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 12, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout grpc_gcp_NextHandshakeMessageReq_msginit = {
   NULL,
   &grpc_gcp_NextHandshakeMessageReq__fields[0],
-  UPB_SIZE(8, 16), 1, false, 255,
+  UPB_SIZE(8, 16), 1, false, 1, 255,
 };
 
 static const upb_msglayout *const grpc_gcp_HandshakerReq_submsgs[3] = {
@@ -146,15 +146,15 @@ static const upb_msglayout *const grpc_gcp_HandshakerReq_submsgs[3] = {
 };
 
 static const upb_msglayout_field grpc_gcp_HandshakerReq__fields[3] = {
-  {1, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 1, 11, 1},
-  {2, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 2, 11, 1},
-  {3, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 11, 1},
+  {1, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 1, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 2, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout grpc_gcp_HandshakerReq_msginit = {
   &grpc_gcp_HandshakerReq_submsgs[0],
   &grpc_gcp_HandshakerReq__fields[0],
-  UPB_SIZE(8, 16), 3, false, 255,
+  UPB_SIZE(8, 16), 3, false, 3, 255,
 };
 
 static const upb_msglayout *const grpc_gcp_HandshakerResult_submsgs[2] = {
@@ -163,31 +163,31 @@ static const upb_msglayout *const grpc_gcp_HandshakerResult_submsgs[2] = {
 };
 
 static const upb_msglayout_field grpc_gcp_HandshakerResult__fields[8] = {
-  {1, UPB_SIZE(12, 16), 0, 0, 9, 1},
-  {2, UPB_SIZE(20, 32), 0, 0, 9, 1},
-  {3, UPB_SIZE(28, 48), 0, 0, 12, 1},
-  {4, UPB_SIZE(36, 64), 1, 0, 11, 1},
-  {5, UPB_SIZE(40, 72), 2, 0, 11, 1},
-  {6, UPB_SIZE(8, 8), 0, 0, 8, 1},
-  {7, UPB_SIZE(44, 80), 3, 1, 11, 1},
-  {8, UPB_SIZE(4, 4), 0, 0, 13, 1},
+  {1, UPB_SIZE(12, 16), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(20, 32), 0, 0, 9, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(28, 48), 0, 0, 12, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(36, 64), 1, 0, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(40, 72), 2, 0, 11, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(8, 8), 0, 0, 8, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(44, 80), 3, 1, 11, _UPB_MODE_SCALAR},
+  {8, UPB_SIZE(4, 4), 0, 0, 13, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout grpc_gcp_HandshakerResult_msginit = {
   &grpc_gcp_HandshakerResult_submsgs[0],
   &grpc_gcp_HandshakerResult__fields[0],
-  UPB_SIZE(48, 96), 8, false, 255,
+  UPB_SIZE(48, 96), 8, false, 8, 255,
 };
 
 static const upb_msglayout_field grpc_gcp_HandshakerStatus__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 13, 1},
-  {2, UPB_SIZE(4, 8), 0, 0, 9, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 13, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout grpc_gcp_HandshakerStatus_msginit = {
   NULL,
   &grpc_gcp_HandshakerStatus__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const grpc_gcp_HandshakerResp_submsgs[2] = {
@@ -196,16 +196,16 @@ static const upb_msglayout *const grpc_gcp_HandshakerResp_submsgs[2] = {
 };
 
 static const upb_msglayout_field grpc_gcp_HandshakerResp__fields[4] = {
-  {1, UPB_SIZE(8, 8), 0, 0, 12, 1},
-  {2, UPB_SIZE(4, 4), 0, 0, 13, 1},
-  {3, UPB_SIZE(16, 24), 1, 0, 11, 1},
-  {4, UPB_SIZE(20, 32), 2, 1, 11, 1},
+  {1, UPB_SIZE(8, 8), 0, 0, 12, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(4, 4), 0, 0, 13, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(16, 24), 1, 0, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(20, 32), 2, 1, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout grpc_gcp_HandshakerResp_msginit = {
   &grpc_gcp_HandshakerResp_submsgs[0],
   &grpc_gcp_HandshakerResp__fields[0],
-  UPB_SIZE(24, 48), 4, false, 255,
+  UPB_SIZE(24, 48), 4, false, 4, 255,
 };
 
 #include "upb/port_undef.inc"
index e4c5bf6..922657a 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef SRC_PROTO_GRPC_GCP_HANDSHAKER_PROTO_UPB_H_
 #define SRC_PROTO_GRPC_GCP_HANDSHAKER_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -80,13 +80,19 @@ UPB_INLINE grpc_gcp_Endpoint *grpc_gcp_Endpoint_new(upb_arena *arena) {
 UPB_INLINE grpc_gcp_Endpoint *grpc_gcp_Endpoint_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   grpc_gcp_Endpoint *ret = grpc_gcp_Endpoint_new(arena);
-  return (ret && upb_decode(buf, size, ret, &grpc_gcp_Endpoint_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &grpc_gcp_Endpoint_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE grpc_gcp_Endpoint *grpc_gcp_Endpoint_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   grpc_gcp_Endpoint *ret = grpc_gcp_Endpoint_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &grpc_gcp_Endpoint_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &grpc_gcp_Endpoint_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *grpc_gcp_Endpoint_serialize(const grpc_gcp_Endpoint *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &grpc_gcp_Endpoint_msginit, arena, len);
@@ -114,13 +120,19 @@ UPB_INLINE grpc_gcp_Identity *grpc_gcp_Identity_new(upb_arena *arena) {
 UPB_INLINE grpc_gcp_Identity *grpc_gcp_Identity_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   grpc_gcp_Identity *ret = grpc_gcp_Identity_new(arena);
-  return (ret && upb_decode(buf, size, ret, &grpc_gcp_Identity_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &grpc_gcp_Identity_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE grpc_gcp_Identity *grpc_gcp_Identity_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   grpc_gcp_Identity *ret = grpc_gcp_Identity_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &grpc_gcp_Identity_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &grpc_gcp_Identity_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *grpc_gcp_Identity_serialize(const grpc_gcp_Identity *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &grpc_gcp_Identity_msginit, arena, len);
@@ -178,13 +190,19 @@ UPB_INLINE grpc_gcp_StartClientHandshakeReq *grpc_gcp_StartClientHandshakeReq_ne
 UPB_INLINE grpc_gcp_StartClientHandshakeReq *grpc_gcp_StartClientHandshakeReq_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   grpc_gcp_StartClientHandshakeReq *ret = grpc_gcp_StartClientHandshakeReq_new(arena);
-  return (ret && upb_decode(buf, size, ret, &grpc_gcp_StartClientHandshakeReq_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &grpc_gcp_StartClientHandshakeReq_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE grpc_gcp_StartClientHandshakeReq *grpc_gcp_StartClientHandshakeReq_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   grpc_gcp_StartClientHandshakeReq *ret = grpc_gcp_StartClientHandshakeReq_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &grpc_gcp_StartClientHandshakeReq_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &grpc_gcp_StartClientHandshakeReq_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *grpc_gcp_StartClientHandshakeReq_serialize(const grpc_gcp_StartClientHandshakeReq *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &grpc_gcp_StartClientHandshakeReq_msginit, arena, len);
@@ -309,13 +327,19 @@ UPB_INLINE grpc_gcp_ServerHandshakeParameters *grpc_gcp_ServerHandshakeParameter
 UPB_INLINE grpc_gcp_ServerHandshakeParameters *grpc_gcp_ServerHandshakeParameters_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   grpc_gcp_ServerHandshakeParameters *ret = grpc_gcp_ServerHandshakeParameters_new(arena);
-  return (ret && upb_decode(buf, size, ret, &grpc_gcp_ServerHandshakeParameters_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &grpc_gcp_ServerHandshakeParameters_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE grpc_gcp_ServerHandshakeParameters *grpc_gcp_ServerHandshakeParameters_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   grpc_gcp_ServerHandshakeParameters *ret = grpc_gcp_ServerHandshakeParameters_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &grpc_gcp_ServerHandshakeParameters_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &grpc_gcp_ServerHandshakeParameters_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *grpc_gcp_ServerHandshakeParameters_serialize(const grpc_gcp_ServerHandshakeParameters *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &grpc_gcp_ServerHandshakeParameters_msginit, arena, len);
@@ -357,13 +381,19 @@ UPB_INLINE grpc_gcp_StartServerHandshakeReq *grpc_gcp_StartServerHandshakeReq_ne
 UPB_INLINE grpc_gcp_StartServerHandshakeReq *grpc_gcp_StartServerHandshakeReq_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   grpc_gcp_StartServerHandshakeReq *ret = grpc_gcp_StartServerHandshakeReq_new(arena);
-  return (ret && upb_decode(buf, size, ret, &grpc_gcp_StartServerHandshakeReq_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &grpc_gcp_StartServerHandshakeReq_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE grpc_gcp_StartServerHandshakeReq *grpc_gcp_StartServerHandshakeReq_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   grpc_gcp_StartServerHandshakeReq *ret = grpc_gcp_StartServerHandshakeReq_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &grpc_gcp_StartServerHandshakeReq_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &grpc_gcp_StartServerHandshakeReq_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *grpc_gcp_StartServerHandshakeReq_serialize(const grpc_gcp_StartServerHandshakeReq *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &grpc_gcp_StartServerHandshakeReq_msginit, arena, len);
@@ -469,13 +499,19 @@ UPB_INLINE grpc_gcp_NextHandshakeMessageReq *grpc_gcp_NextHandshakeMessageReq_ne
 UPB_INLINE grpc_gcp_NextHandshakeMessageReq *grpc_gcp_NextHandshakeMessageReq_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   grpc_gcp_NextHandshakeMessageReq *ret = grpc_gcp_NextHandshakeMessageReq_new(arena);
-  return (ret && upb_decode(buf, size, ret, &grpc_gcp_NextHandshakeMessageReq_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &grpc_gcp_NextHandshakeMessageReq_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE grpc_gcp_NextHandshakeMessageReq *grpc_gcp_NextHandshakeMessageReq_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   grpc_gcp_NextHandshakeMessageReq *ret = grpc_gcp_NextHandshakeMessageReq_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &grpc_gcp_NextHandshakeMessageReq_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &grpc_gcp_NextHandshakeMessageReq_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *grpc_gcp_NextHandshakeMessageReq_serialize(const grpc_gcp_NextHandshakeMessageReq *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &grpc_gcp_NextHandshakeMessageReq_msginit, arena, len);
@@ -495,13 +531,19 @@ UPB_INLINE grpc_gcp_HandshakerReq *grpc_gcp_HandshakerReq_new(upb_arena *arena)
 UPB_INLINE grpc_gcp_HandshakerReq *grpc_gcp_HandshakerReq_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   grpc_gcp_HandshakerReq *ret = grpc_gcp_HandshakerReq_new(arena);
-  return (ret && upb_decode(buf, size, ret, &grpc_gcp_HandshakerReq_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &grpc_gcp_HandshakerReq_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE grpc_gcp_HandshakerReq *grpc_gcp_HandshakerReq_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   grpc_gcp_HandshakerReq *ret = grpc_gcp_HandshakerReq_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &grpc_gcp_HandshakerReq_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &grpc_gcp_HandshakerReq_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *grpc_gcp_HandshakerReq_serialize(const grpc_gcp_HandshakerReq *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &grpc_gcp_HandshakerReq_msginit, arena, len);
@@ -567,13 +609,19 @@ UPB_INLINE grpc_gcp_HandshakerResult *grpc_gcp_HandshakerResult_new(upb_arena *a
 UPB_INLINE grpc_gcp_HandshakerResult *grpc_gcp_HandshakerResult_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   grpc_gcp_HandshakerResult *ret = grpc_gcp_HandshakerResult_new(arena);
-  return (ret && upb_decode(buf, size, ret, &grpc_gcp_HandshakerResult_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &grpc_gcp_HandshakerResult_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE grpc_gcp_HandshakerResult *grpc_gcp_HandshakerResult_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   grpc_gcp_HandshakerResult *ret = grpc_gcp_HandshakerResult_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &grpc_gcp_HandshakerResult_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &grpc_gcp_HandshakerResult_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *grpc_gcp_HandshakerResult_serialize(const grpc_gcp_HandshakerResult *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &grpc_gcp_HandshakerResult_msginit, arena, len);
@@ -654,13 +702,19 @@ UPB_INLINE grpc_gcp_HandshakerStatus *grpc_gcp_HandshakerStatus_new(upb_arena *a
 UPB_INLINE grpc_gcp_HandshakerStatus *grpc_gcp_HandshakerStatus_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   grpc_gcp_HandshakerStatus *ret = grpc_gcp_HandshakerStatus_new(arena);
-  return (ret && upb_decode(buf, size, ret, &grpc_gcp_HandshakerStatus_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &grpc_gcp_HandshakerStatus_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE grpc_gcp_HandshakerStatus *grpc_gcp_HandshakerStatus_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   grpc_gcp_HandshakerStatus *ret = grpc_gcp_HandshakerStatus_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &grpc_gcp_HandshakerStatus_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &grpc_gcp_HandshakerStatus_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *grpc_gcp_HandshakerStatus_serialize(const grpc_gcp_HandshakerStatus *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &grpc_gcp_HandshakerStatus_msginit, arena, len);
@@ -684,13 +738,19 @@ UPB_INLINE grpc_gcp_HandshakerResp *grpc_gcp_HandshakerResp_new(upb_arena *arena
 UPB_INLINE grpc_gcp_HandshakerResp *grpc_gcp_HandshakerResp_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   grpc_gcp_HandshakerResp *ret = grpc_gcp_HandshakerResp_new(arena);
-  return (ret && upb_decode(buf, size, ret, &grpc_gcp_HandshakerResp_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &grpc_gcp_HandshakerResp_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE grpc_gcp_HandshakerResp *grpc_gcp_HandshakerResp_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   grpc_gcp_HandshakerResp *ret = grpc_gcp_HandshakerResp_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &grpc_gcp_HandshakerResp_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &grpc_gcp_HandshakerResp_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *grpc_gcp_HandshakerResp_serialize(const grpc_gcp_HandshakerResp *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &grpc_gcp_HandshakerResp_msginit, arena, len);
index 136c30d..a29a485 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "src/proto/grpc/gcp/transport_security_common.upb.h"
 
 #include "upb/port_def.inc"
@@ -17,25 +17,25 @@ static const upb_msglayout *const grpc_gcp_RpcProtocolVersions_submsgs[1] = {
 };
 
 static const upb_msglayout_field grpc_gcp_RpcProtocolVersions__fields[2] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 11, 1},
-  {2, UPB_SIZE(8, 16), 2, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 2, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout grpc_gcp_RpcProtocolVersions_msginit = {
   &grpc_gcp_RpcProtocolVersions_submsgs[0],
   &grpc_gcp_RpcProtocolVersions__fields[0],
-  UPB_SIZE(16, 24), 2, false, 255,
+  UPB_SIZE(16, 24), 2, false, 2, 255,
 };
 
 static const upb_msglayout_field grpc_gcp_RpcProtocolVersions_Version__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 13, 1},
-  {2, UPB_SIZE(4, 4), 0, 0, 13, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 13, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(4, 4), 0, 0, 13, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout grpc_gcp_RpcProtocolVersions_Version_msginit = {
   NULL,
   &grpc_gcp_RpcProtocolVersions_Version__fields[0],
-  UPB_SIZE(8, 8), 2, false, 255,
+  UPB_SIZE(8, 8), 2, false, 2, 255,
 };
 
 #include "upb/port_undef.inc"
index 9e02e0b..fbba7cc 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef SRC_PROTO_GRPC_GCP_TRANSPORT_SECURITY_COMMON_PROTO_UPB_H_
 #define SRC_PROTO_GRPC_GCP_TRANSPORT_SECURITY_COMMON_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -42,13 +42,19 @@ UPB_INLINE grpc_gcp_RpcProtocolVersions *grpc_gcp_RpcProtocolVersions_new(upb_ar
 UPB_INLINE grpc_gcp_RpcProtocolVersions *grpc_gcp_RpcProtocolVersions_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   grpc_gcp_RpcProtocolVersions *ret = grpc_gcp_RpcProtocolVersions_new(arena);
-  return (ret && upb_decode(buf, size, ret, &grpc_gcp_RpcProtocolVersions_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &grpc_gcp_RpcProtocolVersions_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE grpc_gcp_RpcProtocolVersions *grpc_gcp_RpcProtocolVersions_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   grpc_gcp_RpcProtocolVersions *ret = grpc_gcp_RpcProtocolVersions_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &grpc_gcp_RpcProtocolVersions_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &grpc_gcp_RpcProtocolVersions_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *grpc_gcp_RpcProtocolVersions_serialize(const grpc_gcp_RpcProtocolVersions *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &grpc_gcp_RpcProtocolVersions_msginit, arena, len);
@@ -94,13 +100,19 @@ UPB_INLINE grpc_gcp_RpcProtocolVersions_Version *grpc_gcp_RpcProtocolVersions_Ve
 UPB_INLINE grpc_gcp_RpcProtocolVersions_Version *grpc_gcp_RpcProtocolVersions_Version_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   grpc_gcp_RpcProtocolVersions_Version *ret = grpc_gcp_RpcProtocolVersions_Version_new(arena);
-  return (ret && upb_decode(buf, size, ret, &grpc_gcp_RpcProtocolVersions_Version_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &grpc_gcp_RpcProtocolVersions_Version_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE grpc_gcp_RpcProtocolVersions_Version *grpc_gcp_RpcProtocolVersions_Version_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   grpc_gcp_RpcProtocolVersions_Version *ret = grpc_gcp_RpcProtocolVersions_Version_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &grpc_gcp_RpcProtocolVersions_Version_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &grpc_gcp_RpcProtocolVersions_Version_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *grpc_gcp_RpcProtocolVersions_Version_serialize(const grpc_gcp_RpcProtocolVersions_Version *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &grpc_gcp_RpcProtocolVersions_Version_msginit, arena, len);
index df8d846..5a728e6 100644 (file)
@@ -7,29 +7,29 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "src/proto/grpc/health/v1/health.upb.h"
 
 #include "upb/port_def.inc"
 
 static const upb_msglayout_field grpc_health_v1_HealthCheckRequest__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout grpc_health_v1_HealthCheckRequest_msginit = {
   NULL,
   &grpc_health_v1_HealthCheckRequest__fields[0],
-  UPB_SIZE(8, 16), 1, false, 255,
+  UPB_SIZE(8, 16), 1, false, 1, 255,
 };
 
 static const upb_msglayout_field grpc_health_v1_HealthCheckResponse__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 14, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 14, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout grpc_health_v1_HealthCheckResponse_msginit = {
   NULL,
   &grpc_health_v1_HealthCheckResponse__fields[0],
-  UPB_SIZE(8, 8), 1, false, 255,
+  UPB_SIZE(8, 8), 1, false, 1, 255,
 };
 
 #include "upb/port_undef.inc"
index 361b221..22bc39c 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef SRC_PROTO_GRPC_HEALTH_V1_HEALTH_PROTO_UPB_H_
 #define SRC_PROTO_GRPC_HEALTH_V1_HEALTH_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -43,13 +43,19 @@ UPB_INLINE grpc_health_v1_HealthCheckRequest *grpc_health_v1_HealthCheckRequest_
 UPB_INLINE grpc_health_v1_HealthCheckRequest *grpc_health_v1_HealthCheckRequest_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   grpc_health_v1_HealthCheckRequest *ret = grpc_health_v1_HealthCheckRequest_new(arena);
-  return (ret && upb_decode(buf, size, ret, &grpc_health_v1_HealthCheckRequest_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &grpc_health_v1_HealthCheckRequest_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE grpc_health_v1_HealthCheckRequest *grpc_health_v1_HealthCheckRequest_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   grpc_health_v1_HealthCheckRequest *ret = grpc_health_v1_HealthCheckRequest_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &grpc_health_v1_HealthCheckRequest_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &grpc_health_v1_HealthCheckRequest_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *grpc_health_v1_HealthCheckRequest_serialize(const grpc_health_v1_HealthCheckRequest *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &grpc_health_v1_HealthCheckRequest_msginit, arena, len);
@@ -69,13 +75,19 @@ UPB_INLINE grpc_health_v1_HealthCheckResponse *grpc_health_v1_HealthCheckRespons
 UPB_INLINE grpc_health_v1_HealthCheckResponse *grpc_health_v1_HealthCheckResponse_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   grpc_health_v1_HealthCheckResponse *ret = grpc_health_v1_HealthCheckResponse_new(arena);
-  return (ret && upb_decode(buf, size, ret, &grpc_health_v1_HealthCheckResponse_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &grpc_health_v1_HealthCheckResponse_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE grpc_health_v1_HealthCheckResponse *grpc_health_v1_HealthCheckResponse_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   grpc_health_v1_HealthCheckResponse *ret = grpc_health_v1_HealthCheckResponse_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &grpc_health_v1_HealthCheckResponse_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &grpc_health_v1_HealthCheckResponse_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *grpc_health_v1_HealthCheckResponse_serialize(const grpc_health_v1_HealthCheckResponse *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &grpc_health_v1_HealthCheckResponse_msginit, arena, len);
index 3ecf09f..032fbc6 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "src/proto/grpc/lb/v1/load_balancer.upb.h"
 #include "google/protobuf/duration.upb.h"
 #include "google/protobuf/timestamp.upb.h"
@@ -20,35 +20,35 @@ static const upb_msglayout *const grpc_lb_v1_LoadBalanceRequest_submsgs[2] = {
 };
 
 static const upb_msglayout_field grpc_lb_v1_LoadBalanceRequest__fields[2] = {
-  {1, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 1, 11, 1},
-  {2, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 11, 1},
+  {1, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 1, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout grpc_lb_v1_LoadBalanceRequest_msginit = {
   &grpc_lb_v1_LoadBalanceRequest_submsgs[0],
   &grpc_lb_v1_LoadBalanceRequest__fields[0],
-  UPB_SIZE(8, 16), 2, false, 255,
+  UPB_SIZE(8, 16), 2, false, 2, 255,
 };
 
 static const upb_msglayout_field grpc_lb_v1_InitialLoadBalanceRequest__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout grpc_lb_v1_InitialLoadBalanceRequest_msginit = {
   NULL,
   &grpc_lb_v1_InitialLoadBalanceRequest__fields[0],
-  UPB_SIZE(8, 16), 1, false, 255,
+  UPB_SIZE(8, 16), 1, false, 1, 255,
 };
 
 static const upb_msglayout_field grpc_lb_v1_ClientStatsPerToken__fields[2] = {
-  {1, UPB_SIZE(8, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(0, 0), 0, 0, 3, 1},
+  {1, UPB_SIZE(8, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(0, 0), 0, 0, 3, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout grpc_lb_v1_ClientStatsPerToken_msginit = {
   NULL,
   &grpc_lb_v1_ClientStatsPerToken__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const grpc_lb_v1_ClientStats_submsgs[2] = {
@@ -57,18 +57,18 @@ static const upb_msglayout *const grpc_lb_v1_ClientStats_submsgs[2] = {
 };
 
 static const upb_msglayout_field grpc_lb_v1_ClientStats__fields[6] = {
-  {1, UPB_SIZE(40, 40), 1, 0, 11, 1},
-  {2, UPB_SIZE(8, 8), 0, 0, 3, 1},
-  {3, UPB_SIZE(16, 16), 0, 0, 3, 1},
-  {6, UPB_SIZE(24, 24), 0, 0, 3, 1},
-  {7, UPB_SIZE(32, 32), 0, 0, 3, 1},
-  {8, UPB_SIZE(44, 48), 0, 1, 11, 3},
+  {1, UPB_SIZE(40, 40), 1, 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 8), 0, 0, 3, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(16, 16), 0, 0, 3, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(24, 24), 0, 0, 3, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(32, 32), 0, 0, 3, _UPB_MODE_SCALAR},
+  {8, UPB_SIZE(44, 48), 0, 1, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout grpc_lb_v1_ClientStats_msginit = {
   &grpc_lb_v1_ClientStats_submsgs[0],
   &grpc_lb_v1_ClientStats__fields[0],
-  UPB_SIZE(48, 56), 6, false, 255,
+  UPB_SIZE(48, 56), 6, false, 3, 255,
 };
 
 static const upb_msglayout *const grpc_lb_v1_LoadBalanceResponse_submsgs[3] = {
@@ -78,15 +78,15 @@ static const upb_msglayout *const grpc_lb_v1_LoadBalanceResponse_submsgs[3] = {
 };
 
 static const upb_msglayout_field grpc_lb_v1_LoadBalanceResponse__fields[3] = {
-  {1, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 1, 11, 1},
-  {2, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 2, 11, 1},
-  {3, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 11, 1},
+  {1, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 1, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 2, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout grpc_lb_v1_LoadBalanceResponse_msginit = {
   &grpc_lb_v1_LoadBalanceResponse_submsgs[0],
   &grpc_lb_v1_LoadBalanceResponse__fields[0],
-  UPB_SIZE(8, 16), 3, false, 255,
+  UPB_SIZE(8, 16), 3, false, 3, 255,
 };
 
 static const upb_msglayout *const grpc_lb_v1_InitialLoadBalanceResponse_submsgs[1] = {
@@ -94,14 +94,14 @@ static const upb_msglayout *const grpc_lb_v1_InitialLoadBalanceResponse_submsgs[
 };
 
 static const upb_msglayout_field grpc_lb_v1_InitialLoadBalanceResponse__fields[2] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(12, 24), 1, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(12, 24), 1, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout grpc_lb_v1_InitialLoadBalanceResponse_msginit = {
   &grpc_lb_v1_InitialLoadBalanceResponse_submsgs[0],
   &grpc_lb_v1_InitialLoadBalanceResponse__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const grpc_lb_v1_ServerList_submsgs[1] = {
@@ -109,32 +109,32 @@ static const upb_msglayout *const grpc_lb_v1_ServerList_submsgs[1] = {
 };
 
 static const upb_msglayout_field grpc_lb_v1_ServerList__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 11, 3},
+  {1, UPB_SIZE(0, 0), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout grpc_lb_v1_ServerList_msginit = {
   &grpc_lb_v1_ServerList_submsgs[0],
   &grpc_lb_v1_ServerList__fields[0],
-  UPB_SIZE(8, 8), 1, false, 255,
+  UPB_SIZE(8, 8), 1, false, 1, 255,
 };
 
 static const upb_msglayout_field grpc_lb_v1_Server__fields[4] = {
-  {1, UPB_SIZE(8, 8), 0, 0, 12, 1},
-  {2, UPB_SIZE(0, 0), 0, 0, 5, 1},
-  {3, UPB_SIZE(16, 24), 0, 0, 9, 1},
-  {4, UPB_SIZE(4, 4), 0, 0, 8, 1},
+  {1, UPB_SIZE(8, 8), 0, 0, 12, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(0, 0), 0, 0, 5, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(16, 24), 0, 0, 9, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(4, 4), 0, 0, 8, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout grpc_lb_v1_Server_msginit = {
   NULL,
   &grpc_lb_v1_Server__fields[0],
-  UPB_SIZE(24, 48), 4, false, 255,
+  UPB_SIZE(24, 48), 4, false, 4, 255,
 };
 
 const upb_msglayout grpc_lb_v1_FallbackResponse_msginit = {
   NULL,
   NULL,
-  UPB_SIZE(0, 0), 0, false, 255,
+  UPB_SIZE(0, 0), 0, false, 0, 255,
 };
 
 #include "upb/port_undef.inc"
index c8c352c..6d19430 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef SRC_PROTO_GRPC_LB_V1_LOAD_BALANCER_PROTO_UPB_H_
 #define SRC_PROTO_GRPC_LB_V1_LOAD_BALANCER_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -61,13 +61,19 @@ UPB_INLINE grpc_lb_v1_LoadBalanceRequest *grpc_lb_v1_LoadBalanceRequest_new(upb_
 UPB_INLINE grpc_lb_v1_LoadBalanceRequest *grpc_lb_v1_LoadBalanceRequest_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   grpc_lb_v1_LoadBalanceRequest *ret = grpc_lb_v1_LoadBalanceRequest_new(arena);
-  return (ret && upb_decode(buf, size, ret, &grpc_lb_v1_LoadBalanceRequest_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &grpc_lb_v1_LoadBalanceRequest_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE grpc_lb_v1_LoadBalanceRequest *grpc_lb_v1_LoadBalanceRequest_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   grpc_lb_v1_LoadBalanceRequest *ret = grpc_lb_v1_LoadBalanceRequest_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &grpc_lb_v1_LoadBalanceRequest_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &grpc_lb_v1_LoadBalanceRequest_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *grpc_lb_v1_LoadBalanceRequest_serialize(const grpc_lb_v1_LoadBalanceRequest *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &grpc_lb_v1_LoadBalanceRequest_msginit, arena, len);
@@ -118,13 +124,19 @@ UPB_INLINE grpc_lb_v1_InitialLoadBalanceRequest *grpc_lb_v1_InitialLoadBalanceRe
 UPB_INLINE grpc_lb_v1_InitialLoadBalanceRequest *grpc_lb_v1_InitialLoadBalanceRequest_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   grpc_lb_v1_InitialLoadBalanceRequest *ret = grpc_lb_v1_InitialLoadBalanceRequest_new(arena);
-  return (ret && upb_decode(buf, size, ret, &grpc_lb_v1_InitialLoadBalanceRequest_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &grpc_lb_v1_InitialLoadBalanceRequest_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE grpc_lb_v1_InitialLoadBalanceRequest *grpc_lb_v1_InitialLoadBalanceRequest_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   grpc_lb_v1_InitialLoadBalanceRequest *ret = grpc_lb_v1_InitialLoadBalanceRequest_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &grpc_lb_v1_InitialLoadBalanceRequest_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &grpc_lb_v1_InitialLoadBalanceRequest_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *grpc_lb_v1_InitialLoadBalanceRequest_serialize(const grpc_lb_v1_InitialLoadBalanceRequest *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &grpc_lb_v1_InitialLoadBalanceRequest_msginit, arena, len);
@@ -144,13 +156,19 @@ UPB_INLINE grpc_lb_v1_ClientStatsPerToken *grpc_lb_v1_ClientStatsPerToken_new(up
 UPB_INLINE grpc_lb_v1_ClientStatsPerToken *grpc_lb_v1_ClientStatsPerToken_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   grpc_lb_v1_ClientStatsPerToken *ret = grpc_lb_v1_ClientStatsPerToken_new(arena);
-  return (ret && upb_decode(buf, size, ret, &grpc_lb_v1_ClientStatsPerToken_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &grpc_lb_v1_ClientStatsPerToken_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE grpc_lb_v1_ClientStatsPerToken *grpc_lb_v1_ClientStatsPerToken_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   grpc_lb_v1_ClientStatsPerToken *ret = grpc_lb_v1_ClientStatsPerToken_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &grpc_lb_v1_ClientStatsPerToken_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &grpc_lb_v1_ClientStatsPerToken_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *grpc_lb_v1_ClientStatsPerToken_serialize(const grpc_lb_v1_ClientStatsPerToken *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &grpc_lb_v1_ClientStatsPerToken_msginit, arena, len);
@@ -174,13 +192,19 @@ UPB_INLINE grpc_lb_v1_ClientStats *grpc_lb_v1_ClientStats_new(upb_arena *arena)
 UPB_INLINE grpc_lb_v1_ClientStats *grpc_lb_v1_ClientStats_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   grpc_lb_v1_ClientStats *ret = grpc_lb_v1_ClientStats_new(arena);
-  return (ret && upb_decode(buf, size, ret, &grpc_lb_v1_ClientStats_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &grpc_lb_v1_ClientStats_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE grpc_lb_v1_ClientStats *grpc_lb_v1_ClientStats_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   grpc_lb_v1_ClientStats *ret = grpc_lb_v1_ClientStats_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &grpc_lb_v1_ClientStats_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &grpc_lb_v1_ClientStats_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *grpc_lb_v1_ClientStats_serialize(const grpc_lb_v1_ClientStats *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &grpc_lb_v1_ClientStats_msginit, arena, len);
@@ -242,13 +266,19 @@ UPB_INLINE grpc_lb_v1_LoadBalanceResponse *grpc_lb_v1_LoadBalanceResponse_new(up
 UPB_INLINE grpc_lb_v1_LoadBalanceResponse *grpc_lb_v1_LoadBalanceResponse_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   grpc_lb_v1_LoadBalanceResponse *ret = grpc_lb_v1_LoadBalanceResponse_new(arena);
-  return (ret && upb_decode(buf, size, ret, &grpc_lb_v1_LoadBalanceResponse_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &grpc_lb_v1_LoadBalanceResponse_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE grpc_lb_v1_LoadBalanceResponse *grpc_lb_v1_LoadBalanceResponse_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   grpc_lb_v1_LoadBalanceResponse *ret = grpc_lb_v1_LoadBalanceResponse_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &grpc_lb_v1_LoadBalanceResponse_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &grpc_lb_v1_LoadBalanceResponse_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *grpc_lb_v1_LoadBalanceResponse_serialize(const grpc_lb_v1_LoadBalanceResponse *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &grpc_lb_v1_LoadBalanceResponse_msginit, arena, len);
@@ -314,13 +344,19 @@ UPB_INLINE grpc_lb_v1_InitialLoadBalanceResponse *grpc_lb_v1_InitialLoadBalanceR
 UPB_INLINE grpc_lb_v1_InitialLoadBalanceResponse *grpc_lb_v1_InitialLoadBalanceResponse_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   grpc_lb_v1_InitialLoadBalanceResponse *ret = grpc_lb_v1_InitialLoadBalanceResponse_new(arena);
-  return (ret && upb_decode(buf, size, ret, &grpc_lb_v1_InitialLoadBalanceResponse_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &grpc_lb_v1_InitialLoadBalanceResponse_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE grpc_lb_v1_InitialLoadBalanceResponse *grpc_lb_v1_InitialLoadBalanceResponse_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   grpc_lb_v1_InitialLoadBalanceResponse *ret = grpc_lb_v1_InitialLoadBalanceResponse_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &grpc_lb_v1_InitialLoadBalanceResponse_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &grpc_lb_v1_InitialLoadBalanceResponse_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *grpc_lb_v1_InitialLoadBalanceResponse_serialize(const grpc_lb_v1_InitialLoadBalanceResponse *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &grpc_lb_v1_InitialLoadBalanceResponse_msginit, arena, len);
@@ -355,13 +391,19 @@ UPB_INLINE grpc_lb_v1_ServerList *grpc_lb_v1_ServerList_new(upb_arena *arena) {
 UPB_INLINE grpc_lb_v1_ServerList *grpc_lb_v1_ServerList_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   grpc_lb_v1_ServerList *ret = grpc_lb_v1_ServerList_new(arena);
-  return (ret && upb_decode(buf, size, ret, &grpc_lb_v1_ServerList_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &grpc_lb_v1_ServerList_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE grpc_lb_v1_ServerList *grpc_lb_v1_ServerList_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   grpc_lb_v1_ServerList *ret = grpc_lb_v1_ServerList_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &grpc_lb_v1_ServerList_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &grpc_lb_v1_ServerList_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *grpc_lb_v1_ServerList_serialize(const grpc_lb_v1_ServerList *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &grpc_lb_v1_ServerList_msginit, arena, len);
@@ -392,13 +434,19 @@ UPB_INLINE grpc_lb_v1_Server *grpc_lb_v1_Server_new(upb_arena *arena) {
 UPB_INLINE grpc_lb_v1_Server *grpc_lb_v1_Server_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   grpc_lb_v1_Server *ret = grpc_lb_v1_Server_new(arena);
-  return (ret && upb_decode(buf, size, ret, &grpc_lb_v1_Server_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &grpc_lb_v1_Server_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE grpc_lb_v1_Server *grpc_lb_v1_Server_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   grpc_lb_v1_Server *ret = grpc_lb_v1_Server_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &grpc_lb_v1_Server_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &grpc_lb_v1_Server_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *grpc_lb_v1_Server_serialize(const grpc_lb_v1_Server *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &grpc_lb_v1_Server_msginit, arena, len);
@@ -430,13 +478,19 @@ UPB_INLINE grpc_lb_v1_FallbackResponse *grpc_lb_v1_FallbackResponse_new(upb_aren
 UPB_INLINE grpc_lb_v1_FallbackResponse *grpc_lb_v1_FallbackResponse_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   grpc_lb_v1_FallbackResponse *ret = grpc_lb_v1_FallbackResponse_new(arena);
-  return (ret && upb_decode(buf, size, ret, &grpc_lb_v1_FallbackResponse_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &grpc_lb_v1_FallbackResponse_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE grpc_lb_v1_FallbackResponse *grpc_lb_v1_FallbackResponse_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   grpc_lb_v1_FallbackResponse *ret = grpc_lb_v1_FallbackResponse_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &grpc_lb_v1_FallbackResponse_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &grpc_lb_v1_FallbackResponse_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *grpc_lb_v1_FallbackResponse_serialize(const grpc_lb_v1_FallbackResponse *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &grpc_lb_v1_FallbackResponse_msginit, arena, len);
index a4d95cc..41f38d3 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "third_party/istio/security/proto/providers/google/meshca.upb.h"
 #include "google/protobuf/duration.upb.h"
 
@@ -18,25 +18,25 @@ static const upb_msglayout *const google_security_meshca_v1_MeshCertificateReque
 };
 
 static const upb_msglayout_field google_security_meshca_v1_MeshCertificateRequest__fields[3] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(12, 24), 0, 0, 9, 1},
-  {3, UPB_SIZE(20, 40), 1, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(12, 24), 0, 0, 9, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(20, 40), 1, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_security_meshca_v1_MeshCertificateRequest_msginit = {
   &google_security_meshca_v1_MeshCertificateRequest_submsgs[0],
   &google_security_meshca_v1_MeshCertificateRequest__fields[0],
-  UPB_SIZE(24, 48), 3, false, 255,
+  UPB_SIZE(24, 48), 3, false, 3, 255,
 };
 
 static const upb_msglayout_field google_security_meshca_v1_MeshCertificateResponse__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 3},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout google_security_meshca_v1_MeshCertificateResponse_msginit = {
   NULL,
   &google_security_meshca_v1_MeshCertificateResponse__fields[0],
-  UPB_SIZE(8, 8), 1, false, 255,
+  UPB_SIZE(8, 8), 1, false, 1, 255,
 };
 
 #include "upb/port_undef.inc"
index f301a02..1c1da22 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef THIRD_PARTY_ISTIO_SECURITY_PROTO_PROVIDERS_GOOGLE_MESHCA_PROTO_UPB_H_
 #define THIRD_PARTY_ISTIO_SECURITY_PROTO_PROVIDERS_GOOGLE_MESHCA_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -38,13 +38,19 @@ UPB_INLINE google_security_meshca_v1_MeshCertificateRequest *google_security_mes
 UPB_INLINE google_security_meshca_v1_MeshCertificateRequest *google_security_meshca_v1_MeshCertificateRequest_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_security_meshca_v1_MeshCertificateRequest *ret = google_security_meshca_v1_MeshCertificateRequest_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_security_meshca_v1_MeshCertificateRequest_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_security_meshca_v1_MeshCertificateRequest_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_security_meshca_v1_MeshCertificateRequest *google_security_meshca_v1_MeshCertificateRequest_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_security_meshca_v1_MeshCertificateRequest *ret = google_security_meshca_v1_MeshCertificateRequest_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_security_meshca_v1_MeshCertificateRequest_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_security_meshca_v1_MeshCertificateRequest_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_security_meshca_v1_MeshCertificateRequest_serialize(const google_security_meshca_v1_MeshCertificateRequest *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_security_meshca_v1_MeshCertificateRequest_msginit, arena, len);
@@ -83,13 +89,19 @@ UPB_INLINE google_security_meshca_v1_MeshCertificateResponse *google_security_me
 UPB_INLINE google_security_meshca_v1_MeshCertificateResponse *google_security_meshca_v1_MeshCertificateResponse_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_security_meshca_v1_MeshCertificateResponse *ret = google_security_meshca_v1_MeshCertificateResponse_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_security_meshca_v1_MeshCertificateResponse_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_security_meshca_v1_MeshCertificateResponse_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_security_meshca_v1_MeshCertificateResponse *google_security_meshca_v1_MeshCertificateResponse_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_security_meshca_v1_MeshCertificateResponse *ret = google_security_meshca_v1_MeshCertificateResponse_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_security_meshca_v1_MeshCertificateResponse_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_security_meshca_v1_MeshCertificateResponse_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_security_meshca_v1_MeshCertificateResponse_serialize(const google_security_meshca_v1_MeshCertificateResponse *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_security_meshca_v1_MeshCertificateResponse_msginit, arena, len);
index 5f5f1ed..b398162 100644 (file)
@@ -7,41 +7,41 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "udpa/annotations/migrate.upb.h"
 #include "google/protobuf/descriptor.upb.h"
 
 #include "upb/port_def.inc"
 
 static const upb_msglayout_field udpa_annotations_MigrateAnnotation__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout udpa_annotations_MigrateAnnotation_msginit = {
   NULL,
   &udpa_annotations_MigrateAnnotation__fields[0],
-  UPB_SIZE(8, 16), 1, false, 255,
+  UPB_SIZE(8, 16), 1, false, 1, 255,
 };
 
 static const upb_msglayout_field udpa_annotations_FieldMigrateAnnotation__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {2, UPB_SIZE(8, 16), 0, 0, 9, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 0, 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout udpa_annotations_FieldMigrateAnnotation_msginit = {
   NULL,
   &udpa_annotations_FieldMigrateAnnotation__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout_field udpa_annotations_FileMigrateAnnotation__fields[1] = {
-  {2, UPB_SIZE(0, 0), 0, 0, 9, 1},
+  {2, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout udpa_annotations_FileMigrateAnnotation_msginit = {
   NULL,
   &udpa_annotations_FileMigrateAnnotation__fields[0],
-  UPB_SIZE(8, 16), 1, false, 255,
+  UPB_SIZE(8, 16), 1, false, 0, 255,
 };
 
 #include "upb/port_undef.inc"
index 8d55a77..1efb8c5 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef UDPA_ANNOTATIONS_MIGRATE_PROTO_UPB_H_
 #define UDPA_ANNOTATIONS_MIGRATE_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -39,13 +39,19 @@ UPB_INLINE udpa_annotations_MigrateAnnotation *udpa_annotations_MigrateAnnotatio
 UPB_INLINE udpa_annotations_MigrateAnnotation *udpa_annotations_MigrateAnnotation_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   udpa_annotations_MigrateAnnotation *ret = udpa_annotations_MigrateAnnotation_new(arena);
-  return (ret && upb_decode(buf, size, ret, &udpa_annotations_MigrateAnnotation_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &udpa_annotations_MigrateAnnotation_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE udpa_annotations_MigrateAnnotation *udpa_annotations_MigrateAnnotation_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   udpa_annotations_MigrateAnnotation *ret = udpa_annotations_MigrateAnnotation_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &udpa_annotations_MigrateAnnotation_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &udpa_annotations_MigrateAnnotation_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *udpa_annotations_MigrateAnnotation_serialize(const udpa_annotations_MigrateAnnotation *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &udpa_annotations_MigrateAnnotation_msginit, arena, len);
@@ -65,13 +71,19 @@ UPB_INLINE udpa_annotations_FieldMigrateAnnotation *udpa_annotations_FieldMigrat
 UPB_INLINE udpa_annotations_FieldMigrateAnnotation *udpa_annotations_FieldMigrateAnnotation_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   udpa_annotations_FieldMigrateAnnotation *ret = udpa_annotations_FieldMigrateAnnotation_new(arena);
-  return (ret && upb_decode(buf, size, ret, &udpa_annotations_FieldMigrateAnnotation_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &udpa_annotations_FieldMigrateAnnotation_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE udpa_annotations_FieldMigrateAnnotation *udpa_annotations_FieldMigrateAnnotation_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   udpa_annotations_FieldMigrateAnnotation *ret = udpa_annotations_FieldMigrateAnnotation_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &udpa_annotations_FieldMigrateAnnotation_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &udpa_annotations_FieldMigrateAnnotation_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *udpa_annotations_FieldMigrateAnnotation_serialize(const udpa_annotations_FieldMigrateAnnotation *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &udpa_annotations_FieldMigrateAnnotation_msginit, arena, len);
@@ -95,13 +107,19 @@ UPB_INLINE udpa_annotations_FileMigrateAnnotation *udpa_annotations_FileMigrateA
 UPB_INLINE udpa_annotations_FileMigrateAnnotation *udpa_annotations_FileMigrateAnnotation_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   udpa_annotations_FileMigrateAnnotation *ret = udpa_annotations_FileMigrateAnnotation_new(arena);
-  return (ret && upb_decode(buf, size, ret, &udpa_annotations_FileMigrateAnnotation_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &udpa_annotations_FileMigrateAnnotation_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE udpa_annotations_FileMigrateAnnotation *udpa_annotations_FileMigrateAnnotation_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   udpa_annotations_FileMigrateAnnotation *ret = udpa_annotations_FileMigrateAnnotation_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &udpa_annotations_FileMigrateAnnotation_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &udpa_annotations_FileMigrateAnnotation_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *udpa_annotations_FileMigrateAnnotation_serialize(const udpa_annotations_FileMigrateAnnotation *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &udpa_annotations_FileMigrateAnnotation_msginit, arena, len);
index d135d4f..732903d 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "udpa/annotations/security.upb.h"
 #include "udpa/annotations/status.upb.h"
 #include "google/protobuf/any.upb.h"
 #include "upb/port_def.inc"
 
 static const upb_msglayout_field udpa_annotations_FieldSecurityAnnotation__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 8, 1},
-  {2, UPB_SIZE(1, 1), 0, 0, 8, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 8, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(1, 1), 0, 0, 8, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout udpa_annotations_FieldSecurityAnnotation_msginit = {
   NULL,
   &udpa_annotations_FieldSecurityAnnotation__fields[0],
-  UPB_SIZE(8, 8), 2, false, 255,
+  UPB_SIZE(8, 8), 2, false, 2, 255,
 };
 
 #include "upb/port_undef.inc"
index 415ba04..1ce4b82 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef UDPA_ANNOTATIONS_SECURITY_PROTO_UPB_H_
 #define UDPA_ANNOTATIONS_SECURITY_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -33,13 +33,19 @@ UPB_INLINE udpa_annotations_FieldSecurityAnnotation *udpa_annotations_FieldSecur
 UPB_INLINE udpa_annotations_FieldSecurityAnnotation *udpa_annotations_FieldSecurityAnnotation_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   udpa_annotations_FieldSecurityAnnotation *ret = udpa_annotations_FieldSecurityAnnotation_new(arena);
-  return (ret && upb_decode(buf, size, ret, &udpa_annotations_FieldSecurityAnnotation_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &udpa_annotations_FieldSecurityAnnotation_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE udpa_annotations_FieldSecurityAnnotation *udpa_annotations_FieldSecurityAnnotation_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   udpa_annotations_FieldSecurityAnnotation *ret = udpa_annotations_FieldSecurityAnnotation_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &udpa_annotations_FieldSecurityAnnotation_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &udpa_annotations_FieldSecurityAnnotation_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *udpa_annotations_FieldSecurityAnnotation_serialize(const udpa_annotations_FieldSecurityAnnotation *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &udpa_annotations_FieldSecurityAnnotation_msginit, arena, len);
index ca1fcb5..f9bd0f2 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "udpa/annotations/sensitive.upb.h"
 #include "google/protobuf/descriptor.upb.h"
 
index 69f2a86..bbfd4e9 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef UDPA_ANNOTATIONS_SENSITIVE_PROTO_UPB_H_
 #define UDPA_ANNOTATIONS_SENSITIVE_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
index 16b0181..7d41360 100644 (file)
@@ -7,21 +7,21 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "udpa/annotations/status.upb.h"
 #include "google/protobuf/descriptor.upb.h"
 
 #include "upb/port_def.inc"
 
 static const upb_msglayout_field udpa_annotations_StatusAnnotation__fields[2] = {
-  {1, UPB_SIZE(4, 4), 0, 0, 8, 1},
-  {2, UPB_SIZE(0, 0), 0, 0, 14, 1},
+  {1, UPB_SIZE(4, 4), 0, 0, 8, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(0, 0), 0, 0, 14, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout udpa_annotations_StatusAnnotation_msginit = {
   NULL,
   &udpa_annotations_StatusAnnotation__fields[0],
-  UPB_SIZE(8, 8), 2, false, 255,
+  UPB_SIZE(8, 8), 2, false, 2, 255,
 };
 
 #include "upb/port_undef.inc"
index a55570d..cef5cc5 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef UDPA_ANNOTATIONS_STATUS_PROTO_UPB_H_
 #define UDPA_ANNOTATIONS_STATUS_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -40,13 +40,19 @@ UPB_INLINE udpa_annotations_StatusAnnotation *udpa_annotations_StatusAnnotation_
 UPB_INLINE udpa_annotations_StatusAnnotation *udpa_annotations_StatusAnnotation_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   udpa_annotations_StatusAnnotation *ret = udpa_annotations_StatusAnnotation_new(arena);
-  return (ret && upb_decode(buf, size, ret, &udpa_annotations_StatusAnnotation_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &udpa_annotations_StatusAnnotation_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE udpa_annotations_StatusAnnotation *udpa_annotations_StatusAnnotation_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   udpa_annotations_StatusAnnotation *ret = udpa_annotations_StatusAnnotation_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &udpa_annotations_StatusAnnotation_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &udpa_annotations_StatusAnnotation_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *udpa_annotations_StatusAnnotation_serialize(const udpa_annotations_StatusAnnotation *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &udpa_annotations_StatusAnnotation_msginit, arena, len);
index 253afc8..daf3a8a 100644 (file)
@@ -7,20 +7,20 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "udpa/annotations/versioning.upb.h"
 #include "google/protobuf/descriptor.upb.h"
 
 #include "upb/port_def.inc"
 
 static const upb_msglayout_field udpa_annotations_VersioningAnnotation__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout udpa_annotations_VersioningAnnotation_msginit = {
   NULL,
   &udpa_annotations_VersioningAnnotation__fields[0],
-  UPB_SIZE(8, 16), 1, false, 255,
+  UPB_SIZE(8, 16), 1, false, 1, 255,
 };
 
 #include "upb/port_undef.inc"
index e39f8c3..9a37aed 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef UDPA_ANNOTATIONS_VERSIONING_PROTO_UPB_H_
 #define UDPA_ANNOTATIONS_VERSIONING_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -33,13 +33,19 @@ UPB_INLINE udpa_annotations_VersioningAnnotation *udpa_annotations_VersioningAnn
 UPB_INLINE udpa_annotations_VersioningAnnotation *udpa_annotations_VersioningAnnotation_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   udpa_annotations_VersioningAnnotation *ret = udpa_annotations_VersioningAnnotation_new(arena);
-  return (ret && upb_decode(buf, size, ret, &udpa_annotations_VersioningAnnotation_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &udpa_annotations_VersioningAnnotation_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE udpa_annotations_VersioningAnnotation *udpa_annotations_VersioningAnnotation_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   udpa_annotations_VersioningAnnotation *ret = udpa_annotations_VersioningAnnotation_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &udpa_annotations_VersioningAnnotation_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &udpa_annotations_VersioningAnnotation_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *udpa_annotations_VersioningAnnotation_serialize(const udpa_annotations_VersioningAnnotation *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &udpa_annotations_VersioningAnnotation_msginit, arena, len);
index e5069b7..38feb7b 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "udpa/data/orca/v1/orca_load_report.upb.h"
 #include "validate/validate.upb.h"
 
@@ -19,39 +19,39 @@ static const upb_msglayout *const udpa_data_orca_v1_OrcaLoadReport_submsgs[2] =
 };
 
 static const upb_msglayout_field udpa_data_orca_v1_OrcaLoadReport__fields[5] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 1, 1},
-  {2, UPB_SIZE(8, 8), 0, 0, 1, 1},
-  {3, UPB_SIZE(16, 16), 0, 0, 4, 1},
-  {4, UPB_SIZE(24, 24), 0, 0, 11, _UPB_LABEL_MAP},
-  {5, UPB_SIZE(28, 32), 0, 1, 11, _UPB_LABEL_MAP},
+  {1, UPB_SIZE(0, 0), 0, 0, 1, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 8), 0, 0, 1, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(16, 16), 0, 0, 4, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(24, 24), 0, 0, 11, _UPB_MODE_MAP},
+  {5, UPB_SIZE(28, 32), 0, 1, 11, _UPB_MODE_MAP},
 };
 
 const upb_msglayout udpa_data_orca_v1_OrcaLoadReport_msginit = {
   &udpa_data_orca_v1_OrcaLoadReport_submsgs[0],
   &udpa_data_orca_v1_OrcaLoadReport__fields[0],
-  UPB_SIZE(32, 40), 5, false, 255,
+  UPB_SIZE(32, 40), 5, false, 5, 255,
 };
 
 static const upb_msglayout_field udpa_data_orca_v1_OrcaLoadReport_RequestCostEntry__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {2, UPB_SIZE(8, 16), 0, 0, 1, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 0, 0, 1, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout udpa_data_orca_v1_OrcaLoadReport_RequestCostEntry_msginit = {
   NULL,
   &udpa_data_orca_v1_OrcaLoadReport_RequestCostEntry__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout_field udpa_data_orca_v1_OrcaLoadReport_UtilizationEntry__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {2, UPB_SIZE(8, 16), 0, 0, 1, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 0, 0, 1, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout udpa_data_orca_v1_OrcaLoadReport_UtilizationEntry_msginit = {
   NULL,
   &udpa_data_orca_v1_OrcaLoadReport_UtilizationEntry__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 #include "upb/port_undef.inc"
index e5923cc..dbefd80 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef UDPA_DATA_ORCA_V1_ORCA_LOAD_REPORT_PROTO_UPB_H_
 #define UDPA_DATA_ORCA_V1_ORCA_LOAD_REPORT_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -39,13 +39,19 @@ UPB_INLINE udpa_data_orca_v1_OrcaLoadReport *udpa_data_orca_v1_OrcaLoadReport_ne
 UPB_INLINE udpa_data_orca_v1_OrcaLoadReport *udpa_data_orca_v1_OrcaLoadReport_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   udpa_data_orca_v1_OrcaLoadReport *ret = udpa_data_orca_v1_OrcaLoadReport_new(arena);
-  return (ret && upb_decode(buf, size, ret, &udpa_data_orca_v1_OrcaLoadReport_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &udpa_data_orca_v1_OrcaLoadReport_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE udpa_data_orca_v1_OrcaLoadReport *udpa_data_orca_v1_OrcaLoadReport_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   udpa_data_orca_v1_OrcaLoadReport *ret = udpa_data_orca_v1_OrcaLoadReport_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &udpa_data_orca_v1_OrcaLoadReport_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &udpa_data_orca_v1_OrcaLoadReport_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *udpa_data_orca_v1_OrcaLoadReport_serialize(const udpa_data_orca_v1_OrcaLoadReport *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &udpa_data_orca_v1_OrcaLoadReport_msginit, arena, len);
index 24407fa..347fb1e 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "udpa/type/v1/typed_struct.upb.h"
 #include "validate/validate.upb.h"
 #include "google/protobuf/struct.upb.h"
@@ -19,14 +19,14 @@ static const upb_msglayout *const udpa_type_v1_TypedStruct_submsgs[1] = {
 };
 
 static const upb_msglayout_field udpa_type_v1_TypedStruct__fields[2] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(12, 24), 1, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(12, 24), 1, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout udpa_type_v1_TypedStruct_msginit = {
   &udpa_type_v1_TypedStruct_submsgs[0],
   &udpa_type_v1_TypedStruct__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 #include "upb/port_undef.inc"
index 2dd03ff..431413c 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef UDPA_TYPE_V1_TYPED_STRUCT_PROTO_UPB_H_
 #define UDPA_TYPE_V1_TYPED_STRUCT_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -35,13 +35,19 @@ UPB_INLINE udpa_type_v1_TypedStruct *udpa_type_v1_TypedStruct_new(upb_arena *are
 UPB_INLINE udpa_type_v1_TypedStruct *udpa_type_v1_TypedStruct_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   udpa_type_v1_TypedStruct *ret = udpa_type_v1_TypedStruct_new(arena);
-  return (ret && upb_decode(buf, size, ret, &udpa_type_v1_TypedStruct_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &udpa_type_v1_TypedStruct_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE udpa_type_v1_TypedStruct *udpa_type_v1_TypedStruct_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   udpa_type_v1_TypedStruct *ret = udpa_type_v1_TypedStruct_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &udpa_type_v1_TypedStruct_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &udpa_type_v1_TypedStruct_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *udpa_type_v1_TypedStruct_serialize(const udpa_type_v1_TypedStruct *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &udpa_type_v1_TypedStruct_msginit, arena, len);
index f210e3c..f25077b 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "validate/validate.upb.h"
 #include "google/protobuf/descriptor.upb.h"
 #include "google/protobuf/duration.upb.h"
@@ -41,330 +41,330 @@ static const upb_msglayout *const validate_FieldRules_submsgs[22] = {
 };
 
 static const upb_msglayout_field validate_FieldRules__fields[22] = {
-  {1, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 8, 11, 1},
-  {2, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 3, 11, 1},
-  {3, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 9, 11, 1},
-  {4, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 10, 11, 1},
-  {5, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 20, 11, 1},
-  {6, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 21, 11, 1},
-  {7, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 16, 11, 1},
-  {8, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 17, 11, 1},
-  {9, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 6, 11, 1},
-  {10, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 7, 11, 1},
-  {11, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 14, 11, 1},
-  {12, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 15, 11, 1},
-  {13, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 1, 11, 1},
-  {14, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 18, 11, 1},
-  {15, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 2, 11, 1},
-  {16, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 5, 11, 1},
-  {17, UPB_SIZE(4, 8), 1, 12, 11, 1},
-  {18, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 13, 11, 1},
-  {19, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 11, 11, 1},
-  {20, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 0, 11, 1},
-  {21, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 4, 11, 1},
-  {22, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 19, 11, 1},
+  {1, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 8, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 3, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 9, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 10, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 20, 11, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 21, 11, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 16, 11, _UPB_MODE_SCALAR},
+  {8, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 17, 11, _UPB_MODE_SCALAR},
+  {9, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 6, 11, _UPB_MODE_SCALAR},
+  {10, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 7, 11, _UPB_MODE_SCALAR},
+  {11, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 14, 11, _UPB_MODE_SCALAR},
+  {12, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 15, 11, _UPB_MODE_SCALAR},
+  {13, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 1, 11, _UPB_MODE_SCALAR},
+  {14, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 18, 11, _UPB_MODE_SCALAR},
+  {15, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 2, 11, _UPB_MODE_SCALAR},
+  {16, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 5, 11, _UPB_MODE_SCALAR},
+  {17, UPB_SIZE(4, 8), 1, 12, 11, _UPB_MODE_SCALAR},
+  {18, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 13, 11, _UPB_MODE_SCALAR},
+  {19, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 11, 11, _UPB_MODE_SCALAR},
+  {20, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 0, 11, _UPB_MODE_SCALAR},
+  {21, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 4, 11, _UPB_MODE_SCALAR},
+  {22, UPB_SIZE(8, 16), UPB_SIZE(-13, -25), 19, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout validate_FieldRules_msginit = {
   &validate_FieldRules_submsgs[0],
   &validate_FieldRules__fields[0],
-  UPB_SIZE(16, 32), 22, false, 255,
+  UPB_SIZE(16, 32), 22, false, 22, 255,
 };
 
 static const upb_msglayout_field validate_FloatRules__fields[8] = {
-  {1, UPB_SIZE(4, 4), 1, 0, 2, 1},
-  {2, UPB_SIZE(8, 8), 2, 0, 2, 1},
-  {3, UPB_SIZE(12, 12), 3, 0, 2, 1},
-  {4, UPB_SIZE(16, 16), 4, 0, 2, 1},
-  {5, UPB_SIZE(20, 20), 5, 0, 2, 1},
-  {6, UPB_SIZE(28, 32), 0, 0, 2, 3},
-  {7, UPB_SIZE(32, 40), 0, 0, 2, 3},
-  {8, UPB_SIZE(24, 24), 6, 0, 8, 1},
+  {1, UPB_SIZE(4, 4), 1, 0, 2, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 8), 2, 0, 2, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(12, 12), 3, 0, 2, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(16, 16), 4, 0, 2, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(20, 20), 5, 0, 2, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(28, 32), 0, 0, 2, _UPB_MODE_ARRAY},
+  {7, UPB_SIZE(32, 40), 0, 0, 2, _UPB_MODE_ARRAY},
+  {8, UPB_SIZE(24, 24), 6, 0, 8, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout validate_FloatRules_msginit = {
   NULL,
   &validate_FloatRules__fields[0],
-  UPB_SIZE(40, 48), 8, false, 255,
+  UPB_SIZE(40, 48), 8, false, 8, 255,
 };
 
 static const upb_msglayout_field validate_DoubleRules__fields[8] = {
-  {1, UPB_SIZE(8, 8), 1, 0, 1, 1},
-  {2, UPB_SIZE(16, 16), 2, 0, 1, 1},
-  {3, UPB_SIZE(24, 24), 3, 0, 1, 1},
-  {4, UPB_SIZE(32, 32), 4, 0, 1, 1},
-  {5, UPB_SIZE(40, 40), 5, 0, 1, 1},
-  {6, UPB_SIZE(52, 56), 0, 0, 1, 3},
-  {7, UPB_SIZE(56, 64), 0, 0, 1, 3},
-  {8, UPB_SIZE(48, 48), 6, 0, 8, 1},
+  {1, UPB_SIZE(8, 8), 1, 0, 1, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(16, 16), 2, 0, 1, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(24, 24), 3, 0, 1, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(32, 32), 4, 0, 1, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(40, 40), 5, 0, 1, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(52, 56), 0, 0, 1, _UPB_MODE_ARRAY},
+  {7, UPB_SIZE(56, 64), 0, 0, 1, _UPB_MODE_ARRAY},
+  {8, UPB_SIZE(48, 48), 6, 0, 8, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout validate_DoubleRules_msginit = {
   NULL,
   &validate_DoubleRules__fields[0],
-  UPB_SIZE(64, 72), 8, false, 255,
+  UPB_SIZE(64, 72), 8, false, 8, 255,
 };
 
 static const upb_msglayout_field validate_Int32Rules__fields[8] = {
-  {1, UPB_SIZE(4, 4), 1, 0, 5, 1},
-  {2, UPB_SIZE(8, 8), 2, 0, 5, 1},
-  {3, UPB_SIZE(12, 12), 3, 0, 5, 1},
-  {4, UPB_SIZE(16, 16), 4, 0, 5, 1},
-  {5, UPB_SIZE(20, 20), 5, 0, 5, 1},
-  {6, UPB_SIZE(28, 32), 0, 0, 5, 3},
-  {7, UPB_SIZE(32, 40), 0, 0, 5, 3},
-  {8, UPB_SIZE(24, 24), 6, 0, 8, 1},
+  {1, UPB_SIZE(4, 4), 1, 0, 5, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 8), 2, 0, 5, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(12, 12), 3, 0, 5, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(16, 16), 4, 0, 5, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(20, 20), 5, 0, 5, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(28, 32), 0, 0, 5, _UPB_MODE_ARRAY},
+  {7, UPB_SIZE(32, 40), 0, 0, 5, _UPB_MODE_ARRAY},
+  {8, UPB_SIZE(24, 24), 6, 0, 8, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout validate_Int32Rules_msginit = {
   NULL,
   &validate_Int32Rules__fields[0],
-  UPB_SIZE(40, 48), 8, false, 255,
+  UPB_SIZE(40, 48), 8, false, 8, 255,
 };
 
 static const upb_msglayout_field validate_Int64Rules__fields[8] = {
-  {1, UPB_SIZE(8, 8), 1, 0, 3, 1},
-  {2, UPB_SIZE(16, 16), 2, 0, 3, 1},
-  {3, UPB_SIZE(24, 24), 3, 0, 3, 1},
-  {4, UPB_SIZE(32, 32), 4, 0, 3, 1},
-  {5, UPB_SIZE(40, 40), 5, 0, 3, 1},
-  {6, UPB_SIZE(52, 56), 0, 0, 3, 3},
-  {7, UPB_SIZE(56, 64), 0, 0, 3, 3},
-  {8, UPB_SIZE(48, 48), 6, 0, 8, 1},
+  {1, UPB_SIZE(8, 8), 1, 0, 3, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(16, 16), 2, 0, 3, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(24, 24), 3, 0, 3, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(32, 32), 4, 0, 3, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(40, 40), 5, 0, 3, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(52, 56), 0, 0, 3, _UPB_MODE_ARRAY},
+  {7, UPB_SIZE(56, 64), 0, 0, 3, _UPB_MODE_ARRAY},
+  {8, UPB_SIZE(48, 48), 6, 0, 8, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout validate_Int64Rules_msginit = {
   NULL,
   &validate_Int64Rules__fields[0],
-  UPB_SIZE(64, 72), 8, false, 255,
+  UPB_SIZE(64, 72), 8, false, 8, 255,
 };
 
 static const upb_msglayout_field validate_UInt32Rules__fields[8] = {
-  {1, UPB_SIZE(4, 4), 1, 0, 13, 1},
-  {2, UPB_SIZE(8, 8), 2, 0, 13, 1},
-  {3, UPB_SIZE(12, 12), 3, 0, 13, 1},
-  {4, UPB_SIZE(16, 16), 4, 0, 13, 1},
-  {5, UPB_SIZE(20, 20), 5, 0, 13, 1},
-  {6, UPB_SIZE(28, 32), 0, 0, 13, 3},
-  {7, UPB_SIZE(32, 40), 0, 0, 13, 3},
-  {8, UPB_SIZE(24, 24), 6, 0, 8, 1},
+  {1, UPB_SIZE(4, 4), 1, 0, 13, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 8), 2, 0, 13, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(12, 12), 3, 0, 13, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(16, 16), 4, 0, 13, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(20, 20), 5, 0, 13, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(28, 32), 0, 0, 13, _UPB_MODE_ARRAY},
+  {7, UPB_SIZE(32, 40), 0, 0, 13, _UPB_MODE_ARRAY},
+  {8, UPB_SIZE(24, 24), 6, 0, 8, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout validate_UInt32Rules_msginit = {
   NULL,
   &validate_UInt32Rules__fields[0],
-  UPB_SIZE(40, 48), 8, false, 255,
+  UPB_SIZE(40, 48), 8, false, 8, 255,
 };
 
 static const upb_msglayout_field validate_UInt64Rules__fields[8] = {
-  {1, UPB_SIZE(8, 8), 1, 0, 4, 1},
-  {2, UPB_SIZE(16, 16), 2, 0, 4, 1},
-  {3, UPB_SIZE(24, 24), 3, 0, 4, 1},
-  {4, UPB_SIZE(32, 32), 4, 0, 4, 1},
-  {5, UPB_SIZE(40, 40), 5, 0, 4, 1},
-  {6, UPB_SIZE(52, 56), 0, 0, 4, 3},
-  {7, UPB_SIZE(56, 64), 0, 0, 4, 3},
-  {8, UPB_SIZE(48, 48), 6, 0, 8, 1},
+  {1, UPB_SIZE(8, 8), 1, 0, 4, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(16, 16), 2, 0, 4, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(24, 24), 3, 0, 4, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(32, 32), 4, 0, 4, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(40, 40), 5, 0, 4, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(52, 56), 0, 0, 4, _UPB_MODE_ARRAY},
+  {7, UPB_SIZE(56, 64), 0, 0, 4, _UPB_MODE_ARRAY},
+  {8, UPB_SIZE(48, 48), 6, 0, 8, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout validate_UInt64Rules_msginit = {
   NULL,
   &validate_UInt64Rules__fields[0],
-  UPB_SIZE(64, 72), 8, false, 255,
+  UPB_SIZE(64, 72), 8, false, 8, 255,
 };
 
 static const upb_msglayout_field validate_SInt32Rules__fields[8] = {
-  {1, UPB_SIZE(4, 4), 1, 0, 17, 1},
-  {2, UPB_SIZE(8, 8), 2, 0, 17, 1},
-  {3, UPB_SIZE(12, 12), 3, 0, 17, 1},
-  {4, UPB_SIZE(16, 16), 4, 0, 17, 1},
-  {5, UPB_SIZE(20, 20), 5, 0, 17, 1},
-  {6, UPB_SIZE(28, 32), 0, 0, 17, 3},
-  {7, UPB_SIZE(32, 40), 0, 0, 17, 3},
-  {8, UPB_SIZE(24, 24), 6, 0, 8, 1},
+  {1, UPB_SIZE(4, 4), 1, 0, 17, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 8), 2, 0, 17, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(12, 12), 3, 0, 17, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(16, 16), 4, 0, 17, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(20, 20), 5, 0, 17, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(28, 32), 0, 0, 17, _UPB_MODE_ARRAY},
+  {7, UPB_SIZE(32, 40), 0, 0, 17, _UPB_MODE_ARRAY},
+  {8, UPB_SIZE(24, 24), 6, 0, 8, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout validate_SInt32Rules_msginit = {
   NULL,
   &validate_SInt32Rules__fields[0],
-  UPB_SIZE(40, 48), 8, false, 255,
+  UPB_SIZE(40, 48), 8, false, 8, 255,
 };
 
 static const upb_msglayout_field validate_SInt64Rules__fields[8] = {
-  {1, UPB_SIZE(8, 8), 1, 0, 18, 1},
-  {2, UPB_SIZE(16, 16), 2, 0, 18, 1},
-  {3, UPB_SIZE(24, 24), 3, 0, 18, 1},
-  {4, UPB_SIZE(32, 32), 4, 0, 18, 1},
-  {5, UPB_SIZE(40, 40), 5, 0, 18, 1},
-  {6, UPB_SIZE(52, 56), 0, 0, 18, 3},
-  {7, UPB_SIZE(56, 64), 0, 0, 18, 3},
-  {8, UPB_SIZE(48, 48), 6, 0, 8, 1},
+  {1, UPB_SIZE(8, 8), 1, 0, 18, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(16, 16), 2, 0, 18, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(24, 24), 3, 0, 18, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(32, 32), 4, 0, 18, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(40, 40), 5, 0, 18, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(52, 56), 0, 0, 18, _UPB_MODE_ARRAY},
+  {7, UPB_SIZE(56, 64), 0, 0, 18, _UPB_MODE_ARRAY},
+  {8, UPB_SIZE(48, 48), 6, 0, 8, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout validate_SInt64Rules_msginit = {
   NULL,
   &validate_SInt64Rules__fields[0],
-  UPB_SIZE(64, 72), 8, false, 255,
+  UPB_SIZE(64, 72), 8, false, 8, 255,
 };
 
 static const upb_msglayout_field validate_Fixed32Rules__fields[8] = {
-  {1, UPB_SIZE(4, 4), 1, 0, 7, 1},
-  {2, UPB_SIZE(8, 8), 2, 0, 7, 1},
-  {3, UPB_SIZE(12, 12), 3, 0, 7, 1},
-  {4, UPB_SIZE(16, 16), 4, 0, 7, 1},
-  {5, UPB_SIZE(20, 20), 5, 0, 7, 1},
-  {6, UPB_SIZE(28, 32), 0, 0, 7, 3},
-  {7, UPB_SIZE(32, 40), 0, 0, 7, 3},
-  {8, UPB_SIZE(24, 24), 6, 0, 8, 1},
+  {1, UPB_SIZE(4, 4), 1, 0, 7, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 8), 2, 0, 7, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(12, 12), 3, 0, 7, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(16, 16), 4, 0, 7, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(20, 20), 5, 0, 7, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(28, 32), 0, 0, 7, _UPB_MODE_ARRAY},
+  {7, UPB_SIZE(32, 40), 0, 0, 7, _UPB_MODE_ARRAY},
+  {8, UPB_SIZE(24, 24), 6, 0, 8, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout validate_Fixed32Rules_msginit = {
   NULL,
   &validate_Fixed32Rules__fields[0],
-  UPB_SIZE(40, 48), 8, false, 255,
+  UPB_SIZE(40, 48), 8, false, 8, 255,
 };
 
 static const upb_msglayout_field validate_Fixed64Rules__fields[8] = {
-  {1, UPB_SIZE(8, 8), 1, 0, 6, 1},
-  {2, UPB_SIZE(16, 16), 2, 0, 6, 1},
-  {3, UPB_SIZE(24, 24), 3, 0, 6, 1},
-  {4, UPB_SIZE(32, 32), 4, 0, 6, 1},
-  {5, UPB_SIZE(40, 40), 5, 0, 6, 1},
-  {6, UPB_SIZE(52, 56), 0, 0, 6, 3},
-  {7, UPB_SIZE(56, 64), 0, 0, 6, 3},
-  {8, UPB_SIZE(48, 48), 6, 0, 8, 1},
+  {1, UPB_SIZE(8, 8), 1, 0, 6, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(16, 16), 2, 0, 6, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(24, 24), 3, 0, 6, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(32, 32), 4, 0, 6, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(40, 40), 5, 0, 6, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(52, 56), 0, 0, 6, _UPB_MODE_ARRAY},
+  {7, UPB_SIZE(56, 64), 0, 0, 6, _UPB_MODE_ARRAY},
+  {8, UPB_SIZE(48, 48), 6, 0, 8, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout validate_Fixed64Rules_msginit = {
   NULL,
   &validate_Fixed64Rules__fields[0],
-  UPB_SIZE(64, 72), 8, false, 255,
+  UPB_SIZE(64, 72), 8, false, 8, 255,
 };
 
 static const upb_msglayout_field validate_SFixed32Rules__fields[8] = {
-  {1, UPB_SIZE(4, 4), 1, 0, 15, 1},
-  {2, UPB_SIZE(8, 8), 2, 0, 15, 1},
-  {3, UPB_SIZE(12, 12), 3, 0, 15, 1},
-  {4, UPB_SIZE(16, 16), 4, 0, 15, 1},
-  {5, UPB_SIZE(20, 20), 5, 0, 15, 1},
-  {6, UPB_SIZE(28, 32), 0, 0, 15, 3},
-  {7, UPB_SIZE(32, 40), 0, 0, 15, 3},
-  {8, UPB_SIZE(24, 24), 6, 0, 8, 1},
+  {1, UPB_SIZE(4, 4), 1, 0, 15, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 8), 2, 0, 15, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(12, 12), 3, 0, 15, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(16, 16), 4, 0, 15, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(20, 20), 5, 0, 15, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(28, 32), 0, 0, 15, _UPB_MODE_ARRAY},
+  {7, UPB_SIZE(32, 40), 0, 0, 15, _UPB_MODE_ARRAY},
+  {8, UPB_SIZE(24, 24), 6, 0, 8, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout validate_SFixed32Rules_msginit = {
   NULL,
   &validate_SFixed32Rules__fields[0],
-  UPB_SIZE(40, 48), 8, false, 255,
+  UPB_SIZE(40, 48), 8, false, 8, 255,
 };
 
 static const upb_msglayout_field validate_SFixed64Rules__fields[8] = {
-  {1, UPB_SIZE(8, 8), 1, 0, 16, 1},
-  {2, UPB_SIZE(16, 16), 2, 0, 16, 1},
-  {3, UPB_SIZE(24, 24), 3, 0, 16, 1},
-  {4, UPB_SIZE(32, 32), 4, 0, 16, 1},
-  {5, UPB_SIZE(40, 40), 5, 0, 16, 1},
-  {6, UPB_SIZE(52, 56), 0, 0, 16, 3},
-  {7, UPB_SIZE(56, 64), 0, 0, 16, 3},
-  {8, UPB_SIZE(48, 48), 6, 0, 8, 1},
+  {1, UPB_SIZE(8, 8), 1, 0, 16, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(16, 16), 2, 0, 16, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(24, 24), 3, 0, 16, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(32, 32), 4, 0, 16, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(40, 40), 5, 0, 16, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(52, 56), 0, 0, 16, _UPB_MODE_ARRAY},
+  {7, UPB_SIZE(56, 64), 0, 0, 16, _UPB_MODE_ARRAY},
+  {8, UPB_SIZE(48, 48), 6, 0, 8, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout validate_SFixed64Rules_msginit = {
   NULL,
   &validate_SFixed64Rules__fields[0],
-  UPB_SIZE(64, 72), 8, false, 255,
+  UPB_SIZE(64, 72), 8, false, 8, 255,
 };
 
 static const upb_msglayout_field validate_BoolRules__fields[1] = {
-  {1, UPB_SIZE(1, 1), 1, 0, 8, 1},
+  {1, UPB_SIZE(1, 1), 1, 0, 8, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout validate_BoolRules_msginit = {
   NULL,
   &validate_BoolRules__fields[0],
-  UPB_SIZE(8, 8), 1, false, 255,
+  UPB_SIZE(8, 8), 1, false, 1, 255,
 };
 
 static const upb_msglayout_field validate_StringRules__fields[26] = {
-  {1, UPB_SIZE(60, 64), 1, 0, 12, 1},
-  {2, UPB_SIZE(8, 8), 2, 0, 4, 1},
-  {3, UPB_SIZE(16, 16), 3, 0, 4, 1},
-  {4, UPB_SIZE(24, 24), 4, 0, 4, 1},
-  {5, UPB_SIZE(32, 32), 5, 0, 4, 1},
-  {6, UPB_SIZE(68, 80), 6, 0, 12, 1},
-  {7, UPB_SIZE(76, 96), 7, 0, 12, 1},
-  {8, UPB_SIZE(84, 112), 8, 0, 12, 1},
-  {9, UPB_SIZE(92, 128), 9, 0, 12, 1},
-  {10, UPB_SIZE(108, 160), 0, 0, 12, 3},
-  {11, UPB_SIZE(112, 168), 0, 0, 12, 3},
-  {12, UPB_SIZE(116, 176), UPB_SIZE(-121, -181), 0, 8, 1},
-  {13, UPB_SIZE(116, 176), UPB_SIZE(-121, -181), 0, 8, 1},
-  {14, UPB_SIZE(116, 176), UPB_SIZE(-121, -181), 0, 8, 1},
-  {15, UPB_SIZE(116, 176), UPB_SIZE(-121, -181), 0, 8, 1},
-  {16, UPB_SIZE(116, 176), UPB_SIZE(-121, -181), 0, 8, 1},
-  {17, UPB_SIZE(116, 176), UPB_SIZE(-121, -181), 0, 8, 1},
-  {18, UPB_SIZE(116, 176), UPB_SIZE(-121, -181), 0, 8, 1},
-  {19, UPB_SIZE(40, 40), 10, 0, 4, 1},
-  {20, UPB_SIZE(48, 48), 11, 0, 4, 1},
-  {21, UPB_SIZE(116, 176), UPB_SIZE(-121, -181), 0, 8, 1},
-  {22, UPB_SIZE(116, 176), UPB_SIZE(-121, -181), 0, 8, 1},
-  {23, UPB_SIZE(100, 144), 12, 0, 12, 1},
-  {24, UPB_SIZE(116, 176), UPB_SIZE(-121, -181), 0, 14, 1},
-  {25, UPB_SIZE(56, 56), 13, 0, 8, 1},
-  {26, UPB_SIZE(57, 57), 14, 0, 8, 1},
+  {1, UPB_SIZE(60, 64), 1, 0, 12, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 8), 2, 0, 4, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(16, 16), 3, 0, 4, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(24, 24), 4, 0, 4, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(32, 32), 5, 0, 4, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(68, 80), 6, 0, 12, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(76, 96), 7, 0, 12, _UPB_MODE_SCALAR},
+  {8, UPB_SIZE(84, 112), 8, 0, 12, _UPB_MODE_SCALAR},
+  {9, UPB_SIZE(92, 128), 9, 0, 12, _UPB_MODE_SCALAR},
+  {10, UPB_SIZE(108, 160), 0, 0, 12, _UPB_MODE_ARRAY},
+  {11, UPB_SIZE(112, 168), 0, 0, 12, _UPB_MODE_ARRAY},
+  {12, UPB_SIZE(116, 176), UPB_SIZE(-121, -181), 0, 8, _UPB_MODE_SCALAR},
+  {13, UPB_SIZE(116, 176), UPB_SIZE(-121, -181), 0, 8, _UPB_MODE_SCALAR},
+  {14, UPB_SIZE(116, 176), UPB_SIZE(-121, -181), 0, 8, _UPB_MODE_SCALAR},
+  {15, UPB_SIZE(116, 176), UPB_SIZE(-121, -181), 0, 8, _UPB_MODE_SCALAR},
+  {16, UPB_SIZE(116, 176), UPB_SIZE(-121, -181), 0, 8, _UPB_MODE_SCALAR},
+  {17, UPB_SIZE(116, 176), UPB_SIZE(-121, -181), 0, 8, _UPB_MODE_SCALAR},
+  {18, UPB_SIZE(116, 176), UPB_SIZE(-121, -181), 0, 8, _UPB_MODE_SCALAR},
+  {19, UPB_SIZE(40, 40), 10, 0, 4, _UPB_MODE_SCALAR},
+  {20, UPB_SIZE(48, 48), 11, 0, 4, _UPB_MODE_SCALAR},
+  {21, UPB_SIZE(116, 176), UPB_SIZE(-121, -181), 0, 8, _UPB_MODE_SCALAR},
+  {22, UPB_SIZE(116, 176), UPB_SIZE(-121, -181), 0, 8, _UPB_MODE_SCALAR},
+  {23, UPB_SIZE(100, 144), 12, 0, 12, _UPB_MODE_SCALAR},
+  {24, UPB_SIZE(116, 176), UPB_SIZE(-121, -181), 0, 14, _UPB_MODE_SCALAR},
+  {25, UPB_SIZE(56, 56), 13, 0, 8, _UPB_MODE_SCALAR},
+  {26, UPB_SIZE(57, 57), 14, 0, 8, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout validate_StringRules_msginit = {
   NULL,
   &validate_StringRules__fields[0],
-  UPB_SIZE(128, 192), 26, false, 255,
+  UPB_SIZE(128, 192), 26, false, 26, 255,
 };
 
 static const upb_msglayout_field validate_BytesRules__fields[14] = {
-  {1, UPB_SIZE(36, 40), 1, 0, 12, 1},
-  {2, UPB_SIZE(8, 8), 2, 0, 4, 1},
-  {3, UPB_SIZE(16, 16), 3, 0, 4, 1},
-  {4, UPB_SIZE(44, 56), 4, 0, 12, 1},
-  {5, UPB_SIZE(52, 72), 5, 0, 12, 1},
-  {6, UPB_SIZE(60, 88), 6, 0, 12, 1},
-  {7, UPB_SIZE(68, 104), 7, 0, 12, 1},
-  {8, UPB_SIZE(76, 120), 0, 0, 12, 3},
-  {9, UPB_SIZE(80, 128), 0, 0, 12, 3},
-  {10, UPB_SIZE(84, 136), UPB_SIZE(-89, -141), 0, 8, 1},
-  {11, UPB_SIZE(84, 136), UPB_SIZE(-89, -141), 0, 8, 1},
-  {12, UPB_SIZE(84, 136), UPB_SIZE(-89, -141), 0, 8, 1},
-  {13, UPB_SIZE(24, 24), 8, 0, 4, 1},
-  {14, UPB_SIZE(32, 32), 9, 0, 8, 1},
+  {1, UPB_SIZE(36, 40), 1, 0, 12, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 8), 2, 0, 4, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(16, 16), 3, 0, 4, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(44, 56), 4, 0, 12, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(52, 72), 5, 0, 12, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(60, 88), 6, 0, 12, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(68, 104), 7, 0, 12, _UPB_MODE_SCALAR},
+  {8, UPB_SIZE(76, 120), 0, 0, 12, _UPB_MODE_ARRAY},
+  {9, UPB_SIZE(80, 128), 0, 0, 12, _UPB_MODE_ARRAY},
+  {10, UPB_SIZE(84, 136), UPB_SIZE(-89, -141), 0, 8, _UPB_MODE_SCALAR},
+  {11, UPB_SIZE(84, 136), UPB_SIZE(-89, -141), 0, 8, _UPB_MODE_SCALAR},
+  {12, UPB_SIZE(84, 136), UPB_SIZE(-89, -141), 0, 8, _UPB_MODE_SCALAR},
+  {13, UPB_SIZE(24, 24), 8, 0, 4, _UPB_MODE_SCALAR},
+  {14, UPB_SIZE(32, 32), 9, 0, 8, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout validate_BytesRules_msginit = {
   NULL,
   &validate_BytesRules__fields[0],
-  UPB_SIZE(96, 144), 14, false, 255,
+  UPB_SIZE(96, 144), 14, false, 14, 255,
 };
 
 static const upb_msglayout_field validate_EnumRules__fields[4] = {
-  {1, UPB_SIZE(4, 4), 1, 0, 5, 1},
-  {2, UPB_SIZE(8, 8), 2, 0, 8, 1},
-  {3, UPB_SIZE(12, 16), 0, 0, 5, 3},
-  {4, UPB_SIZE(16, 24), 0, 0, 5, 3},
+  {1, UPB_SIZE(4, 4), 1, 0, 5, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 8), 2, 0, 8, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(12, 16), 0, 0, 5, _UPB_MODE_ARRAY},
+  {4, UPB_SIZE(16, 24), 0, 0, 5, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout validate_EnumRules_msginit = {
   NULL,
   &validate_EnumRules__fields[0],
-  UPB_SIZE(24, 32), 4, false, 255,
+  UPB_SIZE(24, 32), 4, false, 4, 255,
 };
 
 static const upb_msglayout_field validate_MessageRules__fields[2] = {
-  {1, UPB_SIZE(1, 1), 1, 0, 8, 1},
-  {2, UPB_SIZE(2, 2), 2, 0, 8, 1},
+  {1, UPB_SIZE(1, 1), 1, 0, 8, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(2, 2), 2, 0, 8, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout validate_MessageRules_msginit = {
   NULL,
   &validate_MessageRules__fields[0],
-  UPB_SIZE(8, 8), 2, false, 255,
+  UPB_SIZE(8, 8), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const validate_RepeatedRules_submsgs[1] = {
@@ -372,17 +372,17 @@ static const upb_msglayout *const validate_RepeatedRules_submsgs[1] = {
 };
 
 static const upb_msglayout_field validate_RepeatedRules__fields[5] = {
-  {1, UPB_SIZE(8, 8), 1, 0, 4, 1},
-  {2, UPB_SIZE(16, 16), 2, 0, 4, 1},
-  {3, UPB_SIZE(24, 24), 3, 0, 8, 1},
-  {4, UPB_SIZE(28, 32), 4, 0, 11, 1},
-  {5, UPB_SIZE(25, 25), 5, 0, 8, 1},
+  {1, UPB_SIZE(8, 8), 1, 0, 4, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(16, 16), 2, 0, 4, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(24, 24), 3, 0, 8, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(28, 32), 4, 0, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(25, 25), 5, 0, 8, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout validate_RepeatedRules_msginit = {
   &validate_RepeatedRules_submsgs[0],
   &validate_RepeatedRules__fields[0],
-  UPB_SIZE(32, 40), 5, false, 255,
+  UPB_SIZE(32, 40), 5, false, 5, 255,
 };
 
 static const upb_msglayout *const validate_MapRules_submsgs[1] = {
@@ -390,30 +390,30 @@ static const upb_msglayout *const validate_MapRules_submsgs[1] = {
 };
 
 static const upb_msglayout_field validate_MapRules__fields[6] = {
-  {1, UPB_SIZE(8, 8), 1, 0, 4, 1},
-  {2, UPB_SIZE(16, 16), 2, 0, 4, 1},
-  {3, UPB_SIZE(24, 24), 3, 0, 8, 1},
-  {4, UPB_SIZE(28, 32), 4, 0, 11, 1},
-  {5, UPB_SIZE(32, 40), 5, 0, 11, 1},
-  {6, UPB_SIZE(25, 25), 6, 0, 8, 1},
+  {1, UPB_SIZE(8, 8), 1, 0, 4, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(16, 16), 2, 0, 4, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(24, 24), 3, 0, 8, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(28, 32), 4, 0, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(32, 40), 5, 0, 11, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(25, 25), 6, 0, 8, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout validate_MapRules_msginit = {
   &validate_MapRules_submsgs[0],
   &validate_MapRules__fields[0],
-  UPB_SIZE(40, 48), 6, false, 255,
+  UPB_SIZE(40, 48), 6, false, 6, 255,
 };
 
 static const upb_msglayout_field validate_AnyRules__fields[3] = {
-  {1, UPB_SIZE(1, 1), 1, 0, 8, 1},
-  {2, UPB_SIZE(4, 8), 0, 0, 12, 3},
-  {3, UPB_SIZE(8, 16), 0, 0, 12, 3},
+  {1, UPB_SIZE(1, 1), 1, 0, 8, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(4, 8), 0, 0, 12, _UPB_MODE_ARRAY},
+  {3, UPB_SIZE(8, 16), 0, 0, 12, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout validate_AnyRules_msginit = {
   NULL,
   &validate_AnyRules__fields[0],
-  UPB_SIZE(16, 24), 3, false, 255,
+  UPB_SIZE(16, 24), 3, false, 3, 255,
 };
 
 static const upb_msglayout *const validate_DurationRules_submsgs[1] = {
@@ -421,20 +421,20 @@ static const upb_msglayout *const validate_DurationRules_submsgs[1] = {
 };
 
 static const upb_msglayout_field validate_DurationRules__fields[8] = {
-  {1, UPB_SIZE(1, 1), 1, 0, 8, 1},
-  {2, UPB_SIZE(4, 8), 2, 0, 11, 1},
-  {3, UPB_SIZE(8, 16), 3, 0, 11, 1},
-  {4, UPB_SIZE(12, 24), 4, 0, 11, 1},
-  {5, UPB_SIZE(16, 32), 5, 0, 11, 1},
-  {6, UPB_SIZE(20, 40), 6, 0, 11, 1},
-  {7, UPB_SIZE(24, 48), 0, 0, 11, 3},
-  {8, UPB_SIZE(28, 56), 0, 0, 11, 3},
+  {1, UPB_SIZE(1, 1), 1, 0, 8, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(4, 8), 2, 0, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(8, 16), 3, 0, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(12, 24), 4, 0, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(16, 32), 5, 0, 11, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(20, 40), 6, 0, 11, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(24, 48), 0, 0, 11, _UPB_MODE_ARRAY},
+  {8, UPB_SIZE(28, 56), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout validate_DurationRules_msginit = {
   &validate_DurationRules_submsgs[0],
   &validate_DurationRules__fields[0],
-  UPB_SIZE(32, 64), 8, false, 255,
+  UPB_SIZE(32, 64), 8, false, 8, 255,
 };
 
 static const upb_msglayout *const validate_TimestampRules_submsgs[2] = {
@@ -443,21 +443,21 @@ static const upb_msglayout *const validate_TimestampRules_submsgs[2] = {
 };
 
 static const upb_msglayout_field validate_TimestampRules__fields[9] = {
-  {1, UPB_SIZE(2, 2), 1, 0, 8, 1},
-  {2, UPB_SIZE(8, 8), 2, 1, 11, 1},
-  {3, UPB_SIZE(12, 16), 3, 1, 11, 1},
-  {4, UPB_SIZE(16, 24), 4, 1, 11, 1},
-  {5, UPB_SIZE(20, 32), 5, 1, 11, 1},
-  {6, UPB_SIZE(24, 40), 6, 1, 11, 1},
-  {7, UPB_SIZE(3, 3), 7, 0, 8, 1},
-  {8, UPB_SIZE(4, 4), 8, 0, 8, 1},
-  {9, UPB_SIZE(28, 48), 9, 0, 11, 1},
+  {1, UPB_SIZE(2, 2), 1, 0, 8, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 8), 2, 1, 11, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(12, 16), 3, 1, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(16, 24), 4, 1, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(20, 32), 5, 1, 11, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(24, 40), 6, 1, 11, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(3, 3), 7, 0, 8, _UPB_MODE_SCALAR},
+  {8, UPB_SIZE(4, 4), 8, 0, 8, _UPB_MODE_SCALAR},
+  {9, UPB_SIZE(28, 48), 9, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout validate_TimestampRules_msginit = {
   &validate_TimestampRules_submsgs[0],
   &validate_TimestampRules__fields[0],
-  UPB_SIZE(32, 56), 9, false, 255,
+  UPB_SIZE(32, 56), 9, false, 9, 255,
 };
 
 #include "upb/port_undef.inc"
index 640cdf9..e121fd8 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef VALIDATE_VALIDATE_PROTO_UPB_H_
 #define VALIDATE_VALIDATE_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -109,13 +109,19 @@ UPB_INLINE validate_FieldRules *validate_FieldRules_new(upb_arena *arena) {
 UPB_INLINE validate_FieldRules *validate_FieldRules_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   validate_FieldRules *ret = validate_FieldRules_new(arena);
-  return (ret && upb_decode(buf, size, ret, &validate_FieldRules_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &validate_FieldRules_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE validate_FieldRules *validate_FieldRules_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   validate_FieldRules *ret = validate_FieldRules_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &validate_FieldRules_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &validate_FieldRules_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *validate_FieldRules_serialize(const validate_FieldRules *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &validate_FieldRules_msginit, arena, len);
@@ -466,13 +472,19 @@ UPB_INLINE validate_FloatRules *validate_FloatRules_new(upb_arena *arena) {
 UPB_INLINE validate_FloatRules *validate_FloatRules_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   validate_FloatRules *ret = validate_FloatRules_new(arena);
-  return (ret && upb_decode(buf, size, ret, &validate_FloatRules_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &validate_FloatRules_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE validate_FloatRules *validate_FloatRules_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   validate_FloatRules *ret = validate_FloatRules_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &validate_FloatRules_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &validate_FloatRules_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *validate_FloatRules_serialize(const validate_FloatRules *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &validate_FloatRules_msginit, arena, len);
@@ -546,13 +558,19 @@ UPB_INLINE validate_DoubleRules *validate_DoubleRules_new(upb_arena *arena) {
 UPB_INLINE validate_DoubleRules *validate_DoubleRules_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   validate_DoubleRules *ret = validate_DoubleRules_new(arena);
-  return (ret && upb_decode(buf, size, ret, &validate_DoubleRules_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &validate_DoubleRules_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE validate_DoubleRules *validate_DoubleRules_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   validate_DoubleRules *ret = validate_DoubleRules_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &validate_DoubleRules_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &validate_DoubleRules_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *validate_DoubleRules_serialize(const validate_DoubleRules *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &validate_DoubleRules_msginit, arena, len);
@@ -626,13 +644,19 @@ UPB_INLINE validate_Int32Rules *validate_Int32Rules_new(upb_arena *arena) {
 UPB_INLINE validate_Int32Rules *validate_Int32Rules_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   validate_Int32Rules *ret = validate_Int32Rules_new(arena);
-  return (ret && upb_decode(buf, size, ret, &validate_Int32Rules_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &validate_Int32Rules_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE validate_Int32Rules *validate_Int32Rules_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   validate_Int32Rules *ret = validate_Int32Rules_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &validate_Int32Rules_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &validate_Int32Rules_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *validate_Int32Rules_serialize(const validate_Int32Rules *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &validate_Int32Rules_msginit, arena, len);
@@ -706,13 +730,19 @@ UPB_INLINE validate_Int64Rules *validate_Int64Rules_new(upb_arena *arena) {
 UPB_INLINE validate_Int64Rules *validate_Int64Rules_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   validate_Int64Rules *ret = validate_Int64Rules_new(arena);
-  return (ret && upb_decode(buf, size, ret, &validate_Int64Rules_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &validate_Int64Rules_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE validate_Int64Rules *validate_Int64Rules_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   validate_Int64Rules *ret = validate_Int64Rules_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &validate_Int64Rules_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &validate_Int64Rules_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *validate_Int64Rules_serialize(const validate_Int64Rules *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &validate_Int64Rules_msginit, arena, len);
@@ -786,13 +816,19 @@ UPB_INLINE validate_UInt32Rules *validate_UInt32Rules_new(upb_arena *arena) {
 UPB_INLINE validate_UInt32Rules *validate_UInt32Rules_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   validate_UInt32Rules *ret = validate_UInt32Rules_new(arena);
-  return (ret && upb_decode(buf, size, ret, &validate_UInt32Rules_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &validate_UInt32Rules_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE validate_UInt32Rules *validate_UInt32Rules_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   validate_UInt32Rules *ret = validate_UInt32Rules_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &validate_UInt32Rules_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &validate_UInt32Rules_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *validate_UInt32Rules_serialize(const validate_UInt32Rules *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &validate_UInt32Rules_msginit, arena, len);
@@ -866,13 +902,19 @@ UPB_INLINE validate_UInt64Rules *validate_UInt64Rules_new(upb_arena *arena) {
 UPB_INLINE validate_UInt64Rules *validate_UInt64Rules_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   validate_UInt64Rules *ret = validate_UInt64Rules_new(arena);
-  return (ret && upb_decode(buf, size, ret, &validate_UInt64Rules_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &validate_UInt64Rules_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE validate_UInt64Rules *validate_UInt64Rules_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   validate_UInt64Rules *ret = validate_UInt64Rules_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &validate_UInt64Rules_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &validate_UInt64Rules_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *validate_UInt64Rules_serialize(const validate_UInt64Rules *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &validate_UInt64Rules_msginit, arena, len);
@@ -946,13 +988,19 @@ UPB_INLINE validate_SInt32Rules *validate_SInt32Rules_new(upb_arena *arena) {
 UPB_INLINE validate_SInt32Rules *validate_SInt32Rules_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   validate_SInt32Rules *ret = validate_SInt32Rules_new(arena);
-  return (ret && upb_decode(buf, size, ret, &validate_SInt32Rules_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &validate_SInt32Rules_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE validate_SInt32Rules *validate_SInt32Rules_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   validate_SInt32Rules *ret = validate_SInt32Rules_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &validate_SInt32Rules_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &validate_SInt32Rules_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *validate_SInt32Rules_serialize(const validate_SInt32Rules *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &validate_SInt32Rules_msginit, arena, len);
@@ -1026,13 +1074,19 @@ UPB_INLINE validate_SInt64Rules *validate_SInt64Rules_new(upb_arena *arena) {
 UPB_INLINE validate_SInt64Rules *validate_SInt64Rules_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   validate_SInt64Rules *ret = validate_SInt64Rules_new(arena);
-  return (ret && upb_decode(buf, size, ret, &validate_SInt64Rules_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &validate_SInt64Rules_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE validate_SInt64Rules *validate_SInt64Rules_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   validate_SInt64Rules *ret = validate_SInt64Rules_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &validate_SInt64Rules_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &validate_SInt64Rules_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *validate_SInt64Rules_serialize(const validate_SInt64Rules *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &validate_SInt64Rules_msginit, arena, len);
@@ -1106,13 +1160,19 @@ UPB_INLINE validate_Fixed32Rules *validate_Fixed32Rules_new(upb_arena *arena) {
 UPB_INLINE validate_Fixed32Rules *validate_Fixed32Rules_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   validate_Fixed32Rules *ret = validate_Fixed32Rules_new(arena);
-  return (ret && upb_decode(buf, size, ret, &validate_Fixed32Rules_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &validate_Fixed32Rules_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE validate_Fixed32Rules *validate_Fixed32Rules_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   validate_Fixed32Rules *ret = validate_Fixed32Rules_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &validate_Fixed32Rules_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &validate_Fixed32Rules_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *validate_Fixed32Rules_serialize(const validate_Fixed32Rules *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &validate_Fixed32Rules_msginit, arena, len);
@@ -1186,13 +1246,19 @@ UPB_INLINE validate_Fixed64Rules *validate_Fixed64Rules_new(upb_arena *arena) {
 UPB_INLINE validate_Fixed64Rules *validate_Fixed64Rules_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   validate_Fixed64Rules *ret = validate_Fixed64Rules_new(arena);
-  return (ret && upb_decode(buf, size, ret, &validate_Fixed64Rules_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &validate_Fixed64Rules_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE validate_Fixed64Rules *validate_Fixed64Rules_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   validate_Fixed64Rules *ret = validate_Fixed64Rules_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &validate_Fixed64Rules_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &validate_Fixed64Rules_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *validate_Fixed64Rules_serialize(const validate_Fixed64Rules *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &validate_Fixed64Rules_msginit, arena, len);
@@ -1266,13 +1332,19 @@ UPB_INLINE validate_SFixed32Rules *validate_SFixed32Rules_new(upb_arena *arena)
 UPB_INLINE validate_SFixed32Rules *validate_SFixed32Rules_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   validate_SFixed32Rules *ret = validate_SFixed32Rules_new(arena);
-  return (ret && upb_decode(buf, size, ret, &validate_SFixed32Rules_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &validate_SFixed32Rules_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE validate_SFixed32Rules *validate_SFixed32Rules_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   validate_SFixed32Rules *ret = validate_SFixed32Rules_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &validate_SFixed32Rules_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &validate_SFixed32Rules_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *validate_SFixed32Rules_serialize(const validate_SFixed32Rules *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &validate_SFixed32Rules_msginit, arena, len);
@@ -1346,13 +1418,19 @@ UPB_INLINE validate_SFixed64Rules *validate_SFixed64Rules_new(upb_arena *arena)
 UPB_INLINE validate_SFixed64Rules *validate_SFixed64Rules_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   validate_SFixed64Rules *ret = validate_SFixed64Rules_new(arena);
-  return (ret && upb_decode(buf, size, ret, &validate_SFixed64Rules_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &validate_SFixed64Rules_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE validate_SFixed64Rules *validate_SFixed64Rules_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   validate_SFixed64Rules *ret = validate_SFixed64Rules_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &validate_SFixed64Rules_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &validate_SFixed64Rules_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *validate_SFixed64Rules_serialize(const validate_SFixed64Rules *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &validate_SFixed64Rules_msginit, arena, len);
@@ -1426,13 +1504,19 @@ UPB_INLINE validate_BoolRules *validate_BoolRules_new(upb_arena *arena) {
 UPB_INLINE validate_BoolRules *validate_BoolRules_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   validate_BoolRules *ret = validate_BoolRules_new(arena);
-  return (ret && upb_decode(buf, size, ret, &validate_BoolRules_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &validate_BoolRules_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE validate_BoolRules *validate_BoolRules_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   validate_BoolRules *ret = validate_BoolRules_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &validate_BoolRules_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &validate_BoolRules_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *validate_BoolRules_serialize(const validate_BoolRules *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &validate_BoolRules_msginit, arena, len);
@@ -1454,13 +1538,19 @@ UPB_INLINE validate_StringRules *validate_StringRules_new(upb_arena *arena) {
 UPB_INLINE validate_StringRules *validate_StringRules_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   validate_StringRules *ret = validate_StringRules_new(arena);
-  return (ret && upb_decode(buf, size, ret, &validate_StringRules_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &validate_StringRules_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE validate_StringRules *validate_StringRules_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   validate_StringRules *ret = validate_StringRules_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &validate_StringRules_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &validate_StringRules_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *validate_StringRules_serialize(const validate_StringRules *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &validate_StringRules_msginit, arena, len);
@@ -1647,13 +1737,19 @@ UPB_INLINE validate_BytesRules *validate_BytesRules_new(upb_arena *arena) {
 UPB_INLINE validate_BytesRules *validate_BytesRules_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   validate_BytesRules *ret = validate_BytesRules_new(arena);
-  return (ret && upb_decode(buf, size, ret, &validate_BytesRules_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &validate_BytesRules_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE validate_BytesRules *validate_BytesRules_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   validate_BytesRules *ret = validate_BytesRules_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &validate_BytesRules_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &validate_BytesRules_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *validate_BytesRules_serialize(const validate_BytesRules *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &validate_BytesRules_msginit, arena, len);
@@ -1768,13 +1864,19 @@ UPB_INLINE validate_EnumRules *validate_EnumRules_new(upb_arena *arena) {
 UPB_INLINE validate_EnumRules *validate_EnumRules_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   validate_EnumRules *ret = validate_EnumRules_new(arena);
-  return (ret && upb_decode(buf, size, ret, &validate_EnumRules_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &validate_EnumRules_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE validate_EnumRules *validate_EnumRules_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   validate_EnumRules *ret = validate_EnumRules_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &validate_EnumRules_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &validate_EnumRules_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *validate_EnumRules_serialize(const validate_EnumRules *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &validate_EnumRules_msginit, arena, len);
@@ -1824,13 +1926,19 @@ UPB_INLINE validate_MessageRules *validate_MessageRules_new(upb_arena *arena) {
 UPB_INLINE validate_MessageRules *validate_MessageRules_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   validate_MessageRules *ret = validate_MessageRules_new(arena);
-  return (ret && upb_decode(buf, size, ret, &validate_MessageRules_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &validate_MessageRules_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE validate_MessageRules *validate_MessageRules_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   validate_MessageRules *ret = validate_MessageRules_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &validate_MessageRules_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &validate_MessageRules_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *validate_MessageRules_serialize(const validate_MessageRules *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &validate_MessageRules_msginit, arena, len);
@@ -1858,13 +1966,19 @@ UPB_INLINE validate_RepeatedRules *validate_RepeatedRules_new(upb_arena *arena)
 UPB_INLINE validate_RepeatedRules *validate_RepeatedRules_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   validate_RepeatedRules *ret = validate_RepeatedRules_new(arena);
-  return (ret && upb_decode(buf, size, ret, &validate_RepeatedRules_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &validate_RepeatedRules_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE validate_RepeatedRules *validate_RepeatedRules_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   validate_RepeatedRules *ret = validate_RepeatedRules_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &validate_RepeatedRules_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &validate_RepeatedRules_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *validate_RepeatedRules_serialize(const validate_RepeatedRules *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &validate_RepeatedRules_msginit, arena, len);
@@ -1919,13 +2033,19 @@ UPB_INLINE validate_MapRules *validate_MapRules_new(upb_arena *arena) {
 UPB_INLINE validate_MapRules *validate_MapRules_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   validate_MapRules *ret = validate_MapRules_new(arena);
-  return (ret && upb_decode(buf, size, ret, &validate_MapRules_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &validate_MapRules_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE validate_MapRules *validate_MapRules_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   validate_MapRules *ret = validate_MapRules_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &validate_MapRules_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &validate_MapRules_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *validate_MapRules_serialize(const validate_MapRules *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &validate_MapRules_msginit, arena, len);
@@ -1995,13 +2115,19 @@ UPB_INLINE validate_AnyRules *validate_AnyRules_new(upb_arena *arena) {
 UPB_INLINE validate_AnyRules *validate_AnyRules_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   validate_AnyRules *ret = validate_AnyRules_new(arena);
-  return (ret && upb_decode(buf, size, ret, &validate_AnyRules_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &validate_AnyRules_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE validate_AnyRules *validate_AnyRules_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   validate_AnyRules *ret = validate_AnyRules_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &validate_AnyRules_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &validate_AnyRules_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *validate_AnyRules_serialize(const validate_AnyRules *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &validate_AnyRules_msginit, arena, len);
@@ -2045,13 +2171,19 @@ UPB_INLINE validate_DurationRules *validate_DurationRules_new(upb_arena *arena)
 UPB_INLINE validate_DurationRules *validate_DurationRules_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   validate_DurationRules *ret = validate_DurationRules_new(arena);
-  return (ret && upb_decode(buf, size, ret, &validate_DurationRules_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &validate_DurationRules_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE validate_DurationRules *validate_DurationRules_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   validate_DurationRules *ret = validate_DurationRules_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &validate_DurationRules_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &validate_DurationRules_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *validate_DurationRules_serialize(const validate_DurationRules *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &validate_DurationRules_msginit, arena, len);
@@ -2178,13 +2310,19 @@ UPB_INLINE validate_TimestampRules *validate_TimestampRules_new(upb_arena *arena
 UPB_INLINE validate_TimestampRules *validate_TimestampRules_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   validate_TimestampRules *ret = validate_TimestampRules_new(arena);
-  return (ret && upb_decode(buf, size, ret, &validate_TimestampRules_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &validate_TimestampRules_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE validate_TimestampRules *validate_TimestampRules_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   validate_TimestampRules *ret = validate_TimestampRules_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &validate_TimestampRules_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &validate_TimestampRules_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *validate_TimestampRules_serialize(const validate_TimestampRules *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &validate_TimestampRules_msginit, arena, len);
index 6c6da7d..de06e07 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "xds/core/v3/authority.upb.h"
 #include "udpa/annotations/status.upb.h"
 #include "validate/validate.upb.h"
 #include "upb/port_def.inc"
 
 static const upb_msglayout_field xds_core_v3_Authority__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout xds_core_v3_Authority_msginit = {
   NULL,
   &xds_core_v3_Authority__fields[0],
-  UPB_SIZE(8, 16), 1, false, 255,
+  UPB_SIZE(8, 16), 1, false, 1, 255,
 };
 
 #include "upb/port_undef.inc"
index 2f1ff44..fa75a11 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef XDS_CORE_V3_AUTHORITY_PROTO_UPB_H_
 #define XDS_CORE_V3_AUTHORITY_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -33,13 +33,19 @@ UPB_INLINE xds_core_v3_Authority *xds_core_v3_Authority_new(upb_arena *arena) {
 UPB_INLINE xds_core_v3_Authority *xds_core_v3_Authority_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   xds_core_v3_Authority *ret = xds_core_v3_Authority_new(arena);
-  return (ret && upb_decode(buf, size, ret, &xds_core_v3_Authority_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &xds_core_v3_Authority_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE xds_core_v3_Authority *xds_core_v3_Authority_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   xds_core_v3_Authority *ret = xds_core_v3_Authority_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &xds_core_v3_Authority_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &xds_core_v3_Authority_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *xds_core_v3_Authority_serialize(const xds_core_v3_Authority *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &xds_core_v3_Authority_msginit, arena, len);
index 20cc297..e4584e4 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "xds/core/v3/collection_entry.upb.h"
 #include "google/protobuf/any.upb.h"
 #include "udpa/annotations/status.upb.h"
@@ -22,14 +22,14 @@ static const upb_msglayout *const xds_core_v3_CollectionEntry_submsgs[2] = {
 };
 
 static const upb_msglayout_field xds_core_v3_CollectionEntry__fields[2] = {
-  {1, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 1, 11, 1},
-  {2, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 11, 1},
+  {1, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 1, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(0, 0), UPB_SIZE(-5, -9), 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout xds_core_v3_CollectionEntry_msginit = {
   &xds_core_v3_CollectionEntry_submsgs[0],
   &xds_core_v3_CollectionEntry__fields[0],
-  UPB_SIZE(8, 16), 2, false, 255,
+  UPB_SIZE(8, 16), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const xds_core_v3_CollectionEntry_InlineEntry_submsgs[1] = {
@@ -37,15 +37,15 @@ static const upb_msglayout *const xds_core_v3_CollectionEntry_InlineEntry_submsg
 };
 
 static const upb_msglayout_field xds_core_v3_CollectionEntry_InlineEntry__fields[3] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(12, 24), 0, 0, 9, 1},
-  {3, UPB_SIZE(20, 40), 1, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(12, 24), 0, 0, 9, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(20, 40), 1, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout xds_core_v3_CollectionEntry_InlineEntry_msginit = {
   &xds_core_v3_CollectionEntry_InlineEntry_submsgs[0],
   &xds_core_v3_CollectionEntry_InlineEntry__fields[0],
-  UPB_SIZE(24, 48), 3, false, 255,
+  UPB_SIZE(24, 48), 3, false, 3, 255,
 };
 
 #include "upb/port_undef.inc"
index 983a345..df01757 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef XDS_CORE_V3_COLLECTION_ENTRY_PROTO_UPB_H_
 #define XDS_CORE_V3_COLLECTION_ENTRY_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -40,13 +40,19 @@ UPB_INLINE xds_core_v3_CollectionEntry *xds_core_v3_CollectionEntry_new(upb_aren
 UPB_INLINE xds_core_v3_CollectionEntry *xds_core_v3_CollectionEntry_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   xds_core_v3_CollectionEntry *ret = xds_core_v3_CollectionEntry_new(arena);
-  return (ret && upb_decode(buf, size, ret, &xds_core_v3_CollectionEntry_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &xds_core_v3_CollectionEntry_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE xds_core_v3_CollectionEntry *xds_core_v3_CollectionEntry_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   xds_core_v3_CollectionEntry *ret = xds_core_v3_CollectionEntry_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &xds_core_v3_CollectionEntry_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &xds_core_v3_CollectionEntry_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *xds_core_v3_CollectionEntry_serialize(const xds_core_v3_CollectionEntry *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &xds_core_v3_CollectionEntry_msginit, arena, len);
@@ -97,13 +103,19 @@ UPB_INLINE xds_core_v3_CollectionEntry_InlineEntry *xds_core_v3_CollectionEntry_
 UPB_INLINE xds_core_v3_CollectionEntry_InlineEntry *xds_core_v3_CollectionEntry_InlineEntry_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   xds_core_v3_CollectionEntry_InlineEntry *ret = xds_core_v3_CollectionEntry_InlineEntry_new(arena);
-  return (ret && upb_decode(buf, size, ret, &xds_core_v3_CollectionEntry_InlineEntry_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &xds_core_v3_CollectionEntry_InlineEntry_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE xds_core_v3_CollectionEntry_InlineEntry *xds_core_v3_CollectionEntry_InlineEntry_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   xds_core_v3_CollectionEntry_InlineEntry *ret = xds_core_v3_CollectionEntry_InlineEntry_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &xds_core_v3_CollectionEntry_InlineEntry_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &xds_core_v3_CollectionEntry_InlineEntry_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *xds_core_v3_CollectionEntry_InlineEntry_serialize(const xds_core_v3_CollectionEntry_InlineEntry *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &xds_core_v3_CollectionEntry_InlineEntry_msginit, arena, len);
index 17c3c61..b78d54c 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "xds/core/v3/context_params.upb.h"
 #include "udpa/annotations/status.upb.h"
 
@@ -18,24 +18,24 @@ static const upb_msglayout *const xds_core_v3_ContextParams_submsgs[1] = {
 };
 
 static const upb_msglayout_field xds_core_v3_ContextParams__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 11, _UPB_LABEL_MAP},
+  {1, UPB_SIZE(0, 0), 0, 0, 11, _UPB_MODE_MAP},
 };
 
 const upb_msglayout xds_core_v3_ContextParams_msginit = {
   &xds_core_v3_ContextParams_submsgs[0],
   &xds_core_v3_ContextParams__fields[0],
-  UPB_SIZE(8, 8), 1, false, 255,
+  UPB_SIZE(8, 8), 1, false, 1, 255,
 };
 
 static const upb_msglayout_field xds_core_v3_ContextParams_ParamsEntry__fields[2] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 9, 1},
-  {2, UPB_SIZE(8, 16), 0, 0, 9, 1},
+  {1, UPB_SIZE(0, 0), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 16), 0, 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout xds_core_v3_ContextParams_ParamsEntry_msginit = {
   NULL,
   &xds_core_v3_ContextParams_ParamsEntry__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 #include "upb/port_undef.inc"
index 0bcd242..3fab0c4 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef XDS_CORE_V3_CONTEXT_PARAMS_PROTO_UPB_H_
 #define XDS_CORE_V3_CONTEXT_PARAMS_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -36,13 +36,19 @@ UPB_INLINE xds_core_v3_ContextParams *xds_core_v3_ContextParams_new(upb_arena *a
 UPB_INLINE xds_core_v3_ContextParams *xds_core_v3_ContextParams_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   xds_core_v3_ContextParams *ret = xds_core_v3_ContextParams_new(arena);
-  return (ret && upb_decode(buf, size, ret, &xds_core_v3_ContextParams_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &xds_core_v3_ContextParams_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE xds_core_v3_ContextParams *xds_core_v3_ContextParams_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   xds_core_v3_ContextParams *ret = xds_core_v3_ContextParams_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &xds_core_v3_ContextParams_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &xds_core_v3_ContextParams_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *xds_core_v3_ContextParams_serialize(const xds_core_v3_ContextParams *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &xds_core_v3_ContextParams_msginit, arena, len);
index fa2375e..c3fa6ab 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "xds/core/v3/resource.upb.h"
 #include "google/protobuf/any.upb.h"
 #include "udpa/annotations/status.upb.h"
@@ -21,15 +21,15 @@ static const upb_msglayout *const xds_core_v3_Resource_submsgs[2] = {
 };
 
 static const upb_msglayout_field xds_core_v3_Resource__fields[3] = {
-  {1, UPB_SIZE(12, 24), 1, 1, 11, 1},
-  {2, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {3, UPB_SIZE(16, 32), 2, 0, 11, 1},
+  {1, UPB_SIZE(12, 24), 1, 1, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(16, 32), 2, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout xds_core_v3_Resource_msginit = {
   &xds_core_v3_Resource_submsgs[0],
   &xds_core_v3_Resource__fields[0],
-  UPB_SIZE(24, 48), 3, false, 255,
+  UPB_SIZE(24, 48), 3, false, 3, 255,
 };
 
 #include "upb/port_undef.inc"
index ab8e2df..7be7462 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef XDS_CORE_V3_RESOURCE_PROTO_UPB_H_
 #define XDS_CORE_V3_RESOURCE_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -37,13 +37,19 @@ UPB_INLINE xds_core_v3_Resource *xds_core_v3_Resource_new(upb_arena *arena) {
 UPB_INLINE xds_core_v3_Resource *xds_core_v3_Resource_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   xds_core_v3_Resource *ret = xds_core_v3_Resource_new(arena);
-  return (ret && upb_decode(buf, size, ret, &xds_core_v3_Resource_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &xds_core_v3_Resource_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE xds_core_v3_Resource *xds_core_v3_Resource_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   xds_core_v3_Resource *ret = xds_core_v3_Resource_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &xds_core_v3_Resource_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &xds_core_v3_Resource_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *xds_core_v3_Resource_serialize(const xds_core_v3_Resource *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &xds_core_v3_Resource_msginit, arena, len);
index 2bd099a..575e556 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "xds/core/v3/resource_locator.upb.h"
 #include "udpa/annotations/status.upb.h"
 #include "xds/core/v3/context_params.upb.h"
@@ -21,18 +21,18 @@ static const upb_msglayout *const xds_core_v3_ResourceLocator_submsgs[2] = {
 };
 
 static const upb_msglayout_field xds_core_v3_ResourceLocator__fields[6] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 14, 1},
-  {2, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {3, UPB_SIZE(12, 24), 0, 0, 9, 1},
-  {4, UPB_SIZE(20, 40), 0, 0, 9, 1},
-  {5, UPB_SIZE(32, 64), UPB_SIZE(-37, -73), 0, 11, 1},
-  {6, UPB_SIZE(28, 56), 0, 1, 11, 3},
+  {1, UPB_SIZE(0, 0), 0, 0, 14, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(12, 24), 0, 0, 9, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(20, 40), 0, 0, 9, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(32, 64), UPB_SIZE(-37, -73), 0, 11, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(28, 56), 0, 1, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout xds_core_v3_ResourceLocator_msginit = {
   &xds_core_v3_ResourceLocator_submsgs[0],
   &xds_core_v3_ResourceLocator__fields[0],
-  UPB_SIZE(40, 80), 6, false, 255,
+  UPB_SIZE(40, 80), 6, false, 6, 255,
 };
 
 static const upb_msglayout *const xds_core_v3_ResourceLocator_Directive_submsgs[1] = {
@@ -40,14 +40,14 @@ static const upb_msglayout *const xds_core_v3_ResourceLocator_Directive_submsgs[
 };
 
 static const upb_msglayout_field xds_core_v3_ResourceLocator_Directive__fields[2] = {
-  {1, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 11, 1},
-  {2, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 9, 1},
+  {1, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 11, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(0, 0), UPB_SIZE(-9, -17), 0, 9, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout xds_core_v3_ResourceLocator_Directive_msginit = {
   &xds_core_v3_ResourceLocator_Directive_submsgs[0],
   &xds_core_v3_ResourceLocator_Directive__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 #include "upb/port_undef.inc"
index da7442b..797cc45 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef XDS_CORE_V3_RESOURCE_LOCATOR_PROTO_UPB_H_
 #define XDS_CORE_V3_RESOURCE_LOCATOR_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -44,13 +44,19 @@ UPB_INLINE xds_core_v3_ResourceLocator *xds_core_v3_ResourceLocator_new(upb_aren
 UPB_INLINE xds_core_v3_ResourceLocator *xds_core_v3_ResourceLocator_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   xds_core_v3_ResourceLocator *ret = xds_core_v3_ResourceLocator_new(arena);
-  return (ret && upb_decode(buf, size, ret, &xds_core_v3_ResourceLocator_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &xds_core_v3_ResourceLocator_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE xds_core_v3_ResourceLocator *xds_core_v3_ResourceLocator_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   xds_core_v3_ResourceLocator *ret = xds_core_v3_ResourceLocator_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &xds_core_v3_ResourceLocator_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &xds_core_v3_ResourceLocator_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *xds_core_v3_ResourceLocator_serialize(const xds_core_v3_ResourceLocator *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &xds_core_v3_ResourceLocator_msginit, arena, len);
@@ -117,13 +123,19 @@ UPB_INLINE xds_core_v3_ResourceLocator_Directive *xds_core_v3_ResourceLocator_Di
 UPB_INLINE xds_core_v3_ResourceLocator_Directive *xds_core_v3_ResourceLocator_Directive_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   xds_core_v3_ResourceLocator_Directive *ret = xds_core_v3_ResourceLocator_Directive_new(arena);
-  return (ret && upb_decode(buf, size, ret, &xds_core_v3_ResourceLocator_Directive_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &xds_core_v3_ResourceLocator_Directive_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE xds_core_v3_ResourceLocator_Directive *xds_core_v3_ResourceLocator_Directive_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   xds_core_v3_ResourceLocator_Directive *ret = xds_core_v3_ResourceLocator_Directive_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &xds_core_v3_ResourceLocator_Directive_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &xds_core_v3_ResourceLocator_Directive_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *xds_core_v3_ResourceLocator_Directive_serialize(const xds_core_v3_ResourceLocator_Directive *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &xds_core_v3_ResourceLocator_Directive_msginit, arena, len);
index ff645f6..f0bf9b3 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "xds/core/v3/resource_name.upb.h"
 #include "udpa/annotations/status.upb.h"
 #include "xds/core/v3/context_params.upb.h"
@@ -20,16 +20,16 @@ static const upb_msglayout *const xds_core_v3_ResourceName_submsgs[1] = {
 };
 
 static const upb_msglayout_field xds_core_v3_ResourceName__fields[4] = {
-  {1, UPB_SIZE(4, 8), 0, 0, 9, 1},
-  {2, UPB_SIZE(12, 24), 0, 0, 9, 1},
-  {3, UPB_SIZE(20, 40), 0, 0, 9, 1},
-  {4, UPB_SIZE(28, 56), 1, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 0, 0, 9, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(12, 24), 0, 0, 9, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(20, 40), 0, 0, 9, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(28, 56), 1, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout xds_core_v3_ResourceName_msginit = {
   &xds_core_v3_ResourceName_submsgs[0],
   &xds_core_v3_ResourceName__fields[0],
-  UPB_SIZE(32, 64), 4, false, 255,
+  UPB_SIZE(32, 64), 4, false, 4, 255,
 };
 
 #include "upb/port_undef.inc"
index 3f38cc5..06fe8a0 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef XDS_CORE_V3_RESOURCE_NAME_PROTO_UPB_H_
 #define XDS_CORE_V3_RESOURCE_NAME_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -35,13 +35,19 @@ UPB_INLINE xds_core_v3_ResourceName *xds_core_v3_ResourceName_new(upb_arena *are
 UPB_INLINE xds_core_v3_ResourceName *xds_core_v3_ResourceName_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   xds_core_v3_ResourceName *ret = xds_core_v3_ResourceName_new(arena);
-  return (ret && upb_decode(buf, size, ret, &xds_core_v3_ResourceName_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &xds_core_v3_ResourceName_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE xds_core_v3_ResourceName *xds_core_v3_ResourceName_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   xds_core_v3_ResourceName *ret = xds_core_v3_ResourceName_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &xds_core_v3_ResourceName_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &xds_core_v3_ResourceName_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *xds_core_v3_ResourceName_serialize(const xds_core_v3_ResourceName *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &xds_core_v3_ResourceName_msginit, arena, len);
index 156516b..9068d1f 100644 (file)
@@ -82,7 +82,7 @@ static const upb_msglayout *layouts[23] = {
   &envoy_config_cluster_v3_TrackClusterStats_msginit,
 };
 
-static const char descriptor[11266] = {'\n', '%', 'e', 'n', 'v', 'o', 'y', '/', 'c', 'o', 'n', 'f', 'i', 'g', '/', 'c', 'l', 'u', 's', 't', 'e', 'r', '/', 'v', '3', 
+static const char descriptor[11317] = {'\n', '%', 'e', 'n', 'v', 'o', 'y', '/', 'c', 'o', 'n', 'f', 'i', 'g', '/', 'c', 'l', 'u', 's', 't', 'e', 'r', '/', 'v', '3', 
 '/', 'c', 'l', 'u', 's', 't', 'e', 'r', '.', 'p', 'r', 'o', 't', 'o', '\022', '\027', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 
 'f', 'i', 'g', '.', 'c', 'l', 'u', 's', 't', 'e', 'r', '.', 'v', '3', '\032', '-', 'e', 'n', 'v', 'o', 'y', '/', 'c', 'o', 'n', 
 'f', 'i', 'g', '/', 'c', 'l', 'u', 's', 't', 'e', 'r', '/', 'v', '3', '/', 'c', 'i', 'r', 'c', 'u', 'i', 't', '_', 'b', 'r', 
@@ -120,7 +120,7 @@ static const char descriptor[11266] = {'\n', '%', 'e', 'n', 'v', 'o', 'y', '/',
 'e', '.', 'p', 'r', 'o', 't', 'o', '\"', 'K', '\n', '\021', 'C', 'l', 'u', 's', 't', 'e', 'r', 'C', 'o', 'l', 'l', 'e', 'c', 't', 
 'i', 'o', 'n', '\022', '6', '\n', '\007', 'e', 'n', 't', 'r', 'i', 'e', 's', '\030', '\001', ' ', '\001', '(', '\013', '2', '\034', '.', 'x', 'd', 
 's', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'C', 'o', 'l', 'l', 'e', 'c', 't', 'i', 'o', 'n', 'E', 'n', 't', 'r', 'y', 
-'R', '\007', 'e', 'n', 't', 'r', 'i', 'e', 's', '\"', '\300', 'J', '\n', '\007', 'C', 'l', 'u', 's', 't', 'e', 'r', '\022', 'o', '\n', '\030', 
+'R', '\007', 'e', 'n', 't', 'r', 'i', 'e', 's', '\"', '\276', 'J', '\n', '\007', 'C', 'l', 'u', 's', 't', 'e', 'r', '\022', 'o', '\n', '\030', 
 't', 'r', 'a', 'n', 's', 'p', 'o', 'r', 't', '_', 's', 'o', 'c', 'k', 'e', 't', '_', 'm', 'a', 't', 'c', 'h', 'e', 's', '\030', 
 '+', ' ', '\003', '(', '\013', '2', '5', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'l', 'u', 's', 
 't', 'e', 'r', '.', 'v', '3', '.', 'C', 'l', 'u', 's', 't', 'e', 'r', '.', 'T', 'r', 'a', 'n', 's', 'p', 'o', 'r', 't', 'S', 
@@ -147,392 +147,394 @@ static const char descriptor[11266] = {'\n', '%', 'e', 'n', 'v', 'o', 'y', '/',
 'i', 't', '_', 'b', 'y', 't', 'e', 's', '\030', '\005', ' ', '\001', '(', '\013', '2', '\034', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 
 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'U', 'I', 'n', 't', '3', '2', 'V', 'a', 'l', 'u', 'e', 'B', '\007', '\212', '\223', '\267', '*', 
 '\002', '\020', '\001', 'R', '\035', 'p', 'e', 'r', 'C', 'o', 'n', 'n', 'e', 'c', 't', 'i', 'o', 'n', 'B', 'u', 'f', 'f', 'e', 'r', 'L', 
-'i', 'm', 'i', 't', 'B', 'y', 't', 'e', 's', '\022', 'R', '\n', '\t', 'l', 'b', '_', 'p', 'o', 'l', 'i', 'c', 'y', '\030', '\006', ' ', 
+'i', 'm', 'i', 't', 'B', 'y', 't', 'e', 's', '\022', 'P', '\n', '\t', 'l', 'b', '_', 'p', 'o', 'l', 'i', 'c', 'y', '\030', '\006', ' ', 
 '\001', '(', '\016', '2', ')', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'l', 'u', 's', 't', 'e', 
-'r', '.', 'v', '3', '.', 'C', 'l', 'u', 's', 't', 'e', 'r', '.', 'L', 'b', 'P', 'o', 'l', 'i', 'c', 'y', 'B', '\n', '\372', 'B', 
-'\007', '\202', '\001', '\004', '\020', '\001', ' ', '\007', 'R', '\010', 'l', 'b', 'P', 'o', 'l', 'i', 'c', 'y', '\022', 'X', '\n', '\017', 'l', 'o', 'a', 
-'d', '_', 'a', 's', 's', 'i', 'g', 'n', 'm', 'e', 'n', 't', '\030', '!', ' ', '\001', '(', '\013', '2', '/', '.', 'e', 'n', 'v', 'o', 
-'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'e', 'n', 'd', 'p', 'o', 'i', 'n', 't', '.', 'v', '3', '.', 'C', 'l', 'u', 's', 
-'t', 'e', 'r', 'L', 'o', 'a', 'd', 'A', 's', 's', 'i', 'g', 'n', 'm', 'e', 'n', 't', 'R', '\016', 'l', 'o', 'a', 'd', 'A', 's', 
-'s', 'i', 'g', 'n', 'm', 'e', 'n', 't', '\022', 'F', '\n', '\r', 'h', 'e', 'a', 'l', 't', 'h', '_', 'c', 'h', 'e', 'c', 'k', 's', 
-'\030', '\010', ' ', '\003', '(', '\013', '2', '!', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 
-'e', '.', 'v', '3', '.', 'H', 'e', 'a', 'l', 't', 'h', 'C', 'h', 'e', 'c', 'k', 'R', '\014', 'h', 'e', 'a', 'l', 't', 'h', 'C', 
-'h', 'e', 'c', 'k', 's', '\022', 'h', '\n', '\033', 'm', 'a', 'x', '_', 'r', 'e', 'q', 'u', 'e', 's', 't', 's', '_', 'p', 'e', 'r', 
-'_', 'c', 'o', 'n', 'n', 'e', 'c', 't', 'i', 'o', 'n', '\030', '\t', ' ', '\001', '(', '\013', '2', '\034', '.', 'g', 'o', 'o', 'g', 'l', 
-'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'U', 'I', 'n', 't', '3', '2', 'V', 'a', 'l', 'u', 'e', 'B', '\013', '\030', 
-'\001', '\222', '\307', '\206', '\330', '\004', '\003', '3', '.', '0', 'R', '\030', 'm', 'a', 'x', 'R', 'e', 'q', 'u', 'e', 's', 't', 's', 'P', 'e', 
-'r', 'C', 'o', 'n', 'n', 'e', 'c', 't', 'i', 'o', 'n', '\022', 'S', '\n', '\020', 'c', 'i', 'r', 'c', 'u', 'i', 't', '_', 'b', 'r', 
-'e', 'a', 'k', 'e', 'r', 's', '\030', '\n', ' ', '\001', '(', '\013', '2', '(', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 
-'i', 'g', '.', 'c', 'l', 'u', 's', 't', 'e', 'r', '.', 'v', '3', '.', 'C', 'i', 'r', 'c', 'u', 'i', 't', 'B', 'r', 'e', 'a', 
-'k', 'e', 'r', 's', 'R', '\017', 'c', 'i', 'r', 'c', 'u', 'i', 't', 'B', 'r', 'e', 'a', 'k', 'e', 'r', 's', '\022', '\203', '\001', '\n', 
-'\036', 'u', 'p', 's', 't', 'r', 'e', 'a', 'm', '_', 'h', 't', 't', 'p', '_', 'p', 'r', 'o', 't', 'o', 'c', 'o', 'l', '_', 'o', 
-'p', 't', 'i', 'o', 'n', 's', '\030', '.', ' ', '\001', '(', '\013', '2', '1', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 
-'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'U', 'p', 's', 't', 'r', 'e', 'a', 'm', 'H', 't', 't', 'p', 'P', 'r', 
-'o', 't', 'o', 'c', 'o', 'l', 'O', 'p', 't', 'i', 'o', 'n', 's', 'B', '\013', '\030', '\001', '\222', '\307', '\206', '\330', '\004', '\003', '3', '.', 
-'0', 'R', '\033', 'u', 'p', 's', 't', 'r', 'e', 'a', 'm', 'H', 't', 't', 'p', 'P', 'r', 'o', 't', 'o', 'c', 'o', 'l', 'O', 'p', 
-'t', 'i', 'o', 'n', 's', '\022', 'w', '\n', '\034', 'c', 'o', 'm', 'm', 'o', 'n', '_', 'h', 't', 't', 'p', '_', 'p', 'r', 'o', 't', 
-'o', 'c', 'o', 'l', '_', 'o', 'p', 't', 'i', 'o', 'n', 's', '\030', '\035', ' ', '\001', '(', '\013', '2', ')', '.', 'e', 'n', 'v', 'o', 
-'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'H', 't', 't', 'p', 'P', 'r', 'o', 't', 
+'r', '.', 'v', '3', '.', 'C', 'l', 'u', 's', 't', 'e', 'r', '.', 'L', 'b', 'P', 'o', 'l', 'i', 'c', 'y', 'B', '\010', '\372', 'B', 
+'\005', '\202', '\001', '\002', '\020', '\001', 'R', '\010', 'l', 'b', 'P', 'o', 'l', 'i', 'c', 'y', '\022', 'X', '\n', '\017', 'l', 'o', 'a', 'd', '_', 
+'a', 's', 's', 'i', 'g', 'n', 'm', 'e', 'n', 't', '\030', '!', ' ', '\001', '(', '\013', '2', '/', '.', 'e', 'n', 'v', 'o', 'y', '.', 
+'c', 'o', 'n', 'f', 'i', 'g', '.', 'e', 'n', 'd', 'p', 'o', 'i', 'n', 't', '.', 'v', '3', '.', 'C', 'l', 'u', 's', 't', 'e', 
+'r', 'L', 'o', 'a', 'd', 'A', 's', 's', 'i', 'g', 'n', 'm', 'e', 'n', 't', 'R', '\016', 'l', 'o', 'a', 'd', 'A', 's', 's', 'i', 
+'g', 'n', 'm', 'e', 'n', 't', '\022', 'F', '\n', '\r', 'h', 'e', 'a', 'l', 't', 'h', '_', 'c', 'h', 'e', 'c', 'k', 's', '\030', '\010', 
+' ', '\003', '(', '\013', '2', '!', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 
+'v', '3', '.', 'H', 'e', 'a', 'l', 't', 'h', 'C', 'h', 'e', 'c', 'k', 'R', '\014', 'h', 'e', 'a', 'l', 't', 'h', 'C', 'h', 'e', 
+'c', 'k', 's', '\022', 'h', '\n', '\033', 'm', 'a', 'x', '_', 'r', 'e', 'q', 'u', 'e', 's', 't', 's', '_', 'p', 'e', 'r', '_', 'c', 
+'o', 'n', 'n', 'e', 'c', 't', 'i', 'o', 'n', '\030', '\t', ' ', '\001', '(', '\013', '2', '\034', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 
+'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'U', 'I', 'n', 't', '3', '2', 'V', 'a', 'l', 'u', 'e', 'B', '\013', '\030', '\001', '\222', 
+'\307', '\206', '\330', '\004', '\003', '3', '.', '0', 'R', '\030', 'm', 'a', 'x', 'R', 'e', 'q', 'u', 'e', 's', 't', 's', 'P', 'e', 'r', 'C', 
+'o', 'n', 'n', 'e', 'c', 't', 'i', 'o', 'n', '\022', 'S', '\n', '\020', 'c', 'i', 'r', 'c', 'u', 'i', 't', '_', 'b', 'r', 'e', 'a', 
+'k', 'e', 'r', 's', '\030', '\n', ' ', '\001', '(', '\013', '2', '(', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', 
+'.', 'c', 'l', 'u', 's', 't', 'e', 'r', '.', 'v', '3', '.', 'C', 'i', 'r', 'c', 'u', 'i', 't', 'B', 'r', 'e', 'a', 'k', 'e', 
+'r', 's', 'R', '\017', 'c', 'i', 'r', 'c', 'u', 'i', 't', 'B', 'r', 'e', 'a', 'k', 'e', 'r', 's', '\022', '\203', '\001', '\n', '\036', 'u', 
+'p', 's', 't', 'r', 'e', 'a', 'm', '_', 'h', 't', 't', 'p', '_', 'p', 'r', 'o', 't', 'o', 'c', 'o', 'l', '_', 'o', 'p', 't', 
+'i', 'o', 'n', 's', '\030', '.', ' ', '\001', '(', '\013', '2', '1', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', 
+'.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'U', 'p', 's', 't', 'r', 'e', 'a', 'm', 'H', 't', 't', 'p', 'P', 'r', 'o', 't', 
 'o', 'c', 'o', 'l', 'O', 'p', 't', 'i', 'o', 'n', 's', 'B', '\013', '\030', '\001', '\222', '\307', '\206', '\330', '\004', '\003', '3', '.', '0', 'R', 
-'\031', 'c', 'o', 'm', 'm', 'o', 'n', 'H', 't', 't', 'p', 'P', 'r', 'o', 't', 'o', 'c', 'o', 'l', 'O', 'p', 't', 'i', 'o', 'n', 
-'s', '\022', 'k', '\n', '\025', 'h', 't', 't', 'p', '_', 'p', 'r', 'o', 't', 'o', 'c', 'o', 'l', '_', 'o', 'p', 't', 'i', 'o', 'n', 
-'s', '\030', '\r', ' ', '\001', '(', '\013', '2', '*', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 
-'r', 'e', '.', 'v', '3', '.', 'H', 't', 't', 'p', '1', 'P', 'r', 'o', 't', 'o', 'c', 'o', 'l', 'O', 'p', 't', 'i', 'o', 'n', 
-'s', 'B', '\013', '\030', '\001', '\222', '\307', '\206', '\330', '\004', '\003', '3', '.', '0', 'R', '\023', 'h', 't', 't', 'p', 'P', 'r', 'o', 't', 'o', 
-'c', 'o', 'l', 'O', 'p', 't', 'i', 'o', 'n', 's', '\022', 't', '\n', '\026', 'h', 't', 't', 'p', '2', '_', 'p', 'r', 'o', 't', 'o', 
-'c', 'o', 'l', '_', 'o', 'p', 't', 'i', 'o', 'n', 's', '\030', '\016', ' ', '\001', '(', '\013', '2', '*', '.', 'e', 'n', 'v', 'o', 'y', 
-'.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'H', 't', 't', 'p', '2', 'P', 'r', 'o', 't', 
-'o', 'c', 'o', 'l', 'O', 'p', 't', 'i', 'o', 'n', 's', 'B', '\022', '\030', '\001', '\212', '\223', '\267', '*', '\002', '\020', '\001', '\222', '\307', '\206', 
-'\330', '\004', '\003', '3', '.', '0', 'R', '\024', 'h', 't', 't', 'p', '2', 'P', 'r', 'o', 't', 'o', 'c', 'o', 'l', 'O', 'p', 't', 'i', 
-'o', 'n', 's', '\022', '\214', '\001', '\n', ' ', 't', 'y', 'p', 'e', 'd', '_', 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', '_', 'p', 
-'r', 'o', 't', 'o', 'c', 'o', 'l', '_', 'o', 'p', 't', 'i', 'o', 'n', 's', '\030', '$', ' ', '\003', '(', '\013', '2', 'C', '.', 'e', 
-'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'l', 'u', 's', 't', 'e', 'r', '.', 'v', '3', '.', 'C', 'l', 
-'u', 's', 't', 'e', 'r', '.', 'T', 'y', 'p', 'e', 'd', 'E', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 'P', 'r', 'o', 't', 'o', 
-'c', 'o', 'l', 'O', 'p', 't', 'i', 'o', 'n', 's', 'E', 'n', 't', 'r', 'y', 'R', '\035', 't', 'y', 'p', 'e', 'd', 'E', 'x', 't', 
-'e', 'n', 's', 'i', 'o', 'n', 'P', 'r', 'o', 't', 'o', 'c', 'o', 'l', 'O', 'p', 't', 'i', 'o', 'n', 's', '\022', 'Q', '\n', '\020', 
-'d', 'n', 's', '_', 'r', 'e', 'f', 'r', 'e', 's', 'h', '_', 'r', 'a', 't', 'e', '\030', '\020', ' ', '\001', '(', '\013', '2', '\031', '.', 
-'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'D', 'u', 'r', 'a', 't', 'i', 'o', 'n', 'B', 
-'\014', '\372', 'B', '\t', '\252', '\001', '\006', '*', '\004', '\020', '\300', '\204', '=', 'R', '\016', 'd', 'n', 's', 'R', 'e', 'f', 'r', 'e', 's', 'h', 
-'R', 'a', 't', 'e', '\022', 'e', '\n', '\030', 'd', 'n', 's', '_', 'f', 'a', 'i', 'l', 'u', 'r', 'e', '_', 'r', 'e', 'f', 'r', 'e', 
-'s', 'h', '_', 'r', 'a', 't', 'e', '\030', ',', ' ', '\001', '(', '\013', '2', ',', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 
-'f', 'i', 'g', '.', 'c', 'l', 'u', 's', 't', 'e', 'r', '.', 'v', '3', '.', 'C', 'l', 'u', 's', 't', 'e', 'r', '.', 'R', 'e', 
-'f', 'r', 'e', 's', 'h', 'R', 'a', 't', 'e', 'R', '\025', 'd', 'n', 's', 'F', 'a', 'i', 'l', 'u', 'r', 'e', 'R', 'e', 'f', 'r', 
-'e', 's', 'h', 'R', 'a', 't', 'e', '\022', '&', '\n', '\017', 'r', 'e', 's', 'p', 'e', 'c', 't', '_', 'd', 'n', 's', '_', 't', 't', 
-'l', '\030', '\'', ' ', '\001', '(', '\010', 'R', '\r', 'r', 'e', 's', 'p', 'e', 'c', 't', 'D', 'n', 's', 'T', 't', 'l', '\022', 'f', '\n', 
-'\021', 'd', 'n', 's', '_', 'l', 'o', 'o', 'k', 'u', 'p', '_', 'f', 'a', 'm', 'i', 'l', 'y', '\030', '\021', ' ', '\001', '(', '\016', '2', 
-'0', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'l', 'u', 's', 't', 'e', 'r', '.', 'v', '3', 
-'.', 'C', 'l', 'u', 's', 't', 'e', 'r', '.', 'D', 'n', 's', 'L', 'o', 'o', 'k', 'u', 'p', 'F', 'a', 'm', 'i', 'l', 'y', 'B', 
-'\010', '\372', 'B', '\005', '\202', '\001', '\002', '\020', '\001', 'R', '\017', 'd', 'n', 's', 'L', 'o', 'o', 'k', 'u', 'p', 'F', 'a', 'm', 'i', 'l', 
-'y', '\022', 'O', '\n', '\r', 'd', 'n', 's', '_', 'r', 'e', 's', 'o', 'l', 'v', 'e', 'r', 's', '\030', '\022', ' ', '\003', '(', '\013', '2', 
-'\035', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'A', 'd', 
-'d', 'r', 'e', 's', 's', 'B', '\013', '\030', '\001', '\222', '\307', '\206', '\330', '\004', '\003', '3', '.', '0', 'R', '\014', 'd', 'n', 's', 'R', 'e', 
-'s', 'o', 'l', 'v', 'e', 'r', 's', '\022', 'A', '\n', '\027', 'u', 's', 'e', '_', 't', 'c', 'p', '_', 'f', 'o', 'r', '_', 'd', 'n', 
-'s', '_', 'l', 'o', 'o', 'k', 'u', 'p', 's', '\030', '-', ' ', '\001', '(', '\010', 'B', '\013', '\030', '\001', '\222', '\307', '\206', '\330', '\004', '\003', 
-'3', '.', '0', 'R', '\023', 'u', 's', 'e', 'T', 'c', 'p', 'F', 'o', 'r', 'D', 'n', 's', 'L', 'o', 'o', 'k', 'u', 'p', 's', '\022', 
-']', '\n', '\025', 'd', 'n', 's', '_', 'r', 'e', 's', 'o', 'l', 'u', 't', 'i', 'o', 'n', '_', 'c', 'o', 'n', 'f', 'i', 'g', '\030', 
-'5', ' ', '\001', '(', '\013', '2', ')', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', 
-'.', 'v', '3', '.', 'D', 'n', 's', 'R', 'e', 's', 'o', 'l', 'u', 't', 'i', 'o', 'n', 'C', 'o', 'n', 'f', 'i', 'g', 'R', '\023', 
-'d', 'n', 's', 'R', 'e', 's', 'o', 'l', 'u', 't', 'i', 'o', 'n', 'C', 'o', 'n', 'f', 'i', 'g', '\022', 'e', '\n', '\031', 't', 'y', 
-'p', 'e', 'd', '_', 'd', 'n', 's', '_', 'r', 'e', 's', 'o', 'l', 'v', 'e', 'r', '_', 'c', 'o', 'n', 'f', 'i', 'g', '\030', '7', 
-' ', '\001', '(', '\013', '2', '*', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 
-'v', '3', '.', 'T', 'y', 'p', 'e', 'd', 'E', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 'C', 'o', 'n', 'f', 'i', 'g', 'R', '\026', 
-'t', 'y', 'p', 'e', 'd', 'D', 'n', 's', 'R', 'e', 's', 'o', 'l', 'v', 'e', 'r', 'C', 'o', 'n', 'f', 'i', 'g', '\022', 'L', '\n', 
-'\025', 'w', 'a', 'i', 't', '_', 'f', 'o', 'r', '_', 'w', 'a', 'r', 'm', '_', 'o', 'n', '_', 'i', 'n', 'i', 't', '\030', '6', ' ', 
-'\001', '(', '\013', '2', '\032', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'B', 'o', 'o', 
-'l', 'V', 'a', 'l', 'u', 'e', 'R', '\021', 'w', 'a', 'i', 't', 'F', 'o', 'r', 'W', 'a', 'r', 'm', 'O', 'n', 'I', 'n', 'i', 't', 
-'\022', 'V', '\n', '\021', 'o', 'u', 't', 'l', 'i', 'e', 'r', '_', 'd', 'e', 't', 'e', 'c', 't', 'i', 'o', 'n', '\030', '\023', ' ', '\001', 
-'(', '\013', '2', ')', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'l', 'u', 's', 't', 'e', 'r', 
-'.', 'v', '3', '.', 'O', 'u', 't', 'l', 'i', 'e', 'r', 'D', 'e', 't', 'e', 'c', 't', 'i', 'o', 'n', 'R', '\020', 'o', 'u', 't', 
-'l', 'i', 'e', 'r', 'D', 'e', 't', 'e', 'c', 't', 'i', 'o', 'n', '\022', 'N', '\n', '\020', 'c', 'l', 'e', 'a', 'n', 'u', 'p', '_', 
-'i', 'n', 't', 'e', 'r', 'v', 'a', 'l', '\030', '\024', ' ', '\001', '(', '\013', '2', '\031', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 
-'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'D', 'u', 'r', 'a', 't', 'i', 'o', 'n', 'B', '\010', '\372', 'B', '\005', '\252', '\001', '\002', '*', 
-'\000', 'R', '\017', 'c', 'l', 'e', 'a', 'n', 'u', 'p', 'I', 'n', 't', 'e', 'r', 'v', 'a', 'l', '\022', 'R', '\n', '\024', 'u', 'p', 's', 
-'t', 'r', 'e', 'a', 'm', '_', 'b', 'i', 'n', 'd', '_', 'c', 'o', 'n', 'f', 'i', 'g', '\030', '\025', ' ', '\001', '(', '\013', '2', ' ', 
-'.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'B', 'i', 'n', 
-'d', 'C', 'o', 'n', 'f', 'i', 'g', 'R', '\022', 'u', 'p', 's', 't', 'r', 'e', 'a', 'm', 'B', 'i', 'n', 'd', 'C', 'o', 'n', 'f', 
-'i', 'g', '\022', 'Y', '\n', '\020', 'l', 'b', '_', 's', 'u', 'b', 's', 'e', 't', '_', 'c', 'o', 'n', 'f', 'i', 'g', '\030', '\026', ' ', 
-'\001', '(', '\013', '2', '/', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'l', 'u', 's', 't', 'e', 
-'r', '.', 'v', '3', '.', 'C', 'l', 'u', 's', 't', 'e', 'r', '.', 'L', 'b', 'S', 'u', 'b', 's', 'e', 't', 'C', 'o', 'n', 'f', 
-'i', 'g', 'R', '\016', 'l', 'b', 'S', 'u', 'b', 's', 'e', 't', 'C', 'o', 'n', 'f', 'i', 'g', '\022', 'b', '\n', '\023', 'r', 'i', 'n', 
-'g', '_', 'h', 'a', 's', 'h', '_', 'l', 'b', '_', 'c', 'o', 'n', 'f', 'i', 'g', '\030', '\027', ' ', '\001', '(', '\013', '2', '1', '.', 
+'\033', 'u', 'p', 's', 't', 'r', 'e', 'a', 'm', 'H', 't', 't', 'p', 'P', 'r', 'o', 't', 'o', 'c', 'o', 'l', 'O', 'p', 't', 'i', 
+'o', 'n', 's', '\022', 'w', '\n', '\034', 'c', 'o', 'm', 'm', 'o', 'n', '_', 'h', 't', 't', 'p', '_', 'p', 'r', 'o', 't', 'o', 'c', 
+'o', 'l', '_', 'o', 'p', 't', 'i', 'o', 'n', 's', '\030', '\035', ' ', '\001', '(', '\013', '2', ')', '.', 'e', 'n', 'v', 'o', 'y', '.', 
+'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'H', 't', 't', 'p', 'P', 'r', 'o', 't', 'o', 'c', 
+'o', 'l', 'O', 'p', 't', 'i', 'o', 'n', 's', 'B', '\013', '\030', '\001', '\222', '\307', '\206', '\330', '\004', '\003', '3', '.', '0', 'R', '\031', 'c', 
+'o', 'm', 'm', 'o', 'n', 'H', 't', 't', 'p', 'P', 'r', 'o', 't', 'o', 'c', 'o', 'l', 'O', 'p', 't', 'i', 'o', 'n', 's', '\022', 
+'k', '\n', '\025', 'h', 't', 't', 'p', '_', 'p', 'r', 'o', 't', 'o', 'c', 'o', 'l', '_', 'o', 'p', 't', 'i', 'o', 'n', 's', '\030', 
+'\r', ' ', '\001', '(', '\013', '2', '*', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', 
+'.', 'v', '3', '.', 'H', 't', 't', 'p', '1', 'P', 'r', 'o', 't', 'o', 'c', 'o', 'l', 'O', 'p', 't', 'i', 'o', 'n', 's', 'B', 
+'\013', '\030', '\001', '\222', '\307', '\206', '\330', '\004', '\003', '3', '.', '0', 'R', '\023', 'h', 't', 't', 'p', 'P', 'r', 'o', 't', 'o', 'c', 'o', 
+'l', 'O', 'p', 't', 'i', 'o', 'n', 's', '\022', 't', '\n', '\026', 'h', 't', 't', 'p', '2', '_', 'p', 'r', 'o', 't', 'o', 'c', 'o', 
+'l', '_', 'o', 'p', 't', 'i', 'o', 'n', 's', '\030', '\016', ' ', '\001', '(', '\013', '2', '*', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 
+'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'H', 't', 't', 'p', '2', 'P', 'r', 'o', 't', 'o', 'c', 
+'o', 'l', 'O', 'p', 't', 'i', 'o', 'n', 's', 'B', '\022', '\030', '\001', '\212', '\223', '\267', '*', '\002', '\020', '\001', '\222', '\307', '\206', '\330', '\004', 
+'\003', '3', '.', '0', 'R', '\024', 'h', 't', 't', 'p', '2', 'P', 'r', 'o', 't', 'o', 'c', 'o', 'l', 'O', 'p', 't', 'i', 'o', 'n', 
+'s', '\022', '\214', '\001', '\n', ' ', 't', 'y', 'p', 'e', 'd', '_', 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', '_', 'p', 'r', 'o', 
+'t', 'o', 'c', 'o', 'l', '_', 'o', 'p', 't', 'i', 'o', 'n', 's', '\030', '$', ' ', '\003', '(', '\013', '2', 'C', '.', 'e', 'n', 'v', 
+'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'l', 'u', 's', 't', 'e', 'r', '.', 'v', '3', '.', 'C', 'l', 'u', 's', 
+'t', 'e', 'r', '.', 'T', 'y', 'p', 'e', 'd', 'E', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 'P', 'r', 'o', 't', 'o', 'c', 'o', 
+'l', 'O', 'p', 't', 'i', 'o', 'n', 's', 'E', 'n', 't', 'r', 'y', 'R', '\035', 't', 'y', 'p', 'e', 'd', 'E', 'x', 't', 'e', 'n', 
+'s', 'i', 'o', 'n', 'P', 'r', 'o', 't', 'o', 'c', 'o', 'l', 'O', 'p', 't', 'i', 'o', 'n', 's', '\022', 'Q', '\n', '\020', 'd', 'n', 
+'s', '_', 'r', 'e', 'f', 'r', 'e', 's', 'h', '_', 'r', 'a', 't', 'e', '\030', '\020', ' ', '\001', '(', '\013', '2', '\031', '.', 'g', 'o', 
+'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'D', 'u', 'r', 'a', 't', 'i', 'o', 'n', 'B', '\014', '\372', 
+'B', '\t', '\252', '\001', '\006', '*', '\004', '\020', '\300', '\204', '=', 'R', '\016', 'd', 'n', 's', 'R', 'e', 'f', 'r', 'e', 's', 'h', 'R', 'a', 
+'t', 'e', '\022', 'e', '\n', '\030', 'd', 'n', 's', '_', 'f', 'a', 'i', 'l', 'u', 'r', 'e', '_', 'r', 'e', 'f', 'r', 'e', 's', 'h', 
+'_', 'r', 'a', 't', 'e', '\030', ',', ' ', '\001', '(', '\013', '2', ',', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 
+'g', '.', 'c', 'l', 'u', 's', 't', 'e', 'r', '.', 'v', '3', '.', 'C', 'l', 'u', 's', 't', 'e', 'r', '.', 'R', 'e', 'f', 'r', 
+'e', 's', 'h', 'R', 'a', 't', 'e', 'R', '\025', 'd', 'n', 's', 'F', 'a', 'i', 'l', 'u', 'r', 'e', 'R', 'e', 'f', 'r', 'e', 's', 
+'h', 'R', 'a', 't', 'e', '\022', '&', '\n', '\017', 'r', 'e', 's', 'p', 'e', 'c', 't', '_', 'd', 'n', 's', '_', 't', 't', 'l', '\030', 
+'\'', ' ', '\001', '(', '\010', 'R', '\r', 'r', 'e', 's', 'p', 'e', 'c', 't', 'D', 'n', 's', 'T', 't', 'l', '\022', 'f', '\n', '\021', 'd', 
+'n', 's', '_', 'l', 'o', 'o', 'k', 'u', 'p', '_', 'f', 'a', 'm', 'i', 'l', 'y', '\030', '\021', ' ', '\001', '(', '\016', '2', '0', '.', 
 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'l', 'u', 's', 't', 'e', 'r', '.', 'v', '3', '.', 'C', 
-'l', 'u', 's', 't', 'e', 'r', '.', 'R', 'i', 'n', 'g', 'H', 'a', 's', 'h', 'L', 'b', 'C', 'o', 'n', 'f', 'i', 'g', 'H', '\001', 
-'R', '\020', 'r', 'i', 'n', 'g', 'H', 'a', 's', 'h', 'L', 'b', 'C', 'o', 'n', 'f', 'i', 'g', '\022', '[', '\n', '\020', 'm', 'a', 'g', 
-'l', 'e', 'v', '_', 'l', 'b', '_', 'c', 'o', 'n', 'f', 'i', 'g', '\030', '4', ' ', '\001', '(', '\013', '2', '/', '.', 'e', 'n', 'v', 
+'l', 'u', 's', 't', 'e', 'r', '.', 'D', 'n', 's', 'L', 'o', 'o', 'k', 'u', 'p', 'F', 'a', 'm', 'i', 'l', 'y', 'B', '\010', '\372', 
+'B', '\005', '\202', '\001', '\002', '\020', '\001', 'R', '\017', 'd', 'n', 's', 'L', 'o', 'o', 'k', 'u', 'p', 'F', 'a', 'm', 'i', 'l', 'y', '\022', 
+'O', '\n', '\r', 'd', 'n', 's', '_', 'r', 'e', 's', 'o', 'l', 'v', 'e', 'r', 's', '\030', '\022', ' ', '\003', '(', '\013', '2', '\035', '.', 
+'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'A', 'd', 'd', 'r', 
+'e', 's', 's', 'B', '\013', '\030', '\001', '\222', '\307', '\206', '\330', '\004', '\003', '3', '.', '0', 'R', '\014', 'd', 'n', 's', 'R', 'e', 's', 'o', 
+'l', 'v', 'e', 'r', 's', '\022', 'A', '\n', '\027', 'u', 's', 'e', '_', 't', 'c', 'p', '_', 'f', 'o', 'r', '_', 'd', 'n', 's', '_', 
+'l', 'o', 'o', 'k', 'u', 'p', 's', '\030', '-', ' ', '\001', '(', '\010', 'B', '\013', '\030', '\001', '\222', '\307', '\206', '\330', '\004', '\003', '3', '.', 
+'0', 'R', '\023', 'u', 's', 'e', 'T', 'c', 'p', 'F', 'o', 'r', 'D', 'n', 's', 'L', 'o', 'o', 'k', 'u', 'p', 's', '\022', ']', '\n', 
+'\025', 'd', 'n', 's', '_', 'r', 'e', 's', 'o', 'l', 'u', 't', 'i', 'o', 'n', '_', 'c', 'o', 'n', 'f', 'i', 'g', '\030', '5', ' ', 
+'\001', '(', '\013', '2', ')', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', 
+'3', '.', 'D', 'n', 's', 'R', 'e', 's', 'o', 'l', 'u', 't', 'i', 'o', 'n', 'C', 'o', 'n', 'f', 'i', 'g', 'R', '\023', 'd', 'n', 
+'s', 'R', 'e', 's', 'o', 'l', 'u', 't', 'i', 'o', 'n', 'C', 'o', 'n', 'f', 'i', 'g', '\022', 'e', '\n', '\031', 't', 'y', 'p', 'e', 
+'d', '_', 'd', 'n', 's', '_', 'r', 'e', 's', 'o', 'l', 'v', 'e', 'r', '_', 'c', 'o', 'n', 'f', 'i', 'g', '\030', '7', ' ', '\001', 
+'(', '\013', '2', '*', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', 
+'.', 'T', 'y', 'p', 'e', 'd', 'E', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 'C', 'o', 'n', 'f', 'i', 'g', 'R', '\026', 't', 'y', 
+'p', 'e', 'd', 'D', 'n', 's', 'R', 'e', 's', 'o', 'l', 'v', 'e', 'r', 'C', 'o', 'n', 'f', 'i', 'g', '\022', 'L', '\n', '\025', 'w', 
+'a', 'i', 't', '_', 'f', 'o', 'r', '_', 'w', 'a', 'r', 'm', '_', 'o', 'n', '_', 'i', 'n', 'i', 't', '\030', '6', ' ', '\001', '(', 
+'\013', '2', '\032', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'B', 'o', 'o', 'l', 'V', 
+'a', 'l', 'u', 'e', 'R', '\021', 'w', 'a', 'i', 't', 'F', 'o', 'r', 'W', 'a', 'r', 'm', 'O', 'n', 'I', 'n', 'i', 't', '\022', 'V', 
+'\n', '\021', 'o', 'u', 't', 'l', 'i', 'e', 'r', '_', 'd', 'e', 't', 'e', 'c', 't', 'i', 'o', 'n', '\030', '\023', ' ', '\001', '(', '\013', 
+'2', ')', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'l', 'u', 's', 't', 'e', 'r', '.', 'v', 
+'3', '.', 'O', 'u', 't', 'l', 'i', 'e', 'r', 'D', 'e', 't', 'e', 'c', 't', 'i', 'o', 'n', 'R', '\020', 'o', 'u', 't', 'l', 'i', 
+'e', 'r', 'D', 'e', 't', 'e', 'c', 't', 'i', 'o', 'n', '\022', 'N', '\n', '\020', 'c', 'l', 'e', 'a', 'n', 'u', 'p', '_', 'i', 'n', 
+'t', 'e', 'r', 'v', 'a', 'l', '\030', '\024', ' ', '\001', '(', '\013', '2', '\031', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 
+'t', 'o', 'b', 'u', 'f', '.', 'D', 'u', 'r', 'a', 't', 'i', 'o', 'n', 'B', '\010', '\372', 'B', '\005', '\252', '\001', '\002', '*', '\000', 'R', 
+'\017', 'c', 'l', 'e', 'a', 'n', 'u', 'p', 'I', 'n', 't', 'e', 'r', 'v', 'a', 'l', '\022', 'R', '\n', '\024', 'u', 'p', 's', 't', 'r', 
+'e', 'a', 'm', '_', 'b', 'i', 'n', 'd', '_', 'c', 'o', 'n', 'f', 'i', 'g', '\030', '\025', ' ', '\001', '(', '\013', '2', ' ', '.', 'e', 
+'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'B', 'i', 'n', 'd', 'C', 
+'o', 'n', 'f', 'i', 'g', 'R', '\022', 'u', 'p', 's', 't', 'r', 'e', 'a', 'm', 'B', 'i', 'n', 'd', 'C', 'o', 'n', 'f', 'i', 'g', 
+'\022', 'Y', '\n', '\020', 'l', 'b', '_', 's', 'u', 'b', 's', 'e', 't', '_', 'c', 'o', 'n', 'f', 'i', 'g', '\030', '\026', ' ', '\001', '(', 
+'\013', '2', '/', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'l', 'u', 's', 't', 'e', 'r', '.', 
+'v', '3', '.', 'C', 'l', 'u', 's', 't', 'e', 'r', '.', 'L', 'b', 'S', 'u', 'b', 's', 'e', 't', 'C', 'o', 'n', 'f', 'i', 'g', 
+'R', '\016', 'l', 'b', 'S', 'u', 'b', 's', 'e', 't', 'C', 'o', 'n', 'f', 'i', 'g', '\022', 'b', '\n', '\023', 'r', 'i', 'n', 'g', '_', 
+'h', 'a', 's', 'h', '_', 'l', 'b', '_', 'c', 'o', 'n', 'f', 'i', 'g', '\030', '\027', ' ', '\001', '(', '\013', '2', '1', '.', 'e', 'n', 
+'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'l', 'u', 's', 't', 'e', 'r', '.', 'v', '3', '.', 'C', 'l', 'u', 
+'s', 't', 'e', 'r', '.', 'R', 'i', 'n', 'g', 'H', 'a', 's', 'h', 'L', 'b', 'C', 'o', 'n', 'f', 'i', 'g', 'H', '\001', 'R', '\020', 
+'r', 'i', 'n', 'g', 'H', 'a', 's', 'h', 'L', 'b', 'C', 'o', 'n', 'f', 'i', 'g', '\022', '[', '\n', '\020', 'm', 'a', 'g', 'l', 'e', 
+'v', '_', 'l', 'b', '_', 'c', 'o', 'n', 'f', 'i', 'g', '\030', '4', ' ', '\001', '(', '\013', '2', '/', '.', 'e', 'n', 'v', 'o', 'y', 
+'.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'l', 'u', 's', 't', 'e', 'r', '.', 'v', '3', '.', 'C', 'l', 'u', 's', 't', 'e', 
+'r', '.', 'M', 'a', 'g', 'l', 'e', 'v', 'L', 'b', 'C', 'o', 'n', 'f', 'i', 'g', 'H', '\001', 'R', '\016', 'm', 'a', 'g', 'l', 'e', 
+'v', 'L', 'b', 'C', 'o', 'n', 'f', 'i', 'g', '\022', 'k', '\n', '\026', 'o', 'r', 'i', 'g', 'i', 'n', 'a', 'l', '_', 'd', 's', 't', 
+'_', 'l', 'b', '_', 'c', 'o', 'n', 'f', 'i', 'g', '\030', '\"', ' ', '\001', '(', '\013', '2', '4', '.', 'e', 'n', 'v', 'o', 'y', '.', 
+'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'l', 'u', 's', 't', 'e', 'r', '.', 'v', '3', '.', 'C', 'l', 'u', 's', 't', 'e', 'r', 
+'.', 'O', 'r', 'i', 'g', 'i', 'n', 'a', 'l', 'D', 's', 't', 'L', 'b', 'C', 'o', 'n', 'f', 'i', 'g', 'H', '\001', 'R', '\023', 'o', 
+'r', 'i', 'g', 'i', 'n', 'a', 'l', 'D', 's', 't', 'L', 'b', 'C', 'o', 'n', 'f', 'i', 'g', '\022', 'n', '\n', '\027', 'l', 'e', 'a', 
+'s', 't', '_', 'r', 'e', 'q', 'u', 'e', 's', 't', '_', 'l', 'b', '_', 'c', 'o', 'n', 'f', 'i', 'g', '\030', '%', ' ', '\001', '(', 
+'\013', '2', '5', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'l', 'u', 's', 't', 'e', 'r', '.', 
+'v', '3', '.', 'C', 'l', 'u', 's', 't', 'e', 'r', '.', 'L', 'e', 'a', 's', 't', 'R', 'e', 'q', 'u', 'e', 's', 't', 'L', 'b', 
+'C', 'o', 'n', 'f', 'i', 'g', 'H', '\001', 'R', '\024', 'l', 'e', 'a', 's', 't', 'R', 'e', 'q', 'u', 'e', 's', 't', 'L', 'b', 'C', 
+'o', 'n', 'f', 'i', 'g', '\022', 'Y', '\n', '\020', 'c', 'o', 'm', 'm', 'o', 'n', '_', 'l', 'b', '_', 'c', 'o', 'n', 'f', 'i', 'g', 
+'\030', '\033', ' ', '\001', '(', '\013', '2', '/', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'l', 'u', 
+'s', 't', 'e', 'r', '.', 'v', '3', '.', 'C', 'l', 'u', 's', 't', 'e', 'r', '.', 'C', 'o', 'm', 'm', 'o', 'n', 'L', 'b', 'C', 
+'o', 'n', 'f', 'i', 'g', 'R', '\016', 'c', 'o', 'm', 'm', 'o', 'n', 'L', 'b', 'C', 'o', 'n', 'f', 'i', 'g', '\022', 'P', '\n', '\020', 
+'t', 'r', 'a', 'n', 's', 'p', 'o', 'r', 't', '_', 's', 'o', 'c', 'k', 'e', 't', '\030', '\030', ' ', '\001', '(', '\013', '2', '%', '.', 
+'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'T', 'r', 'a', 'n', 
+'s', 'p', 'o', 'r', 't', 'S', 'o', 'c', 'k', 'e', 't', 'R', '\017', 't', 'r', 'a', 'n', 's', 'p', 'o', 'r', 't', 'S', 'o', 'c', 
+'k', 'e', 't', '\022', ':', '\n', '\010', 'm', 'e', 't', 'a', 'd', 'a', 't', 'a', '\030', '\031', ' ', '\001', '(', '\013', '2', '\036', '.', 'e', 
+'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'M', 'e', 't', 'a', 'd', 
+'a', 't', 'a', 'R', '\010', 'm', 'e', 't', 'a', 'd', 'a', 't', 'a', '\022', 'u', '\n', '\022', 'p', 'r', 'o', 't', 'o', 'c', 'o', 'l', 
+'_', 's', 'e', 'l', 'e', 'c', 't', 'i', 'o', 'n', '\030', '\032', ' ', '\001', '(', '\016', '2', '9', '.', 'e', 'n', 'v', 'o', 'y', '.', 
+'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'l', 'u', 's', 't', 'e', 'r', '.', 'v', '3', '.', 'C', 'l', 'u', 's', 't', 'e', 'r', 
+'.', 'C', 'l', 'u', 's', 't', 'e', 'r', 'P', 'r', 'o', 't', 'o', 'c', 'o', 'l', 'S', 'e', 'l', 'e', 'c', 't', 'i', 'o', 'n', 
+'B', '\013', '\030', '\001', '\222', '\307', '\206', '\330', '\004', '\003', '3', '.', '0', 'R', '\021', 'p', 'r', 'o', 't', 'o', 'c', 'o', 'l', 'S', 'e', 
+'l', 'e', 'c', 't', 'i', 'o', 'n', '\022', 'r', '\n', '\033', 'u', 'p', 's', 't', 'r', 'e', 'a', 'm', '_', 'c', 'o', 'n', 'n', 'e', 
+'c', 't', 'i', 'o', 'n', '_', 'o', 'p', 't', 'i', 'o', 'n', 's', '\030', '\036', ' ', '\001', '(', '\013', '2', '2', '.', 'e', 'n', 'v', 
+'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'l', 'u', 's', 't', 'e', 'r', '.', 'v', '3', '.', 'U', 'p', 's', 't', 
+'r', 'e', 'a', 'm', 'C', 'o', 'n', 'n', 'e', 'c', 't', 'i', 'o', 'n', 'O', 'p', 't', 'i', 'o', 'n', 's', 'R', '\031', 'u', 'p', 
+'s', 't', 'r', 'e', 'a', 'm', 'C', 'o', 'n', 'n', 'e', 'c', 't', 'i', 'o', 'n', 'O', 'p', 't', 'i', 'o', 'n', 's', '\022', 'U', 
+'\n', '(', 'c', 'l', 'o', 's', 'e', '_', 'c', 'o', 'n', 'n', 'e', 'c', 't', 'i', 'o', 'n', 's', '_', 'o', 'n', '_', 'h', 'o', 
+'s', 't', '_', 'h', 'e', 'a', 'l', 't', 'h', '_', 'f', 'a', 'i', 'l', 'u', 'r', 'e', '\030', '\037', ' ', '\001', '(', '\010', 'R', '#', 
+'c', 'l', 'o', 's', 'e', 'C', 'o', 'n', 'n', 'e', 'c', 't', 'i', 'o', 'n', 's', 'O', 'n', 'H', 'o', 's', 't', 'H', 'e', 'a', 
+'l', 't', 'h', 'F', 'a', 'i', 'l', 'u', 'r', 'e', '\022', '@', '\n', '\035', 'i', 'g', 'n', 'o', 'r', 'e', '_', 'h', 'e', 'a', 'l', 
+'t', 'h', '_', 'o', 'n', '_', 'h', 'o', 's', 't', '_', 'r', 'e', 'm', 'o', 'v', 'a', 'l', '\030', ' ', ' ', '\001', '(', '\010', 'R', 
+'\031', 'i', 'g', 'n', 'o', 'r', 'e', 'H', 'e', 'a', 'l', 't', 'h', 'O', 'n', 'H', 'o', 's', 't', 'R', 'e', 'm', 'o', 'v', 'a', 
+'l', '\022', '9', '\n', '\007', 'f', 'i', 'l', 't', 'e', 'r', 's', '\030', '(', ' ', '\003', '(', '\013', '2', '\037', '.', 'e', 'n', 'v', 'o', 
+'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'l', 'u', 's', 't', 'e', 'r', '.', 'v', '3', '.', 'F', 'i', 'l', 't', 'e', 
+'r', 'R', '\007', 'f', 'i', 'l', 't', 'e', 'r', 's', '\022', '`', '\n', '\025', 'l', 'o', 'a', 'd', '_', 'b', 'a', 'l', 'a', 'n', 'c', 
+'i', 'n', 'g', '_', 'p', 'o', 'l', 'i', 'c', 'y', '\030', ')', ' ', '\001', '(', '\013', '2', ',', '.', 'e', 'n', 'v', 'o', 'y', '.', 
+'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'l', 'u', 's', 't', 'e', 'r', '.', 'v', '3', '.', 'L', 'o', 'a', 'd', 'B', 'a', 'l', 
+'a', 'n', 'c', 'i', 'n', 'g', 'P', 'o', 'l', 'i', 'c', 'y', 'R', '\023', 'l', 'o', 'a', 'd', 'B', 'a', 'l', 'a', 'n', 'c', 'i', 
+'n', 'g', 'P', 'o', 'l', 'i', 'c', 'y', '\022', 'A', '\n', '\n', 'l', 'r', 's', '_', 's', 'e', 'r', 'v', 'e', 'r', '\030', '*', ' ', 
+'\001', '(', '\013', '2', '\"', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', 
+'3', '.', 'C', 'o', 'n', 'f', 'i', 'g', 'S', 'o', 'u', 'r', 'c', 'e', 'R', '\t', 'l', 'r', 's', 'S', 'e', 'r', 'v', 'e', 'r', 
+'\022', '?', '\n', '\025', 't', 'r', 'a', 'c', 'k', '_', 't', 'i', 'm', 'e', 'o', 'u', 't', '_', 'b', 'u', 'd', 'g', 'e', 't', 's', 
+'\030', '/', ' ', '\001', '(', '\010', 'B', '\013', '\030', '\001', '\222', '\307', '\206', '\330', '\004', '\003', '3', '.', '0', 'R', '\023', 't', 'r', 'a', 'c', 
+'k', 'T', 'i', 'm', 'e', 'o', 'u', 't', 'B', 'u', 'd', 'g', 'e', 't', 's', '\022', 'S', '\n', '\017', 'u', 'p', 's', 't', 'r', 'e', 
+'a', 'm', '_', 'c', 'o', 'n', 'f', 'i', 'g', '\030', '0', ' ', '\001', '(', '\013', '2', '*', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 
+'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'T', 'y', 'p', 'e', 'd', 'E', 'x', 't', 'e', 'n', 's', 
+'i', 'o', 'n', 'C', 'o', 'n', 'f', 'i', 'g', 'R', '\016', 'u', 'p', 's', 't', 'r', 'e', 'a', 'm', 'C', 'o', 'n', 'f', 'i', 'g', 
+'\022', 'Z', '\n', '\023', 't', 'r', 'a', 'c', 'k', '_', 'c', 'l', 'u', 's', 't', 'e', 'r', '_', 's', 't', 'a', 't', 's', '\030', '1', 
+' ', '\001', '(', '\013', '2', '*', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'l', 'u', 's', 't', 
+'e', 'r', '.', 'v', '3', '.', 'T', 'r', 'a', 'c', 'k', 'C', 'l', 'u', 's', 't', 'e', 'r', 'S', 't', 'a', 't', 's', 'R', '\021', 
+'t', 'r', 'a', 'c', 'k', 'C', 'l', 'u', 's', 't', 'e', 'r', 'S', 't', 'a', 't', 's', '\022', '^', '\n', '\021', 'p', 'r', 'e', 'c', 
+'o', 'n', 'n', 'e', 'c', 't', '_', 'p', 'o', 'l', 'i', 'c', 'y', '\030', '2', ' ', '\001', '(', '\013', '2', '1', '.', 'e', 'n', 'v', 
 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'l', 'u', 's', 't', 'e', 'r', '.', 'v', '3', '.', 'C', 'l', 'u', 's', 
-'t', 'e', 'r', '.', 'M', 'a', 'g', 'l', 'e', 'v', 'L', 'b', 'C', 'o', 'n', 'f', 'i', 'g', 'H', '\001', 'R', '\016', 'm', 'a', 'g', 
-'l', 'e', 'v', 'L', 'b', 'C', 'o', 'n', 'f', 'i', 'g', '\022', 'k', '\n', '\026', 'o', 'r', 'i', 'g', 'i', 'n', 'a', 'l', '_', 'd', 
-'s', 't', '_', 'l', 'b', '_', 'c', 'o', 'n', 'f', 'i', 'g', '\030', '\"', ' ', '\001', '(', '\013', '2', '4', '.', 'e', 'n', 'v', 'o', 
-'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'l', 'u', 's', 't', 'e', 'r', '.', 'v', '3', '.', 'C', 'l', 'u', 's', 't', 
-'e', 'r', '.', 'O', 'r', 'i', 'g', 'i', 'n', 'a', 'l', 'D', 's', 't', 'L', 'b', 'C', 'o', 'n', 'f', 'i', 'g', 'H', '\001', 'R', 
-'\023', 'o', 'r', 'i', 'g', 'i', 'n', 'a', 'l', 'D', 's', 't', 'L', 'b', 'C', 'o', 'n', 'f', 'i', 'g', '\022', 'n', '\n', '\027', 'l', 
-'e', 'a', 's', 't', '_', 'r', 'e', 'q', 'u', 'e', 's', 't', '_', 'l', 'b', '_', 'c', 'o', 'n', 'f', 'i', 'g', '\030', '%', ' ', 
-'\001', '(', '\013', '2', '5', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'l', 'u', 's', 't', 'e', 
-'r', '.', 'v', '3', '.', 'C', 'l', 'u', 's', 't', 'e', 'r', '.', 'L', 'e', 'a', 's', 't', 'R', 'e', 'q', 'u', 'e', 's', 't', 
-'L', 'b', 'C', 'o', 'n', 'f', 'i', 'g', 'H', '\001', 'R', '\024', 'l', 'e', 'a', 's', 't', 'R', 'e', 'q', 'u', 'e', 's', 't', 'L', 
-'b', 'C', 'o', 'n', 'f', 'i', 'g', '\022', 'Y', '\n', '\020', 'c', 'o', 'm', 'm', 'o', 'n', '_', 'l', 'b', '_', 'c', 'o', 'n', 'f', 
-'i', 'g', '\030', '\033', ' ', '\001', '(', '\013', '2', '/', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 
-'l', 'u', 's', 't', 'e', 'r', '.', 'v', '3', '.', 'C', 'l', 'u', 's', 't', 'e', 'r', '.', 'C', 'o', 'm', 'm', 'o', 'n', 'L', 
-'b', 'C', 'o', 'n', 'f', 'i', 'g', 'R', '\016', 'c', 'o', 'm', 'm', 'o', 'n', 'L', 'b', 'C', 'o', 'n', 'f', 'i', 'g', '\022', 'P', 
-'\n', '\020', 't', 'r', 'a', 'n', 's', 'p', 'o', 'r', 't', '_', 's', 'o', 'c', 'k', 'e', 't', '\030', '\030', ' ', '\001', '(', '\013', '2', 
-'%', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'T', 'r', 
-'a', 'n', 's', 'p', 'o', 'r', 't', 'S', 'o', 'c', 'k', 'e', 't', 'R', '\017', 't', 'r', 'a', 'n', 's', 'p', 'o', 'r', 't', 'S', 
-'o', 'c', 'k', 'e', 't', '\022', ':', '\n', '\010', 'm', 'e', 't', 'a', 'd', 'a', 't', 'a', '\030', '\031', ' ', '\001', '(', '\013', '2', '\036', 
-'.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'M', 'e', 't', 
-'a', 'd', 'a', 't', 'a', 'R', '\010', 'm', 'e', 't', 'a', 'd', 'a', 't', 'a', '\022', 'u', '\n', '\022', 'p', 'r', 'o', 't', 'o', 'c', 
-'o', 'l', '_', 's', 'e', 'l', 'e', 'c', 't', 'i', 'o', 'n', '\030', '\032', ' ', '\001', '(', '\016', '2', '9', '.', 'e', 'n', 'v', 'o', 
-'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'l', 'u', 's', 't', 'e', 'r', '.', 'v', '3', '.', 'C', 'l', 'u', 's', 't', 
-'e', 'r', '.', 'C', 'l', 'u', 's', 't', 'e', 'r', 'P', 'r', 'o', 't', 'o', 'c', 'o', 'l', 'S', 'e', 'l', 'e', 'c', 't', 'i', 
-'o', 'n', 'B', '\013', '\030', '\001', '\222', '\307', '\206', '\330', '\004', '\003', '3', '.', '0', 'R', '\021', 'p', 'r', 'o', 't', 'o', 'c', 'o', 'l', 
-'S', 'e', 'l', 'e', 'c', 't', 'i', 'o', 'n', '\022', 'r', '\n', '\033', 'u', 'p', 's', 't', 'r', 'e', 'a', 'm', '_', 'c', 'o', 'n', 
-'n', 'e', 'c', 't', 'i', 'o', 'n', '_', 'o', 'p', 't', 'i', 'o', 'n', 's', '\030', '\036', ' ', '\001', '(', '\013', '2', '2', '.', 'e', 
-'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'l', 'u', 's', 't', 'e', 'r', '.', 'v', '3', '.', 'U', 'p', 
-'s', 't', 'r', 'e', 'a', 'm', 'C', 'o', 'n', 'n', 'e', 'c', 't', 'i', 'o', 'n', 'O', 'p', 't', 'i', 'o', 'n', 's', 'R', '\031', 
-'u', 'p', 's', 't', 'r', 'e', 'a', 'm', 'C', 'o', 'n', 'n', 'e', 'c', 't', 'i', 'o', 'n', 'O', 'p', 't', 'i', 'o', 'n', 's', 
-'\022', 'U', '\n', '(', 'c', 'l', 'o', 's', 'e', '_', 'c', 'o', 'n', 'n', 'e', 'c', 't', 'i', 'o', 'n', 's', '_', 'o', 'n', '_', 
-'h', 'o', 's', 't', '_', 'h', 'e', 'a', 'l', 't', 'h', '_', 'f', 'a', 'i', 'l', 'u', 'r', 'e', '\030', '\037', ' ', '\001', '(', '\010', 
-'R', '#', 'c', 'l', 'o', 's', 'e', 'C', 'o', 'n', 'n', 'e', 'c', 't', 'i', 'o', 'n', 's', 'O', 'n', 'H', 'o', 's', 't', 'H', 
-'e', 'a', 'l', 't', 'h', 'F', 'a', 'i', 'l', 'u', 'r', 'e', '\022', '@', '\n', '\035', 'i', 'g', 'n', 'o', 'r', 'e', '_', 'h', 'e', 
-'a', 'l', 't', 'h', '_', 'o', 'n', '_', 'h', 'o', 's', 't', '_', 'r', 'e', 'm', 'o', 'v', 'a', 'l', '\030', ' ', ' ', '\001', '(', 
-'\010', 'R', '\031', 'i', 'g', 'n', 'o', 'r', 'e', 'H', 'e', 'a', 'l', 't', 'h', 'O', 'n', 'H', 'o', 's', 't', 'R', 'e', 'm', 'o', 
-'v', 'a', 'l', '\022', '9', '\n', '\007', 'f', 'i', 'l', 't', 'e', 'r', 's', '\030', '(', ' ', '\003', '(', '\013', '2', '\037', '.', 'e', 'n', 
-'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'l', 'u', 's', 't', 'e', 'r', '.', 'v', '3', '.', 'F', 'i', 'l', 
-'t', 'e', 'r', 'R', '\007', 'f', 'i', 'l', 't', 'e', 'r', 's', '\022', '`', '\n', '\025', 'l', 'o', 'a', 'd', '_', 'b', 'a', 'l', 'a', 
-'n', 'c', 'i', 'n', 'g', '_', 'p', 'o', 'l', 'i', 'c', 'y', '\030', ')', ' ', '\001', '(', '\013', '2', ',', '.', 'e', 'n', 'v', 'o', 
-'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'l', 'u', 's', 't', 'e', 'r', '.', 'v', '3', '.', 'L', 'o', 'a', 'd', 'B', 
-'a', 'l', 'a', 'n', 'c', 'i', 'n', 'g', 'P', 'o', 'l', 'i', 'c', 'y', 'R', '\023', 'l', 'o', 'a', 'd', 'B', 'a', 'l', 'a', 'n', 
-'c', 'i', 'n', 'g', 'P', 'o', 'l', 'i', 'c', 'y', '\022', 'A', '\n', '\n', 'l', 'r', 's', '_', 's', 'e', 'r', 'v', 'e', 'r', '\030', 
-'*', ' ', '\001', '(', '\013', '2', '\"', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', 
-'.', 'v', '3', '.', 'C', 'o', 'n', 'f', 'i', 'g', 'S', 'o', 'u', 'r', 'c', 'e', 'R', '\t', 'l', 'r', 's', 'S', 'e', 'r', 'v', 
-'e', 'r', '\022', '?', '\n', '\025', 't', 'r', 'a', 'c', 'k', '_', 't', 'i', 'm', 'e', 'o', 'u', 't', '_', 'b', 'u', 'd', 'g', 'e', 
-'t', 's', '\030', '/', ' ', '\001', '(', '\010', 'B', '\013', '\030', '\001', '\222', '\307', '\206', '\330', '\004', '\003', '3', '.', '0', 'R', '\023', 't', 'r', 
-'a', 'c', 'k', 'T', 'i', 'm', 'e', 'o', 'u', 't', 'B', 'u', 'd', 'g', 'e', 't', 's', '\022', 'S', '\n', '\017', 'u', 'p', 's', 't', 
-'r', 'e', 'a', 'm', '_', 'c', 'o', 'n', 'f', 'i', 'g', '\030', '0', ' ', '\001', '(', '\013', '2', '*', '.', 'e', 'n', 'v', 'o', 'y', 
-'.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'T', 'y', 'p', 'e', 'd', 'E', 'x', 't', 'e', 
-'n', 's', 'i', 'o', 'n', 'C', 'o', 'n', 'f', 'i', 'g', 'R', '\016', 'u', 'p', 's', 't', 'r', 'e', 'a', 'm', 'C', 'o', 'n', 'f', 
-'i', 'g', '\022', 'Z', '\n', '\023', 't', 'r', 'a', 'c', 'k', '_', 'c', 'l', 'u', 's', 't', 'e', 'r', '_', 's', 't', 'a', 't', 's', 
-'\030', '1', ' ', '\001', '(', '\013', '2', '*', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'l', 'u', 
-'s', 't', 'e', 'r', '.', 'v', '3', '.', 'T', 'r', 'a', 'c', 'k', 'C', 'l', 'u', 's', 't', 'e', 'r', 'S', 't', 'a', 't', 's', 
-'R', '\021', 't', 'r', 'a', 'c', 'k', 'C', 'l', 'u', 's', 't', 'e', 'r', 'S', 't', 'a', 't', 's', '\022', '^', '\n', '\021', 'p', 'r', 
-'e', 'c', 'o', 'n', 'n', 'e', 'c', 't', '_', 'p', 'o', 'l', 'i', 'c', 'y', '\030', '2', ' ', '\001', '(', '\013', '2', '1', '.', 'e', 
-'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'l', 'u', 's', 't', 'e', 'r', '.', 'v', '3', '.', 'C', 'l', 
-'u', 's', 't', 'e', 'r', '.', 'P', 'r', 'e', 'c', 'o', 'n', 'n', 'e', 'c', 't', 'P', 'o', 'l', 'i', 'c', 'y', 'R', '\020', 'p', 
-'r', 'e', 'c', 'o', 'n', 'n', 'e', 'c', 't', 'P', 'o', 'l', 'i', 'c', 'y', '\022', 'X', '\n', ')', 'c', 'o', 'n', 'n', 'e', 'c', 
-'t', 'i', 'o', 'n', '_', 'p', 'o', 'o', 'l', '_', 'p', 'e', 'r', '_', 'd', 'o', 'w', 'n', 's', 't', 'r', 'e', 'a', 'm', '_', 
-'c', 'o', 'n', 'n', 'e', 'c', 't', 'i', 'o', 'n', '\030', '3', ' ', '\001', '(', '\010', 'R', '%', 'c', 'o', 'n', 'n', 'e', 'c', 't', 
-'i', 'o', 'n', 'P', 'o', 'o', 'l', 'P', 'e', 'r', 'D', 'o', 'w', 'n', 's', 't', 'r', 'e', 'a', 'm', 'C', 'o', 'n', 'n', 'e', 
-'c', 't', 'i', 'o', 'n', '\032', '\346', '\001', '\n', '\024', 'T', 'r', 'a', 'n', 's', 'p', 'o', 'r', 't', 'S', 'o', 'c', 'k', 'e', 't', 
-'M', 'a', 't', 'c', 'h', '\022', '\033', '\n', '\004', 'n', 'a', 'm', 'e', '\030', '\001', ' ', '\001', '(', '\t', 'B', '\007', '\372', 'B', '\004', 'r', 
-'\002', '\020', '\001', 'R', '\004', 'n', 'a', 'm', 'e', '\022', '-', '\n', '\005', 'm', 'a', 't', 'c', 'h', '\030', '\002', ' ', '\001', '(', '\013', '2', 
-'\027', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'S', 't', 'r', 'u', 'c', 't', 'R', 
-'\005', 'm', 'a', 't', 'c', 'h', '\022', 'P', '\n', '\020', 't', 'r', 'a', 'n', 's', 'p', 'o', 'r', 't', '_', 's', 'o', 'c', 'k', 'e', 
-'t', '\030', '\003', ' ', '\001', '(', '\013', '2', '%', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 
-'r', 'e', '.', 'v', '3', '.', 'T', 'r', 'a', 'n', 's', 'p', 'o', 'r', 't', 'S', 'o', 'c', 'k', 'e', 't', 'R', '\017', 't', 'r', 
-'a', 'n', 's', 'p', 'o', 'r', 't', 'S', 'o', 'c', 'k', 'e', 't', ':', '0', '\232', '\305', '\210', '\036', '+', '\n', ')', 'e', 'n', 'v', 
-'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'C', 'l', 'u', 's', 't', 'e', 'r', '.', 'T', 'r', 'a', 'n', 's', 'p', 'o', 
-'r', 't', 'S', 'o', 'c', 'k', 'e', 't', 'M', 'a', 't', 'c', 'h', '\032', '\230', '\001', '\n', '\021', 'C', 'u', 's', 't', 'o', 'm', 'C', 
-'l', 'u', 's', 't', 'e', 'r', 'T', 'y', 'p', 'e', '\022', '\033', '\n', '\004', 'n', 'a', 'm', 'e', '\030', '\001', ' ', '\001', '(', '\t', 'B', 
-'\007', '\372', 'B', '\004', 'r', '\002', '\020', '\001', 'R', '\004', 'n', 'a', 'm', 'e', '\022', '7', '\n', '\014', 't', 'y', 'p', 'e', 'd', '_', 'c', 
-'o', 'n', 'f', 'i', 'g', '\030', '\002', ' ', '\001', '(', '\013', '2', '\024', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 
-'o', 'b', 'u', 'f', '.', 'A', 'n', 'y', 'R', '\013', 't', 'y', 'p', 'e', 'd', 'C', 'o', 'n', 'f', 'i', 'g', ':', '-', '\232', '\305', 
-'\210', '\036', '(', '\n', '&', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'C', 'l', 'u', 's', 't', 'e', 'r', 
-'.', 'C', 'u', 's', 't', 'o', 'm', 'C', 'l', 'u', 's', 't', 'e', 'r', 'T', 'y', 'p', 'e', '\032', '\246', '\001', '\n', '\020', 'E', 'd', 
-'s', 'C', 'l', 'u', 's', 't', 'e', 'r', 'C', 'o', 'n', 'f', 'i', 'g', '\022', 'A', '\n', '\n', 'e', 'd', 's', '_', 'c', 'o', 'n', 
-'f', 'i', 'g', '\030', '\001', ' ', '\001', '(', '\013', '2', '\"', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 
-'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'C', 'o', 'n', 'f', 'i', 'g', 'S', 'o', 'u', 'r', 'c', 'e', 'R', '\t', 'e', 'd', 's', 
-'C', 'o', 'n', 'f', 'i', 'g', '\022', '!', '\n', '\014', 's', 'e', 'r', 'v', 'i', 'c', 'e', '_', 'n', 'a', 'm', 'e', '\030', '\002', ' ', 
-'\001', '(', '\t', 'R', '\013', 's', 'e', 'r', 'v', 'i', 'c', 'e', 'N', 'a', 'm', 'e', ':', ',', '\232', '\305', '\210', '\036', '\'', '\n', '%', 
-'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'C', 'l', 'u', 's', 't', 'e', 'r', '.', 'E', 'd', 's', 'C', 
-'l', 'u', 's', 't', 'e', 'r', 'C', 'o', 'n', 'f', 'i', 'g', '\032', '\300', '\010', '\n', '\016', 'L', 'b', 'S', 'u', 'b', 's', 'e', 't', 
-'C', 'o', 'n', 'f', 'i', 'g', '\022', 'y', '\n', '\017', 'f', 'a', 'l', 'l', 'b', 'a', 'c', 'k', '_', 'p', 'o', 'l', 'i', 'c', 'y', 
-'\030', '\001', ' ', '\001', '(', '\016', '2', 'F', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'l', 'u', 
-'s', 't', 'e', 'r', '.', 'v', '3', '.', 'C', 'l', 'u', 's', 't', 'e', 'r', '.', 'L', 'b', 'S', 'u', 'b', 's', 'e', 't', 'C', 
-'o', 'n', 'f', 'i', 'g', '.', 'L', 'b', 'S', 'u', 'b', 's', 'e', 't', 'F', 'a', 'l', 'l', 'b', 'a', 'c', 'k', 'P', 'o', 'l', 
-'i', 'c', 'y', 'B', '\010', '\372', 'B', '\005', '\202', '\001', '\002', '\020', '\001', 'R', '\016', 'f', 'a', 'l', 'l', 'b', 'a', 'c', 'k', 'P', 'o', 
-'l', 'i', 'c', 'y', '\022', '>', '\n', '\016', 'd', 'e', 'f', 'a', 'u', 'l', 't', '_', 's', 'u', 'b', 's', 'e', 't', '\030', '\002', ' ', 
-'\001', '(', '\013', '2', '\027', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'S', 't', 'r', 
-'u', 'c', 't', 'R', '\r', 'd', 'e', 'f', 'a', 'u', 'l', 't', 'S', 'u', 'b', 's', 'e', 't', '\022', 'k', '\n', '\020', 's', 'u', 'b', 
-'s', 'e', 't', '_', 's', 'e', 'l', 'e', 'c', 't', 'o', 'r', 's', '\030', '\003', ' ', '\003', '(', '\013', '2', '@', '.', 'e', 'n', 'v', 
+'t', 'e', 'r', '.', 'P', 'r', 'e', 'c', 'o', 'n', 'n', 'e', 'c', 't', 'P', 'o', 'l', 'i', 'c', 'y', 'R', '\020', 'p', 'r', 'e', 
+'c', 'o', 'n', 'n', 'e', 'c', 't', 'P', 'o', 'l', 'i', 'c', 'y', '\022', 'X', '\n', ')', 'c', 'o', 'n', 'n', 'e', 'c', 't', 'i', 
+'o', 'n', '_', 'p', 'o', 'o', 'l', '_', 'p', 'e', 'r', '_', 'd', 'o', 'w', 'n', 's', 't', 'r', 'e', 'a', 'm', '_', 'c', 'o', 
+'n', 'n', 'e', 'c', 't', 'i', 'o', 'n', '\030', '3', ' ', '\001', '(', '\010', 'R', '%', 'c', 'o', 'n', 'n', 'e', 'c', 't', 'i', 'o', 
+'n', 'P', 'o', 'o', 'l', 'P', 'e', 'r', 'D', 'o', 'w', 'n', 's', 't', 'r', 'e', 'a', 'm', 'C', 'o', 'n', 'n', 'e', 'c', 't', 
+'i', 'o', 'n', '\032', '\346', '\001', '\n', '\024', 'T', 'r', 'a', 'n', 's', 'p', 'o', 'r', 't', 'S', 'o', 'c', 'k', 'e', 't', 'M', 'a', 
+'t', 'c', 'h', '\022', '\033', '\n', '\004', 'n', 'a', 'm', 'e', '\030', '\001', ' ', '\001', '(', '\t', 'B', '\007', '\372', 'B', '\004', 'r', '\002', '\020', 
+'\001', 'R', '\004', 'n', 'a', 'm', 'e', '\022', '-', '\n', '\005', 'm', 'a', 't', 'c', 'h', '\030', '\002', ' ', '\001', '(', '\013', '2', '\027', '.', 
+'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'S', 't', 'r', 'u', 'c', 't', 'R', '\005', 'm', 
+'a', 't', 'c', 'h', '\022', 'P', '\n', '\020', 't', 'r', 'a', 'n', 's', 'p', 'o', 'r', 't', '_', 's', 'o', 'c', 'k', 'e', 't', '\030', 
+'\003', ' ', '\001', '(', '\013', '2', '%', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', 
+'.', 'v', '3', '.', 'T', 'r', 'a', 'n', 's', 'p', 'o', 'r', 't', 'S', 'o', 'c', 'k', 'e', 't', 'R', '\017', 't', 'r', 'a', 'n', 
+'s', 'p', 'o', 'r', 't', 'S', 'o', 'c', 'k', 'e', 't', ':', '0', '\232', '\305', '\210', '\036', '+', '\n', ')', 'e', 'n', 'v', 'o', 'y', 
+'.', 'a', 'p', 'i', '.', 'v', '2', '.', 'C', 'l', 'u', 's', 't', 'e', 'r', '.', 'T', 'r', 'a', 'n', 's', 'p', 'o', 'r', 't', 
+'S', 'o', 'c', 'k', 'e', 't', 'M', 'a', 't', 'c', 'h', '\032', '\230', '\001', '\n', '\021', 'C', 'u', 's', 't', 'o', 'm', 'C', 'l', 'u', 
+'s', 't', 'e', 'r', 'T', 'y', 'p', 'e', '\022', '\033', '\n', '\004', 'n', 'a', 'm', 'e', '\030', '\001', ' ', '\001', '(', '\t', 'B', '\007', '\372', 
+'B', '\004', 'r', '\002', '\020', '\001', 'R', '\004', 'n', 'a', 'm', 'e', '\022', '7', '\n', '\014', 't', 'y', 'p', 'e', 'd', '_', 'c', 'o', 'n', 
+'f', 'i', 'g', '\030', '\002', ' ', '\001', '(', '\013', '2', '\024', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 
+'u', 'f', '.', 'A', 'n', 'y', 'R', '\013', 't', 'y', 'p', 'e', 'd', 'C', 'o', 'n', 'f', 'i', 'g', ':', '-', '\232', '\305', '\210', '\036', 
+'(', '\n', '&', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'C', 'l', 'u', 's', 't', 'e', 'r', '.', 'C', 
+'u', 's', 't', 'o', 'm', 'C', 'l', 'u', 's', 't', 'e', 'r', 'T', 'y', 'p', 'e', '\032', '\246', '\001', '\n', '\020', 'E', 'd', 's', 'C', 
+'l', 'u', 's', 't', 'e', 'r', 'C', 'o', 'n', 'f', 'i', 'g', '\022', 'A', '\n', '\n', 'e', 'd', 's', '_', 'c', 'o', 'n', 'f', 'i', 
+'g', '\030', '\001', ' ', '\001', '(', '\013', '2', '\"', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 
+'r', 'e', '.', 'v', '3', '.', 'C', 'o', 'n', 'f', 'i', 'g', 'S', 'o', 'u', 'r', 'c', 'e', 'R', '\t', 'e', 'd', 's', 'C', 'o', 
+'n', 'f', 'i', 'g', '\022', '!', '\n', '\014', 's', 'e', 'r', 'v', 'i', 'c', 'e', '_', 'n', 'a', 'm', 'e', '\030', '\002', ' ', '\001', '(', 
+'\t', 'R', '\013', 's', 'e', 'r', 'v', 'i', 'c', 'e', 'N', 'a', 'm', 'e', ':', ',', '\232', '\305', '\210', '\036', '\'', '\n', '%', 'e', 'n', 
+'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'C', 'l', 'u', 's', 't', 'e', 'r', '.', 'E', 'd', 's', 'C', 'l', 'u', 
+'s', 't', 'e', 'r', 'C', 'o', 'n', 'f', 'i', 'g', '\032', '\300', '\010', '\n', '\016', 'L', 'b', 'S', 'u', 'b', 's', 'e', 't', 'C', 'o', 
+'n', 'f', 'i', 'g', '\022', 'y', '\n', '\017', 'f', 'a', 'l', 'l', 'b', 'a', 'c', 'k', '_', 'p', 'o', 'l', 'i', 'c', 'y', '\030', '\001', 
+' ', '\001', '(', '\016', '2', 'F', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'l', 'u', 's', 't', 
+'e', 'r', '.', 'v', '3', '.', 'C', 'l', 'u', 's', 't', 'e', 'r', '.', 'L', 'b', 'S', 'u', 'b', 's', 'e', 't', 'C', 'o', 'n', 
+'f', 'i', 'g', '.', 'L', 'b', 'S', 'u', 'b', 's', 'e', 't', 'F', 'a', 'l', 'l', 'b', 'a', 'c', 'k', 'P', 'o', 'l', 'i', 'c', 
+'y', 'B', '\010', '\372', 'B', '\005', '\202', '\001', '\002', '\020', '\001', 'R', '\016', 'f', 'a', 'l', 'l', 'b', 'a', 'c', 'k', 'P', 'o', 'l', 'i', 
+'c', 'y', '\022', '>', '\n', '\016', 'd', 'e', 'f', 'a', 'u', 'l', 't', '_', 's', 'u', 'b', 's', 'e', 't', '\030', '\002', ' ', '\001', '(', 
+'\013', '2', '\027', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'S', 't', 'r', 'u', 'c', 
+'t', 'R', '\r', 'd', 'e', 'f', 'a', 'u', 'l', 't', 'S', 'u', 'b', 's', 'e', 't', '\022', 'k', '\n', '\020', 's', 'u', 'b', 's', 'e', 
+'t', '_', 's', 'e', 'l', 'e', 'c', 't', 'o', 'r', 's', '\030', '\003', ' ', '\003', '(', '\013', '2', '@', '.', 'e', 'n', 'v', 'o', 'y', 
+'.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'l', 'u', 's', 't', 'e', 'r', '.', 'v', '3', '.', 'C', 'l', 'u', 's', 't', 'e', 
+'r', '.', 'L', 'b', 'S', 'u', 'b', 's', 'e', 't', 'C', 'o', 'n', 'f', 'i', 'g', '.', 'L', 'b', 'S', 'u', 'b', 's', 'e', 't', 
+'S', 'e', 'l', 'e', 'c', 't', 'o', 'r', 'R', '\017', 's', 'u', 'b', 's', 'e', 't', 'S', 'e', 'l', 'e', 'c', 't', 'o', 'r', 's', 
+'\022', '2', '\n', '\025', 'l', 'o', 'c', 'a', 'l', 'i', 't', 'y', '_', 'w', 'e', 'i', 'g', 'h', 't', '_', 'a', 'w', 'a', 'r', 'e', 
+'\030', '\004', ' ', '\001', '(', '\010', 'R', '\023', 'l', 'o', 'c', 'a', 'l', 'i', 't', 'y', 'W', 'e', 'i', 'g', 'h', 't', 'A', 'w', 'a', 
+'r', 'e', '\022', '2', '\n', '\025', 's', 'c', 'a', 'l', 'e', '_', 'l', 'o', 'c', 'a', 'l', 'i', 't', 'y', '_', 'w', 'e', 'i', 'g', 
+'h', 't', '\030', '\005', ' ', '\001', '(', '\010', 'R', '\023', 's', 'c', 'a', 'l', 'e', 'L', 'o', 'c', 'a', 'l', 'i', 't', 'y', 'W', 'e', 
+'i', 'g', 'h', 't', '\022', '$', '\n', '\016', 'p', 'a', 'n', 'i', 'c', '_', 'm', 'o', 'd', 'e', '_', 'a', 'n', 'y', '\030', '\006', ' ', 
+'\001', '(', '\010', 'R', '\014', 'p', 'a', 'n', 'i', 'c', 'M', 'o', 'd', 'e', 'A', 'n', 'y', '\022', '\036', '\n', '\013', 'l', 'i', 's', 't', 
+'_', 'a', 's', '_', 'a', 'n', 'y', '\030', '\007', ' ', '\001', '(', '\010', 'R', '\t', 'l', 'i', 's', 't', 'A', 's', 'A', 'n', 'y', '\032', 
+'\332', '\003', '\n', '\020', 'L', 'b', 'S', 'u', 'b', 's', 'e', 't', 'S', 'e', 'l', 'e', 'c', 't', 'o', 'r', '\022', '\022', '\n', '\004', 'k', 
+'e', 'y', 's', '\030', '\001', ' ', '\003', '(', '\t', 'R', '\004', 'k', 'e', 'y', 's', '\022', '3', '\n', '\026', 's', 'i', 'n', 'g', 'l', 'e', 
+'_', 'h', 'o', 's', 't', '_', 'p', 'e', 'r', '_', 's', 'u', 'b', 's', 'e', 't', '\030', '\004', ' ', '\001', '(', '\010', 'R', '\023', 's', 
+'i', 'n', 'g', 'l', 'e', 'H', 'o', 's', 't', 'P', 'e', 'r', 'S', 'u', 'b', 's', 'e', 't', '\022', '\222', '\001', '\n', '\017', 'f', 'a', 
+'l', 'l', 'b', 'a', 'c', 'k', '_', 'p', 'o', 'l', 'i', 'c', 'y', '\030', '\002', ' ', '\001', '(', '\016', '2', '_', '.', 'e', 'n', 'v', 
 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'l', 'u', 's', 't', 'e', 'r', '.', 'v', '3', '.', 'C', 'l', 'u', 's', 
 't', 'e', 'r', '.', 'L', 'b', 'S', 'u', 'b', 's', 'e', 't', 'C', 'o', 'n', 'f', 'i', 'g', '.', 'L', 'b', 'S', 'u', 'b', 's', 
-'e', 't', 'S', 'e', 'l', 'e', 'c', 't', 'o', 'r', 'R', '\017', 's', 'u', 'b', 's', 'e', 't', 'S', 'e', 'l', 'e', 'c', 't', 'o', 
-'r', 's', '\022', '2', '\n', '\025', 'l', 'o', 'c', 'a', 'l', 'i', 't', 'y', '_', 'w', 'e', 'i', 'g', 'h', 't', '_', 'a', 'w', 'a', 
-'r', 'e', '\030', '\004', ' ', '\001', '(', '\010', 'R', '\023', 'l', 'o', 'c', 'a', 'l', 'i', 't', 'y', 'W', 'e', 'i', 'g', 'h', 't', 'A', 
-'w', 'a', 'r', 'e', '\022', '2', '\n', '\025', 's', 'c', 'a', 'l', 'e', '_', 'l', 'o', 'c', 'a', 'l', 'i', 't', 'y', '_', 'w', 'e', 
-'i', 'g', 'h', 't', '\030', '\005', ' ', '\001', '(', '\010', 'R', '\023', 's', 'c', 'a', 'l', 'e', 'L', 'o', 'c', 'a', 'l', 'i', 't', 'y', 
-'W', 'e', 'i', 'g', 'h', 't', '\022', '$', '\n', '\016', 'p', 'a', 'n', 'i', 'c', '_', 'm', 'o', 'd', 'e', '_', 'a', 'n', 'y', '\030', 
-'\006', ' ', '\001', '(', '\010', 'R', '\014', 'p', 'a', 'n', 'i', 'c', 'M', 'o', 'd', 'e', 'A', 'n', 'y', '\022', '\036', '\n', '\013', 'l', 'i', 
-'s', 't', '_', 'a', 's', '_', 'a', 'n', 'y', '\030', '\007', ' ', '\001', '(', '\010', 'R', '\t', 'l', 'i', 's', 't', 'A', 's', 'A', 'n', 
-'y', '\032', '\332', '\003', '\n', '\020', 'L', 'b', 'S', 'u', 'b', 's', 'e', 't', 'S', 'e', 'l', 'e', 'c', 't', 'o', 'r', '\022', '\022', '\n', 
-'\004', 'k', 'e', 'y', 's', '\030', '\001', ' ', '\003', '(', '\t', 'R', '\004', 'k', 'e', 'y', 's', '\022', '3', '\n', '\026', 's', 'i', 'n', 'g', 
-'l', 'e', '_', 'h', 'o', 's', 't', '_', 'p', 'e', 'r', '_', 's', 'u', 'b', 's', 'e', 't', '\030', '\004', ' ', '\001', '(', '\010', 'R', 
-'\023', 's', 'i', 'n', 'g', 'l', 'e', 'H', 'o', 's', 't', 'P', 'e', 'r', 'S', 'u', 'b', 's', 'e', 't', '\022', '\222', '\001', '\n', '\017', 
-'f', 'a', 'l', 'l', 'b', 'a', 'c', 'k', '_', 'p', 'o', 'l', 'i', 'c', 'y', '\030', '\002', ' ', '\001', '(', '\016', '2', '_', '.', 'e', 
+'e', 't', 'S', 'e', 'l', 'e', 'c', 't', 'o', 'r', '.', 'L', 'b', 'S', 'u', 'b', 's', 'e', 't', 'S', 'e', 'l', 'e', 'c', 't', 
+'o', 'r', 'F', 'a', 'l', 'l', 'b', 'a', 'c', 'k', 'P', 'o', 'l', 'i', 'c', 'y', 'B', '\010', '\372', 'B', '\005', '\202', '\001', '\002', '\020', 
+'\001', 'R', '\016', 'f', 'a', 'l', 'l', 'b', 'a', 'c', 'k', 'P', 'o', 'l', 'i', 'c', 'y', '\022', '0', '\n', '\024', 'f', 'a', 'l', 'l', 
+'b', 'a', 'c', 'k', '_', 'k', 'e', 'y', 's', '_', 's', 'u', 'b', 's', 'e', 't', '\030', '\003', ' ', '\003', '(', '\t', 'R', '\022', 'f', 
+'a', 'l', 'l', 'b', 'a', 'c', 'k', 'K', 'e', 'y', 's', 'S', 'u', 'b', 's', 'e', 't', '\"', 'y', '\n', '\036', 'L', 'b', 'S', 'u', 
+'b', 's', 'e', 't', 'S', 'e', 'l', 'e', 'c', 't', 'o', 'r', 'F', 'a', 'l', 'l', 'b', 'a', 'c', 'k', 'P', 'o', 'l', 'i', 'c', 
+'y', '\022', '\017', '\n', '\013', 'N', 'O', 'T', '_', 'D', 'E', 'F', 'I', 'N', 'E', 'D', '\020', '\000', '\022', '\017', '\n', '\013', 'N', 'O', '_', 
+'F', 'A', 'L', 'L', 'B', 'A', 'C', 'K', '\020', '\001', '\022', '\020', '\n', '\014', 'A', 'N', 'Y', '_', 'E', 'N', 'D', 'P', 'O', 'I', 'N', 
+'T', '\020', '\002', '\022', '\022', '\n', '\016', 'D', 'E', 'F', 'A', 'U', 'L', 'T', '_', 'S', 'U', 'B', 'S', 'E', 'T', '\020', '\003', '\022', '\017', 
+'\n', '\013', 'K', 'E', 'Y', 'S', '_', 'S', 'U', 'B', 'S', 'E', 'T', '\020', '\004', ':', ';', '\232', '\305', '\210', '\036', '6', '\n', '4', 'e', 
+'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'C', 'l', 'u', 's', 't', 'e', 'r', '.', 'L', 'b', 'S', 'u', 'b', 
+'s', 'e', 't', 'C', 'o', 'n', 'f', 'i', 'g', '.', 'L', 'b', 'S', 'u', 'b', 's', 'e', 't', 'S', 'e', 'l', 'e', 'c', 't', 'o', 
+'r', '\"', 'O', '\n', '\026', 'L', 'b', 'S', 'u', 'b', 's', 'e', 't', 'F', 'a', 'l', 'l', 'b', 'a', 'c', 'k', 'P', 'o', 'l', 'i', 
+'c', 'y', '\022', '\017', '\n', '\013', 'N', 'O', '_', 'F', 'A', 'L', 'L', 'B', 'A', 'C', 'K', '\020', '\000', '\022', '\020', '\n', '\014', 'A', 'N', 
+'Y', '_', 'E', 'N', 'D', 'P', 'O', 'I', 'N', 'T', '\020', '\001', '\022', '\022', '\n', '\016', 'D', 'E', 'F', 'A', 'U', 'L', 'T', '_', 'S', 
+'U', 'B', 'S', 'E', 'T', '\020', '\002', ':', '*', '\232', '\305', '\210', '\036', '%', '\n', '#', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', 
+'.', 'v', '2', '.', 'C', 'l', 'u', 's', 't', 'e', 'r', '.', 'L', 'b', 'S', 'u', 'b', 's', 'e', 't', 'C', 'o', 'n', 'f', 'i', 
+'g', '\032', '\347', '\001', '\n', '\024', 'L', 'e', 'a', 's', 't', 'R', 'e', 'q', 'u', 'e', 's', 't', 'L', 'b', 'C', 'o', 'n', 'f', 'i', 
+'g', '\022', 'H', '\n', '\014', 'c', 'h', 'o', 'i', 'c', 'e', '_', 'c', 'o', 'u', 'n', 't', '\030', '\001', ' ', '\001', '(', '\013', '2', '\034', 
+'.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'U', 'I', 'n', 't', '3', '2', 'V', 'a', 
+'l', 'u', 'e', 'B', '\007', '\372', 'B', '\004', '*', '\002', '(', '\002', 'R', '\013', 'c', 'h', 'o', 'i', 'c', 'e', 'C', 'o', 'u', 'n', 't', 
+'\022', 'S', '\n', '\023', 'a', 'c', 't', 'i', 'v', 'e', '_', 'r', 'e', 'q', 'u', 'e', 's', 't', '_', 'b', 'i', 'a', 's', '\030', '\002', 
+' ', '\001', '(', '\013', '2', '#', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 
+'v', '3', '.', 'R', 'u', 'n', 't', 'i', 'm', 'e', 'D', 'o', 'u', 'b', 'l', 'e', 'R', '\021', 'a', 'c', 't', 'i', 'v', 'e', 'R', 
+'e', 'q', 'u', 'e', 's', 't', 'B', 'i', 'a', 's', ':', '0', '\232', '\305', '\210', '\036', '+', '\n', ')', 'e', 'n', 'v', 'o', 'y', '.', 
+'a', 'p', 'i', '.', 'v', '2', '.', 'C', 'l', 'u', 's', 't', 'e', 'r', '.', 'L', 'e', 'a', 's', 't', 'R', 'e', 'q', 'u', 'e', 
+'s', 't', 'L', 'b', 'C', 'o', 'n', 'f', 'i', 'g', '\032', '\221', '\003', '\n', '\020', 'R', 'i', 'n', 'g', 'H', 'a', 's', 'h', 'L', 'b', 
+'C', 'o', 'n', 'f', 'i', 'g', '\022', 'T', '\n', '\021', 'm', 'i', 'n', 'i', 'm', 'u', 'm', '_', 'r', 'i', 'n', 'g', '_', 's', 'i', 
+'z', 'e', '\030', '\001', ' ', '\001', '(', '\013', '2', '\034', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 
+'f', '.', 'U', 'I', 'n', 't', '6', '4', 'V', 'a', 'l', 'u', 'e', 'B', '\n', '\372', 'B', '\007', '2', '\005', '\030', '\200', '\200', '\200', '\004', 
+'R', '\017', 'm', 'i', 'n', 'i', 'm', 'u', 'm', 'R', 'i', 'n', 'g', 'S', 'i', 'z', 'e', '\022', 'm', '\n', '\r', 'h', 'a', 's', 'h', 
+'_', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', '\030', '\003', ' ', '\001', '(', '\016', '2', '>', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 
+'o', 'n', 'f', 'i', 'g', '.', 'c', 'l', 'u', 's', 't', 'e', 'r', '.', 'v', '3', '.', 'C', 'l', 'u', 's', 't', 'e', 'r', '.', 
+'R', 'i', 'n', 'g', 'H', 'a', 's', 'h', 'L', 'b', 'C', 'o', 'n', 'f', 'i', 'g', '.', 'H', 'a', 's', 'h', 'F', 'u', 'n', 'c', 
+'t', 'i', 'o', 'n', 'B', '\010', '\372', 'B', '\005', '\202', '\001', '\002', '\020', '\001', 'R', '\014', 'h', 'a', 's', 'h', 'F', 'u', 'n', 'c', 't', 
+'i', 'o', 'n', '\022', 'T', '\n', '\021', 'm', 'a', 'x', 'i', 'm', 'u', 'm', '_', 'r', 'i', 'n', 'g', '_', 's', 'i', 'z', 'e', '\030', 
+'\004', ' ', '\001', '(', '\013', '2', '\034', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'U', 
+'I', 'n', 't', '6', '4', 'V', 'a', 'l', 'u', 'e', 'B', '\n', '\372', 'B', '\007', '2', '\005', '\030', '\200', '\200', '\200', '\004', 'R', '\017', 'm', 
+'a', 'x', 'i', 'm', 'u', 'm', 'R', 'i', 'n', 'g', 'S', 'i', 'z', 'e', '\"', '.', '\n', '\014', 'H', 'a', 's', 'h', 'F', 'u', 'n', 
+'c', 't', 'i', 'o', 'n', '\022', '\013', '\n', '\007', 'X', 'X', '_', 'H', 'A', 'S', 'H', '\020', '\000', '\022', '\021', '\n', '\r', 'M', 'U', 'R', 
+'M', 'U', 'R', '_', 'H', 'A', 'S', 'H', '_', '2', '\020', '\001', ':', ',', '\232', '\305', '\210', '\036', '\'', '\n', '%', 'e', 'n', 'v', 'o', 
+'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'C', 'l', 'u', 's', 't', 'e', 'r', '.', 'R', 'i', 'n', 'g', 'H', 'a', 's', 'h', 
+'L', 'b', 'C', 'o', 'n', 'f', 'i', 'g', 'J', '\004', '\010', '\002', '\020', '\003', '\032', 'Y', '\n', '\016', 'M', 'a', 'g', 'l', 'e', 'v', 'L', 
+'b', 'C', 'o', 'n', 'f', 'i', 'g', '\022', 'G', '\n', '\n', 't', 'a', 'b', 'l', 'e', '_', 's', 'i', 'z', 'e', '\030', '\001', ' ', '\001', 
+'(', '\013', '2', '\034', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'U', 'I', 'n', 't', 
+'6', '4', 'V', 'a', 'l', 'u', 'e', 'B', '\n', '\372', 'B', '\007', '2', '\005', '\030', '\313', '\226', '\261', '\002', 'R', '\t', 't', 'a', 'b', 'l', 
+'e', 'S', 'i', 'z', 'e', '\032', 'n', '\n', '\023', 'O', 'r', 'i', 'g', 'i', 'n', 'a', 'l', 'D', 's', 't', 'L', 'b', 'C', 'o', 'n', 
+'f', 'i', 'g', '\022', '&', '\n', '\017', 'u', 's', 'e', '_', 'h', 't', 't', 'p', '_', 'h', 'e', 'a', 'd', 'e', 'r', '\030', '\001', ' ', 
+'\001', '(', '\010', 'R', '\r', 'u', 's', 'e', 'H', 't', 't', 'p', 'H', 'e', 'a', 'd', 'e', 'r', ':', '/', '\232', '\305', '\210', '\036', '*', 
+'\n', '(', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'C', 'l', 'u', 's', 't', 'e', 'r', '.', 'O', 'r', 
+'i', 'g', 'i', 'n', 'a', 'l', 'D', 's', 't', 'L', 'b', 'C', 'o', 'n', 'f', 'i', 'g', '\032', '\374', '\n', '\n', '\016', 'C', 'o', 'm', 
+'m', 'o', 'n', 'L', 'b', 'C', 'o', 'n', 'f', 'i', 'g', '\022', 'N', '\n', '\027', 'h', 'e', 'a', 'l', 't', 'h', 'y', '_', 'p', 'a', 
+'n', 'i', 'c', '_', 't', 'h', 'r', 'e', 's', 'h', 'o', 'l', 'd', '\030', '\001', ' ', '\001', '(', '\013', '2', '\026', '.', 'e', 'n', 'v', 
+'o', 'y', '.', 't', 'y', 'p', 'e', '.', 'v', '3', '.', 'P', 'e', 'r', 'c', 'e', 'n', 't', 'R', '\025', 'h', 'e', 'a', 'l', 't', 
+'h', 'y', 'P', 'a', 'n', 'i', 'c', 'T', 'h', 'r', 'e', 's', 'h', 'o', 'l', 'd', '\022', 't', '\n', '\024', 'z', 'o', 'n', 'e', '_', 
+'a', 'w', 'a', 'r', 'e', '_', 'l', 'b', '_', 'c', 'o', 'n', 'f', 'i', 'g', '\030', '\002', ' ', '\001', '(', '\013', '2', 'A', '.', 'e', 
 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'l', 'u', 's', 't', 'e', 'r', '.', 'v', '3', '.', 'C', 'l', 
-'u', 's', 't', 'e', 'r', '.', 'L', 'b', 'S', 'u', 'b', 's', 'e', 't', 'C', 'o', 'n', 'f', 'i', 'g', '.', 'L', 'b', 'S', 'u', 
-'b', 's', 'e', 't', 'S', 'e', 'l', 'e', 'c', 't', 'o', 'r', '.', 'L', 'b', 'S', 'u', 'b', 's', 'e', 't', 'S', 'e', 'l', 'e', 
-'c', 't', 'o', 'r', 'F', 'a', 'l', 'l', 'b', 'a', 'c', 'k', 'P', 'o', 'l', 'i', 'c', 'y', 'B', '\010', '\372', 'B', '\005', '\202', '\001', 
-'\002', '\020', '\001', 'R', '\016', 'f', 'a', 'l', 'l', 'b', 'a', 'c', 'k', 'P', 'o', 'l', 'i', 'c', 'y', '\022', '0', '\n', '\024', 'f', 'a', 
-'l', 'l', 'b', 'a', 'c', 'k', '_', 'k', 'e', 'y', 's', '_', 's', 'u', 'b', 's', 'e', 't', '\030', '\003', ' ', '\003', '(', '\t', 'R', 
-'\022', 'f', 'a', 'l', 'l', 'b', 'a', 'c', 'k', 'K', 'e', 'y', 's', 'S', 'u', 'b', 's', 'e', 't', '\"', 'y', '\n', '\036', 'L', 'b', 
-'S', 'u', 'b', 's', 'e', 't', 'S', 'e', 'l', 'e', 'c', 't', 'o', 'r', 'F', 'a', 'l', 'l', 'b', 'a', 'c', 'k', 'P', 'o', 'l', 
-'i', 'c', 'y', '\022', '\017', '\n', '\013', 'N', 'O', 'T', '_', 'D', 'E', 'F', 'I', 'N', 'E', 'D', '\020', '\000', '\022', '\017', '\n', '\013', 'N', 
-'O', '_', 'F', 'A', 'L', 'L', 'B', 'A', 'C', 'K', '\020', '\001', '\022', '\020', '\n', '\014', 'A', 'N', 'Y', '_', 'E', 'N', 'D', 'P', 'O', 
-'I', 'N', 'T', '\020', '\002', '\022', '\022', '\n', '\016', 'D', 'E', 'F', 'A', 'U', 'L', 'T', '_', 'S', 'U', 'B', 'S', 'E', 'T', '\020', '\003', 
-'\022', '\017', '\n', '\013', 'K', 'E', 'Y', 'S', '_', 'S', 'U', 'B', 'S', 'E', 'T', '\020', '\004', ':', ';', '\232', '\305', '\210', '\036', '6', '\n', 
-'4', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'C', 'l', 'u', 's', 't', 'e', 'r', '.', 'L', 'b', 'S', 
-'u', 'b', 's', 'e', 't', 'C', 'o', 'n', 'f', 'i', 'g', '.', 'L', 'b', 'S', 'u', 'b', 's', 'e', 't', 'S', 'e', 'l', 'e', 'c', 
-'t', 'o', 'r', '\"', 'O', '\n', '\026', 'L', 'b', 'S', 'u', 'b', 's', 'e', 't', 'F', 'a', 'l', 'l', 'b', 'a', 'c', 'k', 'P', 'o', 
-'l', 'i', 'c', 'y', '\022', '\017', '\n', '\013', 'N', 'O', '_', 'F', 'A', 'L', 'L', 'B', 'A', 'C', 'K', '\020', '\000', '\022', '\020', '\n', '\014', 
-'A', 'N', 'Y', '_', 'E', 'N', 'D', 'P', 'O', 'I', 'N', 'T', '\020', '\001', '\022', '\022', '\n', '\016', 'D', 'E', 'F', 'A', 'U', 'L', 'T', 
-'_', 'S', 'U', 'B', 'S', 'E', 'T', '\020', '\002', ':', '*', '\232', '\305', '\210', '\036', '%', '\n', '#', 'e', 'n', 'v', 'o', 'y', '.', 'a', 
-'p', 'i', '.', 'v', '2', '.', 'C', 'l', 'u', 's', 't', 'e', 'r', '.', 'L', 'b', 'S', 'u', 'b', 's', 'e', 't', 'C', 'o', 'n', 
-'f', 'i', 'g', '\032', '\347', '\001', '\n', '\024', 'L', 'e', 'a', 's', 't', 'R', 'e', 'q', 'u', 'e', 's', 't', 'L', 'b', 'C', 'o', 'n', 
-'f', 'i', 'g', '\022', 'H', '\n', '\014', 'c', 'h', 'o', 'i', 'c', 'e', '_', 'c', 'o', 'u', 'n', 't', '\030', '\001', ' ', '\001', '(', '\013', 
-'2', '\034', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'U', 'I', 'n', 't', '3', '2', 
-'V', 'a', 'l', 'u', 'e', 'B', '\007', '\372', 'B', '\004', '*', '\002', '(', '\002', 'R', '\013', 'c', 'h', 'o', 'i', 'c', 'e', 'C', 'o', 'u', 
-'n', 't', '\022', 'S', '\n', '\023', 'a', 'c', 't', 'i', 'v', 'e', '_', 'r', 'e', 'q', 'u', 'e', 's', 't', '_', 'b', 'i', 'a', 's', 
-'\030', '\002', ' ', '\001', '(', '\013', '2', '#', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 
-'e', '.', 'v', '3', '.', 'R', 'u', 'n', 't', 'i', 'm', 'e', 'D', 'o', 'u', 'b', 'l', 'e', 'R', '\021', 'a', 'c', 't', 'i', 'v', 
-'e', 'R', 'e', 'q', 'u', 'e', 's', 't', 'B', 'i', 'a', 's', ':', '0', '\232', '\305', '\210', '\036', '+', '\n', ')', 'e', 'n', 'v', 'o', 
-'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'C', 'l', 'u', 's', 't', 'e', 'r', '.', 'L', 'e', 'a', 's', 't', 'R', 'e', 'q', 
-'u', 'e', 's', 't', 'L', 'b', 'C', 'o', 'n', 'f', 'i', 'g', '\032', '\221', '\003', '\n', '\020', 'R', 'i', 'n', 'g', 'H', 'a', 's', 'h', 
-'L', 'b', 'C', 'o', 'n', 'f', 'i', 'g', '\022', 'T', '\n', '\021', 'm', 'i', 'n', 'i', 'm', 'u', 'm', '_', 'r', 'i', 'n', 'g', '_', 
-'s', 'i', 'z', 'e', '\030', '\001', ' ', '\001', '(', '\013', '2', '\034', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 
-'b', 'u', 'f', '.', 'U', 'I', 'n', 't', '6', '4', 'V', 'a', 'l', 'u', 'e', 'B', '\n', '\372', 'B', '\007', '2', '\005', '\030', '\200', '\200', 
-'\200', '\004', 'R', '\017', 'm', 'i', 'n', 'i', 'm', 'u', 'm', 'R', 'i', 'n', 'g', 'S', 'i', 'z', 'e', '\022', 'm', '\n', '\r', 'h', 'a', 
-'s', 'h', '_', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', '\030', '\003', ' ', '\001', '(', '\016', '2', '>', '.', 'e', 'n', 'v', 'o', 'y', 
-'.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'l', 'u', 's', 't', 'e', 'r', '.', 'v', '3', '.', 'C', 'l', 'u', 's', 't', 'e', 
-'r', '.', 'R', 'i', 'n', 'g', 'H', 'a', 's', 'h', 'L', 'b', 'C', 'o', 'n', 'f', 'i', 'g', '.', 'H', 'a', 's', 'h', 'F', 'u', 
-'n', 'c', 't', 'i', 'o', 'n', 'B', '\010', '\372', 'B', '\005', '\202', '\001', '\002', '\020', '\001', 'R', '\014', 'h', 'a', 's', 'h', 'F', 'u', 'n', 
-'c', 't', 'i', 'o', 'n', '\022', 'T', '\n', '\021', 'm', 'a', 'x', 'i', 'm', 'u', 'm', '_', 'r', 'i', 'n', 'g', '_', 's', 'i', 'z', 
-'e', '\030', '\004', ' ', '\001', '(', '\013', '2', '\034', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', 
-'.', 'U', 'I', 'n', 't', '6', '4', 'V', 'a', 'l', 'u', 'e', 'B', '\n', '\372', 'B', '\007', '2', '\005', '\030', '\200', '\200', '\200', '\004', 'R', 
-'\017', 'm', 'a', 'x', 'i', 'm', 'u', 'm', 'R', 'i', 'n', 'g', 'S', 'i', 'z', 'e', '\"', '.', '\n', '\014', 'H', 'a', 's', 'h', 'F', 
-'u', 'n', 'c', 't', 'i', 'o', 'n', '\022', '\013', '\n', '\007', 'X', 'X', '_', 'H', 'A', 'S', 'H', '\020', '\000', '\022', '\021', '\n', '\r', 'M', 
-'U', 'R', 'M', 'U', 'R', '_', 'H', 'A', 'S', 'H', '_', '2', '\020', '\001', ':', ',', '\232', '\305', '\210', '\036', '\'', '\n', '%', 'e', 'n', 
-'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'C', 'l', 'u', 's', 't', 'e', 'r', '.', 'R', 'i', 'n', 'g', 'H', 'a', 
-'s', 'h', 'L', 'b', 'C', 'o', 'n', 'f', 'i', 'g', 'J', '\004', '\010', '\002', '\020', '\003', '\032', 'Y', '\n', '\016', 'M', 'a', 'g', 'l', 'e', 
-'v', 'L', 'b', 'C', 'o', 'n', 'f', 'i', 'g', '\022', 'G', '\n', '\n', 't', 'a', 'b', 'l', 'e', '_', 's', 'i', 'z', 'e', '\030', '\001', 
-' ', '\001', '(', '\013', '2', '\034', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'U', 'I', 
-'n', 't', '6', '4', 'V', 'a', 'l', 'u', 'e', 'B', '\n', '\372', 'B', '\007', '2', '\005', '\030', '\313', '\226', '\261', '\002', 'R', '\t', 't', 'a', 
-'b', 'l', 'e', 'S', 'i', 'z', 'e', '\032', 'n', '\n', '\023', 'O', 'r', 'i', 'g', 'i', 'n', 'a', 'l', 'D', 's', 't', 'L', 'b', 'C', 
-'o', 'n', 'f', 'i', 'g', '\022', '&', '\n', '\017', 'u', 's', 'e', '_', 'h', 't', 't', 'p', '_', 'h', 'e', 'a', 'd', 'e', 'r', '\030', 
-'\001', ' ', '\001', '(', '\010', 'R', '\r', 'u', 's', 'e', 'H', 't', 't', 'p', 'H', 'e', 'a', 'd', 'e', 'r', ':', '/', '\232', '\305', '\210', 
-'\036', '*', '\n', '(', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'C', 'l', 'u', 's', 't', 'e', 'r', '.', 
-'O', 'r', 'i', 'g', 'i', 'n', 'a', 'l', 'D', 's', 't', 'L', 'b', 'C', 'o', 'n', 'f', 'i', 'g', '\032', '\374', '\n', '\n', '\016', 'C', 
-'o', 'm', 'm', 'o', 'n', 'L', 'b', 'C', 'o', 'n', 'f', 'i', 'g', '\022', 'N', '\n', '\027', 'h', 'e', 'a', 'l', 't', 'h', 'y', '_', 
-'p', 'a', 'n', 'i', 'c', '_', 't', 'h', 'r', 'e', 's', 'h', 'o', 'l', 'd', '\030', '\001', ' ', '\001', '(', '\013', '2', '\026', '.', 'e', 
-'n', 'v', 'o', 'y', '.', 't', 'y', 'p', 'e', '.', 'v', '3', '.', 'P', 'e', 'r', 'c', 'e', 'n', 't', 'R', '\025', 'h', 'e', 'a', 
-'l', 't', 'h', 'y', 'P', 'a', 'n', 'i', 'c', 'T', 'h', 'r', 'e', 's', 'h', 'o', 'l', 'd', '\022', 't', '\n', '\024', 'z', 'o', 'n', 
-'e', '_', 'a', 'w', 'a', 'r', 'e', '_', 'l', 'b', '_', 'c', 'o', 'n', 'f', 'i', 'g', '\030', '\002', ' ', '\001', '(', '\013', '2', 'A', 
-'.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'l', 'u', 's', 't', 'e', 'r', '.', 'v', '3', '.', 
-'C', 'l', 'u', 's', 't', 'e', 'r', '.', 'C', 'o', 'm', 'm', 'o', 'n', 'L', 'b', 'C', 'o', 'n', 'f', 'i', 'g', '.', 'Z', 'o', 
-'n', 'e', 'A', 'w', 'a', 'r', 'e', 'L', 'b', 'C', 'o', 'n', 'f', 'i', 'g', 'H', '\000', 'R', '\021', 'z', 'o', 'n', 'e', 'A', 'w', 
-'a', 'r', 'e', 'L', 'b', 'C', 'o', 'n', 'f', 'i', 'g', '\022', '\211', '\001', '\n', '\033', 'l', 'o', 'c', 'a', 'l', 'i', 't', 'y', '_', 
-'w', 'e', 'i', 'g', 'h', 't', 'e', 'd', '_', 'l', 'b', '_', 'c', 'o', 'n', 'f', 'i', 'g', '\030', '\003', ' ', '\001', '(', '\013', '2', 
-'H', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'l', 'u', 's', 't', 'e', 'r', '.', 'v', '3', 
-'.', 'C', 'l', 'u', 's', 't', 'e', 'r', '.', 'C', 'o', 'm', 'm', 'o', 'n', 'L', 'b', 'C', 'o', 'n', 'f', 'i', 'g', '.', 'L', 
-'o', 'c', 'a', 'l', 'i', 't', 'y', 'W', 'e', 'i', 'g', 'h', 't', 'e', 'd', 'L', 'b', 'C', 'o', 'n', 'f', 'i', 'g', 'H', '\000', 
-'R', '\030', 'l', 'o', 'c', 'a', 'l', 'i', 't', 'y', 'W', 'e', 'i', 'g', 'h', 't', 'e', 'd', 'L', 'b', 'C', 'o', 'n', 'f', 'i', 
-'g', '\022', 'I', '\n', '\023', 'u', 'p', 'd', 'a', 't', 'e', '_', 'm', 'e', 'r', 'g', 'e', '_', 'w', 'i', 'n', 'd', 'o', 'w', '\030', 
-'\004', ' ', '\001', '(', '\013', '2', '\031', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'D', 
-'u', 'r', 'a', 't', 'i', 'o', 'n', 'R', '\021', 'u', 'p', 'd', 'a', 't', 'e', 'M', 'e', 'r', 'g', 'e', 'W', 'i', 'n', 'd', 'o', 
-'w', '\022', 'C', '\n', '\037', 'i', 'g', 'n', 'o', 'r', 'e', '_', 'n', 'e', 'w', '_', 'h', 'o', 's', 't', 's', '_', 'u', 'n', 't', 
-'i', 'l', '_', 'f', 'i', 'r', 's', 't', '_', 'h', 'c', '\030', '\005', ' ', '\001', '(', '\010', 'R', '\032', 'i', 'g', 'n', 'o', 'r', 'e', 
-'N', 'e', 'w', 'H', 'o', 's', 't', 's', 'U', 'n', 't', 'i', 'l', 'F', 'i', 'r', 's', 't', 'H', 'c', '\022', 'M', '\n', '$', 'c', 
-'l', 'o', 's', 'e', '_', 'c', 'o', 'n', 'n', 'e', 'c', 't', 'i', 'o', 'n', 's', '_', 'o', 'n', '_', 'h', 'o', 's', 't', '_', 
-'s', 'e', 't', '_', 'c', 'h', 'a', 'n', 'g', 'e', '\030', '\006', ' ', '\001', '(', '\010', 'R', '\037', 'c', 'l', 'o', 's', 'e', 'C', 'o', 
-'n', 'n', 'e', 'c', 't', 'i', 'o', 'n', 's', 'O', 'n', 'H', 'o', 's', 't', 'S', 'e', 't', 'C', 'h', 'a', 'n', 'g', 'e', '\022', 
-'\212', '\001', '\n', '\034', 'c', 'o', 'n', 's', 'i', 's', 't', 'e', 'n', 't', '_', 'h', 'a', 's', 'h', 'i', 'n', 'g', '_', 'l', 'b', 
-'_', 'c', 'o', 'n', 'f', 'i', 'g', '\030', '\007', ' ', '\001', '(', '\013', '2', 'I', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 
-'f', 'i', 'g', '.', 'c', 'l', 'u', 's', 't', 'e', 'r', '.', 'v', '3', '.', 'C', 'l', 'u', 's', 't', 'e', 'r', '.', 'C', 'o', 
-'m', 'm', 'o', 'n', 'L', 'b', 'C', 'o', 'n', 'f', 'i', 'g', '.', 'C', 'o', 'n', 's', 'i', 's', 't', 'e', 'n', 't', 'H', 'a', 
-'s', 'h', 'i', 'n', 'g', 'L', 'b', 'C', 'o', 'n', 'f', 'i', 'g', 'R', '\031', 'c', 'o', 'n', 's', 'i', 's', 't', 'e', 'n', 't', 
-'H', 'a', 's', 'h', 'i', 'n', 'g', 'L', 'b', 'C', 'o', 'n', 'f', 'i', 'g', '\032', '\215', '\002', '\n', '\021', 'Z', 'o', 'n', 'e', 'A', 
-'w', 'a', 'r', 'e', 'L', 'b', 'C', 'o', 'n', 'f', 'i', 'g', '\022', '?', '\n', '\017', 'r', 'o', 'u', 't', 'i', 'n', 'g', '_', 'e', 
-'n', 'a', 'b', 'l', 'e', 'd', '\030', '\001', ' ', '\001', '(', '\013', '2', '\026', '.', 'e', 'n', 'v', 'o', 'y', '.', 't', 'y', 'p', 'e', 
-'.', 'v', '3', '.', 'P', 'e', 'r', 'c', 'e', 'n', 't', 'R', '\016', 'r', 'o', 'u', 't', 'i', 'n', 'g', 'E', 'n', 'a', 'b', 'l', 
-'e', 'd', '\022', 'F', '\n', '\020', 'm', 'i', 'n', '_', 'c', 'l', 'u', 's', 't', 'e', 'r', '_', 's', 'i', 'z', 'e', '\030', '\002', ' ', 
-'\001', '(', '\013', '2', '\034', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'U', 'I', 'n', 
-'t', '6', '4', 'V', 'a', 'l', 'u', 'e', 'R', '\016', 'm', 'i', 'n', 'C', 'l', 'u', 's', 't', 'e', 'r', 'S', 'i', 'z', 'e', '\022', 
-'1', '\n', '\025', 'f', 'a', 'i', 'l', '_', 't', 'r', 'a', 'f', 'f', 'i', 'c', '_', 'o', 'n', '_', 'p', 'a', 'n', 'i', 'c', '\030', 
-'\003', ' ', '\001', '(', '\010', 'R', '\022', 'f', 'a', 'i', 'l', 'T', 'r', 'a', 'f', 'f', 'i', 'c', 'O', 'n', 'P', 'a', 'n', 'i', 'c', 
-':', '<', '\232', '\305', '\210', '\036', '7', '\n', '5', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'C', 'l', 'u', 
-'s', 't', 'e', 'r', '.', 'C', 'o', 'm', 'm', 'o', 'n', 'L', 'b', 'C', 'o', 'n', 'f', 'i', 'g', '.', 'Z', 'o', 'n', 'e', 'A', 
-'w', 'a', 'r', 'e', 'L', 'b', 'C', 'o', 'n', 'f', 'i', 'g', '\032', '_', '\n', '\030', 'L', 'o', 'c', 'a', 'l', 'i', 't', 'y', 'W', 
-'e', 'i', 'g', 'h', 't', 'e', 'd', 'L', 'b', 'C', 'o', 'n', 'f', 'i', 'g', ':', 'C', '\232', '\305', '\210', '\036', '>', '\n', '<', 'e', 
-'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'C', 'l', 'u', 's', 't', 'e', 'r', '.', 'C', 'o', 'm', 'm', 'o', 
-'n', 'L', 'b', 'C', 'o', 'n', 'f', 'i', 'g', '.', 'L', 'o', 'c', 'a', 'l', 'i', 't', 'y', 'W', 'e', 'i', 'g', 'h', 't', 'e', 
-'d', 'L', 'b', 'C', 'o', 'n', 'f', 'i', 'g', '\032', '\361', '\001', '\n', '\031', 'C', 'o', 'n', 's', 'i', 's', 't', 'e', 'n', 't', 'H', 
-'a', 's', 'h', 'i', 'n', 'g', 'L', 'b', 'C', 'o', 'n', 'f', 'i', 'g', '\022', '7', '\n', '\030', 'u', 's', 'e', '_', 'h', 'o', 's', 
-'t', 'n', 'a', 'm', 'e', '_', 'f', 'o', 'r', '_', 'h', 'a', 's', 'h', 'i', 'n', 'g', '\030', '\001', ' ', '\001', '(', '\010', 'R', '\025', 
-'u', 's', 'e', 'H', 'o', 's', 't', 'n', 'a', 'm', 'e', 'F', 'o', 'r', 'H', 'a', 's', 'h', 'i', 'n', 'g', '\022', 'U', '\n', '\023', 
-'h', 'a', 's', 'h', '_', 'b', 'a', 'l', 'a', 'n', 'c', 'e', '_', 'f', 'a', 'c', 't', 'o', 'r', '\030', '\002', ' ', '\001', '(', '\013', 
-'2', '\034', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'U', 'I', 'n', 't', '3', '2', 
-'V', 'a', 'l', 'u', 'e', 'B', '\007', '\372', 'B', '\004', '*', '\002', '(', 'd', 'R', '\021', 'h', 'a', 's', 'h', 'B', 'a', 'l', 'a', 'n', 
-'c', 'e', 'F', 'a', 'c', 't', 'o', 'r', ':', 'D', '\232', '\305', '\210', '\036', '?', '\n', '=', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 
-'i', '.', 'v', '2', '.', 'C', 'l', 'u', 's', 't', 'e', 'r', '.', 'C', 'o', 'm', 'm', 'o', 'n', 'L', 'b', 'C', 'o', 'n', 'f', 
-'i', 'g', '.', 'C', 'o', 'n', 's', 'i', 's', 't', 'e', 'n', 't', 'H', 'a', 's', 'h', 'i', 'n', 'g', 'L', 'b', 'C', 'o', 'n', 
-'f', 'i', 'g', ':', '*', '\232', '\305', '\210', '\036', '%', '\n', '#', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 
-'C', 'l', 'u', 's', 't', 'e', 'r', '.', 'C', 'o', 'm', 'm', 'o', 'n', 'L', 'b', 'C', 'o', 'n', 'f', 'i', 'g', 'B', '\033', '\n', 
-'\031', 'l', 'o', 'c', 'a', 'l', 'i', 't', 'y', '_', 'c', 'o', 'n', 'f', 'i', 'g', '_', 's', 'p', 'e', 'c', 'i', 'f', 'i', 'e', 
-'r', '\032', '\322', '\001', '\n', '\013', 'R', 'e', 'f', 'r', 'e', 's', 'h', 'R', 'a', 't', 'e', '\022', 'N', '\n', '\r', 'b', 'a', 's', 'e', 
-'_', 'i', 'n', 't', 'e', 'r', 'v', 'a', 'l', '\030', '\001', ' ', '\001', '(', '\013', '2', '\031', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 
-'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'D', 'u', 'r', 'a', 't', 'i', 'o', 'n', 'B', '\016', '\372', 'B', '\013', '\252', '\001', '\010', 
-'\010', '\001', '*', '\004', '\020', '\300', '\204', '=', 'R', '\014', 'b', 'a', 's', 'e', 'I', 'n', 't', 'e', 'r', 'v', 'a', 'l', '\022', 'J', '\n', 
-'\014', 'm', 'a', 'x', '_', 'i', 'n', 't', 'e', 'r', 'v', 'a', 'l', '\030', '\002', ' ', '\001', '(', '\013', '2', '\031', '.', 'g', 'o', 'o', 
-'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'D', 'u', 'r', 'a', 't', 'i', 'o', 'n', 'B', '\014', '\372', 'B', 
-'\t', '\252', '\001', '\006', '*', '\004', '\020', '\300', '\204', '=', 'R', '\013', 'm', 'a', 'x', 'I', 'n', 't', 'e', 'r', 'v', 'a', 'l', ':', '\'', 
-'\232', '\305', '\210', '\036', '\"', '\n', ' ', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'C', 'l', 'u', 's', 't', 
-'e', 'r', '.', 'R', 'e', 'f', 'r', 'e', 's', 'h', 'R', 'a', 't', 'e', '\032', '\203', '\002', '\n', '\020', 'P', 'r', 'e', 'c', 'o', 'n', 
-'n', 'e', 'c', 't', 'P', 'o', 'l', 'i', 'c', 'y', '\022', 'x', '\n', '\035', 'p', 'e', 'r', '_', 'u', 'p', 's', 't', 'r', 'e', 'a', 
-'m', '_', 'p', 'r', 'e', 'c', 'o', 'n', 'n', 'e', 'c', 't', '_', 'r', 'a', 't', 'i', 'o', '\030', '\001', ' ', '\001', '(', '\013', '2', 
-'\034', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'D', 'o', 'u', 'b', 'l', 'e', 'V', 
-'a', 'l', 'u', 'e', 'B', '\027', '\372', 'B', '\024', '\022', '\022', '\031', '\000', '\000', '\000', '\000', '\000', '\000', '\010', '@', ')', '\000', '\000', '\000', '\000', 
-'\000', '\000', '\360', '?', 'R', '\032', 'p', 'e', 'r', 'U', 'p', 's', 't', 'r', 'e', 'a', 'm', 'P', 'r', 'e', 'c', 'o', 'n', 'n', 'e', 
-'c', 't', 'R', 'a', 't', 'i', 'o', '\022', 'u', '\n', '\033', 'p', 'r', 'e', 'd', 'i', 'c', 't', 'i', 'v', 'e', '_', 'p', 'r', 'e', 
-'c', 'o', 'n', 'n', 'e', 'c', 't', '_', 'r', 'a', 't', 'i', 'o', '\030', '\002', ' ', '\001', '(', '\013', '2', '\034', '.', 'g', 'o', 'o', 
-'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'D', 'o', 'u', 'b', 'l', 'e', 'V', 'a', 'l', 'u', 'e', 'B', 
-'\027', '\372', 'B', '\024', '\022', '\022', '\031', '\000', '\000', '\000', '\000', '\000', '\000', '\010', '@', ')', '\000', '\000', '\000', '\000', '\000', '\000', '\360', '?', 'R', 
-'\031', 'p', 'r', 'e', 'd', 'i', 'c', 't', 'i', 'v', 'e', 'P', 'r', 'e', 'c', 'o', 'n', 'n', 'e', 'c', 't', 'R', 'a', 't', 'i', 
-'o', '\032', 'f', '\n', '\"', 'T', 'y', 'p', 'e', 'd', 'E', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 'P', 'r', 'o', 't', 'o', 'c', 
-'o', 'l', 'O', 'p', 't', 'i', 'o', 'n', 's', 'E', 'n', 't', 'r', 'y', '\022', '\020', '\n', '\003', 'k', 'e', 'y', '\030', '\001', ' ', '\001', 
-'(', '\t', 'R', '\003', 'k', 'e', 'y', '\022', '*', '\n', '\005', 'v', 'a', 'l', 'u', 'e', '\030', '\002', ' ', '\001', '(', '\013', '2', '\024', '.', 
-'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'A', 'n', 'y', 'R', '\005', 'v', 'a', 'l', 'u', 
-'e', ':', '\002', '8', '\001', '\"', 'W', '\n', '\r', 'D', 'i', 's', 'c', 'o', 'v', 'e', 'r', 'y', 'T', 'y', 'p', 'e', '\022', '\n', '\n', 
-'\006', 'S', 'T', 'A', 'T', 'I', 'C', '\020', '\000', '\022', '\016', '\n', '\n', 'S', 'T', 'R', 'I', 'C', 'T', '_', 'D', 'N', 'S', '\020', '\001', 
-'\022', '\017', '\n', '\013', 'L', 'O', 'G', 'I', 'C', 'A', 'L', '_', 'D', 'N', 'S', '\020', '\002', '\022', '\007', '\n', '\003', 'E', 'D', 'S', '\020', 
-'\003', '\022', '\020', '\n', '\014', 'O', 'R', 'I', 'G', 'I', 'N', 'A', 'L', '_', 'D', 'S', 'T', '\020', '\004', '\"', '\244', '\001', '\n', '\010', 'L', 
-'b', 'P', 'o', 'l', 'i', 'c', 'y', '\022', '\017', '\n', '\013', 'R', 'O', 'U', 'N', 'D', '_', 'R', 'O', 'B', 'I', 'N', '\020', '\000', '\022', 
-'\021', '\n', '\r', 'L', 'E', 'A', 'S', 'T', '_', 'R', 'E', 'Q', 'U', 'E', 'S', 'T', '\020', '\001', '\022', '\r', '\n', '\t', 'R', 'I', 'N', 
-'G', '_', 'H', 'A', 'S', 'H', '\020', '\002', '\022', '\n', '\n', '\006', 'R', 'A', 'N', 'D', 'O', 'M', '\020', '\003', '\022', '\n', '\n', '\006', 'M', 
-'A', 'G', 'L', 'E', 'V', '\020', '\005', '\022', '\024', '\n', '\020', 'C', 'L', 'U', 'S', 'T', 'E', 'R', '_', 'P', 'R', 'O', 'V', 'I', 'D', 
-'E', 'D', '\020', '\006', '\022', ' ', '\n', '\034', 'L', 'O', 'A', 'D', '_', 'B', 'A', 'L', 'A', 'N', 'C', 'I', 'N', 'G', '_', 'P', 'O', 
-'L', 'I', 'C', 'Y', '_', 'C', 'O', 'N', 'F', 'I', 'G', '\020', '\007', '\"', '\004', '\010', '\004', '\020', '\004', '*', '\017', 'O', 'R', 'I', 'G', 
-'I', 'N', 'A', 'L', '_', 'D', 'S', 'T', '_', 'L', 'B', '\"', '5', '\n', '\017', 'D', 'n', 's', 'L', 'o', 'o', 'k', 'u', 'p', 'F', 
-'a', 'm', 'i', 'l', 'y', '\022', '\010', '\n', '\004', 'A', 'U', 'T', 'O', '\020', '\000', '\022', '\013', '\n', '\007', 'V', '4', '_', 'O', 'N', 'L', 
-'Y', '\020', '\001', '\022', '\013', '\n', '\007', 'V', '6', '_', 'O', 'N', 'L', 'Y', '\020', '\002', '\"', 'T', '\n', '\030', 'C', 'l', 'u', 's', 't', 
-'e', 'r', 'P', 'r', 'o', 't', 'o', 'c', 'o', 'l', 'S', 'e', 'l', 'e', 'c', 't', 'i', 'o', 'n', '\022', '\033', '\n', '\027', 'U', 'S', 
-'E', '_', 'C', 'O', 'N', 'F', 'I', 'G', 'U', 'R', 'E', 'D', '_', 'P', 'R', 'O', 'T', 'O', 'C', 'O', 'L', '\020', '\000', '\022', '\033', 
-'\n', '\027', 'U', 'S', 'E', '_', 'D', 'O', 'W', 'N', 'S', 'T', 'R', 'E', 'A', 'M', '_', 'P', 'R', 'O', 'T', 'O', 'C', 'O', 'L', 
-'\020', '\001', ':', '\033', '\232', '\305', '\210', '\036', '\026', '\n', '\024', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'C', 
-'l', 'u', 's', 't', 'e', 'r', 'B', '\030', '\n', '\026', 'c', 'l', 'u', 's', 't', 'e', 'r', '_', 'd', 'i', 's', 'c', 'o', 'v', 'e', 
-'r', 'y', '_', 't', 'y', 'p', 'e', 'B', '\013', '\n', '\t', 'l', 'b', '_', 'c', 'o', 'n', 'f', 'i', 'g', 'J', '\004', '\010', '\014', '\020', 
-'\r', 'J', '\004', '\010', '\017', '\020', '\020', 'J', '\004', '\010', '\007', '\020', '\010', 'J', '\004', '\010', '\013', '\020', '\014', 'J', '\004', '\010', '#', '\020', '$', 
-'R', '\005', 'h', 'o', 's', 't', 's', 'R', '\013', 't', 'l', 's', '_', 'c', 'o', 'n', 't', 'e', 'x', 't', 'R', '\032', 'e', 'x', 't', 
-'e', 'n', 's', 'i', 'o', 'n', '_', 'p', 'r', 'o', 't', 'o', 'c', 'o', 'l', '_', 'o', 'p', 't', 'i', 'o', 'n', 's', '\"', '\245', 
-'\002', '\n', '\023', 'L', 'o', 'a', 'd', 'B', 'a', 'l', 'a', 'n', 'c', 'i', 'n', 'g', 'P', 'o', 'l', 'i', 'c', 'y', '\022', 'O', '\n', 
-'\010', 'p', 'o', 'l', 'i', 'c', 'i', 'e', 's', '\030', '\001', ' ', '\003', '(', '\013', '2', '3', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 
-'o', 'n', 'f', 'i', 'g', '.', 'c', 'l', 'u', 's', 't', 'e', 'r', '.', 'v', '3', '.', 'L', 'o', 'a', 'd', 'B', 'a', 'l', 'a', 
-'n', 'c', 'i', 'n', 'g', 'P', 'o', 'l', 'i', 'c', 'y', '.', 'P', 'o', 'l', 'i', 'c', 'y', 'R', '\010', 'p', 'o', 'l', 'i', 'c', 
-'i', 'e', 's', '\032', '\223', '\001', '\n', '\006', 'P', 'o', 'l', 'i', 'c', 'y', '\022', '\022', '\n', '\004', 'n', 'a', 'm', 'e', '\030', '\001', ' ', 
-'\001', '(', '\t', 'R', '\004', 'n', 'a', 'm', 'e', '\022', '7', '\n', '\014', 't', 'y', 'p', 'e', 'd', '_', 'c', 'o', 'n', 'f', 'i', 'g', 
-'\030', '\003', ' ', '\001', '(', '\013', '2', '\024', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 
-'A', 'n', 'y', 'R', '\013', 't', 'y', 'p', 'e', 'd', 'C', 'o', 'n', 'f', 'i', 'g', ':', '.', '\232', '\305', '\210', '\036', ')', '\n', '\'', 
-'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'L', 'o', 'a', 'd', 'B', 'a', 'l', 'a', 'n', 'c', 'i', 'n', 
-'g', 'P', 'o', 'l', 'i', 'c', 'y', '.', 'P', 'o', 'l', 'i', 'c', 'y', 'J', '\004', '\010', '\002', '\020', '\003', 'R', '\006', 'c', 'o', 'n', 
-'f', 'i', 'g', ':', '\'', '\232', '\305', '\210', '\036', '\"', '\n', ' ', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 
-'L', 'o', 'a', 'd', 'B', 'a', 'l', 'a', 'n', 'c', 'i', 'n', 'g', 'P', 'o', 'l', 'i', 'c', 'y', '\"', '\202', '\001', '\n', '\022', 'U', 
-'p', 's', 't', 'r', 'e', 'a', 'm', 'B', 'i', 'n', 'd', 'C', 'o', 'n', 'f', 'i', 'g', '\022', 'D', '\n', '\016', 's', 'o', 'u', 'r', 
-'c', 'e', '_', 'a', 'd', 'd', 'r', 'e', 's', 's', '\030', '\001', ' ', '\001', '(', '\013', '2', '\035', '.', 'e', 'n', 'v', 'o', 'y', '.', 
-'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'A', 'd', 'd', 'r', 'e', 's', 's', 'R', '\r', 's', 
-'o', 'u', 'r', 'c', 'e', 'A', 'd', 'd', 'r', 'e', 's', 's', ':', '&', '\232', '\305', '\210', '\036', '!', '\n', '\037', 'e', 'n', 'v', 'o', 
-'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'U', 'p', 's', 't', 'r', 'e', 'a', 'm', 'B', 'i', 'n', 'd', 'C', 'o', 'n', 'f', 
-'i', 'g', '\"', '\223', '\001', '\n', '\031', 'U', 'p', 's', 't', 'r', 'e', 'a', 'm', 'C', 'o', 'n', 'n', 'e', 'c', 't', 'i', 'o', 'n', 
-'O', 'p', 't', 'i', 'o', 'n', 's', '\022', 'G', '\n', '\r', 't', 'c', 'p', '_', 'k', 'e', 'e', 'p', 'a', 'l', 'i', 'v', 'e', '\030', 
-'\001', ' ', '\001', '(', '\013', '2', '\"', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', 
-'.', 'v', '3', '.', 'T', 'c', 'p', 'K', 'e', 'e', 'p', 'a', 'l', 'i', 'v', 'e', 'R', '\014', 't', 'c', 'p', 'K', 'e', 'e', 'p', 
-'a', 'l', 'i', 'v', 'e', ':', '-', '\232', '\305', '\210', '\036', '(', '\n', '&', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', 
-'2', '.', 'U', 'p', 's', 't', 'r', 'e', 'a', 'm', 'C', 'o', 'n', 'n', 'e', 'c', 't', 'i', 'o', 'n', 'O', 'p', 't', 'i', 'o', 
-'n', 's', '\"', 'r', '\n', '\021', 'T', 'r', 'a', 'c', 'k', 'C', 'l', 'u', 's', 't', 'e', 'r', 'S', 't', 'a', 't', 's', '\022', '\'', 
-'\n', '\017', 't', 'i', 'm', 'e', 'o', 'u', 't', '_', 'b', 'u', 'd', 'g', 'e', 't', 's', '\030', '\001', ' ', '\001', '(', '\010', 'R', '\016', 
-'t', 'i', 'm', 'e', 'o', 'u', 't', 'B', 'u', 'd', 'g', 'e', 't', 's', '\022', '4', '\n', '\026', 'r', 'e', 'q', 'u', 'e', 's', 't', 
-'_', 'r', 'e', 's', 'p', 'o', 'n', 's', 'e', '_', 's', 'i', 'z', 'e', 's', '\030', '\002', ' ', '\001', '(', '\010', 'R', '\024', 'r', 'e', 
-'q', 'u', 'e', 's', 't', 'R', 'e', 's', 'p', 'o', 'n', 's', 'e', 'S', 'i', 'z', 'e', 's', 'B', '?', '\n', '%', 'i', 'o', '.', 
-'e', 'n', 'v', 'o', 'y', 'p', 'r', 'o', 'x', 'y', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 
-'l', 'u', 's', 't', 'e', 'r', '.', 'v', '3', 'B', '\014', 'C', 'l', 'u', 's', 't', 'e', 'r', 'P', 'r', 'o', 't', 'o', 'P', '\001', 
-'\272', '\200', '\310', '\321', '\006', '\002', '\020', '\002', 'b', '\006', 'p', 'r', 'o', 't', 'o', '3', 
+'u', 's', 't', 'e', 'r', '.', 'C', 'o', 'm', 'm', 'o', 'n', 'L', 'b', 'C', 'o', 'n', 'f', 'i', 'g', '.', 'Z', 'o', 'n', 'e', 
+'A', 'w', 'a', 'r', 'e', 'L', 'b', 'C', 'o', 'n', 'f', 'i', 'g', 'H', '\000', 'R', '\021', 'z', 'o', 'n', 'e', 'A', 'w', 'a', 'r', 
+'e', 'L', 'b', 'C', 'o', 'n', 'f', 'i', 'g', '\022', '\211', '\001', '\n', '\033', 'l', 'o', 'c', 'a', 'l', 'i', 't', 'y', '_', 'w', 'e', 
+'i', 'g', 'h', 't', 'e', 'd', '_', 'l', 'b', '_', 'c', 'o', 'n', 'f', 'i', 'g', '\030', '\003', ' ', '\001', '(', '\013', '2', 'H', '.', 
+'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'l', 'u', 's', 't', 'e', 'r', '.', 'v', '3', '.', 'C', 
+'l', 'u', 's', 't', 'e', 'r', '.', 'C', 'o', 'm', 'm', 'o', 'n', 'L', 'b', 'C', 'o', 'n', 'f', 'i', 'g', '.', 'L', 'o', 'c', 
+'a', 'l', 'i', 't', 'y', 'W', 'e', 'i', 'g', 'h', 't', 'e', 'd', 'L', 'b', 'C', 'o', 'n', 'f', 'i', 'g', 'H', '\000', 'R', '\030', 
+'l', 'o', 'c', 'a', 'l', 'i', 't', 'y', 'W', 'e', 'i', 'g', 'h', 't', 'e', 'd', 'L', 'b', 'C', 'o', 'n', 'f', 'i', 'g', '\022', 
+'I', '\n', '\023', 'u', 'p', 'd', 'a', 't', 'e', '_', 'm', 'e', 'r', 'g', 'e', '_', 'w', 'i', 'n', 'd', 'o', 'w', '\030', '\004', ' ', 
+'\001', '(', '\013', '2', '\031', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'D', 'u', 'r', 
+'a', 't', 'i', 'o', 'n', 'R', '\021', 'u', 'p', 'd', 'a', 't', 'e', 'M', 'e', 'r', 'g', 'e', 'W', 'i', 'n', 'd', 'o', 'w', '\022', 
+'C', '\n', '\037', 'i', 'g', 'n', 'o', 'r', 'e', '_', 'n', 'e', 'w', '_', 'h', 'o', 's', 't', 's', '_', 'u', 'n', 't', 'i', 'l', 
+'_', 'f', 'i', 'r', 's', 't', '_', 'h', 'c', '\030', '\005', ' ', '\001', '(', '\010', 'R', '\032', 'i', 'g', 'n', 'o', 'r', 'e', 'N', 'e', 
+'w', 'H', 'o', 's', 't', 's', 'U', 'n', 't', 'i', 'l', 'F', 'i', 'r', 's', 't', 'H', 'c', '\022', 'M', '\n', '$', 'c', 'l', 'o', 
+'s', 'e', '_', 'c', 'o', 'n', 'n', 'e', 'c', 't', 'i', 'o', 'n', 's', '_', 'o', 'n', '_', 'h', 'o', 's', 't', '_', 's', 'e', 
+'t', '_', 'c', 'h', 'a', 'n', 'g', 'e', '\030', '\006', ' ', '\001', '(', '\010', 'R', '\037', 'c', 'l', 'o', 's', 'e', 'C', 'o', 'n', 'n', 
+'e', 'c', 't', 'i', 'o', 'n', 's', 'O', 'n', 'H', 'o', 's', 't', 'S', 'e', 't', 'C', 'h', 'a', 'n', 'g', 'e', '\022', '\212', '\001', 
+'\n', '\034', 'c', 'o', 'n', 's', 'i', 's', 't', 'e', 'n', 't', '_', 'h', 'a', 's', 'h', 'i', 'n', 'g', '_', 'l', 'b', '_', 'c', 
+'o', 'n', 'f', 'i', 'g', '\030', '\007', ' ', '\001', '(', '\013', '2', 'I', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 
+'g', '.', 'c', 'l', 'u', 's', 't', 'e', 'r', '.', 'v', '3', '.', 'C', 'l', 'u', 's', 't', 'e', 'r', '.', 'C', 'o', 'm', 'm', 
+'o', 'n', 'L', 'b', 'C', 'o', 'n', 'f', 'i', 'g', '.', 'C', 'o', 'n', 's', 'i', 's', 't', 'e', 'n', 't', 'H', 'a', 's', 'h', 
+'i', 'n', 'g', 'L', 'b', 'C', 'o', 'n', 'f', 'i', 'g', 'R', '\031', 'c', 'o', 'n', 's', 'i', 's', 't', 'e', 'n', 't', 'H', 'a', 
+'s', 'h', 'i', 'n', 'g', 'L', 'b', 'C', 'o', 'n', 'f', 'i', 'g', '\032', '\215', '\002', '\n', '\021', 'Z', 'o', 'n', 'e', 'A', 'w', 'a', 
+'r', 'e', 'L', 'b', 'C', 'o', 'n', 'f', 'i', 'g', '\022', '?', '\n', '\017', 'r', 'o', 'u', 't', 'i', 'n', 'g', '_', 'e', 'n', 'a', 
+'b', 'l', 'e', 'd', '\030', '\001', ' ', '\001', '(', '\013', '2', '\026', '.', 'e', 'n', 'v', 'o', 'y', '.', 't', 'y', 'p', 'e', '.', 'v', 
+'3', '.', 'P', 'e', 'r', 'c', 'e', 'n', 't', 'R', '\016', 'r', 'o', 'u', 't', 'i', 'n', 'g', 'E', 'n', 'a', 'b', 'l', 'e', 'd', 
+'\022', 'F', '\n', '\020', 'm', 'i', 'n', '_', 'c', 'l', 'u', 's', 't', 'e', 'r', '_', 's', 'i', 'z', 'e', '\030', '\002', ' ', '\001', '(', 
+'\013', '2', '\034', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'U', 'I', 'n', 't', '6', 
+'4', 'V', 'a', 'l', 'u', 'e', 'R', '\016', 'm', 'i', 'n', 'C', 'l', 'u', 's', 't', 'e', 'r', 'S', 'i', 'z', 'e', '\022', '1', '\n', 
+'\025', 'f', 'a', 'i', 'l', '_', 't', 'r', 'a', 'f', 'f', 'i', 'c', '_', 'o', 'n', '_', 'p', 'a', 'n', 'i', 'c', '\030', '\003', ' ', 
+'\001', '(', '\010', 'R', '\022', 'f', 'a', 'i', 'l', 'T', 'r', 'a', 'f', 'f', 'i', 'c', 'O', 'n', 'P', 'a', 'n', 'i', 'c', ':', '<', 
+'\232', '\305', '\210', '\036', '7', '\n', '5', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'C', 'l', 'u', 's', 't', 
+'e', 'r', '.', 'C', 'o', 'm', 'm', 'o', 'n', 'L', 'b', 'C', 'o', 'n', 'f', 'i', 'g', '.', 'Z', 'o', 'n', 'e', 'A', 'w', 'a', 
+'r', 'e', 'L', 'b', 'C', 'o', 'n', 'f', 'i', 'g', '\032', '_', '\n', '\030', 'L', 'o', 'c', 'a', 'l', 'i', 't', 'y', 'W', 'e', 'i', 
+'g', 'h', 't', 'e', 'd', 'L', 'b', 'C', 'o', 'n', 'f', 'i', 'g', ':', 'C', '\232', '\305', '\210', '\036', '>', '\n', '<', 'e', 'n', 'v', 
+'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'C', 'l', 'u', 's', 't', 'e', 'r', '.', 'C', 'o', 'm', 'm', 'o', 'n', 'L', 
+'b', 'C', 'o', 'n', 'f', 'i', 'g', '.', 'L', 'o', 'c', 'a', 'l', 'i', 't', 'y', 'W', 'e', 'i', 'g', 'h', 't', 'e', 'd', 'L', 
+'b', 'C', 'o', 'n', 'f', 'i', 'g', '\032', '\361', '\001', '\n', '\031', 'C', 'o', 'n', 's', 'i', 's', 't', 'e', 'n', 't', 'H', 'a', 's', 
+'h', 'i', 'n', 'g', 'L', 'b', 'C', 'o', 'n', 'f', 'i', 'g', '\022', '7', '\n', '\030', 'u', 's', 'e', '_', 'h', 'o', 's', 't', 'n', 
+'a', 'm', 'e', '_', 'f', 'o', 'r', '_', 'h', 'a', 's', 'h', 'i', 'n', 'g', '\030', '\001', ' ', '\001', '(', '\010', 'R', '\025', 'u', 's', 
+'e', 'H', 'o', 's', 't', 'n', 'a', 'm', 'e', 'F', 'o', 'r', 'H', 'a', 's', 'h', 'i', 'n', 'g', '\022', 'U', '\n', '\023', 'h', 'a', 
+'s', 'h', '_', 'b', 'a', 'l', 'a', 'n', 'c', 'e', '_', 'f', 'a', 'c', 't', 'o', 'r', '\030', '\002', ' ', '\001', '(', '\013', '2', '\034', 
+'.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'U', 'I', 'n', 't', '3', '2', 'V', 'a', 
+'l', 'u', 'e', 'B', '\007', '\372', 'B', '\004', '*', '\002', '(', 'd', 'R', '\021', 'h', 'a', 's', 'h', 'B', 'a', 'l', 'a', 'n', 'c', 'e', 
+'F', 'a', 'c', 't', 'o', 'r', ':', 'D', '\232', '\305', '\210', '\036', '?', '\n', '=', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 
+'v', '2', '.', 'C', 'l', 'u', 's', 't', 'e', 'r', '.', 'C', 'o', 'm', 'm', 'o', 'n', 'L', 'b', 'C', 'o', 'n', 'f', 'i', 'g', 
+'.', 'C', 'o', 'n', 's', 'i', 's', 't', 'e', 'n', 't', 'H', 'a', 's', 'h', 'i', 'n', 'g', 'L', 'b', 'C', 'o', 'n', 'f', 'i', 
+'g', ':', '*', '\232', '\305', '\210', '\036', '%', '\n', '#', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'C', 'l', 
+'u', 's', 't', 'e', 'r', '.', 'C', 'o', 'm', 'm', 'o', 'n', 'L', 'b', 'C', 'o', 'n', 'f', 'i', 'g', 'B', '\033', '\n', '\031', 'l', 
+'o', 'c', 'a', 'l', 'i', 't', 'y', '_', 'c', 'o', 'n', 'f', 'i', 'g', '_', 's', 'p', 'e', 'c', 'i', 'f', 'i', 'e', 'r', '\032', 
+'\322', '\001', '\n', '\013', 'R', 'e', 'f', 'r', 'e', 's', 'h', 'R', 'a', 't', 'e', '\022', 'N', '\n', '\r', 'b', 'a', 's', 'e', '_', 'i', 
+'n', 't', 'e', 'r', 'v', 'a', 'l', '\030', '\001', ' ', '\001', '(', '\013', '2', '\031', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 
+'o', 't', 'o', 'b', 'u', 'f', '.', 'D', 'u', 'r', 'a', 't', 'i', 'o', 'n', 'B', '\016', '\372', 'B', '\013', '\252', '\001', '\010', '\010', '\001', 
+'*', '\004', '\020', '\300', '\204', '=', 'R', '\014', 'b', 'a', 's', 'e', 'I', 'n', 't', 'e', 'r', 'v', 'a', 'l', '\022', 'J', '\n', '\014', 'm', 
+'a', 'x', '_', 'i', 'n', 't', 'e', 'r', 'v', 'a', 'l', '\030', '\002', ' ', '\001', '(', '\013', '2', '\031', '.', 'g', 'o', 'o', 'g', 'l', 
+'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'D', 'u', 'r', 'a', 't', 'i', 'o', 'n', 'B', '\014', '\372', 'B', '\t', '\252', 
+'\001', '\006', '*', '\004', '\020', '\300', '\204', '=', 'R', '\013', 'm', 'a', 'x', 'I', 'n', 't', 'e', 'r', 'v', 'a', 'l', ':', '\'', '\232', '\305', 
+'\210', '\036', '\"', '\n', ' ', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'C', 'l', 'u', 's', 't', 'e', 'r', 
+'.', 'R', 'e', 'f', 'r', 'e', 's', 'h', 'R', 'a', 't', 'e', '\032', '\203', '\002', '\n', '\020', 'P', 'r', 'e', 'c', 'o', 'n', 'n', 'e', 
+'c', 't', 'P', 'o', 'l', 'i', 'c', 'y', '\022', 'x', '\n', '\035', 'p', 'e', 'r', '_', 'u', 'p', 's', 't', 'r', 'e', 'a', 'm', '_', 
+'p', 'r', 'e', 'c', 'o', 'n', 'n', 'e', 'c', 't', '_', 'r', 'a', 't', 'i', 'o', '\030', '\001', ' ', '\001', '(', '\013', '2', '\034', '.', 
+'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'D', 'o', 'u', 'b', 'l', 'e', 'V', 'a', 'l', 
+'u', 'e', 'B', '\027', '\372', 'B', '\024', '\022', '\022', '\031', '\000', '\000', '\000', '\000', '\000', '\000', '\010', '@', ')', '\000', '\000', '\000', '\000', '\000', '\000', 
+'\360', '?', 'R', '\032', 'p', 'e', 'r', 'U', 'p', 's', 't', 'r', 'e', 'a', 'm', 'P', 'r', 'e', 'c', 'o', 'n', 'n', 'e', 'c', 't', 
+'R', 'a', 't', 'i', 'o', '\022', 'u', '\n', '\033', 'p', 'r', 'e', 'd', 'i', 'c', 't', 'i', 'v', 'e', '_', 'p', 'r', 'e', 'c', 'o', 
+'n', 'n', 'e', 'c', 't', '_', 'r', 'a', 't', 'i', 'o', '\030', '\002', ' ', '\001', '(', '\013', '2', '\034', '.', 'g', 'o', 'o', 'g', 'l', 
+'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'D', 'o', 'u', 'b', 'l', 'e', 'V', 'a', 'l', 'u', 'e', 'B', '\027', '\372', 
+'B', '\024', '\022', '\022', '\031', '\000', '\000', '\000', '\000', '\000', '\000', '\010', '@', ')', '\000', '\000', '\000', '\000', '\000', '\000', '\360', '?', 'R', '\031', 'p', 
+'r', 'e', 'd', 'i', 'c', 't', 'i', 'v', 'e', 'P', 'r', 'e', 'c', 'o', 'n', 'n', 'e', 'c', 't', 'R', 'a', 't', 'i', 'o', '\032', 
+'f', '\n', '\"', 'T', 'y', 'p', 'e', 'd', 'E', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 'P', 'r', 'o', 't', 'o', 'c', 'o', 'l', 
+'O', 'p', 't', 'i', 'o', 'n', 's', 'E', 'n', 't', 'r', 'y', '\022', '\020', '\n', '\003', 'k', 'e', 'y', '\030', '\001', ' ', '\001', '(', '\t', 
+'R', '\003', 'k', 'e', 'y', '\022', '*', '\n', '\005', 'v', 'a', 'l', 'u', 'e', '\030', '\002', ' ', '\001', '(', '\013', '2', '\024', '.', 'g', 'o', 
+'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'A', 'n', 'y', 'R', '\005', 'v', 'a', 'l', 'u', 'e', ':', 
+'\002', '8', '\001', '\"', 'W', '\n', '\r', 'D', 'i', 's', 'c', 'o', 'v', 'e', 'r', 'y', 'T', 'y', 'p', 'e', '\022', '\n', '\n', '\006', 'S', 
+'T', 'A', 'T', 'I', 'C', '\020', '\000', '\022', '\016', '\n', '\n', 'S', 'T', 'R', 'I', 'C', 'T', '_', 'D', 'N', 'S', '\020', '\001', '\022', '\017', 
+'\n', '\013', 'L', 'O', 'G', 'I', 'C', 'A', 'L', '_', 'D', 'N', 'S', '\020', '\002', '\022', '\007', '\n', '\003', 'E', 'D', 'S', '\020', '\003', '\022', 
+'\020', '\n', '\014', 'O', 'R', 'I', 'G', 'I', 'N', 'A', 'L', '_', 'D', 'S', 'T', '\020', '\004', '\"', '\244', '\001', '\n', '\010', 'L', 'b', 'P', 
+'o', 'l', 'i', 'c', 'y', '\022', '\017', '\n', '\013', 'R', 'O', 'U', 'N', 'D', '_', 'R', 'O', 'B', 'I', 'N', '\020', '\000', '\022', '\021', '\n', 
+'\r', 'L', 'E', 'A', 'S', 'T', '_', 'R', 'E', 'Q', 'U', 'E', 'S', 'T', '\020', '\001', '\022', '\r', '\n', '\t', 'R', 'I', 'N', 'G', '_', 
+'H', 'A', 'S', 'H', '\020', '\002', '\022', '\n', '\n', '\006', 'R', 'A', 'N', 'D', 'O', 'M', '\020', '\003', '\022', '\n', '\n', '\006', 'M', 'A', 'G', 
+'L', 'E', 'V', '\020', '\005', '\022', '\024', '\n', '\020', 'C', 'L', 'U', 'S', 'T', 'E', 'R', '_', 'P', 'R', 'O', 'V', 'I', 'D', 'E', 'D', 
+'\020', '\006', '\022', ' ', '\n', '\034', 'L', 'O', 'A', 'D', '_', 'B', 'A', 'L', 'A', 'N', 'C', 'I', 'N', 'G', '_', 'P', 'O', 'L', 'I', 
+'C', 'Y', '_', 'C', 'O', 'N', 'F', 'I', 'G', '\020', '\007', '\"', '\004', '\010', '\004', '\020', '\004', '*', '\017', 'O', 'R', 'I', 'G', 'I', 'N', 
+'A', 'L', '_', 'D', 'S', 'T', '_', 'L', 'B', '\"', '5', '\n', '\017', 'D', 'n', 's', 'L', 'o', 'o', 'k', 'u', 'p', 'F', 'a', 'm', 
+'i', 'l', 'y', '\022', '\010', '\n', '\004', 'A', 'U', 'T', 'O', '\020', '\000', '\022', '\013', '\n', '\007', 'V', '4', '_', 'O', 'N', 'L', 'Y', '\020', 
+'\001', '\022', '\013', '\n', '\007', 'V', '6', '_', 'O', 'N', 'L', 'Y', '\020', '\002', '\"', 'T', '\n', '\030', 'C', 'l', 'u', 's', 't', 'e', 'r', 
+'P', 'r', 'o', 't', 'o', 'c', 'o', 'l', 'S', 'e', 'l', 'e', 'c', 't', 'i', 'o', 'n', '\022', '\033', '\n', '\027', 'U', 'S', 'E', '_', 
+'C', 'O', 'N', 'F', 'I', 'G', 'U', 'R', 'E', 'D', '_', 'P', 'R', 'O', 'T', 'O', 'C', 'O', 'L', '\020', '\000', '\022', '\033', '\n', '\027', 
+'U', 'S', 'E', '_', 'D', 'O', 'W', 'N', 'S', 'T', 'R', 'E', 'A', 'M', '_', 'P', 'R', 'O', 'T', 'O', 'C', 'O', 'L', '\020', '\001', 
+':', '\033', '\232', '\305', '\210', '\036', '\026', '\n', '\024', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'C', 'l', 'u', 
+'s', 't', 'e', 'r', 'B', '\030', '\n', '\026', 'c', 'l', 'u', 's', 't', 'e', 'r', '_', 'd', 'i', 's', 'c', 'o', 'v', 'e', 'r', 'y', 
+'_', 't', 'y', 'p', 'e', 'B', '\013', '\n', '\t', 'l', 'b', '_', 'c', 'o', 'n', 'f', 'i', 'g', 'J', '\004', '\010', '\014', '\020', '\r', 'J', 
+'\004', '\010', '\017', '\020', '\020', 'J', '\004', '\010', '\007', '\020', '\010', 'J', '\004', '\010', '\013', '\020', '\014', 'J', '\004', '\010', '#', '\020', '$', 'R', '\005', 
+'h', 'o', 's', 't', 's', 'R', '\013', 't', 'l', 's', '_', 'c', 'o', 'n', 't', 'e', 'x', 't', 'R', '\032', 'e', 'x', 't', 'e', 'n', 
+'s', 'i', 'o', 'n', '_', 'p', 'r', 'o', 't', 'o', 'c', 'o', 'l', '_', 'o', 'p', 't', 'i', 'o', 'n', 's', '\"', '\332', '\002', '\n', 
+'\023', 'L', 'o', 'a', 'd', 'B', 'a', 'l', 'a', 'n', 'c', 'i', 'n', 'g', 'P', 'o', 'l', 'i', 'c', 'y', '\022', 'O', '\n', '\010', 'p', 
+'o', 'l', 'i', 'c', 'i', 'e', 's', '\030', '\001', ' ', '\003', '(', '\013', '2', '3', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 
+'f', 'i', 'g', '.', 'c', 'l', 'u', 's', 't', 'e', 'r', '.', 'v', '3', '.', 'L', 'o', 'a', 'd', 'B', 'a', 'l', 'a', 'n', 'c', 
+'i', 'n', 'g', 'P', 'o', 'l', 'i', 'c', 'y', '.', 'P', 'o', 'l', 'i', 'c', 'y', 'R', '\010', 'p', 'o', 'l', 'i', 'c', 'i', 'e', 
+'s', '\032', '\310', '\001', '\n', '\006', 'P', 'o', 'l', 'i', 'c', 'y', '\022', '`', '\n', '\026', 't', 'y', 'p', 'e', 'd', '_', 'e', 'x', 't', 
+'e', 'n', 's', 'i', 'o', 'n', '_', 'c', 'o', 'n', 'f', 'i', 'g', '\030', '\004', ' ', '\001', '(', '\013', '2', '*', '.', 'e', 'n', 'v', 
+'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'T', 'y', 'p', 'e', 'd', 'E', 'x', 
+'t', 'e', 'n', 's', 'i', 'o', 'n', 'C', 'o', 'n', 'f', 'i', 'g', 'R', '\024', 't', 'y', 'p', 'e', 'd', 'E', 'x', 't', 'e', 'n', 
+'s', 'i', 'o', 'n', 'C', 'o', 'n', 'f', 'i', 'g', ':', '.', '\232', '\305', '\210', '\036', ')', '\n', '\'', 'e', 'n', 'v', 'o', 'y', '.', 
+'a', 'p', 'i', '.', 'v', '2', '.', 'L', 'o', 'a', 'd', 'B', 'a', 'l', 'a', 'n', 'c', 'i', 'n', 'g', 'P', 'o', 'l', 'i', 'c', 
+'y', '.', 'P', 'o', 'l', 'i', 'c', 'y', 'J', '\004', '\010', '\002', '\020', '\003', 'J', '\004', '\010', '\001', '\020', '\002', 'J', '\004', '\010', '\003', '\020', 
+'\004', 'R', '\006', 'c', 'o', 'n', 'f', 'i', 'g', 'R', '\004', 'n', 'a', 'm', 'e', 'R', '\014', 't', 'y', 'p', 'e', 'd', '_', 'c', 'o', 
+'n', 'f', 'i', 'g', ':', '\'', '\232', '\305', '\210', '\036', '\"', '\n', ' ', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', 
+'.', 'L', 'o', 'a', 'd', 'B', 'a', 'l', 'a', 'n', 'c', 'i', 'n', 'g', 'P', 'o', 'l', 'i', 'c', 'y', '\"', '\202', '\001', '\n', '\022', 
+'U', 'p', 's', 't', 'r', 'e', 'a', 'm', 'B', 'i', 'n', 'd', 'C', 'o', 'n', 'f', 'i', 'g', '\022', 'D', '\n', '\016', 's', 'o', 'u', 
+'r', 'c', 'e', '_', 'a', 'd', 'd', 'r', 'e', 's', 's', '\030', '\001', ' ', '\001', '(', '\013', '2', '\035', '.', 'e', 'n', 'v', 'o', 'y', 
+'.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'A', 'd', 'd', 'r', 'e', 's', 's', 'R', '\r', 
+'s', 'o', 'u', 'r', 'c', 'e', 'A', 'd', 'd', 'r', 'e', 's', 's', ':', '&', '\232', '\305', '\210', '\036', '!', '\n', '\037', 'e', 'n', 'v', 
+'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'U', 'p', 's', 't', 'r', 'e', 'a', 'm', 'B', 'i', 'n', 'd', 'C', 'o', 'n', 
+'f', 'i', 'g', '\"', '\223', '\001', '\n', '\031', 'U', 'p', 's', 't', 'r', 'e', 'a', 'm', 'C', 'o', 'n', 'n', 'e', 'c', 't', 'i', 'o', 
+'n', 'O', 'p', 't', 'i', 'o', 'n', 's', '\022', 'G', '\n', '\r', 't', 'c', 'p', '_', 'k', 'e', 'e', 'p', 'a', 'l', 'i', 'v', 'e', 
+'\030', '\001', ' ', '\001', '(', '\013', '2', '\"', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 
+'e', '.', 'v', '3', '.', 'T', 'c', 'p', 'K', 'e', 'e', 'p', 'a', 'l', 'i', 'v', 'e', 'R', '\014', 't', 'c', 'p', 'K', 'e', 'e', 
+'p', 'a', 'l', 'i', 'v', 'e', ':', '-', '\232', '\305', '\210', '\036', '(', '\n', '&', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 
+'v', '2', '.', 'U', 'p', 's', 't', 'r', 'e', 'a', 'm', 'C', 'o', 'n', 'n', 'e', 'c', 't', 'i', 'o', 'n', 'O', 'p', 't', 'i', 
+'o', 'n', 's', '\"', 'r', '\n', '\021', 'T', 'r', 'a', 'c', 'k', 'C', 'l', 'u', 's', 't', 'e', 'r', 'S', 't', 'a', 't', 's', '\022', 
+'\'', '\n', '\017', 't', 'i', 'm', 'e', 'o', 'u', 't', '_', 'b', 'u', 'd', 'g', 'e', 't', 's', '\030', '\001', ' ', '\001', '(', '\010', 'R', 
+'\016', 't', 'i', 'm', 'e', 'o', 'u', 't', 'B', 'u', 'd', 'g', 'e', 't', 's', '\022', '4', '\n', '\026', 'r', 'e', 'q', 'u', 'e', 's', 
+'t', '_', 'r', 'e', 's', 'p', 'o', 'n', 's', 'e', '_', 's', 'i', 'z', 'e', 's', '\030', '\002', ' ', '\001', '(', '\010', 'R', '\024', 'r', 
+'e', 'q', 'u', 'e', 's', 't', 'R', 'e', 's', 'p', 'o', 'n', 's', 'e', 'S', 'i', 'z', 'e', 's', 'B', '?', '\n', '%', 'i', 'o', 
+'.', 'e', 'n', 'v', 'o', 'y', 'p', 'r', 'o', 'x', 'y', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 
+'c', 'l', 'u', 's', 't', 'e', 'r', '.', 'v', '3', 'B', '\014', 'C', 'l', 'u', 's', 't', 'e', 'r', 'P', 'r', 'o', 't', 'o', 'P', 
+'\001', '\272', '\200', '\310', '\321', '\006', '\002', '\020', '\002', 'b', '\006', 'p', 'r', 'o', 't', 'o', '3', 
 };
 
 static upb_def_init *deps[24] = {
@@ -566,5 +568,5 @@ upb_def_init envoy_config_cluster_v3_cluster_proto_upbdefinit = {
   deps,
   layouts,
   "envoy/config/cluster/v3/cluster.proto",
-  UPB_STRVIEW_INIT(descriptor, 11266)
+  UPB_STRVIEW_INIT(descriptor, 11317)
 };
index ea1dc96..e9ab905 100644 (file)
 
 extern upb_def_init envoy_config_core_v3_address_proto_upbdefinit;
 extern upb_def_init envoy_config_core_v3_base_proto_upbdefinit;
+extern upb_def_init envoy_config_core_v3_config_source_proto_upbdefinit;
 extern upb_def_init envoy_config_core_v3_health_check_proto_upbdefinit;
 extern upb_def_init google_protobuf_wrappers_proto_upbdefinit;
+extern upb_def_init udpa_annotations_migrate_proto_upbdefinit;
 extern upb_def_init udpa_annotations_status_proto_upbdefinit;
 extern upb_def_init udpa_annotations_versioning_proto_upbdefinit;
 extern upb_def_init validate_validate_proto_upbdefinit;
 extern const upb_msglayout envoy_config_endpoint_v3_Endpoint_msginit;
 extern const upb_msglayout envoy_config_endpoint_v3_Endpoint_HealthCheckConfig_msginit;
 extern const upb_msglayout envoy_config_endpoint_v3_LbEndpoint_msginit;
+extern const upb_msglayout envoy_config_endpoint_v3_LedsClusterLocalityConfig_msginit;
 extern const upb_msglayout envoy_config_endpoint_v3_LocalityLbEndpoints_msginit;
+extern const upb_msglayout envoy_config_endpoint_v3_LocalityLbEndpoints_LbEndpointList_msginit;
 
-static const upb_msglayout *layouts[4] = {
+static const upb_msglayout *layouts[6] = {
   &envoy_config_endpoint_v3_Endpoint_msginit,
   &envoy_config_endpoint_v3_Endpoint_HealthCheckConfig_msginit,
   &envoy_config_endpoint_v3_LbEndpoint_msginit,
+  &envoy_config_endpoint_v3_LedsClusterLocalityConfig_msginit,
   &envoy_config_endpoint_v3_LocalityLbEndpoints_msginit,
+  &envoy_config_endpoint_v3_LocalityLbEndpoints_LbEndpointList_msginit,
 };
 
-static const char descriptor[1584] = {'\n', '2', 'e', 'n', 'v', 'o', 'y', '/', 'c', 'o', 'n', 'f', 'i', 'g', '/', 'e', 'n', 'd', 'p', 'o', 'i', 'n', 't', '/', 'v', 
+static const char descriptor[2151] = {'\n', '2', 'e', 'n', 'v', 'o', 'y', '/', 'c', 'o', 'n', 'f', 'i', 'g', '/', 'e', 'n', 'd', 'p', 'o', 'i', 'n', 't', '/', 'v', 
 '3', '/', 'e', 'n', 'd', 'p', 'o', 'i', 'n', 't', '_', 'c', 'o', 'm', 'p', 'o', 'n', 'e', 'n', 't', 's', '.', 'p', 'r', 'o', 
 't', 'o', '\022', '\030', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'e', 'n', 'd', 'p', 'o', 'i', 'n', 't', 
 '.', 'v', '3', '\032', '\"', 'e', 'n', 'v', 'o', 'y', '/', 'c', 'o', 'n', 'f', 'i', 'g', '/', 'c', 'o', 'r', 'e', '/', 'v', '3', 
 '/', 'a', 'd', 'd', 'r', 'e', 's', 's', '.', 'p', 'r', 'o', 't', 'o', '\032', '\037', 'e', 'n', 'v', 'o', 'y', '/', 'c', 'o', 'n', 
-'f', 'i', 'g', '/', 'c', 'o', 'r', 'e', '/', 'v', '3', '/', 'b', 'a', 's', 'e', '.', 'p', 'r', 'o', 't', 'o', '\032', '\'', 'e', 
-'n', 'v', 'o', 'y', '/', 'c', 'o', 'n', 'f', 'i', 'g', '/', 'c', 'o', 'r', 'e', '/', 'v', '3', '/', 'h', 'e', 'a', 'l', 't', 
-'h', '_', 'c', 'h', 'e', 'c', 'k', '.', 'p', 'r', 'o', 't', 'o', '\032', '\036', 'g', 'o', 'o', 'g', 'l', 'e', '/', 'p', 'r', 'o', 
-'t', 'o', 'b', 'u', 'f', '/', 'w', 'r', 'a', 'p', 'p', 'e', 'r', 's', '.', 'p', 'r', 'o', 't', 'o', '\032', '\035', 'u', 'd', 'p', 
-'a', '/', 'a', 'n', 'n', 'o', 't', 'a', 't', 'i', 'o', 'n', 's', '/', 's', 't', 'a', 't', 'u', 's', '.', 'p', 'r', 'o', 't', 
-'o', '\032', '!', 'u', 'd', 'p', 'a', '/', 'a', 'n', 'n', 'o', 't', 'a', 't', 'i', 'o', 'n', 's', '/', 'v', 'e', 'r', 's', 'i', 
-'o', 'n', 'i', 'n', 'g', '.', 'p', 'r', 'o', 't', 'o', '\032', '\027', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'e', '/', 'v', 'a', 'l', 
-'i', 'd', 'a', 't', 'e', '.', 'p', 'r', 'o', 't', 'o', '\"', '\201', '\003', '\n', '\010', 'E', 'n', 'd', 'p', 'o', 'i', 'n', 't', '\022', 
-'7', '\n', '\007', 'a', 'd', 'd', 'r', 'e', 's', 's', '\030', '\001', ' ', '\001', '(', '\013', '2', '\035', '.', 'e', 'n', 'v', 'o', 'y', '.', 
-'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'A', 'd', 'd', 'r', 'e', 's', 's', 'R', '\007', 'a', 
-'d', 'd', 'r', 'e', 's', 's', '\022', 'd', '\n', '\023', 'h', 'e', 'a', 'l', 't', 'h', '_', 'c', 'h', 'e', 'c', 'k', '_', 'c', 'o', 
-'n', 'f', 'i', 'g', '\030', '\002', ' ', '\001', '(', '\013', '2', '4', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', 
-'.', 'e', 'n', 'd', 'p', 'o', 'i', 'n', 't', '.', 'v', '3', '.', 'E', 'n', 'd', 'p', 'o', 'i', 'n', 't', '.', 'H', 'e', 'a', 
-'l', 't', 'h', 'C', 'h', 'e', 'c', 'k', 'C', 'o', 'n', 'f', 'i', 'g', 'R', '\021', 'h', 'e', 'a', 'l', 't', 'h', 'C', 'h', 'e', 
-'c', 'k', 'C', 'o', 'n', 'f', 'i', 'g', '\022', '\032', '\n', '\010', 'h', 'o', 's', 't', 'n', 'a', 'm', 'e', '\030', '\003', ' ', '\001', '(', 
-'\t', 'R', '\010', 'h', 'o', 's', 't', 'n', 'a', 'm', 'e', '\032', '\222', '\001', '\n', '\021', 'H', 'e', 'a', 'l', 't', 'h', 'C', 'h', 'e', 
-'c', 'k', 'C', 'o', 'n', 'f', 'i', 'g', '\022', '(', '\n', '\n', 'p', 'o', 'r', 't', '_', 'v', 'a', 'l', 'u', 'e', '\030', '\001', ' ', 
-'\001', '(', '\r', 'B', '\t', '\372', 'B', '\006', '*', '\004', '\030', '\377', '\377', '\003', 'R', '\t', 'p', 'o', 'r', 't', 'V', 'a', 'l', 'u', 'e', 
-'\022', '\032', '\n', '\010', 'h', 'o', 's', 't', 'n', 'a', 'm', 'e', '\030', '\002', ' ', '\001', '(', '\t', 'R', '\010', 'h', 'o', 's', 't', 'n', 
-'a', 'm', 'e', ':', '7', '\232', '\305', '\210', '\036', '2', '\n', '0', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 
-'e', 'n', 'd', 'p', 'o', 'i', 'n', 't', '.', 'E', 'n', 'd', 'p', 'o', 'i', 'n', 't', '.', 'H', 'e', 'a', 'l', 't', 'h', 'C', 
-'h', 'e', 'c', 'k', 'C', 'o', 'n', 'f', 'i', 'g', ':', '%', '\232', '\305', '\210', '\036', ' ', '\n', '\036', 'e', 'n', 'v', 'o', 'y', '.', 
-'a', 'p', 'i', '.', 'v', '2', '.', 'e', 'n', 'd', 'p', 'o', 'i', 'n', 't', '.', 'E', 'n', 'd', 'p', 'o', 'i', 'n', 't', '\"', 
-'\221', '\003', '\n', '\n', 'L', 'b', 'E', 'n', 'd', 'p', 'o', 'i', 'n', 't', '\022', '@', '\n', '\010', 'e', 'n', 'd', 'p', 'o', 'i', 'n', 
-'t', '\030', '\001', ' ', '\001', '(', '\013', '2', '\"', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'e', 'n', 
-'d', 'p', 'o', 'i', 'n', 't', '.', 'v', '3', '.', 'E', 'n', 'd', 'p', 'o', 'i', 'n', 't', 'H', '\000', 'R', '\010', 'e', 'n', 'd', 
-'p', 'o', 'i', 'n', 't', '\022', '%', '\n', '\r', 'e', 'n', 'd', 'p', 'o', 'i', 'n', 't', '_', 'n', 'a', 'm', 'e', '\030', '\005', ' ', 
-'\001', '(', '\t', 'H', '\000', 'R', '\014', 'e', 'n', 'd', 'p', 'o', 'i', 'n', 't', 'N', 'a', 'm', 'e', '\022', 'G', '\n', '\r', 'h', 'e', 
-'a', 'l', 't', 'h', '_', 's', 't', 'a', 't', 'u', 's', '\030', '\002', ' ', '\001', '(', '\016', '2', '\"', '.', 'e', 'n', 'v', 'o', 'y', 
-'.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'H', 'e', 'a', 'l', 't', 'h', 'S', 't', 'a', 
-'t', 'u', 's', 'R', '\014', 'h', 'e', 'a', 'l', 't', 'h', 'S', 't', 'a', 't', 'u', 's', '\022', ':', '\n', '\010', 'm', 'e', 't', 'a', 
-'d', 'a', 't', 'a', '\030', '\003', ' ', '\001', '(', '\013', '2', '\036', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', 
-'.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'M', 'e', 't', 'a', 'd', 'a', 't', 'a', 'R', '\010', 'm', 'e', 't', 'a', 'd', 'a', 
-'t', 'a', '\022', 'Y', '\n', '\025', 'l', 'o', 'a', 'd', '_', 'b', 'a', 'l', 'a', 'n', 'c', 'i', 'n', 'g', '_', 'w', 'e', 'i', 'g', 
-'h', 't', '\030', '\004', ' ', '\001', '(', '\013', '2', '\034', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 
-'f', '.', 'U', 'I', 'n', 't', '3', '2', 'V', 'a', 'l', 'u', 'e', 'B', '\007', '\372', 'B', '\004', '*', '\002', '(', '\001', 'R', '\023', 'l', 
-'o', 'a', 'd', 'B', 'a', 'l', 'a', 'n', 'c', 'i', 'n', 'g', 'W', 'e', 'i', 'g', 'h', 't', ':', '\'', '\232', '\305', '\210', '\036', '\"', 
-'\n', ' ', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'e', 'n', 'd', 'p', 'o', 'i', 'n', 't', '.', 'L', 
-'b', 'E', 'n', 'd', 'p', 'o', 'i', 'n', 't', 'B', '\021', '\n', '\017', 'h', 'o', 's', 't', '_', 'i', 'd', 'e', 'n', 't', 'i', 'f', 
-'i', 'e', 'r', '\"', '\211', '\003', '\n', '\023', 'L', 'o', 'c', 'a', 'l', 'i', 't', 'y', 'L', 'b', 'E', 'n', 'd', 'p', 'o', 'i', 'n', 
-'t', 's', '\022', ':', '\n', '\010', 'l', 'o', 'c', 'a', 'l', 'i', 't', 'y', '\030', '\001', ' ', '\001', '(', '\013', '2', '\036', '.', 'e', 'n', 
-'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'L', 'o', 'c', 'a', 'l', 'i', 
-'t', 'y', 'R', '\010', 'l', 'o', 'c', 'a', 'l', 'i', 't', 'y', '\022', 'G', '\n', '\014', 'l', 'b', '_', 'e', 'n', 'd', 'p', 'o', 'i', 
-'n', 't', 's', '\030', '\002', ' ', '\003', '(', '\013', '2', '$', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 
-'e', 'n', 'd', 'p', 'o', 'i', 'n', 't', '.', 'v', '3', '.', 'L', 'b', 'E', 'n', 'd', 'p', 'o', 'i', 'n', 't', 'R', '\013', 'l', 
-'b', 'E', 'n', 'd', 'p', 'o', 'i', 'n', 't', 's', '\022', 'Y', '\n', '\025', 'l', 'o', 'a', 'd', '_', 'b', 'a', 'l', 'a', 'n', 'c', 
-'i', 'n', 'g', '_', 'w', 'e', 'i', 'g', 'h', 't', '\030', '\003', ' ', '\001', '(', '\013', '2', '\034', '.', 'g', 'o', 'o', 'g', 'l', 'e', 
-'.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'U', 'I', 'n', 't', '3', '2', 'V', 'a', 'l', 'u', 'e', 'B', '\007', '\372', 'B', 
-'\004', '*', '\002', '(', '\001', 'R', '\023', 'l', 'o', 'a', 'd', 'B', 'a', 'l', 'a', 'n', 'c', 'i', 'n', 'g', 'W', 'e', 'i', 'g', 'h', 
-'t', '\022', '$', '\n', '\010', 'p', 'r', 'i', 'o', 'r', 'i', 't', 'y', '\030', '\005', ' ', '\001', '(', '\r', 'B', '\010', '\372', 'B', '\005', '*', 
-'\003', '\030', '\200', '\001', 'R', '\010', 'p', 'r', 'i', 'o', 'r', 'i', 't', 'y', '\022', ':', '\n', '\t', 'p', 'r', 'o', 'x', 'i', 'm', 'i', 
-'t', 'y', '\030', '\006', ' ', '\001', '(', '\013', '2', '\034', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 
-'f', '.', 'U', 'I', 'n', 't', '3', '2', 'V', 'a', 'l', 'u', 'e', 'R', '\t', 'p', 'r', 'o', 'x', 'i', 'm', 'i', 't', 'y', ':', 
-'0', '\232', '\305', '\210', '\036', '+', '\n', ')', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'e', 'n', 'd', 'p', 
-'o', 'i', 'n', 't', '.', 'L', 'o', 'c', 'a', 'l', 'i', 't', 'y', 'L', 'b', 'E', 'n', 'd', 'p', 'o', 'i', 'n', 't', 's', 'B', 
-'K', '\n', '&', 'i', 'o', '.', 'e', 'n', 'v', 'o', 'y', 'p', 'r', 'o', 'x', 'y', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 
-'n', 'f', 'i', 'g', '.', 'e', 'n', 'd', 'p', 'o', 'i', 'n', 't', '.', 'v', '3', 'B', '\027', 'E', 'n', 'd', 'p', 'o', 'i', 'n', 
-'t', 'C', 'o', 'm', 'p', 'o', 'n', 'e', 'n', 't', 's', 'P', 'r', 'o', 't', 'o', 'P', '\001', '\272', '\200', '\310', '\321', '\006', '\002', '\020', 
-'\002', 'b', '\006', 'p', 'r', 'o', 't', 'o', '3', 
+'f', 'i', 'g', '/', 'c', 'o', 'r', 'e', '/', 'v', '3', '/', 'b', 'a', 's', 'e', '.', 'p', 'r', 'o', 't', 'o', '\032', '(', 'e', 
+'n', 'v', 'o', 'y', '/', 'c', 'o', 'n', 'f', 'i', 'g', '/', 'c', 'o', 'r', 'e', '/', 'v', '3', '/', 'c', 'o', 'n', 'f', 'i', 
+'g', '_', 's', 'o', 'u', 'r', 'c', 'e', '.', 'p', 'r', 'o', 't', 'o', '\032', '\'', 'e', 'n', 'v', 'o', 'y', '/', 'c', 'o', 'n', 
+'f', 'i', 'g', '/', 'c', 'o', 'r', 'e', '/', 'v', '3', '/', 'h', 'e', 'a', 'l', 't', 'h', '_', 'c', 'h', 'e', 'c', 'k', '.', 
+'p', 'r', 'o', 't', 'o', '\032', '\036', 'g', 'o', 'o', 'g', 'l', 'e', '/', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '/', 'w', 'r', 
+'a', 'p', 'p', 'e', 'r', 's', '.', 'p', 'r', 'o', 't', 'o', '\032', '\036', 'u', 'd', 'p', 'a', '/', 'a', 'n', 'n', 'o', 't', 'a', 
+'t', 'i', 'o', 'n', 's', '/', 'm', 'i', 'g', 'r', 'a', 't', 'e', '.', 'p', 'r', 'o', 't', 'o', '\032', '\035', 'u', 'd', 'p', 'a', 
+'/', 'a', 'n', 'n', 'o', 't', 'a', 't', 'i', 'o', 'n', 's', '/', 's', 't', 'a', 't', 'u', 's', '.', 'p', 'r', 'o', 't', 'o', 
+'\032', '!', 'u', 'd', 'p', 'a', '/', 'a', 'n', 'n', 'o', 't', 'a', 't', 'i', 'o', 'n', 's', '/', 'v', 'e', 'r', 's', 'i', 'o', 
+'n', 'i', 'n', 'g', '.', 'p', 'r', 'o', 't', 'o', '\032', '\027', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'e', '/', 'v', 'a', 'l', 'i', 
+'d', 'a', 't', 'e', '.', 'p', 'r', 'o', 't', 'o', '\"', '\201', '\003', '\n', '\010', 'E', 'n', 'd', 'p', 'o', 'i', 'n', 't', '\022', '7', 
+'\n', '\007', 'a', 'd', 'd', 'r', 'e', 's', 's', '\030', '\001', ' ', '\001', '(', '\013', '2', '\035', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 
+'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'A', 'd', 'd', 'r', 'e', 's', 's', 'R', '\007', 'a', 'd', 
+'d', 'r', 'e', 's', 's', '\022', 'd', '\n', '\023', 'h', 'e', 'a', 'l', 't', 'h', '_', 'c', 'h', 'e', 'c', 'k', '_', 'c', 'o', 'n', 
+'f', 'i', 'g', '\030', '\002', ' ', '\001', '(', '\013', '2', '4', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 
+'e', 'n', 'd', 'p', 'o', 'i', 'n', 't', '.', 'v', '3', '.', 'E', 'n', 'd', 'p', 'o', 'i', 'n', 't', '.', 'H', 'e', 'a', 'l', 
+'t', 'h', 'C', 'h', 'e', 'c', 'k', 'C', 'o', 'n', 'f', 'i', 'g', 'R', '\021', 'h', 'e', 'a', 'l', 't', 'h', 'C', 'h', 'e', 'c', 
+'k', 'C', 'o', 'n', 'f', 'i', 'g', '\022', '\032', '\n', '\010', 'h', 'o', 's', 't', 'n', 'a', 'm', 'e', '\030', '\003', ' ', '\001', '(', '\t', 
+'R', '\010', 'h', 'o', 's', 't', 'n', 'a', 'm', 'e', '\032', '\222', '\001', '\n', '\021', 'H', 'e', 'a', 'l', 't', 'h', 'C', 'h', 'e', 'c', 
+'k', 'C', 'o', 'n', 'f', 'i', 'g', '\022', '(', '\n', '\n', 'p', 'o', 'r', 't', '_', 'v', 'a', 'l', 'u', 'e', '\030', '\001', ' ', '\001', 
+'(', '\r', 'B', '\t', '\372', 'B', '\006', '*', '\004', '\030', '\377', '\377', '\003', 'R', '\t', 'p', 'o', 'r', 't', 'V', 'a', 'l', 'u', 'e', '\022', 
+'\032', '\n', '\010', 'h', 'o', 's', 't', 'n', 'a', 'm', 'e', '\030', '\002', ' ', '\001', '(', '\t', 'R', '\010', 'h', 'o', 's', 't', 'n', 'a', 
+'m', 'e', ':', '7', '\232', '\305', '\210', '\036', '2', '\n', '0', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'e', 
+'n', 'd', 'p', 'o', 'i', 'n', 't', '.', 'E', 'n', 'd', 'p', 'o', 'i', 'n', 't', '.', 'H', 'e', 'a', 'l', 't', 'h', 'C', 'h', 
+'e', 'c', 'k', 'C', 'o', 'n', 'f', 'i', 'g', ':', '%', '\232', '\305', '\210', '\036', ' ', '\n', '\036', 'e', 'n', 'v', 'o', 'y', '.', 'a', 
+'p', 'i', '.', 'v', '2', '.', 'e', 'n', 'd', 'p', 'o', 'i', 'n', 't', '.', 'E', 'n', 'd', 'p', 'o', 'i', 'n', 't', '\"', '\221', 
+'\003', '\n', '\n', 'L', 'b', 'E', 'n', 'd', 'p', 'o', 'i', 'n', 't', '\022', '@', '\n', '\010', 'e', 'n', 'd', 'p', 'o', 'i', 'n', 't', 
+'\030', '\001', ' ', '\001', '(', '\013', '2', '\"', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'e', 'n', 'd', 
+'p', 'o', 'i', 'n', 't', '.', 'v', '3', '.', 'E', 'n', 'd', 'p', 'o', 'i', 'n', 't', 'H', '\000', 'R', '\010', 'e', 'n', 'd', 'p', 
+'o', 'i', 'n', 't', '\022', '%', '\n', '\r', 'e', 'n', 'd', 'p', 'o', 'i', 'n', 't', '_', 'n', 'a', 'm', 'e', '\030', '\005', ' ', '\001', 
+'(', '\t', 'H', '\000', 'R', '\014', 'e', 'n', 'd', 'p', 'o', 'i', 'n', 't', 'N', 'a', 'm', 'e', '\022', 'G', '\n', '\r', 'h', 'e', 'a', 
+'l', 't', 'h', '_', 's', 't', 'a', 't', 'u', 's', '\030', '\002', ' ', '\001', '(', '\016', '2', '\"', '.', 'e', 'n', 'v', 'o', 'y', '.', 
+'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'H', 'e', 'a', 'l', 't', 'h', 'S', 't', 'a', 't', 
+'u', 's', 'R', '\014', 'h', 'e', 'a', 'l', 't', 'h', 'S', 't', 'a', 't', 'u', 's', '\022', ':', '\n', '\010', 'm', 'e', 't', 'a', 'd', 
+'a', 't', 'a', '\030', '\003', ' ', '\001', '(', '\013', '2', '\036', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 
+'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'M', 'e', 't', 'a', 'd', 'a', 't', 'a', 'R', '\010', 'm', 'e', 't', 'a', 'd', 'a', 't', 
+'a', '\022', 'Y', '\n', '\025', 'l', 'o', 'a', 'd', '_', 'b', 'a', 'l', 'a', 'n', 'c', 'i', 'n', 'g', '_', 'w', 'e', 'i', 'g', 'h', 
+'t', '\030', '\004', ' ', '\001', '(', '\013', '2', '\034', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', 
+'.', 'U', 'I', 'n', 't', '3', '2', 'V', 'a', 'l', 'u', 'e', 'B', '\007', '\372', 'B', '\004', '*', '\002', '(', '\001', 'R', '\023', 'l', 'o', 
+'a', 'd', 'B', 'a', 'l', 'a', 'n', 'c', 'i', 'n', 'g', 'W', 'e', 'i', 'g', 'h', 't', ':', '\'', '\232', '\305', '\210', '\036', '\"', '\n', 
+' ', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'e', 'n', 'd', 'p', 'o', 'i', 'n', 't', '.', 'L', 'b', 
+'E', 'n', 'd', 'p', 'o', 'i', 'n', 't', 'B', '\021', '\n', '\017', 'h', 'o', 's', 't', '_', 'i', 'd', 'e', 'n', 't', 'i', 'f', 'i', 
+'e', 'r', '\"', '\222', '\001', '\n', '\031', 'L', 'e', 'd', 's', 'C', 'l', 'u', 's', 't', 'e', 'r', 'L', 'o', 'c', 'a', 'l', 'i', 't', 
+'y', 'C', 'o', 'n', 'f', 'i', 'g', '\022', 'C', '\n', '\013', 'l', 'e', 'd', 's', '_', 'c', 'o', 'n', 'f', 'i', 'g', '\030', '\001', ' ', 
+'\001', '(', '\013', '2', '\"', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', 
+'3', '.', 'C', 'o', 'n', 'f', 'i', 'g', 'S', 'o', 'u', 'r', 'c', 'e', 'R', '\n', 'l', 'e', 'd', 's', 'C', 'o', 'n', 'f', 'i', 
+'g', '\022', '0', '\n', '\024', 'l', 'e', 'd', 's', '_', 'c', 'o', 'l', 'l', 'e', 'c', 't', 'i', 'o', 'n', '_', 'n', 'a', 'm', 'e', 
+'\030', '\002', ' ', '\001', '(', '\t', 'R', '\022', 'l', 'e', 'd', 's', 'C', 'o', 'l', 'l', 'e', 'c', 't', 'i', 'o', 'n', 'N', 'a', 'm', 
+'e', '\"', '\341', '\005', '\n', '\023', 'L', 'o', 'c', 'a', 'l', 'i', 't', 'y', 'L', 'b', 'E', 'n', 'd', 'p', 'o', 'i', 'n', 't', 's', 
+'\022', ':', '\n', '\010', 'l', 'o', 'c', 'a', 'l', 'i', 't', 'y', '\030', '\001', ' ', '\001', '(', '\013', '2', '\036', '.', 'e', 'n', 'v', 'o', 
+'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'L', 'o', 'c', 'a', 'l', 'i', 't', 'y', 
+'R', '\010', 'l', 'o', 'c', 'a', 'l', 'i', 't', 'y', '\022', 'G', '\n', '\014', 'l', 'b', '_', 'e', 'n', 'd', 'p', 'o', 'i', 'n', 't', 
+'s', '\030', '\002', ' ', '\003', '(', '\013', '2', '$', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'e', 'n', 
+'d', 'p', 'o', 'i', 'n', 't', '.', 'v', '3', '.', 'L', 'b', 'E', 'n', 'd', 'p', 'o', 'i', 'n', 't', 'R', '\013', 'l', 'b', 'E', 
+'n', 'd', 'p', 'o', 'i', 'n', 't', 's', '\022', 'v', '\n', '\027', 'l', 'o', 'a', 'd', '_', 'b', 'a', 'l', 'a', 'n', 'c', 'e', 'r', 
+'_', 'e', 'n', 'd', 'p', 'o', 'i', 'n', 't', 's', '\030', '\007', ' ', '\001', '(', '\013', '2', '<', '.', 'e', 'n', 'v', 'o', 'y', '.', 
+'c', 'o', 'n', 'f', 'i', 'g', '.', 'e', 'n', 'd', 'p', 'o', 'i', 'n', 't', '.', 'v', '3', '.', 'L', 'o', 'c', 'a', 'l', 'i', 
+'t', 'y', 'L', 'b', 'E', 'n', 'd', 'p', 'o', 'i', 'n', 't', 's', '.', 'L', 'b', 'E', 'n', 'd', 'p', 'o', 'i', 'n', 't', 'L', 
+'i', 's', 't', 'H', '\000', 'R', '\025', 'l', 'o', 'a', 'd', 'B', 'a', 'l', 'a', 'n', 'c', 'e', 'r', 'E', 'n', 'd', 'p', 'o', 'i', 
+'n', 't', 's', '\022', 'v', '\n', '\034', 'l', 'e', 'd', 's', '_', 'c', 'l', 'u', 's', 't', 'e', 'r', '_', 'l', 'o', 'c', 'a', 'l', 
+'i', 't', 'y', '_', 'c', 'o', 'n', 'f', 'i', 'g', '\030', '\010', ' ', '\001', '(', '\013', '2', '3', '.', 'e', 'n', 'v', 'o', 'y', '.', 
+'c', 'o', 'n', 'f', 'i', 'g', '.', 'e', 'n', 'd', 'p', 'o', 'i', 'n', 't', '.', 'v', '3', '.', 'L', 'e', 'd', 's', 'C', 'l', 
+'u', 's', 't', 'e', 'r', 'L', 'o', 'c', 'a', 'l', 'i', 't', 'y', 'C', 'o', 'n', 'f', 'i', 'g', 'H', '\000', 'R', '\031', 'l', 'e', 
+'d', 's', 'C', 'l', 'u', 's', 't', 'e', 'r', 'L', 'o', 'c', 'a', 'l', 'i', 't', 'y', 'C', 'o', 'n', 'f', 'i', 'g', '\022', 'Y', 
+'\n', '\025', 'l', 'o', 'a', 'd', '_', 'b', 'a', 'l', 'a', 'n', 'c', 'i', 'n', 'g', '_', 'w', 'e', 'i', 'g', 'h', 't', '\030', '\003', 
+' ', '\001', '(', '\013', '2', '\034', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'U', 'I', 
+'n', 't', '3', '2', 'V', 'a', 'l', 'u', 'e', 'B', '\007', '\372', 'B', '\004', '*', '\002', '(', '\001', 'R', '\023', 'l', 'o', 'a', 'd', 'B', 
+'a', 'l', 'a', 'n', 'c', 'i', 'n', 'g', 'W', 'e', 'i', 'g', 'h', 't', '\022', '$', '\n', '\010', 'p', 'r', 'i', 'o', 'r', 'i', 't', 
+'y', '\030', '\005', ' ', '\001', '(', '\r', 'B', '\010', '\372', 'B', '\005', '*', '\003', '\030', '\200', '\001', 'R', '\010', 'p', 'r', 'i', 'o', 'r', 'i', 
+'t', 'y', '\022', ':', '\n', '\t', 'p', 'r', 'o', 'x', 'i', 'm', 'i', 't', 'y', '\030', '\006', ' ', '\001', '(', '\013', '2', '\034', '.', 'g', 
+'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'U', 'I', 'n', 't', '3', '2', 'V', 'a', 'l', 'u', 
+'e', 'R', '\t', 'p', 'r', 'o', 'x', 'i', 'm', 'i', 't', 'y', '\032', 'Y', '\n', '\016', 'L', 'b', 'E', 'n', 'd', 'p', 'o', 'i', 'n', 
+'t', 'L', 'i', 's', 't', '\022', 'G', '\n', '\014', 'l', 'b', '_', 'e', 'n', 'd', 'p', 'o', 'i', 'n', 't', 's', '\030', '\001', ' ', '\003', 
+'(', '\013', '2', '$', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'e', 'n', 'd', 'p', 'o', 'i', 'n', 
+'t', '.', 'v', '3', '.', 'L', 'b', 'E', 'n', 'd', 'p', 'o', 'i', 'n', 't', 'R', '\013', 'l', 'b', 'E', 'n', 'd', 'p', 'o', 'i', 
+'n', 't', 's', ':', '0', '\232', '\305', '\210', '\036', '+', '\n', ')', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 
+'e', 'n', 'd', 'p', 'o', 'i', 'n', 't', '.', 'L', 'o', 'c', 'a', 'l', 'i', 't', 'y', 'L', 'b', 'E', 'n', 'd', 'p', 'o', 'i', 
+'n', 't', 's', 'B', '\013', '\n', '\t', 'l', 'b', '_', 'c', 'o', 'n', 'f', 'i', 'g', 'B', 'K', '\n', '&', 'i', 'o', '.', 'e', 'n', 
+'v', 'o', 'y', 'p', 'r', 'o', 'x', 'y', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'e', 'n', 'd', 
+'p', 'o', 'i', 'n', 't', '.', 'v', '3', 'B', '\027', 'E', 'n', 'd', 'p', 'o', 'i', 'n', 't', 'C', 'o', 'm', 'p', 'o', 'n', 'e', 
+'n', 't', 's', 'P', 'r', 'o', 't', 'o', 'P', '\001', '\272', '\200', '\310', '\321', '\006', '\002', '\020', '\002', 'b', '\006', 'p', 'r', 'o', 't', 'o', 
+'3', 
 };
 
-static upb_def_init *deps[8] = {
+static upb_def_init *deps[10] = {
   &envoy_config_core_v3_address_proto_upbdefinit,
   &envoy_config_core_v3_base_proto_upbdefinit,
+  &envoy_config_core_v3_config_source_proto_upbdefinit,
   &envoy_config_core_v3_health_check_proto_upbdefinit,
   &google_protobuf_wrappers_proto_upbdefinit,
+  &udpa_annotations_migrate_proto_upbdefinit,
   &udpa_annotations_status_proto_upbdefinit,
   &udpa_annotations_versioning_proto_upbdefinit,
   &validate_validate_proto_upbdefinit,
@@ -109,5 +140,5 @@ upb_def_init envoy_config_endpoint_v3_endpoint_components_proto_upbdefinit = {
   deps,
   layouts,
   "envoy/config/endpoint/v3/endpoint_components.proto",
-  UPB_STRVIEW_INIT(descriptor, 1584)
+  UPB_STRVIEW_INIT(descriptor, 2151)
 };
index 0173282..78661a9 100644 (file)
@@ -36,11 +36,21 @@ UPB_INLINE const upb_msgdef *envoy_config_endpoint_v3_LbEndpoint_getmsgdef(upb_s
   return upb_symtab_lookupmsg(s, "envoy.config.endpoint.v3.LbEndpoint");
 }
 
+UPB_INLINE const upb_msgdef *envoy_config_endpoint_v3_LedsClusterLocalityConfig_getmsgdef(upb_symtab *s) {
+  _upb_symtab_loaddefinit(s, &envoy_config_endpoint_v3_endpoint_components_proto_upbdefinit);
+  return upb_symtab_lookupmsg(s, "envoy.config.endpoint.v3.LedsClusterLocalityConfig");
+}
+
 UPB_INLINE const upb_msgdef *envoy_config_endpoint_v3_LocalityLbEndpoints_getmsgdef(upb_symtab *s) {
   _upb_symtab_loaddefinit(s, &envoy_config_endpoint_v3_endpoint_components_proto_upbdefinit);
   return upb_symtab_lookupmsg(s, "envoy.config.endpoint.v3.LocalityLbEndpoints");
 }
 
+UPB_INLINE const upb_msgdef *envoy_config_endpoint_v3_LocalityLbEndpoints_LbEndpointList_getmsgdef(upb_symtab *s) {
+  _upb_symtab_loaddefinit(s, &envoy_config_endpoint_v3_endpoint_components_proto_upbdefinit);
+  return upb_symtab_lookupmsg(s, "envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList");
+}
+
 #ifdef __cplusplus
 }  /* extern "C" */
 #endif
index e189d99..c508f37 100644 (file)
@@ -22,9 +22,10 @@ extern const upb_msglayout envoy_config_overload_v3_Trigger_msginit;
 extern const upb_msglayout envoy_config_overload_v3_ScaleTimersOverloadActionConfig_msginit;
 extern const upb_msglayout envoy_config_overload_v3_ScaleTimersOverloadActionConfig_ScaleTimer_msginit;
 extern const upb_msglayout envoy_config_overload_v3_OverloadAction_msginit;
+extern const upb_msglayout envoy_config_overload_v3_BufferFactoryConfig_msginit;
 extern const upb_msglayout envoy_config_overload_v3_OverloadManager_msginit;
 
-static const upb_msglayout *layouts[8] = {
+static const upb_msglayout *layouts[9] = {
   &envoy_config_overload_v3_ResourceMonitor_msginit,
   &envoy_config_overload_v3_ThresholdTrigger_msginit,
   &envoy_config_overload_v3_ScaledTrigger_msginit,
@@ -32,10 +33,11 @@ static const upb_msglayout *layouts[8] = {
   &envoy_config_overload_v3_ScaleTimersOverloadActionConfig_msginit,
   &envoy_config_overload_v3_ScaleTimersOverloadActionConfig_ScaleTimer_msginit,
   &envoy_config_overload_v3_OverloadAction_msginit,
+  &envoy_config_overload_v3_BufferFactoryConfig_msginit,
   &envoy_config_overload_v3_OverloadManager_msginit,
 };
 
-static const char descriptor[2145] = {'\n', '\'', 'e', 'n', 'v', 'o', 'y', '/', 'c', 'o', 'n', 'f', 'i', 'g', '/', 'o', 'v', 'e', 'r', 'l', 'o', 'a', 'd', '/', 'v', 
+static const char descriptor[2358] = {'\n', '\'', 'e', 'n', 'v', 'o', 'y', '/', 'c', 'o', 'n', 'f', 'i', 'g', '/', 'o', 'v', 'e', 'r', 'l', 'o', 'a', 'd', '/', 'v', 
 '3', '/', 'o', 'v', 'e', 'r', 'l', 'o', 'a', 'd', '.', 'p', 'r', 'o', 't', 'o', '\022', '\030', 'e', 'n', 'v', 'o', 'y', '.', 'c', 
 'o', 'n', 'f', 'i', 'g', '.', 'o', 'v', 'e', 'r', 'l', 'o', 'a', 'd', '.', 'v', '3', '\032', '\033', 'e', 'n', 'v', 'o', 'y', '/', 
 't', 'y', 'p', 'e', '/', 'v', '3', '/', 'p', 'e', 'r', 'c', 'e', 'n', 't', '.', 'p', 'r', 'o', 't', 'o', '\032', '\031', 'g', 'o', 
@@ -105,22 +107,31 @@ static const char descriptor[2145] = {'\n', '\'', 'e', 'n', 'v', 'o', 'y', '/',
 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'A', 'n', 'y', 'R', '\013', 't', 'y', 'p', 'e', 
 'd', 'C', 'o', 'n', 'f', 'i', 'g', ':', '3', '\232', '\305', '\210', '\036', '.', '\n', ',', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 
 'f', 'i', 'g', '.', 'o', 'v', 'e', 'r', 'l', 'o', 'a', 'd', '.', 'v', '2', 'a', 'l', 'p', 'h', 'a', '.', 'O', 'v', 'e', 'r', 
-'l', 'o', 'a', 'd', 'A', 'c', 't', 'i', 'o', 'n', '\"', '\263', '\002', '\n', '\017', 'O', 'v', 'e', 'r', 'l', 'o', 'a', 'd', 'M', 'a', 
-'n', 'a', 'g', 'e', 'r', '\022', 'D', '\n', '\020', 'r', 'e', 'f', 'r', 'e', 's', 'h', '_', 'i', 'n', 't', 'e', 'r', 'v', 'a', 'l', 
-'\030', '\001', ' ', '\001', '(', '\013', '2', '\031', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 
-'D', 'u', 'r', 'a', 't', 'i', 'o', 'n', 'R', '\017', 'r', 'e', 'f', 'r', 'e', 's', 'h', 'I', 'n', 't', 'e', 'r', 'v', 'a', 'l', 
-'\022', '`', '\n', '\021', 'r', 'e', 's', 'o', 'u', 'r', 'c', 'e', '_', 'm', 'o', 'n', 'i', 't', 'o', 'r', 's', '\030', '\002', ' ', '\003', 
-'(', '\013', '2', ')', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'o', 'v', 'e', 'r', 'l', 'o', 'a', 
-'d', '.', 'v', '3', '.', 'R', 'e', 's', 'o', 'u', 'r', 'c', 'e', 'M', 'o', 'n', 'i', 't', 'o', 'r', 'B', '\010', '\372', 'B', '\005', 
-'\222', '\001', '\002', '\010', '\001', 'R', '\020', 'r', 'e', 's', 'o', 'u', 'r', 'c', 'e', 'M', 'o', 'n', 'i', 't', 'o', 'r', 's', '\022', 'B', 
-'\n', '\007', 'a', 'c', 't', 'i', 'o', 'n', 's', '\030', '\003', ' ', '\003', '(', '\013', '2', '(', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 
-'o', 'n', 'f', 'i', 'g', '.', 'o', 'v', 'e', 'r', 'l', 'o', 'a', 'd', '.', 'v', '3', '.', 'O', 'v', 'e', 'r', 'l', 'o', 'a', 
-'d', 'A', 'c', 't', 'i', 'o', 'n', 'R', '\007', 'a', 'c', 't', 'i', 'o', 'n', 's', ':', '4', '\232', '\305', '\210', '\036', '/', '\n', '-', 
-'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'o', 'v', 'e', 'r', 'l', 'o', 'a', 'd', '.', 'v', '2', 'a', 
-'l', 'p', 'h', 'a', '.', 'O', 'v', 'e', 'r', 'l', 'o', 'a', 'd', 'M', 'a', 'n', 'a', 'g', 'e', 'r', 'B', 'A', '\n', '&', 'i', 
-'o', '.', 'e', 'n', 'v', 'o', 'y', 'p', 'r', 'o', 'x', 'y', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', 
-'.', 'o', 'v', 'e', 'r', 'l', 'o', 'a', 'd', '.', 'v', '3', 'B', '\r', 'O', 'v', 'e', 'r', 'l', 'o', 'a', 'd', 'P', 'r', 'o', 
-'t', 'o', 'P', '\001', '\272', '\200', '\310', '\321', '\006', '\002', '\020', '\002', 'b', '\006', 'p', 'r', 'o', 't', 'o', '3', 
+'l', 'o', 'a', 'd', 'A', 'c', 't', 'i', 'o', 'n', '\"', 'p', '\n', '\023', 'B', 'u', 'f', 'f', 'e', 'r', 'F', 'a', 'c', 't', 'o', 
+'r', 'y', 'C', 'o', 'n', 'f', 'i', 'g', '\022', 'Y', '\n', '%', 'm', 'i', 'n', 'i', 'm', 'u', 'm', '_', 'a', 'c', 'c', 'o', 'u', 
+'n', 't', '_', 't', 'o', '_', 't', 'r', 'a', 'c', 'k', '_', 'p', 'o', 'w', 'e', 'r', '_', 'o', 'f', '_', 't', 'w', 'o', '\030', 
+'\001', ' ', '\001', '(', '\r', 'B', '\t', '\372', 'B', '\006', '*', '\004', '\030', '8', '(', '\n', 'R', '\037', 'm', 'i', 'n', 'i', 'm', 'u', 'm', 
+'A', 'c', 'c', 'o', 'u', 'n', 't', 'T', 'o', 'T', 'r', 'a', 'c', 'k', 'P', 'o', 'w', 'e', 'r', 'O', 'f', 'T', 'w', 'o', '\"', 
+'\226', '\003', '\n', '\017', 'O', 'v', 'e', 'r', 'l', 'o', 'a', 'd', 'M', 'a', 'n', 'a', 'g', 'e', 'r', '\022', 'D', '\n', '\020', 'r', 'e', 
+'f', 'r', 'e', 's', 'h', '_', 'i', 'n', 't', 'e', 'r', 'v', 'a', 'l', '\030', '\001', ' ', '\001', '(', '\013', '2', '\031', '.', 'g', 'o', 
+'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'D', 'u', 'r', 'a', 't', 'i', 'o', 'n', 'R', '\017', 'r', 
+'e', 'f', 'r', 'e', 's', 'h', 'I', 'n', 't', 'e', 'r', 'v', 'a', 'l', '\022', '`', '\n', '\021', 'r', 'e', 's', 'o', 'u', 'r', 'c', 
+'e', '_', 'm', 'o', 'n', 'i', 't', 'o', 'r', 's', '\030', '\002', ' ', '\003', '(', '\013', '2', ')', '.', 'e', 'n', 'v', 'o', 'y', '.', 
+'c', 'o', 'n', 'f', 'i', 'g', '.', 'o', 'v', 'e', 'r', 'l', 'o', 'a', 'd', '.', 'v', '3', '.', 'R', 'e', 's', 'o', 'u', 'r', 
+'c', 'e', 'M', 'o', 'n', 'i', 't', 'o', 'r', 'B', '\010', '\372', 'B', '\005', '\222', '\001', '\002', '\010', '\001', 'R', '\020', 'r', 'e', 's', 'o', 
+'u', 'r', 'c', 'e', 'M', 'o', 'n', 'i', 't', 'o', 'r', 's', '\022', 'B', '\n', '\007', 'a', 'c', 't', 'i', 'o', 'n', 's', '\030', '\003', 
+' ', '\003', '(', '\013', '2', '(', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'o', 'v', 'e', 'r', 'l', 
+'o', 'a', 'd', '.', 'v', '3', '.', 'O', 'v', 'e', 'r', 'l', 'o', 'a', 'd', 'A', 'c', 't', 'i', 'o', 'n', 'R', '\007', 'a', 'c', 
+'t', 'i', 'o', 'n', 's', '\022', 'a', '\n', '\025', 'b', 'u', 'f', 'f', 'e', 'r', '_', 'f', 'a', 'c', 't', 'o', 'r', 'y', '_', 'c', 
+'o', 'n', 'f', 'i', 'g', '\030', '\004', ' ', '\001', '(', '\013', '2', '-', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 
+'g', '.', 'o', 'v', 'e', 'r', 'l', 'o', 'a', 'd', '.', 'v', '3', '.', 'B', 'u', 'f', 'f', 'e', 'r', 'F', 'a', 'c', 't', 'o', 
+'r', 'y', 'C', 'o', 'n', 'f', 'i', 'g', 'R', '\023', 'b', 'u', 'f', 'f', 'e', 'r', 'F', 'a', 'c', 't', 'o', 'r', 'y', 'C', 'o', 
+'n', 'f', 'i', 'g', ':', '4', '\232', '\305', '\210', '\036', '/', '\n', '-', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', 
+'.', 'o', 'v', 'e', 'r', 'l', 'o', 'a', 'd', '.', 'v', '2', 'a', 'l', 'p', 'h', 'a', '.', 'O', 'v', 'e', 'r', 'l', 'o', 'a', 
+'d', 'M', 'a', 'n', 'a', 'g', 'e', 'r', 'B', 'A', '\n', '&', 'i', 'o', '.', 'e', 'n', 'v', 'o', 'y', 'p', 'r', 'o', 'x', 'y', 
+'.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'o', 'v', 'e', 'r', 'l', 'o', 'a', 'd', '.', 'v', '3', 
+'B', '\r', 'O', 'v', 'e', 'r', 'l', 'o', 'a', 'd', 'P', 'r', 'o', 't', 'o', 'P', '\001', '\272', '\200', '\310', '\321', '\006', '\002', '\020', '\002', 
+'b', '\006', 'p', 'r', 'o', 't', 'o', '3', 
 };
 
 static upb_def_init *deps[7] = {
@@ -137,5 +148,5 @@ upb_def_init envoy_config_overload_v3_overload_proto_upbdefinit = {
   deps,
   layouts,
   "envoy/config/overload/v3/overload.proto",
-  UPB_STRVIEW_INIT(descriptor, 2145)
+  UPB_STRVIEW_INIT(descriptor, 2358)
 };
index ca1dc51..73df103 100644 (file)
@@ -56,6 +56,11 @@ UPB_INLINE const upb_msgdef *envoy_config_overload_v3_OverloadAction_getmsgdef(u
   return upb_symtab_lookupmsg(s, "envoy.config.overload.v3.OverloadAction");
 }
 
+UPB_INLINE const upb_msgdef *envoy_config_overload_v3_BufferFactoryConfig_getmsgdef(upb_symtab *s) {
+  _upb_symtab_loaddefinit(s, &envoy_config_overload_v3_overload_proto_upbdefinit);
+  return upb_symtab_lookupmsg(s, "envoy.config.overload.v3.BufferFactoryConfig");
+}
+
 UPB_INLINE const upb_msgdef *envoy_config_overload_v3_OverloadManager_getmsgdef(upb_symtab *s) {
   _upb_symtab_loaddefinit(s, &envoy_config_overload_v3_overload_proto_upbdefinit);
   return upb_symtab_lookupmsg(s, "envoy.config.overload.v3.OverloadManager");
index f73a9a0..39a554f 100644 (file)
@@ -14,6 +14,7 @@ extern upb_def_init envoy_config_route_v3_route_components_proto_upbdefinit;
 extern upb_def_init envoy_type_matcher_v3_metadata_proto_upbdefinit;
 extern upb_def_init envoy_type_matcher_v3_path_proto_upbdefinit;
 extern upb_def_init envoy_type_matcher_v3_string_proto_upbdefinit;
+extern upb_def_init envoy_type_v3_range_proto_upbdefinit;
 extern upb_def_init google_api_expr_v1alpha1_checked_proto_upbdefinit;
 extern upb_def_init google_api_expr_v1alpha1_syntax_proto_upbdefinit;
 extern upb_def_init envoy_annotations_deprecation_proto_upbdefinit;
@@ -41,7 +42,7 @@ static const upb_msglayout *layouts[8] = {
   &envoy_config_rbac_v3_Principal_Authenticated_msginit,
 };
 
-static const char descriptor[3158] = {'\n', '\037', 'e', 'n', 'v', 'o', 'y', '/', 'c', 'o', 'n', 'f', 'i', 'g', '/', 'r', 'b', 'a', 'c', '/', 'v', '3', '/', 'r', 'b', 
+static const char descriptor[3268] = {'\n', '\037', 'e', 'n', 'v', 'o', 'y', '/', 'c', 'o', 'n', 'f', 'i', 'g', '/', 'r', 'b', 'a', 'c', '/', 'v', '3', '/', 'r', 'b', 
 'a', 'c', '.', 'p', 'r', 'o', 't', 'o', '\022', '\024', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'b', 
 'a', 'c', '.', 'v', '3', '\032', '\"', 'e', 'n', 'v', 'o', 'y', '/', 'c', 'o', 'n', 'f', 'i', 'g', '/', 'c', 'o', 'r', 'e', '/', 
 'v', '3', '/', 'a', 'd', 'd', 'r', 'e', 's', 's', '.', 'p', 'r', 'o', 't', 'o', '\032', ',', 'e', 'n', 'v', 'o', 'y', '/', 'c', 
@@ -50,132 +51,137 @@ static const char descriptor[3158] = {'\n', '\037', 'e', 'n', 'v', 'o', 'y', '/'
 'm', 'a', 't', 'c', 'h', 'e', 'r', '/', 'v', '3', '/', 'm', 'e', 't', 'a', 'd', 'a', 't', 'a', '.', 'p', 'r', 'o', 't', 'o', 
 '\032', ' ', 'e', 'n', 'v', 'o', 'y', '/', 't', 'y', 'p', 'e', '/', 'm', 'a', 't', 'c', 'h', 'e', 'r', '/', 'v', '3', '/', 'p', 
 'a', 't', 'h', '.', 'p', 'r', 'o', 't', 'o', '\032', '\"', 'e', 'n', 'v', 'o', 'y', '/', 't', 'y', 'p', 'e', '/', 'm', 'a', 't', 
-'c', 'h', 'e', 'r', '/', 'v', '3', '/', 's', 't', 'r', 'i', 'n', 'g', '.', 'p', 'r', 'o', 't', 'o', '\032', '&', 'g', 'o', 'o', 
-'g', 'l', 'e', '/', 'a', 'p', 'i', '/', 'e', 'x', 'p', 'r', '/', 'v', '1', 'a', 'l', 'p', 'h', 'a', '1', '/', 'c', 'h', 'e', 
-'c', 'k', 'e', 'd', '.', 'p', 'r', 'o', 't', 'o', '\032', '%', 'g', 'o', 'o', 'g', 'l', 'e', '/', 'a', 'p', 'i', '/', 'e', 'x', 
-'p', 'r', '/', 'v', '1', 'a', 'l', 'p', 'h', 'a', '1', '/', 's', 'y', 'n', 't', 'a', 'x', '.', 'p', 'r', 'o', 't', 'o', '\032', 
-'#', 'e', 'n', 'v', 'o', 'y', '/', 'a', 'n', 'n', 'o', 't', 'a', 't', 'i', 'o', 'n', 's', '/', 'd', 'e', 'p', 'r', 'e', 'c', 
-'a', 't', 'i', 'o', 'n', '.', 'p', 'r', 'o', 't', 'o', '\032', '\036', 'u', 'd', 'p', 'a', '/', 'a', 'n', 'n', 'o', 't', 'a', 't', 
-'i', 'o', 'n', 's', '/', 'm', 'i', 'g', 'r', 'a', 't', 'e', '.', 'p', 'r', 'o', 't', 'o', '\032', '\035', 'u', 'd', 'p', 'a', '/', 
-'a', 'n', 'n', 'o', 't', 'a', 't', 'i', 'o', 'n', 's', '/', 's', 't', 'a', 't', 'u', 's', '.', 'p', 'r', 'o', 't', 'o', '\032', 
-'!', 'u', 'd', 'p', 'a', '/', 'a', 'n', 'n', 'o', 't', 'a', 't', 'i', 'o', 'n', 's', '/', 'v', 'e', 'r', 's', 'i', 'o', 'n', 
-'i', 'n', 'g', '.', 'p', 'r', 'o', 't', 'o', '\032', '\027', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'e', '/', 'v', 'a', 'l', 'i', 'd', 
-'a', 't', 'e', '.', 'p', 'r', 'o', 't', 'o', '\"', '\266', '\002', '\n', '\004', 'R', 'B', 'A', 'C', '\022', 'C', '\n', '\006', 'a', 'c', 't', 
-'i', 'o', 'n', '\030', '\001', ' ', '\001', '(', '\016', '2', '!', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 
-'r', 'b', 'a', 'c', '.', 'v', '3', '.', 'R', 'B', 'A', 'C', '.', 'A', 'c', 't', 'i', 'o', 'n', 'B', '\010', '\372', 'B', '\005', '\202', 
-'\001', '\002', '\020', '\001', 'R', '\006', 'a', 'c', 't', 'i', 'o', 'n', '\022', 'D', '\n', '\010', 'p', 'o', 'l', 'i', 'c', 'i', 'e', 's', '\030', 
-'\002', ' ', '\003', '(', '\013', '2', '(', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'b', 'a', 'c', 
-'.', 'v', '3', '.', 'R', 'B', 'A', 'C', '.', 'P', 'o', 'l', 'i', 'c', 'i', 'e', 's', 'E', 'n', 't', 'r', 'y', 'R', '\010', 'p', 
-'o', 'l', 'i', 'c', 'i', 'e', 's', '\032', 'Y', '\n', '\r', 'P', 'o', 'l', 'i', 'c', 'i', 'e', 's', 'E', 'n', 't', 'r', 'y', '\022', 
-'\020', '\n', '\003', 'k', 'e', 'y', '\030', '\001', ' ', '\001', '(', '\t', 'R', '\003', 'k', 'e', 'y', '\022', '2', '\n', '\005', 'v', 'a', 'l', 'u', 
-'e', '\030', '\002', ' ', '\001', '(', '\013', '2', '\034', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'b', 
-'a', 'c', '.', 'v', '3', '.', 'P', 'o', 'l', 'i', 'c', 'y', 'R', '\005', 'v', 'a', 'l', 'u', 'e', ':', '\002', '8', '\001', '\"', '&', 
-'\n', '\006', 'A', 'c', 't', 'i', 'o', 'n', '\022', '\t', '\n', '\005', 'A', 'L', 'L', 'O', 'W', '\020', '\000', '\022', '\010', '\n', '\004', 'D', 'E', 
-'N', 'Y', '\020', '\001', '\022', '\007', '\n', '\003', 'L', 'O', 'G', '\020', '\002', ':', ' ', '\232', '\305', '\210', '\036', '\033', '\n', '\031', 'e', 'n', 'v', 
-'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'b', 'a', 'c', '.', 'v', '2', '.', 'R', 'B', 'A', 'C', '\"', '\223', '\003', 
-'\n', '\006', 'P', 'o', 'l', 'i', 'c', 'y', '\022', 'L', '\n', '\013', 'p', 'e', 'r', 'm', 'i', 's', 's', 'i', 'o', 'n', 's', '\030', '\001', 
-' ', '\003', '(', '\013', '2', ' ', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'b', 'a', 'c', '.', 
-'v', '3', '.', 'P', 'e', 'r', 'm', 'i', 's', 's', 'i', 'o', 'n', 'B', '\010', '\372', 'B', '\005', '\222', '\001', '\002', '\010', '\001', 'R', '\013', 
-'p', 'e', 'r', 'm', 'i', 's', 's', 'i', 'o', 'n', 's', '\022', 'I', '\n', '\n', 'p', 'r', 'i', 'n', 'c', 'i', 'p', 'a', 'l', 's', 
-'\030', '\002', ' ', '\003', '(', '\013', '2', '\037', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'b', 'a', 
-'c', '.', 'v', '3', '.', 'P', 'r', 'i', 'n', 'c', 'i', 'p', 'a', 'l', 'B', '\010', '\372', 'B', '\005', '\222', '\001', '\002', '\010', '\001', 'R', 
-'\n', 'p', 'r', 'i', 'n', 'c', 'i', 'p', 'a', 'l', 's', '\022', 'Z', '\n', '\t', 'c', 'o', 'n', 'd', 'i', 't', 'i', 'o', 'n', '\030', 
-'\003', ' ', '\001', '(', '\013', '2', '\036', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'a', 'p', 'i', '.', 'e', 'x', 'p', 'r', '.', 'v', 
-'1', 'a', 'l', 'p', 'h', 'a', '1', '.', 'E', 'x', 'p', 'r', 'B', '\034', '\362', '\230', '\376', '\217', '\005', '\026', '\022', '\024', 'e', 'x', 'p', 
-'r', 'e', 's', 's', 'i', 'o', 'n', '_', 's', 'p', 'e', 'c', 'i', 'f', 'i', 'e', 'r', 'R', '\t', 'c', 'o', 'n', 'd', 'i', 't', 
-'i', 'o', 'n', '\022', 'p', '\n', '\021', 'c', 'h', 'e', 'c', 'k', 'e', 'd', '_', 'c', 'o', 'n', 'd', 'i', 't', 'i', 'o', 'n', '\030', 
-'\004', ' ', '\001', '(', '\013', '2', '%', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'a', 'p', 'i', '.', 'e', 'x', 'p', 'r', '.', 'v', 
-'1', 'a', 'l', 'p', 'h', 'a', '1', '.', 'C', 'h', 'e', 'c', 'k', 'e', 'd', 'E', 'x', 'p', 'r', 'B', '\034', '\362', '\230', '\376', '\217', 
-'\005', '\026', '\022', '\024', 'e', 'x', 'p', 'r', 'e', 's', 's', 'i', 'o', 'n', '_', 's', 'p', 'e', 'c', 'i', 'f', 'i', 'e', 'r', 'R', 
-'\020', 'c', 'h', 'e', 'c', 'k', 'e', 'd', 'C', 'o', 'n', 'd', 'i', 't', 'i', 'o', 'n', ':', '\"', '\232', '\305', '\210', '\036', '\035', '\n', 
-'\033', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'b', 'a', 'c', '.', 'v', '2', '.', 'P', 'o', 'l', 
-'i', 'c', 'y', '\"', '\277', '\006', '\n', '\n', 'P', 'e', 'r', 'm', 'i', 's', 's', 'i', 'o', 'n', '\022', 'C', '\n', '\t', 'a', 'n', 'd', 
-'_', 'r', 'u', 'l', 'e', 's', '\030', '\001', ' ', '\001', '(', '\013', '2', '$', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 
-'i', 'g', '.', 'r', 'b', 'a', 'c', '.', 'v', '3', '.', 'P', 'e', 'r', 'm', 'i', 's', 's', 'i', 'o', 'n', '.', 'S', 'e', 't', 
-'H', '\000', 'R', '\010', 'a', 'n', 'd', 'R', 'u', 'l', 'e', 's', '\022', 'A', '\n', '\010', 'o', 'r', '_', 'r', 'u', 'l', 'e', 's', '\030', 
-'\002', ' ', '\001', '(', '\013', '2', '$', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'b', 'a', 'c', 
-'.', 'v', '3', '.', 'P', 'e', 'r', 'm', 'i', 's', 's', 'i', 'o', 'n', '.', 'S', 'e', 't', 'H', '\000', 'R', '\007', 'o', 'r', 'R', 
-'u', 'l', 'e', 's', '\022', '\033', '\n', '\003', 'a', 'n', 'y', '\030', '\003', ' ', '\001', '(', '\010', 'B', '\007', '\372', 'B', '\004', 'j', '\002', '\010', 
-'\001', 'H', '\000', 'R', '\003', 'a', 'n', 'y', '\022', '>', '\n', '\006', 'h', 'e', 'a', 'd', 'e', 'r', '\030', '\004', ' ', '\001', '(', '\013', '2', 
-'$', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'H', 
-'e', 'a', 'd', 'e', 'r', 'M', 'a', 't', 'c', 'h', 'e', 'r', 'H', '\000', 'R', '\006', 'h', 'e', 'a', 'd', 'e', 'r', '\022', '?', '\n', 
-'\010', 'u', 'r', 'l', '_', 'p', 'a', 't', 'h', '\030', '\n', ' ', '\001', '(', '\013', '2', '\"', '.', 'e', 'n', 'v', 'o', 'y', '.', 't', 
-'y', 'p', 'e', '.', 'm', 'a', 't', 'c', 'h', 'e', 'r', '.', 'v', '3', '.', 'P', 'a', 't', 'h', 'M', 'a', 't', 'c', 'h', 'e', 
-'r', 'H', '\000', 'R', '\007', 'u', 'r', 'l', 'P', 'a', 't', 'h', '\022', 'H', '\n', '\016', 'd', 'e', 's', 't', 'i', 'n', 'a', 't', 'i', 
-'o', 'n', '_', 'i', 'p', '\030', '\005', ' ', '\001', '(', '\013', '2', '\037', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 
-'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'C', 'i', 'd', 'r', 'R', 'a', 'n', 'g', 'e', 'H', '\000', 'R', '\r', 'd', 'e', 
-'s', 't', 'i', 'n', 'a', 't', 'i', 'o', 'n', 'I', 'p', '\022', '6', '\n', '\020', 'd', 'e', 's', 't', 'i', 'n', 'a', 't', 'i', 'o', 
-'n', '_', 'p', 'o', 'r', 't', '\030', '\006', ' ', '\001', '(', '\r', 'B', '\t', '\372', 'B', '\006', '*', '\004', '\030', '\377', '\377', '\003', 'H', '\000', 
-'R', '\017', 'd', 'e', 's', 't', 'i', 'n', 'a', 't', 'i', 'o', 'n', 'P', 'o', 'r', 't', '\022', 'D', '\n', '\010', 'm', 'e', 't', 'a', 
-'d', 'a', 't', 'a', '\030', '\007', ' ', '\001', '(', '\013', '2', '&', '.', 'e', 'n', 'v', 'o', 'y', '.', 't', 'y', 'p', 'e', '.', 'm', 
-'a', 't', 'c', 'h', 'e', 'r', '.', 'v', '3', '.', 'M', 'e', 't', 'a', 'd', 'a', 't', 'a', 'M', 'a', 't', 'c', 'h', 'e', 'r', 
-'H', '\000', 'R', '\010', 'm', 'e', 't', 'a', 'd', 'a', 't', 'a', '\022', '=', '\n', '\010', 'n', 'o', 't', '_', 'r', 'u', 'l', 'e', '\030', 
-'\010', ' ', '\001', '(', '\013', '2', ' ', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'b', 'a', 'c', 
-'.', 'v', '3', '.', 'P', 'e', 'r', 'm', 'i', 's', 's', 'i', 'o', 'n', 'H', '\000', 'R', '\007', 'n', 'o', 't', 'R', 'u', 'l', 'e', 
-'\022', 'Z', '\n', '\025', 'r', 'e', 'q', 'u', 'e', 's', 't', 'e', 'd', '_', 's', 'e', 'r', 'v', 'e', 'r', '_', 'n', 'a', 'm', 'e', 
-'\030', '\t', ' ', '\001', '(', '\013', '2', '$', '.', 'e', 'n', 'v', 'o', 'y', '.', 't', 'y', 'p', 'e', '.', 'm', 'a', 't', 'c', 'h', 
-'e', 'r', '.', 'v', '3', '.', 'S', 't', 'r', 'i', 'n', 'g', 'M', 'a', 't', 'c', 'h', 'e', 'r', 'H', '\000', 'R', '\023', 'r', 'e', 
-'q', 'u', 'e', 's', 't', 'e', 'd', 'S', 'e', 'r', 'v', 'e', 'r', 'N', 'a', 'm', 'e', '\032', 's', '\n', '\003', 'S', 'e', 't', '\022', 
-'@', '\n', '\005', 'r', 'u', 'l', 'e', 's', '\030', '\001', ' ', '\003', '(', '\013', '2', ' ', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 
-'n', 'f', 'i', 'g', '.', 'r', 'b', 'a', 'c', '.', 'v', '3', '.', 'P', 'e', 'r', 'm', 'i', 's', 's', 'i', 'o', 'n', 'B', '\010', 
-'\372', 'B', '\005', '\222', '\001', '\002', '\010', '\001', 'R', '\005', 'r', 'u', 'l', 'e', 's', ':', '*', '\232', '\305', '\210', '\036', '%', '\n', '#', 'e', 
-'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'b', 'a', 'c', '.', 'v', '2', '.', 'P', 'e', 'r', 'm', 'i', 
-'s', 's', 'i', 'o', 'n', '.', 'S', 'e', 't', ':', '&', '\232', '\305', '\210', '\036', '!', '\n', '\037', 'e', 'n', 'v', 'o', 'y', '.', 'c', 
-'o', 'n', 'f', 'i', 'g', '.', 'r', 'b', 'a', 'c', '.', 'v', '2', '.', 'P', 'e', 'r', 'm', 'i', 's', 's', 'i', 'o', 'n', 'B', 
-'\013', '\n', '\004', 'r', 'u', 'l', 'e', '\022', '\003', '\370', 'B', '\001', '\"', '\233', '\010', '\n', '\t', 'P', 'r', 'i', 'n', 'c', 'i', 'p', 'a', 
-'l', '\022', '>', '\n', '\007', 'a', 'n', 'd', '_', 'i', 'd', 's', '\030', '\001', ' ', '\001', '(', '\013', '2', '#', '.', 'e', 'n', 'v', 'o', 
-'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'b', 'a', 'c', '.', 'v', '3', '.', 'P', 'r', 'i', 'n', 'c', 'i', 'p', 'a', 
-'l', '.', 'S', 'e', 't', 'H', '\000', 'R', '\006', 'a', 'n', 'd', 'I', 'd', 's', '\022', '<', '\n', '\006', 'o', 'r', '_', 'i', 'd', 's', 
-'\030', '\002', ' ', '\001', '(', '\013', '2', '#', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'b', 'a', 
-'c', '.', 'v', '3', '.', 'P', 'r', 'i', 'n', 'c', 'i', 'p', 'a', 'l', '.', 'S', 'e', 't', 'H', '\000', 'R', '\005', 'o', 'r', 'I', 
-'d', 's', '\022', '\033', '\n', '\003', 'a', 'n', 'y', '\030', '\003', ' ', '\001', '(', '\010', 'B', '\007', '\372', 'B', '\004', 'j', '\002', '\010', '\001', 'H', 
-'\000', 'R', '\003', 'a', 'n', 'y', '\022', 'U', '\n', '\r', 'a', 'u', 't', 'h', 'e', 'n', 't', 'i', 'c', 'a', 't', 'e', 'd', '\030', '\004', 
-' ', '\001', '(', '\013', '2', '-', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'b', 'a', 'c', '.', 
-'v', '3', '.', 'P', 'r', 'i', 'n', 'c', 'i', 'p', 'a', 'l', '.', 'A', 'u', 't', 'h', 'e', 'n', 't', 'i', 'c', 'a', 't', 'e', 
-'d', 'H', '\000', 'R', '\r', 'a', 'u', 't', 'h', 'e', 'n', 't', 'i', 'c', 'a', 't', 'e', 'd', '\022', 'K', '\n', '\t', 's', 'o', 'u', 
-'r', 'c', 'e', '_', 'i', 'p', '\030', '\005', ' ', '\001', '(', '\013', '2', '\037', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 
-'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'C', 'i', 'd', 'r', 'R', 'a', 'n', 'g', 'e', 'B', '\013', '\030', '\001', '\222', 
-'\307', '\206', '\330', '\004', '\003', '3', '.', '0', 'H', '\000', 'R', '\010', 's', 'o', 'u', 'r', 'c', 'e', 'I', 'p', '\022', 'K', '\n', '\020', 'd', 
-'i', 'r', 'e', 'c', 't', '_', 'r', 'e', 'm', 'o', 't', 'e', '_', 'i', 'p', '\030', '\n', ' ', '\001', '(', '\013', '2', '\037', '.', 'e', 
-'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'C', 'i', 'd', 'r', 'R', 
-'a', 'n', 'g', 'e', 'H', '\000', 'R', '\016', 'd', 'i', 'r', 'e', 'c', 't', 'R', 'e', 'm', 'o', 't', 'e', 'I', 'p', '\022', '>', '\n', 
-'\t', 'r', 'e', 'm', 'o', 't', 'e', '_', 'i', 'p', '\030', '\013', ' ', '\001', '(', '\013', '2', '\037', '.', 'e', 'n', 'v', 'o', 'y', '.', 
-'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'C', 'i', 'd', 'r', 'R', 'a', 'n', 'g', 'e', 'H', 
-'\000', 'R', '\010', 'r', 'e', 'm', 'o', 't', 'e', 'I', 'p', '\022', '>', '\n', '\006', 'h', 'e', 'a', 'd', 'e', 'r', '\030', '\006', ' ', '\001', 
-'(', '\013', '2', '$', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', 
-'3', '.', 'H', 'e', 'a', 'd', 'e', 'r', 'M', 'a', 't', 'c', 'h', 'e', 'r', 'H', '\000', 'R', '\006', 'h', 'e', 'a', 'd', 'e', 'r', 
-'\022', '?', '\n', '\010', 'u', 'r', 'l', '_', 'p', 'a', 't', 'h', '\030', '\t', ' ', '\001', '(', '\013', '2', '\"', '.', 'e', 'n', 'v', 'o', 
-'y', '.', 't', 'y', 'p', 'e', '.', 'm', 'a', 't', 'c', 'h', 'e', 'r', '.', 'v', '3', '.', 'P', 'a', 't', 'h', 'M', 'a', 't', 
-'c', 'h', 'e', 'r', 'H', '\000', 'R', '\007', 'u', 'r', 'l', 'P', 'a', 't', 'h', '\022', 'D', '\n', '\010', 'm', 'e', 't', 'a', 'd', 'a', 
-'t', 'a', '\030', '\007', ' ', '\001', '(', '\013', '2', '&', '.', 'e', 'n', 'v', 'o', 'y', '.', 't', 'y', 'p', 'e', '.', 'm', 'a', 't', 
-'c', 'h', 'e', 'r', '.', 'v', '3', '.', 'M', 'e', 't', 'a', 'd', 'a', 't', 'a', 'M', 'a', 't', 'c', 'h', 'e', 'r', 'H', '\000', 
-'R', '\010', 'm', 'e', 't', 'a', 'd', 'a', 't', 'a', '\022', '8', '\n', '\006', 'n', 'o', 't', '_', 'i', 'd', '\030', '\010', ' ', '\001', '(', 
-'\013', '2', '\037', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'b', 'a', 'c', '.', 'v', '3', '.', 
-'P', 'r', 'i', 'n', 'c', 'i', 'p', 'a', 'l', 'H', '\000', 'R', '\005', 'n', 'o', 't', 'I', 'd', '\032', 'm', '\n', '\003', 'S', 'e', 't', 
-'\022', ';', '\n', '\003', 'i', 'd', 's', '\030', '\001', ' ', '\003', '(', '\013', '2', '\037', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 
-'f', 'i', 'g', '.', 'r', 'b', 'a', 'c', '.', 'v', '3', '.', 'P', 'r', 'i', 'n', 'c', 'i', 'p', 'a', 'l', 'B', '\010', '\372', 'B', 
-'\005', '\222', '\001', '\002', '\010', '\001', 'R', '\003', 'i', 'd', 's', ':', ')', '\232', '\305', '\210', '\036', '$', '\n', '\"', 'e', 'n', 'v', 'o', 'y', 
-'.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'b', 'a', 'c', '.', 'v', '2', '.', 'P', 'r', 'i', 'n', 'c', 'i', 'p', 'a', 'l', 
-'.', 'S', 'e', 't', '\032', '\227', '\001', '\n', '\r', 'A', 'u', 't', 'h', 'e', 'n', 't', 'i', 'c', 'a', 't', 'e', 'd', '\022', 'K', '\n', 
-'\016', 'p', 'r', 'i', 'n', 'c', 'i', 'p', 'a', 'l', '_', 'n', 'a', 'm', 'e', '\030', '\002', ' ', '\001', '(', '\013', '2', '$', '.', 'e', 
-'n', 'v', 'o', 'y', '.', 't', 'y', 'p', 'e', '.', 'm', 'a', 't', 'c', 'h', 'e', 'r', '.', 'v', '3', '.', 'S', 't', 'r', 'i', 
-'n', 'g', 'M', 'a', 't', 'c', 'h', 'e', 'r', 'R', '\r', 'p', 'r', 'i', 'n', 'c', 'i', 'p', 'a', 'l', 'N', 'a', 'm', 'e', ':', 
-'3', '\232', '\305', '\210', '\036', '.', '\n', ',', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'b', 'a', 'c', 
-'.', 'v', '2', '.', 'P', 'r', 'i', 'n', 'c', 'i', 'p', 'a', 'l', '.', 'A', 'u', 't', 'h', 'e', 'n', 't', 'i', 'c', 'a', 't', 
-'e', 'd', 'J', '\004', '\010', '\001', '\020', '\002', ':', '%', '\232', '\305', '\210', '\036', ' ', '\n', '\036', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 
-'n', 'f', 'i', 'g', '.', 'r', 'b', 'a', 'c', '.', 'v', '2', '.', 'P', 'r', 'i', 'n', 'c', 'i', 'p', 'a', 'l', 'B', '\021', '\n', 
-'\n', 'i', 'd', 'e', 'n', 't', 'i', 'f', 'i', 'e', 'r', '\022', '\003', '\370', 'B', '\001', 'B', '9', '\n', '\"', 'i', 'o', '.', 'e', 'n', 
-'v', 'o', 'y', 'p', 'r', 'o', 'x', 'y', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'b', 'a', 
-'c', '.', 'v', '3', 'B', '\t', 'R', 'b', 'a', 'c', 'P', 'r', 'o', 't', 'o', 'P', '\001', '\272', '\200', '\310', '\321', '\006', '\002', '\020', '\002', 
-'b', '\006', 'p', 'r', 'o', 't', 'o', '3', 
+'c', 'h', 'e', 'r', '/', 'v', '3', '/', 's', 't', 'r', 'i', 'n', 'g', '.', 'p', 'r', 'o', 't', 'o', '\032', '\031', 'e', 'n', 'v', 
+'o', 'y', '/', 't', 'y', 'p', 'e', '/', 'v', '3', '/', 'r', 'a', 'n', 'g', 'e', '.', 'p', 'r', 'o', 't', 'o', '\032', '&', 'g', 
+'o', 'o', 'g', 'l', 'e', '/', 'a', 'p', 'i', '/', 'e', 'x', 'p', 'r', '/', 'v', '1', 'a', 'l', 'p', 'h', 'a', '1', '/', 'c', 
+'h', 'e', 'c', 'k', 'e', 'd', '.', 'p', 'r', 'o', 't', 'o', '\032', '%', 'g', 'o', 'o', 'g', 'l', 'e', '/', 'a', 'p', 'i', '/', 
+'e', 'x', 'p', 'r', '/', 'v', '1', 'a', 'l', 'p', 'h', 'a', '1', '/', 's', 'y', 'n', 't', 'a', 'x', '.', 'p', 'r', 'o', 't', 
+'o', '\032', '#', 'e', 'n', 'v', 'o', 'y', '/', 'a', 'n', 'n', 'o', 't', 'a', 't', 'i', 'o', 'n', 's', '/', 'd', 'e', 'p', 'r', 
+'e', 'c', 'a', 't', 'i', 'o', 'n', '.', 'p', 'r', 'o', 't', 'o', '\032', '\036', 'u', 'd', 'p', 'a', '/', 'a', 'n', 'n', 'o', 't', 
+'a', 't', 'i', 'o', 'n', 's', '/', 'm', 'i', 'g', 'r', 'a', 't', 'e', '.', 'p', 'r', 'o', 't', 'o', '\032', '\035', 'u', 'd', 'p', 
+'a', '/', 'a', 'n', 'n', 'o', 't', 'a', 't', 'i', 'o', 'n', 's', '/', 's', 't', 'a', 't', 'u', 's', '.', 'p', 'r', 'o', 't', 
+'o', '\032', '!', 'u', 'd', 'p', 'a', '/', 'a', 'n', 'n', 'o', 't', 'a', 't', 'i', 'o', 'n', 's', '/', 'v', 'e', 'r', 's', 'i', 
+'o', 'n', 'i', 'n', 'g', '.', 'p', 'r', 'o', 't', 'o', '\032', '\027', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'e', '/', 'v', 'a', 'l', 
+'i', 'd', 'a', 't', 'e', '.', 'p', 'r', 'o', 't', 'o', '\"', '\266', '\002', '\n', '\004', 'R', 'B', 'A', 'C', '\022', 'C', '\n', '\006', 'a', 
+'c', 't', 'i', 'o', 'n', '\030', '\001', ' ', '\001', '(', '\016', '2', '!', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 
+'g', '.', 'r', 'b', 'a', 'c', '.', 'v', '3', '.', 'R', 'B', 'A', 'C', '.', 'A', 'c', 't', 'i', 'o', 'n', 'B', '\010', '\372', 'B', 
+'\005', '\202', '\001', '\002', '\020', '\001', 'R', '\006', 'a', 'c', 't', 'i', 'o', 'n', '\022', 'D', '\n', '\010', 'p', 'o', 'l', 'i', 'c', 'i', 'e', 
+'s', '\030', '\002', ' ', '\003', '(', '\013', '2', '(', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'b', 
+'a', 'c', '.', 'v', '3', '.', 'R', 'B', 'A', 'C', '.', 'P', 'o', 'l', 'i', 'c', 'i', 'e', 's', 'E', 'n', 't', 'r', 'y', 'R', 
+'\010', 'p', 'o', 'l', 'i', 'c', 'i', 'e', 's', '\032', 'Y', '\n', '\r', 'P', 'o', 'l', 'i', 'c', 'i', 'e', 's', 'E', 'n', 't', 'r', 
+'y', '\022', '\020', '\n', '\003', 'k', 'e', 'y', '\030', '\001', ' ', '\001', '(', '\t', 'R', '\003', 'k', 'e', 'y', '\022', '2', '\n', '\005', 'v', 'a', 
+'l', 'u', 'e', '\030', '\002', ' ', '\001', '(', '\013', '2', '\034', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 
+'r', 'b', 'a', 'c', '.', 'v', '3', '.', 'P', 'o', 'l', 'i', 'c', 'y', 'R', '\005', 'v', 'a', 'l', 'u', 'e', ':', '\002', '8', '\001', 
+'\"', '&', '\n', '\006', 'A', 'c', 't', 'i', 'o', 'n', '\022', '\t', '\n', '\005', 'A', 'L', 'L', 'O', 'W', '\020', '\000', '\022', '\010', '\n', '\004', 
+'D', 'E', 'N', 'Y', '\020', '\001', '\022', '\007', '\n', '\003', 'L', 'O', 'G', '\020', '\002', ':', ' ', '\232', '\305', '\210', '\036', '\033', '\n', '\031', 'e', 
+'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'b', 'a', 'c', '.', 'v', '2', '.', 'R', 'B', 'A', 'C', '\"', 
+'\223', '\003', '\n', '\006', 'P', 'o', 'l', 'i', 'c', 'y', '\022', 'L', '\n', '\013', 'p', 'e', 'r', 'm', 'i', 's', 's', 'i', 'o', 'n', 's', 
+'\030', '\001', ' ', '\003', '(', '\013', '2', ' ', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'b', 'a', 
+'c', '.', 'v', '3', '.', 'P', 'e', 'r', 'm', 'i', 's', 's', 'i', 'o', 'n', 'B', '\010', '\372', 'B', '\005', '\222', '\001', '\002', '\010', '\001', 
+'R', '\013', 'p', 'e', 'r', 'm', 'i', 's', 's', 'i', 'o', 'n', 's', '\022', 'I', '\n', '\n', 'p', 'r', 'i', 'n', 'c', 'i', 'p', 'a', 
+'l', 's', '\030', '\002', ' ', '\003', '(', '\013', '2', '\037', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 
+'b', 'a', 'c', '.', 'v', '3', '.', 'P', 'r', 'i', 'n', 'c', 'i', 'p', 'a', 'l', 'B', '\010', '\372', 'B', '\005', '\222', '\001', '\002', '\010', 
+'\001', 'R', '\n', 'p', 'r', 'i', 'n', 'c', 'i', 'p', 'a', 'l', 's', '\022', 'Z', '\n', '\t', 'c', 'o', 'n', 'd', 'i', 't', 'i', 'o', 
+'n', '\030', '\003', ' ', '\001', '(', '\013', '2', '\036', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'a', 'p', 'i', '.', 'e', 'x', 'p', 'r', 
+'.', 'v', '1', 'a', 'l', 'p', 'h', 'a', '1', '.', 'E', 'x', 'p', 'r', 'B', '\034', '\362', '\230', '\376', '\217', '\005', '\026', '\022', '\024', 'e', 
+'x', 'p', 'r', 'e', 's', 's', 'i', 'o', 'n', '_', 's', 'p', 'e', 'c', 'i', 'f', 'i', 'e', 'r', 'R', '\t', 'c', 'o', 'n', 'd', 
+'i', 't', 'i', 'o', 'n', '\022', 'p', '\n', '\021', 'c', 'h', 'e', 'c', 'k', 'e', 'd', '_', 'c', 'o', 'n', 'd', 'i', 't', 'i', 'o', 
+'n', '\030', '\004', ' ', '\001', '(', '\013', '2', '%', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'a', 'p', 'i', '.', 'e', 'x', 'p', 'r', 
+'.', 'v', '1', 'a', 'l', 'p', 'h', 'a', '1', '.', 'C', 'h', 'e', 'c', 'k', 'e', 'd', 'E', 'x', 'p', 'r', 'B', '\034', '\362', '\230', 
+'\376', '\217', '\005', '\026', '\022', '\024', 'e', 'x', 'p', 'r', 'e', 's', 's', 'i', 'o', 'n', '_', 's', 'p', 'e', 'c', 'i', 'f', 'i', 'e', 
+'r', 'R', '\020', 'c', 'h', 'e', 'c', 'k', 'e', 'd', 'C', 'o', 'n', 'd', 'i', 't', 'i', 'o', 'n', ':', '\"', '\232', '\305', '\210', '\036', 
+'\035', '\n', '\033', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'b', 'a', 'c', '.', 'v', '2', '.', 'P', 
+'o', 'l', 'i', 'c', 'y', '\"', '\222', '\007', '\n', '\n', 'P', 'e', 'r', 'm', 'i', 's', 's', 'i', 'o', 'n', '\022', 'C', '\n', '\t', 'a', 
+'n', 'd', '_', 'r', 'u', 'l', 'e', 's', '\030', '\001', ' ', '\001', '(', '\013', '2', '$', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 
+'n', 'f', 'i', 'g', '.', 'r', 'b', 'a', 'c', '.', 'v', '3', '.', 'P', 'e', 'r', 'm', 'i', 's', 's', 'i', 'o', 'n', '.', 'S', 
+'e', 't', 'H', '\000', 'R', '\010', 'a', 'n', 'd', 'R', 'u', 'l', 'e', 's', '\022', 'A', '\n', '\010', 'o', 'r', '_', 'r', 'u', 'l', 'e', 
+'s', '\030', '\002', ' ', '\001', '(', '\013', '2', '$', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'b', 
+'a', 'c', '.', 'v', '3', '.', 'P', 'e', 'r', 'm', 'i', 's', 's', 'i', 'o', 'n', '.', 'S', 'e', 't', 'H', '\000', 'R', '\007', 'o', 
+'r', 'R', 'u', 'l', 'e', 's', '\022', '\033', '\n', '\003', 'a', 'n', 'y', '\030', '\003', ' ', '\001', '(', '\010', 'B', '\007', '\372', 'B', '\004', 'j', 
+'\002', '\010', '\001', 'H', '\000', 'R', '\003', 'a', 'n', 'y', '\022', '>', '\n', '\006', 'h', 'e', 'a', 'd', 'e', 'r', '\030', '\004', ' ', '\001', '(', 
+'\013', '2', '$', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', 
+'.', 'H', 'e', 'a', 'd', 'e', 'r', 'M', 'a', 't', 'c', 'h', 'e', 'r', 'H', '\000', 'R', '\006', 'h', 'e', 'a', 'd', 'e', 'r', '\022', 
+'?', '\n', '\010', 'u', 'r', 'l', '_', 'p', 'a', 't', 'h', '\030', '\n', ' ', '\001', '(', '\013', '2', '\"', '.', 'e', 'n', 'v', 'o', 'y', 
+'.', 't', 'y', 'p', 'e', '.', 'm', 'a', 't', 'c', 'h', 'e', 'r', '.', 'v', '3', '.', 'P', 'a', 't', 'h', 'M', 'a', 't', 'c', 
+'h', 'e', 'r', 'H', '\000', 'R', '\007', 'u', 'r', 'l', 'P', 'a', 't', 'h', '\022', 'H', '\n', '\016', 'd', 'e', 's', 't', 'i', 'n', 'a', 
+'t', 'i', 'o', 'n', '_', 'i', 'p', '\030', '\005', ' ', '\001', '(', '\013', '2', '\037', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 
+'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'C', 'i', 'd', 'r', 'R', 'a', 'n', 'g', 'e', 'H', '\000', 'R', '\r', 
+'d', 'e', 's', 't', 'i', 'n', 'a', 't', 'i', 'o', 'n', 'I', 'p', '\022', '6', '\n', '\020', 'd', 'e', 's', 't', 'i', 'n', 'a', 't', 
+'i', 'o', 'n', '_', 'p', 'o', 'r', 't', '\030', '\006', ' ', '\001', '(', '\r', 'B', '\t', '\372', 'B', '\006', '*', '\004', '\030', '\377', '\377', '\003', 
+'H', '\000', 'R', '\017', 'd', 'e', 's', 't', 'i', 'n', 'a', 't', 'i', 'o', 'n', 'P', 'o', 'r', 't', '\022', 'Q', '\n', '\026', 'd', 'e', 
+'s', 't', 'i', 'n', 'a', 't', 'i', 'o', 'n', '_', 'p', 'o', 'r', 't', '_', 'r', 'a', 'n', 'g', 'e', '\030', '\013', ' ', '\001', '(', 
+'\013', '2', '\031', '.', 'e', 'n', 'v', 'o', 'y', '.', 't', 'y', 'p', 'e', '.', 'v', '3', '.', 'I', 'n', 't', '3', '2', 'R', 'a', 
+'n', 'g', 'e', 'H', '\000', 'R', '\024', 'd', 'e', 's', 't', 'i', 'n', 'a', 't', 'i', 'o', 'n', 'P', 'o', 'r', 't', 'R', 'a', 'n', 
+'g', 'e', '\022', 'D', '\n', '\010', 'm', 'e', 't', 'a', 'd', 'a', 't', 'a', '\030', '\007', ' ', '\001', '(', '\013', '2', '&', '.', 'e', 'n', 
+'v', 'o', 'y', '.', 't', 'y', 'p', 'e', '.', 'm', 'a', 't', 'c', 'h', 'e', 'r', '.', 'v', '3', '.', 'M', 'e', 't', 'a', 'd', 
+'a', 't', 'a', 'M', 'a', 't', 'c', 'h', 'e', 'r', 'H', '\000', 'R', '\010', 'm', 'e', 't', 'a', 'd', 'a', 't', 'a', '\022', '=', '\n', 
+'\010', 'n', 'o', 't', '_', 'r', 'u', 'l', 'e', '\030', '\010', ' ', '\001', '(', '\013', '2', ' ', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 
+'o', 'n', 'f', 'i', 'g', '.', 'r', 'b', 'a', 'c', '.', 'v', '3', '.', 'P', 'e', 'r', 'm', 'i', 's', 's', 'i', 'o', 'n', 'H', 
+'\000', 'R', '\007', 'n', 'o', 't', 'R', 'u', 'l', 'e', '\022', 'Z', '\n', '\025', 'r', 'e', 'q', 'u', 'e', 's', 't', 'e', 'd', '_', 's', 
+'e', 'r', 'v', 'e', 'r', '_', 'n', 'a', 'm', 'e', '\030', '\t', ' ', '\001', '(', '\013', '2', '$', '.', 'e', 'n', 'v', 'o', 'y', '.', 
+'t', 'y', 'p', 'e', '.', 'm', 'a', 't', 'c', 'h', 'e', 'r', '.', 'v', '3', '.', 'S', 't', 'r', 'i', 'n', 'g', 'M', 'a', 't', 
+'c', 'h', 'e', 'r', 'H', '\000', 'R', '\023', 'r', 'e', 'q', 'u', 'e', 's', 't', 'e', 'd', 'S', 'e', 'r', 'v', 'e', 'r', 'N', 'a', 
+'m', 'e', '\032', 's', '\n', '\003', 'S', 'e', 't', '\022', '@', '\n', '\005', 'r', 'u', 'l', 'e', 's', '\030', '\001', ' ', '\003', '(', '\013', '2', 
+' ', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'b', 'a', 'c', '.', 'v', '3', '.', 'P', 'e', 
+'r', 'm', 'i', 's', 's', 'i', 'o', 'n', 'B', '\010', '\372', 'B', '\005', '\222', '\001', '\002', '\010', '\001', 'R', '\005', 'r', 'u', 'l', 'e', 's', 
+':', '*', '\232', '\305', '\210', '\036', '%', '\n', '#', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'b', 'a', 
+'c', '.', 'v', '2', '.', 'P', 'e', 'r', 'm', 'i', 's', 's', 'i', 'o', 'n', '.', 'S', 'e', 't', ':', '&', '\232', '\305', '\210', '\036', 
+'!', '\n', '\037', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'b', 'a', 'c', '.', 'v', '2', '.', 'P', 
+'e', 'r', 'm', 'i', 's', 's', 'i', 'o', 'n', 'B', '\013', '\n', '\004', 'r', 'u', 'l', 'e', '\022', '\003', '\370', 'B', '\001', '\"', '\233', '\010', 
+'\n', '\t', 'P', 'r', 'i', 'n', 'c', 'i', 'p', 'a', 'l', '\022', '>', '\n', '\007', 'a', 'n', 'd', '_', 'i', 'd', 's', '\030', '\001', ' ', 
+'\001', '(', '\013', '2', '#', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'b', 'a', 'c', '.', 'v', 
+'3', '.', 'P', 'r', 'i', 'n', 'c', 'i', 'p', 'a', 'l', '.', 'S', 'e', 't', 'H', '\000', 'R', '\006', 'a', 'n', 'd', 'I', 'd', 's', 
+'\022', '<', '\n', '\006', 'o', 'r', '_', 'i', 'd', 's', '\030', '\002', ' ', '\001', '(', '\013', '2', '#', '.', 'e', 'n', 'v', 'o', 'y', '.', 
+'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'b', 'a', 'c', '.', 'v', '3', '.', 'P', 'r', 'i', 'n', 'c', 'i', 'p', 'a', 'l', '.', 
+'S', 'e', 't', 'H', '\000', 'R', '\005', 'o', 'r', 'I', 'd', 's', '\022', '\033', '\n', '\003', 'a', 'n', 'y', '\030', '\003', ' ', '\001', '(', '\010', 
+'B', '\007', '\372', 'B', '\004', 'j', '\002', '\010', '\001', 'H', '\000', 'R', '\003', 'a', 'n', 'y', '\022', 'U', '\n', '\r', 'a', 'u', 't', 'h', 'e', 
+'n', 't', 'i', 'c', 'a', 't', 'e', 'd', '\030', '\004', ' ', '\001', '(', '\013', '2', '-', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 
+'n', 'f', 'i', 'g', '.', 'r', 'b', 'a', 'c', '.', 'v', '3', '.', 'P', 'r', 'i', 'n', 'c', 'i', 'p', 'a', 'l', '.', 'A', 'u', 
+'t', 'h', 'e', 'n', 't', 'i', 'c', 'a', 't', 'e', 'd', 'H', '\000', 'R', '\r', 'a', 'u', 't', 'h', 'e', 'n', 't', 'i', 'c', 'a', 
+'t', 'e', 'd', '\022', 'K', '\n', '\t', 's', 'o', 'u', 'r', 'c', 'e', '_', 'i', 'p', '\030', '\005', ' ', '\001', '(', '\013', '2', '\037', '.', 
+'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'C', 'i', 'd', 'r', 
+'R', 'a', 'n', 'g', 'e', 'B', '\013', '\030', '\001', '\222', '\307', '\206', '\330', '\004', '\003', '3', '.', '0', 'H', '\000', 'R', '\010', 's', 'o', 'u', 
+'r', 'c', 'e', 'I', 'p', '\022', 'K', '\n', '\020', 'd', 'i', 'r', 'e', 'c', 't', '_', 'r', 'e', 'm', 'o', 't', 'e', '_', 'i', 'p', 
+'\030', '\n', ' ', '\001', '(', '\013', '2', '\037', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 
+'e', '.', 'v', '3', '.', 'C', 'i', 'd', 'r', 'R', 'a', 'n', 'g', 'e', 'H', '\000', 'R', '\016', 'd', 'i', 'r', 'e', 'c', 't', 'R', 
+'e', 'm', 'o', 't', 'e', 'I', 'p', '\022', '>', '\n', '\t', 'r', 'e', 'm', 'o', 't', 'e', '_', 'i', 'p', '\030', '\013', ' ', '\001', '(', 
+'\013', '2', '\037', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 
+'C', 'i', 'd', 'r', 'R', 'a', 'n', 'g', 'e', 'H', '\000', 'R', '\010', 'r', 'e', 'm', 'o', 't', 'e', 'I', 'p', '\022', '>', '\n', '\006', 
+'h', 'e', 'a', 'd', 'e', 'r', '\030', '\006', ' ', '\001', '(', '\013', '2', '$', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 
+'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'H', 'e', 'a', 'd', 'e', 'r', 'M', 'a', 't', 'c', 'h', 'e', 'r', 
+'H', '\000', 'R', '\006', 'h', 'e', 'a', 'd', 'e', 'r', '\022', '?', '\n', '\010', 'u', 'r', 'l', '_', 'p', 'a', 't', 'h', '\030', '\t', ' ', 
+'\001', '(', '\013', '2', '\"', '.', 'e', 'n', 'v', 'o', 'y', '.', 't', 'y', 'p', 'e', '.', 'm', 'a', 't', 'c', 'h', 'e', 'r', '.', 
+'v', '3', '.', 'P', 'a', 't', 'h', 'M', 'a', 't', 'c', 'h', 'e', 'r', 'H', '\000', 'R', '\007', 'u', 'r', 'l', 'P', 'a', 't', 'h', 
+'\022', 'D', '\n', '\010', 'm', 'e', 't', 'a', 'd', 'a', 't', 'a', '\030', '\007', ' ', '\001', '(', '\013', '2', '&', '.', 'e', 'n', 'v', 'o', 
+'y', '.', 't', 'y', 'p', 'e', '.', 'm', 'a', 't', 'c', 'h', 'e', 'r', '.', 'v', '3', '.', 'M', 'e', 't', 'a', 'd', 'a', 't', 
+'a', 'M', 'a', 't', 'c', 'h', 'e', 'r', 'H', '\000', 'R', '\010', 'm', 'e', 't', 'a', 'd', 'a', 't', 'a', '\022', '8', '\n', '\006', 'n', 
+'o', 't', '_', 'i', 'd', '\030', '\010', ' ', '\001', '(', '\013', '2', '\037', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 
+'g', '.', 'r', 'b', 'a', 'c', '.', 'v', '3', '.', 'P', 'r', 'i', 'n', 'c', 'i', 'p', 'a', 'l', 'H', '\000', 'R', '\005', 'n', 'o', 
+'t', 'I', 'd', '\032', 'm', '\n', '\003', 'S', 'e', 't', '\022', ';', '\n', '\003', 'i', 'd', 's', '\030', '\001', ' ', '\003', '(', '\013', '2', '\037', 
+'.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'b', 'a', 'c', '.', 'v', '3', '.', 'P', 'r', 'i', 
+'n', 'c', 'i', 'p', 'a', 'l', 'B', '\010', '\372', 'B', '\005', '\222', '\001', '\002', '\010', '\001', 'R', '\003', 'i', 'd', 's', ':', ')', '\232', '\305', 
+'\210', '\036', '$', '\n', '\"', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'b', 'a', 'c', '.', 'v', '2', 
+'.', 'P', 'r', 'i', 'n', 'c', 'i', 'p', 'a', 'l', '.', 'S', 'e', 't', '\032', '\227', '\001', '\n', '\r', 'A', 'u', 't', 'h', 'e', 'n', 
+'t', 'i', 'c', 'a', 't', 'e', 'd', '\022', 'K', '\n', '\016', 'p', 'r', 'i', 'n', 'c', 'i', 'p', 'a', 'l', '_', 'n', 'a', 'm', 'e', 
+'\030', '\002', ' ', '\001', '(', '\013', '2', '$', '.', 'e', 'n', 'v', 'o', 'y', '.', 't', 'y', 'p', 'e', '.', 'm', 'a', 't', 'c', 'h', 
+'e', 'r', '.', 'v', '3', '.', 'S', 't', 'r', 'i', 'n', 'g', 'M', 'a', 't', 'c', 'h', 'e', 'r', 'R', '\r', 'p', 'r', 'i', 'n', 
+'c', 'i', 'p', 'a', 'l', 'N', 'a', 'm', 'e', ':', '3', '\232', '\305', '\210', '\036', '.', '\n', ',', 'e', 'n', 'v', 'o', 'y', '.', 'c', 
+'o', 'n', 'f', 'i', 'g', '.', 'r', 'b', 'a', 'c', '.', 'v', '2', '.', 'P', 'r', 'i', 'n', 'c', 'i', 'p', 'a', 'l', '.', 'A', 
+'u', 't', 'h', 'e', 'n', 't', 'i', 'c', 'a', 't', 'e', 'd', 'J', '\004', '\010', '\001', '\020', '\002', ':', '%', '\232', '\305', '\210', '\036', ' ', 
+'\n', '\036', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'b', 'a', 'c', '.', 'v', '2', '.', 'P', 'r', 
+'i', 'n', 'c', 'i', 'p', 'a', 'l', 'B', '\021', '\n', '\n', 'i', 'd', 'e', 'n', 't', 'i', 'f', 'i', 'e', 'r', '\022', '\003', '\370', 'B', 
+'\001', 'B', '9', '\n', '\"', 'i', 'o', '.', 'e', 'n', 'v', 'o', 'y', 'p', 'r', 'o', 'x', 'y', '.', 'e', 'n', 'v', 'o', 'y', '.', 
+'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'b', 'a', 'c', '.', 'v', '3', 'B', '\t', 'R', 'b', 'a', 'c', 'P', 'r', 'o', 't', 'o', 
+'P', '\001', '\272', '\200', '\310', '\321', '\006', '\002', '\020', '\002', 'b', '\006', 'p', 'r', 'o', 't', 'o', '3', 
 };
 
-static upb_def_init *deps[13] = {
+static upb_def_init *deps[14] = {
   &envoy_config_core_v3_address_proto_upbdefinit,
   &envoy_config_route_v3_route_components_proto_upbdefinit,
   &envoy_type_matcher_v3_metadata_proto_upbdefinit,
   &envoy_type_matcher_v3_path_proto_upbdefinit,
   &envoy_type_matcher_v3_string_proto_upbdefinit,
+  &envoy_type_v3_range_proto_upbdefinit,
   &google_api_expr_v1alpha1_checked_proto_upbdefinit,
   &google_api_expr_v1alpha1_syntax_proto_upbdefinit,
   &envoy_annotations_deprecation_proto_upbdefinit,
@@ -190,5 +196,5 @@ upb_def_init envoy_config_rbac_v3_rbac_proto_upbdefinit = {
   deps,
   layouts,
   "envoy/config/rbac/v3/rbac.proto",
-  UPB_STRVIEW_INIT(descriptor, 3158)
+  UPB_STRVIEW_INIT(descriptor, 3268)
 };
index dbeb834..8b1559d 100644 (file)
@@ -12,6 +12,7 @@
 extern upb_def_init envoy_config_core_v3_base_proto_upbdefinit;
 extern upb_def_init envoy_config_core_v3_extension_proto_upbdefinit;
 extern upb_def_init envoy_config_core_v3_proxy_protocol_proto_upbdefinit;
+extern upb_def_init envoy_type_matcher_v3_metadata_proto_upbdefinit;
 extern upb_def_init envoy_type_matcher_v3_regex_proto_upbdefinit;
 extern upb_def_init envoy_type_matcher_v3_string_proto_upbdefinit;
 extern upb_def_init envoy_type_metadata_v3_metadata_proto_upbdefinit;
@@ -136,809 +137,819 @@ static const upb_msglayout *layouts[53] = {
   &envoy_config_route_v3_FilterConfig_msginit,
 };
 
-static const char descriptor[19924] = {'\n', ',', 'e', 'n', 'v', 'o', 'y', '/', 'c', 'o', 'n', 'f', 'i', 'g', '/', 'r', 'o', 'u', 't', 'e', '/', 'v', '3', '/', 'r', 
+static const char descriptor[20140] = {'\n', ',', 'e', 'n', 'v', 'o', 'y', '/', 'c', 'o', 'n', 'f', 'i', 'g', '/', 'r', 'o', 'u', 't', 'e', '/', 'v', '3', '/', 'r', 
 'o', 'u', 't', 'e', '_', 'c', 'o', 'm', 'p', 'o', 'n', 'e', 'n', 't', 's', '.', 'p', 'r', 'o', 't', 'o', '\022', '\025', 'e', 'n', 
 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '\032', '\037', 'e', 'n', 'v', 'o', 
 'y', '/', 'c', 'o', 'n', 'f', 'i', 'g', '/', 'c', 'o', 'r', 'e', '/', 'v', '3', '/', 'b', 'a', 's', 'e', '.', 'p', 'r', 'o', 
 't', 'o', '\032', '$', 'e', 'n', 'v', 'o', 'y', '/', 'c', 'o', 'n', 'f', 'i', 'g', '/', 'c', 'o', 'r', 'e', '/', 'v', '3', '/', 
 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', '.', 'p', 'r', 'o', 't', 'o', '\032', ')', 'e', 'n', 'v', 'o', 'y', '/', 'c', 'o', 
 'n', 'f', 'i', 'g', '/', 'c', 'o', 'r', 'e', '/', 'v', '3', '/', 'p', 'r', 'o', 'x', 'y', '_', 'p', 'r', 'o', 't', 'o', 'c', 
-'o', 'l', '.', 'p', 'r', 'o', 't', 'o', '\032', '!', 'e', 'n', 'v', 'o', 'y', '/', 't', 'y', 'p', 'e', '/', 'm', 'a', 't', 'c', 
-'h', 'e', 'r', '/', 'v', '3', '/', 'r', 'e', 'g', 'e', 'x', '.', 'p', 'r', 'o', 't', 'o', '\032', '\"', 'e', 'n', 'v', 'o', 'y', 
-'/', 't', 'y', 'p', 'e', '/', 'm', 'a', 't', 'c', 'h', 'e', 'r', '/', 'v', '3', '/', 's', 't', 'r', 'i', 'n', 'g', '.', 'p', 
-'r', 'o', 't', 'o', '\032', '%', 'e', 'n', 'v', 'o', 'y', '/', 't', 'y', 'p', 'e', '/', 'm', 'e', 't', 'a', 'd', 'a', 't', 'a', 
-'/', 'v', '3', '/', 'm', 'e', 't', 'a', 'd', 'a', 't', 'a', '.', 'p', 'r', 'o', 't', 'o', '\032', '&', 'e', 'n', 'v', 'o', 'y', 
-'/', 't', 'y', 'p', 'e', '/', 't', 'r', 'a', 'c', 'i', 'n', 'g', '/', 'v', '3', '/', 'c', 'u', 's', 't', 'o', 'm', '_', 't', 
-'a', 'g', '.', 'p', 'r', 'o', 't', 'o', '\032', '\033', 'e', 'n', 'v', 'o', 'y', '/', 't', 'y', 'p', 'e', '/', 'v', '3', '/', 'p', 
-'e', 'r', 'c', 'e', 'n', 't', '.', 'p', 'r', 'o', 't', 'o', '\032', '\031', 'e', 'n', 'v', 'o', 'y', '/', 't', 'y', 'p', 'e', '/', 
-'v', '3', '/', 'r', 'a', 'n', 'g', 'e', '.', 'p', 'r', 'o', 't', 'o', '\032', '\031', 'g', 'o', 'o', 'g', 'l', 'e', '/', 'p', 'r', 
-'o', 't', 'o', 'b', 'u', 'f', '/', 'a', 'n', 'y', '.', 'p', 'r', 'o', 't', 'o', '\032', '\036', 'g', 'o', 'o', 'g', 'l', 'e', '/', 
-'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '/', 'd', 'u', 'r', 'a', 't', 'i', 'o', 'n', '.', 'p', 'r', 'o', 't', 'o', '\032', '\036', 
-'g', 'o', 'o', 'g', 'l', 'e', '/', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '/', 'w', 'r', 'a', 'p', 'p', 'e', 'r', 's', '.', 
-'p', 'r', 'o', 't', 'o', '\032', '#', 'e', 'n', 'v', 'o', 'y', '/', 'a', 'n', 'n', 'o', 't', 'a', 't', 'i', 'o', 'n', 's', '/', 
-'d', 'e', 'p', 'r', 'e', 'c', 'a', 't', 'i', 'o', 'n', '.', 'p', 'r', 'o', 't', 'o', '\032', '\036', 'u', 'd', 'p', 'a', '/', 'a', 
-'n', 'n', 'o', 't', 'a', 't', 'i', 'o', 'n', 's', '/', 'm', 'i', 'g', 'r', 'a', 't', 'e', '.', 'p', 'r', 'o', 't', 'o', '\032', 
-'\035', 'u', 'd', 'p', 'a', '/', 'a', 'n', 'n', 'o', 't', 'a', 't', 'i', 'o', 'n', 's', '/', 's', 't', 'a', 't', 'u', 's', '.', 
-'p', 'r', 'o', 't', 'o', '\032', '!', 'u', 'd', 'p', 'a', '/', 'a', 'n', 'n', 'o', 't', 'a', 't', 'i', 'o', 'n', 's', '/', 'v', 
-'e', 'r', 's', 'i', 'o', 'n', 'i', 'n', 'g', '.', 'p', 'r', 'o', 't', 'o', '\032', '\027', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'e', 
-'/', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'e', '.', 'p', 'r', 'o', 't', 'o', '\"', '\324', '\014', '\n', '\013', 'V', 'i', 'r', 't', 'u', 
-'a', 'l', 'H', 'o', 's', 't', '\022', '\033', '\n', '\004', 'n', 'a', 'm', 'e', '\030', '\001', ' ', '\001', '(', '\t', 'B', '\007', '\372', 'B', '\004', 
-'r', '\002', '\020', '\001', 'R', '\004', 'n', 'a', 'm', 'e', '\022', ',', '\n', '\007', 'd', 'o', 'm', 'a', 'i', 'n', 's', '\030', '\002', ' ', '\003', 
-'(', '\t', 'B', '\022', '\372', 'B', '\017', '\222', '\001', '\014', '\010', '\001', '\"', '\010', 'r', '\006', '\300', '\001', '\002', '\310', '\001', '\000', 'R', '\007', 'd', 
-'o', 'm', 'a', 'i', 'n', 's', '\022', '4', '\n', '\006', 'r', 'o', 'u', 't', 'e', 's', '\030', '\003', ' ', '\003', '(', '\013', '2', '\034', '.', 
-'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'R', 'o', 'u', 
-'t', 'e', 'R', '\006', 'r', 'o', 'u', 't', 'e', 's', '\022', '`', '\n', '\013', 'r', 'e', 'q', 'u', 'i', 'r', 'e', '_', 't', 'l', 's', 
-'\030', '\004', ' ', '\001', '(', '\016', '2', '5', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 
-'t', 'e', '.', 'v', '3', '.', 'V', 'i', 'r', 't', 'u', 'a', 'l', 'H', 'o', 's', 't', '.', 'T', 'l', 's', 'R', 'e', 'q', 'u', 
-'i', 'r', 'e', 'm', 'e', 'n', 't', 'T', 'y', 'p', 'e', 'B', '\010', '\372', 'B', '\005', '\202', '\001', '\002', '\020', '\001', 'R', '\n', 'r', 'e', 
-'q', 'u', 'i', 'r', 'e', 'T', 'l', 's', '\022', 'P', '\n', '\020', 'v', 'i', 'r', 't', 'u', 'a', 'l', '_', 'c', 'l', 'u', 's', 't', 
-'e', 'r', 's', '\030', '\005', ' ', '\003', '(', '\013', '2', '%', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 
-'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'V', 'i', 'r', 't', 'u', 'a', 'l', 'C', 'l', 'u', 's', 't', 'e', 'r', 'R', '\017', 
-'v', 'i', 'r', 't', 'u', 'a', 'l', 'C', 'l', 'u', 's', 't', 'e', 'r', 's', '\022', 'A', '\n', '\013', 'r', 'a', 't', 'e', '_', 'l', 
-'i', 'm', 'i', 't', 's', '\030', '\006', ' ', '\003', '(', '\013', '2', ' ', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 
-'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'R', 'a', 't', 'e', 'L', 'i', 'm', 'i', 't', 'R', '\n', 'r', 'a', 't', 
-'e', 'L', 'i', 'm', 'i', 't', 's', '\022', 'g', '\n', '\026', 'r', 'e', 'q', 'u', 'e', 's', 't', '_', 'h', 'e', 'a', 'd', 'e', 'r', 
-'s', '_', 't', 'o', '_', 'a', 'd', 'd', '\030', '\007', ' ', '\003', '(', '\013', '2', '\'', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 
-'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'H', 'e', 'a', 'd', 'e', 'r', 'V', 'a', 'l', 'u', 'e', 'O', 
-'p', 't', 'i', 'o', 'n', 'B', '\t', '\372', 'B', '\006', '\222', '\001', '\003', '\020', '\350', '\007', 'R', '\023', 'r', 'e', 'q', 'u', 'e', 's', 't', 
-'H', 'e', 'a', 'd', 'e', 'r', 's', 'T', 'o', 'A', 'd', 'd', '\022', 'M', '\n', '\031', 'r', 'e', 'q', 'u', 'e', 's', 't', '_', 'h', 
-'e', 'a', 'd', 'e', 'r', 's', '_', 't', 'o', '_', 'r', 'e', 'm', 'o', 'v', 'e', '\030', '\r', ' ', '\003', '(', '\t', 'B', '\022', '\372', 
-'B', '\017', '\222', '\001', '\014', '\"', '\n', 'r', '\010', '\020', '\001', '\300', '\001', '\001', '\310', '\001', '\000', 'R', '\026', 'r', 'e', 'q', 'u', 'e', 's', 
-'t', 'H', 'e', 'a', 'd', 'e', 'r', 's', 'T', 'o', 'R', 'e', 'm', 'o', 'v', 'e', '\022', 'i', '\n', '\027', 'r', 'e', 's', 'p', 'o', 
-'n', 's', 'e', '_', 'h', 'e', 'a', 'd', 'e', 'r', 's', '_', 't', 'o', '_', 'a', 'd', 'd', '\030', '\n', ' ', '\003', '(', '\013', '2', 
-'\'', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'H', 'e', 
-'a', 'd', 'e', 'r', 'V', 'a', 'l', 'u', 'e', 'O', 'p', 't', 'i', 'o', 'n', 'B', '\t', '\372', 'B', '\006', '\222', '\001', '\003', '\020', '\350', 
-'\007', 'R', '\024', 'r', 'e', 's', 'p', 'o', 'n', 's', 'e', 'H', 'e', 'a', 'd', 'e', 'r', 's', 'T', 'o', 'A', 'd', 'd', '\022', 'O', 
-'\n', '\032', 'r', 'e', 's', 'p', 'o', 'n', 's', 'e', '_', 'h', 'e', 'a', 'd', 'e', 'r', 's', '_', 't', 'o', '_', 'r', 'e', 'm', 
-'o', 'v', 'e', '\030', '\013', ' ', '\003', '(', '\t', 'B', '\022', '\372', 'B', '\017', '\222', '\001', '\014', '\"', '\n', 'r', '\010', '\020', '\001', '\300', '\001', 
-'\001', '\310', '\001', '\000', 'R', '\027', 'r', 'e', 's', 'p', 'o', 'n', 's', 'e', 'H', 'e', 'a', 'd', 'e', 'r', 's', 'T', 'o', 'R', 'e', 
-'m', 'o', 'v', 'e', '\022', '5', '\n', '\004', 'c', 'o', 'r', 's', '\030', '\010', ' ', '\001', '(', '\013', '2', '!', '.', 'e', 'n', 'v', 'o', 
-'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'C', 'o', 'r', 's', 'P', 'o', 'l', 
-'i', 'c', 'y', 'R', '\004', 'c', 'o', 'r', 's', '\022', 's', '\n', '\027', 't', 'y', 'p', 'e', 'd', '_', 'p', 'e', 'r', '_', 'f', 'i', 
-'l', 't', 'e', 'r', '_', 'c', 'o', 'n', 'f', 'i', 'g', '\030', '\017', ' ', '\003', '(', '\013', '2', '<', '.', 'e', 'n', 'v', 'o', 'y', 
-'.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'V', 'i', 'r', 't', 'u', 'a', 'l', 'H', 
-'o', 's', 't', '.', 'T', 'y', 'p', 'e', 'd', 'P', 'e', 'r', 'F', 'i', 'l', 't', 'e', 'r', 'C', 'o', 'n', 'f', 'i', 'g', 'E', 
-'n', 't', 'r', 'y', 'R', '\024', 't', 'y', 'p', 'e', 'd', 'P', 'e', 'r', 'F', 'i', 'l', 't', 'e', 'r', 'C', 'o', 'n', 'f', 'i', 
-'g', '\022', 'A', '\n', '\035', 'i', 'n', 'c', 'l', 'u', 'd', 'e', '_', 'r', 'e', 'q', 'u', 'e', 's', 't', '_', 'a', 't', 't', 'e', 
-'m', 'p', 't', '_', 'c', 'o', 'u', 'n', 't', '\030', '\016', ' ', '\001', '(', '\010', 'R', '\032', 'i', 'n', 'c', 'l', 'u', 'd', 'e', 'R', 
-'e', 'q', 'u', 'e', 's', 't', 'A', 't', 't', 'e', 'm', 'p', 't', 'C', 'o', 'u', 'n', 't', '\022', 'H', '\n', '!', 'i', 'n', 'c', 
-'l', 'u', 'd', 'e', '_', 'a', 't', 't', 'e', 'm', 'p', 't', '_', 'c', 'o', 'u', 'n', 't', '_', 'i', 'n', '_', 'r', 'e', 's', 
-'p', 'o', 'n', 's', 'e', '\030', '\023', ' ', '\001', '(', '\010', 'R', '\035', 'i', 'n', 'c', 'l', 'u', 'd', 'e', 'A', 't', 't', 'e', 'm', 
-'p', 't', 'C', 'o', 'u', 'n', 't', 'I', 'n', 'R', 'e', 's', 'p', 'o', 'n', 's', 'e', '\022', 'E', '\n', '\014', 'r', 'e', 't', 'r', 
-'y', '_', 'p', 'o', 'l', 'i', 'c', 'y', '\030', '\020', ' ', '\001', '(', '\013', '2', '\"', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 
-'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'R', 'e', 't', 'r', 'y', 'P', 'o', 'l', 'i', 'c', 'y', 
-'R', '\013', 'r', 'e', 't', 'r', 'y', 'P', 'o', 'l', 'i', 'c', 'y', '\022', 'O', '\n', '\031', 'r', 'e', 't', 'r', 'y', '_', 'p', 'o', 
-'l', 'i', 'c', 'y', '_', 't', 'y', 'p', 'e', 'd', '_', 'c', 'o', 'n', 'f', 'i', 'g', '\030', '\024', ' ', '\001', '(', '\013', '2', '\024', 
-'.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'A', 'n', 'y', 'R', '\026', 'r', 'e', 't', 
-'r', 'y', 'P', 'o', 'l', 'i', 'c', 'y', 'T', 'y', 'p', 'e', 'd', 'C', 'o', 'n', 'f', 'i', 'g', '\022', 'E', '\n', '\014', 'h', 'e', 
-'d', 'g', 'e', '_', 'p', 'o', 'l', 'i', 'c', 'y', '\030', '\021', ' ', '\001', '(', '\013', '2', '\"', '.', 'e', 'n', 'v', 'o', 'y', '.', 
-'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'H', 'e', 'd', 'g', 'e', 'P', 'o', 'l', 'i', 
-'c', 'y', 'R', '\013', 'h', 'e', 'd', 'g', 'e', 'P', 'o', 'l', 'i', 'c', 'y', '\022', '`', '\n', '\036', 'p', 'e', 'r', '_', 'r', 'e', 
-'q', 'u', 'e', 's', 't', '_', 'b', 'u', 'f', 'f', 'e', 'r', '_', 'l', 'i', 'm', 'i', 't', '_', 'b', 'y', 't', 'e', 's', '\030', 
-'\022', ' ', '\001', '(', '\013', '2', '\034', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'U', 
-'I', 'n', 't', '3', '2', 'V', 'a', 'l', 'u', 'e', 'R', '\032', 'p', 'e', 'r', 'R', 'e', 'q', 'u', 'e', 's', 't', 'B', 'u', 'f', 
-'f', 'e', 'r', 'L', 'i', 'm', 'i', 't', 'B', 'y', 't', 'e', 's', '\032', ']', '\n', '\031', 'T', 'y', 'p', 'e', 'd', 'P', 'e', 'r', 
-'F', 'i', 'l', 't', 'e', 'r', 'C', 'o', 'n', 'f', 'i', 'g', 'E', 'n', 't', 'r', 'y', '\022', '\020', '\n', '\003', 'k', 'e', 'y', '\030', 
-'\001', ' ', '\001', '(', '\t', 'R', '\003', 'k', 'e', 'y', '\022', '*', '\n', '\005', 'v', 'a', 'l', 'u', 'e', '\030', '\002', ' ', '\001', '(', '\013', 
-'2', '\024', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'A', 'n', 'y', 'R', '\005', 'v', 
-'a', 'l', 'u', 'e', ':', '\002', '8', '\001', '\"', ':', '\n', '\022', 'T', 'l', 's', 'R', 'e', 'q', 'u', 'i', 'r', 'e', 'm', 'e', 'n', 
-'t', 'T', 'y', 'p', 'e', '\022', '\010', '\n', '\004', 'N', 'O', 'N', 'E', '\020', '\000', '\022', '\021', '\n', '\r', 'E', 'X', 'T', 'E', 'R', 'N', 
-'A', 'L', '_', 'O', 'N', 'L', 'Y', '\020', '\001', '\022', '\007', '\n', '\003', 'A', 'L', 'L', '\020', '\002', ':', '%', '\232', '\305', '\210', '\036', ' ', 
-'\n', '\036', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'r', 'o', 'u', 't', 'e', '.', 'V', 'i', 'r', 't', 
-'u', 'a', 'l', 'H', 'o', 's', 't', 'J', '\004', '\010', '\t', '\020', '\n', 'J', '\004', '\010', '\014', '\020', '\r', 'R', '\021', 'p', 'e', 'r', '_', 
-'f', 'i', 'l', 't', 'e', 'r', '_', 'c', 'o', 'n', 'f', 'i', 'g', '\"', 'd', '\n', '\014', 'F', 'i', 'l', 't', 'e', 'r', 'A', 'c', 
-'t', 'i', 'o', 'n', '\022', ',', '\n', '\006', 'a', 'c', 't', 'i', 'o', 'n', '\030', '\001', ' ', '\001', '(', '\013', '2', '\024', '.', 'g', 'o', 
-'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'A', 'n', 'y', 'R', '\006', 'a', 'c', 't', 'i', 'o', 'n', 
-':', '&', '\232', '\305', '\210', '\036', '!', '\n', '\037', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'r', 'o', 'u', 
-'t', 'e', '.', 'F', 'i', 'l', 't', 'e', 'r', 'A', 'c', 't', 'i', 'o', 'n', '\"', '\216', '\013', '\n', '\005', 'R', 'o', 'u', 't', 'e', 
-'\022', '\022', '\n', '\004', 'n', 'a', 'm', 'e', '\030', '\016', ' ', '\001', '(', '\t', 'R', '\004', 'n', 'a', 'm', 'e', '\022', 'A', '\n', '\005', 'm', 
-'a', 't', 'c', 'h', '\030', '\001', ' ', '\001', '(', '\013', '2', '!', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', 
-'.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'R', 'o', 'u', 't', 'e', 'M', 'a', 't', 'c', 'h', 'B', '\010', '\372', 'B', '\005', 
-'\212', '\001', '\002', '\020', '\001', 'R', '\005', 'm', 'a', 't', 'c', 'h', '\022', ':', '\n', '\005', 'r', 'o', 'u', 't', 'e', '\030', '\002', ' ', '\001', 
+'o', 'l', '.', 'p', 'r', 'o', 't', 'o', '\032', '$', 'e', 'n', 'v', 'o', 'y', '/', 't', 'y', 'p', 'e', '/', 'm', 'a', 't', 'c', 
+'h', 'e', 'r', '/', 'v', '3', '/', 'm', 'e', 't', 'a', 'd', 'a', 't', 'a', '.', 'p', 'r', 'o', 't', 'o', '\032', '!', 'e', 'n', 
+'v', 'o', 'y', '/', 't', 'y', 'p', 'e', '/', 'm', 'a', 't', 'c', 'h', 'e', 'r', '/', 'v', '3', '/', 'r', 'e', 'g', 'e', 'x', 
+'.', 'p', 'r', 'o', 't', 'o', '\032', '\"', 'e', 'n', 'v', 'o', 'y', '/', 't', 'y', 'p', 'e', '/', 'm', 'a', 't', 'c', 'h', 'e', 
+'r', '/', 'v', '3', '/', 's', 't', 'r', 'i', 'n', 'g', '.', 'p', 'r', 'o', 't', 'o', '\032', '%', 'e', 'n', 'v', 'o', 'y', '/', 
+'t', 'y', 'p', 'e', '/', 'm', 'e', 't', 'a', 'd', 'a', 't', 'a', '/', 'v', '3', '/', 'm', 'e', 't', 'a', 'd', 'a', 't', 'a', 
+'.', 'p', 'r', 'o', 't', 'o', '\032', '&', 'e', 'n', 'v', 'o', 'y', '/', 't', 'y', 'p', 'e', '/', 't', 'r', 'a', 'c', 'i', 'n', 
+'g', '/', 'v', '3', '/', 'c', 'u', 's', 't', 'o', 'm', '_', 't', 'a', 'g', '.', 'p', 'r', 'o', 't', 'o', '\032', '\033', 'e', 'n', 
+'v', 'o', 'y', '/', 't', 'y', 'p', 'e', '/', 'v', '3', '/', 'p', 'e', 'r', 'c', 'e', 'n', 't', '.', 'p', 'r', 'o', 't', 'o', 
+'\032', '\031', 'e', 'n', 'v', 'o', 'y', '/', 't', 'y', 'p', 'e', '/', 'v', '3', '/', 'r', 'a', 'n', 'g', 'e', '.', 'p', 'r', 'o', 
+'t', 'o', '\032', '\031', 'g', 'o', 'o', 'g', 'l', 'e', '/', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '/', 'a', 'n', 'y', '.', 'p', 
+'r', 'o', 't', 'o', '\032', '\036', 'g', 'o', 'o', 'g', 'l', 'e', '/', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '/', 'd', 'u', 'r', 
+'a', 't', 'i', 'o', 'n', '.', 'p', 'r', 'o', 't', 'o', '\032', '\036', 'g', 'o', 'o', 'g', 'l', 'e', '/', 'p', 'r', 'o', 't', 'o', 
+'b', 'u', 'f', '/', 'w', 'r', 'a', 'p', 'p', 'e', 'r', 's', '.', 'p', 'r', 'o', 't', 'o', '\032', '#', 'e', 'n', 'v', 'o', 'y', 
+'/', 'a', 'n', 'n', 'o', 't', 'a', 't', 'i', 'o', 'n', 's', '/', 'd', 'e', 'p', 'r', 'e', 'c', 'a', 't', 'i', 'o', 'n', '.', 
+'p', 'r', 'o', 't', 'o', '\032', '\036', 'u', 'd', 'p', 'a', '/', 'a', 'n', 'n', 'o', 't', 'a', 't', 'i', 'o', 'n', 's', '/', 'm', 
+'i', 'g', 'r', 'a', 't', 'e', '.', 'p', 'r', 'o', 't', 'o', '\032', '\035', 'u', 'd', 'p', 'a', '/', 'a', 'n', 'n', 'o', 't', 'a', 
+'t', 'i', 'o', 'n', 's', '/', 's', 't', 'a', 't', 'u', 's', '.', 'p', 'r', 'o', 't', 'o', '\032', '!', 'u', 'd', 'p', 'a', '/', 
+'a', 'n', 'n', 'o', 't', 'a', 't', 'i', 'o', 'n', 's', '/', 'v', 'e', 'r', 's', 'i', 'o', 'n', 'i', 'n', 'g', '.', 'p', 'r', 
+'o', 't', 'o', '\032', '\027', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'e', '/', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'e', '.', 'p', 'r', 
+'o', 't', 'o', '\"', '\324', '\014', '\n', '\013', 'V', 'i', 'r', 't', 'u', 'a', 'l', 'H', 'o', 's', 't', '\022', '\033', '\n', '\004', 'n', 'a', 
+'m', 'e', '\030', '\001', ' ', '\001', '(', '\t', 'B', '\007', '\372', 'B', '\004', 'r', '\002', '\020', '\001', 'R', '\004', 'n', 'a', 'm', 'e', '\022', ',', 
+'\n', '\007', 'd', 'o', 'm', 'a', 'i', 'n', 's', '\030', '\002', ' ', '\003', '(', '\t', 'B', '\022', '\372', 'B', '\017', '\222', '\001', '\014', '\010', '\001', 
+'\"', '\010', 'r', '\006', '\300', '\001', '\002', '\310', '\001', '\000', 'R', '\007', 'd', 'o', 'm', 'a', 'i', 'n', 's', '\022', '4', '\n', '\006', 'r', 'o', 
+'u', 't', 'e', 's', '\030', '\003', ' ', '\003', '(', '\013', '2', '\034', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', 
+'.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'R', 'o', 'u', 't', 'e', 'R', '\006', 'r', 'o', 'u', 't', 'e', 's', '\022', '`', 
+'\n', '\013', 'r', 'e', 'q', 'u', 'i', 'r', 'e', '_', 't', 'l', 's', '\030', '\004', ' ', '\001', '(', '\016', '2', '5', '.', 'e', 'n', 'v', 
+'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'V', 'i', 'r', 't', 'u', 'a', 
+'l', 'H', 'o', 's', 't', '.', 'T', 'l', 's', 'R', 'e', 'q', 'u', 'i', 'r', 'e', 'm', 'e', 'n', 't', 'T', 'y', 'p', 'e', 'B', 
+'\010', '\372', 'B', '\005', '\202', '\001', '\002', '\020', '\001', 'R', '\n', 'r', 'e', 'q', 'u', 'i', 'r', 'e', 'T', 'l', 's', '\022', 'P', '\n', '\020', 
+'v', 'i', 'r', 't', 'u', 'a', 'l', '_', 'c', 'l', 'u', 's', 't', 'e', 'r', 's', '\030', '\005', ' ', '\003', '(', '\013', '2', '%', '.', 
+'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'V', 'i', 'r', 
+'t', 'u', 'a', 'l', 'C', 'l', 'u', 's', 't', 'e', 'r', 'R', '\017', 'v', 'i', 'r', 't', 'u', 'a', 'l', 'C', 'l', 'u', 's', 't', 
+'e', 'r', 's', '\022', 'A', '\n', '\013', 'r', 'a', 't', 'e', '_', 'l', 'i', 'm', 'i', 't', 's', '\030', '\006', ' ', '\003', '(', '\013', '2', 
+' ', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'R', 
+'a', 't', 'e', 'L', 'i', 'm', 'i', 't', 'R', '\n', 'r', 'a', 't', 'e', 'L', 'i', 'm', 'i', 't', 's', '\022', 'g', '\n', '\026', 'r', 
+'e', 'q', 'u', 'e', 's', 't', '_', 'h', 'e', 'a', 'd', 'e', 'r', 's', '_', 't', 'o', '_', 'a', 'd', 'd', '\030', '\007', ' ', '\003', 
+'(', '\013', '2', '\'', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', 
+'.', 'H', 'e', 'a', 'd', 'e', 'r', 'V', 'a', 'l', 'u', 'e', 'O', 'p', 't', 'i', 'o', 'n', 'B', '\t', '\372', 'B', '\006', '\222', '\001', 
+'\003', '\020', '\350', '\007', 'R', '\023', 'r', 'e', 'q', 'u', 'e', 's', 't', 'H', 'e', 'a', 'd', 'e', 'r', 's', 'T', 'o', 'A', 'd', 'd', 
+'\022', 'M', '\n', '\031', 'r', 'e', 'q', 'u', 'e', 's', 't', '_', 'h', 'e', 'a', 'd', 'e', 'r', 's', '_', 't', 'o', '_', 'r', 'e', 
+'m', 'o', 'v', 'e', '\030', '\r', ' ', '\003', '(', '\t', 'B', '\022', '\372', 'B', '\017', '\222', '\001', '\014', '\"', '\n', 'r', '\010', '\020', '\001', '\300', 
+'\001', '\001', '\310', '\001', '\000', 'R', '\026', 'r', 'e', 'q', 'u', 'e', 's', 't', 'H', 'e', 'a', 'd', 'e', 'r', 's', 'T', 'o', 'R', 'e', 
+'m', 'o', 'v', 'e', '\022', 'i', '\n', '\027', 'r', 'e', 's', 'p', 'o', 'n', 's', 'e', '_', 'h', 'e', 'a', 'd', 'e', 'r', 's', '_', 
+'t', 'o', '_', 'a', 'd', 'd', '\030', '\n', ' ', '\003', '(', '\013', '2', '\'', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 
+'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'H', 'e', 'a', 'd', 'e', 'r', 'V', 'a', 'l', 'u', 'e', 'O', 'p', 't', 
+'i', 'o', 'n', 'B', '\t', '\372', 'B', '\006', '\222', '\001', '\003', '\020', '\350', '\007', 'R', '\024', 'r', 'e', 's', 'p', 'o', 'n', 's', 'e', 'H', 
+'e', 'a', 'd', 'e', 'r', 's', 'T', 'o', 'A', 'd', 'd', '\022', 'O', '\n', '\032', 'r', 'e', 's', 'p', 'o', 'n', 's', 'e', '_', 'h', 
+'e', 'a', 'd', 'e', 'r', 's', '_', 't', 'o', '_', 'r', 'e', 'm', 'o', 'v', 'e', '\030', '\013', ' ', '\003', '(', '\t', 'B', '\022', '\372', 
+'B', '\017', '\222', '\001', '\014', '\"', '\n', 'r', '\010', '\020', '\001', '\300', '\001', '\001', '\310', '\001', '\000', 'R', '\027', 'r', 'e', 's', 'p', 'o', 'n', 
+'s', 'e', 'H', 'e', 'a', 'd', 'e', 'r', 's', 'T', 'o', 'R', 'e', 'm', 'o', 'v', 'e', '\022', '5', '\n', '\004', 'c', 'o', 'r', 's', 
+'\030', '\010', ' ', '\001', '(', '\013', '2', '!', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 
+'t', 'e', '.', 'v', '3', '.', 'C', 'o', 'r', 's', 'P', 'o', 'l', 'i', 'c', 'y', 'R', '\004', 'c', 'o', 'r', 's', '\022', 's', '\n', 
+'\027', 't', 'y', 'p', 'e', 'd', '_', 'p', 'e', 'r', '_', 'f', 'i', 'l', 't', 'e', 'r', '_', 'c', 'o', 'n', 'f', 'i', 'g', '\030', 
+'\017', ' ', '\003', '(', '\013', '2', '<', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 
+'e', '.', 'v', '3', '.', 'V', 'i', 'r', 't', 'u', 'a', 'l', 'H', 'o', 's', 't', '.', 'T', 'y', 'p', 'e', 'd', 'P', 'e', 'r', 
+'F', 'i', 'l', 't', 'e', 'r', 'C', 'o', 'n', 'f', 'i', 'g', 'E', 'n', 't', 'r', 'y', 'R', '\024', 't', 'y', 'p', 'e', 'd', 'P', 
+'e', 'r', 'F', 'i', 'l', 't', 'e', 'r', 'C', 'o', 'n', 'f', 'i', 'g', '\022', 'A', '\n', '\035', 'i', 'n', 'c', 'l', 'u', 'd', 'e', 
+'_', 'r', 'e', 'q', 'u', 'e', 's', 't', '_', 'a', 't', 't', 'e', 'm', 'p', 't', '_', 'c', 'o', 'u', 'n', 't', '\030', '\016', ' ', 
+'\001', '(', '\010', 'R', '\032', 'i', 'n', 'c', 'l', 'u', 'd', 'e', 'R', 'e', 'q', 'u', 'e', 's', 't', 'A', 't', 't', 'e', 'm', 'p', 
+'t', 'C', 'o', 'u', 'n', 't', '\022', 'H', '\n', '!', 'i', 'n', 'c', 'l', 'u', 'd', 'e', '_', 'a', 't', 't', 'e', 'm', 'p', 't', 
+'_', 'c', 'o', 'u', 'n', 't', '_', 'i', 'n', '_', 'r', 'e', 's', 'p', 'o', 'n', 's', 'e', '\030', '\023', ' ', '\001', '(', '\010', 'R', 
+'\035', 'i', 'n', 'c', 'l', 'u', 'd', 'e', 'A', 't', 't', 'e', 'm', 'p', 't', 'C', 'o', 'u', 'n', 't', 'I', 'n', 'R', 'e', 's', 
+'p', 'o', 'n', 's', 'e', '\022', 'E', '\n', '\014', 'r', 'e', 't', 'r', 'y', '_', 'p', 'o', 'l', 'i', 'c', 'y', '\030', '\020', ' ', '\001', 
 '(', '\013', '2', '\"', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', 
-'3', '.', 'R', 'o', 'u', 't', 'e', 'A', 'c', 't', 'i', 'o', 'n', 'H', '\000', 'R', '\005', 'r', 'o', 'u', 't', 'e', '\022', 'C', '\n', 
-'\010', 'r', 'e', 'd', 'i', 'r', 'e', 'c', 't', '\030', '\003', ' ', '\001', '(', '\013', '2', '%', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 
-'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'R', 'e', 'd', 'i', 'r', 'e', 'c', 't', 'A', 'c', 
-'t', 'i', 'o', 'n', 'H', '\000', 'R', '\010', 'r', 'e', 'd', 'i', 'r', 'e', 'c', 't', '\022', 'V', '\n', '\017', 'd', 'i', 'r', 'e', 'c', 
-'t', '_', 'r', 'e', 's', 'p', 'o', 'n', 's', 'e', '\030', '\007', ' ', '\001', '(', '\013', '2', '+', '.', 'e', 'n', 'v', 'o', 'y', '.', 
-'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'D', 'i', 'r', 'e', 'c', 't', 'R', 'e', 's', 
-'p', 'o', 'n', 's', 'e', 'A', 'c', 't', 'i', 'o', 'n', 'H', '\000', 'R', '\016', 'd', 'i', 'r', 'e', 'c', 't', 'R', 'e', 's', 'p', 
-'o', 'n', 's', 'e', '\022', 'J', '\n', '\r', 'f', 'i', 'l', 't', 'e', 'r', '_', 'a', 'c', 't', 'i', 'o', 'n', '\030', '\021', ' ', '\001', 
-'(', '\013', '2', '#', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', 
-'3', '.', 'F', 'i', 'l', 't', 'e', 'r', 'A', 'c', 't', 'i', 'o', 'n', 'H', '\000', 'R', '\014', 'f', 'i', 'l', 't', 'e', 'r', 'A', 
-'c', 't', 'i', 'o', 'n', '\022', '`', '\n', '\025', 'n', 'o', 'n', '_', 'f', 'o', 'r', 'w', 'a', 'r', 'd', 'i', 'n', 'g', '_', 'a', 
-'c', 't', 'i', 'o', 'n', '\030', '\022', ' ', '\001', '(', '\013', '2', '*', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 
-'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'N', 'o', 'n', 'F', 'o', 'r', 'w', 'a', 'r', 'd', 'i', 'n', 'g', 'A', 
-'c', 't', 'i', 'o', 'n', 'H', '\000', 'R', '\023', 'n', 'o', 'n', 'F', 'o', 'r', 'w', 'a', 'r', 'd', 'i', 'n', 'g', 'A', 'c', 't', 
-'i', 'o', 'n', '\022', ':', '\n', '\010', 'm', 'e', 't', 'a', 'd', 'a', 't', 'a', '\030', '\004', ' ', '\001', '(', '\013', '2', '\036', '.', 'e', 
-'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'M', 'e', 't', 'a', 'd', 
-'a', 't', 'a', 'R', '\010', 'm', 'e', 't', 'a', 'd', 'a', 't', 'a', '\022', '>', '\n', '\t', 'd', 'e', 'c', 'o', 'r', 'a', 't', 'o', 
-'r', '\030', '\005', ' ', '\001', '(', '\013', '2', ' ', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 
-'u', 't', 'e', '.', 'v', '3', '.', 'D', 'e', 'c', 'o', 'r', 'a', 't', 'o', 'r', 'R', '\t', 'd', 'e', 'c', 'o', 'r', 'a', 't', 
-'o', 'r', '\022', 'm', '\n', '\027', 't', 'y', 'p', 'e', 'd', '_', 'p', 'e', 'r', '_', 'f', 'i', 'l', 't', 'e', 'r', '_', 'c', 'o', 
-'n', 'f', 'i', 'g', '\030', '\r', ' ', '\003', '(', '\013', '2', '6', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', 
-'.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'R', 'o', 'u', 't', 'e', '.', 'T', 'y', 'p', 'e', 'd', 'P', 'e', 'r', 'F', 
-'i', 'l', 't', 'e', 'r', 'C', 'o', 'n', 'f', 'i', 'g', 'E', 'n', 't', 'r', 'y', 'R', '\024', 't', 'y', 'p', 'e', 'd', 'P', 'e', 
-'r', 'F', 'i', 'l', 't', 'e', 'r', 'C', 'o', 'n', 'f', 'i', 'g', '\022', 'g', '\n', '\026', 'r', 'e', 'q', 'u', 'e', 's', 't', '_', 
-'h', 'e', 'a', 'd', 'e', 'r', 's', '_', 't', 'o', '_', 'a', 'd', 'd', '\030', '\t', ' ', '\003', '(', '\013', '2', '\'', '.', 'e', 'n', 
-'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'H', 'e', 'a', 'd', 'e', 'r', 
-'V', 'a', 'l', 'u', 'e', 'O', 'p', 't', 'i', 'o', 'n', 'B', '\t', '\372', 'B', '\006', '\222', '\001', '\003', '\020', '\350', '\007', 'R', '\023', 'r', 
-'e', 'q', 'u', 'e', 's', 't', 'H', 'e', 'a', 'd', 'e', 'r', 's', 'T', 'o', 'A', 'd', 'd', '\022', 'M', '\n', '\031', 'r', 'e', 'q', 
-'u', 'e', 's', 't', '_', 'h', 'e', 'a', 'd', 'e', 'r', 's', '_', 't', 'o', '_', 'r', 'e', 'm', 'o', 'v', 'e', '\030', '\014', ' ', 
-'\003', '(', '\t', 'B', '\022', '\372', 'B', '\017', '\222', '\001', '\014', '\"', '\n', 'r', '\010', '\020', '\001', '\300', '\001', '\001', '\310', '\001', '\000', 'R', '\026', 
-'r', 'e', 'q', 'u', 'e', 's', 't', 'H', 'e', 'a', 'd', 'e', 'r', 's', 'T', 'o', 'R', 'e', 'm', 'o', 'v', 'e', '\022', 'i', '\n', 
-'\027', 'r', 'e', 's', 'p', 'o', 'n', 's', 'e', '_', 'h', 'e', 'a', 'd', 'e', 'r', 's', '_', 't', 'o', '_', 'a', 'd', 'd', '\030', 
-'\n', ' ', '\003', '(', '\013', '2', '\'', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', 
-'.', 'v', '3', '.', 'H', 'e', 'a', 'd', 'e', 'r', 'V', 'a', 'l', 'u', 'e', 'O', 'p', 't', 'i', 'o', 'n', 'B', '\t', '\372', 'B', 
-'\006', '\222', '\001', '\003', '\020', '\350', '\007', 'R', '\024', 'r', 'e', 's', 'p', 'o', 'n', 's', 'e', 'H', 'e', 'a', 'd', 'e', 'r', 's', 'T', 
-'o', 'A', 'd', 'd', '\022', 'O', '\n', '\032', 'r', 'e', 's', 'p', 'o', 'n', 's', 'e', '_', 'h', 'e', 'a', 'd', 'e', 'r', 's', '_', 
-'t', 'o', '_', 'r', 'e', 'm', 'o', 'v', 'e', '\030', '\013', ' ', '\003', '(', '\t', 'B', '\022', '\372', 'B', '\017', '\222', '\001', '\014', '\"', '\n', 
-'r', '\010', '\020', '\001', '\300', '\001', '\001', '\310', '\001', '\000', 'R', '\027', 'r', 'e', 's', 'p', 'o', 'n', 's', 'e', 'H', 'e', 'a', 'd', 'e', 
-'r', 's', 'T', 'o', 'R', 'e', 'm', 'o', 'v', 'e', '\022', '8', '\n', '\007', 't', 'r', 'a', 'c', 'i', 'n', 'g', '\030', '\017', ' ', '\001', 
-'(', '\013', '2', '\036', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', 
-'3', '.', 'T', 'r', 'a', 'c', 'i', 'n', 'g', 'R', '\007', 't', 'r', 'a', 'c', 'i', 'n', 'g', '\022', '`', '\n', '\036', 'p', 'e', 'r', 
-'_', 'r', 'e', 'q', 'u', 'e', 's', 't', '_', 'b', 'u', 'f', 'f', 'e', 'r', '_', 'l', 'i', 'm', 'i', 't', '_', 'b', 'y', 't', 
-'e', 's', '\030', '\020', ' ', '\001', '(', '\013', '2', '\034', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 
-'f', '.', 'U', 'I', 'n', 't', '3', '2', 'V', 'a', 'l', 'u', 'e', 'R', '\032', 'p', 'e', 'r', 'R', 'e', 'q', 'u', 'e', 's', 't', 
-'B', 'u', 'f', 'f', 'e', 'r', 'L', 'i', 'm', 'i', 't', 'B', 'y', 't', 'e', 's', '\032', ']', '\n', '\031', 'T', 'y', 'p', 'e', 'd', 
-'P', 'e', 'r', 'F', 'i', 'l', 't', 'e', 'r', 'C', 'o', 'n', 'f', 'i', 'g', 'E', 'n', 't', 'r', 'y', '\022', '\020', '\n', '\003', 'k', 
-'e', 'y', '\030', '\001', ' ', '\001', '(', '\t', 'R', '\003', 'k', 'e', 'y', '\022', '*', '\n', '\005', 'v', 'a', 'l', 'u', 'e', '\030', '\002', ' ', 
-'\001', '(', '\013', '2', '\024', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'A', 'n', 'y', 
-'R', '\005', 'v', 'a', 'l', 'u', 'e', ':', '\002', '8', '\001', ':', '\037', '\232', '\305', '\210', '\036', '\032', '\n', '\030', 'e', 'n', 'v', 'o', 'y', 
-'.', 'a', 'p', 'i', '.', 'v', '2', '.', 'r', 'o', 'u', 't', 'e', '.', 'R', 'o', 'u', 't', 'e', 'B', '\r', '\n', '\006', 'a', 'c', 
-'t', 'i', 'o', 'n', '\022', '\003', '\370', 'B', '\001', 'J', '\004', '\010', '\006', '\020', '\007', 'J', '\004', '\010', '\010', '\020', '\t', 'R', '\021', 'p', 'e', 
-'r', '_', 'f', 'i', 'l', 't', 'e', 'r', '_', 'c', 'o', 'n', 'f', 'i', 'g', '\"', '\306', '\t', '\n', '\017', 'W', 'e', 'i', 'g', 'h', 
-'t', 'e', 'd', 'C', 'l', 'u', 's', 't', 'e', 'r', '\022', 'Z', '\n', '\010', 'c', 'l', 'u', 's', 't', 'e', 'r', 's', '\030', '\001', ' ', 
-'\003', '(', '\013', '2', '4', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 
-'v', '3', '.', 'W', 'e', 'i', 'g', 'h', 't', 'e', 'd', 'C', 'l', 'u', 's', 't', 'e', 'r', '.', 'C', 'l', 'u', 's', 't', 'e', 
-'r', 'W', 'e', 'i', 'g', 'h', 't', 'B', '\010', '\372', 'B', '\005', '\222', '\001', '\002', '\010', '\001', 'R', '\010', 'c', 'l', 'u', 's', 't', 'e', 
-'r', 's', '\022', 'H', '\n', '\014', 't', 'o', 't', 'a', 'l', '_', 'w', 'e', 'i', 'g', 'h', 't', '\030', '\003', ' ', '\001', '(', '\013', '2', 
-'\034', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'U', 'I', 'n', 't', '3', '2', 'V', 
-'a', 'l', 'u', 'e', 'B', '\007', '\372', 'B', '\004', '*', '\002', '(', '\001', 'R', '\013', 't', 'o', 't', 'a', 'l', 'W', 'e', 'i', 'g', 'h', 
-'t', '\022', ',', '\n', '\022', 'r', 'u', 'n', 't', 'i', 'm', 'e', '_', 'k', 'e', 'y', '_', 'p', 'r', 'e', 'f', 'i', 'x', '\030', '\002', 
-' ', '\001', '(', '\t', 'R', '\020', 'r', 'u', 'n', 't', 'i', 'm', 'e', 'K', 'e', 'y', 'P', 'r', 'e', 'f', 'i', 'x', '\032', '\263', '\007', 
-'\n', '\r', 'C', 'l', 'u', 's', 't', 'e', 'r', 'W', 'e', 'i', 'g', 'h', 't', '\022', '\033', '\n', '\004', 'n', 'a', 'm', 'e', '\030', '\001', 
-' ', '\001', '(', '\t', 'B', '\007', '\372', 'B', '\004', 'r', '\002', '\020', '\001', 'R', '\004', 'n', 'a', 'm', 'e', '\022', '4', '\n', '\006', 'w', 'e', 
-'i', 'g', 'h', 't', '\030', '\002', ' ', '\001', '(', '\013', '2', '\034', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 
-'b', 'u', 'f', '.', 'U', 'I', 'n', 't', '3', '2', 'V', 'a', 'l', 'u', 'e', 'R', '\006', 'w', 'e', 'i', 'g', 'h', 't', '\022', 'E', 
-'\n', '\016', 'm', 'e', 't', 'a', 'd', 'a', 't', 'a', '_', 'm', 'a', 't', 'c', 'h', '\030', '\003', ' ', '\001', '(', '\013', '2', '\036', '.', 
-'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'M', 'e', 't', 'a', 
-'d', 'a', 't', 'a', 'R', '\r', 'm', 'e', 't', 'a', 'd', 'a', 't', 'a', 'M', 'a', 't', 'c', 'h', '\022', 'g', '\n', '\026', 'r', 'e', 
-'q', 'u', 'e', 's', 't', '_', 'h', 'e', 'a', 'd', 'e', 'r', 's', '_', 't', 'o', '_', 'a', 'd', 'd', '\030', '\004', ' ', '\003', '(', 
-'\013', '2', '\'', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 
-'H', 'e', 'a', 'd', 'e', 'r', 'V', 'a', 'l', 'u', 'e', 'O', 'p', 't', 'i', 'o', 'n', 'B', '\t', '\372', 'B', '\006', '\222', '\001', '\003', 
-'\020', '\350', '\007', 'R', '\023', 'r', 'e', 'q', 'u', 'e', 's', 't', 'H', 'e', 'a', 'd', 'e', 'r', 's', 'T', 'o', 'A', 'd', 'd', '\022', 
-'K', '\n', '\031', 'r', 'e', 'q', 'u', 'e', 's', 't', '_', 'h', 'e', 'a', 'd', 'e', 'r', 's', '_', 't', 'o', '_', 'r', 'e', 'm', 
-'o', 'v', 'e', '\030', '\t', ' ', '\003', '(', '\t', 'B', '\020', '\372', 'B', '\r', '\222', '\001', '\n', '\"', '\010', 'r', '\006', '\300', '\001', '\001', '\310', 
-'\001', '\000', 'R', '\026', 'r', 'e', 'q', 'u', 'e', 's', 't', 'H', 'e', 'a', 'd', 'e', 'r', 's', 'T', 'o', 'R', 'e', 'm', 'o', 'v', 
-'e', '\022', 'i', '\n', '\027', 'r', 'e', 's', 'p', 'o', 'n', 's', 'e', '_', 'h', 'e', 'a', 'd', 'e', 'r', 's', '_', 't', 'o', '_', 
-'a', 'd', 'd', '\030', '\005', ' ', '\003', '(', '\013', '2', '\'', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 
+'3', '.', 'R', 'e', 't', 'r', 'y', 'P', 'o', 'l', 'i', 'c', 'y', 'R', '\013', 'r', 'e', 't', 'r', 'y', 'P', 'o', 'l', 'i', 'c', 
+'y', '\022', 'O', '\n', '\031', 'r', 'e', 't', 'r', 'y', '_', 'p', 'o', 'l', 'i', 'c', 'y', '_', 't', 'y', 'p', 'e', 'd', '_', 'c', 
+'o', 'n', 'f', 'i', 'g', '\030', '\024', ' ', '\001', '(', '\013', '2', '\024', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 
+'o', 'b', 'u', 'f', '.', 'A', 'n', 'y', 'R', '\026', 'r', 'e', 't', 'r', 'y', 'P', 'o', 'l', 'i', 'c', 'y', 'T', 'y', 'p', 'e', 
+'d', 'C', 'o', 'n', 'f', 'i', 'g', '\022', 'E', '\n', '\014', 'h', 'e', 'd', 'g', 'e', '_', 'p', 'o', 'l', 'i', 'c', 'y', '\030', '\021', 
+' ', '\001', '(', '\013', '2', '\"', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', 
+'.', 'v', '3', '.', 'H', 'e', 'd', 'g', 'e', 'P', 'o', 'l', 'i', 'c', 'y', 'R', '\013', 'h', 'e', 'd', 'g', 'e', 'P', 'o', 'l', 
+'i', 'c', 'y', '\022', '`', '\n', '\036', 'p', 'e', 'r', '_', 'r', 'e', 'q', 'u', 'e', 's', 't', '_', 'b', 'u', 'f', 'f', 'e', 'r', 
+'_', 'l', 'i', 'm', 'i', 't', '_', 'b', 'y', 't', 'e', 's', '\030', '\022', ' ', '\001', '(', '\013', '2', '\034', '.', 'g', 'o', 'o', 'g', 
+'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'U', 'I', 'n', 't', '3', '2', 'V', 'a', 'l', 'u', 'e', 'R', '\032', 
+'p', 'e', 'r', 'R', 'e', 'q', 'u', 'e', 's', 't', 'B', 'u', 'f', 'f', 'e', 'r', 'L', 'i', 'm', 'i', 't', 'B', 'y', 't', 'e', 
+'s', '\032', ']', '\n', '\031', 'T', 'y', 'p', 'e', 'd', 'P', 'e', 'r', 'F', 'i', 'l', 't', 'e', 'r', 'C', 'o', 'n', 'f', 'i', 'g', 
+'E', 'n', 't', 'r', 'y', '\022', '\020', '\n', '\003', 'k', 'e', 'y', '\030', '\001', ' ', '\001', '(', '\t', 'R', '\003', 'k', 'e', 'y', '\022', '*', 
+'\n', '\005', 'v', 'a', 'l', 'u', 'e', '\030', '\002', ' ', '\001', '(', '\013', '2', '\024', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 
+'o', 't', 'o', 'b', 'u', 'f', '.', 'A', 'n', 'y', 'R', '\005', 'v', 'a', 'l', 'u', 'e', ':', '\002', '8', '\001', '\"', ':', '\n', '\022', 
+'T', 'l', 's', 'R', 'e', 'q', 'u', 'i', 'r', 'e', 'm', 'e', 'n', 't', 'T', 'y', 'p', 'e', '\022', '\010', '\n', '\004', 'N', 'O', 'N', 
+'E', '\020', '\000', '\022', '\021', '\n', '\r', 'E', 'X', 'T', 'E', 'R', 'N', 'A', 'L', '_', 'O', 'N', 'L', 'Y', '\020', '\001', '\022', '\007', '\n', 
+'\003', 'A', 'L', 'L', '\020', '\002', ':', '%', '\232', '\305', '\210', '\036', ' ', '\n', '\036', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 
+'v', '2', '.', 'r', 'o', 'u', 't', 'e', '.', 'V', 'i', 'r', 't', 'u', 'a', 'l', 'H', 'o', 's', 't', 'J', '\004', '\010', '\t', '\020', 
+'\n', 'J', '\004', '\010', '\014', '\020', '\r', 'R', '\021', 'p', 'e', 'r', '_', 'f', 'i', 'l', 't', 'e', 'r', '_', 'c', 'o', 'n', 'f', 'i', 
+'g', '\"', 'd', '\n', '\014', 'F', 'i', 'l', 't', 'e', 'r', 'A', 'c', 't', 'i', 'o', 'n', '\022', ',', '\n', '\006', 'a', 'c', 't', 'i', 
+'o', 'n', '\030', '\001', ' ', '\001', '(', '\013', '2', '\024', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 
+'f', '.', 'A', 'n', 'y', 'R', '\006', 'a', 'c', 't', 'i', 'o', 'n', ':', '&', '\232', '\305', '\210', '\036', '!', '\n', '\037', 'e', 'n', 'v', 
+'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'r', 'o', 'u', 't', 'e', '.', 'F', 'i', 'l', 't', 'e', 'r', 'A', 'c', 't', 
+'i', 'o', 'n', '\"', '\216', '\013', '\n', '\005', 'R', 'o', 'u', 't', 'e', '\022', '\022', '\n', '\004', 'n', 'a', 'm', 'e', '\030', '\016', ' ', '\001', 
+'(', '\t', 'R', '\004', 'n', 'a', 'm', 'e', '\022', 'A', '\n', '\005', 'm', 'a', 't', 'c', 'h', '\030', '\001', ' ', '\001', '(', '\013', '2', '!', 
+'.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'R', 'o', 
+'u', 't', 'e', 'M', 'a', 't', 'c', 'h', 'B', '\010', '\372', 'B', '\005', '\212', '\001', '\002', '\020', '\001', 'R', '\005', 'm', 'a', 't', 'c', 'h', 
+'\022', ':', '\n', '\005', 'r', 'o', 'u', 't', 'e', '\030', '\002', ' ', '\001', '(', '\013', '2', '\"', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 
+'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'R', 'o', 'u', 't', 'e', 'A', 'c', 't', 'i', 'o', 
+'n', 'H', '\000', 'R', '\005', 'r', 'o', 'u', 't', 'e', '\022', 'C', '\n', '\010', 'r', 'e', 'd', 'i', 'r', 'e', 'c', 't', '\030', '\003', ' ', 
+'\001', '(', '\013', '2', '%', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 
+'v', '3', '.', 'R', 'e', 'd', 'i', 'r', 'e', 'c', 't', 'A', 'c', 't', 'i', 'o', 'n', 'H', '\000', 'R', '\010', 'r', 'e', 'd', 'i', 
+'r', 'e', 'c', 't', '\022', 'V', '\n', '\017', 'd', 'i', 'r', 'e', 'c', 't', '_', 'r', 'e', 's', 'p', 'o', 'n', 's', 'e', '\030', '\007', 
+' ', '\001', '(', '\013', '2', '+', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', 
+'.', 'v', '3', '.', 'D', 'i', 'r', 'e', 'c', 't', 'R', 'e', 's', 'p', 'o', 'n', 's', 'e', 'A', 'c', 't', 'i', 'o', 'n', 'H', 
+'\000', 'R', '\016', 'd', 'i', 'r', 'e', 'c', 't', 'R', 'e', 's', 'p', 'o', 'n', 's', 'e', '\022', 'J', '\n', '\r', 'f', 'i', 'l', 't', 
+'e', 'r', '_', 'a', 'c', 't', 'i', 'o', 'n', '\030', '\021', ' ', '\001', '(', '\013', '2', '#', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 
+'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'F', 'i', 'l', 't', 'e', 'r', 'A', 'c', 't', 'i', 
+'o', 'n', 'H', '\000', 'R', '\014', 'f', 'i', 'l', 't', 'e', 'r', 'A', 'c', 't', 'i', 'o', 'n', '\022', '`', '\n', '\025', 'n', 'o', 'n', 
+'_', 'f', 'o', 'r', 'w', 'a', 'r', 'd', 'i', 'n', 'g', '_', 'a', 'c', 't', 'i', 'o', 'n', '\030', '\022', ' ', '\001', '(', '\013', '2', 
+'*', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'N', 
+'o', 'n', 'F', 'o', 'r', 'w', 'a', 'r', 'd', 'i', 'n', 'g', 'A', 'c', 't', 'i', 'o', 'n', 'H', '\000', 'R', '\023', 'n', 'o', 'n', 
+'F', 'o', 'r', 'w', 'a', 'r', 'd', 'i', 'n', 'g', 'A', 'c', 't', 'i', 'o', 'n', '\022', ':', '\n', '\010', 'm', 'e', 't', 'a', 'd', 
+'a', 't', 'a', '\030', '\004', ' ', '\001', '(', '\013', '2', '\036', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 
+'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'M', 'e', 't', 'a', 'd', 'a', 't', 'a', 'R', '\010', 'm', 'e', 't', 'a', 'd', 'a', 't', 
+'a', '\022', '>', '\n', '\t', 'd', 'e', 'c', 'o', 'r', 'a', 't', 'o', 'r', '\030', '\005', ' ', '\001', '(', '\013', '2', ' ', '.', 'e', 'n', 
+'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'D', 'e', 'c', 'o', 'r', 
+'a', 't', 'o', 'r', 'R', '\t', 'd', 'e', 'c', 'o', 'r', 'a', 't', 'o', 'r', '\022', 'm', '\n', '\027', 't', 'y', 'p', 'e', 'd', '_', 
+'p', 'e', 'r', '_', 'f', 'i', 'l', 't', 'e', 'r', '_', 'c', 'o', 'n', 'f', 'i', 'g', '\030', '\r', ' ', '\003', '(', '\013', '2', '6', 
+'.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'R', 'o', 
+'u', 't', 'e', '.', 'T', 'y', 'p', 'e', 'd', 'P', 'e', 'r', 'F', 'i', 'l', 't', 'e', 'r', 'C', 'o', 'n', 'f', 'i', 'g', 'E', 
+'n', 't', 'r', 'y', 'R', '\024', 't', 'y', 'p', 'e', 'd', 'P', 'e', 'r', 'F', 'i', 'l', 't', 'e', 'r', 'C', 'o', 'n', 'f', 'i', 
+'g', '\022', 'g', '\n', '\026', 'r', 'e', 'q', 'u', 'e', 's', 't', '_', 'h', 'e', 'a', 'd', 'e', 'r', 's', '_', 't', 'o', '_', 'a', 
+'d', 'd', '\030', '\t', ' ', '\003', '(', '\013', '2', '\'', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 
+'o', 'r', 'e', '.', 'v', '3', '.', 'H', 'e', 'a', 'd', 'e', 'r', 'V', 'a', 'l', 'u', 'e', 'O', 'p', 't', 'i', 'o', 'n', 'B', 
+'\t', '\372', 'B', '\006', '\222', '\001', '\003', '\020', '\350', '\007', 'R', '\023', 'r', 'e', 'q', 'u', 'e', 's', 't', 'H', 'e', 'a', 'd', 'e', 'r', 
+'s', 'T', 'o', 'A', 'd', 'd', '\022', 'M', '\n', '\031', 'r', 'e', 'q', 'u', 'e', 's', 't', '_', 'h', 'e', 'a', 'd', 'e', 'r', 's', 
+'_', 't', 'o', '_', 'r', 'e', 'm', 'o', 'v', 'e', '\030', '\014', ' ', '\003', '(', '\t', 'B', '\022', '\372', 'B', '\017', '\222', '\001', '\014', '\"', 
+'\n', 'r', '\010', '\020', '\001', '\300', '\001', '\001', '\310', '\001', '\000', 'R', '\026', 'r', 'e', 'q', 'u', 'e', 's', 't', 'H', 'e', 'a', 'd', 'e', 
+'r', 's', 'T', 'o', 'R', 'e', 'm', 'o', 'v', 'e', '\022', 'i', '\n', '\027', 'r', 'e', 's', 'p', 'o', 'n', 's', 'e', '_', 'h', 'e', 
+'a', 'd', 'e', 'r', 's', '_', 't', 'o', '_', 'a', 'd', 'd', '\030', '\n', ' ', '\003', '(', '\013', '2', '\'', '.', 'e', 'n', 'v', 'o', 
+'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'H', 'e', 'a', 'd', 'e', 'r', 'V', 'a', 
+'l', 'u', 'e', 'O', 'p', 't', 'i', 'o', 'n', 'B', '\t', '\372', 'B', '\006', '\222', '\001', '\003', '\020', '\350', '\007', 'R', '\024', 'r', 'e', 's', 
+'p', 'o', 'n', 's', 'e', 'H', 'e', 'a', 'd', 'e', 'r', 's', 'T', 'o', 'A', 'd', 'd', '\022', 'O', '\n', '\032', 'r', 'e', 's', 'p', 
+'o', 'n', 's', 'e', '_', 'h', 'e', 'a', 'd', 'e', 'r', 's', '_', 't', 'o', '_', 'r', 'e', 'm', 'o', 'v', 'e', '\030', '\013', ' ', 
+'\003', '(', '\t', 'B', '\022', '\372', 'B', '\017', '\222', '\001', '\014', '\"', '\n', 'r', '\010', '\020', '\001', '\300', '\001', '\001', '\310', '\001', '\000', 'R', '\027', 
+'r', 'e', 's', 'p', 'o', 'n', 's', 'e', 'H', 'e', 'a', 'd', 'e', 'r', 's', 'T', 'o', 'R', 'e', 'm', 'o', 'v', 'e', '\022', '8', 
+'\n', '\007', 't', 'r', 'a', 'c', 'i', 'n', 'g', '\030', '\017', ' ', '\001', '(', '\013', '2', '\036', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 
+'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'T', 'r', 'a', 'c', 'i', 'n', 'g', 'R', '\007', 't', 
+'r', 'a', 'c', 'i', 'n', 'g', '\022', '`', '\n', '\036', 'p', 'e', 'r', '_', 'r', 'e', 'q', 'u', 'e', 's', 't', '_', 'b', 'u', 'f', 
+'f', 'e', 'r', '_', 'l', 'i', 'm', 'i', 't', '_', 'b', 'y', 't', 'e', 's', '\030', '\020', ' ', '\001', '(', '\013', '2', '\034', '.', 'g', 
+'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'U', 'I', 'n', 't', '3', '2', 'V', 'a', 'l', 'u', 
+'e', 'R', '\032', 'p', 'e', 'r', 'R', 'e', 'q', 'u', 'e', 's', 't', 'B', 'u', 'f', 'f', 'e', 'r', 'L', 'i', 'm', 'i', 't', 'B', 
+'y', 't', 'e', 's', '\032', ']', '\n', '\031', 'T', 'y', 'p', 'e', 'd', 'P', 'e', 'r', 'F', 'i', 'l', 't', 'e', 'r', 'C', 'o', 'n', 
+'f', 'i', 'g', 'E', 'n', 't', 'r', 'y', '\022', '\020', '\n', '\003', 'k', 'e', 'y', '\030', '\001', ' ', '\001', '(', '\t', 'R', '\003', 'k', 'e', 
+'y', '\022', '*', '\n', '\005', 'v', 'a', 'l', 'u', 'e', '\030', '\002', ' ', '\001', '(', '\013', '2', '\024', '.', 'g', 'o', 'o', 'g', 'l', 'e', 
+'.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'A', 'n', 'y', 'R', '\005', 'v', 'a', 'l', 'u', 'e', ':', '\002', '8', '\001', ':', 
+'\037', '\232', '\305', '\210', '\036', '\032', '\n', '\030', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'r', 'o', 'u', 't', 
+'e', '.', 'R', 'o', 'u', 't', 'e', 'B', '\r', '\n', '\006', 'a', 'c', 't', 'i', 'o', 'n', '\022', '\003', '\370', 'B', '\001', 'J', '\004', '\010', 
+'\006', '\020', '\007', 'J', '\004', '\010', '\010', '\020', '\t', 'R', '\021', 'p', 'e', 'r', '_', 'f', 'i', 'l', 't', 'e', 'r', '_', 'c', 'o', 'n', 
+'f', 'i', 'g', '\"', '\245', '\n', '\n', '\017', 'W', 'e', 'i', 'g', 'h', 't', 'e', 'd', 'C', 'l', 'u', 's', 't', 'e', 'r', '\022', 'Z', 
+'\n', '\010', 'c', 'l', 'u', 's', 't', 'e', 'r', 's', '\030', '\001', ' ', '\003', '(', '\013', '2', '4', '.', 'e', 'n', 'v', 'o', 'y', '.', 
+'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'W', 'e', 'i', 'g', 'h', 't', 'e', 'd', 'C', 
+'l', 'u', 's', 't', 'e', 'r', '.', 'C', 'l', 'u', 's', 't', 'e', 'r', 'W', 'e', 'i', 'g', 'h', 't', 'B', '\010', '\372', 'B', '\005', 
+'\222', '\001', '\002', '\010', '\001', 'R', '\010', 'c', 'l', 'u', 's', 't', 'e', 'r', 's', '\022', 'H', '\n', '\014', 't', 'o', 't', 'a', 'l', '_', 
+'w', 'e', 'i', 'g', 'h', 't', '\030', '\003', ' ', '\001', '(', '\013', '2', '\034', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 
+'t', 'o', 'b', 'u', 'f', '.', 'U', 'I', 'n', 't', '3', '2', 'V', 'a', 'l', 'u', 'e', 'B', '\007', '\372', 'B', '\004', '*', '\002', '(', 
+'\001', 'R', '\013', 't', 'o', 't', 'a', 'l', 'W', 'e', 'i', 'g', 'h', 't', '\022', ',', '\n', '\022', 'r', 'u', 'n', 't', 'i', 'm', 'e', 
+'_', 'k', 'e', 'y', '_', 'p', 'r', 'e', 'f', 'i', 'x', '\030', '\002', ' ', '\001', '(', '\t', 'R', '\020', 'r', 'u', 'n', 't', 'i', 'm', 
+'e', 'K', 'e', 'y', 'P', 'r', 'e', 'f', 'i', 'x', '\032', '\222', '\010', '\n', '\r', 'C', 'l', 'u', 's', 't', 'e', 'r', 'W', 'e', 'i', 
+'g', 'h', 't', '\022', '-', '\n', '\004', 'n', 'a', 'm', 'e', '\030', '\001', ' ', '\001', '(', '\t', 'B', '\031', '\362', '\230', '\376', '\217', '\005', '\023', 
+'\022', '\021', 'c', 'l', 'u', 's', 't', 'e', 'r', '_', 's', 'p', 'e', 'c', 'i', 'f', 'i', 'e', 'r', 'R', '\004', 'n', 'a', 'm', 'e', 
+'\022', 'K', '\n', '\016', 'c', 'l', 'u', 's', 't', 'e', 'r', '_', 'h', 'e', 'a', 'd', 'e', 'r', '\030', '\014', ' ', '\001', '(', '\t', 'B', 
+'$', '\372', 'B', '\010', 'r', '\006', '\300', '\001', '\001', '\310', '\001', '\000', '\362', '\230', '\376', '\217', '\005', '\023', '\022', '\021', 'c', 'l', 'u', 's', 't', 
+'e', 'r', '_', 's', 'p', 'e', 'c', 'i', 'f', 'i', 'e', 'r', 'R', '\r', 'c', 'l', 'u', 's', 't', 'e', 'r', 'H', 'e', 'a', 'd', 
+'e', 'r', '\022', '4', '\n', '\006', 'w', 'e', 'i', 'g', 'h', 't', '\030', '\002', ' ', '\001', '(', '\013', '2', '\034', '.', 'g', 'o', 'o', 'g', 
+'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'U', 'I', 'n', 't', '3', '2', 'V', 'a', 'l', 'u', 'e', 'R', '\006', 
+'w', 'e', 'i', 'g', 'h', 't', '\022', 'E', '\n', '\016', 'm', 'e', 't', 'a', 'd', 'a', 't', 'a', '_', 'm', 'a', 't', 'c', 'h', '\030', 
+'\003', ' ', '\001', '(', '\013', '2', '\036', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', 
+'.', 'v', '3', '.', 'M', 'e', 't', 'a', 'd', 'a', 't', 'a', 'R', '\r', 'm', 'e', 't', 'a', 'd', 'a', 't', 'a', 'M', 'a', 't', 
+'c', 'h', '\022', 'g', '\n', '\026', 'r', 'e', 'q', 'u', 'e', 's', 't', '_', 'h', 'e', 'a', 'd', 'e', 'r', 's', '_', 't', 'o', '_', 
+'a', 'd', 'd', '\030', '\004', ' ', '\003', '(', '\013', '2', '\'', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 
 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'H', 'e', 'a', 'd', 'e', 'r', 'V', 'a', 'l', 'u', 'e', 'O', 'p', 't', 'i', 'o', 'n', 
-'B', '\t', '\372', 'B', '\006', '\222', '\001', '\003', '\020', '\350', '\007', 'R', '\024', 'r', 'e', 's', 'p', 'o', 'n', 's', 'e', 'H', 'e', 'a', 'd', 
-'e', 'r', 's', 'T', 'o', 'A', 'd', 'd', '\022', 'M', '\n', '\032', 'r', 'e', 's', 'p', 'o', 'n', 's', 'e', '_', 'h', 'e', 'a', 'd', 
-'e', 'r', 's', '_', 't', 'o', '_', 'r', 'e', 'm', 'o', 'v', 'e', '\030', '\006', ' ', '\003', '(', '\t', 'B', '\020', '\372', 'B', '\r', '\222', 
-'\001', '\n', '\"', '\010', 'r', '\006', '\300', '\001', '\001', '\310', '\001', '\000', 'R', '\027', 'r', 'e', 's', 'p', 'o', 'n', 's', 'e', 'H', 'e', 'a', 
-'d', 'e', 'r', 's', 'T', 'o', 'R', 'e', 'm', 'o', 'v', 'e', '\022', '\205', '\001', '\n', '\027', 't', 'y', 'p', 'e', 'd', '_', 'p', 'e', 
-'r', '_', 'f', 'i', 'l', 't', 'e', 'r', '_', 'c', 'o', 'n', 'f', 'i', 'g', '\030', '\n', ' ', '\003', '(', '\013', '2', 'N', '.', 'e', 
-'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'W', 'e', 'i', 'g', 
-'h', 't', 'e', 'd', 'C', 'l', 'u', 's', 't', 'e', 'r', '.', 'C', 'l', 'u', 's', 't', 'e', 'r', 'W', 'e', 'i', 'g', 'h', 't', 
-'.', 'T', 'y', 'p', 'e', 'd', 'P', 'e', 'r', 'F', 'i', 'l', 't', 'e', 'r', 'C', 'o', 'n', 'f', 'i', 'g', 'E', 'n', 't', 'r', 
-'y', 'R', '\024', 't', 'y', 'p', 'e', 'd', 'P', 'e', 'r', 'F', 'i', 'l', 't', 'e', 'r', 'C', 'o', 'n', 'f', 'i', 'g', '\022', '?', 
-'\n', '\024', 'h', 'o', 's', 't', '_', 'r', 'e', 'w', 'r', 'i', 't', 'e', '_', 'l', 'i', 't', 'e', 'r', 'a', 'l', '\030', '\013', ' ', 
-'\001', '(', '\t', 'B', '\013', '\372', 'B', '\010', 'r', '\006', '\300', '\001', '\002', '\310', '\001', '\000', 'H', '\000', 'R', '\022', 'h', 'o', 's', 't', 'R', 
-'e', 'w', 'r', 'i', 't', 'e', 'L', 'i', 't', 'e', 'r', 'a', 'l', '\032', ']', '\n', '\031', 'T', 'y', 'p', 'e', 'd', 'P', 'e', 'r', 
-'F', 'i', 'l', 't', 'e', 'r', 'C', 'o', 'n', 'f', 'i', 'g', 'E', 'n', 't', 'r', 'y', '\022', '\020', '\n', '\003', 'k', 'e', 'y', '\030', 
-'\001', ' ', '\001', '(', '\t', 'R', '\003', 'k', 'e', 'y', '\022', '*', '\n', '\005', 'v', 'a', 'l', 'u', 'e', '\030', '\002', ' ', '\001', '(', '\013', 
-'2', '\024', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'A', 'n', 'y', 'R', '\005', 'v', 
-'a', 'l', 'u', 'e', ':', '\002', '8', '\001', ':', '7', '\232', '\305', '\210', '\036', '2', '\n', '0', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 
-'i', '.', 'v', '2', '.', 'r', 'o', 'u', 't', 'e', '.', 'W', 'e', 'i', 'g', 'h', 't', 'e', 'd', 'C', 'l', 'u', 's', 't', 'e', 
-'r', '.', 'C', 'l', 'u', 's', 't', 'e', 'r', 'W', 'e', 'i', 'g', 'h', 't', 'B', '\030', '\n', '\026', 'h', 'o', 's', 't', '_', 'r', 
-'e', 'w', 'r', 'i', 't', 'e', '_', 's', 'p', 'e', 'c', 'i', 'f', 'i', 'e', 'r', 'J', '\004', '\010', '\007', '\020', '\010', 'J', '\004', '\010', 
-'\010', '\020', '\t', 'R', '\021', 'p', 'e', 'r', '_', 'f', 'i', 'l', 't', 'e', 'r', '_', 'c', 'o', 'n', 'f', 'i', 'g', ':', ')', '\232', 
-'\305', '\210', '\036', '$', '\n', '\"', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'r', 'o', 'u', 't', 'e', '.', 
-'W', 'e', 'i', 'g', 'h', 't', 'e', 'd', 'C', 'l', 'u', 's', 't', 'e', 'r', '\"', '\313', '\010', '\n', '\n', 'R', 'o', 'u', 't', 'e', 
-'M', 'a', 't', 'c', 'h', '\022', '\030', '\n', '\006', 'p', 'r', 'e', 'f', 'i', 'x', '\030', '\001', ' ', '\001', '(', '\t', 'H', '\000', 'R', '\006', 
-'p', 'r', 'e', 'f', 'i', 'x', '\022', '\024', '\n', '\004', 'p', 'a', 't', 'h', '\030', '\002', ' ', '\001', '(', '\t', 'H', '\000', 'R', '\004', 'p', 
-'a', 't', 'h', '\022', 'N', '\n', '\n', 's', 'a', 'f', 'e', '_', 'r', 'e', 'g', 'e', 'x', '\030', '\n', ' ', '\001', '(', '\013', '2', '#', 
-'.', 'e', 'n', 'v', 'o', 'y', '.', 't', 'y', 'p', 'e', '.', 'm', 'a', 't', 'c', 'h', 'e', 'r', '.', 'v', '3', '.', 'R', 'e', 
-'g', 'e', 'x', 'M', 'a', 't', 'c', 'h', 'e', 'r', 'B', '\010', '\372', 'B', '\005', '\212', '\001', '\002', '\020', '\001', 'H', '\000', 'R', '\t', 's', 
-'a', 'f', 'e', 'R', 'e', 'g', 'e', 'x', '\022', '[', '\n', '\017', 'c', 'o', 'n', 'n', 'e', 'c', 't', '_', 'm', 'a', 't', 'c', 'h', 
-'e', 'r', '\030', '\014', ' ', '\001', '(', '\013', '2', '0', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 
-'o', 'u', 't', 'e', '.', 'v', '3', '.', 'R', 'o', 'u', 't', 'e', 'M', 'a', 't', 'c', 'h', '.', 'C', 'o', 'n', 'n', 'e', 'c', 
-'t', 'M', 'a', 't', 'c', 'h', 'e', 'r', 'H', '\000', 'R', '\016', 'c', 'o', 'n', 'n', 'e', 'c', 't', 'M', 'a', 't', 'c', 'h', 'e', 
-'r', '\022', 'A', '\n', '\016', 'c', 'a', 's', 'e', '_', 's', 'e', 'n', 's', 'i', 't', 'i', 'v', 'e', '\030', '\004', ' ', '\001', '(', '\013', 
-'2', '\032', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'B', 'o', 'o', 'l', 'V', 'a', 
-'l', 'u', 'e', 'R', '\r', 'c', 'a', 's', 'e', 'S', 'e', 'n', 's', 'i', 't', 'i', 'v', 'e', '\022', 'Y', '\n', '\020', 'r', 'u', 'n', 
-'t', 'i', 'm', 'e', '_', 'f', 'r', 'a', 'c', 't', 'i', 'o', 'n', '\030', '\t', ' ', '\001', '(', '\013', '2', '.', '.', 'e', 'n', 'v', 
+'B', '\t', '\372', 'B', '\006', '\222', '\001', '\003', '\020', '\350', '\007', 'R', '\023', 'r', 'e', 'q', 'u', 'e', 's', 't', 'H', 'e', 'a', 'd', 'e', 
+'r', 's', 'T', 'o', 'A', 'd', 'd', '\022', 'K', '\n', '\031', 'r', 'e', 'q', 'u', 'e', 's', 't', '_', 'h', 'e', 'a', 'd', 'e', 'r', 
+'s', '_', 't', 'o', '_', 'r', 'e', 'm', 'o', 'v', 'e', '\030', '\t', ' ', '\003', '(', '\t', 'B', '\020', '\372', 'B', '\r', '\222', '\001', '\n', 
+'\"', '\010', 'r', '\006', '\300', '\001', '\001', '\310', '\001', '\000', 'R', '\026', 'r', 'e', 'q', 'u', 'e', 's', 't', 'H', 'e', 'a', 'd', 'e', 'r', 
+'s', 'T', 'o', 'R', 'e', 'm', 'o', 'v', 'e', '\022', 'i', '\n', '\027', 'r', 'e', 's', 'p', 'o', 'n', 's', 'e', '_', 'h', 'e', 'a', 
+'d', 'e', 'r', 's', '_', 't', 'o', '_', 'a', 'd', 'd', '\030', '\005', ' ', '\003', '(', '\013', '2', '\'', '.', 'e', 'n', 'v', 'o', 'y', 
+'.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'H', 'e', 'a', 'd', 'e', 'r', 'V', 'a', 'l', 
+'u', 'e', 'O', 'p', 't', 'i', 'o', 'n', 'B', '\t', '\372', 'B', '\006', '\222', '\001', '\003', '\020', '\350', '\007', 'R', '\024', 'r', 'e', 's', 'p', 
+'o', 'n', 's', 'e', 'H', 'e', 'a', 'd', 'e', 'r', 's', 'T', 'o', 'A', 'd', 'd', '\022', 'M', '\n', '\032', 'r', 'e', 's', 'p', 'o', 
+'n', 's', 'e', '_', 'h', 'e', 'a', 'd', 'e', 'r', 's', '_', 't', 'o', '_', 'r', 'e', 'm', 'o', 'v', 'e', '\030', '\006', ' ', '\003', 
+'(', '\t', 'B', '\020', '\372', 'B', '\r', '\222', '\001', '\n', '\"', '\010', 'r', '\006', '\300', '\001', '\001', '\310', '\001', '\000', 'R', '\027', 'r', 'e', 's', 
+'p', 'o', 'n', 's', 'e', 'H', 'e', 'a', 'd', 'e', 'r', 's', 'T', 'o', 'R', 'e', 'm', 'o', 'v', 'e', '\022', '\205', '\001', '\n', '\027', 
+'t', 'y', 'p', 'e', 'd', '_', 'p', 'e', 'r', '_', 'f', 'i', 'l', 't', 'e', 'r', '_', 'c', 'o', 'n', 'f', 'i', 'g', '\030', '\n', 
+' ', '\003', '(', '\013', '2', 'N', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', 
+'.', 'v', '3', '.', 'W', 'e', 'i', 'g', 'h', 't', 'e', 'd', 'C', 'l', 'u', 's', 't', 'e', 'r', '.', 'C', 'l', 'u', 's', 't', 
+'e', 'r', 'W', 'e', 'i', 'g', 'h', 't', '.', 'T', 'y', 'p', 'e', 'd', 'P', 'e', 'r', 'F', 'i', 'l', 't', 'e', 'r', 'C', 'o', 
+'n', 'f', 'i', 'g', 'E', 'n', 't', 'r', 'y', 'R', '\024', 't', 'y', 'p', 'e', 'd', 'P', 'e', 'r', 'F', 'i', 'l', 't', 'e', 'r', 
+'C', 'o', 'n', 'f', 'i', 'g', '\022', '?', '\n', '\024', 'h', 'o', 's', 't', '_', 'r', 'e', 'w', 'r', 'i', 't', 'e', '_', 'l', 'i', 
+'t', 'e', 'r', 'a', 'l', '\030', '\013', ' ', '\001', '(', '\t', 'B', '\013', '\372', 'B', '\010', 'r', '\006', '\300', '\001', '\002', '\310', '\001', '\000', 'H', 
+'\000', 'R', '\022', 'h', 'o', 's', 't', 'R', 'e', 'w', 'r', 'i', 't', 'e', 'L', 'i', 't', 'e', 'r', 'a', 'l', '\032', ']', '\n', '\031', 
+'T', 'y', 'p', 'e', 'd', 'P', 'e', 'r', 'F', 'i', 'l', 't', 'e', 'r', 'C', 'o', 'n', 'f', 'i', 'g', 'E', 'n', 't', 'r', 'y', 
+'\022', '\020', '\n', '\003', 'k', 'e', 'y', '\030', '\001', ' ', '\001', '(', '\t', 'R', '\003', 'k', 'e', 'y', '\022', '*', '\n', '\005', 'v', 'a', 'l', 
+'u', 'e', '\030', '\002', ' ', '\001', '(', '\013', '2', '\024', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 
+'f', '.', 'A', 'n', 'y', 'R', '\005', 'v', 'a', 'l', 'u', 'e', ':', '\002', '8', '\001', ':', '7', '\232', '\305', '\210', '\036', '2', '\n', '0', 
+'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'r', 'o', 'u', 't', 'e', '.', 'W', 'e', 'i', 'g', 'h', 't', 
+'e', 'd', 'C', 'l', 'u', 's', 't', 'e', 'r', '.', 'C', 'l', 'u', 's', 't', 'e', 'r', 'W', 'e', 'i', 'g', 'h', 't', 'B', '\030', 
+'\n', '\026', 'h', 'o', 's', 't', '_', 'r', 'e', 'w', 'r', 'i', 't', 'e', '_', 's', 'p', 'e', 'c', 'i', 'f', 'i', 'e', 'r', 'J', 
+'\004', '\010', '\007', '\020', '\010', 'J', '\004', '\010', '\010', '\020', '\t', 'R', '\021', 'p', 'e', 'r', '_', 'f', 'i', 'l', 't', 'e', 'r', '_', 'c', 
+'o', 'n', 'f', 'i', 'g', ':', ')', '\232', '\305', '\210', '\036', '$', '\n', '\"', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', 
+'2', '.', 'r', 'o', 'u', 't', 'e', '.', 'W', 'e', 'i', 'g', 'h', 't', 'e', 'd', 'C', 'l', 'u', 's', 't', 'e', 'r', '\"', '\236', 
+'\t', '\n', '\n', 'R', 'o', 'u', 't', 'e', 'M', 'a', 't', 'c', 'h', '\022', '\030', '\n', '\006', 'p', 'r', 'e', 'f', 'i', 'x', '\030', '\001', 
+' ', '\001', '(', '\t', 'H', '\000', 'R', '\006', 'p', 'r', 'e', 'f', 'i', 'x', '\022', '\024', '\n', '\004', 'p', 'a', 't', 'h', '\030', '\002', ' ', 
+'\001', '(', '\t', 'H', '\000', 'R', '\004', 'p', 'a', 't', 'h', '\022', 'N', '\n', '\n', 's', 'a', 'f', 'e', '_', 'r', 'e', 'g', 'e', 'x', 
+'\030', '\n', ' ', '\001', '(', '\013', '2', '#', '.', 'e', 'n', 'v', 'o', 'y', '.', 't', 'y', 'p', 'e', '.', 'm', 'a', 't', 'c', 'h', 
+'e', 'r', '.', 'v', '3', '.', 'R', 'e', 'g', 'e', 'x', 'M', 'a', 't', 'c', 'h', 'e', 'r', 'B', '\010', '\372', 'B', '\005', '\212', '\001', 
+'\002', '\020', '\001', 'H', '\000', 'R', '\t', 's', 'a', 'f', 'e', 'R', 'e', 'g', 'e', 'x', '\022', '[', '\n', '\017', 'c', 'o', 'n', 'n', 'e', 
+'c', 't', '_', 'm', 'a', 't', 'c', 'h', 'e', 'r', '\030', '\014', ' ', '\001', '(', '\013', '2', '0', '.', 'e', 'n', 'v', 'o', 'y', '.', 
+'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'R', 'o', 'u', 't', 'e', 'M', 'a', 't', 'c', 
+'h', '.', 'C', 'o', 'n', 'n', 'e', 'c', 't', 'M', 'a', 't', 'c', 'h', 'e', 'r', 'H', '\000', 'R', '\016', 'c', 'o', 'n', 'n', 'e', 
+'c', 't', 'M', 'a', 't', 'c', 'h', 'e', 'r', '\022', 'A', '\n', '\016', 'c', 'a', 's', 'e', '_', 's', 'e', 'n', 's', 'i', 't', 'i', 
+'v', 'e', '\030', '\004', ' ', '\001', '(', '\013', '2', '\032', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 
+'f', '.', 'B', 'o', 'o', 'l', 'V', 'a', 'l', 'u', 'e', 'R', '\r', 'c', 'a', 's', 'e', 'S', 'e', 'n', 's', 'i', 't', 'i', 'v', 
+'e', '\022', 'Y', '\n', '\020', 'r', 'u', 'n', 't', 'i', 'm', 'e', '_', 'f', 'r', 'a', 'c', 't', 'i', 'o', 'n', '\030', '\t', ' ', '\001', 
+'(', '\013', '2', '.', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', 
+'.', 'R', 'u', 'n', 't', 'i', 'm', 'e', 'F', 'r', 'a', 'c', 't', 'i', 'o', 'n', 'a', 'l', 'P', 'e', 'r', 'c', 'e', 'n', 't', 
+'R', '\017', 'r', 'u', 'n', 't', 'i', 'm', 'e', 'F', 'r', 'a', 'c', 't', 'i', 'o', 'n', '\022', '>', '\n', '\007', 'h', 'e', 'a', 'd', 
+'e', 'r', 's', '\030', '\006', ' ', '\003', '(', '\013', '2', '$', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 
+'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'H', 'e', 'a', 'd', 'e', 'r', 'M', 'a', 't', 'c', 'h', 'e', 'r', 'R', '\007', 'h', 
+'e', 'a', 'd', 'e', 'r', 's', '\022', 'W', '\n', '\020', 'q', 'u', 'e', 'r', 'y', '_', 'p', 'a', 'r', 'a', 'm', 'e', 't', 'e', 'r', 
+'s', '\030', '\007', ' ', '\003', '(', '\013', '2', ',', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 
+'u', 't', 'e', '.', 'v', '3', '.', 'Q', 'u', 'e', 'r', 'y', 'P', 'a', 'r', 'a', 'm', 'e', 't', 'e', 'r', 'M', 'a', 't', 'c', 
+'h', 'e', 'r', 'R', '\017', 'q', 'u', 'e', 'r', 'y', 'P', 'a', 'r', 'a', 'm', 'e', 't', 'e', 'r', 's', '\022', 'K', '\n', '\004', 'g', 
+'r', 'p', 'c', '\030', '\010', ' ', '\001', '(', '\013', '2', '7', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 
+'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'R', 'o', 'u', 't', 'e', 'M', 'a', 't', 'c', 'h', '.', 'G', 'r', 'p', 'c', 'R', 
+'o', 'u', 't', 'e', 'M', 'a', 't', 'c', 'h', 'O', 'p', 't', 'i', 'o', 'n', 's', 'R', '\004', 'g', 'r', 'p', 'c', '\022', 'Y', '\n', 
+'\013', 't', 'l', 's', '_', 'c', 'o', 'n', 't', 'e', 'x', 't', '\030', '\013', ' ', '\001', '(', '\013', '2', '8', '.', 'e', 'n', 'v', 'o', 
+'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'R', 'o', 'u', 't', 'e', 'M', 'a', 
+'t', 'c', 'h', '.', 'T', 'l', 's', 'C', 'o', 'n', 't', 'e', 'x', 't', 'M', 'a', 't', 'c', 'h', 'O', 'p', 't', 'i', 'o', 'n', 
+'s', 'R', '\n', 't', 'l', 's', 'C', 'o', 'n', 't', 'e', 'x', 't', '\022', 'Q', '\n', '\020', 'd', 'y', 'n', 'a', 'm', 'i', 'c', '_', 
+'m', 'e', 't', 'a', 'd', 'a', 't', 'a', '\030', '\r', ' ', '\003', '(', '\013', '2', '&', '.', 'e', 'n', 'v', 'o', 'y', '.', 't', 'y', 
+'p', 'e', '.', 'm', 'a', 't', 'c', 'h', 'e', 'r', '.', 'v', '3', '.', 'M', 'e', 't', 'a', 'd', 'a', 't', 'a', 'M', 'a', 't', 
+'c', 'h', 'e', 'r', 'R', '\017', 'd', 'y', 'n', 'a', 'm', 'i', 'c', 'M', 'e', 't', 'a', 'd', 'a', 't', 'a', '\032', 'S', '\n', '\025', 
+'G', 'r', 'p', 'c', 'R', 'o', 'u', 't', 'e', 'M', 'a', 't', 'c', 'h', 'O', 'p', 't', 'i', 'o', 'n', 's', ':', ':', '\232', '\305', 
+'\210', '\036', '5', '\n', '3', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'r', 'o', 'u', 't', 'e', '.', 'R', 
+'o', 'u', 't', 'e', 'M', 'a', 't', 'c', 'h', '.', 'G', 'r', 'p', 'c', 'R', 'o', 'u', 't', 'e', 'M', 'a', 't', 'c', 'h', 'O', 
+'p', 't', 'i', 'o', 'n', 's', '\032', '\311', '\001', '\n', '\026', 'T', 'l', 's', 'C', 'o', 'n', 't', 'e', 'x', 't', 'M', 'a', 't', 'c', 
+'h', 'O', 'p', 't', 'i', 'o', 'n', 's', '\022', '8', '\n', '\t', 'p', 'r', 'e', 's', 'e', 'n', 't', 'e', 'd', '\030', '\001', ' ', '\001', 
+'(', '\013', '2', '\032', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'B', 'o', 'o', 'l', 
+'V', 'a', 'l', 'u', 'e', 'R', '\t', 'p', 'r', 'e', 's', 'e', 'n', 't', 'e', 'd', '\022', '8', '\n', '\t', 'v', 'a', 'l', 'i', 'd', 
+'a', 't', 'e', 'd', '\030', '\002', ' ', '\001', '(', '\013', '2', '\032', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 
+'b', 'u', 'f', '.', 'B', 'o', 'o', 'l', 'V', 'a', 'l', 'u', 'e', 'R', '\t', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'e', 'd', ':', 
+';', '\232', '\305', '\210', '\036', '6', '\n', '4', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'r', 'o', 'u', 't', 
+'e', '.', 'R', 'o', 'u', 't', 'e', 'M', 'a', 't', 'c', 'h', '.', 'T', 'l', 's', 'C', 'o', 'n', 't', 'e', 'x', 't', 'M', 'a', 
+'t', 'c', 'h', 'O', 'p', 't', 'i', 'o', 'n', 's', '\032', '\020', '\n', '\016', 'C', 'o', 'n', 'n', 'e', 'c', 't', 'M', 'a', 't', 'c', 
+'h', 'e', 'r', ':', '$', '\232', '\305', '\210', '\036', '\037', '\n', '\035', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 
+'r', 'o', 'u', 't', 'e', '.', 'R', 'o', 'u', 't', 'e', 'M', 'a', 't', 'c', 'h', 'B', '\025', '\n', '\016', 'p', 'a', 't', 'h', '_', 
+'s', 'p', 'e', 'c', 'i', 'f', 'i', 'e', 'r', '\022', '\003', '\370', 'B', '\001', 'J', '\004', '\010', '\005', '\020', '\006', 'J', '\004', '\010', '\003', '\020', 
+'\004', 'R', '\005', 'r', 'e', 'g', 'e', 'x', '\"', '\350', '\004', '\n', '\n', 'C', 'o', 'r', 's', 'P', 'o', 'l', 'i', 'c', 'y', '\022', '_', 
+'\n', '\031', 'a', 'l', 'l', 'o', 'w', '_', 'o', 'r', 'i', 'g', 'i', 'n', '_', 's', 't', 'r', 'i', 'n', 'g', '_', 'm', 'a', 't', 
+'c', 'h', '\030', '\013', ' ', '\003', '(', '\013', '2', '$', '.', 'e', 'n', 'v', 'o', 'y', '.', 't', 'y', 'p', 'e', '.', 'm', 'a', 't', 
+'c', 'h', 'e', 'r', '.', 'v', '3', '.', 'S', 't', 'r', 'i', 'n', 'g', 'M', 'a', 't', 'c', 'h', 'e', 'r', 'R', '\026', 'a', 'l', 
+'l', 'o', 'w', 'O', 'r', 'i', 'g', 'i', 'n', 'S', 't', 'r', 'i', 'n', 'g', 'M', 'a', 't', 'c', 'h', '\022', '#', '\n', '\r', 'a', 
+'l', 'l', 'o', 'w', '_', 'm', 'e', 't', 'h', 'o', 'd', 's', '\030', '\002', ' ', '\001', '(', '\t', 'R', '\014', 'a', 'l', 'l', 'o', 'w', 
+'M', 'e', 't', 'h', 'o', 'd', 's', '\022', '#', '\n', '\r', 'a', 'l', 'l', 'o', 'w', '_', 'h', 'e', 'a', 'd', 'e', 'r', 's', '\030', 
+'\003', ' ', '\001', '(', '\t', 'R', '\014', 'a', 'l', 'l', 'o', 'w', 'H', 'e', 'a', 'd', 'e', 'r', 's', '\022', '%', '\n', '\016', 'e', 'x', 
+'p', 'o', 's', 'e', '_', 'h', 'e', 'a', 'd', 'e', 'r', 's', '\030', '\004', ' ', '\001', '(', '\t', 'R', '\r', 'e', 'x', 'p', 'o', 's', 
+'e', 'H', 'e', 'a', 'd', 'e', 'r', 's', '\022', '\027', '\n', '\007', 'm', 'a', 'x', '_', 'a', 'g', 'e', '\030', '\005', ' ', '\001', '(', '\t', 
+'R', '\006', 'm', 'a', 'x', 'A', 'g', 'e', '\022', 'G', '\n', '\021', 'a', 'l', 'l', 'o', 'w', '_', 'c', 'r', 'e', 'd', 'e', 'n', 't', 
+'i', 'a', 'l', 's', '\030', '\006', ' ', '\001', '(', '\013', '2', '\032', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 
+'b', 'u', 'f', '.', 'B', 'o', 'o', 'l', 'V', 'a', 'l', 'u', 'e', 'R', '\020', 'a', 'l', 'l', 'o', 'w', 'C', 'r', 'e', 'd', 'e', 
+'n', 't', 'i', 'a', 'l', 's', '\022', 'W', '\n', '\016', 'f', 'i', 'l', 't', 'e', 'r', '_', 'e', 'n', 'a', 'b', 'l', 'e', 'd', '\030', 
+'\t', ' ', '\001', '(', '\013', '2', '.', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', 
+'.', 'v', '3', '.', 'R', 'u', 'n', 't', 'i', 'm', 'e', 'F', 'r', 'a', 'c', 't', 'i', 'o', 'n', 'a', 'l', 'P', 'e', 'r', 'c', 
+'e', 'n', 't', 'H', '\000', 'R', '\r', 'f', 'i', 'l', 't', 'e', 'r', 'E', 'n', 'a', 'b', 'l', 'e', 'd', '\022', 'U', '\n', '\016', 's', 
+'h', 'a', 'd', 'o', 'w', '_', 'e', 'n', 'a', 'b', 'l', 'e', 'd', '\030', '\n', ' ', '\001', '(', '\013', '2', '.', '.', 'e', 'n', 'v', 
 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'R', 'u', 'n', 't', 'i', 'm', 'e', 
-'F', 'r', 'a', 'c', 't', 'i', 'o', 'n', 'a', 'l', 'P', 'e', 'r', 'c', 'e', 'n', 't', 'R', '\017', 'r', 'u', 'n', 't', 'i', 'm', 
-'e', 'F', 'r', 'a', 'c', 't', 'i', 'o', 'n', '\022', '>', '\n', '\007', 'h', 'e', 'a', 'd', 'e', 'r', 's', '\030', '\006', ' ', '\003', '(', 
-'\013', '2', '$', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', 
-'.', 'H', 'e', 'a', 'd', 'e', 'r', 'M', 'a', 't', 'c', 'h', 'e', 'r', 'R', '\007', 'h', 'e', 'a', 'd', 'e', 'r', 's', '\022', 'W', 
-'\n', '\020', 'q', 'u', 'e', 'r', 'y', '_', 'p', 'a', 'r', 'a', 'm', 'e', 't', 'e', 'r', 's', '\030', '\007', ' ', '\003', '(', '\013', '2', 
-',', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'Q', 
-'u', 'e', 'r', 'y', 'P', 'a', 'r', 'a', 'm', 'e', 't', 'e', 'r', 'M', 'a', 't', 'c', 'h', 'e', 'r', 'R', '\017', 'q', 'u', 'e', 
-'r', 'y', 'P', 'a', 'r', 'a', 'm', 'e', 't', 'e', 'r', 's', '\022', 'K', '\n', '\004', 'g', 'r', 'p', 'c', '\030', '\010', ' ', '\001', '(', 
-'\013', '2', '7', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', 
-'.', 'R', 'o', 'u', 't', 'e', 'M', 'a', 't', 'c', 'h', '.', 'G', 'r', 'p', 'c', 'R', 'o', 'u', 't', 'e', 'M', 'a', 't', 'c', 
-'h', 'O', 'p', 't', 'i', 'o', 'n', 's', 'R', '\004', 'g', 'r', 'p', 'c', '\022', 'Y', '\n', '\013', 't', 'l', 's', '_', 'c', 'o', 'n', 
-'t', 'e', 'x', 't', '\030', '\013', ' ', '\001', '(', '\013', '2', '8', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', 
-'.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'R', 'o', 'u', 't', 'e', 'M', 'a', 't', 'c', 'h', '.', 'T', 'l', 's', 'C', 
-'o', 'n', 't', 'e', 'x', 't', 'M', 'a', 't', 'c', 'h', 'O', 'p', 't', 'i', 'o', 'n', 's', 'R', '\n', 't', 'l', 's', 'C', 'o', 
-'n', 't', 'e', 'x', 't', '\032', 'S', '\n', '\025', 'G', 'r', 'p', 'c', 'R', 'o', 'u', 't', 'e', 'M', 'a', 't', 'c', 'h', 'O', 'p', 
-'t', 'i', 'o', 'n', 's', ':', ':', '\232', '\305', '\210', '\036', '5', '\n', '3', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', 
-'2', '.', 'r', 'o', 'u', 't', 'e', '.', 'R', 'o', 'u', 't', 'e', 'M', 'a', 't', 'c', 'h', '.', 'G', 'r', 'p', 'c', 'R', 'o', 
-'u', 't', 'e', 'M', 'a', 't', 'c', 'h', 'O', 'p', 't', 'i', 'o', 'n', 's', '\032', '\311', '\001', '\n', '\026', 'T', 'l', 's', 'C', 'o', 
-'n', 't', 'e', 'x', 't', 'M', 'a', 't', 'c', 'h', 'O', 'p', 't', 'i', 'o', 'n', 's', '\022', '8', '\n', '\t', 'p', 'r', 'e', 's', 
-'e', 'n', 't', 'e', 'd', '\030', '\001', ' ', '\001', '(', '\013', '2', '\032', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 
-'o', 'b', 'u', 'f', '.', 'B', 'o', 'o', 'l', 'V', 'a', 'l', 'u', 'e', 'R', '\t', 'p', 'r', 'e', 's', 'e', 'n', 't', 'e', 'd', 
-'\022', '8', '\n', '\t', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'e', 'd', '\030', '\002', ' ', '\001', '(', '\013', '2', '\032', '.', 'g', 'o', 'o', 
-'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'B', 'o', 'o', 'l', 'V', 'a', 'l', 'u', 'e', 'R', '\t', 'v', 
-'a', 'l', 'i', 'd', 'a', 't', 'e', 'd', ':', ';', '\232', '\305', '\210', '\036', '6', '\n', '4', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 
-'i', '.', 'v', '2', '.', 'r', 'o', 'u', 't', 'e', '.', 'R', 'o', 'u', 't', 'e', 'M', 'a', 't', 'c', 'h', '.', 'T', 'l', 's', 
-'C', 'o', 'n', 't', 'e', 'x', 't', 'M', 'a', 't', 'c', 'h', 'O', 'p', 't', 'i', 'o', 'n', 's', '\032', '\020', '\n', '\016', 'C', 'o', 
-'n', 'n', 'e', 'c', 't', 'M', 'a', 't', 'c', 'h', 'e', 'r', ':', '$', '\232', '\305', '\210', '\036', '\037', '\n', '\035', 'e', 'n', 'v', 'o', 
-'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'r', 'o', 'u', 't', 'e', '.', 'R', 'o', 'u', 't', 'e', 'M', 'a', 't', 'c', 'h', 
-'B', '\025', '\n', '\016', 'p', 'a', 't', 'h', '_', 's', 'p', 'e', 'c', 'i', 'f', 'i', 'e', 'r', '\022', '\003', '\370', 'B', '\001', 'J', '\004', 
-'\010', '\005', '\020', '\006', 'J', '\004', '\010', '\003', '\020', '\004', 'R', '\005', 'r', 'e', 'g', 'e', 'x', '\"', '\350', '\004', '\n', '\n', 'C', 'o', 'r', 
-'s', 'P', 'o', 'l', 'i', 'c', 'y', '\022', '_', '\n', '\031', 'a', 'l', 'l', 'o', 'w', '_', 'o', 'r', 'i', 'g', 'i', 'n', '_', 's', 
-'t', 'r', 'i', 'n', 'g', '_', 'm', 'a', 't', 'c', 'h', '\030', '\013', ' ', '\003', '(', '\013', '2', '$', '.', 'e', 'n', 'v', 'o', 'y', 
-'.', 't', 'y', 'p', 'e', '.', 'm', 'a', 't', 'c', 'h', 'e', 'r', '.', 'v', '3', '.', 'S', 't', 'r', 'i', 'n', 'g', 'M', 'a', 
-'t', 'c', 'h', 'e', 'r', 'R', '\026', 'a', 'l', 'l', 'o', 'w', 'O', 'r', 'i', 'g', 'i', 'n', 'S', 't', 'r', 'i', 'n', 'g', 'M', 
-'a', 't', 'c', 'h', '\022', '#', '\n', '\r', 'a', 'l', 'l', 'o', 'w', '_', 'm', 'e', 't', 'h', 'o', 'd', 's', '\030', '\002', ' ', '\001', 
-'(', '\t', 'R', '\014', 'a', 'l', 'l', 'o', 'w', 'M', 'e', 't', 'h', 'o', 'd', 's', '\022', '#', '\n', '\r', 'a', 'l', 'l', 'o', 'w', 
-'_', 'h', 'e', 'a', 'd', 'e', 'r', 's', '\030', '\003', ' ', '\001', '(', '\t', 'R', '\014', 'a', 'l', 'l', 'o', 'w', 'H', 'e', 'a', 'd', 
-'e', 'r', 's', '\022', '%', '\n', '\016', 'e', 'x', 'p', 'o', 's', 'e', '_', 'h', 'e', 'a', 'd', 'e', 'r', 's', '\030', '\004', ' ', '\001', 
-'(', '\t', 'R', '\r', 'e', 'x', 'p', 'o', 's', 'e', 'H', 'e', 'a', 'd', 'e', 'r', 's', '\022', '\027', '\n', '\007', 'm', 'a', 'x', '_', 
-'a', 'g', 'e', '\030', '\005', ' ', '\001', '(', '\t', 'R', '\006', 'm', 'a', 'x', 'A', 'g', 'e', '\022', 'G', '\n', '\021', 'a', 'l', 'l', 'o', 
-'w', '_', 'c', 'r', 'e', 'd', 'e', 'n', 't', 'i', 'a', 'l', 's', '\030', '\006', ' ', '\001', '(', '\013', '2', '\032', '.', 'g', 'o', 'o', 
-'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'B', 'o', 'o', 'l', 'V', 'a', 'l', 'u', 'e', 'R', '\020', 'a', 
-'l', 'l', 'o', 'w', 'C', 'r', 'e', 'd', 'e', 'n', 't', 'i', 'a', 'l', 's', '\022', 'W', '\n', '\016', 'f', 'i', 'l', 't', 'e', 'r', 
-'_', 'e', 'n', 'a', 'b', 'l', 'e', 'd', '\030', '\t', ' ', '\001', '(', '\013', '2', '.', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 
-'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'R', 'u', 'n', 't', 'i', 'm', 'e', 'F', 'r', 'a', 'c', 't', 
-'i', 'o', 'n', 'a', 'l', 'P', 'e', 'r', 'c', 'e', 'n', 't', 'H', '\000', 'R', '\r', 'f', 'i', 'l', 't', 'e', 'r', 'E', 'n', 'a', 
-'b', 'l', 'e', 'd', '\022', 'U', '\n', '\016', 's', 'h', 'a', 'd', 'o', 'w', '_', 'e', 'n', 'a', 'b', 'l', 'e', 'd', '\030', '\n', ' ', 
-'\001', '(', '\013', '2', '.', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', 
-'3', '.', 'R', 'u', 'n', 't', 'i', 'm', 'e', 'F', 'r', 'a', 'c', 't', 'i', 'o', 'n', 'a', 'l', 'P', 'e', 'r', 'c', 'e', 'n', 
-'t', 'R', '\r', 's', 'h', 'a', 'd', 'o', 'w', 'E', 'n', 'a', 'b', 'l', 'e', 'd', ':', '$', '\232', '\305', '\210', '\036', '\037', '\n', '\035', 
-'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'r', 'o', 'u', 't', 'e', '.', 'C', 'o', 'r', 's', 'P', 'o', 
-'l', 'i', 'c', 'y', 'B', '\023', '\n', '\021', 'e', 'n', 'a', 'b', 'l', 'e', 'd', '_', 's', 'p', 'e', 'c', 'i', 'f', 'i', 'e', 'r', 
-'J', '\004', '\010', '\001', '\020', '\002', 'J', '\004', '\010', '\010', '\020', '\t', 'J', '\004', '\010', '\007', '\020', '\010', 'R', '\014', 'a', 'l', 'l', 'o', 'w', 
-'_', 'o', 'r', 'i', 'g', 'i', 'n', 'R', '\022', 'a', 'l', 'l', 'o', 'w', '_', 'o', 'r', 'i', 'g', 'i', 'n', '_', 'r', 'e', 'g', 
-'e', 'x', 'R', '\007', 'e', 'n', 'a', 'b', 'l', 'e', 'd', '\"', '\262', '\'', '\n', '\013', 'R', 'o', 'u', 't', 'e', 'A', 'c', 't', 'i', 
-'o', 'n', '\022', '#', '\n', '\007', 'c', 'l', 'u', 's', 't', 'e', 'r', '\030', '\001', ' ', '\001', '(', '\t', 'B', '\007', '\372', 'B', '\004', 'r', 
-'\002', '\020', '\001', 'H', '\000', 'R', '\007', 'c', 'l', 'u', 's', 't', 'e', 'r', '\022', '6', '\n', '\016', 'c', 'l', 'u', 's', 't', 'e', 'r', 
-'_', 'h', 'e', 'a', 'd', 'e', 'r', '\030', '\002', ' ', '\001', '(', '\t', 'B', '\r', '\372', 'B', '\n', 'r', '\010', '\020', '\001', '\300', '\001', '\001', 
-'\310', '\001', '\000', 'H', '\000', 'R', '\r', 'c', 'l', 'u', 's', 't', 'e', 'r', 'H', 'e', 'a', 'd', 'e', 'r', '\022', 'U', '\n', '\021', 'w', 
-'e', 'i', 'g', 'h', 't', 'e', 'd', '_', 'c', 'l', 'u', 's', 't', 'e', 'r', 's', '\030', '\003', ' ', '\001', '(', '\013', '2', '&', '.', 
-'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'W', 'e', 'i', 
-'g', 'h', 't', 'e', 'd', 'C', 'l', 'u', 's', 't', 'e', 'r', 'H', '\000', 'R', '\020', 'w', 'e', 'i', 'g', 'h', 't', 'e', 'd', 'C', 
-'l', 'u', 's', 't', 'e', 'r', 's', '\022', ':', '\n', '\030', 'c', 'l', 'u', 's', 't', 'e', 'r', '_', 's', 'p', 'e', 'c', 'i', 'f', 
-'i', 'e', 'r', '_', 'p', 'l', 'u', 'g', 'i', 'n', '\030', '%', ' ', '\001', '(', '\t', 'H', '\000', 'R', '\026', 'c', 'l', 'u', 's', 't', 
-'e', 'r', 'S', 'p', 'e', 'c', 'i', 'f', 'i', 'e', 'r', 'P', 'l', 'u', 'g', 'i', 'n', '\022', '\216', '\001', '\n', '\037', 'c', 'l', 'u', 
-'s', 't', 'e', 'r', '_', 'n', 'o', 't', '_', 'f', 'o', 'u', 'n', 'd', '_', 'r', 'e', 's', 'p', 'o', 'n', 's', 'e', '_', 'c', 
-'o', 'd', 'e', '\030', '\024', ' ', '\001', '(', '\016', '2', '>', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 
-'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'R', 'o', 'u', 't', 'e', 'A', 'c', 't', 'i', 'o', 'n', '.', 'C', 'l', 'u', 's', 
-'t', 'e', 'r', 'N', 'o', 't', 'F', 'o', 'u', 'n', 'd', 'R', 'e', 's', 'p', 'o', 'n', 's', 'e', 'C', 'o', 'd', 'e', 'B', '\010', 
-'\372', 'B', '\005', '\202', '\001', '\002', '\020', '\001', 'R', '\033', 'c', 'l', 'u', 's', 't', 'e', 'r', 'N', 'o', 't', 'F', 'o', 'u', 'n', 'd', 
-'R', 'e', 's', 'p', 'o', 'n', 's', 'e', 'C', 'o', 'd', 'e', '\022', 'E', '\n', '\016', 'm', 'e', 't', 'a', 'd', 'a', 't', 'a', '_', 
-'m', 'a', 't', 'c', 'h', '\030', '\004', ' ', '\001', '(', '\013', '2', '\036', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 
-'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'M', 'e', 't', 'a', 'd', 'a', 't', 'a', 'R', '\r', 'm', 'e', 't', 'a', 'd', 
-'a', 't', 'a', 'M', 'a', 't', 'c', 'h', '\022', '2', '\n', '\016', 'p', 'r', 'e', 'f', 'i', 'x', '_', 'r', 'e', 'w', 'r', 'i', 't', 
-'e', '\030', '\005', ' ', '\001', '(', '\t', 'B', '\013', '\372', 'B', '\010', 'r', '\006', '\300', '\001', '\002', '\310', '\001', '\000', 'R', '\r', 'p', 'r', 'e', 
-'f', 'i', 'x', 'R', 'e', 'w', 'r', 'i', 't', 'e', '\022', 'S', '\n', '\r', 'r', 'e', 'g', 'e', 'x', '_', 'r', 'e', 'w', 'r', 'i', 
-'t', 'e', '\030', ' ', ' ', '\001', '(', '\013', '2', '.', '.', 'e', 'n', 'v', 'o', 'y', '.', 't', 'y', 'p', 'e', '.', 'm', 'a', 't', 
-'c', 'h', 'e', 'r', '.', 'v', '3', '.', 'R', 'e', 'g', 'e', 'x', 'M', 'a', 't', 'c', 'h', 'A', 'n', 'd', 'S', 'u', 'b', 's', 
-'t', 'i', 't', 'u', 't', 'e', 'R', '\014', 'r', 'e', 'g', 'e', 'x', 'R', 'e', 'w', 'r', 'i', 't', 'e', '\022', '?', '\n', '\024', 'h', 
-'o', 's', 't', '_', 'r', 'e', 'w', 'r', 'i', 't', 'e', '_', 'l', 'i', 't', 'e', 'r', 'a', 'l', '\030', '\006', ' ', '\001', '(', '\t', 
-'B', '\013', '\372', 'B', '\010', 'r', '\006', '\300', '\001', '\002', '\310', '\001', '\000', 'H', '\001', 'R', '\022', 'h', 'o', 's', 't', 'R', 'e', 'w', 'r', 
-'i', 't', 'e', 'L', 'i', 't', 'e', 'r', 'a', 'l', '\022', 'H', '\n', '\021', 'a', 'u', 't', 'o', '_', 'h', 'o', 's', 't', '_', 'r', 
-'e', 'w', 'r', 'i', 't', 'e', '\030', '\007', ' ', '\001', '(', '\013', '2', '\032', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 
-'t', 'o', 'b', 'u', 'f', '.', 'B', 'o', 'o', 'l', 'V', 'a', 'l', 'u', 'e', 'H', '\001', 'R', '\017', 'a', 'u', 't', 'o', 'H', 'o', 
-'s', 't', 'R', 'e', 'w', 'r', 'i', 't', 'e', '\022', '=', '\n', '\023', 'h', 'o', 's', 't', '_', 'r', 'e', 'w', 'r', 'i', 't', 'e', 
-'_', 'h', 'e', 'a', 'd', 'e', 'r', '\030', '\035', ' ', '\001', '(', '\t', 'B', '\013', '\372', 'B', '\010', 'r', '\006', '\300', '\001', '\001', '\310', '\001', 
-'\000', 'H', '\001', 'R', '\021', 'h', 'o', 's', 't', 'R', 'e', 'w', 'r', 'i', 't', 'e', 'H', 'e', 'a', 'd', 'e', 'r', '\022', 'g', '\n', 
-'\027', 'h', 'o', 's', 't', '_', 'r', 'e', 'w', 'r', 'i', 't', 'e', '_', 'p', 'a', 't', 'h', '_', 'r', 'e', 'g', 'e', 'x', '\030', 
-'#', ' ', '\001', '(', '\013', '2', '.', '.', 'e', 'n', 'v', 'o', 'y', '.', 't', 'y', 'p', 'e', '.', 'm', 'a', 't', 'c', 'h', 'e', 
-'r', '.', 'v', '3', '.', 'R', 'e', 'g', 'e', 'x', 'M', 'a', 't', 'c', 'h', 'A', 'n', 'd', 'S', 'u', 'b', 's', 't', 'i', 't', 
-'u', 't', 'e', 'H', '\001', 'R', '\024', 'h', 'o', 's', 't', 'R', 'e', 'w', 'r', 'i', 't', 'e', 'P', 'a', 't', 'h', 'R', 'e', 'g', 
-'e', 'x', '\022', '3', '\n', '\007', 't', 'i', 'm', 'e', 'o', 'u', 't', '\030', '\010', ' ', '\001', '(', '\013', '2', '\031', '.', 'g', 'o', 'o', 
-'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'D', 'u', 'r', 'a', 't', 'i', 'o', 'n', 'R', '\007', 't', 'i', 
-'m', 'e', 'o', 'u', 't', '\022', '<', '\n', '\014', 'i', 'd', 'l', 'e', '_', 't', 'i', 'm', 'e', 'o', 'u', 't', '\030', '\030', ' ', '\001', 
-'(', '\013', '2', '\031', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'D', 'u', 'r', 'a', 
-'t', 'i', 'o', 'n', 'R', '\013', 'i', 'd', 'l', 'e', 'T', 'i', 'm', 'e', 'o', 'u', 't', '\022', 'E', '\n', '\014', 'r', 'e', 't', 'r', 
-'y', '_', 'p', 'o', 'l', 'i', 'c', 'y', '\030', '\t', ' ', '\001', '(', '\013', '2', '\"', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 
-'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'R', 'e', 't', 'r', 'y', 'P', 'o', 'l', 'i', 'c', 'y', 
-'R', '\013', 'r', 'e', 't', 'r', 'y', 'P', 'o', 'l', 'i', 'c', 'y', '\022', 'O', '\n', '\031', 'r', 'e', 't', 'r', 'y', '_', 'p', 'o', 
-'l', 'i', 'c', 'y', '_', 't', 'y', 'p', 'e', 'd', '_', 'c', 'o', 'n', 'f', 'i', 'g', '\030', '!', ' ', '\001', '(', '\013', '2', '\024', 
-'.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'A', 'n', 'y', 'R', '\026', 'r', 'e', 't', 
-'r', 'y', 'P', 'o', 'l', 'i', 'c', 'y', 'T', 'y', 'p', 'e', 'd', 'C', 'o', 'n', 'f', 'i', 'g', '\022', 'n', '\n', '\027', 'r', 'e', 
-'q', 'u', 'e', 's', 't', '_', 'm', 'i', 'r', 'r', 'o', 'r', '_', 'p', 'o', 'l', 'i', 'c', 'i', 'e', 's', '\030', '\036', ' ', '\003', 
-'(', '\013', '2', '6', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', 
-'3', '.', 'R', 'o', 'u', 't', 'e', 'A', 'c', 't', 'i', 'o', 'n', '.', 'R', 'e', 'q', 'u', 'e', 's', 't', 'M', 'i', 'r', 'r', 
-'o', 'r', 'P', 'o', 'l', 'i', 'c', 'y', 'R', '\025', 'r', 'e', 'q', 'u', 'e', 's', 't', 'M', 'i', 'r', 'r', 'o', 'r', 'P', 'o', 
-'l', 'i', 'c', 'i', 'e', 's', '\022', 'K', '\n', '\010', 'p', 'r', 'i', 'o', 'r', 'i', 't', 'y', '\030', '\013', ' ', '\001', '(', '\016', '2', 
-'%', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'R', 'o', 
-'u', 't', 'i', 'n', 'g', 'P', 'r', 'i', 'o', 'r', 'i', 't', 'y', 'B', '\010', '\372', 'B', '\005', '\202', '\001', '\002', '\020', '\001', 'R', '\010', 
-'p', 'r', 'i', 'o', 'r', 'i', 't', 'y', '\022', 'A', '\n', '\013', 'r', 'a', 't', 'e', '_', 'l', 'i', 'm', 'i', 't', 's', '\030', '\r', 
-' ', '\003', '(', '\013', '2', ' ', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', 
-'.', 'v', '3', '.', 'R', 'a', 't', 'e', 'L', 'i', 'm', 'i', 't', 'R', '\n', 'r', 'a', 't', 'e', 'L', 'i', 'm', 'i', 't', 's', 
-'\022', '\\', '\n', '\026', 'i', 'n', 'c', 'l', 'u', 'd', 'e', '_', 'v', 'h', '_', 'r', 'a', 't', 'e', '_', 'l', 'i', 'm', 'i', 't', 
-'s', '\030', '\016', ' ', '\001', '(', '\013', '2', '\032', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', 
-'.', 'B', 'o', 'o', 'l', 'V', 'a', 'l', 'u', 'e', 'B', '\013', '\030', '\001', '\222', '\307', '\206', '\330', '\004', '\003', '3', '.', '0', 'R', '\023', 
-'i', 'n', 'c', 'l', 'u', 'd', 'e', 'V', 'h', 'R', 'a', 't', 'e', 'L', 'i', 'm', 'i', 't', 's', '\022', 'N', '\n', '\013', 'h', 'a', 
-'s', 'h', '_', 'p', 'o', 'l', 'i', 'c', 'y', '\030', '\017', ' ', '\003', '(', '\013', '2', '-', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 
+'F', 'r', 'a', 'c', 't', 'i', 'o', 'n', 'a', 'l', 'P', 'e', 'r', 'c', 'e', 'n', 't', 'R', '\r', 's', 'h', 'a', 'd', 'o', 'w', 
+'E', 'n', 'a', 'b', 'l', 'e', 'd', ':', '$', '\232', '\305', '\210', '\036', '\037', '\n', '\035', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', 
+'.', 'v', '2', '.', 'r', 'o', 'u', 't', 'e', '.', 'C', 'o', 'r', 's', 'P', 'o', 'l', 'i', 'c', 'y', 'B', '\023', '\n', '\021', 'e', 
+'n', 'a', 'b', 'l', 'e', 'd', '_', 's', 'p', 'e', 'c', 'i', 'f', 'i', 'e', 'r', 'J', '\004', '\010', '\001', '\020', '\002', 'J', '\004', '\010', 
+'\010', '\020', '\t', 'J', '\004', '\010', '\007', '\020', '\010', 'R', '\014', 'a', 'l', 'l', 'o', 'w', '_', 'o', 'r', 'i', 'g', 'i', 'n', 'R', '\022', 
+'a', 'l', 'l', 'o', 'w', '_', 'o', 'r', 'i', 'g', 'i', 'n', '_', 'r', 'e', 'g', 'e', 'x', 'R', '\007', 'e', 'n', 'a', 'b', 'l', 
+'e', 'd', '\"', '\262', '\'', '\n', '\013', 'R', 'o', 'u', 't', 'e', 'A', 'c', 't', 'i', 'o', 'n', '\022', '#', '\n', '\007', 'c', 'l', 'u', 
+'s', 't', 'e', 'r', '\030', '\001', ' ', '\001', '(', '\t', 'B', '\007', '\372', 'B', '\004', 'r', '\002', '\020', '\001', 'H', '\000', 'R', '\007', 'c', 'l', 
+'u', 's', 't', 'e', 'r', '\022', '6', '\n', '\016', 'c', 'l', 'u', 's', 't', 'e', 'r', '_', 'h', 'e', 'a', 'd', 'e', 'r', '\030', '\002', 
+' ', '\001', '(', '\t', 'B', '\r', '\372', 'B', '\n', 'r', '\010', '\020', '\001', '\300', '\001', '\001', '\310', '\001', '\000', 'H', '\000', 'R', '\r', 'c', 'l', 
+'u', 's', 't', 'e', 'r', 'H', 'e', 'a', 'd', 'e', 'r', '\022', 'U', '\n', '\021', 'w', 'e', 'i', 'g', 'h', 't', 'e', 'd', '_', 'c', 
+'l', 'u', 's', 't', 'e', 'r', 's', '\030', '\003', ' ', '\001', '(', '\013', '2', '&', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 
+'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'W', 'e', 'i', 'g', 'h', 't', 'e', 'd', 'C', 'l', 'u', 's', 
+'t', 'e', 'r', 'H', '\000', 'R', '\020', 'w', 'e', 'i', 'g', 'h', 't', 'e', 'd', 'C', 'l', 'u', 's', 't', 'e', 'r', 's', '\022', ':', 
+'\n', '\030', 'c', 'l', 'u', 's', 't', 'e', 'r', '_', 's', 'p', 'e', 'c', 'i', 'f', 'i', 'e', 'r', '_', 'p', 'l', 'u', 'g', 'i', 
+'n', '\030', '%', ' ', '\001', '(', '\t', 'H', '\000', 'R', '\026', 'c', 'l', 'u', 's', 't', 'e', 'r', 'S', 'p', 'e', 'c', 'i', 'f', 'i', 
+'e', 'r', 'P', 'l', 'u', 'g', 'i', 'n', '\022', '\216', '\001', '\n', '\037', 'c', 'l', 'u', 's', 't', 'e', 'r', '_', 'n', 'o', 't', '_', 
+'f', 'o', 'u', 'n', 'd', '_', 'r', 'e', 's', 'p', 'o', 'n', 's', 'e', '_', 'c', 'o', 'd', 'e', '\030', '\024', ' ', '\001', '(', '\016', 
+'2', '>', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 
+'R', 'o', 'u', 't', 'e', 'A', 'c', 't', 'i', 'o', 'n', '.', 'C', 'l', 'u', 's', 't', 'e', 'r', 'N', 'o', 't', 'F', 'o', 'u', 
+'n', 'd', 'R', 'e', 's', 'p', 'o', 'n', 's', 'e', 'C', 'o', 'd', 'e', 'B', '\010', '\372', 'B', '\005', '\202', '\001', '\002', '\020', '\001', 'R', 
+'\033', 'c', 'l', 'u', 's', 't', 'e', 'r', 'N', 'o', 't', 'F', 'o', 'u', 'n', 'd', 'R', 'e', 's', 'p', 'o', 'n', 's', 'e', 'C', 
+'o', 'd', 'e', '\022', 'E', '\n', '\016', 'm', 'e', 't', 'a', 'd', 'a', 't', 'a', '_', 'm', 'a', 't', 'c', 'h', '\030', '\004', ' ', '\001', 
+'(', '\013', '2', '\036', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', 
+'.', 'M', 'e', 't', 'a', 'd', 'a', 't', 'a', 'R', '\r', 'm', 'e', 't', 'a', 'd', 'a', 't', 'a', 'M', 'a', 't', 'c', 'h', '\022', 
+'2', '\n', '\016', 'p', 'r', 'e', 'f', 'i', 'x', '_', 'r', 'e', 'w', 'r', 'i', 't', 'e', '\030', '\005', ' ', '\001', '(', '\t', 'B', '\013', 
+'\372', 'B', '\010', 'r', '\006', '\300', '\001', '\002', '\310', '\001', '\000', 'R', '\r', 'p', 'r', 'e', 'f', 'i', 'x', 'R', 'e', 'w', 'r', 'i', 't', 
+'e', '\022', 'S', '\n', '\r', 'r', 'e', 'g', 'e', 'x', '_', 'r', 'e', 'w', 'r', 'i', 't', 'e', '\030', ' ', ' ', '\001', '(', '\013', '2', 
+'.', '.', 'e', 'n', 'v', 'o', 'y', '.', 't', 'y', 'p', 'e', '.', 'm', 'a', 't', 'c', 'h', 'e', 'r', '.', 'v', '3', '.', 'R', 
+'e', 'g', 'e', 'x', 'M', 'a', 't', 'c', 'h', 'A', 'n', 'd', 'S', 'u', 'b', 's', 't', 'i', 't', 'u', 't', 'e', 'R', '\014', 'r', 
+'e', 'g', 'e', 'x', 'R', 'e', 'w', 'r', 'i', 't', 'e', '\022', '?', '\n', '\024', 'h', 'o', 's', 't', '_', 'r', 'e', 'w', 'r', 'i', 
+'t', 'e', '_', 'l', 'i', 't', 'e', 'r', 'a', 'l', '\030', '\006', ' ', '\001', '(', '\t', 'B', '\013', '\372', 'B', '\010', 'r', '\006', '\300', '\001', 
+'\002', '\310', '\001', '\000', 'H', '\001', 'R', '\022', 'h', 'o', 's', 't', 'R', 'e', 'w', 'r', 'i', 't', 'e', 'L', 'i', 't', 'e', 'r', 'a', 
+'l', '\022', 'H', '\n', '\021', 'a', 'u', 't', 'o', '_', 'h', 'o', 's', 't', '_', 'r', 'e', 'w', 'r', 'i', 't', 'e', '\030', '\007', ' ', 
+'\001', '(', '\013', '2', '\032', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'B', 'o', 'o', 
+'l', 'V', 'a', 'l', 'u', 'e', 'H', '\001', 'R', '\017', 'a', 'u', 't', 'o', 'H', 'o', 's', 't', 'R', 'e', 'w', 'r', 'i', 't', 'e', 
+'\022', '=', '\n', '\023', 'h', 'o', 's', 't', '_', 'r', 'e', 'w', 'r', 'i', 't', 'e', '_', 'h', 'e', 'a', 'd', 'e', 'r', '\030', '\035', 
+' ', '\001', '(', '\t', 'B', '\013', '\372', 'B', '\010', 'r', '\006', '\300', '\001', '\001', '\310', '\001', '\000', 'H', '\001', 'R', '\021', 'h', 'o', 's', 't', 
+'R', 'e', 'w', 'r', 'i', 't', 'e', 'H', 'e', 'a', 'd', 'e', 'r', '\022', 'g', '\n', '\027', 'h', 'o', 's', 't', '_', 'r', 'e', 'w', 
+'r', 'i', 't', 'e', '_', 'p', 'a', 't', 'h', '_', 'r', 'e', 'g', 'e', 'x', '\030', '#', ' ', '\001', '(', '\013', '2', '.', '.', 'e', 
+'n', 'v', 'o', 'y', '.', 't', 'y', 'p', 'e', '.', 'm', 'a', 't', 'c', 'h', 'e', 'r', '.', 'v', '3', '.', 'R', 'e', 'g', 'e', 
+'x', 'M', 'a', 't', 'c', 'h', 'A', 'n', 'd', 'S', 'u', 'b', 's', 't', 'i', 't', 'u', 't', 'e', 'H', '\001', 'R', '\024', 'h', 'o', 
+'s', 't', 'R', 'e', 'w', 'r', 'i', 't', 'e', 'P', 'a', 't', 'h', 'R', 'e', 'g', 'e', 'x', '\022', '3', '\n', '\007', 't', 'i', 'm', 
+'e', 'o', 'u', 't', '\030', '\010', ' ', '\001', '(', '\013', '2', '\031', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 
+'b', 'u', 'f', '.', 'D', 'u', 'r', 'a', 't', 'i', 'o', 'n', 'R', '\007', 't', 'i', 'm', 'e', 'o', 'u', 't', '\022', '<', '\n', '\014', 
+'i', 'd', 'l', 'e', '_', 't', 'i', 'm', 'e', 'o', 'u', 't', '\030', '\030', ' ', '\001', '(', '\013', '2', '\031', '.', 'g', 'o', 'o', 'g', 
+'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'D', 'u', 'r', 'a', 't', 'i', 'o', 'n', 'R', '\013', 'i', 'd', 'l', 
+'e', 'T', 'i', 'm', 'e', 'o', 'u', 't', '\022', 'E', '\n', '\014', 'r', 'e', 't', 'r', 'y', '_', 'p', 'o', 'l', 'i', 'c', 'y', '\030', 
+'\t', ' ', '\001', '(', '\013', '2', '\"', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 
+'e', '.', 'v', '3', '.', 'R', 'e', 't', 'r', 'y', 'P', 'o', 'l', 'i', 'c', 'y', 'R', '\013', 'r', 'e', 't', 'r', 'y', 'P', 'o', 
+'l', 'i', 'c', 'y', '\022', 'O', '\n', '\031', 'r', 'e', 't', 'r', 'y', '_', 'p', 'o', 'l', 'i', 'c', 'y', '_', 't', 'y', 'p', 'e', 
+'d', '_', 'c', 'o', 'n', 'f', 'i', 'g', '\030', '!', ' ', '\001', '(', '\013', '2', '\024', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 
+'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'A', 'n', 'y', 'R', '\026', 'r', 'e', 't', 'r', 'y', 'P', 'o', 'l', 'i', 'c', 'y', 'T', 
+'y', 'p', 'e', 'd', 'C', 'o', 'n', 'f', 'i', 'g', '\022', 'n', '\n', '\027', 'r', 'e', 'q', 'u', 'e', 's', 't', '_', 'm', 'i', 'r', 
+'r', 'o', 'r', '_', 'p', 'o', 'l', 'i', 'c', 'i', 'e', 's', '\030', '\036', ' ', '\003', '(', '\013', '2', '6', '.', 'e', 'n', 'v', 'o', 
+'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'R', 'o', 'u', 't', 'e', 'A', 'c', 
+'t', 'i', 'o', 'n', '.', 'R', 'e', 'q', 'u', 'e', 's', 't', 'M', 'i', 'r', 'r', 'o', 'r', 'P', 'o', 'l', 'i', 'c', 'y', 'R', 
+'\025', 'r', 'e', 'q', 'u', 'e', 's', 't', 'M', 'i', 'r', 'r', 'o', 'r', 'P', 'o', 'l', 'i', 'c', 'i', 'e', 's', '\022', 'K', '\n', 
+'\010', 'p', 'r', 'i', 'o', 'r', 'i', 't', 'y', '\030', '\013', ' ', '\001', '(', '\016', '2', '%', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 
+'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'R', 'o', 'u', 't', 'i', 'n', 'g', 'P', 'r', 'i', 'o', 
+'r', 'i', 't', 'y', 'B', '\010', '\372', 'B', '\005', '\202', '\001', '\002', '\020', '\001', 'R', '\010', 'p', 'r', 'i', 'o', 'r', 'i', 't', 'y', '\022', 
+'A', '\n', '\013', 'r', 'a', 't', 'e', '_', 'l', 'i', 'm', 'i', 't', 's', '\030', '\r', ' ', '\003', '(', '\013', '2', ' ', '.', 'e', 'n', 
+'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'R', 'a', 't', 'e', 'L', 
+'i', 'm', 'i', 't', 'R', '\n', 'r', 'a', 't', 'e', 'L', 'i', 'm', 'i', 't', 's', '\022', '\\', '\n', '\026', 'i', 'n', 'c', 'l', 'u', 
+'d', 'e', '_', 'v', 'h', '_', 'r', 'a', 't', 'e', '_', 'l', 'i', 'm', 'i', 't', 's', '\030', '\016', ' ', '\001', '(', '\013', '2', '\032', 
+'.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'B', 'o', 'o', 'l', 'V', 'a', 'l', 'u', 
+'e', 'B', '\013', '\030', '\001', '\222', '\307', '\206', '\330', '\004', '\003', '3', '.', '0', 'R', '\023', 'i', 'n', 'c', 'l', 'u', 'd', 'e', 'V', 'h', 
+'R', 'a', 't', 'e', 'L', 'i', 'm', 'i', 't', 's', '\022', 'N', '\n', '\013', 'h', 'a', 's', 'h', '_', 'p', 'o', 'l', 'i', 'c', 'y', 
+'\030', '\017', ' ', '\003', '(', '\013', '2', '-', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 
+'t', 'e', '.', 'v', '3', '.', 'R', 'o', 'u', 't', 'e', 'A', 'c', 't', 'i', 'o', 'n', '.', 'H', 'a', 's', 'h', 'P', 'o', 'l', 
+'i', 'c', 'y', 'R', '\n', 'h', 'a', 's', 'h', 'P', 'o', 'l', 'i', 'c', 'y', '\022', '5', '\n', '\004', 'c', 'o', 'r', 's', '\030', '\021', 
+' ', '\001', '(', '\013', '2', '!', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', 
+'.', 'v', '3', '.', 'C', 'o', 'r', 's', 'P', 'o', 'l', 'i', 'c', 'y', 'R', '\004', 'c', 'o', 'r', 's', '\022', 'P', '\n', '\020', 'm', 
+'a', 'x', '_', 'g', 'r', 'p', 'c', '_', 't', 'i', 'm', 'e', 'o', 'u', 't', '\030', '\027', ' ', '\001', '(', '\013', '2', '\031', '.', 'g', 
+'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'D', 'u', 'r', 'a', 't', 'i', 'o', 'n', 'B', '\013', 
+'\030', '\001', '\222', '\307', '\206', '\330', '\004', '\003', '3', '.', '0', 'R', '\016', 'm', 'a', 'x', 'G', 'r', 'p', 'c', 'T', 'i', 'm', 'e', 'o', 
+'u', 't', '\022', 'V', '\n', '\023', 'g', 'r', 'p', 'c', '_', 't', 'i', 'm', 'e', 'o', 'u', 't', '_', 'o', 'f', 'f', 's', 'e', 't', 
+'\030', '\034', ' ', '\001', '(', '\013', '2', '\031', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 
+'D', 'u', 'r', 'a', 't', 'i', 'o', 'n', 'B', '\013', '\030', '\001', '\222', '\307', '\206', '\330', '\004', '\003', '3', '.', '0', 'R', '\021', 'g', 'r', 
+'p', 'c', 'T', 'i', 'm', 'e', 'o', 'u', 't', 'O', 'f', 'f', 's', 'e', 't', '\022', 'Y', '\n', '\017', 'u', 'p', 'g', 'r', 'a', 'd', 
+'e', '_', 'c', 'o', 'n', 'f', 'i', 'g', 's', '\030', '\031', ' ', '\003', '(', '\013', '2', '0', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 
 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'R', 'o', 'u', 't', 'e', 'A', 'c', 't', 'i', 'o', 
-'n', '.', 'H', 'a', 's', 'h', 'P', 'o', 'l', 'i', 'c', 'y', 'R', '\n', 'h', 'a', 's', 'h', 'P', 'o', 'l', 'i', 'c', 'y', '\022', 
-'5', '\n', '\004', 'c', 'o', 'r', 's', '\030', '\021', ' ', '\001', '(', '\013', '2', '!', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 
-'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'C', 'o', 'r', 's', 'P', 'o', 'l', 'i', 'c', 'y', 'R', '\004', 
-'c', 'o', 'r', 's', '\022', 'P', '\n', '\020', 'm', 'a', 'x', '_', 'g', 'r', 'p', 'c', '_', 't', 'i', 'm', 'e', 'o', 'u', 't', '\030', 
-'\027', ' ', '\001', '(', '\013', '2', '\031', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'D', 
-'u', 'r', 'a', 't', 'i', 'o', 'n', 'B', '\013', '\030', '\001', '\222', '\307', '\206', '\330', '\004', '\003', '3', '.', '0', 'R', '\016', 'm', 'a', 'x', 
-'G', 'r', 'p', 'c', 'T', 'i', 'm', 'e', 'o', 'u', 't', '\022', 'V', '\n', '\023', 'g', 'r', 'p', 'c', '_', 't', 'i', 'm', 'e', 'o', 
-'u', 't', '_', 'o', 'f', 'f', 's', 'e', 't', '\030', '\034', ' ', '\001', '(', '\013', '2', '\031', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 
-'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'D', 'u', 'r', 'a', 't', 'i', 'o', 'n', 'B', '\013', '\030', '\001', '\222', '\307', '\206', '\330', 
-'\004', '\003', '3', '.', '0', 'R', '\021', 'g', 'r', 'p', 'c', 'T', 'i', 'm', 'e', 'o', 'u', 't', 'O', 'f', 'f', 's', 'e', 't', '\022', 
-'Y', '\n', '\017', 'u', 'p', 'g', 'r', 'a', 'd', 'e', '_', 'c', 'o', 'n', 'f', 'i', 'g', 's', '\030', '\031', ' ', '\003', '(', '\013', '2', 
-'0', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'R', 
-'o', 'u', 't', 'e', 'A', 'c', 't', 'i', 'o', 'n', '.', 'U', 'p', 'g', 'r', 'a', 'd', 'e', 'C', 'o', 'n', 'f', 'i', 'g', 'R', 
-'\016', 'u', 'p', 'g', 'r', 'a', 'd', 'e', 'C', 'o', 'n', 'f', 'i', 'g', 's', '\022', 'g', '\n', '\030', 'i', 'n', 't', 'e', 'r', 'n', 
-'a', 'l', '_', 'r', 'e', 'd', 'i', 'r', 'e', 'c', 't', '_', 'p', 'o', 'l', 'i', 'c', 'y', '\030', '\"', ' ', '\001', '(', '\013', '2', 
-'-', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'I', 
-'n', 't', 'e', 'r', 'n', 'a', 'l', 'R', 'e', 'd', 'i', 'r', 'e', 'c', 't', 'P', 'o', 'l', 'i', 'c', 'y', 'R', '\026', 'i', 'n', 
-'t', 'e', 'r', 'n', 'a', 'l', 'R', 'e', 'd', 'i', 'r', 'e', 'c', 't', 'P', 'o', 'l', 'i', 'c', 'y', '\022', '\200', '\001', '\n', '\030', 
-'i', 'n', 't', 'e', 'r', 'n', 'a', 'l', '_', 'r', 'e', 'd', 'i', 'r', 'e', 'c', 't', '_', 'a', 'c', 't', 'i', 'o', 'n', '\030', 
-'\032', ' ', '\001', '(', '\016', '2', '9', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 
-'e', '.', 'v', '3', '.', 'R', 'o', 'u', 't', 'e', 'A', 'c', 't', 'i', 'o', 'n', '.', 'I', 'n', 't', 'e', 'r', 'n', 'a', 'l', 
-'R', 'e', 'd', 'i', 'r', 'e', 'c', 't', 'A', 'c', 't', 'i', 'o', 'n', 'B', '\013', '\030', '\001', '\222', '\307', '\206', '\330', '\004', '\003', '3', 
-'.', '0', 'R', '\026', 'i', 'n', 't', 'e', 'r', 'n', 'a', 'l', 'R', 'e', 'd', 'i', 'r', 'e', 'c', 't', 'A', 'c', 't', 'i', 'o', 
-'n', '\022', '_', '\n', '\026', 'm', 'a', 'x', '_', 'i', 'n', 't', 'e', 'r', 'n', 'a', 'l', '_', 'r', 'e', 'd', 'i', 'r', 'e', 'c', 
-'t', 's', '\030', '\037', ' ', '\001', '(', '\013', '2', '\034', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 
-'f', '.', 'U', 'I', 'n', 't', '3', '2', 'V', 'a', 'l', 'u', 'e', 'B', '\013', '\030', '\001', '\222', '\307', '\206', '\330', '\004', '\003', '3', '.', 
-'0', 'R', '\024', 'm', 'a', 'x', 'I', 'n', 't', 'e', 'r', 'n', 'a', 'l', 'R', 'e', 'd', 'i', 'r', 'e', 'c', 't', 's', '\022', 'E', 
-'\n', '\014', 'h', 'e', 'd', 'g', 'e', '_', 'p', 'o', 'l', 'i', 'c', 'y', '\030', '\033', ' ', '\001', '(', '\013', '2', '\"', '.', 'e', 'n', 
-'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'H', 'e', 'd', 'g', 'e', 
-'P', 'o', 'l', 'i', 'c', 'y', 'R', '\013', 'h', 'e', 'd', 'g', 'e', 'P', 'o', 'l', 'i', 'c', 'y', '\022', 'd', '\n', '\023', 'm', 'a', 
-'x', '_', 's', 't', 'r', 'e', 'a', 'm', '_', 'd', 'u', 'r', 'a', 't', 'i', 'o', 'n', '\030', '$', ' ', '\001', '(', '\013', '2', '4', 
-'.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'R', 'o', 
-'u', 't', 'e', 'A', 'c', 't', 'i', 'o', 'n', '.', 'M', 'a', 'x', 'S', 't', 'r', 'e', 'a', 'm', 'D', 'u', 'r', 'a', 't', 'i', 
-'o', 'n', 'R', '\021', 'm', 'a', 'x', 'S', 't', 'r', 'e', 'a', 'm', 'D', 'u', 'r', 'a', 't', 'i', 'o', 'n', '\032', '\242', '\002', '\n', 
-'\023', 'R', 'e', 'q', 'u', 'e', 's', 't', 'M', 'i', 'r', 'r', 'o', 'r', 'P', 'o', 'l', 'i', 'c', 'y', '\022', '!', '\n', '\007', 'c', 
-'l', 'u', 's', 't', 'e', 'r', '\030', '\001', ' ', '\001', '(', '\t', 'B', '\007', '\372', 'B', '\004', 'r', '\002', '\020', '\001', 'R', '\007', 'c', 'l', 
-'u', 's', 't', 'e', 'r', '\022', 'Y', '\n', '\020', 'r', 'u', 'n', 't', 'i', 'm', 'e', '_', 'f', 'r', 'a', 'c', 't', 'i', 'o', 'n', 
-'\030', '\003', ' ', '\001', '(', '\013', '2', '.', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 
-'e', '.', 'v', '3', '.', 'R', 'u', 'n', 't', 'i', 'm', 'e', 'F', 'r', 'a', 'c', 't', 'i', 'o', 'n', 'a', 'l', 'P', 'e', 'r', 
-'c', 'e', 'n', 't', 'R', '\017', 'r', 'u', 'n', 't', 'i', 'm', 'e', 'F', 'r', 'a', 'c', 't', 'i', 'o', 'n', '\022', '?', '\n', '\r', 
-'t', 'r', 'a', 'c', 'e', '_', 's', 'a', 'm', 'p', 'l', 'e', 'd', '\030', '\004', ' ', '\001', '(', '\013', '2', '\032', '.', 'g', 'o', 'o', 
-'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'B', 'o', 'o', 'l', 'V', 'a', 'l', 'u', 'e', 'R', '\014', 't', 
-'r', 'a', 'c', 'e', 'S', 'a', 'm', 'p', 'l', 'e', 'd', ':', '9', '\232', '\305', '\210', '\036', '4', '\n', '2', 'e', 'n', 'v', 'o', 'y', 
-'.', 'a', 'p', 'i', '.', 'v', '2', '.', 'r', 'o', 'u', 't', 'e', '.', 'R', 'o', 'u', 't', 'e', 'A', 'c', 't', 'i', 'o', 'n', 
-'.', 'R', 'e', 'q', 'u', 'e', 's', 't', 'M', 'i', 'r', 'r', 'o', 'r', 'P', 'o', 'l', 'i', 'c', 'y', 'J', '\004', '\010', '\002', '\020', 
-'\003', 'R', '\013', 'r', 'u', 'n', 't', 'i', 'm', 'e', '_', 'k', 'e', 'y', '\032', '\226', '\n', '\n', '\n', 'H', 'a', 's', 'h', 'P', 'o', 
-'l', 'i', 'c', 'y', '\022', 'N', '\n', '\006', 'h', 'e', 'a', 'd', 'e', 'r', '\030', '\001', ' ', '\001', '(', '\013', '2', '4', '.', 'e', 'n', 
-'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'R', 'o', 'u', 't', 'e', 
-'A', 'c', 't', 'i', 'o', 'n', '.', 'H', 'a', 's', 'h', 'P', 'o', 'l', 'i', 'c', 'y', '.', 'H', 'e', 'a', 'd', 'e', 'r', 'H', 
-'\000', 'R', '\006', 'h', 'e', 'a', 'd', 'e', 'r', '\022', 'N', '\n', '\006', 'c', 'o', 'o', 'k', 'i', 'e', '\030', '\002', ' ', '\001', '(', '\013', 
-'2', '4', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 
-'R', 'o', 'u', 't', 'e', 'A', 'c', 't', 'i', 'o', 'n', '.', 'H', 'a', 's', 'h', 'P', 'o', 'l', 'i', 'c', 'y', '.', 'C', 'o', 
-'o', 'k', 'i', 'e', 'H', '\000', 'R', '\006', 'c', 'o', 'o', 'k', 'i', 'e', '\022', 'y', '\n', '\025', 'c', 'o', 'n', 'n', 'e', 'c', 't', 
-'i', 'o', 'n', '_', 'p', 'r', 'o', 'p', 'e', 'r', 't', 'i', 'e', 's', '\030', '\003', ' ', '\001', '(', '\013', '2', 'B', '.', 'e', 'n', 
-'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'R', 'o', 'u', 't', 'e', 
-'A', 'c', 't', 'i', 'o', 'n', '.', 'H', 'a', 's', 'h', 'P', 'o', 'l', 'i', 'c', 'y', '.', 'C', 'o', 'n', 'n', 'e', 'c', 't', 
-'i', 'o', 'n', 'P', 'r', 'o', 'p', 'e', 'r', 't', 'i', 'e', 's', 'H', '\000', 'R', '\024', 'c', 'o', 'n', 'n', 'e', 'c', 't', 'i', 
-'o', 'n', 'P', 'r', 'o', 'p', 'e', 'r', 't', 'i', 'e', 's', '\022', 'g', '\n', '\017', 'q', 'u', 'e', 'r', 'y', '_', 'p', 'a', 'r', 
-'a', 'm', 'e', 't', 'e', 'r', '\030', '\005', ' ', '\001', '(', '\013', '2', '<', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 
-'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'R', 'o', 'u', 't', 'e', 'A', 'c', 't', 'i', 'o', 'n', '.', 'H', 
-'a', 's', 'h', 'P', 'o', 'l', 'i', 'c', 'y', '.', 'Q', 'u', 'e', 'r', 'y', 'P', 'a', 'r', 'a', 'm', 'e', 't', 'e', 'r', 'H', 
-'\000', 'R', '\016', 'q', 'u', 'e', 'r', 'y', 'P', 'a', 'r', 'a', 'm', 'e', 't', 'e', 'r', '\022', '^', '\n', '\014', 'f', 'i', 'l', 't', 
-'e', 'r', '_', 's', 't', 'a', 't', 'e', '\030', '\006', ' ', '\001', '(', '\013', '2', '9', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 
+'n', '.', 'U', 'p', 'g', 'r', 'a', 'd', 'e', 'C', 'o', 'n', 'f', 'i', 'g', 'R', '\016', 'u', 'p', 'g', 'r', 'a', 'd', 'e', 'C', 
+'o', 'n', 'f', 'i', 'g', 's', '\022', 'g', '\n', '\030', 'i', 'n', 't', 'e', 'r', 'n', 'a', 'l', '_', 'r', 'e', 'd', 'i', 'r', 'e', 
+'c', 't', '_', 'p', 'o', 'l', 'i', 'c', 'y', '\030', '\"', ' ', '\001', '(', '\013', '2', '-', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 
+'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'I', 'n', 't', 'e', 'r', 'n', 'a', 'l', 'R', 'e', 
+'d', 'i', 'r', 'e', 'c', 't', 'P', 'o', 'l', 'i', 'c', 'y', 'R', '\026', 'i', 'n', 't', 'e', 'r', 'n', 'a', 'l', 'R', 'e', 'd', 
+'i', 'r', 'e', 'c', 't', 'P', 'o', 'l', 'i', 'c', 'y', '\022', '\200', '\001', '\n', '\030', 'i', 'n', 't', 'e', 'r', 'n', 'a', 'l', '_', 
+'r', 'e', 'd', 'i', 'r', 'e', 'c', 't', '_', 'a', 'c', 't', 'i', 'o', 'n', '\030', '\032', ' ', '\001', '(', '\016', '2', '9', '.', 'e', 
+'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'R', 'o', 'u', 't', 
+'e', 'A', 'c', 't', 'i', 'o', 'n', '.', 'I', 'n', 't', 'e', 'r', 'n', 'a', 'l', 'R', 'e', 'd', 'i', 'r', 'e', 'c', 't', 'A', 
+'c', 't', 'i', 'o', 'n', 'B', '\013', '\030', '\001', '\222', '\307', '\206', '\330', '\004', '\003', '3', '.', '0', 'R', '\026', 'i', 'n', 't', 'e', 'r', 
+'n', 'a', 'l', 'R', 'e', 'd', 'i', 'r', 'e', 'c', 't', 'A', 'c', 't', 'i', 'o', 'n', '\022', '_', '\n', '\026', 'm', 'a', 'x', '_', 
+'i', 'n', 't', 'e', 'r', 'n', 'a', 'l', '_', 'r', 'e', 'd', 'i', 'r', 'e', 'c', 't', 's', '\030', '\037', ' ', '\001', '(', '\013', '2', 
+'\034', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'U', 'I', 'n', 't', '3', '2', 'V', 
+'a', 'l', 'u', 'e', 'B', '\013', '\030', '\001', '\222', '\307', '\206', '\330', '\004', '\003', '3', '.', '0', 'R', '\024', 'm', 'a', 'x', 'I', 'n', 't', 
+'e', 'r', 'n', 'a', 'l', 'R', 'e', 'd', 'i', 'r', 'e', 'c', 't', 's', '\022', 'E', '\n', '\014', 'h', 'e', 'd', 'g', 'e', '_', 'p', 
+'o', 'l', 'i', 'c', 'y', '\030', '\033', ' ', '\001', '(', '\013', '2', '\"', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 
+'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'H', 'e', 'd', 'g', 'e', 'P', 'o', 'l', 'i', 'c', 'y', 'R', '\013', 'h', 
+'e', 'd', 'g', 'e', 'P', 'o', 'l', 'i', 'c', 'y', '\022', 'd', '\n', '\023', 'm', 'a', 'x', '_', 's', 't', 'r', 'e', 'a', 'm', '_', 
+'d', 'u', 'r', 'a', 't', 'i', 'o', 'n', '\030', '$', ' ', '\001', '(', '\013', '2', '4', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 
 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'R', 'o', 'u', 't', 'e', 'A', 'c', 't', 'i', 'o', 'n', 
-'.', 'H', 'a', 's', 'h', 'P', 'o', 'l', 'i', 'c', 'y', '.', 'F', 'i', 'l', 't', 'e', 'r', 'S', 't', 'a', 't', 'e', 'H', '\000', 
-'R', '\013', 'f', 'i', 'l', 't', 'e', 'r', 'S', 't', 'a', 't', 'e', '\022', '\032', '\n', '\010', 't', 'e', 'r', 'm', 'i', 'n', 'a', 'l', 
-'\030', '\004', ' ', '\001', '(', '\010', 'R', '\010', 't', 'e', 'r', 'm', 'i', 'n', 'a', 'l', '\032', '\306', '\001', '\n', '\006', 'H', 'e', 'a', 'd', 
-'e', 'r', '\022', '.', '\n', '\013', 'h', 'e', 'a', 'd', 'e', 'r', '_', 'n', 'a', 'm', 'e', '\030', '\001', ' ', '\001', '(', '\t', 'B', '\r', 
-'\372', 'B', '\n', 'r', '\010', '\020', '\001', '\300', '\001', '\001', '\310', '\001', '\000', 'R', '\n', 'h', 'e', 'a', 'd', 'e', 'r', 'N', 'a', 'm', 'e', 
-'\022', 'S', '\n', '\r', 'r', 'e', 'g', 'e', 'x', '_', 'r', 'e', 'w', 'r', 'i', 't', 'e', '\030', '\002', ' ', '\001', '(', '\013', '2', '.', 
-'.', 'e', 'n', 'v', 'o', 'y', '.', 't', 'y', 'p', 'e', '.', 'm', 'a', 't', 'c', 'h', 'e', 'r', '.', 'v', '3', '.', 'R', 'e', 
-'g', 'e', 'x', 'M', 'a', 't', 'c', 'h', 'A', 'n', 'd', 'S', 'u', 'b', 's', 't', 'i', 't', 'u', 't', 'e', 'R', '\014', 'r', 'e', 
-'g', 'e', 'x', 'R', 'e', 'w', 'r', 'i', 't', 'e', ':', '7', '\232', '\305', '\210', '\036', '2', '\n', '0', 'e', 'n', 'v', 'o', 'y', '.', 
+'.', 'M', 'a', 'x', 'S', 't', 'r', 'e', 'a', 'm', 'D', 'u', 'r', 'a', 't', 'i', 'o', 'n', 'R', '\021', 'm', 'a', 'x', 'S', 't', 
+'r', 'e', 'a', 'm', 'D', 'u', 'r', 'a', 't', 'i', 'o', 'n', '\032', '\242', '\002', '\n', '\023', 'R', 'e', 'q', 'u', 'e', 's', 't', 'M', 
+'i', 'r', 'r', 'o', 'r', 'P', 'o', 'l', 'i', 'c', 'y', '\022', '!', '\n', '\007', 'c', 'l', 'u', 's', 't', 'e', 'r', '\030', '\001', ' ', 
+'\001', '(', '\t', 'B', '\007', '\372', 'B', '\004', 'r', '\002', '\020', '\001', 'R', '\007', 'c', 'l', 'u', 's', 't', 'e', 'r', '\022', 'Y', '\n', '\020', 
+'r', 'u', 'n', 't', 'i', 'm', 'e', '_', 'f', 'r', 'a', 'c', 't', 'i', 'o', 'n', '\030', '\003', ' ', '\001', '(', '\013', '2', '.', '.', 
+'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'R', 'u', 'n', 't', 
+'i', 'm', 'e', 'F', 'r', 'a', 'c', 't', 'i', 'o', 'n', 'a', 'l', 'P', 'e', 'r', 'c', 'e', 'n', 't', 'R', '\017', 'r', 'u', 'n', 
+'t', 'i', 'm', 'e', 'F', 'r', 'a', 'c', 't', 'i', 'o', 'n', '\022', '?', '\n', '\r', 't', 'r', 'a', 'c', 'e', '_', 's', 'a', 'm', 
+'p', 'l', 'e', 'd', '\030', '\004', ' ', '\001', '(', '\013', '2', '\032', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 
+'b', 'u', 'f', '.', 'B', 'o', 'o', 'l', 'V', 'a', 'l', 'u', 'e', 'R', '\014', 't', 'r', 'a', 'c', 'e', 'S', 'a', 'm', 'p', 'l', 
+'e', 'd', ':', '9', '\232', '\305', '\210', '\036', '4', '\n', '2', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'r', 
+'o', 'u', 't', 'e', '.', 'R', 'o', 'u', 't', 'e', 'A', 'c', 't', 'i', 'o', 'n', '.', 'R', 'e', 'q', 'u', 'e', 's', 't', 'M', 
+'i', 'r', 'r', 'o', 'r', 'P', 'o', 'l', 'i', 'c', 'y', 'J', '\004', '\010', '\002', '\020', '\003', 'R', '\013', 'r', 'u', 'n', 't', 'i', 'm', 
+'e', '_', 'k', 'e', 'y', '\032', '\226', '\n', '\n', '\n', 'H', 'a', 's', 'h', 'P', 'o', 'l', 'i', 'c', 'y', '\022', 'N', '\n', '\006', 'h', 
+'e', 'a', 'd', 'e', 'r', '\030', '\001', ' ', '\001', '(', '\013', '2', '4', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 
+'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'R', 'o', 'u', 't', 'e', 'A', 'c', 't', 'i', 'o', 'n', '.', 'H', 'a', 
+'s', 'h', 'P', 'o', 'l', 'i', 'c', 'y', '.', 'H', 'e', 'a', 'd', 'e', 'r', 'H', '\000', 'R', '\006', 'h', 'e', 'a', 'd', 'e', 'r', 
+'\022', 'N', '\n', '\006', 'c', 'o', 'o', 'k', 'i', 'e', '\030', '\002', ' ', '\001', '(', '\013', '2', '4', '.', 'e', 'n', 'v', 'o', 'y', '.', 
+'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'R', 'o', 'u', 't', 'e', 'A', 'c', 't', 'i', 
+'o', 'n', '.', 'H', 'a', 's', 'h', 'P', 'o', 'l', 'i', 'c', 'y', '.', 'C', 'o', 'o', 'k', 'i', 'e', 'H', '\000', 'R', '\006', 'c', 
+'o', 'o', 'k', 'i', 'e', '\022', 'y', '\n', '\025', 'c', 'o', 'n', 'n', 'e', 'c', 't', 'i', 'o', 'n', '_', 'p', 'r', 'o', 'p', 'e', 
+'r', 't', 'i', 'e', 's', '\030', '\003', ' ', '\001', '(', '\013', '2', 'B', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 
+'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'R', 'o', 'u', 't', 'e', 'A', 'c', 't', 'i', 'o', 'n', '.', 'H', 'a', 
+'s', 'h', 'P', 'o', 'l', 'i', 'c', 'y', '.', 'C', 'o', 'n', 'n', 'e', 'c', 't', 'i', 'o', 'n', 'P', 'r', 'o', 'p', 'e', 'r', 
+'t', 'i', 'e', 's', 'H', '\000', 'R', '\024', 'c', 'o', 'n', 'n', 'e', 'c', 't', 'i', 'o', 'n', 'P', 'r', 'o', 'p', 'e', 'r', 't', 
+'i', 'e', 's', '\022', 'g', '\n', '\017', 'q', 'u', 'e', 'r', 'y', '_', 'p', 'a', 'r', 'a', 'm', 'e', 't', 'e', 'r', '\030', '\005', ' ', 
+'\001', '(', '\013', '2', '<', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 
+'v', '3', '.', 'R', 'o', 'u', 't', 'e', 'A', 'c', 't', 'i', 'o', 'n', '.', 'H', 'a', 's', 'h', 'P', 'o', 'l', 'i', 'c', 'y', 
+'.', 'Q', 'u', 'e', 'r', 'y', 'P', 'a', 'r', 'a', 'm', 'e', 't', 'e', 'r', 'H', '\000', 'R', '\016', 'q', 'u', 'e', 'r', 'y', 'P', 
+'a', 'r', 'a', 'm', 'e', 't', 'e', 'r', '\022', '^', '\n', '\014', 'f', 'i', 'l', 't', 'e', 'r', '_', 's', 't', 'a', 't', 'e', '\030', 
+'\006', ' ', '\001', '(', '\013', '2', '9', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 
+'e', '.', 'v', '3', '.', 'R', 'o', 'u', 't', 'e', 'A', 'c', 't', 'i', 'o', 'n', '.', 'H', 'a', 's', 'h', 'P', 'o', 'l', 'i', 
+'c', 'y', '.', 'F', 'i', 'l', 't', 'e', 'r', 'S', 't', 'a', 't', 'e', 'H', '\000', 'R', '\013', 'f', 'i', 'l', 't', 'e', 'r', 'S', 
+'t', 'a', 't', 'e', '\022', '\032', '\n', '\010', 't', 'e', 'r', 'm', 'i', 'n', 'a', 'l', '\030', '\004', ' ', '\001', '(', '\010', 'R', '\010', 't', 
+'e', 'r', 'm', 'i', 'n', 'a', 'l', '\032', '\306', '\001', '\n', '\006', 'H', 'e', 'a', 'd', 'e', 'r', '\022', '.', '\n', '\013', 'h', 'e', 'a', 
+'d', 'e', 'r', '_', 'n', 'a', 'm', 'e', '\030', '\001', ' ', '\001', '(', '\t', 'B', '\r', '\372', 'B', '\n', 'r', '\010', '\020', '\001', '\300', '\001', 
+'\001', '\310', '\001', '\000', 'R', '\n', 'h', 'e', 'a', 'd', 'e', 'r', 'N', 'a', 'm', 'e', '\022', 'S', '\n', '\r', 'r', 'e', 'g', 'e', 'x', 
+'_', 'r', 'e', 'w', 'r', 'i', 't', 'e', '\030', '\002', ' ', '\001', '(', '\013', '2', '.', '.', 'e', 'n', 'v', 'o', 'y', '.', 't', 'y', 
+'p', 'e', '.', 'm', 'a', 't', 'c', 'h', 'e', 'r', '.', 'v', '3', '.', 'R', 'e', 'g', 'e', 'x', 'M', 'a', 't', 'c', 'h', 'A', 
+'n', 'd', 'S', 'u', 'b', 's', 't', 'i', 't', 'u', 't', 'e', 'R', '\014', 'r', 'e', 'g', 'e', 'x', 'R', 'e', 'w', 'r', 'i', 't', 
+'e', ':', '7', '\232', '\305', '\210', '\036', '2', '\n', '0', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'r', 'o', 
+'u', 't', 'e', '.', 'R', 'o', 'u', 't', 'e', 'A', 'c', 't', 'i', 'o', 'n', '.', 'H', 'a', 's', 'h', 'P', 'o', 'l', 'i', 'c', 
+'y', '.', 'H', 'e', 'a', 'd', 'e', 'r', '\032', '\237', '\001', '\n', '\006', 'C', 'o', 'o', 'k', 'i', 'e', '\022', '\033', '\n', '\004', 'n', 'a', 
+'m', 'e', '\030', '\001', ' ', '\001', '(', '\t', 'B', '\007', '\372', 'B', '\004', 'r', '\002', '\020', '\001', 'R', '\004', 'n', 'a', 'm', 'e', '\022', '+', 
+'\n', '\003', 't', 't', 'l', '\030', '\002', ' ', '\001', '(', '\013', '2', '\031', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 
+'o', 'b', 'u', 'f', '.', 'D', 'u', 'r', 'a', 't', 'i', 'o', 'n', 'R', '\003', 't', 't', 'l', '\022', '\022', '\n', '\004', 'p', 'a', 't', 
+'h', '\030', '\003', ' ', '\001', '(', '\t', 'R', '\004', 'p', 'a', 't', 'h', ':', '7', '\232', '\305', '\210', '\036', '2', '\n', '0', 'e', 'n', 'v', 
+'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'r', 'o', 'u', 't', 'e', '.', 'R', 'o', 'u', 't', 'e', 'A', 'c', 't', 'i', 
+'o', 'n', '.', 'H', 'a', 's', 'h', 'P', 'o', 'l', 'i', 'c', 'y', '.', 'C', 'o', 'o', 'k', 'i', 'e', '\032', 'z', '\n', '\024', 'C', 
+'o', 'n', 'n', 'e', 'c', 't', 'i', 'o', 'n', 'P', 'r', 'o', 'p', 'e', 'r', 't', 'i', 'e', 's', '\022', '\033', '\n', '\t', 's', 'o', 
+'u', 'r', 'c', 'e', '_', 'i', 'p', '\030', '\001', ' ', '\001', '(', '\010', 'R', '\010', 's', 'o', 'u', 'r', 'c', 'e', 'I', 'p', ':', 'E', 
+'\232', '\305', '\210', '\036', '@', '\n', '>', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'r', 'o', 'u', 't', 'e', 
+'.', 'R', 'o', 'u', 't', 'e', 'A', 'c', 't', 'i', 'o', 'n', '.', 'H', 'a', 's', 'h', 'P', 'o', 'l', 'i', 'c', 'y', '.', 'C', 
+'o', 'n', 'n', 'e', 'c', 't', 'i', 'o', 'n', 'P', 'r', 'o', 'p', 'e', 'r', 't', 'i', 'e', 's', '\032', 'n', '\n', '\016', 'Q', 'u', 
+'e', 'r', 'y', 'P', 'a', 'r', 'a', 'm', 'e', 't', 'e', 'r', '\022', '\033', '\n', '\004', 'n', 'a', 'm', 'e', '\030', '\001', ' ', '\001', '(', 
+'\t', 'B', '\007', '\372', 'B', '\004', 'r', '\002', '\020', '\001', 'R', '\004', 'n', 'a', 'm', 'e', ':', '?', '\232', '\305', '\210', '\036', ':', '\n', '8', 
+'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'r', 'o', 'u', 't', 'e', '.', 'R', 'o', 'u', 't', 'e', 'A', 
+'c', 't', 'i', 'o', 'n', '.', 'H', 'a', 's', 'h', 'P', 'o', 'l', 'i', 'c', 'y', '.', 'Q', 'u', 'e', 'r', 'y', 'P', 'a', 'r', 
+'a', 'm', 'e', 't', 'e', 'r', '\032', 'f', '\n', '\013', 'F', 'i', 'l', 't', 'e', 'r', 'S', 't', 'a', 't', 'e', '\022', '\031', '\n', '\003', 
+'k', 'e', 'y', '\030', '\001', ' ', '\001', '(', '\t', 'B', '\007', '\372', 'B', '\004', 'r', '\002', '\020', '\001', 'R', '\003', 'k', 'e', 'y', ':', '<', 
+'\232', '\305', '\210', '\036', '7', '\n', '5', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'r', 'o', 'u', 't', 'e', 
+'.', 'R', 'o', 'u', 't', 'e', 'A', 'c', 't', 'i', 'o', 'n', '.', 'H', 'a', 's', 'h', 'P', 'o', 'l', 'i', 'c', 'y', '.', 'F', 
+'i', 'l', 't', 'e', 'r', 'S', 't', 'a', 't', 'e', ':', '0', '\232', '\305', '\210', '\036', '+', '\n', ')', 'e', 'n', 'v', 'o', 'y', '.', 
 'a', 'p', 'i', '.', 'v', '2', '.', 'r', 'o', 'u', 't', 'e', '.', 'R', 'o', 'u', 't', 'e', 'A', 'c', 't', 'i', 'o', 'n', '.', 
-'H', 'a', 's', 'h', 'P', 'o', 'l', 'i', 'c', 'y', '.', 'H', 'e', 'a', 'd', 'e', 'r', '\032', '\237', '\001', '\n', '\006', 'C', 'o', 'o', 
-'k', 'i', 'e', '\022', '\033', '\n', '\004', 'n', 'a', 'm', 'e', '\030', '\001', ' ', '\001', '(', '\t', 'B', '\007', '\372', 'B', '\004', 'r', '\002', '\020', 
-'\001', 'R', '\004', 'n', 'a', 'm', 'e', '\022', '+', '\n', '\003', 't', 't', 'l', '\030', '\002', ' ', '\001', '(', '\013', '2', '\031', '.', 'g', 'o', 
-'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'D', 'u', 'r', 'a', 't', 'i', 'o', 'n', 'R', '\003', 't', 
-'t', 'l', '\022', '\022', '\n', '\004', 'p', 'a', 't', 'h', '\030', '\003', ' ', '\001', '(', '\t', 'R', '\004', 'p', 'a', 't', 'h', ':', '7', '\232', 
-'\305', '\210', '\036', '2', '\n', '0', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'r', 'o', 'u', 't', 'e', '.', 
-'R', 'o', 'u', 't', 'e', 'A', 'c', 't', 'i', 'o', 'n', '.', 'H', 'a', 's', 'h', 'P', 'o', 'l', 'i', 'c', 'y', '.', 'C', 'o', 
-'o', 'k', 'i', 'e', '\032', 'z', '\n', '\024', 'C', 'o', 'n', 'n', 'e', 'c', 't', 'i', 'o', 'n', 'P', 'r', 'o', 'p', 'e', 'r', 't', 
-'i', 'e', 's', '\022', '\033', '\n', '\t', 's', 'o', 'u', 'r', 'c', 'e', '_', 'i', 'p', '\030', '\001', ' ', '\001', '(', '\010', 'R', '\010', 's', 
-'o', 'u', 'r', 'c', 'e', 'I', 'p', ':', 'E', '\232', '\305', '\210', '\036', '@', '\n', '>', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', 
-'.', 'v', '2', '.', 'r', 'o', 'u', 't', 'e', '.', 'R', 'o', 'u', 't', 'e', 'A', 'c', 't', 'i', 'o', 'n', '.', 'H', 'a', 's', 
-'h', 'P', 'o', 'l', 'i', 'c', 'y', '.', 'C', 'o', 'n', 'n', 'e', 'c', 't', 'i', 'o', 'n', 'P', 'r', 'o', 'p', 'e', 'r', 't', 
-'i', 'e', 's', '\032', 'n', '\n', '\016', 'Q', 'u', 'e', 'r', 'y', 'P', 'a', 'r', 'a', 'm', 'e', 't', 'e', 'r', '\022', '\033', '\n', '\004', 
+'H', 'a', 's', 'h', 'P', 'o', 'l', 'i', 'c', 'y', 'B', '\027', '\n', '\020', 'p', 'o', 'l', 'i', 'c', 'y', '_', 's', 'p', 'e', 'c', 
+'i', 'f', 'i', 'e', 'r', '\022', '\003', '\370', 'B', '\001', '\032', '\243', '\003', '\n', '\r', 'U', 'p', 'g', 'r', 'a', 'd', 'e', 'C', 'o', 'n', 
+'f', 'i', 'g', '\022', '0', '\n', '\014', 'u', 'p', 'g', 'r', 'a', 'd', 'e', '_', 't', 'y', 'p', 'e', '\030', '\001', ' ', '\001', '(', '\t', 
+'B', '\r', '\372', 'B', '\n', 'r', '\010', '\020', '\001', '\300', '\001', '\002', '\310', '\001', '\000', 'R', '\013', 'u', 'p', 'g', 'r', 'a', 'd', 'e', 'T', 
+'y', 'p', 'e', '\022', '4', '\n', '\007', 'e', 'n', 'a', 'b', 'l', 'e', 'd', '\030', '\002', ' ', '\001', '(', '\013', '2', '\032', '.', 'g', 'o', 
+'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'B', 'o', 'o', 'l', 'V', 'a', 'l', 'u', 'e', 'R', '\007', 
+'e', 'n', 'a', 'b', 'l', 'e', 'd', '\022', 'e', '\n', '\016', 'c', 'o', 'n', 'n', 'e', 'c', 't', '_', 'c', 'o', 'n', 'f', 'i', 'g', 
+'\030', '\003', ' ', '\001', '(', '\013', '2', '>', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 
+'t', 'e', '.', 'v', '3', '.', 'R', 'o', 'u', 't', 'e', 'A', 'c', 't', 'i', 'o', 'n', '.', 'U', 'p', 'g', 'r', 'a', 'd', 'e', 
+'C', 'o', 'n', 'f', 'i', 'g', '.', 'C', 'o', 'n', 'n', 'e', 'c', 't', 'C', 'o', 'n', 'f', 'i', 'g', 'R', '\r', 'c', 'o', 'n', 
+'n', 'e', 'c', 't', 'C', 'o', 'n', 'f', 'i', 'g', '\032', '\215', '\001', '\n', '\r', 'C', 'o', 'n', 'n', 'e', 'c', 't', 'C', 'o', 'n', 
+'f', 'i', 'g', '\022', ']', '\n', '\025', 'p', 'r', 'o', 'x', 'y', '_', 'p', 'r', 'o', 't', 'o', 'c', 'o', 'l', '_', 'c', 'o', 'n', 
+'f', 'i', 'g', '\030', '\001', ' ', '\001', '(', '\013', '2', ')', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 
+'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'P', 'r', 'o', 'x', 'y', 'P', 'r', 'o', 't', 'o', 'c', 'o', 'l', 'C', 'o', 'n', 'f', 
+'i', 'g', 'R', '\023', 'p', 'r', 'o', 'x', 'y', 'P', 'r', 'o', 't', 'o', 'c', 'o', 'l', 'C', 'o', 'n', 'f', 'i', 'g', '\022', '\035', 
+'\n', '\n', 'a', 'l', 'l', 'o', 'w', '_', 'p', 'o', 's', 't', '\030', '\002', ' ', '\001', '(', '\010', 'R', '\t', 'a', 'l', 'l', 'o', 'w', 
+'P', 'o', 's', 't', ':', '3', '\232', '\305', '\210', '\036', '.', '\n', ',', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', 
+'.', 'r', 'o', 'u', 't', 'e', '.', 'R', 'o', 'u', 't', 'e', 'A', 'c', 't', 'i', 'o', 'n', '.', 'U', 'p', 'g', 'r', 'a', 'd', 
+'e', 'C', 'o', 'n', 'f', 'i', 'g', '\032', '\210', '\002', '\n', '\021', 'M', 'a', 'x', 'S', 't', 'r', 'e', 'a', 'm', 'D', 'u', 'r', 'a', 
+'t', 'i', 'o', 'n', '\022', 'I', '\n', '\023', 'm', 'a', 'x', '_', 's', 't', 'r', 'e', 'a', 'm', '_', 'd', 'u', 'r', 'a', 't', 'i', 
+'o', 'n', '\030', '\001', ' ', '\001', '(', '\013', '2', '\031', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 
+'f', '.', 'D', 'u', 'r', 'a', 't', 'i', 'o', 'n', 'R', '\021', 'm', 'a', 'x', 'S', 't', 'r', 'e', 'a', 'm', 'D', 'u', 'r', 'a', 
+'t', 'i', 'o', 'n', '\022', 'P', '\n', '\027', 'g', 'r', 'p', 'c', '_', 't', 'i', 'm', 'e', 'o', 'u', 't', '_', 'h', 'e', 'a', 'd', 
+'e', 'r', '_', 'm', 'a', 'x', '\030', '\002', ' ', '\001', '(', '\013', '2', '\031', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 
+'t', 'o', 'b', 'u', 'f', '.', 'D', 'u', 'r', 'a', 't', 'i', 'o', 'n', 'R', '\024', 'g', 'r', 'p', 'c', 'T', 'i', 'm', 'e', 'o', 
+'u', 't', 'H', 'e', 'a', 'd', 'e', 'r', 'M', 'a', 'x', '\022', 'V', '\n', '\032', 'g', 'r', 'p', 'c', '_', 't', 'i', 'm', 'e', 'o', 
+'u', 't', '_', 'h', 'e', 'a', 'd', 'e', 'r', '_', 'o', 'f', 'f', 's', 'e', 't', '\030', '\003', ' ', '\001', '(', '\013', '2', '\031', '.', 
+'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'D', 'u', 'r', 'a', 't', 'i', 'o', 'n', 'R', 
+'\027', 'g', 'r', 'p', 'c', 'T', 'i', 'm', 'e', 'o', 'u', 't', 'H', 'e', 'a', 'd', 'e', 'r', 'O', 'f', 'f', 's', 'e', 't', '\"', 
+'E', '\n', '\033', 'C', 'l', 'u', 's', 't', 'e', 'r', 'N', 'o', 't', 'F', 'o', 'u', 'n', 'd', 'R', 'e', 's', 'p', 'o', 'n', 's', 
+'e', 'C', 'o', 'd', 'e', '\022', '\027', '\n', '\023', 'S', 'E', 'R', 'V', 'I', 'C', 'E', '_', 'U', 'N', 'A', 'V', 'A', 'I', 'L', 'A', 
+'B', 'L', 'E', '\020', '\000', '\022', '\r', '\n', '\t', 'N', 'O', 'T', '_', 'F', 'O', 'U', 'N', 'D', '\020', '\001', '\"', '^', '\n', '\026', 'I', 
+'n', 't', 'e', 'r', 'n', 'a', 'l', 'R', 'e', 'd', 'i', 'r', 'e', 'c', 't', 'A', 'c', 't', 'i', 'o', 'n', '\022', '\"', '\n', '\036', 
+'P', 'A', 'S', 'S', '_', 'T', 'H', 'R', 'O', 'U', 'G', 'H', '_', 'I', 'N', 'T', 'E', 'R', 'N', 'A', 'L', '_', 'R', 'E', 'D', 
+'I', 'R', 'E', 'C', 'T', '\020', '\000', '\022', '\034', '\n', '\030', 'H', 'A', 'N', 'D', 'L', 'E', '_', 'I', 'N', 'T', 'E', 'R', 'N', 'A', 
+'L', '_', 'R', 'E', 'D', 'I', 'R', 'E', 'C', 'T', '\020', '\001', '\032', '\002', '\030', '\001', ':', '%', '\232', '\305', '\210', '\036', ' ', '\n', '\036', 
+'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'r', 'o', 'u', 't', 'e', '.', 'R', 'o', 'u', 't', 'e', 'A', 
+'c', 't', 'i', 'o', 'n', 'B', '\030', '\n', '\021', 'c', 'l', 'u', 's', 't', 'e', 'r', '_', 's', 'p', 'e', 'c', 'i', 'f', 'i', 'e', 
+'r', '\022', '\003', '\370', 'B', '\001', 'B', '\030', '\n', '\026', 'h', 'o', 's', 't', '_', 'r', 'e', 'w', 'r', 'i', 't', 'e', '_', 's', 'p', 
+'e', 'c', 'i', 'f', 'i', 'e', 'r', 'J', '\004', '\010', '\014', '\020', '\r', 'J', '\004', '\010', '\022', '\020', '\023', 'J', '\004', '\010', '\023', '\020', '\024', 
+'J', '\004', '\010', '\020', '\020', '\021', 'J', '\004', '\010', '\026', '\020', '\027', 'J', '\004', '\010', '\025', '\020', '\026', 'J', '\004', '\010', '\n', '\020', '\013', 'R', 
+'\025', 'r', 'e', 'q', 'u', 'e', 's', 't', '_', 'm', 'i', 'r', 'r', 'o', 'r', '_', 'p', 'o', 'l', 'i', 'c', 'y', '\"', '\215', '\017', 
+'\n', '\013', 'R', 'e', 't', 'r', 'y', 'P', 'o', 'l', 'i', 'c', 'y', '\022', '\031', '\n', '\010', 'r', 'e', 't', 'r', 'y', '_', 'o', 'n', 
+'\030', '\001', ' ', '\001', '(', '\t', 'R', '\007', 'r', 'e', 't', 'r', 'y', 'O', 'n', '\022', 'R', '\n', '\013', 'n', 'u', 'm', '_', 'r', 'e', 
+'t', 'r', 'i', 'e', 's', '\030', '\002', ' ', '\001', '(', '\013', '2', '\034', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 
+'o', 'b', 'u', 'f', '.', 'U', 'I', 'n', 't', '3', '2', 'V', 'a', 'l', 'u', 'e', 'B', '\023', '\362', '\230', '\376', '\217', '\005', '\r', '\n', 
+'\013', 'm', 'a', 'x', '_', 'r', 'e', 't', 'r', 'i', 'e', 's', 'R', '\n', 'n', 'u', 'm', 'R', 'e', 't', 'r', 'i', 'e', 's', '\022', 
+'A', '\n', '\017', 'p', 'e', 'r', '_', 't', 'r', 'y', '_', 't', 'i', 'm', 'e', 'o', 'u', 't', '\030', '\003', ' ', '\001', '(', '\013', '2', 
+'\031', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'D', 'u', 'r', 'a', 't', 'i', 'o', 
+'n', 'R', '\r', 'p', 'e', 'r', 'T', 'r', 'y', 'T', 'i', 'm', 'e', 'o', 'u', 't', '\022', 'W', '\n', '\016', 'r', 'e', 't', 'r', 'y', 
+'_', 'p', 'r', 'i', 'o', 'r', 'i', 't', 'y', '\030', '\004', ' ', '\001', '(', '\013', '2', '0', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 
+'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'R', 'e', 't', 'r', 'y', 'P', 'o', 'l', 'i', 'c', 
+'y', '.', 'R', 'e', 't', 'r', 'y', 'P', 'r', 'i', 'o', 'r', 'i', 't', 'y', 'R', '\r', 'r', 'e', 't', 'r', 'y', 'P', 'r', 'i', 
+'o', 'r', 'i', 't', 'y', '\022', 'g', '\n', '\024', 'r', 'e', 't', 'r', 'y', '_', 'h', 'o', 's', 't', '_', 'p', 'r', 'e', 'd', 'i', 
+'c', 'a', 't', 'e', '\030', '\005', ' ', '\003', '(', '\013', '2', '5', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', 
+'.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'R', 'e', 't', 'r', 'y', 'P', 'o', 'l', 'i', 'c', 'y', '.', 'R', 'e', 't', 
+'r', 'y', 'H', 'o', 's', 't', 'P', 'r', 'e', 'd', 'i', 'c', 'a', 't', 'e', 'R', '\022', 'r', 'e', 't', 'r', 'y', 'H', 'o', 's', 
+'t', 'P', 'r', 'e', 'd', 'i', 'c', 'a', 't', 'e', '\022', 'H', '\n', '!', 'h', 'o', 's', 't', '_', 's', 'e', 'l', 'e', 'c', 't', 
+'i', 'o', 'n', '_', 'r', 'e', 't', 'r', 'y', '_', 'm', 'a', 'x', '_', 'a', 't', 't', 'e', 'm', 'p', 't', 's', '\030', '\006', ' ', 
+'\001', '(', '\003', 'R', '\035', 'h', 'o', 's', 't', 'S', 'e', 'l', 'e', 'c', 't', 'i', 'o', 'n', 'R', 'e', 't', 'r', 'y', 'M', 'a', 
+'x', 'A', 't', 't', 'e', 'm', 'p', 't', 's', '\022', '4', '\n', '\026', 'r', 'e', 't', 'r', 'i', 'a', 'b', 'l', 'e', '_', 's', 't', 
+'a', 't', 'u', 's', '_', 'c', 'o', 'd', 'e', 's', '\030', '\007', ' ', '\003', '(', '\r', 'R', '\024', 'r', 'e', 't', 'r', 'i', 'a', 'b', 
+'l', 'e', 'S', 't', 'a', 't', 'u', 's', 'C', 'o', 'd', 'e', 's', '\022', 'U', '\n', '\016', 'r', 'e', 't', 'r', 'y', '_', 'b', 'a', 
+'c', 'k', '_', 'o', 'f', 'f', '\030', '\010', ' ', '\001', '(', '\013', '2', '/', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 
+'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'R', 'e', 't', 'r', 'y', 'P', 'o', 'l', 'i', 'c', 'y', '.', 'R', 
+'e', 't', 'r', 'y', 'B', 'a', 'c', 'k', 'O', 'f', 'f', 'R', '\014', 'r', 'e', 't', 'r', 'y', 'B', 'a', 'c', 'k', 'O', 'f', 'f', 
+'\022', 'x', '\n', '\033', 'r', 'a', 't', 'e', '_', 'l', 'i', 'm', 'i', 't', 'e', 'd', '_', 'r', 'e', 't', 'r', 'y', '_', 'b', 'a', 
+'c', 'k', '_', 'o', 'f', 'f', '\030', '\013', ' ', '\001', '(', '\013', '2', ':', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 
+'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'R', 'e', 't', 'r', 'y', 'P', 'o', 'l', 'i', 'c', 'y', '.', 'R', 
+'a', 't', 'e', 'L', 'i', 'm', 'i', 't', 'e', 'd', 'R', 'e', 't', 'r', 'y', 'B', 'a', 'c', 'k', 'O', 'f', 'f', 'R', '\027', 'r', 
+'a', 't', 'e', 'L', 'i', 'm', 'i', 't', 'e', 'd', 'R', 'e', 't', 'r', 'y', 'B', 'a', 'c', 'k', 'O', 'f', 'f', '\022', 'Q', '\n', 
+'\021', 'r', 'e', 't', 'r', 'i', 'a', 'b', 'l', 'e', '_', 'h', 'e', 'a', 'd', 'e', 'r', 's', '\030', '\t', ' ', '\003', '(', '\013', '2', 
+'$', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'H', 
+'e', 'a', 'd', 'e', 'r', 'M', 'a', 't', 'c', 'h', 'e', 'r', 'R', '\020', 'r', 'e', 't', 'r', 'i', 'a', 'b', 'l', 'e', 'H', 'e', 
+'a', 'd', 'e', 'r', 's', '\022', '`', '\n', '\031', 'r', 'e', 't', 'r', 'i', 'a', 'b', 'l', 'e', '_', 'r', 'e', 'q', 'u', 'e', 's', 
+'t', '_', 'h', 'e', 'a', 'd', 'e', 'r', 's', '\030', '\n', ' ', '\003', '(', '\013', '2', '$', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 
+'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'H', 'e', 'a', 'd', 'e', 'r', 'M', 'a', 't', 'c', 
+'h', 'e', 'r', 'R', '\027', 'r', 'e', 't', 'r', 'i', 'a', 'b', 'l', 'e', 'R', 'e', 'q', 'u', 'e', 's', 't', 'H', 'e', 'a', 'd', 
+'e', 'r', 's', '\032', '\271', '\001', '\n', '\r', 'R', 'e', 't', 'r', 'y', 'P', 'r', 'i', 'o', 'r', 'i', 't', 'y', '\022', '\033', '\n', '\004', 
 'n', 'a', 'm', 'e', '\030', '\001', ' ', '\001', '(', '\t', 'B', '\007', '\372', 'B', '\004', 'r', '\002', '\020', '\001', 'R', '\004', 'n', 'a', 'm', 'e', 
-':', '?', '\232', '\305', '\210', '\036', ':', '\n', '8', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'r', 'o', 'u', 
-'t', 'e', '.', 'R', 'o', 'u', 't', 'e', 'A', 'c', 't', 'i', 'o', 'n', '.', 'H', 'a', 's', 'h', 'P', 'o', 'l', 'i', 'c', 'y', 
-'.', 'Q', 'u', 'e', 'r', 'y', 'P', 'a', 'r', 'a', 'm', 'e', 't', 'e', 'r', '\032', 'f', '\n', '\013', 'F', 'i', 'l', 't', 'e', 'r', 
-'S', 't', 'a', 't', 'e', '\022', '\031', '\n', '\003', 'k', 'e', 'y', '\030', '\001', ' ', '\001', '(', '\t', 'B', '\007', '\372', 'B', '\004', 'r', '\002', 
-'\020', '\001', 'R', '\003', 'k', 'e', 'y', ':', '<', '\232', '\305', '\210', '\036', '7', '\n', '5', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', 
-'.', 'v', '2', '.', 'r', 'o', 'u', 't', 'e', '.', 'R', 'o', 'u', 't', 'e', 'A', 'c', 't', 'i', 'o', 'n', '.', 'H', 'a', 's', 
-'h', 'P', 'o', 'l', 'i', 'c', 'y', '.', 'F', 'i', 'l', 't', 'e', 'r', 'S', 't', 'a', 't', 'e', ':', '0', '\232', '\305', '\210', '\036', 
-'+', '\n', ')', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'r', 'o', 'u', 't', 'e', '.', 'R', 'o', 'u', 
-'t', 'e', 'A', 'c', 't', 'i', 'o', 'n', '.', 'H', 'a', 's', 'h', 'P', 'o', 'l', 'i', 'c', 'y', 'B', '\027', '\n', '\020', 'p', 'o', 
-'l', 'i', 'c', 'y', '_', 's', 'p', 'e', 'c', 'i', 'f', 'i', 'e', 'r', '\022', '\003', '\370', 'B', '\001', '\032', '\243', '\003', '\n', '\r', 'U', 
-'p', 'g', 'r', 'a', 'd', 'e', 'C', 'o', 'n', 'f', 'i', 'g', '\022', '0', '\n', '\014', 'u', 'p', 'g', 'r', 'a', 'd', 'e', '_', 't', 
-'y', 'p', 'e', '\030', '\001', ' ', '\001', '(', '\t', 'B', '\r', '\372', 'B', '\n', 'r', '\010', '\020', '\001', '\300', '\001', '\002', '\310', '\001', '\000', 'R', 
-'\013', 'u', 'p', 'g', 'r', 'a', 'd', 'e', 'T', 'y', 'p', 'e', '\022', '4', '\n', '\007', 'e', 'n', 'a', 'b', 'l', 'e', 'd', '\030', '\002', 
-' ', '\001', '(', '\013', '2', '\032', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'B', 'o', 
-'o', 'l', 'V', 'a', 'l', 'u', 'e', 'R', '\007', 'e', 'n', 'a', 'b', 'l', 'e', 'd', '\022', 'e', '\n', '\016', 'c', 'o', 'n', 'n', 'e', 
-'c', 't', '_', 'c', 'o', 'n', 'f', 'i', 'g', '\030', '\003', ' ', '\001', '(', '\013', '2', '>', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 
-'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'R', 'o', 'u', 't', 'e', 'A', 'c', 't', 'i', 'o', 
-'n', '.', 'U', 'p', 'g', 'r', 'a', 'd', 'e', 'C', 'o', 'n', 'f', 'i', 'g', '.', 'C', 'o', 'n', 'n', 'e', 'c', 't', 'C', 'o', 
-'n', 'f', 'i', 'g', 'R', '\r', 'c', 'o', 'n', 'n', 'e', 'c', 't', 'C', 'o', 'n', 'f', 'i', 'g', '\032', '\215', '\001', '\n', '\r', 'C', 
-'o', 'n', 'n', 'e', 'c', 't', 'C', 'o', 'n', 'f', 'i', 'g', '\022', ']', '\n', '\025', 'p', 'r', 'o', 'x', 'y', '_', 'p', 'r', 'o', 
-'t', 'o', 'c', 'o', 'l', '_', 'c', 'o', 'n', 'f', 'i', 'g', '\030', '\001', ' ', '\001', '(', '\013', '2', ')', '.', 'e', 'n', 'v', 'o', 
-'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'P', 'r', 'o', 'x', 'y', 'P', 'r', 'o', 
-'t', 'o', 'c', 'o', 'l', 'C', 'o', 'n', 'f', 'i', 'g', 'R', '\023', 'p', 'r', 'o', 'x', 'y', 'P', 'r', 'o', 't', 'o', 'c', 'o', 
-'l', 'C', 'o', 'n', 'f', 'i', 'g', '\022', '\035', '\n', '\n', 'a', 'l', 'l', 'o', 'w', '_', 'p', 'o', 's', 't', '\030', '\002', ' ', '\001', 
-'(', '\010', 'R', '\t', 'a', 'l', 'l', 'o', 'w', 'P', 'o', 's', 't', ':', '3', '\232', '\305', '\210', '\036', '.', '\n', ',', 'e', 'n', 'v', 
-'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'r', 'o', 'u', 't', 'e', '.', 'R', 'o', 'u', 't', 'e', 'A', 'c', 't', 'i', 
-'o', 'n', '.', 'U', 'p', 'g', 'r', 'a', 'd', 'e', 'C', 'o', 'n', 'f', 'i', 'g', '\032', '\210', '\002', '\n', '\021', 'M', 'a', 'x', 'S', 
-'t', 'r', 'e', 'a', 'm', 'D', 'u', 'r', 'a', 't', 'i', 'o', 'n', '\022', 'I', '\n', '\023', 'm', 'a', 'x', '_', 's', 't', 'r', 'e', 
-'a', 'm', '_', 'd', 'u', 'r', 'a', 't', 'i', 'o', 'n', '\030', '\001', ' ', '\001', '(', '\013', '2', '\031', '.', 'g', 'o', 'o', 'g', 'l', 
-'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'D', 'u', 'r', 'a', 't', 'i', 'o', 'n', 'R', '\021', 'm', 'a', 'x', 'S', 
-'t', 'r', 'e', 'a', 'm', 'D', 'u', 'r', 'a', 't', 'i', 'o', 'n', '\022', 'P', '\n', '\027', 'g', 'r', 'p', 'c', '_', 't', 'i', 'm', 
-'e', 'o', 'u', 't', '_', 'h', 'e', 'a', 'd', 'e', 'r', '_', 'm', 'a', 'x', '\030', '\002', ' ', '\001', '(', '\013', '2', '\031', '.', 'g', 
-'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'D', 'u', 'r', 'a', 't', 'i', 'o', 'n', 'R', '\024', 
-'g', 'r', 'p', 'c', 'T', 'i', 'm', 'e', 'o', 'u', 't', 'H', 'e', 'a', 'd', 'e', 'r', 'M', 'a', 'x', '\022', 'V', '\n', '\032', 'g', 
-'r', 'p', 'c', '_', 't', 'i', 'm', 'e', 'o', 'u', 't', '_', 'h', 'e', 'a', 'd', 'e', 'r', '_', 'o', 'f', 'f', 's', 'e', 't', 
-'\030', '\003', ' ', '\001', '(', '\013', '2', '\031', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 
-'D', 'u', 'r', 'a', 't', 'i', 'o', 'n', 'R', '\027', 'g', 'r', 'p', 'c', 'T', 'i', 'm', 'e', 'o', 'u', 't', 'H', 'e', 'a', 'd', 
-'e', 'r', 'O', 'f', 'f', 's', 'e', 't', '\"', 'E', '\n', '\033', 'C', 'l', 'u', 's', 't', 'e', 'r', 'N', 'o', 't', 'F', 'o', 'u', 
-'n', 'd', 'R', 'e', 's', 'p', 'o', 'n', 's', 'e', 'C', 'o', 'd', 'e', '\022', '\027', '\n', '\023', 'S', 'E', 'R', 'V', 'I', 'C', 'E', 
-'_', 'U', 'N', 'A', 'V', 'A', 'I', 'L', 'A', 'B', 'L', 'E', '\020', '\000', '\022', '\r', '\n', '\t', 'N', 'O', 'T', '_', 'F', 'O', 'U', 
-'N', 'D', '\020', '\001', '\"', '^', '\n', '\026', 'I', 'n', 't', 'e', 'r', 'n', 'a', 'l', 'R', 'e', 'd', 'i', 'r', 'e', 'c', 't', 'A', 
-'c', 't', 'i', 'o', 'n', '\022', '\"', '\n', '\036', 'P', 'A', 'S', 'S', '_', 'T', 'H', 'R', 'O', 'U', 'G', 'H', '_', 'I', 'N', 'T', 
-'E', 'R', 'N', 'A', 'L', '_', 'R', 'E', 'D', 'I', 'R', 'E', 'C', 'T', '\020', '\000', '\022', '\034', '\n', '\030', 'H', 'A', 'N', 'D', 'L', 
-'E', '_', 'I', 'N', 'T', 'E', 'R', 'N', 'A', 'L', '_', 'R', 'E', 'D', 'I', 'R', 'E', 'C', 'T', '\020', '\001', '\032', '\002', '\030', '\001', 
-':', '%', '\232', '\305', '\210', '\036', ' ', '\n', '\036', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'r', 'o', 'u', 
-'t', 'e', '.', 'R', 'o', 'u', 't', 'e', 'A', 'c', 't', 'i', 'o', 'n', 'B', '\030', '\n', '\021', 'c', 'l', 'u', 's', 't', 'e', 'r', 
-'_', 's', 'p', 'e', 'c', 'i', 'f', 'i', 'e', 'r', '\022', '\003', '\370', 'B', '\001', 'B', '\030', '\n', '\026', 'h', 'o', 's', 't', '_', 'r', 
-'e', 'w', 'r', 'i', 't', 'e', '_', 's', 'p', 'e', 'c', 'i', 'f', 'i', 'e', 'r', 'J', '\004', '\010', '\014', '\020', '\r', 'J', '\004', '\010', 
-'\022', '\020', '\023', 'J', '\004', '\010', '\023', '\020', '\024', 'J', '\004', '\010', '\020', '\020', '\021', 'J', '\004', '\010', '\026', '\020', '\027', 'J', '\004', '\010', '\025', 
-'\020', '\026', 'J', '\004', '\010', '\n', '\020', '\013', 'R', '\025', 'r', 'e', 'q', 'u', 'e', 's', 't', '_', 'm', 'i', 'r', 'r', 'o', 'r', '_', 
-'p', 'o', 'l', 'i', 'c', 'y', '\"', '\215', '\017', '\n', '\013', 'R', 'e', 't', 'r', 'y', 'P', 'o', 'l', 'i', 'c', 'y', '\022', '\031', '\n', 
-'\010', 'r', 'e', 't', 'r', 'y', '_', 'o', 'n', '\030', '\001', ' ', '\001', '(', '\t', 'R', '\007', 'r', 'e', 't', 'r', 'y', 'O', 'n', '\022', 
-'R', '\n', '\013', 'n', 'u', 'm', '_', 'r', 'e', 't', 'r', 'i', 'e', 's', '\030', '\002', ' ', '\001', '(', '\013', '2', '\034', '.', 'g', 'o', 
-'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'U', 'I', 'n', 't', '3', '2', 'V', 'a', 'l', 'u', 'e', 
-'B', '\023', '\362', '\230', '\376', '\217', '\005', '\r', '\n', '\013', 'm', 'a', 'x', '_', 'r', 'e', 't', 'r', 'i', 'e', 's', 'R', '\n', 'n', 'u', 
-'m', 'R', 'e', 't', 'r', 'i', 'e', 's', '\022', 'A', '\n', '\017', 'p', 'e', 'r', '_', 't', 'r', 'y', '_', 't', 'i', 'm', 'e', 'o', 
-'u', 't', '\030', '\003', ' ', '\001', '(', '\013', '2', '\031', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 
-'f', '.', 'D', 'u', 'r', 'a', 't', 'i', 'o', 'n', 'R', '\r', 'p', 'e', 'r', 'T', 'r', 'y', 'T', 'i', 'm', 'e', 'o', 'u', 't', 
-'\022', 'W', '\n', '\016', 'r', 'e', 't', 'r', 'y', '_', 'p', 'r', 'i', 'o', 'r', 'i', 't', 'y', '\030', '\004', ' ', '\001', '(', '\013', '2', 
-'0', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'R', 
-'e', 't', 'r', 'y', 'P', 'o', 'l', 'i', 'c', 'y', '.', 'R', 'e', 't', 'r', 'y', 'P', 'r', 'i', 'o', 'r', 'i', 't', 'y', 'R', 
-'\r', 'r', 'e', 't', 'r', 'y', 'P', 'r', 'i', 'o', 'r', 'i', 't', 'y', '\022', 'g', '\n', '\024', 'r', 'e', 't', 'r', 'y', '_', 'h', 
-'o', 's', 't', '_', 'p', 'r', 'e', 'd', 'i', 'c', 'a', 't', 'e', '\030', '\005', ' ', '\003', '(', '\013', '2', '5', '.', 'e', 'n', 'v', 
-'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'R', 'e', 't', 'r', 'y', 'P', 
-'o', 'l', 'i', 'c', 'y', '.', 'R', 'e', 't', 'r', 'y', 'H', 'o', 's', 't', 'P', 'r', 'e', 'd', 'i', 'c', 'a', 't', 'e', 'R', 
-'\022', 'r', 'e', 't', 'r', 'y', 'H', 'o', 's', 't', 'P', 'r', 'e', 'd', 'i', 'c', 'a', 't', 'e', '\022', 'H', '\n', '!', 'h', 'o', 
-'s', 't', '_', 's', 'e', 'l', 'e', 'c', 't', 'i', 'o', 'n', '_', 'r', 'e', 't', 'r', 'y', '_', 'm', 'a', 'x', '_', 'a', 't', 
-'t', 'e', 'm', 'p', 't', 's', '\030', '\006', ' ', '\001', '(', '\003', 'R', '\035', 'h', 'o', 's', 't', 'S', 'e', 'l', 'e', 'c', 't', 'i', 
-'o', 'n', 'R', 'e', 't', 'r', 'y', 'M', 'a', 'x', 'A', 't', 't', 'e', 'm', 'p', 't', 's', '\022', '4', '\n', '\026', 'r', 'e', 't', 
-'r', 'i', 'a', 'b', 'l', 'e', '_', 's', 't', 'a', 't', 'u', 's', '_', 'c', 'o', 'd', 'e', 's', '\030', '\007', ' ', '\003', '(', '\r', 
-'R', '\024', 'r', 'e', 't', 'r', 'i', 'a', 'b', 'l', 'e', 'S', 't', 'a', 't', 'u', 's', 'C', 'o', 'd', 'e', 's', '\022', 'U', '\n', 
-'\016', 'r', 'e', 't', 'r', 'y', '_', 'b', 'a', 'c', 'k', '_', 'o', 'f', 'f', '\030', '\010', ' ', '\001', '(', '\013', '2', '/', '.', 'e', 
-'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'R', 'e', 't', 'r', 
-'y', 'P', 'o', 'l', 'i', 'c', 'y', '.', 'R', 'e', 't', 'r', 'y', 'B', 'a', 'c', 'k', 'O', 'f', 'f', 'R', '\014', 'r', 'e', 't', 
-'r', 'y', 'B', 'a', 'c', 'k', 'O', 'f', 'f', '\022', 'x', '\n', '\033', 'r', 'a', 't', 'e', '_', 'l', 'i', 'm', 'i', 't', 'e', 'd', 
-'_', 'r', 'e', 't', 'r', 'y', '_', 'b', 'a', 'c', 'k', '_', 'o', 'f', 'f', '\030', '\013', ' ', '\001', '(', '\013', '2', ':', '.', 'e', 
+'\022', '9', '\n', '\014', 't', 'y', 'p', 'e', 'd', '_', 'c', 'o', 'n', 'f', 'i', 'g', '\030', '\003', ' ', '\001', '(', '\013', '2', '\024', '.', 
+'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'A', 'n', 'y', 'H', '\000', 'R', '\013', 't', 'y', 
+'p', 'e', 'd', 'C', 'o', 'n', 'f', 'i', 'g', ':', '3', '\232', '\305', '\210', '\036', '.', '\n', ',', 'e', 'n', 'v', 'o', 'y', '.', 'a', 
+'p', 'i', '.', 'v', '2', '.', 'r', 'o', 'u', 't', 'e', '.', 'R', 'e', 't', 'r', 'y', 'P', 'o', 'l', 'i', 'c', 'y', '.', 'R', 
+'e', 't', 'r', 'y', 'P', 'r', 'i', 'o', 'r', 'i', 't', 'y', 'B', '\r', '\n', '\013', 'c', 'o', 'n', 'f', 'i', 'g', '_', 't', 'y', 
+'p', 'e', 'J', '\004', '\010', '\002', '\020', '\003', 'R', '\006', 'c', 'o', 'n', 'f', 'i', 'g', '\032', '\303', '\001', '\n', '\022', 'R', 'e', 't', 'r', 
+'y', 'H', 'o', 's', 't', 'P', 'r', 'e', 'd', 'i', 'c', 'a', 't', 'e', '\022', '\033', '\n', '\004', 'n', 'a', 'm', 'e', '\030', '\001', ' ', 
+'\001', '(', '\t', 'B', '\007', '\372', 'B', '\004', 'r', '\002', '\020', '\001', 'R', '\004', 'n', 'a', 'm', 'e', '\022', '9', '\n', '\014', 't', 'y', 'p', 
+'e', 'd', '_', 'c', 'o', 'n', 'f', 'i', 'g', '\030', '\003', ' ', '\001', '(', '\013', '2', '\024', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 
+'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'A', 'n', 'y', 'H', '\000', 'R', '\013', 't', 'y', 'p', 'e', 'd', 'C', 'o', 'n', 'f', 
+'i', 'g', ':', '8', '\232', '\305', '\210', '\036', '3', '\n', '1', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'r', 
+'o', 'u', 't', 'e', '.', 'R', 'e', 't', 'r', 'y', 'P', 'o', 'l', 'i', 'c', 'y', '.', 'R', 'e', 't', 'r', 'y', 'H', 'o', 's', 
+'t', 'P', 'r', 'e', 'd', 'i', 'c', 'a', 't', 'e', 'B', '\r', '\n', '\013', 'c', 'o', 'n', 'f', 'i', 'g', '_', 't', 'y', 'p', 'e', 
+'J', '\004', '\010', '\002', '\020', '\003', 'R', '\006', 'c', 'o', 'n', 'f', 'i', 'g', '\032', '\326', '\001', '\n', '\014', 'R', 'e', 't', 'r', 'y', 'B', 
+'a', 'c', 'k', 'O', 'f', 'f', '\022', 'J', '\n', '\r', 'b', 'a', 's', 'e', '_', 'i', 'n', 't', 'e', 'r', 'v', 'a', 'l', '\030', '\001', 
+' ', '\001', '(', '\013', '2', '\031', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'D', 'u', 
+'r', 'a', 't', 'i', 'o', 'n', 'B', '\n', '\372', 'B', '\007', '\252', '\001', '\004', '\010', '\001', '*', '\000', 'R', '\014', 'b', 'a', 's', 'e', 'I', 
+'n', 't', 'e', 'r', 'v', 'a', 'l', '\022', 'F', '\n', '\014', 'm', 'a', 'x', '_', 'i', 'n', 't', 'e', 'r', 'v', 'a', 'l', '\030', '\002', 
+' ', '\001', '(', '\013', '2', '\031', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'D', 'u', 
+'r', 'a', 't', 'i', 'o', 'n', 'B', '\010', '\372', 'B', '\005', '\252', '\001', '\002', '*', '\000', 'R', '\013', 'm', 'a', 'x', 'I', 'n', 't', 'e', 
+'r', 'v', 'a', 'l', ':', '2', '\232', '\305', '\210', '\036', '-', '\n', '+', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', 
+'.', 'r', 'o', 'u', 't', 'e', '.', 'R', 'e', 't', 'r', 'y', 'P', 'o', 'l', 'i', 'c', 'y', '.', 'R', 'e', 't', 'r', 'y', 'B', 
+'a', 'c', 'k', 'O', 'f', 'f', '\032', '\210', '\001', '\n', '\013', 'R', 'e', 's', 'e', 't', 'H', 'e', 'a', 'd', 'e', 'r', '\022', '!', '\n', 
+'\004', 'n', 'a', 'm', 'e', '\030', '\001', ' ', '\001', '(', '\t', 'B', '\r', '\372', 'B', '\n', 'r', '\010', '\020', '\001', '\300', '\001', '\001', '\310', '\001', 
+'\000', 'R', '\004', 'n', 'a', 'm', 'e', '\022', 'V', '\n', '\006', 'f', 'o', 'r', 'm', 'a', 't', '\030', '\002', ' ', '\001', '(', '\016', '2', '4', 
+'.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'R', 'e', 
+'t', 'r', 'y', 'P', 'o', 'l', 'i', 'c', 'y', '.', 'R', 'e', 's', 'e', 't', 'H', 'e', 'a', 'd', 'e', 'r', 'F', 'o', 'r', 'm', 
+'a', 't', 'B', '\010', '\372', 'B', '\005', '\202', '\001', '\002', '\020', '\001', 'R', '\006', 'f', 'o', 'r', 'm', 'a', 't', '\032', '\300', '\001', '\n', '\027', 
+'R', 'a', 't', 'e', 'L', 'i', 'm', 'i', 't', 'e', 'd', 'R', 'e', 't', 'r', 'y', 'B', 'a', 'c', 'k', 'O', 'f', 'f', '\022', ']', 
+'\n', '\r', 'r', 'e', 's', 'e', 't', '_', 'h', 'e', 'a', 'd', 'e', 'r', 's', '\030', '\001', ' ', '\003', '(', '\013', '2', '.', '.', 'e', 
 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'R', 'e', 't', 'r', 
-'y', 'P', 'o', 'l', 'i', 'c', 'y', '.', 'R', 'a', 't', 'e', 'L', 'i', 'm', 'i', 't', 'e', 'd', 'R', 'e', 't', 'r', 'y', 'B', 
-'a', 'c', 'k', 'O', 'f', 'f', 'R', '\027', 'r', 'a', 't', 'e', 'L', 'i', 'm', 'i', 't', 'e', 'd', 'R', 'e', 't', 'r', 'y', 'B', 
-'a', 'c', 'k', 'O', 'f', 'f', '\022', 'Q', '\n', '\021', 'r', 'e', 't', 'r', 'i', 'a', 'b', 'l', 'e', '_', 'h', 'e', 'a', 'd', 'e', 
-'r', 's', '\030', '\t', ' ', '\003', '(', '\013', '2', '$', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 
-'o', 'u', 't', 'e', '.', 'v', '3', '.', 'H', 'e', 'a', 'd', 'e', 'r', 'M', 'a', 't', 'c', 'h', 'e', 'r', 'R', '\020', 'r', 'e', 
-'t', 'r', 'i', 'a', 'b', 'l', 'e', 'H', 'e', 'a', 'd', 'e', 'r', 's', '\022', '`', '\n', '\031', 'r', 'e', 't', 'r', 'i', 'a', 'b', 
-'l', 'e', '_', 'r', 'e', 'q', 'u', 'e', 's', 't', '_', 'h', 'e', 'a', 'd', 'e', 'r', 's', '\030', '\n', ' ', '\003', '(', '\013', '2', 
-'$', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'H', 
-'e', 'a', 'd', 'e', 'r', 'M', 'a', 't', 'c', 'h', 'e', 'r', 'R', '\027', 'r', 'e', 't', 'r', 'i', 'a', 'b', 'l', 'e', 'R', 'e', 
-'q', 'u', 'e', 's', 't', 'H', 'e', 'a', 'd', 'e', 'r', 's', '\032', '\271', '\001', '\n', '\r', 'R', 'e', 't', 'r', 'y', 'P', 'r', 'i', 
-'o', 'r', 'i', 't', 'y', '\022', '\033', '\n', '\004', 'n', 'a', 'm', 'e', '\030', '\001', ' ', '\001', '(', '\t', 'B', '\007', '\372', 'B', '\004', 'r', 
-'\002', '\020', '\001', 'R', '\004', 'n', 'a', 'm', 'e', '\022', '9', '\n', '\014', 't', 'y', 'p', 'e', 'd', '_', 'c', 'o', 'n', 'f', 'i', 'g', 
-'\030', '\003', ' ', '\001', '(', '\013', '2', '\024', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 
-'A', 'n', 'y', 'H', '\000', 'R', '\013', 't', 'y', 'p', 'e', 'd', 'C', 'o', 'n', 'f', 'i', 'g', ':', '3', '\232', '\305', '\210', '\036', '.', 
-'\n', ',', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'r', 'o', 'u', 't', 'e', '.', 'R', 'e', 't', 'r', 
-'y', 'P', 'o', 'l', 'i', 'c', 'y', '.', 'R', 'e', 't', 'r', 'y', 'P', 'r', 'i', 'o', 'r', 'i', 't', 'y', 'B', '\r', '\n', '\013', 
-'c', 'o', 'n', 'f', 'i', 'g', '_', 't', 'y', 'p', 'e', 'J', '\004', '\010', '\002', '\020', '\003', 'R', '\006', 'c', 'o', 'n', 'f', 'i', 'g', 
-'\032', '\303', '\001', '\n', '\022', 'R', 'e', 't', 'r', 'y', 'H', 'o', 's', 't', 'P', 'r', 'e', 'd', 'i', 'c', 'a', 't', 'e', '\022', '\033', 
-'\n', '\004', 'n', 'a', 'm', 'e', '\030', '\001', ' ', '\001', '(', '\t', 'B', '\007', '\372', 'B', '\004', 'r', '\002', '\020', '\001', 'R', '\004', 'n', 'a', 
-'m', 'e', '\022', '9', '\n', '\014', 't', 'y', 'p', 'e', 'd', '_', 'c', 'o', 'n', 'f', 'i', 'g', '\030', '\003', ' ', '\001', '(', '\013', '2', 
-'\024', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'A', 'n', 'y', 'H', '\000', 'R', '\013', 
-'t', 'y', 'p', 'e', 'd', 'C', 'o', 'n', 'f', 'i', 'g', ':', '8', '\232', '\305', '\210', '\036', '3', '\n', '1', 'e', 'n', 'v', 'o', 'y', 
-'.', 'a', 'p', 'i', '.', 'v', '2', '.', 'r', 'o', 'u', 't', 'e', '.', 'R', 'e', 't', 'r', 'y', 'P', 'o', 'l', 'i', 'c', 'y', 
-'.', 'R', 'e', 't', 'r', 'y', 'H', 'o', 's', 't', 'P', 'r', 'e', 'd', 'i', 'c', 'a', 't', 'e', 'B', '\r', '\n', '\013', 'c', 'o', 
-'n', 'f', 'i', 'g', '_', 't', 'y', 'p', 'e', 'J', '\004', '\010', '\002', '\020', '\003', 'R', '\006', 'c', 'o', 'n', 'f', 'i', 'g', '\032', '\326', 
-'\001', '\n', '\014', 'R', 'e', 't', 'r', 'y', 'B', 'a', 'c', 'k', 'O', 'f', 'f', '\022', 'J', '\n', '\r', 'b', 'a', 's', 'e', '_', 'i', 
-'n', 't', 'e', 'r', 'v', 'a', 'l', '\030', '\001', ' ', '\001', '(', '\013', '2', '\031', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 
-'o', 't', 'o', 'b', 'u', 'f', '.', 'D', 'u', 'r', 'a', 't', 'i', 'o', 'n', 'B', '\n', '\372', 'B', '\007', '\252', '\001', '\004', '\010', '\001', 
-'*', '\000', 'R', '\014', 'b', 'a', 's', 'e', 'I', 'n', 't', 'e', 'r', 'v', 'a', 'l', '\022', 'F', '\n', '\014', 'm', 'a', 'x', '_', 'i', 
-'n', 't', 'e', 'r', 'v', 'a', 'l', '\030', '\002', ' ', '\001', '(', '\013', '2', '\031', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 
-'o', 't', 'o', 'b', 'u', 'f', '.', 'D', 'u', 'r', 'a', 't', 'i', 'o', 'n', 'B', '\010', '\372', 'B', '\005', '\252', '\001', '\002', '*', '\000', 
-'R', '\013', 'm', 'a', 'x', 'I', 'n', 't', 'e', 'r', 'v', 'a', 'l', ':', '2', '\232', '\305', '\210', '\036', '-', '\n', '+', 'e', 'n', 'v', 
-'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'r', 'o', 'u', 't', 'e', '.', 'R', 'e', 't', 'r', 'y', 'P', 'o', 'l', 'i', 
-'c', 'y', '.', 'R', 'e', 't', 'r', 'y', 'B', 'a', 'c', 'k', 'O', 'f', 'f', '\032', '\210', '\001', '\n', '\013', 'R', 'e', 's', 'e', 't', 
-'H', 'e', 'a', 'd', 'e', 'r', '\022', '!', '\n', '\004', 'n', 'a', 'm', 'e', '\030', '\001', ' ', '\001', '(', '\t', 'B', '\r', '\372', 'B', '\n', 
-'r', '\010', '\020', '\001', '\300', '\001', '\001', '\310', '\001', '\000', 'R', '\004', 'n', 'a', 'm', 'e', '\022', 'V', '\n', '\006', 'f', 'o', 'r', 'm', 'a', 
-'t', '\030', '\002', ' ', '\001', '(', '\016', '2', '4', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 
-'u', 't', 'e', '.', 'v', '3', '.', 'R', 'e', 't', 'r', 'y', 'P', 'o', 'l', 'i', 'c', 'y', '.', 'R', 'e', 's', 'e', 't', 'H', 
-'e', 'a', 'd', 'e', 'r', 'F', 'o', 'r', 'm', 'a', 't', 'B', '\010', '\372', 'B', '\005', '\202', '\001', '\002', '\020', '\001', 'R', '\006', 'f', 'o', 
-'r', 'm', 'a', 't', '\032', '\300', '\001', '\n', '\027', 'R', 'a', 't', 'e', 'L', 'i', 'm', 'i', 't', 'e', 'd', 'R', 'e', 't', 'r', 'y', 
-'B', 'a', 'c', 'k', 'O', 'f', 'f', '\022', ']', '\n', '\r', 'r', 'e', 's', 'e', 't', '_', 'h', 'e', 'a', 'd', 'e', 'r', 's', '\030', 
-'\001', ' ', '\003', '(', '\013', '2', '.', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 
-'e', '.', 'v', '3', '.', 'R', 'e', 't', 'r', 'y', 'P', 'o', 'l', 'i', 'c', 'y', '.', 'R', 'e', 's', 'e', 't', 'H', 'e', 'a', 
-'d', 'e', 'r', 'B', '\010', '\372', 'B', '\005', '\222', '\001', '\002', '\010', '\001', 'R', '\014', 'r', 'e', 's', 'e', 't', 'H', 'e', 'a', 'd', 'e', 
-'r', 's', '\022', 'F', '\n', '\014', 'm', 'a', 'x', '_', 'i', 'n', 't', 'e', 'r', 'v', 'a', 'l', '\030', '\002', ' ', '\001', '(', '\013', '2', 
-'\031', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'D', 'u', 'r', 'a', 't', 'i', 'o', 
-'n', 'B', '\010', '\372', 'B', '\005', '\252', '\001', '\002', '*', '\000', 'R', '\013', 'm', 'a', 'x', 'I', 'n', 't', 'e', 'r', 'v', 'a', 'l', '\"', 
-'4', '\n', '\021', 'R', 'e', 's', 'e', 't', 'H', 'e', 'a', 'd', 'e', 'r', 'F', 'o', 'r', 'm', 'a', 't', '\022', '\013', '\n', '\007', 'S', 
-'E', 'C', 'O', 'N', 'D', 'S', '\020', '\000', '\022', '\022', '\n', '\016', 'U', 'N', 'I', 'X', '_', 'T', 'I', 'M', 'E', 'S', 'T', 'A', 'M', 
-'P', '\020', '\001', ':', '%', '\232', '\305', '\210', '\036', ' ', '\n', '\036', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 
-'r', 'o', 'u', 't', 'e', '.', 'R', 'e', 't', 'r', 'y', 'P', 'o', 'l', 'i', 'c', 'y', '\"', '\234', '\002', '\n', '\013', 'H', 'e', 'd', 
-'g', 'e', 'P', 'o', 'l', 'i', 'c', 'y', '\022', 'P', '\n', '\020', 'i', 'n', 'i', 't', 'i', 'a', 'l', '_', 'r', 'e', 'q', 'u', 'e', 
-'s', 't', 's', '\030', '\001', ' ', '\001', '(', '\013', '2', '\034', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 
-'u', 'f', '.', 'U', 'I', 'n', 't', '3', '2', 'V', 'a', 'l', 'u', 'e', 'B', '\007', '\372', 'B', '\004', '*', '\002', '(', '\001', 'R', '\017', 
-'i', 'n', 'i', 't', 'i', 'a', 'l', 'R', 'e', 'q', 'u', 'e', 's', 't', 's', '\022', '\\', '\n', '\031', 'a', 'd', 'd', 'i', 't', 'i', 
-'o', 'n', 'a', 'l', '_', 'r', 'e', 'q', 'u', 'e', 's', 't', '_', 'c', 'h', 'a', 'n', 'c', 'e', '\030', '\002', ' ', '\001', '(', '\013', 
-'2', ' ', '.', 'e', 'n', 'v', 'o', 'y', '.', 't', 'y', 'p', 'e', '.', 'v', '3', '.', 'F', 'r', 'a', 'c', 't', 'i', 'o', 'n', 
-'a', 'l', 'P', 'e', 'r', 'c', 'e', 'n', 't', 'R', '\027', 'a', 'd', 'd', 'i', 't', 'i', 'o', 'n', 'a', 'l', 'R', 'e', 'q', 'u', 
-'e', 's', 't', 'C', 'h', 'a', 'n', 'c', 'e', '\022', '6', '\n', '\030', 'h', 'e', 'd', 'g', 'e', '_', 'o', 'n', '_', 'p', 'e', 'r', 
-'_', 't', 'r', 'y', '_', 't', 'i', 'm', 'e', 'o', 'u', 't', '\030', '\003', ' ', '\001', '(', '\010', 'R', '\024', 'h', 'e', 'd', 'g', 'e', 
-'O', 'n', 'P', 'e', 'r', 'T', 'r', 'y', 'T', 'i', 'm', 'e', 'o', 'u', 't', ':', '%', '\232', '\305', '\210', '\036', ' ', '\n', '\036', 'e', 
-'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'r', 'o', 'u', 't', 'e', '.', 'H', 'e', 'd', 'g', 'e', 'P', 'o', 
-'l', 'i', 'c', 'y', '\"', '\341', '\005', '\n', '\016', 'R', 'e', 'd', 'i', 'r', 'e', 'c', 't', 'A', 'c', 't', 'i', 'o', 'n', '\022', '\'', 
-'\n', '\016', 'h', 't', 't', 'p', 's', '_', 'r', 'e', 'd', 'i', 'r', 'e', 'c', 't', '\030', '\004', ' ', '\001', '(', '\010', 'H', '\000', 'R', 
-'\r', 'h', 't', 't', 'p', 's', 'R', 'e', 'd', 'i', 'r', 'e', 'c', 't', '\022', ')', '\n', '\017', 's', 'c', 'h', 'e', 'm', 'e', '_', 
-'r', 'e', 'd', 'i', 'r', 'e', 'c', 't', '\030', '\007', ' ', '\001', '(', '\t', 'H', '\000', 'R', '\016', 's', 'c', 'h', 'e', 'm', 'e', 'R', 
-'e', 'd', 'i', 'r', 'e', 'c', 't', '\022', '0', '\n', '\r', 'h', 'o', 's', 't', '_', 'r', 'e', 'd', 'i', 'r', 'e', 'c', 't', '\030', 
-'\001', ' ', '\001', '(', '\t', 'B', '\013', '\372', 'B', '\010', 'r', '\006', '\300', '\001', '\002', '\310', '\001', '\000', 'R', '\014', 'h', 'o', 's', 't', 'R', 
-'e', 'd', 'i', 'r', 'e', 'c', 't', '\022', '#', '\n', '\r', 'p', 'o', 'r', 't', '_', 'r', 'e', 'd', 'i', 'r', 'e', 'c', 't', '\030', 
-'\010', ' ', '\001', '(', '\r', 'R', '\014', 'p', 'o', 'r', 't', 'R', 'e', 'd', 'i', 'r', 'e', 'c', 't', '\022', '2', '\n', '\r', 'p', 'a', 
-'t', 'h', '_', 'r', 'e', 'd', 'i', 'r', 'e', 'c', 't', '\030', '\002', ' ', '\001', '(', '\t', 'B', '\013', '\372', 'B', '\010', 'r', '\006', '\300', 
-'\001', '\002', '\310', '\001', '\000', 'H', '\001', 'R', '\014', 'p', 'a', 't', 'h', 'R', 'e', 'd', 'i', 'r', 'e', 'c', 't', '\022', '4', '\n', '\016', 
-'p', 'r', 'e', 'f', 'i', 'x', '_', 'r', 'e', 'w', 'r', 'i', 't', 'e', '\030', '\005', ' ', '\001', '(', '\t', 'B', '\013', '\372', 'B', '\010', 
-'r', '\006', '\300', '\001', '\002', '\310', '\001', '\000', 'H', '\001', 'R', '\r', 'p', 'r', 'e', 'f', 'i', 'x', 'R', 'e', 'w', 'r', 'i', 't', 'e', 
-'\022', 'U', '\n', '\r', 'r', 'e', 'g', 'e', 'x', '_', 'r', 'e', 'w', 'r', 'i', 't', 'e', '\030', '\t', ' ', '\001', '(', '\013', '2', '.', 
-'.', 'e', 'n', 'v', 'o', 'y', '.', 't', 'y', 'p', 'e', '.', 'm', 'a', 't', 'c', 'h', 'e', 'r', '.', 'v', '3', '.', 'R', 'e', 
-'g', 'e', 'x', 'M', 'a', 't', 'c', 'h', 'A', 'n', 'd', 'S', 'u', 'b', 's', 't', 'i', 't', 'u', 't', 'e', 'H', '\001', 'R', '\014', 
-'r', 'e', 'g', 'e', 'x', 'R', 'e', 'w', 'r', 'i', 't', 'e', '\022', 'i', '\n', '\r', 'r', 'e', 's', 'p', 'o', 'n', 's', 'e', '_', 
-'c', 'o', 'd', 'e', '\030', '\003', ' ', '\001', '(', '\016', '2', ':', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', 
-'.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'R', 'e', 'd', 'i', 'r', 'e', 'c', 't', 'A', 'c', 't', 'i', 'o', 'n', '.', 
-'R', 'e', 'd', 'i', 'r', 'e', 'c', 't', 'R', 'e', 's', 'p', 'o', 'n', 's', 'e', 'C', 'o', 'd', 'e', 'B', '\010', '\372', 'B', '\005', 
-'\202', '\001', '\002', '\020', '\001', 'R', '\014', 'r', 'e', 's', 'p', 'o', 'n', 's', 'e', 'C', 'o', 'd', 'e', '\022', '\037', '\n', '\013', 's', 't', 
-'r', 'i', 'p', '_', 'q', 'u', 'e', 'r', 'y', '\030', '\006', ' ', '\001', '(', '\010', 'R', '\n', 's', 't', 'r', 'i', 'p', 'Q', 'u', 'e', 
-'r', 'y', '\"', 'w', '\n', '\024', 'R', 'e', 'd', 'i', 'r', 'e', 'c', 't', 'R', 'e', 's', 'p', 'o', 'n', 's', 'e', 'C', 'o', 'd', 
-'e', '\022', '\025', '\n', '\021', 'M', 'O', 'V', 'E', 'D', '_', 'P', 'E', 'R', 'M', 'A', 'N', 'E', 'N', 'T', 'L', 'Y', '\020', '\000', '\022', 
-'\t', '\n', '\005', 'F', 'O', 'U', 'N', 'D', '\020', '\001', '\022', '\r', '\n', '\t', 'S', 'E', 'E', '_', 'O', 'T', 'H', 'E', 'R', '\020', '\002', 
-'\022', '\026', '\n', '\022', 'T', 'E', 'M', 'P', 'O', 'R', 'A', 'R', 'Y', '_', 'R', 'E', 'D', 'I', 'R', 'E', 'C', 'T', '\020', '\003', '\022', 
-'\026', '\n', '\022', 'P', 'E', 'R', 'M', 'A', 'N', 'E', 'N', 'T', '_', 'R', 'E', 'D', 'I', 'R', 'E', 'C', 'T', '\020', '\004', ':', '(', 
-'\232', '\305', '\210', '\036', '#', '\n', '!', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'r', 'o', 'u', 't', 'e', 
-'.', 'R', 'e', 'd', 'i', 'r', 'e', 'c', 't', 'A', 'c', 't', 'i', 'o', 'n', 'B', '\032', '\n', '\030', 's', 'c', 'h', 'e', 'm', 'e', 
-'_', 'r', 'e', 'w', 'r', 'i', 't', 'e', '_', 's', 'p', 'e', 'c', 'i', 'f', 'i', 'e', 'r', 'B', '\030', '\n', '\026', 'p', 'a', 't', 
-'h', '_', 'r', 'e', 'w', 'r', 'i', 't', 'e', '_', 's', 'p', 'e', 'c', 'i', 'f', 'i', 'e', 'r', '\"', '\240', '\001', '\n', '\024', 'D', 
-'i', 'r', 'e', 'c', 't', 'R', 'e', 's', 'p', 'o', 'n', 's', 'e', 'A', 'c', 't', 'i', 'o', 'n', '\022', '\"', '\n', '\006', 's', 't', 
-'a', 't', 'u', 's', '\030', '\001', ' ', '\001', '(', '\r', 'B', '\n', '\372', 'B', '\007', '*', '\005', '\020', '\330', '\004', '(', 'd', 'R', '\006', 's', 
-'t', 'a', 't', 'u', 's', '\022', '4', '\n', '\004', 'b', 'o', 'd', 'y', '\030', '\002', ' ', '\001', '(', '\013', '2', ' ', '.', 'e', 'n', 'v', 
-'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'D', 'a', 't', 'a', 'S', 'o', 'u', 
-'r', 'c', 'e', 'R', '\004', 'b', 'o', 'd', 'y', ':', '.', '\232', '\305', '\210', '\036', ')', '\n', '\'', 'e', 'n', 'v', 'o', 'y', '.', 'a', 
-'p', 'i', '.', 'v', '2', '.', 'r', 'o', 'u', 't', 'e', '.', 'D', 'i', 'r', 'e', 'c', 't', 'R', 'e', 's', 'p', 'o', 'n', 's', 
-'e', 'A', 'c', 't', 'i', 'o', 'n', '\"', '\025', '\n', '\023', 'N', 'o', 'n', 'F', 'o', 'r', 'w', 'a', 'r', 'd', 'i', 'n', 'g', 'A', 
-'c', 't', 'i', 'o', 'n', '\"', '\221', '\001', '\n', '\t', 'D', 'e', 'c', 'o', 'r', 'a', 't', 'o', 'r', '\022', '%', '\n', '\t', 'o', 'p', 
-'e', 'r', 'a', 't', 'i', 'o', 'n', '\030', '\001', ' ', '\001', '(', '\t', 'B', '\007', '\372', 'B', '\004', 'r', '\002', '\020', '\001', 'R', '\t', 'o', 
-'p', 'e', 'r', 'a', 't', 'i', 'o', 'n', '\022', '8', '\n', '\t', 'p', 'r', 'o', 'p', 'a', 'g', 'a', 't', 'e', '\030', '\002', ' ', '\001', 
-'(', '\013', '2', '\032', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'B', 'o', 'o', 'l', 
-'V', 'a', 'l', 'u', 'e', 'R', '\t', 'p', 'r', 'o', 'p', 'a', 'g', 'a', 't', 'e', ':', '#', '\232', '\305', '\210', '\036', '\036', '\n', '\034', 
-'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'r', 'o', 'u', 't', 'e', '.', 'D', 'e', 'c', 'o', 'r', 'a', 
-'t', 'o', 'r', '\"', '\322', '\002', '\n', '\007', 'T', 'r', 'a', 'c', 'i', 'n', 'g', '\022', 'I', '\n', '\017', 'c', 'l', 'i', 'e', 'n', 't', 
-'_', 's', 'a', 'm', 'p', 'l', 'i', 'n', 'g', '\030', '\001', ' ', '\001', '(', '\013', '2', ' ', '.', 'e', 'n', 'v', 'o', 'y', '.', 't', 
-'y', 'p', 'e', '.', 'v', '3', '.', 'F', 'r', 'a', 'c', 't', 'i', 'o', 'n', 'a', 'l', 'P', 'e', 'r', 'c', 'e', 'n', 't', 'R', 
-'\016', 'c', 'l', 'i', 'e', 'n', 't', 'S', 'a', 'm', 'p', 'l', 'i', 'n', 'g', '\022', 'I', '\n', '\017', 'r', 'a', 'n', 'd', 'o', 'm', 
-'_', 's', 'a', 'm', 'p', 'l', 'i', 'n', 'g', '\030', '\002', ' ', '\001', '(', '\013', '2', ' ', '.', 'e', 'n', 'v', 'o', 'y', '.', 't', 
-'y', 'p', 'e', '.', 'v', '3', '.', 'F', 'r', 'a', 'c', 't', 'i', 'o', 'n', 'a', 'l', 'P', 'e', 'r', 'c', 'e', 'n', 't', 'R', 
-'\016', 'r', 'a', 'n', 'd', 'o', 'm', 'S', 'a', 'm', 'p', 'l', 'i', 'n', 'g', '\022', 'K', '\n', '\020', 'o', 'v', 'e', 'r', 'a', 'l', 
-'l', '_', 's', 'a', 'm', 'p', 'l', 'i', 'n', 'g', '\030', '\003', ' ', '\001', '(', '\013', '2', ' ', '.', 'e', 'n', 'v', 'o', 'y', '.', 
+'y', 'P', 'o', 'l', 'i', 'c', 'y', '.', 'R', 'e', 's', 'e', 't', 'H', 'e', 'a', 'd', 'e', 'r', 'B', '\010', '\372', 'B', '\005', '\222', 
+'\001', '\002', '\010', '\001', 'R', '\014', 'r', 'e', 's', 'e', 't', 'H', 'e', 'a', 'd', 'e', 'r', 's', '\022', 'F', '\n', '\014', 'm', 'a', 'x', 
+'_', 'i', 'n', 't', 'e', 'r', 'v', 'a', 'l', '\030', '\002', ' ', '\001', '(', '\013', '2', '\031', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 
+'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'D', 'u', 'r', 'a', 't', 'i', 'o', 'n', 'B', '\010', '\372', 'B', '\005', '\252', '\001', '\002', 
+'*', '\000', 'R', '\013', 'm', 'a', 'x', 'I', 'n', 't', 'e', 'r', 'v', 'a', 'l', '\"', '4', '\n', '\021', 'R', 'e', 's', 'e', 't', 'H', 
+'e', 'a', 'd', 'e', 'r', 'F', 'o', 'r', 'm', 'a', 't', '\022', '\013', '\n', '\007', 'S', 'E', 'C', 'O', 'N', 'D', 'S', '\020', '\000', '\022', 
+'\022', '\n', '\016', 'U', 'N', 'I', 'X', '_', 'T', 'I', 'M', 'E', 'S', 'T', 'A', 'M', 'P', '\020', '\001', ':', '%', '\232', '\305', '\210', '\036', 
+' ', '\n', '\036', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'r', 'o', 'u', 't', 'e', '.', 'R', 'e', 't', 
+'r', 'y', 'P', 'o', 'l', 'i', 'c', 'y', '\"', '\234', '\002', '\n', '\013', 'H', 'e', 'd', 'g', 'e', 'P', 'o', 'l', 'i', 'c', 'y', '\022', 
+'P', '\n', '\020', 'i', 'n', 'i', 't', 'i', 'a', 'l', '_', 'r', 'e', 'q', 'u', 'e', 's', 't', 's', '\030', '\001', ' ', '\001', '(', '\013', 
+'2', '\034', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'U', 'I', 'n', 't', '3', '2', 
+'V', 'a', 'l', 'u', 'e', 'B', '\007', '\372', 'B', '\004', '*', '\002', '(', '\001', 'R', '\017', 'i', 'n', 'i', 't', 'i', 'a', 'l', 'R', 'e', 
+'q', 'u', 'e', 's', 't', 's', '\022', '\\', '\n', '\031', 'a', 'd', 'd', 'i', 't', 'i', 'o', 'n', 'a', 'l', '_', 'r', 'e', 'q', 'u', 
+'e', 's', 't', '_', 'c', 'h', 'a', 'n', 'c', 'e', '\030', '\002', ' ', '\001', '(', '\013', '2', ' ', '.', 'e', 'n', 'v', 'o', 'y', '.', 
 't', 'y', 'p', 'e', '.', 'v', '3', '.', 'F', 'r', 'a', 'c', 't', 'i', 'o', 'n', 'a', 'l', 'P', 'e', 'r', 'c', 'e', 'n', 't', 
-'R', '\017', 'o', 'v', 'e', 'r', 'a', 'l', 'l', 'S', 'a', 'm', 'p', 'l', 'i', 'n', 'g', '\022', 'A', '\n', '\013', 'c', 'u', 's', 't', 
-'o', 'm', '_', 't', 'a', 'g', 's', '\030', '\004', ' ', '\003', '(', '\013', '2', ' ', '.', 'e', 'n', 'v', 'o', 'y', '.', 't', 'y', 'p', 
-'e', '.', 't', 'r', 'a', 'c', 'i', 'n', 'g', '.', 'v', '3', '.', 'C', 'u', 's', 't', 'o', 'm', 'T', 'a', 'g', 'R', '\n', 'c', 
-'u', 's', 't', 'o', 'm', 'T', 'a', 'g', 's', ':', '!', '\232', '\305', '\210', '\036', '\034', '\n', '\032', 'e', 'n', 'v', 'o', 'y', '.', 'a', 
-'p', 'i', '.', 'v', '2', '.', 'r', 'o', 'u', 't', 'e', '.', 'T', 'r', 'a', 'c', 'i', 'n', 'g', '\"', '\264', '\001', '\n', '\016', 'V', 
-'i', 'r', 't', 'u', 'a', 'l', 'C', 'l', 'u', 's', 't', 'e', 'r', '\022', '>', '\n', '\007', 'h', 'e', 'a', 'd', 'e', 'r', 's', '\030', 
-'\004', ' ', '\003', '(', '\013', '2', '$', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 
-'e', '.', 'v', '3', '.', 'H', 'e', 'a', 'd', 'e', 'r', 'M', 'a', 't', 'c', 'h', 'e', 'r', 'R', '\007', 'h', 'e', 'a', 'd', 'e', 
-'r', 's', '\022', '\033', '\n', '\004', 'n', 'a', 'm', 'e', '\030', '\002', ' ', '\001', '(', '\t', 'B', '\007', '\372', 'B', '\004', 'r', '\002', '\020', '\001', 
-'R', '\004', 'n', 'a', 'm', 'e', ':', '(', '\232', '\305', '\210', '\036', '#', '\n', '!', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 
-'v', '2', '.', 'r', 'o', 'u', 't', 'e', '.', 'V', 'i', 'r', 't', 'u', 'a', 'l', 'C', 'l', 'u', 's', 't', 'e', 'r', 'J', '\004', 
-'\010', '\001', '\020', '\002', 'J', '\004', '\010', '\003', '\020', '\004', 'R', '\007', 'p', 'a', 't', 't', 'e', 'r', 'n', 'R', '\006', 'm', 'e', 't', 'h', 
-'o', 'd', '\"', '\252', '\026', '\n', '\t', 'R', 'a', 't', 'e', 'L', 'i', 'm', 'i', 't', '\022', ';', '\n', '\005', 's', 't', 'a', 'g', 'e', 
-'\030', '\001', ' ', '\001', '(', '\013', '2', '\034', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 
-'U', 'I', 'n', 't', '3', '2', 'V', 'a', 'l', 'u', 'e', 'B', '\007', '\372', 'B', '\004', '*', '\002', '\030', '\n', 'R', '\005', 's', 't', 'a', 
-'g', 'e', '\022', '\037', '\n', '\013', 'd', 'i', 's', 'a', 'b', 'l', 'e', '_', 'k', 'e', 'y', '\030', '\002', ' ', '\001', '(', '\t', 'R', '\n', 
-'d', 'i', 's', 'a', 'b', 'l', 'e', 'K', 'e', 'y', '\022', 'K', '\n', '\007', 'a', 'c', 't', 'i', 'o', 'n', 's', '\030', '\003', ' ', '\003', 
-'(', '\013', '2', '\'', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', 
-'3', '.', 'R', 'a', 't', 'e', 'L', 'i', 'm', 'i', 't', '.', 'A', 'c', 't', 'i', 'o', 'n', 'B', '\010', '\372', 'B', '\005', '\222', '\001', 
-'\002', '\010', '\001', 'R', '\007', 'a', 'c', 't', 'i', 'o', 'n', 's', '\022', '?', '\n', '\005', 'l', 'i', 'm', 'i', 't', '\030', '\004', ' ', '\001', 
-'(', '\013', '2', ')', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', 
-'3', '.', 'R', 'a', 't', 'e', 'L', 'i', 'm', 'i', 't', '.', 'O', 'v', 'e', 'r', 'r', 'i', 'd', 'e', 'R', '\005', 'l', 'i', 'm', 
-'i', 't', '\032', '\226', '\022', '\n', '\006', 'A', 'c', 't', 'i', 'o', 'n', '\022', '^', '\n', '\016', 's', 'o', 'u', 'r', 'c', 'e', '_', 'c', 
-'l', 'u', 's', 't', 'e', 'r', '\030', '\001', ' ', '\001', '(', '\013', '2', '5', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 
-'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'R', 'a', 't', 'e', 'L', 'i', 'm', 'i', 't', '.', 'A', 'c', 't', 
-'i', 'o', 'n', '.', 'S', 'o', 'u', 'r', 'c', 'e', 'C', 'l', 'u', 's', 't', 'e', 'r', 'H', '\000', 'R', '\r', 's', 'o', 'u', 'r', 
-'c', 'e', 'C', 'l', 'u', 's', 't', 'e', 'r', '\022', 'm', '\n', '\023', 'd', 'e', 's', 't', 'i', 'n', 'a', 't', 'i', 'o', 'n', '_', 
-'c', 'l', 'u', 's', 't', 'e', 'r', '\030', '\002', ' ', '\001', '(', '\013', '2', ':', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 
-'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'R', 'a', 't', 'e', 'L', 'i', 'm', 'i', 't', '.', 'A', 'c', 
-'t', 'i', 'o', 'n', '.', 'D', 'e', 's', 't', 'i', 'n', 'a', 't', 'i', 'o', 'n', 'C', 'l', 'u', 's', 't', 'e', 'r', 'H', '\000', 
-'R', '\022', 'd', 'e', 's', 't', 'i', 'n', 'a', 't', 'i', 'o', 'n', 'C', 'l', 'u', 's', 't', 'e', 'r', '\022', 'a', '\n', '\017', 'r', 
-'e', 'q', 'u', 'e', 's', 't', '_', 'h', 'e', 'a', 'd', 'e', 'r', 's', '\030', '\003', ' ', '\001', '(', '\013', '2', '6', '.', 'e', 'n', 
-'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'R', 'a', 't', 'e', 'L', 
-'i', 'm', 'i', 't', '.', 'A', 'c', 't', 'i', 'o', 'n', '.', 'R', 'e', 'q', 'u', 'e', 's', 't', 'H', 'e', 'a', 'd', 'e', 'r', 
-'s', 'H', '\000', 'R', '\016', 'r', 'e', 'q', 'u', 'e', 's', 't', 'H', 'e', 'a', 'd', 'e', 'r', 's', '\022', '^', '\n', '\016', 'r', 'e', 
-'m', 'o', 't', 'e', '_', 'a', 'd', 'd', 'r', 'e', 's', 's', '\030', '\004', ' ', '\001', '(', '\013', '2', '5', '.', 'e', 'n', 'v', 'o', 
+'R', '\027', 'a', 'd', 'd', 'i', 't', 'i', 'o', 'n', 'a', 'l', 'R', 'e', 'q', 'u', 'e', 's', 't', 'C', 'h', 'a', 'n', 'c', 'e', 
+'\022', '6', '\n', '\030', 'h', 'e', 'd', 'g', 'e', '_', 'o', 'n', '_', 'p', 'e', 'r', '_', 't', 'r', 'y', '_', 't', 'i', 'm', 'e', 
+'o', 'u', 't', '\030', '\003', ' ', '\001', '(', '\010', 'R', '\024', 'h', 'e', 'd', 'g', 'e', 'O', 'n', 'P', 'e', 'r', 'T', 'r', 'y', 'T', 
+'i', 'm', 'e', 'o', 'u', 't', ':', '%', '\232', '\305', '\210', '\036', ' ', '\n', '\036', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 
+'v', '2', '.', 'r', 'o', 'u', 't', 'e', '.', 'H', 'e', 'd', 'g', 'e', 'P', 'o', 'l', 'i', 'c', 'y', '\"', '\341', '\005', '\n', '\016', 
+'R', 'e', 'd', 'i', 'r', 'e', 'c', 't', 'A', 'c', 't', 'i', 'o', 'n', '\022', '\'', '\n', '\016', 'h', 't', 't', 'p', 's', '_', 'r', 
+'e', 'd', 'i', 'r', 'e', 'c', 't', '\030', '\004', ' ', '\001', '(', '\010', 'H', '\000', 'R', '\r', 'h', 't', 't', 'p', 's', 'R', 'e', 'd', 
+'i', 'r', 'e', 'c', 't', '\022', ')', '\n', '\017', 's', 'c', 'h', 'e', 'm', 'e', '_', 'r', 'e', 'd', 'i', 'r', 'e', 'c', 't', '\030', 
+'\007', ' ', '\001', '(', '\t', 'H', '\000', 'R', '\016', 's', 'c', 'h', 'e', 'm', 'e', 'R', 'e', 'd', 'i', 'r', 'e', 'c', 't', '\022', '0', 
+'\n', '\r', 'h', 'o', 's', 't', '_', 'r', 'e', 'd', 'i', 'r', 'e', 'c', 't', '\030', '\001', ' ', '\001', '(', '\t', 'B', '\013', '\372', 'B', 
+'\010', 'r', '\006', '\300', '\001', '\002', '\310', '\001', '\000', 'R', '\014', 'h', 'o', 's', 't', 'R', 'e', 'd', 'i', 'r', 'e', 'c', 't', '\022', '#', 
+'\n', '\r', 'p', 'o', 'r', 't', '_', 'r', 'e', 'd', 'i', 'r', 'e', 'c', 't', '\030', '\010', ' ', '\001', '(', '\r', 'R', '\014', 'p', 'o', 
+'r', 't', 'R', 'e', 'd', 'i', 'r', 'e', 'c', 't', '\022', '2', '\n', '\r', 'p', 'a', 't', 'h', '_', 'r', 'e', 'd', 'i', 'r', 'e', 
+'c', 't', '\030', '\002', ' ', '\001', '(', '\t', 'B', '\013', '\372', 'B', '\010', 'r', '\006', '\300', '\001', '\002', '\310', '\001', '\000', 'H', '\001', 'R', '\014', 
+'p', 'a', 't', 'h', 'R', 'e', 'd', 'i', 'r', 'e', 'c', 't', '\022', '4', '\n', '\016', 'p', 'r', 'e', 'f', 'i', 'x', '_', 'r', 'e', 
+'w', 'r', 'i', 't', 'e', '\030', '\005', ' ', '\001', '(', '\t', 'B', '\013', '\372', 'B', '\010', 'r', '\006', '\300', '\001', '\002', '\310', '\001', '\000', 'H', 
+'\001', 'R', '\r', 'p', 'r', 'e', 'f', 'i', 'x', 'R', 'e', 'w', 'r', 'i', 't', 'e', '\022', 'U', '\n', '\r', 'r', 'e', 'g', 'e', 'x', 
+'_', 'r', 'e', 'w', 'r', 'i', 't', 'e', '\030', '\t', ' ', '\001', '(', '\013', '2', '.', '.', 'e', 'n', 'v', 'o', 'y', '.', 't', 'y', 
+'p', 'e', '.', 'm', 'a', 't', 'c', 'h', 'e', 'r', '.', 'v', '3', '.', 'R', 'e', 'g', 'e', 'x', 'M', 'a', 't', 'c', 'h', 'A', 
+'n', 'd', 'S', 'u', 'b', 's', 't', 'i', 't', 'u', 't', 'e', 'H', '\001', 'R', '\014', 'r', 'e', 'g', 'e', 'x', 'R', 'e', 'w', 'r', 
+'i', 't', 'e', '\022', 'i', '\n', '\r', 'r', 'e', 's', 'p', 'o', 'n', 's', 'e', '_', 'c', 'o', 'd', 'e', '\030', '\003', ' ', '\001', '(', 
+'\016', '2', ':', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', 
+'.', 'R', 'e', 'd', 'i', 'r', 'e', 'c', 't', 'A', 'c', 't', 'i', 'o', 'n', '.', 'R', 'e', 'd', 'i', 'r', 'e', 'c', 't', 'R', 
+'e', 's', 'p', 'o', 'n', 's', 'e', 'C', 'o', 'd', 'e', 'B', '\010', '\372', 'B', '\005', '\202', '\001', '\002', '\020', '\001', 'R', '\014', 'r', 'e', 
+'s', 'p', 'o', 'n', 's', 'e', 'C', 'o', 'd', 'e', '\022', '\037', '\n', '\013', 's', 't', 'r', 'i', 'p', '_', 'q', 'u', 'e', 'r', 'y', 
+'\030', '\006', ' ', '\001', '(', '\010', 'R', '\n', 's', 't', 'r', 'i', 'p', 'Q', 'u', 'e', 'r', 'y', '\"', 'w', '\n', '\024', 'R', 'e', 'd', 
+'i', 'r', 'e', 'c', 't', 'R', 'e', 's', 'p', 'o', 'n', 's', 'e', 'C', 'o', 'd', 'e', '\022', '\025', '\n', '\021', 'M', 'O', 'V', 'E', 
+'D', '_', 'P', 'E', 'R', 'M', 'A', 'N', 'E', 'N', 'T', 'L', 'Y', '\020', '\000', '\022', '\t', '\n', '\005', 'F', 'O', 'U', 'N', 'D', '\020', 
+'\001', '\022', '\r', '\n', '\t', 'S', 'E', 'E', '_', 'O', 'T', 'H', 'E', 'R', '\020', '\002', '\022', '\026', '\n', '\022', 'T', 'E', 'M', 'P', 'O', 
+'R', 'A', 'R', 'Y', '_', 'R', 'E', 'D', 'I', 'R', 'E', 'C', 'T', '\020', '\003', '\022', '\026', '\n', '\022', 'P', 'E', 'R', 'M', 'A', 'N', 
+'E', 'N', 'T', '_', 'R', 'E', 'D', 'I', 'R', 'E', 'C', 'T', '\020', '\004', ':', '(', '\232', '\305', '\210', '\036', '#', '\n', '!', 'e', 'n', 
+'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'r', 'o', 'u', 't', 'e', '.', 'R', 'e', 'd', 'i', 'r', 'e', 'c', 't', 
+'A', 'c', 't', 'i', 'o', 'n', 'B', '\032', '\n', '\030', 's', 'c', 'h', 'e', 'm', 'e', '_', 'r', 'e', 'w', 'r', 'i', 't', 'e', '_', 
+'s', 'p', 'e', 'c', 'i', 'f', 'i', 'e', 'r', 'B', '\030', '\n', '\026', 'p', 'a', 't', 'h', '_', 'r', 'e', 'w', 'r', 'i', 't', 'e', 
+'_', 's', 'p', 'e', 'c', 'i', 'f', 'i', 'e', 'r', '\"', '\240', '\001', '\n', '\024', 'D', 'i', 'r', 'e', 'c', 't', 'R', 'e', 's', 'p', 
+'o', 'n', 's', 'e', 'A', 'c', 't', 'i', 'o', 'n', '\022', '\"', '\n', '\006', 's', 't', 'a', 't', 'u', 's', '\030', '\001', ' ', '\001', '(', 
+'\r', 'B', '\n', '\372', 'B', '\007', '*', '\005', '\020', '\330', '\004', '(', 'd', 'R', '\006', 's', 't', 'a', 't', 'u', 's', '\022', '4', '\n', '\004', 
+'b', 'o', 'd', 'y', '\030', '\002', ' ', '\001', '(', '\013', '2', ' ', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', 
+'.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'D', 'a', 't', 'a', 'S', 'o', 'u', 'r', 'c', 'e', 'R', '\004', 'b', 'o', 'd', 'y', 
+':', '.', '\232', '\305', '\210', '\036', ')', '\n', '\'', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'r', 'o', 'u', 
+'t', 'e', '.', 'D', 'i', 'r', 'e', 'c', 't', 'R', 'e', 's', 'p', 'o', 'n', 's', 'e', 'A', 'c', 't', 'i', 'o', 'n', '\"', '\025', 
+'\n', '\023', 'N', 'o', 'n', 'F', 'o', 'r', 'w', 'a', 'r', 'd', 'i', 'n', 'g', 'A', 'c', 't', 'i', 'o', 'n', '\"', '\221', '\001', '\n', 
+'\t', 'D', 'e', 'c', 'o', 'r', 'a', 't', 'o', 'r', '\022', '%', '\n', '\t', 'o', 'p', 'e', 'r', 'a', 't', 'i', 'o', 'n', '\030', '\001', 
+' ', '\001', '(', '\t', 'B', '\007', '\372', 'B', '\004', 'r', '\002', '\020', '\001', 'R', '\t', 'o', 'p', 'e', 'r', 'a', 't', 'i', 'o', 'n', '\022', 
+'8', '\n', '\t', 'p', 'r', 'o', 'p', 'a', 'g', 'a', 't', 'e', '\030', '\002', ' ', '\001', '(', '\013', '2', '\032', '.', 'g', 'o', 'o', 'g', 
+'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'B', 'o', 'o', 'l', 'V', 'a', 'l', 'u', 'e', 'R', '\t', 'p', 'r', 
+'o', 'p', 'a', 'g', 'a', 't', 'e', ':', '#', '\232', '\305', '\210', '\036', '\036', '\n', '\034', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', 
+'.', 'v', '2', '.', 'r', 'o', 'u', 't', 'e', '.', 'D', 'e', 'c', 'o', 'r', 'a', 't', 'o', 'r', '\"', '\322', '\002', '\n', '\007', 'T', 
+'r', 'a', 'c', 'i', 'n', 'g', '\022', 'I', '\n', '\017', 'c', 'l', 'i', 'e', 'n', 't', '_', 's', 'a', 'm', 'p', 'l', 'i', 'n', 'g', 
+'\030', '\001', ' ', '\001', '(', '\013', '2', ' ', '.', 'e', 'n', 'v', 'o', 'y', '.', 't', 'y', 'p', 'e', '.', 'v', '3', '.', 'F', 'r', 
+'a', 'c', 't', 'i', 'o', 'n', 'a', 'l', 'P', 'e', 'r', 'c', 'e', 'n', 't', 'R', '\016', 'c', 'l', 'i', 'e', 'n', 't', 'S', 'a', 
+'m', 'p', 'l', 'i', 'n', 'g', '\022', 'I', '\n', '\017', 'r', 'a', 'n', 'd', 'o', 'm', '_', 's', 'a', 'm', 'p', 'l', 'i', 'n', 'g', 
+'\030', '\002', ' ', '\001', '(', '\013', '2', ' ', '.', 'e', 'n', 'v', 'o', 'y', '.', 't', 'y', 'p', 'e', '.', 'v', '3', '.', 'F', 'r', 
+'a', 'c', 't', 'i', 'o', 'n', 'a', 'l', 'P', 'e', 'r', 'c', 'e', 'n', 't', 'R', '\016', 'r', 'a', 'n', 'd', 'o', 'm', 'S', 'a', 
+'m', 'p', 'l', 'i', 'n', 'g', '\022', 'K', '\n', '\020', 'o', 'v', 'e', 'r', 'a', 'l', 'l', '_', 's', 'a', 'm', 'p', 'l', 'i', 'n', 
+'g', '\030', '\003', ' ', '\001', '(', '\013', '2', ' ', '.', 'e', 'n', 'v', 'o', 'y', '.', 't', 'y', 'p', 'e', '.', 'v', '3', '.', 'F', 
+'r', 'a', 'c', 't', 'i', 'o', 'n', 'a', 'l', 'P', 'e', 'r', 'c', 'e', 'n', 't', 'R', '\017', 'o', 'v', 'e', 'r', 'a', 'l', 'l', 
+'S', 'a', 'm', 'p', 'l', 'i', 'n', 'g', '\022', 'A', '\n', '\013', 'c', 'u', 's', 't', 'o', 'm', '_', 't', 'a', 'g', 's', '\030', '\004', 
+' ', '\003', '(', '\013', '2', ' ', '.', 'e', 'n', 'v', 'o', 'y', '.', 't', 'y', 'p', 'e', '.', 't', 'r', 'a', 'c', 'i', 'n', 'g', 
+'.', 'v', '3', '.', 'C', 'u', 's', 't', 'o', 'm', 'T', 'a', 'g', 'R', '\n', 'c', 'u', 's', 't', 'o', 'm', 'T', 'a', 'g', 's', 
+':', '!', '\232', '\305', '\210', '\036', '\034', '\n', '\032', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'r', 'o', 'u', 
+'t', 'e', '.', 'T', 'r', 'a', 'c', 'i', 'n', 'g', '\"', '\264', '\001', '\n', '\016', 'V', 'i', 'r', 't', 'u', 'a', 'l', 'C', 'l', 'u', 
+'s', 't', 'e', 'r', '\022', '>', '\n', '\007', 'h', 'e', 'a', 'd', 'e', 'r', 's', '\030', '\004', ' ', '\003', '(', '\013', '2', '$', '.', 'e', 
+'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'H', 'e', 'a', 'd', 
+'e', 'r', 'M', 'a', 't', 'c', 'h', 'e', 'r', 'R', '\007', 'h', 'e', 'a', 'd', 'e', 'r', 's', '\022', '\033', '\n', '\004', 'n', 'a', 'm', 
+'e', '\030', '\002', ' ', '\001', '(', '\t', 'B', '\007', '\372', 'B', '\004', 'r', '\002', '\020', '\001', 'R', '\004', 'n', 'a', 'm', 'e', ':', '(', '\232', 
+'\305', '\210', '\036', '#', '\n', '!', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'r', 'o', 'u', 't', 'e', '.', 
+'V', 'i', 'r', 't', 'u', 'a', 'l', 'C', 'l', 'u', 's', 't', 'e', 'r', 'J', '\004', '\010', '\001', '\020', '\002', 'J', '\004', '\010', '\003', '\020', 
+'\004', 'R', '\007', 'p', 'a', 't', 't', 'e', 'r', 'n', 'R', '\006', 'm', 'e', 't', 'h', 'o', 'd', '\"', '\252', '\026', '\n', '\t', 'R', 'a', 
+'t', 'e', 'L', 'i', 'm', 'i', 't', '\022', ';', '\n', '\005', 's', 't', 'a', 'g', 'e', '\030', '\001', ' ', '\001', '(', '\013', '2', '\034', '.', 
+'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'U', 'I', 'n', 't', '3', '2', 'V', 'a', 'l', 
+'u', 'e', 'B', '\007', '\372', 'B', '\004', '*', '\002', '\030', '\n', 'R', '\005', 's', 't', 'a', 'g', 'e', '\022', '\037', '\n', '\013', 'd', 'i', 's', 
+'a', 'b', 'l', 'e', '_', 'k', 'e', 'y', '\030', '\002', ' ', '\001', '(', '\t', 'R', '\n', 'd', 'i', 's', 'a', 'b', 'l', 'e', 'K', 'e', 
+'y', '\022', 'K', '\n', '\007', 'a', 'c', 't', 'i', 'o', 'n', 's', '\030', '\003', ' ', '\003', '(', '\013', '2', '\'', '.', 'e', 'n', 'v', 'o', 
+'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'R', 'a', 't', 'e', 'L', 'i', 'm', 
+'i', 't', '.', 'A', 'c', 't', 'i', 'o', 'n', 'B', '\010', '\372', 'B', '\005', '\222', '\001', '\002', '\010', '\001', 'R', '\007', 'a', 'c', 't', 'i', 
+'o', 'n', 's', '\022', '?', '\n', '\005', 'l', 'i', 'm', 'i', 't', '\030', '\004', ' ', '\001', '(', '\013', '2', ')', '.', 'e', 'n', 'v', 'o', 
 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'R', 'a', 't', 'e', 'L', 'i', 'm', 
-'i', 't', '.', 'A', 'c', 't', 'i', 'o', 'n', '.', 'R', 'e', 'm', 'o', 't', 'e', 'A', 'd', 'd', 'r', 'e', 's', 's', 'H', '\000', 
-'R', '\r', 'r', 'e', 'm', 'o', 't', 'e', 'A', 'd', 'd', 'r', 'e', 's', 's', '\022', 'U', '\n', '\013', 'g', 'e', 'n', 'e', 'r', 'i', 
-'c', '_', 'k', 'e', 'y', '\030', '\005', ' ', '\001', '(', '\013', '2', '2', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 
+'i', 't', '.', 'O', 'v', 'e', 'r', 'r', 'i', 'd', 'e', 'R', '\005', 'l', 'i', 'm', 'i', 't', '\032', '\226', '\022', '\n', '\006', 'A', 'c', 
+'t', 'i', 'o', 'n', '\022', '^', '\n', '\016', 's', 'o', 'u', 'r', 'c', 'e', '_', 'c', 'l', 'u', 's', 't', 'e', 'r', '\030', '\001', ' ', 
+'\001', '(', '\013', '2', '5', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 
+'v', '3', '.', 'R', 'a', 't', 'e', 'L', 'i', 'm', 'i', 't', '.', 'A', 'c', 't', 'i', 'o', 'n', '.', 'S', 'o', 'u', 'r', 'c', 
+'e', 'C', 'l', 'u', 's', 't', 'e', 'r', 'H', '\000', 'R', '\r', 's', 'o', 'u', 'r', 'c', 'e', 'C', 'l', 'u', 's', 't', 'e', 'r', 
+'\022', 'm', '\n', '\023', 'd', 'e', 's', 't', 'i', 'n', 'a', 't', 'i', 'o', 'n', '_', 'c', 'l', 'u', 's', 't', 'e', 'r', '\030', '\002', 
+' ', '\001', '(', '\013', '2', ':', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', 
+'.', 'v', '3', '.', 'R', 'a', 't', 'e', 'L', 'i', 'm', 'i', 't', '.', 'A', 'c', 't', 'i', 'o', 'n', '.', 'D', 'e', 's', 't', 
+'i', 'n', 'a', 't', 'i', 'o', 'n', 'C', 'l', 'u', 's', 't', 'e', 'r', 'H', '\000', 'R', '\022', 'd', 'e', 's', 't', 'i', 'n', 'a', 
+'t', 'i', 'o', 'n', 'C', 'l', 'u', 's', 't', 'e', 'r', '\022', 'a', '\n', '\017', 'r', 'e', 'q', 'u', 'e', 's', 't', '_', 'h', 'e', 
+'a', 'd', 'e', 'r', 's', '\030', '\003', ' ', '\001', '(', '\013', '2', '6', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 
 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'R', 'a', 't', 'e', 'L', 'i', 'm', 'i', 't', '.', 'A', 'c', 't', 'i', 
-'o', 'n', '.', 'G', 'e', 'n', 'e', 'r', 'i', 'c', 'K', 'e', 'y', 'H', '\000', 'R', '\n', 'g', 'e', 'n', 'e', 'r', 'i', 'c', 'K', 
-'e', 'y', '\022', 'h', '\n', '\022', 'h', 'e', 'a', 'd', 'e', 'r', '_', 'v', 'a', 'l', 'u', 'e', '_', 'm', 'a', 't', 'c', 'h', '\030', 
-'\006', ' ', '\001', '(', '\013', '2', '8', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 
-'e', '.', 'v', '3', '.', 'R', 'a', 't', 'e', 'L', 'i', 'm', 'i', 't', '.', 'A', 'c', 't', 'i', 'o', 'n', '.', 'H', 'e', 'a', 
-'d', 'e', 'r', 'V', 'a', 'l', 'u', 'e', 'M', 'a', 't', 'c', 'h', 'H', '\000', 'R', '\020', 'h', 'e', 'a', 'd', 'e', 'r', 'V', 'a', 
-'l', 'u', 'e', 'M', 'a', 't', 'c', 'h', '\022', 'w', '\n', '\020', 'd', 'y', 'n', 'a', 'm', 'i', 'c', '_', 'm', 'e', 't', 'a', 'd', 
-'a', 't', 'a', '\030', '\007', ' ', '\001', '(', '\013', '2', '7', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 
+'o', 'n', '.', 'R', 'e', 'q', 'u', 'e', 's', 't', 'H', 'e', 'a', 'd', 'e', 'r', 's', 'H', '\000', 'R', '\016', 'r', 'e', 'q', 'u', 
+'e', 's', 't', 'H', 'e', 'a', 'd', 'e', 'r', 's', '\022', '^', '\n', '\016', 'r', 'e', 'm', 'o', 't', 'e', '_', 'a', 'd', 'd', 'r', 
+'e', 's', 's', '\030', '\004', ' ', '\001', '(', '\013', '2', '5', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 
 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'R', 'a', 't', 'e', 'L', 'i', 'm', 'i', 't', '.', 'A', 'c', 't', 'i', 'o', 'n', 
-'.', 'D', 'y', 'n', 'a', 'm', 'i', 'c', 'M', 'e', 't', 'a', 'D', 'a', 't', 'a', 'B', '\021', '\030', '\001', '\222', '\307', '\206', '\330', '\004', 
-'\003', '3', '.', '0', '\270', '\356', '\362', '\322', '\005', '\001', 'H', '\000', 'R', '\017', 'd', 'y', 'n', 'a', 'm', 'i', 'c', 'M', 'e', 't', 'a', 
-'d', 'a', 't', 'a', '\022', 'N', '\n', '\010', 'm', 'e', 't', 'a', 'd', 'a', 't', 'a', '\030', '\010', ' ', '\001', '(', '\013', '2', '0', '.', 
-'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'R', 'a', 't', 
-'e', 'L', 'i', 'm', 'i', 't', '.', 'A', 'c', 't', 'i', 'o', 'n', '.', 'M', 'e', 't', 'a', 'D', 'a', 't', 'a', 'H', '\000', 'R', 
-'\010', 'm', 'e', 't', 'a', 'd', 'a', 't', 'a', '\022', 'J', '\n', '\t', 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', '\030', '\t', ' ', 
-'\001', '(', '\013', '2', '*', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', 
-'3', '.', 'T', 'y', 'p', 'e', 'd', 'E', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 'C', 'o', 'n', 'f', 'i', 'g', 'H', '\000', 'R', 
-'\t', 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', '\032', 'I', '\n', '\r', 'S', 'o', 'u', 'r', 'c', 'e', 'C', 'l', 'u', 's', 't', 
-'e', 'r', ':', '8', '\232', '\305', '\210', '\036', '3', '\n', '1', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'r', 
-'o', 'u', 't', 'e', '.', 'R', 'a', 't', 'e', 'L', 'i', 'm', 'i', 't', '.', 'A', 'c', 't', 'i', 'o', 'n', '.', 'S', 'o', 'u', 
-'r', 'c', 'e', 'C', 'l', 'u', 's', 't', 'e', 'r', '\032', 'S', '\n', '\022', 'D', 'e', 's', 't', 'i', 'n', 'a', 't', 'i', 'o', 'n', 
-'C', 'l', 'u', 's', 't', 'e', 'r', ':', '=', '\232', '\305', '\210', '\036', '8', '\n', '6', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', 
-'.', 'v', '2', '.', 'r', 'o', 'u', 't', 'e', '.', 'R', 'a', 't', 'e', 'L', 'i', 'm', 'i', 't', '.', 'A', 'c', 't', 'i', 'o', 
-'n', '.', 'D', 'e', 's', 't', 'i', 'n', 'a', 't', 'i', 'o', 'n', 'C', 'l', 'u', 's', 't', 'e', 'r', '\032', '\321', '\001', '\n', '\016', 
-'R', 'e', 'q', 'u', 'e', 's', 't', 'H', 'e', 'a', 'd', 'e', 'r', 's', '\022', '.', '\n', '\013', 'h', 'e', 'a', 'd', 'e', 'r', '_', 
-'n', 'a', 'm', 'e', '\030', '\001', ' ', '\001', '(', '\t', 'B', '\r', '\372', 'B', '\n', 'r', '\010', '\020', '\001', '\300', '\001', '\001', '\310', '\001', '\000', 
-'R', '\n', 'h', 'e', 'a', 'd', 'e', 'r', 'N', 'a', 'm', 'e', '\022', '.', '\n', '\016', 'd', 'e', 's', 'c', 'r', 'i', 'p', 't', 'o', 
-'r', '_', 'k', 'e', 'y', '\030', '\002', ' ', '\001', '(', '\t', 'B', '\007', '\372', 'B', '\004', 'r', '\002', '\020', '\001', 'R', '\r', 'd', 'e', 's', 
-'c', 'r', 'i', 'p', 't', 'o', 'r', 'K', 'e', 'y', '\022', '$', '\n', '\016', 's', 'k', 'i', 'p', '_', 'i', 'f', '_', 'a', 'b', 's', 
-'e', 'n', 't', '\030', '\003', ' ', '\001', '(', '\010', 'R', '\014', 's', 'k', 'i', 'p', 'I', 'f', 'A', 'b', 's', 'e', 'n', 't', ':', '9', 
-'\232', '\305', '\210', '\036', '4', '\n', '2', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'r', 'o', 'u', 't', 'e', 
-'.', 'R', 'a', 't', 'e', 'L', 'i', 'm', 'i', 't', '.', 'A', 'c', 't', 'i', 'o', 'n', '.', 'R', 'e', 'q', 'u', 'e', 's', 't', 
-'H', 'e', 'a', 'd', 'e', 'r', 's', '\032', 'I', '\n', '\r', 'R', 'e', 'm', 'o', 't', 'e', 'A', 'd', 'd', 'r', 'e', 's', 's', ':', 
-'8', '\232', '\305', '\210', '\036', '3', '\n', '1', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'r', 'o', 'u', 't', 
-'e', '.', 'R', 'a', 't', 'e', 'L', 'i', 'm', 'i', 't', '.', 'A', 'c', 't', 'i', 'o', 'n', '.', 'R', 'e', 'm', 'o', 't', 'e', 
-'A', 'd', 'd', 'r', 'e', 's', 's', '\032', '\236', '\001', '\n', '\n', 'G', 'e', 'n', 'e', 'r', 'i', 'c', 'K', 'e', 'y', '\022', '2', '\n', 
-'\020', 'd', 'e', 's', 'c', 'r', 'i', 'p', 't', 'o', 'r', '_', 'v', 'a', 'l', 'u', 'e', '\030', '\001', ' ', '\001', '(', '\t', 'B', '\007', 
-'\372', 'B', '\004', 'r', '\002', '\020', '\001', 'R', '\017', 'd', 'e', 's', 'c', 'r', 'i', 'p', 't', 'o', 'r', 'V', 'a', 'l', 'u', 'e', '\022', 
-'%', '\n', '\016', 'd', 'e', 's', 'c', 'r', 'i', 'p', 't', 'o', 'r', '_', 'k', 'e', 'y', '\030', '\002', ' ', '\001', '(', '\t', 'R', '\r', 
-'d', 'e', 's', 'c', 'r', 'i', 'p', 't', 'o', 'r', 'K', 'e', 'y', ':', '5', '\232', '\305', '\210', '\036', '0', '\n', '.', 'e', 'n', 'v', 
-'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'r', 'o', 'u', 't', 'e', '.', 'R', 'a', 't', 'e', 'L', 'i', 'm', 'i', 't', 
-'.', 'A', 'c', 't', 'i', 'o', 'n', '.', 'G', 'e', 'n', 'e', 'r', 'i', 'c', 'K', 'e', 'y', '\032', '\214', '\002', '\n', '\020', 'H', 'e', 
-'a', 'd', 'e', 'r', 'V', 'a', 'l', 'u', 'e', 'M', 'a', 't', 'c', 'h', '\022', '2', '\n', '\020', 'd', 'e', 's', 'c', 'r', 'i', 'p', 
-'t', 'o', 'r', '_', 'v', 'a', 'l', 'u', 'e', '\030', '\001', ' ', '\001', '(', '\t', 'B', '\007', '\372', 'B', '\004', 'r', '\002', '\020', '\001', 'R', 
-'\017', 'd', 'e', 's', 'c', 'r', 'i', 'p', 't', 'o', 'r', 'V', 'a', 'l', 'u', 'e', '\022', '=', '\n', '\014', 'e', 'x', 'p', 'e', 'c', 
-'t', '_', 'm', 'a', 't', 'c', 'h', '\030', '\002', ' ', '\001', '(', '\013', '2', '\032', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 
-'o', 't', 'o', 'b', 'u', 'f', '.', 'B', 'o', 'o', 'l', 'V', 'a', 'l', 'u', 'e', 'R', '\013', 'e', 'x', 'p', 'e', 'c', 't', 'M', 
-'a', 't', 'c', 'h', '\022', 'H', '\n', '\007', 'h', 'e', 'a', 'd', 'e', 'r', 's', '\030', '\003', ' ', '\003', '(', '\013', '2', '$', '.', 'e', 
-'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'H', 'e', 'a', 'd', 
-'e', 'r', 'M', 'a', 't', 'c', 'h', 'e', 'r', 'B', '\010', '\372', 'B', '\005', '\222', '\001', '\002', '\010', '\001', 'R', '\007', 'h', 'e', 'a', 'd', 
-'e', 'r', 's', ':', ';', '\232', '\305', '\210', '\036', '6', '\n', '4', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 
-'r', 'o', 'u', 't', 'e', '.', 'R', 'a', 't', 'e', 'L', 'i', 'm', 'i', 't', '.', 'A', 'c', 't', 'i', 'o', 'n', '.', 'H', 'e', 
-'a', 'd', 'e', 'r', 'V', 'a', 'l', 'u', 'e', 'M', 'a', 't', 'c', 'h', '\032', '\270', '\001', '\n', '\017', 'D', 'y', 'n', 'a', 'm', 'i', 
-'c', 'M', 'e', 't', 'a', 'D', 'a', 't', 'a', '\022', '.', '\n', '\016', 'd', 'e', 's', 'c', 'r', 'i', 'p', 't', 'o', 'r', '_', 'k', 
-'e', 'y', '\030', '\001', ' ', '\001', '(', '\t', 'B', '\007', '\372', 'B', '\004', 'r', '\002', '\020', '\001', 'R', '\r', 'd', 'e', 's', 'c', 'r', 'i', 
-'p', 't', 'o', 'r', 'K', 'e', 'y', '\022', 'P', '\n', '\014', 'm', 'e', 't', 'a', 'd', 'a', 't', 'a', '_', 'k', 'e', 'y', '\030', '\002', 
-' ', '\001', '(', '\013', '2', '#', '.', 'e', 'n', 'v', 'o', 'y', '.', 't', 'y', 'p', 'e', '.', 'm', 'e', 't', 'a', 'd', 'a', 't', 
-'a', '.', 'v', '3', '.', 'M', 'e', 't', 'a', 'd', 'a', 't', 'a', 'K', 'e', 'y', 'B', '\010', '\372', 'B', '\005', '\212', '\001', '\002', '\020', 
-'\001', 'R', '\013', 'm', 'e', 't', 'a', 'd', 'a', 't', 'a', 'K', 'e', 'y', '\022', '#', '\n', '\r', 'd', 'e', 'f', 'a', 'u', 'l', 't', 
-'_', 'v', 'a', 'l', 'u', 'e', '\030', '\003', ' ', '\001', '(', '\t', 'R', '\014', 'd', 'e', 'f', 'a', 'u', 'l', 't', 'V', 'a', 'l', 'u', 
-'e', '\032', '\264', '\002', '\n', '\010', 'M', 'e', 't', 'a', 'D', 'a', 't', 'a', '\022', '.', '\n', '\016', 'd', 'e', 's', 'c', 'r', 'i', 'p', 
-'t', 'o', 'r', '_', 'k', 'e', 'y', '\030', '\001', ' ', '\001', '(', '\t', 'B', '\007', '\372', 'B', '\004', 'r', '\002', '\020', '\001', 'R', '\r', 'd', 
-'e', 's', 'c', 'r', 'i', 'p', 't', 'o', 'r', 'K', 'e', 'y', '\022', 'P', '\n', '\014', 'm', 'e', 't', 'a', 'd', 'a', 't', 'a', '_', 
-'k', 'e', 'y', '\030', '\002', ' ', '\001', '(', '\013', '2', '#', '.', 'e', 'n', 'v', 'o', 'y', '.', 't', 'y', 'p', 'e', '.', 'm', 'e', 
-'t', 'a', 'd', 'a', 't', 'a', '.', 'v', '3', '.', 'M', 'e', 't', 'a', 'd', 'a', 't', 'a', 'K', 'e', 'y', 'B', '\010', '\372', 'B', 
-'\005', '\212', '\001', '\002', '\020', '\001', 'R', '\013', 'm', 'e', 't', 'a', 'd', 'a', 't', 'a', 'K', 'e', 'y', '\022', '#', '\n', '\r', 'd', 'e', 
-'f', 'a', 'u', 'l', 't', '_', 'v', 'a', 'l', 'u', 'e', '\030', '\003', ' ', '\001', '(', '\t', 'R', '\014', 'd', 'e', 'f', 'a', 'u', 'l', 
-'t', 'V', 'a', 'l', 'u', 'e', '\022', 'Y', '\n', '\006', 's', 'o', 'u', 'r', 'c', 'e', '\030', '\004', ' ', '\001', '(', '\016', '2', '7', '.', 
-'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'R', 'a', 't', 
-'e', 'L', 'i', 'm', 'i', 't', '.', 'A', 'c', 't', 'i', 'o', 'n', '.', 'M', 'e', 't', 'a', 'D', 'a', 't', 'a', '.', 'S', 'o', 
-'u', 'r', 'c', 'e', 'B', '\010', '\372', 'B', '\005', '\202', '\001', '\002', '\020', '\001', 'R', '\006', 's', 'o', 'u', 'r', 'c', 'e', '\"', '&', '\n', 
-'\006', 'S', 'o', 'u', 'r', 'c', 'e', '\022', '\013', '\n', '\007', 'D', 'Y', 'N', 'A', 'M', 'I', 'C', '\020', '\000', '\022', '\017', '\n', '\013', 'R', 
-'O', 'U', 'T', 'E', '_', 'E', 'N', 'T', 'R', 'Y', '\020', '\001', ':', '*', '\232', '\305', '\210', '\036', '%', '\n', '#', 'e', 'n', 'v', 'o', 
-'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'r', 'o', 'u', 't', 'e', '.', 'R', 'a', 't', 'e', 'L', 'i', 'm', 'i', 't', '.', 
-'A', 'c', 't', 'i', 'o', 'n', 'B', '\027', '\n', '\020', 'a', 'c', 't', 'i', 'o', 'n', '_', 's', 'p', 'e', 'c', 'i', 'f', 'i', 'e', 
-'r', '\022', '\003', '\370', 'B', '\001', '\032', '\362', '\001', '\n', '\010', 'O', 'v', 'e', 'r', 'r', 'i', 'd', 'e', '\022', 'f', '\n', '\020', 'd', 'y', 
-'n', 'a', 'm', 'i', 'c', '_', 'm', 'e', 't', 'a', 'd', 'a', 't', 'a', '\030', '\001', ' ', '\001', '(', '\013', '2', '9', '.', 'e', 'n', 
-'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'R', 'a', 't', 'e', 'L', 
-'i', 'm', 'i', 't', '.', 'O', 'v', 'e', 'r', 'r', 'i', 'd', 'e', '.', 'D', 'y', 'n', 'a', 'm', 'i', 'c', 'M', 'e', 't', 'a', 
-'d', 'a', 't', 'a', 'H', '\000', 'R', '\017', 'd', 'y', 'n', 'a', 'm', 'i', 'c', 'M', 'e', 't', 'a', 'd', 'a', 't', 'a', '\032', 'c', 
-'\n', '\017', 'D', 'y', 'n', 'a', 'm', 'i', 'c', 'M', 'e', 't', 'a', 'd', 'a', 't', 'a', '\022', 'P', '\n', '\014', 'm', 'e', 't', 'a', 
-'d', 'a', 't', 'a', '_', 'k', 'e', 'y', '\030', '\001', ' ', '\001', '(', '\013', '2', '#', '.', 'e', 'n', 'v', 'o', 'y', '.', 't', 'y', 
-'p', 'e', '.', 'm', 'e', 't', 'a', 'd', 'a', 't', 'a', '.', 'v', '3', '.', 'M', 'e', 't', 'a', 'd', 'a', 't', 'a', 'K', 'e', 
-'y', 'B', '\010', '\372', 'B', '\005', '\212', '\001', '\002', '\020', '\001', 'R', '\013', 'm', 'e', 't', 'a', 'd', 'a', 't', 'a', 'K', 'e', 'y', 'B', 
-'\031', '\n', '\022', 'o', 'v', 'e', 'r', 'r', 'i', 'd', 'e', '_', 's', 'p', 'e', 'c', 'i', 'f', 'i', 'e', 'r', '\022', '\003', '\370', 'B', 
-'\001', ':', '#', '\232', '\305', '\210', '\036', '\036', '\n', '\034', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'r', 'o', 
-'u', 't', 'e', '.', 'R', 'a', 't', 'e', 'L', 'i', 'm', 'i', 't', '\"', '\244', '\005', '\n', '\r', 'H', 'e', 'a', 'd', 'e', 'r', 'M', 
-'a', 't', 'c', 'h', 'e', 'r', '\022', '!', '\n', '\004', 'n', 'a', 'm', 'e', '\030', '\001', ' ', '\001', '(', '\t', 'B', '\r', '\372', 'B', '\n', 
-'r', '\010', '\020', '\001', '\300', '\001', '\001', '\310', '\001', '\000', 'R', '\004', 'n', 'a', 'm', 'e', '\022', '.', '\n', '\013', 'e', 'x', 'a', 'c', 't', 
-'_', 'm', 'a', 't', 'c', 'h', '\030', '\004', ' ', '\001', '(', '\t', 'B', '\013', '\030', '\001', '\222', '\307', '\206', '\330', '\004', '\003', '3', '.', '0', 
-'H', '\000', 'R', '\n', 'e', 'x', 'a', 'c', 't', 'M', 'a', 't', 'c', 'h', '\022', '\\', '\n', '\020', 's', 'a', 'f', 'e', '_', 'r', 'e', 
-'g', 'e', 'x', '_', 'm', 'a', 't', 'c', 'h', '\030', '\013', ' ', '\001', '(', '\013', '2', '#', '.', 'e', 'n', 'v', 'o', 'y', '.', 't', 
-'y', 'p', 'e', '.', 'm', 'a', 't', 'c', 'h', 'e', 'r', '.', 'v', '3', '.', 'R', 'e', 'g', 'e', 'x', 'M', 'a', 't', 'c', 'h', 
-'e', 'r', 'B', '\013', '\030', '\001', '\222', '\307', '\206', '\330', '\004', '\003', '3', '.', '0', 'H', '\000', 'R', '\016', 's', 'a', 'f', 'e', 'R', 'e', 
-'g', 'e', 'x', 'M', 'a', 't', 'c', 'h', '\022', '<', '\n', '\013', 'r', 'a', 'n', 'g', 'e', '_', 'm', 'a', 't', 'c', 'h', '\030', '\006', 
-' ', '\001', '(', '\013', '2', '\031', '.', 'e', 'n', 'v', 'o', 'y', '.', 't', 'y', 'p', 'e', '.', 'v', '3', '.', 'I', 'n', 't', '6', 
-'4', 'R', 'a', 'n', 'g', 'e', 'H', '\000', 'R', '\n', 'r', 'a', 'n', 'g', 'e', 'M', 'a', 't', 'c', 'h', '\022', '%', '\n', '\r', 'p', 
-'r', 'e', 's', 'e', 'n', 't', '_', 'm', 'a', 't', 'c', 'h', '\030', '\007', ' ', '\001', '(', '\010', 'H', '\000', 'R', '\014', 'p', 'r', 'e', 
-'s', 'e', 'n', 't', 'M', 'a', 't', 'c', 'h', '\022', '7', '\n', '\014', 'p', 'r', 'e', 'f', 'i', 'x', '_', 'm', 'a', 't', 'c', 'h', 
-'\030', '\t', ' ', '\001', '(', '\t', 'B', '\022', '\030', '\001', '\372', 'B', '\004', 'r', '\002', '\020', '\001', '\222', '\307', '\206', '\330', '\004', '\003', '3', '.', 
-'0', 'H', '\000', 'R', '\013', 'p', 'r', 'e', 'f', 'i', 'x', 'M', 'a', 't', 'c', 'h', '\022', '7', '\n', '\014', 's', 'u', 'f', 'f', 'i', 
-'x', '_', 'm', 'a', 't', 'c', 'h', '\030', '\n', ' ', '\001', '(', '\t', 'B', '\022', '\030', '\001', '\372', 'B', '\004', 'r', '\002', '\020', '\001', '\222', 
-'\307', '\206', '\330', '\004', '\003', '3', '.', '0', 'H', '\000', 'R', '\013', 's', 'u', 'f', 'f', 'i', 'x', 'M', 'a', 't', 'c', 'h', '\022', ';', 
-'\n', '\016', 'c', 'o', 'n', 't', 'a', 'i', 'n', 's', '_', 'm', 'a', 't', 'c', 'h', '\030', '\014', ' ', '\001', '(', '\t', 'B', '\022', '\030', 
-'\001', '\372', 'B', '\004', 'r', '\002', '\020', '\001', '\222', '\307', '\206', '\330', '\004', '\003', '3', '.', '0', 'H', '\000', 'R', '\r', 'c', 'o', 'n', 't', 
-'a', 'i', 'n', 's', 'M', 'a', 't', 'c', 'h', '\022', 'I', '\n', '\014', 's', 't', 'r', 'i', 'n', 'g', '_', 'm', 'a', 't', 'c', 'h', 
-'\030', '\r', ' ', '\001', '(', '\013', '2', '$', '.', 'e', 'n', 'v', 'o', 'y', '.', 't', 'y', 'p', 'e', '.', 'm', 'a', 't', 'c', 'h', 
-'e', 'r', '.', 'v', '3', '.', 'S', 't', 'r', 'i', 'n', 'g', 'M', 'a', 't', 'c', 'h', 'e', 'r', 'H', '\000', 'R', '\013', 's', 't', 
-'r', 'i', 'n', 'g', 'M', 'a', 't', 'c', 'h', '\022', '!', '\n', '\014', 'i', 'n', 'v', 'e', 'r', 't', '_', 'm', 'a', 't', 'c', 'h', 
-'\030', '\010', ' ', '\001', '(', '\010', 'R', '\013', 'i', 'n', 'v', 'e', 'r', 't', 'M', 'a', 't', 'c', 'h', ':', '\'', '\232', '\305', '\210', '\036', 
-'\"', '\n', ' ', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'r', 'o', 'u', 't', 'e', '.', 'H', 'e', 'a', 
-'d', 'e', 'r', 'M', 'a', 't', 'c', 'h', 'e', 'r', 'B', '\030', '\n', '\026', 'h', 'e', 'a', 'd', 'e', 'r', '_', 'm', 'a', 't', 'c', 
-'h', '_', 's', 'p', 'e', 'c', 'i', 'f', 'i', 'e', 'r', 'J', '\004', '\010', '\002', '\020', '\003', 'J', '\004', '\010', '\003', '\020', '\004', 'J', '\004', 
-'\010', '\005', '\020', '\006', 'R', '\013', 'r', 'e', 'g', 'e', 'x', '_', 'm', 'a', 't', 'c', 'h', '\"', '\241', '\002', '\n', '\025', 'Q', 'u', 'e', 
-'r', 'y', 'P', 'a', 'r', 'a', 'm', 'e', 't', 'e', 'r', 'M', 'a', 't', 'c', 'h', 'e', 'r', '\022', '\036', '\n', '\004', 'n', 'a', 'm', 
-'e', '\030', '\001', ' ', '\001', '(', '\t', 'B', '\n', '\372', 'B', '\007', 'r', '\005', '\020', '\001', '(', '\200', '\010', 'R', '\004', 'n', 'a', 'm', 'e', 
-'\022', 'S', '\n', '\014', 's', 't', 'r', 'i', 'n', 'g', '_', 'm', 'a', 't', 'c', 'h', '\030', '\005', ' ', '\001', '(', '\013', '2', '$', '.', 
+'.', 'R', 'e', 'm', 'o', 't', 'e', 'A', 'd', 'd', 'r', 'e', 's', 's', 'H', '\000', 'R', '\r', 'r', 'e', 'm', 'o', 't', 'e', 'A', 
+'d', 'd', 'r', 'e', 's', 's', '\022', 'U', '\n', '\013', 'g', 'e', 'n', 'e', 'r', 'i', 'c', '_', 'k', 'e', 'y', '\030', '\005', ' ', '\001', 
+'(', '\013', '2', '2', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', 
+'3', '.', 'R', 'a', 't', 'e', 'L', 'i', 'm', 'i', 't', '.', 'A', 'c', 't', 'i', 'o', 'n', '.', 'G', 'e', 'n', 'e', 'r', 'i', 
+'c', 'K', 'e', 'y', 'H', '\000', 'R', '\n', 'g', 'e', 'n', 'e', 'r', 'i', 'c', 'K', 'e', 'y', '\022', 'h', '\n', '\022', 'h', 'e', 'a', 
+'d', 'e', 'r', '_', 'v', 'a', 'l', 'u', 'e', '_', 'm', 'a', 't', 'c', 'h', '\030', '\006', ' ', '\001', '(', '\013', '2', '8', '.', 'e', 
+'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'R', 'a', 't', 'e', 
+'L', 'i', 'm', 'i', 't', '.', 'A', 'c', 't', 'i', 'o', 'n', '.', 'H', 'e', 'a', 'd', 'e', 'r', 'V', 'a', 'l', 'u', 'e', 'M', 
+'a', 't', 'c', 'h', 'H', '\000', 'R', '\020', 'h', 'e', 'a', 'd', 'e', 'r', 'V', 'a', 'l', 'u', 'e', 'M', 'a', 't', 'c', 'h', '\022', 
+'w', '\n', '\020', 'd', 'y', 'n', 'a', 'm', 'i', 'c', '_', 'm', 'e', 't', 'a', 'd', 'a', 't', 'a', '\030', '\007', ' ', '\001', '(', '\013', 
+'2', '7', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 
+'R', 'a', 't', 'e', 'L', 'i', 'm', 'i', 't', '.', 'A', 'c', 't', 'i', 'o', 'n', '.', 'D', 'y', 'n', 'a', 'm', 'i', 'c', 'M', 
+'e', 't', 'a', 'D', 'a', 't', 'a', 'B', '\021', '\030', '\001', '\222', '\307', '\206', '\330', '\004', '\003', '3', '.', '0', '\270', '\356', '\362', '\322', '\005', 
+'\001', 'H', '\000', 'R', '\017', 'd', 'y', 'n', 'a', 'm', 'i', 'c', 'M', 'e', 't', 'a', 'd', 'a', 't', 'a', '\022', 'N', '\n', '\010', 'm', 
+'e', 't', 'a', 'd', 'a', 't', 'a', '\030', '\010', ' ', '\001', '(', '\013', '2', '0', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 
+'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'R', 'a', 't', 'e', 'L', 'i', 'm', 'i', 't', '.', 'A', 'c', 
+'t', 'i', 'o', 'n', '.', 'M', 'e', 't', 'a', 'D', 'a', 't', 'a', 'H', '\000', 'R', '\010', 'm', 'e', 't', 'a', 'd', 'a', 't', 'a', 
+'\022', 'J', '\n', '\t', 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', '\030', '\t', ' ', '\001', '(', '\013', '2', '*', '.', 'e', 'n', 'v', 
+'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'T', 'y', 'p', 'e', 'd', 'E', 'x', 
+'t', 'e', 'n', 's', 'i', 'o', 'n', 'C', 'o', 'n', 'f', 'i', 'g', 'H', '\000', 'R', '\t', 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 
+'n', '\032', 'I', '\n', '\r', 'S', 'o', 'u', 'r', 'c', 'e', 'C', 'l', 'u', 's', 't', 'e', 'r', ':', '8', '\232', '\305', '\210', '\036', '3', 
+'\n', '1', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'r', 'o', 'u', 't', 'e', '.', 'R', 'a', 't', 'e', 
+'L', 'i', 'm', 'i', 't', '.', 'A', 'c', 't', 'i', 'o', 'n', '.', 'S', 'o', 'u', 'r', 'c', 'e', 'C', 'l', 'u', 's', 't', 'e', 
+'r', '\032', 'S', '\n', '\022', 'D', 'e', 's', 't', 'i', 'n', 'a', 't', 'i', 'o', 'n', 'C', 'l', 'u', 's', 't', 'e', 'r', ':', '=', 
+'\232', '\305', '\210', '\036', '8', '\n', '6', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'r', 'o', 'u', 't', 'e', 
+'.', 'R', 'a', 't', 'e', 'L', 'i', 'm', 'i', 't', '.', 'A', 'c', 't', 'i', 'o', 'n', '.', 'D', 'e', 's', 't', 'i', 'n', 'a', 
+'t', 'i', 'o', 'n', 'C', 'l', 'u', 's', 't', 'e', 'r', '\032', '\321', '\001', '\n', '\016', 'R', 'e', 'q', 'u', 'e', 's', 't', 'H', 'e', 
+'a', 'd', 'e', 'r', 's', '\022', '.', '\n', '\013', 'h', 'e', 'a', 'd', 'e', 'r', '_', 'n', 'a', 'm', 'e', '\030', '\001', ' ', '\001', '(', 
+'\t', 'B', '\r', '\372', 'B', '\n', 'r', '\010', '\020', '\001', '\300', '\001', '\001', '\310', '\001', '\000', 'R', '\n', 'h', 'e', 'a', 'd', 'e', 'r', 'N', 
+'a', 'm', 'e', '\022', '.', '\n', '\016', 'd', 'e', 's', 'c', 'r', 'i', 'p', 't', 'o', 'r', '_', 'k', 'e', 'y', '\030', '\002', ' ', '\001', 
+'(', '\t', 'B', '\007', '\372', 'B', '\004', 'r', '\002', '\020', '\001', 'R', '\r', 'd', 'e', 's', 'c', 'r', 'i', 'p', 't', 'o', 'r', 'K', 'e', 
+'y', '\022', '$', '\n', '\016', 's', 'k', 'i', 'p', '_', 'i', 'f', '_', 'a', 'b', 's', 'e', 'n', 't', '\030', '\003', ' ', '\001', '(', '\010', 
+'R', '\014', 's', 'k', 'i', 'p', 'I', 'f', 'A', 'b', 's', 'e', 'n', 't', ':', '9', '\232', '\305', '\210', '\036', '4', '\n', '2', 'e', 'n', 
+'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'r', 'o', 'u', 't', 'e', '.', 'R', 'a', 't', 'e', 'L', 'i', 'm', 'i', 
+'t', '.', 'A', 'c', 't', 'i', 'o', 'n', '.', 'R', 'e', 'q', 'u', 'e', 's', 't', 'H', 'e', 'a', 'd', 'e', 'r', 's', '\032', 'I', 
+'\n', '\r', 'R', 'e', 'm', 'o', 't', 'e', 'A', 'd', 'd', 'r', 'e', 's', 's', ':', '8', '\232', '\305', '\210', '\036', '3', '\n', '1', 'e', 
+'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'r', 'o', 'u', 't', 'e', '.', 'R', 'a', 't', 'e', 'L', 'i', 'm', 
+'i', 't', '.', 'A', 'c', 't', 'i', 'o', 'n', '.', 'R', 'e', 'm', 'o', 't', 'e', 'A', 'd', 'd', 'r', 'e', 's', 's', '\032', '\236', 
+'\001', '\n', '\n', 'G', 'e', 'n', 'e', 'r', 'i', 'c', 'K', 'e', 'y', '\022', '2', '\n', '\020', 'd', 'e', 's', 'c', 'r', 'i', 'p', 't', 
+'o', 'r', '_', 'v', 'a', 'l', 'u', 'e', '\030', '\001', ' ', '\001', '(', '\t', 'B', '\007', '\372', 'B', '\004', 'r', '\002', '\020', '\001', 'R', '\017', 
+'d', 'e', 's', 'c', 'r', 'i', 'p', 't', 'o', 'r', 'V', 'a', 'l', 'u', 'e', '\022', '%', '\n', '\016', 'd', 'e', 's', 'c', 'r', 'i', 
+'p', 't', 'o', 'r', '_', 'k', 'e', 'y', '\030', '\002', ' ', '\001', '(', '\t', 'R', '\r', 'd', 'e', 's', 'c', 'r', 'i', 'p', 't', 'o', 
+'r', 'K', 'e', 'y', ':', '5', '\232', '\305', '\210', '\036', '0', '\n', '.', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', 
+'.', 'r', 'o', 'u', 't', 'e', '.', 'R', 'a', 't', 'e', 'L', 'i', 'm', 'i', 't', '.', 'A', 'c', 't', 'i', 'o', 'n', '.', 'G', 
+'e', 'n', 'e', 'r', 'i', 'c', 'K', 'e', 'y', '\032', '\214', '\002', '\n', '\020', 'H', 'e', 'a', 'd', 'e', 'r', 'V', 'a', 'l', 'u', 'e', 
+'M', 'a', 't', 'c', 'h', '\022', '2', '\n', '\020', 'd', 'e', 's', 'c', 'r', 'i', 'p', 't', 'o', 'r', '_', 'v', 'a', 'l', 'u', 'e', 
+'\030', '\001', ' ', '\001', '(', '\t', 'B', '\007', '\372', 'B', '\004', 'r', '\002', '\020', '\001', 'R', '\017', 'd', 'e', 's', 'c', 'r', 'i', 'p', 't', 
+'o', 'r', 'V', 'a', 'l', 'u', 'e', '\022', '=', '\n', '\014', 'e', 'x', 'p', 'e', 'c', 't', '_', 'm', 'a', 't', 'c', 'h', '\030', '\002', 
+' ', '\001', '(', '\013', '2', '\032', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'B', 'o', 
+'o', 'l', 'V', 'a', 'l', 'u', 'e', 'R', '\013', 'e', 'x', 'p', 'e', 'c', 't', 'M', 'a', 't', 'c', 'h', '\022', 'H', '\n', '\007', 'h', 
+'e', 'a', 'd', 'e', 'r', 's', '\030', '\003', ' ', '\003', '(', '\013', '2', '$', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 
+'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'H', 'e', 'a', 'd', 'e', 'r', 'M', 'a', 't', 'c', 'h', 'e', 'r', 
+'B', '\010', '\372', 'B', '\005', '\222', '\001', '\002', '\010', '\001', 'R', '\007', 'h', 'e', 'a', 'd', 'e', 'r', 's', ':', ';', '\232', '\305', '\210', '\036', 
+'6', '\n', '4', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'r', 'o', 'u', 't', 'e', '.', 'R', 'a', 't', 
+'e', 'L', 'i', 'm', 'i', 't', '.', 'A', 'c', 't', 'i', 'o', 'n', '.', 'H', 'e', 'a', 'd', 'e', 'r', 'V', 'a', 'l', 'u', 'e', 
+'M', 'a', 't', 'c', 'h', '\032', '\270', '\001', '\n', '\017', 'D', 'y', 'n', 'a', 'm', 'i', 'c', 'M', 'e', 't', 'a', 'D', 'a', 't', 'a', 
+'\022', '.', '\n', '\016', 'd', 'e', 's', 'c', 'r', 'i', 'p', 't', 'o', 'r', '_', 'k', 'e', 'y', '\030', '\001', ' ', '\001', '(', '\t', 'B', 
+'\007', '\372', 'B', '\004', 'r', '\002', '\020', '\001', 'R', '\r', 'd', 'e', 's', 'c', 'r', 'i', 'p', 't', 'o', 'r', 'K', 'e', 'y', '\022', 'P', 
+'\n', '\014', 'm', 'e', 't', 'a', 'd', 'a', 't', 'a', '_', 'k', 'e', 'y', '\030', '\002', ' ', '\001', '(', '\013', '2', '#', '.', 'e', 'n', 
+'v', 'o', 'y', '.', 't', 'y', 'p', 'e', '.', 'm', 'e', 't', 'a', 'd', 'a', 't', 'a', '.', 'v', '3', '.', 'M', 'e', 't', 'a', 
+'d', 'a', 't', 'a', 'K', 'e', 'y', 'B', '\010', '\372', 'B', '\005', '\212', '\001', '\002', '\020', '\001', 'R', '\013', 'm', 'e', 't', 'a', 'd', 'a', 
+'t', 'a', 'K', 'e', 'y', '\022', '#', '\n', '\r', 'd', 'e', 'f', 'a', 'u', 'l', 't', '_', 'v', 'a', 'l', 'u', 'e', '\030', '\003', ' ', 
+'\001', '(', '\t', 'R', '\014', 'd', 'e', 'f', 'a', 'u', 'l', 't', 'V', 'a', 'l', 'u', 'e', '\032', '\264', '\002', '\n', '\010', 'M', 'e', 't', 
+'a', 'D', 'a', 't', 'a', '\022', '.', '\n', '\016', 'd', 'e', 's', 'c', 'r', 'i', 'p', 't', 'o', 'r', '_', 'k', 'e', 'y', '\030', '\001', 
+' ', '\001', '(', '\t', 'B', '\007', '\372', 'B', '\004', 'r', '\002', '\020', '\001', 'R', '\r', 'd', 'e', 's', 'c', 'r', 'i', 'p', 't', 'o', 'r', 
+'K', 'e', 'y', '\022', 'P', '\n', '\014', 'm', 'e', 't', 'a', 'd', 'a', 't', 'a', '_', 'k', 'e', 'y', '\030', '\002', ' ', '\001', '(', '\013', 
+'2', '#', '.', 'e', 'n', 'v', 'o', 'y', '.', 't', 'y', 'p', 'e', '.', 'm', 'e', 't', 'a', 'd', 'a', 't', 'a', '.', 'v', '3', 
+'.', 'M', 'e', 't', 'a', 'd', 'a', 't', 'a', 'K', 'e', 'y', 'B', '\010', '\372', 'B', '\005', '\212', '\001', '\002', '\020', '\001', 'R', '\013', 'm', 
+'e', 't', 'a', 'd', 'a', 't', 'a', 'K', 'e', 'y', '\022', '#', '\n', '\r', 'd', 'e', 'f', 'a', 'u', 'l', 't', '_', 'v', 'a', 'l', 
+'u', 'e', '\030', '\003', ' ', '\001', '(', '\t', 'R', '\014', 'd', 'e', 'f', 'a', 'u', 'l', 't', 'V', 'a', 'l', 'u', 'e', '\022', 'Y', '\n', 
+'\006', 's', 'o', 'u', 'r', 'c', 'e', '\030', '\004', ' ', '\001', '(', '\016', '2', '7', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 
+'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'R', 'a', 't', 'e', 'L', 'i', 'm', 'i', 't', '.', 'A', 'c', 
+'t', 'i', 'o', 'n', '.', 'M', 'e', 't', 'a', 'D', 'a', 't', 'a', '.', 'S', 'o', 'u', 'r', 'c', 'e', 'B', '\010', '\372', 'B', '\005', 
+'\202', '\001', '\002', '\020', '\001', 'R', '\006', 's', 'o', 'u', 'r', 'c', 'e', '\"', '&', '\n', '\006', 'S', 'o', 'u', 'r', 'c', 'e', '\022', '\013', 
+'\n', '\007', 'D', 'Y', 'N', 'A', 'M', 'I', 'C', '\020', '\000', '\022', '\017', '\n', '\013', 'R', 'O', 'U', 'T', 'E', '_', 'E', 'N', 'T', 'R', 
+'Y', '\020', '\001', ':', '*', '\232', '\305', '\210', '\036', '%', '\n', '#', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 
+'r', 'o', 'u', 't', 'e', '.', 'R', 'a', 't', 'e', 'L', 'i', 'm', 'i', 't', '.', 'A', 'c', 't', 'i', 'o', 'n', 'B', '\027', '\n', 
+'\020', 'a', 'c', 't', 'i', 'o', 'n', '_', 's', 'p', 'e', 'c', 'i', 'f', 'i', 'e', 'r', '\022', '\003', '\370', 'B', '\001', '\032', '\362', '\001', 
+'\n', '\010', 'O', 'v', 'e', 'r', 'r', 'i', 'd', 'e', '\022', 'f', '\n', '\020', 'd', 'y', 'n', 'a', 'm', 'i', 'c', '_', 'm', 'e', 't', 
+'a', 'd', 'a', 't', 'a', '\030', '\001', ' ', '\001', '(', '\013', '2', '9', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 
+'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'R', 'a', 't', 'e', 'L', 'i', 'm', 'i', 't', '.', 'O', 'v', 'e', 'r', 
+'r', 'i', 'd', 'e', '.', 'D', 'y', 'n', 'a', 'm', 'i', 'c', 'M', 'e', 't', 'a', 'd', 'a', 't', 'a', 'H', '\000', 'R', '\017', 'd', 
+'y', 'n', 'a', 'm', 'i', 'c', 'M', 'e', 't', 'a', 'd', 'a', 't', 'a', '\032', 'c', '\n', '\017', 'D', 'y', 'n', 'a', 'm', 'i', 'c', 
+'M', 'e', 't', 'a', 'd', 'a', 't', 'a', '\022', 'P', '\n', '\014', 'm', 'e', 't', 'a', 'd', 'a', 't', 'a', '_', 'k', 'e', 'y', '\030', 
+'\001', ' ', '\001', '(', '\013', '2', '#', '.', 'e', 'n', 'v', 'o', 'y', '.', 't', 'y', 'p', 'e', '.', 'm', 'e', 't', 'a', 'd', 'a', 
+'t', 'a', '.', 'v', '3', '.', 'M', 'e', 't', 'a', 'd', 'a', 't', 'a', 'K', 'e', 'y', 'B', '\010', '\372', 'B', '\005', '\212', '\001', '\002', 
+'\020', '\001', 'R', '\013', 'm', 'e', 't', 'a', 'd', 'a', 't', 'a', 'K', 'e', 'y', 'B', '\031', '\n', '\022', 'o', 'v', 'e', 'r', 'r', 'i', 
+'d', 'e', '_', 's', 'p', 'e', 'c', 'i', 'f', 'i', 'e', 'r', '\022', '\003', '\370', 'B', '\001', ':', '#', '\232', '\305', '\210', '\036', '\036', '\n', 
+'\034', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'r', 'o', 'u', 't', 'e', '.', 'R', 'a', 't', 'e', 'L', 
+'i', 'm', 'i', 't', '\"', '\244', '\005', '\n', '\r', 'H', 'e', 'a', 'd', 'e', 'r', 'M', 'a', 't', 'c', 'h', 'e', 'r', '\022', '!', '\n', 
+'\004', 'n', 'a', 'm', 'e', '\030', '\001', ' ', '\001', '(', '\t', 'B', '\r', '\372', 'B', '\n', 'r', '\010', '\020', '\001', '\300', '\001', '\001', '\310', '\001', 
+'\000', 'R', '\004', 'n', 'a', 'm', 'e', '\022', '.', '\n', '\013', 'e', 'x', 'a', 'c', 't', '_', 'm', 'a', 't', 'c', 'h', '\030', '\004', ' ', 
+'\001', '(', '\t', 'B', '\013', '\030', '\001', '\222', '\307', '\206', '\330', '\004', '\003', '3', '.', '0', 'H', '\000', 'R', '\n', 'e', 'x', 'a', 'c', 't', 
+'M', 'a', 't', 'c', 'h', '\022', '\\', '\n', '\020', 's', 'a', 'f', 'e', '_', 'r', 'e', 'g', 'e', 'x', '_', 'm', 'a', 't', 'c', 'h', 
+'\030', '\013', ' ', '\001', '(', '\013', '2', '#', '.', 'e', 'n', 'v', 'o', 'y', '.', 't', 'y', 'p', 'e', '.', 'm', 'a', 't', 'c', 'h', 
+'e', 'r', '.', 'v', '3', '.', 'R', 'e', 'g', 'e', 'x', 'M', 'a', 't', 'c', 'h', 'e', 'r', 'B', '\013', '\030', '\001', '\222', '\307', '\206', 
+'\330', '\004', '\003', '3', '.', '0', 'H', '\000', 'R', '\016', 's', 'a', 'f', 'e', 'R', 'e', 'g', 'e', 'x', 'M', 'a', 't', 'c', 'h', '\022', 
+'<', '\n', '\013', 'r', 'a', 'n', 'g', 'e', '_', 'm', 'a', 't', 'c', 'h', '\030', '\006', ' ', '\001', '(', '\013', '2', '\031', '.', 'e', 'n', 
+'v', 'o', 'y', '.', 't', 'y', 'p', 'e', '.', 'v', '3', '.', 'I', 'n', 't', '6', '4', 'R', 'a', 'n', 'g', 'e', 'H', '\000', 'R', 
+'\n', 'r', 'a', 'n', 'g', 'e', 'M', 'a', 't', 'c', 'h', '\022', '%', '\n', '\r', 'p', 'r', 'e', 's', 'e', 'n', 't', '_', 'm', 'a', 
+'t', 'c', 'h', '\030', '\007', ' ', '\001', '(', '\010', 'H', '\000', 'R', '\014', 'p', 'r', 'e', 's', 'e', 'n', 't', 'M', 'a', 't', 'c', 'h', 
+'\022', '7', '\n', '\014', 'p', 'r', 'e', 'f', 'i', 'x', '_', 'm', 'a', 't', 'c', 'h', '\030', '\t', ' ', '\001', '(', '\t', 'B', '\022', '\030', 
+'\001', '\372', 'B', '\004', 'r', '\002', '\020', '\001', '\222', '\307', '\206', '\330', '\004', '\003', '3', '.', '0', 'H', '\000', 'R', '\013', 'p', 'r', 'e', 'f', 
+'i', 'x', 'M', 'a', 't', 'c', 'h', '\022', '7', '\n', '\014', 's', 'u', 'f', 'f', 'i', 'x', '_', 'm', 'a', 't', 'c', 'h', '\030', '\n', 
+' ', '\001', '(', '\t', 'B', '\022', '\030', '\001', '\372', 'B', '\004', 'r', '\002', '\020', '\001', '\222', '\307', '\206', '\330', '\004', '\003', '3', '.', '0', 'H', 
+'\000', 'R', '\013', 's', 'u', 'f', 'f', 'i', 'x', 'M', 'a', 't', 'c', 'h', '\022', ';', '\n', '\016', 'c', 'o', 'n', 't', 'a', 'i', 'n', 
+'s', '_', 'm', 'a', 't', 'c', 'h', '\030', '\014', ' ', '\001', '(', '\t', 'B', '\022', '\030', '\001', '\372', 'B', '\004', 'r', '\002', '\020', '\001', '\222', 
+'\307', '\206', '\330', '\004', '\003', '3', '.', '0', 'H', '\000', 'R', '\r', 'c', 'o', 'n', 't', 'a', 'i', 'n', 's', 'M', 'a', 't', 'c', 'h', 
+'\022', 'I', '\n', '\014', 's', 't', 'r', 'i', 'n', 'g', '_', 'm', 'a', 't', 'c', 'h', '\030', '\r', ' ', '\001', '(', '\013', '2', '$', '.', 
 'e', 'n', 'v', 'o', 'y', '.', 't', 'y', 'p', 'e', '.', 'm', 'a', 't', 'c', 'h', 'e', 'r', '.', 'v', '3', '.', 'S', 't', 'r', 
-'i', 'n', 'g', 'M', 'a', 't', 'c', 'h', 'e', 'r', 'B', '\010', '\372', 'B', '\005', '\212', '\001', '\002', '\020', '\001', 'H', '\000', 'R', '\013', 's', 
-'t', 'r', 'i', 'n', 'g', 'M', 'a', 't', 'c', 'h', '\022', '%', '\n', '\r', 'p', 'r', 'e', 's', 'e', 'n', 't', '_', 'm', 'a', 't', 
-'c', 'h', '\030', '\006', ' ', '\001', '(', '\010', 'H', '\000', 'R', '\014', 'p', 'r', 'e', 's', 'e', 'n', 't', 'M', 'a', 't', 'c', 'h', ':', 
-'/', '\232', '\305', '\210', '\036', '*', '\n', '(', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'r', 'o', 'u', 't', 
-'e', '.', 'Q', 'u', 'e', 'r', 'y', 'P', 'a', 'r', 'a', 'm', 'e', 't', 'e', 'r', 'M', 'a', 't', 'c', 'h', 'e', 'r', 'B', '!', 
-'\n', '\037', 'q', 'u', 'e', 'r', 'y', '_', 'p', 'a', 'r', 'a', 'm', 'e', 't', 'e', 'r', '_', 'm', 'a', 't', 'c', 'h', '_', 's', 
-'p', 'e', 'c', 'i', 'f', 'i', 'e', 'r', 'J', '\004', '\010', '\003', '\020', '\004', 'J', '\004', '\010', '\004', '\020', '\005', 'R', '\005', 'v', 'a', 'l', 
-'u', 'e', 'R', '\005', 'r', 'e', 'g', 'e', 'x', '\"', '\271', '\002', '\n', '\026', 'I', 'n', 't', 'e', 'r', 'n', 'a', 'l', 'R', 'e', 'd', 
-'i', 'r', 'e', 'c', 't', 'P', 'o', 'l', 'i', 'c', 'y', '\022', 'R', '\n', '\026', 'm', 'a', 'x', '_', 'i', 'n', 't', 'e', 'r', 'n', 
-'a', 'l', '_', 'r', 'e', 'd', 'i', 'r', 'e', 'c', 't', 's', '\030', '\001', ' ', '\001', '(', '\013', '2', '\034', '.', 'g', 'o', 'o', 'g', 
-'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'U', 'I', 'n', 't', '3', '2', 'V', 'a', 'l', 'u', 'e', 'R', '\024', 
-'m', 'a', 'x', 'I', 'n', 't', 'e', 'r', 'n', 'a', 'l', 'R', 'e', 'd', 'i', 'r', 'e', 'c', 't', 's', '\022', '@', '\n', '\027', 'r', 
-'e', 'd', 'i', 'r', 'e', 'c', 't', '_', 'r', 'e', 's', 'p', 'o', 'n', 's', 'e', '_', 'c', 'o', 'd', 'e', 's', '\030', '\002', ' ', 
-'\003', '(', '\r', 'B', '\010', '\372', 'B', '\005', '\222', '\001', '\002', '\020', '\005', 'R', '\025', 'r', 'e', 'd', 'i', 'r', 'e', 'c', 't', 'R', 'e', 
-'s', 'p', 'o', 'n', 's', 'e', 'C', 'o', 'd', 'e', 's', '\022', 'J', '\n', '\n', 'p', 'r', 'e', 'd', 'i', 'c', 'a', 't', 'e', 's', 
-'\030', '\003', ' ', '\003', '(', '\013', '2', '*', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 
-'e', '.', 'v', '3', '.', 'T', 'y', 'p', 'e', 'd', 'E', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 'C', 'o', 'n', 'f', 'i', 'g', 
-'R', '\n', 'p', 'r', 'e', 'd', 'i', 'c', 'a', 't', 'e', 's', '\022', '=', '\n', '\033', 'a', 'l', 'l', 'o', 'w', '_', 'c', 'r', 'o', 
-'s', 's', '_', 's', 'c', 'h', 'e', 'm', 'e', '_', 'r', 'e', 'd', 'i', 'r', 'e', 'c', 't', '\030', '\004', ' ', '\001', '(', '\010', 'R', 
-'\030', 'a', 'l', 'l', 'o', 'w', 'C', 'r', 'o', 's', 's', 'S', 'c', 'h', 'e', 'm', 'e', 'R', 'e', 'd', 'i', 'r', 'e', 'c', 't', 
-'\"', ']', '\n', '\014', 'F', 'i', 'l', 't', 'e', 'r', 'C', 'o', 'n', 'f', 'i', 'g', '\022', ',', '\n', '\006', 'c', 'o', 'n', 'f', 'i', 
-'g', '\030', '\001', ' ', '\001', '(', '\013', '2', '\024', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', 
-'.', 'A', 'n', 'y', 'R', '\006', 'c', 'o', 'n', 'f', 'i', 'g', '\022', '\037', '\n', '\013', 'i', 's', '_', 'o', 'p', 't', 'i', 'o', 'n', 
-'a', 'l', '\030', '\002', ' ', '\001', '(', '\010', 'R', '\n', 'i', 's', 'O', 'p', 't', 'i', 'o', 'n', 'a', 'l', 'B', 'E', '\n', '#', 'i', 
-'o', '.', 'e', 'n', 'v', 'o', 'y', 'p', 'r', 'o', 'x', 'y', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', 
-'.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', 'B', '\024', 'R', 'o', 'u', 't', 'e', 'C', 'o', 'm', 'p', 'o', 'n', 'e', 'n', 't', 
-'s', 'P', 'r', 'o', 't', 'o', 'P', '\001', '\272', '\200', '\310', '\321', '\006', '\002', '\020', '\002', 'b', '\006', 'p', 'r', 'o', 't', 'o', '3', 
+'i', 'n', 'g', 'M', 'a', 't', 'c', 'h', 'e', 'r', 'H', '\000', 'R', '\013', 's', 't', 'r', 'i', 'n', 'g', 'M', 'a', 't', 'c', 'h', 
+'\022', '!', '\n', '\014', 'i', 'n', 'v', 'e', 'r', 't', '_', 'm', 'a', 't', 'c', 'h', '\030', '\010', ' ', '\001', '(', '\010', 'R', '\013', 'i', 
+'n', 'v', 'e', 'r', 't', 'M', 'a', 't', 'c', 'h', ':', '\'', '\232', '\305', '\210', '\036', '\"', '\n', ' ', 'e', 'n', 'v', 'o', 'y', '.', 
+'a', 'p', 'i', '.', 'v', '2', '.', 'r', 'o', 'u', 't', 'e', '.', 'H', 'e', 'a', 'd', 'e', 'r', 'M', 'a', 't', 'c', 'h', 'e', 
+'r', 'B', '\030', '\n', '\026', 'h', 'e', 'a', 'd', 'e', 'r', '_', 'm', 'a', 't', 'c', 'h', '_', 's', 'p', 'e', 'c', 'i', 'f', 'i', 
+'e', 'r', 'J', '\004', '\010', '\002', '\020', '\003', 'J', '\004', '\010', '\003', '\020', '\004', 'J', '\004', '\010', '\005', '\020', '\006', 'R', '\013', 'r', 'e', 'g', 
+'e', 'x', '_', 'm', 'a', 't', 'c', 'h', '\"', '\241', '\002', '\n', '\025', 'Q', 'u', 'e', 'r', 'y', 'P', 'a', 'r', 'a', 'm', 'e', 't', 
+'e', 'r', 'M', 'a', 't', 'c', 'h', 'e', 'r', '\022', '\036', '\n', '\004', 'n', 'a', 'm', 'e', '\030', '\001', ' ', '\001', '(', '\t', 'B', '\n', 
+'\372', 'B', '\007', 'r', '\005', '\020', '\001', '(', '\200', '\010', 'R', '\004', 'n', 'a', 'm', 'e', '\022', 'S', '\n', '\014', 's', 't', 'r', 'i', 'n', 
+'g', '_', 'm', 'a', 't', 'c', 'h', '\030', '\005', ' ', '\001', '(', '\013', '2', '$', '.', 'e', 'n', 'v', 'o', 'y', '.', 't', 'y', 'p', 
+'e', '.', 'm', 'a', 't', 'c', 'h', 'e', 'r', '.', 'v', '3', '.', 'S', 't', 'r', 'i', 'n', 'g', 'M', 'a', 't', 'c', 'h', 'e', 
+'r', 'B', '\010', '\372', 'B', '\005', '\212', '\001', '\002', '\020', '\001', 'H', '\000', 'R', '\013', 's', 't', 'r', 'i', 'n', 'g', 'M', 'a', 't', 'c', 
+'h', '\022', '%', '\n', '\r', 'p', 'r', 'e', 's', 'e', 'n', 't', '_', 'm', 'a', 't', 'c', 'h', '\030', '\006', ' ', '\001', '(', '\010', 'H', 
+'\000', 'R', '\014', 'p', 'r', 'e', 's', 'e', 'n', 't', 'M', 'a', 't', 'c', 'h', ':', '/', '\232', '\305', '\210', '\036', '*', '\n', '(', 'e', 
+'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'r', 'o', 'u', 't', 'e', '.', 'Q', 'u', 'e', 'r', 'y', 'P', 'a', 
+'r', 'a', 'm', 'e', 't', 'e', 'r', 'M', 'a', 't', 'c', 'h', 'e', 'r', 'B', '!', '\n', '\037', 'q', 'u', 'e', 'r', 'y', '_', 'p', 
+'a', 'r', 'a', 'm', 'e', 't', 'e', 'r', '_', 'm', 'a', 't', 'c', 'h', '_', 's', 'p', 'e', 'c', 'i', 'f', 'i', 'e', 'r', 'J', 
+'\004', '\010', '\003', '\020', '\004', 'J', '\004', '\010', '\004', '\020', '\005', 'R', '\005', 'v', 'a', 'l', 'u', 'e', 'R', '\005', 'r', 'e', 'g', 'e', 'x', 
+'\"', '\271', '\002', '\n', '\026', 'I', 'n', 't', 'e', 'r', 'n', 'a', 'l', 'R', 'e', 'd', 'i', 'r', 'e', 'c', 't', 'P', 'o', 'l', 'i', 
+'c', 'y', '\022', 'R', '\n', '\026', 'm', 'a', 'x', '_', 'i', 'n', 't', 'e', 'r', 'n', 'a', 'l', '_', 'r', 'e', 'd', 'i', 'r', 'e', 
+'c', 't', 's', '\030', '\001', ' ', '\001', '(', '\013', '2', '\034', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 
+'u', 'f', '.', 'U', 'I', 'n', 't', '3', '2', 'V', 'a', 'l', 'u', 'e', 'R', '\024', 'm', 'a', 'x', 'I', 'n', 't', 'e', 'r', 'n', 
+'a', 'l', 'R', 'e', 'd', 'i', 'r', 'e', 'c', 't', 's', '\022', '@', '\n', '\027', 'r', 'e', 'd', 'i', 'r', 'e', 'c', 't', '_', 'r', 
+'e', 's', 'p', 'o', 'n', 's', 'e', '_', 'c', 'o', 'd', 'e', 's', '\030', '\002', ' ', '\003', '(', '\r', 'B', '\010', '\372', 'B', '\005', '\222', 
+'\001', '\002', '\020', '\005', 'R', '\025', 'r', 'e', 'd', 'i', 'r', 'e', 'c', 't', 'R', 'e', 's', 'p', 'o', 'n', 's', 'e', 'C', 'o', 'd', 
+'e', 's', '\022', 'J', '\n', '\n', 'p', 'r', 'e', 'd', 'i', 'c', 'a', 't', 'e', 's', '\030', '\003', ' ', '\003', '(', '\013', '2', '*', '.', 
+'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'T', 'y', 'p', 'e', 
+'d', 'E', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 'C', 'o', 'n', 'f', 'i', 'g', 'R', '\n', 'p', 'r', 'e', 'd', 'i', 'c', 'a', 
+'t', 'e', 's', '\022', '=', '\n', '\033', 'a', 'l', 'l', 'o', 'w', '_', 'c', 'r', 'o', 's', 's', '_', 's', 'c', 'h', 'e', 'm', 'e', 
+'_', 'r', 'e', 'd', 'i', 'r', 'e', 'c', 't', '\030', '\004', ' ', '\001', '(', '\010', 'R', '\030', 'a', 'l', 'l', 'o', 'w', 'C', 'r', 'o', 
+'s', 's', 'S', 'c', 'h', 'e', 'm', 'e', 'R', 'e', 'd', 'i', 'r', 'e', 'c', 't', '\"', ']', '\n', '\014', 'F', 'i', 'l', 't', 'e', 
+'r', 'C', 'o', 'n', 'f', 'i', 'g', '\022', ',', '\n', '\006', 'c', 'o', 'n', 'f', 'i', 'g', '\030', '\001', ' ', '\001', '(', '\013', '2', '\024', 
+'.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'A', 'n', 'y', 'R', '\006', 'c', 'o', 'n', 
+'f', 'i', 'g', '\022', '\037', '\n', '\013', 'i', 's', '_', 'o', 'p', 't', 'i', 'o', 'n', 'a', 'l', '\030', '\002', ' ', '\001', '(', '\010', 'R', 
+'\n', 'i', 's', 'O', 'p', 't', 'i', 'o', 'n', 'a', 'l', 'B', 'E', '\n', '#', 'i', 'o', '.', 'e', 'n', 'v', 'o', 'y', 'p', 'r', 
+'o', 'x', 'y', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', 
+'B', '\024', 'R', 'o', 'u', 't', 'e', 'C', 'o', 'm', 'p', 'o', 'n', 'e', 'n', 't', 's', 'P', 'r', 'o', 't', 'o', 'P', '\001', '\272', 
+'\200', '\310', '\321', '\006', '\002', '\020', '\002', 'b', '\006', 'p', 'r', 'o', 't', 'o', '3', 
 };
 
-static upb_def_init *deps[18] = {
+static upb_def_init *deps[19] = {
   &envoy_config_core_v3_base_proto_upbdefinit,
   &envoy_config_core_v3_extension_proto_upbdefinit,
   &envoy_config_core_v3_proxy_protocol_proto_upbdefinit,
+  &envoy_type_matcher_v3_metadata_proto_upbdefinit,
   &envoy_type_matcher_v3_regex_proto_upbdefinit,
   &envoy_type_matcher_v3_string_proto_upbdefinit,
   &envoy_type_metadata_v3_metadata_proto_upbdefinit,
@@ -960,5 +971,5 @@ upb_def_init envoy_config_route_v3_route_components_proto_upbdefinit = {
   deps,
   layouts,
   "envoy/config/route/v3/route_components.proto",
-  UPB_STRVIEW_INIT(descriptor, 19924)
+  UPB_STRVIEW_INIT(descriptor, 20140)
 };
index 755ef09..1e1284a 100644 (file)
@@ -24,7 +24,6 @@ extern upb_def_init envoy_type_v3_percent_proto_upbdefinit;
 extern upb_def_init google_protobuf_any_proto_upbdefinit;
 extern upb_def_init google_protobuf_duration_proto_upbdefinit;
 extern upb_def_init google_protobuf_wrappers_proto_upbdefinit;
-extern upb_def_init envoy_annotations_deprecation_proto_upbdefinit;
 extern upb_def_init udpa_annotations_migrate_proto_upbdefinit;
 extern upb_def_init udpa_annotations_security_proto_upbdefinit;
 extern upb_def_init udpa_annotations_status_proto_upbdefinit;
@@ -72,7 +71,7 @@ static const upb_msglayout *layouts[19] = {
   &envoy_extensions_filters_network_http_connection_manager_v3_EnvoyMobileHttpConnectionManager_msginit,
 };
 
-static const char descriptor[11589] = {'\n', 'Y', 'e', 'n', 'v', 'o', 'y', '/', 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 's', '/', 'f', 'i', 'l', 't', 'e', 'r', 
+static const char descriptor[11539] = {'\n', 'Y', 'e', 'n', 'v', 'o', 'y', '/', 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 's', '/', 'f', 'i', 'l', 't', 'e', 'r', 
 's', '/', 'n', 'e', 't', 'w', 'o', 'r', 'k', '/', 'h', 't', 't', 'p', '_', 'c', 'o', 'n', 'n', 'e', 'c', 't', 'i', 'o', 'n', 
 '_', 'm', 'a', 'n', 'a', 'g', 'e', 'r', '/', 'v', '3', '/', 'h', 't', 't', 'p', '_', 'c', 'o', 'n', 'n', 'e', 'c', 't', 'i', 
 'o', 'n', '_', 'm', 'a', 'n', 'a', 'g', 'e', 'r', '.', 'p', 'r', 'o', 't', 'o', '\022', ';', 'e', 'n', 'v', 'o', 'y', '.', 'e', 
@@ -101,104 +100,102 @@ static const char descriptor[11589] = {'\n', 'Y', 'e', 'n', 'v', 'o', 'y', '/',
 '/', 'a', 'n', 'y', '.', 'p', 'r', 'o', 't', 'o', '\032', '\036', 'g', 'o', 'o', 'g', 'l', 'e', '/', 'p', 'r', 'o', 't', 'o', 'b', 
 'u', 'f', '/', 'd', 'u', 'r', 'a', 't', 'i', 'o', 'n', '.', 'p', 'r', 'o', 't', 'o', '\032', '\036', 'g', 'o', 'o', 'g', 'l', 'e', 
 '/', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '/', 'w', 'r', 'a', 'p', 'p', 'e', 'r', 's', '.', 'p', 'r', 'o', 't', 'o', '\032', 
-'#', 'e', 'n', 'v', 'o', 'y', '/', 'a', 'n', 'n', 'o', 't', 'a', 't', 'i', 'o', 'n', 's', '/', 'd', 'e', 'p', 'r', 'e', 'c', 
-'a', 't', 'i', 'o', 'n', '.', 'p', 'r', 'o', 't', 'o', '\032', '\036', 'u', 'd', 'p', 'a', '/', 'a', 'n', 'n', 'o', 't', 'a', 't', 
-'i', 'o', 'n', 's', '/', 'm', 'i', 'g', 'r', 'a', 't', 'e', '.', 'p', 'r', 'o', 't', 'o', '\032', '\037', 'u', 'd', 'p', 'a', '/', 
-'a', 'n', 'n', 'o', 't', 'a', 't', 'i', 'o', 'n', 's', '/', 's', 'e', 'c', 'u', 'r', 'i', 't', 'y', '.', 'p', 'r', 'o', 't', 
-'o', '\032', '\035', 'u', 'd', 'p', 'a', '/', 'a', 'n', 'n', 'o', 't', 'a', 't', 'i', 'o', 'n', 's', '/', 's', 't', 'a', 't', 'u', 
-'s', '.', 'p', 'r', 'o', 't', 'o', '\032', '!', 'u', 'd', 'p', 'a', '/', 'a', 'n', 'n', 'o', 't', 'a', 't', 'i', 'o', 'n', 's', 
-'/', 'v', 'e', 'r', 's', 'i', 'o', 'n', 'i', 'n', 'g', '.', 'p', 'r', 'o', 't', 'o', '\032', '\027', 'v', 'a', 'l', 'i', 'd', 'a', 
-'t', 'e', '/', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'e', '.', 'p', 'r', 'o', 't', 'o', '\"', '\240', '4', '\n', '\025', 'H', 't', 't', 
-'p', 'C', 'o', 'n', 'n', 'e', 'c', 't', 'i', 'o', 'n', 'M', 'a', 'n', 'a', 'g', 'e', 'r', '\022', '\205', '\001', '\n', '\n', 'c', 'o', 
-'d', 'e', 'c', '_', 't', 'y', 'p', 'e', '\030', '\001', ' ', '\001', '(', '\016', '2', '\\', '.', 'e', 'n', 'v', 'o', 'y', '.', 'e', 'x', 
-'t', 'e', 'n', 's', 'i', 'o', 'n', 's', '.', 'f', 'i', 'l', 't', 'e', 'r', 's', '.', 'n', 'e', 't', 'w', 'o', 'r', 'k', '.', 
-'h', 't', 't', 'p', '_', 'c', 'o', 'n', 'n', 'e', 'c', 't', 'i', 'o', 'n', '_', 'm', 'a', 'n', 'a', 'g', 'e', 'r', '.', 'v', 
-'3', '.', 'H', 't', 't', 'p', 'C', 'o', 'n', 'n', 'e', 'c', 't', 'i', 'o', 'n', 'M', 'a', 'n', 'a', 'g', 'e', 'r', '.', 'C', 
-'o', 'd', 'e', 'c', 'T', 'y', 'p', 'e', 'B', '\010', '\372', 'B', '\005', '\202', '\001', '\002', '\020', '\001', 'R', '\t', 'c', 'o', 'd', 'e', 'c', 
-'T', 'y', 'p', 'e', '\022', '(', '\n', '\013', 's', 't', 'a', 't', '_', 'p', 'r', 'e', 'f', 'i', 'x', '\030', '\002', ' ', '\001', '(', '\t', 
-'B', '\007', '\372', 'B', '\004', 'r', '\002', '\020', '\001', 'R', '\n', 's', 't', 'a', 't', 'P', 'r', 'e', 'f', 'i', 'x', '\022', 'T', '\n', '\003', 
-'r', 'd', 's', '\030', '\003', ' ', '\001', '(', '\013', '2', '@', '.', 'e', 'n', 'v', 'o', 'y', '.', 'e', 'x', 't', 'e', 'n', 's', 'i', 
-'o', 'n', 's', '.', 'f', 'i', 'l', 't', 'e', 'r', 's', '.', 'n', 'e', 't', 'w', 'o', 'r', 'k', '.', 'h', 't', 't', 'p', '_', 
-'c', 'o', 'n', 'n', 'e', 'c', 't', 'i', 'o', 'n', '_', 'm', 'a', 'n', 'a', 'g', 'e', 'r', '.', 'v', '3', '.', 'R', 'd', 's', 
-'H', '\000', 'R', '\003', 'r', 'd', 's', '\022', 'N', '\n', '\014', 'r', 'o', 'u', 't', 'e', '_', 'c', 'o', 'n', 'f', 'i', 'g', '\030', '\004', 
-' ', '\001', '(', '\013', '2', ')', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', 
-'.', 'v', '3', '.', 'R', 'o', 'u', 't', 'e', 'C', 'o', 'n', 'f', 'i', 'g', 'u', 'r', 'a', 't', 'i', 'o', 'n', 'H', '\000', 'R', 
-'\013', 'r', 'o', 'u', 't', 'e', 'C', 'o', 'n', 'f', 'i', 'g', '\022', 'p', '\n', '\r', 's', 'c', 'o', 'p', 'e', 'd', '_', 'r', 'o', 
-'u', 't', 'e', 's', '\030', '\037', ' ', '\001', '(', '\013', '2', 'I', '.', 'e', 'n', 'v', 'o', 'y', '.', 'e', 'x', 't', 'e', 'n', 's', 
-'i', 'o', 'n', 's', '.', 'f', 'i', 'l', 't', 'e', 'r', 's', '.', 'n', 'e', 't', 'w', 'o', 'r', 'k', '.', 'h', 't', 't', 'p', 
-'_', 'c', 'o', 'n', 'n', 'e', 'c', 't', 'i', 'o', 'n', '_', 'm', 'a', 'n', 'a', 'g', 'e', 'r', '.', 'v', '3', '.', 'S', 'c', 
-'o', 'p', 'e', 'd', 'R', 'o', 'u', 't', 'e', 's', 'H', '\000', 'R', '\014', 's', 'c', 'o', 'p', 'e', 'd', 'R', 'o', 'u', 't', 'e', 
-'s', '\022', 'j', '\n', '\014', 'h', 't', 't', 'p', '_', 'f', 'i', 'l', 't', 'e', 'r', 's', '\030', '\005', ' ', '\003', '(', '\013', '2', 'G', 
+'\036', 'u', 'd', 'p', 'a', '/', 'a', 'n', 'n', 'o', 't', 'a', 't', 'i', 'o', 'n', 's', '/', 'm', 'i', 'g', 'r', 'a', 't', 'e', 
+'.', 'p', 'r', 'o', 't', 'o', '\032', '\037', 'u', 'd', 'p', 'a', '/', 'a', 'n', 'n', 'o', 't', 'a', 't', 'i', 'o', 'n', 's', '/', 
+'s', 'e', 'c', 'u', 'r', 'i', 't', 'y', '.', 'p', 'r', 'o', 't', 'o', '\032', '\035', 'u', 'd', 'p', 'a', '/', 'a', 'n', 'n', 'o', 
+'t', 'a', 't', 'i', 'o', 'n', 's', '/', 's', 't', 'a', 't', 'u', 's', '.', 'p', 'r', 'o', 't', 'o', '\032', '!', 'u', 'd', 'p', 
+'a', '/', 'a', 'n', 'n', 'o', 't', 'a', 't', 'i', 'o', 'n', 's', '/', 'v', 'e', 'r', 's', 'i', 'o', 'n', 'i', 'n', 'g', '.', 
+'p', 'r', 'o', 't', 'o', '\032', '\027', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'e', '/', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'e', '.', 
+'p', 'r', 'o', 't', 'o', '\"', '\223', '4', '\n', '\025', 'H', 't', 't', 'p', 'C', 'o', 'n', 'n', 'e', 'c', 't', 'i', 'o', 'n', 'M', 
+'a', 'n', 'a', 'g', 'e', 'r', '\022', '\205', '\001', '\n', '\n', 'c', 'o', 'd', 'e', 'c', '_', 't', 'y', 'p', 'e', '\030', '\001', ' ', '\001', 
+'(', '\016', '2', '\\', '.', 'e', 'n', 'v', 'o', 'y', '.', 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 's', '.', 'f', 'i', 'l', 
+'t', 'e', 'r', 's', '.', 'n', 'e', 't', 'w', 'o', 'r', 'k', '.', 'h', 't', 't', 'p', '_', 'c', 'o', 'n', 'n', 'e', 'c', 't', 
+'i', 'o', 'n', '_', 'm', 'a', 'n', 'a', 'g', 'e', 'r', '.', 'v', '3', '.', 'H', 't', 't', 'p', 'C', 'o', 'n', 'n', 'e', 'c', 
+'t', 'i', 'o', 'n', 'M', 'a', 'n', 'a', 'g', 'e', 'r', '.', 'C', 'o', 'd', 'e', 'c', 'T', 'y', 'p', 'e', 'B', '\010', '\372', 'B', 
+'\005', '\202', '\001', '\002', '\020', '\001', 'R', '\t', 'c', 'o', 'd', 'e', 'c', 'T', 'y', 'p', 'e', '\022', '(', '\n', '\013', 's', 't', 'a', 't', 
+'_', 'p', 'r', 'e', 'f', 'i', 'x', '\030', '\002', ' ', '\001', '(', '\t', 'B', '\007', '\372', 'B', '\004', 'r', '\002', '\020', '\001', 'R', '\n', 's', 
+'t', 'a', 't', 'P', 'r', 'e', 'f', 'i', 'x', '\022', 'T', '\n', '\003', 'r', 'd', 's', '\030', '\003', ' ', '\001', '(', '\013', '2', '@', '.', 
+'e', 'n', 'v', 'o', 'y', '.', 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 's', '.', 'f', 'i', 'l', 't', 'e', 'r', 's', '.', 
+'n', 'e', 't', 'w', 'o', 'r', 'k', '.', 'h', 't', 't', 'p', '_', 'c', 'o', 'n', 'n', 'e', 'c', 't', 'i', 'o', 'n', '_', 'm', 
+'a', 'n', 'a', 'g', 'e', 'r', '.', 'v', '3', '.', 'R', 'd', 's', 'H', '\000', 'R', '\003', 'r', 'd', 's', '\022', 'N', '\n', '\014', 'r', 
+'o', 'u', 't', 'e', '_', 'c', 'o', 'n', 'f', 'i', 'g', '\030', '\004', ' ', '\001', '(', '\013', '2', ')', '.', 'e', 'n', 'v', 'o', 'y', 
+'.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'r', 'o', 'u', 't', 'e', '.', 'v', '3', '.', 'R', 'o', 'u', 't', 'e', 'C', 'o', 'n', 
+'f', 'i', 'g', 'u', 'r', 'a', 't', 'i', 'o', 'n', 'H', '\000', 'R', '\013', 'r', 'o', 'u', 't', 'e', 'C', 'o', 'n', 'f', 'i', 'g', 
+'\022', 'p', '\n', '\r', 's', 'c', 'o', 'p', 'e', 'd', '_', 'r', 'o', 'u', 't', 'e', 's', '\030', '\037', ' ', '\001', '(', '\013', '2', 'I', 
 '.', 'e', 'n', 'v', 'o', 'y', '.', 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 's', '.', 'f', 'i', 'l', 't', 'e', 'r', 's', 
 '.', 'n', 'e', 't', 'w', 'o', 'r', 'k', '.', 'h', 't', 't', 'p', '_', 'c', 'o', 'n', 'n', 'e', 'c', 't', 'i', 'o', 'n', '_', 
-'m', 'a', 'n', 'a', 'g', 'e', 'r', '.', 'v', '3', '.', 'H', 't', 't', 'p', 'F', 'i', 'l', 't', 'e', 'r', 'R', '\013', 'h', 't', 
-'t', 'p', 'F', 'i', 'l', 't', 'e', 'r', 's', '\022', '@', '\n', '\016', 'a', 'd', 'd', '_', 'u', 's', 'e', 'r', '_', 'a', 'g', 'e', 
-'n', 't', '\030', '\006', ' ', '\001', '(', '\013', '2', '\032', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 
-'f', '.', 'B', 'o', 'o', 'l', 'V', 'a', 'l', 'u', 'e', 'R', '\014', 'a', 'd', 'd', 'U', 's', 'e', 'r', 'A', 'g', 'e', 'n', 't', 
-'\022', 't', '\n', '\007', 't', 'r', 'a', 'c', 'i', 'n', 'g', '\030', '\007', ' ', '\001', '(', '\013', '2', 'Z', '.', 'e', 'n', 'v', 'o', 'y', 
-'.', 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 's', '.', 'f', 'i', 'l', 't', 'e', 'r', 's', '.', 'n', 'e', 't', 'w', 'o', 
-'r', 'k', '.', 'h', 't', 't', 'p', '_', 'c', 'o', 'n', 'n', 'e', 'c', 't', 'i', 'o', 'n', '_', 'm', 'a', 'n', 'a', 'g', 'e', 
-'r', '.', 'v', '3', '.', 'H', 't', 't', 'p', 'C', 'o', 'n', 'n', 'e', 'c', 't', 'i', 'o', 'n', 'M', 'a', 'n', 'a', 'g', 'e', 
-'r', '.', 'T', 'r', 'a', 'c', 'i', 'n', 'g', 'R', '\007', 't', 'r', 'a', 'c', 'i', 'n', 'g', '\022', 's', '\n', '\034', 'c', 'o', 'm', 
-'m', 'o', 'n', '_', 'h', 't', 't', 'p', '_', 'p', 'r', 'o', 't', 'o', 'c', 'o', 'l', '_', 'o', 'p', 't', 'i', 'o', 'n', 's', 
-'\030', '#', ' ', '\001', '(', '\013', '2', ')', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 
-'e', '.', 'v', '3', '.', 'H', 't', 't', 'p', 'P', 'r', 'o', 't', 'o', 'c', 'o', 'l', 'O', 'p', 't', 'i', 'o', 'n', 's', 'B', 
-'\007', '\212', '\223', '\267', '*', '\002', '\010', '\001', 'R', '\031', 'c', 'o', 'm', 'm', 'o', 'n', 'H', 't', 't', 'p', 'P', 'r', 'o', 't', 'o', 
-'c', 'o', 'l', 'O', 'p', 't', 'i', 'o', 'n', 's', '\022', '^', '\n', '\025', 'h', 't', 't', 'p', '_', 'p', 'r', 'o', 't', 'o', 'c', 
-'o', 'l', '_', 'o', 'p', 't', 'i', 'o', 'n', 's', '\030', '\010', ' ', '\001', '(', '\013', '2', '*', '.', 'e', 'n', 'v', 'o', 'y', '.', 
-'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'H', 't', 't', 'p', '1', 'P', 'r', 'o', 't', 'o', 
-'c', 'o', 'l', 'O', 'p', 't', 'i', 'o', 'n', 's', 'R', '\023', 'h', 't', 't', 'p', 'P', 'r', 'o', 't', 'o', 'c', 'o', 'l', 'O', 
-'p', 't', 'i', 'o', 'n', 's', '\022', 'i', '\n', '\026', 'h', 't', 't', 'p', '2', '_', 'p', 'r', 'o', 't', 'o', 'c', 'o', 'l', '_', 
-'o', 'p', 't', 'i', 'o', 'n', 's', '\030', '\t', ' ', '\001', '(', '\013', '2', '*', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 
-'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'H', 't', 't', 'p', '2', 'P', 'r', 'o', 't', 'o', 'c', 'o', 'l', 
-'O', 'p', 't', 'i', 'o', 'n', 's', 'B', '\007', '\212', '\223', '\267', '*', '\002', '\010', '\001', 'R', '\024', 'h', 't', 't', 'p', '2', 'P', 'r', 
-'o', 't', 'o', 'c', 'o', 'l', 'O', 'p', 't', 'i', 'o', 'n', 's', '\022', '`', '\n', '\026', 'h', 't', 't', 'p', '3', '_', 'p', 'r', 
-'o', 't', 'o', 'c', 'o', 'l', '_', 'o', 'p', 't', 'i', 'o', 'n', 's', '\030', ',', ' ', '\001', '(', '\013', '2', '*', '.', 'e', 'n', 
-'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'H', 't', 't', 'p', '3', 'P', 
-'r', 'o', 't', 'o', 'c', 'o', 'l', 'O', 'p', 't', 'i', 'o', 'n', 's', 'R', '\024', 'h', 't', 't', 'p', '3', 'P', 'r', 'o', 't', 
-'o', 'c', 'o', 'l', 'O', 'p', 't', 'i', 'o', 'n', 's', '\022', ',', '\n', '\013', 's', 'e', 'r', 'v', 'e', 'r', '_', 'n', 'a', 'm', 
-'e', '\030', '\n', ' ', '\001', '(', '\t', 'B', '\013', '\372', 'B', '\010', 'r', '\006', '\300', '\001', '\002', '\310', '\001', '\000', 'R', '\n', 's', 'e', 'r', 
-'v', 'e', 'r', 'N', 'a', 'm', 'e', '\022', '\271', '\001', '\n', '\034', 's', 'e', 'r', 'v', 'e', 'r', '_', 'h', 'e', 'a', 'd', 'e', 'r', 
-'_', 't', 'r', 'a', 'n', 's', 'f', 'o', 'r', 'm', 'a', 't', 'i', 'o', 'n', '\030', '\"', ' ', '\001', '(', '\016', '2', 'm', '.', 'e', 
-'n', 'v', 'o', 'y', '.', 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 's', '.', 'f', 'i', 'l', 't', 'e', 'r', 's', '.', 'n', 
-'e', 't', 'w', 'o', 'r', 'k', '.', 'h', 't', 't', 'p', '_', 'c', 'o', 'n', 'n', 'e', 'c', 't', 'i', 'o', 'n', '_', 'm', 'a', 
-'n', 'a', 'g', 'e', 'r', '.', 'v', '3', '.', 'H', 't', 't', 'p', 'C', 'o', 'n', 'n', 'e', 'c', 't', 'i', 'o', 'n', 'M', 'a', 
-'n', 'a', 'g', 'e', 'r', '.', 'S', 'e', 'r', 'v', 'e', 'r', 'H', 'e', 'a', 'd', 'e', 'r', 'T', 'r', 'a', 'n', 's', 'f', 'o', 
-'r', 'm', 'a', 't', 'i', 'o', 'n', 'B', '\010', '\372', 'B', '\005', '\202', '\001', '\002', '\020', '\001', 'R', '\032', 's', 'e', 'r', 'v', 'e', 'r', 
-'H', 'e', 'a', 'd', 'e', 'r', 'T', 'r', 'a', 'n', 's', 'f', 'o', 'r', 'm', 'a', 't', 'i', 'o', 'n', '\022', 'r', '\n', '\034', 's', 
-'c', 'h', 'e', 'm', 'e', '_', 'h', 'e', 'a', 'd', 'e', 'r', '_', 't', 'r', 'a', 'n', 's', 'f', 'o', 'r', 'm', 'a', 't', 'i', 
-'o', 'n', '\030', '0', ' ', '\001', '(', '\013', '2', '0', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 
-'o', 'r', 'e', '.', 'v', '3', '.', 'S', 'c', 'h', 'e', 'm', 'e', 'H', 'e', 'a', 'd', 'e', 'r', 'T', 'r', 'a', 'n', 's', 'f', 
-'o', 'r', 'm', 'a', 't', 'i', 'o', 'n', 'R', '\032', 's', 'c', 'h', 'e', 'm', 'e', 'H', 'e', 'a', 'd', 'e', 'r', 'T', 'r', 'a', 
-'n', 's', 'f', 'o', 'r', 'm', 'a', 't', 'i', 'o', 'n', '\022', ']', '\n', '\026', 'm', 'a', 'x', '_', 'r', 'e', 'q', 'u', 'e', 's', 
-'t', '_', 'h', 'e', 'a', 'd', 'e', 'r', 's', '_', 'k', 'b', '\030', '\035', ' ', '\001', '(', '\013', '2', '\034', '.', 'g', 'o', 'o', 'g', 
-'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'U', 'I', 'n', 't', '3', '2', 'V', 'a', 'l', 'u', 'e', 'B', '\n', 
-'\372', 'B', '\007', '*', '\005', '\030', '\200', '@', ' ', '\000', 'R', '\023', 'm', 'a', 'x', 'R', 'e', 'q', 'u', 'e', 's', 't', 'H', 'e', 'a', 
-'d', 'e', 'r', 's', 'K', 'b', '\022', 'R', '\n', '\023', 's', 't', 'r', 'e', 'a', 'm', '_', 'i', 'd', 'l', 'e', '_', 't', 'i', 'm', 
-'e', 'o', 'u', 't', '\030', '\030', ' ', '\001', '(', '\013', '2', '\031', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 
-'b', 'u', 'f', '.', 'D', 'u', 'r', 'a', 't', 'i', 'o', 'n', 'B', '\007', '\212', '\223', '\267', '*', '\002', '\010', '\001', 'R', '\021', 's', 't', 
-'r', 'e', 'a', 'm', 'I', 'd', 'l', 'e', 'T', 'i', 'm', 'e', 'o', 'u', 't', '\022', 'K', '\n', '\017', 'r', 'e', 'q', 'u', 'e', 's', 
-'t', '_', 't', 'i', 'm', 'e', 'o', 'u', 't', '\030', '\034', ' ', '\001', '(', '\013', '2', '\031', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 
-'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'D', 'u', 'r', 'a', 't', 'i', 'o', 'n', 'B', '\007', '\212', '\223', '\267', '*', '\002', '\010', 
-'\001', 'R', '\016', 'r', 'e', 'q', 'u', 'e', 's', 't', 'T', 'i', 'm', 'e', 'o', 'u', 't', '\022', 'b', '\n', '\027', 'r', 'e', 'q', 'u', 
-'e', 's', 't', '_', 'h', 'e', 'a', 'd', 'e', 'r', 's', '_', 't', 'i', 'm', 'e', 'o', 'u', 't', '\030', ')', ' ', '\001', '(', '\013', 
+'m', 'a', 'n', 'a', 'g', 'e', 'r', '.', 'v', '3', '.', 'S', 'c', 'o', 'p', 'e', 'd', 'R', 'o', 'u', 't', 'e', 's', 'H', '\000', 
+'R', '\014', 's', 'c', 'o', 'p', 'e', 'd', 'R', 'o', 'u', 't', 'e', 's', '\022', 'j', '\n', '\014', 'h', 't', 't', 'p', '_', 'f', 'i', 
+'l', 't', 'e', 'r', 's', '\030', '\005', ' ', '\003', '(', '\013', '2', 'G', '.', 'e', 'n', 'v', 'o', 'y', '.', 'e', 'x', 't', 'e', 'n', 
+'s', 'i', 'o', 'n', 's', '.', 'f', 'i', 'l', 't', 'e', 'r', 's', '.', 'n', 'e', 't', 'w', 'o', 'r', 'k', '.', 'h', 't', 't', 
+'p', '_', 'c', 'o', 'n', 'n', 'e', 'c', 't', 'i', 'o', 'n', '_', 'm', 'a', 'n', 'a', 'g', 'e', 'r', '.', 'v', '3', '.', 'H', 
+'t', 't', 'p', 'F', 'i', 'l', 't', 'e', 'r', 'R', '\013', 'h', 't', 't', 'p', 'F', 'i', 'l', 't', 'e', 'r', 's', '\022', '@', '\n', 
+'\016', 'a', 'd', 'd', '_', 'u', 's', 'e', 'r', '_', 'a', 'g', 'e', 'n', 't', '\030', '\006', ' ', '\001', '(', '\013', '2', '\032', '.', 'g', 
+'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'B', 'o', 'o', 'l', 'V', 'a', 'l', 'u', 'e', 'R', 
+'\014', 'a', 'd', 'd', 'U', 's', 'e', 'r', 'A', 'g', 'e', 'n', 't', '\022', 't', '\n', '\007', 't', 'r', 'a', 'c', 'i', 'n', 'g', '\030', 
+'\007', ' ', '\001', '(', '\013', '2', 'Z', '.', 'e', 'n', 'v', 'o', 'y', '.', 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 's', '.', 
+'f', 'i', 'l', 't', 'e', 'r', 's', '.', 'n', 'e', 't', 'w', 'o', 'r', 'k', '.', 'h', 't', 't', 'p', '_', 'c', 'o', 'n', 'n', 
+'e', 'c', 't', 'i', 'o', 'n', '_', 'm', 'a', 'n', 'a', 'g', 'e', 'r', '.', 'v', '3', '.', 'H', 't', 't', 'p', 'C', 'o', 'n', 
+'n', 'e', 'c', 't', 'i', 'o', 'n', 'M', 'a', 'n', 'a', 'g', 'e', 'r', '.', 'T', 'r', 'a', 'c', 'i', 'n', 'g', 'R', '\007', 't', 
+'r', 'a', 'c', 'i', 'n', 'g', '\022', 's', '\n', '\034', 'c', 'o', 'm', 'm', 'o', 'n', '_', 'h', 't', 't', 'p', '_', 'p', 'r', 'o', 
+'t', 'o', 'c', 'o', 'l', '_', 'o', 'p', 't', 'i', 'o', 'n', 's', '\030', '#', ' ', '\001', '(', '\013', '2', ')', '.', 'e', 'n', 'v', 
+'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'H', 't', 't', 'p', 'P', 'r', 'o', 
+'t', 'o', 'c', 'o', 'l', 'O', 'p', 't', 'i', 'o', 'n', 's', 'B', '\007', '\212', '\223', '\267', '*', '\002', '\010', '\001', 'R', '\031', 'c', 'o', 
+'m', 'm', 'o', 'n', 'H', 't', 't', 'p', 'P', 'r', 'o', 't', 'o', 'c', 'o', 'l', 'O', 'p', 't', 'i', 'o', 'n', 's', '\022', '^', 
+'\n', '\025', 'h', 't', 't', 'p', '_', 'p', 'r', 'o', 't', 'o', 'c', 'o', 'l', '_', 'o', 'p', 't', 'i', 'o', 'n', 's', '\030', '\010', 
+' ', '\001', '(', '\013', '2', '*', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 
+'v', '3', '.', 'H', 't', 't', 'p', '1', 'P', 'r', 'o', 't', 'o', 'c', 'o', 'l', 'O', 'p', 't', 'i', 'o', 'n', 's', 'R', '\023', 
+'h', 't', 't', 'p', 'P', 'r', 'o', 't', 'o', 'c', 'o', 'l', 'O', 'p', 't', 'i', 'o', 'n', 's', '\022', 'i', '\n', '\026', 'h', 't', 
+'t', 'p', '2', '_', 'p', 'r', 'o', 't', 'o', 'c', 'o', 'l', '_', 'o', 'p', 't', 'i', 'o', 'n', 's', '\030', '\t', ' ', '\001', '(', 
+'\013', '2', '*', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 
+'H', 't', 't', 'p', '2', 'P', 'r', 'o', 't', 'o', 'c', 'o', 'l', 'O', 'p', 't', 'i', 'o', 'n', 's', 'B', '\007', '\212', '\223', '\267', 
+'*', '\002', '\010', '\001', 'R', '\024', 'h', 't', 't', 'p', '2', 'P', 'r', 'o', 't', 'o', 'c', 'o', 'l', 'O', 'p', 't', 'i', 'o', 'n', 
+'s', '\022', '`', '\n', '\026', 'h', 't', 't', 'p', '3', '_', 'p', 'r', 'o', 't', 'o', 'c', 'o', 'l', '_', 'o', 'p', 't', 'i', 'o', 
+'n', 's', '\030', ',', ' ', '\001', '(', '\013', '2', '*', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 
+'o', 'r', 'e', '.', 'v', '3', '.', 'H', 't', 't', 'p', '3', 'P', 'r', 'o', 't', 'o', 'c', 'o', 'l', 'O', 'p', 't', 'i', 'o', 
+'n', 's', 'R', '\024', 'h', 't', 't', 'p', '3', 'P', 'r', 'o', 't', 'o', 'c', 'o', 'l', 'O', 'p', 't', 'i', 'o', 'n', 's', '\022', 
+',', '\n', '\013', 's', 'e', 'r', 'v', 'e', 'r', '_', 'n', 'a', 'm', 'e', '\030', '\n', ' ', '\001', '(', '\t', 'B', '\013', '\372', 'B', '\010', 
+'r', '\006', '\300', '\001', '\002', '\310', '\001', '\000', 'R', '\n', 's', 'e', 'r', 'v', 'e', 'r', 'N', 'a', 'm', 'e', '\022', '\271', '\001', '\n', '\034', 
+'s', 'e', 'r', 'v', 'e', 'r', '_', 'h', 'e', 'a', 'd', 'e', 'r', '_', 't', 'r', 'a', 'n', 's', 'f', 'o', 'r', 'm', 'a', 't', 
+'i', 'o', 'n', '\030', '\"', ' ', '\001', '(', '\016', '2', 'm', '.', 'e', 'n', 'v', 'o', 'y', '.', 'e', 'x', 't', 'e', 'n', 's', 'i', 
+'o', 'n', 's', '.', 'f', 'i', 'l', 't', 'e', 'r', 's', '.', 'n', 'e', 't', 'w', 'o', 'r', 'k', '.', 'h', 't', 't', 'p', '_', 
+'c', 'o', 'n', 'n', 'e', 'c', 't', 'i', 'o', 'n', '_', 'm', 'a', 'n', 'a', 'g', 'e', 'r', '.', 'v', '3', '.', 'H', 't', 't', 
+'p', 'C', 'o', 'n', 'n', 'e', 'c', 't', 'i', 'o', 'n', 'M', 'a', 'n', 'a', 'g', 'e', 'r', '.', 'S', 'e', 'r', 'v', 'e', 'r', 
+'H', 'e', 'a', 'd', 'e', 'r', 'T', 'r', 'a', 'n', 's', 'f', 'o', 'r', 'm', 'a', 't', 'i', 'o', 'n', 'B', '\010', '\372', 'B', '\005', 
+'\202', '\001', '\002', '\020', '\001', 'R', '\032', 's', 'e', 'r', 'v', 'e', 'r', 'H', 'e', 'a', 'd', 'e', 'r', 'T', 'r', 'a', 'n', 's', 'f', 
+'o', 'r', 'm', 'a', 't', 'i', 'o', 'n', '\022', 'r', '\n', '\034', 's', 'c', 'h', 'e', 'm', 'e', '_', 'h', 'e', 'a', 'd', 'e', 'r', 
+'_', 't', 'r', 'a', 'n', 's', 'f', 'o', 'r', 'm', 'a', 't', 'i', 'o', 'n', '\030', '0', ' ', '\001', '(', '\013', '2', '0', '.', 'e', 
+'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'S', 'c', 'h', 'e', 'm', 
+'e', 'H', 'e', 'a', 'd', 'e', 'r', 'T', 'r', 'a', 'n', 's', 'f', 'o', 'r', 'm', 'a', 't', 'i', 'o', 'n', 'R', '\032', 's', 'c', 
+'h', 'e', 'm', 'e', 'H', 'e', 'a', 'd', 'e', 'r', 'T', 'r', 'a', 'n', 's', 'f', 'o', 'r', 'm', 'a', 't', 'i', 'o', 'n', '\022', 
+']', '\n', '\026', 'm', 'a', 'x', '_', 'r', 'e', 'q', 'u', 'e', 's', 't', '_', 'h', 'e', 'a', 'd', 'e', 'r', 's', '_', 'k', 'b', 
+'\030', '\035', ' ', '\001', '(', '\013', '2', '\034', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 
+'U', 'I', 'n', 't', '3', '2', 'V', 'a', 'l', 'u', 'e', 'B', '\n', '\372', 'B', '\007', '*', '\005', '\030', '\200', '@', ' ', '\000', 'R', '\023', 
+'m', 'a', 'x', 'R', 'e', 'q', 'u', 'e', 's', 't', 'H', 'e', 'a', 'd', 'e', 'r', 's', 'K', 'b', '\022', 'R', '\n', '\023', 's', 't', 
+'r', 'e', 'a', 'm', '_', 'i', 'd', 'l', 'e', '_', 't', 'i', 'm', 'e', 'o', 'u', 't', '\030', '\030', ' ', '\001', '(', '\013', '2', '\031', 
+'.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'D', 'u', 'r', 'a', 't', 'i', 'o', 'n', 
+'B', '\007', '\212', '\223', '\267', '*', '\002', '\010', '\001', 'R', '\021', 's', 't', 'r', 'e', 'a', 'm', 'I', 'd', 'l', 'e', 'T', 'i', 'm', 'e', 
+'o', 'u', 't', '\022', 'K', '\n', '\017', 'r', 'e', 'q', 'u', 'e', 's', 't', '_', 't', 'i', 'm', 'e', 'o', 'u', 't', '\030', '\034', ' ', 
+'\001', '(', '\013', '2', '\031', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'D', 'u', 'r', 
+'a', 't', 'i', 'o', 'n', 'B', '\007', '\212', '\223', '\267', '*', '\002', '\010', '\001', 'R', '\016', 'r', 'e', 'q', 'u', 'e', 's', 't', 'T', 'i', 
+'m', 'e', 'o', 'u', 't', '\022', 'b', '\n', '\027', 'r', 'e', 'q', 'u', 'e', 's', 't', '_', 'h', 'e', 'a', 'd', 'e', 'r', 's', '_', 
+'t', 'i', 'm', 'e', 'o', 'u', 't', '\030', ')', ' ', '\001', '(', '\013', '2', '\031', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 
+'o', 't', 'o', 'b', 'u', 'f', '.', 'D', 'u', 'r', 'a', 't', 'i', 'o', 'n', 'B', '\017', '\372', 'B', '\005', '\252', '\001', '\002', '2', '\000', 
+'\212', '\223', '\267', '*', '\002', '\010', '\001', 'R', '\025', 'r', 'e', 'q', 'u', 'e', 's', 't', 'H', 'e', 'a', 'd', 'e', 'r', 's', 'T', 'i', 
+'m', 'e', 'o', 'u', 't', '\022', '>', '\n', '\r', 'd', 'r', 'a', 'i', 'n', '_', 't', 'i', 'm', 'e', 'o', 'u', 't', '\030', '\014', ' ', 
+'\001', '(', '\013', '2', '\031', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'D', 'u', 'r', 
+'a', 't', 'i', 'o', 'n', 'R', '\014', 'd', 'r', 'a', 'i', 'n', 'T', 'i', 'm', 'e', 'o', 'u', 't', '\022', 'M', '\n', '\025', 'd', 'e', 
+'l', 'a', 'y', 'e', 'd', '_', 'c', 'l', 'o', 's', 'e', '_', 't', 'i', 'm', 'e', 'o', 'u', 't', '\030', '\032', ' ', '\001', '(', '\013', 
 '2', '\031', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'D', 'u', 'r', 'a', 't', 'i', 
-'o', 'n', 'B', '\017', '\372', 'B', '\005', '\252', '\001', '\002', '2', '\000', '\212', '\223', '\267', '*', '\002', '\010', '\001', 'R', '\025', 'r', 'e', 'q', 'u', 
-'e', 's', 't', 'H', 'e', 'a', 'd', 'e', 'r', 's', 'T', 'i', 'm', 'e', 'o', 'u', 't', '\022', '>', '\n', '\r', 'd', 'r', 'a', 'i', 
-'n', '_', 't', 'i', 'm', 'e', 'o', 'u', 't', '\030', '\014', ' ', '\001', '(', '\013', '2', '\031', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 
-'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'D', 'u', 'r', 'a', 't', 'i', 'o', 'n', 'R', '\014', 'd', 'r', 'a', 'i', 'n', 'T', 
-'i', 'm', 'e', 'o', 'u', 't', '\022', 'M', '\n', '\025', 'd', 'e', 'l', 'a', 'y', 'e', 'd', '_', 'c', 'l', 'o', 's', 'e', '_', 't', 
-'i', 'm', 'e', 'o', 'u', 't', '\030', '\032', ' ', '\001', '(', '\013', '2', '\031', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 
-'t', 'o', 'b', 'u', 'f', '.', 'D', 'u', 'r', 'a', 't', 'i', 'o', 'n', 'R', '\023', 'd', 'e', 'l', 'a', 'y', 'e', 'd', 'C', 'l', 
-'o', 's', 'e', 'T', 'i', 'm', 'e', 'o', 'u', 't', '\022', 'C', '\n', '\n', 'a', 'c', 'c', 'e', 's', 's', '_', 'l', 'o', 'g', '\030', 
-'\r', ' ', '\003', '(', '\013', '2', '$', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'a', 'c', 'c', 'e', 
-'s', 's', 'l', 'o', 'g', '.', 'v', '3', '.', 'A', 'c', 'c', 'e', 's', 's', 'L', 'o', 'g', 'R', '\t', 'a', 'c', 'c', 'e', 's', 
-'s', 'L', 'o', 'g', '\022', 'Q', '\n', '\022', 'u', 's', 'e', '_', 'r', 'e', 'm', 'o', 't', 'e', '_', 'a', 'd', 'd', 'r', 'e', 's', 
-'s', '\030', '\016', ' ', '\001', '(', '\013', '2', '\032', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', 
-'.', 'B', 'o', 'o', 'l', 'V', 'a', 'l', 'u', 'e', 'B', '\007', '\212', '\223', '\267', '*', '\002', '\010', '\001', 'R', '\020', 'u', 's', 'e', 'R', 
-'e', 'm', 'o', 't', 'e', 'A', 'd', 'd', 'r', 'e', 's', 's', '\022', '<', '\n', '\024', 'x', 'f', 'f', '_', 'n', 'u', 'm', '_', 't', 
-'r', 'u', 's', 't', 'e', 'd', '_', 'h', 'o', 'p', 's', '\030', '\023', ' ', '\001', '(', '\r', 'B', '\013', '\030', '\001', '\222', '\307', '\206', '\330', 
-'\004', '\003', '3', '.', '0', 'R', '\021', 'x', 'f', 'f', 'N', 'u', 'm', 'T', 'r', 'u', 's', 't', 'e', 'd', 'H', 'o', 'p', 's', '\022', 
+'o', 'n', 'R', '\023', 'd', 'e', 'l', 'a', 'y', 'e', 'd', 'C', 'l', 'o', 's', 'e', 'T', 'i', 'm', 'e', 'o', 'u', 't', '\022', 'C', 
+'\n', '\n', 'a', 'c', 'c', 'e', 's', 's', '_', 'l', 'o', 'g', '\030', '\r', ' ', '\003', '(', '\013', '2', '$', '.', 'e', 'n', 'v', 'o', 
+'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'a', 'c', 'c', 'e', 's', 's', 'l', 'o', 'g', '.', 'v', '3', '.', 'A', 'c', 'c', 
+'e', 's', 's', 'L', 'o', 'g', 'R', '\t', 'a', 'c', 'c', 'e', 's', 's', 'L', 'o', 'g', '\022', 'Q', '\n', '\022', 'u', 's', 'e', '_', 
+'r', 'e', 'm', 'o', 't', 'e', '_', 'a', 'd', 'd', 'r', 'e', 's', 's', '\030', '\016', ' ', '\001', '(', '\013', '2', '\032', '.', 'g', 'o', 
+'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'B', 'o', 'o', 'l', 'V', 'a', 'l', 'u', 'e', 'B', '\007', 
+'\212', '\223', '\267', '*', '\002', '\010', '\001', 'R', '\020', 'u', 's', 'e', 'R', 'e', 'm', 'o', 't', 'e', 'A', 'd', 'd', 'r', 'e', 's', 's', 
+'\022', '/', '\n', '\024', 'x', 'f', 'f', '_', 'n', 'u', 'm', '_', 't', 'r', 'u', 's', 't', 'e', 'd', '_', 'h', 'o', 'p', 's', '\030', 
+'\023', ' ', '\001', '(', '\r', 'R', '\021', 'x', 'f', 'f', 'N', 'u', 'm', 'T', 'r', 'u', 's', 't', 'e', 'd', 'H', 'o', 'p', 's', '\022', 
 's', '\n', ' ', 'o', 'r', 'i', 'g', 'i', 'n', 'a', 'l', '_', 'i', 'p', '_', 'd', 'e', 't', 'e', 'c', 't', 'i', 'o', 'n', '_', 
 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 's', '\030', '.', ' ', '\003', '(', '\013', '2', '*', '.', 'e', 'n', 'v', 'o', 'y', '.', 
 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'T', 'y', 'p', 'e', 'd', 'E', 'x', 't', 'e', 'n', 
@@ -538,7 +535,7 @@ static const char descriptor[11589] = {'\n', 'Y', 'e', 'n', 'v', 'o', 'y', '/',
 '\310', '\321', '\006', '\002', '\020', '\002', 'b', '\006', 'p', 'r', 'o', 't', 'o', '3', 
 };
 
-static upb_def_init *deps[22] = {
+static upb_def_init *deps[21] = {
   &envoy_config_accesslog_v3_accesslog_proto_upbdefinit,
   &envoy_config_core_v3_base_proto_upbdefinit,
   &envoy_config_core_v3_config_source_proto_upbdefinit,
@@ -554,7 +551,6 @@ static upb_def_init *deps[22] = {
   &google_protobuf_any_proto_upbdefinit,
   &google_protobuf_duration_proto_upbdefinit,
   &google_protobuf_wrappers_proto_upbdefinit,
-  &envoy_annotations_deprecation_proto_upbdefinit,
   &udpa_annotations_migrate_proto_upbdefinit,
   &udpa_annotations_security_proto_upbdefinit,
   &udpa_annotations_status_proto_upbdefinit,
@@ -567,5 +563,5 @@ upb_def_init envoy_extensions_filters_network_http_connection_manager_v3_http_co
   deps,
   layouts,
   "envoy/extensions/filters/network/http_connection_manager/v3/http_connection_manager.proto",
-  UPB_STRVIEW_INIT(descriptor, 11589)
+  UPB_STRVIEW_INIT(descriptor, 11539)
 };
index b858209..4c00b2f 100644 (file)
@@ -14,6 +14,7 @@ extern upb_def_init envoy_config_core_v3_extension_proto_upbdefinit;
 extern upb_def_init envoy_type_matcher_v3_string_proto_upbdefinit;
 extern upb_def_init google_protobuf_any_proto_upbdefinit;
 extern upb_def_init google_protobuf_wrappers_proto_upbdefinit;
+extern upb_def_init udpa_annotations_migrate_proto_upbdefinit;
 extern upb_def_init udpa_annotations_sensitive_proto_upbdefinit;
 extern upb_def_init udpa_annotations_status_proto_upbdefinit;
 extern upb_def_init udpa_annotations_versioning_proto_upbdefinit;
@@ -22,17 +23,19 @@ extern const upb_msglayout envoy_extensions_transport_sockets_tls_v3_TlsParamete
 extern const upb_msglayout envoy_extensions_transport_sockets_tls_v3_PrivateKeyProvider_msginit;
 extern const upb_msglayout envoy_extensions_transport_sockets_tls_v3_TlsCertificate_msginit;
 extern const upb_msglayout envoy_extensions_transport_sockets_tls_v3_TlsSessionTicketKeys_msginit;
+extern const upb_msglayout envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance_msginit;
 extern const upb_msglayout envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_msginit;
 
-static const upb_msglayout *layouts[5] = {
+static const upb_msglayout *layouts[6] = {
   &envoy_extensions_transport_sockets_tls_v3_TlsParameters_msginit,
   &envoy_extensions_transport_sockets_tls_v3_PrivateKeyProvider_msginit,
   &envoy_extensions_transport_sockets_tls_v3_TlsCertificate_msginit,
   &envoy_extensions_transport_sockets_tls_v3_TlsSessionTicketKeys_msginit,
+  &envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance_msginit,
   &envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_msginit,
 };
 
-static const char descriptor[3052] = {'\n', '6', 'e', 'n', 'v', 'o', 'y', '/', 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 's', '/', 't', 'r', 'a', 'n', 's', 'p', 
+static const char descriptor[3401] = {'\n', '6', 'e', 'n', 'v', 'o', 'y', '/', 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 's', '/', 't', 'r', 'a', 'n', 's', 'p', 
 'o', 'r', 't', '_', 's', 'o', 'c', 'k', 'e', 't', 's', '/', 't', 'l', 's', '/', 'v', '3', '/', 'c', 'o', 'm', 'm', 'o', 'n', 
 '.', 'p', 'r', 'o', 't', 'o', '\022', ')', 'e', 'n', 'v', 'o', 'y', '.', 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 's', '.', 
 't', 'r', 'a', 'n', 's', 'p', 'o', 'r', 't', '_', 's', 'o', 'c', 'k', 'e', 't', 's', '.', 't', 'l', 's', '.', 'v', '3', '\032', 
@@ -42,127 +45,142 @@ static const char descriptor[3052] = {'\n', '6', 'e', 'n', 'v', 'o', 'y', '/', '
 'o', 'y', '/', 't', 'y', 'p', 'e', '/', 'm', 'a', 't', 'c', 'h', 'e', 'r', '/', 'v', '3', '/', 's', 't', 'r', 'i', 'n', 'g', 
 '.', 'p', 'r', 'o', 't', 'o', '\032', '\031', 'g', 'o', 'o', 'g', 'l', 'e', '/', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '/', 'a', 
 'n', 'y', '.', 'p', 'r', 'o', 't', 'o', '\032', '\036', 'g', 'o', 'o', 'g', 'l', 'e', '/', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', 
-'/', 'w', 'r', 'a', 'p', 'p', 'e', 'r', 's', '.', 'p', 'r', 'o', 't', 'o', '\032', ' ', 'u', 'd', 'p', 'a', '/', 'a', 'n', 'n', 
-'o', 't', 'a', 't', 'i', 'o', 'n', 's', '/', 's', 'e', 'n', 's', 'i', 't', 'i', 'v', 'e', '.', 'p', 'r', 'o', 't', 'o', '\032', 
-'\035', 'u', 'd', 'p', 'a', '/', 'a', 'n', 'n', 'o', 't', 'a', 't', 'i', 'o', 'n', 's', '/', 's', 't', 'a', 't', 'u', 's', '.', 
-'p', 'r', 'o', 't', 'o', '\032', '!', 'u', 'd', 'p', 'a', '/', 'a', 'n', 'n', 'o', 't', 'a', 't', 'i', 'o', 'n', 's', '/', 'v', 
-'e', 'r', 's', 'i', 'o', 'n', 'i', 'n', 'g', '.', 'p', 'r', 'o', 't', 'o', '\032', '\027', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'e', 
-'/', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'e', '.', 'p', 'r', 'o', 't', 'o', '\"', '\362', '\003', '\n', '\r', 'T', 'l', 's', 'P', 'a', 
-'r', 'a', 'm', 'e', 't', 'e', 'r', 's', '\022', '\217', '\001', '\n', '\034', 't', 'l', 's', '_', 'm', 'i', 'n', 'i', 'm', 'u', 'm', '_', 
-'p', 'r', 'o', 't', 'o', 'c', 'o', 'l', '_', 'v', 'e', 'r', 's', 'i', 'o', 'n', '\030', '\001', ' ', '\001', '(', '\016', '2', 'D', '.', 
-'e', 'n', 'v', 'o', 'y', '.', 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 's', '.', 't', 'r', 'a', 'n', 's', 'p', 'o', 'r', 
-'t', '_', 's', 'o', 'c', 'k', 'e', 't', 's', '.', 't', 'l', 's', '.', 'v', '3', '.', 'T', 'l', 's', 'P', 'a', 'r', 'a', 'm', 
-'e', 't', 'e', 'r', 's', '.', 'T', 'l', 's', 'P', 'r', 'o', 't', 'o', 'c', 'o', 'l', 'B', '\010', '\372', 'B', '\005', '\202', '\001', '\002', 
-'\020', '\001', 'R', '\031', 't', 'l', 's', 'M', 'i', 'n', 'i', 'm', 'u', 'm', 'P', 'r', 'o', 't', 'o', 'c', 'o', 'l', 'V', 'e', 'r', 
-'s', 'i', 'o', 'n', '\022', '\217', '\001', '\n', '\034', 't', 'l', 's', '_', 'm', 'a', 'x', 'i', 'm', 'u', 'm', '_', 'p', 'r', 'o', 't', 
-'o', 'c', 'o', 'l', '_', 'v', 'e', 'r', 's', 'i', 'o', 'n', '\030', '\002', ' ', '\001', '(', '\016', '2', 'D', '.', 'e', 'n', 'v', 'o', 
-'y', '.', 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 's', '.', 't', 'r', 'a', 'n', 's', 'p', 'o', 'r', 't', '_', 's', 'o', 
-'c', 'k', 'e', 't', 's', '.', 't', 'l', 's', '.', 'v', '3', '.', 'T', 'l', 's', 'P', 'a', 'r', 'a', 'm', 'e', 't', 'e', 'r', 
-'s', '.', 'T', 'l', 's', 'P', 'r', 'o', 't', 'o', 'c', 'o', 'l', 'B', '\010', '\372', 'B', '\005', '\202', '\001', '\002', '\020', '\001', 'R', '\031', 
-'t', 'l', 's', 'M', 'a', 'x', 'i', 'm', 'u', 'm', 'P', 'r', 'o', 't', 'o', 'c', 'o', 'l', 'V', 'e', 'r', 's', 'i', 'o', 'n', 
-'\022', '#', '\n', '\r', 'c', 'i', 'p', 'h', 'e', 'r', '_', 's', 'u', 'i', 't', 'e', 's', '\030', '\003', ' ', '\003', '(', '\t', 'R', '\014', 
-'c', 'i', 'p', 'h', 'e', 'r', 'S', 'u', 'i', 't', 'e', 's', '\022', '\037', '\n', '\013', 'e', 'c', 'd', 'h', '_', 'c', 'u', 'r', 'v', 
-'e', 's', '\030', '\004', ' ', '\003', '(', '\t', 'R', '\n', 'e', 'c', 'd', 'h', 'C', 'u', 'r', 'v', 'e', 's', '\"', 'O', '\n', '\013', 'T', 
-'l', 's', 'P', 'r', 'o', 't', 'o', 'c', 'o', 'l', '\022', '\014', '\n', '\010', 'T', 'L', 'S', '_', 'A', 'U', 'T', 'O', '\020', '\000', '\022', 
-'\013', '\n', '\007', 'T', 'L', 'S', 'v', '1', '_', '0', '\020', '\001', '\022', '\013', '\n', '\007', 'T', 'L', 'S', 'v', '1', '_', '1', '\020', '\002', 
-'\022', '\013', '\n', '\007', 'T', 'L', 'S', 'v', '1', '_', '2', '\020', '\003', '\022', '\013', '\n', '\007', 'T', 'L', 'S', 'v', '1', '_', '3', '\020', 
-'\004', ':', '&', '\232', '\305', '\210', '\036', '!', '\n', '\037', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'a', 'u', 
-'t', 'h', '.', 'T', 'l', 's', 'P', 'a', 'r', 'a', 'm', 'e', 't', 'e', 'r', 's', '\"', '\317', '\001', '\n', '\022', 'P', 'r', 'i', 'v', 
-'a', 't', 'e', 'K', 'e', 'y', 'P', 'r', 'o', 'v', 'i', 'd', 'e', 'r', '\022', ',', '\n', '\r', 'p', 'r', 'o', 'v', 'i', 'd', 'e', 
-'r', '_', 'n', 'a', 'm', 'e', '\030', '\001', ' ', '\001', '(', '\t', 'B', '\007', '\372', 'B', '\004', 'r', '\002', '\020', '\001', 'R', '\014', 'p', 'r', 
-'o', 'v', 'i', 'd', 'e', 'r', 'N', 'a', 'm', 'e', '\022', 'A', '\n', '\014', 't', 'y', 'p', 'e', 'd', '_', 'c', 'o', 'n', 'f', 'i', 
-'g', '\030', '\003', ' ', '\001', '(', '\013', '2', '\024', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', 
-'.', 'A', 'n', 'y', 'B', '\006', '\270', '\267', '\213', '\244', '\002', '\001', 'H', '\000', 'R', '\013', 't', 'y', 'p', 'e', 'd', 'C', 'o', 'n', 'f', 
-'i', 'g', ':', '+', '\232', '\305', '\210', '\036', '&', '\n', '$', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'a', 
-'u', 't', 'h', '.', 'P', 'r', 'i', 'v', 'a', 't', 'e', 'K', 'e', 'y', 'P', 'r', 'o', 'v', 'i', 'd', 'e', 'r', 'B', '\r', '\n', 
-'\013', 'c', 'o', 'n', 'f', 'i', 'g', '_', 't', 'y', 'p', 'e', 'J', '\004', '\010', '\002', '\020', '\003', 'R', '\006', 'c', 'o', 'n', 'f', 'i', 
-'g', '\"', '\206', '\005', '\n', '\016', 'T', 'l', 's', 'C', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', '\022', 'M', '\n', '\021', 'c', 
-'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', '_', 'c', 'h', 'a', 'i', 'n', '\030', '\001', ' ', '\001', '(', '\013', '2', ' ', '.', 
+'/', 'w', 'r', 'a', 'p', 'p', 'e', 'r', 's', '.', 'p', 'r', 'o', 't', 'o', '\032', '\036', 'u', 'd', 'p', 'a', '/', 'a', 'n', 'n', 
+'o', 't', 'a', 't', 'i', 'o', 'n', 's', '/', 'm', 'i', 'g', 'r', 'a', 't', 'e', '.', 'p', 'r', 'o', 't', 'o', '\032', ' ', 'u', 
+'d', 'p', 'a', '/', 'a', 'n', 'n', 'o', 't', 'a', 't', 'i', 'o', 'n', 's', '/', 's', 'e', 'n', 's', 'i', 't', 'i', 'v', 'e', 
+'.', 'p', 'r', 'o', 't', 'o', '\032', '\035', 'u', 'd', 'p', 'a', '/', 'a', 'n', 'n', 'o', 't', 'a', 't', 'i', 'o', 'n', 's', '/', 
+'s', 't', 'a', 't', 'u', 's', '.', 'p', 'r', 'o', 't', 'o', '\032', '!', 'u', 'd', 'p', 'a', '/', 'a', 'n', 'n', 'o', 't', 'a', 
+'t', 'i', 'o', 'n', 's', '/', 'v', 'e', 'r', 's', 'i', 'o', 'n', 'i', 'n', 'g', '.', 'p', 'r', 'o', 't', 'o', '\032', '\027', 'v', 
+'a', 'l', 'i', 'd', 'a', 't', 'e', '/', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'e', '.', 'p', 'r', 'o', 't', 'o', '\"', '\362', '\003', 
+'\n', '\r', 'T', 'l', 's', 'P', 'a', 'r', 'a', 'm', 'e', 't', 'e', 'r', 's', '\022', '\217', '\001', '\n', '\034', 't', 'l', 's', '_', 'm', 
+'i', 'n', 'i', 'm', 'u', 'm', '_', 'p', 'r', 'o', 't', 'o', 'c', 'o', 'l', '_', 'v', 'e', 'r', 's', 'i', 'o', 'n', '\030', '\001', 
+' ', '\001', '(', '\016', '2', 'D', '.', 'e', 'n', 'v', 'o', 'y', '.', 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 's', '.', 't', 
+'r', 'a', 'n', 's', 'p', 'o', 'r', 't', '_', 's', 'o', 'c', 'k', 'e', 't', 's', '.', 't', 'l', 's', '.', 'v', '3', '.', 'T', 
+'l', 's', 'P', 'a', 'r', 'a', 'm', 'e', 't', 'e', 'r', 's', '.', 'T', 'l', 's', 'P', 'r', 'o', 't', 'o', 'c', 'o', 'l', 'B', 
+'\010', '\372', 'B', '\005', '\202', '\001', '\002', '\020', '\001', 'R', '\031', 't', 'l', 's', 'M', 'i', 'n', 'i', 'm', 'u', 'm', 'P', 'r', 'o', 't', 
+'o', 'c', 'o', 'l', 'V', 'e', 'r', 's', 'i', 'o', 'n', '\022', '\217', '\001', '\n', '\034', 't', 'l', 's', '_', 'm', 'a', 'x', 'i', 'm', 
+'u', 'm', '_', 'p', 'r', 'o', 't', 'o', 'c', 'o', 'l', '_', 'v', 'e', 'r', 's', 'i', 'o', 'n', '\030', '\002', ' ', '\001', '(', '\016', 
+'2', 'D', '.', 'e', 'n', 'v', 'o', 'y', '.', 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 's', '.', 't', 'r', 'a', 'n', 's', 
+'p', 'o', 'r', 't', '_', 's', 'o', 'c', 'k', 'e', 't', 's', '.', 't', 'l', 's', '.', 'v', '3', '.', 'T', 'l', 's', 'P', 'a', 
+'r', 'a', 'm', 'e', 't', 'e', 'r', 's', '.', 'T', 'l', 's', 'P', 'r', 'o', 't', 'o', 'c', 'o', 'l', 'B', '\010', '\372', 'B', '\005', 
+'\202', '\001', '\002', '\020', '\001', 'R', '\031', 't', 'l', 's', 'M', 'a', 'x', 'i', 'm', 'u', 'm', 'P', 'r', 'o', 't', 'o', 'c', 'o', 'l', 
+'V', 'e', 'r', 's', 'i', 'o', 'n', '\022', '#', '\n', '\r', 'c', 'i', 'p', 'h', 'e', 'r', '_', 's', 'u', 'i', 't', 'e', 's', '\030', 
+'\003', ' ', '\003', '(', '\t', 'R', '\014', 'c', 'i', 'p', 'h', 'e', 'r', 'S', 'u', 'i', 't', 'e', 's', '\022', '\037', '\n', '\013', 'e', 'c', 
+'d', 'h', '_', 'c', 'u', 'r', 'v', 'e', 's', '\030', '\004', ' ', '\003', '(', '\t', 'R', '\n', 'e', 'c', 'd', 'h', 'C', 'u', 'r', 'v', 
+'e', 's', '\"', 'O', '\n', '\013', 'T', 'l', 's', 'P', 'r', 'o', 't', 'o', 'c', 'o', 'l', '\022', '\014', '\n', '\010', 'T', 'L', 'S', '_', 
+'A', 'U', 'T', 'O', '\020', '\000', '\022', '\013', '\n', '\007', 'T', 'L', 'S', 'v', '1', '_', '0', '\020', '\001', '\022', '\013', '\n', '\007', 'T', 'L', 
+'S', 'v', '1', '_', '1', '\020', '\002', '\022', '\013', '\n', '\007', 'T', 'L', 'S', 'v', '1', '_', '2', '\020', '\003', '\022', '\013', '\n', '\007', 'T', 
+'L', 'S', 'v', '1', '_', '3', '\020', '\004', ':', '&', '\232', '\305', '\210', '\036', '!', '\n', '\037', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 
+'i', '.', 'v', '2', '.', 'a', 'u', 't', 'h', '.', 'T', 'l', 's', 'P', 'a', 'r', 'a', 'm', 'e', 't', 'e', 'r', 's', '\"', '\317', 
+'\001', '\n', '\022', 'P', 'r', 'i', 'v', 'a', 't', 'e', 'K', 'e', 'y', 'P', 'r', 'o', 'v', 'i', 'd', 'e', 'r', '\022', ',', '\n', '\r', 
+'p', 'r', 'o', 'v', 'i', 'd', 'e', 'r', '_', 'n', 'a', 'm', 'e', '\030', '\001', ' ', '\001', '(', '\t', 'B', '\007', '\372', 'B', '\004', 'r', 
+'\002', '\020', '\001', 'R', '\014', 'p', 'r', 'o', 'v', 'i', 'd', 'e', 'r', 'N', 'a', 'm', 'e', '\022', 'A', '\n', '\014', 't', 'y', 'p', 'e', 
+'d', '_', 'c', 'o', 'n', 'f', 'i', 'g', '\030', '\003', ' ', '\001', '(', '\013', '2', '\024', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 
+'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'A', 'n', 'y', 'B', '\006', '\270', '\267', '\213', '\244', '\002', '\001', 'H', '\000', 'R', '\013', 't', 'y', 
+'p', 'e', 'd', 'C', 'o', 'n', 'f', 'i', 'g', ':', '+', '\232', '\305', '\210', '\036', '&', '\n', '$', 'e', 'n', 'v', 'o', 'y', '.', 'a', 
+'p', 'i', '.', 'v', '2', '.', 'a', 'u', 't', 'h', '.', 'P', 'r', 'i', 'v', 'a', 't', 'e', 'K', 'e', 'y', 'P', 'r', 'o', 'v', 
+'i', 'd', 'e', 'r', 'B', '\r', '\n', '\013', 'c', 'o', 'n', 'f', 'i', 'g', '_', 't', 'y', 'p', 'e', 'J', '\004', '\010', '\002', '\020', '\003', 
+'R', '\006', 'c', 'o', 'n', 'f', 'i', 'g', '\"', '\206', '\005', '\n', '\016', 'T', 'l', 's', 'C', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 
+'t', 'e', '\022', 'M', '\n', '\021', 'c', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', '_', 'c', 'h', 'a', 'i', 'n', '\030', '\001', 
+' ', '\001', '(', '\013', '2', ' ', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 
+'v', '3', '.', 'D', 'a', 't', 'a', 'S', 'o', 'u', 'r', 'c', 'e', 'R', '\020', 'c', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 
+'e', 'C', 'h', 'a', 'i', 'n', '\022', 'I', '\n', '\013', 'p', 'r', 'i', 'v', 'a', 't', 'e', '_', 'k', 'e', 'y', '\030', '\002', ' ', '\001', 
+'(', '\013', '2', ' ', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', 
+'.', 'D', 'a', 't', 'a', 'S', 'o', 'u', 'r', 'c', 'e', 'B', '\006', '\270', '\267', '\213', '\244', '\002', '\001', 'R', '\n', 'p', 'r', 'i', 'v', 
+'a', 't', 'e', 'K', 'e', 'y', '\022', 'S', '\n', '\021', 'w', 'a', 't', 'c', 'h', 'e', 'd', '_', 'd', 'i', 'r', 'e', 'c', 't', 'o', 
+'r', 'y', '\030', '\007', ' ', '\001', '(', '\013', '2', '&', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 
+'o', 'r', 'e', '.', 'v', '3', '.', 'W', 'a', 't', 'c', 'h', 'e', 'd', 'D', 'i', 'r', 'e', 'c', 't', 'o', 'r', 'y', 'R', '\020', 
+'w', 'a', 't', 'c', 'h', 'e', 'd', 'D', 'i', 'r', 'e', 'c', 't', 'o', 'r', 'y', '\022', 'o', '\n', '\024', 'p', 'r', 'i', 'v', 'a', 
+'t', 'e', '_', 'k', 'e', 'y', '_', 'p', 'r', 'o', 'v', 'i', 'd', 'e', 'r', '\030', '\006', ' ', '\001', '(', '\013', '2', '=', '.', 'e', 
+'n', 'v', 'o', 'y', '.', 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 's', '.', 't', 'r', 'a', 'n', 's', 'p', 'o', 'r', 't', 
+'_', 's', 'o', 'c', 'k', 'e', 't', 's', '.', 't', 'l', 's', '.', 'v', '3', '.', 'P', 'r', 'i', 'v', 'a', 't', 'e', 'K', 'e', 
+'y', 'P', 'r', 'o', 'v', 'i', 'd', 'e', 'r', 'R', '\022', 'p', 'r', 'i', 'v', 'a', 't', 'e', 'K', 'e', 'y', 'P', 'r', 'o', 'v', 
+'i', 'd', 'e', 'r', '\022', 'D', '\n', '\010', 'p', 'a', 's', 's', 'w', 'o', 'r', 'd', '\030', '\003', ' ', '\001', '(', '\013', '2', ' ', '.', 
 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'D', 'a', 't', 'a', 
-'S', 'o', 'u', 'r', 'c', 'e', 'R', '\020', 'c', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', 'C', 'h', 'a', 'i', 'n', '\022', 
-'I', '\n', '\013', 'p', 'r', 'i', 'v', 'a', 't', 'e', '_', 'k', 'e', 'y', '\030', '\002', ' ', '\001', '(', '\013', '2', ' ', '.', 'e', 'n', 
+'S', 'o', 'u', 'r', 'c', 'e', 'B', '\006', '\270', '\267', '\213', '\244', '\002', '\001', 'R', '\010', 'p', 'a', 's', 's', 'w', 'o', 'r', 'd', '\022', 
+'A', '\n', '\013', 'o', 'c', 's', 'p', '_', 's', 't', 'a', 'p', 'l', 'e', '\030', '\004', ' ', '\001', '(', '\013', '2', ' ', '.', 'e', 'n', 
 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'D', 'a', 't', 'a', 'S', 'o', 
-'u', 'r', 'c', 'e', 'B', '\006', '\270', '\267', '\213', '\244', '\002', '\001', 'R', '\n', 'p', 'r', 'i', 'v', 'a', 't', 'e', 'K', 'e', 'y', '\022', 
-'S', '\n', '\021', 'w', 'a', 't', 'c', 'h', 'e', 'd', '_', 'd', 'i', 'r', 'e', 'c', 't', 'o', 'r', 'y', '\030', '\007', ' ', '\001', '(', 
-'\013', '2', '&', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 
-'W', 'a', 't', 'c', 'h', 'e', 'd', 'D', 'i', 'r', 'e', 'c', 't', 'o', 'r', 'y', 'R', '\020', 'w', 'a', 't', 'c', 'h', 'e', 'd', 
-'D', 'i', 'r', 'e', 'c', 't', 'o', 'r', 'y', '\022', 'o', '\n', '\024', 'p', 'r', 'i', 'v', 'a', 't', 'e', '_', 'k', 'e', 'y', '_', 
-'p', 'r', 'o', 'v', 'i', 'd', 'e', 'r', '\030', '\006', ' ', '\001', '(', '\013', '2', '=', '.', 'e', 'n', 'v', 'o', 'y', '.', 'e', 'x', 
-'t', 'e', 'n', 's', 'i', 'o', 'n', 's', '.', 't', 'r', 'a', 'n', 's', 'p', 'o', 'r', 't', '_', 's', 'o', 'c', 'k', 'e', 't', 
-'s', '.', 't', 'l', 's', '.', 'v', '3', '.', 'P', 'r', 'i', 'v', 'a', 't', 'e', 'K', 'e', 'y', 'P', 'r', 'o', 'v', 'i', 'd', 
-'e', 'r', 'R', '\022', 'p', 'r', 'i', 'v', 'a', 't', 'e', 'K', 'e', 'y', 'P', 'r', 'o', 'v', 'i', 'd', 'e', 'r', '\022', 'D', '\n', 
-'\010', 'p', 'a', 's', 's', 'w', 'o', 'r', 'd', '\030', '\003', ' ', '\001', '(', '\013', '2', ' ', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 
-'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'D', 'a', 't', 'a', 'S', 'o', 'u', 'r', 'c', 'e', 'B', 
-'\006', '\270', '\267', '\213', '\244', '\002', '\001', 'R', '\010', 'p', 'a', 's', 's', 'w', 'o', 'r', 'd', '\022', 'A', '\n', '\013', 'o', 'c', 's', 'p', 
-'_', 's', 't', 'a', 'p', 'l', 'e', '\030', '\004', ' ', '\001', '(', '\013', '2', ' ', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 
-'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'D', 'a', 't', 'a', 'S', 'o', 'u', 'r', 'c', 'e', 'R', '\n', 'o', 
-'c', 's', 'p', 'S', 't', 'a', 'p', 'l', 'e', '\022', 'b', '\n', '\034', 's', 'i', 'g', 'n', 'e', 'd', '_', 'c', 'e', 'r', 't', 'i', 
-'f', 'i', 'c', 'a', 't', 'e', '_', 't', 'i', 'm', 'e', 's', 't', 'a', 'm', 'p', '\030', '\005', ' ', '\003', '(', '\013', '2', ' ', '.', 
-'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'D', 'a', 't', 'a', 
-'S', 'o', 'u', 'r', 'c', 'e', 'R', '\032', 's', 'i', 'g', 'n', 'e', 'd', 'C', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', 
-'T', 'i', 'm', 'e', 's', 't', 'a', 'm', 'p', ':', '\'', '\232', '\305', '\210', '\036', '\"', '\n', ' ', 'e', 'n', 'v', 'o', 'y', '.', 'a', 
-'p', 'i', '.', 'v', '2', '.', 'a', 'u', 't', 'h', '.', 'T', 'l', 's', 'C', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', 
-'\"', '\213', '\001', '\n', '\024', 'T', 'l', 's', 'S', 'e', 's', 's', 'i', 'o', 'n', 'T', 'i', 'c', 'k', 'e', 't', 'K', 'e', 'y', 's', 
-'\022', 'D', '\n', '\004', 'k', 'e', 'y', 's', '\030', '\001', ' ', '\003', '(', '\013', '2', ' ', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 
-'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'D', 'a', 't', 'a', 'S', 'o', 'u', 'r', 'c', 'e', 'B', '\016', 
-'\372', 'B', '\005', '\222', '\001', '\002', '\010', '\001', '\270', '\267', '\213', '\244', '\002', '\001', 'R', '\004', 'k', 'e', 'y', 's', ':', '-', '\232', '\305', '\210', 
-'\036', '(', '\n', '&', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'a', 'u', 't', 'h', '.', 'T', 'l', 's', 
-'S', 'e', 's', 's', 'i', 'o', 'n', 'T', 'i', 'c', 'k', 'e', 't', 'K', 'e', 'y', 's', '\"', '\253', '\010', '\n', '\034', 'C', 'e', 'r', 
-'t', 'i', 'f', 'i', 'c', 'a', 't', 'e', 'V', 'a', 'l', 'i', 'd', 'a', 't', 'i', 'o', 'n', 'C', 'o', 'n', 't', 'e', 'x', 't', 
-'\022', '?', '\n', '\n', 't', 'r', 'u', 's', 't', 'e', 'd', '_', 'c', 'a', '\030', '\001', ' ', '\001', '(', '\013', '2', ' ', '.', 'e', 'n', 
-'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'D', 'a', 't', 'a', 'S', 'o', 
-'u', 'r', 'c', 'e', 'R', '\t', 't', 'r', 'u', 's', 't', 'e', 'd', 'C', 'a', '\022', 'S', '\n', '\021', 'w', 'a', 't', 'c', 'h', 'e', 
-'d', '_', 'd', 'i', 'r', 'e', 'c', 't', 'o', 'r', 'y', '\030', '\013', ' ', '\001', '(', '\013', '2', '&', '.', 'e', 'n', 'v', 'o', 'y', 
-'.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'W', 'a', 't', 'c', 'h', 'e', 'd', 'D', 'i', 
-'r', 'e', 'c', 't', 'o', 'r', 'y', 'R', '\020', 'w', 'a', 't', 'c', 'h', 'e', 'd', 'D', 'i', 'r', 'e', 'c', 't', 'o', 'r', 'y', 
-'\022', 'F', '\n', '\027', 'v', 'e', 'r', 'i', 'f', 'y', '_', 'c', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', '_', 's', 'p', 
-'k', 'i', '\030', '\003', ' ', '\003', '(', '\t', 'B', '\016', '\372', 'B', '\013', '\222', '\001', '\010', '\"', '\006', 'r', '\004', '\020', ',', '(', ',', 'R', 
-'\025', 'v', 'e', 'r', 'i', 'f', 'y', 'C', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', 'S', 'p', 'k', 'i', '\022', 'F', '\n', 
-'\027', 'v', 'e', 'r', 'i', 'f', 'y', '_', 'c', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', '_', 'h', 'a', 's', 'h', '\030', 
-'\002', ' ', '\003', '(', '\t', 'B', '\016', '\372', 'B', '\013', '\222', '\001', '\010', '\"', '\006', 'r', '\004', '\020', '@', '(', '_', 'R', '\025', 'v', 'e', 
-'r', 'i', 'f', 'y', 'C', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', 'H', 'a', 's', 'h', '\022', '[', '\n', '\027', 'm', 'a', 
-'t', 'c', 'h', '_', 's', 'u', 'b', 'j', 'e', 'c', 't', '_', 'a', 'l', 't', '_', 'n', 'a', 'm', 'e', 's', '\030', '\t', ' ', '\003', 
-'(', '\013', '2', '$', '.', 'e', 'n', 'v', 'o', 'y', '.', 't', 'y', 'p', 'e', '.', 'm', 'a', 't', 'c', 'h', 'e', 'r', '.', 'v', 
-'3', '.', 'S', 't', 'r', 'i', 'n', 'g', 'M', 'a', 't', 'c', 'h', 'e', 'r', 'R', '\024', 'm', 'a', 't', 'c', 'h', 'S', 'u', 'b', 
-'j', 'e', 'c', 't', 'A', 'l', 't', 'N', 'a', 'm', 'e', 's', '\022', 'k', '\n', '$', 'r', 'e', 'q', 'u', 'i', 'r', 'e', '_', 's', 
-'i', 'g', 'n', 'e', 'd', '_', 'c', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', '_', 't', 'i', 'm', 'e', 's', 't', 'a', 
-'m', 'p', '\030', '\006', ' ', '\001', '(', '\013', '2', '\032', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 
-'f', '.', 'B', 'o', 'o', 'l', 'V', 'a', 'l', 'u', 'e', 'R', '!', 'r', 'e', 'q', 'u', 'i', 'r', 'e', 'S', 'i', 'g', 'n', 'e', 
-'d', 'C', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', 'T', 'i', 'm', 'e', 's', 't', 'a', 'm', 'p', '\022', '2', '\n', '\003', 
-'c', 'r', 'l', '\030', '\007', ' ', '\001', '(', '\013', '2', ' ', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 
-'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'D', 'a', 't', 'a', 'S', 'o', 'u', 'r', 'c', 'e', 'R', '\003', 'c', 'r', 'l', '\022', ':', 
-'\n', '\031', 'a', 'l', 'l', 'o', 'w', '_', 'e', 'x', 'p', 'i', 'r', 'e', 'd', '_', 'c', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 
-'t', 'e', '\030', '\010', ' ', '\001', '(', '\010', 'R', '\027', 'a', 'l', 'l', 'o', 'w', 'E', 'x', 'p', 'i', 'r', 'e', 'd', 'C', 'e', 'r', 
-'t', 'i', 'f', 'i', 'c', 'a', 't', 'e', '\022', '\242', '\001', '\n', '\030', 't', 'r', 'u', 's', 't', '_', 'c', 'h', 'a', 'i', 'n', '_', 
-'v', 'e', 'r', 'i', 'f', 'i', 'c', 'a', 't', 'i', 'o', 'n', '\030', '\n', ' ', '\001', '(', '\016', '2', '^', '.', 'e', 'n', 'v', 'o', 
-'y', '.', 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 's', '.', 't', 'r', 'a', 'n', 's', 'p', 'o', 'r', 't', '_', 's', 'o', 
-'c', 'k', 'e', 't', 's', '.', 't', 'l', 's', '.', 'v', '3', '.', 'C', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', 'V', 
-'a', 'l', 'i', 'd', 'a', 't', 'i', 'o', 'n', 'C', 'o', 'n', 't', 'e', 'x', 't', '.', 'T', 'r', 'u', 's', 't', 'C', 'h', 'a', 
-'i', 'n', 'V', 'e', 'r', 'i', 'f', 'i', 'c', 'a', 't', 'i', 'o', 'n', 'B', '\010', '\372', 'B', '\005', '\202', '\001', '\002', '\020', '\001', 'R', 
-'\026', 't', 'r', 'u', 's', 't', 'C', 'h', 'a', 'i', 'n', 'V', 'e', 'r', 'i', 'f', 'i', 'c', 'a', 't', 'i', 'o', 'n', '\022', 'b', 
-'\n', '\027', 'c', 'u', 's', 't', 'o', 'm', '_', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'o', 'r', '_', 'c', 'o', 'n', 'f', 'i', 'g', 
-'\030', '\014', ' ', '\001', '(', '\013', '2', '*', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 
-'e', '.', 'v', '3', '.', 'T', 'y', 'p', 'e', 'd', 'E', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 'C', 'o', 'n', 'f', 'i', 'g', 
-'R', '\025', 'c', 'u', 's', 't', 'o', 'm', 'V', 'a', 'l', 'i', 'd', 'a', 't', 'o', 'r', 'C', 'o', 'n', 'f', 'i', 'g', '\"', 'F', 
-'\n', '\026', 'T', 'r', 'u', 's', 't', 'C', 'h', 'a', 'i', 'n', 'V', 'e', 'r', 'i', 'f', 'i', 'c', 'a', 't', 'i', 'o', 'n', '\022', 
-'\026', '\n', '\022', 'V', 'E', 'R', 'I', 'F', 'Y', '_', 'T', 'R', 'U', 'S', 'T', '_', 'C', 'H', 'A', 'I', 'N', '\020', '\000', '\022', '\024', 
-'\n', '\020', 'A', 'C', 'C', 'E', 'P', 'T', '_', 'U', 'N', 'T', 'R', 'U', 'S', 'T', 'E', 'D', '\020', '\001', ':', '5', '\232', '\305', '\210', 
-'\036', '0', '\n', '.', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'a', 'u', 't', 'h', '.', 'C', 'e', 'r', 
-'t', 'i', 'f', 'i', 'c', 'a', 't', 'e', 'V', 'a', 'l', 'i', 'd', 'a', 't', 'i', 'o', 'n', 'C', 'o', 'n', 't', 'e', 'x', 't', 
-'J', '\004', '\010', '\004', '\020', '\005', 'J', '\004', '\010', '\005', '\020', '\006', 'R', '\027', 'v', 'e', 'r', 'i', 'f', 'y', '_', 's', 'u', 'b', 'j', 
-'e', 'c', 't', '_', 'a', 'l', 't', '_', 'n', 'a', 'm', 'e', 'B', 'P', '\n', '7', 'i', 'o', '.', 'e', 'n', 'v', 'o', 'y', 'p', 
-'r', 'o', 'x', 'y', '.', 'e', 'n', 'v', 'o', 'y', '.', 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 's', '.', 't', 'r', 'a', 
-'n', 's', 'p', 'o', 'r', 't', '_', 's', 'o', 'c', 'k', 'e', 't', 's', '.', 't', 'l', 's', '.', 'v', '3', 'B', '\013', 'C', 'o', 
-'m', 'm', 'o', 'n', 'P', 'r', 'o', 't', 'o', 'P', '\001', '\272', '\200', '\310', '\321', '\006', '\002', '\020', '\002', 'b', '\006', 'p', 'r', 'o', 't', 
-'o', '3', 
+'u', 'r', 'c', 'e', 'R', '\n', 'o', 'c', 's', 'p', 'S', 't', 'a', 'p', 'l', 'e', '\022', 'b', '\n', '\034', 's', 'i', 'g', 'n', 'e', 
+'d', '_', 'c', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', '_', 't', 'i', 'm', 'e', 's', 't', 'a', 'm', 'p', '\030', '\005', 
+' ', '\003', '(', '\013', '2', ' ', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 
+'v', '3', '.', 'D', 'a', 't', 'a', 'S', 'o', 'u', 'r', 'c', 'e', 'R', '\032', 's', 'i', 'g', 'n', 'e', 'd', 'C', 'e', 'r', 't', 
+'i', 'f', 'i', 'c', 'a', 't', 'e', 'T', 'i', 'm', 'e', 's', 't', 'a', 'm', 'p', ':', '\'', '\232', '\305', '\210', '\036', '\"', '\n', ' ', 
+'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'a', 'u', 't', 'h', '.', 'T', 'l', 's', 'C', 'e', 'r', 't', 
+'i', 'f', 'i', 'c', 'a', 't', 'e', '\"', '\213', '\001', '\n', '\024', 'T', 'l', 's', 'S', 'e', 's', 's', 'i', 'o', 'n', 'T', 'i', 'c', 
+'k', 'e', 't', 'K', 'e', 'y', 's', '\022', 'D', '\n', '\004', 'k', 'e', 'y', 's', '\030', '\001', ' ', '\003', '(', '\013', '2', ' ', '.', 'e', 
+'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'D', 'a', 't', 'a', 'S', 
+'o', 'u', 'r', 'c', 'e', 'B', '\016', '\372', 'B', '\005', '\222', '\001', '\002', '\010', '\001', '\270', '\267', '\213', '\244', '\002', '\001', 'R', '\004', 'k', 'e', 
+'y', 's', ':', '-', '\232', '\305', '\210', '\036', '(', '\n', '&', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'a', 
+'u', 't', 'h', '.', 'T', 'l', 's', 'S', 'e', 's', 's', 'i', 'o', 'n', 'T', 'i', 'c', 'k', 'e', 't', 'K', 'e', 'y', 's', '\"', 
+'s', '\n', '!', 'C', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', 'P', 'r', 'o', 'v', 'i', 'd', 'e', 'r', 'P', 'l', 'u', 
+'g', 'i', 'n', 'I', 'n', 's', 't', 'a', 'n', 'c', 'e', '\022', '#', '\n', '\r', 'i', 'n', 's', 't', 'a', 'n', 'c', 'e', '_', 'n', 
+'a', 'm', 'e', '\030', '\001', ' ', '\001', '(', '\t', 'R', '\014', 'i', 'n', 's', 't', 'a', 'n', 'c', 'e', 'N', 'a', 'm', 'e', '\022', ')', 
+'\n', '\020', 'c', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', '_', 'n', 'a', 'm', 'e', '\030', '\002', ' ', '\001', '(', '\t', 'R', 
+'\017', 'c', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', 'N', 'a', 'm', 'e', '\"', '\363', '\t', '\n', '\034', 'C', 'e', 'r', 't', 
+'i', 'f', 'i', 'c', 'a', 't', 'e', 'V', 'a', 'l', 'i', 'd', 'a', 't', 'i', 'o', 'n', 'C', 'o', 'n', 't', 'e', 'x', 't', '\022', 
+'W', '\n', '\n', 't', 'r', 'u', 's', 't', 'e', 'd', '_', 'c', 'a', '\030', '\001', ' ', '\001', '(', '\013', '2', ' ', '.', 'e', 'n', 'v', 
+'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'D', 'a', 't', 'a', 'S', 'o', 'u', 
+'r', 'c', 'e', 'B', '\026', '\362', '\230', '\376', '\217', '\005', '\020', '\022', '\016', 'c', 'a', '_', 'c', 'e', 'r', 't', '_', 's', 'o', 'u', 'r', 
+'c', 'e', 'R', '\t', 't', 'r', 'u', 's', 't', 'e', 'd', 'C', 'a', '\022', '\255', '\001', '\n', ' ', 'c', 'a', '_', 'c', 'e', 'r', 't', 
+'i', 'f', 'i', 'c', 'a', 't', 'e', '_', 'p', 'r', 'o', 'v', 'i', 'd', 'e', 'r', '_', 'i', 'n', 's', 't', 'a', 'n', 'c', 'e', 
+'\030', '\r', ' ', '\001', '(', '\013', '2', 'L', '.', 'e', 'n', 'v', 'o', 'y', '.', 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 's', 
+'.', 't', 'r', 'a', 'n', 's', 'p', 'o', 'r', 't', '_', 's', 'o', 'c', 'k', 'e', 't', 's', '.', 't', 'l', 's', '.', 'v', '3', 
+'.', 'C', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', 'P', 'r', 'o', 'v', 'i', 'd', 'e', 'r', 'P', 'l', 'u', 'g', 'i', 
+'n', 'I', 'n', 's', 't', 'a', 'n', 'c', 'e', 'B', '\026', '\362', '\230', '\376', '\217', '\005', '\020', '\022', '\016', 'c', 'a', '_', 'c', 'e', 'r', 
+'t', '_', 's', 'o', 'u', 'r', 'c', 'e', 'R', '\035', 'c', 'a', 'C', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', 'P', 'r', 
+'o', 'v', 'i', 'd', 'e', 'r', 'I', 'n', 's', 't', 'a', 'n', 'c', 'e', '\022', 'S', '\n', '\021', 'w', 'a', 't', 'c', 'h', 'e', 'd', 
+'_', 'd', 'i', 'r', 'e', 'c', 't', 'o', 'r', 'y', '\030', '\013', ' ', '\001', '(', '\013', '2', '&', '.', 'e', 'n', 'v', 'o', 'y', '.', 
+'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'W', 'a', 't', 'c', 'h', 'e', 'd', 'D', 'i', 'r', 
+'e', 'c', 't', 'o', 'r', 'y', 'R', '\020', 'w', 'a', 't', 'c', 'h', 'e', 'd', 'D', 'i', 'r', 'e', 'c', 't', 'o', 'r', 'y', '\022', 
+'F', '\n', '\027', 'v', 'e', 'r', 'i', 'f', 'y', '_', 'c', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', '_', 's', 'p', 'k', 
+'i', '\030', '\003', ' ', '\003', '(', '\t', 'B', '\016', '\372', 'B', '\013', '\222', '\001', '\010', '\"', '\006', 'r', '\004', '\020', ',', '(', ',', 'R', '\025', 
+'v', 'e', 'r', 'i', 'f', 'y', 'C', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', 'S', 'p', 'k', 'i', '\022', 'F', '\n', '\027', 
+'v', 'e', 'r', 'i', 'f', 'y', '_', 'c', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', '_', 'h', 'a', 's', 'h', '\030', '\002', 
+' ', '\003', '(', '\t', 'B', '\016', '\372', 'B', '\013', '\222', '\001', '\010', '\"', '\006', 'r', '\004', '\020', '@', '(', '_', 'R', '\025', 'v', 'e', 'r', 
+'i', 'f', 'y', 'C', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', 'H', 'a', 's', 'h', '\022', '[', '\n', '\027', 'm', 'a', 't', 
+'c', 'h', '_', 's', 'u', 'b', 'j', 'e', 'c', 't', '_', 'a', 'l', 't', '_', 'n', 'a', 'm', 'e', 's', '\030', '\t', ' ', '\003', '(', 
+'\013', '2', '$', '.', 'e', 'n', 'v', 'o', 'y', '.', 't', 'y', 'p', 'e', '.', 'm', 'a', 't', 'c', 'h', 'e', 'r', '.', 'v', '3', 
+'.', 'S', 't', 'r', 'i', 'n', 'g', 'M', 'a', 't', 'c', 'h', 'e', 'r', 'R', '\024', 'm', 'a', 't', 'c', 'h', 'S', 'u', 'b', 'j', 
+'e', 'c', 't', 'A', 'l', 't', 'N', 'a', 'm', 'e', 's', '\022', 'k', '\n', '$', 'r', 'e', 'q', 'u', 'i', 'r', 'e', '_', 's', 'i', 
+'g', 'n', 'e', 'd', '_', 'c', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', '_', 't', 'i', 'm', 'e', 's', 't', 'a', 'm', 
+'p', '\030', '\006', ' ', '\001', '(', '\013', '2', '\032', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', 
+'.', 'B', 'o', 'o', 'l', 'V', 'a', 'l', 'u', 'e', 'R', '!', 'r', 'e', 'q', 'u', 'i', 'r', 'e', 'S', 'i', 'g', 'n', 'e', 'd', 
+'C', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', 'T', 'i', 'm', 'e', 's', 't', 'a', 'm', 'p', '\022', '2', '\n', '\003', 'c', 
+'r', 'l', '\030', '\007', ' ', '\001', '(', '\013', '2', ' ', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 
+'o', 'r', 'e', '.', 'v', '3', '.', 'D', 'a', 't', 'a', 'S', 'o', 'u', 'r', 'c', 'e', 'R', '\003', 'c', 'r', 'l', '\022', ':', '\n', 
+'\031', 'a', 'l', 'l', 'o', 'w', '_', 'e', 'x', 'p', 'i', 'r', 'e', 'd', '_', 'c', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 
+'e', '\030', '\010', ' ', '\001', '(', '\010', 'R', '\027', 'a', 'l', 'l', 'o', 'w', 'E', 'x', 'p', 'i', 'r', 'e', 'd', 'C', 'e', 'r', 't', 
+'i', 'f', 'i', 'c', 'a', 't', 'e', '\022', '\242', '\001', '\n', '\030', 't', 'r', 'u', 's', 't', '_', 'c', 'h', 'a', 'i', 'n', '_', 'v', 
+'e', 'r', 'i', 'f', 'i', 'c', 'a', 't', 'i', 'o', 'n', '\030', '\n', ' ', '\001', '(', '\016', '2', '^', '.', 'e', 'n', 'v', 'o', 'y', 
+'.', 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 's', '.', 't', 'r', 'a', 'n', 's', 'p', 'o', 'r', 't', '_', 's', 'o', 'c', 
+'k', 'e', 't', 's', '.', 't', 'l', 's', '.', 'v', '3', '.', 'C', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', 'V', 'a', 
+'l', 'i', 'd', 'a', 't', 'i', 'o', 'n', 'C', 'o', 'n', 't', 'e', 'x', 't', '.', 'T', 'r', 'u', 's', 't', 'C', 'h', 'a', 'i', 
+'n', 'V', 'e', 'r', 'i', 'f', 'i', 'c', 'a', 't', 'i', 'o', 'n', 'B', '\010', '\372', 'B', '\005', '\202', '\001', '\002', '\020', '\001', 'R', '\026', 
+'t', 'r', 'u', 's', 't', 'C', 'h', 'a', 'i', 'n', 'V', 'e', 'r', 'i', 'f', 'i', 'c', 'a', 't', 'i', 'o', 'n', '\022', 'b', '\n', 
+'\027', 'c', 'u', 's', 't', 'o', 'm', '_', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'o', 'r', '_', 'c', 'o', 'n', 'f', 'i', 'g', '\030', 
+'\014', ' ', '\001', '(', '\013', '2', '*', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', 
+'.', 'v', '3', '.', 'T', 'y', 'p', 'e', 'd', 'E', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 'C', 'o', 'n', 'f', 'i', 'g', 'R', 
+'\025', 'c', 'u', 's', 't', 'o', 'm', 'V', 'a', 'l', 'i', 'd', 'a', 't', 'o', 'r', 'C', 'o', 'n', 'f', 'i', 'g', '\"', 'F', '\n', 
+'\026', 'T', 'r', 'u', 's', 't', 'C', 'h', 'a', 'i', 'n', 'V', 'e', 'r', 'i', 'f', 'i', 'c', 'a', 't', 'i', 'o', 'n', '\022', '\026', 
+'\n', '\022', 'V', 'E', 'R', 'I', 'F', 'Y', '_', 'T', 'R', 'U', 'S', 'T', '_', 'C', 'H', 'A', 'I', 'N', '\020', '\000', '\022', '\024', '\n', 
+'\020', 'A', 'C', 'C', 'E', 'P', 'T', '_', 'U', 'N', 'T', 'R', 'U', 'S', 'T', 'E', 'D', '\020', '\001', ':', '5', '\232', '\305', '\210', '\036', 
+'0', '\n', '.', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'a', 'u', 't', 'h', '.', 'C', 'e', 'r', 't', 
+'i', 'f', 'i', 'c', 'a', 't', 'e', 'V', 'a', 'l', 'i', 'd', 'a', 't', 'i', 'o', 'n', 'C', 'o', 'n', 't', 'e', 'x', 't', 'J', 
+'\004', '\010', '\004', '\020', '\005', 'J', '\004', '\010', '\005', '\020', '\006', 'R', '\027', 'v', 'e', 'r', 'i', 'f', 'y', '_', 's', 'u', 'b', 'j', 'e', 
+'c', 't', '_', 'a', 'l', 't', '_', 'n', 'a', 'm', 'e', 'B', 'P', '\n', '7', 'i', 'o', '.', 'e', 'n', 'v', 'o', 'y', 'p', 'r', 
+'o', 'x', 'y', '.', 'e', 'n', 'v', 'o', 'y', '.', 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 's', '.', 't', 'r', 'a', 'n', 
+'s', 'p', 'o', 'r', 't', '_', 's', 'o', 'c', 'k', 'e', 't', 's', '.', 't', 'l', 's', '.', 'v', '3', 'B', '\013', 'C', 'o', 'm', 
+'m', 'o', 'n', 'P', 'r', 'o', 't', 'o', 'P', '\001', '\272', '\200', '\310', '\321', '\006', '\002', '\020', '\002', 'b', '\006', 'p', 'r', 'o', 't', 'o', 
+'3', 
 };
 
-static upb_def_init *deps[10] = {
+static upb_def_init *deps[11] = {
   &envoy_config_core_v3_base_proto_upbdefinit,
   &envoy_config_core_v3_extension_proto_upbdefinit,
   &envoy_type_matcher_v3_string_proto_upbdefinit,
   &google_protobuf_any_proto_upbdefinit,
   &google_protobuf_wrappers_proto_upbdefinit,
+  &udpa_annotations_migrate_proto_upbdefinit,
   &udpa_annotations_sensitive_proto_upbdefinit,
   &udpa_annotations_status_proto_upbdefinit,
   &udpa_annotations_versioning_proto_upbdefinit,
@@ -174,5 +192,5 @@ upb_def_init envoy_extensions_transport_sockets_tls_v3_common_proto_upbdefinit =
   deps,
   layouts,
   "envoy/extensions/transport_sockets/tls/v3/common.proto",
-  UPB_STRVIEW_INIT(descriptor, 3052)
+  UPB_STRVIEW_INIT(descriptor, 3401)
 };
index b289899..397f5af 100644 (file)
@@ -41,6 +41,11 @@ UPB_INLINE const upb_msgdef *envoy_extensions_transport_sockets_tls_v3_TlsSessio
   return upb_symtab_lookupmsg(s, "envoy.extensions.transport_sockets.tls.v3.TlsSessionTicketKeys");
 }
 
+UPB_INLINE const upb_msgdef *envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance_getmsgdef(upb_symtab *s) {
+  _upb_symtab_loaddefinit(s, &envoy_extensions_transport_sockets_tls_v3_common_proto_upbdefinit);
+  return upb_symtab_lookupmsg(s, "envoy.extensions.transport_sockets.tls.v3.CertificateProviderPluginInstance");
+}
+
 UPB_INLINE const upb_msgdef *envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_getmsgdef(upb_symtab *s) {
   _upb_symtab_loaddefinit(s, &envoy_extensions_transport_sockets_tls_v3_common_proto_upbdefinit);
   return upb_symtab_lookupmsg(s, "envoy.extensions.transport_sockets.tls.v3.CertificateValidationContext");
index ed4129c..113ca3b 100644 (file)
@@ -14,7 +14,7 @@ extern upb_def_init envoy_extensions_transport_sockets_tls_v3_common_proto_upbde
 extern upb_def_init envoy_extensions_transport_sockets_tls_v3_secret_proto_upbdefinit;
 extern upb_def_init google_protobuf_duration_proto_upbdefinit;
 extern upb_def_init google_protobuf_wrappers_proto_upbdefinit;
-extern upb_def_init udpa_annotations_migrate_proto_upbdefinit;
+extern upb_def_init envoy_annotations_deprecation_proto_upbdefinit;
 extern upb_def_init udpa_annotations_status_proto_upbdefinit;
 extern upb_def_init udpa_annotations_versioning_proto_upbdefinit;
 extern upb_def_init validate_validate_proto_upbdefinit;
@@ -34,7 +34,7 @@ static const upb_msglayout *layouts[6] = {
   &envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CombinedCertificateValidationContext_msginit,
 };
 
-static const char descriptor[4707] = {'\n', '3', 'e', 'n', 'v', 'o', 'y', '/', 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 's', '/', 't', 'r', 'a', 'n', 's', 'p', 
+static const char descriptor[4838] = {'\n', '3', 'e', 'n', 'v', 'o', 'y', '/', 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 's', '/', 't', 'r', 'a', 'n', 's', 'p', 
 'o', 'r', 't', '_', 's', 'o', 'c', 'k', 'e', 't', 's', '/', 't', 'l', 's', '/', 'v', '3', '/', 't', 'l', 's', '.', 'p', 'r', 
 'o', 't', 'o', '\022', ')', 'e', 'n', 'v', 'o', 'y', '.', 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 's', '.', 't', 'r', 'a', 
 'n', 's', 'p', 'o', 'r', 't', '_', 's', 'o', 'c', 'k', 'e', 't', 's', '.', 't', 'l', 's', '.', 'v', '3', '\032', '$', 'e', 'n', 
@@ -46,183 +46,188 @@ static const char descriptor[4707] = {'\n', '3', 'e', 'n', 'v', 'o', 'y', '/', '
 's', '/', 't', 'l', 's', '/', 'v', '3', '/', 's', 'e', 'c', 'r', 'e', 't', '.', 'p', 'r', 'o', 't', 'o', '\032', '\036', 'g', 'o', 
 'o', 'g', 'l', 'e', '/', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '/', 'd', 'u', 'r', 'a', 't', 'i', 'o', 'n', '.', 'p', 'r', 
 'o', 't', 'o', '\032', '\036', 'g', 'o', 'o', 'g', 'l', 'e', '/', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '/', 'w', 'r', 'a', 'p', 
-'p', 'e', 'r', 's', '.', 'p', 'r', 'o', 't', 'o', '\032', '\036', 'u', 'd', 'p', 'a', '/', 'a', 'n', 'n', 'o', 't', 'a', 't', 'i', 
-'o', 'n', 's', '/', 'm', 'i', 'g', 'r', 'a', 't', 'e', '.', 'p', 'r', 'o', 't', 'o', '\032', '\035', 'u', 'd', 'p', 'a', '/', 'a', 
-'n', 'n', 'o', 't', 'a', 't', 'i', 'o', 'n', 's', '/', 's', 't', 'a', 't', 'u', 's', '.', 'p', 'r', 'o', 't', 'o', '\032', '!', 
-'u', 'd', 'p', 'a', '/', 'a', 'n', 'n', 'o', 't', 'a', 't', 'i', 'o', 'n', 's', '/', 'v', 'e', 'r', 's', 'i', 'o', 'n', 'i', 
-'n', 'g', '.', 'p', 'r', 'o', 't', 'o', '\032', '\027', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'e', '/', 'v', 'a', 'l', 'i', 'd', 'a', 
-'t', 'e', '.', 'p', 'r', 'o', 't', 'o', '\"', '\301', '\002', '\n', '\022', 'U', 'p', 's', 't', 'r', 'e', 'a', 'm', 'T', 'l', 's', 'C', 
-'o', 'n', 't', 'e', 'x', 't', '\022', 'i', '\n', '\022', 'c', 'o', 'm', 'm', 'o', 'n', '_', 't', 'l', 's', '_', 'c', 'o', 'n', 't', 
-'e', 'x', 't', '\030', '\001', ' ', '\001', '(', '\013', '2', ';', '.', 'e', 'n', 'v', 'o', 'y', '.', 'e', 'x', 't', 'e', 'n', 's', 'i', 
-'o', 'n', 's', '.', 't', 'r', 'a', 'n', 's', 'p', 'o', 'r', 't', '_', 's', 'o', 'c', 'k', 'e', 't', 's', '.', 't', 'l', 's', 
-'.', 'v', '3', '.', 'C', 'o', 'm', 'm', 'o', 'n', 'T', 'l', 's', 'C', 'o', 'n', 't', 'e', 'x', 't', 'R', '\020', 'c', 'o', 'm', 
-'m', 'o', 'n', 'T', 'l', 's', 'C', 'o', 'n', 't', 'e', 'x', 't', '\022', '\032', '\n', '\003', 's', 'n', 'i', '\030', '\002', ' ', '\001', '(', 
-'\t', 'B', '\010', '\372', 'B', '\005', 'r', '\003', '(', '\377', '\001', 'R', '\003', 's', 'n', 'i', '\022', '/', '\n', '\023', 'a', 'l', 'l', 'o', 'w', 
-'_', 'r', 'e', 'n', 'e', 'g', 'o', 't', 'i', 'a', 't', 'i', 'o', 'n', '\030', '\003', ' ', '\001', '(', '\010', 'R', '\022', 'a', 'l', 'l', 
-'o', 'w', 'R', 'e', 'n', 'e', 'g', 'o', 't', 'i', 'a', 't', 'i', 'o', 'n', '\022', 'F', '\n', '\020', 'm', 'a', 'x', '_', 's', 'e', 
-'s', 's', 'i', 'o', 'n', '_', 'k', 'e', 'y', 's', '\030', '\004', ' ', '\001', '(', '\013', '2', '\034', '.', 'g', 'o', 'o', 'g', 'l', 'e', 
-'.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'U', 'I', 'n', 't', '3', '2', 'V', 'a', 'l', 'u', 'e', 'R', '\016', 'm', 'a', 
-'x', 'S', 'e', 's', 's', 'i', 'o', 'n', 'K', 'e', 'y', 's', ':', '+', '\232', '\305', '\210', '\036', '&', '\n', '$', 'e', 'n', 'v', 'o', 
-'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'a', 'u', 't', 'h', '.', 'U', 'p', 's', 't', 'r', 'e', 'a', 'm', 'T', 'l', 's', 
-'C', 'o', 'n', 't', 'e', 'x', 't', '\"', '\352', '\007', '\n', '\024', 'D', 'o', 'w', 'n', 's', 't', 'r', 'e', 'a', 'm', 'T', 'l', 's', 
-'C', 'o', 'n', 't', 'e', 'x', 't', '\022', 'i', '\n', '\022', 'c', 'o', 'm', 'm', 'o', 'n', '_', 't', 'l', 's', '_', 'c', 'o', 'n', 
-'t', 'e', 'x', 't', '\030', '\001', ' ', '\001', '(', '\013', '2', ';', '.', 'e', 'n', 'v', 'o', 'y', '.', 'e', 'x', 't', 'e', 'n', 's', 
-'i', 'o', 'n', 's', '.', 't', 'r', 'a', 'n', 's', 'p', 'o', 'r', 't', '_', 's', 'o', 'c', 'k', 'e', 't', 's', '.', 't', 'l', 
-'s', '.', 'v', '3', '.', 'C', 'o', 'm', 'm', 'o', 'n', 'T', 'l', 's', 'C', 'o', 'n', 't', 'e', 'x', 't', 'R', '\020', 'c', 'o', 
-'m', 'm', 'o', 'n', 'T', 'l', 's', 'C', 'o', 'n', 't', 'e', 'x', 't', '\022', 'X', '\n', '\032', 'r', 'e', 'q', 'u', 'i', 'r', 'e', 
-'_', 'c', 'l', 'i', 'e', 'n', 't', '_', 'c', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', '\030', '\002', ' ', '\001', '(', '\013', 
-'2', '\032', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'B', 'o', 'o', 'l', 'V', 'a', 
-'l', 'u', 'e', 'R', '\030', 'r', 'e', 'q', 'u', 'i', 'r', 'e', 'C', 'l', 'i', 'e', 'n', 't', 'C', 'e', 'r', 't', 'i', 'f', 'i', 
-'c', 'a', 't', 'e', '\022', ';', '\n', '\013', 'r', 'e', 'q', 'u', 'i', 'r', 'e', '_', 's', 'n', 'i', '\030', '\003', ' ', '\001', '(', '\013', 
-'2', '\032', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'B', 'o', 'o', 'l', 'V', 'a', 
-'l', 'u', 'e', 'R', '\n', 'r', 'e', 'q', 'u', 'i', 'r', 'e', 'S', 'n', 'i', '\022', 'q', '\n', '\023', 's', 'e', 's', 's', 'i', 'o', 
-'n', '_', 't', 'i', 'c', 'k', 'e', 't', '_', 'k', 'e', 'y', 's', '\030', '\004', ' ', '\001', '(', '\013', '2', '?', '.', 'e', 'n', 'v', 
-'o', 'y', '.', 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 's', '.', 't', 'r', 'a', 'n', 's', 'p', 'o', 'r', 't', '_', 's', 
-'o', 'c', 'k', 'e', 't', 's', '.', 't', 'l', 's', '.', 'v', '3', '.', 'T', 'l', 's', 'S', 'e', 's', 's', 'i', 'o', 'n', 'T', 
-'i', 'c', 'k', 'e', 't', 'K', 'e', 'y', 's', 'H', '\000', 'R', '\021', 's', 'e', 's', 's', 'i', 'o', 'n', 'T', 'i', 'c', 'k', 'e', 
-'t', 'K', 'e', 'y', 's', '\022', '\215', '\001', '\n', '%', 's', 'e', 's', 's', 'i', 'o', 'n', '_', 't', 'i', 'c', 'k', 'e', 't', '_', 
-'k', 'e', 'y', 's', '_', 's', 'd', 's', '_', 's', 'e', 'c', 'r', 'e', 't', '_', 'c', 'o', 'n', 'f', 'i', 'g', '\030', '\005', ' ', 
-'\001', '(', '\013', '2', ':', '.', 'e', 'n', 'v', 'o', 'y', '.', 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 's', '.', 't', 'r', 
-'a', 'n', 's', 'p', 'o', 'r', 't', '_', 's', 'o', 'c', 'k', 'e', 't', 's', '.', 't', 'l', 's', '.', 'v', '3', '.', 'S', 'd', 
-'s', 'S', 'e', 'c', 'r', 'e', 't', 'C', 'o', 'n', 'f', 'i', 'g', 'H', '\000', 'R', ' ', 's', 'e', 's', 's', 'i', 'o', 'n', 'T', 
-'i', 'c', 'k', 'e', 't', 'K', 'e', 'y', 's', 'S', 'd', 's', 'S', 'e', 'c', 'r', 'e', 't', 'C', 'o', 'n', 'f', 'i', 'g', '\022', 
-'Q', '\n', '$', 'd', 'i', 's', 'a', 'b', 'l', 'e', '_', 's', 't', 'a', 't', 'e', 'l', 'e', 's', 's', '_', 's', 'e', 's', 's', 
-'i', 'o', 'n', '_', 'r', 'e', 's', 'u', 'm', 'p', 't', 'i', 'o', 'n', '\030', '\007', ' ', '\001', '(', '\010', 'H', '\000', 'R', '!', 'd', 
-'i', 's', 'a', 'b', 'l', 'e', 'S', 't', 'a', 't', 'e', 'l', 'e', 's', 's', 'S', 'e', 's', 's', 'i', 'o', 'n', 'R', 'e', 's', 
-'u', 'm', 'p', 't', 'i', 'o', 'n', '\022', 'T', '\n', '\017', 's', 'e', 's', 's', 'i', 'o', 'n', '_', 't', 'i', 'm', 'e', 'o', 'u', 
-'t', '\030', '\006', ' ', '\001', '(', '\013', '2', '\031', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', 
-'.', 'D', 'u', 'r', 'a', 't', 'i', 'o', 'n', 'B', '\020', '\372', 'B', '\r', '\252', '\001', '\n', '\032', '\006', '\010', '\200', '\200', '\200', '\200', '\020', 
-'2', '\000', 'R', '\016', 's', 'e', 's', 's', 'i', 'o', 'n', 'T', 'i', 'm', 'e', 'o', 'u', 't', '\022', '\210', '\001', '\n', '\022', 'o', 'c', 
-'s', 'p', '_', 's', 't', 'a', 'p', 'l', 'e', '_', 'p', 'o', 'l', 'i', 'c', 'y', '\030', '\010', ' ', '\001', '(', '\016', '2', 'P', '.', 
-'e', 'n', 'v', 'o', 'y', '.', 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 's', '.', 't', 'r', 'a', 'n', 's', 'p', 'o', 'r', 
-'t', '_', 's', 'o', 'c', 'k', 'e', 't', 's', '.', 't', 'l', 's', '.', 'v', '3', '.', 'D', 'o', 'w', 'n', 's', 't', 'r', 'e', 
-'a', 'm', 'T', 'l', 's', 'C', 'o', 'n', 't', 'e', 'x', 't', '.', 'O', 'c', 's', 'p', 'S', 't', 'a', 'p', 'l', 'e', 'P', 'o', 
-'l', 'i', 'c', 'y', 'B', '\010', '\372', 'B', '\005', '\202', '\001', '\002', '\020', '\001', 'R', '\020', 'o', 'c', 's', 'p', 'S', 't', 'a', 'p', 'l', 
-'e', 'P', 'o', 'l', 'i', 'c', 'y', '\"', 'N', '\n', '\020', 'O', 'c', 's', 'p', 'S', 't', 'a', 'p', 'l', 'e', 'P', 'o', 'l', 'i', 
-'c', 'y', '\022', '\024', '\n', '\020', 'L', 'E', 'N', 'I', 'E', 'N', 'T', '_', 'S', 'T', 'A', 'P', 'L', 'I', 'N', 'G', '\020', '\000', '\022', 
-'\023', '\n', '\017', 'S', 'T', 'R', 'I', 'C', 'T', '_', 'S', 'T', 'A', 'P', 'L', 'I', 'N', 'G', '\020', '\001', '\022', '\017', '\n', '\013', 'M', 
-'U', 'S', 'T', '_', 'S', 'T', 'A', 'P', 'L', 'E', '\020', '\002', ':', '-', '\232', '\305', '\210', '\036', '(', '\n', '&', 'e', 'n', 'v', 'o', 
-'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'a', 'u', 't', 'h', '.', 'D', 'o', 'w', 'n', 's', 't', 'r', 'e', 'a', 'm', 'T', 
-'l', 's', 'C', 'o', 'n', 't', 'e', 'x', 't', 'B', '\032', '\n', '\030', 's', 'e', 's', 's', 'i', 'o', 'n', '_', 't', 'i', 'c', 'k', 
-'e', 't', '_', 'k', 'e', 'y', 's', '_', 't', 'y', 'p', 'e', '\"', '\247', '\026', '\n', '\020', 'C', 'o', 'm', 'm', 'o', 'n', 'T', 'l', 
-'s', 'C', 'o', 'n', 't', 'e', 'x', 't', '\022', 'W', '\n', '\n', 't', 'l', 's', '_', 'p', 'a', 'r', 'a', 'm', 's', '\030', '\001', ' ', 
-'\001', '(', '\013', '2', '8', '.', 'e', 'n', 'v', 'o', 'y', '.', 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 's', '.', 't', 'r', 
-'a', 'n', 's', 'p', 'o', 'r', 't', '_', 's', 'o', 'c', 'k', 'e', 't', 's', '.', 't', 'l', 's', '.', 'v', '3', '.', 'T', 'l', 
-'s', 'P', 'a', 'r', 'a', 'm', 'e', 't', 'e', 'r', 's', 'R', '\t', 't', 'l', 's', 'P', 'a', 'r', 'a', 'm', 's', '\022', 'd', '\n', 
-'\020', 't', 'l', 's', '_', 'c', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', 's', '\030', '\002', ' ', '\003', '(', '\013', '2', '9', 
-'.', 'e', 'n', 'v', 'o', 'y', '.', 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 's', '.', 't', 'r', 'a', 'n', 's', 'p', 'o', 
-'r', 't', '_', 's', 'o', 'c', 'k', 'e', 't', 's', '.', 't', 'l', 's', '.', 'v', '3', '.', 'T', 'l', 's', 'C', 'e', 'r', 't', 
-'i', 'f', 'i', 'c', 'a', 't', 'e', 'R', '\017', 't', 'l', 's', 'C', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', 's', '\022', 
-'\220', '\001', '\n', '\"', 't', 'l', 's', '_', 'c', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', '_', 's', 'd', 's', '_', 's', 
-'e', 'c', 'r', 'e', 't', '_', 'c', 'o', 'n', 'f', 'i', 'g', 's', '\030', '\006', ' ', '\003', '(', '\013', '2', ':', '.', 'e', 'n', 'v', 
-'o', 'y', '.', 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 's', '.', 't', 'r', 'a', 'n', 's', 'p', 'o', 'r', 't', '_', 's', 
-'o', 'c', 'k', 'e', 't', 's', '.', 't', 'l', 's', '.', 'v', '3', '.', 'S', 'd', 's', 'S', 'e', 'c', 'r', 'e', 't', 'C', 'o', 
-'n', 'f', 'i', 'g', 'B', '\010', '\372', 'B', '\005', '\222', '\001', '\002', '\020', '\002', 'R', '\036', 't', 'l', 's', 'C', 'e', 'r', 't', 'i', 'f', 
-'i', 'c', 'a', 't', 'e', 'S', 'd', 's', 'S', 'e', 'c', 'r', 'e', 't', 'C', 'o', 'n', 'f', 'i', 'g', 's', '\022', '\240', '\001', '\n', 
-'$', 't', 'l', 's', '_', 'c', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', '_', 'c', 'e', 'r', 't', 'i', 'f', 'i', 'c', 
-'a', 't', 'e', '_', 'p', 'r', 'o', 'v', 'i', 'd', 'e', 'r', '\030', '\t', ' ', '\001', '(', '\013', '2', 'O', '.', 'e', 'n', 'v', 'o', 
-'y', '.', 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 's', '.', 't', 'r', 'a', 'n', 's', 'p', 'o', 'r', 't', '_', 's', 'o', 
-'c', 'k', 'e', 't', 's', '.', 't', 'l', 's', '.', 'v', '3', '.', 'C', 'o', 'm', 'm', 'o', 'n', 'T', 'l', 's', 'C', 'o', 'n', 
-'t', 'e', 'x', 't', '.', 'C', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', 'P', 'r', 'o', 'v', 'i', 'd', 'e', 'r', 'R', 
-'!', 't', 'l', 's', 'C', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', 'C', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 
-'e', 'P', 'r', 'o', 'v', 'i', 'd', 'e', 'r', '\022', '\271', '\001', '\n', '-', 't', 'l', 's', '_', 'c', 'e', 'r', 't', 'i', 'f', 'i', 
-'c', 'a', 't', 'e', '_', 'c', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', '_', 'p', 'r', 'o', 'v', 'i', 'd', 'e', 'r', 
-'_', 'i', 'n', 's', 't', 'a', 'n', 'c', 'e', '\030', '\013', ' ', '\001', '(', '\013', '2', 'W', '.', 'e', 'n', 'v', 'o', 'y', '.', 'e', 
+'p', 'e', 'r', 's', '.', 'p', 'r', 'o', 't', 'o', '\032', '#', 'e', 'n', 'v', 'o', 'y', '/', 'a', 'n', 'n', 'o', 't', 'a', 't', 
+'i', 'o', 'n', 's', '/', 'd', 'e', 'p', 'r', 'e', 'c', 'a', 't', 'i', 'o', 'n', '.', 'p', 'r', 'o', 't', 'o', '\032', '\035', 'u', 
+'d', 'p', 'a', '/', 'a', 'n', 'n', 'o', 't', 'a', 't', 'i', 'o', 'n', 's', '/', 's', 't', 'a', 't', 'u', 's', '.', 'p', 'r', 
+'o', 't', 'o', '\032', '!', 'u', 'd', 'p', 'a', '/', 'a', 'n', 'n', 'o', 't', 'a', 't', 'i', 'o', 'n', 's', '/', 'v', 'e', 'r', 
+'s', 'i', 'o', 'n', 'i', 'n', 'g', '.', 'p', 'r', 'o', 't', 'o', '\032', '\027', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'e', '/', 'v', 
+'a', 'l', 'i', 'd', 'a', 't', 'e', '.', 'p', 'r', 'o', 't', 'o', '\"', '\301', '\002', '\n', '\022', 'U', 'p', 's', 't', 'r', 'e', 'a', 
+'m', 'T', 'l', 's', 'C', 'o', 'n', 't', 'e', 'x', 't', '\022', 'i', '\n', '\022', 'c', 'o', 'm', 'm', 'o', 'n', '_', 't', 'l', 's', 
+'_', 'c', 'o', 'n', 't', 'e', 'x', 't', '\030', '\001', ' ', '\001', '(', '\013', '2', ';', '.', 'e', 'n', 'v', 'o', 'y', '.', 'e', 'x', 
+'t', 'e', 'n', 's', 'i', 'o', 'n', 's', '.', 't', 'r', 'a', 'n', 's', 'p', 'o', 'r', 't', '_', 's', 'o', 'c', 'k', 'e', 't', 
+'s', '.', 't', 'l', 's', '.', 'v', '3', '.', 'C', 'o', 'm', 'm', 'o', 'n', 'T', 'l', 's', 'C', 'o', 'n', 't', 'e', 'x', 't', 
+'R', '\020', 'c', 'o', 'm', 'm', 'o', 'n', 'T', 'l', 's', 'C', 'o', 'n', 't', 'e', 'x', 't', '\022', '\032', '\n', '\003', 's', 'n', 'i', 
+'\030', '\002', ' ', '\001', '(', '\t', 'B', '\010', '\372', 'B', '\005', 'r', '\003', '(', '\377', '\001', 'R', '\003', 's', 'n', 'i', '\022', '/', '\n', '\023', 
+'a', 'l', 'l', 'o', 'w', '_', 'r', 'e', 'n', 'e', 'g', 'o', 't', 'i', 'a', 't', 'i', 'o', 'n', '\030', '\003', ' ', '\001', '(', '\010', 
+'R', '\022', 'a', 'l', 'l', 'o', 'w', 'R', 'e', 'n', 'e', 'g', 'o', 't', 'i', 'a', 't', 'i', 'o', 'n', '\022', 'F', '\n', '\020', 'm', 
+'a', 'x', '_', 's', 'e', 's', 's', 'i', 'o', 'n', '_', 'k', 'e', 'y', 's', '\030', '\004', ' ', '\001', '(', '\013', '2', '\034', '.', 'g', 
+'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'U', 'I', 'n', 't', '3', '2', 'V', 'a', 'l', 'u', 
+'e', 'R', '\016', 'm', 'a', 'x', 'S', 'e', 's', 's', 'i', 'o', 'n', 'K', 'e', 'y', 's', ':', '+', '\232', '\305', '\210', '\036', '&', '\n', 
+'$', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'a', 'u', 't', 'h', '.', 'U', 'p', 's', 't', 'r', 'e', 
+'a', 'm', 'T', 'l', 's', 'C', 'o', 'n', 't', 'e', 'x', 't', '\"', '\352', '\007', '\n', '\024', 'D', 'o', 'w', 'n', 's', 't', 'r', 'e', 
+'a', 'm', 'T', 'l', 's', 'C', 'o', 'n', 't', 'e', 'x', 't', '\022', 'i', '\n', '\022', 'c', 'o', 'm', 'm', 'o', 'n', '_', 't', 'l', 
+'s', '_', 'c', 'o', 'n', 't', 'e', 'x', 't', '\030', '\001', ' ', '\001', '(', '\013', '2', ';', '.', 'e', 'n', 'v', 'o', 'y', '.', 'e', 
 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 's', '.', 't', 'r', 'a', 'n', 's', 'p', 'o', 'r', 't', '_', 's', 'o', 'c', 'k', 'e', 
 't', 's', '.', 't', 'l', 's', '.', 'v', '3', '.', 'C', 'o', 'm', 'm', 'o', 'n', 'T', 'l', 's', 'C', 'o', 'n', 't', 'e', 'x', 
-'t', '.', 'C', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', 'P', 'r', 'o', 'v', 'i', 'd', 'e', 'r', 'I', 'n', 's', 't', 
-'a', 'n', 'c', 'e', 'R', ')', 't', 'l', 's', 'C', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', 'C', 'e', 'r', 't', 'i', 
-'f', 'i', 'c', 'a', 't', 'e', 'P', 'r', 'o', 'v', 'i', 'd', 'e', 'r', 'I', 'n', 's', 't', 'a', 'n', 'c', 'e', '\022', 'x', '\n', 
-'\022', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'i', 'o', 'n', '_', 'c', 'o', 'n', 't', 'e', 'x', 't', '\030', '\003', ' ', '\001', '(', '\013', 
-'2', 'G', '.', 'e', 'n', 'v', 'o', 'y', '.', 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 's', '.', 't', 'r', 'a', 'n', 's', 
-'p', 'o', 'r', 't', '_', 's', 'o', 'c', 'k', 'e', 't', 's', '.', 't', 'l', 's', '.', 'v', '3', '.', 'C', 'e', 'r', 't', 'i', 
-'f', 'i', 'c', 'a', 't', 'e', 'V', 'a', 'l', 'i', 'd', 'a', 't', 'i', 'o', 'n', 'C', 'o', 'n', 't', 'e', 'x', 't', 'H', '\000', 
-'R', '\021', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'i', 'o', 'n', 'C', 'o', 'n', 't', 'e', 'x', 't', '\022', '\214', '\001', '\n', '$', 'v', 
-'a', 'l', 'i', 'd', 'a', 't', 'i', 'o', 'n', '_', 'c', 'o', 'n', 't', 'e', 'x', 't', '_', 's', 'd', 's', '_', 's', 'e', 'c', 
-'r', 'e', 't', '_', 'c', 'o', 'n', 'f', 'i', 'g', '\030', '\007', ' ', '\001', '(', '\013', '2', ':', '.', 'e', 'n', 'v', 'o', 'y', '.', 
-'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 's', '.', 't', 'r', 'a', 'n', 's', 'p', 'o', 'r', 't', '_', 's', 'o', 'c', 'k', 
-'e', 't', 's', '.', 't', 'l', 's', '.', 'v', '3', '.', 'S', 'd', 's', 'S', 'e', 'c', 'r', 'e', 't', 'C', 'o', 'n', 'f', 'i', 
-'g', 'H', '\000', 'R', ' ', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'i', 'o', 'n', 'C', 'o', 'n', 't', 'e', 'x', 't', 'S', 'd', 's', 
-'S', 'e', 'c', 'r', 'e', 't', 'C', 'o', 'n', 'f', 'i', 'g', '\022', '\242', '\001', '\n', '\033', 'c', 'o', 'm', 'b', 'i', 'n', 'e', 'd', 
-'_', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'i', 'o', 'n', '_', 'c', 'o', 'n', 't', 'e', 'x', 't', '\030', '\010', ' ', '\001', '(', '\013', 
-'2', '`', '.', 'e', 'n', 'v', 'o', 'y', '.', 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 's', '.', 't', 'r', 'a', 'n', 's', 
-'p', 'o', 'r', 't', '_', 's', 'o', 'c', 'k', 'e', 't', 's', '.', 't', 'l', 's', '.', 'v', '3', '.', 'C', 'o', 'm', 'm', 'o', 
-'n', 'T', 'l', 's', 'C', 'o', 'n', 't', 'e', 'x', 't', '.', 'C', 'o', 'm', 'b', 'i', 'n', 'e', 'd', 'C', 'e', 'r', 't', 'i', 
-'f', 'i', 'c', 'a', 't', 'e', 'V', 'a', 'l', 'i', 'd', 'a', 't', 'i', 'o', 'n', 'C', 'o', 'n', 't', 'e', 'x', 't', 'H', '\000', 
-'R', '\031', 'c', 'o', 'm', 'b', 'i', 'n', 'e', 'd', 'V', 'a', 'l', 'i', 'd', 'a', 't', 'i', 'o', 'n', 'C', 'o', 'n', 't', 'e', 
-'x', 't', '\022', '\250', '\001', '\n', '\'', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'i', 'o', 'n', '_', 'c', 'o', 'n', 't', 'e', 'x', 't', 
-'_', 'c', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', '_', 'p', 'r', 'o', 'v', 'i', 'd', 'e', 'r', '\030', '\n', ' ', '\001', 
+'t', 'R', '\020', 'c', 'o', 'm', 'm', 'o', 'n', 'T', 'l', 's', 'C', 'o', 'n', 't', 'e', 'x', 't', '\022', 'X', '\n', '\032', 'r', 'e', 
+'q', 'u', 'i', 'r', 'e', '_', 'c', 'l', 'i', 'e', 'n', 't', '_', 'c', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', '\030', 
+'\002', ' ', '\001', '(', '\013', '2', '\032', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'B', 
+'o', 'o', 'l', 'V', 'a', 'l', 'u', 'e', 'R', '\030', 'r', 'e', 'q', 'u', 'i', 'r', 'e', 'C', 'l', 'i', 'e', 'n', 't', 'C', 'e', 
+'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', '\022', ';', '\n', '\013', 'r', 'e', 'q', 'u', 'i', 'r', 'e', '_', 's', 'n', 'i', '\030', 
+'\003', ' ', '\001', '(', '\013', '2', '\032', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'B', 
+'o', 'o', 'l', 'V', 'a', 'l', 'u', 'e', 'R', '\n', 'r', 'e', 'q', 'u', 'i', 'r', 'e', 'S', 'n', 'i', '\022', 'q', '\n', '\023', 's', 
+'e', 's', 's', 'i', 'o', 'n', '_', 't', 'i', 'c', 'k', 'e', 't', '_', 'k', 'e', 'y', 's', '\030', '\004', ' ', '\001', '(', '\013', '2', 
+'?', '.', 'e', 'n', 'v', 'o', 'y', '.', 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 's', '.', 't', 'r', 'a', 'n', 's', 'p', 
+'o', 'r', 't', '_', 's', 'o', 'c', 'k', 'e', 't', 's', '.', 't', 'l', 's', '.', 'v', '3', '.', 'T', 'l', 's', 'S', 'e', 's', 
+'s', 'i', 'o', 'n', 'T', 'i', 'c', 'k', 'e', 't', 'K', 'e', 'y', 's', 'H', '\000', 'R', '\021', 's', 'e', 's', 's', 'i', 'o', 'n', 
+'T', 'i', 'c', 'k', 'e', 't', 'K', 'e', 'y', 's', '\022', '\215', '\001', '\n', '%', 's', 'e', 's', 's', 'i', 'o', 'n', '_', 't', 'i', 
+'c', 'k', 'e', 't', '_', 'k', 'e', 'y', 's', '_', 's', 'd', 's', '_', 's', 'e', 'c', 'r', 'e', 't', '_', 'c', 'o', 'n', 'f', 
+'i', 'g', '\030', '\005', ' ', '\001', '(', '\013', '2', ':', '.', 'e', 'n', 'v', 'o', 'y', '.', 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 
+'n', 's', '.', 't', 'r', 'a', 'n', 's', 'p', 'o', 'r', 't', '_', 's', 'o', 'c', 'k', 'e', 't', 's', '.', 't', 'l', 's', '.', 
+'v', '3', '.', 'S', 'd', 's', 'S', 'e', 'c', 'r', 'e', 't', 'C', 'o', 'n', 'f', 'i', 'g', 'H', '\000', 'R', ' ', 's', 'e', 's', 
+'s', 'i', 'o', 'n', 'T', 'i', 'c', 'k', 'e', 't', 'K', 'e', 'y', 's', 'S', 'd', 's', 'S', 'e', 'c', 'r', 'e', 't', 'C', 'o', 
+'n', 'f', 'i', 'g', '\022', 'Q', '\n', '$', 'd', 'i', 's', 'a', 'b', 'l', 'e', '_', 's', 't', 'a', 't', 'e', 'l', 'e', 's', 's', 
+'_', 's', 'e', 's', 's', 'i', 'o', 'n', '_', 'r', 'e', 's', 'u', 'm', 'p', 't', 'i', 'o', 'n', '\030', '\007', ' ', '\001', '(', '\010', 
+'H', '\000', 'R', '!', 'd', 'i', 's', 'a', 'b', 'l', 'e', 'S', 't', 'a', 't', 'e', 'l', 'e', 's', 's', 'S', 'e', 's', 's', 'i', 
+'o', 'n', 'R', 'e', 's', 'u', 'm', 'p', 't', 'i', 'o', 'n', '\022', 'T', '\n', '\017', 's', 'e', 's', 's', 'i', 'o', 'n', '_', 't', 
+'i', 'm', 'e', 'o', 'u', 't', '\030', '\006', ' ', '\001', '(', '\013', '2', '\031', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 
+'t', 'o', 'b', 'u', 'f', '.', 'D', 'u', 'r', 'a', 't', 'i', 'o', 'n', 'B', '\020', '\372', 'B', '\r', '\252', '\001', '\n', '\032', '\006', '\010', 
+'\200', '\200', '\200', '\200', '\020', '2', '\000', 'R', '\016', 's', 'e', 's', 's', 'i', 'o', 'n', 'T', 'i', 'm', 'e', 'o', 'u', 't', '\022', '\210', 
+'\001', '\n', '\022', 'o', 'c', 's', 'p', '_', 's', 't', 'a', 'p', 'l', 'e', '_', 'p', 'o', 'l', 'i', 'c', 'y', '\030', '\010', ' ', '\001', 
+'(', '\016', '2', 'P', '.', 'e', 'n', 'v', 'o', 'y', '.', 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 's', '.', 't', 'r', 'a', 
+'n', 's', 'p', 'o', 'r', 't', '_', 's', 'o', 'c', 'k', 'e', 't', 's', '.', 't', 'l', 's', '.', 'v', '3', '.', 'D', 'o', 'w', 
+'n', 's', 't', 'r', 'e', 'a', 'm', 'T', 'l', 's', 'C', 'o', 'n', 't', 'e', 'x', 't', '.', 'O', 'c', 's', 'p', 'S', 't', 'a', 
+'p', 'l', 'e', 'P', 'o', 'l', 'i', 'c', 'y', 'B', '\010', '\372', 'B', '\005', '\202', '\001', '\002', '\020', '\001', 'R', '\020', 'o', 'c', 's', 'p', 
+'S', 't', 'a', 'p', 'l', 'e', 'P', 'o', 'l', 'i', 'c', 'y', '\"', 'N', '\n', '\020', 'O', 'c', 's', 'p', 'S', 't', 'a', 'p', 'l', 
+'e', 'P', 'o', 'l', 'i', 'c', 'y', '\022', '\024', '\n', '\020', 'L', 'E', 'N', 'I', 'E', 'N', 'T', '_', 'S', 'T', 'A', 'P', 'L', 'I', 
+'N', 'G', '\020', '\000', '\022', '\023', '\n', '\017', 'S', 'T', 'R', 'I', 'C', 'T', '_', 'S', 'T', 'A', 'P', 'L', 'I', 'N', 'G', '\020', '\001', 
+'\022', '\017', '\n', '\013', 'M', 'U', 'S', 'T', '_', 'S', 'T', 'A', 'P', 'L', 'E', '\020', '\002', ':', '-', '\232', '\305', '\210', '\036', '(', '\n', 
+'&', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'a', 'u', 't', 'h', '.', 'D', 'o', 'w', 'n', 's', 't', 
+'r', 'e', 'a', 'm', 'T', 'l', 's', 'C', 'o', 'n', 't', 'e', 'x', 't', 'B', '\032', '\n', '\030', 's', 'e', 's', 's', 'i', 'o', 'n', 
+'_', 't', 'i', 'c', 'k', 'e', 't', '_', 'k', 'e', 'y', 's', '_', 't', 'y', 'p', 'e', '\"', '\245', '\027', '\n', '\020', 'C', 'o', 'm', 
+'m', 'o', 'n', 'T', 'l', 's', 'C', 'o', 'n', 't', 'e', 'x', 't', '\022', 'W', '\n', '\n', 't', 'l', 's', '_', 'p', 'a', 'r', 'a', 
+'m', 's', '\030', '\001', ' ', '\001', '(', '\013', '2', '8', '.', 'e', 'n', 'v', 'o', 'y', '.', 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 
+'n', 's', '.', 't', 'r', 'a', 'n', 's', 'p', 'o', 'r', 't', '_', 's', 'o', 'c', 'k', 'e', 't', 's', '.', 't', 'l', 's', '.', 
+'v', '3', '.', 'T', 'l', 's', 'P', 'a', 'r', 'a', 'm', 'e', 't', 'e', 'r', 's', 'R', '\t', 't', 'l', 's', 'P', 'a', 'r', 'a', 
+'m', 's', '\022', 'd', '\n', '\020', 't', 'l', 's', '_', 'c', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', 's', '\030', '\002', ' ', 
+'\003', '(', '\013', '2', '9', '.', 'e', 'n', 'v', 'o', 'y', '.', 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 's', '.', 't', 'r', 
+'a', 'n', 's', 'p', 'o', 'r', 't', '_', 's', 'o', 'c', 'k', 'e', 't', 's', '.', 't', 'l', 's', '.', 'v', '3', '.', 'T', 'l', 
+'s', 'C', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', 'R', '\017', 't', 'l', 's', 'C', 'e', 'r', 't', 'i', 'f', 'i', 'c', 
+'a', 't', 'e', 's', '\022', '\220', '\001', '\n', '\"', 't', 'l', 's', '_', 'c', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', '_', 
+'s', 'd', 's', '_', 's', 'e', 'c', 'r', 'e', 't', '_', 'c', 'o', 'n', 'f', 'i', 'g', 's', '\030', '\006', ' ', '\003', '(', '\013', '2', 
+':', '.', 'e', 'n', 'v', 'o', 'y', '.', 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 's', '.', 't', 'r', 'a', 'n', 's', 'p', 
+'o', 'r', 't', '_', 's', 'o', 'c', 'k', 'e', 't', 's', '.', 't', 'l', 's', '.', 'v', '3', '.', 'S', 'd', 's', 'S', 'e', 'c', 
+'r', 'e', 't', 'C', 'o', 'n', 'f', 'i', 'g', 'B', '\010', '\372', 'B', '\005', '\222', '\001', '\002', '\020', '\002', 'R', '\036', 't', 'l', 's', 'C', 
+'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', 'S', 'd', 's', 'S', 'e', 'c', 'r', 'e', 't', 'C', 'o', 'n', 'f', 'i', 'g', 
+'s', '\022', '\227', '\001', '\n', '!', 't', 'l', 's', '_', 'c', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', '_', 'p', 'r', 'o', 
+'v', 'i', 'd', 'e', 'r', '_', 'i', 'n', 's', 't', 'a', 'n', 'c', 'e', '\030', '\016', ' ', '\001', '(', '\013', '2', 'L', '.', 'e', 'n', 
+'v', 'o', 'y', '.', 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 's', '.', 't', 'r', 'a', 'n', 's', 'p', 'o', 'r', 't', '_', 
+'s', 'o', 'c', 'k', 'e', 't', 's', '.', 't', 'l', 's', '.', 'v', '3', '.', 'C', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 
+'e', 'P', 'r', 'o', 'v', 'i', 'd', 'e', 'r', 'P', 'l', 'u', 'g', 'i', 'n', 'I', 'n', 's', 't', 'a', 'n', 'c', 'e', 'R', '\036', 
+'t', 'l', 's', 'C', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', 'P', 'r', 'o', 'v', 'i', 'd', 'e', 'r', 'I', 'n', 's', 
+'t', 'a', 'n', 'c', 'e', '\022', '\255', '\001', '\n', '$', 't', 'l', 's', '_', 'c', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', 
+'_', 'c', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', '_', 'p', 'r', 'o', 'v', 'i', 'd', 'e', 'r', '\030', '\t', ' ', '\001', 
 '(', '\013', '2', 'O', '.', 'e', 'n', 'v', 'o', 'y', '.', 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 's', '.', 't', 'r', 'a', 
 'n', 's', 'p', 'o', 'r', 't', '_', 's', 'o', 'c', 'k', 'e', 't', 's', '.', 't', 'l', 's', '.', 'v', '3', '.', 'C', 'o', 'm', 
 'm', 'o', 'n', 'T', 'l', 's', 'C', 'o', 'n', 't', 'e', 'x', 't', '.', 'C', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', 
-'P', 'r', 'o', 'v', 'i', 'd', 'e', 'r', 'H', '\000', 'R', '$', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'i', 'o', 'n', 'C', 'o', 'n', 
-'t', 'e', 'x', 't', 'C', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', 'P', 'r', 'o', 'v', 'i', 'd', 'e', 'r', '\022', '\301', 
-'\001', '\n', '0', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'i', 'o', 'n', '_', 'c', 'o', 'n', 't', 'e', 'x', 't', '_', 'c', 'e', 'r', 
-'t', 'i', 'f', 'i', 'c', 'a', 't', 'e', '_', 'p', 'r', 'o', 'v', 'i', 'd', 'e', 'r', '_', 'i', 'n', 's', 't', 'a', 'n', 'c', 
-'e', '\030', '\014', ' ', '\001', '(', '\013', '2', 'W', '.', 'e', 'n', 'v', 'o', 'y', '.', 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 
-'s', '.', 't', 'r', 'a', 'n', 's', 'p', 'o', 'r', 't', '_', 's', 'o', 'c', 'k', 'e', 't', 's', '.', 't', 'l', 's', '.', 'v', 
-'3', '.', 'C', 'o', 'm', 'm', 'o', 'n', 'T', 'l', 's', 'C', 'o', 'n', 't', 'e', 'x', 't', '.', 'C', 'e', 'r', 't', 'i', 'f', 
-'i', 'c', 'a', 't', 'e', 'P', 'r', 'o', 'v', 'i', 'd', 'e', 'r', 'I', 'n', 's', 't', 'a', 'n', 'c', 'e', 'H', '\000', 'R', ',', 
-'v', 'a', 'l', 'i', 'd', 'a', 't', 'i', 'o', 'n', 'C', 'o', 'n', 't', 'e', 'x', 't', 'C', 'e', 'r', 't', 'i', 'f', 'i', 'c', 
-'a', 't', 'e', 'P', 'r', 'o', 'v', 'i', 'd', 'e', 'r', 'I', 'n', 's', 't', 'a', 'n', 'c', 'e', '\022', '%', '\n', '\016', 'a', 'l', 
-'p', 'n', '_', 'p', 'r', 'o', 't', 'o', 'c', 'o', 'l', 's', '\030', '\004', ' ', '\003', '(', '\t', 'R', '\r', 'a', 'l', 'p', 'n', 'P', 
-'r', 'o', 't', 'o', 'c', 'o', 'l', 's', '\022', 'W', '\n', '\021', 'c', 'u', 's', 't', 'o', 'm', '_', 'h', 'a', 'n', 'd', 's', 'h', 
-'a', 'k', 'e', 'r', '\030', '\r', ' ', '\001', '(', '\013', '2', '*', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', 
-'.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'T', 'y', 'p', 'e', 'd', 'E', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 'C', 'o', 
-'n', 'f', 'i', 'g', 'R', '\020', 'c', 'u', 's', 't', 'o', 'm', 'H', 'a', 'n', 'd', 's', 'h', 'a', 'k', 'e', 'r', '\032', '\222', '\001', 
-'\n', '\023', 'C', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', 'P', 'r', 'o', 'v', 'i', 'd', 'e', 'r', '\022', '\033', '\n', '\004', 
-'n', 'a', 'm', 'e', '\030', '\001', ' ', '\001', '(', '\t', 'B', '\007', '\372', 'B', '\004', 'r', '\002', '\020', '\001', 'R', '\004', 'n', 'a', 'm', 'e', 
-'\022', 'O', '\n', '\014', 't', 'y', 'p', 'e', 'd', '_', 'c', 'o', 'n', 'f', 'i', 'g', '\030', '\002', ' ', '\001', '(', '\013', '2', '*', '.', 
-'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'T', 'y', 'p', 'e', 
-'d', 'E', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 'C', 'o', 'n', 'f', 'i', 'g', 'H', '\000', 'R', '\013', 't', 'y', 'p', 'e', 'd', 
-'C', 'o', 'n', 'f', 'i', 'g', 'B', '\r', '\n', '\006', 'c', 'o', 'n', 'f', 'i', 'g', '\022', '\003', '\370', 'B', '\001', '\032', 'm', '\n', '\033', 
-'C', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', 'P', 'r', 'o', 'v', 'i', 'd', 'e', 'r', 'I', 'n', 's', 't', 'a', 'n', 
-'c', 'e', '\022', '#', '\n', '\r', 'i', 'n', 's', 't', 'a', 'n', 'c', 'e', '_', 'n', 'a', 'm', 'e', '\030', '\001', ' ', '\001', '(', '\t', 
-'R', '\014', 'i', 'n', 's', 't', 'a', 'n', 'c', 'e', 'N', 'a', 'm', 'e', '\022', ')', '\n', '\020', 'c', 'e', 'r', 't', 'i', 'f', 'i', 
-'c', 'a', 't', 'e', '_', 'n', 'a', 'm', 'e', '\030', '\002', ' ', '\001', '(', '\t', 'R', '\017', 'c', 'e', 'r', 't', 'i', 'f', 'i', 'c', 
-'a', 't', 'e', 'N', 'a', 'm', 'e', '\032', '\364', '\006', '\n', '$', 'C', 'o', 'm', 'b', 'i', 'n', 'e', 'd', 'C', 'e', 'r', 't', 'i', 
-'f', 'i', 'c', 'a', 't', 'e', 'V', 'a', 'l', 'i', 'd', 'a', 't', 'i', 'o', 'n', 'C', 'o', 'n', 't', 'e', 'x', 't', '\022', '\217', 
-'\001', '\n', '\032', 'd', 'e', 'f', 'a', 'u', 'l', 't', '_', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'i', 'o', 'n', '_', 'c', 'o', 'n', 
-'t', 'e', 'x', 't', '\030', '\001', ' ', '\001', '(', '\013', '2', 'G', '.', 'e', 'n', 'v', 'o', 'y', '.', 'e', 'x', 't', 'e', 'n', 's', 
+'P', 'r', 'o', 'v', 'i', 'd', 'e', 'r', 'B', '\013', '\030', '\001', '\222', '\307', '\206', '\330', '\004', '\003', '3', '.', '0', 'R', '!', 't', 'l', 
+'s', 'C', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', 'C', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', 'P', 'r', 
+'o', 'v', 'i', 'd', 'e', 'r', '\022', '\306', '\001', '\n', '-', 't', 'l', 's', '_', 'c', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 
+'e', '_', 'c', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', '_', 'p', 'r', 'o', 'v', 'i', 'd', 'e', 'r', '_', 'i', 'n', 
+'s', 't', 'a', 'n', 'c', 'e', '\030', '\013', ' ', '\001', '(', '\013', '2', 'W', '.', 'e', 'n', 'v', 'o', 'y', '.', 'e', 'x', 't', 'e', 
+'n', 's', 'i', 'o', 'n', 's', '.', 't', 'r', 'a', 'n', 's', 'p', 'o', 'r', 't', '_', 's', 'o', 'c', 'k', 'e', 't', 's', '.', 
+'t', 'l', 's', '.', 'v', '3', '.', 'C', 'o', 'm', 'm', 'o', 'n', 'T', 'l', 's', 'C', 'o', 'n', 't', 'e', 'x', 't', '.', 'C', 
+'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', 'P', 'r', 'o', 'v', 'i', 'd', 'e', 'r', 'I', 'n', 's', 't', 'a', 'n', 'c', 
+'e', 'B', '\013', '\030', '\001', '\222', '\307', '\206', '\330', '\004', '\003', '3', '.', '0', 'R', ')', 't', 'l', 's', 'C', 'e', 'r', 't', 'i', 'f', 
+'i', 'c', 'a', 't', 'e', 'C', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', 'P', 'r', 'o', 'v', 'i', 'd', 'e', 'r', 'I', 
+'n', 's', 't', 'a', 'n', 'c', 'e', '\022', 'x', '\n', '\022', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'i', 'o', 'n', '_', 'c', 'o', 'n', 
+'t', 'e', 'x', 't', '\030', '\003', ' ', '\001', '(', '\013', '2', 'G', '.', 'e', 'n', 'v', 'o', 'y', '.', 'e', 'x', 't', 'e', 'n', 's', 
 'i', 'o', 'n', 's', '.', 't', 'r', 'a', 'n', 's', 'p', 'o', 'r', 't', '_', 's', 'o', 'c', 'k', 'e', 't', 's', '.', 't', 'l', 
 's', '.', 'v', '3', '.', 'C', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', 'V', 'a', 'l', 'i', 'd', 'a', 't', 'i', 'o', 
-'n', 'C', 'o', 'n', 't', 'e', 'x', 't', 'B', '\010', '\372', 'B', '\005', '\212', '\001', '\002', '\020', '\001', 'R', '\030', 'd', 'e', 'f', 'a', 'u', 
-'l', 't', 'V', 'a', 'l', 'i', 'd', 'a', 't', 'i', 'o', 'n', 'C', 'o', 'n', 't', 'e', 'x', 't', '\022', '\266', '\001', '\n', '$', 'v', 
-'a', 'l', 'i', 'd', 'a', 't', 'i', 'o', 'n', '_', 'c', 'o', 'n', 't', 'e', 'x', 't', '_', 's', 'd', 's', '_', 's', 'e', 'c', 
-'r', 'e', 't', '_', 'c', 'o', 'n', 'f', 'i', 'g', '\030', '\002', ' ', '\001', '(', '\013', '2', ':', '.', 'e', 'n', 'v', 'o', 'y', '.', 
-'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 's', '.', 't', 'r', 'a', 'n', 's', 'p', 'o', 'r', 't', '_', 's', 'o', 'c', 'k', 
-'e', 't', 's', '.', 't', 'l', 's', '.', 'v', '3', '.', 'S', 'd', 's', 'S', 'e', 'c', 'r', 'e', 't', 'C', 'o', 'n', 'f', 'i', 
-'g', 'B', '*', '\372', 'B', '\005', '\212', '\001', '\002', '\020', '\001', '\362', '\230', '\376', '\217', '\005', '\034', '\022', '\032', 'd', 'y', 'n', 'a', 'm', 'i', 
-'c', '_', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'i', 'o', 'n', '_', 'c', 'o', 'n', 't', 'e', 'x', 't', 'R', ' ', 'v', 'a', 'l', 
-'i', 'd', 'a', 't', 'i', 'o', 'n', 'C', 'o', 'n', 't', 'e', 'x', 't', 'S', 'd', 's', 'S', 'e', 'c', 'r', 'e', 't', 'C', 'o', 
-'n', 'f', 'i', 'g', '\022', '\312', '\001', '\n', '\'', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'i', 'o', 'n', '_', 'c', 'o', 'n', 't', 'e', 
-'x', 't', '_', 'c', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', '_', 'p', 'r', 'o', 'v', 'i', 'd', 'e', 'r', '\030', '\003', 
-' ', '\001', '(', '\013', '2', 'O', '.', 'e', 'n', 'v', 'o', 'y', '.', 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 's', '.', 't', 
-'r', 'a', 'n', 's', 'p', 'o', 'r', 't', '_', 's', 'o', 'c', 'k', 'e', 't', 's', '.', 't', 'l', 's', '.', 'v', '3', '.', 'C', 
-'o', 'm', 'm', 'o', 'n', 'T', 'l', 's', 'C', 'o', 'n', 't', 'e', 'x', 't', '.', 'C', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 
-'t', 'e', 'P', 'r', 'o', 'v', 'i', 'd', 'e', 'r', 'B', '\"', '\362', '\230', '\376', '\217', '\005', '\034', '\022', '\032', 'd', 'y', 'n', 'a', 'm', 
-'i', 'c', '_', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'i', 'o', 'n', '_', 'c', 'o', 'n', 't', 'e', 'x', 't', 'R', '$', 'v', 'a', 
-'l', 'i', 'd', 'a', 't', 'i', 'o', 'n', 'C', 'o', 'n', 't', 'e', 'x', 't', 'C', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 
-'e', 'P', 'r', 'o', 'v', 'i', 'd', 'e', 'r', '\022', '\343', '\001', '\n', '0', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'i', 'o', 'n', '_', 
-'c', 'o', 'n', 't', 'e', 'x', 't', '_', 'c', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', '_', 'p', 'r', 'o', 'v', 'i', 
-'d', 'e', 'r', '_', 'i', 'n', 's', 't', 'a', 'n', 'c', 'e', '\030', '\004', ' ', '\001', '(', '\013', '2', 'W', '.', 'e', 'n', 'v', 'o', 
-'y', '.', 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 's', '.', 't', 'r', 'a', 'n', 's', 'p', 'o', 'r', 't', '_', 's', 'o', 
-'c', 'k', 'e', 't', 's', '.', 't', 'l', 's', '.', 'v', '3', '.', 'C', 'o', 'm', 'm', 'o', 'n', 'T', 'l', 's', 'C', 'o', 'n', 
-'t', 'e', 'x', 't', '.', 'C', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', 'P', 'r', 'o', 'v', 'i', 'd', 'e', 'r', 'I', 
-'n', 's', 't', 'a', 'n', 'c', 'e', 'B', '\"', '\362', '\230', '\376', '\217', '\005', '\034', '\022', '\032', 'd', 'y', 'n', 'a', 'm', 'i', 'c', '_', 
-'v', 'a', 'l', 'i', 'd', 'a', 't', 'i', 'o', 'n', '_', 'c', 'o', 'n', 't', 'e', 'x', 't', 'R', ',', 'v', 'a', 'l', 'i', 'd', 
-'a', 't', 'i', 'o', 'n', 'C', 'o', 'n', 't', 'e', 'x', 't', 'C', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', 'P', 'r', 
-'o', 'v', 'i', 'd', 'e', 'r', 'I', 'n', 's', 't', 'a', 'n', 'c', 'e', ':', 'N', '\232', '\305', '\210', '\036', 'I', '\n', 'G', 'e', 'n', 
-'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'a', 'u', 't', 'h', '.', 'C', 'o', 'm', 'm', 'o', 'n', 'T', 'l', 's', 
-'C', 'o', 'n', 't', 'e', 'x', 't', '.', 'C', 'o', 'm', 'b', 'i', 'n', 'e', 'd', 'C', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 
-'t', 'e', 'V', 'a', 'l', 'i', 'd', 'a', 't', 'i', 'o', 'n', 'C', 'o', 'n', 't', 'e', 'x', 't', ':', ')', '\232', '\305', '\210', '\036', 
-'$', '\n', '\"', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'a', 'u', 't', 'h', '.', 'C', 'o', 'm', 'm', 
-'o', 'n', 'T', 'l', 's', 'C', 'o', 'n', 't', 'e', 'x', 't', 'B', '\031', '\n', '\027', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'i', 'o', 
-'n', '_', 'c', 'o', 'n', 't', 'e', 'x', 't', '_', 't', 'y', 'p', 'e', 'J', '\004', '\010', '\005', '\020', '\006', 'B', 'M', '\n', '7', 'i', 
-'o', '.', 'e', 'n', 'v', 'o', 'y', 'p', 'r', 'o', 'x', 'y', '.', 'e', 'n', 'v', 'o', 'y', '.', 'e', 'x', 't', 'e', 'n', 's', 
+'n', 'C', 'o', 'n', 't', 'e', 'x', 't', 'H', '\000', 'R', '\021', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'i', 'o', 'n', 'C', 'o', 'n', 
+'t', 'e', 'x', 't', '\022', '\214', '\001', '\n', '$', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'i', 'o', 'n', '_', 'c', 'o', 'n', 't', 'e', 
+'x', 't', '_', 's', 'd', 's', '_', 's', 'e', 'c', 'r', 'e', 't', '_', 'c', 'o', 'n', 'f', 'i', 'g', '\030', '\007', ' ', '\001', '(', 
+'\013', '2', ':', '.', 'e', 'n', 'v', 'o', 'y', '.', 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 's', '.', 't', 'r', 'a', 'n', 
+'s', 'p', 'o', 'r', 't', '_', 's', 'o', 'c', 'k', 'e', 't', 's', '.', 't', 'l', 's', '.', 'v', '3', '.', 'S', 'd', 's', 'S', 
+'e', 'c', 'r', 'e', 't', 'C', 'o', 'n', 'f', 'i', 'g', 'H', '\000', 'R', ' ', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'i', 'o', 'n', 
+'C', 'o', 'n', 't', 'e', 'x', 't', 'S', 'd', 's', 'S', 'e', 'c', 'r', 'e', 't', 'C', 'o', 'n', 'f', 'i', 'g', '\022', '\242', '\001', 
+'\n', '\033', 'c', 'o', 'm', 'b', 'i', 'n', 'e', 'd', '_', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'i', 'o', 'n', '_', 'c', 'o', 'n', 
+'t', 'e', 'x', 't', '\030', '\010', ' ', '\001', '(', '\013', '2', '`', '.', 'e', 'n', 'v', 'o', 'y', '.', 'e', 'x', 't', 'e', 'n', 's', 
 'i', 'o', 'n', 's', '.', 't', 'r', 'a', 'n', 's', 'p', 'o', 'r', 't', '_', 's', 'o', 'c', 'k', 'e', 't', 's', '.', 't', 'l', 
-'s', '.', 'v', '3', 'B', '\010', 'T', 'l', 's', 'P', 'r', 'o', 't', 'o', 'P', '\001', '\272', '\200', '\310', '\321', '\006', '\002', '\020', '\002', 'b', 
-'\006', 'p', 'r', 'o', 't', 'o', '3', 
+'s', '.', 'v', '3', '.', 'C', 'o', 'm', 'm', 'o', 'n', 'T', 'l', 's', 'C', 'o', 'n', 't', 'e', 'x', 't', '.', 'C', 'o', 'm', 
+'b', 'i', 'n', 'e', 'd', 'C', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', 'V', 'a', 'l', 'i', 'd', 'a', 't', 'i', 'o', 
+'n', 'C', 'o', 'n', 't', 'e', 'x', 't', 'H', '\000', 'R', '\031', 'c', 'o', 'm', 'b', 'i', 'n', 'e', 'd', 'V', 'a', 'l', 'i', 'd', 
+'a', 't', 'i', 'o', 'n', 'C', 'o', 'n', 't', 'e', 'x', 't', '\022', '\265', '\001', '\n', '\'', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'i', 
+'o', 'n', '_', 'c', 'o', 'n', 't', 'e', 'x', 't', '_', 'c', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', '_', 'p', 'r', 
+'o', 'v', 'i', 'd', 'e', 'r', '\030', '\n', ' ', '\001', '(', '\013', '2', 'O', '.', 'e', 'n', 'v', 'o', 'y', '.', 'e', 'x', 't', 'e', 
+'n', 's', 'i', 'o', 'n', 's', '.', 't', 'r', 'a', 'n', 's', 'p', 'o', 'r', 't', '_', 's', 'o', 'c', 'k', 'e', 't', 's', '.', 
+'t', 'l', 's', '.', 'v', '3', '.', 'C', 'o', 'm', 'm', 'o', 'n', 'T', 'l', 's', 'C', 'o', 'n', 't', 'e', 'x', 't', '.', 'C', 
+'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', 'P', 'r', 'o', 'v', 'i', 'd', 'e', 'r', 'B', '\013', '\030', '\001', '\222', '\307', '\206', 
+'\330', '\004', '\003', '3', '.', '0', 'H', '\000', 'R', '$', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'i', 'o', 'n', 'C', 'o', 'n', 't', 'e', 
+'x', 't', 'C', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', 'P', 'r', 'o', 'v', 'i', 'd', 'e', 'r', '\022', '\316', '\001', '\n', 
+'0', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'i', 'o', 'n', '_', 'c', 'o', 'n', 't', 'e', 'x', 't', '_', 'c', 'e', 'r', 't', 'i', 
+'f', 'i', 'c', 'a', 't', 'e', '_', 'p', 'r', 'o', 'v', 'i', 'd', 'e', 'r', '_', 'i', 'n', 's', 't', 'a', 'n', 'c', 'e', '\030', 
+'\014', ' ', '\001', '(', '\013', '2', 'W', '.', 'e', 'n', 'v', 'o', 'y', '.', 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 's', '.', 
+'t', 'r', 'a', 'n', 's', 'p', 'o', 'r', 't', '_', 's', 'o', 'c', 'k', 'e', 't', 's', '.', 't', 'l', 's', '.', 'v', '3', '.', 
+'C', 'o', 'm', 'm', 'o', 'n', 'T', 'l', 's', 'C', 'o', 'n', 't', 'e', 'x', 't', '.', 'C', 'e', 'r', 't', 'i', 'f', 'i', 'c', 
+'a', 't', 'e', 'P', 'r', 'o', 'v', 'i', 'd', 'e', 'r', 'I', 'n', 's', 't', 'a', 'n', 'c', 'e', 'B', '\013', '\030', '\001', '\222', '\307', 
+'\206', '\330', '\004', '\003', '3', '.', '0', 'H', '\000', 'R', ',', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'i', 'o', 'n', 'C', 'o', 'n', 't', 
+'e', 'x', 't', 'C', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', 'P', 'r', 'o', 'v', 'i', 'd', 'e', 'r', 'I', 'n', 's', 
+'t', 'a', 'n', 'c', 'e', '\022', '%', '\n', '\016', 'a', 'l', 'p', 'n', '_', 'p', 'r', 'o', 't', 'o', 'c', 'o', 'l', 's', '\030', '\004', 
+' ', '\003', '(', '\t', 'R', '\r', 'a', 'l', 'p', 'n', 'P', 'r', 'o', 't', 'o', 'c', 'o', 'l', 's', '\022', 'W', '\n', '\021', 'c', 'u', 
+'s', 't', 'o', 'm', '_', 'h', 'a', 'n', 'd', 's', 'h', 'a', 'k', 'e', 'r', '\030', '\r', ' ', '\001', '(', '\013', '2', '*', '.', 'e', 
+'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 'o', 'r', 'e', '.', 'v', '3', '.', 'T', 'y', 'p', 'e', 'd', 
+'E', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 'C', 'o', 'n', 'f', 'i', 'g', 'R', '\020', 'c', 'u', 's', 't', 'o', 'm', 'H', 'a', 
+'n', 'd', 's', 'h', 'a', 'k', 'e', 'r', '\032', '\222', '\001', '\n', '\023', 'C', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', 'P', 
+'r', 'o', 'v', 'i', 'd', 'e', 'r', '\022', '\033', '\n', '\004', 'n', 'a', 'm', 'e', '\030', '\001', ' ', '\001', '(', '\t', 'B', '\007', '\372', 'B', 
+'\004', 'r', '\002', '\020', '\001', 'R', '\004', 'n', 'a', 'm', 'e', '\022', 'O', '\n', '\014', 't', 'y', 'p', 'e', 'd', '_', 'c', 'o', 'n', 'f', 
+'i', 'g', '\030', '\002', ' ', '\001', '(', '\013', '2', '*', '.', 'e', 'n', 'v', 'o', 'y', '.', 'c', 'o', 'n', 'f', 'i', 'g', '.', 'c', 
+'o', 'r', 'e', '.', 'v', '3', '.', 'T', 'y', 'p', 'e', 'd', 'E', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 'C', 'o', 'n', 'f', 
+'i', 'g', 'H', '\000', 'R', '\013', 't', 'y', 'p', 'e', 'd', 'C', 'o', 'n', 'f', 'i', 'g', 'B', '\r', '\n', '\006', 'c', 'o', 'n', 'f', 
+'i', 'g', '\022', '\003', '\370', 'B', '\001', '\032', 'm', '\n', '\033', 'C', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', 'P', 'r', 'o', 
+'v', 'i', 'd', 'e', 'r', 'I', 'n', 's', 't', 'a', 'n', 'c', 'e', '\022', '#', '\n', '\r', 'i', 'n', 's', 't', 'a', 'n', 'c', 'e', 
+'_', 'n', 'a', 'm', 'e', '\030', '\001', ' ', '\001', '(', '\t', 'R', '\014', 'i', 'n', 's', 't', 'a', 'n', 'c', 'e', 'N', 'a', 'm', 'e', 
+'\022', ')', '\n', '\020', 'c', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', '_', 'n', 'a', 'm', 'e', '\030', '\002', ' ', '\001', '(', 
+'\t', 'R', '\017', 'c', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', 'N', 'a', 'm', 'e', '\032', '\244', '\006', '\n', '$', 'C', 'o', 
+'m', 'b', 'i', 'n', 'e', 'd', 'C', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', 'V', 'a', 'l', 'i', 'd', 'a', 't', 'i', 
+'o', 'n', 'C', 'o', 'n', 't', 'e', 'x', 't', '\022', '\217', '\001', '\n', '\032', 'd', 'e', 'f', 'a', 'u', 'l', 't', '_', 'v', 'a', 'l', 
+'i', 'd', 'a', 't', 'i', 'o', 'n', '_', 'c', 'o', 'n', 't', 'e', 'x', 't', '\030', '\001', ' ', '\001', '(', '\013', '2', 'G', '.', 'e', 
+'n', 'v', 'o', 'y', '.', 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 's', '.', 't', 'r', 'a', 'n', 's', 'p', 'o', 'r', 't', 
+'_', 's', 'o', 'c', 'k', 'e', 't', 's', '.', 't', 'l', 's', '.', 'v', '3', '.', 'C', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 
+'t', 'e', 'V', 'a', 'l', 'i', 'd', 'a', 't', 'i', 'o', 'n', 'C', 'o', 'n', 't', 'e', 'x', 't', 'B', '\010', '\372', 'B', '\005', '\212', 
+'\001', '\002', '\020', '\001', 'R', '\030', 'd', 'e', 'f', 'a', 'u', 'l', 't', 'V', 'a', 'l', 'i', 'd', 'a', 't', 'i', 'o', 'n', 'C', 'o', 
+'n', 't', 'e', 'x', 't', '\022', '\224', '\001', '\n', '$', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'i', 'o', 'n', '_', 'c', 'o', 'n', 't', 
+'e', 'x', 't', '_', 's', 'd', 's', '_', 's', 'e', 'c', 'r', 'e', 't', '_', 'c', 'o', 'n', 'f', 'i', 'g', '\030', '\002', ' ', '\001', 
+'(', '\013', '2', ':', '.', 'e', 'n', 'v', 'o', 'y', '.', 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 's', '.', 't', 'r', 'a', 
+'n', 's', 'p', 'o', 'r', 't', '_', 's', 'o', 'c', 'k', 'e', 't', 's', '.', 't', 'l', 's', '.', 'v', '3', '.', 'S', 'd', 's', 
+'S', 'e', 'c', 'r', 'e', 't', 'C', 'o', 'n', 'f', 'i', 'g', 'B', '\010', '\372', 'B', '\005', '\212', '\001', '\002', '\020', '\001', 'R', ' ', 'v', 
+'a', 'l', 'i', 'd', 'a', 't', 'i', 'o', 'n', 'C', 'o', 'n', 't', 'e', 'x', 't', 'S', 'd', 's', 'S', 'e', 'c', 'r', 'e', 't', 
+'C', 'o', 'n', 'f', 'i', 'g', '\022', '\263', '\001', '\n', '\'', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'i', 'o', 'n', '_', 'c', 'o', 'n', 
+'t', 'e', 'x', 't', '_', 'c', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', '_', 'p', 'r', 'o', 'v', 'i', 'd', 'e', 'r', 
+'\030', '\003', ' ', '\001', '(', '\013', '2', 'O', '.', 'e', 'n', 'v', 'o', 'y', '.', 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 's', 
+'.', 't', 'r', 'a', 'n', 's', 'p', 'o', 'r', 't', '_', 's', 'o', 'c', 'k', 'e', 't', 's', '.', 't', 'l', 's', '.', 'v', '3', 
+'.', 'C', 'o', 'm', 'm', 'o', 'n', 'T', 'l', 's', 'C', 'o', 'n', 't', 'e', 'x', 't', '.', 'C', 'e', 'r', 't', 'i', 'f', 'i', 
+'c', 'a', 't', 'e', 'P', 'r', 'o', 'v', 'i', 'd', 'e', 'r', 'B', '\013', '\030', '\001', '\222', '\307', '\206', '\330', '\004', '\003', '3', '.', '0', 
+'R', '$', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'i', 'o', 'n', 'C', 'o', 'n', 't', 'e', 'x', 't', 'C', 'e', 'r', 't', 'i', 'f', 
+'i', 'c', 'a', 't', 'e', 'P', 'r', 'o', 'v', 'i', 'd', 'e', 'r', '\022', '\314', '\001', '\n', '0', 'v', 'a', 'l', 'i', 'd', 'a', 't', 
+'i', 'o', 'n', '_', 'c', 'o', 'n', 't', 'e', 'x', 't', '_', 'c', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', '_', 'p', 
+'r', 'o', 'v', 'i', 'd', 'e', 'r', '_', 'i', 'n', 's', 't', 'a', 'n', 'c', 'e', '\030', '\004', ' ', '\001', '(', '\013', '2', 'W', '.', 
+'e', 'n', 'v', 'o', 'y', '.', 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 's', '.', 't', 'r', 'a', 'n', 's', 'p', 'o', 'r', 
+'t', '_', 's', 'o', 'c', 'k', 'e', 't', 's', '.', 't', 'l', 's', '.', 'v', '3', '.', 'C', 'o', 'm', 'm', 'o', 'n', 'T', 'l', 
+'s', 'C', 'o', 'n', 't', 'e', 'x', 't', '.', 'C', 'e', 'r', 't', 'i', 'f', 'i', 'c', 'a', 't', 'e', 'P', 'r', 'o', 'v', 'i', 
+'d', 'e', 'r', 'I', 'n', 's', 't', 'a', 'n', 'c', 'e', 'B', '\013', '\030', '\001', '\222', '\307', '\206', '\330', '\004', '\003', '3', '.', '0', 'R', 
+',', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'i', 'o', 'n', 'C', 'o', 'n', 't', 'e', 'x', 't', 'C', 'e', 'r', 't', 'i', 'f', 'i', 
+'c', 'a', 't', 'e', 'P', 'r', 'o', 'v', 'i', 'd', 'e', 'r', 'I', 'n', 's', 't', 'a', 'n', 'c', 'e', ':', 'N', '\232', '\305', '\210', 
+'\036', 'I', '\n', 'G', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'a', 'u', 't', 'h', '.', 'C', 'o', 'm', 
+'m', 'o', 'n', 'T', 'l', 's', 'C', 'o', 'n', 't', 'e', 'x', 't', '.', 'C', 'o', 'm', 'b', 'i', 'n', 'e', 'd', 'C', 'e', 'r', 
+'t', 'i', 'f', 'i', 'c', 'a', 't', 'e', 'V', 'a', 'l', 'i', 'd', 'a', 't', 'i', 'o', 'n', 'C', 'o', 'n', 't', 'e', 'x', 't', 
+':', ')', '\232', '\305', '\210', '\036', '$', '\n', '\"', 'e', 'n', 'v', 'o', 'y', '.', 'a', 'p', 'i', '.', 'v', '2', '.', 'a', 'u', 't', 
+'h', '.', 'C', 'o', 'm', 'm', 'o', 'n', 'T', 'l', 's', 'C', 'o', 'n', 't', 'e', 'x', 't', 'B', '\031', '\n', '\027', 'v', 'a', 'l', 
+'i', 'd', 'a', 't', 'i', 'o', 'n', '_', 'c', 'o', 'n', 't', 'e', 'x', 't', '_', 't', 'y', 'p', 'e', 'J', '\004', '\010', '\005', '\020', 
+'\006', 'B', 'M', '\n', '7', 'i', 'o', '.', 'e', 'n', 'v', 'o', 'y', 'p', 'r', 'o', 'x', 'y', '.', 'e', 'n', 'v', 'o', 'y', '.', 
+'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', 's', '.', 't', 'r', 'a', 'n', 's', 'p', 'o', 'r', 't', '_', 's', 'o', 'c', 'k', 
+'e', 't', 's', '.', 't', 'l', 's', '.', 'v', '3', 'B', '\010', 'T', 'l', 's', 'P', 'r', 'o', 't', 'o', 'P', '\001', '\272', '\200', '\310', 
+'\321', '\006', '\002', '\020', '\002', 'b', '\006', 'p', 'r', 'o', 't', 'o', '3', 
 };
 
 static upb_def_init *deps[10] = {
@@ -231,7 +236,7 @@ static upb_def_init *deps[10] = {
   &envoy_extensions_transport_sockets_tls_v3_secret_proto_upbdefinit,
   &google_protobuf_duration_proto_upbdefinit,
   &google_protobuf_wrappers_proto_upbdefinit,
-  &udpa_annotations_migrate_proto_upbdefinit,
+  &envoy_annotations_deprecation_proto_upbdefinit,
   &udpa_annotations_status_proto_upbdefinit,
   &udpa_annotations_versioning_proto_upbdefinit,
   &validate_validate_proto_upbdefinit,
@@ -242,5 +247,5 @@ upb_def_init envoy_extensions_transport_sockets_tls_v3_tls_proto_upbdefinit = {
   deps,
   layouts,
   "envoy/extensions/transport_sockets/tls/v3/tls.proto",
-  UPB_STRVIEW_INIT(descriptor, 4707)
+  UPB_STRVIEW_INIT(descriptor, 4838)
 };
index f4afda7..e1aaf05 100644 (file)
@@ -21,14 +21,14 @@ static const upb_msglayout *layouts[2] = {
   &envoy_type_matcher_v3_MetadataMatcher_PathSegment_msginit,
 };
 
-static const char descriptor[621] = {'\n', '$', 'e', 'n', 'v', 'o', 'y', '/', 't', 'y', 'p', 'e', '/', 'm', 'a', 't', 'c', 'h', 'e', 'r', '/', 'v', '3', '/', 'm', 
+static const char descriptor[645] = {'\n', '$', 'e', 'n', 'v', 'o', 'y', '/', 't', 'y', 'p', 'e', '/', 'm', 'a', 't', 'c', 'h', 'e', 'r', '/', 'v', '3', '/', 'm', 
 'e', 't', 'a', 'd', 'a', 't', 'a', '.', 'p', 'r', 'o', 't', 'o', '\022', '\025', 'e', 'n', 'v', 'o', 'y', '.', 't', 'y', 'p', 'e', 
 '.', 'm', 'a', 't', 'c', 'h', 'e', 'r', '.', 'v', '3', '\032', '!', 'e', 'n', 'v', 'o', 'y', '/', 't', 'y', 'p', 'e', '/', 'm', 
 'a', 't', 'c', 'h', 'e', 'r', '/', 'v', '3', '/', 'v', 'a', 'l', 'u', 'e', '.', 'p', 'r', 'o', 't', 'o', '\032', '\035', 'u', 'd', 
 'p', 'a', '/', 'a', 'n', 'n', 'o', 't', 'a', 't', 'i', 'o', 'n', 's', '/', 's', 't', 'a', 't', 'u', 's', '.', 'p', 'r', 'o', 
 't', 'o', '\032', '!', 'u', 'd', 'p', 'a', '/', 'a', 'n', 'n', 'o', 't', 'a', 't', 'i', 'o', 'n', 's', '/', 'v', 'e', 'r', 's', 
 'i', 'o', 'n', 'i', 'n', 'g', '.', 'p', 'r', 'o', 't', 'o', '\032', '\027', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'e', '/', 'v', 'a', 
-'l', 'i', 'd', 'a', 't', 'e', '.', 'p', 'r', 'o', 't', 'o', '\"', '\347', '\002', '\n', '\017', 'M', 'e', 't', 'a', 'd', 'a', 't', 'a', 
+'l', 'i', 'd', 'a', 't', 'e', '.', 'p', 'r', 'o', 't', 'o', '\"', '\377', '\002', '\n', '\017', 'M', 'e', 't', 'a', 'd', 'a', 't', 'a', 
 'M', 'a', 't', 'c', 'h', 'e', 'r', '\022', '\037', '\n', '\006', 'f', 'i', 'l', 't', 'e', 'r', '\030', '\001', ' ', '\001', '(', '\t', 'B', '\007', 
 '\372', 'B', '\004', 'r', '\002', '\020', '\001', 'R', '\006', 'f', 'i', 'l', 't', 'e', 'r', '\022', 'P', '\n', '\004', 'p', 'a', 't', 'h', '\030', '\002', 
 ' ', '\003', '(', '\013', '2', '2', '.', 'e', 'n', 'v', 'o', 'y', '.', 't', 'y', 'p', 'e', '.', 'm', 'a', 't', 'c', 'h', 'e', 'r', 
@@ -36,16 +36,17 @@ static const char descriptor[621] = {'\n', '$', 'e', 'n', 'v', 'o', 'y', '/', 't
 'e', 'g', 'm', 'e', 'n', 't', 'B', '\010', '\372', 'B', '\005', '\222', '\001', '\002', '\010', '\001', 'R', '\004', 'p', 'a', 't', 'h', '\022', 'C', '\n', 
 '\005', 'v', 'a', 'l', 'u', 'e', '\030', '\003', ' ', '\001', '(', '\013', '2', '#', '.', 'e', 'n', 'v', 'o', 'y', '.', 't', 'y', 'p', 'e', 
 '.', 'm', 'a', 't', 'c', 'h', 'e', 'r', '.', 'v', '3', '.', 'V', 'a', 'l', 'u', 'e', 'M', 'a', 't', 'c', 'h', 'e', 'r', 'B', 
-'\010', '\372', 'B', '\005', '\212', '\001', '\002', '\020', '\001', 'R', '\005', 'v', 'a', 'l', 'u', 'e', '\032', 'q', '\n', '\013', 'P', 'a', 't', 'h', 'S', 
-'e', 'g', 'm', 'e', 'n', 't', '\022', '\033', '\n', '\003', 'k', 'e', 'y', '\030', '\001', ' ', '\001', '(', '\t', 'B', '\007', '\372', 'B', '\004', 'r', 
-'\002', '\020', '\001', 'H', '\000', 'R', '\003', 'k', 'e', 'y', ':', '5', '\232', '\305', '\210', '\036', '0', '\n', '.', 'e', 'n', 'v', 'o', 'y', '.', 
-'t', 'y', 'p', 'e', '.', 'm', 'a', 't', 'c', 'h', 'e', 'r', '.', 'M', 'e', 't', 'a', 'd', 'a', 't', 'a', 'M', 'a', 't', 'c', 
-'h', 'e', 'r', '.', 'P', 'a', 't', 'h', 'S', 'e', 'g', 'm', 'e', 'n', 't', 'B', '\016', '\n', '\007', 's', 'e', 'g', 'm', 'e', 'n', 
-'t', '\022', '\003', '\370', 'B', '\001', ':', ')', '\232', '\305', '\210', '\036', '$', '\n', '\"', 'e', 'n', 'v', 'o', 'y', '.', 't', 'y', 'p', 'e', 
-'.', 'm', 'a', 't', 'c', 'h', 'e', 'r', '.', 'M', 'e', 't', 'a', 'd', 'a', 't', 'a', 'M', 'a', 't', 'c', 'h', 'e', 'r', 'B', 
-'>', '\n', '#', 'i', 'o', '.', 'e', 'n', 'v', 'o', 'y', 'p', 'r', 'o', 'x', 'y', '.', 'e', 'n', 'v', 'o', 'y', '.', 't', 'y', 
-'p', 'e', '.', 'm', 'a', 't', 'c', 'h', 'e', 'r', '.', 'v', '3', 'B', '\r', 'M', 'e', 't', 'a', 'd', 'a', 't', 'a', 'P', 'r', 
-'o', 't', 'o', 'P', '\001', '\272', '\200', '\310', '\321', '\006', '\002', '\020', '\002', 'b', '\006', 'p', 'r', 'o', 't', 'o', '3', 
+'\010', '\372', 'B', '\005', '\212', '\001', '\002', '\020', '\001', 'R', '\005', 'v', 'a', 'l', 'u', 'e', '\022', '\026', '\n', '\006', 'i', 'n', 'v', 'e', 'r', 
+'t', '\030', '\004', ' ', '\001', '(', '\010', 'R', '\006', 'i', 'n', 'v', 'e', 'r', 't', '\032', 'q', '\n', '\013', 'P', 'a', 't', 'h', 'S', 'e', 
+'g', 'm', 'e', 'n', 't', '\022', '\033', '\n', '\003', 'k', 'e', 'y', '\030', '\001', ' ', '\001', '(', '\t', 'B', '\007', '\372', 'B', '\004', 'r', '\002', 
+'\020', '\001', 'H', '\000', 'R', '\003', 'k', 'e', 'y', ':', '5', '\232', '\305', '\210', '\036', '0', '\n', '.', 'e', 'n', 'v', 'o', 'y', '.', 't', 
+'y', 'p', 'e', '.', 'm', 'a', 't', 'c', 'h', 'e', 'r', '.', 'M', 'e', 't', 'a', 'd', 'a', 't', 'a', 'M', 'a', 't', 'c', 'h', 
+'e', 'r', '.', 'P', 'a', 't', 'h', 'S', 'e', 'g', 'm', 'e', 'n', 't', 'B', '\016', '\n', '\007', 's', 'e', 'g', 'm', 'e', 'n', 't', 
+'\022', '\003', '\370', 'B', '\001', ':', ')', '\232', '\305', '\210', '\036', '$', '\n', '\"', 'e', 'n', 'v', 'o', 'y', '.', 't', 'y', 'p', 'e', '.', 
+'m', 'a', 't', 'c', 'h', 'e', 'r', '.', 'M', 'e', 't', 'a', 'd', 'a', 't', 'a', 'M', 'a', 't', 'c', 'h', 'e', 'r', 'B', '>', 
+'\n', '#', 'i', 'o', '.', 'e', 'n', 'v', 'o', 'y', 'p', 'r', 'o', 'x', 'y', '.', 'e', 'n', 'v', 'o', 'y', '.', 't', 'y', 'p', 
+'e', '.', 'm', 'a', 't', 'c', 'h', 'e', 'r', '.', 'v', '3', 'B', '\r', 'M', 'e', 't', 'a', 'd', 'a', 't', 'a', 'P', 'r', 'o', 
+'t', 'o', 'P', '\001', '\272', '\200', '\310', '\321', '\006', '\002', '\020', '\002', 'b', '\006', 'p', 'r', 'o', 't', 'o', '3', 
 };
 
 static upb_def_init *deps[5] = {
@@ -60,5 +61,5 @@ upb_def_init envoy_type_matcher_v3_metadata_proto_upbdefinit = {
   deps,
   layouts,
   "envoy/type/matcher/v3/metadata.proto",
-  UPB_STRVIEW_INIT(descriptor, 621)
+  UPB_STRVIEW_INIT(descriptor, 645)
 };
index 9026d56..0b774ae 100644 (file)
@@ -67,7 +67,7 @@ static const upb_msglayout *layouts[27] = {
   &google_protobuf_GeneratedCodeInfo_Annotation_msginit,
 };
 
-static const char descriptor[7601] = {'\n', ' ', 'g', 'o', 'o', 'g', 'l', 'e', '/', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '/', 'd', 'e', 's', 'c', 'r', 'i', 'p', 
+static const char descriptor[7619] = {'\n', ' ', 'g', 'o', 'o', 'g', 'l', 'e', '/', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '/', 'd', 'e', 's', 'c', 'r', 'i', 'p', 
 't', 'o', 'r', '.', 'p', 'r', 'o', 't', 'o', '\022', '\017', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 
 'f', '\"', 'M', '\n', '\021', 'F', 'i', 'l', 'e', 'D', 'e', 's', 'c', 'r', 'i', 'p', 't', 'o', 'r', 'S', 'e', 't', '\022', '8', '\n', 
 '\004', 'f', 'i', 'l', 'e', '\030', '\001', ' ', '\003', '(', '\013', '2', '$', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 
@@ -256,7 +256,7 @@ static const char descriptor[7601] = {'\n', ' ', 'g', 'o', 'o', 'g', 'l', 'e', '
 'r', 'e', 't', 'e', 'd', 'O', 'p', 't', 'i', 'o', 'n', '\"', ':', '\n', '\014', 'O', 'p', 't', 'i', 'm', 'i', 'z', 'e', 'M', 'o', 
 'd', 'e', '\022', '\t', '\n', '\005', 'S', 'P', 'E', 'E', 'D', '\020', '\001', '\022', '\r', '\n', '\t', 'C', 'O', 'D', 'E', '_', 'S', 'I', 'Z', 
 'E', '\020', '\002', '\022', '\020', '\n', '\014', 'L', 'I', 'T', 'E', '_', 'R', 'U', 'N', 'T', 'I', 'M', 'E', '\020', '\003', '*', '\t', '\010', '\350', 
-'\007', '\020', '\200', '\200', '\200', '\200', '\002', 'J', '\004', '\010', '&', '\020', '\'', '\"', '\321', '\002', '\n', '\016', 'M', 'e', 's', 's', 'a', 'g', 'e', 
+'\007', '\020', '\200', '\200', '\200', '\200', '\002', 'J', '\004', '\010', '&', '\020', '\'', '\"', '\343', '\002', '\n', '\016', 'M', 'e', 's', 's', 'a', 'g', 'e', 
 'O', 'p', 't', 'i', 'o', 'n', 's', '\022', '<', '\n', '\027', 'm', 'e', 's', 's', 'a', 'g', 'e', '_', 's', 'e', 't', '_', 'w', 'i', 
 'r', 'e', '_', 'f', 'o', 'r', 'm', 'a', 't', '\030', '\001', ' ', '\001', '(', '\010', ':', '\005', 'f', 'a', 'l', 's', 'e', 'R', '\024', 'm', 
 'e', 's', 's', 'a', 'g', 'e', 'S', 'e', 't', 'W', 'i', 'r', 'e', 'F', 'o', 'r', 'm', 'a', 't', '\022', 'L', '\n', '\037', 'n', 'o', 
@@ -269,109 +269,109 @@ static const char descriptor[7601] = {'\n', ' ', 'g', 'o', 'o', 'g', 'l', 'e', '
 'r', 'p', 'r', 'e', 't', 'e', 'd', '_', 'o', 'p', 't', 'i', 'o', 'n', '\030', '\347', '\007', ' ', '\003', '(', '\013', '2', '$', '.', 'g', 
 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'U', 'n', 'i', 'n', 't', 'e', 'r', 'p', 'r', 'e', 
 't', 'e', 'd', 'O', 'p', 't', 'i', 'o', 'n', 'R', '\023', 'u', 'n', 'i', 'n', 't', 'e', 'r', 'p', 'r', 'e', 't', 'e', 'd', 'O', 
-'p', 't', 'i', 'o', 'n', '*', '\t', '\010', '\350', '\007', '\020', '\200', '\200', '\200', '\200', '\002', 'J', '\004', '\010', '\010', '\020', '\t', 'J', '\004', '\010', 
-'\t', '\020', '\n', '\"', '\342', '\003', '\n', '\014', 'F', 'i', 'e', 'l', 'd', 'O', 'p', 't', 'i', 'o', 'n', 's', '\022', 'A', '\n', '\005', 'c', 
-'t', 'y', 'p', 'e', '\030', '\001', ' ', '\001', '(', '\016', '2', '#', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 
-'b', 'u', 'f', '.', 'F', 'i', 'e', 'l', 'd', 'O', 'p', 't', 'i', 'o', 'n', 's', '.', 'C', 'T', 'y', 'p', 'e', ':', '\006', 'S', 
-'T', 'R', 'I', 'N', 'G', 'R', '\005', 'c', 't', 'y', 'p', 'e', '\022', '\026', '\n', '\006', 'p', 'a', 'c', 'k', 'e', 'd', '\030', '\002', ' ', 
-'\001', '(', '\010', 'R', '\006', 'p', 'a', 'c', 'k', 'e', 'd', '\022', 'G', '\n', '\006', 'j', 's', 't', 'y', 'p', 'e', '\030', '\006', ' ', '\001', 
-'(', '\016', '2', '$', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'F', 'i', 'e', 'l', 
-'d', 'O', 'p', 't', 'i', 'o', 'n', 's', '.', 'J', 'S', 'T', 'y', 'p', 'e', ':', '\t', 'J', 'S', '_', 'N', 'O', 'R', 'M', 'A', 
-'L', 'R', '\006', 'j', 's', 't', 'y', 'p', 'e', '\022', '\031', '\n', '\004', 'l', 'a', 'z', 'y', '\030', '\005', ' ', '\001', '(', '\010', ':', '\005', 
-'f', 'a', 'l', 's', 'e', 'R', '\004', 'l', 'a', 'z', 'y', '\022', '%', '\n', '\n', 'd', 'e', 'p', 'r', 'e', 'c', 'a', 't', 'e', 'd', 
-'\030', '\003', ' ', '\001', '(', '\010', ':', '\005', 'f', 'a', 'l', 's', 'e', 'R', '\n', 'd', 'e', 'p', 'r', 'e', 'c', 'a', 't', 'e', 'd', 
-'\022', '\031', '\n', '\004', 'w', 'e', 'a', 'k', '\030', '\n', ' ', '\001', '(', '\010', ':', '\005', 'f', 'a', 'l', 's', 'e', 'R', '\004', 'w', 'e', 
-'a', 'k', '\022', 'X', '\n', '\024', 'u', 'n', 'i', 'n', 't', 'e', 'r', 'p', 'r', 'e', 't', 'e', 'd', '_', 'o', 'p', 't', 'i', 'o', 
-'n', '\030', '\347', '\007', ' ', '\003', '(', '\013', '2', '$', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 
-'f', '.', 'U', 'n', 'i', 'n', 't', 'e', 'r', 'p', 'r', 'e', 't', 'e', 'd', 'O', 'p', 't', 'i', 'o', 'n', 'R', '\023', 'u', 'n', 
-'i', 'n', 't', 'e', 'r', 'p', 'r', 'e', 't', 'e', 'd', 'O', 'p', 't', 'i', 'o', 'n', '\"', '/', '\n', '\005', 'C', 'T', 'y', 'p', 
-'e', '\022', '\n', '\n', '\006', 'S', 'T', 'R', 'I', 'N', 'G', '\020', '\000', '\022', '\010', '\n', '\004', 'C', 'O', 'R', 'D', '\020', '\001', '\022', '\020', 
-'\n', '\014', 'S', 'T', 'R', 'I', 'N', 'G', '_', 'P', 'I', 'E', 'C', 'E', '\020', '\002', '\"', '5', '\n', '\006', 'J', 'S', 'T', 'y', 'p', 
-'e', '\022', '\r', '\n', '\t', 'J', 'S', '_', 'N', 'O', 'R', 'M', 'A', 'L', '\020', '\000', '\022', '\r', '\n', '\t', 'J', 'S', '_', 'S', 'T', 
-'R', 'I', 'N', 'G', '\020', '\001', '\022', '\r', '\n', '\t', 'J', 'S', '_', 'N', 'U', 'M', 'B', 'E', 'R', '\020', '\002', '*', '\t', '\010', '\350', 
-'\007', '\020', '\200', '\200', '\200', '\200', '\002', 'J', '\004', '\010', '\004', '\020', '\005', '\"', 's', '\n', '\014', 'O', 'n', 'e', 'o', 'f', 'O', 'p', 't', 
-'i', 'o', 'n', 's', '\022', 'X', '\n', '\024', 'u', 'n', 'i', 'n', 't', 'e', 'r', 'p', 'r', 'e', 't', 'e', 'd', '_', 'o', 'p', 't', 
-'i', 'o', 'n', '\030', '\347', '\007', ' ', '\003', '(', '\013', '2', '$', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 
-'b', 'u', 'f', '.', 'U', 'n', 'i', 'n', 't', 'e', 'r', 'p', 'r', 'e', 't', 'e', 'd', 'O', 'p', 't', 'i', 'o', 'n', 'R', '\023', 
-'u', 'n', 'i', 'n', 't', 'e', 'r', 'p', 'r', 'e', 't', 'e', 'd', 'O', 'p', 't', 'i', 'o', 'n', '*', '\t', '\010', '\350', '\007', '\020', 
-'\200', '\200', '\200', '\200', '\002', '\"', '\300', '\001', '\n', '\013', 'E', 'n', 'u', 'm', 'O', 'p', 't', 'i', 'o', 'n', 's', '\022', '\037', '\n', '\013', 
-'a', 'l', 'l', 'o', 'w', '_', 'a', 'l', 'i', 'a', 's', '\030', '\002', ' ', '\001', '(', '\010', 'R', '\n', 'a', 'l', 'l', 'o', 'w', 'A', 
-'l', 'i', 'a', 's', '\022', '%', '\n', '\n', 'd', 'e', 'p', 'r', 'e', 'c', 'a', 't', 'e', 'd', '\030', '\003', ' ', '\001', '(', '\010', ':', 
-'\005', 'f', 'a', 'l', 's', 'e', 'R', '\n', 'd', 'e', 'p', 'r', 'e', 'c', 'a', 't', 'e', 'd', '\022', 'X', '\n', '\024', 'u', 'n', 'i', 
-'n', 't', 'e', 'r', 'p', 'r', 'e', 't', 'e', 'd', '_', 'o', 'p', 't', 'i', 'o', 'n', '\030', '\347', '\007', ' ', '\003', '(', '\013', '2', 
-'$', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'U', 'n', 'i', 'n', 't', 'e', 'r', 
-'p', 'r', 'e', 't', 'e', 'd', 'O', 'p', 't', 'i', 'o', 'n', 'R', '\023', 'u', 'n', 'i', 'n', 't', 'e', 'r', 'p', 'r', 'e', 't', 
-'e', 'd', 'O', 'p', 't', 'i', 'o', 'n', '*', '\t', '\010', '\350', '\007', '\020', '\200', '\200', '\200', '\200', '\002', 'J', '\004', '\010', '\005', '\020', '\006', 
-'\"', '\236', '\001', '\n', '\020', 'E', 'n', 'u', 'm', 'V', 'a', 'l', 'u', 'e', 'O', 'p', 't', 'i', 'o', 'n', 's', '\022', '%', '\n', '\n', 
-'d', 'e', 'p', 'r', 'e', 'c', 'a', 't', 'e', 'd', '\030', '\001', ' ', '\001', '(', '\010', ':', '\005', 'f', 'a', 'l', 's', 'e', 'R', '\n', 
-'d', 'e', 'p', 'r', 'e', 'c', 'a', 't', 'e', 'd', '\022', 'X', '\n', '\024', 'u', 'n', 'i', 'n', 't', 'e', 'r', 'p', 'r', 'e', 't', 
+'p', 't', 'i', 'o', 'n', '*', '\t', '\010', '\350', '\007', '\020', '\200', '\200', '\200', '\200', '\002', 'J', '\004', '\010', '\004', '\020', '\005', 'J', '\004', '\010', 
+'\005', '\020', '\006', 'J', '\004', '\010', '\006', '\020', '\007', 'J', '\004', '\010', '\010', '\020', '\t', 'J', '\004', '\010', '\t', '\020', '\n', '\"', '\342', '\003', '\n', 
+'\014', 'F', 'i', 'e', 'l', 'd', 'O', 'p', 't', 'i', 'o', 'n', 's', '\022', 'A', '\n', '\005', 'c', 't', 'y', 'p', 'e', '\030', '\001', ' ', 
+'\001', '(', '\016', '2', '#', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'F', 'i', 'e', 
+'l', 'd', 'O', 'p', 't', 'i', 'o', 'n', 's', '.', 'C', 'T', 'y', 'p', 'e', ':', '\006', 'S', 'T', 'R', 'I', 'N', 'G', 'R', '\005', 
+'c', 't', 'y', 'p', 'e', '\022', '\026', '\n', '\006', 'p', 'a', 'c', 'k', 'e', 'd', '\030', '\002', ' ', '\001', '(', '\010', 'R', '\006', 'p', 'a', 
+'c', 'k', 'e', 'd', '\022', 'G', '\n', '\006', 'j', 's', 't', 'y', 'p', 'e', '\030', '\006', ' ', '\001', '(', '\016', '2', '$', '.', 'g', 'o', 
+'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'F', 'i', 'e', 'l', 'd', 'O', 'p', 't', 'i', 'o', 'n', 
+'s', '.', 'J', 'S', 'T', 'y', 'p', 'e', ':', '\t', 'J', 'S', '_', 'N', 'O', 'R', 'M', 'A', 'L', 'R', '\006', 'j', 's', 't', 'y', 
+'p', 'e', '\022', '\031', '\n', '\004', 'l', 'a', 'z', 'y', '\030', '\005', ' ', '\001', '(', '\010', ':', '\005', 'f', 'a', 'l', 's', 'e', 'R', '\004', 
+'l', 'a', 'z', 'y', '\022', '%', '\n', '\n', 'd', 'e', 'p', 'r', 'e', 'c', 'a', 't', 'e', 'd', '\030', '\003', ' ', '\001', '(', '\010', ':', 
+'\005', 'f', 'a', 'l', 's', 'e', 'R', '\n', 'd', 'e', 'p', 'r', 'e', 'c', 'a', 't', 'e', 'd', '\022', '\031', '\n', '\004', 'w', 'e', 'a', 
+'k', '\030', '\n', ' ', '\001', '(', '\010', ':', '\005', 'f', 'a', 'l', 's', 'e', 'R', '\004', 'w', 'e', 'a', 'k', '\022', 'X', '\n', '\024', 'u', 
+'n', 'i', 'n', 't', 'e', 'r', 'p', 'r', 'e', 't', 'e', 'd', '_', 'o', 'p', 't', 'i', 'o', 'n', '\030', '\347', '\007', ' ', '\003', '(', 
+'\013', '2', '$', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'U', 'n', 'i', 'n', 't', 
+'e', 'r', 'p', 'r', 'e', 't', 'e', 'd', 'O', 'p', 't', 'i', 'o', 'n', 'R', '\023', 'u', 'n', 'i', 'n', 't', 'e', 'r', 'p', 'r', 
+'e', 't', 'e', 'd', 'O', 'p', 't', 'i', 'o', 'n', '\"', '/', '\n', '\005', 'C', 'T', 'y', 'p', 'e', '\022', '\n', '\n', '\006', 'S', 'T', 
+'R', 'I', 'N', 'G', '\020', '\000', '\022', '\010', '\n', '\004', 'C', 'O', 'R', 'D', '\020', '\001', '\022', '\020', '\n', '\014', 'S', 'T', 'R', 'I', 'N', 
+'G', '_', 'P', 'I', 'E', 'C', 'E', '\020', '\002', '\"', '5', '\n', '\006', 'J', 'S', 'T', 'y', 'p', 'e', '\022', '\r', '\n', '\t', 'J', 'S', 
+'_', 'N', 'O', 'R', 'M', 'A', 'L', '\020', '\000', '\022', '\r', '\n', '\t', 'J', 'S', '_', 'S', 'T', 'R', 'I', 'N', 'G', '\020', '\001', '\022', 
+'\r', '\n', '\t', 'J', 'S', '_', 'N', 'U', 'M', 'B', 'E', 'R', '\020', '\002', '*', '\t', '\010', '\350', '\007', '\020', '\200', '\200', '\200', '\200', '\002', 
+'J', '\004', '\010', '\004', '\020', '\005', '\"', 's', '\n', '\014', 'O', 'n', 'e', 'o', 'f', 'O', 'p', 't', 'i', 'o', 'n', 's', '\022', 'X', '\n', 
+'\024', 'u', 'n', 'i', 'n', 't', 'e', 'r', 'p', 'r', 'e', 't', 'e', 'd', '_', 'o', 'p', 't', 'i', 'o', 'n', '\030', '\347', '\007', ' ', 
+'\003', '(', '\013', '2', '$', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'U', 'n', 'i', 
+'n', 't', 'e', 'r', 'p', 'r', 'e', 't', 'e', 'd', 'O', 'p', 't', 'i', 'o', 'n', 'R', '\023', 'u', 'n', 'i', 'n', 't', 'e', 'r', 
+'p', 'r', 'e', 't', 'e', 'd', 'O', 'p', 't', 'i', 'o', 'n', '*', '\t', '\010', '\350', '\007', '\020', '\200', '\200', '\200', '\200', '\002', '\"', '\300', 
+'\001', '\n', '\013', 'E', 'n', 'u', 'm', 'O', 'p', 't', 'i', 'o', 'n', 's', '\022', '\037', '\n', '\013', 'a', 'l', 'l', 'o', 'w', '_', 'a', 
+'l', 'i', 'a', 's', '\030', '\002', ' ', '\001', '(', '\010', 'R', '\n', 'a', 'l', 'l', 'o', 'w', 'A', 'l', 'i', 'a', 's', '\022', '%', '\n', 
+'\n', 'd', 'e', 'p', 'r', 'e', 'c', 'a', 't', 'e', 'd', '\030', '\003', ' ', '\001', '(', '\010', ':', '\005', 'f', 'a', 'l', 's', 'e', 'R', 
+'\n', 'd', 'e', 'p', 'r', 'e', 'c', 'a', 't', 'e', 'd', '\022', 'X', '\n', '\024', 'u', 'n', 'i', 'n', 't', 'e', 'r', 'p', 'r', 'e', 
+'t', 'e', 'd', '_', 'o', 'p', 't', 'i', 'o', 'n', '\030', '\347', '\007', ' ', '\003', '(', '\013', '2', '$', '.', 'g', 'o', 'o', 'g', 'l', 
+'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'U', 'n', 'i', 'n', 't', 'e', 'r', 'p', 'r', 'e', 't', 'e', 'd', 'O', 
+'p', 't', 'i', 'o', 'n', 'R', '\023', 'u', 'n', 'i', 'n', 't', 'e', 'r', 'p', 'r', 'e', 't', 'e', 'd', 'O', 'p', 't', 'i', 'o', 
+'n', '*', '\t', '\010', '\350', '\007', '\020', '\200', '\200', '\200', '\200', '\002', 'J', '\004', '\010', '\005', '\020', '\006', '\"', '\236', '\001', '\n', '\020', 'E', 'n', 
+'u', 'm', 'V', 'a', 'l', 'u', 'e', 'O', 'p', 't', 'i', 'o', 'n', 's', '\022', '%', '\n', '\n', 'd', 'e', 'p', 'r', 'e', 'c', 'a', 
+'t', 'e', 'd', '\030', '\001', ' ', '\001', '(', '\010', ':', '\005', 'f', 'a', 'l', 's', 'e', 'R', '\n', 'd', 'e', 'p', 'r', 'e', 'c', 'a', 
+'t', 'e', 'd', '\022', 'X', '\n', '\024', 'u', 'n', 'i', 'n', 't', 'e', 'r', 'p', 'r', 'e', 't', 'e', 'd', '_', 'o', 'p', 't', 'i', 
+'o', 'n', '\030', '\347', '\007', ' ', '\003', '(', '\013', '2', '$', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 
+'u', 'f', '.', 'U', 'n', 'i', 'n', 't', 'e', 'r', 'p', 'r', 'e', 't', 'e', 'd', 'O', 'p', 't', 'i', 'o', 'n', 'R', '\023', 'u', 
+'n', 'i', 'n', 't', 'e', 'r', 'p', 'r', 'e', 't', 'e', 'd', 'O', 'p', 't', 'i', 'o', 'n', '*', '\t', '\010', '\350', '\007', '\020', '\200', 
+'\200', '\200', '\200', '\002', '\"', '\234', '\001', '\n', '\016', 'S', 'e', 'r', 'v', 'i', 'c', 'e', 'O', 'p', 't', 'i', 'o', 'n', 's', '\022', '%', 
+'\n', '\n', 'd', 'e', 'p', 'r', 'e', 'c', 'a', 't', 'e', 'd', '\030', '!', ' ', '\001', '(', '\010', ':', '\005', 'f', 'a', 'l', 's', 'e', 
+'R', '\n', 'd', 'e', 'p', 'r', 'e', 'c', 'a', 't', 'e', 'd', '\022', 'X', '\n', '\024', 'u', 'n', 'i', 'n', 't', 'e', 'r', 'p', 'r', 
+'e', 't', 'e', 'd', '_', 'o', 'p', 't', 'i', 'o', 'n', '\030', '\347', '\007', ' ', '\003', '(', '\013', '2', '$', '.', 'g', 'o', 'o', 'g', 
+'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'U', 'n', 'i', 'n', 't', 'e', 'r', 'p', 'r', 'e', 't', 'e', 'd', 
+'O', 'p', 't', 'i', 'o', 'n', 'R', '\023', 'u', 'n', 'i', 'n', 't', 'e', 'r', 'p', 'r', 'e', 't', 'e', 'd', 'O', 'p', 't', 'i', 
+'o', 'n', '*', '\t', '\010', '\350', '\007', '\020', '\200', '\200', '\200', '\200', '\002', '\"', '\340', '\002', '\n', '\r', 'M', 'e', 't', 'h', 'o', 'd', 'O', 
+'p', 't', 'i', 'o', 'n', 's', '\022', '%', '\n', '\n', 'd', 'e', 'p', 'r', 'e', 'c', 'a', 't', 'e', 'd', '\030', '!', ' ', '\001', '(', 
+'\010', ':', '\005', 'f', 'a', 'l', 's', 'e', 'R', '\n', 'd', 'e', 'p', 'r', 'e', 'c', 'a', 't', 'e', 'd', '\022', 'q', '\n', '\021', 'i', 
+'d', 'e', 'm', 'p', 'o', 't', 'e', 'n', 'c', 'y', '_', 'l', 'e', 'v', 'e', 'l', '\030', '\"', ' ', '\001', '(', '\016', '2', '/', '.', 
+'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'M', 'e', 't', 'h', 'o', 'd', 'O', 'p', 't', 
+'i', 'o', 'n', 's', '.', 'I', 'd', 'e', 'm', 'p', 'o', 't', 'e', 'n', 'c', 'y', 'L', 'e', 'v', 'e', 'l', ':', '\023', 'I', 'D', 
+'E', 'M', 'P', 'O', 'T', 'E', 'N', 'C', 'Y', '_', 'U', 'N', 'K', 'N', 'O', 'W', 'N', 'R', '\020', 'i', 'd', 'e', 'm', 'p', 'o', 
+'t', 'e', 'n', 'c', 'y', 'L', 'e', 'v', 'e', 'l', '\022', 'X', '\n', '\024', 'u', 'n', 'i', 'n', 't', 'e', 'r', 'p', 'r', 'e', 't', 
 'e', 'd', '_', 'o', 'p', 't', 'i', 'o', 'n', '\030', '\347', '\007', ' ', '\003', '(', '\013', '2', '$', '.', 'g', 'o', 'o', 'g', 'l', 'e', 
 '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'U', 'n', 'i', 'n', 't', 'e', 'r', 'p', 'r', 'e', 't', 'e', 'd', 'O', 'p', 
 't', 'i', 'o', 'n', 'R', '\023', 'u', 'n', 'i', 'n', 't', 'e', 'r', 'p', 'r', 'e', 't', 'e', 'd', 'O', 'p', 't', 'i', 'o', 'n', 
-'*', '\t', '\010', '\350', '\007', '\020', '\200', '\200', '\200', '\200', '\002', '\"', '\234', '\001', '\n', '\016', 'S', 'e', 'r', 'v', 'i', 'c', 'e', 'O', 'p', 
-'t', 'i', 'o', 'n', 's', '\022', '%', '\n', '\n', 'd', 'e', 'p', 'r', 'e', 'c', 'a', 't', 'e', 'd', '\030', '!', ' ', '\001', '(', '\010', 
-':', '\005', 'f', 'a', 'l', 's', 'e', 'R', '\n', 'd', 'e', 'p', 'r', 'e', 'c', 'a', 't', 'e', 'd', '\022', 'X', '\n', '\024', 'u', 'n', 
-'i', 'n', 't', 'e', 'r', 'p', 'r', 'e', 't', 'e', 'd', '_', 'o', 'p', 't', 'i', 'o', 'n', '\030', '\347', '\007', ' ', '\003', '(', '\013', 
-'2', '$', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'U', 'n', 'i', 'n', 't', 'e', 
-'r', 'p', 'r', 'e', 't', 'e', 'd', 'O', 'p', 't', 'i', 'o', 'n', 'R', '\023', 'u', 'n', 'i', 'n', 't', 'e', 'r', 'p', 'r', 'e', 
-'t', 'e', 'd', 'O', 'p', 't', 'i', 'o', 'n', '*', '\t', '\010', '\350', '\007', '\020', '\200', '\200', '\200', '\200', '\002', '\"', '\340', '\002', '\n', '\r', 
-'M', 'e', 't', 'h', 'o', 'd', 'O', 'p', 't', 'i', 'o', 'n', 's', '\022', '%', '\n', '\n', 'd', 'e', 'p', 'r', 'e', 'c', 'a', 't', 
-'e', 'd', '\030', '!', ' ', '\001', '(', '\010', ':', '\005', 'f', 'a', 'l', 's', 'e', 'R', '\n', 'd', 'e', 'p', 'r', 'e', 'c', 'a', 't', 
-'e', 'd', '\022', 'q', '\n', '\021', 'i', 'd', 'e', 'm', 'p', 'o', 't', 'e', 'n', 'c', 'y', '_', 'l', 'e', 'v', 'e', 'l', '\030', '\"', 
-' ', '\001', '(', '\016', '2', '/', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'M', 'e', 
-'t', 'h', 'o', 'd', 'O', 'p', 't', 'i', 'o', 'n', 's', '.', 'I', 'd', 'e', 'm', 'p', 'o', 't', 'e', 'n', 'c', 'y', 'L', 'e', 
-'v', 'e', 'l', ':', '\023', 'I', 'D', 'E', 'M', 'P', 'O', 'T', 'E', 'N', 'C', 'Y', '_', 'U', 'N', 'K', 'N', 'O', 'W', 'N', 'R', 
-'\020', 'i', 'd', 'e', 'm', 'p', 'o', 't', 'e', 'n', 'c', 'y', 'L', 'e', 'v', 'e', 'l', '\022', 'X', '\n', '\024', 'u', 'n', 'i', 'n', 
-'t', 'e', 'r', 'p', 'r', 'e', 't', 'e', 'd', '_', 'o', 'p', 't', 'i', 'o', 'n', '\030', '\347', '\007', ' ', '\003', '(', '\013', '2', '$', 
-'.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'U', 'n', 'i', 'n', 't', 'e', 'r', 'p', 
-'r', 'e', 't', 'e', 'd', 'O', 'p', 't', 'i', 'o', 'n', 'R', '\023', 'u', 'n', 'i', 'n', 't', 'e', 'r', 'p', 'r', 'e', 't', 'e', 
-'d', 'O', 'p', 't', 'i', 'o', 'n', '\"', 'P', '\n', '\020', 'I', 'd', 'e', 'm', 'p', 'o', 't', 'e', 'n', 'c', 'y', 'L', 'e', 'v', 
-'e', 'l', '\022', '\027', '\n', '\023', 'I', 'D', 'E', 'M', 'P', 'O', 'T', 'E', 'N', 'C', 'Y', '_', 'U', 'N', 'K', 'N', 'O', 'W', 'N', 
-'\020', '\000', '\022', '\023', '\n', '\017', 'N', 'O', '_', 'S', 'I', 'D', 'E', '_', 'E', 'F', 'F', 'E', 'C', 'T', 'S', '\020', '\001', '\022', '\016', 
-'\n', '\n', 'I', 'D', 'E', 'M', 'P', 'O', 'T', 'E', 'N', 'T', '\020', '\002', '*', '\t', '\010', '\350', '\007', '\020', '\200', '\200', '\200', '\200', '\002', 
-'\"', '\232', '\003', '\n', '\023', 'U', 'n', 'i', 'n', 't', 'e', 'r', 'p', 'r', 'e', 't', 'e', 'd', 'O', 'p', 't', 'i', 'o', 'n', '\022', 
-'A', '\n', '\004', 'n', 'a', 'm', 'e', '\030', '\002', ' ', '\003', '(', '\013', '2', '-', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 
-'o', 't', 'o', 'b', 'u', 'f', '.', 'U', 'n', 'i', 'n', 't', 'e', 'r', 'p', 'r', 'e', 't', 'e', 'd', 'O', 'p', 't', 'i', 'o', 
-'n', '.', 'N', 'a', 'm', 'e', 'P', 'a', 'r', 't', 'R', '\004', 'n', 'a', 'm', 'e', '\022', ')', '\n', '\020', 'i', 'd', 'e', 'n', 't', 
-'i', 'f', 'i', 'e', 'r', '_', 'v', 'a', 'l', 'u', 'e', '\030', '\003', ' ', '\001', '(', '\t', 'R', '\017', 'i', 'd', 'e', 'n', 't', 'i', 
-'f', 'i', 'e', 'r', 'V', 'a', 'l', 'u', 'e', '\022', ',', '\n', '\022', 'p', 'o', 's', 'i', 't', 'i', 'v', 'e', '_', 'i', 'n', 't', 
-'_', 'v', 'a', 'l', 'u', 'e', '\030', '\004', ' ', '\001', '(', '\004', 'R', '\020', 'p', 'o', 's', 'i', 't', 'i', 'v', 'e', 'I', 'n', 't', 
-'V', 'a', 'l', 'u', 'e', '\022', ',', '\n', '\022', 'n', 'e', 'g', 'a', 't', 'i', 'v', 'e', '_', 'i', 'n', 't', '_', 'v', 'a', 'l', 
-'u', 'e', '\030', '\005', ' ', '\001', '(', '\003', 'R', '\020', 'n', 'e', 'g', 'a', 't', 'i', 'v', 'e', 'I', 'n', 't', 'V', 'a', 'l', 'u', 
-'e', '\022', '!', '\n', '\014', 'd', 'o', 'u', 'b', 'l', 'e', '_', 'v', 'a', 'l', 'u', 'e', '\030', '\006', ' ', '\001', '(', '\001', 'R', '\013', 
-'d', 'o', 'u', 'b', 'l', 'e', 'V', 'a', 'l', 'u', 'e', '\022', '!', '\n', '\014', 's', 't', 'r', 'i', 'n', 'g', '_', 'v', 'a', 'l', 
-'u', 'e', '\030', '\007', ' ', '\001', '(', '\014', 'R', '\013', 's', 't', 'r', 'i', 'n', 'g', 'V', 'a', 'l', 'u', 'e', '\022', '\'', '\n', '\017', 
-'a', 'g', 'g', 'r', 'e', 'g', 'a', 't', 'e', '_', 'v', 'a', 'l', 'u', 'e', '\030', '\010', ' ', '\001', '(', '\t', 'R', '\016', 'a', 'g', 
-'g', 'r', 'e', 'g', 'a', 't', 'e', 'V', 'a', 'l', 'u', 'e', '\032', 'J', '\n', '\010', 'N', 'a', 'm', 'e', 'P', 'a', 'r', 't', '\022', 
-'\033', '\n', '\t', 'n', 'a', 'm', 'e', '_', 'p', 'a', 'r', 't', '\030', '\001', ' ', '\002', '(', '\t', 'R', '\010', 'n', 'a', 'm', 'e', 'P', 
-'a', 'r', 't', '\022', '!', '\n', '\014', 'i', 's', '_', 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', '\030', '\002', ' ', '\002', '(', '\010', 
-'R', '\013', 'i', 's', 'E', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', '\"', '\247', '\002', '\n', '\016', 'S', 'o', 'u', 'r', 'c', 'e', 'C', 
-'o', 'd', 'e', 'I', 'n', 'f', 'o', '\022', 'D', '\n', '\010', 'l', 'o', 'c', 'a', 't', 'i', 'o', 'n', '\030', '\001', ' ', '\003', '(', '\013', 
-'2', '(', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'S', 'o', 'u', 'r', 'c', 'e', 
-'C', 'o', 'd', 'e', 'I', 'n', 'f', 'o', '.', 'L', 'o', 'c', 'a', 't', 'i', 'o', 'n', 'R', '\010', 'l', 'o', 'c', 'a', 't', 'i', 
-'o', 'n', '\032', '\316', '\001', '\n', '\010', 'L', 'o', 'c', 'a', 't', 'i', 'o', 'n', '\022', '\026', '\n', '\004', 'p', 'a', 't', 'h', '\030', '\001', 
-' ', '\003', '(', '\005', 'B', '\002', '\020', '\001', 'R', '\004', 'p', 'a', 't', 'h', '\022', '\026', '\n', '\004', 's', 'p', 'a', 'n', '\030', '\002', ' ', 
-'\003', '(', '\005', 'B', '\002', '\020', '\001', 'R', '\004', 's', 'p', 'a', 'n', '\022', ')', '\n', '\020', 'l', 'e', 'a', 'd', 'i', 'n', 'g', '_', 
-'c', 'o', 'm', 'm', 'e', 'n', 't', 's', '\030', '\003', ' ', '\001', '(', '\t', 'R', '\017', 'l', 'e', 'a', 'd', 'i', 'n', 'g', 'C', 'o', 
-'m', 'm', 'e', 'n', 't', 's', '\022', '+', '\n', '\021', 't', 'r', 'a', 'i', 'l', 'i', 'n', 'g', '_', 'c', 'o', 'm', 'm', 'e', 'n', 
-'t', 's', '\030', '\004', ' ', '\001', '(', '\t', 'R', '\020', 't', 'r', 'a', 'i', 'l', 'i', 'n', 'g', 'C', 'o', 'm', 'm', 'e', 'n', 't', 
-'s', '\022', ':', '\n', '\031', 'l', 'e', 'a', 'd', 'i', 'n', 'g', '_', 'd', 'e', 't', 'a', 'c', 'h', 'e', 'd', '_', 'c', 'o', 'm', 
-'m', 'e', 'n', 't', 's', '\030', '\006', ' ', '\003', '(', '\t', 'R', '\027', 'l', 'e', 'a', 'd', 'i', 'n', 'g', 'D', 'e', 't', 'a', 'c', 
-'h', 'e', 'd', 'C', 'o', 'm', 'm', 'e', 'n', 't', 's', '\"', '\321', '\001', '\n', '\021', 'G', 'e', 'n', 'e', 'r', 'a', 't', 'e', 'd', 
-'C', 'o', 'd', 'e', 'I', 'n', 'f', 'o', '\022', 'M', '\n', '\n', 'a', 'n', 'n', 'o', 't', 'a', 't', 'i', 'o', 'n', '\030', '\001', ' ', 
-'\003', '(', '\013', '2', '-', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'G', 'e', 'n', 
-'e', 'r', 'a', 't', 'e', 'd', 'C', 'o', 'd', 'e', 'I', 'n', 'f', 'o', '.', 'A', 'n', 'n', 'o', 't', 'a', 't', 'i', 'o', 'n', 
-'R', '\n', 'a', 'n', 'n', 'o', 't', 'a', 't', 'i', 'o', 'n', '\032', 'm', '\n', '\n', 'A', 'n', 'n', 'o', 't', 'a', 't', 'i', 'o', 
-'n', '\022', '\026', '\n', '\004', 'p', 'a', 't', 'h', '\030', '\001', ' ', '\003', '(', '\005', 'B', '\002', '\020', '\001', 'R', '\004', 'p', 'a', 't', 'h', 
-'\022', '\037', '\n', '\013', 's', 'o', 'u', 'r', 'c', 'e', '_', 'f', 'i', 'l', 'e', '\030', '\002', ' ', '\001', '(', '\t', 'R', '\n', 's', 'o', 
-'u', 'r', 'c', 'e', 'F', 'i', 'l', 'e', '\022', '\024', '\n', '\005', 'b', 'e', 'g', 'i', 'n', '\030', '\003', ' ', '\001', '(', '\005', 'R', '\005', 
-'b', 'e', 'g', 'i', 'n', '\022', '\020', '\n', '\003', 'e', 'n', 'd', '\030', '\004', ' ', '\001', '(', '\005', 'R', '\003', 'e', 'n', 'd', 'B', '~', 
-'\n', '\023', 'c', 'o', 'm', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', 'B', '\020', 'D', 'e', 
-'s', 'c', 'r', 'i', 'p', 't', 'o', 'r', 'P', 'r', 'o', 't', 'o', 's', 'H', '\001', 'Z', '-', 'g', 'o', 'o', 'g', 'l', 'e', '.', 
-'g', 'o', 'l', 'a', 'n', 'g', '.', 'o', 'r', 'g', '/', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '/', 't', 'y', 'p', 'e', 's', 
-'/', 'd', 'e', 's', 'c', 'r', 'i', 'p', 't', 'o', 'r', 'p', 'b', '\370', '\001', '\001', '\242', '\002', '\003', 'G', 'P', 'B', '\252', '\002', '\032', 
-'G', 'o', 'o', 'g', 'l', 'e', '.', 'P', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'R', 'e', 'f', 'l', 'e', 'c', 't', 'i', 'o', 
-'n', 
+'\"', 'P', '\n', '\020', 'I', 'd', 'e', 'm', 'p', 'o', 't', 'e', 'n', 'c', 'y', 'L', 'e', 'v', 'e', 'l', '\022', '\027', '\n', '\023', 'I', 
+'D', 'E', 'M', 'P', 'O', 'T', 'E', 'N', 'C', 'Y', '_', 'U', 'N', 'K', 'N', 'O', 'W', 'N', '\020', '\000', '\022', '\023', '\n', '\017', 'N', 
+'O', '_', 'S', 'I', 'D', 'E', '_', 'E', 'F', 'F', 'E', 'C', 'T', 'S', '\020', '\001', '\022', '\016', '\n', '\n', 'I', 'D', 'E', 'M', 'P', 
+'O', 'T', 'E', 'N', 'T', '\020', '\002', '*', '\t', '\010', '\350', '\007', '\020', '\200', '\200', '\200', '\200', '\002', '\"', '\232', '\003', '\n', '\023', 'U', 'n', 
+'i', 'n', 't', 'e', 'r', 'p', 'r', 'e', 't', 'e', 'd', 'O', 'p', 't', 'i', 'o', 'n', '\022', 'A', '\n', '\004', 'n', 'a', 'm', 'e', 
+'\030', '\002', ' ', '\003', '(', '\013', '2', '-', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 
+'U', 'n', 'i', 'n', 't', 'e', 'r', 'p', 'r', 'e', 't', 'e', 'd', 'O', 'p', 't', 'i', 'o', 'n', '.', 'N', 'a', 'm', 'e', 'P', 
+'a', 'r', 't', 'R', '\004', 'n', 'a', 'm', 'e', '\022', ')', '\n', '\020', 'i', 'd', 'e', 'n', 't', 'i', 'f', 'i', 'e', 'r', '_', 'v', 
+'a', 'l', 'u', 'e', '\030', '\003', ' ', '\001', '(', '\t', 'R', '\017', 'i', 'd', 'e', 'n', 't', 'i', 'f', 'i', 'e', 'r', 'V', 'a', 'l', 
+'u', 'e', '\022', ',', '\n', '\022', 'p', 'o', 's', 'i', 't', 'i', 'v', 'e', '_', 'i', 'n', 't', '_', 'v', 'a', 'l', 'u', 'e', '\030', 
+'\004', ' ', '\001', '(', '\004', 'R', '\020', 'p', 'o', 's', 'i', 't', 'i', 'v', 'e', 'I', 'n', 't', 'V', 'a', 'l', 'u', 'e', '\022', ',', 
+'\n', '\022', 'n', 'e', 'g', 'a', 't', 'i', 'v', 'e', '_', 'i', 'n', 't', '_', 'v', 'a', 'l', 'u', 'e', '\030', '\005', ' ', '\001', '(', 
+'\003', 'R', '\020', 'n', 'e', 'g', 'a', 't', 'i', 'v', 'e', 'I', 'n', 't', 'V', 'a', 'l', 'u', 'e', '\022', '!', '\n', '\014', 'd', 'o', 
+'u', 'b', 'l', 'e', '_', 'v', 'a', 'l', 'u', 'e', '\030', '\006', ' ', '\001', '(', '\001', 'R', '\013', 'd', 'o', 'u', 'b', 'l', 'e', 'V', 
+'a', 'l', 'u', 'e', '\022', '!', '\n', '\014', 's', 't', 'r', 'i', 'n', 'g', '_', 'v', 'a', 'l', 'u', 'e', '\030', '\007', ' ', '\001', '(', 
+'\014', 'R', '\013', 's', 't', 'r', 'i', 'n', 'g', 'V', 'a', 'l', 'u', 'e', '\022', '\'', '\n', '\017', 'a', 'g', 'g', 'r', 'e', 'g', 'a', 
+'t', 'e', '_', 'v', 'a', 'l', 'u', 'e', '\030', '\010', ' ', '\001', '(', '\t', 'R', '\016', 'a', 'g', 'g', 'r', 'e', 'g', 'a', 't', 'e', 
+'V', 'a', 'l', 'u', 'e', '\032', 'J', '\n', '\010', 'N', 'a', 'm', 'e', 'P', 'a', 'r', 't', '\022', '\033', '\n', '\t', 'n', 'a', 'm', 'e', 
+'_', 'p', 'a', 'r', 't', '\030', '\001', ' ', '\002', '(', '\t', 'R', '\010', 'n', 'a', 'm', 'e', 'P', 'a', 'r', 't', '\022', '!', '\n', '\014', 
+'i', 's', '_', 'e', 'x', 't', 'e', 'n', 's', 'i', 'o', 'n', '\030', '\002', ' ', '\002', '(', '\010', 'R', '\013', 'i', 's', 'E', 'x', 't', 
+'e', 'n', 's', 'i', 'o', 'n', '\"', '\247', '\002', '\n', '\016', 'S', 'o', 'u', 'r', 'c', 'e', 'C', 'o', 'd', 'e', 'I', 'n', 'f', 'o', 
+'\022', 'D', '\n', '\010', 'l', 'o', 'c', 'a', 't', 'i', 'o', 'n', '\030', '\001', ' ', '\003', '(', '\013', '2', '(', '.', 'g', 'o', 'o', 'g', 
+'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'S', 'o', 'u', 'r', 'c', 'e', 'C', 'o', 'd', 'e', 'I', 'n', 'f', 
+'o', '.', 'L', 'o', 'c', 'a', 't', 'i', 'o', 'n', 'R', '\010', 'l', 'o', 'c', 'a', 't', 'i', 'o', 'n', '\032', '\316', '\001', '\n', '\010', 
+'L', 'o', 'c', 'a', 't', 'i', 'o', 'n', '\022', '\026', '\n', '\004', 'p', 'a', 't', 'h', '\030', '\001', ' ', '\003', '(', '\005', 'B', '\002', '\020', 
+'\001', 'R', '\004', 'p', 'a', 't', 'h', '\022', '\026', '\n', '\004', 's', 'p', 'a', 'n', '\030', '\002', ' ', '\003', '(', '\005', 'B', '\002', '\020', '\001', 
+'R', '\004', 's', 'p', 'a', 'n', '\022', ')', '\n', '\020', 'l', 'e', 'a', 'd', 'i', 'n', 'g', '_', 'c', 'o', 'm', 'm', 'e', 'n', 't', 
+'s', '\030', '\003', ' ', '\001', '(', '\t', 'R', '\017', 'l', 'e', 'a', 'd', 'i', 'n', 'g', 'C', 'o', 'm', 'm', 'e', 'n', 't', 's', '\022', 
+'+', '\n', '\021', 't', 'r', 'a', 'i', 'l', 'i', 'n', 'g', '_', 'c', 'o', 'm', 'm', 'e', 'n', 't', 's', '\030', '\004', ' ', '\001', '(', 
+'\t', 'R', '\020', 't', 'r', 'a', 'i', 'l', 'i', 'n', 'g', 'C', 'o', 'm', 'm', 'e', 'n', 't', 's', '\022', ':', '\n', '\031', 'l', 'e', 
+'a', 'd', 'i', 'n', 'g', '_', 'd', 'e', 't', 'a', 'c', 'h', 'e', 'd', '_', 'c', 'o', 'm', 'm', 'e', 'n', 't', 's', '\030', '\006', 
+' ', '\003', '(', '\t', 'R', '\027', 'l', 'e', 'a', 'd', 'i', 'n', 'g', 'D', 'e', 't', 'a', 'c', 'h', 'e', 'd', 'C', 'o', 'm', 'm', 
+'e', 'n', 't', 's', '\"', '\321', '\001', '\n', '\021', 'G', 'e', 'n', 'e', 'r', 'a', 't', 'e', 'd', 'C', 'o', 'd', 'e', 'I', 'n', 'f', 
+'o', '\022', 'M', '\n', '\n', 'a', 'n', 'n', 'o', 't', 'a', 't', 'i', 'o', 'n', '\030', '\001', ' ', '\003', '(', '\013', '2', '-', '.', 'g', 
+'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'G', 'e', 'n', 'e', 'r', 'a', 't', 'e', 'd', 'C', 
+'o', 'd', 'e', 'I', 'n', 'f', 'o', '.', 'A', 'n', 'n', 'o', 't', 'a', 't', 'i', 'o', 'n', 'R', '\n', 'a', 'n', 'n', 'o', 't', 
+'a', 't', 'i', 'o', 'n', '\032', 'm', '\n', '\n', 'A', 'n', 'n', 'o', 't', 'a', 't', 'i', 'o', 'n', '\022', '\026', '\n', '\004', 'p', 'a', 
+'t', 'h', '\030', '\001', ' ', '\003', '(', '\005', 'B', '\002', '\020', '\001', 'R', '\004', 'p', 'a', 't', 'h', '\022', '\037', '\n', '\013', 's', 'o', 'u', 
+'r', 'c', 'e', '_', 'f', 'i', 'l', 'e', '\030', '\002', ' ', '\001', '(', '\t', 'R', '\n', 's', 'o', 'u', 'r', 'c', 'e', 'F', 'i', 'l', 
+'e', '\022', '\024', '\n', '\005', 'b', 'e', 'g', 'i', 'n', '\030', '\003', ' ', '\001', '(', '\005', 'R', '\005', 'b', 'e', 'g', 'i', 'n', '\022', '\020', 
+'\n', '\003', 'e', 'n', 'd', '\030', '\004', ' ', '\001', '(', '\005', 'R', '\003', 'e', 'n', 'd', 'B', '~', '\n', '\023', 'c', 'o', 'm', '.', 'g', 
+'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', 'B', '\020', 'D', 'e', 's', 'c', 'r', 'i', 'p', 't', 'o', 
+'r', 'P', 'r', 'o', 't', 'o', 's', 'H', '\001', 'Z', '-', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'g', 'o', 'l', 'a', 'n', 'g', '.', 
+'o', 'r', 'g', '/', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '/', 't', 'y', 'p', 'e', 's', '/', 'd', 'e', 's', 'c', 'r', 'i', 
+'p', 't', 'o', 'r', 'p', 'b', '\370', '\001', '\001', '\242', '\002', '\003', 'G', 'P', 'B', '\252', '\002', '\032', 'G', 'o', 'o', 'g', 'l', 'e', '.', 
+'P', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'R', 'e', 'f', 'l', 'e', 'c', 't', 'i', 'o', 'n', 
 };
 
 static upb_def_init *deps[1] = {
@@ -382,5 +382,5 @@ upb_def_init google_protobuf_descriptor_proto_upbdefinit = {
   deps,
   layouts,
   "google/protobuf/descriptor.proto",
-  UPB_STRVIEW_INIT(descriptor, 7601)
+  UPB_STRVIEW_INIT(descriptor, 7619)
 };
index 0d7950d..2b1780c 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include "absl/container/inlined_vector.h"
-
 #include "src/core/ext/xds/certificate_provider_registry.h"
 
+#include "absl/container/inlined_vector.h"
+
 namespace grpc_core {
 
 namespace {
index 759e563..c321a92 100644 (file)
@@ -18,6 +18,8 @@
 
 #include <grpc/support/port_platform.h>
 
+#include "src/core/ext/xds/xds_api.h"
+
 #include <algorithm>
 #include <cctype>
 #include <cstdint>
@@ -89,7 +91,6 @@
 #include <grpc/support/alloc.h>
 #include <grpc/support/string_util.h>
 
-#include "src/core/ext/xds/xds_api.h"
 #include "src/core/lib/address_utils/sockaddr_utils.h"
 #include "src/core/lib/gpr/env.h"
 #include "src/core/lib/gpr/string.h"
@@ -115,17 +116,6 @@ bool XdsAggregateAndLogicalDnsClusterEnabled() {
   return parse_succeeded && parsed_value;
 }
 
-// TODO(yashykt): Check to see if xDS security is enabled. This will be
-// removed once this feature is fully integration-tested and enabled by
-// default.
-bool XdsSecurityEnabled() {
-  char* value = gpr_getenv("GRPC_XDS_EXPERIMENTAL_SECURITY_SUPPORT");
-  bool parsed_value;
-  bool parse_succeeded = gpr_parse_bool_value(value, &parsed_value);
-  gpr_free(value);
-  return parse_succeeded && parsed_value;
-}
-
 //
 // XdsApi::Route::HashPolicy
 //
@@ -437,11 +427,11 @@ bool XdsApi::CommonTlsContext::CertificateValidationContext::Empty() const {
 }
 
 //
-// XdsApi::CommonTlsContext::CertificateValidationContext
+// XdsApi::CommonTlsContext::CertificateProviderPluginInstance
 //
 
-std::string XdsApi::CommonTlsContext::CertificateProviderInstance::ToString()
-    const {
+std::string
+XdsApi::CommonTlsContext::CertificateProviderPluginInstance::ToString() const {
   absl::InlinedVector<std::string, 2> contents;
   if (!instance_name.empty()) {
     contents.push_back(absl::StrFormat("instance_name=%s", instance_name));
@@ -453,34 +443,9 @@ std::string XdsApi::CommonTlsContext::CertificateProviderInstance::ToString()
   return absl::StrCat("{", absl::StrJoin(contents, ", "), "}");
 }
 
-bool XdsApi::CommonTlsContext::CertificateProviderInstance::Empty() const {
-  return instance_name.empty() && certificate_name.empty();
-}
-
-//
-// XdsApi::CommonTlsContext::CombinedCertificateValidationContext
-//
-
-std::string
-XdsApi::CommonTlsContext::CombinedCertificateValidationContext::ToString()
+bool XdsApi::CommonTlsContext::CertificateProviderPluginInstance::Empty()
     const {
-  absl::InlinedVector<std::string, 2> contents;
-  if (!default_validation_context.Empty()) {
-    contents.push_back(absl::StrFormat("default_validation_context=%s",
-                                       default_validation_context.ToString()));
-  }
-  if (!validation_context_certificate_provider_instance.Empty()) {
-    contents.push_back(absl::StrFormat(
-        "validation_context_certificate_provider_instance=%s",
-        validation_context_certificate_provider_instance.ToString()));
-  }
-  return absl::StrCat("{", absl::StrJoin(contents, ", "), "}");
-}
-
-bool XdsApi::CommonTlsContext::CombinedCertificateValidationContext::Empty()
-    const {
-  return default_validation_context.Empty() &&
-         validation_context_certificate_provider_instance.Empty();
+  return instance_name.empty() && certificate_name.empty();
 }
 
 //
@@ -489,21 +454,22 @@ bool XdsApi::CommonTlsContext::CombinedCertificateValidationContext::Empty()
 
 std::string XdsApi::CommonTlsContext::ToString() const {
   absl::InlinedVector<std::string, 2> contents;
-  if (!tls_certificate_certificate_provider_instance.Empty()) {
-    contents.push_back(absl::StrFormat(
-        "tls_certificate_certificate_provider_instance=%s",
-        tls_certificate_certificate_provider_instance.ToString()));
+  if (!tls_certificate_provider_instance.Empty()) {
+    contents.push_back(
+        absl::StrFormat("tls_certificate_provider_instance=%s",
+                        tls_certificate_provider_instance.ToString()));
   }
-  if (!combined_validation_context.Empty()) {
-    contents.push_back(absl::StrFormat("combined_validation_context=%s",
-                                       combined_validation_context.ToString()));
+  if (!certificate_validation_context.Empty()) {
+    contents.push_back(
+        absl::StrFormat("certificate_validation_context=%s",
+                        certificate_validation_context.ToString()));
   }
   return absl::StrCat("{", absl::StrJoin(contents, ", "), "}");
 }
 
 bool XdsApi::CommonTlsContext::Empty() const {
-  return tls_certificate_certificate_provider_instance.Empty() &&
-         combined_validation_context.Empty();
+  return tls_certificate_provider_instance.Empty() &&
+         certificate_validation_context.Empty();
 }
 
 //
@@ -847,15 +813,15 @@ bool IsLds(absl::string_view type_url, bool* is_v2 = nullptr) {
   return false;
 }
 
-bool IsRds(absl::string_view type_url) {
+bool IsRds(absl::string_view type_url, bool* /*is_v2*/ = nullptr) {
   return type_url == XdsApi::kRdsTypeUrl || type_url == kRdsV2TypeUrl;
 }
 
-bool IsCds(absl::string_view type_url) {
+bool IsCds(absl::string_view type_url, bool* /*is_v2*/ = nullptr) {
   return type_url == XdsApi::kCdsTypeUrl || type_url == kCdsV2TypeUrl;
 }
 
-bool IsEds(absl::string_view type_url) {
+bool IsEds(absl::string_view type_url, bool* /*is_v2*/ = nullptr) {
   return type_url == XdsApi::kEdsTypeUrl || type_url == kEdsV2TypeUrl;
 }
 
@@ -1207,6 +1173,18 @@ void MaybeLogDiscoveryResponse(
   }
 }
 
+void MaybeLogListener(const EncodingContext& context,
+                      const envoy_config_listener_v3_Listener* listener) {
+  if (GRPC_TRACE_FLAG_ENABLED(*context.tracer) &&
+      gpr_should_log(GPR_LOG_SEVERITY_DEBUG)) {
+    const upb_msgdef* msg_type =
+        envoy_config_listener_v3_Listener_getmsgdef(context.symtab);
+    char buf[10240];
+    upb_text_encode(listener, msg_type, nullptr, 0, buf, sizeof(buf));
+    gpr_log(GPR_DEBUG, "[xds_client %p] Listener: %s", context.client, buf);
+  }
+}
+
 void MaybeLogHttpConnectionManager(
     const EncodingContext& context,
     const envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager*
@@ -1350,10 +1328,8 @@ grpc_error_handle RoutePathMatchParse(
   absl::StatusOr<StringMatcher> string_matcher =
       StringMatcher::Create(type, match_string, case_sensitive);
   if (!string_matcher.ok()) {
-    return GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-        absl::StrCat("path matcher: ", string_matcher.status().message())
-            .c_str());
-    ;
+    return GRPC_ERROR_CREATE_FROM_CPP_STRING(
+        absl::StrCat("path matcher: ", string_matcher.status().message()));
   }
   route->matchers.path_matcher = std::move(string_matcher.value());
   return GRPC_ERROR_NONE;
@@ -1416,9 +1392,8 @@ grpc_error_handle RouteHeaderMatchersParse(
         HeaderMatcher::Create(name, type, match_string, range_start, range_end,
                               present_match, invert_match);
     if (!header_matcher.ok()) {
-      return GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-          absl::StrCat("header matcher: ", header_matcher.status().message())
-              .c_str());
+      return GRPC_ERROR_CREATE_FROM_CPP_STRING(
+          absl::StrCat("header matcher: ", header_matcher.status().message()));
     }
     route->matchers.header_matchers.emplace_back(
         std::move(header_matcher.value()));
@@ -1498,9 +1473,8 @@ grpc_error_handle ParseTypedPerFilterConfig(
     absl::string_view filter_type =
         UpbStringToAbsl(google_protobuf_Any_type_url(any));
     if (filter_type.empty()) {
-      return GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-          absl::StrCat("no filter config specified for filter name ", key)
-              .c_str());
+      return GRPC_ERROR_CREATE_FROM_CPP_STRING(
+          absl::StrCat("no filter config specified for filter name ", key));
     }
     bool is_optional = false;
     if (filter_type ==
@@ -1509,18 +1483,16 @@ grpc_error_handle ParseTypedPerFilterConfig(
       const auto* filter_config = envoy_config_route_v3_FilterConfig_parse(
           any_value.data, any_value.size, context.arena);
       if (filter_config == nullptr) {
-        return GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-            absl::StrCat("could not parse FilterConfig wrapper for ", key)
-                .c_str());
+        return GRPC_ERROR_CREATE_FROM_CPP_STRING(
+            absl::StrCat("could not parse FilterConfig wrapper for ", key));
       }
       is_optional =
           envoy_config_route_v3_FilterConfig_is_optional(filter_config);
       any = envoy_config_route_v3_FilterConfig_config(filter_config);
       if (any == nullptr) {
         if (is_optional) continue;
-        return GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-            absl::StrCat("no filter config specified for filter name ", key)
-                .c_str());
+        return GRPC_ERROR_CREATE_FROM_CPP_STRING(
+            absl::StrCat("no filter config specified for filter name ", key));
       }
     }
     grpc_error_handle error =
@@ -1530,18 +1502,16 @@ grpc_error_handle ParseTypedPerFilterConfig(
         XdsHttpFilterRegistry::GetFilterForType(filter_type);
     if (filter_impl == nullptr) {
       if (is_optional) continue;
-      return GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-          absl::StrCat("no filter registered for config type ", filter_type)
-              .c_str());
+      return GRPC_ERROR_CREATE_FROM_CPP_STRING(
+          absl::StrCat("no filter registered for config type ", filter_type));
     }
     absl::StatusOr<XdsHttpFilterImpl::FilterConfig> filter_config =
         filter_impl->GenerateFilterConfigOverride(
             google_protobuf_Any_value(any), context.arena);
     if (!filter_config.ok()) {
-      return GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-          absl::StrCat("filter config for type ", filter_type,
-                       " failed to parse: ", filter_config.status().ToString())
-              .c_str());
+      return GRPC_ERROR_CREATE_FROM_CPP_STRING(absl::StrCat(
+          "filter config for type ", filter_type,
+          " failed to parse: ", filter_config.status().ToString()));
     }
     (*typed_per_filter_config)[std::string(key)] = std::move(*filter_config);
   }
@@ -1591,7 +1561,7 @@ grpc_error_handle RetryPolicyParse(
   if (num_retries != nullptr) {
     uint32_t num_retries_value = google_protobuf_UInt32Value_value(num_retries);
     if (num_retries_value == 0) {
-      errors.push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
+      errors.push_back(GRPC_ERROR_CREATE_FROM_STATIC_STRING(
           "RouteAction RetryPolicy num_retries set to invalid value 0."));
     } else {
       retry_to_return.num_retries = num_retries_value;
@@ -1605,7 +1575,7 @@ grpc_error_handle RetryPolicyParse(
     const google_protobuf_Duration* base_interval =
         envoy_config_route_v3_RetryPolicy_RetryBackOff_base_interval(backoff);
     if (base_interval == nullptr) {
-      errors.push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
+      errors.push_back(GRPC_ERROR_CREATE_FROM_STATIC_STRING(
           "RouteAction RetryPolicy RetryBackoff missing base interval."));
     } else {
       retry_to_return.retry_back_off.base_interval =
@@ -1828,7 +1798,7 @@ grpc_error_handle RouteActionParse(const EncodingContext& context,
 grpc_error_handle RouteConfigParse(
     const EncodingContext& context,
     const envoy_config_route_v3_RouteConfiguration* route_config,
-    XdsApi::RdsUpdate* rds_update) {
+    bool /*is_v2*/, XdsApi::RdsUpdate* rds_update) {
   MaybeLogRouteConfiguration(context, route_config);
   // Get the virtual hosts.
   size_t num_virtual_hosts;
@@ -1846,9 +1816,8 @@ grpc_error_handle RouteConfigParse(
       std::string domain_pattern = UpbStringToStdString(domains[j]);
       const MatchType match_type = DomainPatternMatchType(domain_pattern);
       if (match_type == INVALID_MATCH) {
-        return GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-            absl::StrCat("Invalid domain pattern \"", domain_pattern, "\".")
-                .c_str());
+        return GRPC_ERROR_CREATE_FROM_CPP_STRING(
+            absl::StrCat("Invalid domain pattern \"", domain_pattern, "\"."));
       }
       vhost.domains.emplace_back(std::move(domain_pattern));
     }
@@ -1933,13 +1902,18 @@ grpc_error_handle RouteConfigParse(
   return GRPC_ERROR_NONE;
 }
 
+// CertificateProviderInstance is deprecated but we are still supporting it for
+// backward compatibility reasons. Note that we still parse the data into the
+// same CertificateProviderPluginInstance struct since the fields are the same.
+// TODO(yashykt): Remove this once we stop supporting the old way of fetching
+// certificate provider instances.
 grpc_error_handle CertificateProviderInstanceParse(
     const EncodingContext& context,
     const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProviderInstance*
         certificate_provider_instance_proto,
-    XdsApi::CommonTlsContext::CertificateProviderInstance*
-        certificate_provider_instance) {
-  *certificate_provider_instance = {
+    XdsApi::CommonTlsContext::CertificateProviderPluginInstance*
+        certificate_provider_plugin_instance) {
+  *certificate_provider_plugin_instance = {
       UpbStringToStdString(
           envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProviderInstance_instance_name(
               certificate_provider_instance_proto)),
@@ -1947,21 +1921,157 @@ grpc_error_handle CertificateProviderInstanceParse(
           envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CertificateProviderInstance_certificate_name(
               certificate_provider_instance_proto))};
   if (context.certificate_provider_definition_map->find(
-          certificate_provider_instance->instance_name) ==
+          certificate_provider_plugin_instance->instance_name) ==
       context.certificate_provider_definition_map->end()) {
-    return GRPC_ERROR_CREATE_FROM_COPIED_STRING(
+    return GRPC_ERROR_CREATE_FROM_CPP_STRING(
         absl::StrCat("Unrecognized certificate provider instance name: ",
-                     certificate_provider_instance->instance_name)
-            .c_str());
+                     certificate_provider_plugin_instance->instance_name));
   }
   return GRPC_ERROR_NONE;
 }
 
+grpc_error_handle CertificateProviderPluginInstanceParse(
+    const EncodingContext& context,
+    const envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance*
+        certificate_provider_plugin_instance_proto,
+    XdsApi::CommonTlsContext::CertificateProviderPluginInstance*
+        certificate_provider_plugin_instance) {
+  *certificate_provider_plugin_instance = {
+      UpbStringToStdString(
+          envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance_instance_name(
+              certificate_provider_plugin_instance_proto)),
+      UpbStringToStdString(
+          envoy_extensions_transport_sockets_tls_v3_CertificateProviderPluginInstance_certificate_name(
+              certificate_provider_plugin_instance_proto))};
+  if (context.certificate_provider_definition_map->find(
+          certificate_provider_plugin_instance->instance_name) ==
+      context.certificate_provider_definition_map->end()) {
+    return GRPC_ERROR_CREATE_FROM_CPP_STRING(
+        absl::StrCat("Unrecognized certificate provider instance name: ",
+                     certificate_provider_plugin_instance->instance_name));
+  }
+  return GRPC_ERROR_NONE;
+}
+
+grpc_error_handle CertificateValidationContextParse(
+    const EncodingContext& context,
+    const envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext*
+        certificate_validation_context_proto,
+    XdsApi::CommonTlsContext::CertificateValidationContext*
+        certificate_validation_context) {
+  std::vector<grpc_error_handle> errors;
+  size_t len = 0;
+  auto* subject_alt_names_matchers =
+      envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_match_subject_alt_names(
+          certificate_validation_context_proto, &len);
+  for (size_t i = 0; i < len; ++i) {
+    StringMatcher::Type type;
+    std::string matcher;
+    if (envoy_type_matcher_v3_StringMatcher_has_exact(
+            subject_alt_names_matchers[i])) {
+      type = StringMatcher::Type::kExact;
+      matcher = UpbStringToStdString(envoy_type_matcher_v3_StringMatcher_exact(
+          subject_alt_names_matchers[i]));
+    } else if (envoy_type_matcher_v3_StringMatcher_has_prefix(
+                   subject_alt_names_matchers[i])) {
+      type = StringMatcher::Type::kPrefix;
+      matcher = UpbStringToStdString(envoy_type_matcher_v3_StringMatcher_prefix(
+          subject_alt_names_matchers[i]));
+    } else if (envoy_type_matcher_v3_StringMatcher_has_suffix(
+                   subject_alt_names_matchers[i])) {
+      type = StringMatcher::Type::kSuffix;
+      matcher = UpbStringToStdString(envoy_type_matcher_v3_StringMatcher_suffix(
+          subject_alt_names_matchers[i]));
+    } else if (envoy_type_matcher_v3_StringMatcher_has_contains(
+                   subject_alt_names_matchers[i])) {
+      type = StringMatcher::Type::kContains;
+      matcher =
+          UpbStringToStdString(envoy_type_matcher_v3_StringMatcher_contains(
+              subject_alt_names_matchers[i]));
+    } else if (envoy_type_matcher_v3_StringMatcher_has_safe_regex(
+                   subject_alt_names_matchers[i])) {
+      type = StringMatcher::Type::kSafeRegex;
+      auto* regex_matcher = envoy_type_matcher_v3_StringMatcher_safe_regex(
+          subject_alt_names_matchers[i]);
+      matcher = UpbStringToStdString(
+          envoy_type_matcher_v3_RegexMatcher_regex(regex_matcher));
+    } else {
+      errors.push_back(GRPC_ERROR_CREATE_FROM_STATIC_STRING(
+          "Invalid StringMatcher specified"));
+      continue;
+    }
+    bool ignore_case = envoy_type_matcher_v3_StringMatcher_ignore_case(
+        subject_alt_names_matchers[i]);
+    absl::StatusOr<StringMatcher> string_matcher =
+        StringMatcher::Create(type, matcher,
+                              /*case_sensitive=*/!ignore_case);
+    if (!string_matcher.ok()) {
+      errors.push_back(GRPC_ERROR_CREATE_FROM_CPP_STRING(
+          absl::StrCat("string matcher: ", string_matcher.status().message())));
+      continue;
+    }
+    if (type == StringMatcher::Type::kSafeRegex && ignore_case) {
+      errors.push_back(GRPC_ERROR_CREATE_FROM_STATIC_STRING(
+          "StringMatcher: ignore_case has no effect for SAFE_REGEX."));
+      continue;
+    }
+    certificate_validation_context->match_subject_alt_names.push_back(
+        std::move(string_matcher.value()));
+  }
+  auto* ca_certificate_provider_instance =
+      envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_ca_certificate_provider_instance(
+          certificate_validation_context_proto);
+  if (ca_certificate_provider_instance != nullptr) {
+    grpc_error_handle error = CertificateProviderPluginInstanceParse(
+        context, ca_certificate_provider_instance,
+        &certificate_validation_context->ca_certificate_provider_instance);
+    if (error != GRPC_ERROR_NONE) errors.push_back(error);
+  }
+  if (envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_verify_certificate_spki(
+          certificate_validation_context_proto, nullptr) != nullptr) {
+    errors.push_back(GRPC_ERROR_CREATE_FROM_STATIC_STRING(
+        "CertificateValidationContext: verify_certificate_spki "
+        "unsupported"));
+  }
+  if (envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_verify_certificate_hash(
+          certificate_validation_context_proto, nullptr) != nullptr) {
+    errors.push_back(GRPC_ERROR_CREATE_FROM_STATIC_STRING(
+        "CertificateValidationContext: verify_certificate_hash "
+        "unsupported"));
+  }
+  auto* require_signed_certificate_timestamp =
+      envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_require_signed_certificate_timestamp(
+          certificate_validation_context_proto);
+  if (require_signed_certificate_timestamp != nullptr &&
+      google_protobuf_BoolValue_value(require_signed_certificate_timestamp)) {
+    errors.push_back(GRPC_ERROR_CREATE_FROM_STATIC_STRING(
+        "CertificateValidationContext: "
+        "require_signed_certificate_timestamp unsupported"));
+  }
+  if (envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_has_crl(
+          certificate_validation_context_proto)) {
+    errors.push_back(GRPC_ERROR_CREATE_FROM_STATIC_STRING(
+        "CertificateValidationContext: crl unsupported"));
+  }
+  if (envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_has_custom_validator_config(
+          certificate_validation_context_proto)) {
+    errors.push_back(GRPC_ERROR_CREATE_FROM_STATIC_STRING(
+        "CertificateValidationContext: custom_validator_config "
+        "unsupported"));
+  }
+  return GRPC_ERROR_CREATE_FROM_VECTOR(
+      "Error parsing CertificateValidationContext", &errors);
+}
+
 grpc_error_handle CommonTlsContextParse(
     const EncodingContext& context,
     const envoy_extensions_transport_sockets_tls_v3_CommonTlsContext*
         common_tls_context_proto,
     XdsApi::CommonTlsContext* common_tls_context) {
+  std::vector<grpc_error_handle> errors;
+  // The validation context is derived from the oneof in
+  // 'validation_context_type'. 'validation_context_sds_secret_config' is not
+  // supported.
   auto* combined_validation_context =
       envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_combined_validation_context(
           common_tls_context_proto);
@@ -1970,89 +2080,92 @@ grpc_error_handle CommonTlsContextParse(
         envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CombinedCertificateValidationContext_default_validation_context(
             combined_validation_context);
     if (default_validation_context != nullptr) {
-      size_t len = 0;
-      auto* subject_alt_names_matchers =
-          envoy_extensions_transport_sockets_tls_v3_CertificateValidationContext_match_subject_alt_names(
-              default_validation_context, &len);
-      for (size_t i = 0; i < len; ++i) {
-        StringMatcher::Type type;
-        std::string matcher;
-        if (envoy_type_matcher_v3_StringMatcher_has_exact(
-                subject_alt_names_matchers[i])) {
-          type = StringMatcher::Type::kExact;
-          matcher =
-              UpbStringToStdString(envoy_type_matcher_v3_StringMatcher_exact(
-                  subject_alt_names_matchers[i]));
-        } else if (envoy_type_matcher_v3_StringMatcher_has_prefix(
-                       subject_alt_names_matchers[i])) {
-          type = StringMatcher::Type::kPrefix;
-          matcher =
-              UpbStringToStdString(envoy_type_matcher_v3_StringMatcher_prefix(
-                  subject_alt_names_matchers[i]));
-        } else if (envoy_type_matcher_v3_StringMatcher_has_suffix(
-                       subject_alt_names_matchers[i])) {
-          type = StringMatcher::Type::kSuffix;
-          matcher =
-              UpbStringToStdString(envoy_type_matcher_v3_StringMatcher_suffix(
-                  subject_alt_names_matchers[i]));
-        } else if (envoy_type_matcher_v3_StringMatcher_has_contains(
-                       subject_alt_names_matchers[i])) {
-          type = StringMatcher::Type::kContains;
-          matcher =
-              UpbStringToStdString(envoy_type_matcher_v3_StringMatcher_contains(
-                  subject_alt_names_matchers[i]));
-        } else if (envoy_type_matcher_v3_StringMatcher_has_safe_regex(
-                       subject_alt_names_matchers[i])) {
-          type = StringMatcher::Type::kSafeRegex;
-          auto* regex_matcher = envoy_type_matcher_v3_StringMatcher_safe_regex(
-              subject_alt_names_matchers[i]);
-          matcher = UpbStringToStdString(
-              envoy_type_matcher_v3_RegexMatcher_regex(regex_matcher));
-        } else {
-          return GRPC_ERROR_CREATE_FROM_STATIC_STRING(
-              "Invalid StringMatcher specified");
-        }
-        bool ignore_case = envoy_type_matcher_v3_StringMatcher_ignore_case(
-            subject_alt_names_matchers[i]);
-        absl::StatusOr<StringMatcher> string_matcher =
-            StringMatcher::Create(type, matcher,
-                                  /*case_sensitive=*/!ignore_case);
-        if (!string_matcher.ok()) {
-          return GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-              absl::StrCat("string matcher: ",
-                           string_matcher.status().message())
-                  .c_str());
-        }
-        if (type == StringMatcher::Type::kSafeRegex && ignore_case) {
-          return GRPC_ERROR_CREATE_FROM_STATIC_STRING(
-              "StringMatcher: ignore_case has no effect for SAFE_REGEX.");
-        }
-        common_tls_context->combined_validation_context
-            .default_validation_context.match_subject_alt_names.push_back(
-                std::move(string_matcher.value()));
-      }
-    }
+      grpc_error_handle error = CertificateValidationContextParse(
+          context, default_validation_context,
+          &common_tls_context->certificate_validation_context);
+      if (error != GRPC_ERROR_NONE) errors.push_back(error);
+    }
+    // If after parsing default_validation_context,
+    // common_tls_context->certificate_validation_context.ca_certificate_provider_instance
+    // is empty, fall back onto
+    // 'validation_context_certificate_provider_instance' inside
+    // 'combined_validation_context'. Note that this way of fetching root
+    // certificates is deprecated and will be removed in the future.
+    // TODO(yashykt): Remove this once it's no longer needed.
     auto* validation_context_certificate_provider_instance =
         envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_CombinedCertificateValidationContext_validation_context_certificate_provider_instance(
             combined_validation_context);
-    if (validation_context_certificate_provider_instance != nullptr) {
+    if (common_tls_context->certificate_validation_context
+            .ca_certificate_provider_instance.Empty() &&
+        validation_context_certificate_provider_instance != nullptr) {
       grpc_error_handle error = CertificateProviderInstanceParse(
           context, validation_context_certificate_provider_instance,
-          &common_tls_context->combined_validation_context
-               .validation_context_certificate_provider_instance);
-      if (error != GRPC_ERROR_NONE) return error;
+          &common_tls_context->certificate_validation_context
+               .ca_certificate_provider_instance);
+      if (error != GRPC_ERROR_NONE) errors.push_back(error);
     }
-  }
-  auto* tls_certificate_certificate_provider_instance =
-      envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_tls_certificate_certificate_provider_instance(
+  } else {
+    auto* validation_context =
+        envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_validation_context(
+            common_tls_context_proto);
+    if (validation_context != nullptr) {
+      grpc_error_handle error = CertificateValidationContextParse(
+          context, validation_context,
+          &common_tls_context->certificate_validation_context);
+      if (error != GRPC_ERROR_NONE) errors.push_back(error);
+    } else if (
+        envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_has_validation_context_sds_secret_config(
+            common_tls_context_proto)) {
+      errors.push_back(GRPC_ERROR_CREATE_FROM_STATIC_STRING(
+          "validation_context_sds_secret_config unsupported"));
+    }
+  }
+  auto* tls_certificate_provider_instance =
+      envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_tls_certificate_provider_instance(
           common_tls_context_proto);
-  if (tls_certificate_certificate_provider_instance != nullptr) {
-    grpc_error_handle error = CertificateProviderInstanceParse(
-        context, tls_certificate_certificate_provider_instance,
-        &common_tls_context->tls_certificate_certificate_provider_instance);
-    if (error != GRPC_ERROR_NONE) return error;
+  if (tls_certificate_provider_instance != nullptr) {
+    grpc_error_handle error = CertificateProviderPluginInstanceParse(
+        context, tls_certificate_provider_instance,
+        &common_tls_context->tls_certificate_provider_instance);
+    if (error != GRPC_ERROR_NONE) errors.push_back(error);
+  } else {
+    // Fall back onto 'tls_certificate_certificate_provider_instance'. Note that
+    // this way of fetching identity certificates is deprecated and will be
+    // removed in the future.
+    // TODO(yashykt): Remove this once it's no longer needed.
+    auto* tls_certificate_certificate_provider_instance =
+        envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_tls_certificate_certificate_provider_instance(
+            common_tls_context_proto);
+    if (tls_certificate_certificate_provider_instance != nullptr) {
+      grpc_error_handle error = CertificateProviderInstanceParse(
+          context, tls_certificate_certificate_provider_instance,
+          &common_tls_context->tls_certificate_provider_instance);
+      if (error != GRPC_ERROR_NONE) errors.push_back(error);
+    } else {
+      if (envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_has_tls_certificates(
+              common_tls_context_proto)) {
+        errors.push_back(GRPC_ERROR_CREATE_FROM_STATIC_STRING(
+            "tls_certificates unsupported"));
+      }
+      if (envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_has_tls_certificate_sds_secret_configs(
+              common_tls_context_proto)) {
+        errors.push_back(GRPC_ERROR_CREATE_FROM_STATIC_STRING(
+            "tls_certificate_sds_secret_configs unsupported"));
+      }
+    }
   }
-  return GRPC_ERROR_NONE;
+  if (envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_has_tls_params(
+          common_tls_context_proto)) {
+    errors.push_back(
+        GRPC_ERROR_CREATE_FROM_STATIC_STRING("tls_params unsupported"));
+  }
+  if (envoy_extensions_transport_sockets_tls_v3_CommonTlsContext_has_custom_handshaker(
+          common_tls_context_proto)) {
+    errors.push_back(
+        GRPC_ERROR_CREATE_FROM_STATIC_STRING("custom_handshaker unsupported"));
+  }
+  return GRPC_ERROR_CREATE_FROM_VECTOR("Error parsing CommonTlsContext",
+                                       &errors);
 }
 
 grpc_error_handle HttpConnectionManagerParse(
@@ -2087,12 +2200,12 @@ grpc_error_handle HttpConnectionManagerParse(
           envoy_extensions_filters_network_http_connection_manager_v3_HttpFilter_name(
               http_filter));
       if (name.empty()) {
-        return GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-            absl::StrCat("empty filter name at index ", i).c_str());
+        return GRPC_ERROR_CREATE_FROM_CPP_STRING(
+            absl::StrCat("empty filter name at index ", i));
       }
       if (names_seen.find(name) != names_seen.end()) {
-        return GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-            absl::StrCat("duplicate HTTP filter name: ", name).c_str());
+        return GRPC_ERROR_CREATE_FROM_CPP_STRING(
+            absl::StrCat("duplicate HTTP filter name: ", name));
       }
       names_seen.insert(name);
       const bool is_optional =
@@ -2103,9 +2216,8 @@ grpc_error_handle HttpConnectionManagerParse(
               http_filter);
       if (any == nullptr) {
         if (is_optional) continue;
-        return GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-            absl::StrCat("no filter config specified for filter name ", name)
-                .c_str());
+        return GRPC_ERROR_CREATE_FROM_CPP_STRING(
+            absl::StrCat("no filter config specified for filter name ", name));
       }
       absl::string_view filter_type;
       grpc_error_handle error =
@@ -2115,44 +2227,38 @@ grpc_error_handle HttpConnectionManagerParse(
           XdsHttpFilterRegistry::GetFilterForType(filter_type);
       if (filter_impl == nullptr) {
         if (is_optional) continue;
-        return GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-            absl::StrCat("no filter registered for config type ", filter_type)
-                .c_str());
+        return GRPC_ERROR_CREATE_FROM_CPP_STRING(
+            absl::StrCat("no filter registered for config type ", filter_type));
       }
       if ((is_client && !filter_impl->IsSupportedOnClients()) ||
           (!is_client && !filter_impl->IsSupportedOnServers())) {
         if (is_optional) continue;
-        return GRPC_ERROR_CREATE_FROM_COPIED_STRING(
+        return GRPC_ERROR_CREATE_FROM_CPP_STRING(
             absl::StrFormat("Filter %s is not supported on %s", filter_type,
-                            is_client ? "clients" : "servers")
-                .c_str());
+                            is_client ? "clients" : "servers"));
       }
       if (i < num_filters - 1) {
         // Filters before the last filter must not be terminal.
         if (filter_impl->IsTerminalFilter()) {
-          return GRPC_ERROR_CREATE_FROM_COPIED_STRING(
+          return GRPC_ERROR_CREATE_FROM_CPP_STRING(
               absl::StrCat("terminal filter for config type ", filter_type,
-                           " must be the last filter in the chain")
-                  .c_str());
+                           " must be the last filter in the chain"));
         }
       } else {
         // The last filter must be terminal.
         if (!filter_impl->IsTerminalFilter()) {
-          return GRPC_ERROR_CREATE_FROM_COPIED_STRING(
+          return GRPC_ERROR_CREATE_FROM_CPP_STRING(
               absl::StrCat("non-terminal filter for config type ", filter_type,
-                           " is the last filter in the chain")
-                  .c_str());
+                           " is the last filter in the chain"));
         }
       }
       absl::StatusOr<XdsHttpFilterImpl::FilterConfig> filter_config =
           filter_impl->GenerateFilterConfig(google_protobuf_Any_value(any),
                                             context.arena);
       if (!filter_config.ok()) {
-        return GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-            absl::StrCat(
-                "filter config for type ", filter_type,
-                " failed to parse: ", filter_config.status().ToString())
-                .c_str());
+        return GRPC_ERROR_CREATE_FROM_CPP_STRING(absl::StrCat(
+            "filter config for type ", filter_type,
+            " failed to parse: ", filter_config.status().ToString()));
       }
       http_connection_manager->http_filters.emplace_back(
           XdsApi::LdsUpdate::HttpConnectionManager::HttpFilter{
@@ -2176,7 +2282,7 @@ grpc_error_handle HttpConnectionManagerParse(
               http_connection_manager_proto);
       XdsApi::RdsUpdate rds_update;
       grpc_error_handle error =
-          RouteConfigParse(context, route_config, &rds_update);
+          RouteConfigParse(context, route_config, is_v2, &rds_update);
       if (error != GRPC_ERROR_NONE) return error;
       http_connection_manager->rds_update = std::move(rds_update);
       return GRPC_ERROR_NONE;
@@ -2209,7 +2315,7 @@ grpc_error_handle HttpConnectionManagerParse(
   return GRPC_ERROR_NONE;
 }
 
-grpc_error_handle LdsResponseParseClient(
+grpc_error_handle LdsResourceParseClient(
     const EncodingContext& context,
     const envoy_config_listener_v3_ApiListener* api_listener, bool is_v2,
     XdsApi::LdsUpdate* lds_update) {
@@ -2235,11 +2341,12 @@ grpc_error_handle DownstreamTlsContextParse(
   absl::string_view name = UpbStringToAbsl(
       envoy_config_core_v3_TransportSocket_name(transport_socket));
   if (name != "envoy.transport_sockets.tls") {
-    return GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-        absl::StrCat("Unrecognized transport socket: ", name).c_str());
+    return GRPC_ERROR_CREATE_FROM_CPP_STRING(
+        absl::StrCat("Unrecognized transport socket: ", name));
   }
   auto* typed_config =
       envoy_config_core_v3_TransportSocket_typed_config(transport_socket);
+  std::vector<grpc_error_handle> errors;
   if (typed_config != nullptr) {
     const upb_strview encoded_downstream_tls_context =
         google_protobuf_Any_value(typed_config);
@@ -2258,7 +2365,7 @@ grpc_error_handle DownstreamTlsContextParse(
       grpc_error_handle error =
           CommonTlsContextParse(context, common_tls_context,
                                 &downstream_tls_context->common_tls_context);
-      if (error != GRPC_ERROR_NONE) return error;
+      if (error != GRPC_ERROR_NONE) errors.push_back(error);
     }
     auto* require_client_certificate =
         envoy_extensions_transport_sockets_tls_v3_DownstreamTlsContext_require_client_certificate(
@@ -2267,23 +2374,41 @@ grpc_error_handle DownstreamTlsContextParse(
       downstream_tls_context->require_client_certificate =
           google_protobuf_BoolValue_value(require_client_certificate);
     }
+    auto* require_sni =
+        envoy_extensions_transport_sockets_tls_v3_DownstreamTlsContext_require_sni(
+            downstream_tls_context_proto);
+    if (require_sni != nullptr &&
+        google_protobuf_BoolValue_value(require_sni)) {
+      errors.push_back(
+          GRPC_ERROR_CREATE_FROM_STATIC_STRING("require_sni: unsupported"));
+    }
+    if (envoy_extensions_transport_sockets_tls_v3_DownstreamTlsContext_ocsp_staple_policy(
+            downstream_tls_context_proto) !=
+        envoy_extensions_transport_sockets_tls_v3_DownstreamTlsContext_LENIENT_STAPLING) {
+      errors.push_back(GRPC_ERROR_CREATE_FROM_STATIC_STRING(
+          "ocsp_staple_policy: Only LENIENT_STAPLING supported"));
+    }
   }
   if (downstream_tls_context->common_tls_context
-          .tls_certificate_certificate_provider_instance.instance_name
-          .empty()) {
-    return GRPC_ERROR_CREATE_FROM_STATIC_STRING(
+          .tls_certificate_provider_instance.instance_name.empty()) {
+    errors.push_back(GRPC_ERROR_CREATE_FROM_STATIC_STRING(
         "TLS configuration provided but no "
-        "tls_certificate_certificate_provider_instance found.");
+        "tls_certificate_provider_instance found."));
   }
   if (downstream_tls_context->require_client_certificate &&
-      downstream_tls_context->common_tls_context.combined_validation_context
-          .validation_context_certificate_provider_instance.instance_name
-          .empty()) {
-    return GRPC_ERROR_CREATE_FROM_STATIC_STRING(
+      downstream_tls_context->common_tls_context.certificate_validation_context
+          .ca_certificate_provider_instance.instance_name.empty()) {
+    errors.push_back(GRPC_ERROR_CREATE_FROM_STATIC_STRING(
         "TLS configuration requires client certificates but no certificate "
-        "provider instance specified for validation.");
+        "provider instance specified for validation."));
   }
-  return GRPC_ERROR_NONE;
+  if (!downstream_tls_context->common_tls_context.certificate_validation_context
+           .match_subject_alt_names.empty()) {
+    errors.push_back(GRPC_ERROR_CREATE_FROM_STATIC_STRING(
+        "match_subject_alt_names not supported on servers"));
+  }
+  return GRPC_ERROR_CREATE_FROM_VECTOR("Error parsing DownstreamTlsContext",
+                                       &errors);
 }
 
 grpc_error_handle CidrRangeParse(
@@ -2374,67 +2499,69 @@ grpc_error_handle FilterChainParse(
     const EncodingContext& context,
     const envoy_config_listener_v3_FilterChain* filter_chain_proto, bool is_v2,
     FilterChain* filter_chain) {
-  grpc_error_handle error = GRPC_ERROR_NONE;
+  std::vector<grpc_error_handle> errors;
   auto* filter_chain_match =
       envoy_config_listener_v3_FilterChain_filter_chain_match(
           filter_chain_proto);
   if (filter_chain_match != nullptr) {
-    error = FilterChainMatchParse(filter_chain_match,
-                                  &filter_chain->filter_chain_match);
-    if (error != GRPC_ERROR_NONE) return error;
+    grpc_error_handle error = FilterChainMatchParse(
+        filter_chain_match, &filter_chain->filter_chain_match);
+    if (error != GRPC_ERROR_NONE) errors.push_back(error);
   }
   // Parse the filters list. Currently we only support HttpConnectionManager.
   size_t size = 0;
   auto* filters =
       envoy_config_listener_v3_FilterChain_filters(filter_chain_proto, &size);
   if (size != 1) {
-    return GRPC_ERROR_CREATE_FROM_STATIC_STRING(
+    errors.push_back(GRPC_ERROR_CREATE_FROM_STATIC_STRING(
         "FilterChain should have exactly one filter: HttpConnectionManager; no "
-        "other filter is supported at the moment");
-  }
-  auto* typed_config = envoy_config_listener_v3_Filter_typed_config(filters[0]);
-  if (typed_config == nullptr) {
-    return GRPC_ERROR_CREATE_FROM_STATIC_STRING(
-        "No typed_config found in filter.");
-  }
-  absl::string_view type_url =
-      UpbStringToAbsl(google_protobuf_Any_type_url(typed_config));
-  if (type_url !=
-      "type.googleapis.com/"
-      "envoy.extensions.filters.network.http_connection_manager.v3."
-      "HttpConnectionManager") {
-    return GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-        absl::StrCat("Unsupported filter type ", type_url).c_str());
-  }
-  const upb_strview encoded_http_connection_manager =
-      google_protobuf_Any_value(typed_config);
-  const auto* http_connection_manager =
-      envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_parse(
-          encoded_http_connection_manager.data,
-          encoded_http_connection_manager.size, context.arena);
-  if (http_connection_manager == nullptr) {
-    return GRPC_ERROR_CREATE_FROM_STATIC_STRING(
-        "Could not parse HttpConnectionManager config from filter "
-        "typed_config");
-  }
-  filter_chain->filter_chain_data =
-      std::make_shared<XdsApi::LdsUpdate::FilterChainData>();
-  error = HttpConnectionManagerParse(
-      false /* is_client */, context, http_connection_manager, is_v2,
-      &filter_chain->filter_chain_data->http_connection_manager);
-  if (error != GRPC_ERROR_NONE) return error;
-  // Get the DownstreamTlsContext for the filter chain
-  if (XdsSecurityEnabled()) {
-    auto* transport_socket =
-        envoy_config_listener_v3_FilterChain_transport_socket(
-            filter_chain_proto);
-    if (transport_socket != nullptr) {
-      error = DownstreamTlsContextParse(
-          context, transport_socket,
-          &filter_chain->filter_chain_data->downstream_tls_context);
+        "other filter is supported at the moment"));
+  } else {
+    auto* typed_config =
+        envoy_config_listener_v3_Filter_typed_config(filters[0]);
+    if (typed_config == nullptr) {
+      errors.push_back(GRPC_ERROR_CREATE_FROM_STATIC_STRING(
+          "No typed_config found in filter."));
+    } else {
+      absl::string_view type_url =
+          UpbStringToAbsl(google_protobuf_Any_type_url(typed_config));
+      if (type_url !=
+          "type.googleapis.com/"
+          "envoy.extensions.filters.network.http_connection_manager.v3."
+          "HttpConnectionManager") {
+        errors.push_back(GRPC_ERROR_CREATE_FROM_CPP_STRING(
+            absl::StrCat("Unsupported filter type ", type_url)));
+      } else {
+        const upb_strview encoded_http_connection_manager =
+            google_protobuf_Any_value(typed_config);
+        const auto* http_connection_manager =
+            envoy_extensions_filters_network_http_connection_manager_v3_HttpConnectionManager_parse(
+                encoded_http_connection_manager.data,
+                encoded_http_connection_manager.size, context.arena);
+        if (http_connection_manager == nullptr) {
+          errors.push_back(GRPC_ERROR_CREATE_FROM_STATIC_STRING(
+              "Could not parse HttpConnectionManager config from filter "
+              "typed_config"));
+        } else {
+          filter_chain->filter_chain_data =
+              std::make_shared<XdsApi::LdsUpdate::FilterChainData>();
+          grpc_error_handle error = HttpConnectionManagerParse(
+              false /* is_client */, context, http_connection_manager, is_v2,
+              &filter_chain->filter_chain_data->http_connection_manager);
+          if (error != GRPC_ERROR_NONE) errors.push_back(error);
+        }
+      }
     }
   }
-  return error;
+  auto* transport_socket =
+      envoy_config_listener_v3_FilterChain_transport_socket(filter_chain_proto);
+  if (transport_socket != nullptr) {
+    grpc_error_handle error = DownstreamTlsContextParse(
+        context, transport_socket,
+        &filter_chain->filter_chain_data->downstream_tls_context);
+    if (error != GRPC_ERROR_NONE) errors.push_back(error);
+  }
+  return GRPC_ERROR_CREATE_FROM_VECTOR("Error parsing FilterChain", &errors);
 }
 
 grpc_error_handle AddressParse(
@@ -2442,7 +2569,7 @@ grpc_error_handle AddressParse(
   const auto* socket_address =
       envoy_config_core_v3_Address_socket_address(address_proto);
   if (socket_address == nullptr) {
-    return GRPC_ERROR_CREATE_FROM_COPIED_STRING(
+    return GRPC_ERROR_CREATE_FROM_STATIC_STRING(
         "Address does not have socket_address");
   }
   if (envoy_config_core_v3_SocketAddress_protocol(socket_address) !=
@@ -2485,11 +2612,9 @@ grpc_error_handle AddFilterChainDataForSourcePort(
       port, XdsApi::LdsUpdate::FilterChainMap::FilterChainDataSharedPtr{
                 filter_chain.filter_chain_data});
   if (!insert_result.second) {
-    return GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-        absl::StrCat(
-            "Duplicate matching rules detected when adding filter chain: ",
-            filter_chain.filter_chain_match.ToString())
-            .c_str());
+    return GRPC_ERROR_CREATE_FROM_CPP_STRING(absl::StrCat(
+        "Duplicate matching rules detected when adding filter chain: ",
+        filter_chain.filter_chain_match.ToString()));
   }
   return GRPC_ERROR_NONE;
 }
@@ -2654,7 +2779,7 @@ grpc_error_handle BuildFilterChainMap(
   return GRPC_ERROR_NONE;
 }
 
-grpc_error_handle LdsResponseParseServer(
+grpc_error_handle LdsResourceParseServer(
     const EncodingContext& context,
     const envoy_config_listener_v3_Listener* listener, bool is_v2,
     XdsApi::LdsUpdate* lds_update) {
@@ -2703,166 +2828,31 @@ grpc_error_handle LdsResponseParseServer(
   return GRPC_ERROR_NONE;
 }
 
-grpc_error_handle LdsResponseParse(
+grpc_error_handle LdsResourceParse(
     const EncodingContext& context,
-    const envoy_service_discovery_v3_DiscoveryResponse* response,
-    const std::set<absl::string_view>& expected_listener_names,
-    XdsApi::LdsUpdateMap* lds_update_map,
-    std::set<std::string>* resource_names_failed) {
-  std::vector<grpc_error_handle> errors;
-  // Get the resources from the response.
-  size_t size;
-  const google_protobuf_Any* const* resources =
-      envoy_service_discovery_v3_DiscoveryResponse_resources(response, &size);
-  for (size_t i = 0; i < size; ++i) {
-    // Check the type_url of the resource.
-    absl::string_view type_url =
-        UpbStringToAbsl(google_protobuf_Any_type_url(resources[i]));
-    bool is_v2 = false;
-    if (!IsLds(type_url, &is_v2)) {
-      errors.push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-          absl::StrCat("resource index ", i, ": Resource is not LDS.")
-              .c_str()));
-      continue;
-    }
-    // Decode the listener.
-    const upb_strview encoded_listener =
-        google_protobuf_Any_value(resources[i]);
-    const envoy_config_listener_v3_Listener* listener =
-        envoy_config_listener_v3_Listener_parse(
-            encoded_listener.data, encoded_listener.size, context.arena);
-    if (listener == nullptr) {
-      errors.push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-          absl::StrCat("resource index ", i, ": Can't decode listener.")
-              .c_str()));
-      continue;
-    }
-    // Check listener name. Ignore unexpected listeners.
-    std::string listener_name =
-        UpbStringToStdString(envoy_config_listener_v3_Listener_name(listener));
-    if (expected_listener_names.find(listener_name) ==
-        expected_listener_names.end()) {
-      continue;
-    }
-    // Fail if listener name is duplicated.
-    if (lds_update_map->find(listener_name) != lds_update_map->end()) {
-      errors.push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-          absl::StrCat("duplicate listener name \"", listener_name, "\"")
-              .c_str()));
-      resource_names_failed->insert(listener_name);
-      continue;
-    }
-    // Serialize into JSON and store it in the LdsUpdateMap
-    XdsApi::LdsResourceData& lds_resource_data =
-        (*lds_update_map)[listener_name];
-    XdsApi::LdsUpdate& lds_update = lds_resource_data.resource;
-    lds_resource_data.serialized_proto = UpbStringToStdString(encoded_listener);
-    // Check whether it's a client or server listener.
-    const envoy_config_listener_v3_ApiListener* api_listener =
-        envoy_config_listener_v3_Listener_api_listener(listener);
-    const envoy_config_core_v3_Address* address =
-        envoy_config_listener_v3_Listener_address(listener);
-    if (api_listener != nullptr && address != nullptr) {
-      errors.push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-          absl::StrCat(listener_name,
-                       ": Listener has both address and ApiListener")
-              .c_str()));
-      resource_names_failed->insert(listener_name);
-      continue;
-    }
-    if (api_listener == nullptr && address == nullptr) {
-      errors.push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-          absl::StrCat(listener_name,
-                       ": Listener has neither address nor ApiListener")
-              .c_str()));
-      resource_names_failed->insert(listener_name);
-      continue;
-    }
-    grpc_error_handle error = GRPC_ERROR_NONE;
-    if (api_listener != nullptr) {
-      error = LdsResponseParseClient(context, api_listener, is_v2, &lds_update);
-    } else {
-      error = LdsResponseParseServer(context, listener, is_v2, &lds_update);
-    }
-    if (error != GRPC_ERROR_NONE) {
-      errors.push_back(grpc_error_add_child(
-          GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-              absl::StrCat(listener_name, ": validation error").c_str()),
-          error));
-      resource_names_failed->insert(listener_name);
-    }
+    const envoy_config_listener_v3_Listener* listener, bool is_v2,
+    XdsApi::LdsUpdate* lds_update) {
+  // Check whether it's a client or server listener.
+  const envoy_config_listener_v3_ApiListener* api_listener =
+      envoy_config_listener_v3_Listener_api_listener(listener);
+  const envoy_config_core_v3_Address* address =
+      envoy_config_listener_v3_Listener_address(listener);
+  if (api_listener != nullptr && address != nullptr) {
+    return GRPC_ERROR_CREATE_FROM_STATIC_STRING(
+        "Listener has both address and ApiListener");
   }
-  return GRPC_ERROR_CREATE_FROM_VECTOR("errors parsing LDS response", &errors);
-}
-
-grpc_error_handle RdsResponseParse(
-    const EncodingContext& context,
-    const envoy_service_discovery_v3_DiscoveryResponse* response,
-    const std::set<absl::string_view>& expected_route_configuration_names,
-    XdsApi::RdsUpdateMap* rds_update_map,
-    std::set<std::string>* resource_names_failed) {
-  std::vector<grpc_error_handle> errors;
-  // Get the resources from the response.
-  size_t size;
-  const google_protobuf_Any* const* resources =
-      envoy_service_discovery_v3_DiscoveryResponse_resources(response, &size);
-  for (size_t i = 0; i < size; ++i) {
-    // Check the type_url of the resource.
-    absl::string_view type_url =
-        UpbStringToAbsl(google_protobuf_Any_type_url(resources[i]));
-    if (!IsRds(type_url)) {
-      errors.push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-          absl::StrCat("resource index ", i, ": Resource is not RDS.")
-              .c_str()));
-      continue;
-    }
-    // Decode the route_config.
-    const upb_strview encoded_route_config =
-        google_protobuf_Any_value(resources[i]);
-    const envoy_config_route_v3_RouteConfiguration* route_config =
-        envoy_config_route_v3_RouteConfiguration_parse(
-            encoded_route_config.data, encoded_route_config.size,
-            context.arena);
-    if (route_config == nullptr) {
-      errors.push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-          absl::StrCat("resource index ", i, ": Can't decode route_config.")
-              .c_str()));
-      continue;
-    }
-    // Check route_config_name. Ignore unexpected route_config.
-    std::string route_config_name = UpbStringToStdString(
-        envoy_config_route_v3_RouteConfiguration_name(route_config));
-    if (expected_route_configuration_names.find(route_config_name) ==
-        expected_route_configuration_names.end()) {
-      continue;
-    }
-    // Fail if route config name is duplicated.
-    if (rds_update_map->find(route_config_name) != rds_update_map->end()) {
-      errors.push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-          absl::StrCat("duplicate route config name \"", route_config_name,
-                       "\"")
-              .c_str()));
-      resource_names_failed->insert(route_config_name);
-      continue;
-    }
-    // Serialize into JSON and store it in the RdsUpdateMap
-    XdsApi::RdsResourceData& rds_resource_data =
-        (*rds_update_map)[route_config_name];
-    XdsApi::RdsUpdate& rds_update = rds_resource_data.resource;
-    rds_resource_data.serialized_proto =
-        UpbStringToStdString(encoded_route_config);
-    // Parse the route_config.
-    grpc_error_handle error =
-        RouteConfigParse(context, route_config, &rds_update);
-    if (error != GRPC_ERROR_NONE) {
-      errors.push_back(grpc_error_add_child(
-          GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-              absl::StrCat(route_config_name, ": validation error").c_str()),
-          error));
-      resource_names_failed->insert(route_config_name);
-    }
+  if (api_listener == nullptr && address == nullptr) {
+    return GRPC_ERROR_CREATE_FROM_STATIC_STRING(
+        "Listener has neither address nor ApiListener");
+  }
+  // Validate Listener fields.
+  grpc_error_handle error = GRPC_ERROR_NONE;
+  if (api_listener != nullptr) {
+    error = LdsResourceParseClient(context, api_listener, is_v2, lds_update);
+  } else {
+    error = LdsResourceParseServer(context, listener, is_v2, lds_update);
   }
-  return GRPC_ERROR_CREATE_FROM_VECTOR("errors parsing RDS response", &errors);
+  return error;
 }
 
 grpc_error_handle UpstreamTlsContextParse(
@@ -2873,8 +2863,8 @@ grpc_error_handle UpstreamTlsContextParse(
   absl::string_view name = UpbStringToAbsl(
       envoy_config_core_v3_TransportSocket_name(transport_socket));
   if (name != "envoy.transport_sockets.tls") {
-    return GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-        absl::StrCat("Unrecognized transport socket: ", name).c_str());
+    return GRPC_ERROR_CREATE_FROM_CPP_STRING(
+        absl::StrCat("Unrecognized transport socket: ", name));
   }
   auto* typed_config =
       envoy_config_core_v3_TransportSocket_typed_config(transport_socket);
@@ -2902,391 +2892,263 @@ grpc_error_handle UpstreamTlsContextParse(
       }
     }
   }
-  if (common_tls_context->combined_validation_context
-          .validation_context_certificate_provider_instance.instance_name
-          .empty()) {
-    return GRPC_ERROR_CREATE_FROM_COPIED_STRING(
+  if (common_tls_context->certificate_validation_context
+          .ca_certificate_provider_instance.instance_name.empty()) {
+    return GRPC_ERROR_CREATE_FROM_STATIC_STRING(
         "UpstreamTlsContext: TLS configuration provided but no "
-        "validation_context_certificate_provider_instance "
-        "found.");
+        "ca_certificate_provider_instance found.");
+  }
+  return GRPC_ERROR_NONE;
+}
+
+grpc_error_handle CdsLogicalDnsParse(
+    const envoy_config_cluster_v3_Cluster* cluster,
+    XdsApi::CdsUpdate* cds_update) {
+  const auto* load_assignment =
+      envoy_config_cluster_v3_Cluster_load_assignment(cluster);
+  if (load_assignment == nullptr) {
+    return GRPC_ERROR_CREATE_FROM_STATIC_STRING(
+        "load_assignment not present for LOGICAL_DNS cluster");
+  }
+  size_t num_localities;
+  const auto* const* localities =
+      envoy_config_endpoint_v3_ClusterLoadAssignment_endpoints(load_assignment,
+                                                               &num_localities);
+  if (num_localities != 1) {
+    return GRPC_ERROR_CREATE_FROM_CPP_STRING(
+        absl::StrCat("load_assignment for LOGICAL_DNS cluster must have "
+                     "exactly one locality, found ",
+                     num_localities));
+  }
+  size_t num_endpoints;
+  const auto* const* endpoints =
+      envoy_config_endpoint_v3_LocalityLbEndpoints_lb_endpoints(localities[0],
+                                                                &num_endpoints);
+  if (num_endpoints != 1) {
+    return GRPC_ERROR_CREATE_FROM_CPP_STRING(
+        absl::StrCat("locality for LOGICAL_DNS cluster must have "
+                     "exactly one endpoint, found ",
+                     num_endpoints));
+  }
+  const auto* endpoint =
+      envoy_config_endpoint_v3_LbEndpoint_endpoint(endpoints[0]);
+  if (endpoint == nullptr) {
+    return GRPC_ERROR_CREATE_FROM_STATIC_STRING(
+        "LbEndpoint endpoint field not set");
+  }
+  const auto* address = envoy_config_endpoint_v3_Endpoint_address(endpoint);
+  if (address == nullptr) {
+    return GRPC_ERROR_CREATE_FROM_STATIC_STRING(
+        "Endpoint address field not set");
+  }
+  const auto* socket_address =
+      envoy_config_core_v3_Address_socket_address(address);
+  if (socket_address == nullptr) {
+    return GRPC_ERROR_CREATE_FROM_STATIC_STRING(
+        "Address socket_address field not set");
+  }
+  if (envoy_config_core_v3_SocketAddress_resolver_name(socket_address).size !=
+      0) {
+    return GRPC_ERROR_CREATE_FROM_STATIC_STRING(
+        "LOGICAL_DNS clusters must NOT have a custom resolver name set");
+  }
+  absl::string_view address_str = UpbStringToAbsl(
+      envoy_config_core_v3_SocketAddress_address(socket_address));
+  if (address_str.empty()) {
+    return GRPC_ERROR_CREATE_FROM_STATIC_STRING(
+        "SocketAddress address field not set");
   }
+  if (!envoy_config_core_v3_SocketAddress_has_port_value(socket_address)) {
+    return GRPC_ERROR_CREATE_FROM_STATIC_STRING(
+        "SocketAddress port_value field not set");
+  }
+  cds_update->dns_hostname = JoinHostPort(
+      address_str,
+      envoy_config_core_v3_SocketAddress_port_value(socket_address));
   return GRPC_ERROR_NONE;
 }
 
-grpc_error_handle CdsResponseParse(
+grpc_error_handle CdsResourceParse(
     const EncodingContext& context,
-    const envoy_service_discovery_v3_DiscoveryResponse* response,
-    const std::set<absl::string_view>& expected_cluster_names,
-    XdsApi::CdsUpdateMap* cds_update_map,
-    std::set<std::string>* resource_names_failed) {
+    const envoy_config_cluster_v3_Cluster* cluster, bool /*is_v2*/,
+    XdsApi::CdsUpdate* cds_update) {
   std::vector<grpc_error_handle> errors;
-  // Get the resources from the response.
-  size_t size;
-  const google_protobuf_Any* const* resources =
-      envoy_service_discovery_v3_DiscoveryResponse_resources(response, &size);
-  // Parse all the resources in the CDS response.
-  for (size_t i = 0; i < size; ++i) {
-    // Check the type_url of the resource.
-    absl::string_view type_url =
-        UpbStringToAbsl(google_protobuf_Any_type_url(resources[i]));
-    if (!IsCds(type_url)) {
-      errors.push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-          absl::StrCat("resource index ", i, ": Resource is not CDS.")
-              .c_str()));
-      continue;
-    }
-    // Decode the cluster.
-    const upb_strview encoded_cluster = google_protobuf_Any_value(resources[i]);
-    const envoy_config_cluster_v3_Cluster* cluster =
-        envoy_config_cluster_v3_Cluster_parse(
-            encoded_cluster.data, encoded_cluster.size, context.arena);
-    if (cluster == nullptr) {
-      errors.push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-          absl::StrCat("resource index ", i, ": Can't decode cluster.")
-              .c_str()));
-      continue;
-    }
-    MaybeLogCluster(context, cluster);
-    // Ignore unexpected cluster names.
-    std::string cluster_name =
-        UpbStringToStdString(envoy_config_cluster_v3_Cluster_name(cluster));
-    if (expected_cluster_names.find(cluster_name) ==
-        expected_cluster_names.end()) {
-      continue;
-    }
-    // Fail on duplicate resources.
-    if (cds_update_map->find(cluster_name) != cds_update_map->end()) {
-      errors.push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-          absl::StrCat("duplicate resource name \"", cluster_name, "\"")
-              .c_str()));
-      resource_names_failed->insert(cluster_name);
-      continue;
-    }
-    // Add the cluster to cds_update_map.
-    XdsApi::CdsResourceData& cds_resource_data =
-        (*cds_update_map)[cluster_name];
-    XdsApi::CdsUpdate& cds_update = cds_resource_data.resource;
-    // Store serialized proto.
-    cds_resource_data.serialized_proto = UpbStringToStdString(encoded_cluster);
-    // Check the cluster_discovery_type.
-    if (!envoy_config_cluster_v3_Cluster_has_type(cluster) &&
-        !envoy_config_cluster_v3_Cluster_has_cluster_type(cluster)) {
-      errors.push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-          absl::StrCat(cluster_name, ": DiscoveryType not found.").c_str()));
-      resource_names_failed->insert(cluster_name);
-      continue;
-    }
-    if (envoy_config_cluster_v3_Cluster_type(cluster) ==
-        envoy_config_cluster_v3_Cluster_EDS) {
-      cds_update.cluster_type = XdsApi::CdsUpdate::ClusterType::EDS;
-      // Check the EDS config source.
-      const envoy_config_cluster_v3_Cluster_EdsClusterConfig*
-          eds_cluster_config =
-              envoy_config_cluster_v3_Cluster_eds_cluster_config(cluster);
-      const envoy_config_core_v3_ConfigSource* eds_config =
-          envoy_config_cluster_v3_Cluster_EdsClusterConfig_eds_config(
-              eds_cluster_config);
-      if (!envoy_config_core_v3_ConfigSource_has_ads(eds_config)) {
-        errors.push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-            absl::StrCat(cluster_name, ": EDS ConfigSource is not ADS.")
-                .c_str()));
-        resource_names_failed->insert(cluster_name);
-        continue;
-      }
-      // Record EDS service_name (if any).
-      upb_strview service_name =
-          envoy_config_cluster_v3_Cluster_EdsClusterConfig_service_name(
-              eds_cluster_config);
-      if (service_name.size != 0) {
-        cds_update.eds_service_name = UpbStringToStdString(service_name);
-      }
-    } else if (!XdsAggregateAndLogicalDnsClusterEnabled()) {
-      errors.push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-          absl::StrCat(cluster_name, ": DiscoveryType is not valid.").c_str()));
-      resource_names_failed->insert(cluster_name);
-      continue;
-    } else if (envoy_config_cluster_v3_Cluster_type(cluster) ==
-               envoy_config_cluster_v3_Cluster_LOGICAL_DNS) {
-      cds_update.cluster_type = XdsApi::CdsUpdate::ClusterType::LOGICAL_DNS;
-      const auto* load_assignment =
-          envoy_config_cluster_v3_Cluster_load_assignment(cluster);
-      if (load_assignment == nullptr) {
-        errors.push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-            absl::StrCat(
-                cluster_name,
-                ": load_assignment not present for LOGICAL_DNS cluster")
-                .c_str()));
-        resource_names_failed->insert(cluster_name);
-        continue;
-      }
-      size_t num_localities;
-      const auto* const* localities =
-          envoy_config_endpoint_v3_ClusterLoadAssignment_endpoints(
-              load_assignment, &num_localities);
-      if (num_localities != 1) {
-        errors.push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-            absl::StrCat(cluster_name,
-                         ": load_assignment for LOGICAL_DNS cluster must have "
-                         "exactly one locality, found ",
-                         num_localities)
-                .c_str()));
-        resource_names_failed->insert(cluster_name);
-        continue;
-      }
-      size_t num_endpoints;
-      const auto* const* endpoints =
-          envoy_config_endpoint_v3_LocalityLbEndpoints_lb_endpoints(
-              localities[0], &num_endpoints);
-      if (num_endpoints != 1) {
-        errors.push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-            absl::StrCat(cluster_name,
-                         ": locality for LOGICAL_DNS cluster must have "
-                         "exactly one endpoint, found ",
-                         num_endpoints)
-                .c_str()));
-        resource_names_failed->insert(cluster_name);
-        continue;
-      }
-      const auto* endpoint =
-          envoy_config_endpoint_v3_LbEndpoint_endpoint(endpoints[0]);
-      if (endpoint == nullptr) {
-        errors.push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-            absl::StrCat(cluster_name, ": LbEndpoint endpoint field not set")
-                .c_str()));
-        resource_names_failed->insert(cluster_name);
-        continue;
-      }
-      const auto* address = envoy_config_endpoint_v3_Endpoint_address(endpoint);
-      if (address == nullptr) {
-        errors.push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-            absl::StrCat(cluster_name, ": Endpoint address field not set")
-                .c_str()));
-        resource_names_failed->insert(cluster_name);
-        continue;
-      }
-      const auto* socket_address =
-          envoy_config_core_v3_Address_socket_address(address);
-      if (socket_address == nullptr) {
-        errors.push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-            absl::StrCat(cluster_name, ": Address socket_address field not set")
-                .c_str()));
-        resource_names_failed->insert(cluster_name);
-        continue;
-      }
-      if (envoy_config_core_v3_SocketAddress_resolver_name(socket_address)
-              .size != 0) {
-        errors.push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-            absl::StrCat(
-                cluster_name,
-                ": LOGICAL_DNS clusters must NOT have a custom resolver "
-                "name set")
-                .c_str()));
-        resource_names_failed->insert(cluster_name);
-        continue;
-      }
-      absl::string_view address_str = UpbStringToAbsl(
-          envoy_config_core_v3_SocketAddress_address(socket_address));
-      if (address_str.empty()) {
-        errors.push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-            absl::StrCat(cluster_name, ": SocketAddress address field not set")
-                .c_str()));
-        resource_names_failed->insert(cluster_name);
-        continue;
-      }
-      if (!envoy_config_core_v3_SocketAddress_has_port_value(socket_address)) {
-        errors.push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-            absl::StrCat(cluster_name,
-                         ": SocketAddress port_value field not set")
-                .c_str()));
-        resource_names_failed->insert(cluster_name);
-        continue;
-      }
-      cds_update.dns_hostname = JoinHostPort(
-          address_str,
-          envoy_config_core_v3_SocketAddress_port_value(socket_address));
+  // Check the cluster_discovery_type.
+  if (!envoy_config_cluster_v3_Cluster_has_type(cluster) &&
+      !envoy_config_cluster_v3_Cluster_has_cluster_type(cluster)) {
+    errors.push_back(
+        GRPC_ERROR_CREATE_FROM_STATIC_STRING("DiscoveryType not found."));
+  } else if (envoy_config_cluster_v3_Cluster_type(cluster) ==
+             envoy_config_cluster_v3_Cluster_EDS) {
+    cds_update->cluster_type = XdsApi::CdsUpdate::ClusterType::EDS;
+    // Check the EDS config source.
+    const envoy_config_cluster_v3_Cluster_EdsClusterConfig* eds_cluster_config =
+        envoy_config_cluster_v3_Cluster_eds_cluster_config(cluster);
+    const envoy_config_core_v3_ConfigSource* eds_config =
+        envoy_config_cluster_v3_Cluster_EdsClusterConfig_eds_config(
+            eds_cluster_config);
+    if (!envoy_config_core_v3_ConfigSource_has_ads(eds_config)) {
+      errors.push_back(
+          GRPC_ERROR_CREATE_FROM_STATIC_STRING("EDS ConfigSource is not ADS."));
+    }
+    // Record EDS service_name (if any).
+    upb_strview service_name =
+        envoy_config_cluster_v3_Cluster_EdsClusterConfig_service_name(
+            eds_cluster_config);
+    if (service_name.size != 0) {
+      cds_update->eds_service_name = UpbStringToStdString(service_name);
+    }
+  } else if (!XdsAggregateAndLogicalDnsClusterEnabled()) {
+    errors.push_back(
+        GRPC_ERROR_CREATE_FROM_STATIC_STRING("DiscoveryType is not valid."));
+  } else if (envoy_config_cluster_v3_Cluster_type(cluster) ==
+             envoy_config_cluster_v3_Cluster_LOGICAL_DNS) {
+    cds_update->cluster_type = XdsApi::CdsUpdate::ClusterType::LOGICAL_DNS;
+    grpc_error_handle error = CdsLogicalDnsParse(cluster, cds_update);
+    if (error != GRPC_ERROR_NONE) errors.push_back(error);
+  } else {
+    if (!envoy_config_cluster_v3_Cluster_has_cluster_type(cluster)) {
+      errors.push_back(
+          GRPC_ERROR_CREATE_FROM_STATIC_STRING("DiscoveryType is not valid."));
     } else {
-      if (envoy_config_cluster_v3_Cluster_has_cluster_type(cluster)) {
-        const envoy_config_cluster_v3_Cluster_CustomClusterType*
-            custom_cluster_type =
-                envoy_config_cluster_v3_Cluster_cluster_type(cluster);
-        upb_strview type_name =
-            envoy_config_cluster_v3_Cluster_CustomClusterType_name(
+      const envoy_config_cluster_v3_Cluster_CustomClusterType*
+          custom_cluster_type =
+              envoy_config_cluster_v3_Cluster_cluster_type(cluster);
+      upb_strview type_name =
+          envoy_config_cluster_v3_Cluster_CustomClusterType_name(
+              custom_cluster_type);
+      if (UpbStringToAbsl(type_name) != "envoy.clusters.aggregate") {
+        errors.push_back(GRPC_ERROR_CREATE_FROM_STATIC_STRING(
+            "DiscoveryType is not valid."));
+      } else {
+        cds_update->cluster_type = XdsApi::CdsUpdate::ClusterType::AGGREGATE;
+        // Retrieve aggregate clusters.
+        const google_protobuf_Any* typed_config =
+            envoy_config_cluster_v3_Cluster_CustomClusterType_typed_config(
                 custom_cluster_type);
-        if (UpbStringToAbsl(type_name) == "envoy.clusters.aggregate") {
-          cds_update.cluster_type = XdsApi::CdsUpdate::ClusterType::AGGREGATE;
-          // Retrieve aggregate clusters.
-          const google_protobuf_Any* typed_config =
-              envoy_config_cluster_v3_Cluster_CustomClusterType_typed_config(
-                  custom_cluster_type);
-          const upb_strview aggregate_cluster_config_upb_strview =
-              google_protobuf_Any_value(typed_config);
-          const envoy_extensions_clusters_aggregate_v3_ClusterConfig*
-              aggregate_cluster_config =
-                  envoy_extensions_clusters_aggregate_v3_ClusterConfig_parse(
-                      aggregate_cluster_config_upb_strview.data,
-                      aggregate_cluster_config_upb_strview.size, context.arena);
-          if (aggregate_cluster_config == nullptr) {
-            errors.push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-                absl::StrCat(cluster_name, ": Can't parse aggregate cluster.")
-                    .c_str()));
-            resource_names_failed->insert(cluster_name);
-            continue;
-          }
+        const upb_strview aggregate_cluster_config_upb_strview =
+            google_protobuf_Any_value(typed_config);
+        const envoy_extensions_clusters_aggregate_v3_ClusterConfig*
+            aggregate_cluster_config =
+                envoy_extensions_clusters_aggregate_v3_ClusterConfig_parse(
+                    aggregate_cluster_config_upb_strview.data,
+                    aggregate_cluster_config_upb_strview.size, context.arena);
+        if (aggregate_cluster_config == nullptr) {
+          errors.push_back(GRPC_ERROR_CREATE_FROM_STATIC_STRING(
+              "Can't parse aggregate cluster."));
+        } else {
           size_t size;
           const upb_strview* clusters =
               envoy_extensions_clusters_aggregate_v3_ClusterConfig_clusters(
                   aggregate_cluster_config, &size);
           for (size_t i = 0; i < size; ++i) {
             const upb_strview cluster = clusters[i];
-            cds_update.prioritized_cluster_names.emplace_back(
+            cds_update->prioritized_cluster_names.emplace_back(
                 UpbStringToStdString(cluster));
           }
-        } else {
-          errors.push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-              absl::StrCat(cluster_name, ": DiscoveryType is not valid.")
-                  .c_str()));
-          resource_names_failed->insert(cluster_name);
-          continue;
         }
-      } else {
-        errors.push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-            absl::StrCat(cluster_name, ": DiscoveryType is not valid.")
-                .c_str()));
-        resource_names_failed->insert(cluster_name);
-        continue;
       }
     }
-    // Check the LB policy.
-    if (envoy_config_cluster_v3_Cluster_lb_policy(cluster) ==
-        envoy_config_cluster_v3_Cluster_ROUND_ROBIN) {
-      cds_update.lb_policy = "ROUND_ROBIN";
-    } else if (envoy_config_cluster_v3_Cluster_lb_policy(cluster) ==
-               envoy_config_cluster_v3_Cluster_RING_HASH) {
-      cds_update.lb_policy = "RING_HASH";
-      // Record ring hash lb config
-      auto* ring_hash_config =
-          envoy_config_cluster_v3_Cluster_ring_hash_lb_config(cluster);
-      if (ring_hash_config != nullptr) {
-        const google_protobuf_UInt64Value* max_ring_size =
-            envoy_config_cluster_v3_Cluster_RingHashLbConfig_maximum_ring_size(
-                ring_hash_config);
-        if (max_ring_size != nullptr) {
-          cds_update.max_ring_size =
-              google_protobuf_UInt64Value_value(max_ring_size);
-          if (cds_update.max_ring_size > 8388608 ||
-              cds_update.max_ring_size == 0) {
-            errors.push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-                absl::StrCat(
-                    cluster_name,
-                    ": max_ring_size is not in the range of 1 to 8388608.")
-                    .c_str()));
-            resource_names_failed->insert(cluster_name);
-            continue;
-          }
-        }
-        const google_protobuf_UInt64Value* min_ring_size =
-            envoy_config_cluster_v3_Cluster_RingHashLbConfig_minimum_ring_size(
-                ring_hash_config);
-        if (min_ring_size != nullptr) {
-          cds_update.min_ring_size =
-              google_protobuf_UInt64Value_value(min_ring_size);
-          if (cds_update.min_ring_size > 8388608 ||
-              cds_update.min_ring_size == 0) {
-            errors.push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-                absl::StrCat(
-                    cluster_name,
-                    ": min_ring_size is not in the range of 1 to 8388608.")
-                    .c_str()));
-            resource_names_failed->insert(cluster_name);
-            continue;
-          }
-          if (cds_update.min_ring_size > cds_update.max_ring_size) {
-            errors.push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-                absl::StrCat(
-                    cluster_name,
-                    ": min_ring_size cannot be greater than max_ring_size.")
-                    .c_str()));
-            resource_names_failed->insert(cluster_name);
-            continue;
-          }
-        }
-        if (envoy_config_cluster_v3_Cluster_RingHashLbConfig_hash_function(
-                ring_hash_config) !=
-            envoy_config_cluster_v3_Cluster_RingHashLbConfig_XX_HASH) {
-          errors.push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-              absl::StrCat(cluster_name,
-                           ": ring hash lb config has invalid hash function.")
-                  .c_str()));
-          resource_names_failed->insert(cluster_name);
-          continue;
+  }
+  // Check the LB policy.
+  if (envoy_config_cluster_v3_Cluster_lb_policy(cluster) ==
+      envoy_config_cluster_v3_Cluster_ROUND_ROBIN) {
+    cds_update->lb_policy = "ROUND_ROBIN";
+  } else if (envoy_config_cluster_v3_Cluster_lb_policy(cluster) ==
+             envoy_config_cluster_v3_Cluster_RING_HASH) {
+    cds_update->lb_policy = "RING_HASH";
+    // Record ring hash lb config
+    auto* ring_hash_config =
+        envoy_config_cluster_v3_Cluster_ring_hash_lb_config(cluster);
+    if (ring_hash_config != nullptr) {
+      const google_protobuf_UInt64Value* max_ring_size =
+          envoy_config_cluster_v3_Cluster_RingHashLbConfig_maximum_ring_size(
+              ring_hash_config);
+      if (max_ring_size != nullptr) {
+        cds_update->max_ring_size =
+            google_protobuf_UInt64Value_value(max_ring_size);
+        if (cds_update->max_ring_size > 8388608 ||
+            cds_update->max_ring_size == 0) {
+          errors.push_back(GRPC_ERROR_CREATE_FROM_STATIC_STRING(
+              "max_ring_size is not in the range of 1 to 8388608."));
         }
       }
-    } else {
-      errors.push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-          absl::StrCat(cluster_name, ": LB policy is not supported.").c_str()));
-      resource_names_failed->insert(cluster_name);
-      continue;
-    }
-    if (XdsSecurityEnabled()) {
-      auto* transport_socket =
-          envoy_config_cluster_v3_Cluster_transport_socket(cluster);
-      if (transport_socket != nullptr) {
-        grpc_error_handle error = UpstreamTlsContextParse(
-            context, transport_socket, &cds_update.common_tls_context);
-        if (error != GRPC_ERROR_NONE) {
-          errors.push_back(grpc_error_add_child(
-              GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-                  absl::StrCat(
-                      "Error parsing security configuration for cluster: ",
-                      cluster_name)
-                      .c_str()),
-              error));
-          resource_names_failed->insert(cluster_name);
-          continue;
+      const google_protobuf_UInt64Value* min_ring_size =
+          envoy_config_cluster_v3_Cluster_RingHashLbConfig_minimum_ring_size(
+              ring_hash_config);
+      if (min_ring_size != nullptr) {
+        cds_update->min_ring_size =
+            google_protobuf_UInt64Value_value(min_ring_size);
+        if (cds_update->min_ring_size > 8388608 ||
+            cds_update->min_ring_size == 0) {
+          errors.push_back(GRPC_ERROR_CREATE_FROM_STATIC_STRING(
+              "min_ring_size is not in the range of 1 to 8388608."));
+        }
+        if (cds_update->min_ring_size > cds_update->max_ring_size) {
+          errors.push_back(GRPC_ERROR_CREATE_FROM_STATIC_STRING(
+              "min_ring_size cannot be greater than max_ring_size."));
         }
       }
-    }
-    // Record LRS server name (if any).
-    const envoy_config_core_v3_ConfigSource* lrs_server =
-        envoy_config_cluster_v3_Cluster_lrs_server(cluster);
-    if (lrs_server != nullptr) {
-      if (!envoy_config_core_v3_ConfigSource_has_self(lrs_server)) {
-        errors.push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-            absl::StrCat(cluster_name, ": LRS ConfigSource is not self.")
-                .c_str()));
-        resource_names_failed->insert(cluster_name);
-        continue;
+      if (envoy_config_cluster_v3_Cluster_RingHashLbConfig_hash_function(
+              ring_hash_config) !=
+          envoy_config_cluster_v3_Cluster_RingHashLbConfig_XX_HASH) {
+        errors.push_back(GRPC_ERROR_CREATE_FROM_STATIC_STRING(
+            "ring hash lb config has invalid hash function."));
       }
-      cds_update.lrs_load_reporting_server_name.emplace("");
     }
-    // The Cluster resource encodes the circuit breaking parameters in a list of
-    // Thresholds messages, where each message specifies the parameters for a
-    // particular RoutingPriority. we will look only at the first entry in the
-    // list for priority DEFAULT and default to 1024 if not found.
-    if (envoy_config_cluster_v3_Cluster_has_circuit_breakers(cluster)) {
-      const envoy_config_cluster_v3_CircuitBreakers* circuit_breakers =
-          envoy_config_cluster_v3_Cluster_circuit_breakers(cluster);
-      size_t num_thresholds;
-      const envoy_config_cluster_v3_CircuitBreakers_Thresholds* const*
-          thresholds = envoy_config_cluster_v3_CircuitBreakers_thresholds(
-              circuit_breakers, &num_thresholds);
-      for (size_t i = 0; i < num_thresholds; ++i) {
-        const auto* threshold = thresholds[i];
-        if (envoy_config_cluster_v3_CircuitBreakers_Thresholds_priority(
-                threshold) == envoy_config_core_v3_DEFAULT) {
-          const google_protobuf_UInt32Value* max_requests =
-              envoy_config_cluster_v3_CircuitBreakers_Thresholds_max_requests(
-                  threshold);
-          if (max_requests != nullptr) {
-            cds_update.max_concurrent_requests =
-                google_protobuf_UInt32Value_value(max_requests);
-          }
-          break;
+  } else {
+    errors.push_back(
+        GRPC_ERROR_CREATE_FROM_STATIC_STRING("LB policy is not supported."));
+  }
+  auto* transport_socket =
+      envoy_config_cluster_v3_Cluster_transport_socket(cluster);
+  if (transport_socket != nullptr) {
+    grpc_error_handle error = UpstreamTlsContextParse(
+        context, transport_socket, &cds_update->common_tls_context);
+    if (error != GRPC_ERROR_NONE) {
+      errors.push_back(
+          grpc_error_add_child(GRPC_ERROR_CREATE_FROM_STATIC_STRING(
+                                   "Error parsing security configuration"),
+                               error));
+    }
+  }
+  // Record LRS server name (if any).
+  const envoy_config_core_v3_ConfigSource* lrs_server =
+      envoy_config_cluster_v3_Cluster_lrs_server(cluster);
+  if (lrs_server != nullptr) {
+    if (!envoy_config_core_v3_ConfigSource_has_self(lrs_server)) {
+      errors.push_back(GRPC_ERROR_CREATE_FROM_STATIC_STRING(
+          ": LRS ConfigSource is not self."));
+    }
+    cds_update->lrs_load_reporting_server_name.emplace("");
+  }
+  // The Cluster resource encodes the circuit breaking parameters in a list of
+  // Thresholds messages, where each message specifies the parameters for a
+  // particular RoutingPriority. we will look only at the first entry in the
+  // list for priority DEFAULT and default to 1024 if not found.
+  if (envoy_config_cluster_v3_Cluster_has_circuit_breakers(cluster)) {
+    const envoy_config_cluster_v3_CircuitBreakers* circuit_breakers =
+        envoy_config_cluster_v3_Cluster_circuit_breakers(cluster);
+    size_t num_thresholds;
+    const envoy_config_cluster_v3_CircuitBreakers_Thresholds* const*
+        thresholds = envoy_config_cluster_v3_CircuitBreakers_thresholds(
+            circuit_breakers, &num_thresholds);
+    for (size_t i = 0; i < num_thresholds; ++i) {
+      const auto* threshold = thresholds[i];
+      if (envoy_config_cluster_v3_CircuitBreakers_Thresholds_priority(
+              threshold) == envoy_config_core_v3_DEFAULT) {
+        const google_protobuf_UInt32Value* max_requests =
+            envoy_config_cluster_v3_CircuitBreakers_Thresholds_max_requests(
+                threshold);
+        if (max_requests != nullptr) {
+          cds_update->max_concurrent_requests =
+              google_protobuf_UInt32Value_value(max_requests);
         }
+        break;
       }
     }
   }
-  return GRPC_ERROR_CREATE_FROM_VECTOR("errors parsing CDS response", &errors);
+  return GRPC_ERROR_CREATE_FROM_VECTOR("errors parsing CDS resource", &errors);
 }
 
 grpc_error_handle ServerAddressParseAndAppend(
@@ -3420,12 +3282,79 @@ grpc_error_handle DropParseAndAppend(
   return GRPC_ERROR_NONE;
 }
 
-grpc_error_handle EdsResponseParse(
-    const EncodingContext& context,
+grpc_error_handle EdsResourceParse(
+    const EncodingContext& /*context*/,
+    const envoy_config_endpoint_v3_ClusterLoadAssignment*
+        cluster_load_assignment,
+    bool /*is_v2*/, XdsApi::EdsUpdate* eds_update) {
+  std::vector<grpc_error_handle> errors;
+  // Get the endpoints.
+  size_t locality_size;
+  const envoy_config_endpoint_v3_LocalityLbEndpoints* const* endpoints =
+      envoy_config_endpoint_v3_ClusterLoadAssignment_endpoints(
+          cluster_load_assignment, &locality_size);
+  for (size_t j = 0; j < locality_size; ++j) {
+    size_t priority;
+    XdsApi::EdsUpdate::Priority::Locality locality;
+    grpc_error_handle error = LocalityParse(endpoints[j], &locality, &priority);
+    if (error != GRPC_ERROR_NONE) {
+      errors.push_back(error);
+      continue;
+    }
+    // Filter out locality with weight 0.
+    if (locality.lb_weight == 0) continue;
+    // Make sure prorities is big enough. Note that they might not
+    // arrive in priority order.
+    while (eds_update->priorities.size() < priority + 1) {
+      eds_update->priorities.emplace_back();
+    }
+    eds_update->priorities[priority].localities.emplace(locality.name.get(),
+                                                        std::move(locality));
+  }
+  for (const auto& priority : eds_update->priorities) {
+    if (priority.localities.empty()) {
+      errors.push_back(
+          GRPC_ERROR_CREATE_FROM_STATIC_STRING("sparse priority list"));
+    }
+  }
+  // Get the drop config.
+  eds_update->drop_config = MakeRefCounted<XdsApi::EdsUpdate::DropConfig>();
+  const envoy_config_endpoint_v3_ClusterLoadAssignment_Policy* policy =
+      envoy_config_endpoint_v3_ClusterLoadAssignment_policy(
+          cluster_load_assignment);
+  if (policy != nullptr) {
+    size_t drop_size;
+    const envoy_config_endpoint_v3_ClusterLoadAssignment_Policy_DropOverload* const*
+        drop_overload =
+            envoy_config_endpoint_v3_ClusterLoadAssignment_Policy_drop_overloads(
+                policy, &drop_size);
+    for (size_t j = 0; j < drop_size; ++j) {
+      grpc_error_handle error =
+          DropParseAndAppend(drop_overload[j], eds_update->drop_config.get());
+      if (error != GRPC_ERROR_NONE) {
+        errors.push_back(
+            grpc_error_add_child(GRPC_ERROR_CREATE_FROM_STATIC_STRING(
+                                     "drop config validation error"),
+                                 error));
+      }
+    }
+  }
+  return GRPC_ERROR_CREATE_FROM_VECTOR("errors parsing EDS resource", &errors);
+}
+
+template <typename ProtoParseFunction, typename ProtoResourceNameFunction,
+          typename ResourceTypeSelectorFunction, typename ProtoLogFunction,
+          typename ResourceParseFunction, typename UpdateMap>
+grpc_error_handle AdsResponseParse(
+    const EncodingContext& context, ProtoParseFunction proto_parse_function,
+    ProtoResourceNameFunction proto_resource_name_function,
+    ResourceTypeSelectorFunction resource_type_selector_function,
+    ProtoLogFunction proto_log_function,
+    ResourceParseFunction resource_parse_function,
     const envoy_service_discovery_v3_DiscoveryResponse* response,
-    const std::set<absl::string_view>& expected_eds_service_names,
-    XdsApi::EdsUpdateMap* eds_update_map,
-    std::set<std::string>* resource_names_failed) {
+    const char* resource_type_string,
+    const std::set<absl::string_view>& expected_resource_names,
+    UpdateMap* update_map, std::set<std::string>* resource_names_failed) {
   std::vector<grpc_error_handle> errors;
   // Get the resources from the response.
   size_t size;
@@ -3435,115 +3364,57 @@ grpc_error_handle EdsResponseParse(
     // Check the type_url of the resource.
     absl::string_view type_url =
         UpbStringToAbsl(google_protobuf_Any_type_url(resources[i]));
-    if (!IsEds(type_url)) {
-      errors.push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-          absl::StrCat("resource index ", i, ": Resource is not EDS.")
-              .c_str()));
+    bool is_v2 = false;
+    if (!resource_type_selector_function(type_url, &is_v2)) {
+      errors.push_back(GRPC_ERROR_CREATE_FROM_CPP_STRING(
+          absl::StrCat("resource index ", i, ": Resource is not ",
+                       resource_type_string, ".")));
       continue;
     }
-    // Get the cluster_load_assignment.
-    upb_strview encoded_cluster_load_assignment =
-        google_protobuf_Any_value(resources[i]);
-    envoy_config_endpoint_v3_ClusterLoadAssignment* cluster_load_assignment =
-        envoy_config_endpoint_v3_ClusterLoadAssignment_parse(
-            encoded_cluster_load_assignment.data,
-            encoded_cluster_load_assignment.size, context.arena);
-    if (cluster_load_assignment == nullptr) {
-      errors.push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-          absl::StrCat("resource index ", i,
-                       ": Can't parse cluster_load_assignment.")
-              .c_str()));
+    // Parse the resource.
+    upb_strview serialized_resource = google_protobuf_Any_value(resources[i]);
+    auto* resource = proto_parse_function(
+        serialized_resource.data, serialized_resource.size, context.arena);
+    if (resource == nullptr) {
+      errors.push_back(GRPC_ERROR_CREATE_FROM_CPP_STRING(
+          absl::StrCat("resource index ", i, ": Can't parse ",
+                       resource_type_string, " resource.")));
       continue;
     }
-    MaybeLogClusterLoadAssignment(context, cluster_load_assignment);
-    // Check the EDS service name.  Ignore unexpected names.
-    std::string eds_service_name = UpbStringToStdString(
-        envoy_config_endpoint_v3_ClusterLoadAssignment_cluster_name(
-            cluster_load_assignment));
-    if (expected_eds_service_names.find(eds_service_name) ==
-        expected_eds_service_names.end()) {
+    proto_log_function(context, resource);
+    // Check the resource name.  Ignore unexpected names.
+    std::string resource_name =
+        UpbStringToStdString(proto_resource_name_function(resource));
+    if (expected_resource_names.find(resource_name) ==
+        expected_resource_names.end()) {
       continue;
     }
     // Fail on duplicate resources.
-    if (eds_update_map->find(eds_service_name) != eds_update_map->end()) {
-      errors.push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-          absl::StrCat("duplicate resource name \"", eds_service_name, "\"")
-              .c_str()));
-      resource_names_failed->insert(eds_service_name);
+    if (update_map->find(resource_name) != update_map->end()) {
+      errors.push_back(GRPC_ERROR_CREATE_FROM_CPP_STRING(
+          absl::StrCat("duplicate resource name \"", resource_name, "\"")));
+      resource_names_failed->insert(resource_name);
       continue;
     }
-    // Serialize into JSON and store it in the EdsUpdateMap
-    XdsApi::EdsResourceData& eds_resource_data =
-        (*eds_update_map)[eds_service_name];
-    XdsApi::EdsUpdate& eds_update = eds_resource_data.resource;
-    eds_resource_data.serialized_proto =
-        UpbStringToStdString(encoded_cluster_load_assignment);
-    // Get the endpoints.
-    size_t locality_size;
-    const envoy_config_endpoint_v3_LocalityLbEndpoints* const* endpoints =
-        envoy_config_endpoint_v3_ClusterLoadAssignment_endpoints(
-            cluster_load_assignment, &locality_size);
-    grpc_error_handle error = GRPC_ERROR_NONE;
-    for (size_t j = 0; j < locality_size; ++j) {
-      size_t priority;
-      XdsApi::EdsUpdate::Priority::Locality locality;
-      error = LocalityParse(endpoints[j], &locality, &priority);
-      if (error != GRPC_ERROR_NONE) break;
-      // Filter out locality with weight 0.
-      if (locality.lb_weight == 0) continue;
-      // Make sure prorities is big enough. Note that they might not
-      // arrive in priority order.
-      while (eds_update.priorities.size() < priority + 1) {
-        eds_update.priorities.emplace_back();
-      }
-      eds_update.priorities[priority].localities.emplace(locality.name.get(),
-                                                         std::move(locality));
-    }
+    // Validate resource.
+    decltype(UpdateMap::mapped_type::resource) update;
+    grpc_error_handle error =
+        resource_parse_function(context, resource, is_v2, &update);
     if (error != GRPC_ERROR_NONE) {
-      errors.push_back(grpc_error_add_child(
-          GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-              absl::StrCat(eds_service_name, ": locality validation error")
-                  .c_str()),
-          error));
-      resource_names_failed->insert(eds_service_name);
-      continue;
-    }
-    for (const auto& priority : eds_update.priorities) {
-      if (priority.localities.empty()) {
-        errors.push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-            absl::StrCat(eds_service_name, ": sparse priority list").c_str()));
-        resource_names_failed->insert(eds_service_name);
-        continue;
-      }
-    }
-    // Get the drop config.
-    eds_update.drop_config = MakeRefCounted<XdsApi::EdsUpdate::DropConfig>();
-    const envoy_config_endpoint_v3_ClusterLoadAssignment_Policy* policy =
-        envoy_config_endpoint_v3_ClusterLoadAssignment_policy(
-            cluster_load_assignment);
-    if (policy != nullptr) {
-      size_t drop_size;
-      const envoy_config_endpoint_v3_ClusterLoadAssignment_Policy_DropOverload* const*
-          drop_overload =
-              envoy_config_endpoint_v3_ClusterLoadAssignment_Policy_drop_overloads(
-                  policy, &drop_size);
-      for (size_t j = 0; j < drop_size; ++j) {
-        error =
-            DropParseAndAppend(drop_overload[j], eds_update.drop_config.get());
-        if (error != GRPC_ERROR_NONE) break;
-      }
-      if (error != GRPC_ERROR_NONE) {
-        errors.push_back(grpc_error_add_child(
-            GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-                absl::StrCat(eds_service_name, ": drop config validation error")
-                    .c_str()),
-            error));
-        resource_names_failed->insert(eds_service_name);
-        continue;
-      }
+      errors.push_back(
+          grpc_error_add_child(GRPC_ERROR_CREATE_FROM_CPP_STRING(absl::StrCat(
+                                   resource_name, ": validation error")),
+                               error));
+      resource_names_failed->insert(resource_name);
+    } else {
+      // Store result in update map, in both validated and serialized form.
+      auto& resource_data = (*update_map)[resource_name];
+      resource_data.resource = std::move(update);
+      resource_data.serialized_proto =
+          UpbStringToStdString(serialized_resource);
     }
   }
-  return GRPC_ERROR_CREATE_FROM_VECTOR("errors parsing EDS response", &errors);
+  return GRPC_ERROR_CREATE_FROM_VECTOR("errors parsing ADS response", &errors);
 }
 
 std::string TypeUrlInternalToExternal(absl::string_view type_url) {
@@ -3559,13 +3430,25 @@ std::string TypeUrlInternalToExternal(absl::string_view type_url) {
   return std::string(type_url);
 }
 
-template <typename UpdateMap>
-void MoveUpdatesToFailedSet(UpdateMap* update_map,
-                            std::set<std::string>* resource_names_failed) {
-  for (const auto& p : *update_map) {
-    resource_names_failed->insert(p.first);
-  }
-  update_map->clear();
+upb_strview LdsResourceName(
+    const envoy_config_listener_v3_Listener* lds_resource) {
+  return envoy_config_listener_v3_Listener_name(lds_resource);
+}
+
+upb_strview RdsResourceName(
+    const envoy_config_route_v3_RouteConfiguration* rds_resource) {
+  return envoy_config_route_v3_RouteConfiguration_name(rds_resource);
+}
+
+upb_strview CdsResourceName(
+    const envoy_config_cluster_v3_Cluster* cds_resource) {
+  return envoy_config_cluster_v3_Cluster_name(cds_resource);
+}
+
+upb_strview EdsResourceName(
+    const envoy_config_endpoint_v3_ClusterLoadAssignment* eds_resource) {
+  return envoy_config_endpoint_v3_ClusterLoadAssignment_cluster_name(
+      eds_resource);
 }
 
 }  // namespace
@@ -3604,38 +3487,33 @@ XdsApi::AdsParseResult XdsApi::ParseAdsResponse(
   result.nonce = UpbStringToStdString(
       envoy_service_discovery_v3_DiscoveryResponse_nonce(response));
   // Parse the response according to the resource type.
+  // TODO(roth): When we have time, consider defining an interface for the
+  // methods of each resource type, so that we don't have to pass
+  // individual functions into each call to AdsResponseParse().
   if (IsLds(result.type_url)) {
-    result.parse_error =
-        LdsResponseParse(context, response, expected_listener_names,
-                         &result.lds_update_map, &result.resource_names_failed);
-    if (result.parse_error != GRPC_ERROR_NONE) {
-      MoveUpdatesToFailedSet(&result.lds_update_map,
-                             &result.resource_names_failed);
-    }
+    result.parse_error = AdsResponseParse(
+        context, envoy_config_listener_v3_Listener_parse, LdsResourceName,
+        IsLds, MaybeLogListener, LdsResourceParse, response, "LDS",
+        expected_listener_names, &result.lds_update_map,
+        &result.resource_names_failed);
   } else if (IsRds(result.type_url)) {
-    result.parse_error =
-        RdsResponseParse(context, response, expected_route_configuration_names,
-                         &result.rds_update_map, &result.resource_names_failed);
-    if (result.parse_error != GRPC_ERROR_NONE) {
-      MoveUpdatesToFailedSet(&result.rds_update_map,
-                             &result.resource_names_failed);
-    }
+    result.parse_error = AdsResponseParse(
+        context, envoy_config_route_v3_RouteConfiguration_parse,
+        RdsResourceName, IsRds, MaybeLogRouteConfiguration, RouteConfigParse,
+        response, "RDS", expected_route_configuration_names,
+        &result.rds_update_map, &result.resource_names_failed);
   } else if (IsCds(result.type_url)) {
-    result.parse_error =
-        CdsResponseParse(context, response, expected_cluster_names,
-                         &result.cds_update_map, &result.resource_names_failed);
-    if (result.parse_error != GRPC_ERROR_NONE) {
-      MoveUpdatesToFailedSet(&result.cds_update_map,
-                             &result.resource_names_failed);
-    }
+    result.parse_error = AdsResponseParse(
+        context, envoy_config_cluster_v3_Cluster_parse, CdsResourceName, IsCds,
+        MaybeLogCluster, CdsResourceParse, response, "CDS",
+        expected_cluster_names, &result.cds_update_map,
+        &result.resource_names_failed);
   } else if (IsEds(result.type_url)) {
-    result.parse_error =
-        EdsResponseParse(context, response, expected_eds_service_names,
-                         &result.eds_update_map, &result.resource_names_failed);
-    if (result.parse_error != GRPC_ERROR_NONE) {
-      MoveUpdatesToFailedSet(&result.eds_update_map,
-                             &result.resource_names_failed);
-    }
+    result.parse_error = AdsResponseParse(
+        context, envoy_config_endpoint_v3_ClusterLoadAssignment_parse,
+        EdsResourceName, IsEds, MaybeLogClusterLoadAssignment, EdsResourceParse,
+        response, "EDS", expected_eds_service_names, &result.eds_update_map,
+        &result.resource_names_failed);
   }
   return result;
 }
index d3fd9c1..50d8b7e 100644 (file)
 
 #include "absl/container/inlined_vector.h"
 #include "absl/types/optional.h"
+#include "envoy/admin/v3/config_dump.upb.h"
 #include "re2/re2.h"
-
 #include "upb/def.hpp"
 
 #include <grpc/slice_buffer.h>
 
-#include "envoy/admin/v3/config_dump.upb.h"
 #include "src/core/ext/filters/client_channel/server_address.h"
 #include "src/core/ext/xds/xds_bootstrap.h"
 #include "src/core/ext/xds/xds_client_stats.h"
 
 namespace grpc_core {
 
-// TODO(yashykt): Check to see if xDS security is enabled. This will be
-// removed once this feature is fully integration-tested and enabled by
-// default.
-bool XdsSecurityEnabled();
-
 class XdsClient;
 
 class XdsApi {
@@ -194,22 +188,11 @@ class XdsApi {
   };
 
   struct CommonTlsContext {
-    struct CertificateValidationContext {
-      std::vector<StringMatcher> match_subject_alt_names;
-
-      bool operator==(const CertificateValidationContext& other) const {
-        return match_subject_alt_names == other.match_subject_alt_names;
-      }
-
-      std::string ToString() const;
-      bool Empty() const;
-    };
-
-    struct CertificateProviderInstance {
+    struct CertificateProviderPluginInstance {
       std::string instance_name;
       std::string certificate_name;
 
-      bool operator==(const CertificateProviderInstance& other) const {
+      bool operator==(const CertificateProviderPluginInstance& other) const {
         return instance_name == other.instance_name &&
                certificate_name == other.certificate_name;
       }
@@ -218,28 +201,28 @@ class XdsApi {
       bool Empty() const;
     };
 
-    struct CombinedCertificateValidationContext {
-      CertificateValidationContext default_validation_context;
-      CertificateProviderInstance
-          validation_context_certificate_provider_instance;
+    struct CertificateValidationContext {
+      CertificateProviderPluginInstance ca_certificate_provider_instance;
+      std::vector<StringMatcher> match_subject_alt_names;
 
-      bool operator==(const CombinedCertificateValidationContext& other) const {
-        return default_validation_context == other.default_validation_context &&
-               validation_context_certificate_provider_instance ==
-                   other.validation_context_certificate_provider_instance;
+      bool operator==(const CertificateValidationContext& other) const {
+        return ca_certificate_provider_instance ==
+                   other.ca_certificate_provider_instance &&
+               match_subject_alt_names == other.match_subject_alt_names;
       }
 
       std::string ToString() const;
       bool Empty() const;
     };
 
-    CertificateProviderInstance tls_certificate_certificate_provider_instance;
-    CombinedCertificateValidationContext combined_validation_context;
+    CertificateValidationContext certificate_validation_context;
+    CertificateProviderPluginInstance tls_certificate_provider_instance;
 
     bool operator==(const CommonTlsContext& other) const {
-      return tls_certificate_certificate_provider_instance ==
-                 other.tls_certificate_certificate_provider_instance &&
-             combined_validation_context == other.combined_validation_context;
+      return certificate_validation_context ==
+                 other.certificate_validation_context &&
+             tls_certificate_provider_instance ==
+                 other.tls_certificate_provider_instance;
     }
 
     std::string ToString() const;
index d64ab35..1a7a82c 100644 (file)
 
 #include "src/core/ext/xds/xds_bootstrap.h"
 
-#include <vector>
-
 #include <errno.h>
 #include <stdlib.h>
 
+#include <vector>
+
 #include "absl/strings/str_cat.h"
 #include "absl/strings/str_format.h"
 #include "absl/strings/str_join.h"
@@ -132,16 +132,14 @@ XdsBootstrap::XdsBootstrap(Json json, grpc_error_handle* error) {
           std::move(*it->second.mutable_string_value());
     }
   }
-  if (XdsSecurityEnabled()) {
-    it = json.mutable_object()->find("certificate_providers");
-    if (it != json.mutable_object()->end()) {
-      if (it->second.type() != Json::Type::OBJECT) {
-        error_list.push_back(GRPC_ERROR_CREATE_FROM_STATIC_STRING(
-            "\"certificate_providers\" field is not an object"));
-      } else {
-        grpc_error_handle parse_error = ParseCertificateProviders(&it->second);
-        if (parse_error != GRPC_ERROR_NONE) error_list.push_back(parse_error);
-      }
+  it = json.mutable_object()->find("certificate_providers");
+  if (it != json.mutable_object()->end()) {
+    if (it->second.type() != Json::Type::OBJECT) {
+      error_list.push_back(GRPC_ERROR_CREATE_FROM_STATIC_STRING(
+          "\"certificate_providers\" field is not an object"));
+    } else {
+      grpc_error_handle parse_error = ParseCertificateProviders(&it->second);
+      if (parse_error != GRPC_ERROR_NONE) error_list.push_back(parse_error);
     }
   }
   *error = GRPC_ERROR_CREATE_FROM_VECTOR("errors parsing xds bootstrap file",
@@ -153,8 +151,8 @@ grpc_error_handle XdsBootstrap::ParseXdsServerList(Json* json) {
   for (size_t i = 0; i < json->mutable_array()->size(); ++i) {
     Json& child = json->mutable_array()->at(i);
     if (child.type() != Json::Type::OBJECT) {
-      error_list.push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-          absl::StrCat("array element ", i, " is not an object").c_str()));
+      error_list.push_back(GRPC_ERROR_CREATE_FROM_CPP_STRING(
+          absl::StrCat("array element ", i, " is not an object")));
     } else {
       grpc_error_handle parse_error = ParseXdsServer(&child, i);
       if (parse_error != GRPC_ERROR_NONE) error_list.push_back(parse_error);
@@ -201,15 +199,8 @@ grpc_error_handle XdsBootstrap::ParseXdsServer(Json* json, size_t idx) {
       if (parse_error != GRPC_ERROR_NONE) error_list.push_back(parse_error);
     }
   }
-  // Can't use GRPC_ERROR_CREATE_FROM_VECTOR() here, because the error
-  // string is not static in this case.
-  if (error_list.empty()) return GRPC_ERROR_NONE;
-  grpc_error_handle error = GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-      absl::StrCat("errors parsing index ", idx).c_str());
-  for (size_t i = 0; i < error_list.size(); ++i) {
-    error = grpc_error_add_child(error, error_list[i]);
-  }
-  return error;
+  return GRPC_ERROR_CREATE_FROM_VECTOR_AND_CPP_STRING(
+      absl::StrCat("errors parsing index ", idx), &error_list);
 }
 
 grpc_error_handle XdsBootstrap::ParseChannelCredsArray(Json* json,
@@ -218,8 +209,8 @@ grpc_error_handle XdsBootstrap::ParseChannelCredsArray(Json* json,
   for (size_t i = 0; i < json->mutable_array()->size(); ++i) {
     Json& child = json->mutable_array()->at(i);
     if (child.type() != Json::Type::OBJECT) {
-      error_list.push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-          absl::StrCat("array element ", i, " is not an object").c_str()));
+      error_list.push_back(GRPC_ERROR_CREATE_FROM_CPP_STRING(
+          absl::StrCat("array element ", i, " is not an object")));
     } else {
       grpc_error_handle parse_error = ParseChannelCreds(&child, i, server);
       if (parse_error != GRPC_ERROR_NONE) error_list.push_back(parse_error);
@@ -261,22 +252,14 @@ grpc_error_handle XdsBootstrap::ParseChannelCreds(Json* json, size_t idx,
   if (server->channel_creds_type.empty() &&
       XdsChannelCredsRegistry::IsSupported(type)) {
     if (!XdsChannelCredsRegistry::IsValidConfig(type, config)) {
-      error_list.push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-          absl::StrCat("invalid config for channel creds type \"", type, "\"")
-              .c_str()));
+      error_list.push_back(GRPC_ERROR_CREATE_FROM_CPP_STRING(absl::StrCat(
+          "invalid config for channel creds type \"", type, "\"")));
     }
     server->channel_creds_type = std::move(type);
     server->channel_creds_config = std::move(config);
   }
-  // Can't use GRPC_ERROR_CREATE_FROM_VECTOR() here, because the error
-  // string is not static in this case.
-  if (error_list.empty()) return GRPC_ERROR_NONE;
-  grpc_error_handle error = GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-      absl::StrCat("errors parsing index ", idx).c_str());
-  for (size_t i = 0; i < error_list.size(); ++i) {
-    error = grpc_error_add_child(error, error_list[i]);
-  }
-  return error;
+  return GRPC_ERROR_CREATE_FROM_VECTOR_AND_CPP_STRING(
+      absl::StrCat("errors parsing index ", idx), &error_list);
 }
 
 grpc_error_handle XdsBootstrap::ParseServerFeaturesArray(Json* json,
@@ -374,10 +357,8 @@ grpc_error_handle XdsBootstrap::ParseCertificateProviders(Json* json) {
   std::vector<grpc_error_handle> error_list;
   for (auto& certificate_provider : *(json->mutable_object())) {
     if (certificate_provider.second.type() != Json::Type::OBJECT) {
-      error_list.push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-          absl::StrCat("element \"", certificate_provider.first,
-                       "\" is not an object")
-              .c_str()));
+      error_list.push_back(GRPC_ERROR_CREATE_FROM_CPP_STRING(absl::StrCat(
+          "element \"", certificate_provider.first, "\" is not an object")));
     } else {
       grpc_error_handle parse_error = ParseCertificateProvider(
           certificate_provider.first, &certificate_provider.second);
@@ -404,8 +385,8 @@ grpc_error_handle XdsBootstrap::ParseCertificateProvider(
         CertificateProviderRegistry::LookupCertificateProviderFactory(
             plugin_name);
     if (factory == nullptr) {
-      error_list.push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-          absl::StrCat("Unrecognized plugin name: ", plugin_name).c_str()));
+      error_list.push_back(GRPC_ERROR_CREATE_FROM_CPP_STRING(
+          absl::StrCat("Unrecognized plugin name: ", plugin_name)));
     } else {
       RefCountedPtr<CertificateProviderFactory::Config> config;
       it = certificate_provider_json->mutable_object()->find("config");
@@ -430,15 +411,9 @@ grpc_error_handle XdsBootstrap::ParseCertificateProvider(
           {instance_name, {std::move(plugin_name), std::move(config)}});
     }
   }
-  // Can't use GRPC_ERROR_CREATE_FROM_VECTOR() here, because the error
-  // string is not static in this case.
-  if (error_list.empty()) return GRPC_ERROR_NONE;
-  grpc_error_handle error = GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-      absl::StrCat("errors parsing element \"", instance_name, "\"").c_str());
-  for (size_t i = 0; i < error_list.size(); ++i) {
-    error = grpc_error_add_child(error, error_list[i]);
-  }
-  return error;
+  return GRPC_ERROR_CREATE_FROM_VECTOR_AND_CPP_STRING(
+      absl::StrCat("errors parsing element \"", instance_name, "\""),
+      &error_list);
 }
 
 std::string XdsBootstrap::ToString() const {
index 4715a23..78de195 100644 (file)
@@ -16,6 +16,8 @@
 
 #include <grpc/support/port_platform.h>
 
+#include "src/core/ext/xds/xds_client.h"
+
 #include <inttypes.h>
 #include <limits.h>
 #include <string.h>
@@ -35,7 +37,6 @@
 #include "src/core/ext/xds/xds_api.h"
 #include "src/core/ext/xds/xds_bootstrap.h"
 #include "src/core/ext/xds/xds_channel_args.h"
-#include "src/core/ext/xds/xds_client.h"
 #include "src/core/ext/xds/xds_client_stats.h"
 #include "src/core/ext/xds/xds_http_filters.h"
 #include "src/core/lib/address_utils/sockaddr_utils.h"
@@ -193,11 +194,10 @@ class XdsClient::ChannelState::AdsCallState
         ABSL_EXCLUSIVE_LOCKS_REQUIRED(&XdsClient::mu_) {
       if (error == GRPC_ERROR_NONE && timer_pending_) {
         timer_pending_ = false;
-        grpc_error_handle watcher_error = GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-            absl::StrFormat(
+        grpc_error_handle watcher_error =
+            GRPC_ERROR_CREATE_FROM_CPP_STRING(absl::StrFormat(
                 "timeout obtaining resource {type=%s name=%s} from xds server",
-                type_url_, name_)
-                .c_str());
+                type_url_, name_));
         watcher_error = grpc_error_set_int(
             watcher_error, GRPC_ERROR_INT_GRPC_STATUS, GRPC_STATUS_UNAVAILABLE);
         if (GRPC_TRACE_FLAG_ENABLED(grpc_xds_client_trace)) {
@@ -263,13 +263,15 @@ class XdsClient::ChannelState::AdsCallState
       ABSL_EXCLUSIVE_LOCKS_REQUIRED(&XdsClient::mu_);
 
   void AcceptLdsUpdateLocked(std::string version, grpc_millis update_time,
-                             XdsApi::LdsUpdateMap lds_update_map)
+                             XdsApi::LdsUpdateMap lds_update_map,
+                             const std::set<std::string>& resource_names_failed)
       ABSL_EXCLUSIVE_LOCKS_REQUIRED(&XdsClient::mu_);
   void AcceptRdsUpdateLocked(std::string version, grpc_millis update_time,
                              XdsApi::RdsUpdateMap rds_update_map)
       ABSL_EXCLUSIVE_LOCKS_REQUIRED(&XdsClient::mu_);
   void AcceptCdsUpdateLocked(std::string version, grpc_millis update_time,
-                             XdsApi::CdsUpdateMap cds_update_map)
+                             XdsApi::CdsUpdateMap cds_update_map,
+                             const std::set<std::string>& resource_names_failed)
       ABSL_EXCLUSIVE_LOCKS_REQUIRED(&XdsClient::mu_);
   void AcceptEdsUpdateLocked(std::string version, grpc_millis update_time,
                              XdsApi::EdsUpdateMap eds_update_map)
@@ -904,7 +906,8 @@ XdsApi::ResourceMetadata CreateResourceMetadataAcked(
 
 void XdsClient::ChannelState::AdsCallState::AcceptLdsUpdateLocked(
     std::string version, grpc_millis update_time,
-    XdsApi::LdsUpdateMap lds_update_map) {
+    XdsApi::LdsUpdateMap lds_update_map,
+    const std::set<std::string>& resource_names_failed) {
   if (GRPC_TRACE_FLAG_ENABLED(grpc_xds_client_trace)) {
     gpr_log(GPR_INFO,
             "[xds_client %p] LDS update received containing %" PRIuPTR
@@ -948,6 +951,21 @@ void XdsClient::ChannelState::AdsCallState::AcceptLdsUpdateLocked(
       p.first->OnListenerChanged(*listener_state.update);
     }
   }
+  // For invalid resources in the update, if they are already in the
+  // cache, pretend that they are present in the update, so that we
+  // don't incorrectly consider them deleted below.
+  for (const std::string& listener_name : resource_names_failed) {
+    auto it = xds_client()->listener_map_.find(listener_name);
+    if (it != xds_client()->listener_map_.end()) {
+      auto& resource = it->second.update;
+      if (!resource.has_value()) continue;
+      lds_update_map[listener_name];
+      if (!resource->http_connection_manager.route_config_name.empty()) {
+        rds_resource_names_seen.insert(
+            resource->http_connection_manager.route_config_name);
+      }
+    }
+  }
   // For any subscribed resource that is not present in the update,
   // remove it from the cache and notify watchers that it does not exist.
   for (const auto& p : lds_state.subscribed_resources) {
@@ -1030,7 +1048,8 @@ void XdsClient::ChannelState::AdsCallState::AcceptRdsUpdateLocked(
 
 void XdsClient::ChannelState::AdsCallState::AcceptCdsUpdateLocked(
     std::string version, grpc_millis update_time,
-    XdsApi::CdsUpdateMap cds_update_map) {
+    XdsApi::CdsUpdateMap cds_update_map,
+    const std::set<std::string>& resource_names_failed) {
   if (GRPC_TRACE_FLAG_ENABLED(grpc_xds_client_trace)) {
     gpr_log(GPR_INFO,
             "[xds_client %p] CDS update received containing %" PRIuPTR
@@ -1072,6 +1091,20 @@ void XdsClient::ChannelState::AdsCallState::AcceptCdsUpdateLocked(
       p.first->OnClusterChanged(cluster_state.update.value());
     }
   }
+  // For invalid resources in the update, if they are already in the
+  // cache, pretend that they are present in the update, so that we
+  // don't incorrectly consider them deleted below.
+  for (const std::string& cluster_name : resource_names_failed) {
+    auto it = xds_client()->cluster_map_.find(cluster_name);
+    if (it != xds_client()->cluster_map_.end()) {
+      auto& resource = it->second.update;
+      if (!resource.has_value()) continue;
+      cds_update_map[cluster_name];
+      eds_resource_names_seen.insert(resource->eds_service_name.empty()
+                                         ? cluster_name
+                                         : resource->eds_service_name);
+    }
+  }
   // For any subscribed resource that is not present in the update,
   // remove it from the cache and notify watchers that it does not exist.
   for (const auto& p : cds_state.subscribed_resources) {
@@ -1173,7 +1206,7 @@ void XdsClient::ChannelState::AdsCallState::RejectAdsUpdateLocked(
   if (GRPC_TRACE_FLAG_ENABLED(grpc_xds_client_trace)) {
     gpr_log(GPR_INFO,
             "[xds_client %p] %s update NACKed containing %" PRIuPTR
-            " resources",
+            " invalid resources",
             xds_client(), result.type_url.c_str(),
             result.resource_names_failed.size());
   }
@@ -1268,9 +1301,8 @@ bool XdsClient::ChannelState::AdsCallState::OnResponseReceivedLocked() {
     // Update nonce.
     auto& state = state_map_[result.type_url];
     state.nonce = std::move(result.nonce);
-    // NACK or ACK the response.
+    // If we got an error, we'll NACK the update.
     if (result.parse_error != GRPC_ERROR_NONE) {
-      // NACK unacceptable update.
       gpr_log(GPR_ERROR,
               "[xds_client %p] ADS response invalid for resource type %s "
               "version %s, will NACK: nonce=%s error=%s",
@@ -1294,27 +1326,32 @@ bool XdsClient::ChannelState::AdsCallState::OnResponseReceivedLocked() {
         RejectAdsUpdateLocked(update_time, result,
                               &xds_client()->endpoint_map_);
       }
-      SendMessageLocked(result.type_url);
-    } else {
+    }
+    // Process any valid resources.
+    bool have_valid_resources = false;
+    if (result.type_url == XdsApi::kLdsTypeUrl) {
+      have_valid_resources = !result.lds_update_map.empty();
+      AcceptLdsUpdateLocked(result.version, update_time,
+                            std::move(result.lds_update_map),
+                            result.resource_names_failed);
+    } else if (result.type_url == XdsApi::kRdsTypeUrl) {
+      have_valid_resources = !result.rds_update_map.empty();
+      AcceptRdsUpdateLocked(result.version, update_time,
+                            std::move(result.rds_update_map));
+    } else if (result.type_url == XdsApi::kCdsTypeUrl) {
+      have_valid_resources = !result.cds_update_map.empty();
+      AcceptCdsUpdateLocked(result.version, update_time,
+                            std::move(result.cds_update_map),
+                            result.resource_names_failed);
+    } else if (result.type_url == XdsApi::kEdsTypeUrl) {
+      have_valid_resources = !result.eds_update_map.empty();
+      AcceptEdsUpdateLocked(result.version, update_time,
+                            std::move(result.eds_update_map));
+    }
+    if (have_valid_resources) {
       seen_response_ = true;
-      // Accept the ADS response according to the type_url.
-      if (result.type_url == XdsApi::kLdsTypeUrl) {
-        AcceptLdsUpdateLocked(result.version, update_time,
-                              std::move(result.lds_update_map));
-      } else if (result.type_url == XdsApi::kRdsTypeUrl) {
-        AcceptRdsUpdateLocked(result.version, update_time,
-                              std::move(result.rds_update_map));
-      } else if (result.type_url == XdsApi::kCdsTypeUrl) {
-        AcceptCdsUpdateLocked(result.version, update_time,
-                              std::move(result.cds_update_map));
-      } else if (result.type_url == XdsApi::kEdsTypeUrl) {
-        AcceptEdsUpdateLocked(result.version, update_time,
-                              std::move(result.eds_update_map));
-      }
       xds_client()->resource_version_map_[result.type_url] =
           std::move(result.version);
-      // ACK the update.
-      SendMessageLocked(result.type_url);
       // Start load reporting if needed.
       auto& lrs_call = chand()->lrs_calld_;
       if (lrs_call != nullptr) {
@@ -1322,6 +1359,8 @@ bool XdsClient::ChannelState::AdsCallState::OnResponseReceivedLocked() {
         if (lrs_calld != nullptr) lrs_calld->MaybeStartReportingLocked();
       }
     }
+    // Send ACK or NACK.
+    SendMessageLocked(result.type_url);
   }
   if (xds_client()->shutting_down_) return true;
   // Keep listening for updates.
index c38ded2..437541d 100644 (file)
@@ -31,8 +31,8 @@ namespace grpc_core {
 
 namespace {
 
-uint64_t GetAndResetCounter(Atomic<uint64_t>* from) {
-  return from->Exchange(0, MemoryOrder::RELAXED);
+uint64_t GetAndResetCounter(std::atomic<uint64_t>* from) {
+  return from->exchange(0, std::memory_order_relaxed);
 }
 
 }  // namespace
@@ -82,7 +82,7 @@ XdsClusterDropStats::Snapshot XdsClusterDropStats::GetSnapshotAndReset() {
 }
 
 void XdsClusterDropStats::AddUncategorizedDrops() {
-  uncategorized_drops_.FetchAdd(1);
+  uncategorized_drops_.fetch_add(1);
 }
 
 void XdsClusterDropStats::AddCallDropped(const std::string& category) {
@@ -132,28 +132,29 @@ XdsClusterLocalityStats::~XdsClusterLocalityStats() {
 
 XdsClusterLocalityStats::Snapshot
 XdsClusterLocalityStats::GetSnapshotAndReset() {
-  Snapshot snapshot = {GetAndResetCounter(&total_successful_requests_),
-                       // Don't reset total_requests_in_progress because it's
-                       // not related to a single reporting interval.
-                       total_requests_in_progress_.Load(MemoryOrder::RELAXED),
-                       GetAndResetCounter(&total_error_requests_),
-                       GetAndResetCounter(&total_issued_requests_),
-                       {}};
+  Snapshot snapshot = {
+      GetAndResetCounter(&total_successful_requests_),
+      // Don't reset total_requests_in_progress because it's
+      // not related to a single reporting interval.
+      total_requests_in_progress_.load(std::memory_order_relaxed),
+      GetAndResetCounter(&total_error_requests_),
+      GetAndResetCounter(&total_issued_requests_),
+      {}};
   MutexLock lock(&backend_metrics_mu_);
   snapshot.backend_metrics = std::move(backend_metrics_);
   return snapshot;
 }
 
 void XdsClusterLocalityStats::AddCallStarted() {
-  total_issued_requests_.FetchAdd(1, MemoryOrder::RELAXED);
-  total_requests_in_progress_.FetchAdd(1, MemoryOrder::RELAXED);
+  total_issued_requests_.fetch_add(1, std::memory_order_relaxed);
+  total_requests_in_progress_.fetch_add(1, std::memory_order_relaxed);
 }
 
 void XdsClusterLocalityStats::AddCallFinished(bool fail) {
-  Atomic<uint64_t>& to_increment =
+  std::atomic<uint64_t>& to_increment =
       fail ? total_error_requests_ : total_successful_requests_;
-  to_increment.FetchAdd(1, MemoryOrder::RELAXED);
-  total_requests_in_progress_.FetchAdd(-1, MemoryOrder::ACQ_REL);
+  to_increment.fetch_add(1, std::memory_order_relaxed);
+  total_requests_in_progress_.fetch_add(-1, std::memory_order_acq_rel);
 }
 
 }  // namespace grpc_core
index b300fc5..31dbb46 100644 (file)
@@ -21,6 +21,7 @@
 
 #include <grpc/support/port_platform.h>
 
+#include <atomic>
 #include <map>
 #include <string>
 
@@ -29,7 +30,6 @@
 #include "absl/strings/string_view.h"
 
 #include "src/core/lib/gpr/useful.h"
-#include "src/core/lib/gprpp/atomic.h"
 #include "src/core/lib/gprpp/memory.h"
 #include "src/core/lib/gprpp/ref_counted.h"
 #include "src/core/lib/gprpp/sync.h"
@@ -144,7 +144,7 @@ class XdsClusterDropStats : public RefCounted<XdsClusterDropStats> {
   absl::string_view lrs_server_name_;
   absl::string_view cluster_name_;
   absl::string_view eds_service_name_;
-  Atomic<uint64_t> uncategorized_drops_{0};
+  std::atomic<uint64_t> uncategorized_drops_{0};
   // Protects categorized_drops_. A mutex is necessary because the length of
   // dropped_requests can be accessed by both the picker (from data plane
   // mutex) and the load reporting thread (from the control plane combiner).
@@ -221,10 +221,10 @@ class XdsClusterLocalityStats : public RefCounted<XdsClusterLocalityStats> {
   absl::string_view eds_service_name_;
   RefCountedPtr<XdsLocalityName> name_;
 
-  Atomic<uint64_t> total_successful_requests_{0};
-  Atomic<uint64_t> total_requests_in_progress_{0};
-  Atomic<uint64_t> total_error_requests_{0};
-  Atomic<uint64_t> total_issued_requests_{0};
+  std::atomic<uint64_t> total_successful_requests_{0};
+  std::atomic<uint64_t> total_requests_in_progress_{0};
+  std::atomic<uint64_t> total_error_requests_{0};
+  std::atomic<uint64_t> total_issued_requests_{0};
 
   // Protects backend_metrics_. A mutex is necessary because the length of
   // backend_metrics_ can be accessed by both the callback intercepting the
index 64b7a2b..b545b99 100644 (file)
@@ -18,8 +18,6 @@
 
 #include "src/core/ext/xds/xds_http_fault_filter.h"
 
-#include <grpc/grpc.h>
-
 #include <string>
 
 #include "absl/status/statusor.h"
 #include "google/protobuf/any.upb.h"
 #include "google/protobuf/duration.upb.h"
 #include "google/protobuf/wrappers.upb.h"
+#include "upb/def.h"
+
+#include <grpc/grpc.h>
+
 #include "src/core/ext/filters/fault_injection/fault_injection_filter.h"
 #include "src/core/ext/xds/xds_http_filters.h"
 #include "src/core/lib/channel/channel_args.h"
@@ -40,7 +42,6 @@
 #include "src/core/lib/channel/status_util.h"
 #include "src/core/lib/json/json.h"
 #include "src/core/lib/transport/status_conversion.h"
-#include "upb/def.h"
 
 namespace grpc_core {
 
index 60c4952..8ba4054 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
+#include "absl/status/statusor.h"
+#include "upb/def.h"
+
 #include <grpc/grpc.h>
 
-#include "absl/status/statusor.h"
 #include "src/core/ext/xds/xds_http_filters.h"
-#include "upb/def.h"
 
 namespace grpc_core {
 
index 4cf95eb..4f79336 100644 (file)
@@ -20,6 +20,7 @@
 
 #include "envoy/extensions/filters/http/router/v3/router.upb.h"
 #include "envoy/extensions/filters/http/router/v3/router.upbdefs.h"
+
 #include "src/core/ext/xds/xds_http_fault_filter.h"
 
 namespace grpc_core {
index 962731f..fe010cf 100644 (file)
@@ -259,12 +259,12 @@ FilterChainMatchManager::CreateOrGetXdsCertificateProviderFromFilterChainData(
   // Configure root cert.
   absl::string_view root_provider_instance_name =
       filter_chain->downstream_tls_context.common_tls_context
-          .combined_validation_context
-          .validation_context_certificate_provider_instance.instance_name;
+          .certificate_validation_context.ca_certificate_provider_instance
+          .instance_name;
   absl::string_view root_provider_cert_name =
       filter_chain->downstream_tls_context.common_tls_context
-          .combined_validation_context
-          .validation_context_certificate_provider_instance.certificate_name;
+          .certificate_validation_context.ca_certificate_provider_instance
+          .certificate_name;
   if (!root_provider_instance_name.empty()) {
     certificate_providers.root =
         xds_client_->certificate_provider_store()
@@ -278,10 +278,10 @@ FilterChainMatchManager::CreateOrGetXdsCertificateProviderFromFilterChainData(
   // Configure identity cert.
   absl::string_view identity_provider_instance_name =
       filter_chain->downstream_tls_context.common_tls_context
-          .tls_certificate_certificate_provider_instance.instance_name;
+          .tls_certificate_provider_instance.instance_name;
   absl::string_view identity_provider_cert_name =
       filter_chain->downstream_tls_context.common_tls_context
-          .tls_certificate_certificate_provider_instance.certificate_name;
+          .tls_certificate_provider_instance.certificate_name;
   if (!identity_provider_instance_name.empty()) {
     certificate_providers.instance =
         xds_client_->certificate_provider_store()
@@ -428,7 +428,7 @@ class XdsServerConfigFetcher : public grpc_server_config_fetcher {
         if (serving_status_notifier_.on_serving_status_update != nullptr) {
           serving_status_notifier_.on_serving_status_update(
               serving_status_notifier_.user_data, listening_address_.c_str(),
-              GRPC_STATUS_OK, "");
+              {GRPC_STATUS_OK, ""});
         } else {
           gpr_log(GPR_INFO,
                   "xDS Listener resource obtained; will start serving on %s",
@@ -459,7 +459,7 @@ class XdsServerConfigFetcher : public grpc_server_config_fetcher {
         if (serving_status_notifier_.on_serving_status_update != nullptr) {
           serving_status_notifier_.on_serving_status_update(
               serving_status_notifier_.user_data, listening_address_.c_str(),
-              GRPC_STATUS_UNAVAILABLE, grpc_error_std_string(error).c_str());
+              {GRPC_STATUS_UNAVAILABLE, grpc_error_std_string(error).c_str()});
         } else {
           gpr_log(
               GPR_ERROR,
@@ -486,8 +486,8 @@ class XdsServerConfigFetcher : public grpc_server_config_fetcher {
       if (serving_status_notifier_.on_serving_status_update != nullptr) {
         serving_status_notifier_.on_serving_status_update(
             serving_status_notifier_.user_data, listening_address_.c_str(),
-            static_cast<grpc_status_code>(status.raw_code()),
-            std::string(status.message()).c_str());
+            {static_cast<grpc_status_code>(status.raw_code()),
+             std::string(status.message()).c_str()});
       }
     }
 
index 98dd1bc..a621514 100644 (file)
@@ -87,10 +87,8 @@ grpc_error_handle UnixSockaddrPopulate(absl::string_view path,
       reinterpret_cast<struct sockaddr_un*>(resolved_addr->addr);
   const size_t maxlen = sizeof(un->sun_path) - 1;
   if (path.size() > maxlen) {
-    return GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-        absl::StrCat("Path name should not have more than ", maxlen,
-                     " characters")
-            .c_str());
+    return GRPC_ERROR_CREATE_FROM_CPP_STRING(absl::StrCat(
+        "Path name should not have more than ", maxlen, " characters"));
   }
   un->sun_family = AF_UNIX;
   path.copy(un->sun_path, path.size());
@@ -105,10 +103,8 @@ grpc_error_handle UnixAbstractSockaddrPopulate(
       reinterpret_cast<struct sockaddr_un*>(resolved_addr->addr);
   const size_t maxlen = sizeof(un->sun_path) - 1;
   if (path.size() > maxlen) {
-    return GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-        absl::StrCat("Path name should not have more than ", maxlen,
-                     " characters")
-            .c_str());
+    return GRPC_ERROR_CREATE_FROM_CPP_STRING(absl::StrCat(
+        "Path name should not have more than ", maxlen, " characters"));
   }
   un->sun_family = AF_UNIX;
   un->sun_path[0] = '\0';
index 8bda081..33afba1 100644 (file)
@@ -212,8 +212,8 @@ grpc_error_handle grpc_string_to_sockaddr(grpc_resolved_address* out,
     addr4->sin_family = GRPC_AF_INET;
     out->len = sizeof(grpc_sockaddr_in);
   } else {
-    return GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-        absl::StrCat("Failed to parse address:", addr).c_str());
+    return GRPC_ERROR_CREATE_FROM_CPP_STRING(
+        absl::StrCat("Failed to parse address:", addr));
   }
   grpc_sockaddr_set_port(out, port);
   return GRPC_ERROR_NONE;
index a383e5a..a1da9c3 100644 (file)
@@ -18,6 +18,8 @@
 
 #include <grpc/support/port_platform.h>
 
+#include "src/core/lib/channel/channel_args.h"
+
 #include <limits.h>
 #include <string.h>
 
@@ -33,7 +35,6 @@
 #include <grpc/support/log.h>
 #include <grpc/support/string_util.h>
 
-#include "src/core/lib/channel/channel_args.h"
 #include "src/core/lib/gpr/string.h"
 #include "src/core/lib/gpr/useful.h"
 
index 122d7a9..a7f890e 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include <grpc/support/alloc.h>
-#include <grpc/support/log.h>
 #include "src/core/lib/channel/channel_stack.h"
-#include "src/core/lib/gpr/alloc.h"
 
 #include <stdlib.h>
 #include <string.h>
 
+#include <grpc/support/alloc.h>
+#include <grpc/support/log.h>
+
+#include "src/core/lib/gpr/alloc.h"
+
 grpc_core::TraceFlag grpc_trace_channel(false, "channel");
 
 /* Memory layouts.
index 7f7cf75..41ea9b5 100644 (file)
@@ -41,6 +41,7 @@ struct grpc_channel_stack_builder {
   grpc_channel_args* args;
   grpc_transport* transport;
   grpc_resource_user* resource_user;
+  size_t preallocated_bytes;
   char* target;
   const char* name;
 };
@@ -174,17 +175,6 @@ grpc_transport* grpc_channel_stack_builder_get_transport(
   return builder->transport;
 }
 
-void grpc_channel_stack_builder_set_resource_user(
-    grpc_channel_stack_builder* builder, grpc_resource_user* resource_user) {
-  GPR_ASSERT(builder->resource_user == nullptr);
-  builder->resource_user = resource_user;
-}
-
-grpc_resource_user* grpc_channel_stack_builder_get_resource_user(
-    grpc_channel_stack_builder* builder) {
-  return builder->resource_user;
-}
-
 bool grpc_channel_stack_builder_append_filter(
     grpc_channel_stack_builder* builder, const grpc_channel_filter* filter,
     grpc_post_filter_create_init_func post_init_func, void* user_data) {
index 6782a14..0071aa9 100644 (file)
@@ -54,14 +54,6 @@ void grpc_channel_stack_builder_set_transport(
 grpc_transport* grpc_channel_stack_builder_get_transport(
     grpc_channel_stack_builder* builder);
 
-/// Attach \a resource_user to the builder (does not take ownership)
-void grpc_channel_stack_builder_set_resource_user(
-    grpc_channel_stack_builder* builder, grpc_resource_user* resource_user);
-
-/// Fetch attached resource user
-grpc_resource_user* grpc_channel_stack_builder_get_resource_user(
-    grpc_channel_stack_builder* builder);
-
 /// Set channel arguments: copies args
 void grpc_channel_stack_builder_set_channel_arguments(
     grpc_channel_stack_builder* builder, const grpc_channel_args* args);
index 5fc0f9a..50f7e19 100644 (file)
 
 #include "src/core/lib/channel/channel_trace.h"
 
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+
 #include <grpc/grpc.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/string_util.h>
-#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
 
 #include "src/core/lib/channel/status_util.h"
 #include "src/core/lib/gpr/string.h"
index 126abc7..663f29e 100644 (file)
@@ -22,6 +22,7 @@
 #include <grpc/impl/codegen/port_platform.h>
 
 #include <grpc/grpc.h>
+
 #include "src/core/lib/gprpp/ref_counted.h"
 #include "src/core/lib/gprpp/ref_counted_ptr.h"
 #include "src/core/lib/iomgr/error.h"
index 452d664..6aaf557 100644 (file)
@@ -24,6 +24,8 @@
 #include <stdlib.h>
 #include <string.h>
 
+#include <atomic>
+
 #include "absl/strings/escaping.h"
 #include "absl/strings/strip.h"
 
@@ -37,7 +39,6 @@
 #include "src/core/lib/channel/status_util.h"
 #include "src/core/lib/gpr/string.h"
 #include "src/core/lib/gpr/useful.h"
-#include "src/core/lib/gprpp/atomic.h"
 #include "src/core/lib/gprpp/host_port.h"
 #include "src/core/lib/gprpp/memory.h"
 #include "src/core/lib/iomgr/error.h"
@@ -86,34 +87,34 @@ CallCountingHelper::CallCountingHelper() {
 void CallCountingHelper::RecordCallStarted() {
   AtomicCounterData& data =
       per_cpu_counter_data_storage_[ExecCtx::Get()->starting_cpu()];
-  data.calls_started.FetchAdd(1, MemoryOrder::RELAXED);
-  data.last_call_started_cycle.Store(gpr_get_cycle_counter(),
-                                     MemoryOrder::RELAXED);
+  data.calls_started.fetch_add(1, std::memory_order_relaxed);
+  data.last_call_started_cycle.store(gpr_get_cycle_counter(),
+                                     std::memory_order_relaxed);
 }
 
 void CallCountingHelper::RecordCallFailed() {
   per_cpu_counter_data_storage_[ExecCtx::Get()->starting_cpu()]
-      .calls_failed.FetchAdd(1, MemoryOrder::RELAXED);
+      .calls_failed.fetch_add(1, std::memory_order_relaxed);
 }
 
 void CallCountingHelper::RecordCallSucceeded() {
   per_cpu_counter_data_storage_[ExecCtx::Get()->starting_cpu()]
-      .calls_succeeded.FetchAdd(1, MemoryOrder::RELAXED);
+      .calls_succeeded.fetch_add(1, std::memory_order_relaxed);
 }
 
 void CallCountingHelper::CollectData(CounterData* out) {
   for (size_t core = 0; core < num_cores_; ++core) {
     AtomicCounterData& data = per_cpu_counter_data_storage_[core];
 
-    out->calls_started += data.calls_started.Load(MemoryOrder::RELAXED);
+    out->calls_started += data.calls_started.load(std::memory_order_relaxed);
     out->calls_succeeded +=
-        per_cpu_counter_data_storage_[core].calls_succeeded.Load(
-            MemoryOrder::RELAXED);
-    out->calls_failed += per_cpu_counter_data_storage_[core].calls_failed.Load(
-        MemoryOrder::RELAXED);
+        per_cpu_counter_data_storage_[core].calls_succeeded.load(
+            std::memory_order_relaxed);
+    out->calls_failed += per_cpu_counter_data_storage_[core].calls_failed.load(
+        std::memory_order_relaxed);
     const gpr_cycle_counter last_call =
-        per_cpu_counter_data_storage_[core].last_call_started_cycle.Load(
-            MemoryOrder::RELAXED);
+        per_cpu_counter_data_storage_[core].last_call_started_cycle.load(
+            std::memory_order_relaxed);
     if (last_call > out->last_call_started_cycle) {
       out->last_call_started_cycle = last_call;
     }
@@ -173,7 +174,7 @@ Json ChannelNode::RenderJson() {
   };
   // Connectivity state.
   // If low-order bit is on, then the field is set.
-  int state_field = connectivity_state_.Load(MemoryOrder::RELAXED);
+  int state_field = connectivity_state_.load(std::memory_order_relaxed);
   if ((state_field & 1) != 0) {
     grpc_connectivity_state state =
         static_cast<grpc_connectivity_state>(state_field >> 1);
@@ -227,7 +228,7 @@ void ChannelNode::PopulateChildRefs(Json::Object* json) {
 void ChannelNode::SetConnectivityState(grpc_connectivity_state state) {
   // Store with low-order bit set to indicate that the field is set.
   int state_field = (state << 1) + 1;
-  connectivity_state_.Store(state_field, MemoryOrder::RELAXED);
+  connectivity_state_.store(state_field, std::memory_order_relaxed);
 }
 
 void ChannelNode::AddChildChannel(intptr_t child_uuid) {
@@ -474,37 +475,38 @@ SocketNode::SocketNode(std::string local, std::string remote, std::string name,
       security_(std::move(security)) {}
 
 void SocketNode::RecordStreamStartedFromLocal() {
-  streams_started_.FetchAdd(1, MemoryOrder::RELAXED);
-  last_local_stream_created_cycle_.Store(gpr_get_cycle_counter(),
-                                         MemoryOrder::RELAXED);
+  streams_started_.fetch_add(1, std::memory_order_relaxed);
+  last_local_stream_created_cycle_.store(gpr_get_cycle_counter(),
+                                         std::memory_order_relaxed);
 }
 
 void SocketNode::RecordStreamStartedFromRemote() {
-  streams_started_.FetchAdd(1, MemoryOrder::RELAXED);
-  last_remote_stream_created_cycle_.Store(gpr_get_cycle_counter(),
-                                          MemoryOrder::RELAXED);
+  streams_started_.fetch_add(1, std::memory_order_relaxed);
+  last_remote_stream_created_cycle_.store(gpr_get_cycle_counter(),
+                                          std::memory_order_relaxed);
 }
 
 void SocketNode::RecordMessagesSent(uint32_t num_sent) {
-  messages_sent_.FetchAdd(num_sent, MemoryOrder::RELAXED);
-  last_message_sent_cycle_.Store(gpr_get_cycle_counter(), MemoryOrder::RELAXED);
+  messages_sent_.fetch_add(num_sent, std::memory_order_relaxed);
+  last_message_sent_cycle_.store(gpr_get_cycle_counter(),
+                                 std::memory_order_relaxed);
 }
 
 void SocketNode::RecordMessageReceived() {
-  messages_received_.FetchAdd(1, MemoryOrder::RELAXED);
-  last_message_received_cycle_.Store(gpr_get_cycle_counter(),
-                                     MemoryOrder::RELAXED);
+  messages_received_.fetch_add(1, std::memory_order_relaxed);
+  last_message_received_cycle_.store(gpr_get_cycle_counter(),
+                                     std::memory_order_relaxed);
 }
 
 Json SocketNode::RenderJson() {
   // Create and fill the data child.
   Json::Object data;
   gpr_timespec ts;
-  int64_t streams_started = streams_started_.Load(MemoryOrder::RELAXED);
+  int64_t streams_started = streams_started_.load(std::memory_order_relaxed);
   if (streams_started != 0) {
     data["streamsStarted"] = std::to_string(streams_started);
     gpr_cycle_counter last_local_stream_created_cycle =
-        last_local_stream_created_cycle_.Load(MemoryOrder::RELAXED);
+        last_local_stream_created_cycle_.load(std::memory_order_relaxed);
     if (last_local_stream_created_cycle != 0) {
       ts = gpr_convert_clock_type(
           gpr_cycle_counter_to_time(last_local_stream_created_cycle),
@@ -512,7 +514,7 @@ Json SocketNode::RenderJson() {
       data["lastLocalStreamCreatedTimestamp"] = gpr_format_timespec(ts);
     }
     gpr_cycle_counter last_remote_stream_created_cycle =
-        last_remote_stream_created_cycle_.Load(MemoryOrder::RELAXED);
+        last_remote_stream_created_cycle_.load(std::memory_order_relaxed);
     if (last_remote_stream_created_cycle != 0) {
       ts = gpr_convert_clock_type(
           gpr_cycle_counter_to_time(last_remote_stream_created_cycle),
@@ -520,33 +522,35 @@ Json SocketNode::RenderJson() {
       data["lastRemoteStreamCreatedTimestamp"] = gpr_format_timespec(ts);
     }
   }
-  int64_t streams_succeeded = streams_succeeded_.Load(MemoryOrder::RELAXED);
+  int64_t streams_succeeded =
+      streams_succeeded_.load(std::memory_order_relaxed);
   if (streams_succeeded != 0) {
     data["streamsSucceeded"] = std::to_string(streams_succeeded);
   }
-  int64_t streams_failed = streams_failed_.Load(MemoryOrder::RELAXED);
+  int64_t streams_failed = streams_failed_.load(std::memory_order_relaxed);
   if (streams_failed != 0) {
     data["streamsFailed"] = std::to_string(streams_failed);
   }
-  int64_t messages_sent = messages_sent_.Load(MemoryOrder::RELAXED);
+  int64_t messages_sent = messages_sent_.load(std::memory_order_relaxed);
   if (messages_sent != 0) {
     data["messagesSent"] = std::to_string(messages_sent);
     ts = gpr_convert_clock_type(
         gpr_cycle_counter_to_time(
-            last_message_sent_cycle_.Load(MemoryOrder::RELAXED)),
+            last_message_sent_cycle_.load(std::memory_order_relaxed)),
         GPR_CLOCK_REALTIME);
     data["lastMessageSentTimestamp"] = gpr_format_timespec(ts);
   }
-  int64_t messages_received = messages_received_.Load(MemoryOrder::RELAXED);
+  int64_t messages_received =
+      messages_received_.load(std::memory_order_relaxed);
   if (messages_received != 0) {
     data["messagesReceived"] = std::to_string(messages_received);
     ts = gpr_convert_clock_type(
         gpr_cycle_counter_to_time(
-            last_message_received_cycle_.Load(MemoryOrder::RELAXED)),
+            last_message_received_cycle_.load(std::memory_order_relaxed)),
         GPR_CLOCK_REALTIME);
     data["lastMessageReceivedTimestamp"] = gpr_format_timespec(ts);
   }
-  int64_t keepalives_sent = keepalives_sent_.Load(MemoryOrder::RELAXED);
+  int64_t keepalives_sent = keepalives_sent_.load(std::memory_order_relaxed);
   if (keepalives_sent != 0) {
     data["keepAlivesSent"] = std::to_string(keepalives_sent);
   }
index b01fe43..e518862 100644 (file)
 
 #include <grpc/impl/codegen/port_platform.h>
 
-#include <grpc/grpc.h>
-
+#include <atomic>
 #include <set>
 #include <string>
 
 #include "absl/container/inlined_vector.h"
 #include "absl/types/optional.h"
 
+#include <grpc/grpc.h>
+
 #include "src/core/lib/channel/channel_trace.h"
 #include "src/core/lib/gpr/time_precise.h"
-#include "src/core/lib/gprpp/atomic.h"
 #include "src/core/lib/gprpp/manual_constructor.h"
 #include "src/core/lib/gprpp/ref_counted.h"
 #include "src/core/lib/gprpp/ref_counted_ptr.h"
@@ -134,19 +134,19 @@ class CallCountingHelper {
     // Define the ctors so that we can use this structure in InlinedVector.
     AtomicCounterData() = default;
     AtomicCounterData(const AtomicCounterData& that)
-        : calls_started(that.calls_started.Load(MemoryOrder::RELAXED)),
-          calls_succeeded(that.calls_succeeded.Load(MemoryOrder::RELAXED)),
-          calls_failed(that.calls_failed.Load(MemoryOrder::RELAXED)),
+        : calls_started(that.calls_started.load(std::memory_order_relaxed)),
+          calls_succeeded(that.calls_succeeded.load(std::memory_order_relaxed)),
+          calls_failed(that.calls_failed.load(std::memory_order_relaxed)),
           last_call_started_cycle(
-              that.last_call_started_cycle.Load(MemoryOrder::RELAXED)) {}
+              that.last_call_started_cycle.load(std::memory_order_relaxed)) {}
 
-    Atomic<int64_t> calls_started{0};
-    Atomic<int64_t> calls_succeeded{0};
-    Atomic<int64_t> calls_failed{0};
-    Atomic<gpr_cycle_counter> last_call_started_cycle{0};
+    std::atomic<int64_t> calls_started{0};
+    std::atomic<int64_t> calls_succeeded{0};
+    std::atomic<int64_t> calls_failed{0};
+    std::atomic<gpr_cycle_counter> last_call_started_cycle{0};
     // Make sure the size is exactly one cache line.
-    uint8_t padding[GPR_CACHELINE_SIZE - 3 * sizeof(Atomic<intptr_t>) -
-                    sizeof(Atomic<gpr_cycle_counter>)];
+    uint8_t padding[GPR_CACHELINE_SIZE - 3 * sizeof(std::atomic<intptr_t>) -
+                    sizeof(std::atomic<gpr_cycle_counter>)];
   };
   // TODO(soheilhy,veblush): Revist this after abseil integration.
   // This has a problem when using abseil inlined_vector because it
@@ -220,7 +220,7 @@ class ChannelNode : public BaseNode {
 
   // Least significant bit indicates whether the value is set.  Remaining
   // bits are a grpc_connectivity_state value.
-  Atomic<int> connectivity_state_{0};
+  std::atomic<int> connectivity_state_{0};
 
   Mutex child_mu_;  // Guards sets below.
   std::set<intptr_t> child_channels_;
@@ -310,30 +310,30 @@ class SocketNode : public BaseNode {
   void RecordStreamStartedFromLocal();
   void RecordStreamStartedFromRemote();
   void RecordStreamSucceeded() {
-    streams_succeeded_.FetchAdd(1, MemoryOrder::RELAXED);
+    streams_succeeded_.fetch_add(1, std::memory_order_relaxed);
   }
   void RecordStreamFailed() {
-    streams_failed_.FetchAdd(1, MemoryOrder::RELAXED);
+    streams_failed_.fetch_add(1, std::memory_order_relaxed);
   }
   void RecordMessagesSent(uint32_t num_sent);
   void RecordMessageReceived();
   void RecordKeepaliveSent() {
-    keepalives_sent_.FetchAdd(1, MemoryOrder::RELAXED);
+    keepalives_sent_.fetch_add(1, std::memory_order_relaxed);
   }
 
   const std::string& remote() { return remote_; }
 
  private:
-  Atomic<int64_t> streams_started_{0};
-  Atomic<int64_t> streams_succeeded_{0};
-  Atomic<int64_t> streams_failed_{0};
-  Atomic<int64_t> messages_sent_{0};
-  Atomic<int64_t> messages_received_{0};
-  Atomic<int64_t> keepalives_sent_{0};
-  Atomic<gpr_cycle_counter> last_local_stream_created_cycle_{0};
-  Atomic<gpr_cycle_counter> last_remote_stream_created_cycle_{0};
-  Atomic<gpr_cycle_counter> last_message_sent_cycle_{0};
-  Atomic<gpr_cycle_counter> last_message_received_cycle_{0};
+  std::atomic<int64_t> streams_started_{0};
+  std::atomic<int64_t> streams_succeeded_{0};
+  std::atomic<int64_t> streams_failed_{0};
+  std::atomic<int64_t> messages_sent_{0};
+  std::atomic<int64_t> messages_received_{0};
+  std::atomic<int64_t> keepalives_sent_{0};
+  std::atomic<gpr_cycle_counter> last_local_stream_created_cycle_{0};
+  std::atomic<gpr_cycle_counter> last_remote_stream_created_cycle_{0};
+  std::atomic<gpr_cycle_counter> last_message_sent_cycle_{0};
+  std::atomic<gpr_cycle_counter> last_message_received_cycle_{0};
   std::string local_;
   std::string remote_;
   RefCountedPtr<Security> const security_;
index c76b5b4..d801600 100644 (file)
 
 #include <grpc/impl/codegen/port_platform.h>
 
+#include "src/core/lib/channel/channelz_registry.h"
+
 #include <algorithm>
 #include <cstring>
 
 #include "absl/container/inlined_vector.h"
 
+#include <grpc/support/alloc.h>
+#include <grpc/support/log.h>
+#include <grpc/support/string_util.h>
+#include <grpc/support/sync.h>
+
 #include "src/core/lib/channel/channel_trace.h"
 #include "src/core/lib/channel/channelz.h"
-#include "src/core/lib/channel/channelz_registry.h"
 #include "src/core/lib/gpr/useful.h"
 #include "src/core/lib/gprpp/memory.h"
 #include "src/core/lib/gprpp/sync.h"
 
-#include <grpc/support/alloc.h>
-#include <grpc/support/log.h>
-#include <grpc/support/string_util.h>
-#include <grpc/support/sync.h>
-
 namespace grpc_core {
 namespace channelz {
 namespace {
index 12b3d78..2d4eace 100644 (file)
@@ -28,6 +28,7 @@
 #include <grpc/slice_buffer.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
+
 #include "src/core/lib/gpr/string.h"
 #include "src/core/lib/profiling/timers.h"
 #include "src/core/lib/transport/transport.h"
index 632d286..7ebed4b 100644 (file)
@@ -18,6 +18,8 @@
 
 #include <grpc/support/port_platform.h>
 
+#include "src/core/lib/channel/handshaker.h"
+
 #include <string.h>
 
 #include "absl/strings/str_format.h"
@@ -28,7 +30,6 @@
 #include <grpc/support/string_util.h>
 
 #include "src/core/lib/channel/channel_args.h"
-#include "src/core/lib/channel/handshaker.h"
 #include "src/core/lib/debug/trace.h"
 #include "src/core/lib/iomgr/timer.h"
 #include "src/core/lib/slice/slice_internal.h"
index b6b69da..ad2606d 100644 (file)
@@ -23,9 +23,8 @@
 
 #include "absl/container/inlined_vector.h"
 
-#include <grpc/support/string_util.h>
-
 #include <grpc/impl/codegen/grpc_types.h>
+#include <grpc/support/string_util.h>
 
 #include "src/core/lib/channel/channel_args.h"
 #include "src/core/lib/gprpp/ref_counted.h"
index 520e5e4..0d55a6d 100644 (file)
 
 #include <grpc/impl/codegen/grpc_types.h>
 
-#include "src/core/lib/channel/handshaker.h"
-
 // A handshaker factory is used to create handshakers.
 
+// TODO(ctiller): grpc_pollset_set and HandshakeManager are forward declared in
+// this file. grpc_pollset_set ought to be eliminated when EventEngine lands IO
+// support. At the same time, we ought to be able to include handshake_manager.h
+// here and eliminate the HandshakeManager dependency - we cannot right now
+// because HandshakeManager names too many iomgr types.
+
+typedef struct grpc_pollset_set grpc_pollset_set;
+
 namespace grpc_core {
 
+class HandshakeManager;
+
 class HandshakerFactory {
  public:
   virtual void AddHandshakers(const grpc_channel_args* args,
index c2a8373..d9d7bc9 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include "absl/container/inlined_vector.h"
-
 #include "src/core/lib/channel/handshaker_registry.h"
-#include "src/core/lib/gpr/alloc.h"
-#include "src/core/lib/gprpp/memory.h"
-
-#include <string.h>
-#include <algorithm>
-
-#include <grpc/support/alloc.h>
-
-//
-// grpc_handshaker_factory_list
-//
 
 namespace grpc_core {
 
-namespace {
-
-class HandshakerFactoryList {
- public:
-  void Register(bool at_start, std::unique_ptr<HandshakerFactory> factory);
-  void AddHandshakers(const grpc_channel_args* args,
-                      grpc_pollset_set* interested_parties,
-                      HandshakeManager* handshake_mgr);
-
- private:
-  absl::InlinedVector<std::unique_ptr<HandshakerFactory>, 2> factories_;
-};
-
-HandshakerFactoryList* g_handshaker_factory_lists = nullptr;
-
-}  // namespace
-
-void HandshakerFactoryList::Register(
-    bool at_start, std::unique_ptr<HandshakerFactory> factory) {
-  factories_.push_back(std::move(factory));
-  if (at_start) {
-    auto* end = &factories_[factories_.size() - 1];
-    std::rotate(&factories_[0], end, end + 1);
-  }
+void HandshakerRegistry::Builder::RegisterHandshakerFactory(
+    bool at_start, HandshakerType handshaker_type,
+    std::unique_ptr<HandshakerFactory> factory) {
+  auto& vec = factories_[handshaker_type];
+  auto where = at_start ? vec.begin() : vec.end();
+  vec.insert(where, std::move(factory));
 }
 
-void HandshakerFactoryList::AddHandshakers(const grpc_channel_args* args,
-                                           grpc_pollset_set* interested_parties,
-                                           HandshakeManager* handshake_mgr) {
-  for (size_t idx = 0; idx < factories_.size(); ++idx) {
-    auto& handshaker_factory = factories_[idx];
-    handshaker_factory->AddHandshakers(args, interested_parties, handshake_mgr);
+HandshakerRegistry HandshakerRegistry::Builder::Build() {
+  HandshakerRegistry out;
+  for (size_t i = 0; i < NUM_HANDSHAKER_TYPES; i++) {
+    out.factories_[i] = std::move(factories_[i]);
   }
-}
-
-//
-// plugin
-//
-
-void HandshakerRegistry::Init() {
-  GPR_ASSERT(g_handshaker_factory_lists == nullptr);
-  g_handshaker_factory_lists = new HandshakerFactoryList[NUM_HANDSHAKER_TYPES];
-}
-
-void HandshakerRegistry::Shutdown() {
-  GPR_ASSERT(g_handshaker_factory_lists != nullptr);
-  delete[] g_handshaker_factory_lists;
-  g_handshaker_factory_lists = nullptr;
-}
-
-void HandshakerRegistry::RegisterHandshakerFactory(
-    bool at_start, HandshakerType handshaker_type,
-    std::unique_ptr<HandshakerFactory> factory) {
-  GPR_ASSERT(g_handshaker_factory_lists != nullptr);
-  auto& factory_list = g_handshaker_factory_lists[handshaker_type];
-  factory_list.Register(at_start, std::move(factory));
+  return out;
 }
 
 void HandshakerRegistry::AddHandshakers(HandshakerType handshaker_type,
                                         const grpc_channel_args* args,
                                         grpc_pollset_set* interested_parties,
-                                        HandshakeManager* handshake_mgr) {
-  GPR_ASSERT(g_handshaker_factory_lists != nullptr);
-  auto& factory_list = g_handshaker_factory_lists[handshaker_type];
-  factory_list.AddHandshakers(args, interested_parties, handshake_mgr);
+                                        HandshakeManager* handshake_mgr) const {
+  for (const auto& factory : factories_[handshaker_type]) {
+    factory->AddHandshakers(args, interested_parties, handshake_mgr);
+  }
 }
 
 }  // namespace grpc_core
index 4a02efc..ccd6141 100644 (file)
@@ -21,6 +21,9 @@
 
 #include <grpc/support/port_platform.h>
 
+#include <memory>
+#include <vector>
+
 #include <grpc/impl/codegen/grpc_types.h>
 
 #include "src/core/lib/channel/handshaker_factory.h"
@@ -35,18 +38,32 @@ typedef enum {
 
 class HandshakerRegistry {
  public:
-  /// Registers a new handshaker factory.  Takes ownership.
-  /// If \a at_start is true, the new handshaker will be at the beginning of
-  /// the list.  Otherwise, it will be added to the end.
-  static void RegisterHandshakerFactory(
-      bool at_start, HandshakerType handshaker_type,
-      std::unique_ptr<HandshakerFactory> factory);
-  static void AddHandshakers(HandshakerType handshaker_type,
-                             const grpc_channel_args* args,
-                             grpc_pollset_set* interested_parties,
-                             HandshakeManager* handshake_mgr);
-  static void Init();
-  static void Shutdown();
+  class Builder {
+   public:
+    /// Registers a new handshaker factory.  Takes ownership.
+    /// If \a at_start is true, the new handshaker will be at the beginning of
+    /// the list.  Otherwise, it will be added to the end.
+    void RegisterHandshakerFactory(bool at_start,
+                                   HandshakerType handshaker_type,
+                                   std::unique_ptr<HandshakerFactory> factory);
+
+    HandshakerRegistry Build();
+
+   private:
+    std::vector<std::unique_ptr<HandshakerFactory>>
+        factories_[NUM_HANDSHAKER_TYPES];
+  };
+
+  void AddHandshakers(HandshakerType handshaker_type,
+                      const grpc_channel_args* args,
+                      grpc_pollset_set* interested_parties,
+                      HandshakeManager* handshake_mgr) const;
+
+ private:
+  HandshakerRegistry() = default;
+
+  std::vector<std::unique_ptr<HandshakerFactory>>
+      factories_[NUM_HANDSHAKER_TYPES];
 };
 
 }  // namespace grpc_core
index bab6537..b9245f2 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include <grpc/status.h>
-
 #include <stdbool.h>
 #include <string.h>
 
+#include <grpc/status.h>
+
 /// If \a status_str is a valid status string, sets \a status to the
 /// corresponding status value and returns true.
 bool grpc_status_code_from_string(const char* status_str,
index d58d2f5..d053d12 100644 (file)
@@ -22,6 +22,7 @@
 #include <grpc/support/port_platform.h>
 
 #include <grpc/compression.h>
+
 #include "src/core/lib/compression/compression_internal.h"
 #include "src/core/lib/transport/metadata.h"
 
index 03e1a88..90aa578 100644 (file)
@@ -18,6 +18,8 @@
 
 #include <grpc/support/port_platform.h>
 
+#include "src/core/lib/compression/compression_args.h"
+
 #include <limits.h>
 #include <string.h>
 
@@ -28,7 +30,6 @@
 #include <grpc/support/string_util.h>
 
 #include "src/core/lib/channel/channel_args.h"
-#include "src/core/lib/compression/compression_args.h"
 #include "src/core/lib/gpr/string.h"
 #include "src/core/lib/gpr/useful.h"
 
index 50750f8..cce8ddc 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
+#include "src/core/lib/compression/compression_internal.h"
+
 #include <stdlib.h>
 #include <string.h>
 
 #include <grpc/compression.h>
 
 #include "src/core/lib/compression/algorithm_metadata.h"
-#include "src/core/lib/compression/compression_internal.h"
 #include "src/core/lib/gpr/useful.h"
 #include "src/core/lib/slice/slice_utils.h"
 #include "src/core/lib/surface/api_trace.h"
@@ -168,7 +169,6 @@ int grpc_compression_algorithm_from_message_stream_compression_algorithm(
         return 0;
     }
   }
-  return 0;
 }
 
 /* Interfaces for message compression. */
@@ -265,7 +265,6 @@ int grpc_message_compression_algorithm_parse(
   } else {
     return 0;
   }
-  return 0;
 }
 
 /* Interfaces for stream compression. */
@@ -281,5 +280,4 @@ int grpc_stream_compression_algorithm_parse(
   } else {
     return 0;
   }
-  return 0;
 }
index 7c2a70b..797d5ed 100644 (file)
 
 #include <string.h>
 
+#include <zlib.h>
+
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 
-#include <zlib.h>
-
 #include "src/core/lib/slice/slice_internal.h"
 
 #define OUTPUT_BLOCK_SIZE 1024
index e085798..d827aeb 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
+#include "src/core/lib/compression/stream_compression.h"
+
 #include <grpc/support/log.h>
 
-#include "src/core/lib/compression/stream_compression.h"
 #include "src/core/lib/compression/stream_compression_gzip.h"
 #include "src/core/lib/slice/slice_utils.h"
 
index 10ae156..cfa1bf0 100644 (file)
 
 #include <stdbool.h>
 
-#include <grpc/slice_buffer.h>
 #include <zlib.h>
 
+#include <grpc/slice_buffer.h>
+
 #include "src/core/lib/transport/static_metadata.h"
 
 typedef struct grpc_stream_compression_vtable grpc_stream_compression_vtable;
index 452b22b..92a44ea 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
+#include "src/core/lib/compression/stream_compression_gzip.h"
+
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 
-#include "src/core/lib/compression/stream_compression_gzip.h"
 #include "src/core/lib/iomgr/exec_ctx.h"
 #include "src/core/lib/slice/slice_internal.h"
 
index 78486f0..adef4c4 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
+#include "src/core/lib/compression/stream_compression_identity.h"
+
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 
-#include "src/core/lib/compression/stream_compression_identity.h"
 #include "src/core/lib/slice/slice_internal.h"
 
 #define OUTPUT_BLOCK_SIZE (1024)
diff --git a/src/core/lib/config/core_configuration.cc b/src/core/lib/config/core_configuration.cc
new file mode 100644 (file)
index 0000000..61f29e1
--- /dev/null
@@ -0,0 +1,54 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#include <grpc/impl/codegen/port_platform.h>
+
+#include "src/core/lib/config/core_configuration.h"
+
+namespace grpc_core {
+
+std::atomic<CoreConfiguration*> CoreConfiguration::config_{nullptr};
+
+CoreConfiguration::Builder::Builder() = default;
+
+CoreConfiguration* CoreConfiguration::Builder::Build() {
+  return new CoreConfiguration(this);
+}
+
+CoreConfiguration::CoreConfiguration(Builder* builder)
+    : handshaker_registry_(builder->handshaker_registry_.Build()) {}
+
+const CoreConfiguration& CoreConfiguration::BuildNewAndMaybeSet() {
+  // Construct builder, pass it up to code that knows about build configuration
+  Builder builder;
+  BuildCoreConfiguration(&builder);
+  // Use builder to construct a confguration
+  CoreConfiguration* p = builder.Build();
+  // Try to set configuration global - it's possible another thread raced us
+  // here, in which case we drop the work we did and use the one that got set
+  // first
+  CoreConfiguration* expected = nullptr;
+  if (!config_.compare_exchange_strong(expected, p, std::memory_order_acq_rel,
+                                       std::memory_order_acquire)) {
+    delete p;
+    return *expected;
+  }
+  return *p;
+}
+
+void CoreConfiguration::Reset() {
+  delete config_.exchange(nullptr, std::memory_order_acquire);
+}
+
+}  // namespace grpc_core
diff --git a/src/core/lib/config/core_configuration.h b/src/core/lib/config/core_configuration.h
new file mode 100644 (file)
index 0000000..db8530b
--- /dev/null
@@ -0,0 +1,108 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#ifndef GRPC_CORE_LIB_CONFIG_CORE_CONFIGURATION_H
+#define GRPC_CORE_LIB_CONFIG_CORE_CONFIGURATION_H
+
+#include <grpc/impl/codegen/port_platform.h>
+
+#include <atomic>
+
+#include "src/core/lib/channel/handshaker_registry.h"
+
+namespace grpc_core {
+
+// Global singleton that stores library configuration - factories, etc...
+// that plugins might choose to extend.
+class CoreConfiguration {
+ public:
+  CoreConfiguration(const CoreConfiguration&) = delete;
+  CoreConfiguration& operator=(const CoreConfiguration&) = delete;
+
+  // Builder is passed to plugins, etc... at initialization time to collect
+  // their configuration and assemble the published CoreConfiguration.
+  class Builder {
+   public:
+    HandshakerRegistry::Builder* handshaker_registry() {
+      return &handshaker_registry_;
+    }
+
+   private:
+    friend class CoreConfiguration;
+
+    HandshakerRegistry::Builder handshaker_registry_;
+
+    Builder();
+    CoreConfiguration* Build();
+  };
+
+  // Lifetime methods
+
+  // Get the core configuration; if it does not exist, create it.
+  static const CoreConfiguration& Get() {
+    CoreConfiguration* p = config_.load(std::memory_order_acquire);
+    if (p != nullptr) {
+      return *p;
+    }
+    return BuildNewAndMaybeSet();
+  }
+
+  // Build a special core configuration.
+  // Requires no concurrent Get() be called.
+  // Doesn't call the regular BuildCoreConfiguration function, instead calls
+  // `build`.
+  // BuildFunc is a callable that takes a Builder* and returns void.
+  // We use a template instead of std::function<void(Builder*)> to avoid
+  // including std::function in this widely used header, and to ensure no code
+  // is generated in programs that do not use this function.
+  // This is sometimes useful for testing.
+  template <typename BuildFunc>
+  static void BuildSpecialConfiguration(BuildFunc build) {
+    // Build bespoke configuration
+    Builder builder;
+    build(&builder);
+    CoreConfiguration* p = builder.Build();
+    // Swap in final configuration, deleting anything that was already present.
+    delete config_.exchange(p, std::memory_order_release);
+  }
+
+  // Drop the core configuration. Users must ensure no other threads are
+  // accessing the configuration.
+  // Clears any dynamically registered builders.
+  static void Reset();
+
+  // Accessors
+
+  const HandshakerRegistry& handshaker_registry() const {
+    return handshaker_registry_;
+  }
+
+ private:
+  explicit CoreConfiguration(Builder* builder);
+
+  // Create a new CoreConfiguration, and either set it or throw it away.
+  // We allow multiple CoreConfiguration's to be created in parallel.
+  static const CoreConfiguration& BuildNewAndMaybeSet();
+
+  // The configuration
+  static std::atomic<CoreConfiguration*> config_;
+
+  HandshakerRegistry handshaker_registry_;
+};
+
+extern void BuildCoreConfiguration(CoreConfiguration::Builder* builder);
+
+}  // namespace grpc_core
+
+#endif /* GRPC_CORE_LIB_CONFIG_CORE_CONFIGURATION_H */
index be17ac5..cafaa64 100644 (file)
@@ -24,6 +24,7 @@
 #include <string>
 
 #include <grpc/support/atm.h>
+
 #include "src/core/lib/debug/stats_data.h"
 #include "src/core/lib/iomgr/exec_ctx.h"
 
index ceacc57..31bd742 100644 (file)
@@ -20,8 +20,9 @@
 
 #include <grpc/support/port_platform.h>
 
-#include "src/core/lib/debug/stats.h"
 #include "src/core/lib/debug/stats_data.h"
+
+#include "src/core/lib/debug/stats.h"
 #include "src/core/lib/gpr/useful.h"
 #include "src/core/lib/iomgr/exec_ctx.h"
 
index c1356c4..61c3d10 100644 (file)
@@ -24,6 +24,7 @@
 #include <grpc/support/port_platform.h>
 
 #include <inttypes.h>
+
 #include "src/core/lib/iomgr/exec_ctx.h"
 
 typedef enum {
index 84c0a38..87b6144 100644 (file)
@@ -21,6 +21,7 @@
 #include "src/core/lib/debug/trace.h"
 
 #include <string.h>
+
 #include <type_traits>
 
 #include <grpc/grpc.h>
index ac7b40e..d788541 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include <grpc/support/atm.h>
 #include <stdbool.h>
 
+#include <grpc/support/atm.h>
+
 #include "src/core/lib/gprpp/global_config.h"
 
 GPR_GLOBAL_CONFIG_DECLARE_STRING(grpc_trace);
index 78d28ec..ca6438d 100644 (file)
@@ -14,7 +14,6 @@
 #include <grpc/support/port_platform.h>
 
 #include <grpc/event_engine/endpoint_config.h>
-
 #include <grpc/impl/codegen/grpc_types.h>
 #include <grpc/impl/codegen/log.h>
 
index cfc270c..cce18ab 100644 (file)
 // limitations under the License.
 #include <grpc/support/port_platform.h>
 
+#include "absl/strings/str_format.h"
+#include "absl/strings/str_join.h"
+
 #include <grpc/event_engine/endpoint_config.h>
 #include <grpc/event_engine/event_engine.h>
 #include <grpc/event_engine/port.h>
 #include <grpc/impl/codegen/grpc_types.h>
 #include <grpc/support/log.h>
 
-#include "absl/strings/str_format.h"
-#include "absl/strings/str_join.h"
-
 #include "src/core/lib/event_engine/sockaddr.h"
 
 namespace grpc_event_engine {
index 9a784bd..dab44f9 100644 (file)
@@ -16,9 +16,9 @@
 #ifdef GRPC_USE_EVENT_ENGINE
 #include <string.h>
 
-#include "grpc/event_engine/event_engine.h"
-#include "grpc/event_engine/port.h"
-#include "grpc/support/log.h"
+#include <grpc/event_engine/event_engine.h>
+#include <grpc/event_engine/port.h>
+#include <grpc/support/log.h>
 
 uint16_t grpc_htons(uint16_t hostshort) { return htons(hostshort); }
 
index 5bfdc8d..9a46ff8 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include <grpc/support/alloc.h>
-
-#include <grpc/support/log.h>
 #include <stdlib.h>
 #include <string.h>
+
+#include <grpc/support/alloc.h>
+#include <grpc/support/log.h>
+
 #include "src/core/lib/profiling/timers.h"
 
 void* gpr_malloc(size_t size) {
index 6a78dc1..4b33246 100644 (file)
@@ -25,8 +25,6 @@
 
 #ifdef GPR_LINUX_ENV
 
-#include "src/core/lib/gpr/env.h"
-
 #include <dlfcn.h>
 #include <features.h>
 #include <stdlib.h>
@@ -35,6 +33,7 @@
 #include <grpc/support/log.h>
 #include <grpc/support/string_util.h>
 
+#include "src/core/lib/gpr/env.h"
 #include "src/core/lib/gpr/string.h"
 #include "src/core/lib/gpr/useful.h"
 
index 232095b..fb2a21c 100644 (file)
 
 #ifdef GPR_POSIX_ENV
 
-#include "src/core/lib/gpr/env.h"
-
 #include <stdlib.h>
 
 #include <grpc/support/log.h>
-
 #include <grpc/support/string_util.h>
+
+#include "src/core/lib/gpr/env.h"
 #include "src/core/lib/gpr/string.h"
 
 char* gpr_getenv(const char* name) {
index 9400f7c..d18f52b 100644 (file)
@@ -18,6 +18,9 @@
 
 #include <grpc/support/port_platform.h>
 
+#include <stdio.h>
+#include <string.h>
+
 #include <grpc/support/alloc.h>
 #include <grpc/support/atm.h>
 #include <grpc/support/log.h>
@@ -25,9 +28,6 @@
 #include "src/core/lib/gpr/string.h"
 #include "src/core/lib/gprpp/global_config.h"
 
-#include <stdio.h>
-#include <string.h>
-
 #ifndef GPR_DEFAULT_LOG_VERBOSITY_STRING
 #define GPR_DEFAULT_LOG_VERBOSITY_STRING "ERROR"
 #endif  // !GPR_DEFAULT_LOG_VERBOSITY_STRING
index 40ef4c6..11ffd64 100644 (file)
 #ifdef GPR_ANDROID
 
 #include <android/log.h>
-#include <grpc/support/log.h>
-#include <grpc/support/time.h>
 #include <stdarg.h>
 #include <stdio.h>
 #include <string.h>
 
+#include <grpc/support/log.h>
+#include <grpc/support/time.h>
+
 static android_LogPriority severity_to_log_priority(gpr_log_severity severity) {
   switch (severity) {
     case GPR_LOG_SEVERITY_DEBUG:
index 6f64faa..850ee13 100644 (file)
@@ -28,9 +28,6 @@
 
 #ifdef GPR_LINUX_LOG
 
-#include <grpc/support/alloc.h>
-#include <grpc/support/log.h>
-#include <grpc/support/time.h>
 #include <inttypes.h>
 #include <stdarg.h>
 #include <stdio.h>
 #include <string>
 
 #include "absl/strings/str_format.h"
+
+#include <grpc/support/alloc.h>
+#include <grpc/support/log.h>
+#include <grpc/support/time.h>
+
+#include "src/core/lib/gpr/tls.h"
 #include "src/core/lib/gprpp/examine_stack.h"
 
 int gpr_should_log_stacktrace(gpr_log_severity severity);
@@ -74,7 +77,7 @@ void gpr_default_log(gpr_log_func_args* args) {
   time_t timer;
   gpr_timespec now = gpr_now(GPR_CLOCK_REALTIME);
   struct tm tm;
-  static __thread long tid = 0;
+  static GPR_THREAD_LOCAL(long) tid(0);
   if (tid == 0) tid = sys_gettid();
 
   timer = static_cast<time_t>(now.tv_sec);
index 4bd6117..2c28bdd 100644 (file)
 
 #ifdef GPR_POSIX_LOG
 
-#include <grpc/support/alloc.h>
-#include <grpc/support/log.h>
-#include <grpc/support/time.h>
 #include <inttypes.h>
 #include <pthread.h>
 #include <stdarg.h>
 #include <stdio.h>
 #include <string.h>
 #include <time.h>
+
 #include <string>
 
 #include "absl/strings/str_format.h"
+
+#include <grpc/support/alloc.h>
+#include <grpc/support/log.h>
+#include <grpc/support/time.h>
+
 #include "src/core/lib/gprpp/examine_stack.h"
 
 int gpr_should_log_stacktrace(gpr_log_severity severity);
index 8695331..3337560 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include <grpc/impl/codegen/gpr_types.h>
-
 #include <stdbool.h>
 #include <stddef.h>
 
 #include <string>
 
+#include <grpc/impl/codegen/gpr_types.h>
+
 /* String utility functions */
 
 /* Flags for gpr_dump function. */
index 36c35da..28d506f 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
+#include <assert.h>
+
 #include <grpc/support/atm.h>
 #include <grpc/support/log.h>
 #include <grpc/support/sync.h>
 
-#include <assert.h>
-
 /* Number of mutexes to allocate for events, to avoid lock contention.
    Should be a prime. */
 enum { event_sync_partitions = 31 };
index 0da9caa..1633336 100644 (file)
 
 #if defined(GPR_ABSEIL_SYNC) && !defined(GPR_CUSTOM_SYNC)
 
-#include <grpc/support/alloc.h>
-
 #include <errno.h>
-#include <grpc/support/log.h>
-#include <grpc/support/sync.h>
-#include <grpc/support/time.h>
 #include <time.h>
-#include "src/core/lib/profiling/timers.h"
 
 #include "absl/base/call_once.h"
 #include "absl/synchronization/mutex.h"
 #include "absl/time/clock.h"
 #include "absl/time/time.h"
 
+#include <grpc/support/alloc.h>
+#include <grpc/support/log.h>
+#include <grpc/support/sync.h>
+#include <grpc/support/time.h>
+
+#include "src/core/lib/profiling/timers.h"
+
 #ifdef GPR_LOW_LEVEL_COUNTERS
 gpr_atm gpr_mu_locks = 0;
 gpr_atm gpr_counter_atm_cas = 0;
index fdd278b..7ed5403 100644 (file)
 #if defined(GPR_POSIX_SYNC) && !defined(GPR_ABSEIL_SYNC) && \
     !defined(GPR_CUSTOM_SYNC)
 
+#include <errno.h>
+#include <time.h>
+
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/sync.h>
 #include <grpc/support/time.h>
 
-#include <errno.h>
-#include <time.h>
-
 #include "src/core/lib/profiling/timers.h"
 
 #ifdef GPR_LOW_LEVEL_COUNTERS
index 14df70d..d796f41 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include <grpc/support/log.h>
-#include <grpc/support/time.h>
 #include <limits.h>
 #include <stdio.h>
 #include <string.h>
 
+#include <grpc/support/log.h>
+#include <grpc/support/time.h>
+
 int gpr_time_cmp(gpr_timespec a, gpr_timespec b) {
   int cmp = (a.tv_sec > b.tv_sec) - (a.tv_sec < b.tv_sec);
   GPR_ASSERT(a.clock_type == b.clock_type);
index 247cc16..39bca1b 100644 (file)
 
 #ifdef GPR_WINDOWS_TIME
 
-#include <grpc/support/log.h>
-#include <grpc/support/time.h>
 #include <limits.h>
 #include <process.h>
 #include <sys/timeb.h>
 
+#include <grpc/support/log.h>
+#include <grpc/support/time.h>
+
 #include "src/core/lib/gpr/time_precise.h"
 
 static LARGE_INTEGER g_start_time;
index 5eb6951..32add50 100644 (file)
 #ifndef GRPC_CORE_LIB_GPR_TLS_H
 #define GRPC_CORE_LIB_GPR_TLS_H
 
-#include <grpc/support/port_platform.h>
+#include <grpc/impl/codegen/port_platform.h>
 
-/** Thread local storage.
-
-   A minimal wrapper that should be implementable across many compilers,
-   and implementable efficiently across most modern compilers.
-
-   Thread locals have type intptr_t.
-
-   Declaring a thread local variable 'foo':
-     GPR_TLS_DECL(foo);
-   Thread locals always have static scope.
-
-   Declaring a thread local class variable 'foo':
-     GPR_TLS_CLASS_DECL(foo);
-
-   Defining the thread local class variable:
-     GPR_TLS_CLASS_DEF(foo);
-
-   Initializing a thread local (must be done at library initialization
-   time):
-     gpr_tls_init(&foo);
+#include <type_traits>
 
-   Destroying a thread local:
-     gpr_tls_destroy(&foo);
-
-   Setting a thread local (returns new_value):
-     gpr_tls_set(&foo, new_value);
+/** Thread local storage.
 
-   Accessing a thread local:
-     current_value = gpr_tls_get(&foo);
+   Usage is the same as C++ thread_local. Declaring a thread local:
+     static GPR_THREAD_LOCAL(uint32_t) foo;
 
    ALL functions here may be implemented as macros. */
 
-#ifdef GPR_STDCPP_TLS
-#include "src/core/lib/gpr/tls_stdcpp.h"
-#endif
-
-#ifdef GPR_GCC_TLS
-#include "src/core/lib/gpr/tls_gcc.h"
-#endif
-
-#ifdef GPR_MSVC_TLS
-#include "src/core/lib/gpr/tls_msvc.h"
-#endif
+namespace grpc_core {
+
+// This class is never instantiated. It exists to statically ensure that all
+// TLS usage is compatible with the most restrictive implementation, allowing
+// developers to write correct code regardless of the platform they develop on.
+template <typename T>
+class TlsTypeConstrainer {
+  static_assert(std::is_trivial<T>::value,
+                "TLS support is limited to trivial types");
+
+ public:
+  using Type = T;
+};
+
+}  // namespace grpc_core
+
+#if defined(GPR_PTHREAD_TLS)
+
+#include <pthread.h>
+
+#include <array>
+#include <cstring>
+
+#include <grpc/support/log.h> /* for GPR_ASSERT */
+
+namespace grpc_core {
+
+template <typename T>
+class PthreadTlsImpl : TlsTypeConstrainer<T> {
+ public:
+  PthreadTlsImpl(const PthreadTlsImpl&) = delete;
+  PthreadTlsImpl& operator=(const PthreadTlsImpl&) = delete;
+
+  // Achtung! This class emulates C++ `thread_local` using pthread keys. Each
+  // instance of this class is a stand in for a C++ `thread_local`. Think of
+  // each `thread_local` as a *global* pthread_key_t and a type tag. An
+  // important consequence of this is that the lifetime of a `pthread_key_t`
+  // is precisely the lifetime of an instance of this class. To understand why
+  // this is, consider the following scenario given a fictional implementation
+  // of this class which creates and destroys its `pthread_key_t` each time
+  // a given block of code runs (all actions take place on a single thread):
+  //
+  // - instance 1 (type tag = T*) is initialized, is assigned `pthread_key_t` 1
+  // - instance 2 (type tag = int) is initialized, is assigned `pthread_key_t` 2
+  // - instances 1 and 2 store and retrieve values; all is well
+  // - instances 1 and 2 are de-initialized; their keys are released to the pool
+  //
+  // - another run commences
+  // - instance 1 receives key 2
+  // - a value is read from instance 1, it observes a value of type int, but
+  //   interprets it as T*; undefined behavior, kaboom
+  //
+  // To properly ensure these invariants are upheld the `pthread_key_t` must be
+  // `const`, which means it can only be released in the destructor. This is a
+  // a violation of the style guide, since these objects are always static (see
+  // footnote) but this code is used in sufficiently narrow circumstances to
+  // justify the deviation.
+  //
+  // https://google.github.io/styleguide/cppguide.html#Static_and_Global_Variables
+  PthreadTlsImpl()
+      : keys_([]() {
+          typename std::remove_const<decltype(PthreadTlsImpl::keys_)>::type
+              keys;
+          for (pthread_key_t& key : keys) {
+            GPR_ASSERT(0 == pthread_key_create(&key, nullptr));
+          }
+          return keys;
+        }()) {}
+  PthreadTlsImpl(T t) : PthreadTlsImpl() { *this = t; }
+  ~PthreadTlsImpl() {
+    for (pthread_key_t key : keys_) {
+      GPR_ASSERT(0 == pthread_key_delete(key));
+    }
+  }
+
+  operator T() const {
+    T t;
+    char* dst = reinterpret_cast<char*>(&t);
+    for (pthread_key_t key : keys_) {
+      uintptr_t src = uintptr_t(pthread_getspecific(key));
+      size_t remaining = reinterpret_cast<char*>(&t + 1) - dst;
+      size_t step = std::min(sizeof(src), remaining);
+      memcpy(dst, &src, step);
+      dst += step;
+    }
+    return t;
+  }
+
+  T operator=(T t) {
+    char* src = reinterpret_cast<char*>(&t);
+    for (pthread_key_t key : keys_) {
+      uintptr_t dst;
+      size_t remaining = reinterpret_cast<char*>(&t + 1) - src;
+      size_t step = std::min(sizeof(dst), remaining);
+      memcpy(&dst, src, step);
+      GPR_ASSERT(0 == pthread_setspecific(key, reinterpret_cast<void*>(dst)));
+      src += step;
+    }
+    return t;
+  }
+
+ private:
+  const std::array<pthread_key_t,
+                   (sizeof(T) + sizeof(void*) - 1) / sizeof(void*)>
+      keys_;
+};
+
+}  // namespace grpc_core
+
+#define GPR_THREAD_LOCAL(type) grpc_core::PthreadTlsImpl<type>
+
+#else
+
+#define GPR_THREAD_LOCAL(type) \
+  thread_local typename grpc_core::TlsTypeConstrainer<type>::Type
 
-#ifdef GPR_PTHREAD_TLS
-#include "src/core/lib/gpr/tls_pthread.h"
 #endif
 
 #endif /* GRPC_CORE_LIB_GPR_TLS_H */
diff --git a/src/core/lib/gpr/tls_gcc.h b/src/core/lib/gpr/tls_gcc.h
deleted file mode 100644 (file)
index 72b360b..0000000
+++ /dev/null
@@ -1,52 +0,0 @@
-/*
- *
- * Copyright 2015 gRPC authors.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- *
- */
-
-#ifndef GRPC_CORE_LIB_GPR_TLS_GCC_H
-#define GRPC_CORE_LIB_GPR_TLS_GCC_H
-
-#include <grpc/support/port_platform.h>
-
-#include <stdbool.h>
-
-#include <grpc/support/log.h>
-
-/** Thread local storage based on gcc compiler primitives.
-   #include tls.h to use this - and see that file for documentation */
-
-struct gpr_gcc_thread_local {
-  intptr_t value;
-};
-
-#define GPR_TLS_DECL(name) \
-  static __thread struct gpr_gcc_thread_local name = {0}
-
-#define GPR_TLS_CLASS_DECL(name) \
-  static __thread struct gpr_gcc_thread_local name
-
-#define GPR_TLS_CLASS_DEF(name) __thread struct gpr_gcc_thread_local name = {0}
-
-#define gpr_tls_init(tls) \
-  do {                    \
-  } while (0)
-#define gpr_tls_destroy(tls) \
-  do {                       \
-  } while (0)
-#define gpr_tls_set(tls, new_value) (((tls)->value) = (new_value))
-#define gpr_tls_get(tls) ((tls)->value)
-
-#endif /* GRPC_CORE_LIB_GPR_TLS_GCC_H */
diff --git a/src/core/lib/gpr/tls_msvc.h b/src/core/lib/gpr/tls_msvc.h
deleted file mode 100644 (file)
index 73e6734..0000000
+++ /dev/null
@@ -1,54 +0,0 @@
-/*
- *
- * Copyright 2015 gRPC authors.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- *
- */
-
-#ifndef GRPC_CORE_LIB_GPR_TLS_MSVC_H
-#define GRPC_CORE_LIB_GPR_TLS_MSVC_H
-
-/** Thread local storage based on ms visual c compiler primitives.
-#include <grpc/support/port_platform.h>
-
-   #include tls.h to use this - and see that file for documentation */
-
-#include <cstdint>
-
-struct gpr_msvc_thread_local {
-  intptr_t value;
-};
-
-/** Use GPR_TLS_DECL to declare tls static variables outside a class */
-#define GPR_TLS_DECL(name) \
-  static __declspec(thread) struct gpr_msvc_thread_local name = {0}
-
-/** Use GPR_TLS_CLASS_DECL to declare tls static variable members of a class.
- *  GPR_TLS_CLASS_DEF needs to be called to define this member. */
-#define GPR_TLS_CLASS_DECL(name) \
-  static __declspec(thread) struct gpr_msvc_thread_local name
-
-#define GPR_TLS_CLASS_DEF(name) \
-  __declspec(thread) struct gpr_msvc_thread_local name = {0}
-
-#define gpr_tls_init(tls) \
-  do {                    \
-  } while (0)
-#define gpr_tls_destroy(tls) \
-  do {                       \
-  } while (0)
-#define gpr_tls_set(tls, new_value) (((tls)->value) = (new_value))
-#define gpr_tls_get(tls) ((tls)->value)
-
-#endif /* GRPC_CORE_LIB_GPR_TLS_MSVC_H */
diff --git a/src/core/lib/gpr/tls_pthread.cc b/src/core/lib/gpr/tls_pthread.cc
deleted file mode 100644 (file)
index 2e5b306..0000000
+++ /dev/null
@@ -1,30 +0,0 @@
-/*
- *
- * Copyright 2015 gRPC authors.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- *
- */
-
-#include <grpc/support/port_platform.h>
-
-#ifdef GPR_PTHREAD_TLS
-
-#include "src/core/lib/gpr/tls.h"
-
-intptr_t gpr_tls_set(struct gpr_pthread_thread_local* tls, intptr_t value) {
-  GPR_ASSERT(0 == pthread_setspecific(tls->key, (void*)value));
-  return value;
-}
-
-#endif /* GPR_PTHREAD_TLS */
diff --git a/src/core/lib/gpr/tls_pthread.h b/src/core/lib/gpr/tls_pthread.h
deleted file mode 100644 (file)
index a15f2f3..0000000
+++ /dev/null
@@ -1,56 +0,0 @@
-/*
- *
- * Copyright 2015 gRPC authors.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- *
- */
-
-#ifndef GRPC_CORE_LIB_GPR_TLS_PTHREAD_H
-#define GRPC_CORE_LIB_GPR_TLS_PTHREAD_H
-
-#include <grpc/support/port_platform.h>
-
-#include <grpc/support/log.h> /* for GPR_ASSERT */
-#include <pthread.h>
-
-/** Thread local storage based on pthread library calls.
-   #include tls.h to use this - and see that file for documentation */
-
-struct gpr_pthread_thread_local {
-  pthread_key_t key;
-};
-
-/** Use GPR_TLS_DECL to declare tls static variables outside a class */
-#define GPR_TLS_DECL(name) static struct gpr_pthread_thread_local name = {0}
-
-/** Use GPR_TLS_CLASS_DECL to declare tls static variable members of a class.
- *  GPR_TLS_CLASS_DEF needs to be called to define this member. */
-#define GPR_TLS_CLASS_DECL(name) static struct gpr_pthread_thread_local name
-
-/** Use GPR_TLS_CLASS_DEF to declare tls static variable members of a class.
- *  GPR_TLS_CLASS_DEF needs to be called to define this member. */
-#define GPR_TLS_CLASS_DEF(name) struct gpr_pthread_thread_local name = {0}
-
-#define gpr_tls_init(tls) GPR_ASSERT(0 == pthread_key_create(&(tls)->key, NULL))
-#define gpr_tls_destroy(tls) pthread_key_delete((tls)->key)
-#define gpr_tls_get(tls) ((intptr_t)pthread_getspecific((tls)->key))
-#ifdef __cplusplus
-extern "C" {
-#endif
-intptr_t gpr_tls_set(struct gpr_pthread_thread_local* tls, intptr_t value);
-#ifdef __cplusplus
-}
-#endif
-
-#endif /* GRPC_CORE_LIB_GPR_TLS_PTHREAD_H */
diff --git a/src/core/lib/gpr/tls_stdcpp.h b/src/core/lib/gpr/tls_stdcpp.h
deleted file mode 100644 (file)
index b5b422a..0000000
+++ /dev/null
@@ -1,48 +0,0 @@
-/*
- *
- * Copyright 2020 gRPC authors.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- *
- */
-
-#ifndef GRPC_CORE_LIB_GPR_TLS_STDCPP_H
-#define GRPC_CORE_LIB_GPR_TLS_STDCPP_H
-
-#include <grpc/support/port_platform.h>
-
-/** Thread local storage based on C++ thread_local.
-   #include tls.h to use this - and see that file for documentation */
-
-/** Use GPR_TLS_DECL to declare tls static variables outside a class */
-#define GPR_TLS_DECL(name) thread_local static intptr_t name = 0
-
-/** Use GPR_TLS_CLASS_DECL to declare tls static variable members of a class.
- *  GPR_TLS_CLASS_DEF needs to be called to define this member. */
-#define GPR_TLS_CLASS_DECL(name) thread_local static intptr_t name
-
-#define GPR_TLS_CLASS_DEF(name) thread_local intptr_t name = 0
-
-#define gpr_tls_init(tls) \
-  do {                    \
-  } while (0)
-
-#define gpr_tls_destroy(tls) \
-  do {                       \
-  } while (0)
-
-#define gpr_tls_set(tls, new_value) (*(tls) = (new_value))
-
-#define gpr_tls_get(tls) (*(tls))
-
-#endif /* GRPC_CORE_LIB_GPR_TLS_STDCPP_H */
index ffdad33..166cdf6 100644 (file)
@@ -20,8 +20,6 @@
 
 #ifdef GPR_POSIX_TMPFILE
 
-#include "src/core/lib/gpr/tmpfile.h"
-
 #include <errno.h>
 #include <stdlib.h>
 #include <string.h>
@@ -32,6 +30,7 @@
 #include <grpc/support/string_util.h>
 
 #include "src/core/lib/gpr/string.h"
+#include "src/core/lib/gpr/tmpfile.h"
 
 FILE* gpr_tmpfile(const char* prefix, char** tmp_filename) {
   FILE* result = nullptr;
index 6168825..9e979de 100644 (file)
@@ -21,6 +21,7 @@
 #include "src/core/lib/gprpp/arena.h"
 
 #include <string.h>
+
 #include <new>
 
 #include <grpc/support/alloc.h>
@@ -75,7 +76,7 @@ std::pair<Arena*, void*> Arena::CreateWithAlloc(size_t initial_size,
 }
 
 size_t Arena::Destroy() {
-  size_t size = total_used_.Load(MemoryOrder::RELAXED);
+  size_t size = total_used_.load(std::memory_order_relaxed);
   this->~Arena();
   gpr_free_aligned(this);
   return size;
index baca5a7..0c45fa6 100644 (file)
@@ -27,6 +27,9 @@
 
 #include <grpc/support/port_platform.h>
 
+#include <stddef.h>
+
+#include <atomic>
 #include <new>
 #include <utility>
 
@@ -35,9 +38,6 @@
 
 #include "src/core/lib/gpr/alloc.h"
 #include "src/core/lib/gpr/spinlock.h"
-#include "src/core/lib/gprpp/atomic.h"
-
-#include <stddef.h>
 
 namespace grpc_core {
 
@@ -59,7 +59,7 @@ class Arena {
     static constexpr size_t base_size =
         GPR_ROUND_UP_TO_ALIGNMENT_SIZE(sizeof(Arena));
     size = GPR_ROUND_UP_TO_ALIGNMENT_SIZE(size);
-    size_t begin = total_used_.FetchAdd(size, MemoryOrder::RELAXED);
+    size_t begin = total_used_.fetch_add(size, std::memory_order_relaxed);
     if (begin + size <= initial_zone_size_) {
       return reinterpret_cast<char*>(this) + base_size + begin;
     } else {
@@ -105,7 +105,7 @@ class Arena {
 
   // Keep track of the total used size. We use this in our call sizing
   // hysteresis.
-  Atomic<size_t> total_used_;
+  std::atomic<size_t> total_used_{0};
   const size_t initial_zone_size_;
   gpr_spinlock arena_growth_spinlock_ = GPR_SPINLOCK_STATIC_INITIALIZER;
   // If the initial arena allocation wasn't enough, we allocate additional zones
diff --git a/src/core/lib/gprpp/atomic.h b/src/core/lib/gprpp/atomic.h
deleted file mode 100644 (file)
index dd99d9e..0000000
+++ /dev/null
@@ -1,104 +0,0 @@
-/*
- *
- * Copyright 2017 gRPC authors.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- *
- */
-
-#ifndef GRPC_CORE_LIB_GPRPP_ATOMIC_H
-#define GRPC_CORE_LIB_GPRPP_ATOMIC_H
-
-#include <grpc/support/port_platform.h>
-
-#include <atomic>
-
-#include <grpc/support/atm.h>
-
-namespace grpc_core {
-
-enum class MemoryOrder {
-  RELAXED = static_cast<int>(std::memory_order_relaxed),
-  CONSUME = static_cast<int>(std::memory_order_consume),
-  ACQUIRE = static_cast<int>(std::memory_order_acquire),
-  RELEASE = static_cast<int>(std::memory_order_release),
-  ACQ_REL = static_cast<int>(std::memory_order_acq_rel),
-  SEQ_CST = static_cast<int>(std::memory_order_seq_cst)
-};
-
-template <typename T>
-class Atomic {
- public:
-  explicit Atomic(T val = T()) : storage_(val) {}
-
-  T Load(MemoryOrder order) const {
-    return storage_.load(static_cast<std::memory_order>(order));
-  }
-
-  void Store(T val, MemoryOrder order) {
-    storage_.store(val, static_cast<std::memory_order>(order));
-  }
-
-  T Exchange(T desired, MemoryOrder order) {
-    return storage_.exchange(desired, static_cast<std::memory_order>(order));
-  }
-
-  bool CompareExchangeWeak(T* expected, T desired, MemoryOrder success,
-                           MemoryOrder failure) {
-    return GPR_ATM_INC_CAS_THEN(storage_.compare_exchange_weak(
-        *expected, desired, static_cast<std::memory_order>(success),
-        static_cast<std::memory_order>(failure)));
-  }
-
-  bool CompareExchangeStrong(T* expected, T desired, MemoryOrder success,
-                             MemoryOrder failure) {
-    return GPR_ATM_INC_CAS_THEN(storage_.compare_exchange_strong(
-        *expected, desired, static_cast<std::memory_order>(success),
-        static_cast<std::memory_order>(failure)));
-  }
-
-  template <typename Arg>
-  T FetchAdd(Arg arg, MemoryOrder order = MemoryOrder::SEQ_CST) {
-    return GPR_ATM_INC_ADD_THEN(storage_.fetch_add(
-        static_cast<Arg>(arg), static_cast<std::memory_order>(order)));
-  }
-
-  template <typename Arg>
-  T FetchSub(Arg arg, MemoryOrder order = MemoryOrder::SEQ_CST) {
-    return GPR_ATM_INC_ADD_THEN(storage_.fetch_sub(
-        static_cast<Arg>(arg), static_cast<std::memory_order>(order)));
-  }
-
-  // Atomically increment a counter only if the counter value is not zero.
-  // Returns true if increment took place; false if counter is zero.
-  bool IncrementIfNonzero() {
-    T count = storage_.load(std::memory_order_acquire);
-    do {
-      // If zero, we are done (without an increment). If not, we must do a CAS
-      // to maintain the contract: do not increment the counter if it is already
-      // zero
-      if (count == 0) {
-        return false;
-      }
-    } while (!CompareExchangeWeak(&count, count + 1, MemoryOrder::ACQ_REL,
-                                  MemoryOrder::ACQUIRE));
-    return true;
-  }
-
- private:
-  std::atomic<T> storage_;
-};
-
-}  // namespace grpc_core
-
-#endif /* GRPC_CORE_LIB_GPRPP_ATOMIC_H */
diff --git a/src/core/lib/gprpp/atomic_utils.h b/src/core/lib/gprpp/atomic_utils.h
new file mode 100644 (file)
index 0000000..c059ade
--- /dev/null
@@ -0,0 +1,47 @@
+/*
+ *
+ * Copyright 2017 gRPC authors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ *
+ */
+
+#ifndef GRPC_CORE_LIB_GPRPP_ATOMIC_UTILS_H
+#define GRPC_CORE_LIB_GPRPP_ATOMIC_UTILS_H
+
+#include <grpc/support/port_platform.h>
+
+#include <atomic>
+
+namespace grpc_core {
+
+// Atomically increment a counter only if the counter value is not zero.
+// Returns true if increment took place; false if counter is zero.
+template <typename T>
+inline bool IncrementIfNonzero(std::atomic<T>* p) {
+  T count = p->load(std::memory_order_acquire);
+  do {
+    // If zero, we are done (without an increment). If not, we must do a CAS
+    // to maintain the contract: do not increment the counter if it is already
+    // zero
+    if (count == 0) {
+      return false;
+    }
+  } while (!p->compare_exchange_weak(
+      count, count + 1, std::memory_order_acq_rel, std::memory_order_acquire));
+  return true;
+}
+
+}  // namespace grpc_core
+
+#endif /* GRPC_CORE_LIB_GPRPP_ATOMIC_UTILS_H */
index 8e225bd..4577af3 100644 (file)
 
 #include <utility>
 
+#if __cplusplus > 201103l
+#define GRPC_BITSET_CONSTEXPR_MUTATOR constexpr
+#else
+#define GRPC_BITSET_CONSTEXPR_MUTATOR
+#endif
+
 namespace grpc_core {
 
 // Given a bit count as an integer, vend as member type `Type` a type with
@@ -79,10 +85,12 @@ class BitSet {
   constexpr BitSet() : units_{} {}
 
   // Set bit i to true
-  void set(int i) { units_[unit_for(i)] |= mask_for(i); }
+  GRPC_BITSET_CONSTEXPR_MUTATOR void set(int i) {
+    units_[unit_for(i)] |= mask_for(i);
+  }
 
   // Set bit i to is_set
-  void set(int i, bool is_set) {
+  GRPC_BITSET_CONSTEXPR_MUTATOR void set(int i, bool is_set) {
     if (is_set) {
       set(i);
     } else {
@@ -91,7 +99,9 @@ class BitSet {
   }
 
   // Set bit i to false
-  void clear(int i) { units_[unit_for(i)] &= ~mask_for(i); }
+  GRPC_BITSET_CONSTEXPR_MUTATOR void clear(int i) {
+    units_[unit_for(i)] &= ~mask_for(i);
+  }
 
   // Return true if bit i is set
   constexpr bool is_set(int i) const {
diff --git a/src/core/lib/gprpp/capture.h b/src/core/lib/gprpp/capture.h
new file mode 100644 (file)
index 0000000..860bfe4
--- /dev/null
@@ -0,0 +1,76 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#ifndef GRPC_CORE_LIB_GPRPP_CAPTURE_H
+#define GRPC_CORE_LIB_GPRPP_CAPTURE_H
+
+#include <grpc/impl/codegen/port_platform.h>
+
+#include <tuple>
+#include <utility>
+
+#include "absl/utility/utility.h"
+
+namespace grpc_core {
+
+namespace detail {
+
+template <typename F, typename... Captures>
+class Capture {
+ public:
+  explicit Capture(F f, Captures... captures)
+      : f_(std::move(f)), captures_(std::move(captures)...) {}
+
+  template <typename... Args>
+  decltype(std::declval<F>()(static_cast<Captures*>(nullptr)...,
+                             std::declval<Args>()...))
+  operator()(Args... args) {
+    auto f = &f_;
+    return absl::apply(
+        [f, &args...](Captures&... captures) {
+          return (*f)(&captures..., std::move(args)...);
+        },
+        captures_);
+  }
+
+ private:
+  GPR_NO_UNIQUE_ADDRESS F f_;
+  GPR_NO_UNIQUE_ADDRESS std::tuple<Captures...> captures_;
+};
+
+}  // namespace detail
+
+// C++11 helper - best explained by usage:
+//
+// BigThing big_thing;
+// auto f = Capture(
+//             [](BigThing* c, int a, int b) { /*...*/ },
+//             std::move(big_thing));
+//
+// results in: f being a callable that takes arguments (int a, int b), and
+// captures the original value of big_thing by move. Each call, a pointer to
+// each captured thing is inserted into the argument list at the beginning so it
+// can be manipulated.
+//
+// Captured values are mutable, and it's the users responsibility to ensure,
+// should this callable be invoked from different threads, that proper locking
+// is implemented.
+template <typename F, typename... Captures>
+detail::Capture<F, Captures...> Capture(F f, Captures... captures) {
+  return detail::Capture<F, Captures...>(std::move(f), std::move(captures)...);
+}
+
+}  // namespace grpc_core
+
+#endif  // GRPC_CORE_LIB_GPRPP_CAPTURE_H
diff --git a/src/core/lib/gprpp/construct_destruct.h b/src/core/lib/gprpp/construct_destruct.h
new file mode 100644 (file)
index 0000000..ad1949f
--- /dev/null
@@ -0,0 +1,39 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#ifndef GRPC_CORE_LIB_GPRPP_CONSTRUCT_DESTRUCT_H
+#define GRPC_CORE_LIB_GPRPP_CONSTRUCT_DESTRUCT_H
+
+#include <grpc/impl/codegen/port_platform.h>
+
+#include <utility>
+
+namespace grpc_core {
+
+// Call the destructor of p without having to name the type of p.
+template <typename T>
+void Destruct(T* p) {
+  p->~T();
+}
+
+// Call the constructor of p without having to name the type of p and forward
+// any arguments
+template <typename T, typename... Args>
+void Construct(T* p, Args&&... args) {
+  new (p) T(std::forward<Args>(args)...);
+}
+
+}  // namespace grpc_core
+
+#endif  // GRPC_CORE_LIB_GPRPP_CONSTRUCT_DESTRUCT_H
index 5217bfa..560e08d 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include <grpc/support/atm.h>
-#include <grpc/support/log.h>
-#include <grpc/support/sync.h>
-
 #include <atomic>
 #include <cassert>
 #include <cinttypes>
 
-#include "src/core/lib/gprpp/atomic.h"
+#include <grpc/support/atm.h>
+#include <grpc/support/log.h>
+#include <grpc/support/sync.h>
+
 #include "src/core/lib/gprpp/debug_location.h"
 #include "src/core/lib/gprpp/orphanable.h"
 #include "src/core/lib/gprpp/ref_counted_ptr.h"
@@ -67,7 +66,7 @@ class DualRefCounted : public Orphanable {
   void Unref() {
     // Convert strong ref to weak ref.
     const uint64_t prev_ref_pair =
-        refs_.FetchAdd(MakeRefPair(-1, 1), MemoryOrder::ACQ_REL);
+        refs_.fetch_add(MakeRefPair(-1, 1), std::memory_order_acq_rel);
     const uint32_t strong_refs = GetStrongRefs(prev_ref_pair);
 #ifndef NDEBUG
     const uint32_t weak_refs = GetWeakRefs(prev_ref_pair);
@@ -85,7 +84,7 @@ class DualRefCounted : public Orphanable {
   }
   void Unref(const DebugLocation& location, const char* reason) {
     const uint64_t prev_ref_pair =
-        refs_.FetchAdd(MakeRefPair(-1, 1), MemoryOrder::ACQ_REL);
+        refs_.fetch_add(MakeRefPair(-1, 1), std::memory_order_acq_rel);
     const uint32_t strong_refs = GetStrongRefs(prev_ref_pair);
 #ifndef NDEBUG
     const uint32_t weak_refs = GetWeakRefs(prev_ref_pair);
@@ -108,7 +107,7 @@ class DualRefCounted : public Orphanable {
   }
 
   RefCountedPtr<Child> RefIfNonZero() GRPC_MUST_USE_RESULT {
-    uint64_t prev_ref_pair = refs_.Load(MemoryOrder::ACQUIRE);
+    uint64_t prev_ref_pair = refs_.load(std::memory_order_acquire);
     do {
       const uint32_t strong_refs = GetStrongRefs(prev_ref_pair);
 #ifndef NDEBUG
@@ -119,15 +118,15 @@ class DualRefCounted : public Orphanable {
       }
 #endif
       if (strong_refs == 0) return nullptr;
-    } while (!refs_.CompareExchangeWeak(
-        &prev_ref_pair, prev_ref_pair + MakeRefPair(1, 0), MemoryOrder::ACQ_REL,
-        MemoryOrder::ACQUIRE));
+    } while (!refs_.compare_exchange_weak(
+        prev_ref_pair, prev_ref_pair + MakeRefPair(1, 0),
+        std::memory_order_acq_rel, std::memory_order_acquire));
     return RefCountedPtr<Child>(static_cast<Child*>(this));
   }
 
   RefCountedPtr<Child> RefIfNonZero(const DebugLocation& location,
                                     const char* reason) GRPC_MUST_USE_RESULT {
-    uint64_t prev_ref_pair = refs_.Load(MemoryOrder::ACQUIRE);
+    uint64_t prev_ref_pair = refs_.load(std::memory_order_acquire);
     do {
       const uint32_t strong_refs = GetStrongRefs(prev_ref_pair);
 #ifndef NDEBUG
@@ -144,9 +143,9 @@ class DualRefCounted : public Orphanable {
       (void)reason;
 #endif
       if (strong_refs == 0) return nullptr;
-    } while (!refs_.CompareExchangeWeak(
-        &prev_ref_pair, prev_ref_pair + MakeRefPair(1, 0), MemoryOrder::ACQ_REL,
-        MemoryOrder::ACQUIRE));
+    } while (!refs_.compare_exchange_weak(
+        prev_ref_pair, prev_ref_pair + MakeRefPair(1, 0),
+        std::memory_order_acq_rel, std::memory_order_acquire));
     return RefCountedPtr<Child>(static_cast<Child*>(this));
   }
 
@@ -169,7 +168,7 @@ class DualRefCounted : public Orphanable {
     const char* trace = trace_;
 #endif
     const uint64_t prev_ref_pair =
-        refs_.FetchSub(MakeRefPair(0, 1), MemoryOrder::ACQ_REL);
+        refs_.fetch_sub(MakeRefPair(0, 1), std::memory_order_acq_rel);
 #ifndef NDEBUG
     const uint32_t weak_refs = GetWeakRefs(prev_ref_pair);
     const uint32_t strong_refs = GetStrongRefs(prev_ref_pair);
@@ -191,7 +190,7 @@ class DualRefCounted : public Orphanable {
     const char* trace = trace_;
 #endif
     const uint64_t prev_ref_pair =
-        refs_.FetchSub(MakeRefPair(0, 1), MemoryOrder::ACQ_REL);
+        refs_.fetch_sub(MakeRefPair(0, 1), std::memory_order_acq_rel);
 #ifndef NDEBUG
     const uint32_t weak_refs = GetWeakRefs(prev_ref_pair);
     const uint32_t strong_refs = GetStrongRefs(prev_ref_pair);
@@ -254,7 +253,7 @@ class DualRefCounted : public Orphanable {
   void IncrementRefCount() {
 #ifndef NDEBUG
     const uint64_t prev_ref_pair =
-        refs_.FetchAdd(MakeRefPair(1, 0), MemoryOrder::RELAXED);
+        refs_.fetch_add(MakeRefPair(1, 0), std::memory_order_relaxed);
     const uint32_t strong_refs = GetStrongRefs(prev_ref_pair);
     const uint32_t weak_refs = GetWeakRefs(prev_ref_pair);
     GPR_ASSERT(strong_refs != 0);
@@ -263,13 +262,13 @@ class DualRefCounted : public Orphanable {
               strong_refs, strong_refs + 1, weak_refs);
     }
 #else
-    refs_.FetchAdd(MakeRefPair(1, 0), MemoryOrder::RELAXED);
+    refs_.fetch_add(MakeRefPair(1, 0), std::memory_order_relaxed);
 #endif
   }
   void IncrementRefCount(const DebugLocation& location, const char* reason) {
 #ifndef NDEBUG
     const uint64_t prev_ref_pair =
-        refs_.FetchAdd(MakeRefPair(1, 0), MemoryOrder::RELAXED);
+        refs_.fetch_add(MakeRefPair(1, 0), std::memory_order_relaxed);
     const uint32_t strong_refs = GetStrongRefs(prev_ref_pair);
     const uint32_t weak_refs = GetWeakRefs(prev_ref_pair);
     GPR_ASSERT(strong_refs != 0);
@@ -282,14 +281,14 @@ class DualRefCounted : public Orphanable {
     // Use conditionally-important parameters
     (void)location;
     (void)reason;
-    refs_.FetchAdd(MakeRefPair(1, 0), MemoryOrder::RELAXED);
+    refs_.fetch_add(MakeRefPair(1, 0), std::memory_order_relaxed);
 #endif
   }
 
   void IncrementWeakRefCount() {
 #ifndef NDEBUG
     const uint64_t prev_ref_pair =
-        refs_.FetchAdd(MakeRefPair(0, 1), MemoryOrder::RELAXED);
+        refs_.fetch_add(MakeRefPair(0, 1), std::memory_order_relaxed);
     const uint32_t strong_refs = GetStrongRefs(prev_ref_pair);
     const uint32_t weak_refs = GetWeakRefs(prev_ref_pair);
     if (trace_ != nullptr) {
@@ -297,14 +296,14 @@ class DualRefCounted : public Orphanable {
               weak_refs, weak_refs + 1, strong_refs);
     }
 #else
-    refs_.FetchAdd(MakeRefPair(0, 1), MemoryOrder::RELAXED);
+    refs_.fetch_add(MakeRefPair(0, 1), std::memory_order_relaxed);
 #endif
   }
   void IncrementWeakRefCount(const DebugLocation& location,
                              const char* reason) {
 #ifndef NDEBUG
     const uint64_t prev_ref_pair =
-        refs_.FetchAdd(MakeRefPair(0, 1), MemoryOrder::RELAXED);
+        refs_.fetch_add(MakeRefPair(0, 1), std::memory_order_relaxed);
     const uint32_t strong_refs = GetStrongRefs(prev_ref_pair);
     const uint32_t weak_refs = GetWeakRefs(prev_ref_pair);
     if (trace_ != nullptr) {
@@ -316,14 +315,14 @@ class DualRefCounted : public Orphanable {
     // Use conditionally-important parameters
     (void)location;
     (void)reason;
-    refs_.FetchAdd(MakeRefPair(0, 1), MemoryOrder::RELAXED);
+    refs_.fetch_add(MakeRefPair(0, 1), std::memory_order_relaxed);
 #endif
   }
 
 #ifndef NDEBUG
   const char* trace_;
 #endif
-  Atomic<uint64_t> refs_;
+  std::atomic<uint64_t> refs_{0};
 };
 
 }  // namespace grpc_core
index 45a4a89..675f8e4 100644 (file)
@@ -168,28 +168,30 @@ class ThreadState {
 
 void Fork::GlobalInit() {
   if (!override_enabled_) {
-    support_enabled_.Store(GPR_GLOBAL_CONFIG_GET(grpc_enable_fork_support),
-                           MemoryOrder::RELAXED);
+    support_enabled_.store(GPR_GLOBAL_CONFIG_GET(grpc_enable_fork_support),
+                           std::memory_order_relaxed);
   }
-  if (support_enabled_.Load(MemoryOrder::RELAXED)) {
+  if (support_enabled_.load(std::memory_order_relaxed)) {
     exec_ctx_state_ = new internal::ExecCtxState();
     thread_state_ = new internal::ThreadState();
   }
 }
 
 void Fork::GlobalShutdown() {
-  if (support_enabled_.Load(MemoryOrder::RELAXED)) {
+  if (support_enabled_.load(std::memory_order_relaxed)) {
     delete exec_ctx_state_;
     delete thread_state_;
   }
 }
 
-bool Fork::Enabled() { return support_enabled_.Load(MemoryOrder::RELAXED); }
+bool Fork::Enabled() {
+  return support_enabled_.load(std::memory_order_relaxed);
+}
 
 // Testing Only
 void Fork::Enable(bool enable) {
   override_enabled_ = true;
-  support_enabled_.Store(enable, MemoryOrder::RELAXED);
+  support_enabled_.store(enable, std::memory_order_relaxed);
 }
 
 void Fork::DoIncExecCtxCount() { exec_ctx_state_->IncExecCtxCount(); }
@@ -205,38 +207,38 @@ Fork::child_postfork_func Fork::GetResetChildPollingEngineFunc() {
 }
 
 bool Fork::BlockExecCtx() {
-  if (support_enabled_.Load(MemoryOrder::RELAXED)) {
+  if (support_enabled_.load(std::memory_order_relaxed)) {
     return exec_ctx_state_->BlockExecCtx();
   }
   return false;
 }
 
 void Fork::AllowExecCtx() {
-  if (support_enabled_.Load(MemoryOrder::RELAXED)) {
+  if (support_enabled_.load(std::memory_order_relaxed)) {
     exec_ctx_state_->AllowExecCtx();
   }
 }
 
 void Fork::IncThreadCount() {
-  if (support_enabled_.Load(MemoryOrder::RELAXED)) {
+  if (support_enabled_.load(std::memory_order_relaxed)) {
     thread_state_->IncThreadCount();
   }
 }
 
 void Fork::DecThreadCount() {
-  if (support_enabled_.Load(MemoryOrder::RELAXED)) {
+  if (support_enabled_.load(std::memory_order_relaxed)) {
     thread_state_->DecThreadCount();
   }
 }
 void Fork::AwaitThreads() {
-  if (support_enabled_.Load(MemoryOrder::RELAXED)) {
+  if (support_enabled_.load(std::memory_order_relaxed)) {
     thread_state_->AwaitThreads();
   }
 }
 
 internal::ExecCtxState* Fork::exec_ctx_state_ = nullptr;
 internal::ThreadState* Fork::thread_state_ = nullptr;
-Atomic<bool> Fork::support_enabled_(false);
+std::atomic<bool> Fork::support_enabled_(false);
 bool Fork::override_enabled_ = false;
 Fork::child_postfork_func Fork::reset_child_polling_engine_ = nullptr;
 }  // namespace grpc_core
index 3601d7c..d6ef161 100644 (file)
@@ -21,7 +21,7 @@
 
 #include <grpc/support/port_platform.h>
 
-#include "src/core/lib/gprpp/atomic.h"
+#include <atomic>
 
 /*
  * NOTE: FORKING IS NOT GENERALLY SUPPORTED, THIS IS ONLY INTENDED TO WORK
@@ -48,14 +48,14 @@ class Fork {
   // Increment the count of active ExecCtxs.
   // Will block until a pending fork is complete if one is in progress.
   static void IncExecCtxCount() {
-    if (GPR_UNLIKELY(support_enabled_.Load(MemoryOrder::RELAXED))) {
+    if (GPR_UNLIKELY(support_enabled_.load(std::memory_order_relaxed))) {
       DoIncExecCtxCount();
     }
   }
 
   // Decrement the count of active ExecCtxs
   static void DecExecCtxCount() {
-    if (GPR_UNLIKELY(support_enabled_.Load(MemoryOrder::RELAXED))) {
+    if (GPR_UNLIKELY(support_enabled_.load(std::memory_order_relaxed))) {
       DoDecExecCtxCount();
     }
   }
@@ -93,7 +93,7 @@ class Fork {
 
   static internal::ExecCtxState* exec_ctx_state_;
   static internal::ThreadState* thread_state_;
-  static grpc_core::Atomic<bool> support_enabled_;
+  static std::atomic<bool> support_enabled_;
   static bool override_enabled_;
   static child_postfork_func reset_child_polling_engine_;
 };
index ed986b8..150c738 100644 (file)
@@ -89,8 +89,7 @@
 //   bool gpr_global_config_get_test();
 //   void gpr_global_config_set_test(bool value);
 
-#include "src/core/lib/gprpp/global_config_env.h"
-
 #include "src/core/lib/gprpp/global_config_custom.h"
+#include "src/core/lib/gprpp/global_config_env.h"
 
 #endif /* GRPC_CORE_LIB_GPRPP_GLOBAL_CONFIG_H */
index d45d232..d70c8e8 100644 (file)
 
 #include "src/core/lib/gprpp/global_config_env.h"
 
-#include <grpc/support/alloc.h>
-#include <grpc/support/log.h>
-#include <grpc/support/string_util.h>
-
-#include "src/core/lib/gpr/env.h"
-#include "src/core/lib/gpr/string.h"
-
 #include <ctype.h>
 #include <string.h>
 
 
 #include "absl/strings/str_format.h"
 
+#include <grpc/support/alloc.h>
+#include <grpc/support/log.h>
+#include <grpc/support/string_util.h>
+
+#include "src/core/lib/gpr/env.h"
+#include "src/core/lib/gpr/string.h"
+
 namespace grpc_core {
 
 namespace {
index d3e3e2a..6bdadb0 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include "src/core/lib/gprpp/memory.h"
-
 #include <stdint.h>
 
+#include "src/core/lib/gprpp/memory.h"
+
 #define GPR_GLOBAL_CONFIG_GET(name) gpr_global_config_get_##name()
 
 #define GPR_GLOBAL_CONFIG_SET(name, value) gpr_global_config_set_##name(value)
index 48ab231..49517af 100644 (file)
 
 #include <stddef.h>
 #include <stdlib.h>
+
 #include <new>
 #include <type_traits>
 #include <utility>
 
 #include <grpc/support/log.h>
 
+#include "src/core/lib/gprpp/construct_destruct.h"
+
 namespace grpc_core {
 
 // this contains templated helpers needed to implement the ManualConstructors
@@ -182,7 +185,7 @@ class ManualConstructor {
   Type& operator*() { return *get(); }
   const Type& operator*() const { return *get(); }
 
-  void Init() { new (&space_) Type; }
+  void Init() { Construct(get()); }
 
   // Init() constructs the Type instance using the given arguments
   // (which are forwarded to Type's constructor).
@@ -192,17 +195,17 @@ class ManualConstructor {
   // "new Type();"), so it will leave non-class types uninitialized.
   template <typename... Ts>
   void Init(Ts&&... args) {
-    new (&space_) Type(std::forward<Ts>(args)...);
+    Construct(get(), std::forward<Ts>(args)...);
   }
 
   // Init() that is equivalent to copy and move construction.
   // Enables usage like this:
   //   ManualConstructor<std::vector<int>> v;
   //   v.Init({1, 2, 3});
-  void Init(const Type& x) { new (&space_) Type(x); }
-  void Init(Type&& x) { new (&space_) Type(std::move(x)); }
+  void Init(const Type& x) { Construct(get(), x); }
+  void Init(Type&& x) { Construct(get(), std::forward<Type>(x)); }
 
-  void Destroy() { get()->~Type(); }
+  void Destroy() { Destruct(get()); }
 
  private:
   typename std::aligned_storage<sizeof(Type), alignof(Type)>::type space_;
index caec932..1a405d4 100644 (file)
@@ -18,6 +18,7 @@
 #include <grpc/impl/codegen/port_platform.h>
 
 #include "absl/types/variant.h"
+
 #include "src/core/lib/gprpp/overload.h"
 
 namespace grpc_core {
index 4edc9b3..00e24ae 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include <grpc/support/alloc.h>
-#include <grpc/support/log.h>
-
 #include <limits>
 #include <memory>
 #include <utility>
 
 #include "absl/memory/memory.h"
 
+#include <grpc/support/alloc.h>
+#include <grpc/support/log.h>
+
 namespace grpc_core {
 
 class DefaultDeleteChar {
index 373ec09..b5a1717 100644 (file)
@@ -27,9 +27,9 @@ namespace grpc_core {
 //
 
 bool MultiProducerSingleConsumerQueue::Push(Node* node) {
-  node->next.Store(nullptr, MemoryOrder::RELAXED);
-  Node* prev = head_.Exchange(node, MemoryOrder::ACQ_REL);
-  prev->next.Store(node, MemoryOrder::RELEASE);
+  node->next.store(nullptr, std::memory_order_relaxed);
+  Node* prev = head_.exchange(node, std::memory_order_acq_rel);
+  prev->next.store(node, std::memory_order_release);
   return prev == &stub_;
 }
 
@@ -42,7 +42,7 @@ MultiProducerSingleConsumerQueue::Pop() {
 MultiProducerSingleConsumerQueue::Node*
 MultiProducerSingleConsumerQueue::PopAndCheckEnd(bool* empty) {
   Node* tail = tail_;
-  Node* next = tail_->next.Load(MemoryOrder::ACQUIRE);
+  Node* next = tail_->next.load(std::memory_order_acquire);
   if (tail == &stub_) {
     // indicates the list is actually (ephemerally) empty
     if (next == nullptr) {
@@ -51,21 +51,21 @@ MultiProducerSingleConsumerQueue::PopAndCheckEnd(bool* empty) {
     }
     tail_ = next;
     tail = next;
-    next = tail->next.Load(MemoryOrder::ACQUIRE);
+    next = tail->next.load(std::memory_order_acquire);
   }
   if (next != nullptr) {
     *empty = false;
     tail_ = next;
     return tail;
   }
-  Node* head = head_.Load(MemoryOrder::ACQUIRE);
+  Node* head = head_.load(std::memory_order_acquire);
   if (tail != head) {
     *empty = false;
     // indicates a retry is in order: we're still adding
     return nullptr;
   }
   Push(&stub_);
-  next = tail->next.Load(MemoryOrder::ACQUIRE);
+  next = tail->next.load(std::memory_order_acquire);
   if (next != nullptr) {
     *empty = false;
     tail_ = next;
index a1c04ca..38e016c 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include "src/core/lib/gprpp/atomic.h"
-#include "src/core/lib/gprpp/sync.h"
+#include <atomic>
 
 #include <grpc/support/log.h>
 
+#include "src/core/lib/gprpp/sync.h"
+
 namespace grpc_core {
 
 // Multiple-producer single-consumer lock free queue, based upon the
@@ -35,12 +36,12 @@ class MultiProducerSingleConsumerQueue {
  public:
   // List node.  Application node types can inherit from this.
   struct Node {
-    Atomic<Node*> next;
+    std::atomic<Node*> next{nullptr};
   };
 
   MultiProducerSingleConsumerQueue() : head_{&stub_}, tail_(&stub_) {}
   ~MultiProducerSingleConsumerQueue() {
-    GPR_ASSERT(head_.Load(MemoryOrder::RELAXED) == &stub_);
+    GPR_ASSERT(head_.load(std::memory_order_relaxed) == &stub_);
     GPR_ASSERT(tail_ == &stub_);
   }
 
@@ -61,7 +62,7 @@ class MultiProducerSingleConsumerQueue {
   // make sure head & tail don't share a cacheline
   union {
     char padding_[GPR_CACHELINE_SIZE];
-    Atomic<Node*> head_;
+    std::atomic<Node*> head_{nullptr};
   };
   Node* tail_;
   Node stub_;
index b73e520..7fade1c 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include <grpc/support/log.h>
-#include <grpc/support/sync.h>
-
 #include <cinttypes>
 #include <memory>
 
+#include <grpc/support/log.h>
+#include <grpc/support/sync.h>
+
 #include "src/core/lib/gprpp/debug_location.h"
 #include "src/core/lib/gprpp/memory.h"
 #include "src/core/lib/gprpp/ref_counted.h"
index a8def8c..f250bbd 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include <grpc/support/atm.h>
-#include <grpc/support/log.h>
-#include <grpc/support/sync.h>
-
 #include <atomic>
 #include <cassert>
 #include <cinttypes>
 
-#include "src/core/lib/gprpp/atomic.h"
+#include <grpc/support/atm.h>
+#include <grpc/support/log.h>
+#include <grpc/support/sync.h>
+
+#include "src/core/lib/gprpp/atomic_utils.h"
 #include "src/core/lib/gprpp/debug_location.h"
 #include "src/core/lib/gprpp/memory.h"
 #include "src/core/lib/gprpp/ref_counted_ptr.h"
@@ -70,18 +70,18 @@ class RefCount {
   // Increases the ref-count by `n`.
   void Ref(Value n = 1) {
 #ifndef NDEBUG
-    const Value prior = value_.FetchAdd(n, MemoryOrder::RELAXED);
+    const Value prior = value_.fetch_add(n, std::memory_order_relaxed);
     if (trace_ != nullptr) {
       gpr_log(GPR_INFO, "%s:%p ref %" PRIdPTR " -> %" PRIdPTR, trace_, this,
               prior, prior + n);
     }
 #else
-    value_.FetchAdd(n, MemoryOrder::RELAXED);
+    value_.fetch_add(n, std::memory_order_relaxed);
 #endif
   }
   void Ref(const DebugLocation& location, const char* reason, Value n = 1) {
 #ifndef NDEBUG
-    const Value prior = value_.FetchAdd(n, MemoryOrder::RELAXED);
+    const Value prior = value_.fetch_add(n, std::memory_order_relaxed);
     if (trace_ != nullptr) {
       gpr_log(GPR_INFO, "%s:%p %s:%d ref %" PRIdPTR " -> %" PRIdPTR " %s",
               trace_, this, location.file(), location.line(), prior, prior + n,
@@ -91,26 +91,26 @@ class RefCount {
     // Use conditionally-important parameters
     (void)location;
     (void)reason;
-    value_.FetchAdd(n, MemoryOrder::RELAXED);
+    value_.fetch_add(n, std::memory_order_relaxed);
 #endif
   }
 
   // Similar to Ref() with an assert on the ref-count being non-zero.
   void RefNonZero() {
 #ifndef NDEBUG
-    const Value prior = value_.FetchAdd(1, MemoryOrder::RELAXED);
+    const Value prior = value_.fetch_add(1, std::memory_order_relaxed);
     if (trace_ != nullptr) {
       gpr_log(GPR_INFO, "%s:%p ref %" PRIdPTR " -> %" PRIdPTR, trace_, this,
               prior, prior + 1);
     }
     assert(prior > 0);
 #else
-    value_.FetchAdd(1, MemoryOrder::RELAXED);
+    value_.fetch_add(1, std::memory_order_relaxed);
 #endif
   }
   void RefNonZero(const DebugLocation& location, const char* reason) {
 #ifndef NDEBUG
-    const Value prior = value_.FetchAdd(1, MemoryOrder::RELAXED);
+    const Value prior = value_.fetch_add(1, std::memory_order_relaxed);
     if (trace_ != nullptr) {
       gpr_log(GPR_INFO, "%s:%p %s:%d ref %" PRIdPTR " -> %" PRIdPTR " %s",
               trace_, this, location.file(), location.line(), prior, prior + 1,
@@ -133,7 +133,7 @@ class RefCount {
               trace_, this, prior, prior + 1);
     }
 #endif
-    return value_.IncrementIfNonzero();
+    return IncrementIfNonzero(&value_);
   }
   bool RefIfNonZero(const DebugLocation& location, const char* reason) {
 #ifndef NDEBUG
@@ -148,7 +148,7 @@ class RefCount {
     // Avoid unused-parameter warnings for debug-only parameters
     (void)location;
     (void)reason;
-    return value_.IncrementIfNonzero();
+    return IncrementIfNonzero(&value_);
   }
 
   // Decrements the ref-count and returns true if the ref-count reaches 0.
@@ -159,7 +159,7 @@ class RefCount {
     // safely access it, since another thread might free us in the interim.
     auto* trace = trace_;
 #endif
-    const Value prior = value_.FetchSub(1, MemoryOrder::ACQ_REL);
+    const Value prior = value_.fetch_sub(1, std::memory_order_acq_rel);
 #ifndef NDEBUG
     if (trace != nullptr) {
       gpr_log(GPR_INFO, "%s:%p unref %" PRIdPTR " -> %" PRIdPTR, trace, this,
@@ -176,7 +176,7 @@ class RefCount {
     // safely access it, since another thread might free us in the interim.
     auto* trace = trace_;
 #endif
-    const Value prior = value_.FetchSub(1, MemoryOrder::ACQ_REL);
+    const Value prior = value_.fetch_sub(1, std::memory_order_acq_rel);
 #ifndef NDEBUG
     if (trace != nullptr) {
       gpr_log(GPR_INFO, "%s:%p %s:%d unref %" PRIdPTR " -> %" PRIdPTR " %s",
@@ -193,12 +193,12 @@ class RefCount {
   }
 
  private:
-  Value get() const { return value_.Load(MemoryOrder::RELAXED); }
+  Value get() const { return value_.load(std::memory_order_relaxed); }
 
 #ifndef NDEBUG
   const char* trace_;
 #endif
-  Atomic<Value> value_;
+  std::atomic<Value> value_{0};
 };
 
 // PolymorphicRefCount enforces polymorphic destruction of RefCounted.
index 8266e16..f13cd40 100644 (file)
@@ -19,9 +19,6 @@
 #include <grpc/support/port_platform.h>
 
 #include "src/core/lib/gprpp/status_helper.h"
-#include "src/core/lib/gprpp/time_util.h"
-
-#include <grpc/support/log.h>
 
 #include "absl/strings/cord.h"
 #include "absl/strings/escaping.h"
 #include "absl/strings/str_format.h"
 #include "absl/strings/str_join.h"
 #include "absl/time/clock.h"
-
 #include "google/protobuf/any.upb.h"
 #include "google/rpc/status.upb.h"
 #include "upb/upb.hpp"
 
+#include <grpc/support/log.h>
+
+#include "src/core/lib/gprpp/time_util.h"
+
 namespace grpc_core {
 
 namespace {
index d535859..10f4ee6 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
+#include "absl/synchronization/mutex.h"
+
 #include <grpc/support/log.h>
 #include <grpc/support/sync.h>
 #include <grpc/support/time.h>
 
-#include "absl/synchronization/mutex.h"
 #include "src/core/lib/gprpp/time_util.h"
 
 // The core library is not accessible in C++ codegen headers, and vice versa.
@@ -68,6 +69,7 @@ class ABSL_LOCKABLE Mutex {
   bool TryLock() ABSL_EXCLUSIVE_TRYLOCK_FUNCTION(true) {
     return gpr_mu_trylock(&mu_) != 0;
   }
+  void AssertHeld() ABSL_ASSERT_EXCLUSIVE_LOCK() {}
 
  private:
   gpr_mu mu_;
index a1de10e..be1222f 100644 (file)
@@ -18,7 +18,9 @@
 #include <grpc/impl/codegen/port_platform.h>
 
 #include <utility>
+
 #include "absl/utility/utility.h"
+
 #include "src/core/lib/gprpp/bitset.h"
 
 namespace grpc_core {
index c3449bd..2d522c9 100644 (file)
 
 #ifdef GPR_POSIX_SYNC
 
-#include "src/core/lib/gprpp/thd.h"
+#include <pthread.h>
+#include <stdlib.h>
+#include <string.h>
+#include <unistd.h>
 
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/sync.h>
 #include <grpc/support/thd_id.h>
-#include <pthread.h>
-#include <stdlib.h>
-#include <string.h>
-#include <unistd.h>
 
 #include "src/core/lib/gpr/useful.h"
 #include "src/core/lib/gprpp/fork.h"
 #include "src/core/lib/gprpp/memory.h"
+#include "src/core/lib/gprpp/thd.h"
 
 namespace grpc_core {
 namespace {
index fb90afd..ce1a753 100644 (file)
 
 #ifdef GPR_WINDOWS
 
-#include "src/core/lib/gprpp/thd.h"
+#include <string.h>
 
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/thd_id.h>
-#include <string.h>
 
+#include "src/core/lib/gpr/tls.h"
 #include "src/core/lib/gprpp/memory.h"
-
-#if defined(_MSC_VER)
-#define thread_local __declspec(thread)
-#elif defined(__GNUC__)
-#define thread_local __thread
-#else
-#error "Unknown compiler - please file a bug report"
-#endif
+#include "src/core/lib/gprpp/thd.h"
 
 namespace {
 class ThreadInternalsWindows;
@@ -49,7 +42,7 @@ struct thd_info {
   bool joinable;           /* whether it is joinable */
 };
 
-thread_local struct thd_info* g_thd_info;
+GPR_THREAD_LOCAL(struct thd_info*) g_thd_info;
 
 class ThreadInternalsWindows
     : public grpc_core::internal::ThreadInternalsInterface {
index d3aa25a..8479503 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include <grpc/support/log.h>
-
 #include "src/core/lib/gprpp/time_util.h"
 
+#include <grpc/support/log.h>
+
 namespace grpc_core {
 
 gpr_timespec ToGprTimeSpec(absl::Duration duration) {
index 4ae4a40..226e405 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include <grpc/support/time.h>
-
 #include "absl/time/time.h"
 
+#include <grpc/support/time.h>
+
 namespace grpc_core {
 
 // Converts absl::Duration to gpr_timespec(GPR_TIMESPAN)
index 947b19c..1f0a5cf 100644 (file)
@@ -32,6 +32,7 @@
 #include <grpc/slice.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/string_util.h>
+
 #include "src/core/lib/gpr/string.h"
 
 static void fill_common_header(const grpc_httpcli_request* request,
index bcc332f..30c870f 100644 (file)
@@ -22,6 +22,7 @@
 #include <grpc/support/port_platform.h>
 
 #include <grpc/slice.h>
+
 #include "src/core/lib/http/httpcli.h"
 
 grpc_slice grpc_httpcli_format_get_request(const grpc_httpcli_request* request);
index e3d2fbe..722cd57 100644 (file)
@@ -31,7 +31,6 @@
 #include <grpc/support/string_util.h>
 
 #include "src/core/lib/address_utils/sockaddr_utils.h"
-#include "src/core/lib/channel/channel_args.h"
 #include "src/core/lib/gpr/string.h"
 #include "src/core/lib/gprpp/memory.h"
 #include "src/core/lib/http/format_request.h"
@@ -48,6 +47,7 @@ struct internal_request {
   grpc_resolved_addresses* addresses;
   size_t next_address;
   grpc_endpoint* ep;
+  grpc_resource_quota* resource_quota;
   char* host;
   char* ssl_host_override;
   grpc_millis deadline;
@@ -63,7 +63,6 @@ struct internal_request {
   grpc_closure done_write;
   grpc_closure connected;
   grpc_error_handle overall_error;
-  grpc_resource_quota* resource_quota;
 };
 static grpc_httpcli_get_override g_get_override = nullptr;
 static grpc_httpcli_post_override g_post_override = nullptr;
@@ -208,12 +207,11 @@ static void next_address(internal_request* req, grpc_error_handle error) {
   addr = &req->addresses->addrs[req->next_address++];
   GRPC_CLOSURE_INIT(&req->connected, on_connected, req,
                     grpc_schedule_on_exec_ctx);
-  grpc_arg arg = grpc_channel_arg_pointer_create(
-      const_cast<char*>(GRPC_ARG_RESOURCE_QUOTA), req->resource_quota,
-      grpc_resource_quota_arg_vtable());
-  grpc_channel_args args = {1, &arg};
-  grpc_tcp_client_connect(&req->connected, &req->ep, req->context->pollset_set,
-                          &args, addr, req->deadline);
+  grpc_tcp_client_connect(&req->connected, &req->ep,
+                          grpc_slice_allocator_create(
+                              req->resource_quota, grpc_sockaddr_to_uri(addr)),
+                          req->context->pollset_set, nullptr, addr,
+                          req->deadline);
 }
 
 static void on_resolved(void* arg, grpc_error_handle error) {
@@ -246,7 +244,7 @@ static void internal_request_begin(grpc_httpcli_context* context,
   req->context = context;
   req->pollent = pollent;
   req->overall_error = GRPC_ERROR_NONE;
-  req->resource_quota = grpc_resource_quota_ref_internal(resource_quota);
+  req->resource_quota = resource_quota;
   GRPC_CLOSURE_INIT(&req->on_read, on_read, req, grpc_schedule_on_exec_ctx);
   GRPC_CLOSURE_INIT(&req->done_write, done_write, req,
                     grpc_schedule_on_exec_ctx);
@@ -271,6 +269,7 @@ void grpc_httpcli_get(grpc_httpcli_context* context,
                       const grpc_httpcli_request* request, grpc_millis deadline,
                       grpc_closure* on_done, grpc_httpcli_response* response) {
   if (g_get_override && g_get_override(request, deadline, on_done, response)) {
+    grpc_resource_quota_unref_internal(resource_quota);
     return;
   }
   std::string name =
@@ -289,6 +288,7 @@ void grpc_httpcli_post(grpc_httpcli_context* context,
                        grpc_httpcli_response* response) {
   if (g_post_override && g_post_override(request, body_bytes, body_size,
                                          deadline, on_done, response)) {
+    grpc_resource_quota_unref_internal(resource_quota);
     return;
   }
   std::string name =
index b61bb06..495feb3 100644 (file)
@@ -30,6 +30,7 @@
 #include "src/core/lib/iomgr/iomgr_internal.h"
 #include "src/core/lib/iomgr/polling_entity.h"
 #include "src/core/lib/iomgr/pollset_set.h"
+#include "src/core/lib/iomgr/resource_quota.h"
 
 /* User agent this library reports */
 #define GRPC_HTTPCLI_USER_AGENT "grpc-httpcli/0.0"
@@ -75,6 +76,7 @@ void grpc_httpcli_context_destroy(grpc_httpcli_context* context);
    'pollset' indicates a grpc_pollset that is interested in the result
      of the get - work on this pollset may be used to progress the get
      operation
+   'resource_quota: this function takes ownership of a ref from the caller
    'request' contains request parameters - these are caller owned and can be
      destroyed once the call returns
    'deadline' contains a deadline for the request (or gpr_inf_future)
@@ -90,6 +92,7 @@ void grpc_httpcli_get(grpc_httpcli_context* context,
    'pollset' indicates a grpc_pollset that is interested in the result
      of the post - work on this pollset may be used to progress the post
      operation
+   'resource_quota' - this function takes ownership of a ref from the caller.
    'request' contains request parameters - these are caller owned and can be
      destroyed once the call returns
    'body_bytes' and 'body_size' specify the payload for the post.
index e26f99b..1efcf20 100644 (file)
@@ -18,8 +18,6 @@
 
 #include <grpc/support/port_platform.h>
 
-#include "src/core/lib/http/httpcli.h"
-
 #include <string.h>
 
 #include "absl/strings/str_cat.h"
 #include <grpc/support/string_util.h>
 
 #include "src/core/lib/channel/channel_args.h"
-#include "src/core/lib/channel/handshaker_registry.h"
+#include "src/core/lib/config/core_configuration.h"
 #include "src/core/lib/gpr/string.h"
 #include "src/core/lib/gprpp/ref_counted_ptr.h"
+#include "src/core/lib/http/httpcli.h"
 #include "src/core/lib/iomgr/pollset.h"
 #include "src/core/lib/security/credentials/credentials.h"
 #include "src/core/lib/security/security_connector/ssl_utils.h"
@@ -96,10 +95,8 @@ class grpc_httpcli_ssl_channel_security_connector final
     /* Check the peer name. */
     if (secure_peer_name_ != nullptr &&
         !tsi_ssl_peer_matches_name(&peer, secure_peer_name_)) {
-      error = GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-          absl::StrCat("Peer name ", secure_peer_name_,
-                       " is not in peer certificate")
-              .c_str());
+      error = GRPC_ERROR_CREATE_FROM_CPP_STRING(absl::StrCat(
+          "Peer name ", secure_peer_name_, " is not in peer certificate"));
     }
     grpc_core::ExecCtx::Run(DEBUG_LOCATION, on_peer_checked, error);
     tsi_peer_destruct(&peer);
@@ -206,7 +203,7 @@ static void ssl_handshake(void* arg, grpc_endpoint* tcp, const char* host,
   grpc_arg channel_arg = grpc_security_connector_to_arg(sc.get());
   grpc_channel_args args = {1, &channel_arg};
   c->handshake_mgr = grpc_core::MakeRefCounted<grpc_core::HandshakeManager>();
-  grpc_core::HandshakerRegistry::AddHandshakers(
+  grpc_core::CoreConfiguration::Get().handshaker_registry().AddHandshakers(
       grpc_core::HANDSHAKER_CLIENT, &args,
       /*interested_parties=*/nullptr, c->handshake_mgr.get());
   c->handshake_mgr->DoHandshake(tcp, /*channel_args=*/nullptr, deadline,
index 613b972..1f8c388 100644 (file)
@@ -22,6 +22,7 @@
 #include <grpc/support/port_platform.h>
 
 #include <grpc/slice.h>
+
 #include "src/core/lib/debug/trace.h"
 #include "src/core/lib/iomgr/error.h"
 
index fa8c4ae..0ea6af2 100644 (file)
 #include <grpc/support/port_platform.h>
 
 #include "src/core/lib/iomgr/buffer_list.h"
-#include "src/core/lib/iomgr/port.h"
 
 #include <grpc/support/log.h>
 
+#include "src/core/lib/iomgr/port.h"
+
 #ifdef GRPC_LINUX_ERRQUEUE
 #include <netinet/in.h>
 #include <string.h>
index 982c4c6..f09bbe1 100644 (file)
 
 #include "absl/types/optional.h"
 
-#include "src/core/lib/iomgr/port.h"
-
 #include <grpc/support/time.h>
 
 #include "src/core/lib/gprpp/memory.h"
 #include "src/core/lib/iomgr/error.h"
 #include "src/core/lib/iomgr/internal_errqueue.h"
+#include "src/core/lib/iomgr/port.h"
 
 namespace grpc_core {
 
index 44ffb12..945e835 100644 (file)
@@ -23,6 +23,7 @@
 #include <inttypes.h>
 
 #include <grpc/support/log.h>
+
 #include "src/core/lib/debug/stats.h"
 #include "src/core/lib/profiling/timers.h"
 
index fb11231..b94711c 100644 (file)
 
 #ifdef GRPC_CFSTREAM
 #import <CoreFoundation/CoreFoundation.h>
-#import "src/core/lib/iomgr/cfstream_handle.h"
 
 #include <grpc/grpc.h>
 #include <grpc/support/atm.h>
 #include <grpc/support/sync.h>
 
 #include "src/core/lib/debug/trace.h"
+#import "src/core/lib/iomgr/cfstream_handle.h"
 #include "src/core/lib/iomgr/closure.h"
 #include "src/core/lib/iomgr/error_cfstream.h"
 #include "src/core/lib/iomgr/ev_apple.h"
index 48237e5..6835313 100644 (file)
@@ -137,8 +137,9 @@ static void combiner_exec(grpc_core::Combiner* lock, grpc_closure* cl,
   if (last == 1) {
     GRPC_STATS_INC_COMBINER_LOCKS_INITIATED();
     GPR_TIMER_MARK("combiner.initiated", 0);
-    gpr_atm_no_barrier_store(&lock->initiating_exec_ctx_or_null,
-                             (gpr_atm)grpc_core::ExecCtx::Get());
+    gpr_atm_no_barrier_store(
+        &lock->initiating_exec_ctx_or_null,
+        reinterpret_cast<gpr_atm>(grpc_core::ExecCtx::Get()));
     // first element on this list: add it to the list of combiner locks
     // executing within this exec_ctx
     push_last_on_exec_ctx(lock);
index efa2bce..3b9ddfc 100644 (file)
@@ -24,6 +24,7 @@
 #include <stddef.h>
 
 #include <grpc/support/atm.h>
+
 #include "src/core/lib/debug/trace.h"
 #include "src/core/lib/iomgr/exec_ctx.h"
 
index dc0eafe..2d77113 100644 (file)
@@ -23,6 +23,7 @@
 #ifdef GRPC_POSIX_SOCKET_UTILS_COMMON
 
 #include <netinet/in.h>
+
 #include "src/core/lib/iomgr/socket_utils_posix.h"
 
 #ifndef GRPC_SET_SOCKET_DUALSTACK_CUSTOM
index 4c84501..a2f864c 100644 (file)
@@ -62,10 +62,6 @@ absl::string_view grpc_endpoint_get_local_address(grpc_endpoint* ep) {
 
 int grpc_endpoint_get_fd(grpc_endpoint* ep) { return ep->vtable->get_fd(ep); }
 
-grpc_resource_user* grpc_endpoint_get_resource_user(grpc_endpoint* ep) {
-  return ep->vtable->get_resource_user(ep);
-}
-
 bool grpc_endpoint_can_track_err(grpc_endpoint* ep) {
   return ep->vtable->can_track_err(ep);
 }
index 4db5e3d..2a01083 100644 (file)
@@ -26,6 +26,7 @@
 #include <grpc/slice.h>
 #include <grpc/slice_buffer.h>
 #include <grpc/support/time.h>
+
 #include "src/core/lib/iomgr/pollset.h"
 #include "src/core/lib/iomgr/pollset_set.h"
 #include "src/core/lib/iomgr/resource_quota.h"
@@ -46,7 +47,6 @@ struct grpc_endpoint_vtable {
   void (*delete_from_pollset_set)(grpc_endpoint* ep, grpc_pollset_set* pollset);
   void (*shutdown)(grpc_endpoint* ep, grpc_error_handle why);
   void (*destroy)(grpc_endpoint* ep);
-  grpc_resource_user* (*get_resource_user)(grpc_endpoint* ep);
   absl::string_view (*get_peer)(grpc_endpoint* ep);
   absl::string_view (*get_local_address)(grpc_endpoint* ep);
   int (*get_fd)(grpc_endpoint* ep);
@@ -99,8 +99,6 @@ void grpc_endpoint_add_to_pollset_set(grpc_endpoint* ep,
 void grpc_endpoint_delete_from_pollset_set(grpc_endpoint* ep,
                                            grpc_pollset_set* pollset_set);
 
-grpc_resource_user* grpc_endpoint_get_resource_user(grpc_endpoint* ep);
-
 bool grpc_endpoint_can_track_err(grpc_endpoint* ep);
 
 struct grpc_endpoint {
index 6394506..0cc341b 100644 (file)
@@ -23,7 +23,6 @@
 #ifdef GRPC_CFSTREAM_ENDPOINT
 
 #import <CoreFoundation/CoreFoundation.h>
-#import "src/core/lib/iomgr/endpoint_cfstream.h"
 
 #include <grpc/slice_buffer.h>
 #include <grpc/support/alloc.h>
@@ -34,6 +33,7 @@
 #include "src/core/lib/iomgr/cfstream_handle.h"
 #include "src/core/lib/iomgr/closure.h"
 #include "src/core/lib/iomgr/endpoint.h"
+#import "src/core/lib/iomgr/endpoint_cfstream.h"
 #include "src/core/lib/iomgr/error_cfstream.h"
 #include "src/core/lib/iomgr/sockaddr.h"
 #include "src/core/lib/slice/slice_internal.h"
@@ -59,11 +59,10 @@ struct CFStreamEndpoint {
 
   std::string peer_string;
   std::string local_address;
-  grpc_resource_user* resource_user;
-  grpc_resource_user_slice_allocator slice_allocator;
+  grpc_slice_allocator* slice_allocator;
 };
 static void CFStreamFree(CFStreamEndpoint* ep) {
-  grpc_resource_user_unref(ep->resource_user);
+  grpc_slice_allocator_destroy(ep->slice_allocator);
   CFRelease(ep->read_stream);
   CFRelease(ep->write_stream);
   CFSTREAM_HANDLE_UNREF(ep->stream_sync, "free");
@@ -263,9 +262,10 @@ static void CFStreamRead(grpc_endpoint* ep, grpc_slice_buffer* slices,
   ep_impl->read_slices = slices;
   grpc_slice_buffer_reset_and_unref_internal(slices);
   EP_REF(ep_impl, "read");
-  if (grpc_resource_user_alloc_slices(&ep_impl->slice_allocator,
-                                      GRPC_TCP_DEFAULT_READ_SLICE_SIZE, 1,
-                                      ep_impl->read_slices)) {
+  if (grpc_slice_allocator_allocate(
+          ep_impl->slice_allocator, GRPC_TCP_DEFAULT_READ_SLICE_SIZE, 1,
+          grpc_slice_allocator_intent::kReadBuffer, ep_impl->read_slices,
+          CFStreamReadAllocationDone, ep_impl)) {
     ep_impl->stream_sync->NotifyOnRead(&ep_impl->read_action);
   }
 }
@@ -292,7 +292,6 @@ void CFStreamShutdown(grpc_endpoint* ep, grpc_error_handle why) {
   CFReadStreamClose(ep_impl->read_stream);
   CFWriteStreamClose(ep_impl->write_stream);
   ep_impl->stream_sync->Shutdown(why);
-  grpc_resource_user_shutdown(ep_impl->resource_user);
   if (grpc_tcp_trace.enabled()) {
     gpr_log(GPR_DEBUG, "CFStream endpoint:%p shutdown DONE (%p)", ep_impl, why);
   }
@@ -306,11 +305,6 @@ void CFStreamDestroy(grpc_endpoint* ep) {
   EP_UNREF(ep_impl, "destroy");
 }
 
-grpc_resource_user* CFStreamGetResourceUser(grpc_endpoint* ep) {
-  CFStreamEndpoint* ep_impl = reinterpret_cast<CFStreamEndpoint*>(ep);
-  return ep_impl->resource_user;
-}
-
 absl::string_view CFStreamGetPeer(grpc_endpoint* ep) {
   CFStreamEndpoint* ep_impl = reinterpret_cast<CFStreamEndpoint*>(ep);
   return ep_impl->peer_string;
@@ -337,7 +331,6 @@ static const grpc_endpoint_vtable vtable = {CFStreamRead,
                                             CFStreamDeleteFromPollsetSet,
                                             CFStreamShutdown,
                                             CFStreamDestroy,
-                                            CFStreamGetResourceUser,
                                             CFStreamGetPeer,
                                             CFStreamGetLocalAddress,
                                             CFStreamGetFD,
@@ -345,7 +338,7 @@ static const grpc_endpoint_vtable vtable = {CFStreamRead,
 
 grpc_endpoint* grpc_cfstream_endpoint_create(
     CFReadStreamRef read_stream, CFWriteStreamRef write_stream,
-    const char* peer_string, grpc_resource_quota* resource_quota,
+    const char* peer_string, grpc_slice_allocator* slice_allocator,
     CFStreamHandle* stream_sync) {
   CFStreamEndpoint* ep_impl = new CFStreamEndpoint;
   if (grpc_tcp_trace.enabled()) {
@@ -387,11 +380,7 @@ grpc_endpoint* grpc_cfstream_endpoint_create(
                     static_cast<void*>(ep_impl), grpc_schedule_on_exec_ctx);
   GRPC_CLOSURE_INIT(&ep_impl->write_action, WriteAction,
                     static_cast<void*>(ep_impl), grpc_schedule_on_exec_ctx);
-  ep_impl->resource_user =
-      grpc_resource_user_create(resource_quota, peer_string);
-  grpc_resource_user_slice_allocator_init(&ep_impl->slice_allocator,
-                                          ep_impl->resource_user,
-                                          CFStreamReadAllocationDone, ep_impl);
+  ep_impl->slice_allocator = slice_allocator;
 
   return &ep_impl->base;
 }
index ef957c1..671bb3b 100644 (file)
@@ -41,7 +41,7 @@
 
 grpc_endpoint* grpc_cfstream_endpoint_create(
     CFReadStreamRef read_stream, CFWriteStreamRef write_stream,
-    const char* peer_string, grpc_resource_quota* resource_quota,
+    const char* peer_string, grpc_slice_allocator* slice_allocator,
     CFStreamHandle* stream_sync);
 
 #endif /* GRPC_CFSTREAM */
index e01185b..6150b5b 100644 (file)
@@ -27,6 +27,7 @@ struct grpc_endpoint_pair {
   grpc_endpoint* client;
   grpc_endpoint* server;
 };
+
 grpc_endpoint_pair grpc_iomgr_create_endpoint_pair(const char* name,
                                                    grpc_channel_args* args);
 
index a0062e1..7c0c100 100644 (file)
 #include <grpc/support/port_platform.h>
 
 #ifdef GRPC_USE_EVENT_ENGINE
-#include "src/core/lib/iomgr/port.h"
-
 #include <stdlib.h>
 
 #include <grpc/support/log.h>
 
 #include "src/core/lib/iomgr/endpoint_pair.h"
+#include "src/core/lib/iomgr/port.h"
 
 grpc_endpoint_pair grpc_iomgr_create_endpoint_pair(
     const char* /* name */, grpc_channel_args* /* args */) {
index a1a04eb..217ea37 100644 (file)
 
 #ifdef GRPC_POSIX_SOCKET_TCP
 
-#include "src/core/lib/iomgr/endpoint_pair.h"
-#include "src/core/lib/iomgr/socket_utils_posix.h"
-#include "src/core/lib/iomgr/unix_sockets_posix.h"
-
 #include <errno.h>
 #include <fcntl.h>
 #include <string.h>
 
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
+
 #include "src/core/lib/gpr/string.h"
+#include "src/core/lib/iomgr/endpoint_pair.h"
+#include "src/core/lib/iomgr/socket_utils_posix.h"
 #include "src/core/lib/iomgr/tcp_posix.h"
+#include "src/core/lib/iomgr/unix_sockets_posix.h"
 
 static void create_sockets(int sv[2]) {
   int flags;
@@ -57,16 +57,20 @@ grpc_endpoint_pair grpc_iomgr_create_endpoint_pair(const char* name,
   int sv[2];
   grpc_endpoint_pair p;
   create_sockets(sv);
-
   grpc_core::ExecCtx exec_ctx;
-
   std::string final_name = absl::StrCat(name, ":client");
-  p.client = grpc_tcp_create(grpc_fd_create(sv[1], final_name.c_str(), false),
-                             args, "socketpair-server");
+  grpc_resource_quota* resource_quota =
+      grpc_resource_quota_from_channel_args(args, true);
+  p.client = grpc_tcp_create(
+      grpc_fd_create(sv[1], final_name.c_str(), false), args,
+      "socketpair-server",
+      grpc_slice_allocator_create(resource_quota, "server_endpoint", args));
   final_name = absl::StrCat(name, ":server");
-  p.server = grpc_tcp_create(grpc_fd_create(sv[0], final_name.c_str(), false),
-                             args, "socketpair-client");
-
+  p.server = grpc_tcp_create(
+      grpc_fd_create(sv[0], final_name.c_str(), false), args,
+      "socketpair-client",
+      grpc_slice_allocator_create(resource_quota, "client_endpoint", args));
+  grpc_resource_quota_unref_internal(resource_quota);
   return p;
 }
 
diff --git a/src/core/lib/iomgr/endpoint_pair_uv.cc b/src/core/lib/iomgr/endpoint_pair_uv.cc
deleted file mode 100644 (file)
index b99d178..0000000
+++ /dev/null
@@ -1,40 +0,0 @@
-/*
- *
- * Copyright 2016 gRPC authors.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- *
- */
-
-#include <grpc/support/port_platform.h>
-
-#include "src/core/lib/iomgr/port.h"
-
-#ifdef GRPC_UV
-
-#include <stdlib.h>
-
-#include <grpc/support/log.h>
-
-#include "src/core/lib/iomgr/endpoint_pair.h"
-
-grpc_endpoint_pair grpc_iomgr_create_endpoint_pair(const char* name,
-                                                   grpc_channel_args* args) {
-  grpc_endpoint_pair endpoint_pair;
-  // TODO(mlumish): implement this properly under libuv
-  GPR_ASSERT(false &&
-             "grpc_iomgr_create_endpoint_pair is not suppoted with libuv");
-  return endpoint_pair;
-}
-
-#endif /* GRPC_UV */
index c1113e1..c1d34fa 100644 (file)
 #include "src/core/lib/iomgr/port.h"
 
 #ifdef GRPC_WINSOCK_SOCKET
-#include "src/core/lib/address_utils/sockaddr_utils.h"
-#include "src/core/lib/iomgr/endpoint_pair.h"
-#include "src/core/lib/iomgr/sockaddr.h"
-
 #include <errno.h>
 #include <fcntl.h>
 #include <string.h>
 
 #include <grpc/support/log.h>
+
+#include "src/core/lib/address_utils/sockaddr_utils.h"
+#include "src/core/lib/iomgr/endpoint_pair.h"
+#include "src/core/lib/iomgr/sockaddr.h"
 #include "src/core/lib/iomgr/socket_windows.h"
 #include "src/core/lib/iomgr/tcp_windows.h"
 
@@ -76,11 +76,19 @@ grpc_endpoint_pair grpc_iomgr_create_endpoint_pair(
   grpc_endpoint_pair p;
   create_sockets(sv);
   grpc_core::ExecCtx exec_ctx;
-  p.client = grpc_tcp_create(grpc_winsocket_create(sv[1], "endpoint:client"),
-                             channel_args, "endpoint:server");
-  p.server = grpc_tcp_create(grpc_winsocket_create(sv[0], "endpoint:server"),
-                             channel_args, "endpoint:client");
-
+  grpc_resource_quota* resource_quota =
+      grpc_resource_quota_from_channel_args(channel_args, true);
+  p.client =
+      grpc_tcp_create(grpc_winsocket_create(sv[1], "endpoint:client"),
+                      channel_args, "endpoint:server",
+                      grpc_slice_allocator_create(
+                          resource_quota, "endpoint:server", channel_args));
+  p.server =
+      grpc_tcp_create(grpc_winsocket_create(sv[0], "endpoint:server"),
+                      channel_args, "endpoint:client",
+                      grpc_slice_allocator_create(
+                          resource_quota, "endpoint:client", channel_args));
+  grpc_resource_quota_unref_internal(resource_quota);
   return p;
 }
 
index e0492b8..cd68014 100644 (file)
@@ -24,6 +24,8 @@
 #include <inttypes.h>
 #include <stdbool.h>
 
+#include "absl/status/status.h"
+
 #include <grpc/slice.h>
 #include <grpc/status.h>
 #include <grpc/support/log.h>
@@ -31,8 +33,7 @@
 
 #include "src/core/lib/debug/trace.h"
 #include "src/core/lib/gprpp/status_helper.h"
-
-#include "absl/status/status.h"
+#include "src/core/lib/slice/slice_internal.h"
 
 /// Opaque representation of an error.
 /// See https://github.com/grpc/grpc/blob/master/doc/core/grpc-error.md for a
@@ -165,6 +166,8 @@ void grpc_enable_error_creation();
   StatusCreate(absl::StatusCode::kUnknown, desc, DEBUG_LOCATION, {})
 #define GRPC_ERROR_CREATE_FROM_COPIED_STRING(desc) \
   StatusCreate(absl::StatusCode::kUnknown, desc, DEBUG_LOCATION, {})
+#define GRPC_ERROR_CREATE_FROM_CPP_STRING(desc) \
+  StatusCreate(absl::StatusCode::kUnknown, desc, DEBUG_LOCATION, {})
 #define GRPC_ERROR_CREATE_FROM_STRING_VIEW(desc) \
   StatusCreate(absl::StatusCode::kUnknown, desc, DEBUG_LOCATION, {})
 
@@ -199,6 +202,8 @@ static absl::Status grpc_status_create_from_vector(
 
 #define GRPC_ERROR_CREATE_FROM_VECTOR(desc, error_list) \
   grpc_status_create_from_vector(DEBUG_LOCATION, desc, error_list)
+#define GRPC_ERROR_CREATE_FROM_VECTOR_AND_CPP_STRING(desc, error_list) \
+  grpc_status_create_from_vector(DEBUG_LOCATION, desc, error_list)
 
 absl::Status grpc_os_error(const grpc_core::DebugLocation& location, int err,
                            const char* call_name) GRPC_MUST_USE_RESULT;
@@ -286,6 +291,9 @@ grpc_error_handle grpc_error_create(const char* file, int line,
 #define GRPC_ERROR_CREATE_FROM_COPIED_STRING(desc)                           \
   grpc_error_create(__FILE__, __LINE__, grpc_slice_from_copied_string(desc), \
                     NULL, 0)
+#define GRPC_ERROR_CREATE_FROM_CPP_STRING(desc)                           \
+  grpc_error_create(__FILE__, __LINE__, grpc_slice_from_cpp_string(desc), \
+                    NULL, 0)
 #define GRPC_ERROR_CREATE_FROM_STRING_VIEW(desc) \
   grpc_error_create(                             \
       __FILE__, __LINE__,                        \
@@ -301,18 +309,24 @@ grpc_error_handle grpc_error_create(const char* file, int line,
                     errs, count)
 
 #define GRPC_ERROR_CREATE_FROM_VECTOR(desc, error_list) \
-  grpc_error_create_from_vector(__FILE__, __LINE__, desc, error_list)
+  grpc_error_create_from_vector(                        \
+      __FILE__, __LINE__, grpc_slice_from_static_string, desc, error_list)
+#define GRPC_ERROR_CREATE_FROM_VECTOR_AND_CPP_STRING(desc, error_list) \
+  grpc_error_create_from_vector(__FILE__, __LINE__,                    \
+                                grpc_slice_from_cpp_string, desc, error_list)
 
 // Consumes all the errors in the vector and forms a referencing error from
 // them. If the vector is empty, return GRPC_ERROR_NONE.
-template <typename VectorType>
-static grpc_error_handle grpc_error_create_from_vector(const char* file,
-                                                       int line,
-                                                       const char* desc,
-                                                       VectorType* error_list) {
+template <typename VectorType, typename StringType,
+          typename SliceFromStringFunction>
+static grpc_error_handle grpc_error_create_from_vector(
+    const char* file, int line,
+    SliceFromStringFunction slice_from_string_function, StringType desc,
+    VectorType* error_list) {
   grpc_error_handle error = GRPC_ERROR_NONE;
   if (error_list->size() != 0) {
-    error = grpc_error_create(file, line, grpc_slice_from_static_string(desc),
+    error = grpc_error_create(file, line,
+                              slice_from_string_function(std::move(desc)),
                               error_list->data(), error_list->size());
     // Remove refs to all errors in error_list.
     for (size_t i = 0; i < error_list->size(); i++) {
index 114b3f2..9c93dde 100644 (file)
 #include <grpc/support/port_platform.h>
 
 #ifdef GRPC_CFSTREAM
+#include <CoreFoundation/CoreFoundation.h>
+
 #include <string>
 
 #include "absl/strings/str_format.h"
 
-#include <CoreFoundation/CoreFoundation.h>
-
 #include <grpc/support/alloc.h>
 
 #include "src/core/lib/iomgr/error.h"
index 50c1dde..8959ed1 100644 (file)
@@ -25,6 +25,7 @@
 #include <stdbool.h>  // TODO(unknown): , do we need this?
 
 #include <grpc/support/sync.h>
+
 #include "src/core/lib/iomgr/error.h"
 
 #ifndef GRPC_ERROR_IS_ABSEIL_STATUS
index f09cd78..9180563 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include "src/core/lib/iomgr/port.h"
-
 #include <grpc/support/log.h>
 
+#include "src/core/lib/iomgr/port.h"
+
 /* This polling engine is only relevant on linux kernels supporting epoll
    epoll_create() or epoll_create1() */
 #ifdef GRPC_LINUX_EPOLL
-#include "src/core/lib/iomgr/ev_epoll1_linux.h"
-
 #include <assert.h>
 #include <errno.h>
 #include <fcntl.h>
@@ -54,6 +52,7 @@
 #include "src/core/lib/gpr/useful.h"
 #include "src/core/lib/gprpp/manual_constructor.h"
 #include "src/core/lib/iomgr/block_annotate.h"
+#include "src/core/lib/iomgr/ev_epoll1_linux.h"
 #include "src/core/lib/iomgr/ev_posix.h"
 #include "src/core/lib/iomgr/iomgr_internal.h"
 #include "src/core/lib/iomgr/lockfree_event.h"
@@ -464,8 +463,8 @@ static void fd_has_errors(grpc_fd* fd) { fd->error_closure->SetReady(); }
  * Pollset Definitions
  */
 
-GPR_TLS_DECL(g_current_thread_pollset);
-GPR_TLS_DECL(g_current_thread_worker);
+static GPR_THREAD_LOCAL(grpc_pollset*) g_current_thread_pollset;
+static GPR_THREAD_LOCAL(grpc_pollset_worker*) g_current_thread_worker;
 
 /* The designated poller */
 static gpr_atm g_active_poller;
@@ -515,8 +514,6 @@ static size_t choose_neighborhood(void) {
 }
 
 static grpc_error_handle pollset_global_init(void) {
-  gpr_tls_init(&g_current_thread_pollset);
-  gpr_tls_init(&g_current_thread_worker);
   gpr_atm_no_barrier_store(&g_active_poller, 0);
   global_wakeup_fd.read_fd = -1;
   grpc_error_handle err = grpc_wakeup_fd_init(&global_wakeup_fd);
@@ -538,8 +535,6 @@ static grpc_error_handle pollset_global_init(void) {
 }
 
 static void pollset_global_shutdown(void) {
-  gpr_tls_destroy(&g_current_thread_pollset);
-  gpr_tls_destroy(&g_current_thread_worker);
   if (global_wakeup_fd.read_fd != -1) grpc_wakeup_fd_destroy(&global_wakeup_fd);
   for (size_t i = 0; i < g_num_neighborhoods; i++) {
     gpr_mu_destroy(&g_neighborhoods[i].mu);
@@ -1027,8 +1022,8 @@ static grpc_error_handle pollset_work(grpc_pollset* ps,
   }
 
   if (begin_worker(ps, &worker, worker_hdl, deadline)) {
-    gpr_tls_set(&g_current_thread_pollset, (intptr_t)ps);
-    gpr_tls_set(&g_current_thread_worker, (intptr_t)&worker);
+    g_current_thread_pollset = ps;
+    g_current_thread_worker = &worker;
     GPR_ASSERT(!ps->shutting_down);
     GPR_ASSERT(!ps->seen_inactive);
 
@@ -1055,13 +1050,13 @@ static grpc_error_handle pollset_work(grpc_pollset* ps,
 
     gpr_mu_lock(&ps->mu); /* lock */
 
-    gpr_tls_set(&g_current_thread_worker, 0);
+    g_current_thread_worker = nullptr;
   } else {
-    gpr_tls_set(&g_current_thread_pollset, (intptr_t)ps);
+    g_current_thread_pollset = ps;
   }
   end_worker(ps, &worker, worker_hdl);
 
-  gpr_tls_set(&g_current_thread_pollset, 0);
+  g_current_thread_pollset = nullptr;
   return error;
 }
 
@@ -1074,9 +1069,8 @@ static grpc_error_handle pollset_kick(grpc_pollset* pollset,
     std::vector<std::string> log;
     log.push_back(absl::StrFormat(
         "PS:%p KICK:%p curps=%p curworker=%p root=%p", pollset, specific_worker,
-        reinterpret_cast<void*>(gpr_tls_get(&g_current_thread_pollset)),
-        reinterpret_cast<void*>(gpr_tls_get(&g_current_thread_worker)),
-        pollset->root_worker));
+        static_cast<void*>(g_current_thread_pollset),
+        static_cast<void*>(g_current_thread_worker), pollset->root_worker));
     if (pollset->root_worker != nullptr) {
       log.push_back(absl::StrFormat(
           " {kick_state=%s next=%p {kick_state=%s}}",
@@ -1092,8 +1086,7 @@ static grpc_error_handle pollset_kick(grpc_pollset* pollset,
   }
 
   if (specific_worker == nullptr) {
-    if (gpr_tls_get(&g_current_thread_pollset) !=
-        reinterpret_cast<intptr_t>(pollset)) {
+    if (g_current_thread_pollset != pollset) {
       grpc_pollset_worker* root_worker = pollset->root_worker;
       if (root_worker == nullptr) {
         GRPC_STATS_INC_POLLSET_KICKED_WITHOUT_POLLER();
@@ -1185,8 +1178,7 @@ static grpc_error_handle pollset_kick(grpc_pollset* pollset,
       gpr_log(GPR_INFO, " .. specific worker already kicked");
     }
     goto done;
-  } else if (gpr_tls_get(&g_current_thread_worker) ==
-             reinterpret_cast<intptr_t>(specific_worker)) {
+  } else if (g_current_thread_worker == specific_worker) {
     GRPC_STATS_INC_POLLSET_KICK_OWN_THREAD();
     if (GRPC_TRACE_FLAG_ENABLED(grpc_polling_trace)) {
       gpr_log(GPR_INFO, " .. mark %p kicked", specific_worker);
index 72d7da7..2da53d2 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include "src/core/lib/iomgr/port.h"
-
 #include <grpc/support/log.h>
 
+#include "src/core/lib/iomgr/port.h"
+
 /* This polling engine is only relevant on linux kernels supporting epoll() */
 #ifdef GRPC_LINUX_EPOLL_CREATE1
 
-#include "src/core/lib/iomgr/ev_epollex_linux.h"
-
 #include <assert.h>
 #include <errno.h>
 #include <limits.h>
@@ -54,6 +52,7 @@
 #include "src/core/lib/gprpp/ref_counted.h"
 #include "src/core/lib/gprpp/sync.h"
 #include "src/core/lib/iomgr/block_annotate.h"
+#include "src/core/lib/iomgr/ev_epollex_linux.h"
 #include "src/core/lib/iomgr/iomgr_internal.h"
 #include "src/core/lib/iomgr/is_epollexclusive_available.h"
 #include "src/core/lib/iomgr/lockfree_event.h"
@@ -643,20 +642,16 @@ static grpc_error_handle pollable_add_fd(pollable* p, grpc_fd* fd) {
  * Pollset Definitions
  */
 
-GPR_TLS_DECL(g_current_thread_pollset);
-GPR_TLS_DECL(g_current_thread_worker);
+static GPR_THREAD_LOCAL(grpc_pollset*) g_current_thread_pollset;
+static GPR_THREAD_LOCAL(grpc_pollset_worker*) g_current_thread_worker;
 
 /* Global state management */
 static grpc_error_handle pollset_global_init(void) {
-  gpr_tls_init(&g_current_thread_pollset);
-  gpr_tls_init(&g_current_thread_worker);
   return pollable_create(PO_EMPTY, &g_empty_pollable);
 }
 
 static void pollset_global_shutdown(void) {
   POLLABLE_UNREF(g_empty_pollable, "g_empty_pollable");
-  gpr_tls_destroy(&g_current_thread_pollset);
-  gpr_tls_destroy(&g_current_thread_worker);
 }
 
 /* pollset->mu must be held while calling this function */
@@ -693,8 +688,7 @@ static grpc_error_handle kick_one_worker(grpc_pollset_worker* specific_worker) {
     GRPC_STATS_INC_POLLSET_KICKED_AGAIN();
     return GRPC_ERROR_NONE;
   }
-  if (gpr_tls_get(&g_current_thread_worker) ==
-      reinterpret_cast<intptr_t>(specific_worker)) {
+  if (g_current_thread_worker == specific_worker) {
     if (GRPC_TRACE_FLAG_ENABLED(grpc_polling_trace)) {
       gpr_log(GPR_INFO, "PS:%p kicked_specific_but_awake", p);
     }
@@ -731,14 +725,13 @@ static grpc_error_handle pollset_kick(grpc_pollset* pollset,
   GRPC_STATS_INC_POLLSET_KICK();
   if (GRPC_TRACE_FLAG_ENABLED(grpc_polling_trace)) {
     gpr_log(GPR_INFO,
-            "PS:%p kick %p tls_pollset=%" PRIxPTR " tls_worker=%" PRIxPTR
-            " pollset.root_worker=%p",
-            pollset, specific_worker, gpr_tls_get(&g_current_thread_pollset),
-            gpr_tls_get(&g_current_thread_worker), pollset->root_worker);
+            "PS:%p kick %p tls_pollset=%p tls_worker=%p pollset.root_worker=%p",
+            pollset, specific_worker,
+            static_cast<void*>(g_current_thread_pollset),
+            static_cast<void*>(g_current_thread_worker), pollset->root_worker);
   }
   if (specific_worker == nullptr) {
-    if (gpr_tls_get(&g_current_thread_pollset) !=
-        reinterpret_cast<intptr_t>(pollset)) {
+    if (g_current_thread_pollset != pollset) {
       if (pollset->root_worker == nullptr) {
         if (GRPC_TRACE_FLAG_ENABLED(grpc_polling_trace)) {
           gpr_log(GPR_INFO, "PS:%p kicked_any_without_poller", pollset);
@@ -1132,8 +1125,8 @@ static grpc_error_handle pollset_work(grpc_pollset* pollset,
     pollset->kicked_without_poller = false;
   } else {
     if (begin_worker(pollset, WORKER_PTR, worker_hdl, deadline)) {
-      gpr_tls_set(&g_current_thread_pollset, (intptr_t)pollset);
-      gpr_tls_set(&g_current_thread_worker, (intptr_t)WORKER_PTR);
+      g_current_thread_pollset = pollset;
+      g_current_thread_worker = WORKER_PTR;
       if (WORKER_PTR->pollable_obj->event_cursor ==
           WORKER_PTR->pollable_obj->event_count) {
         append_error(&error, pollable_epoll(WORKER_PTR->pollable_obj, deadline),
@@ -1144,8 +1137,8 @@ static grpc_error_handle pollset_work(grpc_pollset* pollset,
           pollable_process_events(pollset, WORKER_PTR->pollable_obj, false),
           err_desc);
       grpc_core::ExecCtx::Get()->Flush();
-      gpr_tls_set(&g_current_thread_pollset, 0);
-      gpr_tls_set(&g_current_thread_worker, 0);
+      g_current_thread_pollset = nullptr;
+      g_current_thread_worker = nullptr;
     }
     end_worker(pollset, WORKER_PTR, worker_hdl);
   }
index fa4242f..cd22b60 100644 (file)
@@ -22,8 +22,6 @@
 
 #ifdef GRPC_POSIX_SOCKET_EV_POLL
 
-#include "src/core/lib/iomgr/ev_poll_posix.h"
-
 #include <assert.h>
 #include <errno.h>
 #include <limits.h>
@@ -45,6 +43,7 @@
 #include "src/core/lib/gpr/useful.h"
 #include "src/core/lib/gprpp/thd.h"
 #include "src/core/lib/iomgr/block_annotate.h"
+#include "src/core/lib/iomgr/ev_poll_posix.h"
 #include "src/core/lib/iomgr/iomgr_internal.h"
 #include "src/core/lib/iomgr/wakeup_fd_posix.h"
 #include "src/core/lib/profiling/timers.h"
@@ -706,8 +705,8 @@ static void fd_end_poll(grpc_fd_watcher* watcher, int got_read, int got_write) {
  * pollset_posix.c
  */
 
-GPR_TLS_DECL(g_current_thread_poller);
-GPR_TLS_DECL(g_current_thread_worker);
+static GPR_THREAD_LOCAL(grpc_pollset*) g_current_thread_poller;
+static GPR_THREAD_LOCAL(grpc_pollset_worker*) g_current_thread_worker;
 
 static void remove_worker(grpc_pollset* /*p*/, grpc_pollset_worker* worker) {
   worker->prev->next = worker->next;
@@ -776,8 +775,7 @@ static grpc_error_handle pollset_kick_ext(grpc_pollset* p,
             &error, grpc_wakeup_fd_wakeup(&specific_worker->wakeup_fd->fd));
       }
       p->kicked_without_pollers = true;
-    } else if (gpr_tls_get(&g_current_thread_worker) !=
-               reinterpret_cast<intptr_t>(specific_worker)) {
+    } else if (g_current_thread_worker != specific_worker) {
       GPR_TIMER_MARK("different_thread_worker", 0);
       if ((flags & GRPC_POLLSET_REEVALUATE_POLLING_ON_WAKEUP) != 0) {
         specific_worker->reevaluate_polling_on_wakeup = true;
@@ -794,20 +792,17 @@ static grpc_error_handle pollset_kick_ext(grpc_pollset* p,
       kick_append_error(&error,
                         grpc_wakeup_fd_wakeup(&specific_worker->wakeup_fd->fd));
     }
-  } else if (gpr_tls_get(&g_current_thread_poller) !=
-             reinterpret_cast<intptr_t>(p)) {
+  } else if (g_current_thread_poller != p) {
     GPR_ASSERT((flags & GRPC_POLLSET_REEVALUATE_POLLING_ON_WAKEUP) == 0);
     GPR_TIMER_MARK("kick_anonymous", 0);
     specific_worker = pop_front_worker(p);
     if (specific_worker != nullptr) {
-      if (gpr_tls_get(&g_current_thread_worker) ==
-          reinterpret_cast<intptr_t>(specific_worker)) {
+      if (g_current_thread_worker == specific_worker) {
         GPR_TIMER_MARK("kick_anonymous_not_self", 0);
         push_back_worker(p, specific_worker);
         specific_worker = pop_front_worker(p);
         if ((flags & GRPC_POLLSET_CAN_KICK_SELF) == 0 &&
-            gpr_tls_get(&g_current_thread_worker) ==
-                reinterpret_cast<intptr_t>(specific_worker)) {
+            g_current_thread_worker == specific_worker) {
           push_back_worker(p, specific_worker);
           specific_worker = nullptr;
         }
@@ -835,16 +830,9 @@ static grpc_error_handle pollset_kick(grpc_pollset* p,
 
 /* global state management */
 
-static grpc_error_handle pollset_global_init(void) {
-  gpr_tls_init(&g_current_thread_poller);
-  gpr_tls_init(&g_current_thread_worker);
-  return GRPC_ERROR_NONE;
-}
+static grpc_error_handle pollset_global_init(void) { return GRPC_ERROR_NONE; }
 
-static void pollset_global_shutdown(void) {
-  gpr_tls_destroy(&g_current_thread_poller);
-  gpr_tls_destroy(&g_current_thread_worker);
-}
+static void pollset_global_shutdown(void) {}
 
 /* main interface */
 
@@ -959,7 +947,7 @@ static grpc_error_handle pollset_work(grpc_pollset* pollset,
      re-evaluate our pollers (this allows poll() based pollers to
      ensure they don't miss wakeups) */
   keep_polling = 1;
-  gpr_tls_set(&g_current_thread_poller, (intptr_t)pollset);
+  g_current_thread_poller = pollset;
   while (keep_polling) {
     keep_polling = 0;
     if (!pollset->kicked_without_pollers ||
@@ -967,7 +955,7 @@ static grpc_error_handle pollset_work(grpc_pollset* pollset,
       if (!added_worker) {
         push_front_worker(pollset, &worker);
         added_worker = 1;
-        gpr_tls_set(&g_current_thread_worker, (intptr_t)&worker);
+        g_current_thread_worker = &worker;
       }
       GPR_TIMER_SCOPE("maybe_work_and_unlock", 0);
 #define POLLOUT_CHECK (POLLOUT | POLLHUP | POLLERR)
@@ -1115,10 +1103,10 @@ static grpc_error_handle pollset_work(grpc_pollset* pollset,
       keep_polling = 1;
     }
   }
-  gpr_tls_set(&g_current_thread_poller, 0);
+  g_current_thread_poller = nullptr;
   if (added_worker) {
     remove_worker(pollset, &worker);
-    gpr_tls_set(&g_current_thread_worker, 0);
+    g_current_thread_worker = nullptr;
   }
   /* release wakeup fd to the local pool */
   worker.wakeup_fd->next = pollset->local_wakeup_cache;
index dfb250f..bae0f15 100644 (file)
@@ -22,8 +22,6 @@
 
 #ifdef GRPC_POSIX_SOCKET_EV
 
-#include "src/core/lib/iomgr/ev_posix.h"
-
 #include <string.h>
 
 #include <grpc/support/alloc.h>
@@ -36,6 +34,7 @@
 #include "src/core/lib/iomgr/ev_epoll1_linux.h"
 #include "src/core/lib/iomgr/ev_epollex_linux.h"
 #include "src/core/lib/iomgr/ev_poll_posix.h"
+#include "src/core/lib/iomgr/ev_posix.h"
 #include "src/core/lib/iomgr/internal_errqueue.h"
 
 GPR_GLOBAL_CONFIG_DEFINE_STRING(
index 3de39a4..c8e2feb 100644 (file)
 #include <grpc/support/port_platform.h>
 
 #ifdef GRPC_USE_EVENT_ENGINE
-#include "src/core/lib/iomgr/event_engine/endpoint.h"
+#include "absl/strings/string_view.h"
 
 #include <grpc/event_engine/event_engine.h>
 #include <grpc/slice.h>
 #include <grpc/slice_buffer.h>
 #include <grpc/support/time.h>
-#include "absl/strings/string_view.h"
 
 #include "src/core/lib/address_utils/sockaddr_utils.h"
 #include "src/core/lib/channel/channel_args.h"
 #include "src/core/lib/iomgr/endpoint.h"
 #include "src/core/lib/iomgr/error.h"
 #include "src/core/lib/iomgr/event_engine/closure.h"
+#include "src/core/lib/iomgr/event_engine/endpoint.h"
 #include "src/core/lib/iomgr/event_engine/pollset.h"
 #include "src/core/lib/iomgr/pollset.h"
 #include "src/core/lib/iomgr/pollset_set.h"
@@ -39,6 +39,7 @@ namespace {
 
 using ::grpc_event_engine::experimental::EventEngine;
 using ::grpc_event_engine::experimental::ResolvedAddressToURI;
+using ::grpc_event_engine::experimental::SliceAllocator;
 using ::grpc_event_engine::experimental::SliceBuffer;
 
 void endpoint_read(grpc_endpoint* ep, grpc_slice_buffer* slices,
@@ -102,21 +103,14 @@ void endpoint_shutdown(grpc_endpoint* ep, grpc_error* why) {
     gpr_log(GPR_INFO, "TCP Endpoint %p shutdown why=%s", eeep->endpoint.get(),
             str);
   }
-  grpc_resource_user_shutdown(eeep->ru);
   eeep->endpoint.reset();
 }
 
 void endpoint_destroy(grpc_endpoint* ep) {
   auto* eeep = reinterpret_cast<grpc_event_engine_endpoint*>(ep);
-  grpc_resource_user_unref(eeep->ru);
   delete eeep;
 }
 
-grpc_resource_user* endpoint_get_resource_user(grpc_endpoint* ep) {
-  auto* eeep = reinterpret_cast<grpc_event_engine_endpoint*>(ep);
-  return eeep->ru;
-}
-
 absl::string_view endpoint_get_peer(grpc_endpoint* ep) {
   auto* eeep = reinterpret_cast<grpc_event_engine_endpoint*>(ep);
   if (eeep->endpoint == nullptr) {
@@ -154,7 +148,6 @@ grpc_endpoint_vtable grpc_event_engine_endpoint_vtable = {
     endpoint_delete_from_pollset_set,
     endpoint_shutdown,
     endpoint_destroy,
-    endpoint_get_resource_user,
     endpoint_get_peer,
     endpoint_get_local_address,
     endpoint_get_fd,
@@ -166,7 +159,6 @@ grpc_event_engine_endpoint* grpc_tcp_server_endpoint_create(
     std::unique_ptr<EventEngine::Endpoint> ee_endpoint) {
   auto endpoint = new grpc_event_engine_endpoint;
   endpoint->base.vtable = &grpc_event_engine_endpoint_vtable;
-  // TODO(hork): populate endpoint->ru from the uvEngine's subclass
   endpoint->endpoint = std::move(ee_endpoint);
   return endpoint;
 }
@@ -175,17 +167,6 @@ grpc_endpoint* grpc_tcp_create(const grpc_channel_args* channel_args,
                                absl::string_view peer_address) {
   auto endpoint = new grpc_event_engine_endpoint;
   endpoint->base.vtable = &grpc_event_engine_endpoint_vtable;
-  grpc_resource_quota* resource_quota =
-      grpc_channel_args_find_pointer<grpc_resource_quota>(
-          channel_args, GRPC_ARG_RESOURCE_QUOTA);
-  if (resource_quota != nullptr) {
-    grpc_resource_quota_ref_internal(resource_quota);
-  } else {
-    resource_quota = grpc_resource_quota_create(nullptr);
-  }
-  endpoint->ru = grpc_resource_user_create(resource_quota,
-                                           std::string(peer_address).c_str());
-  grpc_resource_quota_unref_internal(resource_quota);
   return &endpoint->base;
 }
 
index e4a729d..b0c5c52 100644 (file)
@@ -28,7 +28,6 @@ struct grpc_event_engine_endpoint {
       endpoint;
   std::string peer_address;
   std::string local_address;
-  grpc_resource_user* ru = nullptr;
   std::aligned_storage<
       sizeof(grpc_event_engine::experimental::SliceBuffer),
       alignof(grpc_event_engine::experimental::SliceBuffer)>::type read_buffer;
@@ -45,7 +44,7 @@ grpc_event_engine_endpoint* grpc_tcp_server_endpoint_create(
 
 /// Creates a new internal grpc_endpoint struct, when no EventEngine Endpoint
 /// has yet been created. This is used in client code before connections are
-/// established.
+/// established. Takes ownership of the slice_allocator.
 grpc_endpoint* grpc_tcp_create(const grpc_channel_args* channel_args,
                                absl::string_view peer_address);
 
index eb067b1..6a5a798 100644 (file)
 #include <grpc/support/port_platform.h>
 
 #ifdef GRPC_USE_EVENT_ENGINE
-#include "src/core/lib/iomgr/event_engine/iomgr.h"
-
 #include <grpc/event_engine/event_engine.h>
 
 #include "src/core/lib/debug/trace.h"
 #include "src/core/lib/iomgr/closure.h"
-#include "src/core/lib/iomgr/event_engine/promise.h"
+#include "src/core/lib/iomgr/event_engine/iomgr.h"
 #include "src/core/lib/iomgr/iomgr_internal.h"
 #include "src/core/lib/iomgr/tcp_client.h"
 #include "src/core/lib/iomgr/tcp_server.h"
@@ -42,25 +40,15 @@ namespace {
 
 using ::grpc_event_engine::experimental::DefaultEventEngineFactory;
 using ::grpc_event_engine::experimental::EventEngine;
-using ::grpc_event_engine::experimental::Promise;
 
-// Note: This is a pointer to a shared_ptr, so it's trivially destructible.
-std::shared_ptr<EventEngine>* g_event_engine;
+EventEngine* g_event_engine = nullptr;
 
-void iomgr_platform_init(void) {
-  g_event_engine =
-      new std::shared_ptr<EventEngine>(DefaultEventEngineFactory());
-}
+// TODO(nnoble): Instantiate the default EventEngine if none have been provided.
+void iomgr_platform_init(void) { GPR_ASSERT(g_event_engine != nullptr); }
 
 void iomgr_platform_flush(void) {}
 
 void iomgr_platform_shutdown(void) {
-  Promise<absl::Status> shutdown_status_promise;
-  (*g_event_engine)->Shutdown([&shutdown_status_promise](absl::Status status) {
-    shutdown_status_promise.Set(std::move(status));
-  });
-  auto shutdown_status = shutdown_status_promise.Get();
-  GPR_ASSERT(shutdown_status.ok());
   delete g_event_engine;
   g_event_engine = nullptr;
 }
@@ -68,7 +56,7 @@ void iomgr_platform_shutdown(void) {
 void iomgr_platform_shutdown_background_closure(void) {}
 
 bool iomgr_platform_is_any_background_poller_thread(void) {
-  return (*g_event_engine)->IsWorkerThread();
+  return g_event_engine->IsWorkerThread();
 }
 
 bool iomgr_platform_add_closure_to_background_poller(
@@ -99,7 +87,18 @@ void grpc_set_default_iomgr_platform() {
 bool grpc_iomgr_run_in_background() { return false; }
 
 grpc_event_engine::experimental::EventEngine* grpc_iomgr_event_engine() {
-  return g_event_engine->get();
+  return g_event_engine;
 }
 
+namespace grpc_core {
+
+void SetDefaultEventEngine(
+    std::unique_ptr<grpc_event_engine::experimental::EventEngine>
+        event_engine) {
+  GPR_ASSERT(g_event_engine == nullptr);
+  g_event_engine = event_engine.release();
+}
+
+}  // namespace grpc_core
+
 #endif  // GRPC_USE_EVENT_ENGINE
index 96e97e5..8026c28 100644 (file)
 
 #include <grpc/event_engine/event_engine.h>
 
-// This can be called anywhere in the EE-based iomgr impl where we need to
-// access the global EE instance.
+/// This can be called anywhere in the EventEngine-based iomgr impl where we
+/// need to access the global EventEngine instance.
 grpc_event_engine::experimental::EventEngine* grpc_iomgr_event_engine();
 
+namespace grpc_core {
+
+/// Set the default \a EventEngine.
+///
+/// The iomgr interfaces conceptually expose a global singleton iomgr instance
+/// that is shared throughout gRPC. To accomodate an EventEngine-based iomgr
+/// implementation, this method sets the default EventEngine that will be used.
+/// The default EventEngine can only be set once during the lifetime of gRPC.
+/// This method must be called before \a grpc_init() (truly, before
+/// \a grpc_iomgr_init()). This engine is shut down along with iomgr.
+///
+/// This is an internal method, not intended for public use. Public APIs are
+/// being planned.
+void SetDefaultEventEngine(
+    std::unique_ptr<grpc_event_engine::experimental::EventEngine> event_engine);
+
+}  // namespace grpc_core
+
 #endif  // GRPC_CORE_LIB_IOMGR_EVENT_ENGINE_IOMGR_H
index 3671302..ea0528f 100644 (file)
 #include <grpc/support/port_platform.h>
 
 #ifdef GRPC_USE_EVENT_ENGINE
-#include <grpc/event_engine/event_engine.h>
 #include "absl/functional/bind_front.h"
 
+#include <grpc/event_engine/event_engine.h>
+
 #include "src/core/lib/address_utils/sockaddr_utils.h"
 #include "src/core/lib/gprpp/sync.h"
 #include "src/core/lib/iomgr/error.h"
index e119dfc..6eb2691 100644 (file)
@@ -41,23 +41,53 @@ using ::grpc_event_engine::experimental::SliceAllocatorFactory;
 using ::grpc_event_engine::experimental::SliceBuffer;
 }  // namespace
 
-// TODO(hork): remove these classes in PR #26643, when the iomgr APIs change to
-// accept SliceAllocators and SliceAllocatorFactory(ie)s. In the meantime, the
-// libuv work has temporary implementations as well.
-class NoopSliceAllocator : public SliceAllocator {
+class WrappedInternalSliceAllocator : public SliceAllocator {
  public:
+  explicit WrappedInternalSliceAllocator(grpc_slice_allocator* slice_allocator)
+      : slice_allocator_(slice_allocator) {}
+
+  ~WrappedInternalSliceAllocator() {
+    grpc_slice_allocator_destroy(slice_allocator_);
+  }
+
   absl::Status Allocate(size_t size, SliceBuffer* dest,
-                        SliceAllocator::AllocateCallback cb) {
+                        SliceAllocator::AllocateCallback cb) override {
+    // TODO(nnoble): requires the SliceBuffer definition.
+    grpc_slice_allocator_allocate(
+        slice_allocator_, size, 1, grpc_slice_allocator_intent::kReadBuffer,
+        dest->RawSliceBuffer(),
+        [](void* arg, grpc_error_handle error) {
+          auto cb = static_cast<SliceAllocator::AllocateCallback*>(arg);
+          (*cb)(grpc_error_to_absl_status(error));
+          delete cb;
+        },
+        new SliceAllocator::AllocateCallback(cb));
     return absl::OkStatus();
   }
+
+ private:
+  grpc_slice_allocator* slice_allocator_;
 };
 
-class NoopSliceAllocatorFactory : public SliceAllocatorFactory {
+class WrappedInternalSliceAllocatorFactory : public SliceAllocatorFactory {
  public:
+  explicit WrappedInternalSliceAllocatorFactory(
+      grpc_slice_allocator_factory* slice_allocator_factory)
+      : slice_allocator_factory_(slice_allocator_factory) {}
+
+  ~WrappedInternalSliceAllocatorFactory() {
+    grpc_slice_allocator_factory_destroy(slice_allocator_factory_);
+  }
+
   std::unique_ptr<SliceAllocator> CreateSliceAllocator(
-      absl::string_view peer_name) {
-    return absl::make_unique<NoopSliceAllocator>();
+      absl::string_view peer_name) override {
+    return absl::make_unique<WrappedInternalSliceAllocator>(
+        grpc_slice_allocator_factory_create_slice_allocator(
+            slice_allocator_factory_, peer_name));
   };
+
+ private:
+  grpc_slice_allocator_factory* slice_allocator_factory_;
 };
 
 struct grpc_tcp_server {
@@ -105,6 +135,7 @@ EventEngine::OnConnectCallback GrpcClosureToOnConnectCallback(
 
 /// Usage note: this method does not take ownership of any pointer arguments.
 void tcp_connect(grpc_closure* on_connect, grpc_endpoint** endpoint,
+                 grpc_slice_allocator* slice_allocator,
                  grpc_pollset_set* /* interested_parties */,
                  const grpc_channel_args* channel_args,
                  const grpc_resolved_address* addr, grpc_millis deadline) {
@@ -114,16 +145,16 @@ void tcp_connect(grpc_closure* on_connect, grpc_endpoint** endpoint,
   *endpoint = &ee_endpoint->base;
   EventEngine::OnConnectCallback ee_on_connect =
       GrpcClosureToOnConnectCallback(on_connect, endpoint);
-  // TODO(hork): tcp_connect will change to accept a SliceAllocator. This is
-  // temporary.
-  auto sa = absl::make_unique<NoopSliceAllocator>();
+  auto ee_slice_allocator =
+      absl::make_unique<WrappedInternalSliceAllocator>(slice_allocator);
   EventEngine::ResolvedAddress ra(reinterpret_cast<const sockaddr*>(addr->addr),
                                   addr->len);
   absl::Time ee_deadline = grpc_core::ToAbslTime(
       grpc_millis_to_timespec(deadline, GPR_CLOCK_MONOTONIC));
   ChannelArgsEndpointConfig endpoint_config(channel_args);
   absl::Status connected = grpc_iomgr_event_engine()->Connect(
-      ee_on_connect, ra, endpoint_config, std::move(sa), ee_deadline);
+      ee_on_connect, ra, endpoint_config, std::move(ee_slice_allocator),
+      ee_deadline);
   if (!connected.ok()) {
     // EventEngine failed to start an asynchronous connect.
     grpc_endpoint_destroy(*endpoint);
@@ -133,17 +164,14 @@ void tcp_connect(grpc_closure* on_connect, grpc_endpoint** endpoint,
   }
 }
 
-grpc_error* tcp_server_create(grpc_closure* shutdown_complete,
-                              const grpc_channel_args* args,
-                              grpc_tcp_server** server) {
+grpc_error* tcp_server_create(
+    grpc_closure* shutdown_complete, const grpc_channel_args* args,
+    grpc_slice_allocator_factory* slice_allocator_factory,
+    grpc_tcp_server** server) {
   ChannelArgsEndpointConfig endpoint_config(args);
-  grpc_resource_quota* rq = grpc_resource_quota_from_channel_args(args);
-  if (rq == nullptr) {
-    rq = grpc_resource_quota_create(nullptr);
-  }
-  // TODO(hork): tcp_server_create will change to accept a
-  // SliceAllocatorFactory. This is temporary.
-  auto saf = absl::make_unique<NoopSliceAllocatorFactory>();
+  auto ee_slice_allocator_factory =
+      absl::make_unique<WrappedInternalSliceAllocatorFactory>(
+          slice_allocator_factory);
   EventEngine* event_engine = grpc_iomgr_event_engine();
   absl::StatusOr<std::unique_ptr<EventEngine::Listener>> listener =
       event_engine->CreateListener(
@@ -164,7 +192,7 @@ grpc_error* tcp_server_create(grpc_closure* shutdown_complete,
             grpc_pollset_ee_broadcast_event();
           },
           GrpcClosureToCallback(shutdown_complete, GRPC_ERROR_NONE),
-          endpoint_config, std::move(saf));
+          endpoint_config, std::move(ee_slice_allocator_factory));
   if (!listener.ok()) {
     return absl_status_to_grpc_error(listener.status());
   }
@@ -256,7 +284,8 @@ grpc_fd* grpc_fd_create(int /* fd */, const char* /* name */,
 
 grpc_endpoint* grpc_tcp_client_create_from_fd(
     grpc_fd* /* fd */, const grpc_channel_args* /* channel_args */,
-    const char* /* addr_str */) {
+    const char* /* addr_str */, grpc_slice_allocator* slice_allocator) {
+  grpc_slice_allocator_destroy(slice_allocator);
   return nullptr;
 }
 
index b1ae781..b551106 100644 (file)
@@ -131,13 +131,13 @@ grpc_millis grpc_cycle_counter_to_millis_round_up(gpr_cycle_counter cycles) {
 }
 
 namespace grpc_core {
-GPR_TLS_CLASS_DEF(ExecCtx::exec_ctx_);
-GPR_TLS_CLASS_DEF(ApplicationCallbackExecCtx::callback_exec_ctx_);
+GPR_THREAD_LOCAL(ExecCtx*) ExecCtx::exec_ctx_;
+GPR_THREAD_LOCAL(ApplicationCallbackExecCtx*)
+ApplicationCallbackExecCtx::callback_exec_ctx_;
 
 // WARNING: for testing purposes only!
 void ExecCtx::TestOnlyGlobalInit(gpr_timespec new_val) {
   g_start_time = new_val;
-  gpr_tls_init(&exec_ctx_);
 }
 
 void ExecCtx::GlobalInit(void) {
@@ -148,7 +148,6 @@ void ExecCtx::GlobalInit(void) {
   g_start_time = gpr_now(GPR_CLOCK_MONOTONIC);
   const gpr_cycle_counter cycle_after = gpr_get_cycle_counter();
   g_start_cycle = (cycle_before + cycle_after) / 2;
-  gpr_tls_init(&exec_ctx_);
 }
 
 bool ExecCtx::Flush() {
index 4123b3c..1465c5a 100644 (file)
@@ -216,16 +216,12 @@ class ExecCtx {
   static void GlobalInit(void);
 
   /** Global shutdown for ExecCtx. Called by iomgr. */
-  static void GlobalShutdown(void) { gpr_tls_destroy(&exec_ctx_); }
+  static void GlobalShutdown(void) {}
 
   /** Gets pointer to current exec_ctx. */
-  static ExecCtx* Get() {
-    return reinterpret_cast<ExecCtx*>(gpr_tls_get(&exec_ctx_));
-  }
+  static ExecCtx* Get() { return exec_ctx_; }
 
-  static void Set(ExecCtx* exec_ctx) {
-    gpr_tls_set(&exec_ctx_, reinterpret_cast<intptr_t>(exec_ctx));
-  }
+  static void Set(ExecCtx* exec_ctx) { exec_ctx_ = exec_ctx; }
 
   static void Run(const DebugLocation& location, grpc_closure* closure,
                   grpc_error_handle error);
@@ -251,7 +247,7 @@ class ExecCtx {
   bool now_is_valid_ = false;
   grpc_millis now_ = 0;
 
-  GPR_TLS_CLASS_DECL(exec_ctx_);
+  static GPR_THREAD_LOCAL(ExecCtx*) exec_ctx_;
   ExecCtx* last_exec_ctx_ = Get();
 };
 
@@ -313,8 +309,7 @@ class ApplicationCallbackExecCtx {
   }
 
   ~ApplicationCallbackExecCtx() {
-    if (reinterpret_cast<ApplicationCallbackExecCtx*>(
-            gpr_tls_get(&callback_exec_ctx_)) == this) {
+    if (Get() == this) {
       while (head_ != nullptr) {
         auto* f = head_;
         head_ = f->internal_next;
@@ -323,7 +318,7 @@ class ApplicationCallbackExecCtx {
         }
         (*f->functor_run)(f, f->internal_success);
       }
-      gpr_tls_set(&callback_exec_ctx_, reinterpret_cast<intptr_t>(nullptr));
+      callback_exec_ctx_ = nullptr;
       if (!(GRPC_APP_CALLBACK_EXEC_CTX_FLAG_IS_INTERNAL_THREAD & flags_)) {
         grpc_core::Fork::DecExecCtxCount();
       }
@@ -335,17 +330,14 @@ class ApplicationCallbackExecCtx {
 
   uintptr_t Flags() { return flags_; }
 
-  static ApplicationCallbackExecCtx* Get() {
-    return reinterpret_cast<ApplicationCallbackExecCtx*>(
-        gpr_tls_get(&callback_exec_ctx_));
-  }
+  static ApplicationCallbackExecCtx* Get() { return callback_exec_ctx_; }
 
   static void Set(ApplicationCallbackExecCtx* exec_ctx, uintptr_t flags) {
     if (Get() == nullptr) {
       if (!(GRPC_APP_CALLBACK_EXEC_CTX_FLAG_IS_INTERNAL_THREAD & flags)) {
         grpc_core::Fork::IncExecCtxCount();
       }
-      gpr_tls_set(&callback_exec_ctx_, reinterpret_cast<intptr_t>(exec_ctx));
+      callback_exec_ctx_ = exec_ctx;
     }
   }
 
@@ -365,10 +357,10 @@ class ApplicationCallbackExecCtx {
   }
 
   /** Global initialization for ApplicationCallbackExecCtx. Called by init. */
-  static void GlobalInit(void) { gpr_tls_init(&callback_exec_ctx_); }
+  static void GlobalInit(void) {}
 
   /** Global shutdown for ApplicationCallbackExecCtx. Called by init. */
-  static void GlobalShutdown(void) { gpr_tls_destroy(&callback_exec_ctx_); }
+  static void GlobalShutdown(void) {}
 
   static bool Available() { return Get() != nullptr; }
 
@@ -376,7 +368,7 @@ class ApplicationCallbackExecCtx {
   uintptr_t flags_{0u};
   grpc_completion_queue_functor* head_{nullptr};
   grpc_completion_queue_functor* tail_{nullptr};
-  GPR_TLS_CLASS_DECL(callback_exec_ctx_);
+  static GPR_THREAD_LOCAL(ApplicationCallbackExecCtx*) callback_exec_ctx_;
 };
 }  // namespace grpc_core
 
index 3d8d757..50edabf 100644 (file)
@@ -53,7 +53,7 @@
 namespace grpc_core {
 namespace {
 
-GPR_TLS_DECL(g_this_thread_state);
+static GPR_THREAD_LOCAL(ThreadState*) g_this_thread_state;
 
 Executor* executors[static_cast<size_t>(ExecutorType::NUM_EXECUTORS)];
 
@@ -214,7 +214,7 @@ void Executor::Shutdown() { SetThreading(false); }
 
 void Executor::ThreadMain(void* arg) {
   ThreadState* ts = static_cast<ThreadState*>(arg);
-  gpr_tls_set(&g_this_thread_state, reinterpret_cast<intptr_t>(ts));
+  g_this_thread_state = ts;
 
   grpc_core::ExecCtx exec_ctx(GRPC_EXEC_CTX_FLAG_IS_INTERNAL_THREAD);
 
@@ -248,7 +248,7 @@ void Executor::ThreadMain(void* arg) {
     subtract_depth = RunClosures(ts->name, closures);
   }
 
-  gpr_tls_set(&g_this_thread_state, reinterpret_cast<intptr_t>(nullptr));
+  g_this_thread_state = nullptr;
 }
 
 void Executor::Enqueue(grpc_closure* closure, grpc_error_handle error,
@@ -283,8 +283,7 @@ void Executor::Enqueue(grpc_closure* closure, grpc_error_handle error,
       return;
     }
 
-    ThreadState* ts =
-        reinterpret_cast<ThreadState*>(gpr_tls_get(&g_this_thread_state));
+    ThreadState* ts = g_this_thread_state;
     if (ts == nullptr) {
       ts = &thd_state_[GPR_HASH_POINTER(grpc_core::ExecCtx::Get(),
                                         cur_thread_count)];
@@ -465,6 +464,6 @@ void Executor::SetThreadingDefault(bool enable) {
   executors[static_cast<size_t>(ExecutorType::DEFAULT)]->SetThreading(enable);
 }
 
-void grpc_executor_global_init() { gpr_tls_init(&g_this_thread_state); }
+void grpc_executor_global_init() {}
 
 }  // namespace grpc_core
index 74096a4..ab2e9c1 100644 (file)
@@ -29,7 +29,8 @@ inline void* InfLenFIFOQueue::PopFront() {
   // mutex. This function will assume that there is at least one element in the
   // queue (i.e. queue_head_->content is valid).
   void* result = queue_head_->content;
-  count_.Store(count_.Load(MemoryOrder::RELAXED) - 1, MemoryOrder::RELAXED);
+  count_.store(count_.load(std::memory_order_relaxed) - 1,
+               std::memory_order_relaxed);
 
   // Updates Stats when trace flag turned on.
   if (GRPC_TRACE_FLAG_ENABLED(grpc_thread_pool_trace)) {
@@ -40,7 +41,7 @@ inline void* InfLenFIFOQueue::PopFront() {
     stats_.max_queue_time = gpr_time_max(
         gpr_convert_clock_type(stats_.max_queue_time, GPR_TIMESPAN), wait_time);
 
-    if (count_.Load(MemoryOrder::RELAXED) == 0) {
+    if (count_.load(std::memory_order_relaxed) == 0) {
       stats_.busy_queue_time =
           gpr_time_add(stats_.busy_queue_time,
                        gpr_time_sub(gpr_now(GPR_CLOCK_MONOTONIC), busy_time));
@@ -57,7 +58,7 @@ inline void* InfLenFIFOQueue::PopFront() {
 
   queue_head_ = queue_head_->next;
   // Signal waiting thread
-  if (count_.Load(MemoryOrder::RELAXED) > 0) {
+  if (count_.load(std::memory_order_relaxed) > 0) {
     TopWaiter()->cv.Signal();
   }
 
@@ -92,7 +93,7 @@ InfLenFIFOQueue::InfLenFIFOQueue() {
 }
 
 InfLenFIFOQueue::~InfLenFIFOQueue() {
-  GPR_ASSERT(count_.Load(MemoryOrder::RELAXED) == 0);
+  GPR_ASSERT(count_.load(std::memory_order_relaxed) == 0);
   for (size_t i = 0; i < delete_list_count_; ++i) {
     gpr_free(delete_list_[i]);
   }
@@ -102,7 +103,7 @@ InfLenFIFOQueue::~InfLenFIFOQueue() {
 void InfLenFIFOQueue::Put(void* elem) {
   MutexLock l(&mu_);
 
-  int curr_count = count_.Load(MemoryOrder::RELAXED);
+  int curr_count = count_.load(std::memory_order_relaxed);
 
   if (queue_tail_ == queue_head_ && curr_count != 0) {
     // List is full. Expands list to double size by inserting new chunk of nodes
@@ -134,7 +135,7 @@ void InfLenFIFOQueue::Put(void* elem) {
     queue_tail_->insert_time = current_time;
   }
 
-  count_.Store(curr_count + 1, MemoryOrder::RELAXED);
+  count_.store(curr_count + 1, std::memory_order_relaxed);
   queue_tail_ = queue_tail_->next;
 
   TopWaiter()->cv.Signal();
@@ -143,7 +144,7 @@ void InfLenFIFOQueue::Put(void* elem) {
 void* InfLenFIFOQueue::Get(gpr_timespec* wait_time) {
   MutexLock l(&mu_);
 
-  if (count_.Load(MemoryOrder::RELAXED) == 0) {
+  if (count_.load(std::memory_order_relaxed) == 0) {
     gpr_timespec start_time;
     if (GRPC_TRACE_FLAG_ENABLED(grpc_thread_pool_trace) &&
         wait_time != nullptr) {
@@ -154,14 +155,14 @@ void* InfLenFIFOQueue::Get(gpr_timespec* wait_time) {
     PushWaiter(&self);
     do {
       self.cv.Wait(&mu_);
-    } while (count_.Load(MemoryOrder::RELAXED) == 0);
+    } while (count_.load(std::memory_order_relaxed) == 0);
     RemoveWaiter(&self);
     if (GRPC_TRACE_FLAG_ENABLED(grpc_thread_pool_trace) &&
         wait_time != nullptr) {
       *wait_time = gpr_time_sub(gpr_now(GPR_CLOCK_MONOTONIC), start_time);
     }
   }
-  GPR_DEBUG_ASSERT(count_.Load(MemoryOrder::RELAXED) > 0);
+  GPR_DEBUG_ASSERT(count_.load(std::memory_order_relaxed) > 0);
   return PopFront();
 }
 
index 46e88b8..c3ee759 100644 (file)
@@ -21,8 +21,9 @@
 
 #include <grpc/support/port_platform.h>
 
+#include <atomic>
+
 #include "src/core/lib/debug/stats.h"
-#include "src/core/lib/gprpp/atomic.h"
 #include "src/core/lib/gprpp/sync.h"
 
 namespace grpc_core {
@@ -70,7 +71,7 @@ class InfLenFIFOQueue : public MPMCQueueInterface {
   // Returns number of elements in queue currently.
   // There might be concurrently add/remove on queue, so count might change
   // quickly.
-  int count() const override { return count_.Load(MemoryOrder::RELAXED); }
+  int count() const override { return count_.load(std::memory_order_relaxed); }
 
   struct Node {
     Node* next;  // Linking
@@ -157,7 +158,7 @@ class InfLenFIFOQueue : public MPMCQueueInterface {
 
   Node* queue_head_ = nullptr;  // Head of the queue, remove position
   Node* queue_tail_ = nullptr;  // End of queue, insert position
-  Atomic<int> count_{0};        // Number of elements in queue
+  std::atomic<int> count_{0};   // Number of elements in queue
   int num_nodes_ = 0;           // Number of nodes allocated
 
   Stats stats_;            // Stats info
index a0dd871..8bd954c 100644 (file)
@@ -72,7 +72,7 @@ size_t ThreadPool::DefaultStackSize() {
 
 void ThreadPool::AssertHasNotBeenShutDown() {
   // For debug checking purpose, using RELAXED order is sufficient.
-  GPR_DEBUG_ASSERT(!shut_down_.Load(MemoryOrder::RELAXED));
+  GPR_DEBUG_ASSERT(!shut_down_.load(std::memory_order_relaxed));
 }
 
 ThreadPool::ThreadPool(int num_threads) : num_threads_(num_threads) {
@@ -102,7 +102,7 @@ ThreadPool::ThreadPool(int num_threads, const char* thd_name,
 
 ThreadPool::~ThreadPool() {
   // For debug checking purpose, using RELAXED order is sufficient.
-  shut_down_.Store(true, MemoryOrder::RELAXED);
+  shut_down_.store(true, std::memory_order_relaxed);
 
   for (int i = 0; i < num_threads_; ++i) {
     queue_->Put(nullptr);
index 55bad8b..e0e5eb0 100644 (file)
@@ -134,7 +134,8 @@ class ThreadPool : public ThreadPoolInterface {
   ThreadPoolWorker** threads_ = nullptr;  // Array of worker threads
   MPMCQueueInterface* queue_ = nullptr;   // Closure queue
 
-  Atomic<bool> shut_down_{false};  // Destructor has been called if set to true
+  std::atomic<bool> shut_down_{
+      false};  // Destructor has been called if set to true
 
   void SharedThreadPoolConstructor();
   // For ThreadPool, default stack size for mobile platform is 1952K. for other
index f1ba20d..8916eac 100644 (file)
 
 #if GRPC_IF_NAMETOINDEX == 1 && defined(GRPC_POSIX_SOCKET_IF_NAMETOINDEX)
 
-#include "src/core/lib/iomgr/grpc_if_nametoindex.h"
-
 #include <errno.h>
 #include <net/if.h>
 
 #include <grpc/support/log.h>
 
+#include "src/core/lib/iomgr/grpc_if_nametoindex.h"
+
 uint32_t grpc_if_nametoindex(char* name) {
   uint32_t out = if_nametoindex(name);
   if (out == 0) {
index 08644cc..6306243 100644 (file)
 
 #if GRPC_IF_NAMETOINDEX == 0 || !defined(GRPC_POSIX_SOCKET_IF_NAMETOINDEX)
 
-#include "src/core/lib/iomgr/grpc_if_nametoindex.h"
-
 #include <grpc/support/log.h>
 
+#include "src/core/lib/iomgr/grpc_if_nametoindex.h"
+
 uint32_t grpc_if_nametoindex(char* name) {
   gpr_log(GPR_DEBUG,
           "Not attempting to convert interface name %s to index for current "
index b68c66b..ac644b2 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include "src/core/lib/iomgr/port.h"
+#include "src/core/lib/iomgr/internal_errqueue.h"
 
 #include <grpc/impl/codegen/log.h>
-#include "src/core/lib/iomgr/internal_errqueue.h"
+
+#include "src/core/lib/iomgr/port.h"
 
 #ifdef GRPC_POSIX_SOCKET_TCP
 
index 29a05ee..d4c76ec 100644 (file)
@@ -23,6 +23,7 @@
 #ifdef GRPC_WINSOCK_SOCKET
 
 #include <winsock2.h>
+
 #include <limits>
 
 #include <grpc/support/alloc.h>
index 9af0557..190942b 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
+#include <stdlib.h>
+
 #include "src/core/lib/iomgr/closure.h"
 #include "src/core/lib/iomgr/port.h"
 
-#include <stdlib.h>
-
 /** Initializes the iomgr. */
 void grpc_iomgr_init();
 
index 9a9f06a..70f4e1b 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include "src/core/lib/iomgr/port.h"
+#include "src/core/lib/iomgr/iomgr_custom.h"
 
 #include <grpc/support/thd_id.h>
 
 #include "src/core/lib/iomgr/exec_ctx.h"
 #include "src/core/lib/iomgr/executor.h"
-#include "src/core/lib/iomgr/iomgr_custom.h"
 #include "src/core/lib/iomgr/iomgr_internal.h"
 #include "src/core/lib/iomgr/pollset_custom.h"
 #include "src/core/lib/iomgr/pollset_set_custom.h"
+#include "src/core/lib/iomgr/port.h"
 #include "src/core/lib/iomgr/resolve_address_custom.h"
 
 gpr_thd_id g_init_thread;
index e6a8884..36b75b8 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
+#include <grpc/support/thd_id.h>
+
 #include "src/core/lib/iomgr/pollset_custom.h"
 #include "src/core/lib/iomgr/resolve_address_custom.h"
 #include "src/core/lib/iomgr/tcp_custom.h"
 #include "src/core/lib/iomgr/timer_custom.h"
 
-#include <grpc/support/thd_id.h>
-
 /* The thread ID of the thread on which grpc was initialized. Used to verify
  * that all calls into the custom iomgr are made on that same thread */
 extern gpr_thd_id g_init_thread;
index e5ce8ab..eb527f7 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
+#include "src/core/lib/iomgr/iomgr_internal.h"
+
 #include <stddef.h>
 
-#include "src/core/lib/iomgr/iomgr_internal.h"
 #include "src/core/lib/iomgr/timer.h"
 #include "src/core/lib/iomgr/timer_manager.h"
 
diff --git a/src/core/lib/iomgr/iomgr_uv.cc b/src/core/lib/iomgr/iomgr_uv.cc
deleted file mode 100644 (file)
index a617239..0000000
+++ /dev/null
@@ -1,43 +0,0 @@
-/*
- *
- * Copyright 2018 gRPC authors.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- *
- */
-
-#include <grpc/support/port_platform.h>
-
-#include "src/core/lib/iomgr/port.h"
-
-#if defined(GRPC_CUSTOM_SOCKET) && defined(GRPC_UV)
-
-#include "src/core/lib/iomgr/iomgr_custom.h"
-#include "src/core/lib/iomgr/iomgr_internal.h"
-#include "src/core/lib/iomgr/pollset_custom.h"
-#include "src/core/lib/iomgr/tcp_custom.h"
-#include "src/core/lib/iomgr/timer_custom.h"
-
-extern grpc_socket_vtable grpc_uv_socket_vtable;
-extern grpc_custom_resolver_vtable uv_resolver_vtable;
-extern grpc_custom_timer_vtable uv_timer_vtable;
-extern grpc_custom_poller_vtable uv_pollset_vtable;
-
-void grpc_set_default_iomgr_platform() {
-  grpc_custom_iomgr_init(&grpc_uv_socket_vtable, &uv_resolver_vtable,
-                         &uv_timer_vtable, &uv_pollset_vtable);
-}
-
-bool grpc_iomgr_run_in_background() { return false; }
-
-#endif
index df1207a..93fdaf8 100644 (file)
 
 #ifdef GRPC_WINSOCK_SOCKET
 
-#include "src/core/lib/iomgr/sockaddr_windows.h"
-
 #include <grpc/support/log.h>
 
 #include "src/core/lib/iomgr/iocp_windows.h"
 #include "src/core/lib/iomgr/iomgr.h"
 #include "src/core/lib/iomgr/pollset_windows.h"
 #include "src/core/lib/iomgr/resolve_address.h"
+#include "src/core/lib/iomgr/sockaddr_windows.h"
 #include "src/core/lib/iomgr/socket_windows.h"
 #include "src/core/lib/iomgr/tcp_client.h"
 #include "src/core/lib/iomgr/tcp_server.h"
index abc901e..80cac4a 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include "src/core/lib/iomgr/port.h"
-
 #include "src/core/lib/iomgr/is_epollexclusive_available.h"
 
-#ifdef GRPC_LINUX_EPOLL_CREATE1
+#include "src/core/lib/iomgr/port.h"
 
-#include <grpc/support/log.h>
+#ifdef GRPC_LINUX_EPOLL_CREATE1
 
 #include <errno.h>
 #include <sys/epoll.h>
 #include <sys/eventfd.h>
 #include <unistd.h>
 
+#include <grpc/support/log.h>
+
 #include "src/core/lib/iomgr/sys_epoll_wrapper.h"
 
 /* This polling engine is only relevant on linux kernels supporting epoll() */
index dea07ca..0c1788a 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
+#include "src/core/lib/iomgr/polling_entity.h"
+
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 
-#include "src/core/lib/iomgr/polling_entity.h"
-
 grpc_polling_entity grpc_polling_entity_create_from_pollset_set(
     grpc_pollset_set* pollset_set) {
   grpc_polling_entity pollent;
index 1165ea8..bad30fb 100644 (file)
@@ -18,7 +18,7 @@
 
 #include <grpc/support/port_platform.h>
 
-#include "src/core/lib/iomgr/port.h"
+#include "src/core/lib/iomgr/pollset_custom.h"
 
 #include <stddef.h>
 #include <string.h>
 #include <grpc/support/log.h>
 #include <grpc/support/sync.h>
 
+#include "src/core/lib/debug/trace.h"
 #include "src/core/lib/iomgr/closure.h"
 #include "src/core/lib/iomgr/iomgr_custom.h"
 #include "src/core/lib/iomgr/pollset.h"
-#include "src/core/lib/iomgr/pollset_custom.h"
+#include "src/core/lib/iomgr/port.h"
 #include "src/core/lib/iomgr/timer.h"
 
-#include "src/core/lib/debug/trace.h"
-
 static grpc_custom_poller_vtable* poller_vtable;
 
 struct grpc_pollset {
index de3067f..4e6f382 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include "src/core/lib/iomgr/error.h"
-
 #include <stddef.h>
 
+#include "src/core/lib/iomgr/error.h"
+
 typedef struct grpc_custom_poller_vtable {
   void (*init)();
   grpc_error* (*poll)(size_t timeout_ms);
index 0cc9089..db105bf 100644 (file)
@@ -18,9 +18,8 @@
 
 #include <grpc/support/port_platform.h>
 
-#include "src/core/lib/iomgr/port.h"
-
 #include "src/core/lib/iomgr/pollset_set.h"
+#include "src/core/lib/iomgr/port.h"
 
 static grpc_pollset_set* pollset_set_create(void) {
   return reinterpret_cast<grpc_pollset_set*>(static_cast<intptr_t>(0xdeafbeef));
index bb9e7f5..1b105a2 100644 (file)
@@ -19,6 +19,7 @@
 #include <grpc/support/port_platform.h>
 
 #include <stdint.h>
+
 #include "src/core/lib/iomgr/port.h"
 
 #ifdef GRPC_WINSOCK_SOCKET
diff --git a/src/core/lib/iomgr/pollset_uv.cc b/src/core/lib/iomgr/pollset_uv.cc
deleted file mode 100644 (file)
index ef76870..0000000
+++ /dev/null
@@ -1,95 +0,0 @@
-/*
- *
- * Copyright 2016 gRPC authors.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- *
- */
-
-#include <grpc/support/port_platform.h>
-
-#include "src/core/lib/iomgr/port.h"
-
-#ifdef GRPC_UV
-
-#include <grpc/support/alloc.h>
-#include <grpc/support/log.h>
-#include "src/core/lib/iomgr/error.h"
-#include "src/core/lib/iomgr/pollset_custom.h"
-
-#include <uv.h>
-
-/* Indicates that grpc_pollset_work should run an iteration of the UV loop
-   before running callbacks. This defaults to 1, and should be disabled if
-   grpc_pollset_work will be called within the callstack of uv_run */
-int grpc_pollset_work_run_loop = 1;
-
-static bool g_kicked = false;
-
-typedef struct uv_poller_handle {
-  uv_timer_t poll_timer;
-  uv_timer_t kick_timer;
-  int refs;
-} uv_poller_handle;
-
-static uv_poller_handle* g_handle;
-
-static void init() {
-  g_handle = (uv_poller_handle*)gpr_malloc(sizeof(uv_poller_handle));
-  g_handle->refs = 2;
-  uv_timer_init(uv_default_loop(), &g_handle->poll_timer);
-  uv_timer_init(uv_default_loop(), &g_handle->kick_timer);
-}
-
-static void empty_timer_cb(uv_timer_t* handle) {}
-
-static void kick_timer_cb(uv_timer_t* handle) { g_kicked = false; }
-
-static grpc_error* run_loop(size_t timeout) {
-  if (grpc_pollset_work_run_loop) {
-    if (timeout == 0) {
-      uv_run(uv_default_loop(), UV_RUN_NOWAIT);
-    } else {
-      uv_timer_start(&g_handle->poll_timer, empty_timer_cb, timeout, 0);
-      uv_run(uv_default_loop(), UV_RUN_ONCE);
-      uv_timer_stop(&g_handle->poll_timer);
-    }
-  }
-  return GRPC_ERROR_NONE;
-}
-
-static void kick() {
-  if (!g_kicked) {
-    g_kicked = true;
-    uv_timer_start(&g_handle->kick_timer, kick_timer_cb, 0, 0);
-  }
-}
-
-static void close_timer_cb(uv_handle_t* handle) {
-  g_handle->refs--;
-  if (g_handle->refs == 0) {
-    gpr_free(g_handle);
-  }
-}
-
-static void shutdown() {
-  uv_close((uv_handle_t*)&g_handle->poll_timer, close_timer_cb);
-  uv_close((uv_handle_t*)&g_handle->kick_timer, close_timer_cb);
-  if (grpc_pollset_work_run_loop) {
-    GPR_ASSERT(uv_run(uv_default_loop(), UV_RUN_DEFAULT) == 0);
-  }
-}
-
-grpc_custom_poller_vtable uv_pollset_vtable = {init, run_loop, kick, shutdown};
-
-#endif /* GRPC_UV */
diff --git a/src/core/lib/iomgr/pollset_uv.h b/src/core/lib/iomgr/pollset_uv.h
deleted file mode 100644 (file)
index 84fdefc..0000000
+++ /dev/null
@@ -1,36 +0,0 @@
-/*
- *
- * Copyright 2016 gRPC authors.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- *
- */
-
-#ifndef GRPC_CORE_LIB_IOMGR_POLLSET_UV_H
-#define GRPC_CORE_LIB_IOMGR_POLLSET_UV_H
-
-#include <grpc/support/port_platform.h>
-
-#include "src/core/lib/iomgr/error.h"
-
-extern int grpc_pollset_work_run_loop;
-
-typedef struct grpc_custom_poller_vtable {
-  void (*init)(void);
-  grpc_error* (*run_loop)(int blocking);
-} grpc_custom_poller_vtable;
-
-void grpc_custom_pollset_global_init(grpc_custom_poller_vtable* vtable);
-void grpc_custom_pollset_global_shutdown(void);
-
-#endif /* GRPC_CORE_LIB_IOMGR_POLLSET_UV_H */
index 5f14cd6..3e32429 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#ifdef GRPC_UV
-#ifndef GRPC_CUSTOM_SOCKET
-#define GRPC_CUSTOM_SOCKET
-#endif
-#endif
 /* This needs to be separate from the other conditions because it needs to
  * apply to custom sockets too */
 #ifdef GPR_WINDOWS
index b2f4162..5b7eecc 100644 (file)
@@ -23,6 +23,7 @@
 
 #include <grpc/impl/codegen/slice.h>
 #include <grpc/status.h>
+
 #include "src/core/lib/iomgr/error.h"
 
 // These are only used by the gRPC Python extensions.
index 30c0db1..a2e159a 100644 (file)
  */
 #include <grpc/support/port_platform.h>
 
+#include "src/core/lib/iomgr/resolve_address.h"
+
 #include <grpc/event_engine/event_engine.h>
 #include <grpc/support/alloc.h>
-#include "src/core/lib/iomgr/resolve_address.h"
 
 namespace grpc_core {
 const char* kDefaultSecurePort = "https";
index bcb3666..b9e25b0 100644 (file)
 
 #include "src/core/lib/iomgr/port.h"
 
-#ifdef GRPC_UV
-#include <uv.h>
-#endif
-
 #ifdef GRPC_WINSOCK_SOCKET
 #include <ws2tcpip.h>
 #endif
index f89eab0..6d8c599 100644 (file)
@@ -93,14 +93,14 @@ static grpc_error_handle try_split_host_port(const char* name,
   /* parse name, splitting it into host and port parts */
   grpc_core::SplitHostPort(name, host, port);
   if (host->empty()) {
-    return GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-        absl::StrFormat("unparseable host:port: '%s'", name).c_str());
+    return GRPC_ERROR_CREATE_FROM_CPP_STRING(
+        absl::StrFormat("unparseable host:port: '%s'", name));
   }
   if (port->empty()) {
     // TODO(murgatroid99): add tests for this case
     if (default_port == nullptr) {
-      return GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-          absl::StrFormat("no port in name '%s'", name).c_str());
+      return GRPC_ERROR_CREATE_FROM_CPP_STRING(
+          absl::StrFormat("no port in name '%s'", name));
     }
     *port = default_port;
   }
index 5f674dd..4063dcf 100644 (file)
@@ -22,7 +22,6 @@
 #include <grpc/support/port_platform.h>
 
 #include "src/core/lib/iomgr/port.h"
-
 #include "src/core/lib/iomgr/resolve_address.h"
 #include "src/core/lib/iomgr/sockaddr.h"
 
index d0d1e0c..32816fe 100644 (file)
 #include "src/core/lib/iomgr/port.h"
 #ifdef GRPC_POSIX_SOCKET_RESOLVE_ADDRESS
 
-#include "src/core/lib/iomgr/sockaddr.h"
-
-#include "src/core/lib/iomgr/resolve_address.h"
-
 #include <string.h>
 #include <sys/types.h>
 
@@ -40,6 +36,8 @@
 #include "src/core/lib/iomgr/block_annotate.h"
 #include "src/core/lib/iomgr/executor.h"
 #include "src/core/lib/iomgr/iomgr_internal.h"
+#include "src/core/lib/iomgr/resolve_address.h"
+#include "src/core/lib/iomgr/sockaddr.h"
 #include "src/core/lib/iomgr/unix_sockets_posix.h"
 
 static grpc_error_handle posix_blocking_resolve_address(
index 926237b..8cea3c1 100644 (file)
 #include "src/core/lib/iomgr/port.h"
 #ifdef GRPC_WINSOCK_SOCKET
 
-#include "src/core/lib/iomgr/sockaddr.h"
-
-#include "src/core/lib/iomgr/resolve_address.h"
-
 #include <inttypes.h>
 #include <string.h>
 #include <sys/types.h>
@@ -46,6 +42,8 @@
 #include "src/core/lib/iomgr/block_annotate.h"
 #include "src/core/lib/iomgr/executor.h"
 #include "src/core/lib/iomgr/iomgr_internal.h"
+#include "src/core/lib/iomgr/resolve_address.h"
+#include "src/core/lib/iomgr/sockaddr.h"
 
 struct request {
   char* name;
@@ -69,14 +67,14 @@ static grpc_error_handle windows_blocking_resolve_address(
   std::string port;
   grpc_core::SplitHostPort(name, &host, &port);
   if (host.empty()) {
-    error = GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-        absl::StrFormat("unparseable host:port: '%s'", name).c_str());
+    error = GRPC_ERROR_CREATE_FROM_CPP_STRING(
+        absl::StrFormat("unparseable host:port: '%s'", name));
     goto done;
   }
   if (port.empty()) {
     if (default_port == NULL) {
-      error = GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-          absl::StrFormat("no port in name '%s'", name).c_str());
+      error = GRPC_ERROR_CREATE_FROM_CPP_STRING(
+          absl::StrFormat("no port in name '%s'", name));
       goto done;
     }
     port = default_port;
index 8a6a11b..838c62e 100644 (file)
@@ -33,6 +33,7 @@
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 
+#include "src/core/lib/channel/channel_args.h"
 #include "src/core/lib/gpr/useful.h"
 #include "src/core/lib/iomgr/combiner.h"
 #include "src/core/lib/slice/slice_internal.h"
@@ -484,6 +485,7 @@ static grpc_slice ru_slice_create(grpc_resource_user* resource_user,
  * the combiner
  */
 
+// TODO(hork): rename all ru variables to resource_user
 static void ru_allocate(void* ru, grpc_error_handle /*error*/) {
   grpc_resource_user* resource_user = static_cast<grpc_resource_user*>(ru);
   if (rulist_empty(resource_user->resource_quota,
@@ -590,11 +592,14 @@ static void ru_destroy(void* ru, grpc_error_handle /*error*/) {
   }
   grpc_resource_quota_unref_internal(resource_user->resource_quota);
   gpr_mu_destroy(&resource_user->mu);
+  if (GRPC_TRACE_FLAG_ENABLED(grpc_resource_quota_trace)) {
+    gpr_log(GPR_INFO, "RU '%s' (%p) destroyed", resource_user->name.c_str(),
+            resource_user);
+  }
   delete resource_user;
 }
 
-static void ru_alloc_slices(
-    grpc_resource_user_slice_allocator* slice_allocator) {
+static void ru_alloc_slices(grpc_slice_allocator* slice_allocator) {
   for (size_t i = 0; i < slice_allocator->count; i++) {
     grpc_slice_buffer_add_indexed(
         slice_allocator->dest, ru_slice_create(slice_allocator->resource_user,
@@ -603,8 +608,8 @@ static void ru_alloc_slices(
 }
 
 static void ru_allocated_slices(void* arg, grpc_error_handle error) {
-  grpc_resource_user_slice_allocator* slice_allocator =
-      static_cast<grpc_resource_user_slice_allocator*>(arg);
+  grpc_slice_allocator* slice_allocator =
+      static_cast<grpc_slice_allocator*>(arg);
   if (error == GRPC_ERROR_NONE) ru_alloc_slices(slice_allocator);
   grpc_core::Closure::Run(DEBUG_LOCATION, &slice_allocator->on_done,
                           GRPC_ERROR_REF(error));
@@ -740,16 +745,10 @@ size_t grpc_resource_quota_peek_size(grpc_resource_quota* resource_quota) {
 
 grpc_resource_quota* grpc_resource_quota_from_channel_args(
     const grpc_channel_args* channel_args, bool create) {
-  for (size_t i = 0; i < channel_args->num_args; i++) {
-    if (0 == strcmp(channel_args->args[i].key, GRPC_ARG_RESOURCE_QUOTA)) {
-      if (channel_args->args[i].type == GRPC_ARG_POINTER) {
-        return grpc_resource_quota_ref_internal(
-            static_cast<grpc_resource_quota*>(
-                channel_args->args[i].value.pointer.p));
-      } else {
-        gpr_log(GPR_DEBUG, GRPC_ARG_RESOURCE_QUOTA " should be a pointer");
-      }
-    }
+  auto* resource_quota = grpc_channel_args_find_pointer<grpc_resource_quota>(
+      channel_args, GRPC_ARG_RESOURCE_QUOTA);
+  if (resource_quota != nullptr) {
+    return grpc_resource_quota_ref_internal(resource_quota);
   }
   return create ? grpc_resource_quota_create(nullptr) : nullptr;
 }
@@ -775,7 +774,7 @@ const grpc_arg_pointer_vtable* grpc_resource_quota_arg_vtable(void) {
  */
 
 grpc_resource_user* grpc_resource_user_create(
-    grpc_resource_quota* resource_quota, const char* name) {
+    grpc_resource_quota* resource_quota, absl::string_view name) {
   grpc_resource_user* resource_user = new grpc_resource_user;
   resource_user->resource_quota =
       grpc_resource_quota_ref_internal(resource_quota);
@@ -805,14 +804,16 @@ grpc_resource_user* grpc_resource_user_create(
   for (int i = 0; i < GRPC_RULIST_COUNT; i++) {
     resource_user->links[i].next = resource_user->links[i].prev = nullptr;
   }
-  // TODO(hork): the RU should own a copy of the name. See Craig's comments on
-  // the EventEngine gRFC for justification.
-  if (name != nullptr) {
-    resource_user->name = name;
+  if (!name.empty()) {
+    resource_user->name = std::string(name);
   } else {
     resource_user->name = absl::StrCat(
         "anonymous_resource_user_", reinterpret_cast<intptr_t>(resource_user));
   }
+  if (GRPC_TRACE_FLAG_ENABLED(grpc_resource_quota_trace)) {
+    gpr_log(GPR_INFO, "RU '%s' (%p) created", resource_user->name.c_str(),
+            resource_user);
+  }
   return resource_user;
 }
 
@@ -823,13 +824,22 @@ grpc_resource_quota* grpc_resource_user_quota(
 
 static void ru_ref_by(grpc_resource_user* resource_user, gpr_atm amount) {
   GPR_ASSERT(amount > 0);
-  GPR_ASSERT(gpr_atm_no_barrier_fetch_add(&resource_user->refs, amount) != 0);
+  gpr_atm prior = gpr_atm_no_barrier_fetch_add(&resource_user->refs, amount);
+  if (GRPC_TRACE_FLAG_ENABLED(grpc_resource_quota_trace)) {
+    gpr_log(GPR_INFO, "RU '%s' (%p) reffing: %" PRIdPTR " -> %" PRIdPTR,
+            resource_user->name.c_str(), resource_user, prior, prior + amount);
+  }
+  GPR_ASSERT(prior != 0);
 }
 
 static void ru_unref_by(grpc_resource_user* resource_user, gpr_atm amount) {
   GPR_ASSERT(amount > 0);
   gpr_atm old = gpr_atm_full_fetch_add(&resource_user->refs, -amount);
   GPR_ASSERT(old >= amount);
+  if (GRPC_TRACE_FLAG_ENABLED(grpc_resource_quota_trace)) {
+    gpr_log(GPR_INFO, "RU '%s' (%p) unreffing: %" PRIdPTR " -> %" PRIdPTR,
+            resource_user->name.c_str(), resource_user, old, old - amount);
+  }
   if (old == amount) {
     resource_user->resource_quota->combiner->Run(
         &resource_user->destroy_closure, GRPC_ERROR_NONE);
@@ -857,9 +867,10 @@ bool grpc_resource_user_allocate_threads(grpc_resource_user* resource_user,
   GPR_ASSERT(thread_count >= 0);
   bool is_success = false;
   gpr_mu_lock(&resource_user->resource_quota->thread_count_mu);
-  grpc_resource_quota* rq = resource_user->resource_quota;
-  if (rq->num_threads_allocated + thread_count <= rq->max_threads) {
-    rq->num_threads_allocated += thread_count;
+  grpc_resource_quota* resource_quota = resource_user->resource_quota;
+  if (resource_quota->num_threads_allocated + thread_count <=
+      resource_quota->max_threads) {
+    resource_quota->num_threads_allocated += thread_count;
     gpr_atm_no_barrier_fetch_add(&resource_user->num_threads_allocated,
                                  thread_count);
     is_success = true;
@@ -872,15 +883,16 @@ void grpc_resource_user_free_threads(grpc_resource_user* resource_user,
                                      int thread_count) {
   GPR_ASSERT(thread_count >= 0);
   gpr_mu_lock(&resource_user->resource_quota->thread_count_mu);
-  grpc_resource_quota* rq = resource_user->resource_quota;
-  rq->num_threads_allocated -= thread_count;
+  grpc_resource_quota* resource_quota = resource_user->resource_quota;
+  resource_quota->num_threads_allocated -= thread_count;
   int old_count = static_cast<int>(gpr_atm_no_barrier_fetch_add(
       &resource_user->num_threads_allocated, -thread_count));
-  if (old_count < thread_count || rq->num_threads_allocated < 0) {
+  if (old_count < thread_count || resource_quota->num_threads_allocated < 0) {
     gpr_log(GPR_ERROR,
-            "Releasing more threads (%d) than currently allocated (rq threads: "
-            "%d, ru threads: %d)",
-            thread_count, rq->num_threads_allocated + thread_count, old_count);
+            "Releasing more threads (%d) than currently allocated "
+            "(resource_quota threads: %d, ru threads: %d)",
+            thread_count, resource_quota->num_threads_allocated + thread_count,
+            old_count);
     abort();
   }
   gpr_mu_unlock(&resource_user->resource_quota->thread_count_mu);
@@ -988,19 +1000,69 @@ void grpc_resource_user_finish_reclamation(grpc_resource_user* resource_user) {
       GRPC_ERROR_NONE);
 }
 
-void grpc_resource_user_slice_allocator_init(
-    grpc_resource_user_slice_allocator* slice_allocator,
-    grpc_resource_user* resource_user, grpc_iomgr_cb_func cb, void* p) {
+grpc_slice_allocator* grpc_slice_allocator_create(
+    grpc_resource_quota* resource_quota, absl::string_view name,
+    const grpc_channel_args* args) {
+  grpc_slice_allocator* slice_allocator = new grpc_slice_allocator;
+  slice_allocator->min_length = grpc_channel_args_find_integer(
+      args, GRPC_ARG_TCP_MIN_READ_CHUNK_SIZE,
+      {GRPC_SLICE_ALLOCATOR_MIN_ALLOCATE_SIZE, -1, INT_MAX});
+  slice_allocator->max_length = grpc_channel_args_find_integer(
+      args, GRPC_ARG_TCP_MAX_READ_CHUNK_SIZE,
+      {GRPC_SLICE_ALLOCATOR_MAX_ALLOCATE_SIZE, -1, INT_MAX});
+  slice_allocator->resource_user =
+      grpc_resource_user_create(resource_quota, name);
   GRPC_CLOSURE_INIT(&slice_allocator->on_allocated, ru_allocated_slices,
                     slice_allocator, grpc_schedule_on_exec_ctx);
-  GRPC_CLOSURE_INIT(&slice_allocator->on_done, cb, p,
-                    grpc_schedule_on_exec_ctx);
-  slice_allocator->resource_user = resource_user;
+  return slice_allocator;
+}
+
+void grpc_slice_allocator_destroy(grpc_slice_allocator* slice_allocator) {
+  ru_unref_by(slice_allocator->resource_user, 1);
+  delete slice_allocator;
 }
 
-bool grpc_resource_user_alloc_slices(
-    grpc_resource_user_slice_allocator* slice_allocator, size_t length,
-    size_t count, grpc_slice_buffer* dest) {
+static size_t grpc_slice_allocator_adjust_allocation_length(
+    grpc_slice_allocator* slice_allocator, size_t requested_length,
+    grpc_slice_allocator_intent intent) {
+  if (intent == grpc_slice_allocator_intent::kDefault) {
+    return requested_length;
+  }
+  GPR_ASSERT(intent == grpc_slice_allocator_intent::kReadBuffer);
+  double pressure = grpc_resource_quota_get_memory_pressure(
+      slice_allocator->resource_user->resource_quota);
+  // Reduce allocation size proportional to the pressure > 80% usage.
+  size_t target =
+      requested_length * (pressure > 0.8 ? (1.0 - pressure) / 0.2 : 1.0);
+  // Target will be some multiple of 8 bytes, rounded up
+  target = ((static_cast<size_t> GPR_CLAMP(target, slice_allocator->min_length,
+                                           slice_allocator->max_length)) +
+            255) &
+           ~static_cast<size_t>(255);
+  // Don't use more than 1/16th of the overall resource quota for a single
+  // read alloc
+  size_t rqmax = grpc_resource_quota_peek_size(
+      slice_allocator->resource_user->resource_quota);
+  if (target > rqmax / 16 && rqmax > 1024) {
+    target = rqmax / 16;
+  }
+  if (GRPC_TRACE_FLAG_ENABLED(grpc_resource_quota_trace)) {
+    gpr_log(
+        GPR_INFO,
+        "SliceAllocator(%p) requested %zu bytes for (%s) intent, adjusted "
+        "allocation size to %zu",
+        slice_allocator, requested_length,
+        intent == grpc_slice_allocator_intent::kDefault ? "default" : "read",
+        target);
+  }
+  return target;
+}
+
+bool grpc_slice_allocator_allocate(grpc_slice_allocator* slice_allocator,
+                                   size_t length, size_t count,
+                                   grpc_slice_allocator_intent intent,
+                                   grpc_slice_buffer* dest,
+                                   grpc_iomgr_cb_func cb, void* p) {
   if (GPR_UNLIKELY(
           gpr_atm_no_barrier_load(&slice_allocator->resource_user->shutdown))) {
     grpc_core::ExecCtx::Run(
@@ -1008,12 +1070,35 @@ bool grpc_resource_user_alloc_slices(
         GRPC_ERROR_CREATE_FROM_STATIC_STRING("Resource user shutdown"));
     return false;
   }
-  slice_allocator->length = length;
+  GRPC_CLOSURE_INIT(&slice_allocator->on_done, cb, p,
+                    grpc_schedule_on_exec_ctx);
+  slice_allocator->length = grpc_slice_allocator_adjust_allocation_length(
+      slice_allocator, length, intent);
   slice_allocator->count = count;
   slice_allocator->dest = dest;
-  const bool ret =
-      grpc_resource_user_alloc(slice_allocator->resource_user, count * length,
-                               &slice_allocator->on_allocated);
+  const bool ret = grpc_resource_user_alloc(slice_allocator->resource_user,
+                                            count * slice_allocator->length,
+                                            &slice_allocator->on_allocated);
   if (ret) ru_alloc_slices(slice_allocator);
   return ret;
 }
+
+grpc_slice_allocator_factory* grpc_slice_allocator_factory_create(
+    grpc_resource_quota* resource_quota) {
+  grpc_slice_allocator_factory* factory = new grpc_slice_allocator_factory;
+  factory->resource_quota = resource_quota;
+  return factory;
+}
+
+grpc_slice_allocator* grpc_slice_allocator_factory_create_slice_allocator(
+    grpc_slice_allocator_factory* slice_allocator_factory,
+    absl::string_view name, grpc_channel_args* args) {
+  return grpc_slice_allocator_create(slice_allocator_factory->resource_quota,
+                                     name, args);
+}
+
+void grpc_slice_allocator_factory_destroy(
+    grpc_slice_allocator_factory* slice_allocator_factory) {
+  grpc_resource_quota_unref_internal(slice_allocator_factory->resource_quota);
+  delete slice_allocator_factory;
+}
index ec89a92..aeb8259 100644 (file)
@@ -69,6 +69,8 @@ extern grpc_core::TraceFlag grpc_resource_quota_trace;
 // hard coding.
 constexpr size_t GRPC_RESOURCE_QUOTA_CALL_SIZE = 15 * 1024;
 constexpr size_t GRPC_RESOURCE_QUOTA_CHANNEL_SIZE = 50 * 1024;
+constexpr size_t GRPC_SLICE_ALLOCATOR_MIN_ALLOCATE_SIZE = 256;
+constexpr size_t GRPC_SLICE_ALLOCATOR_MAX_ALLOCATE_SIZE = 4 * 1024 * 1024;
 
 grpc_resource_quota* grpc_resource_quota_ref_internal(
     grpc_resource_quota* resource_quota);
@@ -87,7 +89,7 @@ size_t grpc_resource_quota_peek_size(grpc_resource_quota* resource_quota);
 typedef struct grpc_resource_user grpc_resource_user;
 
 grpc_resource_user* grpc_resource_user_create(
-    grpc_resource_quota* resource_quota, const char* name);
+    grpc_resource_quota* resource_quota, absl::string_view name);
 
 /* Returns a borrowed reference to the underlying resource quota for this
    resource user. */
@@ -145,7 +147,7 @@ void grpc_resource_user_post_reclaimer(grpc_resource_user* resource_user,
 void grpc_resource_user_finish_reclamation(grpc_resource_user* resource_user);
 
 /* Helper to allocate slices from a resource user */
-typedef struct grpc_resource_user_slice_allocator {
+typedef struct grpc_slice_allocator {
   /* Closure for when a resource user allocation completes */
   grpc_closure on_allocated;
   /* Closure to call when slices have been allocated */
@@ -154,24 +156,71 @@ typedef struct grpc_resource_user_slice_allocator {
   size_t length;
   /* Number of slices to allocate on the current request */
   size_t count;
+  /* Minimum size to allocate under memory pressure. */
+  size_t min_length;
+  /* Maximum size that can be allocated. */
+  size_t max_length;
   /* Destination for slices to allocate on the current request */
   grpc_slice_buffer* dest;
   /* Parent resource user */
   grpc_resource_user* resource_user;
-} grpc_resource_user_slice_allocator;
-
-/* Initialize a slice allocator.
-   When an allocation is completed, calls \a cb with arg \p. */
-void grpc_resource_user_slice_allocator_init(
-    grpc_resource_user_slice_allocator* slice_allocator,
-    grpc_resource_user* resource_user, grpc_iomgr_cb_func cb, void* p);
-
-/* Allocate \a count slices of length \a length into \a dest. Only one request
-   can be outstanding at a time.
-   Returns whether the slice was allocated inline in the function. If true,
-   the \a slice_allocator->on_allocated callback will not be called. */
-bool grpc_resource_user_alloc_slices(
-    grpc_resource_user_slice_allocator* slice_allocator, size_t length,
-    size_t count, grpc_slice_buffer* dest) GRPC_MUST_USE_RESULT;
+} grpc_slice_allocator;
+
+/// Constructs a slice allocator using configuration from \a args.
+///
+/// Minimum and maximum limits for memory allocation size can be defined in
+/// \a args, and used to configure an allocator. See
+/// \a grpc_slice_allocator_allocate for details on how those values are used.
+///
+/// Caller is responsible for calling \a grpc_slice_allocator_destroy.
+grpc_slice_allocator* grpc_slice_allocator_create(
+    grpc_resource_quota* resource_quota, absl::string_view name,
+    const grpc_channel_args* args = nullptr);
+
+/* Cleans up after a slice_allocator. */
+void grpc_slice_allocator_destroy(grpc_slice_allocator* slice_allocator);
+
+enum class grpc_slice_allocator_intent {
+  kDefault,    // Default intent allocates exactly the memory required.
+  kReadBuffer  // ReadBuffer intent may return a smaller slice than requested if
+               // memory pressure is high.
+};
+
+/** Allocate \a count slices of length \a length into \a dest. Only one request
+   can be outstanding at a time. When an allocation is completed, calls \a cb
+   with arg \a p. Returns whether the slice was allocated inline in the
+   function. If true, the \a cb will not be called. The \a intent argument
+   allows allocation of smaller slices if memory pressure is high; the size is
+   implementation-dependent. */
+bool grpc_slice_allocator_allocate(grpc_slice_allocator* slice_allocator,
+                                   size_t length, size_t count,
+                                   grpc_slice_allocator_intent intent,
+                                   grpc_slice_buffer* dest,
+                                   grpc_iomgr_cb_func cb,
+                                   void* p) GRPC_MUST_USE_RESULT;
+
+/* Allows creation of slice_allocators (thus resource_users) without calling
+ * code having to understand resource_user concepts. */
+typedef struct grpc_slice_allocator_factory {
+  /* Parent resource quota */
+  grpc_resource_quota* resource_quota;
+} grpc_slice_allocator_factory;
+
+/* Constructs a slice allocator factory. Takes ownership of a ref on
+ * \a resource_quota from the caller. Caller is responsible for calling \a
+ * grpc_slice_allocator_factory_destroy. */
+grpc_slice_allocator_factory* grpc_slice_allocator_factory_create(
+    grpc_resource_quota* resource_quota);
+
+/* Cleans up after a slice_allocator. */
+void grpc_slice_allocator_factory_destroy(
+    grpc_slice_allocator_factory* slice_allocator_factory);
+
+/** A factory method to create and initialize a slice_allocator using the
+  factory's resource quota. \a name is the resulting resource_user name. \a args
+  are used to configure the \a slice_allocator */
+grpc_slice_allocator* grpc_slice_allocator_factory_create_slice_allocator(
+    grpc_slice_allocator_factory* slice_allocator_factory,
+    absl::string_view name, grpc_channel_args* args = nullptr);
 
 #endif /* GRPC_CORE_LIB_IOMGR_RESOURCE_QUOTA_H */
index 96a8f77..7abb82d 100644 (file)
@@ -26,7 +26,7 @@
 #include <grpc/support/port_platform.h>
 
 #include "src/core/lib/event_engine/sockaddr.h"
-#include "src/core/lib/iomgr/sockaddr_custom.h"
+#include "src/core/lib/iomgr/port.h"
 #include "src/core/lib/iomgr/sockaddr_posix.h"
 #include "src/core/lib/iomgr/sockaddr_windows.h"
 
diff --git a/src/core/lib/iomgr/sockaddr_custom.h b/src/core/lib/iomgr/sockaddr_custom.h
deleted file mode 100644 (file)
index d85cc50..0000000
+++ /dev/null
@@ -1,54 +0,0 @@
-/*
- *
- * Copyright 2018 gRPC authors.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- *
- */
-
-#ifndef GRPC_CORE_LIB_IOMGR_SOCKADDR_CUSTOM_H
-#define GRPC_CORE_LIB_IOMGR_SOCKADDR_CUSTOM_H
-
-#include <grpc/support/port_platform.h>
-
-#include <stddef.h>
-#include "src/core/lib/iomgr/port.h"
-
-#ifdef GRPC_UV
-
-#include <uv.h>
-
-// TODO(kpayson)  It would be nice to abstract this so we don't
-// depend on anything uv specific
-typedef struct sockaddr grpc_sockaddr;
-typedef struct sockaddr_in grpc_sockaddr_in;
-typedef struct in_addr grpc_in_addr;
-typedef struct sockaddr_in6 grpc_sockaddr_in6;
-typedef struct in6_addr grpc_in6_addr;
-
-#define GRPC_INET_ADDRSTRLEN INET_ADDRSTRLEN
-#define GRPC_INET6_ADDRSTRLEN INET6_ADDRSTRLEN
-
-#define GRPC_SOCK_STREAM SOCK_STREAM
-#define GRPC_SOCK_DGRAM SOCK_DGRAM
-
-#define GRPC_AF_UNSPEC AF_UNSPEC
-#define GRPC_AF_UNIX AF_UNIX
-#define GRPC_AF_INET AF_INET
-#define GRPC_AF_INET6 AF_INET6
-
-#define GRPC_AI_PASSIVE AI_PASSIVE
-
-#endif  // GRPC_UV
-
-#endif /* GRPC_CORE_LIB_IOMGR_SOCKADDR_CUSTOM_H */
index 8d1bd71..50fb2ef 100644 (file)
 
 #ifdef GRPC_POSIX_SOCKET_SOCKET_FACTORY
 
+#include <grpc/impl/codegen/grpc_types.h>
+#include <grpc/support/sync.h>
+
 #include "src/core/lib/channel/channel_args.h"
 #include "src/core/lib/gpr/useful.h"
 #include "src/core/lib/iomgr/socket_factory_posix.h"
 
-#include <grpc/impl/codegen/grpc_types.h>
-#include <grpc/support/sync.h>
-
 void grpc_socket_factory_init(grpc_socket_factory* factory,
                               const grpc_socket_factory_vtable* vtable) {
   factory->vtable = vtable;
index 92ea6c1..287ae5f 100644 (file)
@@ -23,6 +23,7 @@
 
 #include <grpc/impl/codegen/grpc_types.h>
 #include <grpc/support/sync.h>
+
 #include "src/core/lib/iomgr/resolve_address.h"
 
 /** The virtual table of grpc_socket_factory */
index 55e69e3..f7564da 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
+#include <stdbool.h>
+
 #include <grpc/impl/codegen/grpc_types.h>
 #include <grpc/support/sync.h>
 
-#include <stdbool.h>
-
 /** How is an fd to be used? */
 typedef enum {
   /** Used for client connection */
index a9e45ef..53df6d6 100644 (file)
 
 #ifdef GRPC_POSIX_SOCKET_UTILS_COMMON
 
-#include "src/core/lib/iomgr/socket_utils.h"
-#include "src/core/lib/iomgr/socket_utils_posix.h"
-
 #include <arpa/inet.h>
 #include <errno.h>
 #include <fcntl.h>
 #include <limits.h>
 #include <netinet/in.h>
+
+#include "src/core/lib/iomgr/socket_utils.h"
+#include "src/core/lib/iomgr/socket_utils_posix.h"
 #ifdef GRPC_LINUX_TCP_H
 #include <linux/tcp.h>
 #else
index 34f93cc..ef5d975 100644 (file)
 
 #ifdef GRPC_LINUX_SOCKETUTILS
 
-#include "src/core/lib/iomgr/sockaddr.h"
-#include "src/core/lib/iomgr/socket_utils_posix.h"
+#include <sys/socket.h>
+#include <sys/types.h>
 
 #include <grpc/support/log.h>
 
-#include <sys/socket.h>
-#include <sys/types.h>
+#include "src/core/lib/iomgr/sockaddr.h"
+#include "src/core/lib/iomgr/socket_utils_posix.h"
 
 int grpc_accept4(int sockfd, grpc_resolved_address* resolved_addr, int nonblock,
                  int cloexec) {
index c48da52..333e60d 100644 (file)
 
 #ifdef GRPC_POSIX_SOCKETUTILS
 
-#include "src/core/lib/iomgr/socket_utils_posix.h"
-
 #include <fcntl.h>
 #include <sys/socket.h>
 #include <unistd.h>
 
 #include <grpc/support/log.h>
+
 #include "src/core/lib/iomgr/sockaddr.h"
+#include "src/core/lib/iomgr/socket_utils_posix.h"
 
 int grpc_accept4(int sockfd, grpc_resolved_address* resolved_addr, int nonblock,
                  int cloexec) {
index d1a52a2..d79a4a1 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include "src/core/lib/iomgr/resolve_address.h"
-
 #include <sys/socket.h>
 #include <unistd.h>
 
 #include <grpc/impl/codegen/grpc_types.h>
+
 #include "src/core/lib/iomgr/error.h"
+#include "src/core/lib/iomgr/resolve_address.h"
 #include "src/core/lib/iomgr/socket_factory_posix.h"
 #include "src/core/lib/iomgr/socket_mutator.h"
 
diff --git a/src/core/lib/iomgr/socket_utils_uv.cc b/src/core/lib/iomgr/socket_utils_uv.cc
deleted file mode 100644 (file)
index b5f96b5..0000000
+++ /dev/null
@@ -1,49 +0,0 @@
-/*
- *
- * Copyright 2016 gRPC authors.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- *
- */
-
-#include <grpc/support/port_platform.h>
-
-#include "src/core/lib/iomgr/port.h"
-
-#ifdef GRPC_UV
-
-#include "src/core/lib/iomgr/sockaddr.h"
-#include "src/core/lib/iomgr/socket_utils.h"
-
-#include <grpc/support/log.h>
-
-#include <uv.h>
-
-uint16_t grpc_htons(uint16_t hostshort) { return htons(hostshort); }
-
-uint16_t grpc_ntohs(uint16_t netshort) { return ntohs(netshort); }
-
-uint32_t grpc_htonl(uint32_t hostlong) { return htonl(hostlong); }
-
-uint32_t grpc_ntohl(uint32_t netlong) { return ntohl(netlong); }
-
-int grpc_inet_pton(int af, const char* src, void* dst) {
-  return inet_pton(af, src, dst);
-}
-
-const char* grpc_inet_ntop(int af, const void* src, char* dst, size_t size) {
-  uv_inet_ntop(af, src, dst, size);
-  return dst;
-}
-
-#endif /* GRPC_UV */
index 9137ab9..4f483f0 100644 (file)
 
 #ifdef GRPC_WINDOWS_SOCKETUTILS
 
+#include <grpc/support/log.h>
+
 #include "src/core/lib/iomgr/sockaddr.h"
 #include "src/core/lib/iomgr/socket_utils.h"
 
-#include <grpc/support/log.h>
-
 uint16_t grpc_htons(uint16_t hostshort) { return htons(hostshort); }
 
 uint16_t grpc_ntohs(uint16_t netshort) { return ntohs(netshort); }
index 3441a63..02b7e4b 100644 (file)
 grpc_tcp_client_vtable* grpc_tcp_client_impl;
 
 void grpc_tcp_client_connect(grpc_closure* on_connect, grpc_endpoint** endpoint,
+                             grpc_slice_allocator* slice_allocator,
                              grpc_pollset_set* interested_parties,
                              const grpc_channel_args* channel_args,
                              const grpc_resolved_address* addr,
                              grpc_millis deadline) {
-  grpc_tcp_client_impl->connect(on_connect, endpoint, interested_parties,
-                                channel_args, addr, deadline);
+  grpc_tcp_client_impl->connect(on_connect, endpoint, slice_allocator,
+                                interested_parties, channel_args, addr,
+                                deadline);
 }
 
 void grpc_set_tcp_client_impl(grpc_tcp_client_vtable* impl) {
index d209eeb..995f817 100644 (file)
 
 #include <grpc/impl/codegen/grpc_types.h>
 #include <grpc/support/time.h>
+
 #include "src/core/lib/iomgr/endpoint.h"
 #include "src/core/lib/iomgr/pollset_set.h"
 #include "src/core/lib/iomgr/resolve_address.h"
+#include "src/core/lib/iomgr/resource_quota.h"
 
 typedef struct grpc_tcp_client_vtable {
   void (*connect)(grpc_closure* on_connect, grpc_endpoint** endpoint,
+                  grpc_slice_allocator* slice_allocator,
                   grpc_pollset_set* interested_parties,
                   const grpc_channel_args* channel_args,
                   const grpc_resolved_address* addr, grpc_millis deadline);
@@ -40,6 +43,7 @@ typedef struct grpc_tcp_client_vtable {
    interested_parties points to a set of pollsets that would be interested
    in this connection being established (in order to continue their work) */
 void grpc_tcp_client_connect(grpc_closure* on_connect, grpc_endpoint** endpoint,
+                             grpc_slice_allocator* slice_allocator,
                              grpc_pollset_set* interested_parties,
                              const grpc_channel_args* channel_args,
                              const grpc_resolved_address* addr,
index 5c0a95e..d329f8d 100644 (file)
 #ifdef GRPC_CFSTREAM_CLIENT
 
 #include <CoreFoundation/CoreFoundation.h>
-
+#include <netinet/in.h>
 #include <string.h>
 
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/sync.h>
 
-#include <netinet/in.h>
-
 #include "src/core/lib/address_utils/sockaddr_utils.h"
 #include "src/core/lib/channel/channel_args.h"
 #include "src/core/lib/gprpp/host_port.h"
@@ -66,14 +64,16 @@ struct CFStreamConnect {
   grpc_endpoint** endpoint;
   int refs;
   std::string addr_name;
-  grpc_resource_quota* resource_quota;
+  grpc_slice_allocator* slice_allocator;
 };
 
 static void CFStreamConnectCleanup(CFStreamConnect* connect) {
-  grpc_resource_quota_unref_internal(connect->resource_quota);
   CFSTREAM_HANDLE_UNREF(connect->stream_handle, "async connect clean up");
   CFRelease(connect->read_stream);
   CFRelease(connect->write_stream);
+  if (connect->slice_allocator != nullptr) {
+    grpc_slice_allocator_destroy(connect->slice_allocator);
+  }
   gpr_mu_destroy(&connect->mu);
   delete connect;
 }
@@ -130,8 +130,9 @@ static void OnOpen(void* arg, grpc_error_handle error) {
       if (error == GRPC_ERROR_NONE) {
         *endpoint = grpc_cfstream_endpoint_create(
             connect->read_stream, connect->write_stream,
-            connect->addr_name.c_str(), connect->resource_quota,
+            connect->addr_name.c_str(), connect->slice_allocator,
             connect->stream_handle);
+        connect->slice_allocator = nullptr;
       }
     } else {
       GRPC_ERROR_REF(error);
@@ -153,6 +154,7 @@ static void ParseResolvedAddress(const grpc_resolved_address* addr,
 }
 
 static void CFStreamClientConnect(grpc_closure* closure, grpc_endpoint** ep,
+                                  grpc_slice_allocator* slice_allocator,
                                   grpc_pollset_set* interested_parties,
                                   const grpc_channel_args* channel_args,
                                   const grpc_resolved_address* resolved_addr,
@@ -161,7 +163,6 @@ static void CFStreamClientConnect(grpc_closure* closure, grpc_endpoint** ep,
   connect->closure = closure;
   connect->endpoint = ep;
   connect->addr_name = grpc_sockaddr_to_uri(resolved_addr);
-  // connect->resource_quota = resource_quota;
   connect->refs = 2;  // One for the connect operation, one for the timer.
   gpr_ref_init(&connect->refcount, 1);
   gpr_mu_init(&connect->mu);
@@ -170,18 +171,7 @@ static void CFStreamClientConnect(grpc_closure* closure, grpc_endpoint** ep,
     gpr_log(GPR_DEBUG, "CLIENT_CONNECT: %p, %s: asynchronously connecting",
             connect, connect->addr_name.c_str());
   }
-
-  grpc_resource_quota* resource_quota = grpc_resource_quota_create(NULL);
-  if (channel_args != NULL) {
-    for (size_t i = 0; i < channel_args->num_args; i++) {
-      if (0 == strcmp(channel_args->args[i].key, GRPC_ARG_RESOURCE_QUOTA)) {
-        grpc_resource_quota_unref_internal(resource_quota);
-        resource_quota = grpc_resource_quota_ref_internal(
-            (grpc_resource_quota*)channel_args->args[i].value.pointer.p);
-      }
-    }
-  }
-  connect->resource_quota = resource_quota;
+  connect->slice_allocator = slice_allocator;
 
   CFReadStreamRef read_stream;
   CFWriteStreamRef write_stream;
index d54a5f0..fea2522 100644 (file)
@@ -18,8 +18,6 @@
 
 #include <grpc/support/port_platform.h>
 
-#include "src/core/lib/iomgr/port.h"
-
 #include <string.h>
 
 #include <grpc/support/alloc.h>
@@ -28,6 +26,7 @@
 #include "src/core/lib/address_utils/sockaddr_utils.h"
 #include "src/core/lib/iomgr/error.h"
 #include "src/core/lib/iomgr/iomgr_custom.h"
+#include "src/core/lib/iomgr/port.h"
 #include "src/core/lib/iomgr/tcp_client.h"
 #include "src/core/lib/iomgr/tcp_custom.h"
 #include "src/core/lib/iomgr/timer.h"
@@ -43,12 +42,14 @@ struct grpc_custom_tcp_connect {
   grpc_endpoint** endpoint;
   int refs;
   std::string addr_name;
-  grpc_resource_quota* resource_quota;
+  grpc_slice_allocator* slice_allocator;
 };
 
 static void custom_tcp_connect_cleanup(grpc_custom_tcp_connect* connect) {
+  if (connect->slice_allocator != nullptr) {
+    grpc_slice_allocator_destroy(connect->slice_allocator);
+  }
   grpc_custom_socket* socket = connect->socket;
-  grpc_resource_quota_unref_internal(connect->resource_quota);
   delete connect;
   socket->refs--;
   if (socket->refs == 0) {
@@ -87,7 +88,8 @@ static void custom_connect_callback_internal(grpc_custom_socket* socket,
   grpc_timer_cancel(&connect->alarm);
   if (error == GRPC_ERROR_NONE) {
     *connect->endpoint = custom_tcp_endpoint_create(
-        socket, connect->resource_quota, connect->addr_name.c_str());
+        socket, connect->slice_allocator, connect->addr_name.c_str());
+    connect->slice_allocator = nullptr;
   }
   done = (--connect->refs == 0);
   if (done) {
@@ -111,6 +113,7 @@ static void custom_connect_callback(grpc_custom_socket* socket,
 }
 
 static void tcp_connect(grpc_closure* closure, grpc_endpoint** ep,
+                        grpc_slice_allocator* slice_allocator,
                         grpc_pollset_set* interested_parties,
                         const grpc_channel_args* channel_args,
                         const grpc_resolved_address* resolved_addr,
@@ -118,17 +121,6 @@ static void tcp_connect(grpc_closure* closure, grpc_endpoint** ep,
   GRPC_CUSTOM_IOMGR_ASSERT_SAME_THREAD();
   (void)channel_args;
   (void)interested_parties;
-  grpc_resource_quota* resource_quota = grpc_resource_quota_create(nullptr);
-  if (channel_args != nullptr) {
-    for (size_t i = 0; i < channel_args->num_args; i++) {
-      if (0 == strcmp(channel_args->args[i].key, GRPC_ARG_RESOURCE_QUOTA)) {
-        grpc_resource_quota_unref_internal(resource_quota);
-        resource_quota =
-            grpc_resource_quota_ref_internal(static_cast<grpc_resource_quota*>(
-                channel_args->args[i].value.pointer.p));
-      }
-    }
-  }
   grpc_custom_socket* socket =
       static_cast<grpc_custom_socket*>(gpr_malloc(sizeof(grpc_custom_socket)));
   socket->refs = 2;
@@ -137,7 +129,7 @@ static void tcp_connect(grpc_closure* closure, grpc_endpoint** ep,
   connect->closure = closure;
   connect->endpoint = ep;
   connect->addr_name = grpc_sockaddr_to_uri(resolved_addr);
-  connect->resource_quota = resource_quota;
+  connect->slice_allocator = slice_allocator;
   connect->socket = socket;
   socket->connector = connect;
   socket->endpoint = nullptr;
index 54c1511..3e8d20a 100644 (file)
@@ -22,8 +22,6 @@
 
 #ifdef GRPC_POSIX_SOCKET_TCP_CLIENT
 
-#include "src/core/lib/iomgr/tcp_client_posix.h"
-
 #include <errno.h>
 #include <netinet/in.h>
 #include <string.h>
@@ -44,6 +42,7 @@
 #include "src/core/lib/iomgr/sockaddr.h"
 #include "src/core/lib/iomgr/socket_mutator.h"
 #include "src/core/lib/iomgr/socket_utils_posix.h"
+#include "src/core/lib/iomgr/tcp_client_posix.h"
 #include "src/core/lib/iomgr/tcp_posix.h"
 #include "src/core/lib/iomgr/timer.h"
 #include "src/core/lib/iomgr/unix_sockets_posix.h"
@@ -63,6 +62,7 @@ struct async_connect {
   grpc_endpoint** ep;
   grpc_closure* closure;
   grpc_channel_args* channel_args;
+  grpc_slice_allocator* slice_allocator;
 };
 
 static grpc_error_handle prepare_socket(const grpc_resolved_address* addr,
@@ -118,14 +118,18 @@ static void tc_on_alarm(void* acp, grpc_error_handle error) {
   gpr_mu_unlock(&ac->mu);
   if (done) {
     gpr_mu_destroy(&ac->mu);
+    if (ac->slice_allocator != nullptr) {
+      grpc_slice_allocator_destroy(ac->slice_allocator);
+    }
     grpc_channel_args_destroy(ac->channel_args);
     delete ac;
   }
 }
 
 grpc_endpoint* grpc_tcp_client_create_from_fd(
-    grpc_fd* fd, const grpc_channel_args* channel_args, const char* addr_str) {
-  return grpc_tcp_create(fd, channel_args, addr_str);
+    grpc_fd* fd, const grpc_channel_args* channel_args, const char* addr_str,
+    grpc_slice_allocator* slice_allocator) {
+  return grpc_tcp_create(fd, channel_args, addr_str, slice_allocator);
 }
 
 static void on_writable(void* acp, grpc_error_handle error) {
@@ -174,8 +178,9 @@ static void on_writable(void* acp, grpc_error_handle error) {
   switch (so_error) {
     case 0:
       grpc_pollset_set_del_fd(ac->interested_parties, fd);
-      *ep = grpc_tcp_client_create_from_fd(fd, ac->channel_args,
-                                           ac->addr_str.c_str());
+      *ep = grpc_tcp_client_create_from_fd(
+          fd, ac->channel_args, ac->addr_str.c_str(), ac->slice_allocator);
+      ac->slice_allocator = nullptr;
       fd = nullptr;
       break;
     case ENOBUFS:
@@ -237,6 +242,10 @@ finish:
     // This is safe even outside the lock, because "done", the sentinel, is
     // populated *inside* the lock.
     gpr_mu_destroy(&ac->mu);
+    if (ac->slice_allocator != nullptr) {
+      grpc_slice_allocator_destroy(ac->slice_allocator);
+      ac->slice_allocator = nullptr;
+    }
     grpc_channel_args_destroy(ac->channel_args);
     delete ac;
   }
@@ -279,7 +288,8 @@ grpc_error_handle grpc_tcp_client_prepare_fd(
 void grpc_tcp_client_create_from_prepared_fd(
     grpc_pollset_set* interested_parties, grpc_closure* closure, const int fd,
     const grpc_channel_args* channel_args, const grpc_resolved_address* addr,
-    grpc_millis deadline, grpc_endpoint** ep) {
+    grpc_millis deadline, grpc_endpoint** ep,
+    grpc_slice_allocator* slice_allocator) {
   int err;
   do {
     err = connect(fd, reinterpret_cast<const grpc_sockaddr*>(addr->addr),
@@ -291,11 +301,13 @@ void grpc_tcp_client_create_from_prepared_fd(
 
   if (err >= 0) {
     *ep = grpc_tcp_client_create_from_fd(fdobj, channel_args,
-                                         grpc_sockaddr_to_uri(addr).c_str());
+                                         grpc_sockaddr_to_uri(addr).c_str(),
+                                         slice_allocator);
     grpc_core::ExecCtx::Run(DEBUG_LOCATION, closure, GRPC_ERROR_NONE);
     return;
   }
   if (errno != EWOULDBLOCK && errno != EINPROGRESS) {
+    grpc_slice_allocator_destroy(slice_allocator);
     grpc_error_handle error = GRPC_OS_ERROR(errno, "connect");
     error = grpc_error_set_str(
         error, GRPC_ERROR_STR_TARGET_ADDRESS,
@@ -315,6 +327,7 @@ void grpc_tcp_client_create_from_prepared_fd(
   ac->addr_str = grpc_sockaddr_to_uri(addr);
   gpr_mu_init(&ac->mu);
   ac->refs = 2;
+  ac->slice_allocator = slice_allocator;
   GRPC_CLOSURE_INIT(&ac->write_closure, on_writable, ac,
                     grpc_schedule_on_exec_ctx);
   ac->channel_args = grpc_channel_args_copy(channel_args);
@@ -332,6 +345,7 @@ void grpc_tcp_client_create_from_prepared_fd(
 }
 
 static void tcp_connect(grpc_closure* closure, grpc_endpoint** ep,
+                        grpc_slice_allocator* slice_allocator,
                         grpc_pollset_set* interested_parties,
                         const grpc_channel_args* channel_args,
                         const grpc_resolved_address* addr,
@@ -342,12 +356,13 @@ static void tcp_connect(grpc_closure* closure, grpc_endpoint** ep,
   *ep = nullptr;
   if ((error = grpc_tcp_client_prepare_fd(channel_args, addr, &mapped_addr,
                                           &fd)) != GRPC_ERROR_NONE) {
+    grpc_slice_allocator_destroy(slice_allocator);
     grpc_core::ExecCtx::Run(DEBUG_LOCATION, closure, error);
     return;
   }
   grpc_tcp_client_create_from_prepared_fd(interested_parties, closure, fd,
                                           channel_args, &mapped_addr, deadline,
-                                          ep);
+                                          ep, slice_allocator);
 }
 
 grpc_tcp_client_vtable grpc_posix_tcp_client_vtable = {tcp_connect};
index 2467f37..dc5b9c3 100644 (file)
    fd: a connected FD. Ownership is taken.
    channel_args: may contain custom settings for the endpoint
    addr_str: destination address in printable format
+   slice_allocator: ownership is taken by client.
    Returns: a new endpoint
 */
 grpc_endpoint* grpc_tcp_client_create_from_fd(
-    grpc_fd* fd, const grpc_channel_args* channel_args, const char* addr_str);
+    grpc_fd* fd, const grpc_channel_args* channel_args, const char* addr_str,
+    grpc_slice_allocator* slice_allocator);
 
 /* Return a configured, unbound, unconnected TCP client fd.
 
@@ -62,6 +64,7 @@ grpc_error_handle grpc_tcp_client_prepare_fd(
 void grpc_tcp_client_create_from_prepared_fd(
     grpc_pollset_set* interested_parties, grpc_closure* closure, const int fd,
     const grpc_channel_args* channel_args, const grpc_resolved_address* addr,
-    grpc_millis deadline, grpc_endpoint** ep);
+    grpc_millis deadline, grpc_endpoint** ep,
+    grpc_slice_allocator* slice_allocator);
 
 #endif /* GRPC_CORE_LIB_IOMGR_TCP_CLIENT_POSIX_H */
index 1f862de..5138b88 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include "src/core/lib/iomgr/port.h"
-
 #include <inttypes.h>
 
-#ifdef GRPC_WINSOCK_SOCKET
+#include "src/core/lib/iomgr/port.h"
 
-#include "src/core/lib/iomgr/sockaddr_windows.h"
+#ifdef GRPC_WINSOCK_SOCKET
 
 #include <grpc/slice_buffer.h>
 #include <grpc/support/alloc.h>
@@ -35,6 +33,7 @@
 #include "src/core/lib/channel/channel_args.h"
 #include "src/core/lib/iomgr/iocp_windows.h"
 #include "src/core/lib/iomgr/sockaddr.h"
+#include "src/core/lib/iomgr/sockaddr_windows.h"
 #include "src/core/lib/iomgr/socket_windows.h"
 #include "src/core/lib/iomgr/tcp_client.h"
 #include "src/core/lib/iomgr/tcp_windows.h"
@@ -52,6 +51,7 @@ struct async_connect {
   grpc_closure on_connect;
   grpc_endpoint** endpoint;
   grpc_channel_args* channel_args;
+  grpc_slice_allocator* slice_allocator;
 };
 
 static void async_connect_unlock_and_cleanup(async_connect* ac,
@@ -61,6 +61,9 @@ static void async_connect_unlock_and_cleanup(async_connect* ac,
   if (done) {
     grpc_channel_args_destroy(ac->channel_args);
     gpr_mu_destroy(&ac->mu);
+    if (ac->slice_allocator != nullptr) {
+      grpc_slice_allocator_destroy(ac->slice_allocator);
+    }
     delete ac;
   }
   if (socket != NULL) grpc_winsocket_destroy(socket);
@@ -106,8 +109,10 @@ static void on_connect(void* acp, grpc_error_handle error) {
         error = GRPC_WSA_ERROR(WSAGetLastError(), "ConnectEx");
         closesocket(socket->socket);
       } else {
-        *ep = grpc_tcp_create(socket, ac->channel_args, ac->addr_name.c_str());
-        socket = NULL;
+        *ep = grpc_tcp_create(socket, ac->channel_args, ac->addr_name.c_str(),
+                              ac->slice_allocator);
+        ac->slice_allocator = nullptr;
+        socket = nullptr;
       }
     } else {
       error = GRPC_ERROR_CREATE_FROM_STATIC_STRING("socket is null");
@@ -123,6 +128,7 @@ static void on_connect(void* acp, grpc_error_handle error) {
 /* Tries to issue one async connection, then schedules both an IOCP
    notification request for the connection, and one timeout alert. */
 static void tcp_connect(grpc_closure* on_done, grpc_endpoint** endpoint,
+                        grpc_slice_allocator* slice_allocator,
                         grpc_pollset_set* interested_parties,
                         const grpc_channel_args* channel_args,
                         const grpc_resolved_address* addr,
@@ -202,6 +208,7 @@ static void tcp_connect(grpc_closure* on_done, grpc_endpoint** endpoint,
   ac->refs = 2;
   ac->addr_name = grpc_sockaddr_to_uri(addr);
   ac->endpoint = endpoint;
+  ac->slice_allocator = slice_allocator;
   ac->channel_args = grpc_channel_args_copy(channel_args);
   GRPC_CLOSURE_INIT(&ac->on_connect, on_connect, ac, grpc_schedule_on_exec_ctx);
 
@@ -221,6 +228,7 @@ failure:
                          GRPC_ERROR_STR_TARGET_ADDRESS,
                          grpc_slice_from_cpp_string(std::move(target_uri)));
   GRPC_ERROR_UNREF(error);
+  grpc_slice_allocator_destroy(slice_allocator);
   if (socket != NULL) {
     grpc_winsocket_destroy(socket);
   } else if (sock != INVALID_SOCKET) {
index c526a95..a74bc28 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include "src/core/lib/iomgr/port.h"
+#include "src/core/lib/iomgr/tcp_custom.h"
 
 #include <limits.h>
 #include <string.h>
 
 #include <grpc/slice_buffer.h>
-
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/string_util.h>
@@ -32,9 +31,9 @@
 #include "src/core/lib/address_utils/sockaddr_utils.h"
 #include "src/core/lib/iomgr/error.h"
 #include "src/core/lib/iomgr/iomgr_custom.h"
+#include "src/core/lib/iomgr/port.h"
 #include "src/core/lib/iomgr/resource_quota.h"
 #include "src/core/lib/iomgr/tcp_client.h"
-#include "src/core/lib/iomgr/tcp_custom.h"
 #include "src/core/lib/iomgr/tcp_server.h"
 #include "src/core/lib/slice/slice_internal.h"
 #include "src/core/lib/slice/slice_string_helpers.h"
@@ -64,8 +63,7 @@ struct custom_tcp_endpoint {
   grpc_slice_buffer* read_slices = nullptr;
   grpc_slice_buffer* write_slices = nullptr;
 
-  grpc_resource_user* resource_user;
-  grpc_resource_user_slice_allocator slice_allocator;
+  grpc_slice_allocator* slice_allocator;
 
   bool shutting_down;
 
@@ -75,7 +73,7 @@ struct custom_tcp_endpoint {
 static void tcp_free(grpc_custom_socket* s) {
   custom_tcp_endpoint* tcp =
       reinterpret_cast<custom_tcp_endpoint*>(s->endpoint);
-  grpc_resource_user_unref(tcp->resource_user);
+  grpc_slice_allocator_destroy(tcp->slice_allocator);
   delete tcp;
   s->refs--;
   if (s->refs == 0) {
@@ -203,9 +201,10 @@ static void endpoint_read(grpc_endpoint* ep, grpc_slice_buffer* read_slices,
   tcp->read_slices = read_slices;
   grpc_slice_buffer_reset_and_unref_internal(read_slices);
   TCP_REF(tcp, "read");
-  if (grpc_resource_user_alloc_slices(&tcp->slice_allocator,
-                                      GRPC_TCP_DEFAULT_READ_SLICE_SIZE, 1,
-                                      tcp->read_slices)) {
+  if (grpc_slice_allocator_allocate(
+          tcp->slice_allocator, GRPC_TCP_DEFAULT_READ_SLICE_SIZE, 1,
+          grpc_slice_allocator_intent::kReadBuffer, tcp->read_slices,
+          tcp_read_allocation_done, tcp)) {
     tcp_read_allocation_done(tcp, GRPC_ERROR_NONE);
   }
 }
@@ -254,8 +253,7 @@ static void endpoint_write(grpc_endpoint* ep, grpc_slice_buffer* write_slices,
   tcp->write_slices = write_slices;
   GPR_ASSERT(tcp->write_slices->count <= UINT_MAX);
   if (tcp->write_slices->count == 0) {
-    // No slices means we don't have to do anything,
-    // and libuv doesn't like empty writes
+    // No slices means we don't have to do anything
     grpc_core::ExecCtx::Run(DEBUG_LOCATION, cb, GRPC_ERROR_NONE);
     return;
   }
@@ -297,7 +295,6 @@ static void endpoint_shutdown(grpc_endpoint* ep, grpc_error_handle why) {
     // GRPC_ERROR_REF(why));
     // grpc_core::ExecCtx::Run(DEBUG_LOCATION,tcp->write_cb,
     // GRPC_ERROR_REF(why)); tcp->read_cb = nullptr; tcp->write_cb = nullptr;
-    grpc_resource_user_shutdown(tcp->resource_user);
     grpc_custom_socket_vtable->shutdown(tcp->socket);
   }
   GRPC_ERROR_UNREF(why);
@@ -332,11 +329,6 @@ static absl::string_view endpoint_get_local_address(grpc_endpoint* ep) {
   return tcp->local_address;
 }
 
-static grpc_resource_user* endpoint_get_resource_user(grpc_endpoint* ep) {
-  custom_tcp_endpoint* tcp = reinterpret_cast<custom_tcp_endpoint*>(ep);
-  return tcp->resource_user;
-}
-
 static int endpoint_get_fd(grpc_endpoint* /*ep*/) { return -1; }
 
 static bool endpoint_can_track_err(grpc_endpoint* /*ep*/) { return false; }
@@ -348,14 +340,13 @@ static grpc_endpoint_vtable vtable = {endpoint_read,
                                       endpoint_delete_from_pollset_set,
                                       endpoint_shutdown,
                                       endpoint_destroy,
-                                      endpoint_get_resource_user,
                                       endpoint_get_peer,
                                       endpoint_get_local_address,
                                       endpoint_get_fd,
                                       endpoint_can_track_err};
 
 grpc_endpoint* custom_tcp_endpoint_create(grpc_custom_socket* socket,
-                                          grpc_resource_quota* resource_quota,
+                                          grpc_slice_allocator* slice_allocator,
                                           const char* peer_string) {
   custom_tcp_endpoint* tcp = new custom_tcp_endpoint;
   grpc_core::ApplicationCallbackExecCtx callback_exec_ctx;
@@ -381,9 +372,6 @@ grpc_endpoint* custom_tcp_endpoint_create(grpc_custom_socket* socket,
     tcp->local_address = grpc_sockaddr_to_uri(&resolved_local_addr);
   }
   tcp->shutting_down = false;
-  tcp->resource_user = grpc_resource_user_create(resource_quota, peer_string);
-  grpc_resource_user_slice_allocator_init(
-      &tcp->slice_allocator, tcp->resource_user, tcp_read_allocation_done, tcp);
-
+  tcp->slice_allocator = slice_allocator;
   return &tcp->base;
 }
index b342efb..f0778e0 100644 (file)
@@ -78,8 +78,9 @@ void grpc_custom_endpoint_init(grpc_socket_vtable* impl);
 
 void grpc_custom_close_server_callback(grpc_tcp_listener* listener);
 
+/// Takes ownership of \a slice_allocator.
 grpc_endpoint* custom_tcp_endpoint_create(grpc_custom_socket* socket,
-                                          grpc_resource_quota* resource_quota,
+                                          grpc_slice_allocator* slice_allocator,
                                           const char* peer_string);
 
 #endif /* GRPC_CORE_LIB_IOMGR_TCP_CUSTOM_H */
index ad09713..9d00000 100644 (file)
@@ -22,8 +22,6 @@
 
 #ifdef GRPC_POSIX_SOCKET_TCP
 
-#include "src/core/lib/iomgr/tcp_posix.h"
-
 #include <errno.h>
 #include <limits.h>
 #include <netinet/in.h>
@@ -35,6 +33,7 @@
 #include <sys/socket.h>
 #include <sys/types.h>
 #include <unistd.h>
+
 #include <algorithm>
 #include <unordered_map>
 
@@ -55,7 +54,9 @@
 #include "src/core/lib/iomgr/buffer_list.h"
 #include "src/core/lib/iomgr/ev_posix.h"
 #include "src/core/lib/iomgr/executor.h"
+#include "src/core/lib/iomgr/resource_quota.h"
 #include "src/core/lib/iomgr/socket_utils_posix.h"
+#include "src/core/lib/iomgr/tcp_posix.h"
 #include "src/core/lib/profiling/timers.h"
 #include "src/core/lib/slice/slice_internal.h"
 #include "src/core/lib/slice/slice_string_helpers.h"
@@ -136,12 +137,12 @@ class TcpZerocopySendRecord {
   }
 
   // References: 1 reference per sendmsg(), and 1 for the tcp_write().
-  void Ref() { ref_.FetchAdd(1, MemoryOrder::RELAXED); }
+  void Ref() { ref_.fetch_add(1, std::memory_order_relaxed); }
 
   // Unref: called when we get an error queue notification for a sendmsg(), if a
   //  sendmsg() failed or when tcp_write() is done.
   bool Unref() {
-    const intptr_t prior = ref_.FetchSub(1, MemoryOrder::ACQ_REL);
+    const intptr_t prior = ref_.fetch_sub(1, std::memory_order_acq_rel);
     GPR_DEBUG_ASSERT(prior > 0);
     if (prior == 1) {
       AllSendsComplete();
@@ -159,7 +160,7 @@ class TcpZerocopySendRecord {
   void AssertEmpty() {
     GPR_DEBUG_ASSERT(buf_.count == 0);
     GPR_DEBUG_ASSERT(buf_.length == 0);
-    GPR_DEBUG_ASSERT(ref_.Load(MemoryOrder::RELAXED) == 0);
+    GPR_DEBUG_ASSERT(ref_.load(std::memory_order_relaxed) == 0);
   }
 
   // When all sendmsg() calls associated with this tcp_write() have been
@@ -167,12 +168,12 @@ class TcpZerocopySendRecord {
   // for each sendmsg()) and all reference counts have been dropped, drop our
   // reference to the underlying data since we no longer need it.
   void AllSendsComplete() {
-    GPR_DEBUG_ASSERT(ref_.Load(MemoryOrder::RELAXED) == 0);
+    GPR_DEBUG_ASSERT(ref_.load(std::memory_order_relaxed) == 0);
     grpc_slice_buffer_reset_and_unref_internal(&buf_);
   }
 
   grpc_slice_buffer buf_;
-  Atomic<intptr_t> ref_;
+  std::atomic<intptr_t> ref_{0};
   OutgoingOffset out_offset_;
 };
 
@@ -286,7 +287,7 @@ class TcpZerocopySendCtx {
 
   // Indicate that we are disposing of this zerocopy context. This indicator
   // will prevent new zerocopy writes from being issued.
-  void Shutdown() { shutdown_.Store(true, MemoryOrder::RELEASE); }
+  void Shutdown() { shutdown_.store(true, std::memory_order_release); }
 
   // Indicates that there are no inflight tcp_write() instances with zerocopy
   // enabled.
@@ -317,7 +318,7 @@ class TcpZerocopySendCtx {
   }
 
   TcpZerocopySendRecord* TryGetSendRecordLocked() {
-    if (shutdown_.Load(MemoryOrder::ACQUIRE)) {
+    if (shutdown_.load(std::memory_order_acquire)) {
       return nullptr;
     }
     if (free_send_records_size_ == 0) {
@@ -339,7 +340,7 @@ class TcpZerocopySendCtx {
   int free_send_records_size_;
   Mutex lock_;
   uint32_t last_send_ = 0;
-  Atomic<bool> shutdown_;
+  std::atomic<bool> shutdown_{false};
   bool enabled_ = false;
   size_t threshold_bytes_ = kDefaultSendBytesThreshold;
   std::unordered_map<uint32_t, TcpZerocopySendRecord*> ctx_lookup_;
@@ -392,8 +393,7 @@ struct grpc_tcp {
   std::string peer_string;
   std::string local_address;
 
-  grpc_resource_user* resource_user;
-  grpc_resource_user_slice_allocator slice_allocator;
+  grpc_slice_allocator* slice_allocator;
 
   grpc_core::TracedBuffer* tb_head; /* List of traced buffers */
   gpr_mu tb_mu; /* Lock for access to list of traced buffers */
@@ -584,24 +584,6 @@ static void finish_estimate(grpc_tcp* tcp) {
   tcp->bytes_read_this_round = 0;
 }
 
-static size_t get_target_read_size(grpc_tcp* tcp) {
-  grpc_resource_quota* rq = grpc_resource_user_quota(tcp->resource_user);
-  double pressure = grpc_resource_quota_get_memory_pressure(rq);
-  double target =
-      tcp->target_length * (pressure > 0.8 ? (1.0 - pressure) / 0.2 : 1.0);
-  size_t sz = ((static_cast<size_t> GPR_CLAMP(target, tcp->min_read_chunk_size,
-                                              tcp->max_read_chunk_size)) +
-               255) &
-              ~static_cast<size_t>(255);
-  /* don't use more than 1/16th of the overall resource quota for a single read
-   * alloc */
-  size_t rqmax = grpc_resource_quota_peek_size(rq);
-  if (sz > rqmax / 16 && rqmax > 1024) {
-    sz = rqmax / 16;
-  }
-  return sz;
-}
-
 static grpc_error_handle tcp_annotate_error(grpc_error_handle src_error,
                                             grpc_tcp* tcp) {
   return grpc_error_set_str(
@@ -621,14 +603,13 @@ static void tcp_shutdown(grpc_endpoint* ep, grpc_error_handle why) {
   grpc_tcp* tcp = reinterpret_cast<grpc_tcp*>(ep);
   ZerocopyDisableAndWaitForRemaining(tcp);
   grpc_fd_shutdown(tcp->em_fd, why);
-  grpc_resource_user_shutdown(tcp->resource_user);
 }
 
 static void tcp_free(grpc_tcp* tcp) {
   grpc_fd_orphan(tcp->em_fd, tcp->release_fd_cb, tcp->release_fd,
                  "tcp_unref_orphan");
   grpc_slice_buffer_destroy_internal(&tcp->last_read_buffer);
-  grpc_resource_user_unref(tcp->resource_user);
+  grpc_slice_allocator_destroy(tcp->slice_allocator);
   /* The lock is not really necessary here, since all refs have been released */
   gpr_mu_lock(&tcp->tb_mu);
   grpc_core::TracedBuffer::Shutdown(
@@ -864,16 +845,16 @@ static void tcp_read_allocation_done(void* tcpp, grpc_error_handle error) {
 }
 
 static void tcp_continue_read(grpc_tcp* tcp) {
-  size_t target_read_size = get_target_read_size(tcp);
   /* Wait for allocation only when there is no buffer left. */
   if (tcp->incoming_buffer->length == 0 &&
       tcp->incoming_buffer->count < MAX_READ_IOVEC) {
     if (GRPC_TRACE_FLAG_ENABLED(grpc_tcp_trace)) {
       gpr_log(GPR_INFO, "TCP:%p alloc_slices", tcp);
     }
-    if (GPR_UNLIKELY(!grpc_resource_user_alloc_slices(&tcp->slice_allocator,
-                                                      target_read_size, 1,
-                                                      tcp->incoming_buffer))) {
+    if (GPR_UNLIKELY(!grpc_slice_allocator_allocate(
+            tcp->slice_allocator, tcp->target_length, 1,
+            grpc_slice_allocator_intent::kReadBuffer, tcp->incoming_buffer,
+            tcp_read_allocation_done, tcp))) {
       // Wait for allocation.
       return;
     }
@@ -1276,10 +1257,10 @@ void tcp_shutdown_buffer_list(grpc_tcp* tcp) {
   }
 }
 
-#if defined(IOV_MAX) && IOV_MAX < 1000
+#if defined(IOV_MAX) && IOV_MAX < 260
 #define MAX_WRITE_IOVEC IOV_MAX
 #else
-#define MAX_WRITE_IOVEC 1000
+#define MAX_WRITE_IOVEC 260
 #endif
 msg_iovlen_type TcpZerocopySendRecord::PopulateIovs(size_t* unwind_slice_idx,
                                                     size_t* unwind_byte_idx,
@@ -1324,13 +1305,17 @@ void TcpZerocopySendRecord::UpdateOffsetForBytesSent(size_t sending_length,
 // returns true if done, false if pending; if returning true, *error is set
 static bool do_tcp_flush_zerocopy(grpc_tcp* tcp, TcpZerocopySendRecord* record,
                                   grpc_error_handle* error) {
-  struct msghdr msg;
-  struct iovec iov[MAX_WRITE_IOVEC];
   msg_iovlen_type iov_size;
   ssize_t sent_length = 0;
   size_t sending_length;
   size_t unwind_slice_idx;
   size_t unwind_byte_idx;
+  bool tried_sending_message;
+  msghdr msg;
+  // iov consumes a large space. Keep it as the last item on the stack to
+  // improve locality. After all, we expect only the first elements of it being
+  // populated in most cases.
+  iovec iov[MAX_WRITE_IOVEC];
   while (true) {
     sending_length = 0;
     iov_size = record->PopulateIovs(&unwind_slice_idx, &unwind_byte_idx,
@@ -1340,7 +1325,7 @@ static bool do_tcp_flush_zerocopy(grpc_tcp* tcp, TcpZerocopySendRecord* record,
     msg.msg_iov = iov;
     msg.msg_iovlen = iov_size;
     msg.msg_flags = 0;
-    bool tried_sending_message = false;
+    tried_sending_message = false;
     // Before calling sendmsg (with or without timestamps): we
     // take a single ref on the zerocopy send record.
     tcp->tcp_zerocopy_send_ctx.NoteSend(record);
@@ -1656,11 +1641,6 @@ static int tcp_get_fd(grpc_endpoint* ep) {
   return tcp->fd;
 }
 
-static grpc_resource_user* tcp_get_resource_user(grpc_endpoint* ep) {
-  grpc_tcp* tcp = reinterpret_cast<grpc_tcp*>(ep);
-  return tcp->resource_user;
-}
-
 static bool tcp_can_track_err(grpc_endpoint* ep) {
   grpc_tcp* tcp = reinterpret_cast<grpc_tcp*>(ep);
   if (!grpc_event_engine_can_track_errors()) {
@@ -1681,7 +1661,6 @@ static const grpc_endpoint_vtable vtable = {tcp_read,
                                             tcp_delete_from_pollset_set,
                                             tcp_shutdown,
                                             tcp_destroy,
-                                            tcp_get_resource_user,
                                             tcp_get_peer,
                                             tcp_get_local_address,
                                             tcp_get_fd,
@@ -1691,7 +1670,8 @@ static const grpc_endpoint_vtable vtable = {tcp_read,
 
 grpc_endpoint* grpc_tcp_create(grpc_fd* em_fd,
                                const grpc_channel_args* channel_args,
-                               const char* peer_string) {
+                               const char* peer_string,
+                               grpc_slice_allocator* slice_allocator) {
   static constexpr bool kZerocpTxEnabledDefault = false;
   int tcp_read_chunk_size = GRPC_TCP_DEFAULT_READ_SLICE_SIZE;
   int tcp_max_read_chunk_size = 4 * 1024 * 1024;
@@ -1701,7 +1681,6 @@ grpc_endpoint* grpc_tcp_create(grpc_fd* em_fd,
       grpc_core::TcpZerocopySendCtx::kDefaultSendBytesThreshold;
   int tcp_tx_zerocopy_max_simult_sends =
       grpc_core::TcpZerocopySendCtx::kDefaultMaxSends;
-  grpc_resource_quota* resource_quota = grpc_resource_quota_create(nullptr);
   if (channel_args != nullptr) {
     for (size_t i = 0; i < channel_args->num_args; i++) {
       if (0 ==
@@ -1719,12 +1698,6 @@ grpc_endpoint* grpc_tcp_create(grpc_fd* em_fd,
         grpc_integer_options options = {tcp_read_chunk_size, 1, MAX_CHUNK_SIZE};
         tcp_max_read_chunk_size =
             grpc_channel_arg_get_integer(&channel_args->args[i], options);
-      } else if (0 ==
-                 strcmp(channel_args->args[i].key, GRPC_ARG_RESOURCE_QUOTA)) {
-        grpc_resource_quota_unref_internal(resource_quota);
-        resource_quota =
-            grpc_resource_quota_ref_internal(static_cast<grpc_resource_quota*>(
-                channel_args->args[i].value.pointer.p));
       } else if (0 == strcmp(channel_args->args[i].key,
                              GRPC_ARG_TCP_TX_ZEROCOPY_ENABLED)) {
         tcp_tx_zerocopy_enabled = grpc_channel_arg_get_bool(
@@ -1757,6 +1730,7 @@ grpc_endpoint* grpc_tcp_create(grpc_fd* em_fd,
   tcp->base.vtable = &vtable;
   tcp->peer_string = peer_string;
   tcp->fd = grpc_fd_wrapped_fd(em_fd);
+  tcp->slice_allocator = slice_allocator;
   grpc_resolved_address resolved_local_addr;
   memset(&resolved_local_addr, 0, sizeof(resolved_local_addr));
   resolved_local_addr.len = sizeof(resolved_local_addr.addr);
@@ -1801,10 +1775,6 @@ grpc_endpoint* grpc_tcp_create(grpc_fd* em_fd,
   gpr_atm_no_barrier_store(&tcp->shutdown_count, 0);
   tcp->em_fd = em_fd;
   grpc_slice_buffer_init(&tcp->last_read_buffer);
-  tcp->resource_user = grpc_resource_user_create(resource_quota, peer_string);
-  grpc_resource_user_slice_allocator_init(
-      &tcp->slice_allocator, tcp->resource_user, tcp_read_allocation_done, tcp);
-  grpc_resource_quota_unref_internal(resource_quota);
   gpr_mu_init(&tcp->tb_mu);
   tcp->tb_head = nullptr;
   GRPC_CLOSURE_INIT(&tcp->read_done_closure, tcp_handle_read, tcp,
index f9ab134..41f4f67 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include "src/core/lib/iomgr/port.h"
-
 #include "src/core/lib/debug/trace.h"
 #include "src/core/lib/iomgr/buffer_list.h"
 #include "src/core/lib/iomgr/endpoint.h"
 #include "src/core/lib/iomgr/ev_posix.h"
+#include "src/core/lib/iomgr/port.h"
+#include "src/core/lib/iomgr/resource_quota.h"
 
 extern grpc_core::TraceFlag grpc_tcp_trace;
 
-/* Create a tcp endpoint given a file desciptor and a read slice size.
-   Takes ownership of fd. */
+/// Create a tcp endpoint given a file desciptor and a read slice size.
+/// Takes ownership of \a fd. Takes ownership of the \a slice_allocator.
 grpc_endpoint* grpc_tcp_create(grpc_fd* fd, const grpc_channel_args* args,
-                               const char* peer_string);
+                               const char* peer_string,
+                               grpc_slice_allocator* slice_allocator);
 
-/* Return the tcp endpoint's fd, or -1 if this is not available. Does not
-   release the fd.
-   Requires: ep must be a tcp endpoint.
- */
+/// Return the tcp endpoint's fd, or -1 if this is not available. Does not
+/// release the fd. Requires: \a ep must be a tcp endpoint.
 int grpc_tcp_fd(grpc_endpoint* ep);
 
-/* Destroy the tcp endpoint without closing its fd. *fd will be set and done
- * will be called when the endpoint is destroyed.
- * Requires: ep must be a tcp endpoint and fd must not be NULL. */
+/// Destroy the tcp endpoint without closing its fd. *fd will be set and done
+/// will be called when the endpoint is destroyed. Requires: \a ep must be a tcp
+/// endpoint and fd must not be NULL.
 void grpc_tcp_destroy_and_release_fd(grpc_endpoint* ep, int* fd,
                                      grpc_closure* done);
 
index 8d6fefb..70be587 100644 (file)
 
 grpc_tcp_server_vtable* grpc_tcp_server_impl;
 
-grpc_error_handle grpc_tcp_server_create(grpc_closure* shutdown_complete,
-                                         const grpc_channel_args* args,
-                                         grpc_tcp_server** server) {
-  return grpc_tcp_server_impl->create(shutdown_complete, args, server);
+grpc_error_handle grpc_tcp_server_create(
+    grpc_closure* shutdown_complete, const grpc_channel_args* args,
+    grpc_slice_allocator_factory* slice_allocator_factory,
+    grpc_tcp_server** server) {
+  return grpc_tcp_server_impl->create(shutdown_complete, args,
+                                      slice_allocator_factory, server);
 }
 
 void grpc_tcp_server_start(grpc_tcp_server* server,
index 50ac4e7..9a65b6e 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
+#include <vector>
+
 #include <grpc/grpc.h>
 #include <grpc/impl/codegen/grpc_types.h>
 
-#include <vector>
-
 #include "src/core/lib/iomgr/closure.h"
 #include "src/core/lib/iomgr/endpoint.h"
 #include "src/core/lib/iomgr/resolve_address.h"
@@ -63,9 +63,10 @@ class TcpServerFdHandler {
 }  // namespace grpc_core
 
 typedef struct grpc_tcp_server_vtable {
-  grpc_error_handle (*create)(grpc_closure* shutdown_complete,
-                              const grpc_channel_args* args,
-                              grpc_tcp_server** server);
+  grpc_error_handle (*create)(
+      grpc_closure* shutdown_complete, const grpc_channel_args* args,
+      grpc_slice_allocator_factory* slice_allocator_factory,
+      grpc_tcp_server** server);
   void (*start)(grpc_tcp_server* server,
                 const std::vector<grpc_pollset*>* pollsets,
                 grpc_tcp_server_cb on_accept_cb, void* cb_arg);
@@ -84,10 +85,12 @@ typedef struct grpc_tcp_server_vtable {
 
 /* Create a server, initially not bound to any ports. The caller owns one ref.
    If shutdown_complete is not NULL, it will be used by
-   grpc_tcp_server_unref() when the ref count reaches zero. */
-grpc_error_handle grpc_tcp_server_create(grpc_closure* shutdown_complete,
-                                         const grpc_channel_args* args,
-                                         grpc_tcp_server** server);
+   grpc_tcp_server_unref() when the ref count reaches zero.
+   Takes ownership of the slice_allocator_factory. */
+grpc_error_handle grpc_tcp_server_create(
+    grpc_closure* shutdown_complete, const grpc_channel_args* args,
+    grpc_slice_allocator_factory* slice_allocator_factory,
+    grpc_tcp_server** server);
 
 /* Start listening to bound ports */
 void grpc_tcp_server_start(grpc_tcp_server* server,
index 8ffd728..cb622c0 100644 (file)
@@ -18,8 +18,6 @@
 
 #include <grpc/support/port_platform.h>
 
-#include "src/core/lib/iomgr/port.h"
-
 #include <assert.h>
 #include <string.h>
 
@@ -33,6 +31,7 @@
 #include "src/core/lib/iomgr/error.h"
 #include "src/core/lib/iomgr/exec_ctx.h"
 #include "src/core/lib/iomgr/iomgr_custom.h"
+#include "src/core/lib/iomgr/port.h"
 #include "src/core/lib/iomgr/sockaddr.h"
 #include "src/core/lib/iomgr/tcp_custom.h"
 #include "src/core/lib/iomgr/tcp_server.h"
@@ -77,34 +76,17 @@ struct grpc_tcp_server {
   bool shutdown;
   bool so_reuseport;
 
-  grpc_resource_quota* resource_quota;
+  grpc_slice_allocator_factory* slice_allocator_factory;
 };
 
-static grpc_error_handle tcp_server_create(grpc_closure* shutdown_complete,
-                                           const grpc_channel_args* args,
-                                           grpc_tcp_server** server) {
+static grpc_error_handle tcp_server_create(
+    grpc_closure* shutdown_complete, const grpc_channel_args* args,
+    grpc_slice_allocator_factory* slice_allocator_factory,
+    grpc_tcp_server** server) {
   grpc_tcp_server* s =
       static_cast<grpc_tcp_server*>(gpr_malloc(sizeof(grpc_tcp_server)));
-  // Let the implementation decide if so_reuseport can be enabled or not.
-  s->so_reuseport = true;
-  s->resource_quota = grpc_resource_quota_create(nullptr);
-  for (size_t i = 0; i < (args == nullptr ? 0 : args->num_args); i++) {
-    if (!grpc_channel_args_find_bool(args, GRPC_ARG_ALLOW_REUSEPORT, true)) {
-      s->so_reuseport = false;
-    }
-    if (0 == strcmp(GRPC_ARG_RESOURCE_QUOTA, args->args[i].key)) {
-      if (args->args[i].type == GRPC_ARG_POINTER) {
-        grpc_resource_quota_unref_internal(s->resource_quota);
-        s->resource_quota = grpc_resource_quota_ref_internal(
-            static_cast<grpc_resource_quota*>(args->args[i].value.pointer.p));
-      } else {
-        grpc_resource_quota_unref_internal(s->resource_quota);
-        gpr_free(s);
-        return GRPC_ERROR_CREATE_FROM_STATIC_STRING(
-            GRPC_ARG_RESOURCE_QUOTA " must be a pointer to a buffer pool");
-      }
-    }
-  }
+  s->so_reuseport =
+      grpc_channel_args_find_bool(args, GRPC_ARG_ALLOW_REUSEPORT, true);
   gpr_ref_init(&s->refs, 1);
   s->on_accept_cb = nullptr;
   s->on_accept_cb_arg = nullptr;
@@ -115,6 +97,7 @@ static grpc_error_handle tcp_server_create(grpc_closure* shutdown_complete,
   s->shutdown_starting.tail = nullptr;
   s->shutdown_complete = shutdown_complete;
   s->shutdown = false;
+  s->slice_allocator_factory = slice_allocator_factory;
   *server = s;
   return GRPC_ERROR_NONE;
 }
@@ -144,7 +127,7 @@ static void finish_shutdown(grpc_tcp_server* s) {
     sp->next = nullptr;
     gpr_free(sp);
   }
-  grpc_resource_quota_unref_internal(s->resource_quota);
+  grpc_slice_allocator_factory_destroy(s->slice_allocator_factory);
   gpr_free(s);
 }
 
@@ -235,8 +218,11 @@ static void finish_accept(grpc_tcp_listener* sp, grpc_custom_socket* socket) {
     gpr_log(GPR_INFO, "SERVER_CONNECT: %p accepted connection: %s", sp->server,
             peer_name_string.c_str());
   }
-  ep = custom_tcp_endpoint_create(socket, sp->server->resource_quota,
-                                  peer_name_string.c_str());
+  ep = custom_tcp_endpoint_create(
+      socket,
+      grpc_slice_allocator_factory_create_slice_allocator(
+          sp->server->slice_allocator_factory, peer_name_string),
+      peer_name_string.c_str());
   acceptor->from_server = sp->server;
   acceptor->port_index = sp->port_index;
   acceptor->fd_index = 0;
@@ -478,7 +464,3 @@ grpc_tcp_server_vtable custom_tcp_server_vtable = {
     tcp_server_port_fd_count, tcp_server_port_fd,
     tcp_server_ref,           tcp_server_shutdown_starting_add,
     tcp_server_unref,         tcp_server_shutdown_listeners};
-
-#ifdef GRPC_UV_TEST
-grpc_tcp_server_vtable* default_tcp_server_vtable = &custom_tcp_server_vtable;
-#endif
index c08c0a4..73a118c 100644 (file)
 #include "src/core/lib/iomgr/tcp_server_utils_posix.h"
 #include "src/core/lib/iomgr/unix_sockets_posix.h"
 
-static grpc_error_handle tcp_server_create(grpc_closure* shutdown_complete,
-                                           const grpc_channel_args* args,
-                                           grpc_tcp_server** server) {
+static grpc_error_handle tcp_server_create(
+    grpc_closure* shutdown_complete, const grpc_channel_args* args,
+    grpc_slice_allocator_factory* slice_allocator_factory,
+    grpc_tcp_server** server) {
   grpc_tcp_server* s =
       static_cast<grpc_tcp_server*>(gpr_zalloc(sizeof(grpc_tcp_server)));
   s->so_reuseport = grpc_is_socket_reuse_port_supported();
@@ -74,6 +75,7 @@ static grpc_error_handle tcp_server_create(grpc_closure* shutdown_complete,
                           (args->args[i].value.integer != 0);
       } else {
         gpr_free(s);
+        grpc_slice_allocator_factory_destroy(slice_allocator_factory);
         return GRPC_ERROR_CREATE_FROM_STATIC_STRING(GRPC_ARG_ALLOW_REUSEPORT
                                                     " must be an integer");
       }
@@ -82,6 +84,7 @@ static grpc_error_handle tcp_server_create(grpc_closure* shutdown_complete,
         s->expand_wildcard_addrs = (args->args[i].value.integer != 0);
       } else {
         gpr_free(s);
+        grpc_slice_allocator_factory_destroy(slice_allocator_factory);
         return GRPC_ERROR_CREATE_FROM_STATIC_STRING(
             GRPC_ARG_EXPAND_WILDCARD_ADDRS " must be an integer");
       }
@@ -102,6 +105,7 @@ static grpc_error_handle tcp_server_create(grpc_closure* shutdown_complete,
   s->nports = 0;
   s->channel_args = grpc_channel_args_copy(args);
   s->fd_handler = nullptr;
+  s->slice_allocator_factory = slice_allocator_factory;
   gpr_atm_no_barrier_store(&s->next_pollset_to_assign, 0);
   *server = s;
   return GRPC_ERROR_NONE;
@@ -115,17 +119,15 @@ static void finish_shutdown(grpc_tcp_server* s) {
     grpc_core::ExecCtx::Run(DEBUG_LOCATION, s->shutdown_complete,
                             GRPC_ERROR_NONE);
   }
-
   gpr_mu_destroy(&s->mu);
-
   while (s->head) {
     grpc_tcp_listener* sp = s->head;
     s->head = sp->next;
     gpr_free(sp);
   }
+  grpc_slice_allocator_factory_destroy(s->slice_allocator_factory);
   grpc_channel_args_destroy(s->channel_args);
   delete s->fd_handler;
-
   gpr_free(s);
 }
 
@@ -169,10 +171,8 @@ static void deactivated_all_ports(grpc_tcp_server* s) {
 
 static void tcp_server_destroy(grpc_tcp_server* s) {
   gpr_mu_lock(&s->mu);
-
   GPR_ASSERT(!s->shutdown);
   s->shutdown = true;
-
   /* shutdown all fd's */
   if (s->active_ports) {
     grpc_tcp_listener* sp;
@@ -267,10 +267,13 @@ static void on_read(void* arg, grpc_error_handle err) {
     acceptor->port_index = sp->port_index;
     acceptor->fd_index = sp->fd_index;
     acceptor->external_connection = false;
-
     sp->server->on_accept_cb(
         sp->server->on_accept_cb_arg,
-        grpc_tcp_create(fdobj, sp->server->channel_args, addr_str.c_str()),
+        grpc_tcp_create(fdobj, sp->server->channel_args, addr_str.c_str(),
+                        grpc_slice_allocator_factory_create_slice_allocator(
+                            sp->server->slice_allocator_factory,
+                            absl::StrCat("tcp_server_posix:", addr_str),
+                            sp->server->channel_args)),
         read_notifier_pollset, acceptor);
   }
 
@@ -613,9 +616,13 @@ class ExternalConnectionHandler : public grpc_core::TcpServerFdHandler {
     acceptor->external_connection = true;
     acceptor->listener_fd = listener_fd;
     acceptor->pending_data = buf;
-    s_->on_accept_cb(s_->on_accept_cb_arg,
-                     grpc_tcp_create(fdobj, s_->channel_args, addr_str.c_str()),
-                     read_notifier_pollset, acceptor);
+    s_->on_accept_cb(
+        s_->on_accept_cb_arg,
+        grpc_tcp_create(
+            fdobj, s_->channel_args, addr_str.c_str(),
+            grpc_slice_allocator_factory_create_slice_allocator(
+                s_->slice_allocator_factory, addr_str, s_->channel_args)),
+        read_notifier_pollset, acceptor);
   }
 
  private:
index ed4587a..6cce4c1 100644 (file)
@@ -94,6 +94,9 @@ struct grpc_tcp_server {
 
   /* a handler for external connections, owned */
   grpc_core::TcpServerFdHandler* fd_handler;
+
+  /* used to create slice allocators for endpoints, owned */
+  grpc_slice_allocator_factory* slice_allocator_factory;
 };
 
 /* If successful, add a listener to \a s for \a addr, set \a dsmode for the
index 2804cac..7501596 100644 (file)
@@ -22,8 +22,6 @@
 
 #ifdef GRPC_POSIX_SOCKET_TCP_SERVER_UTILS_COMMON
 
-#include "src/core/lib/iomgr/tcp_server_utils_posix.h"
-
 #include <errno.h>
 #include <limits.h>
 #include <stdio.h>
@@ -40,6 +38,7 @@
 #include "src/core/lib/address_utils/sockaddr_utils.h"
 #include "src/core/lib/iomgr/error.h"
 #include "src/core/lib/iomgr/sockaddr.h"
+#include "src/core/lib/iomgr/tcp_server_utils_posix.h"
 #include "src/core/lib/iomgr/unix_sockets_posix.h"
 
 #define MIN_SAFE_ACCEPT_QUEUE_SIZE 100
index a7e8f84..0a8cb7a 100644 (file)
@@ -22,8 +22,6 @@
 
 #ifdef GRPC_HAVE_IFADDRS
 
-#include "src/core/lib/iomgr/tcp_server_utils_posix.h"
-
 #include <errno.h>
 #include <ifaddrs.h>
 #include <stddef.h>
@@ -39,6 +37,7 @@
 #include "src/core/lib/address_utils/sockaddr_utils.h"
 #include "src/core/lib/iomgr/error.h"
 #include "src/core/lib/iomgr/sockaddr.h"
+#include "src/core/lib/iomgr/tcp_server_utils_posix.h"
 
 /* Return the listener in s with address addr or NULL. */
 static grpc_tcp_listener* find_listener_with_addr(grpc_tcp_server* s,
@@ -146,8 +145,8 @@ grpc_error_handle grpc_tcp_server_add_all_local_addrs(grpc_tcp_server* s,
     }
     if ((err = grpc_tcp_server_add_addr(s, &addr, port_index, fd_index, &dsmode,
                                         &new_sp)) != GRPC_ERROR_NONE) {
-      grpc_error_handle root_err = GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-          absl::StrCat("Failed to add listener: ", addr_str).c_str());
+      grpc_error_handle root_err = GRPC_ERROR_CREATE_FROM_CPP_STRING(
+          absl::StrCat("Failed to add listener: ", addr_str));
       err = grpc_error_add_child(root_err, err);
       break;
     } else {
index a9354b0..beaf489 100644 (file)
 
 #include "src/core/lib/iomgr/tcp_server_utils_posix.h"
 
-grpc_error_handle grpc_tcp_server_add_all_local_addrs(grpc_tcp_server* s,
-                                                      unsigned port_index,
-                                                      int requested_port,
-                                                      int* out_port) {
+grpc_error_handle grpc_tcp_server_add_all_local_addrs(grpc_tcp_server* /*s*/,
+                                                      unsigned /*port_index*/,
+                                                      int /*requested_port*/,
+                                                      int* /*out_port*/) {
   return GRPC_ERROR_CREATE_FROM_STATIC_STRING("no ifaddrs available");
 }
 
index 614ea35..80f4d35 100644 (file)
@@ -22,8 +22,6 @@
 
 #ifdef GRPC_WINSOCK_SOCKET
 
-#include "src/core/lib/iomgr/sockaddr.h"
-
 #include <inttypes.h>
 #include <io.h>
 
@@ -43,6 +41,7 @@
 #include "src/core/lib/iomgr/iocp_windows.h"
 #include "src/core/lib/iomgr/pollset_windows.h"
 #include "src/core/lib/iomgr/resolve_address.h"
+#include "src/core/lib/iomgr/sockaddr.h"
 #include "src/core/lib/iomgr/socket_windows.h"
 #include "src/core/lib/iomgr/tcp_server.h"
 #include "src/core/lib/iomgr/tcp_windows.h"
@@ -97,13 +96,15 @@ struct grpc_tcp_server {
   grpc_closure* shutdown_complete;
 
   grpc_channel_args* channel_args;
+  grpc_slice_allocator_factory* slice_allocator_factory;
 };
 
 /* Public function. Allocates the proper data structures to hold a
    grpc_tcp_server. */
-static grpc_error_handle tcp_server_create(grpc_closure* shutdown_complete,
-                                           const grpc_channel_args* args,
-                                           grpc_tcp_server** server) {
+static grpc_error_handle tcp_server_create(
+    grpc_closure* shutdown_complete, const grpc_channel_args* args,
+    grpc_slice_allocator_factory* slice_allocator_factory,
+    grpc_tcp_server** server) {
   grpc_tcp_server* s = (grpc_tcp_server*)gpr_malloc(sizeof(grpc_tcp_server));
   s->channel_args = grpc_channel_args_copy(args);
   gpr_ref_init(&s->refs, 1);
@@ -116,6 +117,7 @@ static grpc_error_handle tcp_server_create(grpc_closure* shutdown_complete,
   s->shutdown_starting.head = NULL;
   s->shutdown_starting.tail = NULL;
   s->shutdown_complete = shutdown_complete;
+  s->slice_allocator_factory = slice_allocator_factory;
   *server = s;
   return GRPC_ERROR_NONE;
 }
@@ -166,7 +168,7 @@ static void tcp_server_shutdown_starting_add(grpc_tcp_server* s,
 static void tcp_server_destroy(grpc_tcp_server* s) {
   grpc_tcp_listener* sp;
   gpr_mu_lock(&s->mu);
-
+  grpc_slice_allocator_factory_destroy(s->slice_allocator_factory);
   /* First, shutdown all fd's. This will queue abortion calls for all
      of the pending accepts due to the normal operation mechanism. */
   if (s->active_ports == 0) {
@@ -324,7 +326,6 @@ static void on_accept(void* arg, grpc_error_handle error) {
     gpr_mu_unlock(&sp->server->mu);
     return;
   }
-
   /* The IOCP notified us of a completed operation. Let's grab the results,
      and act accordingly. */
   transfered_bytes = 0;
@@ -358,8 +359,11 @@ static void on_accept(void* arg, grpc_error_handle error) {
         gpr_free(utf8_message);
       }
       std::string fd_name = absl::StrCat("tcp_server:", peer_name_string);
-      ep = grpc_tcp_create(grpc_winsocket_create(sock, fd_name.c_str()),
-                           sp->server->channel_args, peer_name_string.c_str());
+      ep = grpc_tcp_create(
+          grpc_winsocket_create(sock, fd_name.c_str()),
+          sp->server->channel_args, peer_name_string.c_str(),
+          grpc_slice_allocator_factory_create_slice_allocator(
+              sp->server->slice_allocator_factory, peer_name_string));
     } else {
       closesocket(sock);
     }
diff --git a/src/core/lib/iomgr/tcp_uv.cc b/src/core/lib/iomgr/tcp_uv.cc
deleted file mode 100644 (file)
index 8f64d22..0000000
+++ /dev/null
@@ -1,421 +0,0 @@
-/*
- *
- * Copyright 2016 gRPC authors.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- *
- */
-
-#include <grpc/support/port_platform.h>
-
-#include "src/core/lib/iomgr/port.h"
-
-#ifdef GRPC_UV
-#include <limits.h>
-#include <string.h>
-
-#include <grpc/slice_buffer.h>
-
-#include <grpc/support/alloc.h>
-#include <grpc/support/log.h>
-#include <grpc/support/string_util.h>
-
-#include "src/core/lib/gpr/string.h"
-#include "src/core/lib/iomgr/error.h"
-#include "src/core/lib/iomgr/iomgr_custom.h"
-#include "src/core/lib/iomgr/resolve_address_custom.h"
-#include "src/core/lib/iomgr/resource_quota.h"
-#include "src/core/lib/iomgr/tcp_custom.h"
-#include "src/core/lib/slice/slice_internal.h"
-#include "src/core/lib/slice/slice_string_helpers.h"
-
-#include <uv.h>
-
-#define IGNORE_CONST(addr) ((grpc_sockaddr*)(uintptr_t)(addr))
-
-typedef struct uv_socket_t {
-  uv_connect_t connect_req;
-  uv_write_t write_req;
-  uv_shutdown_t shutdown_req;
-  uv_tcp_t* handle;
-  uv_buf_t* write_buffers;
-
-  char* read_buf;
-  size_t read_len;
-
-  int pending_connections;
-  grpc_custom_socket* accept_socket;
-  grpc_error_handle accept_error;
-
-  grpc_custom_connect_callback connect_cb;
-  grpc_custom_write_callback write_cb;
-  grpc_custom_read_callback read_cb;
-  grpc_custom_accept_callback accept_cb;
-  grpc_custom_close_callback close_cb;
-
-} uv_socket_t;
-
-static grpc_error_handle tcp_error_create(const char* desc, int status) {
-  if (status == 0) {
-    return GRPC_ERROR_NONE;
-  }
-  grpc_error_handle error = GRPC_ERROR_CREATE_FROM_STATIC_STRING(desc);
-  /* All tcp errors are marked with UNAVAILABLE so that application may
-   * choose to retry. */
-  error = grpc_error_set_int(error, GRPC_ERROR_INT_GRPC_STATUS,
-                             GRPC_STATUS_UNAVAILABLE);
-  return grpc_error_set_str(error, GRPC_ERROR_STR_OS_ERROR,
-                            grpc_slice_from_static_string(uv_strerror(status)));
-}
-
-static void uv_socket_destroy(grpc_custom_socket* socket) {
-  uv_socket_t* uv_socket = (uv_socket_t*)socket->impl;
-  gpr_free(uv_socket->handle);
-  gpr_free(uv_socket);
-}
-
-static void alloc_uv_buf(uv_handle_t* handle, size_t suggested_size,
-                         uv_buf_t* buf) {
-  uv_socket_t* uv_socket =
-      (uv_socket_t*)((grpc_custom_socket*)handle->data)->impl;
-  (void)suggested_size;
-  buf->base = uv_socket->read_buf;
-  buf->len = uv_socket->read_len;
-}
-
-static void uv_read_callback(uv_stream_t* stream, ssize_t nread,
-                             const uv_buf_t* buf) {
-  grpc_error_handle error = GRPC_ERROR_NONE;
-  if (nread == 0) {
-    // Nothing happened. Wait for the next callback
-    return;
-  }
-  // TODO(murgatroid99): figure out what the return value here means
-  uv_read_stop(stream);
-  if (nread == UV_EOF) {
-    error = GRPC_ERROR_CREATE_FROM_STATIC_STRING("EOF");
-  } else if (nread < 0) {
-    error = tcp_error_create("TCP Read failed", nread);
-  }
-  grpc_custom_socket* socket = (grpc_custom_socket*)stream->data;
-  uv_socket_t* uv_socket = (uv_socket_t*)socket->impl;
-  uv_socket->read_cb(socket, (size_t)nread, error);
-}
-
-static void uv_close_callback(uv_handle_t* handle) {
-  grpc_custom_socket* socket = (grpc_custom_socket*)handle->data;
-  uv_socket_t* uv_socket = (uv_socket_t*)socket->impl;
-  if (uv_socket->accept_socket) {
-    uv_socket->accept_cb(socket, uv_socket->accept_socket,
-                         GRPC_ERROR_CREATE_FROM_STATIC_STRING("socket closed"));
-  }
-  uv_socket->close_cb(socket);
-}
-
-static void uv_socket_read(grpc_custom_socket* socket, char* buffer,
-                           size_t length, grpc_custom_read_callback read_cb) {
-  uv_socket_t* uv_socket = (uv_socket_t*)socket->impl;
-  int status;
-  grpc_error_handle error;
-  uv_socket->read_cb = read_cb;
-  uv_socket->read_buf = buffer;
-  uv_socket->read_len = length;
-  // TODO(murgatroid99): figure out what the return value here means
-  status =
-      uv_read_start((uv_stream_t*)uv_socket->handle, (uv_alloc_cb)alloc_uv_buf,
-                    (uv_read_cb)uv_read_callback);
-  if (status != 0) {
-    error = tcp_error_create("TCP Read failed at start", status);
-    uv_socket->read_cb(socket, 0, error);
-  }
-}
-
-static void uv_write_callback(uv_write_t* req, int status) {
-  grpc_custom_socket* socket = (grpc_custom_socket*)req->data;
-  uv_socket_t* uv_socket = (uv_socket_t*)socket->impl;
-  gpr_free(uv_socket->write_buffers);
-  uv_socket->write_cb(socket, tcp_error_create("TCP Write failed", status));
-}
-
-void uv_socket_write(grpc_custom_socket* socket,
-                     grpc_slice_buffer* write_slices,
-                     grpc_custom_write_callback write_cb) {
-  uv_socket_t* uv_socket = (uv_socket_t*)socket->impl;
-  uv_socket->write_cb = write_cb;
-  uv_buf_t* uv_buffers;
-  uv_write_t* write_req;
-
-  uv_buffers = (uv_buf_t*)gpr_malloc(sizeof(uv_buf_t) * write_slices->count);
-  for (size_t i = 0; i < write_slices->count; i++) {
-    uv_buffers[i].base = (char*)GRPC_SLICE_START_PTR(write_slices->slices[i]);
-    uv_buffers[i].len = GRPC_SLICE_LENGTH(write_slices->slices[i]);
-  }
-
-  uv_socket->write_buffers = uv_buffers;
-  write_req = &uv_socket->write_req;
-  write_req->data = socket;
-  // TODO(murgatroid99): figure out what the return value here means
-  uv_write(write_req, (uv_stream_t*)uv_socket->handle, uv_buffers,
-           write_slices->count, uv_write_callback);
-}
-
-static void shutdown_callback(uv_shutdown_t* req, int status) {}
-
-static void uv_socket_shutdown(grpc_custom_socket* socket) {
-  uv_socket_t* uv_socket = (uv_socket_t*)socket->impl;
-  uv_shutdown_t* req = &uv_socket->shutdown_req;
-  uv_shutdown(req, (uv_stream_t*)uv_socket->handle, shutdown_callback);
-}
-
-static void uv_socket_close(grpc_custom_socket* socket,
-                            grpc_custom_close_callback close_cb) {
-  uv_socket_t* uv_socket = (uv_socket_t*)socket->impl;
-  uv_socket->close_cb = close_cb;
-  uv_close((uv_handle_t*)uv_socket->handle, uv_close_callback);
-}
-
-static grpc_error_handle uv_socket_init_helper(uv_socket_t* uv_socket,
-                                               int domain) {
-  uv_tcp_t* tcp = (uv_tcp_t*)gpr_malloc(sizeof(uv_tcp_t));
-  uv_socket->handle = tcp;
-  int status = uv_tcp_init_ex(uv_default_loop(), tcp, (unsigned int)domain);
-  if (status != 0) {
-    return tcp_error_create("Failed to initialize UV tcp handle", status);
-  }
-#if defined(GPR_LINUX) && defined(SO_REUSEPORT)
-  if (domain == AF_INET || domain == AF_INET6) {
-    int enable = 1;
-    int fd;
-    uv_fileno((uv_handle_t*)tcp, &fd);
-    // TODO Handle error here.
-    setsockopt(fd, SOL_SOCKET, SO_REUSEPORT, &enable, sizeof(enable));
-  }
-#endif
-  uv_socket->write_buffers = nullptr;
-  uv_socket->read_len = 0;
-  uv_tcp_nodelay(uv_socket->handle, 1);
-  // Node uses a garbage collector to call destructors, so we don't
-  // want to hold the uv loop open with active gRPC objects.
-  uv_unref((uv_handle_t*)uv_socket->handle);
-  uv_socket->pending_connections = 0;
-  uv_socket->accept_socket = nullptr;
-  uv_socket->accept_error = GRPC_ERROR_NONE;
-  return GRPC_ERROR_NONE;
-}
-
-static grpc_error_handle uv_socket_init(grpc_custom_socket* socket,
-                                        int domain) {
-  uv_socket_t* uv_socket = (uv_socket_t*)gpr_malloc(sizeof(uv_socket_t));
-  grpc_error_handle error = uv_socket_init_helper(uv_socket, domain);
-  if (error != GRPC_ERROR_NONE) {
-    return error;
-  }
-  uv_socket->handle->data = socket;
-  socket->impl = uv_socket;
-  return GRPC_ERROR_NONE;
-}
-
-static grpc_error_handle uv_socket_getpeername(grpc_custom_socket* socket,
-                                               const grpc_sockaddr* addr,
-                                               int* addr_len) {
-  uv_socket_t* uv_socket = (uv_socket_t*)socket->impl;
-  int err = uv_tcp_getpeername(uv_socket->handle,
-                               (struct sockaddr*)IGNORE_CONST(addr), addr_len);
-  return tcp_error_create("getpeername failed", err);
-}
-
-static grpc_error_handle uv_socket_getsockname(grpc_custom_socket* socket,
-                                               const grpc_sockaddr* addr,
-                                               int* addr_len) {
-  uv_socket_t* uv_socket = (uv_socket_t*)socket->impl;
-  int err = uv_tcp_getsockname(uv_socket->handle,
-                               (struct sockaddr*)IGNORE_CONST(addr), addr_len);
-  return tcp_error_create("getsockname failed", err);
-}
-
-static void accept_new_connection(grpc_custom_socket* socket) {
-  uv_socket_t* uv_socket = (uv_socket_t*)socket->impl;
-  if (uv_socket->pending_connections == 0 || !uv_socket->accept_socket) {
-    return;
-  }
-  grpc_custom_socket* new_socket = uv_socket->accept_socket;
-  grpc_error_handle error = uv_socket->accept_error;
-  uv_socket->accept_socket = nullptr;
-  uv_socket->accept_error = GRPC_ERROR_NONE;
-  uv_socket->pending_connections -= 1;
-  if (uv_socket->accept_error != GRPC_ERROR_NONE) {
-    uv_stream_t phony_handle;
-    uv_accept((uv_stream_t*)uv_socket->handle, &phony_handle);
-    uv_socket->accept_cb(socket, new_socket, error);
-  } else {
-    uv_socket_t* uv_new_socket = (uv_socket_t*)gpr_malloc(sizeof(uv_socket_t));
-    uv_socket_init_helper(uv_new_socket, AF_UNSPEC);
-    // UV documentation says this is guaranteed to succeed
-    GPR_ASSERT(uv_accept((uv_stream_t*)uv_socket->handle,
-                         (uv_stream_t*)uv_new_socket->handle) == 0);
-    new_socket->impl = uv_new_socket;
-    uv_new_socket->handle->data = new_socket;
-    uv_socket->accept_cb(socket, new_socket, error);
-  }
-}
-
-static void uv_on_connect(uv_stream_t* server, int status) {
-  grpc_custom_socket* socket = (grpc_custom_socket*)server->data;
-  uv_socket_t* uv_socket = (uv_socket_t*)socket->impl;
-  if (status < 0) {
-    switch (status) {
-      case UV_EINTR:
-      case UV_EAGAIN:
-        return;
-      default:
-        uv_socket->accept_error = tcp_error_create("accept failed", status);
-    }
-  }
-  uv_socket->pending_connections += 1;
-  accept_new_connection(socket);
-}
-
-void uv_socket_accept(grpc_custom_socket* socket,
-                      grpc_custom_socket* new_socket,
-                      grpc_custom_accept_callback accept_cb) {
-  uv_socket_t* uv_socket = (uv_socket_t*)socket->impl;
-  uv_socket->accept_cb = accept_cb;
-  GPR_ASSERT(uv_socket->accept_socket == nullptr);
-  uv_socket->accept_socket = new_socket;
-  accept_new_connection(socket);
-}
-
-static grpc_error_handle uv_socket_bind(grpc_custom_socket* socket,
-                                        const grpc_sockaddr* addr, size_t len,
-                                        int flags) {
-  uv_socket_t* uv_socket = (uv_socket_t*)socket->impl;
-  int status =
-      uv_tcp_bind((uv_tcp_t*)uv_socket->handle, (struct sockaddr*)addr, 0);
-  return tcp_error_create("Failed to bind to port", status);
-}
-
-static grpc_error_handle uv_socket_listen(grpc_custom_socket* socket) {
-  uv_socket_t* uv_socket = (uv_socket_t*)socket->impl;
-  int status =
-      uv_listen((uv_stream_t*)uv_socket->handle, SOMAXCONN, uv_on_connect);
-  return tcp_error_create("Failed to listen to port", status);
-}
-
-static void uv_tc_on_connect(uv_connect_t* req, int status) {
-  grpc_custom_socket* socket = (grpc_custom_socket*)req->data;
-  uv_socket_t* uv_socket = (uv_socket_t*)socket->impl;
-  grpc_error_handle error;
-  if (status == UV_ECANCELED) {
-    // This should only happen if the handle is already closed
-    error = GRPC_ERROR_CREATE_FROM_STATIC_STRING("Timeout occurred");
-  } else {
-    error = tcp_error_create("Failed to connect to remote host", status);
-  }
-  uv_socket->connect_cb(socket, error);
-}
-
-static void uv_socket_connect(grpc_custom_socket* socket,
-                              const grpc_sockaddr* addr, size_t len,
-                              grpc_custom_connect_callback connect_cb) {
-  uv_socket_t* uv_socket = (uv_socket_t*)socket->impl;
-  uv_socket->connect_cb = connect_cb;
-  uv_socket->connect_req.data = socket;
-  int status = uv_tcp_connect(&uv_socket->connect_req, uv_socket->handle,
-                              (struct sockaddr*)addr, uv_tc_on_connect);
-  if (status != 0) {
-    // The callback will not be called
-    uv_socket->connect_cb(socket, tcp_error_create("connect failed", status));
-  }
-}
-
-static grpc_resolved_addresses* handle_addrinfo_result(
-    struct addrinfo* result) {
-  struct addrinfo* resp;
-  size_t i;
-  grpc_resolved_addresses* addresses =
-      (grpc_resolved_addresses*)gpr_malloc(sizeof(grpc_resolved_addresses));
-  addresses->naddrs = 0;
-  for (resp = result; resp != nullptr; resp = resp->ai_next) {
-    addresses->naddrs++;
-  }
-  addresses->addrs = (grpc_resolved_address*)gpr_malloc(
-      sizeof(grpc_resolved_address) * addresses->naddrs);
-  for (resp = result, i = 0; resp != nullptr; resp = resp->ai_next, i++) {
-    memcpy(&addresses->addrs[i].addr, resp->ai_addr, resp->ai_addrlen);
-    addresses->addrs[i].len = resp->ai_addrlen;
-  }
-  // addrinfo objects are allocated by libuv (e.g. in uv_getaddrinfo)
-  // and not by gpr_malloc
-  uv_freeaddrinfo(result);
-  return addresses;
-}
-
-static void uv_resolve_callback(uv_getaddrinfo_t* req, int status,
-                                struct addrinfo* res) {
-  grpc_custom_resolver* r = (grpc_custom_resolver*)req->data;
-  gpr_free(req);
-  grpc_resolved_addresses* result = nullptr;
-  if (status == 0) {
-    result = handle_addrinfo_result(res);
-  }
-  grpc_custom_resolve_callback(r, result,
-                               tcp_error_create("getaddrinfo failed", status));
-}
-
-static grpc_error_handle uv_resolve(const char* host, const char* port,
-                                    grpc_resolved_addresses** result) {
-  int status;
-  uv_getaddrinfo_t req;
-  struct addrinfo hints;
-  memset(&hints, 0, sizeof(struct addrinfo));
-  hints.ai_family = AF_UNSPEC;     /* ipv4 or ipv6 */
-  hints.ai_socktype = SOCK_STREAM; /* stream socket */
-  hints.ai_flags = AI_PASSIVE;     /* for wildcard IP address */
-  status = uv_getaddrinfo(uv_default_loop(), &req, NULL, host, port, &hints);
-  if (status != 0) {
-    *result = nullptr;
-  } else {
-    *result = handle_addrinfo_result(req.addrinfo);
-  }
-  return tcp_error_create("getaddrinfo failed", status);
-}
-
-static void uv_resolve_async(grpc_custom_resolver* r, const char* host,
-                             const char* port) {
-  int status;
-  uv_getaddrinfo_t* req =
-      (uv_getaddrinfo_t*)gpr_malloc(sizeof(uv_getaddrinfo_t));
-  req->data = r;
-  struct addrinfo hints;
-  memset(&hints, 0, sizeof(struct addrinfo));
-  hints.ai_family = GRPC_AF_UNSPEC;     /* ipv4 or ipv6 */
-  hints.ai_socktype = GRPC_SOCK_STREAM; /* stream socket */
-  hints.ai_flags = GRPC_AI_PASSIVE;     /* for wildcard IP address */
-  status = uv_getaddrinfo(uv_default_loop(), req, uv_resolve_callback, host,
-                          port, &hints);
-  if (status != 0) {
-    gpr_free(req);
-    grpc_error_handle error = tcp_error_create("getaddrinfo failed", status);
-    grpc_custom_resolve_callback(r, NULL, error);
-  }
-}
-
-grpc_custom_resolver_vtable uv_resolver_vtable = {uv_resolve, uv_resolve_async};
-
-grpc_socket_vtable grpc_uv_socket_vtable = {
-    uv_socket_init,     uv_socket_connect,     uv_socket_destroy,
-    uv_socket_shutdown, uv_socket_close,       uv_socket_write,
-    uv_socket_read,     uv_socket_getpeername, uv_socket_getsockname,
-    uv_socket_bind,     uv_socket_listen,      uv_socket_accept};
-
-#endif
index aa693cc..d0bca6b 100644 (file)
@@ -24,8 +24,6 @@
 
 #include <limits.h>
 
-#include "src/core/lib/iomgr/sockaddr_windows.h"
-
 #include <grpc/slice_buffer.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
@@ -36,6 +34,7 @@
 #include "src/core/lib/gpr/useful.h"
 #include "src/core/lib/iomgr/iocp_windows.h"
 #include "src/core/lib/iomgr/sockaddr.h"
+#include "src/core/lib/iomgr/sockaddr_windows.h"
 #include "src/core/lib/iomgr/socket_windows.h"
 #include "src/core/lib/iomgr/tcp_client.h"
 #include "src/core/lib/iomgr/tcp_windows.h"
@@ -117,7 +116,7 @@ typedef struct grpc_tcp {
   grpc_slice_buffer* write_slices;
   grpc_slice_buffer* read_slices;
 
-  grpc_resource_user* resource_user;
+  grpc_slice_allocator* slice_allocator;
 
   /* The IO Completion Port runs from another thread. We need some mechanism
      to protect ourselves when requesting a shutdown. */
@@ -133,7 +132,7 @@ static void tcp_free(grpc_tcp* tcp) {
   grpc_winsocket_destroy(tcp->socket);
   gpr_mu_destroy(&tcp->mu);
   grpc_slice_buffer_destroy_internal(&tcp->last_read_buffer);
-  grpc_resource_user_unref(tcp->resource_user);
+  grpc_slice_allocator_destroy(tcp->slice_allocator);
   if (tcp->shutting_down) GRPC_ERROR_UNREF(tcp->shutdown_error);
   delete tcp;
 }
@@ -467,7 +466,6 @@ static void win_shutdown(grpc_endpoint* ep, grpc_error_handle why) {
   }
   grpc_winsocket_shutdown(tcp->socket);
   gpr_mu_unlock(&tcp->mu);
-  grpc_resource_user_shutdown(tcp->resource_user);
 }
 
 static void win_destroy(grpc_endpoint* ep) {
@@ -486,11 +484,6 @@ static absl::string_view win_get_local_address(grpc_endpoint* ep) {
   return tcp->local_address;
 }
 
-static grpc_resource_user* win_get_resource_user(grpc_endpoint* ep) {
-  grpc_tcp* tcp = (grpc_tcp*)ep;
-  return tcp->resource_user;
-}
-
 static int win_get_fd(grpc_endpoint* ep) { return -1; }
 
 static bool win_can_track_err(grpc_endpoint* ep) { return false; }
@@ -502,7 +495,6 @@ static grpc_endpoint_vtable vtable = {win_read,
                                       win_delete_from_pollset_set,
                                       win_shutdown,
                                       win_destroy,
-                                      win_get_resource_user,
                                       win_get_peer,
                                       win_get_local_address,
                                       win_get_fd,
@@ -510,17 +502,8 @@ static grpc_endpoint_vtable vtable = {win_read,
 
 grpc_endpoint* grpc_tcp_create(grpc_winsocket* socket,
                                grpc_channel_args* channel_args,
-                               const char* peer_string) {
-  grpc_resource_quota* resource_quota = grpc_resource_quota_create(NULL);
-  if (channel_args != NULL) {
-    for (size_t i = 0; i < channel_args->num_args; i++) {
-      if (0 == strcmp(channel_args->args[i].key, GRPC_ARG_RESOURCE_QUOTA)) {
-        grpc_resource_quota_unref_internal(resource_quota);
-        resource_quota = grpc_resource_quota_ref_internal(
-            (grpc_resource_quota*)channel_args->args[i].value.pointer.p);
-      }
-    }
-  }
+                               const char* peer_string,
+                               grpc_slice_allocator* slice_allocator) {
   grpc_tcp* tcp = new grpc_tcp;
   memset(tcp, 0, sizeof(grpc_tcp));
   tcp->base.vtable = &vtable;
@@ -540,9 +523,7 @@ grpc_endpoint* grpc_tcp_create(grpc_winsocket* socket,
   }
   tcp->peer_string = peer_string;
   grpc_slice_buffer_init(&tcp->last_read_buffer);
-  tcp->resource_user = grpc_resource_user_create(resource_quota, peer_string);
-  grpc_resource_quota_unref_internal(resource_quota);
-
+  tcp->slice_allocator = slice_allocator;
   return &tcp->base;
 }
 
index de3dc55..ca43704 100644 (file)
@@ -42,7 +42,8 @@
  */
 grpc_endpoint* grpc_tcp_create(grpc_winsocket* socket,
                                grpc_channel_args* channel_args,
-                               const char* peer_string);
+                               const char* peer_string,
+                               grpc_slice_allocator* slice_allocator);
 
 grpc_error_handle grpc_tcp_prepare_socket(SOCKET sock);
 
index e647cde..6506d30 100644 (file)
@@ -19,6 +19,7 @@
 #include <grpc/support/port_platform.h>
 
 #include "src/core/lib/iomgr/timer.h"
+
 #include "src/core/lib/iomgr/timer_manager.h"
 
 grpc_timer_vtable* grpc_timer_impl;
index 5b55950..492d2a5 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include "src/core/lib/iomgr/port.h"
-
 #include <grpc/event_engine/event_engine.h>
 #include <grpc/support/time.h>
 
 #include "src/core/lib/iomgr/exec_ctx.h"
 #include "src/core/lib/iomgr/iomgr.h"
+#include "src/core/lib/iomgr/port.h"
 
 typedef struct grpc_timer {
   grpc_millis deadline;
index cb01b7c..9062966 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include "src/core/lib/iomgr/port.h"
+#include "src/core/lib/iomgr/timer_custom.h"
 
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 
 #include "src/core/lib/debug/trace.h"
 #include "src/core/lib/iomgr/iomgr_custom.h"
+#include "src/core/lib/iomgr/port.h"
 #include "src/core/lib/iomgr/timer.h"
-#include "src/core/lib/iomgr/timer_custom.h"
 
 static grpc_custom_timer_vtable* custom_timer_impl;
 
index 3d2fc00..109de1b 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include "src/core/lib/iomgr/port.h"
-
 #include <inttypes.h>
 
 #include <string>
 
 #include "absl/strings/str_cat.h"
 
-#include "src/core/lib/iomgr/timer.h"
-
 #include <grpc/support/alloc.h>
 #include <grpc/support/cpu.h>
 #include <grpc/support/log.h>
@@ -38,7 +34,9 @@
 #include "src/core/lib/gpr/tls.h"
 #include "src/core/lib/gpr/useful.h"
 #include "src/core/lib/iomgr/exec_ctx.h"
+#include "src/core/lib/iomgr/port.h"
 #include "src/core/lib/iomgr/time_averaged_stats.h"
+#include "src/core/lib/iomgr/timer.h"
 #include "src/core/lib/iomgr/timer_heap.h"
 
 #define INVALID_HEAP_INDEX 0xffffffffu
@@ -212,19 +210,11 @@ static void validate_non_pending_timer(grpc_timer* t) {
 
 #endif
 
-#if GPR_ARCH_64
-/* NOTE: TODO(sreek) - Currently the thread local storage support in grpc is
-   for intptr_t which means on 32-bit machines it is not wide enough to hold
-   grpc_millis which is 64-bit. Adding thread local support for 64 bit values
-   is a lot of work for very little gain. So we are currently restricting this
-   optimization to only 64 bit machines */
-
 /* Thread local variable that stores the deadline of the next timer the thread
  * has last-seen. This is an optimization to prevent the thread from checking
  * shared_mutables.min_timer (which requires acquiring shared_mutables.mu lock,
  * an expensive operation) */
-GPR_TLS_DECL(g_last_seen_min_timer);
-#endif
+static GPR_THREAD_LOCAL(grpc_millis) g_last_seen_min_timer;
 
 struct shared_mutables {
   /* The deadline of the next timer due across all timer shards */
@@ -269,10 +259,7 @@ static void timer_list_init() {
   gpr_mu_init(&g_shared_mutables.mu);
   g_shared_mutables.min_timer = grpc_core::ExecCtx::Get()->Now();
 
-#if GPR_ARCH_64
-  gpr_tls_init(&g_last_seen_min_timer);
-  gpr_tls_set(&g_last_seen_min_timer, 0);
-#endif
+  g_last_seen_min_timer = 0;
 
   for (i = 0; i < g_num_shards; i++) {
     timer_shard* shard = &g_shards[i];
@@ -301,11 +288,6 @@ static void timer_list_shutdown() {
     grpc_timer_heap_destroy(&shard->heap);
   }
   gpr_mu_destroy(&g_shared_mutables.mu);
-
-#if GPR_ARCH_64
-  gpr_tls_destroy(&g_last_seen_min_timer);
-#endif
-
   gpr_free(g_shards);
   gpr_free(g_shard_queue);
   g_shared_mutables.initialized = false;
@@ -452,10 +434,8 @@ static void timer_init(grpc_timer* timer, grpc_millis deadline,
 }
 
 static void timer_consume_kick(void) {
-#if GPR_ARCH_64
   /* Force re-evaluation of last seen min */
-  gpr_tls_set(&g_last_seen_min_timer, 0);
-#endif
+  g_last_seen_min_timer = 0;
 }
 
 static void timer_cancel(grpc_timer* timer) {
@@ -592,7 +572,6 @@ static grpc_timer_check_result run_some_expired_timers(
   // safe since we know that both are pointer types and 64-bit wide
   grpc_millis min_timer = static_cast<grpc_millis>(
       gpr_atm_no_barrier_load((gpr_atm*)(&g_shared_mutables.min_timer)));
-  gpr_tls_set(&g_last_seen_min_timer, min_timer);
 #else
   // On 32-bit systems, gpr_atm_no_barrier_load does not work on 64-bit types
   // (like grpc_millis). So all reads and writes to g_shared_mutables.min_timer
@@ -601,6 +580,8 @@ static grpc_timer_check_result run_some_expired_timers(
   grpc_millis min_timer = g_shared_mutables.min_timer;
   gpr_mu_unlock(&g_shared_mutables.mu);
 #endif
+  g_last_seen_min_timer = min_timer;
+
   if (now < min_timer) {
     if (next != nullptr) *next = GPR_MIN(*next, min_timer);
     return GRPC_TIMERS_CHECKED_AND_EMPTY;
@@ -676,20 +657,9 @@ static grpc_timer_check_result timer_check(grpc_millis* next) {
   // prelude
   grpc_millis now = grpc_core::ExecCtx::Get()->Now();
 
-#if GPR_ARCH_64
   /* fetch from a thread-local first: this avoids contention on a globally
      mutable cacheline in the common case */
-  grpc_millis min_timer = gpr_tls_get(&g_last_seen_min_timer);
-#else
-  // On 32-bit systems, we currently do not have thread local support for 64-bit
-  // types. In this case, directly read from g_shared_mutables.min_timer.
-  // Also, note that on 32-bit systems, gpr_atm_no_barrier_store does not work
-  // on 64-bit types (like grpc_millis). So all reads and writes to
-  // g_shared_mutables.min_timer are done under g_shared_mutables.mu
-  gpr_mu_lock(&g_shared_mutables.mu);
-  grpc_millis min_timer = g_shared_mutables.min_timer;
-  gpr_mu_unlock(&g_shared_mutables.mu);
-#endif
+  grpc_millis min_timer = g_last_seen_min_timer;
 
   if (now < min_timer) {
     if (next != nullptr) {
index 97a4513..2ac002b 100644 (file)
@@ -22,6 +22,7 @@
 #include <grpc/support/port_platform.h>
 
 #include <grpc/support/time.h>
+
 #include "src/core/lib/iomgr/exec_ctx.h"
 
 struct grpc_timer {
index 2c6a599..5c53fad 100644 (file)
@@ -18,8 +18,6 @@
 
 #include <grpc/support/port_platform.h>
 
-#include "src/core/lib/iomgr/port.h"
-
 #include "src/core/lib/iomgr/timer_heap.h"
 
 #include <string.h>
@@ -27,6 +25,7 @@
 #include <grpc/support/alloc.h>
 
 #include "src/core/lib/gpr/useful.h"
+#include "src/core/lib/iomgr/port.h"
 
 /* Adjusts a heap so as to move a hole at position i closer to the root,
    until a suitable position is found for element t. Then, copies t into that
diff --git a/src/core/lib/iomgr/timer_uv.cc b/src/core/lib/iomgr/timer_uv.cc
deleted file mode 100644 (file)
index 8b7c82e..0000000
+++ /dev/null
@@ -1,66 +0,0 @@
-/*
- *
- * Copyright 2016 gRPC authors.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- *
- */
-
-#include <grpc/support/port_platform.h>
-
-#include "src/core/lib/iomgr/port.h"
-
-#ifdef GRPC_UV
-
-#include <grpc/support/alloc.h>
-#include <grpc/support/log.h>
-
-#include "src/core/lib/debug/trace.h"
-#include "src/core/lib/iomgr/iomgr_custom.h"
-#include "src/core/lib/iomgr/timer.h"
-#include "src/core/lib/iomgr/timer_custom.h"
-
-#include <uv.h>
-
-static void timer_close_callback(uv_handle_t* handle) { gpr_free(handle); }
-
-static void stop_uv_timer(uv_timer_t* handle) {
-  uv_timer_stop(handle);
-  uv_unref((uv_handle_t*)handle);
-  uv_close((uv_handle_t*)handle, timer_close_callback);
-}
-
-void run_expired_timer(uv_timer_t* handle) {
-  grpc_custom_timer* timer_wrapper = (grpc_custom_timer*)handle->data;
-  grpc_custom_timer_callback(timer_wrapper, GRPC_ERROR_NONE);
-}
-
-static void timer_start(grpc_custom_timer* t) {
-  uv_timer_t* uv_timer;
-  uv_timer = (uv_timer_t*)gpr_malloc(sizeof(uv_timer_t));
-  uv_timer_init(uv_default_loop(), uv_timer);
-  uv_timer->data = t;
-  t->timer = (void*)uv_timer;
-  uv_timer_start(uv_timer, run_expired_timer, t->timeout_ms, 0);
-  // Node uses a garbage collector to call destructors, so we don't
-  // want to hold the uv loop open with active gRPC objects.
-  uv_unref((uv_handle_t*)uv_timer);
-}
-
-static void timer_stop(grpc_custom_timer* t) {
-  stop_uv_timer((uv_timer_t*)t->timer);
-}
-
-grpc_custom_timer_vtable uv_timer_vtable = {timer_start, timer_stop};
-
-#endif
index 4efaf23..653e78e 100644 (file)
@@ -31,8 +31,6 @@
 
 #ifdef GRPC_POSIX_SOCKET_UDP_SERVER
 
-#include "src/core/lib/iomgr/udp_server.h"
-
 #include <errno.h>
 #include <fcntl.h>
 #include <limits.h>
@@ -68,6 +66,7 @@
 #include "src/core/lib/iomgr/sockaddr.h"
 #include "src/core/lib/iomgr/socket_factory_posix.h"
 #include "src/core/lib/iomgr/socket_utils_posix.h"
+#include "src/core/lib/iomgr/udp_server.h"
 #include "src/core/lib/iomgr/unix_sockets_posix.h"
 
 /* A listener which implements basic features of Listening on a port for
index 2b077a3..0154831 100644 (file)
@@ -21,8 +21,6 @@
 
 #ifdef GRPC_HAVE_UNIX_SOCKET
 
-#include "src/core/lib/iomgr/sockaddr.h"
-
 #include <string.h>
 #include <sys/stat.h>
 #include <sys/types.h>
 
 #include "absl/strings/str_cat.h"
 
-#include "src/core/lib/address_utils/parse_address.h"
-#include "src/core/lib/iomgr/unix_sockets_posix.h"
-
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 
+#include "src/core/lib/address_utils/parse_address.h"
 #include "src/core/lib/gpr/useful.h"
+#include "src/core/lib/iomgr/sockaddr.h"
+#include "src/core/lib/iomgr/unix_sockets_posix.h"
 
 void grpc_create_socketpair_if_unix(int sv[2]) {
   GPR_ASSERT(socketpair(AF_UNIX, SOCK_STREAM, 0, sv) == 0);
index c35423b..f0e5d44 100644 (file)
 
 #include <string>
 
-#include "src/core/lib/iomgr/port.h"
+#include "absl/strings/string_view.h"
 
 #include <grpc/support/string_util.h>
 
+#include "src/core/lib/iomgr/port.h"
 #include "src/core/lib/iomgr/resolve_address.h"
 
-#include "absl/strings/string_view.h"
-
 void grpc_create_socketpair_if_unix(int sv[2]);
 
 grpc_error_handle grpc_resolve_unix_domain_address(
index b156575..aff61ea 100644 (file)
@@ -28,6 +28,7 @@
 #ifdef GRPC_POSIX_NO_SPECIAL_WAKEUP_FD
 
 #include <stddef.h>
+
 #include "src/core/lib/iomgr/wakeup_fd_posix.h"
 
 static int check_availability_invalid(void) { return 0; }
index 943d9d5..e25a944 100644 (file)
@@ -22,9 +22,6 @@
 
 #ifdef GRPC_POSIX_WAKEUP_FD
 
-#include "src/core/lib/iomgr/wakeup_fd_pipe.h"
-#include "src/core/lib/iomgr/wakeup_fd_posix.h"
-
 #include <errno.h>
 #include <string.h>
 #include <unistd.h>
@@ -32,6 +29,8 @@
 #include <grpc/support/log.h>
 
 #include "src/core/lib/iomgr/socket_utils_posix.h"
+#include "src/core/lib/iomgr/wakeup_fd_pipe.h"
+#include "src/core/lib/iomgr/wakeup_fd_posix.h"
 
 static grpc_error_handle pipe_init(grpc_wakeup_fd* fd_info) {
   int pipefd[2];
index 36b497b..89bd51b 100644 (file)
@@ -23,6 +23,7 @@
 #ifdef GRPC_POSIX_WAKEUP_FD
 
 #include <stddef.h>
+
 #include "src/core/lib/iomgr/wakeup_fd_pipe.h"
 #include "src/core/lib/iomgr/wakeup_fd_posix.h"
 
index db573e3..92a711d 100644 (file)
@@ -45,7 +45,7 @@ class WorkSerializer::WorkSerializerImpl : public Orphanable {
 
   // An initial size of 1 keeps track of whether the work serializer has been
   // orphaned.
-  Atomic<size_t> size_{1};
+  std::atomic<size_t> size_{1};
   MultiProducerSingleConsumerQueue queue_;
 };
 
@@ -55,7 +55,7 @@ void WorkSerializer::WorkSerializerImpl::Run(
     gpr_log(GPR_INFO, "WorkSerializer::Run() %p Scheduling callback [%s:%d]",
             this, location.file(), location.line());
   }
-  const size_t prev_size = size_.FetchAdd(1);
+  const size_t prev_size = size_.fetch_add(1);
   // The work serializer should not have been orphaned.
   GPR_DEBUG_ASSERT(prev_size > 0);
   if (prev_size == 1) {
@@ -83,7 +83,7 @@ void WorkSerializer::WorkSerializerImpl::Orphan() {
   if (GRPC_TRACE_FLAG_ENABLED(grpc_work_serializer_trace)) {
     gpr_log(GPR_INFO, "WorkSerializer::Orphan() %p", this);
   }
-  size_t prev_size = size_.FetchSub(1);
+  size_t prev_size = size_.fetch_sub(1);
   if (prev_size == 1) {
     if (GRPC_TRACE_FLAG_ENABLED(grpc_work_serializer_trace)) {
       gpr_log(GPR_INFO, "  Destroying");
@@ -101,7 +101,7 @@ void WorkSerializer::WorkSerializerImpl::DrainQueue() {
     if (GRPC_TRACE_FLAG_ENABLED(grpc_work_serializer_trace)) {
       gpr_log(GPR_INFO, "WorkSerializer::DrainQueue() %p", this);
     }
-    size_t prev_size = size_.FetchSub(1);
+    size_t prev_size = size_.fetch_sub(1);
     GPR_DEBUG_ASSERT(prev_size >= 1);
     // It is possible that while draining the queue, one of the callbacks ended
     // up orphaning the work serializer. In that case, delete the object.
index 547b80c..78debea 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
+#include <atomic>
 #include <functional>
 
 #include "absl/synchronization/mutex.h"
 
 #include "src/core/lib/debug/trace.h"
-#include "src/core/lib/gprpp/atomic.h"
 #include "src/core/lib/gprpp/debug_location.h"
 #include "src/core/lib/gprpp/mpscq.h"
 #include "src/core/lib/gprpp/orphanable.h"
index 295970f..b8425f2 100644 (file)
@@ -180,10 +180,9 @@ Json* JsonReader::CreateAndLinkValue() {
         if (errors_.size() == GRPC_JSON_MAX_ERRORS) {
           truncated_errors_ = true;
         } else {
-          errors_.push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
+          errors_.push_back(GRPC_ERROR_CREATE_FROM_CPP_STRING(
               absl::StrFormat("duplicate key \"%s\" at index %" PRIuPTR, key_,
-                              CurrentIndex())
-                  .c_str()));
+                              CurrentIndex())));
         }
       }
       value = &(*parent->mutable_object())[std::move(key_)];
@@ -201,10 +200,9 @@ bool JsonReader::StartContainer(Json::Type type) {
     if (errors_.size() == GRPC_JSON_MAX_ERRORS) {
       truncated_errors_ = true;
     } else {
-      errors_.push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
+      errors_.push_back(GRPC_ERROR_CREATE_FROM_CPP_STRING(
           absl::StrFormat("exceeded max stack depth (%d) at index %" PRIuPTR,
-                          GRPC_JSON_MAX_DEPTH, CurrentIndex())
-              .c_str()));
+                          GRPC_JSON_MAX_DEPTH, CurrentIndex())));
     }
     return false;
   }
@@ -279,10 +277,8 @@ JsonReader::Status JsonReader::Run() {
       case GRPC_JSON_READ_CHAR_EOF:
         if (IsComplete()) {
           return Status::GRPC_JSON_DONE;
-        } else {
-          return Status::GRPC_JSON_PARSE_ERROR;
         }
-        break;
+        return Status::GRPC_JSON_PARSE_ERROR;
 
       /* Processing whitespaces. */
       case ' ':
@@ -341,7 +337,6 @@ JsonReader::Status JsonReader::Run() {
             } else if (c == '}' &&
                        stack_.back()->type() != Json::Type::OBJECT) {
               return Status::GRPC_JSON_PARSE_ERROR;
-              return Status::GRPC_JSON_PARSE_ERROR;
             } else if (c == ']' && stack_.back()->type() != Json::Type::ARRAY) {
               return Status::GRPC_JSON_PARSE_ERROR;
             }
@@ -829,14 +824,11 @@ grpc_error_handle JsonReader::Parse(absl::string_view input, Json* output) {
         "errors and try again to see additional errors"));
   }
   if (status == Status::GRPC_JSON_INTERNAL_ERROR) {
-    reader.errors_.push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-        absl::StrCat("internal error in JSON parser at index ",
-                     reader.CurrentIndex())
-            .c_str()));
+    reader.errors_.push_back(GRPC_ERROR_CREATE_FROM_CPP_STRING(absl::StrCat(
+        "internal error in JSON parser at index ", reader.CurrentIndex())));
   } else if (status == Status::GRPC_JSON_PARSE_ERROR) {
-    reader.errors_.push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-        absl::StrCat("JSON parse error at index ", reader.CurrentIndex())
-            .c_str()));
+    reader.errors_.push_back(GRPC_ERROR_CREATE_FROM_CPP_STRING(
+        absl::StrCat("JSON parse error at index ", reader.CurrentIndex())));
   }
   if (!reader.errors_.empty()) {
     return GRPC_ERROR_CREATE_FROM_VECTOR("JSON parsing failed",
index 00a96eb..f77febd 100644 (file)
@@ -46,14 +46,13 @@ inline bool ExtractJsonNumber(const Json& json, const std::string& field_name,
                               ErrorVectorType* error_list) {
   static_assert(std::is_integral<NumericType>::value, "Integral required");
   if (json.type() != Json::Type::NUMBER) {
-    error_list->push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-        absl::StrCat("field:", field_name, " error:type should be NUMBER")
-            .c_str()));
+    error_list->push_back(GRPC_ERROR_CREATE_FROM_CPP_STRING(
+        absl::StrCat("field:", field_name, " error:type should be NUMBER")));
     return false;
   }
   if (!absl::SimpleAtoi(json.string_value(), output)) {
-    error_list->push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-        absl::StrCat("field:", field_name, " error:failed to parse.").c_str()));
+    error_list->push_back(GRPC_ERROR_CREATE_FROM_CPP_STRING(
+        absl::StrCat("field:", field_name, " error:failed to parse.")));
     return false;
   }
   return true;
@@ -70,9 +69,8 @@ inline bool ExtractJsonBool(const Json& json, const std::string& field_name,
       *output = false;
       return true;
     default:
-      error_list->push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-          absl::StrCat("field:", field_name, " error:type should be BOOLEAN")
-              .c_str()));
+      error_list->push_back(GRPC_ERROR_CREATE_FROM_CPP_STRING(
+          absl::StrCat("field:", field_name, " error:type should be BOOLEAN")));
       return false;
   }
 }
@@ -83,9 +81,8 @@ inline bool ExtractJsonString(const Json& json, const std::string& field_name,
                               ErrorVectorType* error_list) {
   if (json.type() != Json::Type::STRING) {
     *output = "";
-    error_list->push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-        absl::StrCat("field:", field_name, " error:type should be STRING")
-            .c_str()));
+    error_list->push_back(GRPC_ERROR_CREATE_FROM_CPP_STRING(
+        absl::StrCat("field:", field_name, " error:type should be STRING")));
     return false;
   }
   *output = json.string_value();
@@ -98,9 +95,8 @@ inline bool ExtractJsonArray(const Json& json, const std::string& field_name,
                              ErrorVectorType* error_list) {
   if (json.type() != Json::Type::ARRAY) {
     *output = nullptr;
-    error_list->push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-        absl::StrCat("field:", field_name, " error:type should be ARRAY")
-            .c_str()));
+    error_list->push_back(GRPC_ERROR_CREATE_FROM_CPP_STRING(
+        absl::StrCat("field:", field_name, " error:type should be ARRAY")));
     return false;
   }
   *output = &json.array_value();
@@ -113,9 +109,8 @@ inline bool ExtractJsonObject(const Json& json, const std::string& field_name,
                               ErrorVectorType* error_list) {
   if (json.type() != Json::Type::OBJECT) {
     *output = nullptr;
-    error_list->push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-        absl::StrCat("field:", field_name, " error:type should be OBJECT")
-            .c_str()));
+    error_list->push_back(GRPC_ERROR_CREATE_FROM_CPP_STRING(
+        absl::StrCat("field:", field_name, " error:type should be OBJECT")));
     return false;
   }
   *output = &json.object_value();
@@ -162,9 +157,8 @@ inline bool ParseJsonObjectField(const Json::Object& object,
   auto it = object.find(field_name);
   if (it == object.end()) {
     if (required) {
-      error_list->push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-          absl::StrCat("field:", field_name, " error:does not exist.")
-              .c_str()));
+      error_list->push_back(GRPC_ERROR_CREATE_FROM_CPP_STRING(
+          absl::StrCat("field:", field_name, " error:does not exist.")));
     }
     return false;
   }
@@ -181,19 +175,17 @@ inline bool ParseJsonObjectFieldAsDuration(const Json::Object& object,
   auto it = object.find(field_name);
   if (it == object.end()) {
     if (required) {
-      error_list->push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-          absl::StrCat("field:", field_name, " error:does not exist.")
-              .c_str()));
+      error_list->push_back(GRPC_ERROR_CREATE_FROM_CPP_STRING(
+          absl::StrCat("field:", field_name, " error:does not exist.")));
     }
     return false;
   }
   if (!ParseDurationFromJson(it->second, output)) {
     *output = GRPC_MILLIS_INF_PAST;
-    error_list->push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
+    error_list->push_back(GRPC_ERROR_CREATE_FROM_CPP_STRING(
         absl::StrCat("field:", field_name,
                      " error:type should be STRING of the form given by "
-                     "google.proto.Duration.")
-            .c_str()));
+                     "google.proto.Duration.")));
     return false;
   }
   return true;
index fa17b41..9889d68 100644 (file)
@@ -23,7 +23,6 @@
 #include "absl/status/statusor.h"
 #include "absl/strings/string_view.h"
 #include "absl/types/optional.h"
-
 #include "re2/re2.h"
 
 namespace grpc_core {
index 2056940..f98624b 100644 (file)
 
 #ifdef GRPC_BASIC_PROFILER
 
-#include <grpc/support/alloc.h>
-#include <grpc/support/log.h>
-#include <grpc/support/sync.h>
-#include <grpc/support/time.h>
 #include <inttypes.h>
 #include <pthread.h>
 #include <stdio.h>
 #include <string.h>
 
+#include <grpc/support/alloc.h>
+#include <grpc/support/log.h>
+#include <grpc/support/sync.h>
+#include <grpc/support/time.h>
+
+#include "src/core/lib/gpr/tls.h"
 #include "src/core/lib/gprpp/global_config.h"
 #include "src/core/lib/profiling/timers.h"
 
@@ -61,7 +63,7 @@ typedef struct gpr_timer_log_list {
   gpr_timer_log* tail;
 } gpr_timer_log_list;
 
-static __thread gpr_timer_log* g_thread_log;
+static GPR_THREAD_LOCAL(gpr_timer_log*) g_thread_log;
 static gpr_once g_once_init = GPR_ONCE_INIT;
 static FILE* output_file;
 static const char* output_filename_or_null = NULL;
@@ -71,7 +73,7 @@ static gpr_timer_log_list g_in_progress_logs;
 static gpr_timer_log_list g_done_logs;
 static int g_shutdown;
 static pthread_t g_writing_thread;
-static __thread int g_thread_id;
+static GPR_THREAD_LOCAL(int) g_thread_id;
 static int g_next_thread_id;
 static int g_writing_enabled = 1;
 
index 5ee1c43..a00dbaf 100644 (file)
@@ -20,9 +20,9 @@
 
 #ifdef GRPC_STAP_PROFILER
 
-#include "src/core/lib/profiling/timers.h"
-
 #include <sys/sdt.h>
+
+#include "src/core/lib/profiling/timers.h"
 /* Generated from src/core/profiling/stap_probes.d */
 #include "src/core/lib/profiling/stap_probes.h"
 
diff --git a/src/core/lib/promise/activity.cc b/src/core/lib/promise/activity.cc
new file mode 100644 (file)
index 0000000..a8d4715
--- /dev/null
@@ -0,0 +1,114 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#include <grpc/impl/codegen/port_platform.h>
+
+#include "src/core/lib/promise/activity.h"
+
+#include "src/core/lib/gprpp/atomic_utils.h"
+
+namespace grpc_core {
+
+///////////////////////////////////////////////////////////////////////////////
+// GLOBALS
+
+ABSL_CONST_INIT GPR_THREAD_LOCAL(Activity*) Activity::g_current_activity_ =
+    nullptr;
+Waker::Unwakeable Waker::unwakeable_;
+
+///////////////////////////////////////////////////////////////////////////////
+// HELPER TYPES
+
+// Weak handle to an Activity.
+// Handle can persist while Activity goes away.
+class Activity::Handle final : public Wakeable {
+ public:
+  explicit Handle(Activity* activity) : activity_(activity) {}
+
+  // Ref the Handle (not the activity).
+  void Ref() { refs_.fetch_add(1, std::memory_order_relaxed); }
+
+  // Activity is going away... drop its reference and sever the connection back.
+  void DropActivity() ABSL_LOCKS_EXCLUDED(mu_) {
+    mu_.Lock();
+    GPR_ASSERT(activity_ != nullptr);
+    activity_ = nullptr;
+    mu_.Unlock();
+    Unref();
+  }
+
+  // Activity needs to wake up (if it still exists!) - wake it up, and drop the
+  // ref that was kept for this handle.
+  void Wakeup() override ABSL_LOCKS_EXCLUDED(mu_) {
+    mu_.Lock();
+    // Note that activity refcount can drop to zero, but we could win the lock
+    // against DropActivity, so we need to only increase activities refcount if
+    // it is non-zero.
+    if (activity_ && activity_->RefIfNonzero()) {
+      Activity* activity = activity_;
+      mu_.Unlock();
+      // Activity still exists and we have a reference: wake it up, which will
+      // drop the ref.
+      activity->Wakeup();
+    } else {
+      // Could not get the activity - it's either gone or going. No need to wake
+      // it up!
+      mu_.Unlock();
+    }
+    // Drop the ref to the handle (we have one ref = one wakeup semantics).
+    Unref();
+  }
+
+  void Drop() override { Unref(); }
+
+ private:
+  // Unref the Handle (not the activity).
+  void Unref() {
+    if (1 == refs_.fetch_sub(1, std::memory_order_acq_rel)) {
+      delete this;
+    }
+  }
+
+  // Two initial refs: one for the waiter that caused instantiation, one for the
+  // activity.
+  std::atomic<size_t> refs_{2};
+  Mutex mu_ ABSL_ACQUIRED_AFTER(activity_->mu_);
+  Activity* activity_ ABSL_GUARDED_BY(mu_);
+};
+
+///////////////////////////////////////////////////////////////////////////////
+// ACTIVITY IMPLEMENTATION
+
+bool Activity::RefIfNonzero() { return IncrementIfNonzero(&refs_); }
+
+Activity::Handle* Activity::RefHandle() {
+  if (handle_ == nullptr) {
+    // No handle created yet - construct it and return it.
+    handle_ = new Handle(this);
+    return handle_;
+  } else {
+    // Already had to create a handle, ref & return it.
+    handle_->Ref();
+    return handle_;
+  }
+}
+
+void Activity::DropHandle() {
+  handle_->DropActivity();
+  handle_ = nullptr;
+}
+
+Waker Activity::MakeNonOwningWaker() { return Waker(RefHandle()); }
+
+}  // namespace grpc_core
diff --git a/src/core/lib/promise/activity.h b/src/core/lib/promise/activity.h
new file mode 100644 (file)
index 0000000..6941d98
--- /dev/null
@@ -0,0 +1,437 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#ifndef GRPC_CORE_LIB_PROMISE_ACTIVITY_H
+#define GRPC_CORE_LIB_PROMISE_ACTIVITY_H
+
+#include <grpc/impl/codegen/port_platform.h>
+
+#include <functional>
+
+#include <grpc/support/log.h>
+
+#include "src/core/lib/gprpp/construct_destruct.h"
+#include "src/core/lib/gprpp/sync.h"
+#include "src/core/lib/promise/context.h"
+#include "src/core/lib/promise/detail/promise_factory.h"
+#include "src/core/lib/promise/detail/status.h"
+#include "src/core/lib/promise/poll.h"
+
+namespace grpc_core {
+
+// A Wakeable object is used by queues to wake activities.
+class Wakeable {
+ public:
+  // Wake up the underlying activity.
+  // After calling, this Wakeable cannot be used again.
+  virtual void Wakeup() = 0;
+  // Drop this wakeable without waking up the underlying activity.
+  virtual void Drop() = 0;
+
+ protected:
+  inline ~Wakeable() {}
+};
+
+// An owning reference to a Wakeable.
+// This type is non-copyable but movable.
+class Waker {
+ public:
+  explicit Waker(Wakeable* wakeable) : wakeable_(wakeable) {}
+  Waker() : wakeable_(&unwakeable_) {}
+  ~Waker() { wakeable_->Drop(); }
+  Waker(const Waker&) = delete;
+  Waker& operator=(const Waker&) = delete;
+  Waker(Waker&& other) noexcept : wakeable_(other.wakeable_) {
+    other.wakeable_ = &unwakeable_;
+  }
+  Waker& operator=(Waker&& other) noexcept {
+    std::swap(wakeable_, other.wakeable_);
+    return *this;
+  }
+
+  // Wake the underlying activity.
+  void Wakeup() {
+    wakeable_->Wakeup();
+    wakeable_ = &unwakeable_;
+  }
+
+  template <typename H>
+  friend H AbslHashValue(H h, const Waker& w) {
+    return H::combine(std::move(h), w.wakeable_);
+  }
+
+  bool operator==(const Waker& other) const noexcept {
+    return wakeable_ == other.wakeable_;
+  }
+
+ private:
+  class Unwakeable final : public Wakeable {
+   public:
+    void Wakeup() final { abort(); }
+    void Drop() final {}
+  };
+
+  Wakeable* wakeable_;
+  static Unwakeable unwakeable_;
+};
+
+// An Activity tracks execution of a single promise.
+// It executes the promise under a mutex.
+// When the promise stalls, it registers the containing activity to be woken up
+// later.
+// The activity takes a callback, which will be called exactly once with the
+// result of execution.
+// Activity execution may be cancelled by simply deleting the activity. In such
+// a case, if execution had not already finished, the done callback would be
+// called with absl::CancelledError().
+// Activity also takes a CallbackScheduler instance on which to schedule
+// callbacks to itself in a lock-clean environment.
+class Activity : private Wakeable {
+ public:
+  // Cancel execution of the underlying promise.
+  virtual void Cancel() ABSL_LOCKS_EXCLUDED(mu_) = 0;
+
+  // Destroy the Activity - used for the type alias ActivityPtr.
+  struct Deleter {
+    void operator()(Activity* activity) {
+      activity->Cancel();
+      activity->Unref();
+    }
+  };
+
+  // Fetch the size of the implementation of this activity.
+  virtual size_t Size() = 0;
+
+  // Wakeup the current threads activity - will force a subsequent poll after
+  // the one that's running.
+  static void WakeupCurrent() { current()->got_wakeup_during_run_ = true; }
+
+  // Return the current activity.
+  // Additionally:
+  // - assert that there is a current activity (and catch bugs if there's not)
+  // - indicate to thread safety analysis that the current activity is indeed
+  //   locked
+  // - back up that assertation with a runtime check in debug builds (it's
+  //   prohibitively expensive in non-debug builds)
+  static Activity* current() ABSL_ASSERT_EXCLUSIVE_LOCK(current()->mu_) {
+#ifndef NDEBUG
+    GPR_ASSERT(g_current_activity_);
+    if (g_current_activity_ != nullptr) {
+      g_current_activity_->mu_.AssertHeld();
+    }
+#endif
+    return g_current_activity_;
+  }
+
+  // Produce an activity-owning Waker. The produced waker will keep the activity
+  // alive until it's awoken or dropped.
+  Waker MakeOwningWaker() {
+    Ref();
+    return Waker(this);
+  }
+
+  // Produce a non-owning Waker. The waker will own a small heap allocated weak
+  // pointer to this activity. This is more suitable for wakeups that may not be
+  // delivered until long after the activity should be destroyed.
+  Waker MakeNonOwningWaker() ABSL_EXCLUSIVE_LOCKS_REQUIRED(mu_);
+
+ protected:
+  inline virtual ~Activity() {
+    if (handle_) {
+      DropHandle();
+    }
+  }
+
+  // All promise execution occurs under this mutex.
+  Mutex mu_;
+
+  // Check if this activity is the current activity executing on the current
+  // thread.
+  bool is_current() const { return this == g_current_activity_; }
+  // Check if there is an activity executing on the current thread.
+  static bool have_current() { return g_current_activity_ != nullptr; }
+  // Check if we got an internal wakeup since the last time this function was
+  // called.
+  bool got_wakeup() ABSL_EXCLUSIVE_LOCKS_REQUIRED(mu_) {
+    return absl::exchange(got_wakeup_during_run_, false);
+  }
+
+  // Set the current activity at construction, clean it up at destruction.
+  class ScopedActivity {
+   public:
+    explicit ScopedActivity(Activity* activity) {
+      GPR_ASSERT(g_current_activity_ == nullptr);
+      g_current_activity_ = activity;
+    }
+    ~ScopedActivity() { g_current_activity_ = nullptr; }
+    ScopedActivity(const ScopedActivity&) = delete;
+    ScopedActivity& operator=(const ScopedActivity&) = delete;
+  };
+
+  // Implementors of Wakeable::Wakeup should call this after the wakeup has
+  // completed.
+  void WakeupComplete() { Unref(); }
+
+ private:
+  class Handle;
+
+  void Ref() { refs_.fetch_add(1, std::memory_order_relaxed); }
+  void Unref() {
+    if (1 == refs_.fetch_sub(1, std::memory_order_acq_rel)) {
+      delete this;
+    }
+  }
+
+  // Return a Handle instance with a ref so that it can be stored waiting for
+  // some wakeup.
+  Handle* RefHandle() ABSL_EXCLUSIVE_LOCKS_REQUIRED(mu_);
+  // If our refcount is non-zero, ref and return true.
+  // Otherwise, return false.
+  bool RefIfNonzero();
+  // Drop the (proved existing) wait handle.
+  void DropHandle() ABSL_EXCLUSIVE_LOCKS_REQUIRED(mu_);
+
+  // Current refcount.
+  std::atomic<uint32_t> refs_{1};
+  // If wakeup is called during Promise polling, we raise this flag and repoll
+  // until things settle out.
+  bool got_wakeup_during_run_ ABSL_GUARDED_BY(mu_) = false;
+  // Handle for long waits. Allows a very small weak pointer type object to
+  // queue for wakeups while Activity may be deleted earlier.
+  Handle* handle_ ABSL_GUARDED_BY(mu_) = nullptr;
+  // Set during RunLoop to the Activity that's executing.
+  // Being set implies that mu_ is held.
+  static GPR_THREAD_LOCAL(Activity*) g_current_activity_;
+};
+
+// Owned pointer to one Activity.
+using ActivityPtr = std::unique_ptr<Activity, Activity::Deleter>;
+
+namespace promise_detail {
+
+template <typename Context>
+class ContextHolder {
+ public:
+  explicit ContextHolder(Context value) : value_(std::move(value)) {}
+  Context* GetContext() { return &value_; }
+
+ private:
+  Context value_;
+};
+
+template <typename Context>
+class ContextHolder<Context*> {
+ public:
+  explicit ContextHolder(Context* value) : value_(value) {}
+  Context* GetContext() { return value_; }
+
+ private:
+  Context* value_;
+};
+
+template <typename... Contexts>
+class EnterContexts : public promise_detail::Context<Contexts>... {
+ public:
+  explicit EnterContexts(Contexts*... contexts)
+      : promise_detail::Context<Contexts>(contexts)... {}
+};
+
+// Implementation details for an Activity of an arbitrary type of promise.
+template <class F, class CallbackScheduler, class OnDone, typename... Contexts>
+class PromiseActivity final
+    : public Activity,
+      private promise_detail::ContextHolder<Contexts>... {
+ public:
+  using Factory = PromiseFactory<void, F>;
+  PromiseActivity(F promise_factory, CallbackScheduler callback_scheduler,
+                  OnDone on_done, Contexts... contexts)
+      : Activity(),
+        ContextHolder<Contexts>(std::move(contexts))...,
+        callback_scheduler_(std::move(callback_scheduler)),
+        on_done_(std::move(on_done)) {
+    // Lock, construct an initial promise from the factory, and step it.
+    // This may hit a waiter, which could expose our this pointer to other
+    // threads, meaning we do need to hold this mutex even though we're still
+    // constructing.
+    mu_.Lock();
+    auto status = Start(Factory(std::move(promise_factory)));
+    mu_.Unlock();
+    // We may complete immediately.
+    if (status.has_value()) {
+      on_done_(std::move(*status));
+    }
+  }
+
+  ~PromiseActivity() override {
+    // We shouldn't destruct without calling Cancel() first, and that must get
+    // us to be done_, so we assume that and have no logic to destruct the
+    // promise here.
+    GPR_ASSERT(done_);
+  }
+
+  size_t Size() override { return sizeof(*this); }
+
+  void Cancel() final {
+    bool was_done;
+    {
+      MutexLock lock(&mu_);
+      // Check if we were done, and flag done.
+      was_done = done_;
+      if (!done_) MarkDone();
+    }
+    // If we were not done, then call the on_done callback.
+    if (!was_done) {
+      on_done_(absl::CancelledError());
+    }
+  }
+
+ private:
+  // Wakeup this activity. Arrange to poll the activity again at a convenient
+  // time: this could be inline if it's deemed safe, or it could be by passing
+  // the activity to an external threadpool to run. If the activity is already
+  // running on this thread, a note is taken of such and the activity is
+  // repolled if it doesn't complete.
+  void Wakeup() final {
+    // If there's no active activity, we can just run inline.
+    if (!Activity::have_current()) {
+      Step();
+      WakeupComplete();
+      return;
+    }
+    // If there is an active activity, but hey it's us, flag that and we'll loop
+    // in RunLoop (that's calling from above here!).
+    if (Activity::is_current()) {
+      WakeupCurrent();
+      WakeupComplete();
+      return;
+    }
+    // Can't safely run, so ask to run later.
+    callback_scheduler_([this]() {
+      this->Step();
+      this->WakeupComplete();
+    });
+  }
+
+  // Drop a wakeup
+  void Drop() final { this->WakeupComplete(); }
+
+  // Notification that we're no longer executing - it's ok to destruct the
+  // promise.
+  void MarkDone() ABSL_EXCLUSIVE_LOCKS_REQUIRED(mu_) {
+    GPR_ASSERT(!done_);
+    done_ = true;
+    Destruct(&promise_holder_.promise);
+  }
+
+  // In response to Wakeup, run the Promise state machine again until it
+  // settles. Then check for completion, and if we have completed, call on_done.
+  void Step() ABSL_LOCKS_EXCLUDED(mu_) {
+    // Poll the promise until things settle out under a lock.
+    mu_.Lock();
+    if (done_) {
+      // We might get some spurious wakeups after finishing.
+      mu_.Unlock();
+      return;
+    }
+    auto status = RunStep();
+    mu_.Unlock();
+    if (status.has_value()) {
+      on_done_(std::move(*status));
+    }
+  }
+
+  // The main body of a step: set the current activity, and any contexts, and
+  // then run the main polling loop. Contained in a function by itself in order
+  // to keep the scoping rules a little easier in Step().
+  absl::optional<absl::Status> RunStep() ABSL_EXCLUSIVE_LOCKS_REQUIRED(mu_) {
+    ScopedActivity scoped_activity(this);
+    EnterContexts<Contexts...> contexts(
+        static_cast<ContextHolder<Contexts>*>(this)->GetContext()...);
+    return StepLoop();
+  }
+
+  // Similarly to RunStep, but additionally construct the promise from a promise
+  // factory before entering the main loop. Called once from the constructor.
+  absl::optional<absl::Status> Start(Factory promise_factory)
+      ABSL_EXCLUSIVE_LOCKS_REQUIRED(mu_) {
+    ScopedActivity scoped_activity(this);
+    EnterContexts<Contexts...> contexts(
+        static_cast<ContextHolder<Contexts>*>(this)->GetContext()...);
+    Construct(&promise_holder_.promise, promise_factory.Once());
+    return StepLoop();
+  }
+
+  // Until there are no wakeups from within and the promise is incomplete: poll
+  // the promise.
+  absl::optional<absl::Status> StepLoop() ABSL_EXCLUSIVE_LOCKS_REQUIRED(mu_) {
+    GPR_ASSERT(is_current());
+    do {
+      // Run the promise.
+      GPR_ASSERT(!done_);
+      auto r = promise_holder_.promise();
+      if (auto* status = absl::get_if<kPollReadyIdx>(&r)) {
+        // If complete, destroy the promise, flag done, and exit this loop.
+        MarkDone();
+        return IntoStatus(status);
+      }
+      // Continue looping til no wakeups occur.
+    } while (got_wakeup());
+    return {};
+  }
+
+  using Promise = typename Factory::Promise;
+  // We wrap the promise in a union to allow control over the construction
+  // simultaneously with annotating mutex requirements and noting that the
+  // promise contained may not use any memory.
+  union PromiseHolder {
+    PromiseHolder() {}
+    ~PromiseHolder() {}
+    GPR_NO_UNIQUE_ADDRESS Promise promise;
+  };
+  GPR_NO_UNIQUE_ADDRESS PromiseHolder promise_holder_ ABSL_GUARDED_BY(mu_);
+  // Schedule callbacks on some external executor.
+  GPR_NO_UNIQUE_ADDRESS CallbackScheduler callback_scheduler_;
+  // Callback on completion of the promise.
+  GPR_NO_UNIQUE_ADDRESS OnDone on_done_;
+  // Has execution completed?
+  GPR_NO_UNIQUE_ADDRESS bool done_ ABSL_GUARDED_BY(mu_) = false;
+};
+
+}  // namespace promise_detail
+
+// Given a functor that returns a promise (a promise factory), a callback for
+// completion, and a callback scheduler, construct an activity.
+template <typename Factory, typename CallbackScheduler, typename OnDone,
+          typename... Contexts>
+ActivityPtr MakeActivity(Factory promise_factory,
+                         CallbackScheduler callback_scheduler, OnDone on_done,
+                         Contexts... contexts) {
+  return ActivityPtr(
+      new promise_detail::PromiseActivity<Factory, CallbackScheduler, OnDone,
+                                          Contexts...>(
+          std::move(promise_factory), std::move(callback_scheduler),
+          std::move(on_done), std::move(contexts)...));
+}
+
+// A callback scheduler that simply crashes
+struct NoCallbackScheduler {
+  template <typename F>
+  void operator()(F) {
+    abort();
+  }
+};
+
+}  // namespace grpc_core
+
+#endif  // GRPC_CORE_LIB_PROMISE_ACTIVITY_H
diff --git a/src/core/lib/promise/context.h b/src/core/lib/promise/context.h
new file mode 100644 (file)
index 0000000..59cdf21
--- /dev/null
@@ -0,0 +1,85 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#ifndef GRPC_CORE_LIB_PROMISE_CONTEXT_H
+#define GRPC_CORE_LIB_PROMISE_CONTEXT_H
+
+#include <grpc/impl/codegen/port_platform.h>
+
+#include <utility>
+
+#include "src/core/lib/gpr/tls.h"
+
+namespace grpc_core {
+
+// To avoid accidentally creating context types, we require an explicit
+// specialization of this template per context type. The specialization need
+// not contain any members, only exist.
+// The reason for avoiding this is that context types each use a thread local.
+template <typename T>
+struct ContextType;
+
+namespace promise_detail {
+
+template <typename T>
+class Context : public ContextType<T> {
+ public:
+  explicit Context(T* p) : old_(current_) { current_ = p; }
+  ~Context() { current_ = old_; }
+  Context(const Context&) = delete;
+  Context& operator=(const Context&) = delete;
+
+  static T* get() { return current_; }
+
+ private:
+  T* const old_;
+  static GPR_THREAD_LOCAL(T*) current_;
+};
+
+template <typename T>
+GPR_THREAD_LOCAL(T*)
+Context<T>::current_;
+
+template <typename T, typename F>
+class WithContext {
+ public:
+  WithContext(F f, T* context) : context_(context), f_(std::move(f)) {}
+
+  decltype(std::declval<F>()()) operator()() {
+    Context<T> ctx(context_);
+    return f_();
+  }
+
+ private:
+  T* context_;
+  F f_;
+};
+
+}  // namespace promise_detail
+
+// Retrieve the current value of a context.
+template <typename T>
+T* GetContext() {
+  return promise_detail::Context<T>::get();
+}
+
+// Given a promise and a context, return a promise that has that context set.
+template <typename T, typename F>
+promise_detail::WithContext<T, F> WithContext(F f, T* context) {
+  return promise_detail::WithContext<T, F>(f, context);
+}
+
+}  // namespace grpc_core
+
+#endif  // GRPC_CORE_LIB_PROMISE_CONTEXT_H
diff --git a/src/core/lib/promise/detail/basic_join.h b/src/core/lib/promise/detail/basic_join.h
new file mode 100644 (file)
index 0000000..01d2d33
--- /dev/null
@@ -0,0 +1,192 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#ifndef GRPC_CORE_LIB_PROMISE_DETAIL_BASIC_JOIN_H
+#define GRPC_CORE_LIB_PROMISE_DETAIL_BASIC_JOIN_H
+
+#include <grpc/impl/codegen/port_platform.h>
+
+#include <tuple>
+#include <utility>
+
+#include "absl/utility/utility.h"
+
+#include "src/core/lib/gprpp/bitset.h"
+#include "src/core/lib/gprpp/construct_destruct.h"
+#include "src/core/lib/promise/detail/promise_factory.h"
+#include "src/core/lib/promise/poll.h"
+
+namespace grpc_core {
+namespace promise_detail {
+
+// This union can either be a functor, or the result of the functor (after
+// mapping via a trait). Allows us to remember the result of one joined functor
+// until the rest are ready.
+template <typename Traits, typename F>
+union Fused {
+  explicit Fused(F&& f) : f(std::forward<F>(f)) {}
+  explicit Fused(PromiseLike<F>&& f) : f(std::forward<PromiseLike<F>>(f)) {}
+  ~Fused() {}
+  // Wrap the functor in a PromiseLike to handle immediately returning functors
+  // and the like.
+  using Promise = PromiseLike<F>;
+  GPR_NO_UNIQUE_ADDRESS Promise f;
+  // Compute the result type: We take the result of the promise, and pass it via
+  // our traits, so that, for example, TryJoin and take a StatusOr<T> and just
+  // store a T.
+  using Result = typename Traits::template ResultType<typename Promise::Result>;
+  GPR_NO_UNIQUE_ADDRESS Result result;
+};
+
+// A join gets composed of joints... these are just wrappers around a Fused for
+// their data, with some machinery as methods to get the system working.
+template <typename Traits, size_t kRemaining, typename... Fs>
+struct Joint : public Joint<Traits, kRemaining - 1, Fs...> {
+  // The index into Fs for this Joint
+  static constexpr size_t kIdx = sizeof...(Fs) - kRemaining;
+  // The next join (the one we derive from)
+  using NextJoint = Joint<Traits, kRemaining - 1, Fs...>;
+  // From Fs, extract the functor for this joint.
+  using F = typename std::tuple_element<kIdx, std::tuple<Fs...>>::type;
+  // Generate the Fused type for this functor.
+  using Fsd = Fused<Traits, F>;
+  GPR_NO_UNIQUE_ADDRESS Fsd fused;
+  // Figure out what kind of bitmask will be used by the outer join.
+  using Bits = BitSet<sizeof...(Fs)>;
+  // Initialize from a tuple of pointers to Fs
+  explicit Joint(std::tuple<Fs*...> fs)
+      : NextJoint(fs), fused(std::move(*std::get<kIdx>(fs))) {}
+  // Copy: assume that the Fuse is still in the promise state (since it's not
+  // legal to copy after the first poll!)
+  Joint(const Joint& j) : NextJoint(j), fused(j.fused.f) {}
+  // Move: assume that the Fuse is still in the promise state (since it's not
+  // legal to move after the first poll!)
+  Joint(Joint&& j) noexcept
+      : NextJoint(std::forward<NextJoint>(j)), fused(std::move(j.fused.f)) {}
+  // Destruct: check bits to see if we're in promise or result state, and call
+  // the appropriate destructor. Recursively, call up through the join.
+  void DestructAll(const Bits& bits) {
+    if (!bits.is_set(kIdx)) {
+      Destruct(&fused.f);
+    } else {
+      Destruct(&fused.result);
+    }
+    NextJoint::DestructAll(bits);
+  }
+  // Poll all joints up, and then call finally.
+  template <typename F>
+  auto Run(Bits* bits, F finally) -> decltype(finally()) {
+    // If we're still in the promise state...
+    if (!bits->is_set(kIdx)) {
+      // Poll the promise
+      auto r = fused.f();
+      if (auto* p = absl::get_if<kPollReadyIdx>(&r)) {
+        // If it's done, then ask the trait to unwrap it and store that result
+        // in the Fused, and continue the iteration. Note that OnResult could
+        // instead choose to return a value instead of recursing through the
+        // iteration, in that case we continue returning the same result up.
+        // Here is where TryJoin can escape out.
+        return Traits::OnResult(
+            std::move(*p), [this, bits, &finally](typename Fsd::Result result) {
+              bits->set(kIdx);
+              Destruct(&fused.f);
+              Construct(&fused.result, std::move(result));
+              return NextJoint::Run(bits, std::move(finally));
+            });
+      }
+    }
+    // That joint is still pending... we'll still poll the result of the joints.
+    return NextJoint::Run(bits, std::move(finally));
+  }
+};
+
+// Terminating joint... for each of the recursions, do the thing we're supposed
+// to do at the end.
+template <typename Traits, typename... Fs>
+struct Joint<Traits, 0, Fs...> {
+  explicit Joint(std::tuple<Fs*...>) {}
+  Joint(const Joint&) {}
+  Joint(Joint&&) noexcept {}
+  template <typename T>
+  void DestructAll(const T&) {}
+  template <typename F>
+  auto Run(BitSet<sizeof...(Fs)>*, F finally) -> decltype(finally()) {
+    return finally();
+  }
+};
+
+template <typename Traits, typename... Fs>
+class BasicJoin {
+ private:
+  // How many things are we joining?
+  static constexpr size_t N = sizeof...(Fs);
+  // Bitset: if a bit is 0, that joint is still in promise state. If it's 1,
+  // then the joint has a result.
+  GPR_NO_UNIQUE_ADDRESS BitSet<N> state_;
+  // The actual joints, wrapped in an anonymous union to give us control of
+  // construction/destruction.
+  union {
+    GPR_NO_UNIQUE_ADDRESS Joint<Traits, sizeof...(Fs), Fs...> joints_;
+  };
+
+  // Access joint index I
+  template <size_t I>
+  Joint<Traits, sizeof...(Fs) - I, Fs...>* GetJoint() {
+    return static_cast<Joint<Traits, sizeof...(Fs) - I, Fs...>*>(&joints_);
+  }
+
+  // The tuple of results of all our promises
+  using Tuple = std::tuple<typename Fused<Traits, Fs>::Result...>;
+
+  // Collect up all the results and construct a tuple.
+  template <size_t... I>
+  Tuple Finish(absl::index_sequence<I...>) {
+    return Tuple(std::move(GetJoint<I>()->fused.result)...);
+  }
+
+ public:
+  explicit BasicJoin(Fs&&... fs) : joints_(std::tuple<Fs*...>(&fs...)) {}
+  BasicJoin& operator=(const BasicJoin&) = delete;
+  // Copy a join - only available before polling.
+  BasicJoin(const BasicJoin& other) {
+    assert(other.state_.none());
+    Construct(&joints_, other.joints_);
+  }
+  // Move a join - only available before polling.
+  BasicJoin(BasicJoin&& other) noexcept {
+    assert(other.state_.none());
+    Construct(&joints_, std::move(other.joints_));
+  }
+  ~BasicJoin() { joints_.DestructAll(state_); }
+  using Result = decltype(Traits::Wrap(std::declval<Tuple>()));
+  // Poll the join
+  Poll<Result> operator()() {
+    // Poll the joints...
+    return joints_.Run(&state_, [this]() -> Poll<Result> {
+      // If all of them are completed, collect the results, and then ask our
+      // traits to wrap them - allowing for example TryJoin to turn tuple<A,B,C>
+      // into StatusOr<tuple<A,B,C>>.
+      if (state_.all()) {
+        return Traits::Wrap(Finish(absl::make_index_sequence<N>()));
+      } else {
+        return Pending();
+      }
+    });
+  }
+};
+
+}  // namespace promise_detail
+}  // namespace grpc_core
+
+#endif  // GRPC_CORE_LIB_PROMISE_DETAIL_BASIC_JOIN_H
diff --git a/src/core/lib/promise/detail/basic_seq.h b/src/core/lib/promise/detail/basic_seq.h
new file mode 100644 (file)
index 0000000..72b91f9
--- /dev/null
@@ -0,0 +1,396 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#ifndef GRPC_CORE_LIB_PROMISE_DETAIL_BASIC_SEQ_H
+#define GRPC_CORE_LIB_PROMISE_DETAIL_BASIC_SEQ_H
+
+#include <grpc/impl/codegen/port_platform.h>
+
+#include "absl/types/variant.h"
+#include "absl/utility/utility.h"
+
+#include "src/core/lib/gprpp/construct_destruct.h"
+#include "src/core/lib/promise/detail/promise_factory.h"
+#include "src/core/lib/promise/detail/switch.h"
+#include "src/core/lib/promise/poll.h"
+
+namespace grpc_core {
+namespace promise_detail {
+
+// Helper for SeqState to evaluate some common types to all partial
+// specializations.
+template <template <typename> class Traits, typename FPromise, typename FNext>
+struct SeqStateTypes {
+  // Our current promise.
+  using Promise = FPromise;
+  // The result of our current promise.
+  using PromiseResult = typename Promise::Result;
+  // Traits around the result of our promise.
+  using PromiseResultTraits = Traits<PromiseResult>;
+  // Wrap the factory callable in our factory wrapper to deal with common edge
+  // cases. We use the 'unwrapped type' from the traits, so for instance, TrySeq
+  // can pass back a T from a StatusOr<T>.
+  using Next = promise_detail::PromiseFactory<
+      typename PromiseResultTraits::UnwrappedType, FNext>;
+};
+
+// One state in a sequence.
+// A state contains the current promise, and the promise factory to turn the
+// result of the current promise into the next state's promise. We play a shell
+// game such that the prior state and our current promise are kept in a union,
+// and the next promise factory is kept alongside in the state struct.
+// Recursively this guarantees that the next functions get initialized once, and
+// destroyed once, and don't need to be moved around in between, which avoids a
+// potential O(n**2) loop of next factory moves had we used a variant of states
+// here. The very first state does not have a prior state, and so that state has
+// a partial specialization below. The final state does not have a next state;
+// that state is inlined in BasicSeq since that was simpler to type.
+template <template <typename> class Traits, char I, typename... Fs>
+struct SeqState {
+  // The state evaluated before this state.
+  using PriorState = SeqState<Traits, I - 1, Fs...>;
+  // Initialization from callables.
+  explicit SeqState(std::tuple<Fs*...> fs)
+      : next_factory(std::move(*std::get<I + 1>(fs))) {
+    new (&prior) PriorState(fs);
+  }
+  // Move constructor - assumes we're in the initial state (move prior) as it's
+  // illegal to move a promise after polling it.
+  SeqState(SeqState&& other) noexcept
+      : prior(std::move(other.prior)),
+        next_factory(std::move(other.next_factory)) {}
+  // Copy constructor - assumes we're in the initial state (move prior) as it's
+  // illegal to move a promise after polling it.
+  SeqState(const SeqState& other)
+      : prior(other.prior), next_factory(other.next_factory) {}
+  // Empty destructor - we instead destruct the innards in BasicSeq manually
+  // depending on state.
+  ~SeqState() {}
+  // Evaluate the current promise, next promise factory types for this state.
+  // The current promise is the next promise from the prior state.
+  // The next factory callable is from the callables passed in:
+  // Fs[0] is the initial promise, Fs[1] is the state 0 next factory, Fs[2] is
+  // the state 1 next factory, etc...
+  using Types = SeqStateTypes<
+      Traits, typename PriorState::Types::Next::Promise,
+      typename std::tuple_element<I + 1, std::tuple<Fs...>>::type>;
+  // Storage for either the current promise or the prior state.
+  union {
+    // If we're in the prior state.
+    GPR_NO_UNIQUE_ADDRESS PriorState prior;
+    // The callables representing our promise.
+    GPR_NO_UNIQUE_ADDRESS typename Types::Promise current_promise;
+  };
+  // Storage for the next promise factory.
+  GPR_NO_UNIQUE_ADDRESS typename Types::Next next_factory;
+};
+
+// Partial specialization of SeqState above for the first state - it has no
+// prior state, so we take the first callable from the template arg list and use
+// it as a promise.
+template <template <typename> class Traits, typename... Fs>
+struct SeqState<Traits, 0, Fs...> {
+  // Initialization from callables.
+  explicit SeqState(std::tuple<Fs*...> args)
+      : current_promise(std::move(*std::get<0>(args))),
+        next_factory(std::move(*std::get<1>(args))) {}
+  // Move constructor - it's assumed we're in this state (see above).
+  SeqState(SeqState&& other) noexcept
+      : current_promise(std::move(other.current_promise)),
+        next_factory(std::move(other.next_factory)) {}
+  // Copy constructor - it's assumed we're in this state (see above).
+  SeqState(const SeqState& other)
+      : current_promise(other.current_promise),
+        next_factory(other.next_factory) {}
+  // Empty destructor - we instead destruct the innards in BasicSeq manually
+  // depending on state.
+  ~SeqState(){};
+  // Evaluate the current promise, next promise factory types for this state.
+  // Our callable is the first element of Fs, wrapped in PromiseLike to handle
+  // some common edge cases. The next factory is the second element.
+  using Types = SeqStateTypes<
+      Traits,
+      PromiseLike<typename std::tuple_element<0, std::tuple<Fs...>>::type>,
+      typename std::tuple_element<1, std::tuple<Fs...>>::type>;
+  GPR_NO_UNIQUE_ADDRESS typename Types::Promise current_promise;
+  GPR_NO_UNIQUE_ADDRESS typename Types::Next next_factory;
+};
+
+// Helper to get a specific state index.
+// Calls the prior state, unless it's this state, in which case it returns
+// that.
+template <char I, template <typename> class Traits, char J, typename... Fs>
+struct GetSeqStateInner {
+  static SeqState<Traits, I, Fs...>* f(SeqState<Traits, J, Fs...>* p) {
+    return GetSeqStateInner<I, Traits, J - 1, Fs...>::f(&p->prior);
+  }
+};
+
+template <char I, template <typename> class Traits, typename... Fs>
+struct GetSeqStateInner<I, Traits, I, Fs...> {
+  static SeqState<Traits, I, Fs...>* f(SeqState<Traits, I, Fs...>* p) {
+    return p;
+  }
+};
+
+template <char I, template <typename> class Traits, char J, typename... Fs>
+absl::enable_if_t<I <= J, SeqState<Traits, I, Fs...>*> GetSeqState(
+    SeqState<Traits, J, Fs...>* p) {
+  return GetSeqStateInner<I, Traits, J, Fs...>::f(p);
+}
+
+template <template <typename> class Traits, char I, typename... Fs, typename T>
+auto CallNext(SeqState<Traits, I, Fs...>* state, T&& arg) -> decltype(
+    SeqState<Traits, I, Fs...>::Types::PromiseResultTraits::CallFactory(
+        &state->next_factory, std::forward<T>(arg))) {
+  return SeqState<Traits, I, Fs...>::Types::PromiseResultTraits::CallFactory(
+      &state->next_factory, std::forward<T>(arg));
+}
+
+// A sequence under stome traits for some set of callables Fs.
+// Fs[0] should be a promise-like object that yields a value.
+// Fs[1..] should be promise-factory-like objects that take the value from the
+// previous step and yield a promise. Note that most of the machinery in
+// PromiseFactory exists to make it possible for those promise-factory-like
+// objects to be anything that's convenient. Traits defines how we move from one
+// step to the next. Traits sets up the wrapping and escape handling for the
+// sequence. Promises return wrapped values that the trait can inspect and
+// unwrap before passing them to the next element of the sequence. The trait can
+// also interpret a wrapped value as an escape value, which terminates
+// evaluation of the sequence immediately yielding a result. Traits for type T
+// have the members:
+//  * type UnwrappedType - the type after removing wrapping from T (i.e. for
+//    TrySeq, T=StatusOr<U> yields UnwrappedType=U).
+//  * type WrappedType - the type after adding wrapping if it doesn't already
+//    exist (i.e. for TrySeq if T is not Status/StatusOr/void, then
+//    WrappedType=StatusOr<T>; if T is Status then WrappedType=Status (it's
+//    already wrapped!))
+//  * template <typename Next> void CallFactory(Next* next_factory, T&& value) -
+//    call promise factory next_factory with the result of unwrapping value, and
+//    return the resulting promise.
+//  * template <typename Result, typename RunNext> Poll<Result>
+//    CheckResultAndRunNext(T prior, RunNext run_next) - examine the value of
+//    prior, and decide to escape or continue. If escaping, return the final
+//    sequence value of type Poll<Result>. If continuing, return the value of
+//    run_next(std::move(prior)).
+template <template <typename> class Traits, typename... Fs>
+class BasicSeq {
+ private:
+  // Number of states in the sequence - we'll refer to this some!
+  static constexpr char N = sizeof...(Fs);
+
+  // Current state.
+  static_assert(N < 128, "Long sequence... please revisit BasicSeq");
+  char state_ = 0;
+  // The penultimate state contains all the preceding states too.
+  using PenultimateState = SeqState<Traits, N - 2, Fs...>;
+  // The final state is simply the final promise, which is the next promise from
+  // the penultimate state.
+  using FinalPromise = typename PenultimateState::Types::Next::Promise;
+  union {
+    GPR_NO_UNIQUE_ADDRESS PenultimateState penultimate_state_;
+    GPR_NO_UNIQUE_ADDRESS FinalPromise final_promise_;
+  };
+  using FinalPromiseResult = typename FinalPromise::Result;
+  using Result = typename Traits<FinalPromiseResult>::WrappedType;
+
+  // Get a state by index.
+  template <char I>
+      absl::enable_if_t < I<N - 2, SeqState<Traits, I, Fs...>*> state() {
+    return GetSeqState<I>(&penultimate_state_);
+  }
+
+  template <char I>
+  absl::enable_if_t<I == N - 2, PenultimateState*> state() {
+    return &penultimate_state_;
+  }
+
+  // Get the next state's promise.
+  template <char I>
+  auto next_promise() -> absl::enable_if_t<
+      I != N - 2,
+      decltype(&GetSeqState<I + 1>(static_cast<PenultimateState*>(nullptr))
+                    ->current_promise)> {
+    return &GetSeqState<I + 1>(&penultimate_state_)->current_promise;
+  }
+
+  template <char I>
+  absl::enable_if_t<I == N - 2, FinalPromise*> next_promise() {
+    return &final_promise_;
+  }
+
+  // Callable to advance the state to the next one after I given the result from
+  // state I.
+  template <char I>
+  struct RunNext {
+    BasicSeq* s;
+    template <typename T>
+    Poll<Result> operator()(T&& value) {
+      auto* prior = s->state<I>();
+      using StateType = absl::remove_reference_t<decltype(*prior)>;
+      // Destroy the promise that just completed.
+      Destruct(&prior->current_promise);
+      // Construct the next promise by calling the next promise factory.
+      // We need to ask the traits to do this to deal with value
+      // wrapping/unwrapping.
+      auto n = StateType::Types::PromiseResultTraits::CallFactory(
+          &prior->next_factory, std::forward<T>(value));
+      // Now we also no longer need the factory, so we can destroy that.
+      Destruct(&prior->next_factory);
+      // Constructing the promise for the new state will use the memory
+      // previously occupied by the promise & next factory of the old state.
+      Construct(s->next_promise<I>(), std::move(n));
+      // Store the state counter.
+      s->state_ = I + 1;
+      // Recursively poll the new current state.
+      return s->RunState<I + 1>();
+    }
+  };
+
+  // Poll the current state, advance it if necessary.
+  template <char I>
+  absl::enable_if_t<I != N - 1, Poll<Result>> RunState() {
+    // Get a pointer to the state object.
+    auto* s = state<I>();
+    // Poll the current promise in this state.
+    auto r = s->current_promise();
+    // If we are still pending, say so by returning.
+    if (absl::holds_alternative<Pending>(r)) {
+      return Pending();
+    }
+    // Current promise is ready, as the traits to do the next thing.
+    // That may be returning - eg if TrySeq sees an error.
+    // Or it may be by calling the callable we hand down - RunNext - which
+    // will advance the state and call the next promise.
+    return Traits<
+        typename absl::remove_reference_t<decltype(*s)>::Types::PromiseResult>::
+        template CheckResultAndRunNext<Result>(
+            std::move(absl::get<kPollReadyIdx>(std::move(r))),
+            RunNext<I>{this});
+  }
+
+  // Specialization of RunState to run the final state.
+  template <char I>
+  absl::enable_if_t<I == N - 1, Poll<Result>> RunState() {
+    // Poll the final promise.
+    auto r = final_promise_();
+    // If we are still pending, say so by returning.
+    if (absl::holds_alternative<Pending>(r)) {
+      return Pending();
+    }
+    // We are complete, return the (wrapped) result.
+    return Result(std::move(absl::get<kPollReadyIdx>(std::move(r))));
+  }
+
+  // For state numbered I, destruct the current promise and the next promise
+  // factory, and recursively destruct the next promise factories for future
+  // states (since they also still exist).
+  template <char I>
+  absl::enable_if_t<I != N - 1, void>
+  DestructCurrentPromiseAndSubsequentFactories() {
+    Destruct(&GetSeqState<I>(&penultimate_state_)->current_promise);
+    DestructSubsequentFactories<I>();
+  }
+
+  template <char I>
+  absl::enable_if_t<I == N - 1, void>
+  DestructCurrentPromiseAndSubsequentFactories() {
+    Destruct(&final_promise_);
+  }
+
+  // For state I, destruct the next promise factory, and recursively the next
+  // promise factories after.
+  template <char I>
+  absl::enable_if_t<I != N - 1, void> DestructSubsequentFactories() {
+    Destruct(&GetSeqState<I>(&penultimate_state_)->next_factory);
+    DestructSubsequentFactories<I + 1>();
+  }
+
+  template <char I>
+  absl::enable_if_t<I == N - 1, void> DestructSubsequentFactories() {}
+
+  // Placate older compilers by wrapping RunState in a struct so that their
+  // parameter unpacking can work.
+  template <char I>
+  struct RunStateStruct {
+    BasicSeq* s;
+    Poll<Result> operator()() { return s->RunState<I>(); }
+  };
+
+  // Similarly placate those compilers for
+  // DestructCurrentPromiseAndSubsequentFactories
+  template <char I>
+  struct DestructCurrentPromiseAndSubsequentFactoriesStruct {
+    BasicSeq* s;
+    void operator()() {
+      return s->DestructCurrentPromiseAndSubsequentFactories<I>();
+    }
+  };
+
+  // Run the current state (and possibly later states if that one finishes).
+  // Single argument is a type that encodes the integer sequence 0, 1, 2, ...,
+  // N-1 as a type, but which uses no memory. This is used to expand out
+  // RunState instances using a template unpack to pass to Switch, which encodes
+  // a switch statement over the various cases. This ultimately gives us a
+  // Duff's device like mechanic for evaluating sequences.
+  template <char... I>
+  Poll<Result> Run(absl::integer_sequence<char, I...>) {
+    return Switch<Poll<Result>>(state_, RunStateStruct<I>{this}...);
+  }
+
+  // Run the appropriate destructors for a given state.
+  // Single argument is a type that encodes the integer sequence 0, 1, 2, ...,
+  // N-1 as a type, but which uses no memory. This is used to expand out
+  // DestructCurrentPromiseAndSubsequentFactories instances to pass to Switch,
+  // which can choose the correct instance at runtime to destroy everything.
+  template <char... I>
+  void RunDestruct(absl::integer_sequence<char, I...>) {
+    Switch<void>(
+        state_, DestructCurrentPromiseAndSubsequentFactoriesStruct<I>{this}...);
+  }
+
+ public:
+  // Construct a sequence given the callables that will control it.
+  explicit BasicSeq(Fs... fs) : penultimate_state_(std::make_tuple(&fs...)) {}
+  // No assignment... we don't need it (but if we ever find a good case, then
+  // it's ok to implement).
+  BasicSeq& operator=(const BasicSeq&) = delete;
+  // Copy construction - only for state 0.
+  // It's illegal to copy a Promise after polling it - if we are in state>0 we
+  // *must* have been polled.
+  BasicSeq(const BasicSeq& other) {
+    assert(other.state_ == 0);
+    new (&penultimate_state_) PenultimateState(other.penultimate_state_);
+  }
+  // Move construction - only for state 0.
+  // It's illegal to copy a Promise after polling it - if we are in state>0 we
+  // *must* have been polled.
+  BasicSeq(BasicSeq&& other) noexcept {
+    assert(other.state_ == 0);
+    new (&penultimate_state_)
+        PenultimateState(std::move(other.penultimate_state_));
+  }
+  // Destruct based on current state.
+  ~BasicSeq() { RunDestruct(absl::make_integer_sequence<char, N>()); }
+
+  // Poll the sequence once.
+  Poll<Result> operator()() {
+    return Run(absl::make_integer_sequence<char, N>());
+  }
+};
+
+}  // namespace promise_detail
+}  // namespace grpc_core
+
+#endif  // GRPC_CORE_LIB_PROMISE_DETAIL_BASIC_SEQ_H
diff --git a/src/core/lib/promise/detail/promise_factory.h b/src/core/lib/promise/detail/promise_factory.h
new file mode 100644 (file)
index 0000000..2adb0b7
--- /dev/null
@@ -0,0 +1,185 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#ifndef GRPC_CORE_LIB_PROMISE_DETAIL_PROMISE_FACTORY_H
+#define GRPC_CORE_LIB_PROMISE_DETAIL_PROMISE_FACTORY_H
+
+#include <grpc/impl/codegen/port_platform.h>
+
+#include "absl/meta/type_traits.h"
+
+#include "src/core/lib/promise/detail/promise_like.h"
+#include "src/core/lib/promise/poll.h"
+
+// PromiseFactory is an adaptor class.
+//
+// Where a Promise is a thing that's polled periodically, a PromiseFactory
+// creates a Promise. Within this Promise/Activity framework, PromiseFactory's
+// then provide the edges for computation -- invoked at state transition
+// boundaries to provide the new steady state.
+//
+// A PromiseFactory formally is f(A) -> Promise<T> for some types A & T.
+// This get a bit awkward and inapproprate to write however, and so the type
+// contained herein can adapt various kinds of callable into the correct form.
+// Of course a callable of a single argument returning a Promise will see an
+// identity translation. One taking no arguments and returning a Promise
+// similarly.
+//
+// A Promise passed to a PromiseFactory will yield a PromiseFactory that
+// returns just that Promise.
+//
+// Generalizing slightly, a callable taking a single argument A and returning a
+// Poll<T> will yield a PromiseFactory that captures it's argument A and
+// returns a Poll<T>.
+//
+// Since various consumers of PromiseFactory run either repeatedly through an
+// overarching Promises lifetime, or just once, and we can optimize just once
+// by moving the contents of the PromiseFactory, two factory methods are
+// provided: Once, that can be called just once, and Repeated, that can (wait
+// for it) be called Repeatedly.
+
+namespace grpc_core {
+namespace promise_detail {
+
+// Helper trait: given a T, and T x, is calling x() legal?
+template <typename T, typename Ignored = void>
+struct IsVoidCallable {
+  static constexpr bool value = false;
+};
+template <typename F>
+struct IsVoidCallable<F, absl::void_t<decltype(std::declval<F>()())>> {
+  static constexpr bool value = true;
+};
+
+// Given F(A,B,C,...), what's the return type?
+template <typename T, typename Ignored = void>
+struct ResultOfT;
+template <typename F, typename... Args>
+struct ResultOfT<F(Args...),
+                 absl::void_t<decltype(std::declval<RemoveCVRef<F>>()(
+                     std::declval<Args>()...))>> {
+  using T = decltype(std::declval<RemoveCVRef<F>>()(std::declval<Args>()...));
+};
+
+template <typename T>
+using ResultOf = typename ResultOfT<T>::T;
+
+// Captures the promise functor and the argument passed.
+// Provides the interface of a promise.
+template <typename F, typename Arg>
+class Curried {
+ public:
+  Curried(F&& f, Arg&& arg)
+      : f_(std::forward<F>(f)), arg_(std::forward<Arg>(arg)) {}
+  Curried(const F& f, Arg&& arg) : f_(f), arg_(std::forward<Arg>(arg)) {}
+  using Result = decltype(std::declval<F>()(std::declval<Arg>()));
+  Result operator()() { return f_(arg_); }
+
+ private:
+  GPR_NO_UNIQUE_ADDRESS F f_;
+  GPR_NO_UNIQUE_ADDRESS Arg arg_;
+};
+
+// Promote a callable(A) -> T | Poll<T> to a PromiseFactory(A) -> Promise<T> by
+// capturing A.
+template <typename A, typename F>
+absl::enable_if_t<!IsVoidCallable<ResultOf<F(A)>>::value,
+                  PromiseLike<Curried<RemoveCVRef<F>, A>>>
+PromiseFactoryImpl(F&& f, A&& arg) {
+  return Curried<RemoveCVRef<F>, A>(std::forward<F>(f), std::forward<A>(arg));
+}
+
+// Promote a callable() -> T|Poll<T> to a PromiseFactory(A) -> Promise<T>
+// by dropping the argument passed to the factory.
+template <typename A, typename F>
+absl::enable_if_t<!IsVoidCallable<ResultOf<F()>>::value,
+                  PromiseLike<RemoveCVRef<F>>>
+PromiseFactoryImpl(F f, A&&) {
+  return PromiseLike<F>(std::move(f));
+}
+
+// Promote a callable() -> T|Poll<T> to a PromiseFactory() -> Promise<T>
+template <typename F>
+absl::enable_if_t<!IsVoidCallable<ResultOf<F()>>::value,
+                  PromiseLike<RemoveCVRef<F>>>
+PromiseFactoryImpl(F f) {
+  return PromiseLike<F>(std::move(f));
+}
+
+// Given a callable(A) -> Promise<T>, name it a PromiseFactory and use it.
+template <typename A, typename F>
+absl::enable_if_t<IsVoidCallable<ResultOf<F(A)>>::value,
+                  PromiseLike<decltype(std::declval<F>()(std::declval<A>()))>>
+PromiseFactoryImpl(F&& f, A&& arg) {
+  return f(std::forward<A>(arg));
+}
+
+// Given a callable() -> Promise<T>, promote it to a
+// PromiseFactory(A) -> Promise<T> by dropping the first argument.
+template <typename A, typename F>
+absl::enable_if_t<IsVoidCallable<ResultOf<F()>>::value,
+                  PromiseLike<decltype(std::declval<F>()())>>
+PromiseFactoryImpl(F&& f, A&&) {
+  return f();
+}
+
+// Given a callable() -> Promise<T>, name it a PromiseFactory and use it.
+template <typename F>
+absl::enable_if_t<IsVoidCallable<ResultOf<F()>>::value,
+                  PromiseLike<decltype(std::declval<F>()())>>
+PromiseFactoryImpl(F&& f) {
+  return f();
+};
+
+template <typename A, typename F>
+class PromiseFactory {
+ private:
+  GPR_NO_UNIQUE_ADDRESS F f_;
+
+ public:
+  using Arg = A;
+  using Promise =
+      decltype(PromiseFactoryImpl(std::move(f_), std::declval<A>()));
+
+  explicit PromiseFactory(F f) : f_(std::move(f)) {}
+
+  Promise Once(Arg&& a) {
+    return PromiseFactoryImpl(std::move(f_), std::forward<Arg>(a));
+  }
+
+  Promise Repeated(Arg&& a) const {
+    return PromiseFactoryImpl(f_, std::forward<Arg>(a));
+  }
+};
+
+template <typename F>
+class PromiseFactory<void, F> {
+ private:
+  GPR_NO_UNIQUE_ADDRESS F f_;
+
+ public:
+  using Arg = void;
+  using Promise = decltype(PromiseFactoryImpl(std::move(f_)));
+
+  explicit PromiseFactory(F f) : f_(std::move(f)) {}
+
+  Promise Once() { return PromiseFactoryImpl(std::move(f_)); }
+
+  Promise Repeated() const { return PromiseFactoryImpl(f_); }
+};
+
+}  // namespace promise_detail
+}  // namespace grpc_core
+
+#endif  // GRPC_CORE_LIB_PROMISE_DETAIL_PROMISE_FACTORY_H
diff --git a/src/core/lib/promise/detail/promise_like.h b/src/core/lib/promise/detail/promise_like.h
new file mode 100644 (file)
index 0000000..c80169a
--- /dev/null
@@ -0,0 +1,83 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#ifndef GRPC_CORE_LIB_PROMISE_DETAIL_PROMISE_LIKE_H
+#define GRPC_CORE_LIB_PROMISE_DETAIL_PROMISE_LIKE_H
+
+#include <grpc/impl/codegen/port_platform.h>
+
+#include <utility>
+
+#include "src/core/lib/promise/poll.h"
+
+// A Promise is a callable object that returns Poll<T> for some T.
+// Often when we're writing code that uses promises, we end up wanting to also
+// deal with code that completes instantaneously - that is, it returns some T
+// where T is not Poll.
+// PromiseLike wraps any callable that takes no parameters and implements the
+// Promise interface. For things that already return Poll, this wrapping does
+// nothing. For things that do not return Poll, we wrap the return type in Poll.
+// This allows us to write things like:
+//   Seq(
+//     [] { return 42; },
+//     ...)
+// in preference to things like:
+//   Seq(
+//     [] { return Poll<int>(42); },
+//     ...)
+// or:
+//   Seq(
+//     [] -> Poll<int> { return 42; },
+//     ...)
+// leading to slightly more concise code and eliminating some rules that in
+// practice people find hard to deal with.
+
+namespace grpc_core {
+namespace promise_detail {
+
+template <typename T>
+struct PollWrapper {
+  static Poll<T> Wrap(T&& x) { return Poll<T>(std::forward<T>(x)); }
+};
+
+template <typename T>
+struct PollWrapper<Poll<T>> {
+  static Poll<T> Wrap(Poll<T>&& x) { return std::forward<Poll<T>>(x); }
+};
+
+template <typename T>
+auto WrapInPoll(T&& x) -> decltype(PollWrapper<T>::Wrap(std::forward<T>(x))) {
+  return PollWrapper<T>::Wrap(std::forward<T>(x));
+}
+
+template <typename F>
+class PromiseLike {
+ private:
+  GPR_NO_UNIQUE_ADDRESS F f_;
+
+ public:
+  // NOLINTNEXTLINE - internal detail that drastically simplifies calling code.
+  PromiseLike(F&& f) : f_(std::forward<F>(f)) {}
+  auto operator()() -> decltype(WrapInPoll(f_())) { return WrapInPoll(f_()); }
+  using Result = typename PollTraits<decltype(WrapInPoll(f_()))>::Type;
+};
+
+// T -> T, const T& -> T
+template <typename T>
+using RemoveCVRef = absl::remove_cv_t<absl::remove_reference_t<T>>;
+
+}  // namespace promise_detail
+}  // namespace grpc_core
+
+#endif  // GRPC_CORE_LIB_PROMISE_DETAIL_PROMISE_LIKE_H
diff --git a/src/core/lib/promise/detail/status.h b/src/core/lib/promise/detail/status.h
new file mode 100644 (file)
index 0000000..8b0aa25
--- /dev/null
@@ -0,0 +1,42 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#ifndef GRPC_CORE_LIB_PROMISE_DETAIL_STATUS_H
+#define GRPC_CORE_LIB_PROMISE_DETAIL_STATUS_H
+
+#include <grpc/impl/codegen/port_platform.h>
+
+#include "absl/status/status.h"
+#include "absl/status/statusor.h"
+
+// Helpers for dealing with absl::Status/StatusOr generically
+
+namespace grpc_core {
+namespace promise_detail {
+
+// Convert with a move the input status to an absl::Status.
+template <typename T>
+absl::Status IntoStatus(absl::StatusOr<T>* status) {
+  return std::move(status->status());
+}
+
+// Convert with a move the input status to an absl::Status.
+inline absl::Status IntoStatus(absl::Status* status) {
+  return std::move(*status);
+}
+
+}  // namespace promise_detail
+}  // namespace grpc_core
+
+#endif  // GRPC_CORE_LIB_PROMISE_DETAIL_STATUS_H
diff --git a/src/core/lib/promise/detail/switch.h b/src/core/lib/promise/detail/switch.h
new file mode 100644 (file)
index 0000000..f164e23
--- /dev/null
@@ -0,0 +1,1455 @@
+/*
+ * Copyright 2021 gRPC authors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+/*
+ * Automatically generated by tools/codegen/core/gen_switch.py
+ */
+
+#ifndef GRPC_CORE_LIB_PROMISE_DETAIL_SWITCH_H
+#define GRPC_CORE_LIB_PROMISE_DETAIL_SWITCH_H
+
+#include <grpc/impl/codegen/port_platform.h>
+
+#include <stdlib.h>
+
+namespace grpc_core {
+
+template <typename R, typename F0>
+R Switch(char idx, F0 f0) {
+  switch (idx) {
+    case 0:
+      return f0();
+  }
+  abort();
+}
+
+template <typename R, typename F0, typename F1>
+R Switch(char idx, F0 f0, F1 f1) {
+  switch (idx) {
+    case 0:
+      return f0();
+    case 1:
+      return f1();
+  }
+  abort();
+}
+
+template <typename R, typename F0, typename F1, typename F2>
+R Switch(char idx, F0 f0, F1 f1, F2 f2) {
+  switch (idx) {
+    case 0:
+      return f0();
+    case 1:
+      return f1();
+    case 2:
+      return f2();
+  }
+  abort();
+}
+
+template <typename R, typename F0, typename F1, typename F2, typename F3>
+R Switch(char idx, F0 f0, F1 f1, F2 f2, F3 f3) {
+  switch (idx) {
+    case 0:
+      return f0();
+    case 1:
+      return f1();
+    case 2:
+      return f2();
+    case 3:
+      return f3();
+  }
+  abort();
+}
+
+template <typename R, typename F0, typename F1, typename F2, typename F3,
+          typename F4>
+R Switch(char idx, F0 f0, F1 f1, F2 f2, F3 f3, F4 f4) {
+  switch (idx) {
+    case 0:
+      return f0();
+    case 1:
+      return f1();
+    case 2:
+      return f2();
+    case 3:
+      return f3();
+    case 4:
+      return f4();
+  }
+  abort();
+}
+
+template <typename R, typename F0, typename F1, typename F2, typename F3,
+          typename F4, typename F5>
+R Switch(char idx, F0 f0, F1 f1, F2 f2, F3 f3, F4 f4, F5 f5) {
+  switch (idx) {
+    case 0:
+      return f0();
+    case 1:
+      return f1();
+    case 2:
+      return f2();
+    case 3:
+      return f3();
+    case 4:
+      return f4();
+    case 5:
+      return f5();
+  }
+  abort();
+}
+
+template <typename R, typename F0, typename F1, typename F2, typename F3,
+          typename F4, typename F5, typename F6>
+R Switch(char idx, F0 f0, F1 f1, F2 f2, F3 f3, F4 f4, F5 f5, F6 f6) {
+  switch (idx) {
+    case 0:
+      return f0();
+    case 1:
+      return f1();
+    case 2:
+      return f2();
+    case 3:
+      return f3();
+    case 4:
+      return f4();
+    case 5:
+      return f5();
+    case 6:
+      return f6();
+  }
+  abort();
+}
+
+template <typename R, typename F0, typename F1, typename F2, typename F3,
+          typename F4, typename F5, typename F6, typename F7>
+R Switch(char idx, F0 f0, F1 f1, F2 f2, F3 f3, F4 f4, F5 f5, F6 f6, F7 f7) {
+  switch (idx) {
+    case 0:
+      return f0();
+    case 1:
+      return f1();
+    case 2:
+      return f2();
+    case 3:
+      return f3();
+    case 4:
+      return f4();
+    case 5:
+      return f5();
+    case 6:
+      return f6();
+    case 7:
+      return f7();
+  }
+  abort();
+}
+
+template <typename R, typename F0, typename F1, typename F2, typename F3,
+          typename F4, typename F5, typename F6, typename F7, typename F8>
+R Switch(char idx, F0 f0, F1 f1, F2 f2, F3 f3, F4 f4, F5 f5, F6 f6, F7 f7,
+         F8 f8) {
+  switch (idx) {
+    case 0:
+      return f0();
+    case 1:
+      return f1();
+    case 2:
+      return f2();
+    case 3:
+      return f3();
+    case 4:
+      return f4();
+    case 5:
+      return f5();
+    case 6:
+      return f6();
+    case 7:
+      return f7();
+    case 8:
+      return f8();
+  }
+  abort();
+}
+
+template <typename R, typename F0, typename F1, typename F2, typename F3,
+          typename F4, typename F5, typename F6, typename F7, typename F8,
+          typename F9>
+R Switch(char idx, F0 f0, F1 f1, F2 f2, F3 f3, F4 f4, F5 f5, F6 f6, F7 f7,
+         F8 f8, F9 f9) {
+  switch (idx) {
+    case 0:
+      return f0();
+    case 1:
+      return f1();
+    case 2:
+      return f2();
+    case 3:
+      return f3();
+    case 4:
+      return f4();
+    case 5:
+      return f5();
+    case 6:
+      return f6();
+    case 7:
+      return f7();
+    case 8:
+      return f8();
+    case 9:
+      return f9();
+  }
+  abort();
+}
+
+template <typename R, typename F0, typename F1, typename F2, typename F3,
+          typename F4, typename F5, typename F6, typename F7, typename F8,
+          typename F9, typename F10>
+R Switch(char idx, F0 f0, F1 f1, F2 f2, F3 f3, F4 f4, F5 f5, F6 f6, F7 f7,
+         F8 f8, F9 f9, F10 f10) {
+  switch (idx) {
+    case 0:
+      return f0();
+    case 1:
+      return f1();
+    case 2:
+      return f2();
+    case 3:
+      return f3();
+    case 4:
+      return f4();
+    case 5:
+      return f5();
+    case 6:
+      return f6();
+    case 7:
+      return f7();
+    case 8:
+      return f8();
+    case 9:
+      return f9();
+    case 10:
+      return f10();
+  }
+  abort();
+}
+
+template <typename R, typename F0, typename F1, typename F2, typename F3,
+          typename F4, typename F5, typename F6, typename F7, typename F8,
+          typename F9, typename F10, typename F11>
+R Switch(char idx, F0 f0, F1 f1, F2 f2, F3 f3, F4 f4, F5 f5, F6 f6, F7 f7,
+         F8 f8, F9 f9, F10 f10, F11 f11) {
+  switch (idx) {
+    case 0:
+      return f0();
+    case 1:
+      return f1();
+    case 2:
+      return f2();
+    case 3:
+      return f3();
+    case 4:
+      return f4();
+    case 5:
+      return f5();
+    case 6:
+      return f6();
+    case 7:
+      return f7();
+    case 8:
+      return f8();
+    case 9:
+      return f9();
+    case 10:
+      return f10();
+    case 11:
+      return f11();
+  }
+  abort();
+}
+
+template <typename R, typename F0, typename F1, typename F2, typename F3,
+          typename F4, typename F5, typename F6, typename F7, typename F8,
+          typename F9, typename F10, typename F11, typename F12>
+R Switch(char idx, F0 f0, F1 f1, F2 f2, F3 f3, F4 f4, F5 f5, F6 f6, F7 f7,
+         F8 f8, F9 f9, F10 f10, F11 f11, F12 f12) {
+  switch (idx) {
+    case 0:
+      return f0();
+    case 1:
+      return f1();
+    case 2:
+      return f2();
+    case 3:
+      return f3();
+    case 4:
+      return f4();
+    case 5:
+      return f5();
+    case 6:
+      return f6();
+    case 7:
+      return f7();
+    case 8:
+      return f8();
+    case 9:
+      return f9();
+    case 10:
+      return f10();
+    case 11:
+      return f11();
+    case 12:
+      return f12();
+  }
+  abort();
+}
+
+template <typename R, typename F0, typename F1, typename F2, typename F3,
+          typename F4, typename F5, typename F6, typename F7, typename F8,
+          typename F9, typename F10, typename F11, typename F12, typename F13>
+R Switch(char idx, F0 f0, F1 f1, F2 f2, F3 f3, F4 f4, F5 f5, F6 f6, F7 f7,
+         F8 f8, F9 f9, F10 f10, F11 f11, F12 f12, F13 f13) {
+  switch (idx) {
+    case 0:
+      return f0();
+    case 1:
+      return f1();
+    case 2:
+      return f2();
+    case 3:
+      return f3();
+    case 4:
+      return f4();
+    case 5:
+      return f5();
+    case 6:
+      return f6();
+    case 7:
+      return f7();
+    case 8:
+      return f8();
+    case 9:
+      return f9();
+    case 10:
+      return f10();
+    case 11:
+      return f11();
+    case 12:
+      return f12();
+    case 13:
+      return f13();
+  }
+  abort();
+}
+
+template <typename R, typename F0, typename F1, typename F2, typename F3,
+          typename F4, typename F5, typename F6, typename F7, typename F8,
+          typename F9, typename F10, typename F11, typename F12, typename F13,
+          typename F14>
+R Switch(char idx, F0 f0, F1 f1, F2 f2, F3 f3, F4 f4, F5 f5, F6 f6, F7 f7,
+         F8 f8, F9 f9, F10 f10, F11 f11, F12 f12, F13 f13, F14 f14) {
+  switch (idx) {
+    case 0:
+      return f0();
+    case 1:
+      return f1();
+    case 2:
+      return f2();
+    case 3:
+      return f3();
+    case 4:
+      return f4();
+    case 5:
+      return f5();
+    case 6:
+      return f6();
+    case 7:
+      return f7();
+    case 8:
+      return f8();
+    case 9:
+      return f9();
+    case 10:
+      return f10();
+    case 11:
+      return f11();
+    case 12:
+      return f12();
+    case 13:
+      return f13();
+    case 14:
+      return f14();
+  }
+  abort();
+}
+
+template <typename R, typename F0, typename F1, typename F2, typename F3,
+          typename F4, typename F5, typename F6, typename F7, typename F8,
+          typename F9, typename F10, typename F11, typename F12, typename F13,
+          typename F14, typename F15>
+R Switch(char idx, F0 f0, F1 f1, F2 f2, F3 f3, F4 f4, F5 f5, F6 f6, F7 f7,
+         F8 f8, F9 f9, F10 f10, F11 f11, F12 f12, F13 f13, F14 f14, F15 f15) {
+  switch (idx) {
+    case 0:
+      return f0();
+    case 1:
+      return f1();
+    case 2:
+      return f2();
+    case 3:
+      return f3();
+    case 4:
+      return f4();
+    case 5:
+      return f5();
+    case 6:
+      return f6();
+    case 7:
+      return f7();
+    case 8:
+      return f8();
+    case 9:
+      return f9();
+    case 10:
+      return f10();
+    case 11:
+      return f11();
+    case 12:
+      return f12();
+    case 13:
+      return f13();
+    case 14:
+      return f14();
+    case 15:
+      return f15();
+  }
+  abort();
+}
+
+template <typename R, typename F0, typename F1, typename F2, typename F3,
+          typename F4, typename F5, typename F6, typename F7, typename F8,
+          typename F9, typename F10, typename F11, typename F12, typename F13,
+          typename F14, typename F15, typename F16>
+R Switch(char idx, F0 f0, F1 f1, F2 f2, F3 f3, F4 f4, F5 f5, F6 f6, F7 f7,
+         F8 f8, F9 f9, F10 f10, F11 f11, F12 f12, F13 f13, F14 f14, F15 f15,
+         F16 f16) {
+  switch (idx) {
+    case 0:
+      return f0();
+    case 1:
+      return f1();
+    case 2:
+      return f2();
+    case 3:
+      return f3();
+    case 4:
+      return f4();
+    case 5:
+      return f5();
+    case 6:
+      return f6();
+    case 7:
+      return f7();
+    case 8:
+      return f8();
+    case 9:
+      return f9();
+    case 10:
+      return f10();
+    case 11:
+      return f11();
+    case 12:
+      return f12();
+    case 13:
+      return f13();
+    case 14:
+      return f14();
+    case 15:
+      return f15();
+    case 16:
+      return f16();
+  }
+  abort();
+}
+
+template <typename R, typename F0, typename F1, typename F2, typename F3,
+          typename F4, typename F5, typename F6, typename F7, typename F8,
+          typename F9, typename F10, typename F11, typename F12, typename F13,
+          typename F14, typename F15, typename F16, typename F17>
+R Switch(char idx, F0 f0, F1 f1, F2 f2, F3 f3, F4 f4, F5 f5, F6 f6, F7 f7,
+         F8 f8, F9 f9, F10 f10, F11 f11, F12 f12, F13 f13, F14 f14, F15 f15,
+         F16 f16, F17 f17) {
+  switch (idx) {
+    case 0:
+      return f0();
+    case 1:
+      return f1();
+    case 2:
+      return f2();
+    case 3:
+      return f3();
+    case 4:
+      return f4();
+    case 5:
+      return f5();
+    case 6:
+      return f6();
+    case 7:
+      return f7();
+    case 8:
+      return f8();
+    case 9:
+      return f9();
+    case 10:
+      return f10();
+    case 11:
+      return f11();
+    case 12:
+      return f12();
+    case 13:
+      return f13();
+    case 14:
+      return f14();
+    case 15:
+      return f15();
+    case 16:
+      return f16();
+    case 17:
+      return f17();
+  }
+  abort();
+}
+
+template <typename R, typename F0, typename F1, typename F2, typename F3,
+          typename F4, typename F5, typename F6, typename F7, typename F8,
+          typename F9, typename F10, typename F11, typename F12, typename F13,
+          typename F14, typename F15, typename F16, typename F17, typename F18>
+R Switch(char idx, F0 f0, F1 f1, F2 f2, F3 f3, F4 f4, F5 f5, F6 f6, F7 f7,
+         F8 f8, F9 f9, F10 f10, F11 f11, F12 f12, F13 f13, F14 f14, F15 f15,
+         F16 f16, F17 f17, F18 f18) {
+  switch (idx) {
+    case 0:
+      return f0();
+    case 1:
+      return f1();
+    case 2:
+      return f2();
+    case 3:
+      return f3();
+    case 4:
+      return f4();
+    case 5:
+      return f5();
+    case 6:
+      return f6();
+    case 7:
+      return f7();
+    case 8:
+      return f8();
+    case 9:
+      return f9();
+    case 10:
+      return f10();
+    case 11:
+      return f11();
+    case 12:
+      return f12();
+    case 13:
+      return f13();
+    case 14:
+      return f14();
+    case 15:
+      return f15();
+    case 16:
+      return f16();
+    case 17:
+      return f17();
+    case 18:
+      return f18();
+  }
+  abort();
+}
+
+template <typename R, typename F0, typename F1, typename F2, typename F3,
+          typename F4, typename F5, typename F6, typename F7, typename F8,
+          typename F9, typename F10, typename F11, typename F12, typename F13,
+          typename F14, typename F15, typename F16, typename F17, typename F18,
+          typename F19>
+R Switch(char idx, F0 f0, F1 f1, F2 f2, F3 f3, F4 f4, F5 f5, F6 f6, F7 f7,
+         F8 f8, F9 f9, F10 f10, F11 f11, F12 f12, F13 f13, F14 f14, F15 f15,
+         F16 f16, F17 f17, F18 f18, F19 f19) {
+  switch (idx) {
+    case 0:
+      return f0();
+    case 1:
+      return f1();
+    case 2:
+      return f2();
+    case 3:
+      return f3();
+    case 4:
+      return f4();
+    case 5:
+      return f5();
+    case 6:
+      return f6();
+    case 7:
+      return f7();
+    case 8:
+      return f8();
+    case 9:
+      return f9();
+    case 10:
+      return f10();
+    case 11:
+      return f11();
+    case 12:
+      return f12();
+    case 13:
+      return f13();
+    case 14:
+      return f14();
+    case 15:
+      return f15();
+    case 16:
+      return f16();
+    case 17:
+      return f17();
+    case 18:
+      return f18();
+    case 19:
+      return f19();
+  }
+  abort();
+}
+
+template <typename R, typename F0, typename F1, typename F2, typename F3,
+          typename F4, typename F5, typename F6, typename F7, typename F8,
+          typename F9, typename F10, typename F11, typename F12, typename F13,
+          typename F14, typename F15, typename F16, typename F17, typename F18,
+          typename F19, typename F20>
+R Switch(char idx, F0 f0, F1 f1, F2 f2, F3 f3, F4 f4, F5 f5, F6 f6, F7 f7,
+         F8 f8, F9 f9, F10 f10, F11 f11, F12 f12, F13 f13, F14 f14, F15 f15,
+         F16 f16, F17 f17, F18 f18, F19 f19, F20 f20) {
+  switch (idx) {
+    case 0:
+      return f0();
+    case 1:
+      return f1();
+    case 2:
+      return f2();
+    case 3:
+      return f3();
+    case 4:
+      return f4();
+    case 5:
+      return f5();
+    case 6:
+      return f6();
+    case 7:
+      return f7();
+    case 8:
+      return f8();
+    case 9:
+      return f9();
+    case 10:
+      return f10();
+    case 11:
+      return f11();
+    case 12:
+      return f12();
+    case 13:
+      return f13();
+    case 14:
+      return f14();
+    case 15:
+      return f15();
+    case 16:
+      return f16();
+    case 17:
+      return f17();
+    case 18:
+      return f18();
+    case 19:
+      return f19();
+    case 20:
+      return f20();
+  }
+  abort();
+}
+
+template <typename R, typename F0, typename F1, typename F2, typename F3,
+          typename F4, typename F5, typename F6, typename F7, typename F8,
+          typename F9, typename F10, typename F11, typename F12, typename F13,
+          typename F14, typename F15, typename F16, typename F17, typename F18,
+          typename F19, typename F20, typename F21>
+R Switch(char idx, F0 f0, F1 f1, F2 f2, F3 f3, F4 f4, F5 f5, F6 f6, F7 f7,
+         F8 f8, F9 f9, F10 f10, F11 f11, F12 f12, F13 f13, F14 f14, F15 f15,
+         F16 f16, F17 f17, F18 f18, F19 f19, F20 f20, F21 f21) {
+  switch (idx) {
+    case 0:
+      return f0();
+    case 1:
+      return f1();
+    case 2:
+      return f2();
+    case 3:
+      return f3();
+    case 4:
+      return f4();
+    case 5:
+      return f5();
+    case 6:
+      return f6();
+    case 7:
+      return f7();
+    case 8:
+      return f8();
+    case 9:
+      return f9();
+    case 10:
+      return f10();
+    case 11:
+      return f11();
+    case 12:
+      return f12();
+    case 13:
+      return f13();
+    case 14:
+      return f14();
+    case 15:
+      return f15();
+    case 16:
+      return f16();
+    case 17:
+      return f17();
+    case 18:
+      return f18();
+    case 19:
+      return f19();
+    case 20:
+      return f20();
+    case 21:
+      return f21();
+  }
+  abort();
+}
+
+template <typename R, typename F0, typename F1, typename F2, typename F3,
+          typename F4, typename F5, typename F6, typename F7, typename F8,
+          typename F9, typename F10, typename F11, typename F12, typename F13,
+          typename F14, typename F15, typename F16, typename F17, typename F18,
+          typename F19, typename F20, typename F21, typename F22>
+R Switch(char idx, F0 f0, F1 f1, F2 f2, F3 f3, F4 f4, F5 f5, F6 f6, F7 f7,
+         F8 f8, F9 f9, F10 f10, F11 f11, F12 f12, F13 f13, F14 f14, F15 f15,
+         F16 f16, F17 f17, F18 f18, F19 f19, F20 f20, F21 f21, F22 f22) {
+  switch (idx) {
+    case 0:
+      return f0();
+    case 1:
+      return f1();
+    case 2:
+      return f2();
+    case 3:
+      return f3();
+    case 4:
+      return f4();
+    case 5:
+      return f5();
+    case 6:
+      return f6();
+    case 7:
+      return f7();
+    case 8:
+      return f8();
+    case 9:
+      return f9();
+    case 10:
+      return f10();
+    case 11:
+      return f11();
+    case 12:
+      return f12();
+    case 13:
+      return f13();
+    case 14:
+      return f14();
+    case 15:
+      return f15();
+    case 16:
+      return f16();
+    case 17:
+      return f17();
+    case 18:
+      return f18();
+    case 19:
+      return f19();
+    case 20:
+      return f20();
+    case 21:
+      return f21();
+    case 22:
+      return f22();
+  }
+  abort();
+}
+
+template <typename R, typename F0, typename F1, typename F2, typename F3,
+          typename F4, typename F5, typename F6, typename F7, typename F8,
+          typename F9, typename F10, typename F11, typename F12, typename F13,
+          typename F14, typename F15, typename F16, typename F17, typename F18,
+          typename F19, typename F20, typename F21, typename F22, typename F23>
+R Switch(char idx, F0 f0, F1 f1, F2 f2, F3 f3, F4 f4, F5 f5, F6 f6, F7 f7,
+         F8 f8, F9 f9, F10 f10, F11 f11, F12 f12, F13 f13, F14 f14, F15 f15,
+         F16 f16, F17 f17, F18 f18, F19 f19, F20 f20, F21 f21, F22 f22,
+         F23 f23) {
+  switch (idx) {
+    case 0:
+      return f0();
+    case 1:
+      return f1();
+    case 2:
+      return f2();
+    case 3:
+      return f3();
+    case 4:
+      return f4();
+    case 5:
+      return f5();
+    case 6:
+      return f6();
+    case 7:
+      return f7();
+    case 8:
+      return f8();
+    case 9:
+      return f9();
+    case 10:
+      return f10();
+    case 11:
+      return f11();
+    case 12:
+      return f12();
+    case 13:
+      return f13();
+    case 14:
+      return f14();
+    case 15:
+      return f15();
+    case 16:
+      return f16();
+    case 17:
+      return f17();
+    case 18:
+      return f18();
+    case 19:
+      return f19();
+    case 20:
+      return f20();
+    case 21:
+      return f21();
+    case 22:
+      return f22();
+    case 23:
+      return f23();
+  }
+  abort();
+}
+
+template <typename R, typename F0, typename F1, typename F2, typename F3,
+          typename F4, typename F5, typename F6, typename F7, typename F8,
+          typename F9, typename F10, typename F11, typename F12, typename F13,
+          typename F14, typename F15, typename F16, typename F17, typename F18,
+          typename F19, typename F20, typename F21, typename F22, typename F23,
+          typename F24>
+R Switch(char idx, F0 f0, F1 f1, F2 f2, F3 f3, F4 f4, F5 f5, F6 f6, F7 f7,
+         F8 f8, F9 f9, F10 f10, F11 f11, F12 f12, F13 f13, F14 f14, F15 f15,
+         F16 f16, F17 f17, F18 f18, F19 f19, F20 f20, F21 f21, F22 f22, F23 f23,
+         F24 f24) {
+  switch (idx) {
+    case 0:
+      return f0();
+    case 1:
+      return f1();
+    case 2:
+      return f2();
+    case 3:
+      return f3();
+    case 4:
+      return f4();
+    case 5:
+      return f5();
+    case 6:
+      return f6();
+    case 7:
+      return f7();
+    case 8:
+      return f8();
+    case 9:
+      return f9();
+    case 10:
+      return f10();
+    case 11:
+      return f11();
+    case 12:
+      return f12();
+    case 13:
+      return f13();
+    case 14:
+      return f14();
+    case 15:
+      return f15();
+    case 16:
+      return f16();
+    case 17:
+      return f17();
+    case 18:
+      return f18();
+    case 19:
+      return f19();
+    case 20:
+      return f20();
+    case 21:
+      return f21();
+    case 22:
+      return f22();
+    case 23:
+      return f23();
+    case 24:
+      return f24();
+  }
+  abort();
+}
+
+template <typename R, typename F0, typename F1, typename F2, typename F3,
+          typename F4, typename F5, typename F6, typename F7, typename F8,
+          typename F9, typename F10, typename F11, typename F12, typename F13,
+          typename F14, typename F15, typename F16, typename F17, typename F18,
+          typename F19, typename F20, typename F21, typename F22, typename F23,
+          typename F24, typename F25>
+R Switch(char idx, F0 f0, F1 f1, F2 f2, F3 f3, F4 f4, F5 f5, F6 f6, F7 f7,
+         F8 f8, F9 f9, F10 f10, F11 f11, F12 f12, F13 f13, F14 f14, F15 f15,
+         F16 f16, F17 f17, F18 f18, F19 f19, F20 f20, F21 f21, F22 f22, F23 f23,
+         F24 f24, F25 f25) {
+  switch (idx) {
+    case 0:
+      return f0();
+    case 1:
+      return f1();
+    case 2:
+      return f2();
+    case 3:
+      return f3();
+    case 4:
+      return f4();
+    case 5:
+      return f5();
+    case 6:
+      return f6();
+    case 7:
+      return f7();
+    case 8:
+      return f8();
+    case 9:
+      return f9();
+    case 10:
+      return f10();
+    case 11:
+      return f11();
+    case 12:
+      return f12();
+    case 13:
+      return f13();
+    case 14:
+      return f14();
+    case 15:
+      return f15();
+    case 16:
+      return f16();
+    case 17:
+      return f17();
+    case 18:
+      return f18();
+    case 19:
+      return f19();
+    case 20:
+      return f20();
+    case 21:
+      return f21();
+    case 22:
+      return f22();
+    case 23:
+      return f23();
+    case 24:
+      return f24();
+    case 25:
+      return f25();
+  }
+  abort();
+}
+
+template <typename R, typename F0, typename F1, typename F2, typename F3,
+          typename F4, typename F5, typename F6, typename F7, typename F8,
+          typename F9, typename F10, typename F11, typename F12, typename F13,
+          typename F14, typename F15, typename F16, typename F17, typename F18,
+          typename F19, typename F20, typename F21, typename F22, typename F23,
+          typename F24, typename F25, typename F26>
+R Switch(char idx, F0 f0, F1 f1, F2 f2, F3 f3, F4 f4, F5 f5, F6 f6, F7 f7,
+         F8 f8, F9 f9, F10 f10, F11 f11, F12 f12, F13 f13, F14 f14, F15 f15,
+         F16 f16, F17 f17, F18 f18, F19 f19, F20 f20, F21 f21, F22 f22, F23 f23,
+         F24 f24, F25 f25, F26 f26) {
+  switch (idx) {
+    case 0:
+      return f0();
+    case 1:
+      return f1();
+    case 2:
+      return f2();
+    case 3:
+      return f3();
+    case 4:
+      return f4();
+    case 5:
+      return f5();
+    case 6:
+      return f6();
+    case 7:
+      return f7();
+    case 8:
+      return f8();
+    case 9:
+      return f9();
+    case 10:
+      return f10();
+    case 11:
+      return f11();
+    case 12:
+      return f12();
+    case 13:
+      return f13();
+    case 14:
+      return f14();
+    case 15:
+      return f15();
+    case 16:
+      return f16();
+    case 17:
+      return f17();
+    case 18:
+      return f18();
+    case 19:
+      return f19();
+    case 20:
+      return f20();
+    case 21:
+      return f21();
+    case 22:
+      return f22();
+    case 23:
+      return f23();
+    case 24:
+      return f24();
+    case 25:
+      return f25();
+    case 26:
+      return f26();
+  }
+  abort();
+}
+
+template <typename R, typename F0, typename F1, typename F2, typename F3,
+          typename F4, typename F5, typename F6, typename F7, typename F8,
+          typename F9, typename F10, typename F11, typename F12, typename F13,
+          typename F14, typename F15, typename F16, typename F17, typename F18,
+          typename F19, typename F20, typename F21, typename F22, typename F23,
+          typename F24, typename F25, typename F26, typename F27>
+R Switch(char idx, F0 f0, F1 f1, F2 f2, F3 f3, F4 f4, F5 f5, F6 f6, F7 f7,
+         F8 f8, F9 f9, F10 f10, F11 f11, F12 f12, F13 f13, F14 f14, F15 f15,
+         F16 f16, F17 f17, F18 f18, F19 f19, F20 f20, F21 f21, F22 f22, F23 f23,
+         F24 f24, F25 f25, F26 f26, F27 f27) {
+  switch (idx) {
+    case 0:
+      return f0();
+    case 1:
+      return f1();
+    case 2:
+      return f2();
+    case 3:
+      return f3();
+    case 4:
+      return f4();
+    case 5:
+      return f5();
+    case 6:
+      return f6();
+    case 7:
+      return f7();
+    case 8:
+      return f8();
+    case 9:
+      return f9();
+    case 10:
+      return f10();
+    case 11:
+      return f11();
+    case 12:
+      return f12();
+    case 13:
+      return f13();
+    case 14:
+      return f14();
+    case 15:
+      return f15();
+    case 16:
+      return f16();
+    case 17:
+      return f17();
+    case 18:
+      return f18();
+    case 19:
+      return f19();
+    case 20:
+      return f20();
+    case 21:
+      return f21();
+    case 22:
+      return f22();
+    case 23:
+      return f23();
+    case 24:
+      return f24();
+    case 25:
+      return f25();
+    case 26:
+      return f26();
+    case 27:
+      return f27();
+  }
+  abort();
+}
+
+template <typename R, typename F0, typename F1, typename F2, typename F3,
+          typename F4, typename F5, typename F6, typename F7, typename F8,
+          typename F9, typename F10, typename F11, typename F12, typename F13,
+          typename F14, typename F15, typename F16, typename F17, typename F18,
+          typename F19, typename F20, typename F21, typename F22, typename F23,
+          typename F24, typename F25, typename F26, typename F27, typename F28>
+R Switch(char idx, F0 f0, F1 f1, F2 f2, F3 f3, F4 f4, F5 f5, F6 f6, F7 f7,
+         F8 f8, F9 f9, F10 f10, F11 f11, F12 f12, F13 f13, F14 f14, F15 f15,
+         F16 f16, F17 f17, F18 f18, F19 f19, F20 f20, F21 f21, F22 f22, F23 f23,
+         F24 f24, F25 f25, F26 f26, F27 f27, F28 f28) {
+  switch (idx) {
+    case 0:
+      return f0();
+    case 1:
+      return f1();
+    case 2:
+      return f2();
+    case 3:
+      return f3();
+    case 4:
+      return f4();
+    case 5:
+      return f5();
+    case 6:
+      return f6();
+    case 7:
+      return f7();
+    case 8:
+      return f8();
+    case 9:
+      return f9();
+    case 10:
+      return f10();
+    case 11:
+      return f11();
+    case 12:
+      return f12();
+    case 13:
+      return f13();
+    case 14:
+      return f14();
+    case 15:
+      return f15();
+    case 16:
+      return f16();
+    case 17:
+      return f17();
+    case 18:
+      return f18();
+    case 19:
+      return f19();
+    case 20:
+      return f20();
+    case 21:
+      return f21();
+    case 22:
+      return f22();
+    case 23:
+      return f23();
+    case 24:
+      return f24();
+    case 25:
+      return f25();
+    case 26:
+      return f26();
+    case 27:
+      return f27();
+    case 28:
+      return f28();
+  }
+  abort();
+}
+
+template <typename R, typename F0, typename F1, typename F2, typename F3,
+          typename F4, typename F5, typename F6, typename F7, typename F8,
+          typename F9, typename F10, typename F11, typename F12, typename F13,
+          typename F14, typename F15, typename F16, typename F17, typename F18,
+          typename F19, typename F20, typename F21, typename F22, typename F23,
+          typename F24, typename F25, typename F26, typename F27, typename F28,
+          typename F29>
+R Switch(char idx, F0 f0, F1 f1, F2 f2, F3 f3, F4 f4, F5 f5, F6 f6, F7 f7,
+         F8 f8, F9 f9, F10 f10, F11 f11, F12 f12, F13 f13, F14 f14, F15 f15,
+         F16 f16, F17 f17, F18 f18, F19 f19, F20 f20, F21 f21, F22 f22, F23 f23,
+         F24 f24, F25 f25, F26 f26, F27 f27, F28 f28, F29 f29) {
+  switch (idx) {
+    case 0:
+      return f0();
+    case 1:
+      return f1();
+    case 2:
+      return f2();
+    case 3:
+      return f3();
+    case 4:
+      return f4();
+    case 5:
+      return f5();
+    case 6:
+      return f6();
+    case 7:
+      return f7();
+    case 8:
+      return f8();
+    case 9:
+      return f9();
+    case 10:
+      return f10();
+    case 11:
+      return f11();
+    case 12:
+      return f12();
+    case 13:
+      return f13();
+    case 14:
+      return f14();
+    case 15:
+      return f15();
+    case 16:
+      return f16();
+    case 17:
+      return f17();
+    case 18:
+      return f18();
+    case 19:
+      return f19();
+    case 20:
+      return f20();
+    case 21:
+      return f21();
+    case 22:
+      return f22();
+    case 23:
+      return f23();
+    case 24:
+      return f24();
+    case 25:
+      return f25();
+    case 26:
+      return f26();
+    case 27:
+      return f27();
+    case 28:
+      return f28();
+    case 29:
+      return f29();
+  }
+  abort();
+}
+
+template <typename R, typename F0, typename F1, typename F2, typename F3,
+          typename F4, typename F5, typename F6, typename F7, typename F8,
+          typename F9, typename F10, typename F11, typename F12, typename F13,
+          typename F14, typename F15, typename F16, typename F17, typename F18,
+          typename F19, typename F20, typename F21, typename F22, typename F23,
+          typename F24, typename F25, typename F26, typename F27, typename F28,
+          typename F29, typename F30>
+R Switch(char idx, F0 f0, F1 f1, F2 f2, F3 f3, F4 f4, F5 f5, F6 f6, F7 f7,
+         F8 f8, F9 f9, F10 f10, F11 f11, F12 f12, F13 f13, F14 f14, F15 f15,
+         F16 f16, F17 f17, F18 f18, F19 f19, F20 f20, F21 f21, F22 f22, F23 f23,
+         F24 f24, F25 f25, F26 f26, F27 f27, F28 f28, F29 f29, F30 f30) {
+  switch (idx) {
+    case 0:
+      return f0();
+    case 1:
+      return f1();
+    case 2:
+      return f2();
+    case 3:
+      return f3();
+    case 4:
+      return f4();
+    case 5:
+      return f5();
+    case 6:
+      return f6();
+    case 7:
+      return f7();
+    case 8:
+      return f8();
+    case 9:
+      return f9();
+    case 10:
+      return f10();
+    case 11:
+      return f11();
+    case 12:
+      return f12();
+    case 13:
+      return f13();
+    case 14:
+      return f14();
+    case 15:
+      return f15();
+    case 16:
+      return f16();
+    case 17:
+      return f17();
+    case 18:
+      return f18();
+    case 19:
+      return f19();
+    case 20:
+      return f20();
+    case 21:
+      return f21();
+    case 22:
+      return f22();
+    case 23:
+      return f23();
+    case 24:
+      return f24();
+    case 25:
+      return f25();
+    case 26:
+      return f26();
+    case 27:
+      return f27();
+    case 28:
+      return f28();
+    case 29:
+      return f29();
+    case 30:
+      return f30();
+  }
+  abort();
+}
+
+template <typename R, typename F0, typename F1, typename F2, typename F3,
+          typename F4, typename F5, typename F6, typename F7, typename F8,
+          typename F9, typename F10, typename F11, typename F12, typename F13,
+          typename F14, typename F15, typename F16, typename F17, typename F18,
+          typename F19, typename F20, typename F21, typename F22, typename F23,
+          typename F24, typename F25, typename F26, typename F27, typename F28,
+          typename F29, typename F30, typename F31>
+R Switch(char idx, F0 f0, F1 f1, F2 f2, F3 f3, F4 f4, F5 f5, F6 f6, F7 f7,
+         F8 f8, F9 f9, F10 f10, F11 f11, F12 f12, F13 f13, F14 f14, F15 f15,
+         F16 f16, F17 f17, F18 f18, F19 f19, F20 f20, F21 f21, F22 f22, F23 f23,
+         F24 f24, F25 f25, F26 f26, F27 f27, F28 f28, F29 f29, F30 f30,
+         F31 f31) {
+  switch (idx) {
+    case 0:
+      return f0();
+    case 1:
+      return f1();
+    case 2:
+      return f2();
+    case 3:
+      return f3();
+    case 4:
+      return f4();
+    case 5:
+      return f5();
+    case 6:
+      return f6();
+    case 7:
+      return f7();
+    case 8:
+      return f8();
+    case 9:
+      return f9();
+    case 10:
+      return f10();
+    case 11:
+      return f11();
+    case 12:
+      return f12();
+    case 13:
+      return f13();
+    case 14:
+      return f14();
+    case 15:
+      return f15();
+    case 16:
+      return f16();
+    case 17:
+      return f17();
+    case 18:
+      return f18();
+    case 19:
+      return f19();
+    case 20:
+      return f20();
+    case 21:
+      return f21();
+    case 22:
+      return f22();
+    case 23:
+      return f23();
+    case 24:
+      return f24();
+    case 25:
+      return f25();
+    case 26:
+      return f26();
+    case 27:
+      return f27();
+    case 28:
+      return f28();
+    case 29:
+      return f29();
+    case 30:
+      return f30();
+    case 31:
+      return f31();
+  }
+  abort();
+}
+
+}  // namespace grpc_core
+
+#endif  // GRPC_CORE_LIB_PROMISE_DETAIL_SWITCH_H
diff --git a/src/core/lib/promise/for_each.h b/src/core/lib/promise/for_each.h
new file mode 100644 (file)
index 0000000..c9136ee
--- /dev/null
@@ -0,0 +1,136 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#ifndef GRPC_CORE_LIB_PROMISE_FOR_EACH_H
+#define GRPC_CORE_LIB_PROMISE_FOR_EACH_H
+
+#include <grpc/impl/codegen/port_platform.h>
+
+#include "absl/status/status.h"
+#include "absl/types/variant.h"
+
+#include "src/core/lib/promise/detail/promise_factory.h"
+#include "src/core/lib/promise/poll.h"
+
+namespace grpc_core {
+
+namespace for_each_detail {
+
+// Helper function: at the end of each iteration of a for-each loop, this is
+// called. If the iteration failed, return failure. If the iteration succeeded,
+// then call the next iteration.
+template <typename Reader, typename CallPoll>
+Poll<absl::Status> FinishIteration(absl::Status* r, Reader* reader,
+                                   CallPoll call_poll) {
+  if (r->ok()) {
+    auto next = reader->Next();
+    return call_poll(next);
+  }
+  return std::move(*r);
+}
+
+// Done creates statuses for the end of the iteration. It's templated on the
+// type of the result of the ForEach loop, so that we can introduce new types
+// easily.
+template <typename T>
+struct Done;
+template <>
+struct Done<absl::Status> {
+  static absl::Status Make() { return absl::OkStatus(); }
+};
+
+template <typename Reader, typename Action>
+class ForEach {
+ private:
+  using ReaderNext = decltype(std::declval<Reader>().Next());
+  using ReaderResult = typename PollTraits<decltype(
+      std::declval<ReaderNext>()())>::Type::value_type;
+  using ActionFactory = promise_detail::PromiseFactory<ReaderResult, Action>;
+  using ActionPromise = typename ActionFactory::Promise;
+
+ public:
+  using Result =
+      typename PollTraits<decltype(std::declval<ActionPromise>()())>::Type;
+  ForEach(Reader reader, Action action)
+      : reader_(std::move(reader)),
+        action_factory_(std::move(action)),
+        state_(reader_.Next()) {}
+
+  ForEach(const ForEach&) = delete;
+  ForEach& operator=(const ForEach&) = delete;
+  // noexcept causes compiler errors on older gcc's
+  // NOLINTNEXTLINE(performance-noexcept-move-constructor)
+  ForEach(ForEach&&) = default;
+  // noexcept causes compiler errors on older gcc's
+  // NOLINTNEXTLINE(performance-noexcept-move-constructor)
+  ForEach& operator=(ForEach&&) = default;
+
+  Poll<Result> operator()() {
+    return absl::visit(CallPoll<false>{this}, state_);
+  }
+
+ private:
+  Reader reader_;
+  ActionFactory action_factory_;
+  absl::variant<ReaderNext, ActionPromise> state_;
+
+  // Call the inner poll function, and if it's finished, start the next
+  // iteration. If kSetState==true, also set the current state in self->state_.
+  // We omit that on the first iteration because it's common to poll once and
+  // not change state, which saves us some work.
+  template <bool kSetState>
+  struct CallPoll {
+    ForEach* const self;
+
+    Poll<Result> operator()(ReaderNext& reader_next) {
+      auto r = reader_next();
+      if (auto* p = absl::get_if<kPollReadyIdx>(&r)) {
+        if (p->has_value()) {
+          auto action = self->action_factory_.Repeated(std::move(**p));
+          return CallPoll<true>{self}(action);
+        } else {
+          return Done<Result>::Make();
+        }
+      }
+      if (kSetState) {
+        self->state_.template emplace<ReaderNext>(std::move(reader_next));
+      }
+      return Pending();
+    }
+
+    Poll<Result> operator()(ActionPromise& promise) {
+      auto r = promise();
+      if (auto* p = absl::get_if<kPollReadyIdx>(&r)) {
+        return FinishIteration(p, &self->reader_, CallPoll<true>{self});
+      }
+      if (kSetState) {
+        self->state_.template emplace<ActionPromise>(std::move(promise));
+      }
+      return Pending();
+    }
+  };
+};
+
+}  // namespace for_each_detail
+
+/// For each item acquired by calling Reader::Next, run the promise Action.
+template <typename Reader, typename Action>
+for_each_detail::ForEach<Reader, Action> ForEach(Reader reader, Action action) {
+  return for_each_detail::ForEach<Reader, Action>(std::move(reader),
+                                                  std::move(action));
+}
+
+}  // namespace grpc_core
+
+#endif  // GRPC_CORE_LIB_PROMISE_FOR_EACH_H
diff --git a/src/core/lib/promise/if.h b/src/core/lib/promise/if.h
new file mode 100644 (file)
index 0000000..5c13105
--- /dev/null
@@ -0,0 +1,131 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#ifndef GRPC_CORE_LIB_PROMISE_IF_H
+#define GRPC_CORE_LIB_PROMISE_IF_H
+
+#include <grpc/impl/codegen/port_platform.h>
+
+#include "absl/status/statusor.h"
+#include "absl/types/variant.h"
+
+#include "src/core/lib/promise/detail/promise_factory.h"
+#include "src/core/lib/promise/poll.h"
+
+namespace grpc_core {
+
+namespace promise_detail {
+
+template <typename CallPoll, typename T, typename F>
+typename CallPoll::PollResult ChooseIf(CallPoll call_poll, bool result,
+                                       T* if_true, F* if_false) {
+  if (result) {
+    auto promise = if_true->Once();
+    return call_poll(promise);
+  } else {
+    auto promise = if_false->Once();
+    return call_poll(promise);
+  }
+}
+
+template <typename CallPoll, typename T, typename F>
+typename CallPoll::PollResult ChooseIf(CallPoll call_poll,
+                                       absl::StatusOr<bool> result, T* if_true,
+                                       F* if_false) {
+  if (!result.ok()) {
+    return typename CallPoll::PollResult(result.status());
+  } else if (*result) {
+    auto promise = if_true->Once();
+    return call_poll(promise);
+  } else {
+    auto promise = if_false->Once();
+    return call_poll(promise);
+  }
+}
+
+template <typename C, typename T, typename F>
+class If {
+ private:
+  using TrueFactory = promise_detail::PromiseFactory<void, T>;
+  using FalseFactory = promise_detail::PromiseFactory<void, F>;
+  using ConditionPromise = PromiseLike<C>;
+  using TruePromise = typename TrueFactory::Promise;
+  using FalsePromise = typename FalseFactory::Promise;
+  using Result =
+      typename PollTraits<decltype(std::declval<TruePromise>()())>::Type;
+
+ public:
+  If(C condition, T if_true, F if_false)
+      : state_(Evaluating{ConditionPromise(std::move(condition)),
+                          TrueFactory(std::move(if_true)),
+                          FalseFactory(std::move(if_false))}) {}
+
+  Poll<Result> operator()() {
+    return absl::visit(CallPoll<false>{this}, state_);
+  }
+
+ private:
+  struct Evaluating {
+    ConditionPromise condition;
+    TrueFactory if_true;
+    FalseFactory if_false;
+  };
+  using State = absl::variant<Evaluating, TruePromise, FalsePromise>;
+  State state_;
+
+  template <bool kSetState>
+  struct CallPoll {
+    using PollResult = Poll<Result>;
+
+    If* const self;
+
+    PollResult operator()(Evaluating& evaluating) const {
+      static_assert(
+          !kSetState,
+          "shouldn't need to set state coming through the initial branch");
+      auto r = evaluating.condition();
+      if (auto* p = absl::get_if<kPollReadyIdx>(&r)) {
+        return ChooseIf(CallPoll<true>{self}, std::move(*p),
+                        &evaluating.if_true, &evaluating.if_false);
+      }
+      return Pending();
+    }
+
+    template <class Promise>
+    PollResult operator()(Promise& promise) const {
+      auto r = promise();
+      if (kSetState && absl::holds_alternative<Pending>(r)) {
+        self->state_.template emplace<Promise>(std::move(promise));
+      }
+      return r;
+    }
+  };
+};
+
+}  // namespace promise_detail
+
+// If promise combinator.
+// Takes 3 promise factories, and evaluates the first.
+// If it returns failure, returns failure for the entire combinator.
+// If it returns true, evaluates the second promise.
+// If it returns false, evaluates the third promise.
+template <typename C, typename T, typename F>
+promise_detail::If<C, T, F> If(C condition, T if_true, F if_false) {
+  return promise_detail::If<C, T, F>(std::move(condition), std::move(if_true),
+                                     std::move(if_false));
+}
+
+}  // namespace grpc_core
+
+#endif  // GRPC_CORE_LIB_PROMISE_IF_H
diff --git a/src/core/lib/promise/intra_activity_waiter.h b/src/core/lib/promise/intra_activity_waiter.h
new file mode 100644 (file)
index 0000000..a9e43ab
--- /dev/null
@@ -0,0 +1,48 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#ifndef GRPC_CORE_LIB_PROMISE_INTRA_ACTIVITY_WAITER_H
+#define GRPC_CORE_LIB_PROMISE_INTRA_ACTIVITY_WAITER_H
+
+#include <grpc/impl/codegen/port_platform.h>
+
+#include "src/core/lib/promise/activity.h"
+
+namespace grpc_core {
+
+// Helper type to track wakeups between objects in the same activity.
+// Can be fairly fast as no ref counting or locking needs to occur.
+class IntraActivityWaiter {
+ public:
+  // Register for wakeup, return Pending(). If state is not ready to proceed,
+  // Promises should bottom out here.
+  Pending pending() {
+    waiting_ = true;
+    return Pending();
+  }
+  // Wake the activity
+  void Wake() {
+    if (waiting_) {
+      waiting_ = false;
+      Activity::WakeupCurrent();
+    }
+  }
+
+ private:
+  bool waiting_ = false;
+};
+
+}  // namespace grpc_core
+
+#endif  // GRPC_CORE_LIB_PROMISE_INTRA_ACTIVITY_WAITER_H
diff --git a/src/core/lib/promise/join.h b/src/core/lib/promise/join.h
new file mode 100644 (file)
index 0000000..d41840b
--- /dev/null
@@ -0,0 +1,53 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#ifndef GRPC_CORE_LIB_PROMISE_JOIN_H
+#define GRPC_CORE_LIB_PROMISE_JOIN_H
+
+#include <grpc/impl/codegen/port_platform.h>
+
+#include "src/core/lib/promise/detail/basic_join.h"
+
+namespace grpc_core {
+namespace promise_detail {
+
+struct JoinTraits {
+  template <typename T>
+  using ResultType = absl::remove_reference_t<T>;
+  template <typename T, typename F>
+  static auto OnResult(T result, F kontinue)
+      -> decltype(kontinue(std::move(result))) {
+    return kontinue(std::move(result));
+  }
+  template <typename T>
+  static T Wrap(T x) {
+    return x;
+  }
+};
+
+template <typename... Promises>
+using Join = BasicJoin<JoinTraits, Promises...>;
+
+}  // namespace promise_detail
+
+/// Combinator to run all promises to completion, and return a tuple
+/// of their results.
+template <typename... Promise>
+promise_detail::Join<Promise...> Join(Promise... promises) {
+  return promise_detail::Join<Promise...>(std::move(promises)...);
+}
+
+}  // namespace grpc_core
+
+#endif  // GRPC_CORE_LIB_PROMISE_JOIN_H
diff --git a/src/core/lib/promise/latch.h b/src/core/lib/promise/latch.h
new file mode 100644 (file)
index 0000000..c697956
--- /dev/null
@@ -0,0 +1,104 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#ifndef GRPC_CORE_LIB_PROMISE_LATCH_H
+#define GRPC_CORE_LIB_PROMISE_LATCH_H
+
+#include <grpc/impl/codegen/port_platform.h>
+
+#include <grpc/support/log.h>
+
+#include "src/core/lib/promise/activity.h"
+#include "src/core/lib/promise/intra_activity_waiter.h"
+#include "src/core/lib/promise/poll.h"
+
+namespace grpc_core {
+
+// Latch provides a single set waitable object.
+// Initially the Latch is unset.
+// It can be waited upon by the Wait method, which produces a Promise that
+// resolves when the Latch is Set to a value of type T.
+template <typename T>
+class Latch {
+ public:
+  // This is the type of the promise returned by Wait.
+  class WaitPromise {
+   public:
+    Poll<T*> operator()() const {
+      if (latch_->has_value_) {
+        return &latch_->value_;
+      } else {
+        return latch_->waiter_.pending();
+      }
+    }
+
+   private:
+    friend class Latch;
+    explicit WaitPromise(Latch* latch) : latch_(latch) {}
+    Latch* latch_;
+  };
+
+  Latch() = default;
+  Latch(const Latch&) = delete;
+  Latch& operator=(const Latch&) = delete;
+  Latch(Latch&& other) noexcept
+      : value_(std::move(other.value_)), has_value_(other.has_value_) {
+#ifndef NDEBUG
+    GPR_DEBUG_ASSERT(!other.has_had_waiters_);
+#endif
+  }
+  Latch& operator=(Latch&& other) noexcept {
+#ifndef NDEBUG
+    GPR_DEBUG_ASSERT(!other.has_had_waiters_);
+#endif
+    value_ = std::move(other.value_);
+    has_value_ = other.has_value_;
+    return *this;
+  }
+
+  // Produce a promise to wait for a value from this latch.
+  WaitPromise Wait() {
+#ifndef NDEBUG
+    has_had_waiters_ = true;
+#endif
+    return WaitPromise(this);
+  }
+
+  // Set the value of the latch. Can only be called once.
+  void Set(T value) {
+    GPR_DEBUG_ASSERT(!has_value_);
+    value_ = std::move(value);
+    has_value_ = true;
+    waiter_.Wake();
+  }
+
+ private:
+  // The value stored (if has_value_ is true), otherwise some random value, we
+  // don't care.
+  // Why not absl::optional<>? Writing things this way lets us compress
+  // has_value_ with waiter_ and leads to some significant memory savings for
+  // some scenarios.
+  GPR_NO_UNIQUE_ADDRESS T value_;
+  // True if we have a value set, false otherwise.
+  bool has_value_ = false;
+#ifndef NDEBUG
+  // Has this latch ever had waiters.
+  bool has_had_waiters_ = false;
+#endif
+  IntraActivityWaiter waiter_;
+};
+
+}  // namespace grpc_core
+
+#endif  // GRPC_CORE_LIB_PROMISE_LATCH_H
diff --git a/src/core/lib/promise/loop.h b/src/core/lib/promise/loop.h
new file mode 100644 (file)
index 0000000..0a5346b
--- /dev/null
@@ -0,0 +1,96 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#ifndef GRPC_CORE_LIB_PROMISE_LOOP_H
+#define GRPC_CORE_LIB_PROMISE_LOOP_H
+
+#include <grpc/impl/codegen/port_platform.h>
+
+#include "absl/types/variant.h"
+
+#include "src/core/lib/promise/detail/promise_factory.h"
+
+namespace grpc_core {
+
+// Special type - signals to loop to take another iteration, instead of
+// finishing
+struct Continue {};
+
+// Result of polling a loop promise - either Continue looping, or return a value
+// T
+template <typename T>
+using LoopCtl = absl::variant<Continue, T>;
+
+namespace promise_detail {
+
+template <typename T>
+struct LoopTraits;
+template <typename T>
+struct LoopTraits<LoopCtl<T>> {
+  using Result = T;
+};
+
+template <typename F>
+class Loop {
+ private:
+  using Factory = promise_detail::PromiseFactory<void, F>;
+  using Promise = decltype(std::declval<Factory>().Repeated());
+  using PromiseResult = typename Promise::Result;
+
+ public:
+  using Result = typename LoopTraits<PromiseResult>::Result;
+
+  explicit Loop(F f) : factory_(std::move(f)), promise_(factory_.Repeated()) {}
+  ~Loop() { promise_.~Promise(); }
+
+  Poll<Result> operator()() {
+    while (true) {
+      // Poll the inner promise.
+      auto promise_result = promise_();
+      // If it returns a value:
+      if (auto* p = absl::get_if<kPollReadyIdx>(&promise_result)) {
+        //  - then if it's Continue, destroy the promise and recreate a new one
+        //  from our factory.
+        if (absl::holds_alternative<Continue>(*p)) {
+          promise_.~Promise();
+          new (&promise_) Promise(factory_.Repeated());
+          continue;
+        }
+        //  - otherwise there's our result... return it out.
+        return absl::get<Result>(*p);
+      } else {
+        // Otherwise the inner promise was pending, so we are pending.
+        return Pending();
+      }
+    }
+  }
+
+ private:
+  GPR_NO_UNIQUE_ADDRESS Factory factory_;
+  GPR_NO_UNIQUE_ADDRESS union { GPR_NO_UNIQUE_ADDRESS Promise promise_; };
+};
+
+}  // namespace promise_detail
+
+// Looping combinator.
+// Expects F returns LoopCtl<T> - if it's Continue, then run the loop again -
+// otherwise yield the returned value as the result of the loop.
+template <typename F>
+promise_detail::Loop<F> Loop(F f) {
+  return promise_detail::Loop<F>(std::move(f));
+}
+
+}  // namespace grpc_core
+
+#endif  // GRPC_CORE_LIB_PROMISE_LOOP_H
diff --git a/src/core/lib/promise/map.h b/src/core/lib/promise/map.h
new file mode 100644 (file)
index 0000000..1ac94d4
--- /dev/null
@@ -0,0 +1,84 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#ifndef GRPC_CORE_LIB_PROMISE_MAP_H
+#define GRPC_CORE_LIB_PROMISE_MAP_H
+
+#include <grpc/impl/codegen/port_platform.h>
+
+#include <tuple>
+
+#include "absl/types/variant.h"
+
+#include "src/core/lib/promise/detail/promise_like.h"
+#include "src/core/lib/promise/poll.h"
+
+namespace grpc_core {
+
+namespace promise_detail {
+
+// Implementation of mapping combinator - use this via the free function below!
+// Promise is the type of promise to poll on, Fn is a function that takes the
+// result of Promise and maps it to some new type.
+template <typename Promise, typename Fn>
+class Map {
+ public:
+  Map(Promise promise, Fn fn)
+      : promise_(std::move(promise)), fn_(std::move(fn)) {}
+
+  using PromiseResult = typename PromiseLike<Promise>::Result;
+  using Result =
+      RemoveCVRef<decltype(std::declval<Fn>()(std::declval<PromiseResult>()))>;
+
+  Poll<Result> operator()() {
+    Poll<PromiseResult> r = promise_();
+    if (auto* p = absl::get_if<kPollReadyIdx>(&r)) {
+      return fn_(std::move(*p));
+    }
+    return Pending();
+  }
+
+ private:
+  PromiseLike<Promise> promise_;
+  Fn fn_;
+};
+
+}  // namespace promise_detail
+
+// Mapping combinator.
+// Takes a promise, and a synchronous function to mutate its result, and
+// returns a promise.
+template <typename Promise, typename Fn>
+promise_detail::Map<Promise, Fn> Map(Promise promise, Fn fn) {
+  return promise_detail::Map<Promise, Fn>(std::move(promise), std::move(fn));
+}
+
+// Callable that takes a tuple and returns one element
+template <size_t kElem>
+struct JustElem {
+  template <typename... A>
+  auto operator()(std::tuple<A...>&& t) const
+      -> decltype(std::get<kElem>(std::forward<std::tuple<A...>>(t))) {
+    return std::get<kElem>(std::forward<std::tuple<A...>>(t));
+  }
+  template <typename... A>
+  auto operator()(const std::tuple<A...>& t) const
+      -> decltype(std::get<kElem>(t)) {
+    return std::get<kElem>(t);
+  }
+};
+
+}  // namespace grpc_core
+
+#endif  // GRPC_CORE_LIB_PROMISE_MAP_H
diff --git a/src/core/lib/promise/observable.h b/src/core/lib/promise/observable.h
new file mode 100644 (file)
index 0000000..6ca58c3
--- /dev/null
@@ -0,0 +1,286 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#ifndef GRPC_CORE_LIB_PROMISE_OBSERVABLE_H
+#define GRPC_CORE_LIB_PROMISE_OBSERVABLE_H
+
+#include <grpc/impl/codegen/port_platform.h>
+
+#include <limits>
+
+#include "absl/types/optional.h"
+
+#include "src/core/lib/promise/activity.h"
+#include "src/core/lib/promise/wait_set.h"
+
+namespace grpc_core {
+
+namespace promise_detail {
+
+using ObservableVersion = uint64_t;
+static constexpr ObservableVersion kTombstoneVersion =
+    std::numeric_limits<ObservableVersion>::max();
+
+}  // namespace promise_detail
+
+class WatchCommitter {
+ public:
+  void Commit() { version_seen_ = promise_detail::kTombstoneVersion; }
+
+ protected:
+  promise_detail::ObservableVersion version_seen_ = 0;
+};
+
+namespace promise_detail {
+
+// Shared state between Observable and Observer.
+template <typename T>
+class ObservableState {
+ public:
+  explicit ObservableState(absl::optional<T> value)
+      : value_(std::move(value)) {}
+
+  // Publish that we're closed.
+  void Close() {
+    mu_.Lock();
+    version_ = kTombstoneVersion;
+    value_.reset();
+    auto wakeup = waiters_.TakeWakeupSet();
+    mu_.Unlock();
+    wakeup.Wakeup();
+  }
+
+  // Synchronously publish a new value, and wake any waiters.
+  void Push(T value) {
+    mu_.Lock();
+    version_++;
+    value_ = std::move(value);
+    auto wakeup = waiters_.TakeWakeupSet();
+    mu_.Unlock();
+    wakeup.Wakeup();
+  }
+
+  Poll<absl::optional<T>> PollGet(ObservableVersion* version_seen) {
+    absl::MutexLock lock(&mu_);
+    if (!Started()) return Pending();
+    *version_seen = version_;
+    return value_;
+  }
+
+  Poll<absl::optional<T>> PollNext(ObservableVersion* version_seen) {
+    absl::MutexLock lock(&mu_);
+    if (!NextValueReady(version_seen)) return Pending();
+    return value_;
+  }
+
+  Poll<absl::optional<T>> PollWatch(ObservableVersion* version_seen) {
+    if (*version_seen == kTombstoneVersion) return Pending();
+
+    absl::MutexLock lock(&mu_);
+    if (!NextValueReady(version_seen)) return Pending();
+    // Watch needs to be woken up if the value changes even if it's ready now.
+    waiters_.AddPending(Activity::current()->MakeNonOwningWaker());
+    return value_;
+  }
+
+ private:
+  // Returns true if an initial value is set.
+  // If one is not set, add ourselves as pending to waiters_, and return false.
+  bool Started() ABSL_EXCLUSIVE_LOCKS_REQUIRED(mu_) {
+    if (!value_.has_value()) {
+      if (version_ != kTombstoneVersion) {
+        // We allow initial no-value, which does not indicate closure.
+        waiters_.AddPending(Activity::current()->MakeNonOwningWaker());
+        return false;
+      }
+    }
+    return true;
+  }
+
+  // If no value is ready, add ourselves as pending to waiters_ and return
+  // false.
+  // If the next value is ready, update the last version seen and return true.
+  bool NextValueReady(ObservableVersion* version_seen)
+      ABSL_EXCLUSIVE_LOCKS_REQUIRED(mu_) {
+    if (!Started()) return false;
+    if (version_ == *version_seen) {
+      waiters_.AddPending(Activity::current()->MakeNonOwningWaker());
+      return false;
+    }
+    *version_seen = version_;
+    return true;
+  }
+
+  absl::Mutex mu_;
+  WaitSet waiters_ ABSL_GUARDED_BY(mu_);
+  ObservableVersion version_ ABSL_GUARDED_BY(mu_) = 1;
+  absl::optional<T> value_ ABSL_GUARDED_BY(mu_);
+};
+
+// Promise implementation for Observer::Get.
+template <typename T>
+class ObservableGet {
+ public:
+  ObservableGet(ObservableVersion* version_seen, ObservableState<T>* state)
+      : version_seen_(version_seen), state_(state) {}
+
+  Poll<absl::optional<T>> operator()() {
+    return state_->PollGet(version_seen_);
+  }
+
+ private:
+  ObservableVersion* version_seen_;
+  ObservableState<T>* state_;
+};
+
+// Promise implementation for Observer::Next.
+template <typename T>
+class ObservableNext {
+ public:
+  ObservableNext(ObservableVersion* version_seen, ObservableState<T>* state)
+      : version_seen_(version_seen), state_(state) {}
+
+  Poll<absl::optional<T>> operator()() {
+    return state_->PollNext(version_seen_);
+  }
+
+ private:
+  ObservableVersion* version_seen_;
+  ObservableState<T>* state_;
+};
+
+template <typename T, typename F>
+class ObservableWatch final : private WatchCommitter {
+ private:
+  using Promise = PromiseLike<decltype(
+      std::declval<F>()(std::declval<T>(), std::declval<WatchCommitter*>()))>;
+  using Result = typename Promise::Result;
+
+ public:
+  explicit ObservableWatch(F factory, std::shared_ptr<ObservableState<T>> state)
+      : state_(std::move(state)), factory_(std::move(factory)) {}
+  ObservableWatch(const ObservableWatch&) = delete;
+  ObservableWatch& operator=(const ObservableWatch&) = delete;
+  ObservableWatch(ObservableWatch&& other) noexcept
+      : state_(std::move(other.state_)),
+        promise_(std::move(other.promise_)),
+        factory_(std::move(other.factory_)) {}
+  ObservableWatch& operator=(ObservableWatch&&) noexcept = default;
+
+  Poll<Result> operator()() {
+    auto r = state_->PollWatch(&version_seen_);
+    if (auto* p = absl::get_if<kPollReadyIdx>(&r)) {
+      if (p->has_value()) {
+        promise_ = Promise(factory_(std::move(**p), this));
+      } else {
+        promise_ = {};
+      }
+    }
+    if (promise_.has_value()) {
+      return (*promise_)();
+    } else {
+      return Pending();
+    }
+  }
+
+ private:
+  std::shared_ptr<ObservableState<T>> state_;
+  absl::optional<Promise> promise_;
+  F factory_;
+};
+
+}  // namespace promise_detail
+
+template <typename T>
+class Observable;
+
+// Observer watches an Observable for updates.
+// It can see either the latest value or wait for a new value, but is not
+// guaranteed to see every value pushed to the Observable.
+template <typename T>
+class Observer {
+ public:
+  Observer(const Observer&) = delete;
+  Observer& operator=(const Observer&) = delete;
+  Observer(Observer&& other) noexcept
+      : version_seen_(other.version_seen_), state_(std::move(other.state_)) {}
+  Observer& operator=(Observer&& other) noexcept {
+    version_seen_ = other.version_seen_;
+    state_ = std::move(other.state_);
+    return *this;
+  }
+
+  // Return a promise that will produce an optional<T>.
+  // If the Observable is still present, this will be a value T, but if the
+  // Observable has been closed, this will be nullopt. Borrows data from the
+  // Observer, so this value must stay valid until the promise is resolved. Only
+  // one Next, Get call is allowed to be outstanding at a time.
+  promise_detail::ObservableGet<T> Get() {
+    return promise_detail::ObservableGet<T>{&version_seen_, &*state_};
+  }
+
+  // Return a promise that will produce the next unseen value as an optional<T>.
+  // If the Observable is still present, this will be a value T, but if the
+  // Observable has been closed, this will be nullopt. Borrows data from the
+  // Observer, so this value must stay valid until the promise is resolved. Only
+  // one Next, Get call is allowed to be outstanding at a time.
+  promise_detail::ObservableNext<T> Next() {
+    return promise_detail::ObservableNext<T>{&version_seen_, &*state_};
+  }
+
+ private:
+  using State = promise_detail::ObservableState<T>;
+  friend class Observable<T>;
+  explicit Observer(std::shared_ptr<State> state) : state_(state) {}
+  promise_detail::ObservableVersion version_seen_ = 0;
+  std::shared_ptr<State> state_;
+};
+
+// Observable models a single writer multiple reader broadcast channel.
+// Readers can observe the latest value, or await a new latest value, but they
+// are not guaranteed to observe every value.
+template <typename T>
+class Observable {
+ public:
+  Observable() : state_(std::make_shared<State>(absl::nullopt)) {}
+  explicit Observable(T value)
+      : state_(std::make_shared<State>(std::move(value))) {}
+  ~Observable() { state_->Close(); }
+  Observable(const Observable&) = delete;
+  Observable& operator=(const Observable&) = delete;
+
+  // Push a new value into the observable.
+  void Push(T value) { state_->Push(std::move(value)); }
+
+  // Create a new Observer - which can pull the current state from this
+  // Observable.
+  Observer<T> MakeObserver() { return Observer<T>(state_); }
+
+  // Create a new Watch - a promise that pushes state into the passed in promise
+  // factory. The promise factory takes two parameters - the current value and a
+  // commit token. If the commit token is used (the Commit function on it is
+  // called), then no further Watch updates are provided.
+  template <typename F>
+  promise_detail::ObservableWatch<T, F> Watch(F f) {
+    return promise_detail::ObservableWatch<T, F>(std::move(f), state_);
+  }
+
+ private:
+  using State = promise_detail::ObservableState<T>;
+  std::shared_ptr<State> state_;
+};
+
+}  // namespace grpc_core
+
+#endif  // GRPC_CORE_LIB_PROMISE_OBSERVABLE_H
diff --git a/src/core/lib/promise/pipe.h b/src/core/lib/promise/pipe.h
new file mode 100644 (file)
index 0000000..3d287ca
--- /dev/null
@@ -0,0 +1,592 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#ifndef GRPC_CORE_LIB_PROMISE_PIPE_H
+#define GRPC_CORE_LIB_PROMISE_PIPE_H
+
+#include <grpc/impl/codegen/port_platform.h>
+
+#include "absl/status/status.h"
+#include "absl/status/statusor.h"
+#include "absl/types/optional.h"
+
+#include "src/core/lib/promise/activity.h"
+#include "src/core/lib/promise/detail/promise_factory.h"
+#include "src/core/lib/promise/intra_activity_waiter.h"
+#include "src/core/lib/promise/poll.h"
+
+namespace grpc_core {
+
+template <typename T>
+struct Pipe;
+
+template <typename T>
+class PipeSender;
+
+template <typename T>
+class PipeReceiver;
+
+namespace pipe_detail {
+
+template <typename T>
+class Push;
+
+template <typename T>
+class Next;
+
+template <class T>
+class Promise {
+ public:
+  virtual Poll<bool> Step(T* output) = 0;
+  virtual void Stop() = 0;
+
+ protected:
+  inline virtual ~Promise() = default;
+};
+
+struct alignas(alignof(void*)) Scratch {
+  uint8_t scratch[32];
+};
+
+template <typename T>
+class FilterInterface {
+ public:
+  FilterInterface() = default;
+  FilterInterface(const FilterInterface&) = delete;
+  FilterInterface& operator=(const FilterInterface&) = delete;
+  virtual Promise<T>* Step(T* p, Scratch* scratch_space) = 0;
+  virtual void UpdateReceiver(PipeReceiver<T>* receiver) = 0;
+
+ protected:
+  inline virtual ~FilterInterface() {}
+  static void SetReceiverIndex(PipeReceiver<T>* receiver, int idx,
+                               FilterInterface* p);
+  char AllocIndex(PipeReceiver<T>* receiver);
+};
+
+template <typename T, typename F>
+class Filter;
+
+}  // namespace pipe_detail
+
+// Send end of a Pipe.
+template <typename T>
+class PipeSender {
+ public:
+  PipeSender(const PipeSender&) = delete;
+  PipeSender& operator=(const PipeSender&) = delete;
+
+  PipeSender(PipeSender&& other) noexcept
+      : receiver_(other.receiver_), push_(other.push_) {
+    if (receiver_ != nullptr) {
+      receiver_->sender_ = this;
+      other.receiver_ = nullptr;
+    }
+    if (push_ != nullptr) {
+      push_->sender_ = this;
+      other.push_ = nullptr;
+    }
+  }
+  PipeSender& operator=(PipeSender&& other) noexcept {
+    if (receiver_ != nullptr) {
+      receiver_->sender_ = nullptr;
+    }
+    if (push_ != nullptr) {
+      push_->sender_ = nullptr;
+    }
+    receiver_ = other.receiver_;
+    if (receiver_ != nullptr) {
+      receiver_->sender_ = this;
+      other.receiver_ = nullptr;
+    }
+    if (push_ != nullptr) {
+      push_->sender_ = this;
+      other.push_ = nullptr;
+    }
+    return *this;
+  }
+
+  ~PipeSender() {
+    if (receiver_ != nullptr) {
+      receiver_->MarkClosed();
+    }
+    if (push_ != nullptr) {
+      push_->sender_ = nullptr;
+    }
+  }
+
+  // Send a single message along the pipe.
+  // Returns a promise that will resolve to a bool - true if the message was
+  // sent, false if it could never be sent. Blocks the promise until the
+  // receiver is either closed or able to receive another message.
+  pipe_detail::Push<T> Push(T value);
+
+  // Attach a promise factory based filter to this pipe.
+  // The overall promise returned from this will be active until the pipe is
+  // closed. If this promise is cancelled before the pipe is closed, the pipe
+  // will close. The filter will be run _after_ any other registered filters.
+  template <typename F>
+  pipe_detail::Filter<T, F> Filter(F f);
+
+ private:
+  friend struct Pipe<T>;
+  friend class PipeReceiver<T>;
+  friend class pipe_detail::Next<T>;
+  friend class pipe_detail::Push<T>;
+  explicit PipeSender(PipeReceiver<T>* receiver) : receiver_(receiver) {}
+  PipeReceiver<T>* receiver_;
+  pipe_detail::Push<T>* push_ = nullptr;
+};
+
+// Receive end of a Pipe.
+template <typename T>
+class PipeReceiver {
+ public:
+  PipeReceiver(const PipeReceiver&) = delete;
+  PipeReceiver& operator=(const PipeReceiver&) = delete;
+
+  PipeReceiver(PipeReceiver&& other) noexcept
+      : sender_(other.sender_),
+        next_(other.next_),
+        filters_(std::move(other.filters_)),
+        pending_(std::move(other.pending_)),
+        waiting_to_send_(std::move(other.waiting_to_send_)),
+        waiting_to_receive_(other.waiting_to_receive_) {
+    if (sender_ != nullptr) {
+      sender_->receiver_ = this;
+      other.sender_ = nullptr;
+    }
+    if (next_ != nullptr) {
+      next_->receiver_ = this;
+      other.next_ = nullptr;
+    }
+    for (auto filter : filters_) {
+      filter->UpdateReceiver(this);
+    }
+  }
+  PipeReceiver& operator=(PipeReceiver&& other) noexcept {
+    if (sender_ != nullptr) {
+      sender_->receiver_ = nullptr;
+    }
+    if (next_ != nullptr) {
+      next_->receiver_ = nullptr;
+    }
+    sender_ = other.sender_;
+    next_ = other.next_;
+    filters_ = std::move(other.filters_);
+    for (auto filter : filters_) {
+      filter->UpdateReceiver(this);
+    }
+    pending_ = std::move(other.pending_);
+    waiting_to_send_ = std::move(other.waiting_to_send_);
+    waiting_to_receive_ = std::move(other.waiting_to_receive_);
+    if (sender_ != nullptr) {
+      sender_->receiver_ = this;
+      other.sender_ = nullptr;
+    }
+    if (next_ != nullptr) {
+      next_->receiver_ = this;
+      other.next_ = nullptr;
+    }
+    return *this;
+  }
+  ~PipeReceiver() {
+    MarkClosed();
+    if (next_ != nullptr) {
+      next_->receiver_ = nullptr;
+    }
+  }
+
+  // Receive a single message from the pipe.
+  // Returns a promise that will resolve to an optional<T> - with a value if a
+  // message was received, or no value if the other end of the pipe was closed.
+  // Blocks the promise until the receiver is either closed or a message is
+  // available.
+  pipe_detail::Next<T> Next();
+
+  // Attach a promise factory based filter to this pipe.
+  // The overall promise returned from this will be active until the pipe is
+  // closed. If this promise is cancelled before the pipe is closed, the pipe
+  // will close. The filter will be run _after_ any other registered filters.
+  template <typename F>
+  pipe_detail::Filter<T, F> Filter(F f);
+
+ private:
+  friend struct Pipe<T>;
+  friend class PipeSender<T>;
+  friend class pipe_detail::Next<T>;
+  friend class pipe_detail::Push<T>;
+  friend class pipe_detail::FilterInterface<T>;
+  explicit PipeReceiver(PipeSender<T>* sender) : sender_(sender) {}
+  PipeSender<T>* sender_;
+  pipe_detail::Next<T>* next_ = nullptr;
+  absl::InlinedVector<pipe_detail::FilterInterface<T>*, 12> filters_;
+  absl::optional<T> pending_;
+  IntraActivityWaiter waiting_to_send_;
+  IntraActivityWaiter waiting_to_receive_;
+
+  void MarkClosed() {
+    if (sender_ == nullptr) {
+      return;
+    }
+
+    sender_->receiver_ = nullptr;
+
+    waiting_to_receive_.Wake();
+    waiting_to_send_.Wake();
+    sender_ = nullptr;
+
+    for (auto* filter : filters_) {
+      if (filter != nullptr) {
+        filter->UpdateReceiver(nullptr);
+      }
+    }
+  }
+};
+
+namespace pipe_detail {
+
+// Implementation of PipeSender::Push promise.
+template <typename T>
+class Push {
+ public:
+  Push(const Push&) = delete;
+  Push& operator=(const Push&) = delete;
+  Push(Push&& other) noexcept
+      : sender_(other.sender_), push_(std::move(other.push_)) {
+    if (sender_ != nullptr) {
+      sender_->push_ = this;
+      other.sender_ = nullptr;
+    }
+  }
+  Push& operator=(Push&& other) noexcept {
+    if (sender_ != nullptr) {
+      sender_->push_ = nullptr;
+    }
+    sender_ = other.sender_;
+    push_ = std::move(other.push_);
+    if (sender_ != nullptr) {
+      sender_->push_ = this;
+      other.sender_ = nullptr;
+    }
+    return *this;
+  }
+
+  ~Push() {
+    if (sender_ != nullptr) {
+      assert(sender_->push_ == this);
+      sender_->push_ = nullptr;
+    }
+  }
+
+  Poll<bool> operator()() {
+    auto* receiver = sender_->receiver_;
+    if (receiver == nullptr) {
+      return false;
+    }
+    if (receiver->pending_.has_value()) {
+      return receiver->waiting_to_send_.pending();
+    }
+    receiver->pending_ = std::move(push_);
+    receiver->waiting_to_receive_.Wake();
+    sender_->push_ = nullptr;
+    sender_ = nullptr;
+    return true;
+  }
+
+ private:
+  friend class PipeSender<T>;
+  Push(PipeSender<T>* sender, T push)
+      : sender_(sender), push_(std::move(push)) {
+    assert(sender_->push_ == nullptr);
+    sender_->push_ = this;
+  }
+  PipeSender<T>* sender_;
+  T push_;
+};
+
+// Implementation of PipeReceiver::Next promise.
+template <typename T>
+class Next {
+ public:
+  Next(const Next&) = delete;
+  Next& operator=(const Next&) = delete;
+  Next(Next&& other) noexcept
+      : receiver_(other.receiver_),
+        next_filter_(other.next_filter_),
+        current_promise_(nullptr) {
+    assert(other.current_promise_ == nullptr);
+    if (receiver_ != nullptr) {
+      receiver_->next_ = this;
+      other.receiver_ = nullptr;
+    }
+  }
+  Next& operator=(Next&& other) noexcept {
+    assert(current_promise_ == nullptr);
+    assert(other.current_promise_ == nullptr);
+    if (receiver_ != nullptr) {
+      receiver_->next_ = nullptr;
+    }
+    receiver_ = other.receiver_;
+    next_filter_ = other.next_filter_;
+    if (receiver_ != nullptr) {
+      receiver_->next_ = this;
+      other.receiver_ = nullptr;
+    }
+    return *this;
+  }
+
+  ~Next() {
+    if (receiver_ != nullptr) {
+      assert(receiver_->next_ == this);
+      receiver_->next_ = nullptr;
+    }
+    if (current_promise_ != nullptr) {
+      current_promise_->Stop();
+    }
+  }
+
+  Poll<absl::optional<T>> operator()() {
+    if (receiver_->pending_.has_value()) {
+      auto* pending = &*receiver_->pending_;
+      if (current_promise_ != nullptr) {
+        auto r = current_promise_->Step(pending);
+        if (auto* p = absl::get_if<kPollReadyIdx>(&r)) {
+          current_promise_->Stop();
+          current_promise_ = nullptr;
+          if (!*p) {
+            receiver_->MarkClosed();
+            return absl::optional<T>();
+          }
+        } else {
+          return Pending();
+        }
+      }
+      while (true) {
+        if (next_filter_ >= receiver_->filters_.size()) {
+          auto result = absl::optional<T>(std::move(*pending));
+          receiver_->pending_.reset();
+          receiver_->waiting_to_send_.Wake();
+          receiver_->next_ = nullptr;
+          receiver_ = nullptr;
+          return result;
+        }
+        auto* filter = receiver_->filters_[next_filter_];
+        current_promise_ = filter ? filter->Step(pending, &scratch_) : nullptr;
+        next_filter_++;
+        if (current_promise_ ==
+            reinterpret_cast<Promise<T>*>(uintptr_t(false))) {
+          current_promise_ = nullptr;
+          receiver_->MarkClosed();
+          return absl::optional<T>();
+        } else if (current_promise_ ==
+                   reinterpret_cast<Promise<T>*>(uintptr_t(true))) {
+          current_promise_ = nullptr;
+        } else {
+          return Pending();
+        }
+      }
+    }
+    if (receiver_->sender_ == nullptr) {
+      return absl::optional<T>();
+    }
+    return receiver_->waiting_to_receive_.pending();
+  }
+
+ private:
+  friend class PipeReceiver<T>;
+  explicit Next(PipeReceiver<T>* receiver) : receiver_(receiver) {
+    assert(receiver_->next_ == nullptr);
+    receiver_->next_ = this;
+  }
+  PipeReceiver<T>* receiver_;
+  size_t next_filter_ = 0;
+  Promise<T>* current_promise_ = nullptr;
+  Scratch scratch_;
+};
+
+template <typename T, typename F>
+class Filter final : private FilterInterface<T> {
+ public:
+  Filter(PipeReceiver<T>* receiver, F f)
+      : active_{receiver, promise_detail::PromiseFactory<T, F>(std::move(f))},
+        index_(this->AllocIndex(receiver)){};
+  explicit Filter(absl::Status already_finished)
+      : done_(std::move(already_finished)) {}
+  ~Filter() {
+    if (index_ != kTombstoneIndex) {
+      this->SetReceiverIndex(active_.receiver, index_, nullptr);
+      active_.~Active();
+    } else {
+      done_.~Status();
+    }
+  }
+  Filter(Filter&& other) noexcept : index_(other.index_) {
+    if (index_ != kTombstoneIndex) {
+      new (&active_) Active(std::move(other.active_));
+      other.active_.~Active();
+      new (&other.done_) absl::Status(absl::OkStatus());
+      other.index_ = kTombstoneIndex;
+      this->SetReceiverIndex(active_.receiver, index_, this);
+    } else {
+      new (&done_) absl::Status(std::move(other.done_));
+    }
+  }
+
+  Filter(const Filter&) = delete;
+  Filter& operator=(const Filter&) = delete;
+
+  Poll<absl::Status> operator()() {
+    if (index_ == kTombstoneIndex) {
+      return std::move(done_);
+    }
+    return Pending();
+  }
+
+ private:
+  static constexpr char kTombstoneIndex = -1;
+  struct Active {
+    GPR_NO_UNIQUE_ADDRESS PipeReceiver<T>* receiver;
+    GPR_NO_UNIQUE_ADDRESS promise_detail::PromiseFactory<T, F> factory;
+  };
+  union {
+    GPR_NO_UNIQUE_ADDRESS Active active_;
+    GPR_NO_UNIQUE_ADDRESS absl::Status done_;
+  };
+  GPR_NO_UNIQUE_ADDRESS char index_;
+
+  class PromiseImpl final : public ::grpc_core::pipe_detail::Promise<T> {
+    using PF = typename promise_detail::PromiseFactory<T, F>::Promise;
+
+   public:
+    PromiseImpl(PF f, Filter* filter) : f_(std::move(f)), filter_(filter) {}
+
+    Poll<bool> Step(T* output) final {
+      auto r = f_();
+      if (auto* p = absl::get_if<kPollReadyIdx>(&r)) {
+        if (p->ok()) {
+          *output = std::move(**p);
+          return true;
+        } else {
+          filter_->SetReceiverIndex(filter_->active_.receiver, filter_->index_,
+                                    nullptr);
+          filter_->active_.~Active();
+          filter_->index_ = kTombstoneIndex;
+          new (&filter_->done_) absl::Status(std::move(p->status()));
+          Activity::WakeupCurrent();
+          return false;
+        }
+      } else {
+        return Pending();
+      }
+    }
+
+    void Stop() final { this->~PromiseImpl(); }
+
+   private:
+    PF f_;
+    Filter* filter_;
+  };
+
+  Promise<T>* Step(T* p, Scratch* scratch) final {
+    if (index_ != kTombstoneIndex) {
+      PromiseImpl promise(active_.factory.Repeated(std::move(*p)), this);
+      auto r = promise.Step(p);
+      if (auto* result = absl::get_if<kPollReadyIdx>(&r)) {
+        return reinterpret_cast<Promise<T>*>(uintptr_t(*result));
+      }
+      static_assert(sizeof(promise) <= sizeof(Scratch),
+                    "scratch size too small");
+      static_assert(alignof(decltype(promise)) <= alignof(Scratch),
+                    "bad alignment");
+      return new (scratch) decltype(promise)(std::move(promise));
+    } else {
+      return nullptr;
+    }
+  }
+
+  void UpdateReceiver(PipeReceiver<T>* receiver) final {
+    if (index_ != kTombstoneIndex) {
+      if (receiver == nullptr) {
+        active_.~Active();
+        index_ = kTombstoneIndex;
+        new (&done_) absl::Status(absl::OkStatus());
+      } else {
+        active_.receiver = receiver;
+      }
+      Activity::WakeupCurrent();
+    }
+  }
+};
+
+template <typename T>
+void FilterInterface<T>::SetReceiverIndex(PipeReceiver<T>* receiver, int idx,
+                                          FilterInterface* p) {
+  receiver->filters_[idx] = p;
+}
+
+template <typename T>
+char FilterInterface<T>::AllocIndex(PipeReceiver<T>* receiver) {
+  auto r = receiver->filters_.size();
+  receiver->filters_.push_back(this);
+  return r;
+}
+
+}  // namespace pipe_detail
+
+template <typename T>
+pipe_detail::Push<T> PipeSender<T>::Push(T value) {
+  return pipe_detail::Push<T>(this, std::move(value));
+}
+
+template <typename T>
+pipe_detail::Next<T> PipeReceiver<T>::Next() {
+  return pipe_detail::Next<T>(this);
+}
+
+template <typename T>
+template <typename F>
+pipe_detail::Filter<T, F> PipeSender<T>::Filter(F f) {
+  if (receiver_) {
+    return pipe_detail::Filter<T, F>(receiver_, std::move(f));
+  } else {
+    return pipe_detail::Filter<T, F>(absl::OkStatus());
+  }
+}
+
+template <typename T>
+template <typename F>
+pipe_detail::Filter<T, F> PipeReceiver<T>::Filter(F f) {
+  return pipe_detail::Filter<T, F>(this, std::move(f));
+}
+
+// A Pipe is an intra-Activity communications channel that transmits T's from
+// one end to the other.
+// It is only safe to use a Pipe within the context of a single Activity.
+// No synchronization is performed internally.
+template <typename T>
+struct Pipe {
+  Pipe() : sender(&receiver), receiver(&sender) {}
+  Pipe(const Pipe&) = delete;
+  Pipe& operator=(const Pipe&) = delete;
+  Pipe(Pipe&&) noexcept = default;
+  Pipe& operator=(Pipe&&) noexcept = default;
+
+  PipeSender<T> sender;
+  PipeReceiver<T> receiver;
+};
+
+}  // namespace grpc_core
+
+#endif  // GRPC_CORE_LIB_PROMISE_PIPE_H
diff --git a/src/core/lib/promise/poll.h b/src/core/lib/promise/poll.h
new file mode 100644 (file)
index 0000000..fa3e19f
--- /dev/null
@@ -0,0 +1,58 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#ifndef GRPC_CORE_LIB_PROMISE_POLL_H
+#define GRPC_CORE_LIB_PROMISE_POLL_H
+
+#include <grpc/impl/codegen/port_platform.h>
+
+#include "absl/types/variant.h"
+
+namespace grpc_core {
+
+// A type that signals a Promise is still pending and not yet completed.
+// Allows writing 'return Pending{}' and with automatic conversions gets
+// upgraded to a Poll<> object.
+struct Pending {
+  constexpr bool operator==(Pending) const { return true; }
+};
+
+// The result of polling a Promise once.
+//
+// Can be either pending - the Promise has not yet completed, or ready -
+// indicating that the Promise has completed AND should not be polled again.
+template <typename T>
+using Poll = absl::variant<Pending, T>;
+
+// Variant of Poll that serves as a ready value
+static constexpr size_t kPollReadyIdx = 1;
+
+// PollTraits tells us whether a type is Poll<> or some other type, and is
+// leveraged in the PromiseLike/PromiseFactory machinery to select the
+// appropriate implementation of those concepts based upon the return type of a
+// lambda, for example (via enable_if).
+template <typename T>
+struct PollTraits {
+  static constexpr bool is_poll() { return false; }
+};
+
+template <typename T>
+struct PollTraits<Poll<T>> {
+  using Type = T;
+  static constexpr bool is_poll() { return true; }
+};
+
+}  // namespace grpc_core
+
+#endif  // GRPC_CORE_LIB_PROMISE_POLL_H
diff --git a/src/core/lib/promise/promise.h b/src/core/lib/promise/promise.h
new file mode 100644 (file)
index 0000000..9cf5266
--- /dev/null
@@ -0,0 +1,88 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#ifndef GRPC_CORE_LIB_PROMISE_PROMISE_H
+#define GRPC_CORE_LIB_PROMISE_PROMISE_H
+
+#include <grpc/impl/codegen/port_platform.h>
+
+#include <functional>
+
+#include "absl/types/optional.h"
+
+#include "src/core/lib/promise/detail/promise_like.h"
+#include "src/core/lib/promise/poll.h"
+
+namespace grpc_core {
+
+// A Promise is any functor that takes no arguments and returns Poll<T>.
+// Most of the time we just pass around the functor, but occasionally
+// it pays to have a type erased variant, which we define here.
+template <typename T>
+using Promise = std::function<Poll<T>()>;
+
+// Helper to execute a promise immediately and return either the result or
+// nothing.
+template <typename Promise>
+auto NowOrNever(Promise promise)
+    -> absl::optional<typename promise_detail::PromiseLike<Promise>::Result> {
+  auto r = promise_detail::PromiseLike<Promise>(std::move(promise))();
+  if (auto* p = absl::get_if<kPollReadyIdx>(&r)) {
+    return std::move(*p);
+  }
+  return {};
+}
+
+// A promise that never completes.
+template <typename T>
+struct Never {
+  Poll<T> operator()() { return Pending(); }
+};
+
+namespace promise_detail {
+// A promise that immediately completes.
+template <typename T>
+class Immediate {
+ public:
+  explicit Immediate(T value) : value_(std::move(value)) {}
+
+  Poll<T> operator()() { return std::move(value_); }
+
+ private:
+  T value_;
+};
+
+}  // namespace promise_detail
+
+// Return \a value immediately
+template <typename T>
+promise_detail::Immediate<T> Immediate(T value) {
+  return promise_detail::Immediate<T>(std::move(value));
+}
+
+// Typecheck that a promise returns the expected return type.
+// usage: auto promise = WithResult<int>([]() { return 3; });
+// NOTE: there are tests in promise_test.cc that are commented out because they
+// should fail to compile. When modifying this code these should be uncommented
+// and their miscompilation verified.
+template <typename T, typename F>
+auto WithResult(F f) ->
+    typename std::enable_if<std::is_same<decltype(f()), Poll<T>>::value,
+                            F>::type {
+  return f;
+}
+
+}  // namespace grpc_core
+
+#endif  // GRPC_CORE_LIB_PROMISE_PROMISE_H
diff --git a/src/core/lib/promise/race.h b/src/core/lib/promise/race.h
new file mode 100644 (file)
index 0000000..9bd9e93
--- /dev/null
@@ -0,0 +1,81 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#ifndef GRPC_CORE_LIB_PROMISE_RACE_H
+#define GRPC_CORE_LIB_PROMISE_RACE_H
+
+#include <grpc/impl/codegen/port_platform.h>
+
+#include <tuple>
+
+#include "src/core/lib/promise/poll.h"
+
+namespace grpc_core {
+
+namespace promise_detail {
+
+// Implementation type for Race combinator.
+template <typename... Promises>
+class Race;
+
+template <typename Promise, typename... Promises>
+class Race<Promise, Promises...> {
+ public:
+  using Result = decltype(std::declval<Promise>()());
+
+  explicit Race(Promise promise, Promises... promises)
+      : promise_(std::move(promise)), next_(std::move(promises)...) {}
+
+  Result operator()() {
+    // Check our own promise.
+    auto r = promise_();
+    if (absl::holds_alternative<Pending>(r)) {
+      // Check the rest of them.
+      return next_();
+    }
+    // Return the first ready result.
+    return std::move(absl::get<kPollReadyIdx>(std::move(r)));
+  }
+
+ private:
+  // The Promise checked by this instance.
+  Promise promise_;
+  // We recursively expand to check the rest of the instances.
+  Race<Promises...> next_;
+};
+
+template <typename Promise>
+class Race<Promise> {
+ public:
+  using Result = decltype(std::declval<Promise>()());
+  explicit Race(Promise promise) : promise_(std::move(promise)) {}
+  Result operator()() { return promise_(); }
+
+ private:
+  Promise promise_;
+};
+
+}  // namespace promise_detail
+
+/// Run all the promises, return the first result that's available.
+/// If two results are simultaneously available, bias towards the first result
+/// listed.
+template <typename... Promises>
+promise_detail::Race<Promises...> Race(Promises... promises) {
+  return promise_detail::Race<Promises...>(std::move(promises)...);
+}
+
+}  // namespace grpc_core
+
+#endif  // GRPC_CORE_LIB_PROMISE_RACE_H
diff --git a/src/core/lib/promise/seq.h b/src/core/lib/promise/seq.h
new file mode 100644 (file)
index 0000000..b81cb2d
--- /dev/null
@@ -0,0 +1,69 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#ifndef GRPC_CORE_LIB_PROMISE_SEQ_H
+#define GRPC_CORE_LIB_PROMISE_SEQ_H
+
+#include <grpc/impl/codegen/port_platform.h>
+
+#include "absl/types/variant.h"
+
+#include "src/core/lib/promise/detail/basic_seq.h"
+#include "src/core/lib/promise/poll.h"
+
+namespace grpc_core {
+
+namespace promise_detail {
+
+template <typename T>
+struct SeqTraits {
+  using UnwrappedType = T;
+  using WrappedType = T;
+  template <typename Next>
+  static auto CallFactory(Next* next, T&& value)
+      -> decltype(next->Once(std::forward<T>(value))) {
+    return next->Once(std::forward<T>(value));
+  }
+
+  template <typename Result, typename PriorResult, typename RunNext>
+  static Poll<Result> CheckResultAndRunNext(PriorResult prior,
+                                            RunNext run_next) {
+    return run_next(std::move(prior));
+  }
+};
+
+template <typename... Fs>
+using Seq = BasicSeq<SeqTraits, Fs...>;
+
+}  // namespace promise_detail
+
+// Sequencing combinator.
+// Run the first promise.
+// Pass its result to the second, and run the returned promise.
+// Pass its result to the third, and run the returned promise.
+// etc
+// Return the final value.
+template <typename... Functors>
+promise_detail::Seq<Functors...> Seq(Functors... functors) {
+  return promise_detail::Seq<Functors...>(std::move(functors)...);
+}
+
+template <typename F>
+F Seq(F functor) {
+  return functor;
+}
+
+}  // namespace grpc_core
+
+#endif  // GRPC_CORE_LIB_PROMISE_SEQ_H
diff --git a/src/core/lib/promise/try_join.h b/src/core/lib/promise/try_join.h
new file mode 100644 (file)
index 0000000..c15a6ee
--- /dev/null
@@ -0,0 +1,76 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#ifndef GRPC_CORE_LIB_PROMISE_TRY_JOIN_H
+#define GRPC_CORE_LIB_PROMISE_TRY_JOIN_H
+
+#include <grpc/impl/codegen/port_platform.h>
+
+#include "src/core/lib/promise/detail/basic_join.h"
+#include "src/core/lib/promise/detail/status.h"
+
+namespace grpc_core {
+
+namespace promise_detail {
+
+// Extract the T from a StatusOr<T>
+template <typename T>
+T IntoResult(absl::StatusOr<T>* status) {
+  return std::move(**status);
+}
+
+// TryJoin returns a StatusOr<tuple<A,B,C>> for f()->Poll<StatusOr<A>>,
+// g()->Poll<StatusOr<B>>, h()->Poll<StatusOr<C>>. If one of those should be a
+// Status instead, we need a placeholder type to return, and this is it.
+struct Empty {};
+inline Empty IntoResult(absl::Status*) { return Empty{}; }
+
+// Traits object to pass to BasicJoin
+struct TryJoinTraits {
+  template <typename T>
+  using ResultType =
+      decltype(IntoResult(std::declval<absl::remove_reference_t<T>*>()));
+  template <typename T, typename F>
+  static auto OnResult(T result, F kontinue)
+      -> decltype(kontinue(IntoResult(&result))) {
+    using Result =
+        typename PollTraits<decltype(kontinue(IntoResult(&result)))>::Type;
+    if (!result.ok()) {
+      return Result(IntoStatus(&result));
+    }
+    return kontinue(IntoResult(&result));
+  }
+  template <typename T>
+  static absl::StatusOr<T> Wrap(T x) {
+    return absl::StatusOr<T>(std::move(x));
+  }
+};
+
+// Implementation of TryJoin combinator.
+template <typename... Promises>
+using TryJoin = BasicJoin<TryJoinTraits, Promises...>;
+
+}  // namespace promise_detail
+
+// Run all promises.
+// If any fail, cancel the rest and return the failure.
+// If all succeed, return Ok(tuple-of-results).
+template <typename... Promises>
+promise_detail::TryJoin<Promises...> TryJoin(Promises... promises) {
+  return promise_detail::TryJoin<Promises...>(std::move(promises)...);
+}
+
+}  // namespace grpc_core
+
+#endif  // GRPC_CORE_LIB_PROMISE_TRY_JOIN_H
diff --git a/src/core/lib/promise/try_seq.h b/src/core/lib/promise/try_seq.h
new file mode 100644 (file)
index 0000000..9b4fb93
--- /dev/null
@@ -0,0 +1,104 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#ifndef GRPC_CORE_LIB_PROMISE_TRY_SEQ_H
+#define GRPC_CORE_LIB_PROMISE_TRY_SEQ_H
+
+#include <grpc/impl/codegen/port_platform.h>
+
+#include <tuple>
+
+#include "absl/status/statusor.h"
+#include "absl/types/variant.h"
+
+#include "src/core/lib/promise/detail/basic_seq.h"
+#include "src/core/lib/promise/poll.h"
+
+namespace grpc_core {
+
+namespace promise_detail {
+
+template <typename T>
+struct TrySeqTraits {
+  using UnwrappedType = T;
+  using WrappedType = absl::StatusOr<T>;
+  template <typename Next>
+  static auto CallFactory(Next* next, T&& value)
+      -> decltype(next->Once(std::forward<T>(value))) {
+    return next->Once(std::forward<T>(value));
+  }
+  template <typename Result, typename RunNext>
+  static Poll<Result> CheckResultAndRunNext(T prior, RunNext run_next) {
+    return run_next(std::move(prior));
+  }
+};
+
+template <typename T>
+struct TrySeqTraits<absl::StatusOr<T>> {
+  using UnwrappedType = T;
+  using WrappedType = absl::StatusOr<T>;
+  template <typename Next>
+  static auto CallFactory(Next* next, absl::StatusOr<T>&& status)
+      -> decltype(next->Once(std::move(*status))) {
+    return next->Once(std::move(*status));
+  }
+  template <typename Result, typename RunNext>
+  static Poll<Result> CheckResultAndRunNext(absl::StatusOr<T> prior,
+                                            RunNext run_next) {
+    if (!prior.ok()) return Result(prior.status());
+    return run_next(std::move(prior));
+  }
+};
+template <>
+struct TrySeqTraits<absl::Status> {
+  using UnwrappedType = void;
+  using WrappedType = absl::Status;
+  template <typename Next>
+  static auto CallFactory(Next* next, absl::Status&&)
+      -> decltype(next->Once()) {
+    return next->Once();
+  }
+  template <typename Result, typename RunNext>
+  static Poll<Result> CheckResultAndRunNext(absl::Status prior,
+                                            RunNext run_next) {
+    if (!prior.ok()) return Result(prior);
+    return run_next(std::move(prior));
+  }
+};
+
+template <typename... Fs>
+using TrySeq = BasicSeq<TrySeqTraits, Fs...>;
+
+}  // namespace promise_detail
+
+// Try a sequence of operations.
+// * Run the first functor as a promise.
+// * Feed its success result into the second functor to create a promise,
+//   then run that.
+// * ...
+// * Feed the second-final success result into the final functor to create a
+//   promise, then run that, with the overall success result being that
+//   promises success result.
+// If any step fails, fail everything.
+// Functors can return StatusOr<> to signal that a value is fed forward, or
+// Status to indicate only success/failure. In the case of returning Status,
+// the construction functors take no arguments.
+template <typename... Functors>
+promise_detail::TrySeq<Functors...> TrySeq(Functors... functors) {
+  return promise_detail::TrySeq<Functors...>(std::move(functors)...);
+}
+
+}  // namespace grpc_core
+
+#endif  // GRPC_CORE_LIB_PROMISE_TRY_SEQ_H
diff --git a/src/core/lib/promise/wait_set.h b/src/core/lib/promise/wait_set.h
new file mode 100644 (file)
index 0000000..719f60b
--- /dev/null
@@ -0,0 +1,73 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#ifndef GRPC_CORE_LIB_PROMISE_WAIT_SET_H
+#define GRPC_CORE_LIB_PROMISE_WAIT_SET_H
+
+#include <grpc/impl/codegen/port_platform.h>
+
+#include "absl/container/flat_hash_set.h"
+
+#include "src/core/lib/promise/activity.h"
+
+namespace grpc_core {
+
+// Helper type that can be used to enqueue many Activities waiting for some
+// external state.
+// Typically the external state should be guarded by mu_, and a call to
+// WakeAllAndUnlock should be made when the state changes.
+// Promises should bottom out polling inside pending(), which will register for
+// wakeup and return Pending().
+// Queues handles to Activities, and not Activities themselves, meaning that if
+// an Activity is destroyed prior to wakeup we end up holding only a small
+// amount of memory (around 16 bytes + malloc overhead) until the next wakeup
+// occurs.
+class WaitSet final {
+  using WakerSet = absl::flat_hash_set<Waker>;
+
+ public:
+  // Register for wakeup, return Pending(). If state is not ready to proceed,
+  // Promises should bottom out here.
+  Pending AddPending(Waker waker) {
+    pending_.emplace(std::move(waker));
+    return Pending();
+  }
+
+  class WakeupSet {
+   public:
+    void Wakeup() {
+      while (!wakeup_.empty()) {
+        wakeup_.extract(wakeup_.begin()).value().Wakeup();
+      }
+    }
+
+   private:
+    friend class WaitSet;
+    explicit WakeupSet(WakerSet&& wakeup)
+        : wakeup_(std::forward<WakerSet>(wakeup)) {}
+    WakerSet wakeup_;
+  };
+
+  GRPC_MUST_USE_RESULT WakeupSet TakeWakeupSet() {
+    return WakeupSet(std::move(pending_));
+  }
+
+ private:
+  // Handles to activities that need to be awoken.
+  WakerSet pending_;
+};
+
+}  // namespace grpc_core
+
+#endif  // GRPC_CORE_LIB_PROMISE_WAIT_SET_H
index 1c9116a..0268a2c 100644 (file)
 struct grpc_authorization_policy_provider
     : public grpc_core::DualRefCounted<grpc_authorization_policy_provider> {
  public:
-  virtual grpc_core::RefCountedPtr<grpc_core::AuthorizationEngine>
-  allow_engine() const = 0;
-  virtual grpc_core::RefCountedPtr<grpc_core::AuthorizationEngine> deny_engine()
-      const = 0;
+  struct AuthorizationEngines {
+    grpc_core::RefCountedPtr<grpc_core::AuthorizationEngine> allow_engine;
+    grpc_core::RefCountedPtr<grpc_core::AuthorizationEngine> deny_engine;
+  };
+  virtual AuthorizationEngines engines() const = 0;
 };
 
 #endif  // GRPC_CORE_LIB_SECURITY_AUTHORIZATION_AUTHORIZATION_POLICY_PROVIDER_H
index fae5cc4..a5d0a92 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
+#include "src/core/lib/security/authorization/cel_authorization_engine.h"
+
 #include "absl/memory/memory.h"
 
 #include "src/core/lib/address_utils/sockaddr_utils.h"
-#include "src/core/lib/security/authorization/cel_authorization_engine.h"
 
 namespace grpc_core {
 
index 6f37bfb..3c20478 100644 (file)
@@ -18,7 +18,6 @@
 
 #include <grpc/support/port_platform.h>
 
-#include <grpc/support/log.h>
 #include <map>
 #include <memory>
 #include <string>
@@ -29,6 +28,8 @@
 #include "google/api/expr/v1alpha1/syntax.upb.h"
 #include "upb/upb.hpp"
 
+#include <grpc/support/log.h>
+
 #include "src/core/lib/security/authorization/evaluate_args.h"
 #include "src/core/lib/security/authorization/mock_cel/activation.h"
 
index 2a8e0a6..aa9f249 100644 (file)
@@ -16,6 +16,8 @@
 
 #include "src/core/lib/security/authorization/evaluate_args.h"
 
+#include "absl/strings/numbers.h"
+
 #include "src/core/lib/address_utils/parse_address.h"
 #include "src/core/lib/address_utils/sockaddr_utils.h"
 #include "src/core/lib/gprpp/host_port.h"
index a2e706c..7a0c77e 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
+#include "src/core/lib/security/authorization/grpc_authorization_policy_provider.h"
+
 #include <grpc/grpc_security.h>
 #include <grpc/support/string_util.h>
 
 #include "src/core/lib/security/authorization/grpc_authorization_engine.h"
-#include "src/core/lib/security/authorization/grpc_authorization_policy_provider.h"
 
 namespace grpc_core {
 
index 97c9d85..4e80ac6 100644 (file)
@@ -38,11 +38,8 @@ class StaticDataAuthorizationPolicyProvider
 
   explicit StaticDataAuthorizationPolicyProvider(RbacPolicies policies);
 
-  RefCountedPtr<AuthorizationEngine> allow_engine() const override {
-    return allow_engine_;
-  }
-  RefCountedPtr<AuthorizationEngine> deny_engine() const override {
-    return deny_engine_;
+  AuthorizationEngines engines() const override {
+    return {allow_engine_, deny_engine_};
   }
 
   void Orphan() override {}
index ddff2bb..a5d337b 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
+#include "src/core/lib/security/authorization/matchers.h"
+
 #include <grpc/grpc_security_constants.h>
 
 #include "src/core/lib/address_utils/sockaddr_utils.h"
-#include "src/core/lib/security/authorization/matchers.h"
 
 namespace grpc_core {
 
index 34a31a6..82ece38 100644 (file)
@@ -21,8 +21,8 @@
 #include <vector>
 
 #include "absl/status/statusor.h"
-
 #include "google/api/expr/v1alpha1/syntax.upb.h"
+
 #include "src/core/lib/security/authorization/mock_cel/activation.h"
 #include "src/core/lib/security/authorization/mock_cel/cel_value.h"
 
index 9aab0d2..1cf9915 100644 (file)
@@ -22,8 +22,8 @@
 #include <vector>
 
 #include "absl/status/statusor.h"
-
 #include "google/api/expr/v1alpha1/syntax.upb.h"
+
 #include "src/core/lib/security/authorization/mock_cel/activation.h"
 #include "src/core/lib/security/authorization/mock_cel/cel_expression.h"
 #include "src/core/lib/security/authorization/mock_cel/cel_value.h"
index ea5599d..ef82af7 100644 (file)
@@ -20,6 +20,7 @@
 #include "absl/strings/str_format.h"
 #include "absl/strings/strip.h"
 
+#include "src/core/lib/gpr/useful.h"
 #include "src/core/lib/matchers/matchers.h"
 
 namespace grpc_core {
@@ -56,6 +57,24 @@ absl::StatusOr<HeaderMatcher> GetHeaderMatcher(absl::string_view name,
                                matcher);
 }
 
+bool IsUnsupportedHeader(absl::string_view header_name) {
+  static const char* const kUnsupportedHeaders[] = {"host",
+                                                    "connection",
+                                                    "keep-alive",
+                                                    "proxy-authenticate",
+                                                    "proxy-authorization",
+                                                    "te",
+                                                    "trailer",
+                                                    "transfer-encoding",
+                                                    "upgrade"};
+  for (size_t i = 0; i < GPR_ARRAY_SIZE(kUnsupportedHeaders); ++i) {
+    if (absl::EqualsIgnoreCase(header_name, kUnsupportedHeaders[i])) {
+      return true;
+    }
+  }
+  return false;
+}
+
 absl::StatusOr<Rbac::Principal> ParsePrincipalsArray(const Json& json) {
   std::vector<std::unique_ptr<Rbac::Principal>> principal_names;
   for (size_t i = 0; i < json.array_value().size(); ++i) {
@@ -131,10 +150,9 @@ absl::StatusOr<Rbac::Permission> ParseHeaders(const Json& json) {
     return absl::InvalidArgumentError("\"key\" is not a string.");
   }
   absl::string_view header_name = it->second.string_value();
-  // TODO(ashithasantosh): Add connection headers below.
   if (absl::StartsWith(header_name, ":") ||
-      absl::StartsWith(header_name, "grpc-") || header_name == "host" ||
-      header_name == "Host") {
+      absl::StartsWith(header_name, "grpc-") ||
+      IsUnsupportedHeader(header_name)) {
     return absl::InvalidArgumentError(
         absl::StrFormat("Unsupported \"key\" %s.", header_name));
   }
index 51d7024..4adab7d 100644 (file)
@@ -18,6 +18,7 @@
 #include <grpc/support/port_platform.h>
 
 #include "absl/status/statusor.h"
+
 #include "src/core/lib/json/json.h"
 #include "src/core/lib/security/authorization/rbac_policy.h"
 
diff --git a/src/core/lib/security/authorization/sdk_server_authz_filter.cc b/src/core/lib/security/authorization/sdk_server_authz_filter.cc
new file mode 100644 (file)
index 0000000..473fc73
--- /dev/null
@@ -0,0 +1,159 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#include <grpc/support/port_platform.h>
+
+#include "src/core/lib/security/authorization/sdk_server_authz_filter.h"
+
+#include "src/core/lib/security/authorization/evaluate_args.h"
+#include "src/core/lib/transport/transport.h"
+
+namespace grpc_core {
+
+TraceFlag grpc_sdk_authz_trace(false, "sdk_authz");
+
+SdkServerAuthzFilter::SdkServerAuthzFilter(
+    RefCountedPtr<grpc_auth_context> auth_context, grpc_endpoint* endpoint,
+    RefCountedPtr<grpc_authorization_policy_provider> provider)
+    : auth_context_(std::move(auth_context)),
+      per_channel_evaluate_args_(auth_context_.get(), endpoint),
+      provider_(std::move(provider)) {}
+
+grpc_error_handle SdkServerAuthzFilter::Init(grpc_channel_element* elem,
+                                             grpc_channel_element_args* args) {
+  GPR_ASSERT(!args->is_last);
+  grpc_auth_context* auth_context =
+      grpc_find_auth_context_in_args(args->channel_args);
+  grpc_authorization_policy_provider* provider =
+      grpc_channel_args_find_pointer<grpc_authorization_policy_provider>(
+          args->channel_args, GRPC_ARG_AUTHORIZATION_POLICY_PROVIDER);
+  if (provider == nullptr) {
+    return GRPC_ERROR_CREATE_FROM_STATIC_STRING(
+        "Failed to get authorization provider.");
+  }
+  // grpc_endpoint isn't needed because the current SDK authorization policy
+  // does not support any rules that requires looking for source or destination
+  // addresses.
+  new (elem->channel_data) SdkServerAuthzFilter(
+      auth_context != nullptr ? auth_context->Ref() : nullptr,
+      /*endpoint=*/nullptr, provider->Ref());
+  return GRPC_ERROR_NONE;
+}
+
+void SdkServerAuthzFilter::Destroy(grpc_channel_element* elem) {
+  auto* chand = static_cast<SdkServerAuthzFilter*>(elem->channel_data);
+  chand->~SdkServerAuthzFilter();
+}
+
+SdkServerAuthzFilter::CallData::CallData(grpc_call_element* elem) {
+  GRPC_CLOSURE_INIT(&recv_initial_metadata_ready_, RecvInitialMetadataReady,
+                    elem, grpc_schedule_on_exec_ctx);
+}
+
+void SdkServerAuthzFilter::CallData::StartTransportStreamOpBatch(
+    grpc_call_element* elem, grpc_transport_stream_op_batch* batch) {
+  auto* calld = static_cast<CallData*>(elem->call_data);
+  if (batch->recv_initial_metadata) {
+    // Inject our callback.
+    calld->recv_initial_metadata_batch_ =
+        batch->payload->recv_initial_metadata.recv_initial_metadata;
+    calld->original_recv_initial_metadata_ready_ =
+        batch->payload->recv_initial_metadata.recv_initial_metadata_ready;
+    batch->payload->recv_initial_metadata.recv_initial_metadata_ready =
+        &calld->recv_initial_metadata_ready_;
+  }
+  grpc_call_next_op(elem, batch);
+}
+
+grpc_error_handle SdkServerAuthzFilter::CallData::Init(
+    grpc_call_element* elem, const grpc_call_element_args*) {
+  new (elem->call_data) CallData(elem);
+  return GRPC_ERROR_NONE;
+}
+
+void SdkServerAuthzFilter::CallData::Destroy(
+    grpc_call_element* elem, const grpc_call_final_info* /*final_info*/,
+    grpc_closure* /*ignored*/) {
+  CallData* calld = static_cast<CallData*>(elem->call_data);
+  calld->~CallData();
+}
+
+bool SdkServerAuthzFilter::CallData::IsAuthorized(SdkServerAuthzFilter* chand) {
+  EvaluateArgs args(recv_initial_metadata_batch_,
+                    &chand->per_channel_evaluate_args_);
+  grpc_authorization_policy_provider::AuthorizationEngines engines =
+      chand->provider_->engines();
+  if (engines.deny_engine != nullptr) {
+    AuthorizationEngine::Decision decision =
+        engines.deny_engine->Evaluate(args);
+    if (decision.type == AuthorizationEngine::Decision::Type::kDeny) {
+      if (GRPC_TRACE_FLAG_ENABLED(grpc_sdk_authz_trace)) {
+        gpr_log(GPR_INFO, "chand=%p calld=%p: request denied by policy %s.",
+                chand, this, decision.matching_policy_name.c_str());
+      }
+      return false;
+    }
+  }
+  if (engines.allow_engine != nullptr) {
+    AuthorizationEngine::Decision decision =
+        engines.allow_engine->Evaluate(args);
+    if (decision.type == AuthorizationEngine::Decision::Type::kAllow) {
+      if (GRPC_TRACE_FLAG_ENABLED(grpc_sdk_authz_trace)) {
+        gpr_log(GPR_INFO, "chand=%p calld=%p: request allowed by policy %s.",
+                chand, this, decision.matching_policy_name.c_str());
+      }
+      return true;
+    }
+  }
+  if (GRPC_TRACE_FLAG_ENABLED(grpc_sdk_authz_trace)) {
+    gpr_log(GPR_INFO,
+            "chand=%p calld=%p: request denied, no matching policy found.",
+            chand, this);
+  }
+  return false;
+}
+
+void SdkServerAuthzFilter::CallData::RecvInitialMetadataReady(
+    void* arg, grpc_error_handle error) {
+  grpc_call_element* elem = static_cast<grpc_call_element*>(arg);
+  auto* chand = static_cast<SdkServerAuthzFilter*>(elem->channel_data);
+  auto* calld = static_cast<CallData*>(elem->call_data);
+  if (error == GRPC_ERROR_NONE) {
+    if (!calld->IsAuthorized(chand)) {
+      error = grpc_error_set_int(GRPC_ERROR_CREATE_FROM_STATIC_STRING(
+                                     "Unauthorized RPC request rejected."),
+                                 GRPC_ERROR_INT_GRPC_STATUS,
+                                 GRPC_STATUS_PERMISSION_DENIED);
+    }
+  } else {
+    GRPC_ERROR_REF(error);
+  }
+  Closure::Run(DEBUG_LOCATION, calld->original_recv_initial_metadata_ready_,
+               error);
+}
+
+const grpc_channel_filter SdkServerAuthzFilter::kFilterVtable = {
+    SdkServerAuthzFilter::CallData::StartTransportStreamOpBatch,
+    grpc_channel_next_op,
+    sizeof(SdkServerAuthzFilter::CallData),
+    SdkServerAuthzFilter::CallData::Init,
+    grpc_call_stack_ignore_set_pollset_or_pollset_set,
+    SdkServerAuthzFilter::CallData::Destroy,
+    sizeof(SdkServerAuthzFilter),
+    SdkServerAuthzFilter::Init,
+    SdkServerAuthzFilter::Destroy,
+    grpc_channel_next_get_info,
+    "sdk-server-authz"};
+
+}  // namespace grpc_core
diff --git a/src/core/lib/security/authorization/sdk_server_authz_filter.h b/src/core/lib/security/authorization/sdk_server_authz_filter.h
new file mode 100644 (file)
index 0000000..f11716c
--- /dev/null
@@ -0,0 +1,67 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#ifndef GRPC_CORE_LIB_SECURITY_AUTHORIZATION_SDK_SERVER_AUTHZ_FILTER_H
+#define GRPC_CORE_LIB_SECURITY_AUTHORIZATION_SDK_SERVER_AUTHZ_FILTER_H
+
+#include <grpc/support/port_platform.h>
+
+#include "src/core/lib/channel/channel_stack.h"
+#include "src/core/lib/security/authorization/authorization_policy_provider.h"
+
+namespace grpc_core {
+
+class SdkServerAuthzFilter {
+ public:
+  static const grpc_channel_filter kFilterVtable;
+
+ private:
+  class CallData {
+   public:
+    static void StartTransportStreamOpBatch(
+        grpc_call_element* elem, grpc_transport_stream_op_batch* batch);
+    static grpc_error_handle Init(grpc_call_element* elem,
+                                  const grpc_call_element_args*);
+    static void Destroy(grpc_call_element* elem,
+                        const grpc_call_final_info* /*final_info*/,
+                        grpc_closure* /*ignored*/);
+
+   private:
+    explicit CallData(grpc_call_element* elem);
+
+    bool IsAuthorized(SdkServerAuthzFilter* chand);
+
+    static void RecvInitialMetadataReady(void* arg, grpc_error_handle error);
+
+    grpc_metadata_batch* recv_initial_metadata_batch_;
+    grpc_closure* original_recv_initial_metadata_ready_;
+    grpc_closure recv_initial_metadata_ready_;
+  };
+
+  SdkServerAuthzFilter(
+      RefCountedPtr<grpc_auth_context> auth_context, grpc_endpoint* endpoint,
+      RefCountedPtr<grpc_authorization_policy_provider> provider);
+
+  static grpc_error_handle Init(grpc_channel_element* elem,
+                                grpc_channel_element_args* args);
+  static void Destroy(grpc_channel_element* elem);
+
+  RefCountedPtr<grpc_auth_context> auth_context_;
+  EvaluateArgs::PerChannelArgs per_channel_evaluate_args_;
+  RefCountedPtr<grpc_authorization_policy_provider> provider_;
+};
+
+}  // namespace grpc_core
+
+#endif  // GRPC_CORE_LIB_SECURITY_AUTHORIZATION_SDK_SERVER_AUTHZ_FILTER_H
index d760d82..bc683f3 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
+#include "src/core/lib/security/context/security_context.h"
+
 #include <string.h>
 
+#include <grpc/grpc_security.h>
+#include <grpc/support/alloc.h>
+#include <grpc/support/log.h>
+#include <grpc/support/string_util.h>
+
 #include "src/core/lib/channel/channel_args.h"
 #include "src/core/lib/gpr/string.h"
 #include "src/core/lib/gprpp/arena.h"
 #include "src/core/lib/gprpp/ref_counted.h"
 #include "src/core/lib/gprpp/ref_counted_ptr.h"
-#include "src/core/lib/security/context/security_context.h"
 #include "src/core/lib/surface/api_trace.h"
 #include "src/core/lib/surface/call.h"
 
-#include <grpc/grpc_security.h>
-#include <grpc/support/alloc.h>
-#include <grpc/support/log.h>
-#include <grpc/support/string_util.h>
-
 grpc_core::DebugOnlyTraceFlag grpc_trace_auth_context_refcount(
     false, "auth_context_refcount");
 
index 8454fd7..0c6f556 100644 (file)
 
 #ifdef GPR_LINUX
 
-#include "src/core/lib/security/credentials/alts/check_gcp_environment.h"
+#include <string.h>
 
 #include <grpc/support/alloc.h>
 #include <grpc/support/sync.h>
 
-#include <string.h>
+#include "src/core/lib/security/credentials/alts/check_gcp_environment.h"
 
 #define GRPC_ALTS_EXPECT_NAME_GOOGLE "Google"
 #define GRPC_ALTS_EXPECT_NAME_GCE "Google Compute Engine"
index b71f66a..cb40102 100644 (file)
 
 #if !defined(GPR_LINUX) && !defined(GPR_WINDOWS)
 
-#include "src/core/lib/security/credentials/alts/check_gcp_environment.h"
-
 #include <grpc/support/log.h>
 
+#include "src/core/lib/security/credentials/alts/check_gcp_environment.h"
+
 bool grpc_alts_is_running_on_gcp() {
   gpr_log(GPR_INFO,
           "ALTS: Platforms other than Linux and Windows are not supported");
index 59432cf..5d2bdc1 100644 (file)
@@ -20,8 +20,6 @@
 
 #ifdef GPR_WINDOWS
 
-#include "src/core/lib/security/credentials/alts/check_gcp_environment.h"
-
 #include <shellapi.h>
 #include <stdio.h>
 #include <tchar.h>
@@ -31,6 +29,8 @@
 #include <grpc/support/log.h>
 #include <grpc/support/sync.h>
 
+#include "src/core/lib/security/credentials/alts/check_gcp_environment.h"
+
 namespace grpc_core {
 namespace internal {
 
index 5543ad1..b4bdc31 100644 (file)
 
 #include "absl/strings/str_cat.h"
 #include "absl/strings/str_join.h"
-#include "src/core/lib/gprpp/ref_counted_ptr.h"
-#include "src/core/lib/iomgr/polling_entity.h"
-#include "src/core/lib/surface/api_trace.h"
 
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/string_util.h>
 
+#include "src/core/lib/gprpp/ref_counted_ptr.h"
+#include "src/core/lib/iomgr/polling_entity.h"
+#include "src/core/lib/surface/api_trace.h"
+
 /* -- Composite call credentials. -- */
 
 static void composite_call_metadata_cb(void* arg, grpc_error_handle error);
index d2f4c9c..dcc69d7 100644 (file)
 #include <stdio.h>
 #include <string.h>
 
+#include <grpc/support/alloc.h>
+#include <grpc/support/log.h>
+#include <grpc/support/string_util.h>
+#include <grpc/support/sync.h>
+#include <grpc/support/time.h>
+
 #include "src/core/lib/channel/channel_args.h"
 #include "src/core/lib/gpr/string.h"
 #include "src/core/lib/http/httpcli.h"
 #include "src/core/lib/json/json.h"
 #include "src/core/lib/surface/api_trace.h"
 
-#include <grpc/support/alloc.h>
-#include <grpc/support/log.h>
-#include <grpc/support/string_util.h>
-#include <grpc/support/sync.h>
-#include <grpc/support/time.h>
-
 /* -- Common. -- */
 
 void grpc_channel_credentials_release(grpc_channel_credentials* creds) {
index b8609c5..737fe87 100644 (file)
 #include <grpc/grpc.h>
 #include <grpc/grpc_security.h>
 #include <grpc/support/sync.h>
-#include "src/core/lib/transport/metadata_batch.h"
 
 #include "src/core/lib/gprpp/ref_counted.h"
 #include "src/core/lib/http/httpcli.h"
 #include "src/core/lib/http/parser.h"
 #include "src/core/lib/iomgr/polling_entity.h"
 #include "src/core/lib/security/security_connector/security_connector.h"
+#include "src/core/lib/transport/metadata_batch.h"
 
 struct grpc_http_response;
 
index 703de4a..9d0284d 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include "src/core/lib/security/credentials/credentials.h"
+#include <string.h>
 
 #include <grpc/support/alloc.h>
 
-#include <string.h>
-
+#include "src/core/lib/security/credentials/credentials.h"
 #include "src/core/lib/slice/slice_internal.h"
 
 static void mdelem_list_ensure_capacity(grpc_credentials_mdelem_array* list,
index c479bf0..03dd4d5 100644 (file)
@@ -155,10 +155,9 @@ void AwsExternalAccountCredentials::RetrieveRegion() {
   }
   absl::StatusOr<URI> uri = URI::Parse(region_url_);
   if (!uri.ok()) {
-    FinishRetrieveSubjectToken("", GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-                                       absl::StrFormat("Invalid region url. %s",
-                                                       uri.status().ToString())
-                                           .c_str()));
+    FinishRetrieveSubjectToken(
+        "", GRPC_ERROR_CREATE_FROM_CPP_STRING(absl::StrFormat(
+                "Invalid region url. %s", uri.status().ToString())));
     return;
   }
   grpc_httpcli_request request;
@@ -174,7 +173,6 @@ void AwsExternalAccountCredentials::RetrieveRegion() {
   GRPC_CLOSURE_INIT(&ctx_->closure, OnRetrieveRegion, this, nullptr);
   grpc_httpcli_get(ctx_->httpcli_context, ctx_->pollent, resource_quota,
                    &request, ctx_->deadline, &ctx_->closure, &ctx_->response);
-  grpc_resource_quota_unref_internal(resource_quota);
   grpc_http_request_destroy(&request.http);
 }
 
@@ -206,9 +204,8 @@ void AwsExternalAccountCredentials::RetrieveRoleName() {
   absl::StatusOr<URI> uri = URI::Parse(url_);
   if (!uri.ok()) {
     FinishRetrieveSubjectToken(
-        "", GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-                absl::StrFormat("Invalid url: %s.", uri.status().ToString())
-                    .c_str()));
+        "", GRPC_ERROR_CREATE_FROM_CPP_STRING(
+                absl::StrFormat("Invalid url: %s.", uri.status().ToString())));
     return;
   }
   grpc_httpcli_request request;
@@ -224,7 +221,6 @@ void AwsExternalAccountCredentials::RetrieveRoleName() {
   GRPC_CLOSURE_INIT(&ctx_->closure, OnRetrieveRoleName, this, nullptr);
   grpc_httpcli_get(ctx_->httpcli_context, ctx_->pollent, resource_quota,
                    &request, ctx_->deadline, &ctx_->closure, &ctx_->response);
-  grpc_resource_quota_unref_internal(resource_quota);
   grpc_http_request_destroy(&request.http);
 }
 
@@ -268,10 +264,8 @@ void AwsExternalAccountCredentials::RetrieveSigningKeys() {
   absl::StatusOr<URI> uri = URI::Parse(url_with_role_name);
   if (!uri.ok()) {
     FinishRetrieveSubjectToken(
-        "", GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-                absl::StrFormat("Invalid url with role name: %s.",
-                                uri.status().ToString())
-                    .c_str()));
+        "", GRPC_ERROR_CREATE_FROM_CPP_STRING(absl::StrFormat(
+                "Invalid url with role name: %s.", uri.status().ToString())));
     return;
   }
   grpc_httpcli_request request;
@@ -287,7 +281,6 @@ void AwsExternalAccountCredentials::RetrieveSigningKeys() {
   GRPC_CLOSURE_INIT(&ctx_->closure, OnRetrieveSigningKeys, this, nullptr);
   grpc_httpcli_get(ctx_->httpcli_context, ctx_->pollent, resource_quota,
                    &request, ctx_->deadline, &ctx_->closure, &ctx_->response);
-  grpc_resource_quota_unref_internal(resource_quota);
   grpc_http_request_destroy(&request.http);
 }
 
@@ -320,10 +313,8 @@ void AwsExternalAccountCredentials::OnRetrieveSigningKeysInternal(
     access_key_id_ = it->second.string_value();
   } else {
     FinishRetrieveSubjectToken(
-        "", GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-                absl::StrFormat("Missing or invalid AccessKeyId in %s.",
-                                response_body)
-                    .c_str()));
+        "", GRPC_ERROR_CREATE_FROM_CPP_STRING(absl::StrFormat(
+                "Missing or invalid AccessKeyId in %s.", response_body)));
     return;
   }
   it = json.object_value().find("SecretAccessKey");
@@ -332,10 +323,8 @@ void AwsExternalAccountCredentials::OnRetrieveSigningKeysInternal(
     secret_access_key_ = it->second.string_value();
   } else {
     FinishRetrieveSubjectToken(
-        "", GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-                absl::StrFormat("Missing or invalid SecretAccessKey in %s.",
-                                response_body)
-                    .c_str()));
+        "", GRPC_ERROR_CREATE_FROM_CPP_STRING(absl::StrFormat(
+                "Missing or invalid SecretAccessKey in %s.", response_body)));
     return;
   }
   it = json.object_value().find("Token");
@@ -344,10 +333,8 @@ void AwsExternalAccountCredentials::OnRetrieveSigningKeysInternal(
     token_ = it->second.string_value();
   } else {
     FinishRetrieveSubjectToken(
-        "",
-        GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-            absl::StrFormat("Missing or invalid Token in %s.", response_body)
-                .c_str()));
+        "", GRPC_ERROR_CREATE_FROM_CPP_STRING(absl::StrFormat(
+                "Missing or invalid Token in %s.", response_body)));
     return;
   }
   BuildSubjectToken();
index 50ccf19..bf232f2 100644 (file)
@@ -19,9 +19,8 @@
 
 #include <grpc/support/port_platform.h>
 
-#include "src/core/lib/security/credentials/external/external_account_credentials.h"
-
 #include "src/core/lib/security/credentials/external/aws_request_signer.h"
+#include "src/core/lib/security/credentials/external/external_account_credentials.h"
 
 namespace grpc_core {
 
index b665701..bc4920f 100644 (file)
@@ -17,6 +17,9 @@
 
 #include "src/core/lib/security/credentials/external/aws_request_signer.h"
 
+#include <openssl/hmac.h>
+#include <openssl/sha.h>
+
 #include "absl/strings/ascii.h"
 #include "absl/strings/escaping.h"
 #include "absl/strings/str_format.h"
@@ -25,9 +28,6 @@
 #include "absl/time/clock.h"
 #include "absl/time/time.h"
 
-#include <openssl/hmac.h>
-#include <openssl/sha.h>
-
 namespace grpc_core {
 
 namespace {
index f5d9442..f3c6a78 100644 (file)
 #include "absl/time/time.h"
 
 #include "src/core/lib/http/parser.h"
-#include "src/core/lib/security/util/json_util.h"
-#include "src/core/lib/slice/b64.h"
-
 #include "src/core/lib/security/credentials/external/aws_external_account_credentials.h"
 #include "src/core/lib/security/credentials/external/file_external_account_credentials.h"
 #include "src/core/lib/security/credentials/external/url_external_account_credentials.h"
+#include "src/core/lib/security/util/json_util.h"
+#include "src/core/lib/slice/b64.h"
 
 #define EXTERNAL_ACCOUNT_CREDENTIALS_GRANT_TYPE \
   "urn:ietf:params:oauth:grant-type:token-exchange"
@@ -233,10 +232,9 @@ void ExternalAccountCredentials::ExchangeToken(
     absl::string_view subject_token) {
   absl::StatusOr<URI> uri = URI::Parse(options_.token_url);
   if (!uri.ok()) {
-    FinishTokenFetch(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
+    FinishTokenFetch(GRPC_ERROR_CREATE_FROM_CPP_STRING(
         absl::StrFormat("Invalid token url: %s. Error: %s", options_.token_url,
-                        uri.status().ToString())
-            .c_str()));
+                        uri.status().ToString())));
     return;
   }
   grpc_httpcli_request request;
@@ -297,7 +295,6 @@ void ExternalAccountCredentials::ExchangeToken(
   grpc_httpcli_post(ctx_->httpcli_context, ctx_->pollent, resource_quota,
                     &request, body.c_str(), body.size(), ctx_->deadline,
                     &ctx_->closure, &ctx_->response);
-  grpc_resource_quota_unref_internal(resource_quota);
   grpc_http_request_destroy(&request.http);
 }
 
@@ -346,20 +343,17 @@ void ExternalAccountCredentials::ImpersenateServiceAccount() {
   auto it = json.object_value().find("access_token");
   if (it == json.object_value().end() ||
       it->second.type() != Json::Type::STRING) {
-    FinishTokenFetch(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-        absl::StrFormat("Missing or invalid access_token in %s.", response_body)
-            .c_str()));
+    FinishTokenFetch(GRPC_ERROR_CREATE_FROM_CPP_STRING(absl::StrFormat(
+        "Missing or invalid access_token in %s.", response_body)));
     return;
   }
   std::string access_token = it->second.string_value();
   absl::StatusOr<URI> uri =
       URI::Parse(options_.service_account_impersonation_url);
   if (!uri.ok()) {
-    FinishTokenFetch(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-        absl::StrFormat(
-            "Invalid service account impersonation url: %s. Error: %s",
-            options_.service_account_impersonation_url, uri.status().ToString())
-            .c_str()));
+    FinishTokenFetch(GRPC_ERROR_CREATE_FROM_CPP_STRING(absl::StrFormat(
+        "Invalid service account impersonation url: %s. Error: %s",
+        options_.service_account_impersonation_url, uri.status().ToString())));
     return;
   }
   grpc_httpcli_request request;
@@ -387,7 +381,6 @@ void ExternalAccountCredentials::ImpersenateServiceAccount() {
   grpc_httpcli_post(ctx_->httpcli_context, ctx_->pollent, resource_quota,
                     &request, body.c_str(), body.size(), ctx_->deadline,
                     &ctx_->closure, &ctx_->response);
-  grpc_resource_quota_unref_internal(resource_quota);
   grpc_http_request_destroy(&request.http);
 }
 
@@ -416,18 +409,16 @@ void ExternalAccountCredentials::OnImpersenateServiceAccountInternal(
   auto it = json.object_value().find("accessToken");
   if (it == json.object_value().end() ||
       it->second.type() != Json::Type::STRING) {
-    FinishTokenFetch(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-        absl::StrFormat("Missing or invalid accessToken in %s.", response_body)
-            .c_str()));
+    FinishTokenFetch(GRPC_ERROR_CREATE_FROM_CPP_STRING(absl::StrFormat(
+        "Missing or invalid accessToken in %s.", response_body)));
     return;
   }
   std::string access_token = it->second.string_value();
   it = json.object_value().find("expireTime");
   if (it == json.object_value().end() ||
       it->second.type() != Json::Type::STRING) {
-    FinishTokenFetch(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-        absl::StrFormat("Missing or invalid expireTime in %s.", response_body)
-            .c_str()));
+    FinishTokenFetch(GRPC_ERROR_CREATE_FROM_CPP_STRING(absl::StrFormat(
+        "Missing or invalid expireTime in %s.", response_body)));
     return;
   }
   std::string expire_time = it->second.string_value();
index 55151b9..b48bf71 100644 (file)
@@ -51,10 +51,9 @@ UrlExternalAccountCredentials::UrlExternalAccountCredentials(
   }
   absl::StatusOr<URI> tmp_url = URI::Parse(it->second.string_value());
   if (!tmp_url.ok()) {
-    *error = GRPC_ERROR_CREATE_FROM_COPIED_STRING(
+    *error = GRPC_ERROR_CREATE_FROM_CPP_STRING(
         absl::StrFormat("Invalid credential source url. Error: %s",
-                        tmp_url.status().ToString())
-            .c_str());
+                        tmp_url.status().ToString()));
     return;
   }
   url_ = *tmp_url;
@@ -147,7 +146,6 @@ void UrlExternalAccountCredentials::RetrieveSubjectToken(
   GRPC_CLOSURE_INIT(&ctx_->closure, OnRetrieveSubjectToken, this, nullptr);
   grpc_httpcli_get(ctx_->httpcli_context, ctx_->pollent, resource_quota,
                    &request, ctx_->deadline, &ctx_->closure, &ctx_->response);
-  grpc_resource_quota_unref_internal(resource_quota);
   grpc_http_request_destroy(&request.http);
 }
 
index 8716ede..1b56824 100644 (file)
@@ -18,8 +18,6 @@
 
 #include <grpc/support/port_platform.h>
 
-#include "src/core/lib/security/credentials/google_default/google_default_credentials.h"
-
 #include <string>
 
 #include "absl/strings/str_cat.h"
@@ -28,6 +26,7 @@
 #include <grpc/support/log.h>
 
 #include "src/core/lib/gpr/env.h"
+#include "src/core/lib/security/credentials/google_default/google_default_credentials.h"
 
 std::string grpc_get_well_known_google_credentials_file_path_impl(void) {
   char* base = gpr_getenv(GRPC_GOOGLE_CREDENTIALS_PATH_ENV_VAR);
index 93fdd53..1d95fe3 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include "src/core/lib/security/credentials/credentials.h"
+#include "src/core/lib/security/credentials/google_default/google_default_credentials.h"
 
 #include <string.h>
 
 #include "absl/strings/match.h"
+#include "absl/strings/strip.h"
 
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
@@ -33,6 +34,7 @@
 #include "src/core/lib/channel/channel_args.h"
 #include "src/core/lib/gpr/env.h"
 #include "src/core/lib/gpr/string.h"
+#include "src/core/lib/gprpp/host_port.h"
 #include "src/core/lib/gprpp/ref_counted_ptr.h"
 #include "src/core/lib/http/httpcli.h"
 #include "src/core/lib/http/parser.h"
@@ -40,8 +42,8 @@
 #include "src/core/lib/iomgr/polling_entity.h"
 #include "src/core/lib/security/credentials/alts/alts_credentials.h"
 #include "src/core/lib/security/credentials/alts/check_gcp_environment.h"
+#include "src/core/lib/security/credentials/credentials.h"
 #include "src/core/lib/security/credentials/external/external_account_credentials.h"
-#include "src/core/lib/security/credentials/google_default/google_default_credentials.h"
 #include "src/core/lib/security/credentials/jwt/jwt_credentials.h"
 #include "src/core/lib/security/credentials/oauth2/oauth2_credentials.h"
 #include "src/core/lib/slice/slice_internal.h"
@@ -193,7 +195,6 @@ static int is_metadata_server_reachable() {
       GRPC_CLOSURE_CREATE(on_metadata_server_detection_http_response, &detector,
                           grpc_schedule_on_exec_ctx),
       &detector.response);
-  grpc_resource_quota_unref_internal(resource_quota);
   grpc_core::ExecCtx::Get()->Flush();
   /* Block until we get the response. This is not ideal but this should only be
     called once for the lifetime of the process by the default credentials. */
@@ -222,6 +223,52 @@ static int is_metadata_server_reachable() {
   return detector.success;
 }
 
+namespace {
+
+bool ValidateUrlField(const Json& json, const std::string& field) {
+  auto it = json.object_value().find(field);
+  if (it == json.object_value().end()) {
+    return true;
+  }
+  if (it->second.type() != Json::Type::STRING ||
+      it->second.string_value().empty()) {
+    return false;
+  }
+  absl::StatusOr<grpc_core::URI> url =
+      grpc_core::URI::Parse(it->second.string_value());
+  if (!url.ok()) return false;
+  if (!absl::EqualsIgnoreCase(url->scheme(), "https")) {
+    return false;
+  }
+  absl::string_view host;
+  absl::string_view port;
+  grpc_core::SplitHostPort(url->authority(), &host, &port);
+  if (absl::ConsumeSuffix(&host, ".googleapis.com")) {
+    if (host == "sts" || host == "iamcredentials") {
+      return true;
+    } else if (absl::StartsWith(host, "sts.") ||
+               absl::StartsWith(host, "iamcredentials.")) {
+      return true;
+    } else if (absl::EndsWith(host, ".sts") ||
+               absl::EndsWith(host, ".iamcredentials")) {
+      return true;
+    } else if (absl::EndsWith(host, "-sts") ||
+               absl::EndsWith(host, "-iamcredentials")) {
+      return true;
+    }
+  }
+  return false;
+}
+
+bool ValidateExteralAccountCredentials(const Json& json) {
+  return json.type() == Json::Type::OBJECT &&
+         ValidateUrlField(json, "token_url") &&
+         ValidateUrlField(json, "service_account_impersonation_url") &&
+         ValidateUrlField(json, "token_info_url");
+}
+
+}  // namespace
+
 /* Takes ownership of creds_path if not NULL. */
 static grpc_error_handle create_default_creds_from_path(
     const std::string& creds_path,
@@ -275,6 +322,11 @@ static grpc_error_handle create_default_creds_from_path(
   }
 
   /* Finally try an external account credentials.*/
+  if (!ValidateExteralAccountCredentials(json)) {
+    error = GRPC_ERROR_CREATE_FROM_STATIC_STRING(
+        "Invalid external account credentials format.");
+    goto end;
+  }
   result = grpc_core::ExternalAccountCredentials::Create(json, {}, &error);
 
 end:
index c9dc223..36e7f11 100644 (file)
 
 #include "src/core/lib/security/credentials/iam/iam_credentials.h"
 
+#include "absl/strings/str_format.h"
+
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/string_util.h>
 #include <grpc/support/sync.h>
 
-#include "absl/strings/str_format.h"
 #include "src/core/lib/gprpp/ref_counted_ptr.h"
 #include "src/core/lib/surface/api_trace.h"
 
index 5e317c4..f44ef0f 100644 (file)
@@ -18,7 +18,6 @@
 
 #include <grpc/support/port_platform.h>
 
-#include "src/core/lib/iomgr/error.h"
 #include "src/core/lib/security/credentials/jwt/json_token.h"
 
 #include <string.h>
@@ -30,6 +29,7 @@
 #include <grpc/support/time.h>
 
 #include "src/core/lib/gpr/string.h"
+#include "src/core/lib/iomgr/error.h"
 #include "src/core/lib/security/util/json_util.h"
 #include "src/core/lib/slice/b64.h"
 
index b9a41c6..163cc3d 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include <grpc/slice.h>
 #include <openssl/rsa.h>
 
+#include <grpc/slice.h>
+
 #include "src/core/lib/json/json.h"
 
 /* --- Constants. --- */
index 27590f4..f913257 100644 (file)
 
 #include "absl/strings/str_cat.h"
 
-#include "src/core/lib/gprpp/ref_counted.h"
-#include "src/core/lib/gprpp/ref_counted_ptr.h"
-#include "src/core/lib/slice/slice_internal.h"
-#include "src/core/lib/surface/api_trace.h"
-
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/string_util.h>
 #include <grpc/support/sync.h>
 
+#include "src/core/lib/gprpp/ref_counted.h"
+#include "src/core/lib/gprpp/ref_counted_ptr.h"
+#include "src/core/lib/slice/slice_internal.h"
+#include "src/core/lib/surface/api_trace.h"
+#include "src/core/lib/transport/error_utils.h"
+#include "src/core/lib/uri/uri_parser.h"
+
 using grpc_core::Json;
 
 void grpc_service_account_jwt_access_credentials::reset_cache() {
   GRPC_MDELEM_UNREF(cached_.jwt_md);
   cached_.jwt_md = GRPC_MDNULL;
-  if (cached_.service_url != nullptr) {
-    gpr_free(cached_.service_url);
-    cached_.service_url = nullptr;
-  }
+  cached_.service_url.clear();
   cached_.jwt_expiration = gpr_inf_past(GPR_CLOCK_REALTIME);
 }
 
@@ -63,12 +62,19 @@ bool grpc_service_account_jwt_access_credentials::get_request_metadata(
   gpr_timespec refresh_threshold = gpr_time_from_seconds(
       GRPC_SECURE_TOKEN_REFRESH_THRESHOLD_SECS, GPR_TIMESPAN);
 
+  // Remove service name from service_url to follow the audience format
+  // dictated in https://google.aip.dev/auth/4111.
+  absl::StatusOr<std::string> uri =
+      grpc_core::RemoveServiceNameFromJwtUri(context.service_url);
+  if (!uri.ok()) {
+    *error = absl_status_to_grpc_error(uri.status());
+    return true;
+  }
   /* See if we can return a cached jwt. */
   grpc_mdelem jwt_md = GRPC_MDNULL;
   {
     gpr_mu_lock(&cache_mu_);
-    if (cached_.service_url != nullptr &&
-        strcmp(cached_.service_url, context.service_url) == 0 &&
+    if (!cached_.service_url.empty() && cached_.service_url == *uri &&
         !GRPC_MDISNULL(cached_.jwt_md) &&
         (gpr_time_cmp(
              gpr_time_sub(cached_.jwt_expiration, gpr_now(GPR_CLOCK_REALTIME)),
@@ -83,14 +89,13 @@ bool grpc_service_account_jwt_access_credentials::get_request_metadata(
     /* Generate a new jwt. */
     gpr_mu_lock(&cache_mu_);
     reset_cache();
-    jwt = grpc_jwt_encode_and_sign(&key_, context.service_url, jwt_lifetime_,
-                                   nullptr);
+    jwt = grpc_jwt_encode_and_sign(&key_, uri->c_str(), jwt_lifetime_, nullptr);
     if (jwt != nullptr) {
       std::string md_value = absl::StrCat("Bearer ", jwt);
       gpr_free(jwt);
       cached_.jwt_expiration =
           gpr_time_add(gpr_now(GPR_CLOCK_REALTIME), jwt_lifetime_);
-      cached_.service_url = gpr_strdup(context.service_url);
+      cached_.service_url = std::move(*uri);
       cached_.jwt_md = grpc_mdelem_from_slices(
           grpc_slice_from_static_string(GRPC_AUTHORIZATION_METADATA_KEY),
           grpc_slice_from_cpp_string(std::move(md_value)));
@@ -173,3 +178,15 @@ grpc_call_credentials* grpc_service_account_jwt_access_credentials_create(
              grpc_auth_json_key_create_from_string(json_key), token_lifetime)
       .release();
 }
+
+namespace grpc_core {
+
+absl::StatusOr<std::string> RemoveServiceNameFromJwtUri(absl::string_view uri) {
+  auto parsed = grpc_core::URI::Parse(uri);
+  if (!parsed.ok()) {
+    return parsed.status();
+  }
+  return absl::StrFormat("%s://%s/", parsed->scheme(), parsed->authority());
+}
+
+}  // namespace grpc_core
index 5ae4c1f..7a79cb7 100644 (file)
 
 #include <string>
 
-#include <grpc/support/time.h>
-
 #include "absl/strings/str_format.h"
 #include "absl/time/time.h"
+
+#include <grpc/support/time.h>
+
 #include "src/core/lib/security/credentials/credentials.h"
 #include "src/core/lib/security/credentials/jwt/json_token.h"
 
@@ -64,7 +65,7 @@ class grpc_service_account_jwt_access_credentials
   gpr_mu cache_mu_;
   struct {
     grpc_mdelem jwt_md = GRPC_MDNULL;
-    char* service_url = nullptr;
+    std::string service_url;
     gpr_timespec jwt_expiration;
   } cached_;
 
@@ -78,4 +79,11 @@ grpc_core::RefCountedPtr<grpc_call_credentials>
 grpc_service_account_jwt_access_credentials_create_from_auth_json_key(
     grpc_auth_json_key key, gpr_timespec token_lifetime);
 
+namespace grpc_core {
+
+// Exposed for testing purposes only.
+absl::StatusOr<std::string> RemoveServiceNameFromJwtUri(absl::string_view uri);
+
+}  // namespace grpc_core
+
 #endif /* GRPC_CORE_LIB_SECURITY_CREDENTIALS_JWT_JWT_CREDENTIALS_H */
index 8d43cf9..9f1e025 100644 (file)
@@ -709,7 +709,6 @@ static void on_openid_config_retrieved(void* user_data,
       grpc_core::ExecCtx::Get()->Now() + grpc_jwt_verifier_max_delay,
       GRPC_CLOSURE_CREATE(on_keys_retrieved, ctx, grpc_schedule_on_exec_ctx),
       &ctx->responses[HTTP_RESPONSE_KEYS]);
-  grpc_resource_quota_unref_internal(resource_quota);
   gpr_free(req.host);
   return;
 
@@ -834,7 +833,6 @@ static void retrieve_key_and_verify(verifier_cb_ctx* ctx) {
       &ctx->verifier->http_ctx, &ctx->pollent, resource_quota, &req,
       grpc_core::ExecCtx::Get()->Now() + grpc_jwt_verifier_max_delay, http_cb,
       &ctx->responses[rsp_idx]);
-  grpc_resource_quota_unref_internal(resource_quota);
   gpr_free(req.host);
   gpr_free(req.http.path);
   return;
index 66ddbf2..2d1d360 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include "src/core/lib/iomgr/pollset.h"
-#include "src/core/lib/json/json.h"
-
 #include <grpc/slice.h>
 #include <grpc/support/time.h>
 
+#include "src/core/lib/iomgr/pollset.h"
+#include "src/core/lib/json/json.h"
+
 /* --- Constants. --- */
 
 #define GRPC_OPENID_CONFIG_URL_SUFFIX "/.well-known/openid-configuration"
index 50d20e6..df467fe 100644 (file)
@@ -18,7 +18,6 @@
 
 #include <grpc/support/port_platform.h>
 
-#include "src/core/lib/json/json.h"
 #include "src/core/lib/security/credentials/oauth2/oauth2_credentials.h"
 
 #include <string.h>
@@ -39,6 +38,7 @@
 #include "src/core/lib/gprpp/ref_counted_ptr.h"
 #include "src/core/lib/iomgr/error.h"
 #include "src/core/lib/iomgr/load_file.h"
+#include "src/core/lib/json/json.h"
 #include "src/core/lib/security/util/json_util.h"
 #include "src/core/lib/slice/slice_internal.h"
 #include "src/core/lib/surface/api_trace.h"
@@ -401,7 +401,6 @@ class grpc_compute_engine_token_fetcher_credentials
                      GRPC_CLOSURE_INIT(&http_get_cb_closure_, response_cb,
                                        metadata_req, grpc_schedule_on_exec_ctx),
                      &metadata_req->response);
-    grpc_resource_quota_unref_internal(resource_quota);
   }
 
   std::string debug_string() override {
@@ -462,7 +461,6 @@ void grpc_google_refresh_token_credentials::fetch_oauth2(
                     GRPC_CLOSURE_INIT(&http_post_cb_closure_, response_cb,
                                       metadata_req, grpc_schedule_on_exec_ctx),
                     &metadata_req->response);
-  grpc_resource_quota_unref_internal(resource_quota);
 }
 
 grpc_google_refresh_token_credentials::grpc_google_refresh_token_credentials(
@@ -595,7 +593,6 @@ class StsTokenFetcherCredentials
         GRPC_CLOSURE_INIT(&http_post_cb_closure_, response_cb, metadata_req,
                           grpc_schedule_on_exec_ctx),
         &metadata_req->response);
-    grpc_resource_quota_unref_internal(resource_quota);
     gpr_free(body);
   }
 
@@ -663,10 +660,9 @@ absl::StatusOr<URI> ValidateStsCredentialsOptions(
                      ? ""
                      : options->token_exchange_service_uri);
   if (!sts_url.ok()) {
-    error_list.push_back(GRPC_ERROR_CREATE_FROM_COPIED_STRING(
+    error_list.push_back(GRPC_ERROR_CREATE_FROM_CPP_STRING(
         absl::StrFormat("Invalid or missing STS endpoint URL. Error: %s",
-                        sts_url.status().ToString())
-            .c_str()));
+                        sts_url.status().ToString())));
   } else if (sts_url->scheme() != "https" && sts_url->scheme() != "http") {
     error_list.push_back(GRPC_ERROR_CREATE_FROM_STATIC_STRING(
         "Invalid URI scheme, must be https to http."));
index f174112..ef64b23 100644 (file)
@@ -24,6 +24,7 @@
 #include <string>
 
 #include <grpc/grpc_security.h>
+
 #include "src/core/lib/json/json.h"
 #include "src/core/lib/security/credentials/credentials.h"
 #include "src/core/lib/uri/uri_parser.h"
index 4c583ad..5b8fe1a 100644 (file)
@@ -87,10 +87,8 @@ static grpc_error_handle process_plugin_result(
     size_t num_md, grpc_status_code status, const char* error_details) {
   grpc_error_handle error = GRPC_ERROR_NONE;
   if (status != GRPC_STATUS_OK) {
-    error = GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-        absl::StrCat("Getting metadata from plugin failed with error: ",
-                     error_details)
-            .c_str());
+    error = GRPC_ERROR_CREATE_FROM_CPP_STRING(absl::StrCat(
+        "Getting metadata from plugin failed with error: ", error_details));
   } else {
     bool seen_illegal_header = false;
     for (size_t i = 0; i < num_md; ++i) {
index 469eb0c..093f1ad 100644 (file)
 
 #include <string.h>
 
-#include "src/core/lib/channel/channel_args.h"
-#include "src/core/lib/surface/api_trace.h"
-#include "src/core/tsi/ssl_transport_security.h"
-
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/string_util.h>
 
+#include "src/core/lib/channel/channel_args.h"
+#include "src/core/lib/surface/api_trace.h"
+#include "src/core/tsi/ssl_transport_security.h"
+
 //
 // SSL Channel Credentials.
 //
index 0491eea..647d619 100644 (file)
@@ -21,7 +21,6 @@
 #include <grpc/support/port_platform.h>
 
 #include "src/core/lib/security/credentials/credentials.h"
-
 #include "src/core/lib/security/security_connector/ssl/ssl_security_connector.h"
 
 class grpc_ssl_credentials : public grpc_channel_credentials {
index e831aa5..5fa1719 100644 (file)
 
 #include "src/core/lib/security/credentials/tls/grpc_tls_certificate_distributor.h"
 
+#include <stdlib.h>
+#include <string.h>
+
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/string_util.h>
-#include <stdlib.h>
-#include <string.h>
 
 void grpc_tls_certificate_distributor::SetKeyMaterials(
     const std::string& cert_name, absl::optional<std::string> pem_root_certs,
index 36c46be..b0bc58c 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include <grpc/grpc_security.h>
-
 #include <utility>
 
 #include "absl/container/inlined_vector.h"
 #include "absl/types/optional.h"
+
+#include <grpc/grpc_security.h>
+
 #include "src/core/lib/gprpp/ref_counted.h"
 #include "src/core/lib/security/security_connector/ssl_utils.h"
 
@@ -125,7 +126,7 @@ struct grpc_tls_certificate_distributor
   // are being watched.
   void SetWatchStatusCallback(
       std::function<void(std::string, bool, bool)> callback) {
-    grpc_core::MutexLock lock(&mu_);
+    grpc_core::MutexLock lock(&callback_mu_);
     watch_status_callback_ = std::move(callback);
   };
 
@@ -201,13 +202,16 @@ struct grpc_tls_certificate_distributor
   // functions.
   grpc_core::Mutex callback_mu_;
   // Stores information about each watcher.
-  std::map<TlsCertificatesWatcherInterface*, WatcherInfo> watchers_;
+  std::map<TlsCertificatesWatcherInterface*, WatcherInfo> watchers_
+      ABSL_GUARDED_BY(mu_);
   // The callback to notify the caller, e.g. the Producer, that the watch status
   // is changed.
-  std::function<void(std::string, bool, bool)> watch_status_callback_;
+  std::function<void(std::string, bool, bool)> watch_status_callback_
+      ABSL_GUARDED_BY(callback_mu_);
   // Stores the names of each certificate, and their corresponding credential
   // contents as well as some additional watcher information.
-  std::map<std::string, CertificateInfo> certificate_info_map_;
+  std::map<std::string, CertificateInfo> certificate_info_map_
+      ABSL_GUARDED_BY(mu_);
 };
 
 #endif  // GRPC_CORE_LIB_SECURITY_CREDENTIALS_TLS_GRPC_TLS_CERTIFICATE_DISTRIBUTOR_H
index 6e1d934..65357ea 100644 (file)
 
 #include "src/core/lib/security/credentials/tls/grpc_tls_certificate_provider.h"
 
+#include <openssl/ssl.h>
+
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/string_util.h>
-#include <openssl/ssl.h>
 
 #include "src/core/lib/gprpp/stat.h"
 #include "src/core/lib/slice/slice_internal.h"
index d8b44f2..707e97f 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include <grpc/grpc_security.h>
 #include <string.h>
 
 #include "absl/container/inlined_vector.h"
 #include "absl/status/statusor.h"
 
+#include <grpc/grpc_security.h>
+
 #include "src/core/lib/gprpp/ref_counted.h"
 #include "src/core/lib/gprpp/ref_counted_ptr.h"
 #include "src/core/lib/gprpp/thd.h"
@@ -108,7 +109,8 @@ class FileWatcherCertificateProvider final
   // Read the root certificates from files and update the distributor.
   absl::optional<std::string> ReadRootCertificatesFromFile(
       const std::string& root_cert_full_path);
-  // Read the root certificates from files and update the distributor.
+  // Read the private key and the certificate chain from files and update the
+  // distributor.
   absl::optional<PemKeyCertPairList> ReadIdentityKeyCertPairFromFiles(
       const std::string& private_key_path,
       const std::string& identity_certificate_path);
@@ -127,11 +129,11 @@ class FileWatcherCertificateProvider final
   grpc_core::Mutex mu_;
   // The most-recent credential data. It will be empty if the most recent read
   // attempt failed.
-  std::string root_certificate_;
-  grpc_core::PemKeyCertPairList pem_key_cert_pairs_;
+  std::string root_certificate_ ABSL_GUARDED_BY(mu_);
+  grpc_core::PemKeyCertPairList pem_key_cert_pairs_ ABSL_GUARDED_BY(mu_);
   // Stores each cert_name we get from the distributor callback and its watcher
   // information.
-  std::map<std::string, WatcherInfo> watcher_info_;
+  std::map<std::string, WatcherInfo> watcher_info_ ABSL_GUARDED_BY(mu_);
 };
 
 //  Checks if the private key matches the certificate's public key.
index 2aae29b..c395391 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include <grpc/grpc_security.h>
-
 #include "absl/container/inlined_vector.h"
 
+#include <grpc/grpc_security.h>
+
 #include "src/core/lib/gprpp/ref_counted.h"
 #include "src/core/lib/security/credentials/tls/grpc_tls_certificate_distributor.h"
 #include "src/core/lib/security/credentials/tls/grpc_tls_certificate_provider.h"
index 0e25fb0..3307d24 100644 (file)
@@ -229,10 +229,9 @@ static void fake_check_peer(
   prop_name = peer.properties[0].name;
   if (prop_name == nullptr ||
       strcmp(prop_name, TSI_CERTIFICATE_TYPE_PEER_PROPERTY) != 0) {
-    error = GRPC_ERROR_CREATE_FROM_COPIED_STRING(
+    error = GRPC_ERROR_CREATE_FROM_CPP_STRING(
         absl::StrCat("Unexpected property in fake peer: ",
-                     prop_name == nullptr ? "<EMPTY>" : prop_name)
-            .c_str());
+                     prop_name == nullptr ? "<EMPTY>" : prop_name));
     goto end;
   }
   if (strncmp(peer.properties[0].value.data, TSI_FAKE_CERTIFICATE_TYPE,
@@ -244,10 +243,9 @@ static void fake_check_peer(
   prop_name = peer.properties[1].name;
   if (prop_name == nullptr ||
       strcmp(prop_name, TSI_SECURITY_LEVEL_PEER_PROPERTY) != 0) {
-    error = GRPC_ERROR_CREATE_FROM_COPIED_STRING(
+    error = GRPC_ERROR_CREATE_FROM_CPP_STRING(
         absl::StrCat("Unexpected property in fake peer: ",
-                     prop_name == nullptr ? "<EMPTY>" : prop_name)
-            .c_str());
+                     prop_name == nullptr ? "<EMPTY>" : prop_name));
     goto end;
   }
   if (strncmp(peer.properties[1].value.data, TSI_FAKE_SECURITY_LEVEL,
index f04d0ed..f448d3f 100644 (file)
@@ -19,6 +19,7 @@
 #include <grpc/support/port_platform.h>
 
 #include <grpc/slice_buffer.h>
+
 #include "src/core/lib/security/security_connector/load_system_roots.h"
 
 #if !defined(GPR_LINUX) && !defined(GPR_ANDROID)
index 4cd709f..da311da 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include <grpc/slice_buffer.h>
 #include "src/core/lib/security/security_connector/load_system_roots_linux.h"
 
-#if defined(GPR_LINUX) || defined(GPR_ANDROID)
+#include <grpc/slice_buffer.h>
 
-#include "src/core/lib/security/security_connector/load_system_roots.h"
+#if defined(GPR_LINUX) || defined(GPR_ANDROID)
 
 #include <dirent.h>
 #include <fcntl.h>
@@ -44,6 +43,7 @@
 #include "src/core/lib/gpr/useful.h"
 #include "src/core/lib/gprpp/global_config.h"
 #include "src/core/lib/iomgr/load_file.h"
+#include "src/core/lib/security/security_connector/load_system_roots.h"
 
 GPR_GLOBAL_CONFIG_DEFINE_STRING(grpc_system_ssl_roots_dir, "",
                                 "Custom directory to SSL Roots");
index 3e424e3..c858149 100644 (file)
@@ -54,9 +54,8 @@ grpc_error_handle ssl_check_peer(
   }
   /* Check the peer name if specified. */
   if (peer_name != nullptr && !grpc_ssl_host_matches_name(peer, peer_name)) {
-    return GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-        absl::StrCat("Peer name ", peer_name, " is not in peer certificate")
-            .c_str());
+    return GRPC_ERROR_CREATE_FROM_CPP_STRING(
+        absl::StrCat("Peer name ", peer_name, " is not in peer certificate"));
   }
   *auth_context =
       grpc_ssl_peer_to_auth_context(peer, GRPC_SSL_TRANSPORT_SECURITY_TYPE);
@@ -162,10 +161,8 @@ class grpc_ssl_channel_security_connector final
             verify_options_->verify_peer_callback_userdata);
         gpr_free(peer_pem);
         if (callback_status) {
-          error = GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-              absl::StrFormat("Verify peer callback returned a failure (%d)",
-                              callback_status)
-                  .c_str());
+          error = GRPC_ERROR_CREATE_FROM_CPP_STRING(absl::StrFormat(
+              "Verify peer callback returned a failure (%d)", callback_status));
         }
       }
     }
index 04c32bb..57342d9 100644 (file)
@@ -23,9 +23,8 @@
 
 #include <grpc/grpc_security.h>
 
-#include "src/core/lib/security/security_connector/security_connector.h"
-
 #include "src/core/lib/gprpp/ref_counted_ptr.h"
+#include "src/core/lib/security/security_connector/security_connector.h"
 #include "src/core/tsi/ssl_transport_security.h"
 #include "src/core/tsi/transport_security_interface.h"
 
index 803d31d..de22379 100644 (file)
@@ -173,9 +173,8 @@ grpc_error_handle grpc_ssl_check_peer_name(absl::string_view peer_name,
                                            const tsi_peer* peer) {
   /* Check the peer name if specified. */
   if (!peer_name.empty() && !grpc_ssl_host_matches_name(peer, peer_name)) {
-    return GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-        absl::StrCat("Peer name ", peer_name, " is not in peer certificate")
-            .c_str());
+    return GRPC_ERROR_CREATE_FROM_CPP_STRING(
+        absl::StrCat("Peer name ", peer_name, " is not in peer certificate"));
   }
   return GRPC_ERROR_NONE;
 }
index a1b90f1..7ee655d 100644 (file)
@@ -421,27 +421,23 @@ TlsChannelSecurityConnector::ProcessServerAuthorizationCheckResult(
   grpc_error_handle error = GRPC_ERROR_NONE;
   /* Server authorization check is cancelled by caller. */
   if (arg->status == GRPC_STATUS_CANCELLED) {
-    error = GRPC_ERROR_CREATE_FROM_COPIED_STRING(
+    error = GRPC_ERROR_CREATE_FROM_CPP_STRING(
         absl::StrCat("Server authorization check is cancelled by the caller "
                      "with error: ",
-                     arg->error_details->error_details())
-            .c_str());
+                     arg->error_details->error_details()));
   } else if (arg->status == GRPC_STATUS_OK) {
     /* Server authorization check completed successfully but returned check
      * failure. */
     if (!arg->success) {
-      error = GRPC_ERROR_CREATE_FROM_COPIED_STRING(
+      error = GRPC_ERROR_CREATE_FROM_CPP_STRING(
           absl::StrCat("Server authorization check failed with error: ",
-                       arg->error_details->error_details())
-              .c_str());
+                       arg->error_details->error_details()));
     }
     /* Server authorization check did not complete correctly. */
   } else {
-    error = GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-        absl::StrCat(
-            "Server authorization check did not finish correctly with error: ",
-            arg->error_details->error_details())
-            .c_str());
+    error = GRPC_ERROR_CREATE_FROM_CPP_STRING(absl::StrCat(
+        "Server authorization check did not finish correctly with error: ",
+        arg->error_details->error_details()));
   }
   return error;
 }
@@ -659,9 +655,8 @@ grpc_error_handle TlsCheckHostName(const char* peer_name,
                                    const tsi_peer* peer) {
   /* Check the peer name if specified. */
   if (peer_name != nullptr && !grpc_ssl_host_matches_name(peer, peer_name)) {
-    return GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-        absl::StrCat("Peer name ", peer_name, " is not in peer certificate")
-            .c_str());
+    return GRPC_ERROR_CREATE_FROM_CPP_STRING(
+        absl::StrCat("Peer name ", peer_name, " is not in peer certificate"));
   }
   return GRPC_ERROR_NONE;
 }
index ae31b1d..fc9e59c 100644 (file)
@@ -22,6 +22,7 @@
 #include <grpc/support/port_platform.h>
 
 #include <grpc/grpc_security.h>
+
 #include "src/core/lib/channel/channel_stack.h"
 
 extern const grpc_channel_filter grpc_client_auth_filter;
index babc90f..4e940b1 100644 (file)
@@ -18,8 +18,6 @@
 
 #include <grpc/support/port_platform.h>
 
-#include "src/core/lib/security/transport/auth_filters.h"
-
 #include <string.h>
 
 #include <string>
@@ -37,6 +35,7 @@
 #include "src/core/lib/security/credentials/credentials.h"
 #include "src/core/lib/security/security_connector/security_connector.h"
 #include "src/core/lib/security/security_connector/ssl_utils.h"
+#include "src/core/lib/security/transport/auth_filters.h"
 #include "src/core/lib/slice/slice_internal.h"
 #include "src/core/lib/slice/slice_string_helpers.h"
 #include "src/core/lib/surface/call.h"
@@ -339,13 +338,12 @@ static void on_host_checked(void* arg, grpc_error_handle error) {
   if (error == GRPC_ERROR_NONE) {
     send_security_metadata(elem, batch);
   } else {
-    std::string error_msg = absl::StrCat(
-        "Invalid host ", grpc_core::StringViewFromSlice(calld->host),
-        " set in :authority metadata.");
     grpc_transport_stream_op_batch_finish_with_failure(
         batch,
         grpc_error_set_int(
-            GRPC_ERROR_CREATE_FROM_COPIED_STRING(error_msg.c_str()),
+            GRPC_ERROR_CREATE_FROM_CPP_STRING(absl::StrCat(
+                "Invalid host ", grpc_core::StringViewFromSlice(calld->host),
+                " set in :authority metadata.")),
             GRPC_ERROR_INT_GRPC_STATUS, GRPC_STATUS_UNAUTHENTICATED),
         calld->call_combiner);
   }
index fc1fb7e..c60ecfb 100644 (file)
  *
  */
 
-/* With the addition of a libuv endpoint, sockaddr.h now includes uv.h when
-   using that endpoint. Because of various transitive includes in uv.h,
-   including windows.h on Windows, uv.h must be included before other system
-   headers. Therefore, sockaddr.h must always be included first */
 #include <grpc/support/port_platform.h>
 
-#include <new>
+#include "src/core/lib/security/transport/secure_endpoint.h"
 
-#include "src/core/lib/iomgr/sockaddr.h"
+#include <new>
 
 #include <grpc/slice.h>
 #include <grpc/slice_buffer.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/sync.h>
+
 #include "src/core/lib/debug/trace.h"
 #include "src/core/lib/gpr/string.h"
 #include "src/core/lib/gprpp/memory.h"
+#include "src/core/lib/iomgr/sockaddr.h"
 #include "src/core/lib/profiling/timers.h"
-#include "src/core/lib/security/transport/secure_endpoint.h"
 #include "src/core/lib/security/transport/tsi_error.h"
 #include "src/core/lib/slice/slice_internal.h"
 #include "src/core/lib/slice/slice_string_helpers.h"
@@ -416,12 +413,6 @@ static int endpoint_get_fd(grpc_endpoint* secure_ep) {
   return grpc_endpoint_get_fd(ep->wrapped_ep);
 }
 
-static grpc_resource_user* endpoint_get_resource_user(
-    grpc_endpoint* secure_ep) {
-  secure_endpoint* ep = reinterpret_cast<secure_endpoint*>(secure_ep);
-  return grpc_endpoint_get_resource_user(ep->wrapped_ep);
-}
-
 static bool endpoint_can_track_err(grpc_endpoint* secure_ep) {
   secure_endpoint* ep = reinterpret_cast<secure_endpoint*>(secure_ep);
   return grpc_endpoint_can_track_err(ep->wrapped_ep);
@@ -434,7 +425,6 @@ static const grpc_endpoint_vtable vtable = {endpoint_read,
                                             endpoint_delete_from_pollset_set,
                                             endpoint_shutdown,
                                             endpoint_destroy,
-                                            endpoint_get_resource_user,
                                             endpoint_get_peer,
                                             endpoint_get_local_address,
                                             endpoint_get_fd,
index e7e3351..b3b8e23 100644 (file)
@@ -22,6 +22,7 @@
 #include <grpc/support/port_platform.h>
 
 #include <grpc/slice.h>
+
 #include "src/core/lib/iomgr/endpoint.h"
 
 struct tsi_frame_protector;
index f464218..d062e90 100644 (file)
@@ -22,6 +22,7 @@
 
 #include <stdbool.h>
 #include <string.h>
+
 #include <limits>
 
 #include <grpc/slice_buffer.h>
@@ -31,7 +32,7 @@
 #include "src/core/lib/channel/channel_args.h"
 #include "src/core/lib/channel/channelz.h"
 #include "src/core/lib/channel/handshaker.h"
-#include "src/core/lib/channel/handshaker_registry.h"
+#include "src/core/lib/config/core_configuration.h"
 #include "src/core/lib/gprpp/ref_counted_ptr.h"
 #include "src/core/lib/security/context/security_context.h"
 #include "src/core/lib/security/transport/secure_endpoint.h"
@@ -593,11 +594,11 @@ RefCountedPtr<Handshaker> SecurityHandshakerCreate(
   }
 }
 
-void SecurityRegisterHandshakerFactories() {
-  HandshakerRegistry::RegisterHandshakerFactory(
+void SecurityRegisterHandshakerFactories(CoreConfiguration::Builder* builder) {
+  builder->handshaker_registry()->RegisterHandshakerFactory(
       false /* at_start */, HANDSHAKER_CLIENT,
       absl::make_unique<ClientSecurityHandshakerFactory>());
-  HandshakerRegistry::RegisterHandshakerFactory(
+  builder->handshaker_registry()->RegisterHandshakerFactory(
       false /* at_start */, HANDSHAKER_SERVER,
       absl::make_unique<ServerSecurityHandshakerFactory>());
 }
index a9e1fe8..8f4ab8b 100644 (file)
@@ -22,6 +22,7 @@
 #include <grpc/support/port_platform.h>
 
 #include "src/core/lib/channel/handshaker.h"
+#include "src/core/lib/config/core_configuration.h"
 #include "src/core/lib/security/security_connector/security_connector.h"
 
 namespace grpc_core {
@@ -32,7 +33,7 @@ RefCountedPtr<Handshaker> SecurityHandshakerCreate(
     const grpc_channel_args* args);
 
 /// Registers security handshaker factories.
-void SecurityRegisterHandshakerFactories();
+void SecurityRegisterHandshakerFactories(CoreConfiguration::Builder*);
 
 }  // namespace grpc_core
 
index 34bf88f..25223ee 100644 (file)
@@ -18,6 +18,8 @@
 
 #include <grpc/support/port_platform.h>
 
+#include "src/core/lib/security/util/json_util.h"
+
 #include <string.h>
 
 #include "absl/strings/str_cat.h"
@@ -26,7 +28,6 @@
 #include <grpc/support/string_util.h>
 
 #include "src/core/lib/iomgr/error.h"
-#include "src/core/lib/security/util/json_util.h"
 
 const char* grpc_json_get_string_property(const grpc_core::Json& json,
                                           const char* prop_name,
@@ -41,18 +42,15 @@ const char* grpc_json_get_string_property(const grpc_core::Json& json,
   auto it = json.object_value().find(prop_name);
   if (it == json.object_value().end()) {
     if (error != nullptr) {
-      *error = GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-          absl::StrCat("Property ", prop_name, " not found in JSON object.")
-              .c_str());
+      *error = GRPC_ERROR_CREATE_FROM_CPP_STRING(
+          absl::StrCat("Property ", prop_name, " not found in JSON object."));
     }
     return nullptr;
   }
   if (it->second.type() != grpc_core::Json::Type::STRING) {
     if (error != nullptr) {
-      *error = GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-          absl::StrCat("Property ", prop_name,
-                       " n JSON object is not a string.")
-              .c_str());
+      *error = GRPC_ERROR_CREATE_FROM_CPP_STRING(absl::StrCat(
+          "Property ", prop_name, " n JSON object is not a string."));
     }
     return nullptr;
   }
index 79a4805..5ec2935 100644 (file)
 
 #include "src/core/lib/slice/percent_encoding.h"
 
+#include <cstdint>
+
 #include <grpc/support/log.h>
 
+#include "src/core/lib/gprpp/bitset.h"
 #include "src/core/lib/slice/slice_internal.h"
 
-const uint8_t grpc_url_percent_encoding_unreserved_bytes[256 / 8] = {
-    0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0xff, 0x03, 0xfe, 0xff, 0xff,
-    0x87, 0xfe, 0xff, 0xff, 0x47, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-    0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00};
-const uint8_t grpc_compatible_percent_encoding_unreserved_bytes[256 / 8] = {
-    0x00, 0x00, 0x00, 0x00, 0xdf, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
-    0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-    0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00};
-
-static bool is_unreserved_character(uint8_t c,
-                                    const uint8_t* unreserved_bytes) {
-  return ((unreserved_bytes[c / 8] >> (c % 8)) & 1) != 0;
+#if __cplusplus > 201103l
+#define GRPC_PCTENCODE_CONSTEXPR_FN constexpr
+#define GRPC_PCTENCODE_CONSTEXPR_VALUE constexpr
+#else
+#define GRPC_PCTENCODE_CONSTEXPR_FN
+#define GRPC_PCTENCODE_CONSTEXPR_VALUE const
+#endif
+
+namespace grpc_core {
+
+namespace {
+class UrlTable : public BitSet<256> {
+ public:
+  GRPC_PCTENCODE_CONSTEXPR_FN UrlTable() {
+    for (int i = 'a'; i <= 'z'; i++) set(i);
+    for (int i = 'A'; i <= 'Z'; i++) set(i);
+    for (int i = '0'; i <= '9'; i++) set(i);
+    set('-');
+    set('_');
+    set('.');
+    set('~');
+  }
+};
+
+static GRPC_PCTENCODE_CONSTEXPR_VALUE UrlTable g_url_table;
+
+class CompatibleTable : public BitSet<256> {
+ public:
+  GRPC_PCTENCODE_CONSTEXPR_FN CompatibleTable() {
+    for (int i = 32; i <= 126; i++) {
+      if (i == '%') continue;
+      set(i);
+    }
+  }
+};
+
+static GRPC_PCTENCODE_CONSTEXPR_VALUE CompatibleTable g_compatible_table;
+
+// Map PercentEncodingType to a lookup table of legal symbols for that encoding.
+const BitSet<256>& LookupTableForPercentEncodingType(PercentEncodingType type) {
+  switch (type) {
+    case PercentEncodingType::URL:
+      return g_url_table;
+    case PercentEncodingType::Compatible:
+      return g_compatible_table;
+  }
+  // Crash if a bad PercentEncodingType was passed in.
+  GPR_UNREACHABLE_CODE(abort());
 }
+}  // namespace
 
-grpc_slice grpc_percent_encode_slice(const grpc_slice& slice,
-                                     const uint8_t* unreserved_bytes) {
+grpc_slice PercentEncodeSlice(const grpc_slice& slice,
+                              PercentEncodingType type) {
   static const uint8_t hex[] = "0123456789ABCDEF";
 
+  const BitSet<256>& lut = LookupTableForPercentEncodingType(type);
+
   // first pass: count the number of bytes needed to output this string
   size_t output_length = 0;
   const uint8_t* slice_start = GRPC_SLICE_START_PTR(slice);
@@ -49,7 +91,7 @@ grpc_slice grpc_percent_encode_slice(const grpc_slice& slice,
   const uint8_t* p;
   bool any_reserved_bytes = false;
   for (p = slice_start; p < slice_end; p++) {
-    bool unres = is_unreserved_character(*p, unreserved_bytes);
+    bool unres = lut.is_set(*p);
     output_length += unres ? 1 : 3;
     any_reserved_bytes |= !unres;
   }
@@ -61,7 +103,7 @@ grpc_slice grpc_percent_encode_slice(const grpc_slice& slice,
   grpc_slice out = GRPC_SLICE_MALLOC(output_length);
   uint8_t* q = GRPC_SLICE_START_PTR(out);
   for (p = slice_start; p < slice_end; p++) {
-    if (is_unreserved_character(*p, unreserved_bytes)) {
+    if (lut.is_set(*p)) {
       *q++ = *p;
     } else {
       *q++ = '%';
@@ -86,34 +128,33 @@ static uint8_t dehex(uint8_t c) {
   GPR_UNREACHABLE_CODE(return 255);
 }
 
-bool grpc_strict_percent_decode_slice(const grpc_slice& slice_in,
-                                      const uint8_t* unreserved_bytes,
-                                      grpc_slice* slice_out) {
+absl::optional<grpc_slice> PercentDecodeSlice(const grpc_slice& slice_in,
+                                              PercentEncodingType type) {
   const uint8_t* p = GRPC_SLICE_START_PTR(slice_in);
   const uint8_t* in_end = GRPC_SLICE_END_PTR(slice_in);
   size_t out_length = 0;
   bool any_percent_encoded_stuff = false;
+  const BitSet<256>& lut = LookupTableForPercentEncodingType(type);
   while (p != in_end) {
     if (*p == '%') {
-      if (!valid_hex(++p, in_end)) return false;
-      if (!valid_hex(++p, in_end)) return false;
+      if (!valid_hex(++p, in_end)) return {};
+      if (!valid_hex(++p, in_end)) return {};
       p++;
       out_length++;
       any_percent_encoded_stuff = true;
-    } else if (is_unreserved_character(*p, unreserved_bytes)) {
+    } else if (lut.is_set(*p)) {
       p++;
       out_length++;
     } else {
-      return false;
+      return {};
     }
   }
   if (!any_percent_encoded_stuff) {
-    *slice_out = grpc_slice_ref_internal(slice_in);
-    return true;
+    return grpc_slice_ref_internal(slice_in);
   }
   p = GRPC_SLICE_START_PTR(slice_in);
-  *slice_out = GRPC_SLICE_MALLOC(out_length);
-  uint8_t* q = GRPC_SLICE_START_PTR(*slice_out);
+  grpc_slice slice_out = GRPC_SLICE_MALLOC(out_length);
+  uint8_t* q = GRPC_SLICE_START_PTR(slice_out);
   while (p != in_end) {
     if (*p == '%') {
       *q++ = static_cast<uint8_t>(dehex(p[1]) << 4) | (dehex(p[2]));
@@ -122,11 +163,11 @@ bool grpc_strict_percent_decode_slice(const grpc_slice& slice_in,
       *q++ = *p++;
     }
   }
-  GPR_ASSERT(q == GRPC_SLICE_END_PTR(*slice_out));
-  return true;
+  GPR_ASSERT(q == GRPC_SLICE_END_PTR(slice_out));
+  return slice_out;
 }
 
-grpc_slice grpc_permissive_percent_decode_slice(const grpc_slice& slice_in) {
+grpc_slice PermissivePercentDecodeSlice(const grpc_slice& slice_in) {
   const uint8_t* p = GRPC_SLICE_START_PTR(slice_in);
   const uint8_t* in_end = GRPC_SLICE_END_PTR(slice_in);
   size_t out_length = 0;
@@ -167,3 +208,5 @@ grpc_slice grpc_permissive_percent_decode_slice(const grpc_slice& slice_in) {
   GPR_ASSERT(q == GRPC_SLICE_END_PTR(out));
   return out;
 }
+
+}  // namespace grpc_core
index 43b20f0..2cc85c5 100644 (file)
 
 #include <stdbool.h>
 
+#include "absl/types/optional.h"
+
 #include <grpc/slice.h>
 
-/* URL percent encoding spec bitfield (usabel as 'unreserved_bytes' in
-   grpc_percent_encode_slice, grpc_strict_percent_decode_slice).
-   Flags [A-Za-z0-9-_.~] as unreserved bytes for the percent encoding routines
-   */
-extern const uint8_t grpc_url_percent_encoding_unreserved_bytes[256 / 8];
-/* URL percent encoding spec bitfield (usabel as 'unreserved_bytes' in
-   grpc_percent_encode_slice, grpc_strict_percent_decode_slice).
-   Flags ascii7 non-control characters excluding '%' as unreserved bytes for the
-   percent encoding routines */
-extern const uint8_t grpc_compatible_percent_encoding_unreserved_bytes[256 / 8];
+namespace grpc_core {
+
+enum class PercentEncodingType {
+  // Flags [A-Za-z0-9-_.~] as unreserved bytes for the percent encoding routines
+  URL,
+  // Flags ascii7 non-control characters excluding '%' as unreserved bytes for
+  // the
+  // percent encoding routines
+  Compatible
+};
+
+// Percent-encode a slice, returning the new slice (this cannot fail):
+// unreserved_bytes is a bitfield indicating which bytes are considered
+// unreserved and thus do not need percent encoding
+grpc_slice PercentEncodeSlice(const grpc_slice& slice,
+                              PercentEncodingType type);
+// Percent-decode a slice, strictly.
+// If the input is legal (contains no unreserved bytes, and legal % encodings),
+// returns the decoded slice.
+// If the input is not legal, returns {}.
+absl::optional<grpc_slice> PercentDecodeSlice(const grpc_slice& slice_in,
+                                              PercentEncodingType type);
+// Percent-decode a slice, permissively.
+// If a % triplet can not be decoded, pass it through verbatim.
+// This cannot fail.
+grpc_slice PermissivePercentDecodeSlice(const grpc_slice& slice_in);
 
-/* Percent-encode a slice, returning the new slice (this cannot fail):
-   unreserved_bytes is a bitfield indicating which bytes are considered
-   unreserved and thus do not need percent encoding */
-grpc_slice grpc_percent_encode_slice(const grpc_slice& slice,
-                                     const uint8_t* unreserved_bytes);
-/* Percent-decode a slice, strictly.
-   If the input is legal (contains no unreserved bytes, and legal % encodings),
-   returns true and sets *slice_out to the decoded slice.
-   If the input is not legal, returns false and leaves *slice_out untouched.
-   unreserved_bytes is a bitfield indicating which bytes are considered
-   unreserved and thus do not need percent encoding */
-bool grpc_strict_percent_decode_slice(const grpc_slice& slice_in,
-                                      const uint8_t* unreserved_bytes,
-                                      grpc_slice* slice_out);
-/* Percent-decode a slice, permissively.
-   If a % triplet can not be decoded, pass it through verbatim.
-   This cannot fail. */
-grpc_slice grpc_permissive_percent_decode_slice(const grpc_slice& slice_in);
+}  // namespace grpc_core
 
 #endif /* GRPC_CORE_LIB_SLICE_PERCENT_ENCODING_H */
index 7f39df1..ac33a31 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include "src/core/lib/slice/slice_internal.h"
+#include <string.h>
 
 #include <grpc/slice.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 
-#include <string.h>
-
 #include "src/core/lib/gprpp/memory.h"
 #include "src/core/lib/gprpp/ref_counted.h"
 #include "src/core/lib/iomgr/exec_ctx.h"
+#include "src/core/lib/slice/slice_internal.h"
 
 char* grpc_slice_to_c_string(grpc_slice slice) {
   char* out = static_cast<char*>(gpr_malloc(GRPC_SLICE_LENGTH(slice) + 1));
index ba103d7..b16d493 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include <grpc/slice_buffer.h>
-
 #include <string.h>
 
+#include <grpc/slice_buffer.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 
index 0468130..305d99e 100644 (file)
@@ -18,9 +18,6 @@
 
 #include <grpc/support/port_platform.h>
 
-#include "src/core/lib/slice/slice_internal.h"
-#include "src/core/lib/slice/slice_utils.h"
-
 #include <inttypes.h>
 #include <string.h>
 
@@ -31,7 +28,9 @@
 #include "src/core/lib/gprpp/sync.h"
 #include "src/core/lib/iomgr/iomgr_internal.h" /* for iomgr_abort_on_leaks() */
 #include "src/core/lib/profiling/timers.h"
+#include "src/core/lib/slice/slice_internal.h"
 #include "src/core/lib/slice/slice_string_helpers.h"
+#include "src/core/lib/slice/slice_utils.h"
 #include "src/core/lib/transport/static_metadata.h"
 
 #define LOG2_SHARD_COUNT 5
index 21140a9..1e90ac5 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include <grpc/support/log.h>
+#include <string.h>
 
 #include <grpc/slice.h>
 #include <grpc/slice_buffer.h>
-#include <string.h>
+#include <grpc/support/log.h>
 
 #include "src/core/lib/gpr/murmur_hash.h"
 #include "src/core/lib/gprpp/memory.h"
index bab5a79..c40b9e1 100644 (file)
@@ -18,7 +18,8 @@
 
 #include <grpc/support/port_platform.h>
 
-#include "src/core/lib/debug/trace.h"
 #include "src/core/lib/surface/api_trace.h"
 
+#include "src/core/lib/debug/trace.h"
+
 grpc_core::TraceFlag grpc_api_trace(false, "api");
index 51d1f52..a7981d1 100644 (file)
@@ -22,6 +22,7 @@
 #include <grpc/support/port_platform.h>
 
 #include <grpc/support/log.h>
+
 #include "src/core/lib/debug/trace.h"
 
 extern grpc_core::TraceFlag grpc_api_trace;
index 3689c79..207aaef 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include <grpc/byte_buffer_reader.h>
 #include <string.h>
 
 #include <grpc/byte_buffer.h>
+#include <grpc/byte_buffer_reader.h>
 #include <grpc/grpc.h>
 #include <grpc/slice_buffer.h>
 #include <grpc/support/alloc.h>
index c6cc769..5d91002 100644 (file)
@@ -18,6 +18,8 @@
 
 #include <grpc/support/port_platform.h>
 
+#include "src/core/lib/surface/call.h"
+
 #include <assert.h>
 #include <limits.h>
 #include <stdio.h>
@@ -51,7 +53,6 @@
 #include "src/core/lib/slice/slice_string_helpers.h"
 #include "src/core/lib/slice/slice_utils.h"
 #include "src/core/lib/surface/api_trace.h"
-#include "src/core/lib/surface/call.h"
 #include "src/core/lib/surface/call_test_only.h"
 #include "src/core/lib/surface/channel.h"
 #include "src/core/lib/surface/completion_queue.h"
@@ -105,13 +106,13 @@ struct batch_control {
   } completion_data;
   grpc_closure start_batch;
   grpc_closure finish_batch;
-  grpc_core::Atomic<intptr_t> steps_to_complete;
+  std::atomic<intptr_t> steps_to_complete{0};
   gpr_atm batch_error = reinterpret_cast<gpr_atm>(GRPC_ERROR_NONE);
   void set_num_steps_to_complete(uintptr_t steps) {
-    steps_to_complete.Store(steps, grpc_core::MemoryOrder::RELEASE);
+    steps_to_complete.store(steps, std::memory_order_release);
   }
   bool completed_batch_step() {
-    return steps_to_complete.FetchSub(1, grpc_core::MemoryOrder::ACQ_REL) == 1;
+    return steps_to_complete.fetch_sub(1, std::memory_order_acq_rel) == 1;
   }
 };
 
@@ -1065,10 +1066,10 @@ static void recv_trailing_filter(void* args, grpc_metadata_batch* b,
     grpc_error_handle error = GRPC_ERROR_NONE;
     if (status_code != GRPC_STATUS_OK) {
       char* peer = grpc_call_get_peer(call);
-      error = grpc_error_set_int(
-          GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-              absl::StrCat("Error received from peer ", peer).c_str()),
-          GRPC_ERROR_INT_GRPC_STATUS, static_cast<intptr_t>(status_code));
+      error = grpc_error_set_int(GRPC_ERROR_CREATE_FROM_CPP_STRING(absl::StrCat(
+                                     "Error received from peer ", peer)),
+                                 GRPC_ERROR_INT_GRPC_STATUS,
+                                 static_cast<intptr_t>(status_code));
       gpr_free(peer);
     }
     if (b->idx.named.grpc_message != nullptr) {
index d682760..221de35 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
+#include <grpc/grpc.h>
+#include <grpc/impl/codegen/compression_types.h>
+
 #include "src/core/lib/channel/channel_stack.h"
 #include "src/core/lib/channel/context.h"
 #include "src/core/lib/gprpp/arena.h"
 #include "src/core/lib/surface/api_trace.h"
 #include "src/core/lib/surface/server.h"
 
-#include <grpc/grpc.h>
-#include <grpc/impl/codegen/compression_types.h>
-
 typedef void (*grpc_ioreq_completion_func)(grpc_call* call, int success,
                                            void* user_data);
 
index 29c184c..ce73c3a 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
+#include <string.h>
+
 #include <grpc/grpc.h>
 #include <grpc/support/alloc.h>
 
-#include <string.h>
-
 #include "src/core/lib/iomgr/exec_ctx.h"
 #include "src/core/lib/slice/slice_internal.h"
 #include "src/core/lib/surface/api_trace.h"
index eac5513..6bc1881 100644 (file)
@@ -18,8 +18,6 @@
 
 #include <grpc/support/port_platform.h>
 
-#include "src/core/lib/surface/call.h"
-
 #include <inttypes.h>
 
 #include <vector>
 
 #include <grpc/support/alloc.h>
 #include <grpc/support/string_util.h>
+
 #include "src/core/lib/gpr/string.h"
 #include "src/core/lib/slice/slice_string_helpers.h"
+#include "src/core/lib/surface/call.h"
 
 static void add_metadata(const grpc_metadata* md, size_t count,
                          std::vector<std::string>* b) {
index d3552c8..f914f6e 100644 (file)
@@ -58,12 +58,12 @@ static void destroy_channel(void* arg, grpc_error_handle error);
 
 grpc_channel* grpc_channel_create_with_builder(
     grpc_channel_stack_builder* builder,
-    grpc_channel_stack_type channel_stack_type, grpc_error_handle* error) {
+    grpc_channel_stack_type channel_stack_type,
+    grpc_resource_user* resource_user, size_t preallocated_bytes,
+    grpc_error_handle* error) {
   char* target = gpr_strdup(grpc_channel_stack_builder_get_target(builder));
   grpc_channel_args* args = grpc_channel_args_copy(
       grpc_channel_stack_builder_get_channel_arguments(builder));
-  grpc_resource_user* resource_user =
-      grpc_channel_stack_builder_get_resource_user(builder);
   grpc_channel* channel;
   if (channel_stack_type == GRPC_SERVER_CHANNEL) {
     GRPC_STATS_INC_SERVER_CHANNELS_CREATED();
@@ -84,10 +84,17 @@ grpc_channel* grpc_channel_create_with_builder(
     }
     gpr_free(target);
     grpc_channel_args_destroy(args);
+    if (resource_user != nullptr) {
+      if (preallocated_bytes > 0) {
+        grpc_resource_user_free(resource_user, preallocated_bytes);
+      }
+      grpc_resource_user_unref(resource_user);
+    }
     return nullptr;
   }
   channel->target = target;
   channel->resource_user = resource_user;
+  channel->preallocated_bytes = preallocated_bytes;
   channel->is_client = grpc_channel_stack_type_is_client(channel_stack_type);
   channel->registration_table.Init();
 
@@ -225,6 +232,7 @@ grpc_channel* grpc_channel_create(const char* target,
                                   grpc_channel_stack_type channel_stack_type,
                                   grpc_transport* optional_transport,
                                   grpc_resource_user* resource_user,
+                                  size_t preallocated_bytes,
                                   grpc_error_handle* error) {
   // We need to make sure that grpc_shutdown() does not shut things down
   // until after the channel is destroyed.  However, the channel may not
@@ -259,11 +267,13 @@ grpc_channel* grpc_channel_create(const char* target,
   grpc_channel_args_destroy(args);
   grpc_channel_stack_builder_set_target(builder, target);
   grpc_channel_stack_builder_set_transport(builder, optional_transport);
-  grpc_channel_stack_builder_set_resource_user(builder, resource_user);
   if (!grpc_channel_init_create_stack(builder, channel_stack_type)) {
     grpc_channel_stack_builder_destroy(builder);
     if (resource_user != nullptr) {
-      grpc_resource_user_free(resource_user, GRPC_RESOURCE_QUOTA_CHANNEL_SIZE);
+      if (preallocated_bytes > 0) {
+        grpc_resource_user_free(resource_user, preallocated_bytes);
+      }
+      grpc_resource_user_unref(resource_user);
     }
     grpc_shutdown();  // Since we won't call destroy_channel().
     return nullptr;
@@ -273,8 +283,8 @@ grpc_channel* grpc_channel_create(const char* target,
   if (grpc_channel_stack_type_is_client(channel_stack_type)) {
     CreateChannelzNode(builder);
   }
-  grpc_channel* channel =
-      grpc_channel_create_with_builder(builder, channel_stack_type, error);
+  grpc_channel* channel = grpc_channel_create_with_builder(
+      builder, channel_stack_type, resource_user, preallocated_bytes, error);
   if (channel == nullptr) {
     grpc_shutdown();  // Since we won't call destroy_channel().
   }
@@ -508,8 +518,11 @@ static void destroy_channel(void* arg, grpc_error_handle /*error*/) {
   grpc_channel_stack_destroy(CHANNEL_STACK_FROM_CHANNEL(channel));
   channel->registration_table.Destroy();
   if (channel->resource_user != nullptr) {
-    grpc_resource_user_free(channel->resource_user,
-                            GRPC_RESOURCE_QUOTA_CHANNEL_SIZE);
+    if (channel->preallocated_bytes > 0) {
+      grpc_resource_user_free(channel->resource_user,
+                              channel->preallocated_bytes);
+    }
+    grpc_resource_user_unref(channel->resource_user);
   }
   gpr_free(channel->target);
   gpr_free(channel);
index 8a14a72..4e885fa 100644 (file)
 #include "src/core/lib/surface/channel_stack_type.h"
 #include "src/core/lib/transport/metadata.h"
 
+/// Creates a grpc_channel.
+///
+/// If the \a resource_user is not null, \a preallocated_bytes may have been
+/// allocated on that resource_user for use by the channel. These bytes will be
+/// freed from the resource_user upon channel destruction.
+///
+/// Takes ownership of a \a resource_user ref.
 grpc_channel* grpc_channel_create(const char* target,
                                   const grpc_channel_args* args,
                                   grpc_channel_stack_type channel_stack_type,
                                   grpc_transport* optional_transport,
-                                  grpc_resource_user* resource_user = nullptr,
-                                  grpc_error_handle* error = nullptr);
+                                  grpc_resource_user* resource_user,
+                                  size_t preallocated_bytes,
+                                  grpc_error_handle* error);
 
 /** The same as grpc_channel_destroy, but doesn't create an ExecCtx, and so
  * is safe to use from within core. */
 void grpc_channel_destroy_internal(grpc_channel* channel);
 
+/// Creates a grpc_channel with a builder. See the description of
+/// \a grpc_channel_create for variable definitions.
 grpc_channel* grpc_channel_create_with_builder(
     grpc_channel_stack_builder* builder,
     grpc_channel_stack_type channel_stack_type,
+    grpc_resource_user* resource_user, size_t preallocated_bytes,
     grpc_error_handle* error = nullptr);
 
 /** Create a call given a grpc_channel, in order to call \a method.
@@ -108,6 +119,7 @@ struct grpc_channel {
 
   gpr_atm call_size_estimate;
   grpc_resource_user* resource_user;
+  size_t preallocated_bytes;
 
   // TODO(vjpai): Once the grpc_channel is allocated via new rather than malloc,
   //              expand the members of the CallRegistrationTable directly into
index a6e53ec..22c4938 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include "src/core/lib/surface/channel.h"
-
 #include <string.h>
 
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 
 #include "src/core/lib/surface/api_trace.h"
+#include "src/core/lib/surface/channel.h"
 #include "src/core/lib/surface/completion_queue.h"
 
 struct ping_result {
index fcf96dd..ecbc3ef 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include <grpc/support/log.h>
 #include "src/core/lib/surface/channel_stack_type.h"
 
+#include <grpc/support/log.h>
+
 bool grpc_channel_stack_type_is_client(grpc_channel_stack_type type) {
   switch (type) {
     case GRPC_CLIENT_CHANNEL:
index 1d210d2..17e8ed4 100644 (file)
@@ -23,6 +23,7 @@
 #include <stdio.h>
 #include <string.h>
 
+#include <atomic>
 #include <vector>
 
 #include "absl/strings/str_format.h"
@@ -38,7 +39,6 @@
 #include "src/core/lib/gpr/spinlock.h"
 #include "src/core/lib/gpr/string.h"
 #include "src/core/lib/gpr/tls.h"
-#include "src/core/lib/gprpp/atomic.h"
 #include "src/core/lib/iomgr/executor.h"
 #include "src/core/lib/iomgr/pollset.h"
 #include "src/core/lib/iomgr/timer.h"
@@ -58,8 +58,8 @@ namespace {
 // with a cq cache will go into that cache, and
 // will only be returned on the thread that initialized the cache.
 // NOTE: Only one event will ever be cached.
-GPR_TLS_DECL(g_cached_event);
-GPR_TLS_DECL(g_cached_cq);
+static GPR_THREAD_LOCAL(grpc_cq_completion*) g_cached_event;
+static GPR_THREAD_LOCAL(grpc_completion_queue*) g_cached_cq;
 
 struct plucker {
   grpc_pollset_worker** worker;
@@ -224,7 +224,7 @@ class CqEventQueue {
   /* Note: The counter is not incremented/decremented atomically with push/pop.
    * The count is only eventually consistent */
   intptr_t num_items() const {
-    return num_queue_items_.Load(grpc_core::MemoryOrder::RELAXED);
+    return num_queue_items_.load(std::memory_order_relaxed);
   }
 
   bool Push(grpc_cq_completion* c);
@@ -239,14 +239,14 @@ class CqEventQueue {
   /* A lazy counter of number of items in the queue. This is NOT atomically
      incremented/decremented along with push/pop operations and hence is only
      eventually consistent */
-  grpc_core::Atomic<intptr_t> num_queue_items_{0};
+  std::atomic<intptr_t> num_queue_items_{0};
 };
 
 struct cq_next_data {
   ~cq_next_data() {
     GPR_ASSERT(queue.num_items() == 0);
 #ifndef NDEBUG
-    if (pending_events.Load(grpc_core::MemoryOrder::ACQUIRE) != 0) {
+    if (pending_events.load(std::memory_order_acquire) != 0) {
       gpr_log(GPR_ERROR, "Destroying CQ without draining it fully.");
     }
 #endif
@@ -257,11 +257,11 @@ struct cq_next_data {
 
   /** Counter of how many things have ever been queued on this completion queue
       useful for avoiding locks to check the queue */
-  grpc_core::Atomic<intptr_t> things_queued_ever{0};
+  std::atomic<intptr_t> things_queued_ever{0};
 
   /** Number of outstanding events (+1 if not shut down)
       Initial count is dropped by grpc_completion_queue_shutdown */
-  grpc_core::Atomic<intptr_t> pending_events{1};
+  std::atomic<intptr_t> pending_events{1};
 
   /** 0 initially. 1 once we initiated shutdown */
   bool shutdown_called = false;
@@ -277,7 +277,7 @@ struct cq_pluck_data {
     GPR_ASSERT(completed_head.next ==
                reinterpret_cast<uintptr_t>(&completed_head));
 #ifndef NDEBUG
-    if (pending_events.Load(grpc_core::MemoryOrder::ACQUIRE) != 0) {
+    if (pending_events.load(std::memory_order_acquire) != 0) {
       gpr_log(GPR_ERROR, "Destroying CQ without draining it fully.");
     }
 #endif
@@ -289,17 +289,17 @@ struct cq_pluck_data {
 
   /** Number of pending events (+1 if we're not shutdown).
       Initial count is dropped by grpc_completion_queue_shutdown. */
-  grpc_core::Atomic<intptr_t> pending_events{1};
+  std::atomic<intptr_t> pending_events{1};
 
   /** Counter of how many things have ever been queued on this completion queue
       useful for avoiding locks to check the queue */
-  grpc_core::Atomic<intptr_t> things_queued_ever{0};
+  std::atomic<intptr_t> things_queued_ever{0};
 
   /** 0 initially. 1 once we completed shutting */
   /* TODO: (sreek) This is not needed since (shutdown == 1) if and only if
    * (pending_events == 0). So consider removing this in future and use
    * pending_events */
-  grpc_core::Atomic<bool> shutdown{false};
+  std::atomic<bool> shutdown{false};
 
   /** 0 initially. 1 once we initiated shutdown */
   bool shutdown_called = false;
@@ -314,7 +314,7 @@ struct cq_callback_data {
 
   ~cq_callback_data() {
 #ifndef NDEBUG
-    if (pending_events.Load(grpc_core::MemoryOrder::ACQUIRE) != 0) {
+    if (pending_events.load(std::memory_order_acquire) != 0) {
       gpr_log(GPR_ERROR, "Destroying CQ without draining it fully.");
     }
 #endif
@@ -324,7 +324,7 @@ struct cq_callback_data {
 
   /** Number of pending events (+1 if we're not shutdown).
       Initial count is dropped by grpc_completion_queue_shutdown. */
-  grpc_core::Atomic<intptr_t> pending_events{1};
+  std::atomic<intptr_t> pending_events{1};
 
   /** 0 initially. 1 once we initiated shutdown */
   bool shutdown_called = false;
@@ -439,33 +439,27 @@ grpc_core::TraceFlag grpc_cq_pluck_trace(false, "queue_pluck");
 
 static void on_pollset_shutdown_done(void* arg, grpc_error_handle error);
 
-void grpc_cq_global_init() {
-  gpr_tls_init(&g_cached_event);
-  gpr_tls_init(&g_cached_cq);
-}
+void grpc_cq_global_init() {}
 
 void grpc_completion_queue_thread_local_cache_init(grpc_completion_queue* cq) {
-  if (reinterpret_cast<grpc_completion_queue*>(gpr_tls_get(&g_cached_cq)) ==
-      nullptr) {
-    gpr_tls_set(&g_cached_event, (intptr_t)0);
-    gpr_tls_set(&g_cached_cq, (intptr_t)cq);
+  if (g_cached_cq == nullptr) {
+    g_cached_event = nullptr;
+    g_cached_cq = cq;
   }
 }
 
 int grpc_completion_queue_thread_local_cache_flush(grpc_completion_queue* cq,
                                                    void** tag, int* ok) {
-  grpc_cq_completion* storage =
-      reinterpret_cast<grpc_cq_completion*>(gpr_tls_get(&g_cached_event));
+  grpc_cq_completion* storage = g_cached_event;
   int ret = 0;
-  if (storage != nullptr && reinterpret_cast<grpc_completion_queue*>(
-                                gpr_tls_get(&g_cached_cq)) == cq) {
+  if (storage != nullptr && g_cached_cq == cq) {
     *tag = storage->tag;
     grpc_core::ExecCtx exec_ctx;
     *ok = (storage->next & static_cast<uintptr_t>(1)) == 1;
     storage->done(storage->done_arg, storage);
     ret = 1;
     cq_next_data* cqd = static_cast<cq_next_data*> DATA_FROM_CQ(cq);
-    if (cqd->pending_events.FetchSub(1, grpc_core::MemoryOrder::ACQ_REL) == 1) {
+    if (cqd->pending_events.fetch_sub(1, std::memory_order_acq_rel) == 1) {
       GRPC_CQ_INTERNAL_REF(cq, "shutting_down");
       gpr_mu_lock(cq->mu);
       cq_finish_shutdown_next(cq);
@@ -473,8 +467,8 @@ int grpc_completion_queue_thread_local_cache_flush(grpc_completion_queue* cq,
       GRPC_CQ_INTERNAL_UNREF(cq, "shutting_down");
     }
   }
-  gpr_tls_set(&g_cached_event, (intptr_t)0);
-  gpr_tls_set(&g_cached_cq, (intptr_t)0);
+  g_cached_event = nullptr;
+  g_cached_cq = nullptr;
 
   return ret;
 }
@@ -482,7 +476,7 @@ int grpc_completion_queue_thread_local_cache_flush(grpc_completion_queue* cq,
 bool CqEventQueue::Push(grpc_cq_completion* c) {
   queue_.Push(
       reinterpret_cast<grpc_core::MultiProducerSingleConsumerQueue::Node*>(c));
-  return num_queue_items_.FetchAdd(1, grpc_core::MemoryOrder::RELAXED) == 0;
+  return num_queue_items_.fetch_add(1, std::memory_order_relaxed) == 0;
 }
 
 grpc_cq_completion* CqEventQueue::Pop() {
@@ -503,7 +497,7 @@ grpc_cq_completion* CqEventQueue::Pop() {
   }
 
   if (c) {
-    num_queue_items_.FetchSub(1, grpc_core::MemoryOrder::RELAXED);
+    num_queue_items_.fetch_sub(1, std::memory_order_relaxed);
   }
 
   return c;
@@ -654,17 +648,17 @@ static void cq_check_tag(grpc_completion_queue* /*cq*/, void* /*tag*/,
 
 static bool cq_begin_op_for_next(grpc_completion_queue* cq, void* /*tag*/) {
   cq_next_data* cqd = static_cast<cq_next_data*> DATA_FROM_CQ(cq);
-  return cqd->pending_events.IncrementIfNonzero();
+  return grpc_core::IncrementIfNonzero(&cqd->pending_events);
 }
 
 static bool cq_begin_op_for_pluck(grpc_completion_queue* cq, void* /*tag*/) {
   cq_pluck_data* cqd = static_cast<cq_pluck_data*> DATA_FROM_CQ(cq);
-  return cqd->pending_events.IncrementIfNonzero();
+  return grpc_core::IncrementIfNonzero(&cqd->pending_events);
 }
 
 static bool cq_begin_op_for_callback(grpc_completion_queue* cq, void* /*tag*/) {
   cq_callback_data* cqd = static_cast<cq_callback_data*> DATA_FROM_CQ(cq);
-  return cqd->pending_events.IncrementIfNonzero();
+  return grpc_core::IncrementIfNonzero(&cqd->pending_events);
 }
 
 bool grpc_cq_begin_op(grpc_completion_queue* cq, void* tag) {
@@ -715,21 +709,18 @@ static void cq_end_op_for_next(
 
   cq_check_tag(cq, tag, true); /* Used in debug builds only */
 
-  if (reinterpret_cast<grpc_completion_queue*>(gpr_tls_get(&g_cached_cq)) ==
-          cq &&
-      reinterpret_cast<grpc_cq_completion*>(gpr_tls_get(&g_cached_event)) ==
-          nullptr) {
-    gpr_tls_set(&g_cached_event, (intptr_t)storage);
+  if (g_cached_cq == cq && g_cached_event == nullptr) {
+    g_cached_event = storage;
   } else {
     /* Add the completion to the queue */
     bool is_first = cqd->queue.Push(storage);
-    cqd->things_queued_ever.FetchAdd(1, grpc_core::MemoryOrder::RELAXED);
+    cqd->things_queued_ever.fetch_add(1, std::memory_order_relaxed);
     /* Since we do not hold the cq lock here, it is important to do an 'acquire'
        load here (instead of a 'no_barrier' load) to match with the release
        store
-       (done via pending_events.FetchSub(1, ACQ_REL)) in cq_shutdown_next
+       (done via pending_events.fetch_sub(1, ACQ_REL)) in cq_shutdown_next
        */
-    if (cqd->pending_events.Load(grpc_core::MemoryOrder::ACQUIRE) != 1) {
+    if (cqd->pending_events.load(std::memory_order_acquire) != 1) {
       /* Only kick if this is the first item queued */
       if (is_first) {
         gpr_mu_lock(cq->mu);
@@ -743,8 +734,7 @@ static void cq_end_op_for_next(
           GRPC_ERROR_UNREF(kick_error);
         }
       }
-      if (cqd->pending_events.FetchSub(1, grpc_core::MemoryOrder::ACQ_REL) ==
-          1) {
+      if (cqd->pending_events.fetch_sub(1, std::memory_order_acq_rel) == 1) {
         GRPC_CQ_INTERNAL_REF(cq, "shutting_down");
         gpr_mu_lock(cq->mu);
         cq_finish_shutdown_next(cq);
@@ -753,7 +743,7 @@ static void cq_end_op_for_next(
       }
     } else {
       GRPC_CQ_INTERNAL_REF(cq, "shutting_down");
-      cqd->pending_events.Store(0, grpc_core::MemoryOrder::RELEASE);
+      cqd->pending_events.store(0, std::memory_order_release);
       gpr_mu_lock(cq->mu);
       cq_finish_shutdown_next(cq);
       gpr_mu_unlock(cq->mu);
@@ -801,12 +791,12 @@ static void cq_end_op_for_pluck(
   cq_check_tag(cq, tag, false); /* Used in debug builds only */
 
   /* Add to the list of completions */
-  cqd->things_queued_ever.FetchAdd(1, grpc_core::MemoryOrder::RELAXED);
+  cqd->things_queued_ever.fetch_add(1, std::memory_order_relaxed);
   cqd->completed_tail->next =
       reinterpret_cast<uintptr_t>(storage) | (1u & cqd->completed_tail->next);
   cqd->completed_tail = storage;
 
-  if (cqd->pending_events.FetchSub(1, grpc_core::MemoryOrder::ACQ_REL) == 1) {
+  if (cqd->pending_events.fetch_sub(1, std::memory_order_acq_rel) == 1) {
     cq_finish_shutdown_pluck(cq);
     gpr_mu_unlock(cq->mu);
   } else {
@@ -866,7 +856,7 @@ static void cq_end_op_for_callback(
 
   cq_check_tag(cq, tag, true); /* Used in debug builds only */
 
-  if (cqd->pending_events.FetchSub(1, grpc_core::MemoryOrder::ACQ_REL) == 1) {
+  if (cqd->pending_events.fetch_sub(1, std::memory_order_acq_rel) == 1) {
     cq_finish_shutdown_callback(cq);
   }
 
@@ -921,12 +911,12 @@ class ExecCtxNext : public grpc_core::ExecCtx {
     GPR_ASSERT(a->stolen_completion == nullptr);
 
     intptr_t current_last_seen_things_queued_ever =
-        cqd->things_queued_ever.Load(grpc_core::MemoryOrder::RELAXED);
+        cqd->things_queued_ever.load(std::memory_order_relaxed);
 
     if (current_last_seen_things_queued_ever !=
         a->last_seen_things_queued_ever) {
       a->last_seen_things_queued_ever =
-          cqd->things_queued_ever.Load(grpc_core::MemoryOrder::RELAXED);
+          cqd->things_queued_ever.load(std::memory_order_relaxed);
 
       /* Pop a cq_completion from the queue. Returns NULL if the queue is empty
        * might return NULL in some cases even if the queue is not empty; but
@@ -985,7 +975,7 @@ static grpc_event cq_next(grpc_completion_queue* cq, gpr_timespec deadline,
 
   grpc_millis deadline_millis = grpc_timespec_to_millis_round_up(deadline);
   cq_is_finished_arg is_finished_arg = {
-      cqd->things_queued_ever.Load(grpc_core::MemoryOrder::RELAXED),
+      cqd->things_queued_ever.load(std::memory_order_relaxed),
       cq,
       deadline_millis,
       nullptr,
@@ -1024,7 +1014,7 @@ static grpc_event cq_next(grpc_completion_queue* cq, gpr_timespec deadline,
       }
     }
 
-    if (cqd->pending_events.Load(grpc_core::MemoryOrder::ACQUIRE) == 0) {
+    if (cqd->pending_events.load(std::memory_order_acquire) == 0) {
       /* Before returning, check if the queue has any items left over (since
          MultiProducerSingleConsumerQueue::Pop() can sometimes return NULL
          even if the queue is not empty. If so, keep retrying but do not
@@ -1074,7 +1064,7 @@ static grpc_event cq_next(grpc_completion_queue* cq, gpr_timespec deadline,
   }
 
   if (cqd->queue.num_items() > 0 &&
-      cqd->pending_events.Load(grpc_core::MemoryOrder::ACQUIRE) > 0) {
+      cqd->pending_events.load(std::memory_order_acquire) > 0) {
     gpr_mu_lock(cq->mu);
     cq->poller_vtable->kick(POLLSET_FROM_CQ(cq), nullptr);
     gpr_mu_unlock(cq->mu);
@@ -1098,7 +1088,7 @@ static void cq_finish_shutdown_next(grpc_completion_queue* cq) {
   cq_next_data* cqd = static_cast<cq_next_data*> DATA_FROM_CQ(cq);
 
   GPR_ASSERT(cqd->shutdown_called);
-  GPR_ASSERT(cqd->pending_events.Load(grpc_core::MemoryOrder::RELAXED) == 0);
+  GPR_ASSERT(cqd->pending_events.load(std::memory_order_relaxed) == 0);
 
   cq->poller_vtable->shutdown(POLLSET_FROM_CQ(cq), &cq->pollset_shutdown_done);
 }
@@ -1120,10 +1110,10 @@ static void cq_shutdown_next(grpc_completion_queue* cq) {
     return;
   }
   cqd->shutdown_called = true;
-  /* Doing acq/release FetchSub here to match with
+  /* Doing acq/release fetch_sub here to match with
    * cq_begin_op_for_next and cq_end_op_for_next functions which read/write
    * on this counter without necessarily holding a lock on cq */
-  if (cqd->pending_events.FetchSub(1, grpc_core::MemoryOrder::ACQ_REL) == 1) {
+  if (cqd->pending_events.fetch_sub(1, std::memory_order_acq_rel) == 1) {
     cq_finish_shutdown_next(cq);
   }
   gpr_mu_unlock(cq->mu);
@@ -1173,12 +1163,12 @@ class ExecCtxPluck : public grpc_core::ExecCtx {
 
     GPR_ASSERT(a->stolen_completion == nullptr);
     gpr_atm current_last_seen_things_queued_ever =
-        cqd->things_queued_ever.Load(grpc_core::MemoryOrder::RELAXED);
+        cqd->things_queued_ever.load(std::memory_order_relaxed);
     if (current_last_seen_things_queued_ever !=
         a->last_seen_things_queued_ever) {
       gpr_mu_lock(cq->mu);
       a->last_seen_things_queued_ever =
-          cqd->things_queued_ever.Load(grpc_core::MemoryOrder::RELAXED);
+          cqd->things_queued_ever.load(std::memory_order_relaxed);
       grpc_cq_completion* c;
       grpc_cq_completion* prev = &cqd->completed_head;
       while ((c = reinterpret_cast<grpc_cq_completion*>(
@@ -1234,7 +1224,7 @@ static grpc_event cq_pluck(grpc_completion_queue* cq, void* tag,
   gpr_mu_lock(cq->mu);
   grpc_millis deadline_millis = grpc_timespec_to_millis_round_up(deadline);
   cq_is_finished_arg is_finished_arg = {
-      cqd->things_queued_ever.Load(grpc_core::MemoryOrder::RELAXED),
+      cqd->things_queued_ever.load(std::memory_order_relaxed),
       cq,
       deadline_millis,
       nullptr,
@@ -1271,7 +1261,7 @@ static grpc_event cq_pluck(grpc_completion_queue* cq, void* tag,
       }
       prev = c;
     }
-    if (cqd->shutdown.Load(grpc_core::MemoryOrder::RELAXED)) {
+    if (cqd->shutdown.load(std::memory_order_relaxed)) {
       gpr_mu_unlock(cq->mu);
       ret.type = GRPC_QUEUE_SHUTDOWN;
       ret.success = 0;
@@ -1333,8 +1323,8 @@ static void cq_finish_shutdown_pluck(grpc_completion_queue* cq) {
   cq_pluck_data* cqd = static_cast<cq_pluck_data*> DATA_FROM_CQ(cq);
 
   GPR_ASSERT(cqd->shutdown_called);
-  GPR_ASSERT(!cqd->shutdown.Load(grpc_core::MemoryOrder::RELAXED));
-  cqd->shutdown.Store(true, grpc_core::MemoryOrder::RELAXED);
+  GPR_ASSERT(!cqd->shutdown.load(std::memory_order_relaxed));
+  cqd->shutdown.store(true, std::memory_order_relaxed);
 
   cq->poller_vtable->shutdown(POLLSET_FROM_CQ(cq), &cq->pollset_shutdown_done);
 }
@@ -1358,7 +1348,7 @@ static void cq_shutdown_pluck(grpc_completion_queue* cq) {
     return;
   }
   cqd->shutdown_called = true;
-  if (cqd->pending_events.FetchSub(1, grpc_core::MemoryOrder::ACQ_REL) == 1) {
+  if (cqd->pending_events.fetch_sub(1, std::memory_order_acq_rel) == 1) {
     cq_finish_shutdown_pluck(cq);
   }
   gpr_mu_unlock(cq->mu);
@@ -1401,7 +1391,7 @@ static void cq_shutdown_callback(grpc_completion_queue* cq) {
     return;
   }
   cqd->shutdown_called = true;
-  if (cqd->pending_events.FetchSub(1, grpc_core::MemoryOrder::ACQ_REL) == 1) {
+  if (cqd->pending_events.fetch_sub(1, std::memory_order_acq_rel) == 1) {
     gpr_mu_unlock(cq->mu);
     cq_finish_shutdown_callback(cq);
   } else {
index d719f3b..80aaba2 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include "src/core/lib/surface/completion_queue.h"
 #include "src/core/lib/surface/completion_queue_factory.h"
 
 #include <grpc/support/log.h>
 
+#include "src/core/lib/surface/completion_queue.h"
+
 /*
  * == Default completion queue factory implementation ==
  */
index d2b30a9..b1b1372 100644 (file)
@@ -22,6 +22,7 @@
 #include <grpc/support/port_platform.h>
 
 #include <grpc/grpc.h>
+
 #include "src/core/lib/surface/completion_queue.h"
 
 typedef struct grpc_completion_queue_factory_vtable {
index 32d85f7..da40734 100644 (file)
@@ -29,6 +29,7 @@
 
 #include <grpc/byte_buffer.h>
 #include <grpc/support/string_util.h>
+
 #include "src/core/lib/gpr/string.h"
 
 static void addhdr(grpc_event* ev, std::vector<std::string>* buf) {
index 19d353f..961de64 100644 (file)
@@ -32,7 +32,6 @@
 #include "src/core/lib/channel/channel_stack.h"
 #include "src/core/lib/channel/channelz_registry.h"
 #include "src/core/lib/channel/connected_channel.h"
-#include "src/core/lib/channel/handshaker_registry.h"
 #include "src/core/lib/debug/stats.h"
 #include "src/core/lib/debug/trace.h"
 #include "src/core/lib/gprpp/fork.h"
@@ -64,20 +63,18 @@ extern void grpc_register_built_in_plugins(void);
 
 static gpr_once g_basic_init = GPR_ONCE_INIT;
 static grpc_core::Mutex* g_init_mu;
-static int g_initializations;
+static int g_initializations ABSL_GUARDED_BY(g_init_mu) = 0;
 static grpc_core::CondVar* g_shutting_down_cv;
-static bool g_shutting_down;
+static bool g_shutting_down ABSL_GUARDED_BY(g_init_mu) = false;
 
 static void do_basic_init(void) {
   gpr_log_verbosity_init();
   g_init_mu = new grpc_core::Mutex();
   g_shutting_down_cv = new grpc_core::CondVar();
-  g_shutting_down = false;
   grpc_register_built_in_plugins();
   grpc_cq_global_init();
   grpc_core::grpc_executor_global_init();
   gpr_time_init();
-  g_initializations = 0;
 }
 
 static bool append_filter(grpc_channel_stack_builder* builder, void* arg) {
@@ -147,8 +144,6 @@ void grpc_init(void) {
     grpc_core::ExecCtx::GlobalInit();
     grpc_iomgr_init();
     gpr_timers_global_init();
-    grpc_core::HandshakerRegistry::Init();
-    grpc_security_init();
     for (int i = 0; i < g_number_of_plugins; i++) {
       if (g_all_of_the_plugins[i].init != nullptr) {
         g_all_of_the_plugins[i].init();
@@ -167,7 +162,8 @@ void grpc_init(void) {
   GRPC_API_TRACE("grpc_init(void)", 0, ());
 }
 
-void grpc_shutdown_internal_locked(void) {
+void grpc_shutdown_internal_locked(void)
+    ABSL_EXCLUSIVE_LOCKS_REQUIRED(g_init_mu) {
   int i;
   {
     grpc_core::ExecCtx exec_ctx(0);
@@ -184,7 +180,6 @@ void grpc_shutdown_internal_locked(void) {
     gpr_timers_global_destroy();
     grpc_tracer_shutdown();
     grpc_mdctx_global_shutdown();
-    grpc_core::HandshakerRegistry::Shutdown();
     grpc_slice_intern_shutdown();
     grpc_core::channelz::ChannelzRegistry::Shutdown();
     grpc_stats_shutdown();
index 9e8bedc..8982e28 100644 (file)
@@ -30,7 +30,6 @@ class EventEngine;
 
 void grpc_register_security_filters(void);
 void grpc_security_pre_init(void);
-void grpc_security_init(void);
 void grpc_maybe_wait_for_async_shutdown(void);
 
 #endif /* GRPC_CORE_LIB_SURFACE_INIT_H */
index 428c581..0db0ebc 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include "src/core/lib/surface/init.h"
-
 #include <limits.h>
 #include <string.h>
 
 #include "src/core/lib/debug/trace.h"
+#include "src/core/lib/security/authorization/sdk_server_authz_filter.h"
 #include "src/core/lib/security/context/security_context.h"
 #include "src/core/lib/security/credentials/credentials.h"
 #include "src/core/lib/security/credentials/plugin/plugin_credentials.h"
@@ -32,6 +31,7 @@
 #include "src/core/lib/security/transport/secure_endpoint.h"
 #include "src/core/lib/security/transport/security_handshaker.h"
 #include "src/core/lib/surface/channel_init.h"
+#include "src/core/lib/surface/init.h"
 #include "src/core/tsi/transport_security_interface.h"
 
 void grpc_security_pre_init(void) {}
@@ -66,6 +66,21 @@ static bool maybe_prepend_server_auth_filter(
   return true;
 }
 
+static bool maybe_prepend_sdk_server_authz_filter(
+    grpc_channel_stack_builder* builder, void* /*arg*/) {
+  const grpc_channel_args* args =
+      grpc_channel_stack_builder_get_channel_arguments(builder);
+  const auto* provider =
+      grpc_channel_args_find_pointer<grpc_authorization_policy_provider>(
+          args, GRPC_ARG_AUTHORIZATION_POLICY_PROVIDER);
+  if (provider != nullptr) {
+    return grpc_channel_stack_builder_prepend_filter(
+        builder, &grpc_core::SdkServerAuthzFilter::kFilterVtable, nullptr,
+        nullptr);
+  }
+  return true;
+}
+
 void grpc_register_security_filters(void) {
   // Register the auth client with a priority < INT_MAX to allow the authority
   // filter -on which the auth filter depends- to be higher on the channel
@@ -76,6 +91,10 @@ void grpc_register_security_filters(void) {
                                    maybe_prepend_client_auth_filter, nullptr);
   grpc_channel_init_register_stage(GRPC_SERVER_CHANNEL, INT_MAX - 1,
                                    maybe_prepend_server_auth_filter, nullptr);
+  // Register the SdkServerAuthzFilter with a priority less than
+  // server_auth_filter to allow server_auth_filter on which the sdk filter
+  // depends on to be higher on the channel stack.
+  grpc_channel_init_register_stage(GRPC_SERVER_CHANNEL, INT_MAX - 2,
+                                   maybe_prepend_sdk_server_authz_filter,
+                                   nullptr);
 }
-
-void grpc_security_init() { grpc_core::SecurityRegisterHandshakerFactories(); }
index 7b86d50..c9e1688 100644 (file)
@@ -25,9 +25,3 @@
 void grpc_security_pre_init(void) {}
 
 void grpc_register_security_filters(void) {}
-
-void grpc_security_init(void) {
-  gpr_log(GPR_DEBUG,
-          "Using insecure gRPC build. Security handshakers will not be invoked "
-          "even if secure credentials are used.");
-}
index 65e659a..65843e0 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include <grpc/grpc.h>
+#include "src/core/lib/surface/lame_client.h"
 
 #include <string.h>
 
+#include <atomic>
+
+#include <grpc/grpc.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 
 #include "src/core/lib/channel/channel_stack.h"
 #include "src/core/lib/gpr/string.h"
-#include "src/core/lib/gprpp/atomic.h"
 #include "src/core/lib/surface/api_trace.h"
 #include "src/core/lib/surface/call.h"
 #include "src/core/lib/surface/channel.h"
-#include "src/core/lib/surface/lame_client.h"
 #include "src/core/lib/transport/connectivity_state.h"
 #include "src/core/lib/transport/static_metadata.h"
 
@@ -177,8 +178,8 @@ grpc_channel* grpc_lame_client_channel_create(const char* target,
       grpc_slice_from_static_string(error_message));
   grpc_arg error_arg = grpc_core::MakeLameClientErrorArg(error);
   grpc_channel_args args = {1, &error_arg};
-  grpc_channel* channel =
-      grpc_channel_create(target, &args, GRPC_CLIENT_LAME_CHANNEL, nullptr);
+  grpc_channel* channel = grpc_channel_create(
+      target, &args, GRPC_CLIENT_LAME_CHANNEL, nullptr, nullptr, 0, nullptr);
   GRPC_ERROR_UNREF(error);
   return channel;
 }
index f794a2b..3633382 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
+#include <string.h>
+
 #include <grpc/grpc.h>
 #include <grpc/support/alloc.h>
 
-#include <string.h>
-
 #include "src/core/lib/surface/api_trace.h"
 
 void grpc_metadata_array_init(grpc_metadata_array* array) {
index 558d41a..6c5f713 100644 (file)
@@ -513,17 +513,6 @@ const grpc_channel_filter Server::kServerTopFilter = {
 
 namespace {
 
-grpc_resource_user* CreateDefaultResourceUser(const grpc_channel_args* args) {
-  if (args != nullptr) {
-    grpc_resource_quota* resource_quota =
-        grpc_resource_quota_from_channel_args(args, false /* create */);
-    if (resource_quota != nullptr) {
-      return grpc_resource_user_create(resource_quota, "default");
-    }
-  }
-  return nullptr;
-}
-
 RefCountedPtr<channelz::ServerNode> CreateChannelzNode(
     const grpc_channel_args* args) {
   RefCountedPtr<channelz::ServerNode> channelz_node;
@@ -545,7 +534,6 @@ RefCountedPtr<channelz::ServerNode> CreateChannelzNode(
 
 Server::Server(const grpc_channel_args* args)
     : channel_args_(grpc_channel_args_copy(args)),
-      default_resource_user_(CreateDefaultResourceUser(args)),
       channelz_node_(CreateChannelzNode(args)) {}
 
 Server::~Server() {
@@ -613,11 +601,12 @@ grpc_error_handle Server::SetupTransport(
     grpc_transport* transport, grpc_pollset* accepting_pollset,
     const grpc_channel_args* args,
     const RefCountedPtr<grpc_core::channelz::SocketNode>& socket_node,
-    grpc_resource_user* resource_user) {
+    grpc_resource_user* resource_user, size_t preallocated_bytes) {
   // Create channel.
   grpc_error_handle error = GRPC_ERROR_NONE;
-  grpc_channel* channel = grpc_channel_create(
-      nullptr, args, GRPC_SERVER_CHANNEL, transport, resource_user, &error);
+  grpc_channel* channel =
+      grpc_channel_create(nullptr, args, GRPC_SERVER_CHANNEL, transport,
+                          resource_user, preallocated_bytes, &error);
   if (channel == nullptr) {
     return error;
   }
@@ -866,11 +855,6 @@ void Server::Orphan() {
     GPR_ASSERT(ShutdownCalled() || listeners_.empty());
     GPR_ASSERT(listeners_destroyed_ == listeners_.size());
   }
-  if (default_resource_user_ != nullptr) {
-    grpc_resource_quota_unref(grpc_resource_user_quota(default_resource_user_));
-    grpc_resource_user_shutdown(default_resource_user_);
-    grpc_resource_user_unref(default_resource_user_);
-  }
   Unref();
 }
 
@@ -1209,7 +1193,7 @@ Server::CallData::CallData(grpc_call_element* elem,
 }
 
 Server::CallData::~CallData() {
-  GPR_ASSERT(state_.Load(MemoryOrder::RELAXED) != CallState::PENDING);
+  GPR_ASSERT(state_.load(std::memory_order_relaxed) != CallState::PENDING);
   GRPC_ERROR_UNREF(recv_initial_metadata_error_);
   if (host_.has_value()) {
     grpc_slice_unref_internal(*host_);
@@ -1222,26 +1206,26 @@ Server::CallData::~CallData() {
 }
 
 void Server::CallData::SetState(CallState state) {
-  state_.Store(state, MemoryOrder::RELAXED);
+  state_.store(state, std::memory_order_relaxed);
 }
 
 bool Server::CallData::MaybeActivate() {
   CallState expected = CallState::PENDING;
-  return state_.CompareExchangeStrong(&expected, CallState::ACTIVATED,
-                                      MemoryOrder::ACQ_REL,
-                                      MemoryOrder::RELAXED);
+  return state_.compare_exchange_strong(expected, CallState::ACTIVATED,
+                                        std::memory_order_acq_rel,
+                                        std::memory_order_relaxed);
 }
 
 void Server::CallData::FailCallCreation() {
   CallState expected_not_started = CallState::NOT_STARTED;
   CallState expected_pending = CallState::PENDING;
-  if (state_.CompareExchangeStrong(&expected_not_started, CallState::ZOMBIED,
-                                   MemoryOrder::ACQ_REL,
-                                   MemoryOrder::ACQUIRE)) {
+  if (state_.compare_exchange_strong(expected_not_started, CallState::ZOMBIED,
+                                     std::memory_order_acq_rel,
+                                     std::memory_order_acquire)) {
     KillZombie();
-  } else if (state_.CompareExchangeStrong(&expected_pending, CallState::ZOMBIED,
-                                          MemoryOrder::ACQ_REL,
-                                          MemoryOrder::RELAXED)) {
+  } else if (state_.compare_exchange_strong(
+                 expected_pending, CallState::ZOMBIED,
+                 std::memory_order_acq_rel, std::memory_order_relaxed)) {
     // Zombied call will be destroyed when it's removed from the pending
     // queue... later.
   }
@@ -1297,7 +1281,7 @@ void Server::CallData::PublishNewRpc(void* arg, grpc_error_handle error) {
   RequestMatcherInterface* rm = calld->matcher_;
   Server* server = rm->server();
   if (error != GRPC_ERROR_NONE || server->ShutdownCalled()) {
-    calld->state_.Store(CallState::ZOMBIED, MemoryOrder::RELAXED);
+    calld->state_.store(CallState::ZOMBIED, std::memory_order_relaxed);
     calld->KillZombie();
     return;
   }
@@ -1321,7 +1305,7 @@ void Server::CallData::KillZombie() {
 void Server::CallData::StartNewRpc(grpc_call_element* elem) {
   auto* chand = static_cast<ChannelData*>(elem->channel_data);
   if (server_->ShutdownCalled()) {
-    state_.Store(CallState::ZOMBIED, MemoryOrder::RELAXED);
+    state_.store(CallState::ZOMBIED, std::memory_order_relaxed);
     KillZombie();
     return;
   }
index 7061c42..ab41300 100644 (file)
@@ -19,6 +19,7 @@
 
 #include <grpc/support/port_platform.h>
 
+#include <atomic>
 #include <list>
 #include <vector>
 
@@ -31,7 +32,6 @@
 #include "src/core/lib/channel/channel_stack.h"
 #include "src/core/lib/channel/channelz.h"
 #include "src/core/lib/debug/trace.h"
-#include "src/core/lib/gprpp/atomic.h"
 #include "src/core/lib/iomgr/resolve_address.h"
 #include "src/core/lib/surface/completion_queue.h"
 #include "src/core/lib/transport/transport.h"
@@ -97,9 +97,6 @@ class Server : public InternallyRefCounted<Server> {
   void Orphan() ABSL_LOCKS_EXCLUDED(mu_global_) override;
 
   const grpc_channel_args* channel_args() const { return channel_args_; }
-  grpc_resource_user* default_resource_user() const {
-    return default_resource_user_;
-  }
   channelz::ServerNode* channelz_node() const { return channelz_node_.get(); }
 
   // Do not call this before Start(). Returns the pollsets. The
@@ -128,11 +125,13 @@ class Server : public InternallyRefCounted<Server> {
 
   // Sets up a transport.  Creates a channel stack and binds the transport to
   // the server.  Called from the listener when a new connection is accepted.
+  // Takes ownership of a ref on resource_user from the caller.
   grpc_error_handle SetupTransport(
       grpc_transport* transport, grpc_pollset* accepting_pollset,
       const grpc_channel_args* args,
       const RefCountedPtr<channelz::SocketNode>& socket_node,
-      grpc_resource_user* resource_user = nullptr);
+      grpc_resource_user* resource_user = nullptr,
+      size_t preallocated_bytes = 0);
 
   void RegisterCompletionQueue(grpc_completion_queue* cq);
 
@@ -289,7 +288,7 @@ class Server : public InternallyRefCounted<Server> {
 
     grpc_call* call_;
 
-    Atomic<CallState> state_{CallState::NOT_STARTED};
+    std::atomic<CallState> state_{CallState::NOT_STARTED};
 
     absl::optional<grpc_slice> path_;
     absl::optional<grpc_slice> host_;
@@ -367,7 +366,7 @@ class Server : public InternallyRefCounted<Server> {
   // Take a shutdown ref for a request (increment by 2) and return if shutdown
   // has already been called.
   bool ShutdownRefOnRequest() {
-    int old_value = shutdown_refs_.FetchAdd(2, MemoryOrder::ACQ_REL);
+    int old_value = shutdown_refs_.fetch_add(2, std::memory_order_acq_rel);
     return (old_value & 1) != 0;
   }
 
@@ -375,30 +374,29 @@ class Server : public InternallyRefCounted<Server> {
   // (for in-flight request) and possibly call MaybeFinishShutdown if
   // appropriate.
   void ShutdownUnrefOnRequest() ABSL_LOCKS_EXCLUDED(mu_global_) {
-    if (shutdown_refs_.FetchSub(2, MemoryOrder::ACQ_REL) == 2) {
+    if (shutdown_refs_.fetch_sub(2, std::memory_order_acq_rel) == 2) {
       MutexLock lock(&mu_global_);
       MaybeFinishShutdown();
     }
   }
   void ShutdownUnrefOnShutdownCall() ABSL_EXCLUSIVE_LOCKS_REQUIRED(mu_global_) {
-    if (shutdown_refs_.FetchSub(1, MemoryOrder::ACQ_REL) == 1) {
+    if (shutdown_refs_.fetch_sub(1, std::memory_order_acq_rel) == 1) {
       MaybeFinishShutdown();
     }
   }
 
   bool ShutdownCalled() const {
-    return (shutdown_refs_.Load(MemoryOrder::ACQUIRE) & 1) == 0;
+    return (shutdown_refs_.load(std::memory_order_acquire) & 1) == 0;
   }
 
   // Returns whether there are no more shutdown refs, which means that shutdown
   // has been called and all accepted requests have been published if using an
   // AllocatingRequestMatcher.
   bool ShutdownReady() const {
-    return shutdown_refs_.Load(MemoryOrder::ACQUIRE) == 0;
+    return shutdown_refs_.load(std::memory_order_acquire) == 0;
   }
 
   grpc_channel_args* const channel_args_;
-  grpc_resource_user* default_resource_user_ = nullptr;
   RefCountedPtr<channelz::ServerNode> channelz_node_;
   std::unique_ptr<grpc_server_config_fetcher> config_fetcher_;
 
@@ -432,7 +430,7 @@ class Server : public InternallyRefCounted<Server> {
   // the lowest bit will be 0 (defaults to 1) and the counter will be even. The
   // server should not notify on shutdown until the counter is 0 (shutdown is
   // called and there are no requests that are accepted but not started).
-  Atomic<int> shutdown_refs_{1};
+  std::atomic<int> shutdown_refs_{1};
   bool shutdown_published_ ABSL_GUARDED_BY(mu_global_) = false;
   std::vector<ShutdownTag> shutdown_tags_ ABSL_GUARDED_BY(mu_global_);
 
index c1ec936..1f16ec2 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
+#include "src/core/lib/surface/validate_metadata.h"
+
 #include <stdlib.h>
 #include <string.h>
 
 #include <grpc/grpc.h>
 #include <grpc/support/alloc.h>
 
+#include "src/core/lib/gprpp/bitset.h"
 #include "src/core/lib/gprpp/memory.h"
 #include "src/core/lib/iomgr/error.h"
 #include "src/core/lib/slice/slice_internal.h"
 #include "src/core/lib/slice/slice_string_helpers.h"
-#include "src/core/lib/surface/validate_metadata.h"
+
+#if __cplusplus > 201103l
+#define GRPC_VALIDATE_METADATA_CONSTEXPR_FN constexpr
+#define GRPC_VALIDATE_METADATA_CONSTEXPR_VALUE constexpr
+#else
+#define GRPC_VALIDATE_METADATA_CONSTEXPR_FN
+#define GRPC_VALIDATE_METADATA_CONSTEXPR_VALUE const
+#endif
 
 static grpc_error_handle conforms_to(const grpc_slice& slice,
-                                     const uint8_t* legal_bits,
+                                     const grpc_core::BitSet<256>& legal_bits,
                                      const char* err_desc) {
   const uint8_t* p = GRPC_SLICE_START_PTR(slice);
   const uint8_t* e = GRPC_SLICE_END_PTR(slice);
   for (; p != e; p++) {
-    int idx = *p;
-    int byte = idx / 8;
-    int bit = idx % 8;
-    if ((legal_bits[byte] & (1 << bit)) == 0) {
+    if (!legal_bits.is_set(*p)) {
       grpc_error_handle error = grpc_error_set_str(
           grpc_error_set_int(GRPC_ERROR_CREATE_FROM_COPIED_STRING(err_desc),
                              GRPC_ERROR_INT_OFFSET,
@@ -58,11 +65,22 @@ static int error2int(grpc_error_handle error) {
   return r;
 }
 
+namespace {
+class LegalHeaderKeyBits : public grpc_core::BitSet<256> {
+ public:
+  GRPC_VALIDATE_METADATA_CONSTEXPR_FN LegalHeaderKeyBits() {
+    for (int i = 'a'; i <= 'z'; i++) set(i);
+    for (int i = '0'; i <= '9'; i++) set(i);
+    set('-');
+    set('_');
+    set('.');
+  }
+};
+static GRPC_VALIDATE_METADATA_CONSTEXPR_VALUE LegalHeaderKeyBits
+    g_legal_header_key_bits;
+}  // namespace
+
 grpc_error_handle grpc_validate_header_key_is_legal(const grpc_slice& slice) {
-  static const uint8_t legal_header_bits[256 / 8] = {
-      0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0xff, 0x03, 0x00, 0x00, 0x00,
-      0x80, 0xfe, 0xff, 0xff, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-      0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00};
   if (GRPC_SLICE_LENGTH(slice) == 0) {
     return GRPC_ERROR_CREATE_FROM_STATIC_STRING(
         "Metadata keys cannot be zero length");
@@ -75,20 +93,30 @@ grpc_error_handle grpc_validate_header_key_is_legal(const grpc_slice& slice) {
     return GRPC_ERROR_CREATE_FROM_STATIC_STRING(
         "Metadata keys cannot start with :");
   }
-  return conforms_to(slice, legal_header_bits, "Illegal header key");
+  return conforms_to(slice, g_legal_header_key_bits, "Illegal header key");
 }
 
 int grpc_header_key_is_legal(grpc_slice slice) {
   return error2int(grpc_validate_header_key_is_legal(slice));
 }
 
+namespace {
+class LegalHeaderNonBinValueBits : public grpc_core::BitSet<256> {
+ public:
+  GRPC_VALIDATE_METADATA_CONSTEXPR_FN LegalHeaderNonBinValueBits() {
+    for (int i = 32; i <= 126; i++) {
+      set(i);
+    }
+  }
+};
+static GRPC_VALIDATE_METADATA_CONSTEXPR_VALUE LegalHeaderNonBinValueBits
+    g_legal_header_non_bin_value_bits;
+}  // namespace
+
 grpc_error_handle grpc_validate_header_nonbin_value_is_legal(
     const grpc_slice& slice) {
-  static const uint8_t legal_header_bits[256 / 8] = {
-      0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
-      0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-      0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00};
-  return conforms_to(slice, legal_header_bits, "Illegal header value");
+  return conforms_to(slice, g_legal_header_non_bin_value_bits,
+                     "Illegal header value");
 }
 
 int grpc_header_nonbin_value_is_legal(grpc_slice slice) {
index 683b436..07f1fbc 100644 (file)
@@ -23,6 +23,6 @@
 
 #include <grpc/grpc.h>
 
-const char* grpc_version_string(void) { return "18.0.0"; }
+const char* grpc_version_string(void) { return "19.0.0"; }
 
-const char* grpc_g_stands_for(void) { return "guileless"; }
+const char* grpc_g_stands_for(void) { return "goat"; }
index 09a3032..28dd443 100644 (file)
@@ -22,6 +22,7 @@
 #include <grpc/support/port_platform.h>
 
 #include <grpc/slice_buffer.h>
+
 #include "src/core/lib/gprpp/orphanable.h"
 #include "src/core/lib/iomgr/closure.h"
 
index 01a4f5c..ffad92e 100644 (file)
@@ -101,7 +101,8 @@ void AsyncConnectivityStateWatcherInterface::Notify(
 //
 
 ConnectivityStateTracker::~ConnectivityStateTracker() {
-  grpc_connectivity_state current_state = state_.Load(MemoryOrder::RELAXED);
+  grpc_connectivity_state current_state =
+      state_.load(std::memory_order_relaxed);
   if (current_state == GRPC_CHANNEL_SHUTDOWN) return;
   for (const auto& p : watchers_) {
     if (GRPC_TRACE_FLAG_ENABLED(grpc_connectivity_state_trace)) {
@@ -121,7 +122,8 @@ void ConnectivityStateTracker::AddWatcher(
     gpr_log(GPR_INFO, "ConnectivityStateTracker %s[%p]: add watcher %p", name_,
             this, watcher.get());
   }
-  grpc_connectivity_state current_state = state_.Load(MemoryOrder::RELAXED);
+  grpc_connectivity_state current_state =
+      state_.load(std::memory_order_relaxed);
   if (initial_state != current_state) {
     if (GRPC_TRACE_FLAG_ENABLED(grpc_connectivity_state_trace)) {
       gpr_log(GPR_INFO,
@@ -150,14 +152,15 @@ void ConnectivityStateTracker::RemoveWatcher(
 void ConnectivityStateTracker::SetState(grpc_connectivity_state state,
                                         const absl::Status& status,
                                         const char* reason) {
-  grpc_connectivity_state current_state = state_.Load(MemoryOrder::RELAXED);
+  grpc_connectivity_state current_state =
+      state_.load(std::memory_order_relaxed);
   if (state == current_state) return;
   if (GRPC_TRACE_FLAG_ENABLED(grpc_connectivity_state_trace)) {
     gpr_log(GPR_INFO, "ConnectivityStateTracker %s[%p]: %s -> %s (%s, %s)",
             name_, this, ConnectivityStateName(current_state),
             ConnectivityStateName(state), reason, status.ToString().c_str());
   }
-  state_.Store(state, MemoryOrder::RELAXED);
+  state_.store(state, std::memory_order_relaxed);
   status_ = status;
   for (const auto& p : watchers_) {
     if (GRPC_TRACE_FLAG_ENABLED(grpc_connectivity_state_trace)) {
@@ -174,7 +177,7 @@ void ConnectivityStateTracker::SetState(grpc_connectivity_state state,
 }
 
 grpc_connectivity_state ConnectivityStateTracker::state() const {
-  grpc_connectivity_state state = state_.Load(MemoryOrder::RELAXED);
+  grpc_connectivity_state state = state_.load(std::memory_order_relaxed);
   if (GRPC_TRACE_FLAG_ENABLED(grpc_connectivity_state_trace)) {
     gpr_log(GPR_INFO, "ConnectivityStateTracker %s[%p]: get current state: %s",
             name_, this, ConnectivityStateName(state));
index 3417311..8c866a3 100644 (file)
@@ -21,6 +21,7 @@
 
 #include <grpc/support/port_platform.h>
 
+#include <atomic>
 #include <map>
 #include <memory>
 
@@ -29,7 +30,6 @@
 #include <grpc/grpc.h>
 
 #include "src/core/lib/debug/trace.h"
-#include "src/core/lib/gprpp/atomic.h"
 #include "src/core/lib/gprpp/orphanable.h"
 #include "src/core/lib/iomgr/closure.h"
 #include "src/core/lib/iomgr/exec_ctx.h"
@@ -131,7 +131,7 @@ class ConnectivityStateTracker {
 
  private:
   const char* name_;
-  Atomic<grpc_connectivity_state> state_;
+  std::atomic<grpc_connectivity_state> state_{grpc_connectivity_state()};
   absl::Status status_;
   // TODO(roth): Once we can use C++-14 heterogeneous lookups, this can
   // be a set instead of a map.
index 2d75a56..a826b91 100644 (file)
@@ -21,6 +21,7 @@
 #include "src/core/lib/transport/error_utils.h"
 
 #include <grpc/support/string_util.h>
+
 #include "src/core/lib/iomgr/error_internal.h"
 #include "src/core/lib/slice/slice_internal.h"
 #include "src/core/lib/transport/status_conversion.h"
index ef1e07d..5b19eb8 100644 (file)
@@ -145,10 +145,10 @@ AllocatedMetadata::AllocatedMetadata(
 AllocatedMetadata::~AllocatedMetadata() {
   grpc_slice_unref_internal(key());
   grpc_slice_unref_internal(value());
-  void* user_data = user_data_.data.Load(grpc_core::MemoryOrder::RELAXED);
+  void* user_data = user_data_.data.load(std::memory_order_relaxed);
   if (user_data) {
     destroy_user_data_func destroy_user_data =
-        user_data_.destroy_user_data.Load(grpc_core::MemoryOrder::RELAXED);
+        user_data_.destroy_user_data.load(std::memory_order_relaxed);
     destroy_user_data(user_data);
   }
 }
@@ -189,10 +189,10 @@ InternedMetadata::InternedMetadata(const grpc_slice& key,
 InternedMetadata::~InternedMetadata() {
   grpc_slice_unref_internal(key());
   grpc_slice_unref_internal(value());
-  void* user_data = user_data_.data.Load(grpc_core::MemoryOrder::RELAXED);
+  void* user_data = user_data_.data.load(std::memory_order_relaxed);
   if (user_data) {
     destroy_user_data_func destroy_user_data =
-        user_data_.destroy_user_data.Load(grpc_core::MemoryOrder::RELAXED);
+        user_data_.destroy_user_data.load(std::memory_order_relaxed);
     destroy_user_data(user_data);
   }
 }
@@ -560,9 +560,9 @@ grpc_mdelem grpc_mdelem_from_grpc_metadata(grpc_metadata* metadata) {
 }
 
 static void* get_user_data(UserData* user_data, void (*destroy_func)(void*)) {
-  if (user_data->destroy_user_data.Load(grpc_core::MemoryOrder::ACQUIRE) ==
+  if (user_data->destroy_user_data.load(std::memory_order_acquire) ==
       destroy_func) {
-    return user_data->data.Load(grpc_core::MemoryOrder::RELAXED);
+    return user_data->data.load(std::memory_order_relaxed);
   } else {
     return nullptr;
   }
@@ -594,16 +594,16 @@ static void* set_user_data(UserData* ud, void (*destroy_func)(void*),
                            void* data) {
   GPR_ASSERT((data == nullptr) == (destroy_func == nullptr));
   grpc_core::ReleasableMutexLock lock(&ud->mu_user_data);
-  if (ud->destroy_user_data.Load(grpc_core::MemoryOrder::RELAXED)) {
+  if (ud->destroy_user_data.load(std::memory_order_relaxed)) {
     /* user data can only be set once */
     lock.Release();
     if (destroy_func != nullptr) {
       destroy_func(data);
     }
-    return ud->data.Load(grpc_core::MemoryOrder::RELAXED);
+    return ud->data.load(std::memory_order_relaxed);
   }
-  ud->data.Store(data, grpc_core::MemoryOrder::RELAXED);
-  ud->destroy_user_data.Store(destroy_func, grpc_core::MemoryOrder::RELEASE);
+  ud->data.store(data, std::memory_order_relaxed);
+  ud->destroy_user_data.store(destroy_func, std::memory_order_release);
   return data;
 }
 
index e6de4ea..5d83cbb 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include <grpc/impl/codegen/log.h>
+#include <atomic>
 
 #include <grpc/grpc.h>
+#include <grpc/impl/codegen/log.h>
 #include <grpc/slice.h>
 
 #include "src/core/lib/debug/trace.h"
 #include "src/core/lib/gpr/useful.h"
-#include "src/core/lib/gprpp/atomic.h"
 #include "src/core/lib/gprpp/sync.h"
 #include "src/core/lib/slice/slice_utils.h"
 
@@ -203,8 +203,8 @@ typedef void (*destroy_user_data_func)(void* data);
 
 struct UserData {
   Mutex mu_user_data;
-  grpc_core::Atomic<destroy_user_data_func> destroy_user_data;
-  grpc_core::Atomic<void*> data;
+  std::atomic<destroy_user_data_func> destroy_user_data{nullptr};
+  std::atomic<void*> data{nullptr};
 };
 
 class StaticMetadata {
@@ -241,7 +241,7 @@ class RefcountedMdBase {
 #ifndef NDEBUG
   void Ref(const char* file, int line) {
     grpc_mdelem_trace_ref(this, key_, value_, RefValue(), file, line);
-    const intptr_t prior = refcnt_.FetchAdd(1, MemoryOrder::RELAXED);
+    const intptr_t prior = refcnt_.fetch_add(1, std::memory_order_relaxed);
     GPR_ASSERT(prior > 0);
   }
   bool Unref(const char* file, int line) {
@@ -253,10 +253,10 @@ class RefcountedMdBase {
     /* we can assume the ref count is >= 1 as the application is calling
        this function - meaning that no adjustment to mdtab_free is necessary,
        simplifying the logic here to be just an atomic increment */
-    refcnt_.FetchAdd(1, MemoryOrder::RELAXED);
+    refcnt_.fetch_add(1, std::memory_order_relaxed);
   }
   bool Unref() {
-    const intptr_t prior = refcnt_.FetchSub(1, MemoryOrder::ACQ_REL);
+    const intptr_t prior = refcnt_.fetch_sub(1, std::memory_order_acq_rel);
     GPR_DEBUG_ASSERT(prior > 0);
     return prior == 1;
   }
@@ -266,15 +266,17 @@ class RefcountedMdBase {
   void TraceAtStart(const char* tag);
 #endif
 
-  intptr_t RefValue() { return refcnt_.Load(MemoryOrder::RELAXED); }
-  bool AllRefsDropped() { return refcnt_.Load(MemoryOrder::ACQUIRE) == 0; }
-  bool FirstRef() { return refcnt_.FetchAdd(1, MemoryOrder::RELAXED) == 0; }
+  intptr_t RefValue() { return refcnt_.load(std::memory_order_relaxed); }
+  bool AllRefsDropped() { return refcnt_.load(std::memory_order_acquire) == 0; }
+  bool FirstRef() {
+    return refcnt_.fetch_add(1, std::memory_order_relaxed) == 0;
+  }
 
  private:
   /* must be byte compatible with grpc_mdelem_data */
   grpc_slice key_;
   grpc_slice value_;
-  grpc_core::Atomic<intptr_t> refcnt_;
+  std::atomic<intptr_t> refcnt_{0};
   uint32_t hash_ = 0;
 };
 
index 986d030..028bf52 100644 (file)
@@ -57,6 +57,14 @@ typedef struct grpc_metadata_batch {
       or GRPC_MILLIS_INF_FUTURE if this batch does not need to send a
       grpc-timeout */
   grpc_millis deadline;
+
+  template <typename Encoder>
+  void Encode(Encoder* encoder) const {
+    for (auto* l = list.head; l; l = l->next) {
+      encoder->Encode(l->md);
+    }
+    if (deadline != GRPC_MILLIS_INF_FUTURE) encoder->EncodeDeadline(deadline);
+  }
 } grpc_metadata_batch;
 
 void grpc_metadata_batch_init(grpc_metadata_batch* batch);
index 0285ac0..449141d 100644 (file)
@@ -18,8 +18,6 @@
 
 #include <grpc/support/port_platform.h>
 
-#include "src/core/lib/channel/channel_stack.h"
-
 #include <inttypes.h>
 #include <stdarg.h>
 #include <stdio.h>
@@ -33,6 +31,8 @@
 
 #include <grpc/support/alloc.h>
 #include <grpc/support/string_util.h>
+
+#include "src/core/lib/channel/channel_stack.h"
 #include "src/core/lib/gpr/string.h"
 #include "src/core/lib/slice/slice_string_helpers.h"
 #include "src/core/lib/transport/connectivity_state.h"
index 271b010..6a790f3 100644 (file)
@@ -20,6 +20,8 @@
 
 #include <grpc/grpc.h>
 
+#include "src/core/lib/config/core_configuration.h"
+
 void grpc_http_filters_init(void);
 void grpc_http_filters_shutdown(void);
 void grpc_chttp2_plugin_init(void);
@@ -160,3 +162,15 @@ void grpc_register_built_in_plugins(void) {
                        grpc_core::GoogleCloud2ProdResolverShutdown);
 #endif
 }
+
+namespace grpc_core {
+
+extern void BuildClientChannelConfiguration(CoreConfiguration::Builder* builder);
+extern void SecurityRegisterHandshakerFactories(CoreConfiguration::Builder* builder);
+
+void BuildCoreConfiguration(CoreConfiguration::Builder* builder) {
+  BuildClientChannelConfiguration(builder);
+  SecurityRegisterHandshakerFactories(builder);
+}
+
+}  // namespace grpc_core
index b58ab32..86edc86 100644 (file)
@@ -20,6 +20,8 @@
 
 #include <grpc/grpc.h>
 
+#include "src/core/lib/config/core_configuration.h"
+
 void grpc_http_filters_init(void);
 void grpc_http_filters_shutdown(void);
 void grpc_chttp2_plugin_init(void);
@@ -113,3 +115,13 @@ void grpc_register_built_in_plugins(void) {
   grpc_register_plugin(grpc_workaround_cronet_compression_filter_init,
                        grpc_workaround_cronet_compression_filter_shutdown);
 }
+
+namespace grpc_core {
+
+extern void BuildClientChannelConfiguration(CoreConfiguration::Builder* builder);
+
+void BuildCoreConfiguration(CoreConfiguration::Builder* builder) {
+  BuildClientChannelConfiguration(builder);
+}
+
+}
index 02b1ac4..b761224 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include "src/core/tsi/alts/crypt/gsec.h"
+#include <string.h>
 
 #include <openssl/bio.h>
 #include <openssl/buffer.h>
 #include <openssl/err.h>
 #include <openssl/evp.h>
 #include <openssl/hmac.h>
-#include <string.h>
 
 #include <grpc/support/alloc.h>
 
+#include "src/core/tsi/alts/crypt/gsec.h"
+
 constexpr size_t kKdfKeyLen = 32;
 constexpr size_t kKdfCounterLen = 6;
 constexpr size_t kKdfCounterOffset = 2;
index f7d1cda..11b2154 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include <grpc/event_engine/port.h>
-
 #include <assert.h>
 #include <stdint.h>
 #include <stdlib.h>
 
+#include <grpc/event_engine/port.h>
 #include <grpc/grpc.h>
 
 #ifndef _STRUCT_IOVEC
-#ifndef GRPC_EVENT_ENGINE_POSIX
+#if !defined(GRPC_EVENT_ENGINE_POSIX)
 struct iovec {
   void* iov_base;
   size_t iov_len;
index ed70d81..2e335ab 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include <list>
-
 #include "src/core/tsi/alts/handshaker/alts_handshaker_client.h"
 
+#include <list>
+
 #include "upb/upb.hpp"
 
 #include <grpc/byte_buffer.h>
index d8669da..133cea5 100644 (file)
 #include <grpc/byte_buffer_reader.h>
 #include <grpc/grpc.h>
 
-#include "src/core/tsi/alts/handshaker/alts_tsi_handshaker.h"
-#include "src/core/tsi/transport_security_interface.h"
-
 #include "src/core/lib/iomgr/closure.h"
 #include "src/core/lib/iomgr/pollset_set.h"
+#include "src/core/tsi/alts/handshaker/alts_tsi_handshaker.h"
+#include "src/core/tsi/transport_security_interface.h"
 
 #define ALTS_SERVICE_METHOD "/grpc.gcp.HandshakerService/DoHandshake"
 #define ALTS_APPLICATION_PROTOCOL "grpc"
index 352561d..67cdd99 100644 (file)
 
 #include "src/core/tsi/alts/zero_copy_frame_protector/alts_grpc_integrity_only_record_protocol.h"
 
+#include <string.h>
+
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 
-#include <string.h>
-
 #include "src/core/lib/slice/slice_internal.h"
 #include "src/core/tsi/alts/zero_copy_frame_protector/alts_grpc_record_protocol_common.h"
 #include "src/core/tsi/alts/zero_copy_frame_protector/alts_iovec_record_protocol.h"
index 9254dce..15fd6fd 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include "src/core/lib/gprpp/sync.h"
-#include "src/core/lib/slice/slice_internal.h"
-#include "src/core/tsi/ssl/session_cache/ssl_session.h"
 #include "src/core/tsi/ssl/session_cache/ssl_session_cache.h"
 
 #include <grpc/support/log.h>
 #include <grpc/support/string_util.h>
 
+#include "src/core/lib/gprpp/sync.h"
+#include "src/core/lib/slice/slice_internal.h"
+#include "src/core/tsi/ssl/session_cache/ssl_session.h"
+
 namespace tsi {
 
 static void cache_key_avl_destroy(void* /*key*/, void* /*unused*/) {}
index f45205c..60675d2 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include "src/core/tsi/ssl/session_cache/ssl_session.h"
-
 #include <grpc/support/log.h>
 
+#include "src/core/tsi/ssl/session_cache/ssl_session.h"
+
 #ifndef OPENSSL_IS_BORINGSSL
 
 // OpenSSL invalidates SSL_SESSION on SSL destruction making it pointless
index 4241b6f..b687207 100644 (file)
@@ -35,6 +35,9 @@
 
 #include <string>
 
+#include "absl/strings/match.h"
+#include "absl/strings/string_view.h"
+
 #include <grpc/grpc_security.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
@@ -42,9 +45,6 @@
 #include <grpc/support/sync.h>
 #include <grpc/support/thd_id.h>
 
-#include "absl/strings/match.h"
-#include "absl/strings/string_view.h"
-
 extern "C" {
 #include <openssl/bio.h>
 #include <openssl/crypto.h> /* For OPENSSL_free */
@@ -503,10 +503,10 @@ static void log_ssl_error_stack(void) {
 /* Performs an SSL_read and handle errors. */
 static tsi_result do_ssl_read(SSL* ssl, unsigned char* unprotected_bytes,
                               size_t* unprotected_bytes_size) {
-  int read_from_ssl;
   GPR_ASSERT(*unprotected_bytes_size <= INT_MAX);
-  read_from_ssl = SSL_read(ssl, unprotected_bytes,
-                           static_cast<int>(*unprotected_bytes_size));
+  ERR_clear_error();
+  int read_from_ssl = SSL_read(ssl, unprotected_bytes,
+                               static_cast<int>(*unprotected_bytes_size));
   if (read_from_ssl <= 0) {
     read_from_ssl = SSL_get_error(ssl, read_from_ssl);
     switch (read_from_ssl) {
@@ -536,10 +536,10 @@ static tsi_result do_ssl_read(SSL* ssl, unsigned char* unprotected_bytes,
 /* Performs an SSL_write and handle errors. */
 static tsi_result do_ssl_write(SSL* ssl, unsigned char* unprotected_bytes,
                                size_t unprotected_bytes_size) {
-  int ssl_write_result;
   GPR_ASSERT(unprotected_bytes_size <= INT_MAX);
-  ssl_write_result = SSL_write(ssl, unprotected_bytes,
-                               static_cast<int>(unprotected_bytes_size));
+  ERR_clear_error();
+  int ssl_write_result = SSL_write(ssl, unprotected_bytes,
+                                   static_cast<int>(unprotected_bytes_size));
   if (ssl_write_result < 0) {
     ssl_write_result = SSL_get_error(ssl, ssl_write_result);
     if (ssl_write_result == SSL_ERROR_WANT_READ) {
@@ -1449,6 +1449,7 @@ static tsi_result ssl_handshaker_process_bytes_from_peer(
     impl->result = TSI_OK;
     return impl->result;
   } else {
+    ERR_clear_error();
     /* Get ready to get some bytes from SSL. */
     int ssl_result = SSL_do_handshake(impl->ssl);
     ssl_result = SSL_get_error(impl->ssl, ssl_result);
@@ -1645,6 +1646,7 @@ static tsi_result create_tsi_ssl_handshaker(SSL_CTX* ctx, int is_client,
       tsi_ssl_handshaker_resume_session(ssl,
                                         client_factory->session_cache.get());
     }
+    ERR_clear_error();
     ssl_result = SSL_do_handshake(ssl);
     ssl_result = SSL_get_error(ssl, ssl_result);
     if (ssl_result != SSL_ERROR_WANT_READ) {
index c3d30a8..3711db0 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include <grpc/grpc_security_constants.h>
 #include "absl/strings/string_view.h"
+
+#include <grpc/grpc_security_constants.h>
+
 #include "src/core/tsi/transport_security_interface.h"
 
 extern "C" {
index dd62189..f08093d 100644 (file)
 
 #include "src/core/tsi/transport_security.h"
 
-#include <grpc/support/alloc.h>
-#include <grpc/support/string_util.h>
-
 #include <stdlib.h>
 #include <string.h>
 
+#include <grpc/support/alloc.h>
+#include <grpc/support/string_util.h>
+
 /* --- Tracing. --- */
 
 grpc_core::TraceFlag tsi_tracing_enabled(false, "tsi");
index 4779b68..ba9428b 100644 (file)
@@ -22,6 +22,7 @@
 #include <grpc/support/port_platform.h>
 
 #include <grpc/slice_buffer.h>
+
 #include "src/core/tsi/transport_security.h"
 
 /* This method creates a tsi_zero_copy_grpc_protector object. It return TSI_OK
index 7da2377..7565d95 100644 (file)
@@ -1,6 +1,6 @@
 Pod::Spec.new do |s|
   s.name     = 'Protobuf-C++'
-  s.version  = '3.15.8'
+  s.version  = '3.17.3'
   s.summary  = 'Protocol Buffers v3 runtime library for C++.'
   s.homepage = 'https://github.com/protocolbuffers/protobuf'
   s.license  = '3-Clause BSD License'
index 4b357a7..e4bd449 100755 (executable)
@@ -9,6 +9,24 @@ This section describes how to add gRPC as a dependency to your C++ project.
 In the C++ world, there's no universally accepted standard for managing project dependencies.
 Therefore, gRPC supports several major build systems, which should satisfy most users.
 
+## Supported Platforms
+
+* Supported: These platforms are officially supported. We test our code on these
+platform and have automated continuous integration tests for them.
+
+* Best Effort: We do not have continous integration tests for these, but we are fairly confident that gRPC C++ would work on them.
+We will make our best effort to support them, and we welcome patches for such platforms, but we might need to declare bankruptcy on some issues.
+
+| Operating System | Architectures | Versions | Support Level |
+|------------------|---------------|----------|---------------|
+| Linux - Debian, Ubuntu, CentOS | x86, x64      | clang 3.4+, GCC 4.9+   | Supported |
+| Windows 10+                    | x86, x64      | Visual Studio 2015+    | Supported |
+| MacOS                          | x86, x64      | XCode 7.2+             | Supported |
+| Linux - Others                 | x86, x64      | clang 3.4+, GCC 4.9+   | Best Effort |
+| Linux                          | ARM           |                        | Best Effort |
+| iOS                            |               |                        | Best Effort |
+| Android                        |               |                        | Best Effort |
+
 ## Bazel
 
 Bazel is the primary build system used by the core gRPC development team. Bazel
index a96e4d1..1702dc5 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include <grpcpp/channel.h>
-
 #include <cstring>
 #include <memory>
 
@@ -27,6 +25,7 @@
 #include <grpc/support/log.h>
 #include <grpc/support/sync.h>
 #include <grpc/support/time.h>
+#include <grpcpp/channel.h>
 #include <grpcpp/client_context.h>
 #include <grpcpp/completion_queue.h>
 #include <grpcpp/impl/call.h>
index f921352..e55f522 100644 (file)
  *
  */
 
-#include <grpcpp/test/channel_test_peer.h>
-
 #include <grpc/support/sync.h>
 #include <grpcpp/channel.h>
+#include <grpcpp/test/channel_test_peer.h>
 
 #include "src/core/lib/surface/channel.h"
 
index 4d35cce..d7a37f7 100644 (file)
  *
  */
 
-#include <grpcpp/client_context.h>
-
 #include <grpc/compression.h>
 #include <grpc/grpc.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/string_util.h>
-
+#include <grpcpp/client_context.h>
 #include <grpcpp/impl/codegen/interceptor_common.h>
 #include <grpcpp/impl/codegen/sync.h>
 #include <grpcpp/impl/grpc_library.h>
index 466d524..f90836a 100644 (file)
@@ -16,6 +16,8 @@
  *
  */
 
+#include "src/cpp/client/create_channel_internal.h"
+
 #include <memory>
 #include <string>
 #include <utility>
@@ -23,8 +25,6 @@
 
 #include <grpcpp/channel.h>
 
-#include "src/cpp/client/create_channel_internal.h"
-
 struct grpc_channel;
 
 namespace grpc {
index d09e284..4ef8113 100644 (file)
  *
  */
 
-#include <grpcpp/security/credentials.h>
-
 #include <grpc/grpc_cronet.h>
 #include <grpcpp/channel.h>
+#include <grpcpp/security/credentials.h>
 #include <grpcpp/support/channel_arguments.h>
+
 #include "src/cpp/client/create_channel_internal.h"
 
 namespace grpc {
index 98e8cb7..57c0e77 100644 (file)
  * limitations under the License.
  *
  */
-#include <grpcpp/security/credentials.h>
-
 #include <grpc/grpc.h>
 #include <grpc/support/log.h>
 #include <grpcpp/channel.h>
+#include <grpcpp/security/credentials.h>
 #include <grpcpp/support/channel_arguments.h>
 #include <grpcpp/support/config.h>
+
 #include "src/cpp/client/create_channel_internal.h"
 
 namespace grpc {
index e743165..3a3b04a 100644 (file)
@@ -18,6 +18,8 @@
 
 #include "src/cpp/client/secure_credentials.h"
 
+#include "absl/strings/str_join.h"
+
 #include <grpc/impl/codegen/slice.h>
 #include <grpc/slice.h>
 #include <grpc/support/alloc.h>
@@ -28,8 +30,6 @@
 #include <grpcpp/impl/grpc_library.h>
 #include <grpcpp/support/channel_arguments.h>
 
-#include "absl/strings/str_join.h"
-
 // TODO(yashykt): We shouldn't be including "src/core" headers.
 #include "src/core/lib/gpr/env.h"
 #include "src/core/lib/iomgr/error.h"
index 318c402..b3bde23 100644 (file)
 #ifndef GRPC_INTERNAL_CPP_CLIENT_SECURE_CREDENTIALS_H
 #define GRPC_INTERNAL_CPP_CLIENT_SECURE_CREDENTIALS_H
 
-#include <grpc/grpc_security.h>
+#include "absl/strings/str_cat.h"
 
+#include <grpc/grpc_security.h>
 #include <grpcpp/security/credentials.h>
 #include <grpcpp/security/tls_credentials_options.h>
 #include <grpcpp/support/config.h>
-
-#include "absl/strings/str_cat.h"
 // TODO(yashykt): We shouldn't be including "src/core" headers.
 #include "src/core/lib/security/credentials/credentials.h"
 #include "src/cpp/server/thread_pool_interface.h"
index 63b4883..d5446a0 100644 (file)
@@ -19,7 +19,6 @@
 #include "src/cpp/client/secure_credentials.h"
 
 namespace grpc {
-namespace experimental {
 
 std::shared_ptr<ChannelCredentials> XdsCredentials(
     const std::shared_ptr<ChannelCredentials>& fallback_creds) {
@@ -37,5 +36,12 @@ std::shared_ptr<ChannelCredentials> XdsCredentials(
   }
 }
 
+namespace experimental {
+
+std::shared_ptr<ChannelCredentials> XdsCredentials(
+    const std::shared_ptr<ChannelCredentials>& fallback_creds) {
+  return grpc::XdsCredentials(fallback_creds);
+}
+
 }  // namespace experimental
 }  // namespace grpc
index 10d633c..a367b53 100644 (file)
  *
  */
 
-#include <grpcpp/alarm.h>
+#include <grpc/support/port_platform.h>
 
 #include <memory>
 
 #include <grpc/support/log.h>
-#include <grpc/support/port_platform.h>
+#include <grpcpp/alarm.h>
 #include <grpcpp/completion_queue.h>
 #include <grpcpp/impl/grpc_library.h>
 #include <grpcpp/support/time.h>
+
+#include "src/core/lib/debug/trace.h"
 #include "src/core/lib/iomgr/exec_ctx.h"
 #include "src/core/lib/iomgr/executor.h"
 #include "src/core/lib/iomgr/timer.h"
 #include "src/core/lib/surface/completion_queue.h"
 
-#include <grpc/support/log.h>
-#include "src/core/lib/debug/trace.h"
-
 namespace grpc {
 
 namespace internal {
index 0f380b0..1334ea9 100644 (file)
@@ -16,9 +16,8 @@
  *
  */
 
-#include <grpcpp/security/auth_context.h>
-
 #include <grpc/grpc_security.h>
+#include <grpcpp/security/auth_context.h>
 
 namespace grpc {
 
index 2eb2809..6c45dda 100644 (file)
  * limitations under the License.
  *
  */
-#include <grpcpp/support/channel_arguments.h>
-
 #include <sstream>
 
 #include <grpc/impl/codegen/grpc_types.h>
 #include <grpc/support/log.h>
 #include <grpcpp/grpcpp.h>
 #include <grpcpp/resource_quota.h>
+#include <grpcpp/support/channel_arguments.h>
+
 #include "src/core/lib/channel/channel_args.h"
 #include "src/core/lib/iomgr/exec_ctx.h"
 #include "src/core/lib/iomgr/socket_mutator.h"
index ab56d60..6d3a055 100644 (file)
  *
  */
 
-#include <string.h>
-
-#include "src/core/lib/channel/channel_stack.h"
 #include "src/cpp/common/channel_filter.h"
 
+#include <string.h>
+
 #include <grpcpp/impl/codegen/slice.h>
 
+#include "src/core/lib/channel/channel_stack.h"
+
 namespace grpc {
 
 // MetadataBatch
index d588056..87f38af 100644 (file)
 #ifndef GRPCXX_CHANNEL_FILTER_H
 #define GRPCXX_CHANNEL_FILTER_H
 
+#include <functional>
+#include <vector>
+
 #include <grpc/grpc.h>
 #include <grpc/support/alloc.h>
 #include <grpcpp/impl/codegen/config.h>
 
-#include <functional>
-#include <vector>
-
 #include "src/core/lib/channel/channel_stack.h"
 #include "src/core/lib/surface/channel_init.h"
 #include "src/core/lib/transport/metadata_batch.h"
@@ -56,48 +56,6 @@ class MetadataBatch {
   /// lifetime of the gRPC call.
   grpc_linked_mdelem* AddMetadata(const string& key, const string& value);
 
-  class const_iterator : public std::iterator<std::bidirectional_iterator_tag,
-                                              const grpc_mdelem> {
-   public:
-    const grpc_mdelem& operator*() const { return elem_->md; }
-    grpc_mdelem operator->() const { return elem_->md; }
-
-    const_iterator& operator++() {
-      elem_ = elem_->next;
-      return *this;
-    }
-    const_iterator operator++(int) {
-      const_iterator tmp(*this);
-      operator++();
-      return tmp;
-    }
-    const_iterator& operator--() {
-      elem_ = elem_->prev;
-      return *this;
-    }
-    const_iterator operator--(int) {
-      const_iterator tmp(*this);
-      operator--();
-      return tmp;
-    }
-
-    bool operator==(const const_iterator& other) const {
-      return elem_ == other.elem_;
-    }
-    bool operator!=(const const_iterator& other) const {
-      return elem_ != other.elem_;
-    }
-
-   private:
-    friend class MetadataBatch;
-    explicit const_iterator(grpc_linked_mdelem* elem) : elem_(elem) {}
-
-    grpc_linked_mdelem* elem_;
-  };
-
-  const_iterator begin() const { return const_iterator(batch_->list.head); }
-  const_iterator end() const { return const_iterator(nullptr); }
-
  private:
   grpc_metadata_batch* batch_;  // Not owned.
 };
index cdf36b8..42494f7 100644 (file)
  *
  */
 
-#include <grpcpp/completion_queue.h>
-
 #include <memory>
 
 #include <grpc/grpc.h>
 #include <grpc/support/cpu.h>
 #include <grpc/support/log.h>
+#include <grpcpp/completion_queue.h>
 #include <grpcpp/impl/grpc_library.h>
 #include <grpcpp/support/time.h>
 
index 75383ed..e35b1dd 100644 (file)
@@ -16,7 +16,7 @@
  *
  */
 
-#include <grpcpp/impl/codegen/core_codegen.h>
+#include <grpc/support/port_platform.h>
 
 #include <stdlib.h>
 
@@ -27,8 +27,8 @@
 #include <grpc/slice_buffer.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
-#include <grpc/support/port_platform.h>
 #include <grpc/support/sync.h>
+#include <grpcpp/impl/codegen/core_codegen.h>
 #include <grpcpp/support/config.h>
 
 #include "src/core/lib/profiling/timers.h"
index 471c23f..339d94b 100644 (file)
@@ -16,9 +16,9 @@
  *
  */
 
+#include <grpc/grpc_security.h>
 #include <grpcpp/support/channel_arguments.h>
 
-#include <grpc/grpc_security.h>
 #include "src/core/lib/channel/channel_args.h"
 
 namespace grpc {
index 908c466..6633374 100644 (file)
@@ -20,6 +20,7 @@
 #include <grpc/grpc.h>
 #include <grpc/grpc_security.h>
 #include <grpcpp/security/auth_context.h>
+
 #include "src/core/lib/gprpp/ref_counted_ptr.h"
 #include "src/cpp/common/secure_auth_context.h"
 
index 2deea5f..62a2a5c 100644 (file)
 // limitations under the License.
 //
 
+#include "absl/container/inlined_vector.h"
+
 #include <grpc/grpc_security.h>
 #include <grpc/support/alloc.h>
 #include <grpcpp/security/tls_certificate_provider.h>
 
-#include "absl/container/inlined_vector.h"
-
 namespace grpc {
 namespace experimental {
 
index 729e6a4..8e67230 100644 (file)
  *
  */
 
+#include "absl/container/inlined_vector.h"
+
 #include <grpc/grpc_security.h>
 #include <grpc/support/alloc.h>
 #include <grpcpp/security/tls_credentials_options.h>
 
-#include "absl/container/inlined_vector.h"
 #include "src/cpp/common/tls_credentials_options_util.h"
 
 namespace grpc {
index 1cea450..ebcab26 100644 (file)
  *
  */
 
+#include "src/cpp/common/tls_credentials_options_util.h"
+
 #include "absl/container/inlined_vector.h"
 
 #include <grpcpp/security/tls_credentials_options.h>
 
-#include "src/cpp/common/tls_credentials_options_util.h"
-
 namespace grpc {
 namespace experimental {
 
index 8248a1c..101d1c8 100644 (file)
@@ -22,5 +22,5 @@
 #include <grpcpp/grpcpp.h>
 
 namespace grpc {
-std::string Version() { return "1.40.0"; }
+std::string Version() { return "1.41.0"; }
 }  // namespace grpc
index 362ea52..bb332a8 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
+#include "src/cpp/ext/filters/census/client_filter.h"
+
 #include <string>
 #include <utility>
 #include <vector>
 
-#include "src/cpp/ext/filters/census/client_filter.h"
-
 #include "absl/strings/str_cat.h"
 #include "absl/strings/string_view.h"
 #include "opencensus/stats/stats.h"
 #include "opencensus/tags/context_util.h"
 #include "opencensus/tags/tag_key.h"
 #include "opencensus/tags/tag_map.h"
+
 #include "src/core/lib/surface/call.h"
 #include "src/cpp/ext/filters/census/grpc_plugin.h"
 #include "src/cpp/ext/filters/census/measures.h"
index ea90cad..1c08f7d 100644 (file)
@@ -23,6 +23,7 @@
 
 #include "absl/strings/string_view.h"
 #include "absl/time/time.h"
+
 #include "src/cpp/ext/filters/census/channel_filter.h"
 #include "src/cpp/ext/filters/census/open_census_call_tracer.h"
 
index 0650bd1..672228a 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
+#include "src/cpp/ext/filters/census/context.h"
+
 #include "opencensus/tags/context_util.h"
 #include "opencensus/trace/context_util.h"
 #include "opencensus/trace/propagation/grpc_trace_bin.h"
-#include "src/cpp/ext/filters/census/context.h"
 
 namespace grpc {
 
index 668e5ec..4519204 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include <grpc/status.h>
-
 #include "absl/memory/memory.h"
 #include "absl/strings/string_view.h"
 #include "absl/strings/strip.h"
-
 #include "opencensus/context/context.h"
 #include "opencensus/tags/tag_map.h"
 #include "opencensus/trace/context_util.h"
@@ -34,6 +31,8 @@
 #include "opencensus/trace/span_context.h"
 #include "opencensus/trace/trace_params.h"
 
+#include <grpc/status.h>
+
 #include "src/core/lib/slice/slice_internal.h"
 #include "src/cpp/common/channel_filter.h"
 #include "src/cpp/ext/filters/census/rpc_encoding.h"
index f16eb52..41ded5c 100644 (file)
 
 #include "src/cpp/ext/filters/census/grpc_plugin.h"
 
-#include <grpcpp/server_context.h>
-
 #include "opencensus/tags/tag_key.h"
 #include "opencensus/trace/span.h"
+
+#include <grpcpp/server_context.h>
+
 #include "src/cpp/ext/filters/census/channel_filter.h"
 #include "src/cpp/ext/filters/census/client_filter.h"
 #include "src/cpp/ext/filters/census/measures.h"
index 83c135b..54754aa 100644 (file)
 #include <grpc/support/port_platform.h>
 
 #include "absl/strings/string_view.h"
-#include "include/grpcpp/opencensus.h"
 #include "opencensus/stats/stats.h"
 #include "opencensus/tags/tag_key.h"
 
+#include <grpcpp/opencensus.h>
+
 namespace grpc {
 
 // The tag keys set when recording RPC stats.
index f8a6508..c02fdce 100644 (file)
@@ -21,6 +21,7 @@
 #include "src/cpp/ext/filters/census/measures.h"
 
 #include "opencensus/stats/stats.h"
+
 #include "src/cpp/ext/filters/census/grpc_plugin.h"
 
 namespace grpc {
index 2a95cb7..0682f2e 100644 (file)
@@ -22,6 +22,7 @@
 #include <grpc/support/port_platform.h>
 
 #include "opencensus/stats/stats.h"
+
 #include "src/cpp/ext/filters/census/grpc_plugin.h"
 
 namespace grpc {
index 72ee8e1..fa606b8 100644 (file)
@@ -25,6 +25,7 @@
 #include "absl/time/clock.h"
 #include "absl/time/time.h"
 #include "opencensus/stats/stats.h"
+
 #include "src/core/lib/surface/call.h"
 #include "src/cpp/ext/filters/census/grpc_plugin.h"
 #include "src/cpp/ext/filters/census/measures.h"
index 81bec8f..3359c49 100644 (file)
@@ -24,7 +24,9 @@
 #include "absl/strings/string_view.h"
 #include "absl/time/clock.h"
 #include "absl/time/time.h"
-#include "include/grpc/grpc_security.h"
+
+#include <grpc/grpc_security.h>
+
 #include "src/cpp/ext/filters/census/channel_filter.h"
 #include "src/cpp/ext/filters/census/context.h"
 
index cd552a9..926e842 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include "src/cpp/ext/filters/census/grpc_plugin.h"
-
 #include "absl/time/time.h"
 #include "opencensus/stats/internal/aggregation_window.h"
 #include "opencensus/stats/internal/set_aggregation_window.h"
 #include "opencensus/stats/stats.h"
 
+#include "src/cpp/ext/filters/census/grpc_plugin.h"
+
 namespace grpc {
 
 using ::opencensus::stats::Aggregation;
index 336465a..af35a28 100644 (file)
  *
  */
 
+#include "src/cpp/ext/proto_server_reflection.h"
+
 #include <unordered_set>
 #include <vector>
 
 #include <grpcpp/grpcpp.h>
 
-#include "src/cpp/ext/proto_server_reflection.h"
-
 using grpc::Status;
 using grpc::StatusCode;
 using grpc::reflection::v1alpha::ErrorResponse;
index 31e386f..04f1e63 100644 (file)
@@ -23,6 +23,7 @@
 #include <vector>
 
 #include <grpcpp/grpcpp.h>
+
 #include "src/proto/grpc/reflection/v1alpha/reflection.grpc.pb.h"
 
 namespace grpc {
index 5159b3a..7e8841e 100644 (file)
@@ -22,7 +22,6 @@
 
 #include <grpcpp/ext/admin_services.h>
 #include <grpcpp/impl/server_builder_plugin.h>
-
 #include <grpcpp/server_builder.h>
 
 // TODO(lidiz) build a real registration system that can pull in services
index 07697a5..fdb3da8 100644 (file)
@@ -17,7 +17,6 @@
  */
 
 #include <grpcpp/generic/async_generic_service.h>
-
 #include <grpcpp/server.h>
 
 namespace grpc {
index b4a66ba..824f0a9 100644 (file)
@@ -22,6 +22,7 @@
 #include <grpc/support/port_platform.h>
 
 #include <grpcpp/grpcpp.h>
+
 #include "src/proto/grpc/channelz/channelz.grpc.pb.h"
 
 namespace grpc {
index fc8e7e0..61de376 100644 (file)
 
 #include "src/cpp/server/csds/csds.h"
 
+#include <string>
+
 #include "absl/status/statusor.h"
 
 #include <grpc/grpc.h>
 #include <grpc/support/alloc.h>
 #include <grpcpp/impl/codegen/slice.h>
 
-#include <string>
-
 #include "src/proto/grpc/testing/xds/v3/csds.grpc.pb.h"
 
 namespace grpc {
index be2a4aa..d08e152 100644 (file)
 #define GRPC_INTERNAL_CPP_SERVER_CSDS_H
 
 #include <grpc/support/port_platform.h>
-#include <grpcpp/grpcpp.h>
+
 #include "absl/status/status.h"
 
+#include <grpcpp/grpcpp.h>
+
 #include "src/proto/grpc/testing/xds/v3/csds.grpc.pb.h"
 
 namespace grpc {
index 42c55c5..dd638e6 100644 (file)
@@ -16,6 +16,8 @@
  *
  */
 
+#include "src/cpp/server/health/default_health_check_service.h"
+
 #include <memory>
 
 #include "absl/memory/memory.h"
@@ -26,9 +28,7 @@
 #include <grpc/support/log.h>
 #include <grpcpp/impl/codegen/method_handler.h>
 
-#include "src/cpp/server/health/default_health_check_service.h"
 #include "src/proto/grpc/health/v1/health.upb.h"
-#include "upb/upb.hpp"
 
 #define MAX_SERVICE_NAME_LENGTH 200
 
index 4c1cec0..10da4b9 100644 (file)
  *
  */
 
-#include <grpcpp/security/server_credentials.h>
-
 #include <grpc/grpc.h>
 #include <grpc/support/log.h>
+#include <grpcpp/security/server_credentials.h>
 
 namespace grpc {
 namespace {
index 0a98e84..c03dadd 100644 (file)
@@ -21,6 +21,7 @@
 #ifdef GPR_WINDOWS
 
 #include <windows.h>
+
 #include <cstdint>
 
 #include "src/cpp/server/load_reporter/get_cpu_stats.h"
index 003192c..9a65c3e 100644 (file)
 
 #include <grpc/impl/codegen/port_platform.h>
 
+#include "src/cpp/server/load_reporter/load_data_store.h"
+
 #include <stdio.h>
+
 #include <cstdlib>
 #include <set>
 #include <unordered_map>
 #include <vector>
 
 #include "src/core/lib/iomgr/socket_utils.h"
-#include "src/cpp/server/load_reporter/load_data_store.h"
 
 namespace grpc {
 namespace load_reporter {
index 613cf3a..df0ac09 100644 (file)
 
 #include <grpc/impl/codegen/port_platform.h>
 
+#include "src/cpp/server/load_reporter/load_reporter.h"
+
 #include <inttypes.h>
 #include <stdint.h>
 #include <stdio.h>
+
 #include <chrono>
 #include <ctime>
 #include <iterator>
 
-#include "src/cpp/server/load_reporter/constants.h"
-#include "src/cpp/server/load_reporter/get_cpu_stats.h"
-#include "src/cpp/server/load_reporter/load_reporter.h"
-
 #include "opencensus/stats/internal/set_aggregation_window.h"
 #include "opencensus/tags/tag_key.h"
 
+#include "src/cpp/server/load_reporter/constants.h"
+#include "src/cpp/server/load_reporter/get_cpu_stats.h"
+
 namespace grpc {
 namespace load_reporter {
 
index f8b1123..e83e146 100644 (file)
@@ -26,6 +26,9 @@
 #include <deque>
 #include <vector>
 
+#include "opencensus/stats/stats.h"
+#include "opencensus/tags/tag_key.h"
+
 #include <grpc/support/log.h>
 #include <grpcpp/impl/codegen/config.h>
 
@@ -33,9 +36,6 @@
 #include "src/cpp/server/load_reporter/load_data_store.h"
 #include "src/proto/grpc/lb/v1/load_reporter.grpc.pb.h"
 
-#include "opencensus/stats/stats.h"
-#include "opencensus/tags/tag_key.h"
-
 namespace grpc {
 namespace load_reporter {
 
index e2a14ef..7c9465b 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
+#include "src/cpp/server/load_reporter/load_reporter_async_service_impl.h"
+
 #include <inttypes.h>
 
 #include "absl/memory/memory.h"
 
-#include "src/cpp/server/load_reporter/load_reporter_async_service_impl.h"
-
 namespace grpc {
 namespace load_reporter {
 
index 4f05a5b..75be7f1 100644 (file)
 
 #include <grpc/impl/codegen/port_platform.h>
 
-#include <grpcpp/ext/server_load_reporting.h>
-
 #include <cmath>
 
 #include <grpc/support/log.h>
+#include <grpcpp/ext/server_load_reporting.h>
 
 namespace grpc {
 namespace load_reporter {
index 53c9236..b69ee52 100644 (file)
@@ -16,6 +16,8 @@
  *
  */
 
+#include "src/cpp/server/secure_server_credentials.h"
+
 #include <functional>
 #include <map>
 #include <memory>
@@ -25,7 +27,6 @@
 #include <grpcpp/security/auth_metadata_processor.h>
 
 #include "src/cpp/common/secure_auth_context.h"
-#include "src/cpp/server/secure_server_credentials.h"
 
 namespace grpc {
 
index 730abdb..6a74fd9 100644 (file)
 
 #include <memory>
 
+#include <grpc/grpc_security.h>
 #include <grpcpp/security/server_credentials.h>
 #include <grpcpp/security/tls_credentials_options.h>
 
-#include <grpc/grpc_security.h>
-
 #include "src/cpp/server/thread_pool_interface.h"
 
 namespace grpc {
index af30879..4519eb0 100644 (file)
  *
  */
 
-#include <grpcpp/server_builder.h>
+#include <utility>
 
 #include <grpc/support/cpu.h>
 #include <grpc/support/log.h>
 #include <grpcpp/impl/service_type.h>
 #include <grpcpp/resource_quota.h>
 #include <grpcpp/server.h>
-
-#include <utility>
+#include <grpcpp/server_builder.h>
 
 #include "src/core/lib/channel/channel_args.h"
 #include "src/core/lib/gpr/string.h"
index efa12aa..ebfbc9e 100644 (file)
  *
  */
 
-#include <grpcpp/server.h>
-
 #include <cstdlib>
 #include <sstream>
 #include <type_traits>
 #include <utility>
 
+#include "absl/memory/memory.h"
+
 #include <grpc/grpc.h>
 #include <grpc/impl/codegen/grpc_types.h>
 #include <grpc/support/alloc.h>
 #include <grpcpp/impl/server_initializer.h>
 #include <grpcpp/impl/service_type.h>
 #include <grpcpp/security/server_credentials.h>
+#include <grpcpp/server.h>
 #include <grpcpp/server_context.h>
 #include <grpcpp/support/time.h>
 
-#include "absl/memory/memory.h"
-
 #include "src/core/ext/transport/inproc/inproc_transport.h"
 #include "src/core/lib/gprpp/manual_constructor.h"
 #include "src/core/lib/iomgr/exec_ctx.h"
index 4df3ea5..43a98b4 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include <grpcpp/impl/codegen/server_context.h>
-
 #include <algorithm>
 #include <atomic>
 #include <utility>
@@ -29,6 +27,7 @@
 #include <grpc/support/log.h>
 #include <grpcpp/impl/call.h>
 #include <grpcpp/impl/codegen/completion_queue.h>
+#include <grpcpp/impl/codegen/server_context.h>
 #include <grpcpp/impl/grpc_library.h>
 #include <grpcpp/support/server_callback.h>
 #include <grpcpp/support/time.h>
index 36b5a52..454e8b4 100644 (file)
@@ -16,9 +16,8 @@
  *
  */
 
-#include <grpcpp/security/server_credentials.h>
-
 #include <grpcpp/impl/grpc_library.h>
+#include <grpcpp/security/server_credentials.h>
 
 namespace grpc {
 
index c3d40d4..f2452cc 100644 (file)
@@ -16,9 +16,8 @@
  *
  */
 
-#include <grpcpp/server_posix.h>
-
 #include <grpc/grpc_posix.h>
+#include <grpcpp/server_posix.h>
 
 namespace grpc {
 
index b543f3f..f184238 100644 (file)
@@ -19,7 +19,6 @@
 #include "src/cpp/server/secure_server_credentials.h"
 
 namespace grpc {
-namespace experimental {
 
 std::shared_ptr<ServerCredentials> XdsServerCredentials(
     const std::shared_ptr<ServerCredentials>& fallback_credentials) {
@@ -37,5 +36,12 @@ std::shared_ptr<ServerCredentials> XdsServerCredentials(
           fallback_credentials->AsSecureServerCredentials()->c_creds()));
 }
 
+namespace experimental {
+
+std::shared_ptr<ServerCredentials> XdsServerCredentials(
+    const std::shared_ptr<ServerCredentials>& fallback_credentials) {
+  return grpc::XdsServerCredentials(fallback_credentials);
+}
+
 }  // namespace experimental
 }  // namespace grpc
index 5155f61..d257ae8 100644 (file)
@@ -21,6 +21,7 @@
 #include <climits>
 
 #include <grpc/support/log.h>
+
 #include "src/core/lib/gprpp/thd.h"
 #include "src/core/lib/iomgr/exec_ctx.h"
 
@@ -58,7 +59,8 @@ ThreadManager::ThreadManager(const char* name,
       max_pollers_(max_pollers == -1 ? INT_MAX : max_pollers),
       num_threads_(0),
       max_active_threads_sofar_(0) {
-  resource_user_ = grpc_resource_user_create(resource_quota, name);
+  resource_user_ =
+      grpc_resource_user_create(resource_quota, name != nullptr ? name : "");
 }
 
 ThreadManager::~ThreadManager() {
index 6366d7d..358de90 100644 (file)
@@ -19,9 +19,8 @@
 #ifndef GRPC_INTERNAL_CPP_UTIL_CORE_STATS_H
 #define GRPC_INTERNAL_CPP_UTIL_CORE_STATS_H
 
-#include "src/proto/grpc/core/stats.pb.h"
-
 #include "src/core/lib/debug/stats.h"
+#include "src/proto/grpc/core/stats.pb.h"
 
 namespace grpc {
 
index b40cbef..8997565 100644 (file)
@@ -33,11 +33,11 @@ namespace Grpc.Core
         /// <summary>
         /// Current <c>AssemblyFileVersion</c> of gRPC C# assemblies
         /// </summary>
-        public const string CurrentAssemblyFileVersion = "2.40.0.0";
+        public const string CurrentAssemblyFileVersion = "2.41.0.0";
 
         /// <summary>
         /// Current version of gRPC C#
         /// </summary>
-        public const string CurrentVersion = "2.40.0";
+        public const string CurrentVersion = "2.41.0";
     }
 }
index 78c7f3a..e337f90 100644 (file)
@@ -410,6 +410,22 @@ namespace Grpc.Core.Internal.Tests
             // try alternative order of completions
             fakeCall.ReceivedStatusOnClientCallback.OnReceivedStatusOnClient(true, new ClientSideStatus(Status.DefaultSuccess, new Metadata()));
             fakeCall.ReceivedMessageCallback.OnReceivedMessage(true, CreateNullResponse());
+            fakeCall.ReceivedResponseHeadersCallback.OnReceivedResponseHeaders(true, new Metadata());
+
+            AssertStreamingResponseSuccess(asyncCall, fakeCall, readTask);
+        }
+
+        [Test]
+        public void ServerStreaming_NoResponse_Success3()
+        {
+            asyncCall.StartServerStreamingCall("request1");
+            var responseStream = new ClientResponseStream<string, string>(asyncCall);
+            var readTask = responseStream.MoveNext();
+
+            // try alternative order of completions
+            fakeCall.ReceivedStatusOnClientCallback.OnReceivedStatusOnClient(true, new ClientSideStatus(Status.DefaultSuccess, new Metadata()));
+            fakeCall.ReceivedResponseHeadersCallback.OnReceivedResponseHeaders(true, new Metadata());
+            fakeCall.ReceivedMessageCallback.OnReceivedMessage(true, CreateNullResponse());
 
             AssertStreamingResponseSuccess(asyncCall, fakeCall, readTask);
         }
@@ -421,6 +437,9 @@ namespace Grpc.Core.Internal.Tests
             var responseStream = new ClientResponseStream<string, string>(asyncCall);
             var readTask = responseStream.MoveNext();
 
+            fakeCall.ReceivedResponseHeadersCallback.OnReceivedResponseHeaders(true, new Metadata());
+            Assert.AreEqual(0, asyncCall.ResponseHeadersAsync.Result.Count);
+
             fakeCall.ReceivedMessageCallback.OnReceivedMessage(false, CreateNullResponse());  // after a failed read, we rely on C core to deliver appropriate status code.
             fakeCall.ReceivedStatusOnClientCallback.OnReceivedStatusOnClient(true, CreateClientSideStatus(StatusCode.Internal));
 
@@ -433,6 +452,9 @@ namespace Grpc.Core.Internal.Tests
             asyncCall.StartServerStreamingCall("request1");
             var responseStream = new ClientResponseStream<string, string>(asyncCall);
 
+            fakeCall.ReceivedResponseHeadersCallback.OnReceivedResponseHeaders(true, new Metadata());
+            Assert.AreEqual(0, asyncCall.ResponseHeadersAsync.Result.Count);
+
             var readTask1 = responseStream.MoveNext();
             fakeCall.ReceivedMessageCallback.OnReceivedMessage(true, CreateResponsePayload());
             Assert.IsTrue(readTask1.Result);
@@ -472,12 +494,15 @@ namespace Grpc.Core.Internal.Tests
         }
 
         [Test]
-        public void DuplexStreaming_NoRequestNoResponse_Success()
+        public void DuplexStreaming_NoRequestNoResponse_Success1()
         {
             asyncCall.StartDuplexStreamingCall();
             var requestStream = new ClientRequestStream<string, string>(asyncCall);
             var responseStream = new ClientResponseStream<string, string>(asyncCall);
 
+            fakeCall.ReceivedResponseHeadersCallback.OnReceivedResponseHeaders(true, new Metadata());
+            Assert.AreEqual(0, asyncCall.ResponseHeadersAsync.Result.Count);
+
             var writeTask1 = requestStream.CompleteAsync();
             fakeCall.SendCompletionCallback.OnSendCompletion(true);
             Assert.DoesNotThrowAsync(async () => await writeTask1);
@@ -490,12 +515,36 @@ namespace Grpc.Core.Internal.Tests
         }
 
         [Test]
+        public void DuplexStreaming_NoRequestNoResponse_Success2()
+        {
+            asyncCall.StartDuplexStreamingCall();
+            var requestStream = new ClientRequestStream<string, string>(asyncCall);
+            var responseStream = new ClientResponseStream<string, string>(asyncCall);
+
+            var writeTask1 = requestStream.CompleteAsync();
+            fakeCall.SendCompletionCallback.OnSendCompletion(true);
+            Assert.DoesNotThrowAsync(async () => await writeTask1);
+
+            var readTask = responseStream.MoveNext();
+            fakeCall.ReceivedMessageCallback.OnReceivedMessage(true, CreateNullResponse());
+            fakeCall.ReceivedStatusOnClientCallback.OnReceivedStatusOnClient(true, new ClientSideStatus(Status.DefaultSuccess, new Metadata()));
+
+            fakeCall.ReceivedResponseHeadersCallback.OnReceivedResponseHeaders(true, new Metadata());
+            Assert.AreEqual(0, asyncCall.ResponseHeadersAsync.Result.Count);
+
+            AssertStreamingResponseSuccess(asyncCall, fakeCall, readTask);
+        }
+
+        [Test]
         public void DuplexStreaming_WriteAfterReceivingStatusThrowsRpcException()
         {
             asyncCall.StartDuplexStreamingCall();
             var requestStream = new ClientRequestStream<string, string>(asyncCall);
             var responseStream = new ClientResponseStream<string, string>(asyncCall);
 
+            fakeCall.ReceivedResponseHeadersCallback.OnReceivedResponseHeaders(true, new Metadata());
+            Assert.AreEqual(0, asyncCall.ResponseHeadersAsync.Result.Count);
+
             var readTask = responseStream.MoveNext();
             fakeCall.ReceivedMessageCallback.OnReceivedMessage(true, CreateNullResponse());
             fakeCall.ReceivedStatusOnClientCallback.OnReceivedStatusOnClient(true, new ClientSideStatus(Status.DefaultSuccess, new Metadata()));
@@ -514,6 +563,9 @@ namespace Grpc.Core.Internal.Tests
             var requestStream = new ClientRequestStream<string, string>(asyncCall);
             var responseStream = new ClientResponseStream<string, string>(asyncCall);
 
+            fakeCall.ReceivedResponseHeadersCallback.OnReceivedResponseHeaders(true, new Metadata());
+            Assert.AreEqual(0, asyncCall.ResponseHeadersAsync.Result.Count);
+
             var readTask = responseStream.MoveNext();
             fakeCall.ReceivedMessageCallback.OnReceivedMessage(true, CreateNullResponse());
             fakeCall.ReceivedStatusOnClientCallback.OnReceivedStatusOnClient(true, new ClientSideStatus(Status.DefaultSuccess, new Metadata()));
@@ -530,6 +582,9 @@ namespace Grpc.Core.Internal.Tests
             var requestStream = new ClientRequestStream<string, string>(asyncCall);
             var responseStream = new ClientResponseStream<string, string>(asyncCall);
 
+            fakeCall.ReceivedResponseHeadersCallback.OnReceivedResponseHeaders(true, new Metadata());
+            Assert.AreEqual(0, asyncCall.ResponseHeadersAsync.Result.Count);
+
             var writeTask = requestStream.WriteAsync("request1");
             fakeCall.SendCompletionCallback.OnSendCompletion(false);
 
@@ -553,6 +608,9 @@ namespace Grpc.Core.Internal.Tests
             var requestStream = new ClientRequestStream<string, string>(asyncCall);
             var responseStream = new ClientResponseStream<string, string>(asyncCall);
 
+            fakeCall.ReceivedResponseHeadersCallback.OnReceivedResponseHeaders(true, new Metadata());
+            Assert.AreEqual(0, asyncCall.ResponseHeadersAsync.Result.Count);
+
             var writeTask = requestStream.WriteAsync("request1");
 
             var readTask = responseStream.MoveNext();
@@ -573,6 +631,9 @@ namespace Grpc.Core.Internal.Tests
             var requestStream = new ClientRequestStream<string, string>(asyncCall);
             var responseStream = new ClientResponseStream<string, string>(asyncCall);
 
+            fakeCall.ReceivedResponseHeadersCallback.OnReceivedResponseHeaders(true, new Metadata());
+            Assert.AreEqual(0, asyncCall.ResponseHeadersAsync.Result.Count);
+
             asyncCall.Cancel();
             Assert.IsTrue(fakeCall.IsCancelled);
 
@@ -592,6 +653,9 @@ namespace Grpc.Core.Internal.Tests
             asyncCall.StartDuplexStreamingCall();
             var responseStream = new ClientResponseStream<string, string>(asyncCall);
 
+            fakeCall.ReceivedResponseHeadersCallback.OnReceivedResponseHeaders(true, new Metadata());
+            Assert.AreEqual(0, asyncCall.ResponseHeadersAsync.Result.Count);
+
             asyncCall.Cancel();
             Assert.IsTrue(fakeCall.IsCancelled);
 
@@ -613,6 +677,9 @@ namespace Grpc.Core.Internal.Tests
             asyncCall.StartDuplexStreamingCall();
             var responseStream = new ClientResponseStream<string, string>(asyncCall);
 
+            fakeCall.ReceivedResponseHeadersCallback.OnReceivedResponseHeaders(true, new Metadata());
+            Assert.AreEqual(0, asyncCall.ResponseHeadersAsync.Result.Count);
+
             var readTask1 = responseStream.MoveNext();  // initiate the read before cancel request
             asyncCall.Cancel();
             Assert.IsTrue(fakeCall.IsCancelled);
index 6a7466a..500842f 100644 (file)
@@ -236,6 +236,7 @@ namespace Grpc.Core.Internal
                     Initialize(details.Channel.CompletionQueue);
 
                     halfcloseRequested = true;
+                    receiveResponseHeadersPending = true;
 
                     using (var serializationScope = DefaultSerializationContext.GetInitializedThreadLocalScope())
                     {
@@ -272,6 +273,7 @@ namespace Grpc.Core.Internal
                 {
                     GrpcPreconditions.CheckState(!started);
                     started = true;
+                    receiveResponseHeadersPending = true;
 
                     Initialize(details.Channel.CompletionQueue);
 
@@ -531,6 +533,19 @@ namespace Grpc.Core.Internal
         private void HandleReceivedResponseHeaders(bool success, Metadata responseHeaders)
         {
             // TODO(jtattermusch): handle success==false
+
+            bool releasedResources;
+            lock (myLock)
+            {
+                receiveResponseHeadersPending = false;
+                releasedResources = ReleaseResourcesIfPossible();
+            }
+
+            if (releasedResources)
+            {
+                OnAfterReleaseResourcesUnlocked();
+            }
+
             responseHeadersTcs.SetResult(responseHeaders);
         }
 
index 252fe11..e5d30e9 100644 (file)
@@ -62,6 +62,7 @@ namespace Grpc.Core.Internal
 
         protected bool initialMetadataSent;
         protected long streamingWritesCounter;  // Number of streaming send operations started so far.
+        protected bool receiveResponseHeadersPending;  // True if this is a call with streaming response and the recv_initial_metadata_on_client operation hasn't finished yet.
 
         public AsyncCallBase(Action<TWrite, SerializationContext> serializer, Func<DeserializationContext, TRead> deserializer)
         {
@@ -171,7 +172,7 @@ namespace Grpc.Core.Internal
             if (!disposed && call != null)
             {
                 bool noMoreSendCompletions = streamingWriteTcs == null && (halfcloseRequested || cancelRequested || finished);
-                if (noMoreSendCompletions && readingDone && finished)
+                if (noMoreSendCompletions && readingDone && finished && !receiveResponseHeadersPending)
                 {
                     ReleaseResources();
                     return true;
index 577b11a..c275559 100644 (file)
@@ -134,9 +134,19 @@ namespace Grpc.Core.Internal
         {
             if (PlatformApis.IsWindows)
             {
-                // TODO(jtattermusch): populate the error on Windows
                 errorMsg = null;
-                return Windows.LoadLibrary(libraryPath);
+                var handle = Windows.LoadLibrary(libraryPath);
+                if (handle == IntPtr.Zero)
+                {
+                    int win32Error = Marshal.GetLastWin32Error();
+                    errorMsg = $"LoadLibrary failed with error {win32Error}";
+                    // add extra info for the most common error ERROR_MOD_NOT_FOUND
+                    if (win32Error == 126)
+                    {
+                        errorMsg += ": The specified module could not be found.";
+                    }
+                }
+                return handle;
             }
             if (PlatformApis.IsLinux)
             {
@@ -179,13 +189,13 @@ namespace Grpc.Core.Internal
                 }
             }
             throw new FileNotFoundException(
-                String.Format("Error loading native library. Not found in any of the possible locations: {0}", 
+                String.Format("Error loading native library. Not found in any of the possible locations: {0}",
                     string.Join(",", libraryPathAlternatives)));
         }
 
         private static class Windows
         {
-            [DllImport("kernel32.dll")]
+            [DllImport("kernel32.dll", CharSet = CharSet.Unicode, SetLastError = true)]
             internal static extern IntPtr LoadLibrary(string filename);
 
             [DllImport("kernel32.dll")]
index 3f33b9f..ef44f65 100644 (file)
       <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
       <Link>grpc_csharp_ext.x86.dll</Link>
       <Visible>false</Visible>
+      <NuGetPackageId>Grpc.Core</NuGetPackageId>
     </Content>
     <Content Include="$(MSBuildThisFileDirectory)..\..\runtimes\win-x64\native\grpc_csharp_ext.x64.dll">
       <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
       <Link>grpc_csharp_ext.x64.dll</Link>
       <Visible>false</Visible>
+      <NuGetPackageId>Grpc.Core</NuGetPackageId>
     </Content>
     <Content Include="$(MSBuildThisFileDirectory)..\..\runtimes\linux-x64\native\libgrpc_csharp_ext.x64.so">
       <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
       <Link>libgrpc_csharp_ext.x64.so</Link>
       <Visible>false</Visible>
+      <NuGetPackageId>Grpc.Core</NuGetPackageId>
     </Content>
     <Content Include="$(MSBuildThisFileDirectory)..\..\runtimes\osx-x64\native\libgrpc_csharp_ext.x64.dylib">
       <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
       <Link>libgrpc_csharp_ext.x64.dylib</Link>
       <Visible>false</Visible>
+      <NuGetPackageId>Grpc.Core</NuGetPackageId>
     </Content>
   </ItemGroup>
 </Project>
index 4eadc1c..0eece85 100644 (file)
@@ -55,19 +55,23 @@ namespace Math {
     private static readonly pb::MessageParser<DivArgs> _parser = new pb::MessageParser<DivArgs>(() => new DivArgs());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<DivArgs> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Math.MathReflection.Descriptor.MessageTypes[0]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public DivArgs() {
       OnConstruction();
     }
@@ -75,6 +79,7 @@ namespace Math {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public DivArgs(DivArgs other) : this() {
       dividend_ = other.dividend_;
       divisor_ = other.divisor_;
@@ -82,6 +87,7 @@ namespace Math {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public DivArgs Clone() {
       return new DivArgs(this);
     }
@@ -90,6 +96,7 @@ namespace Math {
     public const int DividendFieldNumber = 1;
     private long dividend_;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public long Dividend {
       get { return dividend_; }
       set {
@@ -101,6 +108,7 @@ namespace Math {
     public const int DivisorFieldNumber = 2;
     private long divisor_;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public long Divisor {
       get { return divisor_; }
       set {
@@ -109,11 +117,13 @@ namespace Math {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as DivArgs);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(DivArgs other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -127,6 +137,7 @@ namespace Math {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (Dividend != 0L) hash ^= Dividend.GetHashCode();
@@ -138,11 +149,13 @@ namespace Math {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -163,6 +176,7 @@ namespace Math {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (Dividend != 0L) {
         output.WriteRawTag(8);
@@ -179,6 +193,7 @@ namespace Math {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (Dividend != 0L) {
@@ -194,6 +209,7 @@ namespace Math {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(DivArgs other) {
       if (other == null) {
         return;
@@ -208,6 +224,7 @@ namespace Math {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -233,6 +250,7 @@ namespace Math {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -263,19 +281,23 @@ namespace Math {
     private static readonly pb::MessageParser<DivReply> _parser = new pb::MessageParser<DivReply>(() => new DivReply());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<DivReply> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Math.MathReflection.Descriptor.MessageTypes[1]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public DivReply() {
       OnConstruction();
     }
@@ -283,6 +305,7 @@ namespace Math {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public DivReply(DivReply other) : this() {
       quotient_ = other.quotient_;
       remainder_ = other.remainder_;
@@ -290,6 +313,7 @@ namespace Math {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public DivReply Clone() {
       return new DivReply(this);
     }
@@ -298,6 +322,7 @@ namespace Math {
     public const int QuotientFieldNumber = 1;
     private long quotient_;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public long Quotient {
       get { return quotient_; }
       set {
@@ -309,6 +334,7 @@ namespace Math {
     public const int RemainderFieldNumber = 2;
     private long remainder_;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public long Remainder {
       get { return remainder_; }
       set {
@@ -317,11 +343,13 @@ namespace Math {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as DivReply);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(DivReply other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -335,6 +363,7 @@ namespace Math {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (Quotient != 0L) hash ^= Quotient.GetHashCode();
@@ -346,11 +375,13 @@ namespace Math {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -371,6 +402,7 @@ namespace Math {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (Quotient != 0L) {
         output.WriteRawTag(8);
@@ -387,6 +419,7 @@ namespace Math {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (Quotient != 0L) {
@@ -402,6 +435,7 @@ namespace Math {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(DivReply other) {
       if (other == null) {
         return;
@@ -416,6 +450,7 @@ namespace Math {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -441,6 +476,7 @@ namespace Math {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -471,19 +507,23 @@ namespace Math {
     private static readonly pb::MessageParser<FibArgs> _parser = new pb::MessageParser<FibArgs>(() => new FibArgs());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<FibArgs> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Math.MathReflection.Descriptor.MessageTypes[2]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public FibArgs() {
       OnConstruction();
     }
@@ -491,12 +531,14 @@ namespace Math {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public FibArgs(FibArgs other) : this() {
       limit_ = other.limit_;
       _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public FibArgs Clone() {
       return new FibArgs(this);
     }
@@ -505,6 +547,7 @@ namespace Math {
     public const int LimitFieldNumber = 1;
     private long limit_;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public long Limit {
       get { return limit_; }
       set {
@@ -513,11 +556,13 @@ namespace Math {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as FibArgs);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(FibArgs other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -530,6 +575,7 @@ namespace Math {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (Limit != 0L) hash ^= Limit.GetHashCode();
@@ -540,11 +586,13 @@ namespace Math {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -561,6 +609,7 @@ namespace Math {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (Limit != 0L) {
         output.WriteRawTag(8);
@@ -573,6 +622,7 @@ namespace Math {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (Limit != 0L) {
@@ -585,6 +635,7 @@ namespace Math {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(FibArgs other) {
       if (other == null) {
         return;
@@ -596,6 +647,7 @@ namespace Math {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -617,6 +669,7 @@ namespace Math {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -643,19 +696,23 @@ namespace Math {
     private static readonly pb::MessageParser<Num> _parser = new pb::MessageParser<Num>(() => new Num());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<Num> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Math.MathReflection.Descriptor.MessageTypes[3]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public Num() {
       OnConstruction();
     }
@@ -663,12 +720,14 @@ namespace Math {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public Num(Num other) : this() {
       num_ = other.num_;
       _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public Num Clone() {
       return new Num(this);
     }
@@ -677,6 +736,7 @@ namespace Math {
     public const int Num_FieldNumber = 1;
     private long num_;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public long Num_ {
       get { return num_; }
       set {
@@ -685,11 +745,13 @@ namespace Math {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as Num);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(Num other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -702,6 +764,7 @@ namespace Math {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (Num_ != 0L) hash ^= Num_.GetHashCode();
@@ -712,11 +775,13 @@ namespace Math {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -733,6 +798,7 @@ namespace Math {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (Num_ != 0L) {
         output.WriteRawTag(8);
@@ -745,6 +811,7 @@ namespace Math {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (Num_ != 0L) {
@@ -757,6 +824,7 @@ namespace Math {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(Num other) {
       if (other == null) {
         return;
@@ -768,6 +836,7 @@ namespace Math {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -789,6 +858,7 @@ namespace Math {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -815,19 +885,23 @@ namespace Math {
     private static readonly pb::MessageParser<FibReply> _parser = new pb::MessageParser<FibReply>(() => new FibReply());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<FibReply> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Math.MathReflection.Descriptor.MessageTypes[4]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public FibReply() {
       OnConstruction();
     }
@@ -835,12 +909,14 @@ namespace Math {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public FibReply(FibReply other) : this() {
       count_ = other.count_;
       _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public FibReply Clone() {
       return new FibReply(this);
     }
@@ -849,6 +925,7 @@ namespace Math {
     public const int CountFieldNumber = 1;
     private long count_;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public long Count {
       get { return count_; }
       set {
@@ -857,11 +934,13 @@ namespace Math {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as FibReply);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(FibReply other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -874,6 +953,7 @@ namespace Math {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (Count != 0L) hash ^= Count.GetHashCode();
@@ -884,11 +964,13 @@ namespace Math {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -905,6 +987,7 @@ namespace Math {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (Count != 0L) {
         output.WriteRawTag(8);
@@ -917,6 +1000,7 @@ namespace Math {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (Count != 0L) {
@@ -929,6 +1013,7 @@ namespace Math {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(FibReply other) {
       if (other == null) {
         return;
@@ -940,6 +1025,7 @@ namespace Math {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -961,6 +1047,7 @@ namespace Math {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
index 66b03c0..2bc976f 100644 (file)
@@ -55,19 +55,23 @@ namespace Grpc.Health.V1 {
     private static readonly pb::MessageParser<HealthCheckRequest> _parser = new pb::MessageParser<HealthCheckRequest>(() => new HealthCheckRequest());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<HealthCheckRequest> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Health.V1.HealthReflection.Descriptor.MessageTypes[0]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public HealthCheckRequest() {
       OnConstruction();
     }
@@ -75,12 +79,14 @@ namespace Grpc.Health.V1 {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public HealthCheckRequest(HealthCheckRequest other) : this() {
       service_ = other.service_;
       _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public HealthCheckRequest Clone() {
       return new HealthCheckRequest(this);
     }
@@ -89,6 +95,7 @@ namespace Grpc.Health.V1 {
     public const int ServiceFieldNumber = 1;
     private string service_ = "";
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public string Service {
       get { return service_; }
       set {
@@ -97,11 +104,13 @@ namespace Grpc.Health.V1 {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as HealthCheckRequest);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(HealthCheckRequest other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -114,6 +123,7 @@ namespace Grpc.Health.V1 {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (Service.Length != 0) hash ^= Service.GetHashCode();
@@ -124,11 +134,13 @@ namespace Grpc.Health.V1 {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -145,6 +157,7 @@ namespace Grpc.Health.V1 {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (Service.Length != 0) {
         output.WriteRawTag(10);
@@ -157,6 +170,7 @@ namespace Grpc.Health.V1 {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (Service.Length != 0) {
@@ -169,6 +183,7 @@ namespace Grpc.Health.V1 {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(HealthCheckRequest other) {
       if (other == null) {
         return;
@@ -180,6 +195,7 @@ namespace Grpc.Health.V1 {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -201,6 +217,7 @@ namespace Grpc.Health.V1 {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -227,19 +244,23 @@ namespace Grpc.Health.V1 {
     private static readonly pb::MessageParser<HealthCheckResponse> _parser = new pb::MessageParser<HealthCheckResponse>(() => new HealthCheckResponse());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<HealthCheckResponse> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Health.V1.HealthReflection.Descriptor.MessageTypes[1]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public HealthCheckResponse() {
       OnConstruction();
     }
@@ -247,12 +268,14 @@ namespace Grpc.Health.V1 {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public HealthCheckResponse(HealthCheckResponse other) : this() {
       status_ = other.status_;
       _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public HealthCheckResponse Clone() {
       return new HealthCheckResponse(this);
     }
@@ -261,6 +284,7 @@ namespace Grpc.Health.V1 {
     public const int StatusFieldNumber = 1;
     private global::Grpc.Health.V1.HealthCheckResponse.Types.ServingStatus status_ = global::Grpc.Health.V1.HealthCheckResponse.Types.ServingStatus.Unknown;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public global::Grpc.Health.V1.HealthCheckResponse.Types.ServingStatus Status {
       get { return status_; }
       set {
@@ -269,11 +293,13 @@ namespace Grpc.Health.V1 {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as HealthCheckResponse);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(HealthCheckResponse other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -286,6 +312,7 @@ namespace Grpc.Health.V1 {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (Status != global::Grpc.Health.V1.HealthCheckResponse.Types.ServingStatus.Unknown) hash ^= Status.GetHashCode();
@@ -296,11 +323,13 @@ namespace Grpc.Health.V1 {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -317,6 +346,7 @@ namespace Grpc.Health.V1 {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (Status != global::Grpc.Health.V1.HealthCheckResponse.Types.ServingStatus.Unknown) {
         output.WriteRawTag(8);
@@ -329,6 +359,7 @@ namespace Grpc.Health.V1 {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (Status != global::Grpc.Health.V1.HealthCheckResponse.Types.ServingStatus.Unknown) {
@@ -341,6 +372,7 @@ namespace Grpc.Health.V1 {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(HealthCheckResponse other) {
       if (other == null) {
         return;
@@ -352,6 +384,7 @@ namespace Grpc.Health.V1 {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -373,6 +406,7 @@ namespace Grpc.Health.V1 {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -392,6 +426,7 @@ namespace Grpc.Health.V1 {
     #region Nested types
     /// <summary>Container for nested types declared in the HealthCheckResponse message type.</summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static partial class Types {
       public enum ServingStatus {
         [pbr::OriginalName("UNKNOWN")] Unknown = 0,
index 09ec98a..1837bc8 100644 (file)
@@ -180,19 +180,23 @@ namespace Grpc.Testing {
     private static readonly pb::MessageParser<PoissonParams> _parser = new pb::MessageParser<PoissonParams>(() => new PoissonParams());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<PoissonParams> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Testing.ControlReflection.Descriptor.MessageTypes[0]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public PoissonParams() {
       OnConstruction();
     }
@@ -200,12 +204,14 @@ namespace Grpc.Testing {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public PoissonParams(PoissonParams other) : this() {
       offeredLoad_ = other.offeredLoad_;
       _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public PoissonParams Clone() {
       return new PoissonParams(this);
     }
@@ -217,6 +223,7 @@ namespace Grpc.Testing {
     /// The rate of arrivals (a.k.a. lambda parameter of the exp distribution).
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public double OfferedLoad {
       get { return offeredLoad_; }
       set {
@@ -225,11 +232,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as PoissonParams);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(PoissonParams other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -242,6 +251,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (OfferedLoad != 0D) hash ^= pbc::ProtobufEqualityComparers.BitwiseDoubleEqualityComparer.GetHashCode(OfferedLoad);
@@ -252,11 +262,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -273,6 +285,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (OfferedLoad != 0D) {
         output.WriteRawTag(9);
@@ -285,6 +298,7 @@ namespace Grpc.Testing {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (OfferedLoad != 0D) {
@@ -297,6 +311,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(PoissonParams other) {
       if (other == null) {
         return;
@@ -308,6 +323,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -329,6 +345,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -359,19 +376,23 @@ namespace Grpc.Testing {
     private static readonly pb::MessageParser<ClosedLoopParams> _parser = new pb::MessageParser<ClosedLoopParams>(() => new ClosedLoopParams());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<ClosedLoopParams> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Testing.ControlReflection.Descriptor.MessageTypes[1]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ClosedLoopParams() {
       OnConstruction();
     }
@@ -379,21 +400,25 @@ namespace Grpc.Testing {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ClosedLoopParams(ClosedLoopParams other) : this() {
       _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ClosedLoopParams Clone() {
       return new ClosedLoopParams(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as ClosedLoopParams);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(ClosedLoopParams other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -405,6 +430,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (_unknownFields != null) {
@@ -414,11 +440,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -431,6 +459,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (_unknownFields != null) {
         _unknownFields.WriteTo(ref output);
@@ -439,6 +468,7 @@ namespace Grpc.Testing {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (_unknownFields != null) {
@@ -448,6 +478,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(ClosedLoopParams other) {
       if (other == null) {
         return;
@@ -456,6 +487,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -473,6 +505,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -495,19 +528,23 @@ namespace Grpc.Testing {
     private static readonly pb::MessageParser<LoadParams> _parser = new pb::MessageParser<LoadParams>(() => new LoadParams());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<LoadParams> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Testing.ControlReflection.Descriptor.MessageTypes[2]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public LoadParams() {
       OnConstruction();
     }
@@ -515,6 +552,7 @@ namespace Grpc.Testing {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public LoadParams(LoadParams other) : this() {
       switch (other.LoadCase) {
         case LoadOneofCase.ClosedLoop:
@@ -529,6 +567,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public LoadParams Clone() {
       return new LoadParams(this);
     }
@@ -536,6 +575,7 @@ namespace Grpc.Testing {
     /// <summary>Field number for the "closed_loop" field.</summary>
     public const int ClosedLoopFieldNumber = 1;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public global::Grpc.Testing.ClosedLoopParams ClosedLoop {
       get { return loadCase_ == LoadOneofCase.ClosedLoop ? (global::Grpc.Testing.ClosedLoopParams) load_ : null; }
       set {
@@ -547,6 +587,7 @@ namespace Grpc.Testing {
     /// <summary>Field number for the "poisson" field.</summary>
     public const int PoissonFieldNumber = 2;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public global::Grpc.Testing.PoissonParams Poisson {
       get { return loadCase_ == LoadOneofCase.Poisson ? (global::Grpc.Testing.PoissonParams) load_ : null; }
       set {
@@ -564,22 +605,26 @@ namespace Grpc.Testing {
     }
     private LoadOneofCase loadCase_ = LoadOneofCase.None;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public LoadOneofCase LoadCase {
       get { return loadCase_; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void ClearLoad() {
       loadCase_ = LoadOneofCase.None;
       load_ = null;
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as LoadParams);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(LoadParams other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -594,6 +639,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (loadCase_ == LoadOneofCase.ClosedLoop) hash ^= ClosedLoop.GetHashCode();
@@ -606,11 +652,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -631,6 +679,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (loadCase_ == LoadOneofCase.ClosedLoop) {
         output.WriteRawTag(10);
@@ -647,6 +696,7 @@ namespace Grpc.Testing {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (loadCase_ == LoadOneofCase.ClosedLoop) {
@@ -662,6 +712,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(LoadParams other) {
       if (other == null) {
         return;
@@ -685,6 +736,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -720,6 +772,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -763,19 +816,23 @@ namespace Grpc.Testing {
     private static readonly pb::MessageParser<SecurityParams> _parser = new pb::MessageParser<SecurityParams>(() => new SecurityParams());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<SecurityParams> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Testing.ControlReflection.Descriptor.MessageTypes[3]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public SecurityParams() {
       OnConstruction();
     }
@@ -783,6 +840,7 @@ namespace Grpc.Testing {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public SecurityParams(SecurityParams other) : this() {
       useTestCa_ = other.useTestCa_;
       serverHostOverride_ = other.serverHostOverride_;
@@ -791,6 +849,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public SecurityParams Clone() {
       return new SecurityParams(this);
     }
@@ -799,6 +858,7 @@ namespace Grpc.Testing {
     public const int UseTestCaFieldNumber = 1;
     private bool useTestCa_;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool UseTestCa {
       get { return useTestCa_; }
       set {
@@ -810,6 +870,7 @@ namespace Grpc.Testing {
     public const int ServerHostOverrideFieldNumber = 2;
     private string serverHostOverride_ = "";
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public string ServerHostOverride {
       get { return serverHostOverride_; }
       set {
@@ -821,6 +882,7 @@ namespace Grpc.Testing {
     public const int CredTypeFieldNumber = 3;
     private string credType_ = "";
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public string CredType {
       get { return credType_; }
       set {
@@ -829,11 +891,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as SecurityParams);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(SecurityParams other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -848,6 +912,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (UseTestCa != false) hash ^= UseTestCa.GetHashCode();
@@ -860,11 +925,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -889,6 +956,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (UseTestCa != false) {
         output.WriteRawTag(8);
@@ -909,6 +977,7 @@ namespace Grpc.Testing {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (UseTestCa != false) {
@@ -927,6 +996,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(SecurityParams other) {
       if (other == null) {
         return;
@@ -944,6 +1014,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -973,6 +1044,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -1007,19 +1079,23 @@ namespace Grpc.Testing {
     private static readonly pb::MessageParser<ChannelArg> _parser = new pb::MessageParser<ChannelArg>(() => new ChannelArg());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<ChannelArg> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Testing.ControlReflection.Descriptor.MessageTypes[4]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ChannelArg() {
       OnConstruction();
     }
@@ -1027,6 +1103,7 @@ namespace Grpc.Testing {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ChannelArg(ChannelArg other) : this() {
       name_ = other.name_;
       switch (other.ValueCase) {
@@ -1042,6 +1119,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ChannelArg Clone() {
       return new ChannelArg(this);
     }
@@ -1050,6 +1128,7 @@ namespace Grpc.Testing {
     public const int NameFieldNumber = 1;
     private string name_ = "";
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public string Name {
       get { return name_; }
       set {
@@ -1060,6 +1139,7 @@ namespace Grpc.Testing {
     /// <summary>Field number for the "str_value" field.</summary>
     public const int StrValueFieldNumber = 2;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public string StrValue {
       get { return valueCase_ == ValueOneofCase.StrValue ? (string) value_ : ""; }
       set {
@@ -1071,6 +1151,7 @@ namespace Grpc.Testing {
     /// <summary>Field number for the "int_value" field.</summary>
     public const int IntValueFieldNumber = 3;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int IntValue {
       get { return valueCase_ == ValueOneofCase.IntValue ? (int) value_ : 0; }
       set {
@@ -1088,22 +1169,26 @@ namespace Grpc.Testing {
     }
     private ValueOneofCase valueCase_ = ValueOneofCase.None;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ValueOneofCase ValueCase {
       get { return valueCase_; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void ClearValue() {
       valueCase_ = ValueOneofCase.None;
       value_ = null;
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as ChannelArg);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(ChannelArg other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -1119,6 +1204,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (Name.Length != 0) hash ^= Name.GetHashCode();
@@ -1132,11 +1218,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -1161,6 +1249,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (Name.Length != 0) {
         output.WriteRawTag(10);
@@ -1181,6 +1270,7 @@ namespace Grpc.Testing {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (Name.Length != 0) {
@@ -1199,6 +1289,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(ChannelArg other) {
       if (other == null) {
         return;
@@ -1219,6 +1310,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -1248,6 +1340,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -1282,19 +1375,23 @@ namespace Grpc.Testing {
     private static readonly pb::MessageParser<ClientConfig> _parser = new pb::MessageParser<ClientConfig>(() => new ClientConfig());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<ClientConfig> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Testing.ControlReflection.Descriptor.MessageTypes[5]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ClientConfig() {
       OnConstruction();
     }
@@ -1302,6 +1399,7 @@ namespace Grpc.Testing {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ClientConfig(ClientConfig other) : this() {
       serverTargets_ = other.serverTargets_.Clone();
       clientType_ = other.clientType_;
@@ -1326,6 +1424,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ClientConfig Clone() {
       return new ClientConfig(this);
     }
@@ -1339,6 +1438,7 @@ namespace Grpc.Testing {
     /// List of targets to connect to. At least one target needs to be specified.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public pbc::RepeatedField<string> ServerTargets {
       get { return serverTargets_; }
     }
@@ -1347,6 +1447,7 @@ namespace Grpc.Testing {
     public const int ClientTypeFieldNumber = 2;
     private global::Grpc.Testing.ClientType clientType_ = global::Grpc.Testing.ClientType.SyncClient;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public global::Grpc.Testing.ClientType ClientType {
       get { return clientType_; }
       set {
@@ -1358,6 +1459,7 @@ namespace Grpc.Testing {
     public const int SecurityParamsFieldNumber = 3;
     private global::Grpc.Testing.SecurityParams securityParams_;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public global::Grpc.Testing.SecurityParams SecurityParams {
       get { return securityParams_; }
       set {
@@ -1373,6 +1475,7 @@ namespace Grpc.Testing {
     /// For synchronous client, use a separate thread for each outstanding RPC.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int OutstandingRpcsPerChannel {
       get { return outstandingRpcsPerChannel_; }
       set {
@@ -1388,6 +1491,7 @@ namespace Grpc.Testing {
     /// i-th channel will connect to server_target[i % server_targets.size()]
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int ClientChannels {
       get { return clientChannels_; }
       set {
@@ -1402,6 +1506,7 @@ namespace Grpc.Testing {
     /// Only for async client. Number of threads to use to start/manage RPCs.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int AsyncClientThreads {
       get { return asyncClientThreads_; }
       set {
@@ -1413,6 +1518,7 @@ namespace Grpc.Testing {
     public const int RpcTypeFieldNumber = 8;
     private global::Grpc.Testing.RpcType rpcType_ = global::Grpc.Testing.RpcType.Unary;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public global::Grpc.Testing.RpcType RpcType {
       get { return rpcType_; }
       set {
@@ -1427,6 +1533,7 @@ namespace Grpc.Testing {
     /// The requested load for the entire client (aggregated over all the threads).
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public global::Grpc.Testing.LoadParams LoadParams {
       get { return loadParams_; }
       set {
@@ -1438,6 +1545,7 @@ namespace Grpc.Testing {
     public const int PayloadConfigFieldNumber = 11;
     private global::Grpc.Testing.PayloadConfig payloadConfig_;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public global::Grpc.Testing.PayloadConfig PayloadConfig {
       get { return payloadConfig_; }
       set {
@@ -1449,6 +1557,7 @@ namespace Grpc.Testing {
     public const int HistogramParamsFieldNumber = 12;
     private global::Grpc.Testing.HistogramParams histogramParams_;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public global::Grpc.Testing.HistogramParams HistogramParams {
       get { return histogramParams_; }
       set {
@@ -1465,6 +1574,7 @@ namespace Grpc.Testing {
     /// Specify the cores we should run the client on, if desired
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public pbc::RepeatedField<int> CoreList {
       get { return coreList_; }
     }
@@ -1473,6 +1583,7 @@ namespace Grpc.Testing {
     public const int CoreLimitFieldNumber = 14;
     private int coreLimit_;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CoreLimit {
       get { return coreLimit_; }
       set {
@@ -1487,6 +1598,7 @@ namespace Grpc.Testing {
     /// If we use an OTHER_CLIENT client_type, this string gives more detail
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public string OtherClientApi {
       get { return otherClientApi_; }
       set {
@@ -1500,6 +1612,7 @@ namespace Grpc.Testing {
         = pb::FieldCodec.ForMessage(130, global::Grpc.Testing.ChannelArg.Parser);
     private readonly pbc::RepeatedField<global::Grpc.Testing.ChannelArg> channelArgs_ = new pbc::RepeatedField<global::Grpc.Testing.ChannelArg>();
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public pbc::RepeatedField<global::Grpc.Testing.ChannelArg> ChannelArgs {
       get { return channelArgs_; }
     }
@@ -1511,6 +1624,7 @@ namespace Grpc.Testing {
     /// Number of threads that share each completion queue
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int ThreadsPerCq {
       get { return threadsPerCq_; }
       set {
@@ -1525,6 +1639,7 @@ namespace Grpc.Testing {
     /// Number of messages on a stream before it gets finished/restarted
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int MessagesPerStream {
       get { return messagesPerStream_; }
       set {
@@ -1539,6 +1654,7 @@ namespace Grpc.Testing {
     /// Use coalescing API when possible.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool UseCoalesceApi {
       get { return useCoalesceApi_; }
       set {
@@ -1554,6 +1670,7 @@ namespace Grpc.Testing {
     /// medians in milliseconds.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int MedianLatencyCollectionIntervalMillis {
       get { return medianLatencyCollectionIntervalMillis_; }
       set {
@@ -1568,6 +1685,7 @@ namespace Grpc.Testing {
     /// Number of client processes. 0 indicates no restriction.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int ClientProcesses {
       get { return clientProcesses_; }
       set {
@@ -1576,11 +1694,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as ClientConfig);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(ClientConfig other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -1611,6 +1731,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       hash ^= serverTargets_.GetHashCode();
@@ -1639,11 +1760,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -1723,6 +1846,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       serverTargets_.WriteTo(ref output, _repeated_serverTargets_codec);
       if (ClientType != global::Grpc.Testing.ClientType.SyncClient) {
@@ -1798,6 +1922,7 @@ namespace Grpc.Testing {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       size += serverTargets_.CalculateSize(_repeated_serverTargets_codec);
@@ -1858,6 +1983,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(ClientConfig other) {
       if (other == null) {
         return;
@@ -1929,6 +2055,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -2035,6 +2162,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -2146,19 +2274,23 @@ namespace Grpc.Testing {
     private static readonly pb::MessageParser<ClientStatus> _parser = new pb::MessageParser<ClientStatus>(() => new ClientStatus());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<ClientStatus> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Testing.ControlReflection.Descriptor.MessageTypes[6]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ClientStatus() {
       OnConstruction();
     }
@@ -2166,12 +2298,14 @@ namespace Grpc.Testing {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ClientStatus(ClientStatus other) : this() {
       stats_ = other.stats_ != null ? other.stats_.Clone() : null;
       _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ClientStatus Clone() {
       return new ClientStatus(this);
     }
@@ -2180,6 +2314,7 @@ namespace Grpc.Testing {
     public const int StatsFieldNumber = 1;
     private global::Grpc.Testing.ClientStats stats_;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public global::Grpc.Testing.ClientStats Stats {
       get { return stats_; }
       set {
@@ -2188,11 +2323,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as ClientStatus);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(ClientStatus other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -2205,6 +2342,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (stats_ != null) hash ^= Stats.GetHashCode();
@@ -2215,11 +2353,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -2236,6 +2376,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (stats_ != null) {
         output.WriteRawTag(10);
@@ -2248,6 +2389,7 @@ namespace Grpc.Testing {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (stats_ != null) {
@@ -2260,6 +2402,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(ClientStatus other) {
       if (other == null) {
         return;
@@ -2274,6 +2417,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -2298,6 +2442,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -2330,19 +2475,23 @@ namespace Grpc.Testing {
     private static readonly pb::MessageParser<Mark> _parser = new pb::MessageParser<Mark>(() => new Mark());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<Mark> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Testing.ControlReflection.Descriptor.MessageTypes[7]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public Mark() {
       OnConstruction();
     }
@@ -2350,12 +2499,14 @@ namespace Grpc.Testing {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public Mark(Mark other) : this() {
       reset_ = other.reset_;
       _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public Mark Clone() {
       return new Mark(this);
     }
@@ -2367,6 +2518,7 @@ namespace Grpc.Testing {
     /// if true, the stats will be reset after taking their snapshot.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Reset {
       get { return reset_; }
       set {
@@ -2375,11 +2527,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as Mark);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(Mark other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -2392,6 +2546,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (Reset != false) hash ^= Reset.GetHashCode();
@@ -2402,11 +2557,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -2423,6 +2580,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (Reset != false) {
         output.WriteRawTag(8);
@@ -2435,6 +2593,7 @@ namespace Grpc.Testing {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (Reset != false) {
@@ -2447,6 +2606,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(Mark other) {
       if (other == null) {
         return;
@@ -2458,6 +2618,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -2479,6 +2640,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -2505,19 +2667,23 @@ namespace Grpc.Testing {
     private static readonly pb::MessageParser<ClientArgs> _parser = new pb::MessageParser<ClientArgs>(() => new ClientArgs());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<ClientArgs> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Testing.ControlReflection.Descriptor.MessageTypes[8]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ClientArgs() {
       OnConstruction();
     }
@@ -2525,6 +2691,7 @@ namespace Grpc.Testing {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ClientArgs(ClientArgs other) : this() {
       switch (other.ArgtypeCase) {
         case ArgtypeOneofCase.Setup:
@@ -2539,6 +2706,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ClientArgs Clone() {
       return new ClientArgs(this);
     }
@@ -2546,6 +2714,7 @@ namespace Grpc.Testing {
     /// <summary>Field number for the "setup" field.</summary>
     public const int SetupFieldNumber = 1;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public global::Grpc.Testing.ClientConfig Setup {
       get { return argtypeCase_ == ArgtypeOneofCase.Setup ? (global::Grpc.Testing.ClientConfig) argtype_ : null; }
       set {
@@ -2557,6 +2726,7 @@ namespace Grpc.Testing {
     /// <summary>Field number for the "mark" field.</summary>
     public const int MarkFieldNumber = 2;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public global::Grpc.Testing.Mark Mark {
       get { return argtypeCase_ == ArgtypeOneofCase.Mark ? (global::Grpc.Testing.Mark) argtype_ : null; }
       set {
@@ -2574,22 +2744,26 @@ namespace Grpc.Testing {
     }
     private ArgtypeOneofCase argtypeCase_ = ArgtypeOneofCase.None;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ArgtypeOneofCase ArgtypeCase {
       get { return argtypeCase_; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void ClearArgtype() {
       argtypeCase_ = ArgtypeOneofCase.None;
       argtype_ = null;
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as ClientArgs);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(ClientArgs other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -2604,6 +2778,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (argtypeCase_ == ArgtypeOneofCase.Setup) hash ^= Setup.GetHashCode();
@@ -2616,11 +2791,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -2641,6 +2818,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (argtypeCase_ == ArgtypeOneofCase.Setup) {
         output.WriteRawTag(10);
@@ -2657,6 +2835,7 @@ namespace Grpc.Testing {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (argtypeCase_ == ArgtypeOneofCase.Setup) {
@@ -2672,6 +2851,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(ClientArgs other) {
       if (other == null) {
         return;
@@ -2695,6 +2875,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -2730,6 +2911,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -2770,19 +2952,23 @@ namespace Grpc.Testing {
     private static readonly pb::MessageParser<ServerConfig> _parser = new pb::MessageParser<ServerConfig>(() => new ServerConfig());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<ServerConfig> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Testing.ControlReflection.Descriptor.MessageTypes[9]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ServerConfig() {
       OnConstruction();
     }
@@ -2790,6 +2976,7 @@ namespace Grpc.Testing {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ServerConfig(ServerConfig other) : this() {
       serverType_ = other.serverType_;
       securityParams_ = other.securityParams_ != null ? other.securityParams_.Clone() : null;
@@ -2807,6 +2994,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ServerConfig Clone() {
       return new ServerConfig(this);
     }
@@ -2815,6 +3003,7 @@ namespace Grpc.Testing {
     public const int ServerTypeFieldNumber = 1;
     private global::Grpc.Testing.ServerType serverType_ = global::Grpc.Testing.ServerType.SyncServer;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public global::Grpc.Testing.ServerType ServerType {
       get { return serverType_; }
       set {
@@ -2826,6 +3015,7 @@ namespace Grpc.Testing {
     public const int SecurityParamsFieldNumber = 2;
     private global::Grpc.Testing.SecurityParams securityParams_;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public global::Grpc.Testing.SecurityParams SecurityParams {
       get { return securityParams_; }
       set {
@@ -2840,6 +3030,7 @@ namespace Grpc.Testing {
     /// Port on which to listen. Zero means pick unused port.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int Port {
       get { return port_; }
       set {
@@ -2854,6 +3045,7 @@ namespace Grpc.Testing {
     /// Only for async server. Number of threads used to serve the requests.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int AsyncServerThreads {
       get { return asyncServerThreads_; }
       set {
@@ -2868,6 +3060,7 @@ namespace Grpc.Testing {
     /// Specify the number of cores to limit server to, if desired
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CoreLimit {
       get { return coreLimit_; }
       set {
@@ -2885,6 +3078,7 @@ namespace Grpc.Testing {
     /// 'SimpleRequest' objects in RPC requests.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public global::Grpc.Testing.PayloadConfig PayloadConfig {
       get { return payloadConfig_; }
       set {
@@ -2901,6 +3095,7 @@ namespace Grpc.Testing {
     /// Specify the cores we should run the server on, if desired
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public pbc::RepeatedField<int> CoreList {
       get { return coreList_; }
     }
@@ -2912,6 +3107,7 @@ namespace Grpc.Testing {
     /// If we use an OTHER_SERVER client_type, this string gives more detail
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public string OtherServerApi {
       get { return otherServerApi_; }
       set {
@@ -2926,6 +3122,7 @@ namespace Grpc.Testing {
     /// Number of threads that share each completion queue
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int ThreadsPerCq {
       get { return threadsPerCq_; }
       set {
@@ -2940,6 +3137,7 @@ namespace Grpc.Testing {
     /// Buffer pool size (no buffer pool specified if unset)
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int ResourceQuotaSize {
       get { return resourceQuotaSize_; }
       set {
@@ -2953,6 +3151,7 @@ namespace Grpc.Testing {
         = pb::FieldCodec.ForMessage(8018, global::Grpc.Testing.ChannelArg.Parser);
     private readonly pbc::RepeatedField<global::Grpc.Testing.ChannelArg> channelArgs_ = new pbc::RepeatedField<global::Grpc.Testing.ChannelArg>();
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public pbc::RepeatedField<global::Grpc.Testing.ChannelArg> ChannelArgs {
       get { return channelArgs_; }
     }
@@ -2964,6 +3163,7 @@ namespace Grpc.Testing {
     /// Number of server processes. 0 indicates no restriction.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int ServerProcesses {
       get { return serverProcesses_; }
       set {
@@ -2972,11 +3172,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as ServerConfig);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(ServerConfig other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -3000,6 +3202,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (ServerType != global::Grpc.Testing.ServerType.SyncServer) hash ^= ServerType.GetHashCode();
@@ -3021,11 +3224,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -3080,6 +3285,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (ServerType != global::Grpc.Testing.ServerType.SyncServer) {
         output.WriteRawTag(8);
@@ -3130,6 +3336,7 @@ namespace Grpc.Testing {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (ServerType != global::Grpc.Testing.ServerType.SyncServer) {
@@ -3171,6 +3378,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(ServerConfig other) {
       if (other == null) {
         return;
@@ -3217,6 +3425,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -3289,6 +3498,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -3366,19 +3576,23 @@ namespace Grpc.Testing {
     private static readonly pb::MessageParser<ServerArgs> _parser = new pb::MessageParser<ServerArgs>(() => new ServerArgs());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<ServerArgs> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Testing.ControlReflection.Descriptor.MessageTypes[10]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ServerArgs() {
       OnConstruction();
     }
@@ -3386,6 +3600,7 @@ namespace Grpc.Testing {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ServerArgs(ServerArgs other) : this() {
       switch (other.ArgtypeCase) {
         case ArgtypeOneofCase.Setup:
@@ -3400,6 +3615,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ServerArgs Clone() {
       return new ServerArgs(this);
     }
@@ -3407,6 +3623,7 @@ namespace Grpc.Testing {
     /// <summary>Field number for the "setup" field.</summary>
     public const int SetupFieldNumber = 1;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public global::Grpc.Testing.ServerConfig Setup {
       get { return argtypeCase_ == ArgtypeOneofCase.Setup ? (global::Grpc.Testing.ServerConfig) argtype_ : null; }
       set {
@@ -3418,6 +3635,7 @@ namespace Grpc.Testing {
     /// <summary>Field number for the "mark" field.</summary>
     public const int MarkFieldNumber = 2;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public global::Grpc.Testing.Mark Mark {
       get { return argtypeCase_ == ArgtypeOneofCase.Mark ? (global::Grpc.Testing.Mark) argtype_ : null; }
       set {
@@ -3435,22 +3653,26 @@ namespace Grpc.Testing {
     }
     private ArgtypeOneofCase argtypeCase_ = ArgtypeOneofCase.None;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ArgtypeOneofCase ArgtypeCase {
       get { return argtypeCase_; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void ClearArgtype() {
       argtypeCase_ = ArgtypeOneofCase.None;
       argtype_ = null;
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as ServerArgs);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(ServerArgs other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -3465,6 +3687,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (argtypeCase_ == ArgtypeOneofCase.Setup) hash ^= Setup.GetHashCode();
@@ -3477,11 +3700,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -3502,6 +3727,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (argtypeCase_ == ArgtypeOneofCase.Setup) {
         output.WriteRawTag(10);
@@ -3518,6 +3744,7 @@ namespace Grpc.Testing {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (argtypeCase_ == ArgtypeOneofCase.Setup) {
@@ -3533,6 +3760,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(ServerArgs other) {
       if (other == null) {
         return;
@@ -3556,6 +3784,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -3591,6 +3820,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -3631,19 +3861,23 @@ namespace Grpc.Testing {
     private static readonly pb::MessageParser<ServerStatus> _parser = new pb::MessageParser<ServerStatus>(() => new ServerStatus());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<ServerStatus> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Testing.ControlReflection.Descriptor.MessageTypes[11]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ServerStatus() {
       OnConstruction();
     }
@@ -3651,6 +3885,7 @@ namespace Grpc.Testing {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ServerStatus(ServerStatus other) : this() {
       stats_ = other.stats_ != null ? other.stats_.Clone() : null;
       port_ = other.port_;
@@ -3659,6 +3894,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ServerStatus Clone() {
       return new ServerStatus(this);
     }
@@ -3667,6 +3903,7 @@ namespace Grpc.Testing {
     public const int StatsFieldNumber = 1;
     private global::Grpc.Testing.ServerStats stats_;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public global::Grpc.Testing.ServerStats Stats {
       get { return stats_; }
       set {
@@ -3681,6 +3918,7 @@ namespace Grpc.Testing {
     /// the port bound by the server
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int Port {
       get { return port_; }
       set {
@@ -3695,6 +3933,7 @@ namespace Grpc.Testing {
     /// Number of cores available to the server
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int Cores {
       get { return cores_; }
       set {
@@ -3703,11 +3942,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as ServerStatus);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(ServerStatus other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -3722,6 +3963,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (stats_ != null) hash ^= Stats.GetHashCode();
@@ -3734,11 +3976,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -3763,6 +4007,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (stats_ != null) {
         output.WriteRawTag(10);
@@ -3783,6 +4028,7 @@ namespace Grpc.Testing {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (stats_ != null) {
@@ -3801,6 +4047,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(ServerStatus other) {
       if (other == null) {
         return;
@@ -3821,6 +4068,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -3853,6 +4101,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -3890,19 +4139,23 @@ namespace Grpc.Testing {
     private static readonly pb::MessageParser<CoreRequest> _parser = new pb::MessageParser<CoreRequest>(() => new CoreRequest());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<CoreRequest> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Testing.ControlReflection.Descriptor.MessageTypes[12]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public CoreRequest() {
       OnConstruction();
     }
@@ -3910,21 +4163,25 @@ namespace Grpc.Testing {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public CoreRequest(CoreRequest other) : this() {
       _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public CoreRequest Clone() {
       return new CoreRequest(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as CoreRequest);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(CoreRequest other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -3936,6 +4193,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (_unknownFields != null) {
@@ -3945,11 +4203,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -3962,6 +4222,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (_unknownFields != null) {
         _unknownFields.WriteTo(ref output);
@@ -3970,6 +4231,7 @@ namespace Grpc.Testing {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (_unknownFields != null) {
@@ -3979,6 +4241,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(CoreRequest other) {
       if (other == null) {
         return;
@@ -3987,6 +4250,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -4004,6 +4268,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -4026,19 +4291,23 @@ namespace Grpc.Testing {
     private static readonly pb::MessageParser<CoreResponse> _parser = new pb::MessageParser<CoreResponse>(() => new CoreResponse());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<CoreResponse> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Testing.ControlReflection.Descriptor.MessageTypes[13]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public CoreResponse() {
       OnConstruction();
     }
@@ -4046,12 +4315,14 @@ namespace Grpc.Testing {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public CoreResponse(CoreResponse other) : this() {
       cores_ = other.cores_;
       _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public CoreResponse Clone() {
       return new CoreResponse(this);
     }
@@ -4063,6 +4334,7 @@ namespace Grpc.Testing {
     /// Number of cores available on the server
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int Cores {
       get { return cores_; }
       set {
@@ -4071,11 +4343,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as CoreResponse);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(CoreResponse other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -4088,6 +4362,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (Cores != 0) hash ^= Cores.GetHashCode();
@@ -4098,11 +4373,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -4119,6 +4396,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (Cores != 0) {
         output.WriteRawTag(8);
@@ -4131,6 +4409,7 @@ namespace Grpc.Testing {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (Cores != 0) {
@@ -4143,6 +4422,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(CoreResponse other) {
       if (other == null) {
         return;
@@ -4154,6 +4434,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -4175,6 +4456,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -4201,19 +4483,23 @@ namespace Grpc.Testing {
     private static readonly pb::MessageParser<Void> _parser = new pb::MessageParser<Void>(() => new Void());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<Void> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Testing.ControlReflection.Descriptor.MessageTypes[14]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public Void() {
       OnConstruction();
     }
@@ -4221,21 +4507,25 @@ namespace Grpc.Testing {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public Void(Void other) : this() {
       _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public Void Clone() {
       return new Void(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as Void);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(Void other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -4247,6 +4537,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (_unknownFields != null) {
@@ -4256,11 +4547,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -4273,6 +4566,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (_unknownFields != null) {
         _unknownFields.WriteTo(ref output);
@@ -4281,6 +4575,7 @@ namespace Grpc.Testing {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (_unknownFields != null) {
@@ -4290,6 +4585,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(Void other) {
       if (other == null) {
         return;
@@ -4298,6 +4594,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -4315,6 +4612,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -4340,19 +4638,23 @@ namespace Grpc.Testing {
     private static readonly pb::MessageParser<Scenario> _parser = new pb::MessageParser<Scenario>(() => new Scenario());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<Scenario> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Testing.ControlReflection.Descriptor.MessageTypes[15]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public Scenario() {
       OnConstruction();
     }
@@ -4360,6 +4662,7 @@ namespace Grpc.Testing {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public Scenario(Scenario other) : this() {
       name_ = other.name_;
       clientConfig_ = other.clientConfig_ != null ? other.clientConfig_.Clone() : null;
@@ -4373,6 +4676,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public Scenario Clone() {
       return new Scenario(this);
     }
@@ -4384,6 +4688,7 @@ namespace Grpc.Testing {
     /// Human readable name for this scenario
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public string Name {
       get { return name_; }
       set {
@@ -4398,6 +4703,7 @@ namespace Grpc.Testing {
     /// Client configuration
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public global::Grpc.Testing.ClientConfig ClientConfig {
       get { return clientConfig_; }
       set {
@@ -4412,6 +4718,7 @@ namespace Grpc.Testing {
     /// Number of clients to start for the test
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int NumClients {
       get { return numClients_; }
       set {
@@ -4426,6 +4733,7 @@ namespace Grpc.Testing {
     /// Server configuration
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public global::Grpc.Testing.ServerConfig ServerConfig {
       get { return serverConfig_; }
       set {
@@ -4440,6 +4748,7 @@ namespace Grpc.Testing {
     /// Number of servers to start for the test
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int NumServers {
       get { return numServers_; }
       set {
@@ -4454,6 +4763,7 @@ namespace Grpc.Testing {
     /// Warmup period, in seconds
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int WarmupSeconds {
       get { return warmupSeconds_; }
       set {
@@ -4468,6 +4778,7 @@ namespace Grpc.Testing {
     /// Benchmark time, in seconds
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int BenchmarkSeconds {
       get { return benchmarkSeconds_; }
       set {
@@ -4482,6 +4793,7 @@ namespace Grpc.Testing {
     /// Number of workers to spawn locally (usually zero)
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int SpawnLocalWorkerCount {
       get { return spawnLocalWorkerCount_; }
       set {
@@ -4490,11 +4802,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as Scenario);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(Scenario other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -4514,6 +4828,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (Name.Length != 0) hash ^= Name.GetHashCode();
@@ -4531,11 +4846,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -4580,6 +4897,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (Name.Length != 0) {
         output.WriteRawTag(10);
@@ -4620,6 +4938,7 @@ namespace Grpc.Testing {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (Name.Length != 0) {
@@ -4653,6 +4972,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(Scenario other) {
       if (other == null) {
         return;
@@ -4691,6 +5011,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -4746,6 +5067,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -4809,19 +5131,23 @@ namespace Grpc.Testing {
     private static readonly pb::MessageParser<Scenarios> _parser = new pb::MessageParser<Scenarios>(() => new Scenarios());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<Scenarios> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Testing.ControlReflection.Descriptor.MessageTypes[16]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public Scenarios() {
       OnConstruction();
     }
@@ -4829,12 +5155,14 @@ namespace Grpc.Testing {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public Scenarios(Scenarios other) : this() {
       scenarios_ = other.scenarios_.Clone();
       _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public Scenarios Clone() {
       return new Scenarios(this);
     }
@@ -4845,16 +5173,19 @@ namespace Grpc.Testing {
         = pb::FieldCodec.ForMessage(10, global::Grpc.Testing.Scenario.Parser);
     private readonly pbc::RepeatedField<global::Grpc.Testing.Scenario> scenarios_ = new pbc::RepeatedField<global::Grpc.Testing.Scenario>();
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public pbc::RepeatedField<global::Grpc.Testing.Scenario> Scenarios_ {
       get { return scenarios_; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as Scenarios);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(Scenarios other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -4867,6 +5198,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       hash ^= scenarios_.GetHashCode();
@@ -4877,11 +5209,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -4895,6 +5229,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       scenarios_.WriteTo(ref output, _repeated_scenarios_codec);
       if (_unknownFields != null) {
@@ -4904,6 +5239,7 @@ namespace Grpc.Testing {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       size += scenarios_.CalculateSize(_repeated_scenarios_codec);
@@ -4914,6 +5250,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(Scenarios other) {
       if (other == null) {
         return;
@@ -4923,6 +5260,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -4944,6 +5282,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -4974,19 +5313,23 @@ namespace Grpc.Testing {
     private static readonly pb::MessageParser<ScenarioResultSummary> _parser = new pb::MessageParser<ScenarioResultSummary>(() => new ScenarioResultSummary());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<ScenarioResultSummary> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Testing.ControlReflection.Descriptor.MessageTypes[17]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ScenarioResultSummary() {
       OnConstruction();
     }
@@ -4994,6 +5337,7 @@ namespace Grpc.Testing {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ScenarioResultSummary(ScenarioResultSummary other) : this() {
       qps_ = other.qps_;
       qpsPerServerCore_ = other.qpsPerServerCore_;
@@ -5017,6 +5361,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ScenarioResultSummary Clone() {
       return new ScenarioResultSummary(this);
     }
@@ -5030,6 +5375,7 @@ namespace Grpc.Testing {
     /// For streaming benchmarks, an operation is processing of a single ping pong of request and response. 
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public double Qps {
       get { return qps_; }
       set {
@@ -5044,6 +5390,7 @@ namespace Grpc.Testing {
     /// QPS per server core.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public double QpsPerServerCore {
       get { return qpsPerServerCore_; }
       set {
@@ -5061,6 +5408,7 @@ namespace Grpc.Testing {
     /// Same explanation for the total client cpu load below.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public double ServerSystemTime {
       get { return serverSystemTime_; }
       set {
@@ -5075,6 +5423,7 @@ namespace Grpc.Testing {
     /// The total server cpu load based on user time across all server processes, expressed as percentage of a single cpu core. (85 => 85%, 125 => 125%)
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public double ServerUserTime {
       get { return serverUserTime_; }
       set {
@@ -5089,6 +5438,7 @@ namespace Grpc.Testing {
     /// The total client cpu load based on system time across all client processes, expressed as percentage of a single cpu core. (85 => 85%, 125 => 125%)
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public double ClientSystemTime {
       get { return clientSystemTime_; }
       set {
@@ -5103,6 +5453,7 @@ namespace Grpc.Testing {
     /// The total client cpu load based on user time across all client processes, expressed as percentage of a single cpu core. (85 => 85%, 125 => 125%)
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public double ClientUserTime {
       get { return clientUserTime_; }
       set {
@@ -5117,6 +5468,7 @@ namespace Grpc.Testing {
     /// X% latency percentiles (in nanoseconds)
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public double Latency50 {
       get { return latency50_; }
       set {
@@ -5128,6 +5480,7 @@ namespace Grpc.Testing {
     public const int Latency90FieldNumber = 8;
     private double latency90_;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public double Latency90 {
       get { return latency90_; }
       set {
@@ -5139,6 +5492,7 @@ namespace Grpc.Testing {
     public const int Latency95FieldNumber = 9;
     private double latency95_;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public double Latency95 {
       get { return latency95_; }
       set {
@@ -5150,6 +5504,7 @@ namespace Grpc.Testing {
     public const int Latency99FieldNumber = 10;
     private double latency99_;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public double Latency99 {
       get { return latency99_; }
       set {
@@ -5161,6 +5516,7 @@ namespace Grpc.Testing {
     public const int Latency999FieldNumber = 11;
     private double latency999_;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public double Latency999 {
       get { return latency999_; }
       set {
@@ -5175,6 +5531,7 @@ namespace Grpc.Testing {
     /// server cpu usage percentage
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public double ServerCpuUsage {
       get { return serverCpuUsage_; }
       set {
@@ -5189,6 +5546,7 @@ namespace Grpc.Testing {
     /// Number of requests that succeeded/failed
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public double SuccessfulRequestsPerSecond {
       get { return successfulRequestsPerSecond_; }
       set {
@@ -5200,6 +5558,7 @@ namespace Grpc.Testing {
     public const int FailedRequestsPerSecondFieldNumber = 14;
     private double failedRequestsPerSecond_;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public double FailedRequestsPerSecond {
       get { return failedRequestsPerSecond_; }
       set {
@@ -5214,6 +5573,7 @@ namespace Grpc.Testing {
     /// Number of polls called inside completion queue per request
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public double ClientPollsPerRequest {
       get { return clientPollsPerRequest_; }
       set {
@@ -5225,6 +5585,7 @@ namespace Grpc.Testing {
     public const int ServerPollsPerRequestFieldNumber = 16;
     private double serverPollsPerRequest_;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public double ServerPollsPerRequest {
       get { return serverPollsPerRequest_; }
       set {
@@ -5239,6 +5600,7 @@ namespace Grpc.Testing {
     /// Queries per CPU-sec over all servers or clients
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public double ServerQueriesPerCpuSec {
       get { return serverQueriesPerCpuSec_; }
       set {
@@ -5250,6 +5612,7 @@ namespace Grpc.Testing {
     public const int ClientQueriesPerCpuSecFieldNumber = 18;
     private double clientQueriesPerCpuSec_;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public double ClientQueriesPerCpuSec {
       get { return clientQueriesPerCpuSec_; }
       set {
@@ -5258,11 +5621,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as ScenarioResultSummary);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(ScenarioResultSummary other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -5292,6 +5657,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (Qps != 0D) hash ^= pbc::ProtobufEqualityComparers.BitwiseDoubleEqualityComparer.GetHashCode(Qps);
@@ -5319,11 +5685,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -5408,6 +5776,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (Qps != 0D) {
         output.WriteRawTag(9);
@@ -5488,6 +5857,7 @@ namespace Grpc.Testing {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (Qps != 0D) {
@@ -5551,6 +5921,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(ScenarioResultSummary other) {
       if (other == null) {
         return;
@@ -5613,6 +5984,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -5702,6 +6074,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -5799,19 +6172,23 @@ namespace Grpc.Testing {
     private static readonly pb::MessageParser<ScenarioResult> _parser = new pb::MessageParser<ScenarioResult>(() => new ScenarioResult());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<ScenarioResult> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Testing.ControlReflection.Descriptor.MessageTypes[18]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ScenarioResult() {
       OnConstruction();
     }
@@ -5819,6 +6196,7 @@ namespace Grpc.Testing {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ScenarioResult(ScenarioResult other) : this() {
       scenario_ = other.scenario_ != null ? other.scenario_.Clone() : null;
       latencies_ = other.latencies_ != null ? other.latencies_.Clone() : null;
@@ -5833,6 +6211,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ScenarioResult Clone() {
       return new ScenarioResult(this);
     }
@@ -5844,6 +6223,7 @@ namespace Grpc.Testing {
     /// Inputs used to run the scenario.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public global::Grpc.Testing.Scenario Scenario {
       get { return scenario_; }
       set {
@@ -5858,6 +6238,7 @@ namespace Grpc.Testing {
     /// Histograms from all clients merged into one histogram.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public global::Grpc.Testing.HistogramData Latencies {
       get { return latencies_; }
       set {
@@ -5874,6 +6255,7 @@ namespace Grpc.Testing {
     /// Client stats for each client
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public pbc::RepeatedField<global::Grpc.Testing.ClientStats> ClientStats {
       get { return clientStats_; }
     }
@@ -5887,6 +6269,7 @@ namespace Grpc.Testing {
     /// Server stats for each server
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public pbc::RepeatedField<global::Grpc.Testing.ServerStats> ServerStats {
       get { return serverStats_; }
     }
@@ -5900,6 +6283,7 @@ namespace Grpc.Testing {
     /// Number of cores available to each server
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public pbc::RepeatedField<int> ServerCores {
       get { return serverCores_; }
     }
@@ -5911,6 +6295,7 @@ namespace Grpc.Testing {
     /// An after-the-fact computed summary
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public global::Grpc.Testing.ScenarioResultSummary Summary {
       get { return summary_; }
       set {
@@ -5927,6 +6312,7 @@ namespace Grpc.Testing {
     /// Information on success or failure of each worker
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public pbc::RepeatedField<bool> ClientSuccess {
       get { return clientSuccess_; }
     }
@@ -5937,6 +6323,7 @@ namespace Grpc.Testing {
         = pb::FieldCodec.ForBool(66);
     private readonly pbc::RepeatedField<bool> serverSuccess_ = new pbc::RepeatedField<bool>();
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public pbc::RepeatedField<bool> ServerSuccess {
       get { return serverSuccess_; }
     }
@@ -5950,16 +6337,19 @@ namespace Grpc.Testing {
     /// Number of failed requests (one row per status code seen)
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public pbc::RepeatedField<global::Grpc.Testing.RequestResultCount> RequestResults {
       get { return requestResults_; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as ScenarioResult);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(ScenarioResult other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -5980,6 +6370,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (scenario_ != null) hash ^= Scenario.GetHashCode();
@@ -5998,11 +6389,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -6033,6 +6426,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (scenario_ != null) {
         output.WriteRawTag(10);
@@ -6059,6 +6453,7 @@ namespace Grpc.Testing {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (scenario_ != null) {
@@ -6083,6 +6478,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(ScenarioResult other) {
       if (other == null) {
         return;
@@ -6115,6 +6511,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -6180,6 +6577,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
index cbcae85..2f877f1 100644 (file)
@@ -51,19 +51,23 @@ namespace Grpc.Core {
     private static readonly pb::MessageParser<Bucket> _parser = new pb::MessageParser<Bucket>(() => new Bucket());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<Bucket> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Core.StatsReflection.Descriptor.MessageTypes[0]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public Bucket() {
       OnConstruction();
     }
@@ -71,6 +75,7 @@ namespace Grpc.Core {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public Bucket(Bucket other) : this() {
       start_ = other.start_;
       count_ = other.count_;
@@ -78,6 +83,7 @@ namespace Grpc.Core {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public Bucket Clone() {
       return new Bucket(this);
     }
@@ -86,6 +92,7 @@ namespace Grpc.Core {
     public const int StartFieldNumber = 1;
     private double start_;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public double Start {
       get { return start_; }
       set {
@@ -97,6 +104,7 @@ namespace Grpc.Core {
     public const int CountFieldNumber = 2;
     private ulong count_;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ulong Count {
       get { return count_; }
       set {
@@ -105,11 +113,13 @@ namespace Grpc.Core {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as Bucket);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(Bucket other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -123,6 +133,7 @@ namespace Grpc.Core {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (Start != 0D) hash ^= pbc::ProtobufEqualityComparers.BitwiseDoubleEqualityComparer.GetHashCode(Start);
@@ -134,11 +145,13 @@ namespace Grpc.Core {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -159,6 +172,7 @@ namespace Grpc.Core {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (Start != 0D) {
         output.WriteRawTag(9);
@@ -175,6 +189,7 @@ namespace Grpc.Core {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (Start != 0D) {
@@ -190,6 +205,7 @@ namespace Grpc.Core {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(Bucket other) {
       if (other == null) {
         return;
@@ -204,6 +220,7 @@ namespace Grpc.Core {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -229,6 +246,7 @@ namespace Grpc.Core {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -259,19 +277,23 @@ namespace Grpc.Core {
     private static readonly pb::MessageParser<Histogram> _parser = new pb::MessageParser<Histogram>(() => new Histogram());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<Histogram> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Core.StatsReflection.Descriptor.MessageTypes[1]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public Histogram() {
       OnConstruction();
     }
@@ -279,12 +301,14 @@ namespace Grpc.Core {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public Histogram(Histogram other) : this() {
       buckets_ = other.buckets_.Clone();
       _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public Histogram Clone() {
       return new Histogram(this);
     }
@@ -295,16 +319,19 @@ namespace Grpc.Core {
         = pb::FieldCodec.ForMessage(10, global::Grpc.Core.Bucket.Parser);
     private readonly pbc::RepeatedField<global::Grpc.Core.Bucket> buckets_ = new pbc::RepeatedField<global::Grpc.Core.Bucket>();
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public pbc::RepeatedField<global::Grpc.Core.Bucket> Buckets {
       get { return buckets_; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as Histogram);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(Histogram other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -317,6 +344,7 @@ namespace Grpc.Core {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       hash ^= buckets_.GetHashCode();
@@ -327,11 +355,13 @@ namespace Grpc.Core {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -345,6 +375,7 @@ namespace Grpc.Core {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       buckets_.WriteTo(ref output, _repeated_buckets_codec);
       if (_unknownFields != null) {
@@ -354,6 +385,7 @@ namespace Grpc.Core {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       size += buckets_.CalculateSize(_repeated_buckets_codec);
@@ -364,6 +396,7 @@ namespace Grpc.Core {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(Histogram other) {
       if (other == null) {
         return;
@@ -373,6 +406,7 @@ namespace Grpc.Core {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -394,6 +428,7 @@ namespace Grpc.Core {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -420,19 +455,23 @@ namespace Grpc.Core {
     private static readonly pb::MessageParser<Metric> _parser = new pb::MessageParser<Metric>(() => new Metric());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<Metric> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Core.StatsReflection.Descriptor.MessageTypes[2]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public Metric() {
       OnConstruction();
     }
@@ -440,6 +479,7 @@ namespace Grpc.Core {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public Metric(Metric other) : this() {
       name_ = other.name_;
       switch (other.ValueCase) {
@@ -455,6 +495,7 @@ namespace Grpc.Core {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public Metric Clone() {
       return new Metric(this);
     }
@@ -463,6 +504,7 @@ namespace Grpc.Core {
     public const int NameFieldNumber = 1;
     private string name_ = "";
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public string Name {
       get { return name_; }
       set {
@@ -473,6 +515,7 @@ namespace Grpc.Core {
     /// <summary>Field number for the "count" field.</summary>
     public const int CountFieldNumber = 10;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ulong Count {
       get { return valueCase_ == ValueOneofCase.Count ? (ulong) value_ : 0UL; }
       set {
@@ -484,6 +527,7 @@ namespace Grpc.Core {
     /// <summary>Field number for the "histogram" field.</summary>
     public const int HistogramFieldNumber = 11;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public global::Grpc.Core.Histogram Histogram {
       get { return valueCase_ == ValueOneofCase.Histogram ? (global::Grpc.Core.Histogram) value_ : null; }
       set {
@@ -501,22 +545,26 @@ namespace Grpc.Core {
     }
     private ValueOneofCase valueCase_ = ValueOneofCase.None;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ValueOneofCase ValueCase {
       get { return valueCase_; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void ClearValue() {
       valueCase_ = ValueOneofCase.None;
       value_ = null;
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as Metric);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(Metric other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -532,6 +580,7 @@ namespace Grpc.Core {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (Name.Length != 0) hash ^= Name.GetHashCode();
@@ -545,11 +594,13 @@ namespace Grpc.Core {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -574,6 +625,7 @@ namespace Grpc.Core {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (Name.Length != 0) {
         output.WriteRawTag(10);
@@ -594,6 +646,7 @@ namespace Grpc.Core {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (Name.Length != 0) {
@@ -612,6 +665,7 @@ namespace Grpc.Core {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(Metric other) {
       if (other == null) {
         return;
@@ -635,6 +689,7 @@ namespace Grpc.Core {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -669,6 +724,7 @@ namespace Grpc.Core {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -708,19 +764,23 @@ namespace Grpc.Core {
     private static readonly pb::MessageParser<Stats> _parser = new pb::MessageParser<Stats>(() => new Stats());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<Stats> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Core.StatsReflection.Descriptor.MessageTypes[3]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public Stats() {
       OnConstruction();
     }
@@ -728,12 +788,14 @@ namespace Grpc.Core {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public Stats(Stats other) : this() {
       metrics_ = other.metrics_.Clone();
       _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public Stats Clone() {
       return new Stats(this);
     }
@@ -744,16 +806,19 @@ namespace Grpc.Core {
         = pb::FieldCodec.ForMessage(10, global::Grpc.Core.Metric.Parser);
     private readonly pbc::RepeatedField<global::Grpc.Core.Metric> metrics_ = new pbc::RepeatedField<global::Grpc.Core.Metric>();
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public pbc::RepeatedField<global::Grpc.Core.Metric> Metrics {
       get { return metrics_; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as Stats);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(Stats other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -766,6 +831,7 @@ namespace Grpc.Core {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       hash ^= metrics_.GetHashCode();
@@ -776,11 +842,13 @@ namespace Grpc.Core {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -794,6 +862,7 @@ namespace Grpc.Core {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       metrics_.WriteTo(ref output, _repeated_metrics_codec);
       if (_unknownFields != null) {
@@ -803,6 +872,7 @@ namespace Grpc.Core {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       size += metrics_.CalculateSize(_repeated_metrics_codec);
@@ -813,6 +883,7 @@ namespace Grpc.Core {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(Stats other) {
       if (other == null) {
         return;
@@ -822,6 +893,7 @@ namespace Grpc.Core {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -843,6 +915,7 @@ namespace Grpc.Core {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
index 861caa8..f68680b 100644 (file)
@@ -73,19 +73,23 @@ namespace Grpc.Testing {
     private static readonly pb::MessageParser<DebugInfo> _parser = new pb::MessageParser<DebugInfo>(() => new DebugInfo());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<DebugInfo> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Testing.EchoMessagesReflection.Descriptor.MessageTypes[0]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public DebugInfo() {
       OnConstruction();
     }
@@ -93,6 +97,7 @@ namespace Grpc.Testing {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public DebugInfo(DebugInfo other) : this() {
       stackEntries_ = other.stackEntries_.Clone();
       detail_ = other.detail_;
@@ -100,6 +105,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public DebugInfo Clone() {
       return new DebugInfo(this);
     }
@@ -110,6 +116,7 @@ namespace Grpc.Testing {
         = pb::FieldCodec.ForString(10);
     private readonly pbc::RepeatedField<string> stackEntries_ = new pbc::RepeatedField<string>();
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public pbc::RepeatedField<string> StackEntries {
       get { return stackEntries_; }
     }
@@ -118,6 +125,7 @@ namespace Grpc.Testing {
     public const int DetailFieldNumber = 2;
     private string detail_ = "";
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public string Detail {
       get { return detail_; }
       set {
@@ -126,11 +134,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as DebugInfo);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(DebugInfo other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -144,6 +154,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       hash ^= stackEntries_.GetHashCode();
@@ -155,11 +166,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -177,6 +190,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       stackEntries_.WriteTo(ref output, _repeated_stackEntries_codec);
       if (Detail.Length != 0) {
@@ -190,6 +204,7 @@ namespace Grpc.Testing {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       size += stackEntries_.CalculateSize(_repeated_stackEntries_codec);
@@ -203,6 +218,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(DebugInfo other) {
       if (other == null) {
         return;
@@ -215,6 +231,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -240,6 +257,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -273,19 +291,23 @@ namespace Grpc.Testing {
     private static readonly pb::MessageParser<ErrorStatus> _parser = new pb::MessageParser<ErrorStatus>(() => new ErrorStatus());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<ErrorStatus> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Testing.EchoMessagesReflection.Descriptor.MessageTypes[1]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ErrorStatus() {
       OnConstruction();
     }
@@ -293,6 +315,7 @@ namespace Grpc.Testing {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ErrorStatus(ErrorStatus other) : this() {
       code_ = other.code_;
       errorMessage_ = other.errorMessage_;
@@ -301,6 +324,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ErrorStatus Clone() {
       return new ErrorStatus(this);
     }
@@ -309,6 +333,7 @@ namespace Grpc.Testing {
     public const int CodeFieldNumber = 1;
     private int code_;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int Code {
       get { return code_; }
       set {
@@ -320,6 +345,7 @@ namespace Grpc.Testing {
     public const int ErrorMessageFieldNumber = 2;
     private string errorMessage_ = "";
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public string ErrorMessage {
       get { return errorMessage_; }
       set {
@@ -331,6 +357,7 @@ namespace Grpc.Testing {
     public const int BinaryErrorDetailsFieldNumber = 3;
     private string binaryErrorDetails_ = "";
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public string BinaryErrorDetails {
       get { return binaryErrorDetails_; }
       set {
@@ -339,11 +366,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as ErrorStatus);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(ErrorStatus other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -358,6 +387,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (Code != 0) hash ^= Code.GetHashCode();
@@ -370,11 +400,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -399,6 +431,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (Code != 0) {
         output.WriteRawTag(8);
@@ -419,6 +452,7 @@ namespace Grpc.Testing {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (Code != 0) {
@@ -437,6 +471,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(ErrorStatus other) {
       if (other == null) {
         return;
@@ -454,6 +489,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -483,6 +519,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -517,19 +554,23 @@ namespace Grpc.Testing {
     private static readonly pb::MessageParser<RequestParams> _parser = new pb::MessageParser<RequestParams>(() => new RequestParams());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<RequestParams> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Testing.EchoMessagesReflection.Descriptor.MessageTypes[2]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public RequestParams() {
       OnConstruction();
     }
@@ -537,6 +578,7 @@ namespace Grpc.Testing {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public RequestParams(RequestParams other) : this() {
       echoDeadline_ = other.echoDeadline_;
       clientCancelAfterUs_ = other.clientCancelAfterUs_;
@@ -560,6 +602,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public RequestParams Clone() {
       return new RequestParams(this);
     }
@@ -568,6 +611,7 @@ namespace Grpc.Testing {
     public const int EchoDeadlineFieldNumber = 1;
     private bool echoDeadline_;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool EchoDeadline {
       get { return echoDeadline_; }
       set {
@@ -579,6 +623,7 @@ namespace Grpc.Testing {
     public const int ClientCancelAfterUsFieldNumber = 2;
     private int clientCancelAfterUs_;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int ClientCancelAfterUs {
       get { return clientCancelAfterUs_; }
       set {
@@ -590,6 +635,7 @@ namespace Grpc.Testing {
     public const int ServerCancelAfterUsFieldNumber = 3;
     private int serverCancelAfterUs_;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int ServerCancelAfterUs {
       get { return serverCancelAfterUs_; }
       set {
@@ -601,6 +647,7 @@ namespace Grpc.Testing {
     public const int EchoMetadataFieldNumber = 4;
     private bool echoMetadata_;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool EchoMetadata {
       get { return echoMetadata_; }
       set {
@@ -612,6 +659,7 @@ namespace Grpc.Testing {
     public const int CheckAuthContextFieldNumber = 5;
     private bool checkAuthContext_;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool CheckAuthContext {
       get { return checkAuthContext_; }
       set {
@@ -623,6 +671,7 @@ namespace Grpc.Testing {
     public const int ResponseMessageLengthFieldNumber = 6;
     private int responseMessageLength_;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int ResponseMessageLength {
       get { return responseMessageLength_; }
       set {
@@ -634,6 +683,7 @@ namespace Grpc.Testing {
     public const int EchoPeerFieldNumber = 7;
     private bool echoPeer_;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool EchoPeer {
       get { return echoPeer_; }
       set {
@@ -648,6 +698,7 @@ namespace Grpc.Testing {
     /// will force check_auth_context.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public string ExpectedClientIdentity {
       get { return expectedClientIdentity_; }
       set {
@@ -659,6 +710,7 @@ namespace Grpc.Testing {
     public const int SkipCancelledCheckFieldNumber = 9;
     private bool skipCancelledCheck_;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool SkipCancelledCheck {
       get { return skipCancelledCheck_; }
       set {
@@ -670,6 +722,7 @@ namespace Grpc.Testing {
     public const int ExpectedTransportSecurityTypeFieldNumber = 10;
     private string expectedTransportSecurityType_ = "";
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public string ExpectedTransportSecurityType {
       get { return expectedTransportSecurityType_; }
       set {
@@ -681,6 +734,7 @@ namespace Grpc.Testing {
     public const int DebugInfoFieldNumber = 11;
     private global::Grpc.Testing.DebugInfo debugInfo_;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public global::Grpc.Testing.DebugInfo DebugInfo {
       get { return debugInfo_; }
       set {
@@ -695,6 +749,7 @@ namespace Grpc.Testing {
     /// Server should not see a request with this set.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool ServerDie {
       get { return serverDie_; }
       set {
@@ -706,6 +761,7 @@ namespace Grpc.Testing {
     public const int BinaryErrorDetailsFieldNumber = 13;
     private string binaryErrorDetails_ = "";
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public string BinaryErrorDetails {
       get { return binaryErrorDetails_; }
       set {
@@ -717,6 +773,7 @@ namespace Grpc.Testing {
     public const int ExpectedErrorFieldNumber = 14;
     private global::Grpc.Testing.ErrorStatus expectedError_;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public global::Grpc.Testing.ErrorStatus ExpectedError {
       get { return expectedError_; }
       set {
@@ -731,6 +788,7 @@ namespace Grpc.Testing {
     /// sleep when invoking server for deadline tests
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int ServerSleepUs {
       get { return serverSleepUs_; }
       set {
@@ -745,6 +803,7 @@ namespace Grpc.Testing {
     /// which backend to send request to
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int BackendChannelIdx {
       get { return backendChannelIdx_; }
       set {
@@ -756,6 +815,7 @@ namespace Grpc.Testing {
     public const int EchoMetadataInitiallyFieldNumber = 17;
     private bool echoMetadataInitially_;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool EchoMetadataInitially {
       get { return echoMetadataInitially_; }
       set {
@@ -767,6 +827,7 @@ namespace Grpc.Testing {
     public const int ServerNotifyClientWhenStartedFieldNumber = 18;
     private bool serverNotifyClientWhenStarted_;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool ServerNotifyClientWhenStarted {
       get { return serverNotifyClientWhenStarted_; }
       set {
@@ -775,11 +836,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as RequestParams);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(RequestParams other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -809,6 +872,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (EchoDeadline != false) hash ^= EchoDeadline.GetHashCode();
@@ -836,11 +900,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -925,6 +991,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (EchoDeadline != false) {
         output.WriteRawTag(8);
@@ -1005,6 +1072,7 @@ namespace Grpc.Testing {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (EchoDeadline != false) {
@@ -1068,6 +1136,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(RequestParams other) {
       if (other == null) {
         return;
@@ -1136,6 +1205,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -1231,6 +1301,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -1331,19 +1402,23 @@ namespace Grpc.Testing {
     private static readonly pb::MessageParser<EchoRequest> _parser = new pb::MessageParser<EchoRequest>(() => new EchoRequest());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<EchoRequest> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Testing.EchoMessagesReflection.Descriptor.MessageTypes[3]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public EchoRequest() {
       OnConstruction();
     }
@@ -1351,6 +1426,7 @@ namespace Grpc.Testing {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public EchoRequest(EchoRequest other) : this() {
       message_ = other.message_;
       param_ = other.param_ != null ? other.param_.Clone() : null;
@@ -1358,6 +1434,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public EchoRequest Clone() {
       return new EchoRequest(this);
     }
@@ -1366,6 +1443,7 @@ namespace Grpc.Testing {
     public const int MessageFieldNumber = 1;
     private string message_ = "";
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public string Message {
       get { return message_; }
       set {
@@ -1377,6 +1455,7 @@ namespace Grpc.Testing {
     public const int ParamFieldNumber = 2;
     private global::Grpc.Testing.RequestParams param_;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public global::Grpc.Testing.RequestParams Param {
       get { return param_; }
       set {
@@ -1385,11 +1464,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as EchoRequest);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(EchoRequest other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -1403,6 +1484,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (Message.Length != 0) hash ^= Message.GetHashCode();
@@ -1414,11 +1496,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -1439,6 +1523,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (Message.Length != 0) {
         output.WriteRawTag(10);
@@ -1455,6 +1540,7 @@ namespace Grpc.Testing {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (Message.Length != 0) {
@@ -1470,6 +1556,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(EchoRequest other) {
       if (other == null) {
         return;
@@ -1487,6 +1574,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -1515,6 +1603,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -1548,19 +1637,23 @@ namespace Grpc.Testing {
     private static readonly pb::MessageParser<ResponseParams> _parser = new pb::MessageParser<ResponseParams>(() => new ResponseParams());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<ResponseParams> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Testing.EchoMessagesReflection.Descriptor.MessageTypes[4]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ResponseParams() {
       OnConstruction();
     }
@@ -1568,6 +1661,7 @@ namespace Grpc.Testing {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ResponseParams(ResponseParams other) : this() {
       requestDeadline_ = other.requestDeadline_;
       host_ = other.host_;
@@ -1576,6 +1670,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ResponseParams Clone() {
       return new ResponseParams(this);
     }
@@ -1584,6 +1679,7 @@ namespace Grpc.Testing {
     public const int RequestDeadlineFieldNumber = 1;
     private long requestDeadline_;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public long RequestDeadline {
       get { return requestDeadline_; }
       set {
@@ -1595,6 +1691,7 @@ namespace Grpc.Testing {
     public const int HostFieldNumber = 2;
     private string host_ = "";
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public string Host {
       get { return host_; }
       set {
@@ -1606,6 +1703,7 @@ namespace Grpc.Testing {
     public const int PeerFieldNumber = 3;
     private string peer_ = "";
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public string Peer {
       get { return peer_; }
       set {
@@ -1614,11 +1712,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as ResponseParams);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(ResponseParams other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -1633,6 +1733,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (RequestDeadline != 0L) hash ^= RequestDeadline.GetHashCode();
@@ -1645,11 +1746,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -1674,6 +1777,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (RequestDeadline != 0L) {
         output.WriteRawTag(8);
@@ -1694,6 +1798,7 @@ namespace Grpc.Testing {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (RequestDeadline != 0L) {
@@ -1712,6 +1817,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(ResponseParams other) {
       if (other == null) {
         return;
@@ -1729,6 +1835,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -1758,6 +1865,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -1792,19 +1900,23 @@ namespace Grpc.Testing {
     private static readonly pb::MessageParser<EchoResponse> _parser = new pb::MessageParser<EchoResponse>(() => new EchoResponse());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<EchoResponse> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Testing.EchoMessagesReflection.Descriptor.MessageTypes[5]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public EchoResponse() {
       OnConstruction();
     }
@@ -1812,6 +1924,7 @@ namespace Grpc.Testing {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public EchoResponse(EchoResponse other) : this() {
       message_ = other.message_;
       param_ = other.param_ != null ? other.param_.Clone() : null;
@@ -1819,6 +1932,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public EchoResponse Clone() {
       return new EchoResponse(this);
     }
@@ -1827,6 +1941,7 @@ namespace Grpc.Testing {
     public const int MessageFieldNumber = 1;
     private string message_ = "";
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public string Message {
       get { return message_; }
       set {
@@ -1838,6 +1953,7 @@ namespace Grpc.Testing {
     public const int ParamFieldNumber = 2;
     private global::Grpc.Testing.ResponseParams param_;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public global::Grpc.Testing.ResponseParams Param {
       get { return param_; }
       set {
@@ -1846,11 +1962,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as EchoResponse);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(EchoResponse other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -1864,6 +1982,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (Message.Length != 0) hash ^= Message.GetHashCode();
@@ -1875,11 +1994,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -1900,6 +2021,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (Message.Length != 0) {
         output.WriteRawTag(10);
@@ -1916,6 +2038,7 @@ namespace Grpc.Testing {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (Message.Length != 0) {
@@ -1931,6 +2054,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(EchoResponse other) {
       if (other == null) {
         return;
@@ -1948,6 +2072,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -1976,6 +2101,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
index 82bcfba..dc1a2e7 100644 (file)
@@ -53,19 +53,23 @@ namespace Grpc.Testing {
     private static readonly pb::MessageParser<Empty> _parser = new pb::MessageParser<Empty>(() => new Empty());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<Empty> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Testing.EmptyReflection.Descriptor.MessageTypes[0]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public Empty() {
       OnConstruction();
     }
@@ -73,21 +77,25 @@ namespace Grpc.Testing {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public Empty(Empty other) : this() {
       _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public Empty Clone() {
       return new Empty(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as Empty);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(Empty other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -99,6 +107,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (_unknownFields != null) {
@@ -108,11 +117,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -125,6 +136,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (_unknownFields != null) {
         _unknownFields.WriteTo(ref output);
@@ -133,6 +145,7 @@ namespace Grpc.Testing {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (_unknownFields != null) {
@@ -142,6 +155,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(Empty other) {
       if (other == null) {
         return;
@@ -150,6 +164,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -167,6 +182,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
index bdc31f2..8c051ce 100644 (file)
@@ -182,19 +182,23 @@ namespace Grpc.Testing {
     private static readonly pb::MessageParser<BoolValue> _parser = new pb::MessageParser<BoolValue>(() => new BoolValue());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<BoolValue> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Testing.MessagesReflection.Descriptor.MessageTypes[0]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public BoolValue() {
       OnConstruction();
     }
@@ -202,12 +206,14 @@ namespace Grpc.Testing {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public BoolValue(BoolValue other) : this() {
       value_ = other.value_;
       _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public BoolValue Clone() {
       return new BoolValue(this);
     }
@@ -219,6 +225,7 @@ namespace Grpc.Testing {
     /// The bool value.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Value {
       get { return value_; }
       set {
@@ -227,11 +234,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as BoolValue);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(BoolValue other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -244,6 +253,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (Value != false) hash ^= Value.GetHashCode();
@@ -254,11 +264,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -275,6 +287,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (Value != false) {
         output.WriteRawTag(8);
@@ -287,6 +300,7 @@ namespace Grpc.Testing {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (Value != false) {
@@ -299,6 +313,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(BoolValue other) {
       if (other == null) {
         return;
@@ -310,6 +325,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -331,6 +347,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -360,19 +377,23 @@ namespace Grpc.Testing {
     private static readonly pb::MessageParser<Payload> _parser = new pb::MessageParser<Payload>(() => new Payload());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<Payload> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Testing.MessagesReflection.Descriptor.MessageTypes[1]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public Payload() {
       OnConstruction();
     }
@@ -380,6 +401,7 @@ namespace Grpc.Testing {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public Payload(Payload other) : this() {
       type_ = other.type_;
       body_ = other.body_;
@@ -387,6 +409,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public Payload Clone() {
       return new Payload(this);
     }
@@ -398,6 +421,7 @@ namespace Grpc.Testing {
     /// The type of data in body.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public global::Grpc.Testing.PayloadType Type {
       get { return type_; }
       set {
@@ -412,6 +436,7 @@ namespace Grpc.Testing {
     /// Primary contents of payload.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public pb::ByteString Body {
       get { return body_; }
       set {
@@ -420,11 +445,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as Payload);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(Payload other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -438,6 +465,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (Type != global::Grpc.Testing.PayloadType.Compressable) hash ^= Type.GetHashCode();
@@ -449,11 +477,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -474,6 +504,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (Type != global::Grpc.Testing.PayloadType.Compressable) {
         output.WriteRawTag(8);
@@ -490,6 +521,7 @@ namespace Grpc.Testing {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (Type != global::Grpc.Testing.PayloadType.Compressable) {
@@ -505,6 +537,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(Payload other) {
       if (other == null) {
         return;
@@ -519,6 +552,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -544,6 +578,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -578,19 +613,23 @@ namespace Grpc.Testing {
     private static readonly pb::MessageParser<EchoStatus> _parser = new pb::MessageParser<EchoStatus>(() => new EchoStatus());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<EchoStatus> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Testing.MessagesReflection.Descriptor.MessageTypes[2]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public EchoStatus() {
       OnConstruction();
     }
@@ -598,6 +637,7 @@ namespace Grpc.Testing {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public EchoStatus(EchoStatus other) : this() {
       code_ = other.code_;
       message_ = other.message_;
@@ -605,6 +645,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public EchoStatus Clone() {
       return new EchoStatus(this);
     }
@@ -613,6 +654,7 @@ namespace Grpc.Testing {
     public const int CodeFieldNumber = 1;
     private int code_;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int Code {
       get { return code_; }
       set {
@@ -624,6 +666,7 @@ namespace Grpc.Testing {
     public const int MessageFieldNumber = 2;
     private string message_ = "";
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public string Message {
       get { return message_; }
       set {
@@ -632,11 +675,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as EchoStatus);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(EchoStatus other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -650,6 +695,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (Code != 0) hash ^= Code.GetHashCode();
@@ -661,11 +707,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -686,6 +734,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (Code != 0) {
         output.WriteRawTag(8);
@@ -702,6 +751,7 @@ namespace Grpc.Testing {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (Code != 0) {
@@ -717,6 +767,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(EchoStatus other) {
       if (other == null) {
         return;
@@ -731,6 +782,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -756,6 +808,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -789,19 +842,23 @@ namespace Grpc.Testing {
     private static readonly pb::MessageParser<SimpleRequest> _parser = new pb::MessageParser<SimpleRequest>(() => new SimpleRequest());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<SimpleRequest> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Testing.MessagesReflection.Descriptor.MessageTypes[3]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public SimpleRequest() {
       OnConstruction();
     }
@@ -809,6 +866,7 @@ namespace Grpc.Testing {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public SimpleRequest(SimpleRequest other) : this() {
       responseType_ = other.responseType_;
       responseSize_ = other.responseSize_;
@@ -824,6 +882,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public SimpleRequest Clone() {
       return new SimpleRequest(this);
     }
@@ -836,6 +895,7 @@ namespace Grpc.Testing {
     /// If response_type is RANDOM, server randomly chooses one from other formats.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public global::Grpc.Testing.PayloadType ResponseType {
       get { return responseType_; }
       set {
@@ -850,6 +910,7 @@ namespace Grpc.Testing {
     /// Desired payload size in the response from the server.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int ResponseSize {
       get { return responseSize_; }
       set {
@@ -864,6 +925,7 @@ namespace Grpc.Testing {
     /// Optional input payload sent along with the request.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public global::Grpc.Testing.Payload Payload {
       get { return payload_; }
       set {
@@ -878,6 +940,7 @@ namespace Grpc.Testing {
     /// Whether SimpleResponse should include username.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool FillUsername {
       get { return fillUsername_; }
       set {
@@ -892,6 +955,7 @@ namespace Grpc.Testing {
     /// Whether SimpleResponse should include OAuth scope.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool FillOauthScope {
       get { return fillOauthScope_; }
       set {
@@ -909,6 +973,7 @@ namespace Grpc.Testing {
     /// the response's compression status.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public global::Grpc.Testing.BoolValue ResponseCompressed {
       get { return responseCompressed_; }
       set {
@@ -923,6 +988,7 @@ namespace Grpc.Testing {
     /// Whether server should return a given status
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public global::Grpc.Testing.EchoStatus ResponseStatus {
       get { return responseStatus_; }
       set {
@@ -937,6 +1003,7 @@ namespace Grpc.Testing {
     /// Whether the server should expect this request to be compressed.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public global::Grpc.Testing.BoolValue ExpectCompressed {
       get { return expectCompressed_; }
       set {
@@ -951,6 +1018,7 @@ namespace Grpc.Testing {
     /// Whether SimpleResponse should include server_id.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool FillServerId {
       get { return fillServerId_; }
       set {
@@ -965,6 +1033,7 @@ namespace Grpc.Testing {
     /// Whether SimpleResponse should include grpclb_route_type.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool FillGrpclbRouteType {
       get { return fillGrpclbRouteType_; }
       set {
@@ -973,11 +1042,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as SimpleRequest);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(SimpleRequest other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -999,6 +1070,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (ResponseType != global::Grpc.Testing.PayloadType.Compressable) hash ^= ResponseType.GetHashCode();
@@ -1018,11 +1090,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -1075,6 +1149,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (ResponseType != global::Grpc.Testing.PayloadType.Compressable) {
         output.WriteRawTag(8);
@@ -1123,6 +1198,7 @@ namespace Grpc.Testing {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (ResponseType != global::Grpc.Testing.PayloadType.Compressable) {
@@ -1162,6 +1238,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(SimpleRequest other) {
       if (other == null) {
         return;
@@ -1212,6 +1289,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -1281,6 +1359,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -1358,19 +1437,23 @@ namespace Grpc.Testing {
     private static readonly pb::MessageParser<SimpleResponse> _parser = new pb::MessageParser<SimpleResponse>(() => new SimpleResponse());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<SimpleResponse> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Testing.MessagesReflection.Descriptor.MessageTypes[4]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public SimpleResponse() {
       OnConstruction();
     }
@@ -1378,6 +1461,7 @@ namespace Grpc.Testing {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public SimpleResponse(SimpleResponse other) : this() {
       payload_ = other.payload_ != null ? other.payload_.Clone() : null;
       username_ = other.username_;
@@ -1389,6 +1473,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public SimpleResponse Clone() {
       return new SimpleResponse(this);
     }
@@ -1400,6 +1485,7 @@ namespace Grpc.Testing {
     /// Payload to increase message size.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public global::Grpc.Testing.Payload Payload {
       get { return payload_; }
       set {
@@ -1415,6 +1501,7 @@ namespace Grpc.Testing {
     /// successful when the client expected it.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public string Username {
       get { return username_; }
       set {
@@ -1429,6 +1516,7 @@ namespace Grpc.Testing {
     /// OAuth scope.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public string OauthScope {
       get { return oauthScope_; }
       set {
@@ -1444,6 +1532,7 @@ namespace Grpc.Testing {
     /// but the same across all RPC's made to a particular server instance.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public string ServerId {
       get { return serverId_; }
       set {
@@ -1458,6 +1547,7 @@ namespace Grpc.Testing {
     /// gRPCLB Path.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public global::Grpc.Testing.GrpclbRouteType GrpclbRouteType {
       get { return grpclbRouteType_; }
       set {
@@ -1472,6 +1562,7 @@ namespace Grpc.Testing {
     /// Server hostname.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public string Hostname {
       get { return hostname_; }
       set {
@@ -1480,11 +1571,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as SimpleResponse);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(SimpleResponse other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -1502,6 +1595,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (payload_ != null) hash ^= Payload.GetHashCode();
@@ -1517,11 +1611,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -1558,6 +1654,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (payload_ != null) {
         output.WriteRawTag(10);
@@ -1590,6 +1687,7 @@ namespace Grpc.Testing {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (payload_ != null) {
@@ -1617,6 +1715,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(SimpleResponse other) {
       if (other == null) {
         return;
@@ -1646,6 +1745,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -1690,6 +1790,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -1742,19 +1843,23 @@ namespace Grpc.Testing {
     private static readonly pb::MessageParser<StreamingInputCallRequest> _parser = new pb::MessageParser<StreamingInputCallRequest>(() => new StreamingInputCallRequest());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<StreamingInputCallRequest> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Testing.MessagesReflection.Descriptor.MessageTypes[5]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public StreamingInputCallRequest() {
       OnConstruction();
     }
@@ -1762,6 +1867,7 @@ namespace Grpc.Testing {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public StreamingInputCallRequest(StreamingInputCallRequest other) : this() {
       payload_ = other.payload_ != null ? other.payload_.Clone() : null;
       expectCompressed_ = other.expectCompressed_ != null ? other.expectCompressed_.Clone() : null;
@@ -1769,6 +1875,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public StreamingInputCallRequest Clone() {
       return new StreamingInputCallRequest(this);
     }
@@ -1780,6 +1887,7 @@ namespace Grpc.Testing {
     /// Optional input payload sent along with the request.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public global::Grpc.Testing.Payload Payload {
       get { return payload_; }
       set {
@@ -1797,6 +1905,7 @@ namespace Grpc.Testing {
     /// the request's compression status.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public global::Grpc.Testing.BoolValue ExpectCompressed {
       get { return expectCompressed_; }
       set {
@@ -1805,11 +1914,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as StreamingInputCallRequest);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(StreamingInputCallRequest other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -1823,6 +1934,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (payload_ != null) hash ^= Payload.GetHashCode();
@@ -1834,11 +1946,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -1859,6 +1973,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (payload_ != null) {
         output.WriteRawTag(10);
@@ -1875,6 +1990,7 @@ namespace Grpc.Testing {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (payload_ != null) {
@@ -1890,6 +2006,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(StreamingInputCallRequest other) {
       if (other == null) {
         return;
@@ -1910,6 +2027,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -1941,6 +2059,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -1980,19 +2099,23 @@ namespace Grpc.Testing {
     private static readonly pb::MessageParser<StreamingInputCallResponse> _parser = new pb::MessageParser<StreamingInputCallResponse>(() => new StreamingInputCallResponse());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<StreamingInputCallResponse> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Testing.MessagesReflection.Descriptor.MessageTypes[6]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public StreamingInputCallResponse() {
       OnConstruction();
     }
@@ -2000,12 +2123,14 @@ namespace Grpc.Testing {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public StreamingInputCallResponse(StreamingInputCallResponse other) : this() {
       aggregatedPayloadSize_ = other.aggregatedPayloadSize_;
       _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public StreamingInputCallResponse Clone() {
       return new StreamingInputCallResponse(this);
     }
@@ -2017,6 +2142,7 @@ namespace Grpc.Testing {
     /// Aggregated size of payloads received from the client.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int AggregatedPayloadSize {
       get { return aggregatedPayloadSize_; }
       set {
@@ -2025,11 +2151,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as StreamingInputCallResponse);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(StreamingInputCallResponse other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -2042,6 +2170,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (AggregatedPayloadSize != 0) hash ^= AggregatedPayloadSize.GetHashCode();
@@ -2052,11 +2181,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -2073,6 +2204,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (AggregatedPayloadSize != 0) {
         output.WriteRawTag(8);
@@ -2085,6 +2217,7 @@ namespace Grpc.Testing {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (AggregatedPayloadSize != 0) {
@@ -2097,6 +2230,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(StreamingInputCallResponse other) {
       if (other == null) {
         return;
@@ -2108,6 +2242,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -2129,6 +2264,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -2158,19 +2294,23 @@ namespace Grpc.Testing {
     private static readonly pb::MessageParser<ResponseParameters> _parser = new pb::MessageParser<ResponseParameters>(() => new ResponseParameters());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<ResponseParameters> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Testing.MessagesReflection.Descriptor.MessageTypes[7]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ResponseParameters() {
       OnConstruction();
     }
@@ -2178,6 +2318,7 @@ namespace Grpc.Testing {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ResponseParameters(ResponseParameters other) : this() {
       size_ = other.size_;
       intervalUs_ = other.intervalUs_;
@@ -2186,6 +2327,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ResponseParameters Clone() {
       return new ResponseParameters(this);
     }
@@ -2197,6 +2339,7 @@ namespace Grpc.Testing {
     /// Desired payload sizes in responses from the server.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int Size {
       get { return size_; }
       set {
@@ -2212,6 +2355,7 @@ namespace Grpc.Testing {
     /// microseconds.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int IntervalUs {
       get { return intervalUs_; }
       set {
@@ -2229,6 +2373,7 @@ namespace Grpc.Testing {
     /// the response's compression status.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public global::Grpc.Testing.BoolValue Compressed {
       get { return compressed_; }
       set {
@@ -2237,11 +2382,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as ResponseParameters);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(ResponseParameters other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -2256,6 +2403,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (Size != 0) hash ^= Size.GetHashCode();
@@ -2268,11 +2416,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -2297,6 +2447,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (Size != 0) {
         output.WriteRawTag(8);
@@ -2317,6 +2468,7 @@ namespace Grpc.Testing {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (Size != 0) {
@@ -2335,6 +2487,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(ResponseParameters other) {
       if (other == null) {
         return;
@@ -2355,6 +2508,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -2387,6 +2541,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -2427,19 +2582,23 @@ namespace Grpc.Testing {
     private static readonly pb::MessageParser<StreamingOutputCallRequest> _parser = new pb::MessageParser<StreamingOutputCallRequest>(() => new StreamingOutputCallRequest());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<StreamingOutputCallRequest> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Testing.MessagesReflection.Descriptor.MessageTypes[8]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public StreamingOutputCallRequest() {
       OnConstruction();
     }
@@ -2447,6 +2606,7 @@ namespace Grpc.Testing {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public StreamingOutputCallRequest(StreamingOutputCallRequest other) : this() {
       responseType_ = other.responseType_;
       responseParameters_ = other.responseParameters_.Clone();
@@ -2456,6 +2616,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public StreamingOutputCallRequest Clone() {
       return new StreamingOutputCallRequest(this);
     }
@@ -2470,6 +2631,7 @@ namespace Grpc.Testing {
     /// stream.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public global::Grpc.Testing.PayloadType ResponseType {
       get { return responseType_; }
       set {
@@ -2486,6 +2648,7 @@ namespace Grpc.Testing {
     /// Configuration for each expected response message.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public pbc::RepeatedField<global::Grpc.Testing.ResponseParameters> ResponseParameters {
       get { return responseParameters_; }
     }
@@ -2497,6 +2660,7 @@ namespace Grpc.Testing {
     /// Optional input payload sent along with the request.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public global::Grpc.Testing.Payload Payload {
       get { return payload_; }
       set {
@@ -2511,6 +2675,7 @@ namespace Grpc.Testing {
     /// Whether server should return a given status
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public global::Grpc.Testing.EchoStatus ResponseStatus {
       get { return responseStatus_; }
       set {
@@ -2519,11 +2684,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as StreamingOutputCallRequest);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(StreamingOutputCallRequest other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -2539,6 +2706,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (ResponseType != global::Grpc.Testing.PayloadType.Compressable) hash ^= ResponseType.GetHashCode();
@@ -2552,11 +2720,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -2582,6 +2752,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (ResponseType != global::Grpc.Testing.PayloadType.Compressable) {
         output.WriteRawTag(8);
@@ -2603,6 +2774,7 @@ namespace Grpc.Testing {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (ResponseType != global::Grpc.Testing.PayloadType.Compressable) {
@@ -2622,6 +2794,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(StreamingOutputCallRequest other) {
       if (other == null) {
         return;
@@ -2646,6 +2819,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -2685,6 +2859,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -2732,19 +2907,23 @@ namespace Grpc.Testing {
     private static readonly pb::MessageParser<StreamingOutputCallResponse> _parser = new pb::MessageParser<StreamingOutputCallResponse>(() => new StreamingOutputCallResponse());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<StreamingOutputCallResponse> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Testing.MessagesReflection.Descriptor.MessageTypes[9]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public StreamingOutputCallResponse() {
       OnConstruction();
     }
@@ -2752,12 +2931,14 @@ namespace Grpc.Testing {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public StreamingOutputCallResponse(StreamingOutputCallResponse other) : this() {
       payload_ = other.payload_ != null ? other.payload_.Clone() : null;
       _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public StreamingOutputCallResponse Clone() {
       return new StreamingOutputCallResponse(this);
     }
@@ -2769,6 +2950,7 @@ namespace Grpc.Testing {
     /// Payload to increase response size.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public global::Grpc.Testing.Payload Payload {
       get { return payload_; }
       set {
@@ -2777,11 +2959,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as StreamingOutputCallResponse);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(StreamingOutputCallResponse other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -2794,6 +2978,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (payload_ != null) hash ^= Payload.GetHashCode();
@@ -2804,11 +2989,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -2825,6 +3012,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (payload_ != null) {
         output.WriteRawTag(10);
@@ -2837,6 +3025,7 @@ namespace Grpc.Testing {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (payload_ != null) {
@@ -2849,6 +3038,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(StreamingOutputCallResponse other) {
       if (other == null) {
         return;
@@ -2863,6 +3053,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -2887,6 +3078,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -2920,19 +3112,23 @@ namespace Grpc.Testing {
     private static readonly pb::MessageParser<ReconnectParams> _parser = new pb::MessageParser<ReconnectParams>(() => new ReconnectParams());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<ReconnectParams> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Testing.MessagesReflection.Descriptor.MessageTypes[10]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ReconnectParams() {
       OnConstruction();
     }
@@ -2940,12 +3136,14 @@ namespace Grpc.Testing {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ReconnectParams(ReconnectParams other) : this() {
       maxReconnectBackoffMs_ = other.maxReconnectBackoffMs_;
       _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ReconnectParams Clone() {
       return new ReconnectParams(this);
     }
@@ -2954,6 +3152,7 @@ namespace Grpc.Testing {
     public const int MaxReconnectBackoffMsFieldNumber = 1;
     private int maxReconnectBackoffMs_;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int MaxReconnectBackoffMs {
       get { return maxReconnectBackoffMs_; }
       set {
@@ -2962,11 +3161,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as ReconnectParams);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(ReconnectParams other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -2979,6 +3180,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (MaxReconnectBackoffMs != 0) hash ^= MaxReconnectBackoffMs.GetHashCode();
@@ -2989,11 +3191,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -3010,6 +3214,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (MaxReconnectBackoffMs != 0) {
         output.WriteRawTag(8);
@@ -3022,6 +3227,7 @@ namespace Grpc.Testing {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (MaxReconnectBackoffMs != 0) {
@@ -3034,6 +3240,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(ReconnectParams other) {
       if (other == null) {
         return;
@@ -3045,6 +3252,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -3066,6 +3274,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -3097,19 +3306,23 @@ namespace Grpc.Testing {
     private static readonly pb::MessageParser<ReconnectInfo> _parser = new pb::MessageParser<ReconnectInfo>(() => new ReconnectInfo());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<ReconnectInfo> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Testing.MessagesReflection.Descriptor.MessageTypes[11]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ReconnectInfo() {
       OnConstruction();
     }
@@ -3117,6 +3330,7 @@ namespace Grpc.Testing {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ReconnectInfo(ReconnectInfo other) : this() {
       passed_ = other.passed_;
       backoffMs_ = other.backoffMs_.Clone();
@@ -3124,6 +3338,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ReconnectInfo Clone() {
       return new ReconnectInfo(this);
     }
@@ -3132,6 +3347,7 @@ namespace Grpc.Testing {
     public const int PassedFieldNumber = 1;
     private bool passed_;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Passed {
       get { return passed_; }
       set {
@@ -3145,16 +3361,19 @@ namespace Grpc.Testing {
         = pb::FieldCodec.ForInt32(18);
     private readonly pbc::RepeatedField<int> backoffMs_ = new pbc::RepeatedField<int>();
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public pbc::RepeatedField<int> BackoffMs {
       get { return backoffMs_; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as ReconnectInfo);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(ReconnectInfo other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -3168,6 +3387,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (Passed != false) hash ^= Passed.GetHashCode();
@@ -3179,11 +3399,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -3201,6 +3423,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (Passed != false) {
         output.WriteRawTag(8);
@@ -3214,6 +3437,7 @@ namespace Grpc.Testing {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (Passed != false) {
@@ -3227,6 +3451,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(ReconnectInfo other) {
       if (other == null) {
         return;
@@ -3239,6 +3464,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -3265,6 +3491,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -3296,19 +3523,23 @@ namespace Grpc.Testing {
     private static readonly pb::MessageParser<LoadBalancerStatsRequest> _parser = new pb::MessageParser<LoadBalancerStatsRequest>(() => new LoadBalancerStatsRequest());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<LoadBalancerStatsRequest> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Testing.MessagesReflection.Descriptor.MessageTypes[12]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public LoadBalancerStatsRequest() {
       OnConstruction();
     }
@@ -3316,6 +3547,7 @@ namespace Grpc.Testing {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public LoadBalancerStatsRequest(LoadBalancerStatsRequest other) : this() {
       numRpcs_ = other.numRpcs_;
       timeoutSec_ = other.timeoutSec_;
@@ -3323,6 +3555,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public LoadBalancerStatsRequest Clone() {
       return new LoadBalancerStatsRequest(this);
     }
@@ -3334,6 +3567,7 @@ namespace Grpc.Testing {
     /// Request stats for the next num_rpcs sent by client.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int NumRpcs {
       get { return numRpcs_; }
       set {
@@ -3348,6 +3582,7 @@ namespace Grpc.Testing {
     /// If num_rpcs have not completed within timeout_sec, return partial results.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int TimeoutSec {
       get { return timeoutSec_; }
       set {
@@ -3356,11 +3591,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as LoadBalancerStatsRequest);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(LoadBalancerStatsRequest other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -3374,6 +3611,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (NumRpcs != 0) hash ^= NumRpcs.GetHashCode();
@@ -3385,11 +3623,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -3410,6 +3650,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (NumRpcs != 0) {
         output.WriteRawTag(8);
@@ -3426,6 +3667,7 @@ namespace Grpc.Testing {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (NumRpcs != 0) {
@@ -3441,6 +3683,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(LoadBalancerStatsRequest other) {
       if (other == null) {
         return;
@@ -3455,6 +3698,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -3480,6 +3724,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -3510,19 +3755,23 @@ namespace Grpc.Testing {
     private static readonly pb::MessageParser<LoadBalancerStatsResponse> _parser = new pb::MessageParser<LoadBalancerStatsResponse>(() => new LoadBalancerStatsResponse());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<LoadBalancerStatsResponse> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Testing.MessagesReflection.Descriptor.MessageTypes[13]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public LoadBalancerStatsResponse() {
       OnConstruction();
     }
@@ -3530,6 +3779,7 @@ namespace Grpc.Testing {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public LoadBalancerStatsResponse(LoadBalancerStatsResponse other) : this() {
       rpcsByPeer_ = other.rpcsByPeer_.Clone();
       numFailures_ = other.numFailures_;
@@ -3538,6 +3788,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public LoadBalancerStatsResponse Clone() {
       return new LoadBalancerStatsResponse(this);
     }
@@ -3551,6 +3802,7 @@ namespace Grpc.Testing {
     /// The number of completed RPCs for each peer.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public pbc::MapField<string, int> RpcsByPeer {
       get { return rpcsByPeer_; }
     }
@@ -3562,6 +3814,7 @@ namespace Grpc.Testing {
     /// The number of RPCs that failed to record a remote peer.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int NumFailures {
       get { return numFailures_; }
       set {
@@ -3575,16 +3828,19 @@ namespace Grpc.Testing {
         = new pbc::MapField<string, global::Grpc.Testing.LoadBalancerStatsResponse.Types.RpcsByPeer>.Codec(pb::FieldCodec.ForString(10, ""), pb::FieldCodec.ForMessage(18, global::Grpc.Testing.LoadBalancerStatsResponse.Types.RpcsByPeer.Parser), 26);
     private readonly pbc::MapField<string, global::Grpc.Testing.LoadBalancerStatsResponse.Types.RpcsByPeer> rpcsByMethod_ = new pbc::MapField<string, global::Grpc.Testing.LoadBalancerStatsResponse.Types.RpcsByPeer>();
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public pbc::MapField<string, global::Grpc.Testing.LoadBalancerStatsResponse.Types.RpcsByPeer> RpcsByMethod {
       get { return rpcsByMethod_; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as LoadBalancerStatsResponse);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(LoadBalancerStatsResponse other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -3599,6 +3855,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       hash ^= RpcsByPeer.GetHashCode();
@@ -3611,11 +3868,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -3634,6 +3893,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       rpcsByPeer_.WriteTo(ref output, _map_rpcsByPeer_codec);
       if (NumFailures != 0) {
@@ -3648,6 +3908,7 @@ namespace Grpc.Testing {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       size += rpcsByPeer_.CalculateSize(_map_rpcsByPeer_codec);
@@ -3662,6 +3923,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(LoadBalancerStatsResponse other) {
       if (other == null) {
         return;
@@ -3675,6 +3937,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -3704,6 +3967,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -3731,6 +3995,7 @@ namespace Grpc.Testing {
     #region Nested types
     /// <summary>Container for nested types declared in the LoadBalancerStatsResponse message type.</summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static partial class Types {
       public sealed partial class RpcsByPeer : pb::IMessage<RpcsByPeer>
       #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
@@ -3740,19 +4005,23 @@ namespace Grpc.Testing {
         private static readonly pb::MessageParser<RpcsByPeer> _parser = new pb::MessageParser<RpcsByPeer>(() => new RpcsByPeer());
         private pb::UnknownFieldSet _unknownFields;
         [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+        [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
         public static pb::MessageParser<RpcsByPeer> Parser { get { return _parser; } }
 
         [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+        [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
         public static pbr::MessageDescriptor Descriptor {
           get { return global::Grpc.Testing.LoadBalancerStatsResponse.Descriptor.NestedTypes[0]; }
         }
 
         [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+        [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
         pbr::MessageDescriptor pb::IMessage.Descriptor {
           get { return Descriptor; }
         }
 
         [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+        [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
         public RpcsByPeer() {
           OnConstruction();
         }
@@ -3760,12 +4029,14 @@ namespace Grpc.Testing {
         partial void OnConstruction();
 
         [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+        [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
         public RpcsByPeer(RpcsByPeer other) : this() {
           rpcsByPeer_ = other.rpcsByPeer_.Clone();
           _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields);
         }
 
         [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+        [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
         public RpcsByPeer Clone() {
           return new RpcsByPeer(this);
         }
@@ -3779,16 +4050,19 @@ namespace Grpc.Testing {
         /// The number of completed RPCs for each peer.
         /// </summary>
         [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+        [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
         public pbc::MapField<string, int> RpcsByPeer_ {
           get { return rpcsByPeer_; }
         }
 
         [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+        [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
         public override bool Equals(object other) {
           return Equals(other as RpcsByPeer);
         }
 
         [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+        [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
         public bool Equals(RpcsByPeer other) {
           if (ReferenceEquals(other, null)) {
             return false;
@@ -3801,6 +4075,7 @@ namespace Grpc.Testing {
         }
 
         [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+        [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
         public override int GetHashCode() {
           int hash = 1;
           hash ^= RpcsByPeer_.GetHashCode();
@@ -3811,11 +4086,13 @@ namespace Grpc.Testing {
         }
 
         [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+        [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
         public override string ToString() {
           return pb::JsonFormatter.ToDiagnosticString(this);
         }
 
         [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+        [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
         public void WriteTo(pb::CodedOutputStream output) {
         #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
           output.WriteRawMessage(this);
@@ -3829,6 +4106,7 @@ namespace Grpc.Testing {
 
         #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
         [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+        [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
         void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
           rpcsByPeer_.WriteTo(ref output, _map_rpcsByPeer_codec);
           if (_unknownFields != null) {
@@ -3838,6 +4116,7 @@ namespace Grpc.Testing {
         #endif
 
         [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+        [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
         public int CalculateSize() {
           int size = 0;
           size += rpcsByPeer_.CalculateSize(_map_rpcsByPeer_codec);
@@ -3848,6 +4127,7 @@ namespace Grpc.Testing {
         }
 
         [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+        [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
         public void MergeFrom(RpcsByPeer other) {
           if (other == null) {
             return;
@@ -3857,6 +4137,7 @@ namespace Grpc.Testing {
         }
 
         [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+        [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
         public void MergeFrom(pb::CodedInputStream input) {
         #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
           input.ReadRawMessage(this);
@@ -3878,6 +4159,7 @@ namespace Grpc.Testing {
 
         #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
         [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+        [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
         void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
           uint tag;
           while ((tag = input.ReadTag()) != 0) {
@@ -3912,19 +4194,23 @@ namespace Grpc.Testing {
     private static readonly pb::MessageParser<LoadBalancerAccumulatedStatsRequest> _parser = new pb::MessageParser<LoadBalancerAccumulatedStatsRequest>(() => new LoadBalancerAccumulatedStatsRequest());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<LoadBalancerAccumulatedStatsRequest> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Testing.MessagesReflection.Descriptor.MessageTypes[14]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public LoadBalancerAccumulatedStatsRequest() {
       OnConstruction();
     }
@@ -3932,21 +4218,25 @@ namespace Grpc.Testing {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public LoadBalancerAccumulatedStatsRequest(LoadBalancerAccumulatedStatsRequest other) : this() {
       _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public LoadBalancerAccumulatedStatsRequest Clone() {
       return new LoadBalancerAccumulatedStatsRequest(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as LoadBalancerAccumulatedStatsRequest);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(LoadBalancerAccumulatedStatsRequest other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -3958,6 +4248,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (_unknownFields != null) {
@@ -3967,11 +4258,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -3984,6 +4277,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (_unknownFields != null) {
         _unknownFields.WriteTo(ref output);
@@ -3992,6 +4286,7 @@ namespace Grpc.Testing {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (_unknownFields != null) {
@@ -4001,6 +4296,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(LoadBalancerAccumulatedStatsRequest other) {
       if (other == null) {
         return;
@@ -4009,6 +4305,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -4026,6 +4323,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -4051,19 +4349,23 @@ namespace Grpc.Testing {
     private static readonly pb::MessageParser<LoadBalancerAccumulatedStatsResponse> _parser = new pb::MessageParser<LoadBalancerAccumulatedStatsResponse>(() => new LoadBalancerAccumulatedStatsResponse());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<LoadBalancerAccumulatedStatsResponse> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Testing.MessagesReflection.Descriptor.MessageTypes[15]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public LoadBalancerAccumulatedStatsResponse() {
       OnConstruction();
     }
@@ -4071,6 +4373,7 @@ namespace Grpc.Testing {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public LoadBalancerAccumulatedStatsResponse(LoadBalancerAccumulatedStatsResponse other) : this() {
       numRpcsStartedByMethod_ = other.numRpcsStartedByMethod_.Clone();
       numRpcsSucceededByMethod_ = other.numRpcsSucceededByMethod_.Clone();
@@ -4080,6 +4383,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public LoadBalancerAccumulatedStatsResponse Clone() {
       return new LoadBalancerAccumulatedStatsResponse(this);
     }
@@ -4095,6 +4399,7 @@ namespace Grpc.Testing {
     /// </summary>
     [global::System.ObsoleteAttribute]
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public pbc::MapField<string, int> NumRpcsStartedByMethod {
       get { return numRpcsStartedByMethod_; }
     }
@@ -4110,6 +4415,7 @@ namespace Grpc.Testing {
     /// </summary>
     [global::System.ObsoleteAttribute]
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public pbc::MapField<string, int> NumRpcsSucceededByMethod {
       get { return numRpcsSucceededByMethod_; }
     }
@@ -4125,6 +4431,7 @@ namespace Grpc.Testing {
     /// </summary>
     [global::System.ObsoleteAttribute]
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public pbc::MapField<string, int> NumRpcsFailedByMethod {
       get { return numRpcsFailedByMethod_; }
     }
@@ -4139,16 +4446,19 @@ namespace Grpc.Testing {
     /// 'EMPTY_CALL' or 'UNARY_CALL'
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public pbc::MapField<string, global::Grpc.Testing.LoadBalancerAccumulatedStatsResponse.Types.MethodStats> StatsPerMethod {
       get { return statsPerMethod_; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as LoadBalancerAccumulatedStatsResponse);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(LoadBalancerAccumulatedStatsResponse other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -4164,6 +4474,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       hash ^= NumRpcsStartedByMethod.GetHashCode();
@@ -4177,11 +4488,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -4198,6 +4511,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       numRpcsStartedByMethod_.WriteTo(ref output, _map_numRpcsStartedByMethod_codec);
       numRpcsSucceededByMethod_.WriteTo(ref output, _map_numRpcsSucceededByMethod_codec);
@@ -4210,6 +4524,7 @@ namespace Grpc.Testing {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       size += numRpcsStartedByMethod_.CalculateSize(_map_numRpcsStartedByMethod_codec);
@@ -4223,6 +4538,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(LoadBalancerAccumulatedStatsResponse other) {
       if (other == null) {
         return;
@@ -4235,6 +4551,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -4268,6 +4585,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -4299,6 +4617,7 @@ namespace Grpc.Testing {
     #region Nested types
     /// <summary>Container for nested types declared in the LoadBalancerAccumulatedStatsResponse message type.</summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static partial class Types {
       public sealed partial class MethodStats : pb::IMessage<MethodStats>
       #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
@@ -4308,19 +4627,23 @@ namespace Grpc.Testing {
         private static readonly pb::MessageParser<MethodStats> _parser = new pb::MessageParser<MethodStats>(() => new MethodStats());
         private pb::UnknownFieldSet _unknownFields;
         [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+        [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
         public static pb::MessageParser<MethodStats> Parser { get { return _parser; } }
 
         [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+        [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
         public static pbr::MessageDescriptor Descriptor {
           get { return global::Grpc.Testing.LoadBalancerAccumulatedStatsResponse.Descriptor.NestedTypes[3]; }
         }
 
         [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+        [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
         pbr::MessageDescriptor pb::IMessage.Descriptor {
           get { return Descriptor; }
         }
 
         [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+        [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
         public MethodStats() {
           OnConstruction();
         }
@@ -4328,6 +4651,7 @@ namespace Grpc.Testing {
         partial void OnConstruction();
 
         [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+        [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
         public MethodStats(MethodStats other) : this() {
           rpcsStarted_ = other.rpcsStarted_;
           result_ = other.result_.Clone();
@@ -4335,6 +4659,7 @@ namespace Grpc.Testing {
         }
 
         [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+        [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
         public MethodStats Clone() {
           return new MethodStats(this);
         }
@@ -4346,6 +4671,7 @@ namespace Grpc.Testing {
         /// The number of RPCs that were started for this method.
         /// </summary>
         [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+        [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
         public int RpcsStarted {
           get { return rpcsStarted_; }
           set {
@@ -4363,16 +4689,19 @@ namespace Grpc.Testing {
         /// key is the integral value of a google.rpc.Code; the value is the count.
         /// </summary>
         [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+        [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
         public pbc::MapField<int, int> Result {
           get { return result_; }
         }
 
         [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+        [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
         public override bool Equals(object other) {
           return Equals(other as MethodStats);
         }
 
         [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+        [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
         public bool Equals(MethodStats other) {
           if (ReferenceEquals(other, null)) {
             return false;
@@ -4386,6 +4715,7 @@ namespace Grpc.Testing {
         }
 
         [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+        [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
         public override int GetHashCode() {
           int hash = 1;
           if (RpcsStarted != 0) hash ^= RpcsStarted.GetHashCode();
@@ -4397,11 +4727,13 @@ namespace Grpc.Testing {
         }
 
         [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+        [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
         public override string ToString() {
           return pb::JsonFormatter.ToDiagnosticString(this);
         }
 
         [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+        [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
         public void WriteTo(pb::CodedOutputStream output) {
         #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
           output.WriteRawMessage(this);
@@ -4419,6 +4751,7 @@ namespace Grpc.Testing {
 
         #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
         [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+        [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
         void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
           if (RpcsStarted != 0) {
             output.WriteRawTag(8);
@@ -4432,6 +4765,7 @@ namespace Grpc.Testing {
         #endif
 
         [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+        [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
         public int CalculateSize() {
           int size = 0;
           if (RpcsStarted != 0) {
@@ -4445,6 +4779,7 @@ namespace Grpc.Testing {
         }
 
         [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+        [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
         public void MergeFrom(MethodStats other) {
           if (other == null) {
             return;
@@ -4457,6 +4792,7 @@ namespace Grpc.Testing {
         }
 
         [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+        [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
         public void MergeFrom(pb::CodedInputStream input) {
         #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
           input.ReadRawMessage(this);
@@ -4482,6 +4818,7 @@ namespace Grpc.Testing {
 
         #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
         [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+        [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
         void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
           uint tag;
           while ((tag = input.ReadTag()) != 0) {
@@ -4520,19 +4857,23 @@ namespace Grpc.Testing {
     private static readonly pb::MessageParser<ClientConfigureRequest> _parser = new pb::MessageParser<ClientConfigureRequest>(() => new ClientConfigureRequest());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<ClientConfigureRequest> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Testing.MessagesReflection.Descriptor.MessageTypes[16]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ClientConfigureRequest() {
       OnConstruction();
     }
@@ -4540,6 +4881,7 @@ namespace Grpc.Testing {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ClientConfigureRequest(ClientConfigureRequest other) : this() {
       types_ = other.types_.Clone();
       metadata_ = other.metadata_.Clone();
@@ -4548,6 +4890,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ClientConfigureRequest Clone() {
       return new ClientConfigureRequest(this);
     }
@@ -4561,6 +4904,7 @@ namespace Grpc.Testing {
     /// The types of RPCs the client sends.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public pbc::RepeatedField<global::Grpc.Testing.ClientConfigureRequest.Types.RpcType> Types_ {
       get { return types_; }
     }
@@ -4574,6 +4918,7 @@ namespace Grpc.Testing {
     /// The collection of custom metadata to be attached to RPCs sent by the client.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public pbc::RepeatedField<global::Grpc.Testing.ClientConfigureRequest.Types.Metadata> Metadata {
       get { return metadata_; }
     }
@@ -4586,6 +4931,7 @@ namespace Grpc.Testing {
     /// client will use the default from the command-line.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int TimeoutSec {
       get { return timeoutSec_; }
       set {
@@ -4594,11 +4940,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as ClientConfigureRequest);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(ClientConfigureRequest other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -4613,6 +4961,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       hash ^= types_.GetHashCode();
@@ -4625,11 +4974,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -4648,6 +4999,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       types_.WriteTo(ref output, _repeated_types_codec);
       metadata_.WriteTo(ref output, _repeated_metadata_codec);
@@ -4662,6 +5014,7 @@ namespace Grpc.Testing {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       size += types_.CalculateSize(_repeated_types_codec);
@@ -4676,6 +5029,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(ClientConfigureRequest other) {
       if (other == null) {
         return;
@@ -4689,6 +5043,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -4719,6 +5074,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -4747,6 +5103,7 @@ namespace Grpc.Testing {
     #region Nested types
     /// <summary>Container for nested types declared in the ClientConfigureRequest message type.</summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static partial class Types {
       /// <summary>
       /// Type of RPCs to send.
@@ -4767,19 +5124,23 @@ namespace Grpc.Testing {
         private static readonly pb::MessageParser<Metadata> _parser = new pb::MessageParser<Metadata>(() => new Metadata());
         private pb::UnknownFieldSet _unknownFields;
         [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+        [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
         public static pb::MessageParser<Metadata> Parser { get { return _parser; } }
 
         [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+        [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
         public static pbr::MessageDescriptor Descriptor {
           get { return global::Grpc.Testing.ClientConfigureRequest.Descriptor.NestedTypes[0]; }
         }
 
         [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+        [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
         pbr::MessageDescriptor pb::IMessage.Descriptor {
           get { return Descriptor; }
         }
 
         [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+        [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
         public Metadata() {
           OnConstruction();
         }
@@ -4787,6 +5148,7 @@ namespace Grpc.Testing {
         partial void OnConstruction();
 
         [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+        [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
         public Metadata(Metadata other) : this() {
           type_ = other.type_;
           key_ = other.key_;
@@ -4795,6 +5157,7 @@ namespace Grpc.Testing {
         }
 
         [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+        [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
         public Metadata Clone() {
           return new Metadata(this);
         }
@@ -4803,6 +5166,7 @@ namespace Grpc.Testing {
         public const int TypeFieldNumber = 1;
         private global::Grpc.Testing.ClientConfigureRequest.Types.RpcType type_ = global::Grpc.Testing.ClientConfigureRequest.Types.RpcType.EmptyCall;
         [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+        [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
         public global::Grpc.Testing.ClientConfigureRequest.Types.RpcType Type {
           get { return type_; }
           set {
@@ -4814,6 +5178,7 @@ namespace Grpc.Testing {
         public const int KeyFieldNumber = 2;
         private string key_ = "";
         [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+        [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
         public string Key {
           get { return key_; }
           set {
@@ -4825,6 +5190,7 @@ namespace Grpc.Testing {
         public const int ValueFieldNumber = 3;
         private string value_ = "";
         [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+        [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
         public string Value {
           get { return value_; }
           set {
@@ -4833,11 +5199,13 @@ namespace Grpc.Testing {
         }
 
         [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+        [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
         public override bool Equals(object other) {
           return Equals(other as Metadata);
         }
 
         [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+        [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
         public bool Equals(Metadata other) {
           if (ReferenceEquals(other, null)) {
             return false;
@@ -4852,6 +5220,7 @@ namespace Grpc.Testing {
         }
 
         [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+        [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
         public override int GetHashCode() {
           int hash = 1;
           if (Type != global::Grpc.Testing.ClientConfigureRequest.Types.RpcType.EmptyCall) hash ^= Type.GetHashCode();
@@ -4864,11 +5233,13 @@ namespace Grpc.Testing {
         }
 
         [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+        [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
         public override string ToString() {
           return pb::JsonFormatter.ToDiagnosticString(this);
         }
 
         [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+        [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
         public void WriteTo(pb::CodedOutputStream output) {
         #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
           output.WriteRawMessage(this);
@@ -4893,6 +5264,7 @@ namespace Grpc.Testing {
 
         #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
         [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+        [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
         void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
           if (Type != global::Grpc.Testing.ClientConfigureRequest.Types.RpcType.EmptyCall) {
             output.WriteRawTag(8);
@@ -4913,6 +5285,7 @@ namespace Grpc.Testing {
         #endif
 
         [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+        [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
         public int CalculateSize() {
           int size = 0;
           if (Type != global::Grpc.Testing.ClientConfigureRequest.Types.RpcType.EmptyCall) {
@@ -4931,6 +5304,7 @@ namespace Grpc.Testing {
         }
 
         [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+        [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
         public void MergeFrom(Metadata other) {
           if (other == null) {
             return;
@@ -4948,6 +5322,7 @@ namespace Grpc.Testing {
         }
 
         [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+        [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
         public void MergeFrom(pb::CodedInputStream input) {
         #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
           input.ReadRawMessage(this);
@@ -4977,6 +5352,7 @@ namespace Grpc.Testing {
 
         #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
         [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+        [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
         void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
           uint tag;
           while ((tag = input.ReadTag()) != 0) {
@@ -5019,19 +5395,23 @@ namespace Grpc.Testing {
     private static readonly pb::MessageParser<ClientConfigureResponse> _parser = new pb::MessageParser<ClientConfigureResponse>(() => new ClientConfigureResponse());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<ClientConfigureResponse> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Testing.MessagesReflection.Descriptor.MessageTypes[17]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ClientConfigureResponse() {
       OnConstruction();
     }
@@ -5039,21 +5419,25 @@ namespace Grpc.Testing {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ClientConfigureResponse(ClientConfigureResponse other) : this() {
       _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ClientConfigureResponse Clone() {
       return new ClientConfigureResponse(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as ClientConfigureResponse);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(ClientConfigureResponse other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -5065,6 +5449,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (_unknownFields != null) {
@@ -5074,11 +5459,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -5091,6 +5478,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (_unknownFields != null) {
         _unknownFields.WriteTo(ref output);
@@ -5099,6 +5487,7 @@ namespace Grpc.Testing {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (_unknownFields != null) {
@@ -5108,6 +5497,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(ClientConfigureResponse other) {
       if (other == null) {
         return;
@@ -5116,6 +5506,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -5133,6 +5524,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
index e20a6b3..3b622f9 100644 (file)
@@ -56,19 +56,23 @@ namespace Grpc.Testing {
     private static readonly pb::MessageParser<GaugeResponse> _parser = new pb::MessageParser<GaugeResponse>(() => new GaugeResponse());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<GaugeResponse> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Testing.MetricsReflection.Descriptor.MessageTypes[0]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public GaugeResponse() {
       OnConstruction();
     }
@@ -76,6 +80,7 @@ namespace Grpc.Testing {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public GaugeResponse(GaugeResponse other) : this() {
       name_ = other.name_;
       switch (other.ValueCase) {
@@ -94,6 +99,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public GaugeResponse Clone() {
       return new GaugeResponse(this);
     }
@@ -102,6 +108,7 @@ namespace Grpc.Testing {
     public const int NameFieldNumber = 1;
     private string name_ = "";
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public string Name {
       get { return name_; }
       set {
@@ -112,6 +119,7 @@ namespace Grpc.Testing {
     /// <summary>Field number for the "long_value" field.</summary>
     public const int LongValueFieldNumber = 2;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public long LongValue {
       get { return valueCase_ == ValueOneofCase.LongValue ? (long) value_ : 0L; }
       set {
@@ -123,6 +131,7 @@ namespace Grpc.Testing {
     /// <summary>Field number for the "double_value" field.</summary>
     public const int DoubleValueFieldNumber = 3;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public double DoubleValue {
       get { return valueCase_ == ValueOneofCase.DoubleValue ? (double) value_ : 0D; }
       set {
@@ -134,6 +143,7 @@ namespace Grpc.Testing {
     /// <summary>Field number for the "string_value" field.</summary>
     public const int StringValueFieldNumber = 4;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public string StringValue {
       get { return valueCase_ == ValueOneofCase.StringValue ? (string) value_ : ""; }
       set {
@@ -152,22 +162,26 @@ namespace Grpc.Testing {
     }
     private ValueOneofCase valueCase_ = ValueOneofCase.None;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ValueOneofCase ValueCase {
       get { return valueCase_; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void ClearValue() {
       valueCase_ = ValueOneofCase.None;
       value_ = null;
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as GaugeResponse);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(GaugeResponse other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -184,6 +198,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (Name.Length != 0) hash ^= Name.GetHashCode();
@@ -198,11 +213,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -231,6 +248,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (Name.Length != 0) {
         output.WriteRawTag(10);
@@ -255,6 +273,7 @@ namespace Grpc.Testing {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (Name.Length != 0) {
@@ -276,6 +295,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(GaugeResponse other) {
       if (other == null) {
         return;
@@ -299,6 +319,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -332,6 +353,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -373,19 +395,23 @@ namespace Grpc.Testing {
     private static readonly pb::MessageParser<GaugeRequest> _parser = new pb::MessageParser<GaugeRequest>(() => new GaugeRequest());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<GaugeRequest> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Testing.MetricsReflection.Descriptor.MessageTypes[1]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public GaugeRequest() {
       OnConstruction();
     }
@@ -393,12 +419,14 @@ namespace Grpc.Testing {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public GaugeRequest(GaugeRequest other) : this() {
       name_ = other.name_;
       _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public GaugeRequest Clone() {
       return new GaugeRequest(this);
     }
@@ -407,6 +435,7 @@ namespace Grpc.Testing {
     public const int NameFieldNumber = 1;
     private string name_ = "";
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public string Name {
       get { return name_; }
       set {
@@ -415,11 +444,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as GaugeRequest);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(GaugeRequest other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -432,6 +463,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (Name.Length != 0) hash ^= Name.GetHashCode();
@@ -442,11 +474,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -463,6 +497,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (Name.Length != 0) {
         output.WriteRawTag(10);
@@ -475,6 +510,7 @@ namespace Grpc.Testing {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (Name.Length != 0) {
@@ -487,6 +523,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(GaugeRequest other) {
       if (other == null) {
         return;
@@ -498,6 +535,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -519,6 +557,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -545,19 +584,23 @@ namespace Grpc.Testing {
     private static readonly pb::MessageParser<EmptyMessage> _parser = new pb::MessageParser<EmptyMessage>(() => new EmptyMessage());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<EmptyMessage> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Testing.MetricsReflection.Descriptor.MessageTypes[2]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public EmptyMessage() {
       OnConstruction();
     }
@@ -565,21 +608,25 @@ namespace Grpc.Testing {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public EmptyMessage(EmptyMessage other) : this() {
       _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public EmptyMessage Clone() {
       return new EmptyMessage(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as EmptyMessage);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(EmptyMessage other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -591,6 +638,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (_unknownFields != null) {
@@ -600,11 +648,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -617,6 +667,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (_unknownFields != null) {
         _unknownFields.WriteTo(ref output);
@@ -625,6 +676,7 @@ namespace Grpc.Testing {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (_unknownFields != null) {
@@ -634,6 +686,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(EmptyMessage other) {
       if (other == null) {
         return;
@@ -642,6 +695,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -659,6 +713,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
index 50211e9..309e6a6 100644 (file)
@@ -54,19 +54,23 @@ namespace Grpc.Testing {
     private static readonly pb::MessageParser<ByteBufferParams> _parser = new pb::MessageParser<ByteBufferParams>(() => new ByteBufferParams());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<ByteBufferParams> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Testing.PayloadsReflection.Descriptor.MessageTypes[0]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ByteBufferParams() {
       OnConstruction();
     }
@@ -74,6 +78,7 @@ namespace Grpc.Testing {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ByteBufferParams(ByteBufferParams other) : this() {
       reqSize_ = other.reqSize_;
       respSize_ = other.respSize_;
@@ -81,6 +86,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ByteBufferParams Clone() {
       return new ByteBufferParams(this);
     }
@@ -89,6 +95,7 @@ namespace Grpc.Testing {
     public const int ReqSizeFieldNumber = 1;
     private int reqSize_;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int ReqSize {
       get { return reqSize_; }
       set {
@@ -100,6 +107,7 @@ namespace Grpc.Testing {
     public const int RespSizeFieldNumber = 2;
     private int respSize_;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int RespSize {
       get { return respSize_; }
       set {
@@ -108,11 +116,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as ByteBufferParams);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(ByteBufferParams other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -126,6 +136,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (ReqSize != 0) hash ^= ReqSize.GetHashCode();
@@ -137,11 +148,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -162,6 +175,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (ReqSize != 0) {
         output.WriteRawTag(8);
@@ -178,6 +192,7 @@ namespace Grpc.Testing {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (ReqSize != 0) {
@@ -193,6 +208,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(ByteBufferParams other) {
       if (other == null) {
         return;
@@ -207,6 +223,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -232,6 +249,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -262,19 +280,23 @@ namespace Grpc.Testing {
     private static readonly pb::MessageParser<SimpleProtoParams> _parser = new pb::MessageParser<SimpleProtoParams>(() => new SimpleProtoParams());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<SimpleProtoParams> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Testing.PayloadsReflection.Descriptor.MessageTypes[1]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public SimpleProtoParams() {
       OnConstruction();
     }
@@ -282,6 +304,7 @@ namespace Grpc.Testing {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public SimpleProtoParams(SimpleProtoParams other) : this() {
       reqSize_ = other.reqSize_;
       respSize_ = other.respSize_;
@@ -289,6 +312,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public SimpleProtoParams Clone() {
       return new SimpleProtoParams(this);
     }
@@ -297,6 +321,7 @@ namespace Grpc.Testing {
     public const int ReqSizeFieldNumber = 1;
     private int reqSize_;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int ReqSize {
       get { return reqSize_; }
       set {
@@ -308,6 +333,7 @@ namespace Grpc.Testing {
     public const int RespSizeFieldNumber = 2;
     private int respSize_;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int RespSize {
       get { return respSize_; }
       set {
@@ -316,11 +342,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as SimpleProtoParams);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(SimpleProtoParams other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -334,6 +362,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (ReqSize != 0) hash ^= ReqSize.GetHashCode();
@@ -345,11 +374,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -370,6 +401,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (ReqSize != 0) {
         output.WriteRawTag(8);
@@ -386,6 +418,7 @@ namespace Grpc.Testing {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (ReqSize != 0) {
@@ -401,6 +434,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(SimpleProtoParams other) {
       if (other == null) {
         return;
@@ -415,6 +449,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -440,6 +475,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -474,19 +510,23 @@ namespace Grpc.Testing {
     private static readonly pb::MessageParser<ComplexProtoParams> _parser = new pb::MessageParser<ComplexProtoParams>(() => new ComplexProtoParams());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<ComplexProtoParams> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Testing.PayloadsReflection.Descriptor.MessageTypes[2]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ComplexProtoParams() {
       OnConstruction();
     }
@@ -494,21 +534,25 @@ namespace Grpc.Testing {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ComplexProtoParams(ComplexProtoParams other) : this() {
       _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ComplexProtoParams Clone() {
       return new ComplexProtoParams(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as ComplexProtoParams);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(ComplexProtoParams other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -520,6 +564,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (_unknownFields != null) {
@@ -529,11 +574,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -546,6 +593,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (_unknownFields != null) {
         _unknownFields.WriteTo(ref output);
@@ -554,6 +602,7 @@ namespace Grpc.Testing {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (_unknownFields != null) {
@@ -563,6 +612,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(ComplexProtoParams other) {
       if (other == null) {
         return;
@@ -571,6 +621,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -588,6 +639,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -610,19 +662,23 @@ namespace Grpc.Testing {
     private static readonly pb::MessageParser<PayloadConfig> _parser = new pb::MessageParser<PayloadConfig>(() => new PayloadConfig());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<PayloadConfig> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Testing.PayloadsReflection.Descriptor.MessageTypes[3]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public PayloadConfig() {
       OnConstruction();
     }
@@ -630,6 +686,7 @@ namespace Grpc.Testing {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public PayloadConfig(PayloadConfig other) : this() {
       switch (other.PayloadCase) {
         case PayloadOneofCase.BytebufParams:
@@ -647,6 +704,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public PayloadConfig Clone() {
       return new PayloadConfig(this);
     }
@@ -654,6 +712,7 @@ namespace Grpc.Testing {
     /// <summary>Field number for the "bytebuf_params" field.</summary>
     public const int BytebufParamsFieldNumber = 1;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public global::Grpc.Testing.ByteBufferParams BytebufParams {
       get { return payloadCase_ == PayloadOneofCase.BytebufParams ? (global::Grpc.Testing.ByteBufferParams) payload_ : null; }
       set {
@@ -665,6 +724,7 @@ namespace Grpc.Testing {
     /// <summary>Field number for the "simple_params" field.</summary>
     public const int SimpleParamsFieldNumber = 2;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public global::Grpc.Testing.SimpleProtoParams SimpleParams {
       get { return payloadCase_ == PayloadOneofCase.SimpleParams ? (global::Grpc.Testing.SimpleProtoParams) payload_ : null; }
       set {
@@ -676,6 +736,7 @@ namespace Grpc.Testing {
     /// <summary>Field number for the "complex_params" field.</summary>
     public const int ComplexParamsFieldNumber = 3;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public global::Grpc.Testing.ComplexProtoParams ComplexParams {
       get { return payloadCase_ == PayloadOneofCase.ComplexParams ? (global::Grpc.Testing.ComplexProtoParams) payload_ : null; }
       set {
@@ -694,22 +755,26 @@ namespace Grpc.Testing {
     }
     private PayloadOneofCase payloadCase_ = PayloadOneofCase.None;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public PayloadOneofCase PayloadCase {
       get { return payloadCase_; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void ClearPayload() {
       payloadCase_ = PayloadOneofCase.None;
       payload_ = null;
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as PayloadConfig);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(PayloadConfig other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -725,6 +790,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (payloadCase_ == PayloadOneofCase.BytebufParams) hash ^= BytebufParams.GetHashCode();
@@ -738,11 +804,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -767,6 +835,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (payloadCase_ == PayloadOneofCase.BytebufParams) {
         output.WriteRawTag(10);
@@ -787,6 +856,7 @@ namespace Grpc.Testing {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (payloadCase_ == PayloadOneofCase.BytebufParams) {
@@ -805,6 +875,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(PayloadConfig other) {
       if (other == null) {
         return;
@@ -834,6 +905,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -878,6 +950,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
index 3aa5b7d..375ca03 100644 (file)
@@ -63,19 +63,23 @@ namespace Grpc.Testing {
     private static readonly pb::MessageParser<ServerStats> _parser = new pb::MessageParser<ServerStats>(() => new ServerStats());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<ServerStats> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Testing.StatsReflection.Descriptor.MessageTypes[0]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ServerStats() {
       OnConstruction();
     }
@@ -83,6 +87,7 @@ namespace Grpc.Testing {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ServerStats(ServerStats other) : this() {
       timeElapsed_ = other.timeElapsed_;
       timeUser_ = other.timeUser_;
@@ -95,6 +100,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ServerStats Clone() {
       return new ServerStats(this);
     }
@@ -106,6 +112,7 @@ namespace Grpc.Testing {
     /// wall clock time change in seconds since last reset
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public double TimeElapsed {
       get { return timeElapsed_; }
       set {
@@ -120,6 +127,7 @@ namespace Grpc.Testing {
     /// change in user time (in seconds) used by the server since last reset
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public double TimeUser {
       get { return timeUser_; }
       set {
@@ -135,6 +143,7 @@ namespace Grpc.Testing {
     /// threads since last reset
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public double TimeSystem {
       get { return timeSystem_; }
       set {
@@ -149,6 +158,7 @@ namespace Grpc.Testing {
     /// change in total cpu time of the server (data from proc/stat)
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ulong TotalCpuTime {
       get { return totalCpuTime_; }
       set {
@@ -163,6 +173,7 @@ namespace Grpc.Testing {
     /// change in idle time of the server (data from proc/stat)
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ulong IdleCpuTime {
       get { return idleCpuTime_; }
       set {
@@ -177,6 +188,7 @@ namespace Grpc.Testing {
     /// Number of polls called inside completion queue
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ulong CqPollCount {
       get { return cqPollCount_; }
       set {
@@ -191,6 +203,7 @@ namespace Grpc.Testing {
     /// Core library stats
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public global::Grpc.Core.Stats CoreStats {
       get { return coreStats_; }
       set {
@@ -199,11 +212,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as ServerStats);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(ServerStats other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -222,6 +237,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (TimeElapsed != 0D) hash ^= pbc::ProtobufEqualityComparers.BitwiseDoubleEqualityComparer.GetHashCode(TimeElapsed);
@@ -238,11 +254,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -283,6 +301,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (TimeElapsed != 0D) {
         output.WriteRawTag(9);
@@ -319,6 +338,7 @@ namespace Grpc.Testing {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (TimeElapsed != 0D) {
@@ -349,6 +369,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(ServerStats other) {
       if (other == null) {
         return;
@@ -381,6 +402,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -429,6 +451,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -485,19 +508,23 @@ namespace Grpc.Testing {
     private static readonly pb::MessageParser<HistogramParams> _parser = new pb::MessageParser<HistogramParams>(() => new HistogramParams());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<HistogramParams> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Testing.StatsReflection.Descriptor.MessageTypes[1]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public HistogramParams() {
       OnConstruction();
     }
@@ -505,6 +532,7 @@ namespace Grpc.Testing {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public HistogramParams(HistogramParams other) : this() {
       resolution_ = other.resolution_;
       maxPossible_ = other.maxPossible_;
@@ -512,6 +540,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public HistogramParams Clone() {
       return new HistogramParams(this);
     }
@@ -523,6 +552,7 @@ namespace Grpc.Testing {
     /// first bucket is [0, 1 + resolution)
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public double Resolution {
       get { return resolution_; }
       set {
@@ -537,6 +567,7 @@ namespace Grpc.Testing {
     /// use enough buckets to allow this value
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public double MaxPossible {
       get { return maxPossible_; }
       set {
@@ -545,11 +576,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as HistogramParams);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(HistogramParams other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -563,6 +596,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (Resolution != 0D) hash ^= pbc::ProtobufEqualityComparers.BitwiseDoubleEqualityComparer.GetHashCode(Resolution);
@@ -574,11 +608,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -599,6 +635,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (Resolution != 0D) {
         output.WriteRawTag(9);
@@ -615,6 +652,7 @@ namespace Grpc.Testing {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (Resolution != 0D) {
@@ -630,6 +668,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(HistogramParams other) {
       if (other == null) {
         return;
@@ -644,6 +683,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -669,6 +709,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -702,19 +743,23 @@ namespace Grpc.Testing {
     private static readonly pb::MessageParser<HistogramData> _parser = new pb::MessageParser<HistogramData>(() => new HistogramData());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<HistogramData> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Testing.StatsReflection.Descriptor.MessageTypes[2]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public HistogramData() {
       OnConstruction();
     }
@@ -722,6 +767,7 @@ namespace Grpc.Testing {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public HistogramData(HistogramData other) : this() {
       bucket_ = other.bucket_.Clone();
       minSeen_ = other.minSeen_;
@@ -733,6 +779,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public HistogramData Clone() {
       return new HistogramData(this);
     }
@@ -743,6 +790,7 @@ namespace Grpc.Testing {
         = pb::FieldCodec.ForUInt32(10);
     private readonly pbc::RepeatedField<uint> bucket_ = new pbc::RepeatedField<uint>();
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public pbc::RepeatedField<uint> Bucket {
       get { return bucket_; }
     }
@@ -751,6 +799,7 @@ namespace Grpc.Testing {
     public const int MinSeenFieldNumber = 2;
     private double minSeen_;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public double MinSeen {
       get { return minSeen_; }
       set {
@@ -762,6 +811,7 @@ namespace Grpc.Testing {
     public const int MaxSeenFieldNumber = 3;
     private double maxSeen_;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public double MaxSeen {
       get { return maxSeen_; }
       set {
@@ -773,6 +823,7 @@ namespace Grpc.Testing {
     public const int SumFieldNumber = 4;
     private double sum_;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public double Sum {
       get { return sum_; }
       set {
@@ -784,6 +835,7 @@ namespace Grpc.Testing {
     public const int SumOfSquaresFieldNumber = 5;
     private double sumOfSquares_;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public double SumOfSquares {
       get { return sumOfSquares_; }
       set {
@@ -795,6 +847,7 @@ namespace Grpc.Testing {
     public const int CountFieldNumber = 6;
     private double count_;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public double Count {
       get { return count_; }
       set {
@@ -803,11 +856,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as HistogramData);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(HistogramData other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -825,6 +880,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       hash ^= bucket_.GetHashCode();
@@ -840,11 +896,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -878,6 +936,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       bucket_.WriteTo(ref output, _repeated_bucket_codec);
       if (MinSeen != 0D) {
@@ -907,6 +966,7 @@ namespace Grpc.Testing {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       size += bucket_.CalculateSize(_repeated_bucket_codec);
@@ -932,6 +992,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(HistogramData other) {
       if (other == null) {
         return;
@@ -956,6 +1017,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -998,6 +1060,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -1045,19 +1108,23 @@ namespace Grpc.Testing {
     private static readonly pb::MessageParser<RequestResultCount> _parser = new pb::MessageParser<RequestResultCount>(() => new RequestResultCount());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<RequestResultCount> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Testing.StatsReflection.Descriptor.MessageTypes[3]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public RequestResultCount() {
       OnConstruction();
     }
@@ -1065,6 +1132,7 @@ namespace Grpc.Testing {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public RequestResultCount(RequestResultCount other) : this() {
       statusCode_ = other.statusCode_;
       count_ = other.count_;
@@ -1072,6 +1140,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public RequestResultCount Clone() {
       return new RequestResultCount(this);
     }
@@ -1080,6 +1149,7 @@ namespace Grpc.Testing {
     public const int StatusCodeFieldNumber = 1;
     private int statusCode_;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int StatusCode {
       get { return statusCode_; }
       set {
@@ -1091,6 +1161,7 @@ namespace Grpc.Testing {
     public const int CountFieldNumber = 2;
     private long count_;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public long Count {
       get { return count_; }
       set {
@@ -1099,11 +1170,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as RequestResultCount);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(RequestResultCount other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -1117,6 +1190,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (StatusCode != 0) hash ^= StatusCode.GetHashCode();
@@ -1128,11 +1202,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -1153,6 +1229,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (StatusCode != 0) {
         output.WriteRawTag(8);
@@ -1169,6 +1246,7 @@ namespace Grpc.Testing {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (StatusCode != 0) {
@@ -1184,6 +1262,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(RequestResultCount other) {
       if (other == null) {
         return;
@@ -1198,6 +1277,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -1223,6 +1303,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -1253,19 +1334,23 @@ namespace Grpc.Testing {
     private static readonly pb::MessageParser<ClientStats> _parser = new pb::MessageParser<ClientStats>(() => new ClientStats());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<ClientStats> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Testing.StatsReflection.Descriptor.MessageTypes[4]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ClientStats() {
       OnConstruction();
     }
@@ -1273,6 +1358,7 @@ namespace Grpc.Testing {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ClientStats(ClientStats other) : this() {
       latencies_ = other.latencies_ != null ? other.latencies_.Clone() : null;
       timeElapsed_ = other.timeElapsed_;
@@ -1285,6 +1371,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ClientStats Clone() {
       return new ClientStats(this);
     }
@@ -1296,6 +1383,7 @@ namespace Grpc.Testing {
     /// Latency histogram. Data points are in nanoseconds.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public global::Grpc.Testing.HistogramData Latencies {
       get { return latencies_; }
       set {
@@ -1310,6 +1398,7 @@ namespace Grpc.Testing {
     /// See ServerStats for details.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public double TimeElapsed {
       get { return timeElapsed_; }
       set {
@@ -1321,6 +1410,7 @@ namespace Grpc.Testing {
     public const int TimeUserFieldNumber = 3;
     private double timeUser_;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public double TimeUser {
       get { return timeUser_; }
       set {
@@ -1332,6 +1422,7 @@ namespace Grpc.Testing {
     public const int TimeSystemFieldNumber = 4;
     private double timeSystem_;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public double TimeSystem {
       get { return timeSystem_; }
       set {
@@ -1348,6 +1439,7 @@ namespace Grpc.Testing {
     /// Number of failed requests (one row per status code seen)
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public pbc::RepeatedField<global::Grpc.Testing.RequestResultCount> RequestResults {
       get { return requestResults_; }
     }
@@ -1359,6 +1451,7 @@ namespace Grpc.Testing {
     /// Number of polls called inside completion queue
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ulong CqPollCount {
       get { return cqPollCount_; }
       set {
@@ -1373,6 +1466,7 @@ namespace Grpc.Testing {
     /// Core library stats
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public global::Grpc.Core.Stats CoreStats {
       get { return coreStats_; }
       set {
@@ -1381,11 +1475,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as ClientStats);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(ClientStats other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -1404,6 +1500,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (latencies_ != null) hash ^= Latencies.GetHashCode();
@@ -1420,11 +1517,13 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -1462,6 +1561,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (latencies_ != null) {
         output.WriteRawTag(10);
@@ -1495,6 +1595,7 @@ namespace Grpc.Testing {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (latencies_ != null) {
@@ -1523,6 +1624,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(ClientStats other) {
       if (other == null) {
         return;
@@ -1556,6 +1658,7 @@ namespace Grpc.Testing {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -1607,6 +1710,7 @@ namespace Grpc.Testing {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
index 0b21de7..ce4b28b 100644 (file)
@@ -82,19 +82,23 @@ namespace Grpc.Reflection.V1Alpha {
     private static readonly pb::MessageParser<ServerReflectionRequest> _parser = new pb::MessageParser<ServerReflectionRequest>(() => new ServerReflectionRequest());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<ServerReflectionRequest> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Reflection.V1Alpha.ReflectionReflection.Descriptor.MessageTypes[0]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ServerReflectionRequest() {
       OnConstruction();
     }
@@ -102,6 +106,7 @@ namespace Grpc.Reflection.V1Alpha {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ServerReflectionRequest(ServerReflectionRequest other) : this() {
       host_ = other.host_;
       switch (other.MessageRequestCase) {
@@ -126,6 +131,7 @@ namespace Grpc.Reflection.V1Alpha {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ServerReflectionRequest Clone() {
       return new ServerReflectionRequest(this);
     }
@@ -134,6 +140,7 @@ namespace Grpc.Reflection.V1Alpha {
     public const int HostFieldNumber = 1;
     private string host_ = "";
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public string Host {
       get { return host_; }
       set {
@@ -147,6 +154,7 @@ namespace Grpc.Reflection.V1Alpha {
     /// Find a proto file by the file name.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public string FileByFilename {
       get { return messageRequestCase_ == MessageRequestOneofCase.FileByFilename ? (string) messageRequest_ : ""; }
       set {
@@ -163,6 +171,7 @@ namespace Grpc.Reflection.V1Alpha {
     /// (e.g. &lt;package>.&lt;service>[.&lt;method>] or &lt;package>.&lt;type>).
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public string FileContainingSymbol {
       get { return messageRequestCase_ == MessageRequestOneofCase.FileContainingSymbol ? (string) messageRequest_ : ""; }
       set {
@@ -178,6 +187,7 @@ namespace Grpc.Reflection.V1Alpha {
     /// message type with the given field number.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public global::Grpc.Reflection.V1Alpha.ExtensionRequest FileContainingExtension {
       get { return messageRequestCase_ == MessageRequestOneofCase.FileContainingExtension ? (global::Grpc.Reflection.V1Alpha.ExtensionRequest) messageRequest_ : null; }
       set {
@@ -199,6 +209,7 @@ namespace Grpc.Reflection.V1Alpha {
     /// &lt;package>.&lt;type>
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public string AllExtensionNumbersOfType {
       get { return messageRequestCase_ == MessageRequestOneofCase.AllExtensionNumbersOfType ? (string) messageRequest_ : ""; }
       set {
@@ -214,6 +225,7 @@ namespace Grpc.Reflection.V1Alpha {
     /// checked.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public string ListServices {
       get { return messageRequestCase_ == MessageRequestOneofCase.ListServices ? (string) messageRequest_ : ""; }
       set {
@@ -234,22 +246,26 @@ namespace Grpc.Reflection.V1Alpha {
     }
     private MessageRequestOneofCase messageRequestCase_ = MessageRequestOneofCase.None;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public MessageRequestOneofCase MessageRequestCase {
       get { return messageRequestCase_; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void ClearMessageRequest() {
       messageRequestCase_ = MessageRequestOneofCase.None;
       messageRequest_ = null;
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as ServerReflectionRequest);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(ServerReflectionRequest other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -268,6 +284,7 @@ namespace Grpc.Reflection.V1Alpha {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (Host.Length != 0) hash ^= Host.GetHashCode();
@@ -284,11 +301,13 @@ namespace Grpc.Reflection.V1Alpha {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -325,6 +344,7 @@ namespace Grpc.Reflection.V1Alpha {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (Host.Length != 0) {
         output.WriteRawTag(10);
@@ -357,6 +377,7 @@ namespace Grpc.Reflection.V1Alpha {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (Host.Length != 0) {
@@ -384,6 +405,7 @@ namespace Grpc.Reflection.V1Alpha {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(ServerReflectionRequest other) {
       if (other == null) {
         return;
@@ -416,6 +438,7 @@ namespace Grpc.Reflection.V1Alpha {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -462,6 +485,7 @@ namespace Grpc.Reflection.V1Alpha {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -517,19 +541,23 @@ namespace Grpc.Reflection.V1Alpha {
     private static readonly pb::MessageParser<ExtensionRequest> _parser = new pb::MessageParser<ExtensionRequest>(() => new ExtensionRequest());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<ExtensionRequest> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Reflection.V1Alpha.ReflectionReflection.Descriptor.MessageTypes[1]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ExtensionRequest() {
       OnConstruction();
     }
@@ -537,6 +565,7 @@ namespace Grpc.Reflection.V1Alpha {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ExtensionRequest(ExtensionRequest other) : this() {
       containingType_ = other.containingType_;
       extensionNumber_ = other.extensionNumber_;
@@ -544,6 +573,7 @@ namespace Grpc.Reflection.V1Alpha {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ExtensionRequest Clone() {
       return new ExtensionRequest(this);
     }
@@ -555,6 +585,7 @@ namespace Grpc.Reflection.V1Alpha {
     /// Fully-qualified type name. The format should be &lt;package>.&lt;type>
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public string ContainingType {
       get { return containingType_; }
       set {
@@ -566,6 +597,7 @@ namespace Grpc.Reflection.V1Alpha {
     public const int ExtensionNumberFieldNumber = 2;
     private int extensionNumber_;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int ExtensionNumber {
       get { return extensionNumber_; }
       set {
@@ -574,11 +606,13 @@ namespace Grpc.Reflection.V1Alpha {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as ExtensionRequest);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(ExtensionRequest other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -592,6 +626,7 @@ namespace Grpc.Reflection.V1Alpha {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (ContainingType.Length != 0) hash ^= ContainingType.GetHashCode();
@@ -603,11 +638,13 @@ namespace Grpc.Reflection.V1Alpha {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -628,6 +665,7 @@ namespace Grpc.Reflection.V1Alpha {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (ContainingType.Length != 0) {
         output.WriteRawTag(10);
@@ -644,6 +682,7 @@ namespace Grpc.Reflection.V1Alpha {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (ContainingType.Length != 0) {
@@ -659,6 +698,7 @@ namespace Grpc.Reflection.V1Alpha {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(ExtensionRequest other) {
       if (other == null) {
         return;
@@ -673,6 +713,7 @@ namespace Grpc.Reflection.V1Alpha {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -698,6 +739,7 @@ namespace Grpc.Reflection.V1Alpha {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -731,19 +773,23 @@ namespace Grpc.Reflection.V1Alpha {
     private static readonly pb::MessageParser<ServerReflectionResponse> _parser = new pb::MessageParser<ServerReflectionResponse>(() => new ServerReflectionResponse());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<ServerReflectionResponse> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Reflection.V1Alpha.ReflectionReflection.Descriptor.MessageTypes[2]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ServerReflectionResponse() {
       OnConstruction();
     }
@@ -751,6 +797,7 @@ namespace Grpc.Reflection.V1Alpha {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ServerReflectionResponse(ServerReflectionResponse other) : this() {
       validHost_ = other.validHost_;
       originalRequest_ = other.originalRequest_ != null ? other.originalRequest_.Clone() : null;
@@ -773,6 +820,7 @@ namespace Grpc.Reflection.V1Alpha {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ServerReflectionResponse Clone() {
       return new ServerReflectionResponse(this);
     }
@@ -781,6 +829,7 @@ namespace Grpc.Reflection.V1Alpha {
     public const int ValidHostFieldNumber = 1;
     private string validHost_ = "";
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public string ValidHost {
       get { return validHost_; }
       set {
@@ -792,6 +841,7 @@ namespace Grpc.Reflection.V1Alpha {
     public const int OriginalRequestFieldNumber = 2;
     private global::Grpc.Reflection.V1Alpha.ServerReflectionRequest originalRequest_;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public global::Grpc.Reflection.V1Alpha.ServerReflectionRequest OriginalRequest {
       get { return originalRequest_; }
       set {
@@ -810,6 +860,7 @@ namespace Grpc.Reflection.V1Alpha {
     /// that were previously sent in response to earlier requests in the stream.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public global::Grpc.Reflection.V1Alpha.FileDescriptorResponse FileDescriptorResponse {
       get { return messageResponseCase_ == MessageResponseOneofCase.FileDescriptorResponse ? (global::Grpc.Reflection.V1Alpha.FileDescriptorResponse) messageResponse_ : null; }
       set {
@@ -824,6 +875,7 @@ namespace Grpc.Reflection.V1Alpha {
     /// This message is used to answer all_extension_numbers_of_type requst.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public global::Grpc.Reflection.V1Alpha.ExtensionNumberResponse AllExtensionNumbersResponse {
       get { return messageResponseCase_ == MessageResponseOneofCase.AllExtensionNumbersResponse ? (global::Grpc.Reflection.V1Alpha.ExtensionNumberResponse) messageResponse_ : null; }
       set {
@@ -838,6 +890,7 @@ namespace Grpc.Reflection.V1Alpha {
     /// This message is used to answer list_services request.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public global::Grpc.Reflection.V1Alpha.ListServiceResponse ListServicesResponse {
       get { return messageResponseCase_ == MessageResponseOneofCase.ListServicesResponse ? (global::Grpc.Reflection.V1Alpha.ListServiceResponse) messageResponse_ : null; }
       set {
@@ -852,6 +905,7 @@ namespace Grpc.Reflection.V1Alpha {
     /// This message is used when an error occurs.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public global::Grpc.Reflection.V1Alpha.ErrorResponse ErrorResponse {
       get { return messageResponseCase_ == MessageResponseOneofCase.ErrorResponse ? (global::Grpc.Reflection.V1Alpha.ErrorResponse) messageResponse_ : null; }
       set {
@@ -871,22 +925,26 @@ namespace Grpc.Reflection.V1Alpha {
     }
     private MessageResponseOneofCase messageResponseCase_ = MessageResponseOneofCase.None;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public MessageResponseOneofCase MessageResponseCase {
       get { return messageResponseCase_; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void ClearMessageResponse() {
       messageResponseCase_ = MessageResponseOneofCase.None;
       messageResponse_ = null;
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as ServerReflectionResponse);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(ServerReflectionResponse other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -905,6 +963,7 @@ namespace Grpc.Reflection.V1Alpha {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (ValidHost.Length != 0) hash ^= ValidHost.GetHashCode();
@@ -921,11 +980,13 @@ namespace Grpc.Reflection.V1Alpha {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -962,6 +1023,7 @@ namespace Grpc.Reflection.V1Alpha {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (ValidHost.Length != 0) {
         output.WriteRawTag(10);
@@ -994,6 +1056,7 @@ namespace Grpc.Reflection.V1Alpha {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (ValidHost.Length != 0) {
@@ -1021,6 +1084,7 @@ namespace Grpc.Reflection.V1Alpha {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(ServerReflectionResponse other) {
       if (other == null) {
         return;
@@ -1065,6 +1129,7 @@ namespace Grpc.Reflection.V1Alpha {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -1129,6 +1194,7 @@ namespace Grpc.Reflection.V1Alpha {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -1203,19 +1269,23 @@ namespace Grpc.Reflection.V1Alpha {
     private static readonly pb::MessageParser<FileDescriptorResponse> _parser = new pb::MessageParser<FileDescriptorResponse>(() => new FileDescriptorResponse());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<FileDescriptorResponse> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Reflection.V1Alpha.ReflectionReflection.Descriptor.MessageTypes[3]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public FileDescriptorResponse() {
       OnConstruction();
     }
@@ -1223,12 +1293,14 @@ namespace Grpc.Reflection.V1Alpha {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public FileDescriptorResponse(FileDescriptorResponse other) : this() {
       fileDescriptorProto_ = other.fileDescriptorProto_.Clone();
       _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public FileDescriptorResponse Clone() {
       return new FileDescriptorResponse(this);
     }
@@ -1244,16 +1316,19 @@ namespace Grpc.Reflection.V1Alpha {
     /// bytes instead.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public pbc::RepeatedField<pb::ByteString> FileDescriptorProto {
       get { return fileDescriptorProto_; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as FileDescriptorResponse);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(FileDescriptorResponse other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -1266,6 +1341,7 @@ namespace Grpc.Reflection.V1Alpha {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       hash ^= fileDescriptorProto_.GetHashCode();
@@ -1276,11 +1352,13 @@ namespace Grpc.Reflection.V1Alpha {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -1294,6 +1372,7 @@ namespace Grpc.Reflection.V1Alpha {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       fileDescriptorProto_.WriteTo(ref output, _repeated_fileDescriptorProto_codec);
       if (_unknownFields != null) {
@@ -1303,6 +1382,7 @@ namespace Grpc.Reflection.V1Alpha {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       size += fileDescriptorProto_.CalculateSize(_repeated_fileDescriptorProto_codec);
@@ -1313,6 +1393,7 @@ namespace Grpc.Reflection.V1Alpha {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(FileDescriptorResponse other) {
       if (other == null) {
         return;
@@ -1322,6 +1403,7 @@ namespace Grpc.Reflection.V1Alpha {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -1343,6 +1425,7 @@ namespace Grpc.Reflection.V1Alpha {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -1373,19 +1456,23 @@ namespace Grpc.Reflection.V1Alpha {
     private static readonly pb::MessageParser<ExtensionNumberResponse> _parser = new pb::MessageParser<ExtensionNumberResponse>(() => new ExtensionNumberResponse());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<ExtensionNumberResponse> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Reflection.V1Alpha.ReflectionReflection.Descriptor.MessageTypes[4]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ExtensionNumberResponse() {
       OnConstruction();
     }
@@ -1393,6 +1480,7 @@ namespace Grpc.Reflection.V1Alpha {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ExtensionNumberResponse(ExtensionNumberResponse other) : this() {
       baseTypeName_ = other.baseTypeName_;
       extensionNumber_ = other.extensionNumber_.Clone();
@@ -1400,6 +1488,7 @@ namespace Grpc.Reflection.V1Alpha {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ExtensionNumberResponse Clone() {
       return new ExtensionNumberResponse(this);
     }
@@ -1412,6 +1501,7 @@ namespace Grpc.Reflection.V1Alpha {
     /// is &lt;package>.&lt;type>
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public string BaseTypeName {
       get { return baseTypeName_; }
       set {
@@ -1425,16 +1515,19 @@ namespace Grpc.Reflection.V1Alpha {
         = pb::FieldCodec.ForInt32(18);
     private readonly pbc::RepeatedField<int> extensionNumber_ = new pbc::RepeatedField<int>();
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public pbc::RepeatedField<int> ExtensionNumber {
       get { return extensionNumber_; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as ExtensionNumberResponse);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(ExtensionNumberResponse other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -1448,6 +1541,7 @@ namespace Grpc.Reflection.V1Alpha {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (BaseTypeName.Length != 0) hash ^= BaseTypeName.GetHashCode();
@@ -1459,11 +1553,13 @@ namespace Grpc.Reflection.V1Alpha {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -1481,6 +1577,7 @@ namespace Grpc.Reflection.V1Alpha {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (BaseTypeName.Length != 0) {
         output.WriteRawTag(10);
@@ -1494,6 +1591,7 @@ namespace Grpc.Reflection.V1Alpha {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (BaseTypeName.Length != 0) {
@@ -1507,6 +1605,7 @@ namespace Grpc.Reflection.V1Alpha {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(ExtensionNumberResponse other) {
       if (other == null) {
         return;
@@ -1519,6 +1618,7 @@ namespace Grpc.Reflection.V1Alpha {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -1545,6 +1645,7 @@ namespace Grpc.Reflection.V1Alpha {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -1579,19 +1680,23 @@ namespace Grpc.Reflection.V1Alpha {
     private static readonly pb::MessageParser<ListServiceResponse> _parser = new pb::MessageParser<ListServiceResponse>(() => new ListServiceResponse());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<ListServiceResponse> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Reflection.V1Alpha.ReflectionReflection.Descriptor.MessageTypes[5]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ListServiceResponse() {
       OnConstruction();
     }
@@ -1599,12 +1704,14 @@ namespace Grpc.Reflection.V1Alpha {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ListServiceResponse(ListServiceResponse other) : this() {
       service_ = other.service_.Clone();
       _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ListServiceResponse Clone() {
       return new ListServiceResponse(this);
     }
@@ -1619,16 +1726,19 @@ namespace Grpc.Reflection.V1Alpha {
     /// ServiceResponse message to encapsulate it.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public pbc::RepeatedField<global::Grpc.Reflection.V1Alpha.ServiceResponse> Service {
       get { return service_; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as ListServiceResponse);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(ListServiceResponse other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -1641,6 +1751,7 @@ namespace Grpc.Reflection.V1Alpha {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       hash ^= service_.GetHashCode();
@@ -1651,11 +1762,13 @@ namespace Grpc.Reflection.V1Alpha {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -1669,6 +1782,7 @@ namespace Grpc.Reflection.V1Alpha {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       service_.WriteTo(ref output, _repeated_service_codec);
       if (_unknownFields != null) {
@@ -1678,6 +1792,7 @@ namespace Grpc.Reflection.V1Alpha {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       size += service_.CalculateSize(_repeated_service_codec);
@@ -1688,6 +1803,7 @@ namespace Grpc.Reflection.V1Alpha {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(ListServiceResponse other) {
       if (other == null) {
         return;
@@ -1697,6 +1813,7 @@ namespace Grpc.Reflection.V1Alpha {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -1718,6 +1835,7 @@ namespace Grpc.Reflection.V1Alpha {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -1748,19 +1866,23 @@ namespace Grpc.Reflection.V1Alpha {
     private static readonly pb::MessageParser<ServiceResponse> _parser = new pb::MessageParser<ServiceResponse>(() => new ServiceResponse());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<ServiceResponse> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Reflection.V1Alpha.ReflectionReflection.Descriptor.MessageTypes[6]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ServiceResponse() {
       OnConstruction();
     }
@@ -1768,12 +1890,14 @@ namespace Grpc.Reflection.V1Alpha {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ServiceResponse(ServiceResponse other) : this() {
       name_ = other.name_;
       _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ServiceResponse Clone() {
       return new ServiceResponse(this);
     }
@@ -1786,6 +1910,7 @@ namespace Grpc.Reflection.V1Alpha {
     /// is &lt;package>.&lt;service>
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public string Name {
       get { return name_; }
       set {
@@ -1794,11 +1919,13 @@ namespace Grpc.Reflection.V1Alpha {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as ServiceResponse);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(ServiceResponse other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -1811,6 +1938,7 @@ namespace Grpc.Reflection.V1Alpha {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (Name.Length != 0) hash ^= Name.GetHashCode();
@@ -1821,11 +1949,13 @@ namespace Grpc.Reflection.V1Alpha {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -1842,6 +1972,7 @@ namespace Grpc.Reflection.V1Alpha {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (Name.Length != 0) {
         output.WriteRawTag(10);
@@ -1854,6 +1985,7 @@ namespace Grpc.Reflection.V1Alpha {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (Name.Length != 0) {
@@ -1866,6 +1998,7 @@ namespace Grpc.Reflection.V1Alpha {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(ServiceResponse other) {
       if (other == null) {
         return;
@@ -1877,6 +2010,7 @@ namespace Grpc.Reflection.V1Alpha {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -1898,6 +2032,7 @@ namespace Grpc.Reflection.V1Alpha {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
@@ -1927,19 +2062,23 @@ namespace Grpc.Reflection.V1Alpha {
     private static readonly pb::MessageParser<ErrorResponse> _parser = new pb::MessageParser<ErrorResponse>(() => new ErrorResponse());
     private pb::UnknownFieldSet _unknownFields;
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pb::MessageParser<ErrorResponse> Parser { get { return _parser; } }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public static pbr::MessageDescriptor Descriptor {
       get { return global::Grpc.Reflection.V1Alpha.ReflectionReflection.Descriptor.MessageTypes[7]; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     pbr::MessageDescriptor pb::IMessage.Descriptor {
       get { return Descriptor; }
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ErrorResponse() {
       OnConstruction();
     }
@@ -1947,6 +2086,7 @@ namespace Grpc.Reflection.V1Alpha {
     partial void OnConstruction();
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ErrorResponse(ErrorResponse other) : this() {
       errorCode_ = other.errorCode_;
       errorMessage_ = other.errorMessage_;
@@ -1954,6 +2094,7 @@ namespace Grpc.Reflection.V1Alpha {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public ErrorResponse Clone() {
       return new ErrorResponse(this);
     }
@@ -1965,6 +2106,7 @@ namespace Grpc.Reflection.V1Alpha {
     /// This field uses the error codes defined in grpc::StatusCode.
     /// </summary>
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int ErrorCode {
       get { return errorCode_; }
       set {
@@ -1976,6 +2118,7 @@ namespace Grpc.Reflection.V1Alpha {
     public const int ErrorMessageFieldNumber = 2;
     private string errorMessage_ = "";
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public string ErrorMessage {
       get { return errorMessage_; }
       set {
@@ -1984,11 +2127,13 @@ namespace Grpc.Reflection.V1Alpha {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override bool Equals(object other) {
       return Equals(other as ErrorResponse);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public bool Equals(ErrorResponse other) {
       if (ReferenceEquals(other, null)) {
         return false;
@@ -2002,6 +2147,7 @@ namespace Grpc.Reflection.V1Alpha {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override int GetHashCode() {
       int hash = 1;
       if (ErrorCode != 0) hash ^= ErrorCode.GetHashCode();
@@ -2013,11 +2159,13 @@ namespace Grpc.Reflection.V1Alpha {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public override string ToString() {
       return pb::JsonFormatter.ToDiagnosticString(this);
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void WriteTo(pb::CodedOutputStream output) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       output.WriteRawMessage(this);
@@ -2038,6 +2186,7 @@ namespace Grpc.Reflection.V1Alpha {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
       if (ErrorCode != 0) {
         output.WriteRawTag(8);
@@ -2054,6 +2203,7 @@ namespace Grpc.Reflection.V1Alpha {
     #endif
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public int CalculateSize() {
       int size = 0;
       if (ErrorCode != 0) {
@@ -2069,6 +2219,7 @@ namespace Grpc.Reflection.V1Alpha {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(ErrorResponse other) {
       if (other == null) {
         return;
@@ -2083,6 +2234,7 @@ namespace Grpc.Reflection.V1Alpha {
     }
 
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     public void MergeFrom(pb::CodedInputStream input) {
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
       input.ReadRawMessage(this);
@@ -2108,6 +2260,7 @@ namespace Grpc.Reflection.V1Alpha {
 
     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
       uint tag;
       while ((tag = input.ReadTag()) != 0) {
index b6e6703..50c06d3 100644 (file)
@@ -1,7 +1,7 @@
 <!-- This file is generated -->
 <Project>
   <PropertyGroup>
-    <GrpcCsharpVersion>2.40.0</GrpcCsharpVersion>
-    <GoogleProtobufVersion>3.15.8</GoogleProtobufVersion>
+    <GrpcCsharpVersion>2.41.0</GrpcCsharpVersion>
+    <GoogleProtobufVersion>3.17.3</GoogleProtobufVersion>
   </PropertyGroup>
 </Project>
index 760442f..5afa071 100755 (executable)
@@ -28,7 +28,7 @@ function build {
     PATH_CC="$(xcrun --sdk $SDK --find clang)"
     PATH_CXX="$(xcrun --sdk $SDK --find clang++)"
 
-    CPPFLAGS="-O2 -Wframe-larger-than=16384 -arch $ARCH -isysroot $(xcrun --sdk $SDK --show-sdk-path) -mios-version-min=9.0 -DPB_NO_PACKED_STRUCTS=1"
+    CPPFLAGS="-O2 -Wframe-larger-than=16384 -arch $ARCH -isysroot $(xcrun --sdk $SDK --show-sdk-path) -mios-version-min=9.0 -DPB_NO_PACKED_STRUCTS=1 -DBORINGSSL_PREFIX=GRPC -Isrc/boringssl"
     LDFLAGS="-arch $ARCH -isysroot $(xcrun --sdk $SDK --show-sdk-path) -Wl,ios_version_min=9.0"
 
     # TODO(jtattermusch): Ideally we'd be setting build defines that correspond to using cmake's
index 710b59d..2133a6a 100644 (file)
  *
  */
 
+#include <grpc/support/port_platform.h>
+
+#include <string.h>
+
 #include <grpc/byte_buffer_reader.h>
 #include <grpc/grpc.h>
 #include <grpc/grpc_security.h>
 #include <grpc/slice.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
-#include <grpc/support/port_platform.h>
 #include <grpc/support/string_util.h>
 #include <grpc/support/thd_id.h>
 
-#include <string.h>
-
 #ifdef GPR_WINDOWS
 #define GPR_EXPORT __declspec(dllexport)
 #define GPR_CALLTYPE __stdcall
index 70d7960..698a369 100644 (file)
@@ -42,7 +42,7 @@ Pod::Spec.new do |s|
   # exclamation mark ensures that other "regular" pods will be able to find it as it'll be installed
   # before them.
   s.name     = '!ProtoCompiler-gRPCCppPlugin'
-  v = '1.40.0'
+  v = '1.41.0'
   s.version  = v
   s.summary  = 'The gRPC ProtoC plugin generates C++ files from .proto services.'
   s.description = <<-DESC
@@ -100,7 +100,7 @@ Pod::Spec.new do |s|
   s.preserve_paths = plugin
 
   # Restrict the protoc version to the one supported by this plugin.
-  s.dependency '!ProtoCompiler', '3.15.8'
+  s.dependency '!ProtoCompiler', '3.17.3'
   # For the Protobuf dependency not to complain:
   s.ios.deployment_target = '9.0'
   s.osx.deployment_target = '10.10'
index df57915..87ff17e 100644 (file)
@@ -42,7 +42,7 @@ Pod::Spec.new do |s|
   # exclamation mark ensures that other "regular" pods will be able to find it as it'll be installed
   # before them.
   s.name     = '!ProtoCompiler-gRPCPlugin'
-  v = '1.40.0'
+  v = '1.41.0'
   s.version  = v
   s.summary  = 'The gRPC ProtoC plugin generates Objective-C files from .proto services.'
   s.description = <<-DESC
@@ -102,7 +102,7 @@ Pod::Spec.new do |s|
   s.preserve_paths = plugin
 
   # Restrict the protoc version to the one supported by this plugin.
-  s.dependency '!ProtoCompiler', '3.15.8'
+  s.dependency '!ProtoCompiler', '3.17.3'
   # For the Protobuf dependency not to complain:
   s.ios.deployment_target = '9.0'
   s.osx.deployment_target = '10.10'
index 5da8b30..3b23259 100644 (file)
@@ -36,7 +36,7 @@ Pod::Spec.new do |s|
   # exclamation mark ensures that other "regular" pods will be able to find it as it'll be installed
   # before them.
   s.name     = '!ProtoCompiler'
-  v = '3.15.8'
+  v = '3.17.3'
   s.version  = v
   s.summary  = 'The Protobuf Compiler (protoc) generates Objective-C files from .proto files'
   s.description = <<-DESC
index aae630d..3820725 100644 (file)
@@ -39,7 +39,7 @@
 
 Pod::Spec.new do |s|
   s.name     = 'BoringSSL-GRPC'
-  version = '0.0.19'
+  version = '0.0.20'
   s.version  = version
   s.summary  = 'BoringSSL is a fork of OpenSSL that is designed to meet Google\'s needs.'
   # Adapted from the homepage:
@@ -76,7 +76,7 @@ Pod::Spec.new do |s|
 
   s.source = {
     :git => 'https://github.com/google/boringssl.git',
-    :commit => "bcc01b6c66b1c6fa2816b108e50a544b757fbd7b",
+    :commit => "fc44652a42b396e1645d5e72aba053349992136a",
   }
 
   s.ios.deployment_target = '9.0'
@@ -153,14 +153,15 @@ Pod::Spec.new do |s|
 
   s.prepare_command = <<-END_OF_COMMAND
     # Add a module map and an umbrella header
+    mkdir -p src/include/openssl
     cat > src/include/openssl/umbrella.h <<EOF
       #include "ssl.h"
       #include "crypto.h"
       #include "aes.h"
-      /* The following macros are defined by base.h. The latter is the first file included by the    
-         other headers. */    
-      #if defined(OPENSSL_ARM) || defined(OPENSSL_AARCH64)    
-      #  include "arm_arch.h"   
+      /* The following macros are defined by base.h. The latter is the first file included by the
+         other headers. */
+      #if defined(OPENSSL_ARM) || defined(OPENSSL_AARCH64)
+      #  include "arm_arch.h"
       #endif
       #include "asn1.h"
       #include "asn1_mac.h"
@@ -212,499 +213,504 @@ Pod::Spec.new do |s|
     # limit on the 'prepare_command' field length. The encoded header is generated from
     # /src/boringssl/boringssl_prefix_symbols.h. Here we decode the content and inject the header to
     # the correct location in BoringSSL.
-    base64 -D <<EOF | gunzip > src/include/openssl/boringssl_prefix_symbols.h
+    case "$(uname)" in
+      Darwin) opts="" ;;
+           *) opts="--ignore-garbage" ;;
+    esac
+    base64 --decode $opts <<EOF | gunzip > src/include/openssl/boringssl_prefix_symbols.h
       H4sICAAAAAAC/2JvcmluZ3NzbF9wcmVmaXhfc3ltYm9scy5oAKydXXPbuJZo3+dXuO683Kk6NRM77bT7
       vim20tG0Y/tISk9nXliURNk8oUiFoOy4f/0FQErEx94g94arTs10LK21KQDEF0Hgv/7r7DErszptss3Z
-      6vX0j2RV1Xn5KESR7Otsm/9MnrJ0k9X/KZ7OqvLso/50sbg9W1e7Xd78v7PVev3ufPVh/eHD6nz9YZte
-      XJ3L/3p3lV2+Sy9/+WX16+Wv29Xm19W//dt//dfZdbV/rfPHp+bs/67/4+zi3fnVP85+r6rHIjublev/
-      lF9R33rI6l0uRC7jNdXZQWT/kNH2r/8421WbfCv/f1pu/quqzza5aOp8dWiys+YpF2ei2jYvaZ2dbeWH
-      afmqXPtDva9EdvaSN/IH1Pr/V4fmbJtlZxJ5yupM/fo6LWVC/ONsX1fP+UYmSfOUNvL/ZGfpqnrOlGl9
-      uvayavJ1pq6ijbvvr/f40X6fpfVZXp6lRaHIPBPHX7f8PD1b3H9a/s9kPj2bLc4e5vd/zm6mN2f/Z7KQ
-      //4/Z5O7G/2lydfl5/v52c1scX07mX1ZnE1ub88kNZ/cLWfThXL9z2z5+Ww+/X0yl8i9pKSvd99d3369
-      md39rsHZl4fbmYzSC87uPynHl+n8+rP8y+Tj7Ha2/KbDf5ot76aLxX9Kx9nd/dn0z+nd8mzxWXmMK/s4
-      PbudTT7eTs8+yX9N7r4p3eJhej2b3P5DXvd8er38h1Qc/0t+6fr+bjH951epk985u5l8mfyuLkTTx3/q
-      H/Z5slzcy7hz+fMWX2+X6md8mt9/Obu9X6grP/u6mMoYk+VE0TIN5SUv/iG5qbzAubruifzf9XJ2f6d8
-      EpChl/OJuo676e+3s9+nd9dTxd5rYHk/l9/9uuiYf5xN5rOFCnr/danoe+XURfj+7m6qv9OmvkoPeS36
-      KqZzmRBfJlr8yc6N/9Tl/+P9XDrl7ZNMbm6Sh/n00+yvs30qmkycNS/VmSx6ZZNv86wWsvDIwl+VmcyE
-      RhUxWah3Qv1BifJG3a2qxFXbs126rquz7Oc+LXUhlP/LG3GW1o+HnfSJs1Um4UwHknfvf/7bv2/knV1m
-      4OX83/QfZ6v/AD9KZvKnz9svBB3mF8/Ss3//97NE/R9ZB5yo2X2yTWQtA19D/8f2D//ogf+wHCJrqJYO
-      6T03y9tFsi5ymVTJLpPVw2aszicdK0MHekRWP2c1R2eRjlXVhcnqsN3K4sZxA7wd4fk8ueCnrE8DdqYW
-      9bFT2qc9e0xKhNPhUZbpJt9lqmWjeQ3Ssz7JFq7ImGIb9tysREB+fUyehXNM1RV5mTd5Whx/SbI5dDUv
-      NRCu6uNO5/OkqNJNogyqdyO7YmMDQWxvvn+Y3qkP1DVQqkyX640P0y9JnXXxFrK7oNrEkVaIBcyrvIqy
-      O7wd4aWWrShX78GQO+LyQUEfQ/3xevYgey7JJhPrOt9TiiRMg3ZVP6QHWc+X+YahN3HUv1K9FZ5boah3
-      ne9l/z7iynsBGmOTP2aiiYjRC9AYbHfA+f1nUqa7jCnu6KCdfdUtjLp36c9EVtmCV94dAx4lL2Oj9AY0
-      SkQWBNN/X28jMqCjA/aqqdZVkUREOBnQKPV2HZM+Rxz1P6fFgSvXLG6OKjehMpOLJJXtGsPckZh1VVTr
-      7119x7ObBjCKaGSPMK033Ey1eCfC/ZeHJN1sknW129eZnoohdgcHNEC8bZ1lwDcFOSImAmLK8vGOnn4W
-      CVvf5IcgHiRivmEFyDeIj5ssUKos/1Ll4F2yfkplLb7O6oZk9nHQfx7nPx/y60+sHEmLR0Yg0INEbIep
-      1xNWmCMMu7OfTZ3GJZnngCOJ9mdyAnSo710/ZbJ+3Nf5s5pl/569Uu2eAIjR9lflb3usq8OeHMHGAX+R
-      pbWReoIcwRVgMdx8YkbyNFi8XbXJeCEUiVkrPa5iXnsH++6sTFdFllRrsVeN4r6QA31qCMiBRhL5Y5l1
-      tYCaupDAbi+YIWEZGrsphMq/sszI3U1M4sfaFgfxdLx1yT/MpgG7bN/JTsn4Jt2Iq5TLt/la1gJUq8tj
-      EdT9wnMrMmTl3cwuj0TYp3W6Y7k1iVnbGpdRYzs46G9vBNGo5zN0vUEjdl2lC5a6RRHvsalOilw0LL1l
-      gKPIP6WHQg4XUyFeZJ2x4gTyJCNjJQeR1Zu0Sd8k6MkGR89+JtxQHYp6y+xFNumb7CdTfuKxCJEtNSiB
-      Y+XltkrWaVGs0vV3ThxLAMeQN2pRPUZFcRRwHDUJpe9e7g1kCfAYeqqFNSWBSZBYMuviY7kSJBajt3bk
-      YCOzp2agsPfHIVePm58OzaZ6YSWJbYCj6Gcd6RN1ZsijYXvXs5HlWQ5B2GnvW+BoxKeNAIp4CyFrGfmd
-      9ff2FmVltm+Bo8nim29fo2oRRxGMs8n2zVNEEM0HI3Cz3cB9v35a2X2jqNYp6x4EJX6sMpOjjma3T+YL
-      8uSEyULmF7rwxffU2a56zriTDzbt29UHSbpey5ymqg006E0eq2oTIdd8OEKdldlj1eSMwQ+iQeK11dT2
-      UBSsOD2O+VfJU07vLJksZq7kOHfNy+SODZv52WwKBmLEZjTgQSLqwYjOLpH/zQtmKwJx9BdX7BgtHvCr
-      vnqEv8UD/q6SiQhxMiBR2DdF4I5Qi3MznrVFEW952K2Ij8tsFPGK+BIpxpRIEVcixVCJFHElUgyVSBFd
-      IsWIEtn1Knnl5whD7uZdt3gy2VcVo5mxeSQCay5PBOby2s+OkzeCpz7hiP/Y92XPjcEWMNo5O43OA2kk
-      PzvUz5xa54QGvaxpA5dHImTrJ9YAyYIRN2uOticRq8gf0+KRd8EdGzbzk9sUIDHinnEACiTOW9xV5yPv
-      qkQOW6uX5FB+L6sX9cB4383scDIJl2GxI6ON8YusUB1MTsvjGuAo7VN3lr5DA15u/g/mu/48cvoD8yAR
-      9bRxWm44T9U9ARKjfTTOrAVMHPFHPU8RI56nGN+JKViWAYlyqGv1JdX34YaxFVgcWQx3XRnhRTEEcIzo
-      J1Bi3BMo8aZPoATxCZT5/e6W26fNk4iJa3qQiJXQtaysA/XEMC9tXQkcK0vr4lU/J+vWBHCaWcCCROM9
-      zROhp3nqw21aiEyt16i7JjHbJN0LrbpF4QQccsJX8lhnqcQi0tI2wFGinveJ4ed9Iv55nxjzvE/EPu8T
-      w8/7xFs87xPjnvcdvyYy2WZu6/RRvWbKjWVJkFixzxbFuGeLgvlsUaDPFvUnIq54mfxwhCStH2OjKAcc
-      qVRPv9pUjOr/Qp6hiCJJN89q8ZLINtFhHRkcWy+PqzOxr0rBKhSWAInBe/IsQk+e1YdqU4JDk6mlFVkp
-      uCF8CxKtX5bKWXiPWpBo4vupJxpxYwEaPF73omhsPEeDxOs2reDEaFHY++OQryOyx8BRf8RqBzFitYOI
-      Wu0gBlY7tJ83ajRYlbKnJ57Si8sPSbU1xz2CF3XIil1N14+WfVtZjxx2GS+6a4GjHavifoUos54FRVjM
-      2NUlYuTqEvN7uXrJp2xktRYTrbeEo6kbf/OUcde2BFRIXGiNNbvjidvw6Hn5qF4SqWo5ktjpnYQENzSg
-      QuLWzV417tu8yHjRTAESo6nzdfR0kG+Bo3XLjNSLexHVtm/BorFLZ7A02nPTMWNG2IRGVZ29tr1Vr3hx
-      O8agaGzMmO4CbgtHb9LmIGJ/7UkyJhavkXAdwUj9iru4aJZnZETxJvFEMNpBTcLI+ici1FGBxJF19uaJ
-      pddkyBpXzG0FHidb869fsbi5FilXLNGgNzppTAcSqT7wmiENwk7+pHpoNr3rhb5BxwA2BaOy1siKwTWy
-      BzXA31K9LQXY5D380I6C/6A/zLLpIXsyWdydx4XQisE4qj8VGUcp4DjzxSQuwSzBiBjsZPMtY6JxE8+3
-      wNEiXid08EE/O+Vcx3Ck9pEuN+1g03DUt4iHR1JDv3aDyOY1ecrpM+6gxI41vf6c/DH9tlDvslP0JocY
-      qa/BWiDifEpFsjnsiy6rqnKbPxKX0Ay5kMi7tBZPaaEmdurX7tuCFRc0IVGJrxqYHGKkN18Oanu7jcoS
-      tVnu6TFi/9iUEmdABcc1ntCu070aHnJC+hY4GrVImxxmrHbJ6rWhTWD4NGxv36Mmb/ID4AE/b2oNUQTi
-      sB/O4JZAtH0WkWYKHnCbbYCICmSZhqK2c9Fx8VpHINLbTEeOVAauox2Ls2O2OOrnrPoA8KCf9S435sAj
-      0VpQm8StO7XPdU1dpAcb8CinreUYSwVCHjxiN8VT5NtMr1ejds2GXKHIu4wfaZeFzcS5YADH/ZGZE8wT
-      1ZGLrNwcBR6HX6X0NGzPRfuojtuHMXk4ArEzaWCwT68O51UdHRr0xvQqHAUaJ6YOF0N1uHij2kmMrp36
-      pz/cOKESKiJqIBGsgURcDSSGaiAhxxLFJlmpt+PKxyJTI2NWIMADR2wqfq/+yIbNybaqIzIb0MDx6ANG
-      m7St9BfSoffQI/ZqDO7TGLFHY3B/RrVRYLpvpxrUQ31ZYBvKTu8hhx+JtSdjYD9G9ZGapepeBTms/pWt
-      G6FKkOyF0x50DKicuIX6ktqwvNvdnhTJhQfcSVFFBtAGKIoepXcPFVQTXTT0OL4DitS87jN2WhnwgJuZ
-      Vq7BjtKu5HnKSYlzglyXWvdU6AXnzB04EYUTRy3kardvJLl7zPHF7Bk6sF8o/SqB64vZD3RgL1DevpzY
-      npzs/TgDe3EyNtoA99dYH5rmqa4Oj096j90ioz2JAXDbv5HF9lGd85as60xP/aeF6qmQeuqoxIlV6YNf
-      5LDpO+lHmJxjlN0GxmtxBmb72rnd00r3dfOzX9ysxpaUIEMuKLKeVW47MbQcAHDUr96tUX0CctWPOZxI
-      6yfeTzA4xxi5p+3wfrZvtpctYR/b6D1sR+xfm9W17LEzD4HxYMf9c1/VevGSaqN38vav5W1PCgAa7CjU
-      pyj+05PT4ZVqWZc+iIDi82nX3rwzX9imlXmfBuzmA2DVLRLkCJ4BisJrqMO777YHC/Sv85y2W6KnEmgB
-      orGf/Aw98eHtIoztINw/IYkd64VNWFTuE6UxT5L673Qdg+5UgHY1FjMcqMLiuivAmDE9DRCve2enzn4c
-      ZDUvK33ivjeoBIwV84ICooDivMkzOdKzuEe9HQp9d0OT84xJt7iFKDxivo+5HspBAW+72H/1Sj94CMBR
-      PyMH8fcQmDuIo7uHx+0cPrRruPF5LccS1Y4pb2HA3W1KQV9A4dMBe3/MCjtEr8Dj9McFM6OcBGCM54zY
-      1TU5zEg94scmfetxrwrGswYA9/3eaIoawRMAMVQXnuxVEOCiP/1CVy4YHyR/Xb77LVks7+dTvQ4x3/xk
-      hgBMYFTWOonw+ohum/qdSMRhrwY1dLUB++4t+W7ZAveJ/EcunjK6q+N8I3sPjoH99vXHz+R2RSK+5zRw
-      S4qMfI9ZsO9m79sxsEd/9P78I/bmj96Xf8Se/Jz9+OG9+Jn78KN78OtVPMdhDH2TRwAP+JldRpdHInBv
-      awvG3IeiiE0ix4FE0vsHNLJ7JfSkkB4yC1Y80IREVcOTtDnUWT/IY8UEPFDEcqNmunh9RJsG7KyjiGwS
-      sBqvBJC9Bhs2k5fFgQI/Bn/PiaHTNfR21au8ojoVA5hYu1aEzuc4fSbUnEK5zljiIwy46V2SGuqTiGyt
-      7pp+J3Y9ecXrRIVcUOR2xtV6s58eEpBAsdr5HdbI04JRt3odlHHv2zRm54ytejJk1fPRfLXGIT9rjIzO
-      I4mntFazWLzpDptG7Yx9in0asvNqP7zeAxq77qR6cgzUNC6q6p6zClDANS4y645APEBE7m4lj+GdSoxV
-      5OljlojvtFW+AA742Q80fRq2H8r8B32StCdBq7HbxOkhECMEpBmKxynBvsGPErHR8uAZUzHnS4XPloo4
-      Vyp4ppTxIX1hnQeDbk6bg46bXxi9yxewd/lC76u9QH21F1llZewOpU3bdvW+Q+xzUMxhR8pL5hunFug5
-      jY1yiVKD9KxybE7VKcTxiGQjawuSp0U8j5Kzphtc1jO3PTqisoV8F9DMqo1S9oKaCAGTHVX1HQ77DXGO
-      p6dsW5Gv6rR+JWe/yTlGdQxe/3iMOtIBcMDfrhdql4QJst6ibfsufczXp/mP02Z3Dam8oBI3VvvCvVqN
-      1r5uTwvi0q5dbWksv1DJgksd7nuw7eaeYYifX0h8B8x796s87OzBOKlU+LRt32cZqUujvu8adGGgSTTi
-      eOpqrc5z0hOP+0o0vGWuAQ0cT1bR5+/1I6ljcaa/4jPk8iI/55usvURqC+rBtrvdQFaW8dOvTrZF/vjU
-      UJ/bBEVATD3TVWTPWUGO0qOAt+3w8MQGa5trYqVRe/UE8/BE9KxE4wPOHQXgrl8vijJyU831CloMUOHG
-      Ee5D9X8RV/AjCjtOt/1tv56REsGDXbfaLl9GLtrXaGhqm3XNam1u/nfWbnqSF3mT06YmYAMWJSK3UYkb
-      q63n6oz6uoNNulbOuXrYmXoR5+kFz9LTH1IfX5wgwBV1etiY8/j0d144V/wCXfE5K4/OkTzinOeHnuUX
-      c45f+Aw//Sn0rg45BCQBYvXdYN4vcXggAnk9NnZaIPekQPyUwKgTAgdOB4w8GXDwVMD4EwHHnAYoeCt0
-      BbZCV5+d157hreZFqddrsYCZd25g8MxA9SG9TkugGo1zcBt6GmDUyXkDp+ZFnJgXPC0v7qS8oVPy9Ofd
-      seGswmXBgJt7Xt3AWXXx55uNOdtMf6d9HU3V2e3xXeQgrgCKsa3qdaYn4fTsmUgfGXEACRCLvt4V3eVF
-      kNdwCmANp/pbVL+4GeoRR6zoHDhRTX38r8338/Pkpaq/p3V1KMnp4fJ+BPZ6zIEz1KLPTxtxdlr0uWkj
-      zkyLPi9txFlpnHPS4DPSYs5HC5+NFnsu2vCZaPobzYEsbQ6+h/1K48ApY8wTxtDTxeJPFhtzqlj8iWJj
-      ThN7g5PERp0i9gYniI06PYx5chh6atjpyC9zO1z6O4kBDRKPl93o6WSnD2OWHqMSJJbaa1sNoNdqS+dN
-      tq/ykpdqkAiMyVwHNnTqGv/EtdBpa+1n/bQwpzVxeSjCW57lxjnHTdDX0QpoHa3grXgU2IrH+LPQxpyD
-      pr/zlG2MPin9gSsqgWLxyj9e8t/mNWnKKWpvdILa6NPTok5OGzg1rT3rjDGSRkbQcaevjTl57W3OKxt7
-      VplxeNOTehhMXXEK8WiEmJWPYuzKRxG98lGMWPkYeW7W4JlZvPOysLOyIs/JGjwji3s+Fn42FvNcLPRM
-      rNjzsIbPwmKdg4WcgcU7/wo7++ptzr0ae+ZVzHlX4bOuRMzaWhFeWyvoK1gFtIKV1f7DbT+51QJaLPUn
-      xh5sJocbyZtuerDtbqpGH0LDXcsF8XYE/tlmoXPNIs80GzzPLPIss8FzzKLOMBs4vyz+7LIx55bFn1k2
-      5ryyiLPKgueUxZ5RNnw+WewpYcMnhEWfDjbiZDC1DiZ5yoqi6k6q6lZcEcOADjsSY84anKV+SWmJoL7v
-      GNQSPZJCAZbj+eL9cXqAPK3lsZ6ZpURc3dwiS2mxvXl5u+D9eA+0nXQZZGH9YA+0neqcsmR12G5lgWSY
-      AdzyP58n5+wU9WHfzZNiNm4K+7DrvohJhYtwKlwwpZgtIhUuwqkQkQbBFOAIYVPEb0d++eYiT4xTJcY6
-      HQz1UdbqAGjvzS82nOt0MNRHuU4A7b2y1b+ef3tY3icfv376NJ3rAXZ76OL2UK7HxhjQDMVTe/q+QbyT
-      JhBvk2V7fWHsUCdDIIp6zaI8FAU7yFEQinHY8fWHXcC8P4gntlrBAbcY//YKxAbMpI01YdqyL+bLB/n9
-      ++X0eqnuG/mfn2a3U07eDqnGxSXld8AyKhqxDIQ0djy1rnP28PlUR+z21DsfU2Bx1FrmJuMFaFnUfNgz
-      tYc95pR/2vCkisSsnELr06idVjQtEHNSC6BNYlZqJeGilldvR3k3+TJlF2XEEIzCaJsxRSgOp03GFEgc
-      TlsM0IideCPZIOYkHFbggYiT8BKuy+FG6s3uw4h7X+35qXCEMTftlrdBxKlXT8fcmKYAi0HYyswDfWfc
-      7Td053ELB14uaLX/EfE93KKFlyrxlG/JOaMh30VtOXqod02ur+UgLLmZLq7ns4cl9RB5BA/6x28wAcJB
-      N6HmgmnDPl0k118m16N93fdtw3q1TrJyXb+OP1TSwRzfdnV+ccVSWqRjbWqu1SJt6yYj6zrE9mTrFefS
-      DMzxMVyQp2LnRRXIC6E3ctcfUN6CAlDf2wXkeA3U9h7KlzrdU5U9hdmSfbrZjF/mBMK2m3Od8FVGXCN+
-      hYu782Ry941SP/aI4/k4WyaLpfp+e+wiyejCuJvUVAAsbn7Urxw2XHmH436+OmSlND8+insJU1QAGvTG
-      pLKAU/nLA7t4WCjqpV6xAaJOctaZpGu9v7+dTu7I13nCHN/07uuX6XyynN7Qk9RhcfMjsYzZKO7N2dpQ
-      OlCzy0Zxr+CnggilQlMlH++4Zg077k/MQvYJLWW/T+9kvNvZ/05vljM5FEw3/yKZAX4gAr1pAg0DUci3
-      DCQYiEHMBB8f8FOLO8APRNjXhCU6uGEgCvX2AvjhCMQljgMaOB63hfPxoJ9XrrDWzv6YWabQVm82ueSm
-      io2iXmJqmCDqpKaCRbrWu+X0d/UMaLenOXsOMRIe67gcYqTnkQEiTmoXwuAQY84T5piPnNs9hxgF8zcL
-      9Derqucgq9IPv3DFHY746V0Ri3Ssd19vb+mF6URBNmKmdwxkomb3EXJc9x//e3q9VPtOERb6+iRsJaed
-      wcFGYvqdKNhGTcMec33Xy2k/sUCsIl045KZWli4cctNzy6VDdmrO2WzITM5FBw65qVWgCzvuB/n35eTj
-      7ZSb5JBgIAYx4X18wE9NfoDHIkSkTzBl2GkSSA1+OgRTgPJKJ4A63sX0n1+nd9dTzmSsw2JmrhUwLnmX
-      uUSusC1ubdqkmw3N6sAh97rI0pJYT0OCUAxqd9SFYTe15ULbrOMHhNUmLgcbKVuIuRxi5OXUBssfcpWF
-      1+T9hP879g8/waj7dLTyLhXfmSEsBxypyMrH8e/I+iRspVa6aJvTfUCfKjLBgDMZfz4yxIbNyXYfI5c4
-      7Be8WkZg9YvaQJgpfIcak9Vrcje7YXo7GrfH3h1i1N3hfitJxfotoikPHFEOeL8uP11xgnQo4qV2WAwO
-      N3Jv9CPrmJcfzrnVtY2iXmKvxQRRJzUNLNK1Mp+xLNFnLKwHK8jTFOYjFPS5if5gk2+3dJ2iIBu94CDP
-      WzgPWeAnK6zHKcgzFOaDE/RpCesRCfJcJOZhSPgJiP5UVm+PWZnV+tCDjdo/ih7Bd7iRvj1Myf3tIwS5
-      6OXxSEE26vjiCEEuconsIMglONcl4OtSe6qzZOeO7evd7M/pfMF/cgYJBmIQKwwfH/BTMw3g3QjLa1YT
-      YXCIkd5QWCRm3e315nFJw1OfcMRPLyUGiDhz3rXm2DWSS0HPIUZ6k2KRiJVaLRgcbuQ0Lz7u+T9dsasJ
-      m8XN5GJgkLiVXhhM1PH+OVvMIubBfTzoJyaICwfd1GTxaMdOO/rbQBxP2/9o5PBHbeFJ8tko5n1+z5M+
-      v/eMTVKtKKeDOZjjy5tsl2wucpLtCCEuyh4AHog5idM2Bgca6QXH4EDjgXOBB/Dq1EEOnCxpOcRIrjdM
-      EHHmFxuWUnKIkVpDGBxk5P1o7Bezfi7yW9XmF6z7pAMxJ+c+aTnIyMoOJC/2KbHneaIgm9pEmG5TFGZL
-      1s1PnlGRkPVQ8n5zy0FG2v6fLucYd6tu10XysyeLxKwlX1sC3rb5kun9N+2ONjjHKHvJu7zJnzN6NWGj
-      rvfQJFlFm5PuGMDEaO17zPE16eMF9UWPjgFMYvwx2CbjmrLdvtD7B1IzwSIN69flZwksvyWzu0/3SfeC
-      J8mOGoaiENIW4YciUGpkTADF+GP6bXbDTKWexc2clDmSuJWVGie0936cLGbXyfX9nRxqTGZ3S1p5gemQ
-      fXxqQGzITEgREDbcs/sk3e/1kU55kVE2gQdQ23s6vWjd1AXFaoGOs8jSOtkW6fhjNB0M8rUbgjKtBuy4
-      1UYn+ihl/RWS2UYdLzU5/VSUf9HDRX1ECnEzVVSAxGjPGn88pHVaNlnGCuM4gEjEo8FdzjZuquN5ihRf
-      T9m2rNpSNPLrNq92hCE9RrYgx1UQdjk5AY6jpuWiU092f0nSoqBaFGOb9FobwlIgk/FN47eB7wnAsidb
-      9r4lL/OG6lGMb9qpSQhGGh052Lgf3zF0MN+ndneR5XX8kiAP9J3MOt1BMa86QHT8NtEQ65upJwi4nGek
-      /nDn1z5lPzeHHakwd4jtURlUkspyS7iWhtzyHRnbpIqhPjKqpKWQybnG5olcLZ4gwEXp4BkMYNIbSJFe
-      ZgFQzEvMDgtEnBvZkairV5a2YxEz9YawQMQpB+E8pwIRZ0046s4DESdpM3mf9K0VvUdiYLaPWNi9cq4a
-      gVVeJfs0r4miE+cbGR1AA/N9tL5FSwAWwvkNJgOY9mTP3reoOnF12FJVHeb7RLX+npETvaVc20+i56dr
-      OOxWWU2+Hw0M9Kk7SrYhDGVH2lbGwAcc8+wrUoGQX3d4tRyBVBBawrE0NblZOTKOiTjQ2XvjHGrl7tfp
-      1KLjl5n2DFNRnlM1GgJcnFkeC3Sdgna7asBxvPCu6gW5JsGpuwVccwtivS28WluQ62wB1NjqRI4dTSIB
-      10GvXQVYt+o+XEE469mCAJdMen2KJLUMeDDiVgOBPWGfVBBG3Gwv7KSO1AU4myHIsxkCmM3Qf6OOoE8Q
-      4NqTRXvfQp0ZEeDMiOgmJIi9FwODfVm1VeP8Q11ytD3t20vCUgKT8U2neQhyCenJgJU4MyKCMyP9p2Kf
-      rfO04Kk7GHOTB0gO6ns5szkCnc05DcW6E5pIj8hRgRPjqToUm0SOiDgp7cKgm1zkegzxER+smBxopBcE
-      g3ONbU7Kz2jCE+b4Snof+8jYpiYTjIq9p2zbQR3GTLqqlrAtz9T5s2d/7uyZk0TPcBq9MAZWL+DIilyk
-      gLLU3rrERyYnCHJxutw2aVhvJ39MLz5eXH4YbTsRkCX5lJeE6sfhQOOM0mmwMdD3db+hzKm6oOG8Sz7e
-      zu5u2vf8y+eM0Jv0UdhLurUcDjbm5XNa5KQkAGnUzkyGPJAKlHlGG7N818u/kmz84R494VmI2XJEPA/h
-      5bSe8Cy05OkIzyKatKZejWYs0+/Tu+uPeh0IQdVDgEuQ0ujEWKYv93dLfcGURY8uBxuJRcHiYCMtO00M
-      9alKRjSUF0BRAR5jW9XJrtocioPgRjEUcBxaYTAx1JcUap5kw9R2tGVPVyLJRfJS1RSrQdm2Dcmy8Wjy
-      hXSI7RHri1VJsWjAcqzykuZoAdsh/5KTHBoAHMRjAVwOMO5Tum2feqb1asW6tp5zjZtsTVNJwHU8EdZ4
-      HAHXUWSsH3bCXN9un9NMErAceh0gQaG/7xso2/ObDGAiNic9ZLsIiz/u7Pfw239T64wjYntoja3Xxq6r
-      Q6kq2Jfk76yuVIIJks6jLbss47TaqAVsR/5MEeTPLk1N5yNiew6U3LbeapP/zsqntFxnm2SXF4V6/Jnq
-      Sq7Od7Kn37zqyQOCfozOjv/jkBasDopD2taflDSR37Zo4l3o3X/butrJjkzZPFa7rH4lqSzSsj6uKUVF
-      ftumj2+tqrzIElJ17rGOuUnq7fr95cWH7gvnl+8/kPSQwItxGL/Zck94FuIdd0Qsj2zbaHVHC1gO0sOQ
-      O/c5yJ3qK8o6jdgj7iHXVWaPqXpliiY7Uq6tInVaW8BzlMSLkYDr2FcvFzSJIjwL/Y4xKNi2TWWtpeZl
-      eVoDd/3EAg6NOeTfVKNJsyjCshQZ7SbR37cNpJMYTwDgOCdLzi3LLq3Fk2xtSCs6bMzxie/UHs2JsU3V
-      hjhG7AjIkvw45OPfiXU5z0hrhTsCslzoNpHuajnIyBSGfaxuDCzAYxDvb4/1zHrqVVAvuaMwW7Iq1GLw
-      Dc96pFF7teGaK6Dkk+uZHkJc5yzZOWZj3ZcWi5gjxIh3dyiIOklAFl4H2oc9N7FTcEQ8j/hREzWSgCwN
-      XeOXO3FYUTWHFWRhFYkT5xkZ1ZVfS+1zWleiBWwHrVy6ZVIWKeov6RDLQ5vcd+f0y1ImD4VX3/cN1Dug
-      h2zXYUftwhwR0ENNYIvzja+yf0y1KcYy0QYh7ghkn6oWR3X+kkOp9iIhtYcAbdu5czSB2RjSrnbH7/sG
-      yoLBHrE9IjtsqqROSU9sDQqzqf/zmPGcLWuZiRfoXRnrkgLX0v6ZNqy0ONtI7RnVfq+oJveIaqA3RDwG
-      tyc8C2Oqw8Q8H21eSgDzUoI+LyWgeSlaj8TtjRB7Il4vhNYDcXsfqgdBTYMOsTxNlThHsxKMPgy6u7PW
-      GOKOdK2srq7FWcYDbULg4M4GHGgPkA7uE6QDrSgc3LLwnBaHjNj2nhjLRJzGcuawTl/ZHsp1k1dl8kSo
-      gUAasous2NLacB81vF8/JV+mX7otXkYrLcq3kR6JGIxveqyrF6pJMbCpPWOI42tJ30rpoveI71EvTNXP
-      5ETrMNu3y3aUp3wnwraIpiZaWsKzFOu0IWoUAngIT4h7xPOU9J9VQr+rLLKS6inM9zqvP37U06GUaWKT
-      gU3JqqoKjk6DiJN0eKlPItZq3ZD3m0YFWIx80z4nbQhvCuMGJMqBn0AHJIVIQ1IL8l1in64zqktDvutw
-      /oFqkgjo6c64kkM6+dHP8cPdgAKMU2QMcwH99gtyHksE9ET/dl8BxHl/Qfa+vwA9jDRUEOCi3ycH6P6Q
-      f2Rck4IA1xVZdAVZojP1KpynxDMWDcT2UN4+PX7fMeTEl6gsyHWJdVpvkvVTXmxoPgO0nfI/8vE7A/QE
-      ZKFsFm1Tjo2yK9sJABxtw6EG9eP3nANh201ZZHL8vm9IyCW/p2wboX/Vfd3miX1qA7E9lGHh8fumYdF1
-      r7JajcI3WT1e5qGQN2+6vZafUkGZ9cINQBTVC5KXQOtF+axtVvtspXkpulWXr5TqBKJd+/6V2o0yKdtG
-      qzMXXp250KvD0vKV2N+3OdyYZEW2I+zAhvFwBFUCY6O4DiASJ2XgVKGPhBwQcXJ//+DvTvLdvsjXOX1A
-      hDuwSLTBiksi1gNfe0C85Jv3BPmuIhUNqaNnYb6v2qtZOuIqLxAecLOKsW8YisIbjA+ZhqLyCg3k8COR
-      RqonBPTwO/aoAoxTZAxzkQGuC3KiOiPV0x+jf3t4pNp9iTJSPSGgh5GG7kh1QV1CbiCgh3FN7ki1+zO5
-      AoPqrpiRKmawo9DGEgtvLLFQi4SPCxlObU/2SOs8Yw4vkn5R3ekMEwNBilAc3s/xBXYM0php4Y6ZFu3u
-      ROpVGYrlBNmufZZ9by+1SUmpaYG2U3zP9xSV+r5jaMY/UTp+3zVQnoz0hGGZzpezT7PryXL6cH87u55N
-      aadUYHw4AuGOBOmwnfAkDMEN/5fJNfkVfAsCXKQENiHARfmxBuOYSPuf9IRjoex5cgIcx5yywWNPOBba
-      bikGYnju7z4lf05uv5JOYbUpx6b3CMgELf9dEHEWVbdnJkt8oh17u5avyMc/43cwwze/TW5mi2XycE8+
-      CwdicTOhEHokbqUUAh81vd8elvfJx6+fPk3n8hv3t8SkAPGgn3TpEI3Z06IYfyQZgGJe0gyXR2JWfjKH
-      UljPGcumlWc+0pid0otyQczJLg6BkqC3QVGPptkpYRqwKLSd3yDWM3/5upz+RX6cBbCImTT8cEHEqTZv
-      IW1tCNMhO+2JGowj/kMZd/0GH47A/w2mwIshO4rfZAtPfbAHwaibUWpMFPUedCcnWamfJ5gBLIcXabGc
-      LGfXkQUVloyIxclyxBKOxi/EmGZUvOjfFyzZy8/z6eRmdpOsD3VNebQA47hfb0ndHbrHDWI6wpHKwy6r
-      83VMoE4RjrOv1ERIHROnU3hx1qv1+cWV2sulft1T88WGMXdWRrg72HdvV+rjc67dwTH/VZx/8Pqj7Kj7
-      KZX/Sy7eUbVHzje2PRHVt9bHttN70YDBj9LUEWliwQNu9U/CbDyu8OJsq/q7vCEadYhz/lhWdZbs0s1z
-      8pLvs6rUn6pN/dQKdcr8K0fuX5s6eJCXfSbqeR/XO5UwKbnF6kHMyauXbHjAzSoLkAKLwyvPNjzgjvkN
-      4fLcfYnVJbVYzKzHqd+zV577SGN22fSN35IMQDEvZbbfBX2nOvjite0/tcfUcfswAVMwanfe3FuEdVXB
-      uO2Fxge1PGBEXrVnkJiVfOIngoN+XaV3m43lVckI4RjAKDr1KDuoQyxqVmvuIrLYVYBxmid9spP8LuFh
-      A4z7/qdUrXSlj5t70HOqNYip2BGFHeXb2o4bub934jyjrlbFq6C8yw2gvlcfTrXN1aGoeVokqwNlOXTA
-      4UUq8lWd1q+cfDNRz7vT08scrUH61mxHeMPUgjyXqlF4tZ1B+tbDLuHM7Zw4z1jFjICq8AioKtfUykwh
-      nmdfFa/n799d8vo/Do3bGaXJYnHzgfa4EqR9uxx3CHl7r6qfrEt3cM9fbxj1TgshLrX3TJPvi+yKckpW
-      QOHHybbtBrtySJCor+vNCEnL6odEeMy8XHOjSNTzqvki9apOTO8MdICR3qbnKwg9X/F2PV9B6fmKN+r5
-      itE9X8Hu+YpAz1cfQ7eJuXqDBu2R/UYxpt8o4vqNYqjfyOs+YT2n7u9Jvk3S5zQv0lWR8dSWwovTFOJc
-      1tDUOvKIGb7lPLmZf/ydtqe8TQG2487LZOERBJykNsyEAJd6u4qw1NTGDN9Teq165sSJHYvqbTfTxXGq
-      6v1Yl8nYpmy9ek/ttrmcZ2QKEd8mu1APEFhSh/XM7yPM7wPmkp4/R8Y2lczrK9FrU3UdYYrOQEBPcijX
-      TxnlkBkQ9t2V7HDs0zpvyJfak4b1c6IjjXZ13/cNyf6wIiWgw9nGarc/yO4N0ddTmE3NLzwR8gSCUTft
-      nBMQttyUJVfd1y3+tIM/LRlNDPbJUpTusiarBWHLOVTgxGjeJY8kpwJ8B/U3t4jv2VMte8Dxg/yLJAJ4
-      6vyZ88OOHGAk37Qm5vt+UE0/XIc6FOLX385/Sy7e/XJFs1mo5T1uyd6XO4LZhy03YUFg+22bJu6naiCW
-      p100zPp9Lmp5Bf1eEtC9JOj3gYDuAz3s0W8s0UwdZLsIpzJ3X7d42oLKE2A6dKoLymk+JmOYZvPp9fJ+
-      /m2xnFPPEIVY3Dx+GOGTuJVyE/mo6V083E6+Lad/LYlpYHOwkfLbTQq2kX6zhVm+bqF8cjf5MqX+Zo/F
-      zaTf7pC4lZYGLgp6mUmA/nrWD0d+M+/nYr9Uz5HtKQ81QdhwLybJYkasPQzGN3VtJ1XWYb6PkoA94nt0
-      m0c1ach2tUMY9Wpq2hxqktFBbe+milH7tGdXnxCVCvE8z1mdb1+JphZyXLJxvPlMEmnCtlBLrl9qWYMm
-      h0OMvGETanCjkAZOJwKwkH+51987/nVP9uwhyw/677L7jae/UgdQLgg5iUMohwOMP8iuH56F+kjEwUAf
-      eRkQxNrmiIEZSCN2mXuMWxrAEf9hVeRrtv5E23ZiW+e1c+whIcCCZl6qejDoZqWoy9pmwajbBFi3CUat
-      JMBaSfDuVIHdqdRm3W/TSYPi7vu2gTgsPhG2hd6xAHoVjOG1CfWu6TVvVtrlcGOyzfeCq9Ww5Wb05G0K
-      tlXEM3YgFjKrVozuVBRmS2qeL6lRo2AawV9MHBl5IOz8SXnn2QMhJ6EVsiDIRRp1ORjkE6xSI5BS01Tc
-      sn0kXStxnGVBgItWJTqY66NfGHRV6m/JS948JaVaXKgXcxVZ+t1s3zkvA/Hs/tX9nVEj/u2VNE6y+2me
-      /P6pO49T9qiexp/o5pOetcxFs7+4+IVndmjEfvkhxn6iQfvfUfa/Mfv8/utDQlhybDKAidCJMBnARGuU
-      DQhwtYP4dn6gqslWG8f8VU3Y7RhAYW+7Ndi2SB856p5G7Otqm66ZaXKCMfehfs5UCeTJj3TQTpnXRXDE
-      v8keOSWwRxEvu5igpaS9rQnbo/skYFVzEavXmGT2DEgUfjmxaMCuU4z05BhAAa+Iui/FwH2pPudXVhaN
-      2PUeAOrlGXXwszp+S3YPdqxIoMmK+sf0WzfPThu7OSDiJI0ybc4zygzPZVHSYzCRrevxm8ShAj8GqX3s
-      CM9CbBuPiOfhTOMDaNDLyXaPByKoJrmuyMnZg7CTMV+H4IifPGcH05Bd34fUe9ljQXNWrnV1JRjmEwub
-      aRN7PolZyRPxCO75c5FU+/THgXoLnjjPKPPzgvA6kk15tuOUOavphgVoDP7tEnxu0H2HNK1yJCALuycD
-      8mAE8tDMBj1nO03PvmgXR/z0Bx8IjvnZ5SPwBKT7BrcX5rGgmVuXimBdKiLqUhGsSwW7LhWBulT3JhnN
-      7IkDjfxS4dCwndvE2vCAO0m36kOZ13KokJcpaU50nM+7AtpDIwuyXF+my8/3N+22EHlWbJLmdU+pYEDe
-      itAunyIctmwygEm/BUbt97oo5CXNfJ0YyETYvduCANdmVZBVkoFMB/rvc0cc9BWDFgS49MxUzO0T0oyO
-      R5xyGFIBcXM1LG7IMVoM8okkVW9qq20EGnpps3HYL4fwutPAkR9ZwLw70Eu0ZAATrU8IrA09/bVaNxd6
-      /oLsO5GAVf/9Yr1aka0nErXKuEyrJAGreJv7UIy9D8Xb3YeCch+2fbLdvs6EyDZvEhvXIfGbin/jOrwV
-      oevi55uLkrCHvgeCTtHIzzYMZwtaTn1a2SEvmryrJSjlzIcN983F5eX5b6oPtU/z8ROmNob6jtN5499Z
-      RAV+DNLzZYPxTcTnrxZl2mYPk/nyG/k1CQ9EnOPfE3AwxEdpDRzOMN79Prsj/t4e8TyqsLYPuIlzAjAO
-      +ucx9jnu1qd0HO+0rHyUHwliBEjhxaHk24nwLHX2KKsaddJmUegaucgaahaCDi+SiMtTMZSnIiZPBZan
-      83mymPw51ftzE8u3j9petaVPVtdVTZtx8MiQdcvXbm1vOwbUH1OcBgb5xKssODuu1qRte/szaAezuRxu
-      TEquMyltq94LuP1IUJwm5xgP5Zr98z3Ydut5fWpWnSDElRTqTxyhJkNW8o0F4L6/zH7239LbG1JD+AY7
-      ivwjOwtd1jGrluXj7J5T5lwWMKv/4JoNFjDPJ3c3bLUJA269S0vFttu47ddHE5JvmZ7CbOSbxkGDXvJt
-      A/FABH02Mi8xejTo5SWLww9H4CUQJHFiVXs1SN2l9XeSvcccX62WluiQpGJtcrgxWa+4UokGvNs927vd
-      O94Dp8QdwLJWZ6moSnbFDOCuf1c9q1adsCWby4HGbms9rtjEXb9o1MEJDLMB2k6RctKgpxybbG2pt9OR
-      MUx/PiST6eRGn8uZEk4T8kDESTzZDGIRM2nE4oKIU3Vhxp8EAKCIl7J3oAcGnO3S/k1eZ2vKzu9DHiQi
-      ZVzucIix2me8i1ZgwJk8ps0TYSUtwiMRREZ468gFA85ErNOmYV62KUBiNOkj6eUmgEXMlB2MPRBwqkfe
-      tD2KABTwqre0ZMVfP3FqOhNG3NwUNljA3L66w0wPE7bdH9ULV8vqD8JSCIuybdezh8/Tuc5UfTQf7dUh
-      TIDGWOd74g3uwbib3mb5NG6nrAXwUdzb1AXXK1HU2+31SekTYgI0Bm3FE8DiZmIvwUFRr37Uv9/Txku4
-      Ao1D7Tk4KO59ZlQoEI9G4NXhoACNsas23NxVKOol9nRsErfmG64136DWmnJiPcSiZhFfxsWYMq6+FFMD
-      nPhghOjyaEuCsdRWtPwK0zCAUaLa14G2lZsPePrH1DThWiYqRwdyklmzoLUK797373t6twfq6+i/fcrL
-      tCDso+WTkHVGbbBOFGZjXWIHQs6vpNNuXM423mRrmeMfU5F9+IViNDnQqO5ShlBhkE/nGN2nMchHzeWe
-      gmz0HDE5yLi5JdcLFug5VQ+Wc8M4KOhlJOYRQ328ywTvmu4zVib1oOPMHzNB+9GagCz0st1jqO+v+09M
-      pSRRKzVXLBKykovOicJsrEuEy43+aEFZxWZRmI2Z3ycU8/LS8khiVsZt47CQmWvFjX/S1gg6HG5k5pYB
-      425ejvUsbuamr0nb9mnJatcNDPKRU9fAIB81RXsKstFT0eQgI6Ndt0DPyW3XHRT0MhITbteND3iXCdbP
-      3WesTMLa9c8Pf0zbeWfqw0SbxKw505lDRs4zTwtEnIz5Y5dFzNnPfVU3LHGLIt7vmy1LKjnEyH3SAgqQ
-      GNSnhxaIOKnP9iwQdTb6Pct1vs+zsmHqLUcwksjKDW2SABSMiNE+N1avL7C2qKNpkeuhPnu0QMD5x80n
-      TjXTYpBv+oXl0xjo+8auYQwWMxOfTlkg4qSexgjCiJv6fMQCEef3bMdSSg4xct5pR3gsAv29dhhH/Ky7
-      7Ajazi83EU+JPRh0M+6PL4E1R8fPiPeGgaE+Yn/OJmGrPteYI9Ug6OwOLWZIOxK0Up/NfsHWb33hrbL6
-      gq2x6j7YbRi23QZ2Vc+c36ow0Ed8QvkFWYnV/Z38DNHkQCPrmZ7LwmZejYHWFaTtLWzM87HrtEB9xklF
-      OPXUK2DtvhwMpQ17bsZvBn8tIzf8nHj4OE0E6WRbm3Jsf1wvri5ke/aNZDtRrm367UJ/SLMdKd/GWv1j
-      gYhzQ2tBTQ4xUmt8C0Sc7d53xI6PT4fstUiTKs32SZGusoIfx/bgEfUXd4/bc2IThDkGIulLiozUOQYi
-      MdZFYI6hSEIkIi0a4mrMkCcQ8XRKWEwymhIkFrHVNzncSBydOijiFW9034jR943eqWzd7jqn1hxyw1mS
-      EbHkALXfLiM6qGULRFdJImst9XXSFsYDnnER5Wgx+7l/i5itaSBqTE0oRtWE4g1qQjGqJhRvUBOKUTWh
-      MGqwLrUjf5llIkR9g+zzdePjxzQDuG5E/LcKPBwxuv0Rw+1PKgTxUb6Bob7kZjFhOhWKe9sNDrnqlsbt
-      c/5Vz8GrXqUi4zTEHQcZOc0C0gZQdkI0GNjE2VcWxiG/mhmLCWDzQIRNRh9ZGhxuJM9feTDoVtvOM6wK
-      Q33cSz2xuFkvfs5oj68gHojQvYhCNnccbuQlhwkDbtZYGRknkw6HMyHERThn2OVQI6NGPYKYk9kGGCxm
-      nnOvdo5d7TkzTc/RND3npuk5nqbnEWl6HkzTc26anofStCmEus/UAiDabp5BCxwtqdMX7pM+zBGKxHri
-      hyiAOIzOCNgPoZ+I4JGAte2Mk5Uthvp4FbnBAuZdLvt95WNMp8RXAHE4c0PwvJCa2Ikty4AjFIlfln0F
-      EOc4tUK2H8GAk1dmLBqy671f2oN06XIDxt1tznDlLY3bdXZw5RoG3ILbqgm8VRMRrZoItmqC26oJvFUT
-      b9KqiZGtmt5bmPhEzgIhJ2cWAZlD0ANq1v13IkHr34xf7D3N1H9mpR6ScsQTHmwM8D2Tl/wbGOrj5YfB
-      4uY6W6sloVx5hw/6o36B6bAjsd5dQd5a4byvAr+pcvwrcSGSgfk++pJy7G0X5jsk6NsjvPdGsDdG+r8T
-      U88CISc9BfE3T9Tmt+2OJ0la5CmpO+GyvnlDfpOvpxyb2ostzURyfnGVrFfrRDylupUiyTHJyFhJvtvL
-      vkdO3QdslDB0DetdsioOWVNVtNdbcMvYaMnV28RLrkIRmzp52qU6XS4uP/Aj2p5AxMf1jh1FsmGzHHKU
-      G721UkyM3jIQTUQUxo4fiCBL6vlFVAxtGBHlfXSU91iU3y74ud6yiFkdkB5dI7mSkbGia6SQMHQNb3DH
-      Ap5ARG7edWzYHHnHepaBaCIis8J37PEb/DvWMoyI8j46CnTHrp9S+b+Ld8m+Kl7P37+7JEfxDECUjbyS
-      bJO9j7t9QcvYaFE38KARuIryUBT832rRgP1nfMb9HMy5Uz+K5j5hiK+pWb6mhn0ZYZ9oG4N95AoQ7a20
-      H1Rb1vVJDPDJBpKTHy2G+Bj50WKwj5MfLQb7OPkB9yPaDzj50WK+r2vVqb4OQ3z0/Ogw2MfIjw6DfYz8
-      QPoG7QeM/Ogw27cq0u/ZxYrYS+op28Z4eQ18a001HcQS0iG+h5iTHQJ4aLuqdQjoec8QvYdNnGQ6coiR
-      k2AdBxqZl+hfoTokWjXxFNmRsU3qKXI7N7R6JR1CDrABM+05tIP63nbmiXfFJhsw06/YQHFvtfoX1ytR
-      2/uUCl2dPaX15iWtSSnhso55/z3jdmhcFjEzmgKXBcxR3VrYAER5+r7ZMkbULguYf7anNsYE8BV2nF1a
-      yz8XXbFK0uKxqvPmiZQTmAOOxFyCAOCIn7XwwKcd+4a0GaT8ustf0vhLj9cjOKJEM7ZpL39pFpXfsAGK
-      wsxrDwbdrHx2Wdtcry+SX95RG+ae8m0MFeD5heZwyh613PhlRs8dbPXGWN0+LutavV5w2G7zn1Q1KvJi
-      Xlz8QpRLwrfQqk2olpR/e39FvRZJeJZL2vxeS0CWhP6rOsq2qaknNQ+lF8nvUlJhdVnY3NUT6iF6veHo
-      LQEco/3s+E1x2KuNsTJWNESFxdWHTjHe/IINRpS/ltO7m+mN3nDl62LyO/E8VxgP+gkP0CE46KasZATp
-      3v5p9rAg7eV9AgBHQtgkw4Iclz50bF0dSsJZPx7YO3+f3k3nk9tEnV29IGW8T2LW8dntcpiRkMkeCDsp
-      bym5HGIk7IDgcoiRmz2B3GlfLKjUgVV3hEFtQBGK85wWh4gYGkf8vEKGljFuEQuUML08leXUJGIVp8Qv
-      uflnK0Jx+PknAvm3+PpxOZ/yirfJ4mZ64ehJ3MooIgbaez//cTN6v3D1XZtUm3Om5YYi6BDP09TpuiGK
-      NGOYvkyuRxvkd22Ss/+ay0FGwt5rFoS4CAv2XA4wUoq9BQEuyuJTCwJchOJtMoCJtEOYTTk20mLOnnAs
-      M2oqzfwUIi7cNBnHRFuuaSCOh7Ly/AQYjvlioV4ITsffeSfCsWQl1aIJx3LcvJMy8eKBjpM/dYfgjp87
-      YQTCrrsqXt/Lm/U5G7+LsweCzt2hYAgl1dtmi8VX+dXkZrZYJg/3s7slqV5D8KB//D0MwkE3oe6D6d7+
-      5Wb0dI78qsXRqrsTYDsold3x+7ZhWael2Fb1jqI5QbaLVtn1hGm5HI9fWhw1PS/99Lwkpuell56XnPS8
-      hNPzkpyel356Tpef728oLwf1hGc5lHSPZnqTHi5c398tlvOJvJkWyfopG3/sBUwH7JRaCoQD7vEFBUAD
-      XkLtBLGGWX7yiZYEJ8K16F3oaEeJeyDobGrCjKfLucaiGn+kQE9AlmSVV3STolwbJTuPgOGYLhfXk4dp
-      snj4Q3bqSJnpo6iXUJZdEHVSfrhHwtZZsvrwi+qUEqZtMT4UoX33lR+h5bEI3EycBfJwpu8K2bskdEsx
-      HovAKyQztIzMuEVkFiohIjIdxGA6UF5T9knMSnvlFmIN8/1ydj2VX6WVNYuCbIQSYDCQiZLzJtS77j/+
-      d7JeiQvCmioDcTy0SSkDcTw7mmPn8qQN+nvCtmxov2Tj/gr5HxtVVPONWpUhKC4HRb2r1xh1R9t2/QyB
-      ch61Bdku2tHBPeFYSmrhbAnbIv9wsV6tKJoO8T1FSdUUpW8hrDY0EN8jyFcjnKuRWmoSd4jvaX42VI9E
-      bI8g57gAclxqqZoO8T3EvOoQw/MwvVNfUm9mp0XRL9MSyboqRw8GBzR+vNUhL9T+d+2Ox4Iax8F9v66+
-      RUb1dhjiI9S7Ngb7alLr7ZOAVaZ1/kg2agqw7Q+yMtanc5GVPep7Ob8a/r2PuybfkV0thdlkGf4Xz6hI
-      1LrJt1umVqG+9ykVT+8vqMqW8m15+v5ine6TB6rwBAJO9cBEb3RZka096nvbkbiqAWQFsKs2h4JegUAO
-      P9JO1mXVmupuKcxGesoHoIA3223ot2hL+bayYlYjJ9B3yk4sJyE7zPeJpl6nIqN0xz0StDLSsaVAW7FO
-      G4ZOYYhv/JNwBwN9JT8Ry1AqlrxkLLF0LAlbqTuY72uqonoZv/rOwQzf8vN0Tl18ZkGQi9Q2WhRkI1Q0
-      BgOZCON5CzJc+6yEu4ijxagBj9K+EMYO0eG4v13/y/Z3uO9/llEJc/EOhvqS8rBjOhXaex+mX5LJ4u5c
-      L0wda7QgxEWZmPdAwPkiS0hGFmoKs7Eu8UTa1r8u3/2WzO4+3ZMT0iZDVur1+jRmZyUHgNv+1WuTCdaV
-      26Rtlf+ZrOU9t0rHP490Odf4XfbIthXN1jKOqUrUYdfjWyULsl1qnl+9OXA9e5D1sE5oihXAbf++lh1R
-      yt6WFmS7qGXeL+k6r28+03bL9UDIuZg8tC+W/TH+SQNMw/bk4etHwsazAAp7uUlxJAHr9DoiKUwYdHMT
-      4kQCVnVe4q9ko6YQ2xXLdoXZ5Ndnf+pXV6g3KOaAIvESFk9VfikIloF51L02H7jX1Od6VR5XfoRhNzeV
-      56H7WLWRZKOCEFcy+foXy6dAzHk9v+U5JYg559N/8pwSBJzE/gPcczj+ld/OmDDmjroHPAMehVtebRz3
-      xyRRoA1Sn0e1Q64AjRGTQKE2SX3Oa5dOZMB6xbZehayR7RTiwSLyEz6c6nGlZrDMzKPv3fmIezeqHXMF
-      eIyYXJgP1Q+sdu0IBpys9s2EQ25OO2fCITenvTNh202e7ADmOdpBOaeps0nQyr1RABzxM4qvyyJmdoLA
-      rVr7IbdJ82nYzk4OpCVrPyQ3YwaG+a54vivUF5OwjmBEDMoR0EEJGovfFKMSMBazwARKS0xGBPNgHlef
-      zIfqE26T69OInZ3a82BtRW1mewqzURtYm0StxKbVJlErsVG1yZA1uZv+D9+saMhOHKQis+anP0e03fg4
-      1fg87p4bGKlaX2LfHaGxqvWNqIQKtesxw1XYgEeJSqZgO88asjpoyHvF914FvbEJP6L9B77G6wMgomDM
-      2L7AqHG58dWIAjZQumIzajCP5vH11XxMfRXXVwiPz63vROXGfLBW5PUd4DG6/RmvD4GP0p3PWX0JfJzu
-      fM7qUwyM1K3PeX0L12BEkbf3+UXy8HGqVpuMNluUZ6O9wGJBnouy1MlAPI96Yv1d1plpuUnWWT1+MQ7G
-      exH01g5Eq2Y8U3dSIGEDRQ+0nZcyq/64+XSRULbu8cCAM1l8npyzxZp27ftVdqFe0lTLe0mrYREc9Gdl
-      lN/Ebf+vyepQbopM1RikomaBiFOVv3ybr+X9wnObAjcG9Yb7FbjfftW3C/2nHynIpmoznvFIYlZ+ckIG
-      KEpchCG7Ot06LoJrcKNQ3nXtCdeiVvaoM9spr+f5JGolnTMJsZi5u8uzDU9+wnH/c1ZUe76/wzG/yguu
-      vGXD5km5mcb9BN9jR3QGIOQ6CuLDEWjNgU+H7YR10gju+ruWjmbtINfVFViaq4Nc13E3rdNNwNnFfYTK
-      jdvus/UGUQMiL6bqH6p3iYkRjhjoEzyfsH33t7Prb/Rbx8ZAH+FGMSHQRbktLMq1/fPr5Jb5ay0U9VJ/
-      tQGiTvKvN0nXyt7/CMGDfmpqoLsgAR+TUwXfCan7/Mvk4UGR9Ms2SMzKSWsTRb3ciw1dKz1tDdKwzu//
-      ksk+nS/b5knvub6Y3d/REiNoGRONkEQBx5hIlIQLSdxYXSrTk80AESc1cU4Y4iMnQc/1xvnk7ibp3iAa
-      azMZxyT/kqWvJFGLOB7CTNjx+45Bv2JCcmgCsrRHm6gTHdTuaepgJMLwaUDjxCNuX2Ayjil7pKWg/L5r
-      KNNVkSXbqv6eHEqRbrNkddhuM8pGcYMiJ+Y2l1+kbLFuU46tHViXm2SXNU8VLT0c1jHr19JVWJLzRDm2
-      fTX+sL8T4DpEdthUjGJvgo5TZBkt0RTgOfh5IIJ5IJq0OdB+a4sYnuvRu8bKr1qcvjjCWMZADI/5wIqy
-      X5QH2s7j0ymq0uQs4/8m5+8uflEbMKhd7ZP0+ecFwQvQlj15WCySh8l88oXWUwZQ1Du+9fVA1ElogX3S
-      tqoXjfff1+JcDm8zwiFcEGubV/n4Jy3H7zuGIi/VaUbJ+PecHcz26c1iZT24J11XT0E2yp1oQraLOIdj
-      IK5nmx6KhlrneaRtJc4KGYjt2RbpIynpNeA4iLepf2+a+8cTtvgH0ICXWsg82HU375J13SS09UgACng3
-      ZN0Gsuz253SRhEDXD47rB+TKyKIMsGzTdVPV9ITvOMCY/9jtyToFAS5iJXRkAFNJ9pSAhf7DoF/1g2z5
-      4VnkXUobNdkY6JNtaCJbGGrVYbO2ORdJtU9/HEiF9QTZrojzcREc8ZOPwYBp207s2nj9GZXA9Navp2xb
-      d5yi7unohRbJ/WT6kOwet6T6KaAZiqf6bvHhjpahaPqpXGSs1jEq0sUbRLrAI5VVmXEjKBY2t124NygN
-      oGg4Jj+PfMvIaBdvEs3LKebJziAMulk1FH5Oj/6UcszfCfAc+rIZvX4Hhb2M/rqDwl7dN62rHXGyBzXg
-      UZoqLkZThSI01BNaQNhxt+WFk6UWCVo5GWqRoDUiOyEBGoOVmT5u+wV/RCRCIyLB7O0LtLcvGD10AfbQ
-      Ba8/K7D+LGVt1/H7viHZC0FuAy0QcNbpC1knGdf0d0az/O20+Yc95eSknrAttJMdegKyRHQLQQEYg5Oj
-      Dgp6ibnaU72NstrYXlus/kU7IqwnHAvlkLAT4DjIx4TZlGOjHRRmIJbn4uIXgkJ+26XJ6XtiPBMxjY+I
-      5yGnTA/ZrssPFMnlB5emp82R8UzUtOkQz8MpgxaHGz8W1fq74Hpb2rPT8/IEWa73V5RyLr/t0uS8PDGe
-      iZiXR8TzkNOmhyzX5fkFQSK/7dIJ7U7pCMhCTmWLA43E1DYx0EdOdRv0nJxfDP9axi8FfyWnjrA4z8hK
-      My+9Zg+fJ4vPCaHFOhGG5WHyx/SCfE63g4E+wkSmTXm207OhnXgkKk3U86o9VzPVXSNrDdKwkpZguauv
-      2n9Tt7W2qd62nH9dLJPl/R/Tu+T6dja9W+pJPcIoDDcEo6yyx7xMciEOabnOIoLZohEx62yT7faU8zlH
-      qIJx5d9z8fQWP9YxjYn6Jj/Xc4UjE2oIBA/6CTUGTAftahZA1HXkPWBY4GjqvOzpPOZusw3BKNwcMfCg
-      XxXImACaD0Zg5nlPB+2qYGe7iACtYEQMytA+KAnGUqVvlzWpmsqKLF6uajBuxL3jW+Bokm3/g1uuLQEc
-      oz379jSbfUwCTjREBcfNfu6zOt9lZZM8n3OiWYLhGLKTslvFxtGSMbGeq329jY+mNXA8bpHAS4K55Ihj
-      Nnk4ArNys2q1r4vpvD0AlpQEDgb6xo+PLAh0EX6qTRm25acrtUxk9M4PJ8Bx7A9EhwJ6x18Xl5fno3d4
-      ab/t0qpM7NO8plmOlGfrngbpZ01ddUM0AwYjyuW73/58r97PUZsFtI//KYdbYjwYQe3DEhPB4sEIhHdY
-      bAqzJWmRp4LnbFnUXOTjX9wHUNTLTd3BlG0/TcT3GLnEQT/xLRyfBK2bi5xhlBRoo9TCDgb6ZAXG0EkK
-      s1E2WfNJ0JpfcIySAm3csomXy7ZQ8X73iQXNpOUuLocbk+2eK5Uo6H3WaxZLhrYjPWt3cp5sMUS2psw0
-      YLwXQVYI54zCdcQgn3rVqNyktXrjpclKNS0m6HrIAkaTaXfIGH7N4cZkVVUFV6vhAXdCvgM9PhCBfs9Y
-      bMB8WD+lNdutac+uKwBGtX7iPGNfaFgViIt7flVX01u1jgJtvDvcIGFrQ3ln1QNBJ/v+sOGAm55hFuuZ
-      2wWVjJ5eD3rOLtU5xdZEAW+TrJufZKWmQBuntT9xvlEXDNbP7knbmkxuf7+fU15UtCnIRjny1qZA2+bA
-      sW0OsI2aeAYG+ij7/jgY6ONkBJYPhHkJmwJtgvdLBfZL9STshmeUoOtcLuezj1+XU9kyHUpiItosbibt
-      bwrCA+5k9ZrczW6iQnSOEZHuP/53dCTpGBGp+dlER5IONBK5jjBJ1EqvKywU9bZvLBIm3jE+HKFa/Uu2
-      djExWkM4CuWwV4xHI+Tcy8/xqybXiiaJWmWldB6Tpyc+HCEqTw2DE0XvUzT5+he9yFskZiVmo8FhRmom
-      miDmJI9WHNT1zu4+MdLzSEE2ajq2DGQip18Hua75LX1nTp/ErNTf23OYkfy7DRBwfpkuP9/f8H69weJm
-      zvX2KOBNN5t3SZ09V9+zDdlswrD7XI3fqbNaHgy71accreIAY/uKojjkTbYia00YchNHQB0DmDZZkalX
-      8xg/vUchb77d0o0SAl2ULZgdDPId6Knn9+PUX1k3JnJH6t6K7IeqDbPJThMOuEVW52nBtrc45ufNCUM8
-      FqFIRUNb4IvxWIRSXkRMhJ7HIqi3ydLmUDMDnHDYn8ynf97/Mb3hyI8sYuZUER2HGzkDUh8P+6nDUB8P
-      +9d13uRr3m3lOgKR6PMOHh2wE2e8XRYx6zWKNUvcoog3riIYrAf0dh300ZZHI/a4SmawjunrCOpTW9iA
-      RCGupodYwMzokoO98V3arJ/IKk0BNk43Ge4fMwaBRwqzEZ93WyDg1KP4iBvM4bEIETeBw2MR+kKcFo8V
-      L4rtGI5EfmSNSuBYzE34AgokTlv9knatxXgkAr+OFQN1rIionUSwdqJsamBBiIv6ONACIWfFGDsoCHDR
-      tidwMMBH26jAwRzfabdz8pNFi8SsEU9LEMeISNRuKuJAI1FHvRaJWskjYGz/fedDfUAVp2MNK4JxyJWQ
-      jwf9jEl1SIDG4N4CoTuA2uNBzh9wPhPxuSrG5KqIy1UxlKsiNlcFlqu82W5spps1J43MR9/e3//x9UHV
-      MuQV2y6LmuXfHrOa3kcGDWiUrm/CmAxDHGgkcaAXEo+G7eumZl274mAjZed/l0OM1HJscLDxKRWy25fX
-      HOuRhc2UozpdDjZS77seg33i6dBsqpeSIz2yjlmvIp7eLeezKbkn5bCY+VtEZwqTjIlF7U5hkjGxqMtP
-      MAkei9p5s1HcS75DHRY3szpWAB+OwGiEQQMeJWfbQ/cEtW6wUdwrMvbliqwJeqNyUwzmpojOTRHMzdnd
-      cjq/m9yyMtSAIbd+CFw29SvdfEKDXnbl6RoGo7CqTdcwGIVVYboGKAr1wfgRglzH59u8jDVp0E5/qG1w
-      oJHTRiCtQ5vO9EdOLgy5eW0O1tq0ixWJD5ksErFyM/6EYl69RT/7jnYNg1FYd7RrwKI0zGe4kGAoBvuH
-      NOiTXP0VNS6gixWF2ZKq2PCMioSsnEYLbqtYPQ+kz1GVWZGXjJu5AyEnffDfY6iPcBSPT4as1GdvLgy5
-      WX04v/cmS/v0un03Wr1N18g6iTZpAwngGLomVX/g+E8w6qavAXdY2JxvfnLnaEADHKXOmjrPnrPIUIBm
-      IB79CThogKO0T3kYHQSAdyI8qPPoyX2EEwXZqHXeEXJd7VGzd/c3nGrKo13714+8X95zsJG4CYKBob53
-      7fb2TG1Hh+zkwzUCCjhOzkqUHEkTcgk7YbBP8PJMYHkmovJM4Hk2f7hfTKm7wpgcYmTsVuKyiJn8RqUJ
-      Bpz0tRIeHbKLOL0I+/UjjQ1X39Jhe9T1nwSBGPS2yKMD9ojECaZMUx8E/6o1jdjpVciJc4xqVyjec0mL
-      xKzEmtjgMCO1NjZBwKlfHUmbpiZLT2TIyhk/Q4KhGNTxMyQYikGd2IMEcAzu6wU+PugnL5uFFUCc9rUe
-      xrFkuAGI0k09skqswUJm+qRlj0E+YgvfMYDplPSszLNowM6q+JA6L+ItEB+H/edJtkvzguPuUNjLK1JH
-      MODkVoEOPxCBUwE6fCgCvQPi44g/ou6zccQvB0ucyqhHES//TQTQgEVp50PoHXBIgMTgrCd2WMDM6PqA
-      vR5Ohwfu69DnNU4UZqNOvpog6tzumc4t1HoI/j0gQveAiC2dYrh0iojSKYKlk7za/QghLvJqdxMEnIwV
-      5T3m+fS7j/x3zCEBHoP8NqXDImbm29w+jvnJ/bUThxgZPaseRJwxbyMjjlAktWHBOlXbvt1Q32YKeEIR
-      21Wnd4fdKqv58UwLHo1dmOB3f51PeR0/SDEch979gxTDcVgL3AOegYicbidgGIhCfT8Y4JEIOe/ic+yK
-      6X2hE4cYVSv5Bje5rwnEi77FXYkTazH7nV73HiHARZ5VP0Kwa8dx7QAXsXS1COChlqqOcU3L+/lUn8XG
-      eb7h0aidnrMWinp1u0HeoATgByI8pXkZFUIJBmIc6lqdjLImvkaBa8bFY2yJEDSFo9If+UGCwRg6BYid
-      e9QyEK0q8vVr0vBLuKsJxxNNVUdF0oJwDNn8qgc5xB2zMEko1nnsvXU+fG+dR5fx8xFlO/aHDP+O/t6O
-      qvAsTTBeVtdVRKq1/HAEOczbN0+xcVpLONpP+jsDoGEoimxo29WqcaFOmoF4e1l15E1XhUSFtExoVPKr
-      aTaKesl9GpNErftDva+E2q39SXY/uRfuWNBoemmKbHwFM86JD0eIaUfFcDuqX2rm1zJHPOyPqC/FYH1p
-      bCwSEaMzDETh114nPhghph4Wg/WwiK4ZxYiaUX1nW6SPEfdFywcjdHdpRIzOEIzS5LuYEAoP+8lrcAA+
-      GKGdck7Wq4goJwcaqev/qfN11t+ZkSwHGunvrK6YARQKetXMNrMOPKK4lzXI60jUWlTVd9YQvodBN3P0
-      jo7cjb3WOdWBieN+bgs5MMpshxwyb5lX3sEBN6/vcGIxM3e9PyRAY6jfxizcJo779WqjiABHfiCCHu5t
-      ooK0ioE4/fRrVKxeg8djz+8ZNGpvtzbi5kpHB+3sIbwtQGO01V/MnW0pBuOw73LTgEZhPIl24QE3r+/w
-      ONhvKKpUtUVtaeYkkS0AY/DGmdgYUw+nZAuaq4BpETV5hrqwyOfsdq6HMXdMbS6GanMRWZuLwdpcxNfm
-      YkxtLt6mNhdja3MRVZuLgdrc3JBznzZPghnDcgQi8cbO4XFzzFgzPM4UUW2dGGjrRGxbJ4bbOhHf1okx
-      bZ2IbuvEiLYubsw/NN6PGYuHx+Eipo0W4TY6dnw/PLZn7MRqgo5zOf+6IJ/j3lOgjVM/WiRoJa8p6DHU
-      R1+G6bCYmfEGncOiZvoKH4dFzfRa22FRM/0+dljQTH2n7URhNtactUc79j8njJNhjhDgIj5E+RPap0r9
-      kdoP7xjXNJ3PPn1LHibzyZf2xCbGgzBMMhirSVfEXSoRx0Ck8+SpIhZgWBGKoyq/mnETYpJQLHqBdOmQ
-      nVxVe/SQnV5xw4rBOPssq98g1lEzEI9RucOKoTj0rj+sGIoTWZqxlsX6EufRMiQIxWBM7gN8KAK5Onbg
-      kFvNNvDlih6yM14xRByDkeJq4pNiME6+j4yS70fESFKxjo6jJIOx4mqxk2Iwjm6680xExjpqBuLF1mRi
-      TE0m4msyMaYmU19SZfMNYp00Q/E4A3hMMhSL/OgeNAxGIQ82YEUoju40sga6uMaJx373LPDOmf6ozvQL
-      hIztdX0c8uvEY+tN2reT3z+C35DT5w7Qu6k9BvrIzWyPOT69uop/ZqyPg37GTJIJek4VLv1OnPboMdC3
-      Thm2dQq66H0UgwON5L5Ij4E+Yp/jCCEuct/CBGEn/VlO4AlO3P4nQ3ufdJ8zmjeLBK30JsbgXCNxk2p/
-      f2r5l9OycnIT68KAm+UEXMz3kdH3kBn7z4B7z1DfY/bfX9Y1BH1Spcccn/yvjXGuTCr/xTifBrUg0TgL
-      lBzWNVNTBEgLPX+SHpqnSo7RXzmP50BDOIqsTqjz96AhHIWRp6ABisJ84z38pns7b1Y1k23DyYMjiVg/
-      Zlvq21U2Cnnb3TiSVd6IhnHJFg752a/mDr11H7EzVHBXqPbDbhcRbjm3eShCsxLqEtLikW7vWch8yDeM
-      Mq0o38aZuEL3xdIfVGuxp+sU5dsSY9tVqtNkAfNxhYheJpTWWUr2e4ahKNSDuiDBiBhJVj5Hx1GSoVjk
-      E9JAw5go8T/paAlEO/akY7LJcACROO+54O/9Rb3tN/COH2enE3iHk4idTYI7mkTsZBLcwSR255LhHUv4
-      O5WEdijh7kyC70hy2ipvk210O3cQ6WPGkTsKLI7ecZI+9QvwQATuCd6PwdO71af8pAmlCLeTGehj8ruY
-      oR6mXmNZZCXZ2XGQkb73HLr34mPM7jGP4V1j4vZ0HNrPMWovx4F9HLl7OOL7N6oNZ9iFdhcotTt+sd3h
-      5XanpmeSdPMvmvOEOT5vhoE8qwUa4CgqP7n+Ixswkw+AcuEBN/k4KEjgxqA1pN5aB1lv5Bv685AeA33k
-      5yE95vj0ayXHNxroHW8fR/0RbtTLv2T4aqlLRfzVIWq4KVOavr2rCTrOfVqLLNnW1S5ZHbZbYi3o0a69
-      3aFHT6PTxAYIO4vsOSuOM0mbjGN3FKE46nNG3xdxwJH058Y+SpxIrmMwEn3ZJ+IYivTjkBb5NpfNcFy0
-      3gNHVLtB0WewXTjg1lehc5QdoVcMxWEty0EtQ9EOshF/o5CWKhC3vTXYd5brcCORq0qwjuTsgI3sfs09
-      dBA/b5C1lzayj3Y3b854RGeRjrVbe6IXOZOkJug425VtnJ67RSJWRs/dRiFvP2xKi8eKLrf5cITntDhk
-      MSG0wI/Bmg3E97oREXMcIjjHIbizEQKfjRDs2QgRmI1g7luP7lkftfPswI6zUXvhD+yDz90DH9//nrz3
-      PbDvPWvPe2S/+/7u2hyIA2EbRb309s5hXbORXeTBuwuH3OThu0cP2ckDeNDgRdnvq1rttXSayyXG8Hgn
-      AmvGB5nvOf6Z2pUxONdYJccjGWjGnnONeiEpvatgcI6RsV4SXCnJePcYfOP4+J4wdZssg8ON3b6eopE3
-      8yNXb0nsWGnDO0nP5HAj43kbgIf9xOduAB72E0/PA3DPzzwLziY9qx6mqT4ZL1VcHPJzLhk+acz4gFdI
-      gqeMOZ+zEiNYQvjni3mw7X5+z1lf31Oejbfa0wI9J+O5fE9hNkYx8OCQm1gIPDjk5jyjhw1oFHJBc9ne
-      nF7kye/Tu+l8cpvcTb5Mx1pdzjbOHiQ8ny4WFN0JQlzJ3TVLJznDuMqTJpO9iVW6SQ7li1or22Q72VFL
-      69Htf1ASjvVSV+Wj7IA85oIweB02AVHXRbWSo7ykPn9HjmOwQfN5hPk8aL6IMF8Eze8jzO+D5l8izL8E
-      zZcR5suQ+Yovvgp5f+N7fwt50598cfozZF7t+ebVPmiOuOZV8JrXEeZ10LzJ+eZNHjRHXPMmeM0i4ppF
-      6Jp/7nb8KlTBYfd5jPt8wB114edDVx536UPXfhFlvxiwv4+yvx+w/xJl/2XAfhllvwzbo5J9INWjEn0g
-      zaOSfCDFoxJ8IL0/xLg/hN2/xrh/DbuvYtxXYfdvMW6oB6EH2rLb3O7GtMnrbN0cV+eSY4VkQGy9o0Vc
-      RF8BxGnqdKeenZcZ2d+jgLcbcdRZc6hLstqicbto0vGTpiAccld7vroye3eZOL+4elzvRP6cyH8k30ev
-      pQDQoDfJynXy8zxC3xmQKJtszXJLDjFm65UOuSqq8UvCcAMWRX6+E4/Jz194IU74kP8qzn+F+L9vtiyx
-      5CzjxeUHbjl00aCXXg4RAxKFVg4tDjFyyyFiwKJwyiGED/mv4vxXiJ9WDi3OMibrptbtE2GVg4PZvqeX
-      ZL1aqx9Qv+4bitImfWtTv784ftrmraDqAYUXR5ZMxpV3lGfryiLDaJC+lWdEbO2eXW2iEIuBT4P2Y5Lz
-      7AZt28uKX9pcFjJHljhUAsRilDqTA4zcNMHTI6KcQDwSgVlWIN6K0FWAT3qPsA+kYx9hGrdHyYfcsqP/
-      +jz+CRXGQxG6j5Knqi4JzzcQ3opQ5on8EqOY2yDkpBd0GzScojxPNlWSbkbvD2Ygjkc14ZTV7hYEuEhl
-      yoQAV52RDl52OcAo0me6TkGO6zGTJSct8r+zjV7c1FTJ+OPqcYMXRR1PUuXrTFYZhRyXjz+REuOBCNs8
-      KzbJvqG7T6RjzZtsl6yr3Ur+hV64PNqx19lWP2BWN5ueIdEjacpphAMaLJ6qtqsy40XpYMctInNYDOZw
-      87rvFmMnqZBVX15SngmjBifKoVkz7wOL7K2rLDsku2ojqwa1NlddQE3ZkAzjjQh51c2tCdnZoZ74CtO2
-      fbtJxFN1KPS81Pgn/wBqe9VOfbK8qoWfKtm6C1B/Sjcb0i8Im+yo6kN6GvWUb1Nr2uV/U3UdZvjKJFVb
-      Bx1WstooRUMqJwBrmzeb5KWqx+89ZDKWaV3tX8mqHrJcG9mN4fxWi7OM2c+9zHeCqgUsxzZvhLzhyD/S
-      4myjejN0V5XNY7XLCLeQR4asidilRcF3t7wV4TFtnrL6kuDsCMsik6ROy8eMnKA2aDuF2tVMNxxkq4O6
-      3jor0iZ/zopX9S4AqVwCtGX/V7quVjlB2AKWo1jvWPeMxdnGTIikeUpLszDMKWpQgMSgZpdDWtZdXhR6
-      uYrsZJG67BAbMMueAulsPlTgxChzecslL/lm/CbwLmcbq0170jOjfHgsaKbmnsV5Rln5JqtUdmsu2JcM
-      KcA4qmiSq0gf9txdz+xde7vzw6AeLCI7yTwejUCt/zwWNYtsXWdNVABT4cUpxFO+VcdaM9PI45EIkQEC
-      /t2hiGncMYUXh9vf9FjQzKkvTpxnPJx/YF+rxTpmeauV70g+TdgWmdisGtLkPKOaQEh/IepaCHZdcVxX
-      gIuRCybnGVWaEmUKAT2MjquLel7yDXhkPBOnhPilo5JlptQvJ6tuZ7V6zquDkL1OmWH7SsgeByHCoMuO
-      XOp5DtZ4xmMt8756oeVaC1iOWo37eeMNF/W9XZujv0MVm6xtzjaHdSaTZk1y9hRmUwOofZFytSfc8Yv8
-      b0baGpjt61pastDkAOMxvfU/yF6Lhuy8ywWuVqzTpqGV+iNie/TEKfm6TMzxNewRisd6ZtHI8dCacbU2
-      6nk5QsD0o776megZ4jKlVPo26DrprXkPwa4rjusKcNFbc4vzjNTW8sR4JnKOHhnX9JOdpT/RPGX0cOHe
-      rdUmklMPoC37gTspcMBnBA7cgcMBHzW8kKdvX7z520q9rS+E2ntwr46nKrb6kdhoJ8L3EdYXeTJZ3J0n
-      H2fLZLFUgrFyAAW8s7vl9PfpnCztOMB4//G/p9dLsrDFDN9qpYcqaoazHL3K0aZ822EtLpJVRtV1GOBr
-      tu9Zwo4DjVcM25VtUo+a1V8Twn7LLmca9Vlu5LwwKd9GzgsLA3zkvLA50HjFsJl58ZTK/13o7QBfz9+/
-      u0yqPSFHQDpkF9n49gamDbtaQlPp9TTrQo0Ls1ItMxpdY2J8H2Gjbv7ra/Uy+M10cT2fPSxn93dj/TDt
-      2Hl15yZUd/Yffnngao8kZL2/v51O7ujOlgOM07uvX6bzyXJ6Q5b2KODtNhqY/e/0Zjkbv0cBxuMRmKls
-      0YB9Nrlkmk8kZKW1qBu0RT19cvf19pasUxDgorXOG6x17j+4Xk7Zd5cJA+4H+ffl5OMtvWSdyJCVedEO
-      D0RYTP/5dXp3PU0md9/IehMG3UumdokYlx/OmSlxIiErp0JAaoHltweGS0KA6+vd7M/pfMGuUxweirC8
-      Zv34jgONn664l3tCAe+fs8WMfx9YtGP/uvwsweU3Wal9uu8aaVIASIDF+GP6bXbDs2vU8R6a6qE9nOmP
-      8evUfdK2fpwsZtfJ9f2dTK6JrD9IqeHBtvt6Ol/OPs2uZSv9cH87u55NSXYAd/zz2+RmtlgmD/fUK3dQ
-      23vzeZ/W6U5QhEcGNiWEpXEu5xhnc9ne3c+/0W8OB3W9i4fbybfl9K8lzXnCPF+XuERdR2E20qZTAOp4
-      FxPeLWWBASc541045B6/zTfE+ubDqsjXjIQ4cp6ReO6hTWE2RpIaJGolJ2YP+s7F7HeqTSKeh1ENHSHb
-      Nb1mXNUJcl0PKkLWEE5vcDnPyLoJTQ43UsuLywbMtDLjoK6XcbOcIMRF/+nondJ/RP3R2H0yvZk9TObL
-      b9QK3eQc41/L6d3N9Eb1npKvi8nvNK9H23bOrocbdNdD95MFV+n0XWaLxVdJMNtfn7btd9Pl4nryME0W
-      D39Mrilmm8StM6505jjvlzPZgZx+IvmOkO26X36ezqnZfoJs18Mf14vx+1T1BGSh3t49BdpoN/YJ8l2/
-      Uj2/Ag7Oj/sV/m1X/MYAwMN+eiJeBVoF/bma2PlT10pqzEnW2/ign5VCvmI4DiOlPAMUhXX9yBVzrtG7
-      KjV2/UbOuhMF2f75dXLLMx5Jxzq//+ubHnC3KavbwgXxkQcqgWK1V0PXt5xjJHecoF4Tr8uE9ZdYnSWk
-      p8TrHWN944jKMFQPsqvAQO3HGZAio9E5d6Q/x0f685iR/jw80p9HjPTnwZH+nDnSn6MjffMTTjKYbMBM
-      TwQD9bzJw2KRyIHE5MuCqDVIwEqui+bIjMecPeMxD8x4zLkzHnN8xuPrQvZ0ddeZIuwp26b2n6d41Pd9
-      QzK5/f1+TvW0FGZb8HQLyLdczmcfvy6ndOWRhKxf/6L7vv4FmHQrztEdQcgpewV0n4Qg1/yWrprfwiZy
-      v9oCESfxnjU5xEi7Xw0M8LE6eDYZsi74WuhuoY69TxDiSqZ3y/k3lrFFAS+94jcwwEc4RctkYBOvhB9B
-      xMkp4R2HGBklvMVA35/3f9AWFpkcYCROnx8ZwPTnhF57SQYwcfIATn9G2lvpLtJE7wGzy8a/JGFBtksf
-      9p3s6U8aALY3Z+vk90/di8zpZvSCQQeDfZtVwfFJDPZtsyLbdcepvzbjj2AOOUKRdoeCH0LCIbf4UfPd
-      Eg65myo2fY4GOMpjXR32ifxzPv5USowPRaDs3ADTIbveXOpQj98xLaCA46grSPZ1pl6X5AQxeTgCs4Si
-      ZVMt/VW7JjClmg2Zm/UTXy1h3B2RzAYe8OuRc9xPMB1eJHkzNOpczXW1ydSbfEVaq/1oqDcxpvHiiXy3
-      L/TBs8nPZF1V9SYv04aa84gFixZZgyOWcDRmbQg6sEgRNSJgCEd5ZNZbsCQci1EDe3w4gniLXyOGfo3e
-      G4T5S1oWNYskVTW1yrnmlRnBcgQiVWVMWhkCLIbe/lDvysYL0fPhCPxy1fPhCKpIyLs2LmNAVTCuSLIf
-      h7SICNcZrCjpVv1Xt+tXWpJjgDwUoX3rm25uOcgoE+4Ylq41YNtNHVaZjGVa5Y/lQdfvuqIn+BwSsbYt
-      MEvbopY3orEOttCq63NosuTlbvKJ4jQwy9c2mrTh5IkBTNTyblCAjdX9CPY52g/L7JEslAxkkvW02qo3
-      2aXiO91p0oCdfJObGOQ7rOiywwowqW6WLv9k34lErKzcBnt9qudk3khq12CqHnUMRiLXJ7jEjqX7UWX2
-      QlEfGcv0lIonlXK6n5Hs31/9kvzcqf1+08vzi0SIl0OyqdNt8+5XQqjxUvBaunGQy/GvIyy0roE5CYCO
-      /U+NuLyMtpkkWH14wE0e8GIKK87+e/ZKbb9PjG3SPTRdLR9KlVZ1JkRGaXcQAxBF79xFvf9cNOilzr2A
-      /FAEWn7CgnAMemnHFANx9HxKVBhtGBMlPuHQ2Z/jKIPYKpsY6GuON2Bf+wuGH9IA8RitrA3azjb/Gali
-      gZZT7bZW6e6R7h2Rb2WQtyJ0OU3r+PYQ5NKdWOrxAAgO+VmdYY9FzfTNAFEBFCMvn99FxXAEYAxBOn3D
-      AyGnvQMrXW3zUATaYKSHIFe79x9d13KQkXxbWxxoJA1CeghyMaoyh0SsMVmO7I6JfEEVbH6tgarsuO28
-      mEi33dQVJZDL2uZ2Piz+Jg95AhHfJCnHGc2rUE/qhRzFJi9586TamXWWbKs6+V5WL2WSluIlq0mblhGU
-      5nW0T5H+vrj8kKTPPy9Oe0ESRkqoAolD3ekXhBE3qSq0OcQo+0FxV2wKAjHUnoVRMY4CJEbbASN1VyB6
-      yE4epwYkwVibSvaxY+K0AiTGsQxfsgKc6AH7r1F27P6KKklAKdpcXF6e/8aYiHdB30mfHHDB3qk2NHvU
-      kzayFhrrsyDIpbdIo9s0BvnUqZl0naIgmxAie0/XaczxyettyCl3hCAXPeV6DPKRU+5EQTZ6yvWY7dOz
-      d8SEOzKAiZxsPQXYqIl2ggAXOcl6qrflF2nE3oIw7dh5e+sBKOAl7iLncoCRtvObgwE+2s44Dmb61txd
-      GgEU8JJTco2m5CaqRG0GStSGnw6bUDpsmLtV+iRkpe1W6XKAkXNHbUJ31CZqt0qMxyMwUxnZrfL0OXm3
-      Sp/8/62dQY+jNhiG7/0nvXWYrqbnqpeVVqpEVr0iAs4EJQEWk2xmf31tIMBnfya8H3MbDX4eE4IdY8ML
-      Z0VbR77UOtC0SgIxLrTPykN9Vi5Pq2Rhxg2nVfrkklW408G0yrGEJK2ShVn3d6H2e8AIp1X6JGeVdAiB
-      XgBJqyQQ4xKmVYZ4rgYsrdLlWCOaVsmgjFeUVsnTjn1LWmVQEKoDSqtkUOoV50qyMHVvyJUM4I5flivJ
-      oNSL5krOGd6EPP/lco5RlivJoK4XzpV0MM8H5lpRKmSDnjFlUMcrSZvwwAUn/MWH0yb8zesfBeRY34ym
-      TbicZwQftqVUyCY4pGzKgrMNPphcysJjE/AI6gzxPIJuyM+VtP+GcyUJ5LrwXEmX84yiRsjnSrpb0PMl
-      nCvpbcXOmWCuZL9R0FiYXEnyb/yjB1uKJFfS5RyjIFfS5RyjOFeSp6ldkivpcmHjTqp0xi7yXEmepnZZ
-      rqRPhq1fpdKvjhPNlSQQdcG5kgSiLixXciI4C9q8uVzJ2f+xhs3kSj7+/YZ63hiH5MO98Z9tltz4tTxU
-      EjOjeF4PfkB9w2ItGz/J00+x7RM83fuyyLd+gkHxvJ5tn6Q3MLXIMj8D+FO/6GgtZX6GCgmO1kLm51RG
-      tP+BPZbso7dXcOYnpTgbmvnpk451a+bnooSrC8v8dDnHCA9quRGtbDgbGsuKBrKBUazsyiV03bKha1/q
-      1cUd+kJfLpksCMwUxNJZmDg8CxNvmYWJl2dh4g2zMPHiLEwsnIWJg7Mw0sxPjl0w4weBzfwcNgoyP32S
-      scJ9URyYjYrFs1HxwmxULJ2NisOzUXjmJ6WoDcn8fJT3DVjmJ6VCtp1Mt+N8aOanT3LW9SGdc4YxoZmf
-      Hsg5gcxPAnGu+Buuir/xJnhcHcj8JJvANstnfpItWHtlMz/JhnavRULDMUbRkDGUIupv28m1XPtDZ1qY
-      FFHybyxFlEEZL/5TwqaIjhuAFNE5w5tkbcZPESWbJG3GSxElWwRtxk0RnW2AUkRdjjGCiyV+iuj4XyBF
-      dM4wJsl3wB9/wbFnj7ukn/L6qEaJOz4H5b32rBF6B5T3Cp2Or7ILQ/ign2Bzn5bfBamX7oL0NibgzWoB
-      AVMHfE+hDt5TqLfct6eX79trZfcYtqF7DG/y+3dvS/fv3oRrV7fg2tVNunZ1C61dnf6umqJ8N6XNxczu
-      R9N+/7m6r+PYZfM3VW6RG3zm/7dWpd2sUl2Vu9aW/idt09UVBPhQDf+l5+v6p4A5dtmMHBsen/xndVPn
-      7jm5sspXPwJHKddm/pToRmzmOya5Oqv1iWUjQB1Veja727wjmgdDTIdGIftiixO+KDUQKDkCxAGkLfWl
-      KX29JEWr1t+0MmeIqVGmJagbcjweCOtJTut/XR2M+HTb2CfTANVATJZL/meyP1fZKclNO7ePxKrViR8c
-      Ozd/Gbam+iKy8/xUQ9W/IBUdrzjY5KtPmX6J7PffpG1RlTpJs0zVbQo8Mrvk8Gqyj2O+r+/iKOXZ6r1K
-      VJk1HzUWHxrAqf8t2V/LHDsOD8Y11WmjVXJUKXA2+CS1/tXtf666/UekBJw5L/u2OqkyUff6xZyHpsde
-      bfXRkDc7F6psu28Uj5lZoQrVa04fe35CHVHYEK6lTY5dmILNTzBDCWlVjiZUX6H1VTWfcjRZVajexpyP
-      smosGbLaUAqZ1ZIh67XccC4PMO+O5K0kSha9n9ZKIqSVRJtbSbSilUSf00qita0k+rxWEiGtJBK3kmih
-      lUTiVhIttJJoSyuJmFZSmZHGR5Kl2VH1Y/8cuCbj6ZAdGLV7YMCpVStSGi5sTC5pXSMne4D3augGioLD
-      MHK8EbgUcTDPZy/8urRp3DlHea/gk48cb7wgsY4eSJwfSfwDeSPLDJk8NmTQ9nMn09C6dKz99XBQdqbC
-      DF/tMHt1s31umtUqeVdVw7+rqpneN9UnXgK/LxxLzebP1IZugGNhBuW9dX/LSNKaw6fN0btIavAkfF1d
-      MFeT/pRU8WBD5l9KZv2lqBFO4yEQcf1KXv6I/kze0/aomi9dLhggZWjOblO1ZOYHyVlL8x1GjcqFaoJz
-      frMtsoWEfoJzfp2lbSs/6ARn/T8aqXogJ6uOCtHahMsxRsnaBAvP3Mf0RTzFxMLEbeO3Ntg5nPhtavkG
-      P4fP/ObfStXQ+2TmjGNC5o9HgHEkddvAHgtR17VGJNea0Adg/D0UpzwwEBqKEx6bvx4B6tCJrppWIR9k
-      ZIgJGCr2pV06Ka/nM6boEOpZ/96JvjSh6wo5H0xpl0a/0wfCesy1mkBlKGq7rp9+H4oTHri26ku7dHc1
-      cLiWGaYZMeo7Fgdof2x5aqigNmOLE/5m1+0AQVeeGJAk6qH4xLf2K+6usde/VWbOTKbb40cRX0FnUOqV
-      rKC7XNi4kyp3YSfQ2Bh05n1NUjtyLlb3qBNBLecWMZxbQu+zqtQA35Unhsxc2iKGrjw1NGebkpwDL7mi
-      lGcDeveJ8CxNt/4OinrIdeWYhX7DZlBixlvm34BkZIhJ3dvkdAU0PUAc5rdDH5VuwR2aY8RX5DWgMaUp
-      XR4qBDfFHf5Y7G0WZ/kB7cYMIz7bQK86fUfO5JEhpjK92NdwlLptUvuqQEDootSrkyL9kpwLjfQbM8qx
-      ZcDYcgSIo8p0bdeWzRmCfAdzzPeVVTe3hPoGjPjqrAA0pjSlh+le0Tfpw5x7mEAWiB8ksWqwUWmvVWn4
-      l017v2xV3RwEi3Euxxo3LcM987A1ShbgAjjr37QU9szD1ogsgjkY60OWvxyM9YELXz45s9ap0km2zx53
-      layWuqDnbJvXaLxXpZtd0aCcMbi1gPPnBHJdoiMQ+PT26m2oBmoXHMy5H0dF5J7Bk/sujMK/B5Pwhy3v
-      Cnk1A4E4l227XdNFX2ayoODqqV/qF/u+kzrCK5jYRfPrBvMra37t3i5pl18FB3xOc/b+HTA2Kx53T+yy
-      GXp1YFDwpA59sffSgq/3e25ia13/PicCca62gn76PNBzwoti9+AbKoYtOgPfsuVyM6N98iUv3u2FVbdK
-      mJ7fq6Zoj6uvf8MGvpabaorDB3RXZgB3/HVjX8rSrShqnWAZfUGBU0e35Nzeu75BY3aKMl5bqe0Z2jvs
-      nVDqtfM1UZEUNfLT4HCese/TTXVHdQelc9Tz9vezqHurSl0Ak0oB3PObOuGXtTGo5z1X1UmbC9uTSnJz
-      lWuvnUE9Y/Bq6S/JgY6UYr//9j8R+yVO/ZwEAA==
+      6vX0j2RV1Xn5KESR7Otsm/9MnrJ0k9X/KZ7OqvLso/50sbg9W1e7Xd78v7Pt+pdfPlxepL9crN7/9iE7
+      //DL5eYy+/UiXaXvLt+//+W33367OH//If23f/uv/zq7rvavdf741Jz93/V/nF28O7/6x9nvVfVYZGez
+      cv2f8ivqWw9ZvcuFyGW8pjo7iOwfMtr+9R9nu2qTb+X/T8vNf1X12SYXTZ2vDk121jzl4kxU2+YlrbOz
+      rfwwLV+Va3+o95XIzl7yRv6AWv//6tCcbbPsTCJPWZ2pX1+npUyIf5zt6+o538gkaZ7SRv6f7CxdVc+Z
+      Mq1P115WTb7O1FW0cff99R4/2u+ztD7Ly7O0KBSZZ+L465afp2eL+0/L/5nMp2ezxdnD/P7P2c305uz/
+      TBby3//nbHJ3o780+br8fD8/u5ktrm8nsy+Ls8nt7Zmk5pO75Wy6UK7/mS0/n82nv0/mErmXlPT17rvr
+      2683s7vfNTj78nA7k1F6wdn9J+X4Mp1ff5Z/mXyc3c6W33T4T7Pl3XSx+E/pOLu7P5v+Ob1bni0+K49x
+      ZR+nZ7ezycfb6dkn+a/J3TelWzxMr2eT23/I655Pr5f/kIrjf8kvXd/fLab//Cp18jtnN5Mvk9/VhWj6
+      +E/9wz5Plot7GXcuf97i6+1S/YxP8/svZ7f3C3XlZ18XUxljspwoWqahvOTFPyQ3lRc4V9c9kf+7Xs7u
+      75RPAjL0cj5R13E3/f129vv07nqq2HsNLO/n8rtfFx3zj7PJfLZQQe+/LhV9r5y6CN/f3U31d9rUV+kh
+      r0VfxXQuE+LLRIs/2bnxn7r8f7yfS6e8fZLJzU3yMJ9+mv11tk9Fk4mz5qU6k0WvbPJtntVCFh5Z+Ksy
+      k5nQqCImC/VOqD8oUd6ou1WVuGp7tkvXdXWW/dynpS6E8n95I87S+vGwkz5xtsoknOlA8u79z3/79428
+      s8sMvJz/m/7jbPUf4EfJTP70efuFoMP84ll69u//fpao/7P6t56a3SfbRNYy8DX0f2z/8I8e+A/LIbKG
+      aumQ3nOzvF0k6yKXSZXsMlk9bMbqfNKxMnSgR2T1c1ZzdBbpWFVdmKwO260sbhw3wNsRns+TC37K+jRg
+      Z2pRHzulfdqzx6REOB0eZZlu8l2mWjaa1yA965Ns4YqMKbZhz81KBOTXx+RZOMdUXZGXeZOnxfGXJJtD
+      V/NSA+GqPu50Pk+KKt0kyqB6N7IrNjYQxPbm+4fpnfpAXQOlynS53vgw/ZLUWRdvIbsLqk0caYVYwLzK
+      qyi7w9sRXmrZinL1Hgy5Iy4fFPQx1B+vZw+y55JsMrGu8z2lSMI0aFf1Q3qQ9XyZbxh6E0f9K9Vb4bkV
+      inrX+V727yOuvBegMTb5YyaaiBi9AI3Bdgec338mZbrLmOKODtrZV93CqHuX/kxklS145d0x4FHyMjZK
+      b0CjRGRBMP339TYiAzo6YK+aal0VSUSEkwGNUm/XMelzxFH/c1ocuHLN4uaochMqM7lIUtmuMcwdiVlX
+      RbX+3tV3PLtpAKOIRvYI03rDzVSLdyLcf3lI0s0mWVe7fZ3pqRhid3BAA8Tb1lkGfFOQI2IiIKYsH+/o
+      6WeRsPVNfgjiQSLmG1aAfIP4uMkCpcryL1UO3iXrp1TW4uusbkhmHwf953H+8yG//sTKkbR4ZAQCPUjE
+      dph6PWGFOcKwO/vZ1GlcknkOOJJofyYnQIf63vVTJuvHfZ0/q1n279kr1e4JgBhtf1X+tse6OuzJEWwc
+      8BdZWhupJ8gRXAEWw80nZiRPg8XbVZuMF0KRmLXS4yrmtXew787KdFVkSbUWe9Uo7gs50KeGgBxoJJE/
+      lllXC6ipCwns9oIZEpahsZtCqPwry4zc3cQkfqxtcRBPx1uX/MNsGrDL9p3slIxv0o24Srl8m69lLUC1
+      ujwWQd0vPLciQ1bezezySIR9Wqc7lluTmLWtcRk1toOD/vZGEI16PkPXGzRi11W6YKlbFPEem+qkyEXD
+      0lsGOIr8U3oo5HAxFeJF1hkrTiBPMjJWchBZvUmb9E2Cnmxw9Oxnwg3Voai3zF5kk77JfjLlJx6LENlS
+      gxI4Vl5uq2SdFsUqXX/nxLEEcAx5oxbVY1QURwHHUZNQ+u7l3kCWAI+hp1pYUxKYBIklsy4+litBYjF6
+      a0cONjJ7agYKe38ccvW4+enQbKoXVpLYBjiKftaRPlFnhjwatnc9G1me5RCEnfa+BY5GfNoIoIi3ELKW
+      kd9Zf29vUVZm+xY4miy++fY1qhZxFME4m2zfPEUE0XwwAjfbDdz366eV3TeKap2y7kFQ4scqMznqaHb7
+      ZL4gT06YLGR+oQtffE+d7arnjDv5YNO+XX2QpOu1zGmq2kCD3uSxqjYRcs2HI9RZmT1WTc4Y/CAaJF5b
+      TW0PRcGK0+OYf5U85fTOksli5kqOc9e8TO7YsJmfzaZgIEZsRgMeJKIejOjsEvnfvGC2IhBHf3HFjtHi
+      Ab/qq0f4Wzzg7yqZiBAnAxKFfVME7gi1ODfjWVsU8ZaH3Yr4uMxGEa+IL5FiTIkUcSVSDJVIEVcixVCJ
+      FNElUowokV2vkld+jjDkbt51iyeTfVUxmhmbRyKw5vJEYC6v/ew4eSN46hOO+I99X/bcGGwBo52z0+g8
+      kEbys0P9zKl1TmjQy5o2cHkkQrZ+Yg2QLBhxs+ZoexKxivwxLR55F9yxYTM/uU0BEiPuGQegQOK8xV11
+      PvKuSuSwtXpJDuX3snpRD4z33cwOJ5NwGRY7MtoYv8gK1cHktDyuAY7SPnVn6Ts04OXm/2C+688jpz8w
+      DxJRTxun5YbzVN0TIDHaR+PMWsDEEX/U8xQx4nmK8Z2YgmUZkCiHulZfUn0fbhhbgcWRxXDXlRFeFEMA
+      x4h+AiXGPYESb/oEShCfQJnf7265fdo8iZi4pgeJWAldy8o6UE8M89LWlcCxsrQuXvVzsm5NAKeZBSxI
+      NN7TPBF6mqc+3KaFyNR6jbprErNN0r3QqlsUTsAhJ3wlj3WWSiwiLW0DHCXqeZ8Yft4n4p/3iTHP+0Ts
+      8z4x/LxPvMXzPjHued/xayKTbea2Th/Va6bcWJYEiRX7bFGMe7YomM8WBfpsUX8i4oqXyQ9HSNL6MTaK
+      csCRSvX0q03FqP4v5BmKKJJ086wWL4lsEx3WkcGx9fK4OhP7qhSsQmEJkBi8J88i9ORZfag2JTg0mVpa
+      kZWCG8K3INH6ZamchfeoBYkmvp96ohE3FqDB43UvisbGczRIvG7TCk6MFoW9Pw75OiJ7DBz1R6x2ECNW
+      O4io1Q5iYLVD+3mjRoNVKXt64im9uPyQVFtz3CN4UYes2NV0/WjZt5X1yGGX8aK7FjjasSruV4gy61lQ
+      hMWMXV0iRq4uMb+Xq5d8ykZWazHReks4mrrxN08Zd21LQIXEhdZYszueuA2PnpeP6iWRqpYjiZ3eSUhw
+      QwMqJG7d7FXjvs2LjBfNFCAxmjpfR08H+RY4WrfMSL24F1Ft+xYsGrt0BkujPTcdM2aETWhU1dlr21v1
+      ihe3YwyKxsaM6S7gtnD0Jm0OIvbXniRjYvEaCdcRjNSvuIuLZnlGRhRvEk8Eox3UJIysfyJCHRVIHFln
+      b55Yek2GrHHF3FbgcbI1//oVi5trkXLFEg16o5PGdCCR6gOvGdIg7ORPqodm07te6Bt0DGBTMCprjawY
+      XCN7UAP8LdXbUoBN3sMP7Sj4D/rDLJsesieTxd15XAitGIyj+lORcZQCjjNfTOISzBKMiMFONt8yJho3
+      8XwLHC3idUIHH/SzU851DEdqH+ly0w42DUd9i3h4JDX0azeIbF6Tp5w+4w5K7FjT68/JH9NvC/UuO0Vv
+      coiR+hqsBSLOp1Qkm8O+6LKqKrf5I3EJzZALibxLa/GUFmpip37tvi1YcUETEpX4qoHJIUZ68+Wgtrfb
+      qCxRm+WeHiP2j00pcQZUcFzjCe063avhISekb4GjUYu0yWHGapesXhvaBIZPw/b2PWryJj8AHvDzptYQ
+      RSAO++EMbglE22cRaabgAbfZBoioQJZpKGo7Fx0Xr3UEIr3NdORIZeA62rE4O2aLo37Oqg8AD/pZ73Jj
+      DjwSrQW1Sdy6U/tc19RFerABj3LaWo6xVCDkwSN2UzxFvs30ejVq12zIFYq8y/iRdlnYTJwLBnDcH5k5
+      wTxRHbnIys1R4HH4VUpPw/ZctI/quH0Yk4cjEDuTBgb79OpwXtXRoUFvTK/CUaBxYupwMVSHizeqncTo
+      2ql/+sONEyqhIqIGEsEaSMTVQGKoBhJyLFFskpV6O658LDI1MmYFAjxwxKbi9+qPbNicbKs6IrMBDRyP
+      PmC0SdtKfyEdeg89Yq/G4D6NEXs0BvdnVBsFpvt2qkE91JcFtqHs9B5y+JFYezIG9mNUH6lZqu5VkMPq
+      X9m6EaoEyV447UHHgMqJW6gvqQ3Lu93tSZFceMCdFFVkAG2AouhRevdQQTXRRUOP4zugSM3rPmOnlQEP
+      uJlp5RrsKO1KnqeclDgnyHWpdU+FXnDO3IETUThx1EKudvtGkrvHHF/MnqED+4XSrxK4vpj9QAf2AuXt
+      y4ntycnejzOwFydjow1wf431oWme6urw+KT32C0y2pMYALf9G1lsH9U5b8m6zvTUf1qongqpp45KnFiV
+      PvhFDpu+k36EyTlG2W1gvBZnYLavnds9rXRfNz/7xc1qbEkJMuSCIutZ5bYTQ8sBAEf96t0a1ScgV/2Y
+      w4m0fuL9BINzjJF72g7vZ/tme9kS9rGN3sN2xP61WV3LHjvzEBgPdtw/91WtFy+pNnonb/9a3vakAKDB
+      jkJ9iuI/PTkdXqmWdemDCCg+n3btzTvzhW1amfdpwG4+AFbdIkGO4BmgKLyGOrz7rv5U3dh6hWIl+6R1
+      TmuzYQMShf28FTYAUYxXk05bR9FzHLQA0dhPsYaeXvF2RMZ2Q+6f9sSOW8MmLCr36diYp2L9d7pOTnfC
+      QbuyjBkOVGFx3dVszJieBojXvX9UZz8OssmSDRhxDx9UAsaKedkCUUBx3uT5Ium54qPe2oW+U6PJecak
+      W6hDFB4x38dc2+WggLd9cWH1Sj9ECcBRPyMH8XcqmLuhozuhx+2CPrQDuvF5LcdF1Y4pb2HA3W2wQV8M
+      4tMBe39kDDtEr8Dj9EcfM6OcBGCM54zYbTc5zEg9rsgmfetx3w3GcxMA9/3eyJAawRMAMdRwhOxVEOCi
+      P8lDV2EYHyR/Xb77LVks7+dTvaYy3/xkhgBMYFTWmo/wWo9uy/2dSMRhrwZodLUB++4t+W7ZAveJ/Ecu
+      njK6q+N8I3s/kYGzA/THz+R2RSK+5zQITYqMfI9ZsO9m70EycN5A9FkDI84ZiD5jYMT5ApyzBeBzBZhn
+      CqDnCegVScdhDH3DSgAP+JldRpdHInBvawvG3IeiiE0ix4FE0nshNLJ7JfQElx4yC1Y80IREVcOTtDnU
+      WT/IY8UEPFDEcqNm7Xh9RJsG7KxjlWwSsBqvN5C9Bhs2k5f4gQI/Bn//jKGTQvTW26u8ojoVA5hYO3CE
+      zho5fSbUnEK5zljiIwy46V2SGuqTiGyt7pp+V3k9ecXrRIVcUOR29tjapYAeEpBAsdr5HdbI04JRt3q1
+      lXHv2zRm54ytejJk1XPrfLXGIT9rjIzOI4mntFazWLzpDptG7Yw9l30asvNqP7zeAxq7ZJM/ZvQuMG4a
+      F1V1z1kFKOAaF5l1RyAeICJ355XH8K4rxor49DFLxHfaimUAB/zsh7M+DdsPZf6DPknak6DV2Dnj9BCI
+      EQLSDMXjlGDf4EeJ2DR68LysmLOywudkRZyRFTwfy/iQvkjQg0E3p81Bx80vjN7lC9i7fKH31V6gvtqL
+      rLIydofSpm27encj9jko5rAj5SXz7VkL9JzGpr9EqUF6Vjk2p+oU4nhEspG1BcnTIp5HyVnTDS7rmdse
+      HVHZQr4LaGbVpi97QU2EgMmOqvoOh/2GOMfTU7atyFd1Wr+Ss9/kHKM60q9/PEYd6QA44G/XPrXL2wRZ
+      b9G2fZc+5uvT/Mdp476GVF5QiRur3TxALWxpl7TQgri0a1fbM8svqEU51OG+B9tu7nmM+FmMxPfZvPfY
+      ysPOHoyTSoVP2/Z9lpG6NOr7rkEXBppEI46nrtbqbCo98bivRMNbshvQwPFkFX3+Xj+SOhZn+utKQy4v
+      8nO+ydpLpLagHmy7281wZRk//epkW+SPTw31uU1QBMTUM11F9pwV5Cg9CnjbDg9PbLC2uSZWGrVXTzAP
+      gkTPfTQ+4NxRAO769aIoIzfVXK+gxQAVbhzhPlT/F/FtBERhx+m28u3XM1IieLDrVlv/y8hF+0oQTW2z
+      rlmtM87/ztoNXPIib3La1ARswKJE5DYqcWO19VydUV/dsEnXyjkjEDsfMOJswOC5gPpD6uOLEwS4ok5C
+      G3O2oP7OC+eKX6ArPmfl0TmSR5yzCdFzCWPOJAyfR6g/hd47IoeAJECsvhvM+yUOD0Qgr8fGTj7knnqI
+      n3gYddrhwEmHkaccDp5wGH+64ZiTDQVvha7AVujqcwDb88jVvCj1ei0WMPPOQAyef6g+pNdpCVSjcQ6h
+      Q082jDoFcOAEwIjT/4In/8Wd+jd04p/+vDsCnVW4LBhwc8/eGzh3L/6stjHntOnvtK/WqTq7PYqMHMQV
+      QDG2Vb3O9CScnj0T6SMjDiABYtHXu6I71gjyGk4BrOFUf4vqFzdDPeKIFZ0Dp8Opj/+1+X5+nrxU9fe0
+      rg4lOT1c3o/AXo85cB5c9FlwI86Biz4DbsT5b9Fnv404941z5ht83lvMWW/hc95iz3gbPt9Nf6M5kKXN
+      wfewX2kcODGNeVoaelJa/ClpY05Iiz8dbczJaG9wKtqoE9He4DS0USehMU9BQ09AOx1fZm7tS38nMaBB
+      4vGyGz1p7fRhzNJjVILEUvuGqwH0Wr02vcn2VV7yUg0SgTGZ68CGTpDjnx4XOjmu/ayfFua0Ji4PRXjL
+      c+k4Z9IJ+jpaAa2jFbwVjwJb8Rh/rtuYM930d56yjdEnpT9wRSVQLF75x0v+27wmTTkR7o1Ogxt9ElzU
+      KXADJ8C157YxRtLICDruJLkxp8i9zdlrY89dMw6ielIPg6krTiEejRCz8lGMXfkoolc+ihErHyPPABs8
+      /4t39hd27lfkmV+D531xz/rCz/linvGFnu8Ve7bX8LlerDO9kPO8eGd5Yed4vc0ZXmPP74o5uyt8bpeI
+      WVsrwmtrBX0Fq4BWsLLaf7jtJ7daQIul/sTYT87kcCN5A1EPtt1N1egDdbhruSDejsA/py10Rlvk+WyD
+      Z7NFnss2eCZb1HlsA2exxZ/DNuYMtvjz18acvRZx7lrwzLXY89aGz1qLPfFs+LSz6JPORpxyptbBJE9Z
+      UVTdbnDdiitiGNBhR2LMWYOz1C8pLRHU9x2DWqJHUijAcjxfvD9OD5CntTzWM7OUiKubW2QpLbY3L28X
+      vB/vgbaTLoMsrB/sgbZTnbmWrA7brSyQDDOAW/7n8+ScnaI+7Lt5UszGTWEfdt0XMalwEU6FC6YUs0Wk
+      wkU4FSLSIJgCHCFsivjtyC/fXOSJcULGWKeDoT7KWh0A7b35xYZznQ6G+ijXCaC9V7b61/NvD8v75OPX
+      T5+mcz3Abg+Q3B7K9dgYA5qheGp/4jeId9IE4m2ybK8vjB3qZAhEUa9ZlIeiYAc5CkIxDju+/rALmPcH
+      8cRWKzjgFuPfXoHYgJm0sSZMW/bFfPkgv3+/nF4v1X0j//PT7HbKydsh1bi4pPwOWEZFI5aBkMaOp9Z1
+      zh4+n+qI3Z5652MKLI5ay9xkvAAti5oPe6b2sMec8k8bnlSRmJVTaH0atdOKpgViTmoBtEnMSq0kXNTy
+      6u0o7yZfpuyijBiCURhtM6YIxeG0yZgCicNpiwEasRNvJBvEnISDFzwQcRJewnU53Ei92X0Yce+rPT8V
+      jjDmpt3yNog49erpmBvTFGAxCFuZeaDvjLv9hu48buHAywWt9j8ivodbtPBSJZ7yLTlnNOS7qC1HD/Wu
+      yfW1HIQlN9PF9Xz2sDwebD/WiuBB//gNJkA46CbUXDBt2KeL5PrL5Hq0r/u+bViv1klWruvX8QdkOpjj
+      267OL65YSot0rE3NtVqkbd1kZF2H2J5sveJcmoE5PoYL8lTsvKgCeSH0Ru76A8pbUADqe7uAHK+B2t5D
+      +VKne6qypzBbsk83m/HLnEDYdnOuE77KiGvEr3Bxd55M7r5R6scecTwfZ8tksVTfb4+QJBldGHeTmgqA
+      xc2P+pXDhivvcNzPV4eslObHRwPew4529DQqwGMQpsEANOiNyUkB5+SXB3YRtFDUS71iA0Sd5OJhkq71
+      /v52OrkjX+cJc3zTu69fpvPJcnpDT1KHxc2PxDJmo7g3Z2tD6UDNLhvFvYKfCiKUCk2VfLzjmjXsuD8x
+      C9kntJT9Pr2T8W5n/zu9Wc7kcDPd/ItkBviBCPTmDzQMRCHfMpBgIAYxE3x8wE8t7gA/EGFfE5YB4YaB
+      KNTbC+CHIxCXUQ5o4HjcFs7Hg35eucJaO/tjZplCW73Z5JKbKjaKeompYYKok5oKFula75bT39Vzpt2e
+      5uw5xEh4dORyiJGeRwaIOKldCINDjDlPmGM+cm73HGIUzN8s0N+sqp6DrEo//MIVdzjip3dFLNKx3n29
+      vaUXphMF2YiZ3jGQiZrdR8hx3X/87+n1Uu1tRVhM7JOwlZx2Bgcbiel3omAbNQ17zPVdL6f95AWxinTh
+      kJtaWbpwyE3PLZcO2ak5Z7MhMzkXHTjkplaBLuy4H+Tfl5OPt1NukkOCgRjEhPfxAT81+QEeixCRPsGU
+      YadJIDX46RBMAcprowDqeBfTf36d3l1PORO+DouZuVbAuORd5hK5wra4tWmTbjY0qwOH3OsiS0tiPQ0J
+      QjGo3VEXht3Ulgtts44fEFa0uBxspGxT5nKIkZdTGyx/yFUWXpP3DxXesX/4CUbdp+Obd6n4zgxhOeBI
+      RVY+jn8P1ydhK7XSRduc7gP6VJEJBpzJ+DOYITZsTrb7GLnEYb/g1TICq1/UJsVM4TvUmKxek7vZDdPb
+      0bg99u4Qo+4O91tJKtZvEU154IhywPt1+emKE6RDES+1w2JwuJF7ox9Zx7z8cM6trm0U9RJ7LSaIOqlp
+      YJGulfmMZYk+Y2E9WEGepjAfoaDPTfQHm3y7pesUBdnoBQd53sJ5yAI/WWE9TkGeoTAfnKBPS1iPSJDn
+      IjEPQ8JPQPSnsnp7zMqs1gcrbNQeVfQIvsON9O1hSu5vHyHIRS+PRwqyUccXRwhykUtkB0EuwbkuAV+X
+      2redJTt3bF/vZn9O5wv+kzNIMBCDWGH4+ICfmmkA70ZYXrOaCINDjPSGwiIx626vN6hLGp76hCN+eikx
+      QMSZ8641x66RXAp6DjHSmxSLRKzUasHgcCOnefFxz//pil1N2CxuJhcDg8St9MJgoo73z9liFjEP7uNB
+      PzFBXDjopiaLRzt22vHiBuJ42v5HI4c/aptQks9GMe/ze570+b1nbJJqRTmBzMEcX95ku2RzkZNsRwhx
+      UfYZ8EDMSZy2MTjQSC84BgcaD5wLPIBXpw6L4GRJyyFGcr1hgogzv9iwlJJDjNQawuAgI+9HY7+Y9XOR
+      36o22GDdJx2IOTn3SctBRlZ2IHmxT4k9zxMF2dRGxXSbojBbsm5+8oyKhKyHkvebWw4y0vYYdTnHuFt1
+      OzuSnz1ZJGYt+doS8LbNl0zvv2l3tME5RtlL3uVN/pzRqwkbdb2HJskq2px0xwAmRmvfY46vSR8vqC96
+      dAxgEuOP2jYZ15Tt9oXeo5CaCRZpWL8uP0tg+S2Z3X26T7qXSEl21DAUhZC2CD8UgVIjYwIoxh/Tb7Mb
+      Zir1LG7mpMyRxK2s1DihvffjZDG7Tq7v7+RQYzK7W9LKC0yH7ONTA2JDZkKKgLDhnt0n6X6vj43Ki4yy
+      0TyA2t7TCUnrpi4oVgt0nEWW1sm2SMcf1elgkK/ddJRpNWDHrTZT0cc166+QzDbqeKnJ6aei/IseLupj
+      WIgbtqICJEZ7nvnjIa3TsskyVhjHAUQiHj/ucrZxUx3PbKT4esq2ZdWWopFft3m16wzpMbIFOa6CsJPK
+      CXAcNS0XnXqy+0uSFgXVohjbpNfaEJYCmYxvGr/VfE8Alj3ZsvcteZk3VI9ifNNOTUIw0ujIwcb9+I6h
+      g/k+tYOMLK/jlwR5oO9k1ukOinnVIaXjt6KGWN9MPaXA5Twj9Yc7v/Yp+7k57EiFuUNsj8qgklSWW8K1
+      NOSW78jYJlUM9bFUJS2FTM41Nk/kavEEAS5KB89gAJPepIr0MguAYl5idlgg4tzIjkRdvbK0HYuYqTeE
+      BSJOOQjnORWIOGvCcXoeiDhJG9b7pG+t6D0SA7N9xMLulXPVCKzyKtmneU0UnTjfyOgAGpjvo/UtWgKw
+      EM6IMBnAtCd79r5F1Ymrw5aq6jDfJ6r194yc6C3l2n4SPT9dw2G3ymry/WhgoE/dUbINYSg70rYyBj7g
+      mGdfkQqE/LrDq+UIpILQEo6lqcnNypFxTMSBzt4b51Ard79OpxYdv8y056SK8pyq0RDg4szyWKDrFLTb
+      VQOO44V3VS/INQlO3S3gmlsQ623h1dqCXGcLoMZWp37saBIJuA567SrAulX34QrCedIWBLhk0uuTKqll
+      wIMRtxoI7Al7sYIw4mZ7YSd1pC7A2QxBns0QwGyG/ht1BH2CANeeLNr7FurMiABnRkQ3IUHsvRgY7Muq
+      rRrnH+qSo+1p314SlhKYjG86zUOQS0hPBqzEmRERnBnpPxX7bJ2nBU/dwZibPEByUN/Lmc0R6GzOaSjW
+      nQJFekSOCpwYT9Wh2CRyRMRJaRcG3eQi12OIj/hgxeRAI70gGJxrbHNSfkYTnjDHV9L72EfGNjWZYFTs
+      PWXbDurAZ9JVtYRteabOnz37c2fPnCR6htPohTGwegFHVuQiBZSl9tYlPjI5QZCL0+W2ScN6O/ljevHx
+      4vLDaNuJgCzJp7wkVD8OBxpnlE6DjYG+r/sNZU7VBQ3nXfLxdnZ3077nXz5nhN6kj8Je0q3lcLAxL5/T
+      IiclAUijdmYy5IFUoMwz2pjlu17+lWTjDxDpCc9CzJYj4nkIL6f1hGehJU9HeBbRpDX1ajRjmX6f3l1/
+      1OtACKoeAlyClEYnxjJ9ub9b6gumLHp0OdhILAoWBxtp2WliqE9VMqKhvACKCvAY26pOdtXmUBwEN4qh
+      gOPQCoOJob6kUPMkG6a2oy17uhJJLpKXqqZYDcq2bUiWjUeTL6RDbI9YX6xKikUDlmOVlzRHC9gO+Zec
+      5NAA4CAePeBygHGf0m371DOtVyvWtfWca9xka5pKAq7jibDG4wi4jiJj/bAT5vp2+5xmkoDl0OsACQr9
+      fd9A2Z7fZAATsTnpIdtFWPxxZ7+H3/6bWmccEdtDa2y9NnZdHUpVwb4kf2d1pRJMkHQebdllGafVRi1g
+      O/JniiB/dmlqOh8R23Og5Lb1Vpv8d1Y+peU62yS7vCjU489UV3J1vpM9/eZVTx4Q9GN0dvwfh7RgdVAc
+      0rb+pKSJ/LZFE+9C7/7b1tVOdmTK5rHaZfUrSWWRlvVxTSkq8ts2fXxrVeVFlpCqc491zE1Sb9fvLy8+
+      dF84v3z/gaSHBF6Mw/jNlnvCsxDvuCNieWTbRqs7WsBykB6G3LnPQe5UX1HWacQecQ+5rjJ7TNUrUzTZ
+      kXJtFanT2gKeoyRejARcx756uaBJFOFZ6HeMQcG2bSprLTUvy9MauOsnFnBozCH/phpNmkURlqXIaDeJ
+      /r5tIJ32eAIAxzlZcm5ZdmktnmRrQ1rRYWOOT3yn9mhOjG2qNsQxYkdAluTHIR//TqzLeUZaK9wRkOVC
+      t4l0V8tBRqYw7GN1Y2ABHoN4f3usZ9ZTr4J6yR2F2ZJVoRaDb3jWI43aqw3XXAEln1zP9BDiOmfJzjEb
+      6760WMQcIUa8u0NB1EkCsvA60D7suYmdgiPiecSPmqiRBGRp6Bq/3InDiqo5rCALq0icOM/IqK78Wmqf
+      07oSLWA7aOXSLZOySFF/SYdYHtrkvjunX5YyeSi8+r5voN4BPWS71JmYtC7MEQE91AS2ON9IOe7TZCwT
+      bRDijkD2qWpxVOcvOZRqLxJSewjQtp07RxOYjSHtanf8vm+gLBjsEdsjssOmSuqU9MTWoDCb+j+PGc/Z
+      spaZeIHelbEuKXAt7Z9pw0qLs43UnlHt94pqco+oBnpDxGNwe8KzMKY6TMzz0ealBDAvJejzUgKal6L1
+      SNzeCLEn4vVCaD0Qt/ehehDUNOgQy9NUiXM0K8How6C7O2uNIe5I18rq6lqcZTzQJgQO7mzAgfYA6eA+
+      QTrQisLBLQvPaXHIiG3vibFMxGksZw7r9JXtoVw3eVUmT4QaCKQhu8iKLa0N91HD+/VT8mX6pdviZbTS
+      onwb6ZGIwfimx7p6oZoUA5vaM4Y4vpb0rZQueo/4HvXCVP1MTrQOs327bEd5yncibItoaqKlJTxLsU4b
+      okYhgIfwhLhHPE9J/1kl9LvKIiupnsJ8r/P640c9HUqZJjYZ2JSsqqrg6DSIOEmHl/okYq3WDXm/aVSA
+      xcg37XPShvCmMG5Aohz4CXRAUog0JLUg3yX26TqjujTkuw7nH6gmiYCe7owrOaSTH/0cP9wNKMA4RcYw
+      F9BvvyDnsURAT/Rv9xVAnPcXZO/7C9DDSEMFAS76fXKA7g/5R8Y1KQhwXZFFV5AlOlOvwnlKPGPRQGwP
+      5e3T4/cdQ058icqCXJdYp/UmWT/lxYbmM0DbKf8jH78zQE9AFspm0Tbl2Ci7sp0AwNE2HGpQP37PORC2
+      3ZRFJsfv+4aEXPJ7yrYR+lfd122e2Kc2ENtDGRYev28aFl33KqvVKHyT1eNlHgp586bba/kpFZRZL9wA
+      RFG9IHkJtF6Uz9pmtc9WmpeiW3X5SqlOINq171+p3SiTsm20OnPh1ZkLvTosLV+J/X2bw41JVmQ7wg5s
+      GA9HUCUwNorrACJxUgZOFfpIyAERJ/f3D/7uJN/ti3yd0wdEuAOLRBusuCRiPfC1B8RLvnlPkO8qUtGQ
+      OnoW5vuqvZqlI67yAuEBN6sY+4ahKLzB+JBpKCqv0EAOPxJppHpCQA+/Y48qwDhFxjAXGeC6ICeqM1I9
+      /TH6t4dHqt2XKCPVEwJ6GGnojlQX1CXkBgJ6GNfkjlS7P5MrMKjuihmpYgY7Cm0ssfDGEgu1SPi4kOHU
+      9mSPtM4z5vAi6RfVnc4wMRCkCMXh/RxfYMcgjZkW7php0e5OpF6VoVhOkO3aZ9n39lKblJSaFmg7xfd8
+      T1Gp7zuGZvwTpeP3XQPlyUhPGJbpfDn7NLueLKcP97ez69mUdkoFxocjEO5IkA7bCU/CENzwf5lck1/B
+      tyDARUpgEwJclB9rMI6JtP9JTzgWyp4nJ8BxzCkbPPaEY6HtlmIghuf+7lPy5+T2K+kUVptybHqPgEzQ
+      8t8FEWdRdXtmssQn2rG3a/mKfPwzfgczfPPb5Ga2WCYP9+SzcCAWNxMKoUfiVkoh8FHT++1heZ98/Prp
+      03Quv3F/S0wKEA/6SZcO0Zg9LYrxR5IBKOYlzXB5JGblJ3MohfWcsWxaeeYjjdkpvSgXxJzs4hAoCXob
+      FPVomp0SpgGLQtv5DWI985evy+lf5MdZAIuYScMPF0ScavMW0taGMB2y056owTjiP5Rx12/w4Qj832AK
+      vBiyo/hNtvDUB3sQjLoZpcZEUe9Bd3KSlfp5ghnAcniRFsvJcnYdWVBhyYhYnCxHLOFo/EKMaUbFi/59
+      wZK9/DyfTm5mN8n6UNeURwswjvv1ltTdoXvcIKYjHKk87LI6X8cE6hThOPtKTYTUMXE6hRdnvVqfX1yp
+      vVzq1z01X2wYc2dlhLuDffd2pT4+59odHPNfxfkHrz/KjrqfUvm/5OIdVXvkfGPbE1F9a31sO70XDRj8
+      KE0dkSYWPOBW/yTMxuMKL862qr/LG6JRhzjnj2VVZ8ku3TwnL/k+q0r9qdrUT61Qp8y/cuT+tamDB3nZ
+      Z6Ke93G9UwmTklusHsScvHrJhgfcrLIAKbA4vPJswwPumN8QLs/dl1hdUovFzHqc+j175bmPNGaXTd/4
+      LckAFPNSZvtd0Heqgy9e2/5Te0wdtw8TMAWjdufNvUVYVxWM215ofFDLA0bkVXsGiVnJJ34iOOjXVXq3
+      2VhelYwQjgGMolOPsoM6xKJmteYuIotdBRinedInO8nvEh42wLjvf0rVSlf6uLkHPadag5iKHVHYUb6t
+      7biR+3snzjPqalW8Csq73ADqe/XhVNtcHYqap0WyOlCWQwccXqQiX9Vp/crJNxP1vDs9vczRGqRvzXaE
+      N0wtyHOpGoVX2xmkbz3sEs7czonzjFXMCKgKj4Cqck2tzBTiefZV8Xr+/t0lr//j0LidUZosFjcfaI8r
+      Qdq3y3GHkLf3qvrJunQH9/z1hlHvtBDiUnvPNPm+yK4op2QFFH6cbNtusCuHBIn6ut6MkLSsfkiEx8zL
+      NTeKRD2vmi9Sr+rE9M5ABxjpbXq+gtDzFW/X8xWUnq94o56vGN3zFeyerwj0fPUxdJuYqzdo0B7ZbxRj
+      +o0irt8ohvqNvO4T1nPq/q7nd0SWMbUnHPXn2yR9TvMiXRUZM4ap8OI0hTiXLQC1Dj5ihm85T27mH3+n
+      7VlvU4DtuLMzWXgEASepjTQhwKXe3iLkvo0Zvqf0WvX8iRNHFtXbbqaL41TY+7Euk7FN2Xr1ntotdDnP
+      yBQivk12oR5QsKQO65nfR5jfB8wlPX+OjG0qmddXotem6lLCFKCBgJ7kUK6fMsohNiDsuyvZodmndd6Q
+      L7UnDevnREca7eq+7xuS/WFFSkCHs43Vbn+Q3Seir6cwm5q/eCLkCQSjbto5KiBsuSlLurqvW/zphABa
+      MpoY7JOlKN1lTVYLwpZ2qMCJ0bxLHklOBfgO6m9uEd+zp1r2gOMH+RdJBPDU+TPnhx05wEi+aU3M9/2g
+      mn64DnXoxK+/nf+WXLz75Ypms1DLe9zyvS93BLMPW27CgsP22zZN3K/VQCxPuyiZ9ftc1PIK+r0koHtJ
+      0O8DAd0Helil34iimTrIdhFOfe6+bvG0BZsnwHToVBeU04JMxjDN5tPr5f3822I5p55RCrG4efwwwidx
+      K+Um8lHTu3i4nXxbTv9aEtPA5mAj5bebFGwj/WYLs3zdQvzkbvJlSv3NHoubSb/dIXErLQ1cFPQykwD9
+      9awfjvxm3s/Ffqmeg9tTHpqCsOFeTJLFjFh7GIxv6tpOqqzDfB8lAXvE9+g2j2rSkO1qhzDq1de0OdQk
+      o4Pa3k0Vo/Zpz64+ISoV4nmeszrfvhJNLeS4ZON485kk0oRtoZZcv9SyBk0Ohxh5wybU4EYhDZxOBGAh
+      /3Kvv3f8657s2UOWH/TfZfcbT3+lDqBcEHISh1AOBxh/kF0/PAv1kYuDgT7yMiOItc0RAzOQRuwy9xi3
+      NIAj/sOqyNds/Ym27cS2zmvn2ENCgAXNvFT1YNDNSlGXtc2CUbcJsG4TjFpJgLWS4N2pArtTqc2636aT
+      BsXd920DcVh8ImwLvWMB9CoYw2sT6l3Ta96stMvhxmSb7wVXq2HLzejJ2xRsq4hn+EAsZFatGN2pKMyW
+      1DxfUqNGwTSCv5g4MvJA2PmT8k61B0JOQitkQZCLNOpyMMgnWKVGIKWmqbhl+0i6VuI4y4IAF61KdDDX
+      R78w6KrU35KXvHlKSrV4US8WK7L0u9m+c1424tn9q/s7o0b82ytpnGT30zz5/VN33qfsUT2NPzHOJz1r
+      mYtmf3HxC8/s0Ij98kOM/USD9r+j7H9j9vn914eEsKTZZAAToRNhMoCJ1igbEOBqB/Ht/EBVk602jvmr
+      mrCbMoDC3nbrsW2RPnLUPY3Y19U2XTPT5ARj7kP9nKkSyJMf6aCdMq+L4Ih/kz1ySmCPIl52MUFLSXtb
+      E7Zf90nAquYiVq8xyewZkCj8cmLRgF2nGOnJMYACXhF1X4qB+1J9zq+sLBqx6z0G1Ms56mBpdbyX7B7s
+      WJFAkxX1j+m3bp6dNnZzQMRJGmXanGeUGZ7LoqTHYCJb1+M3oUMFfgxS+9gRnoXYNh4Rz8OZxgfQoJeT
+      7R4PRFBNcl2Rk7MHYSdjvg7BET95zg6mIbu+D6n3sseC5qxc6+pKMMwnFjbTJvZ8ErOSJ+IR3PPnIqn2
+      6Y8D9RY8cZ5R5ucF4XUnm/JsxylzVtMNC9AY/Nsl+Nyg+w5pWuVIQBZ2TwbkwQjkoZkNes52mp590S6O
+      +OkPPhAc87PLR+AJSPcNbi/MY0Ezty4VwbpURNSlIliXCnZdKgJ1qe5NMprZEwca+aXCoWE7t4m14QF3
+      km7VhzKv5VAhL1PSnOg4n3cFtIdGFmS5vkyXn+9v2m0n8qzYJM3rnlLBgLwVoV0+RTjM2WQAk34LjNrv
+      dVHIS5r5OjGQibA7uAUBrs2qIKskA5kO9N/njjjoKwYtCHDpmamY2yekGR2POOUwpALi5mpY3JBjtBjk
+      E0mq3gRX2xQ09NJm47BfDuF1p4EjP7KAeXegl2jJACZanxBYG3r6a7VuLvT8Bdl3IgGr/vvFerUiW08k
+      apVxmVZJAlbxNvehGHsfire7DwXlPmz7ZLt9nQmRbd4kNq5D4jcV/8Z1eCtC18XPNxclYY9+DwSdopGf
+      bRjOFrSc+jS0Q140eVdLUMqZDxvum4vLy/PfVB9qn+bjJ0xtDPUdp/PGv7OICvwYpOfLBuObiM9fLcq0
+      zR4m8+U38msSHog4x78n4GCIj9IaOJxhvPt9dkf8vT3ieVRhbR9wE+cEYBz0z2Psc9ytTwE53mlZ+Sg/
+      EsQIkMKLQ8m3E+FZ6uxRVjXqJM+i0DVykTXULAQdXiQRl6diKE9FTJ4KLE/n82Qx+XOq9/8mlm8ftb1q
+      y6CsrquaNuPgkSHrlq/d2t52DKg/pjgNDPKJV1lwdlytSdv29mfQDn5zOdyYlFxnUtpWvddw+5GgOE3O
+      MR7KNfvne7Dt1vP61Kw6QYgrKdSfOEJNhqzkGwvAfX+Z/ey/pbdPpIbwDXYU+Ud2FrqsY1Yty8fZPafM
+      uSxgVv/BNRssYJ5P7m7YahMG3HqXloptt3Hbr48+JN8yPYXZyDeNgwa95NsG4oEI+uxlXmL0aNDLSxaH
+      H47ASyBI4sSq9mqQukvr7yR7jzm+Wi0t0SFJxdrkcGOyXnGlEg14t3u2d7t3vAdOiTuAZa3OUlGV7IoZ
+      wF3/rnpWrTphSzaXA43d1n1csYm7ftGogxkYZgO0nSLlpEFPOTbZ2lJvpyNjmP58SCbTyY0+9zMlnFbk
+      gYiTeHIaxCJm0ojFBRGn6sKMP2kAQBEvZe9ADww426X9m7zO1pSd5Yc8SETKuNzhEGO1z3gXrcCAM3lM
+      myfCSlqERyKIjPDWkQsGnIlYp03DvGxTgMRo0kfSy00Ai5gpOyR7IOBUj7xpexQBKOBVb2nJir9+4tR0
+      Joy4uSlssIC5fXWHmR4mbLs/qheultUfhKUQFmXbrmcPn6dznan66D/aq0OYAI2xzvfEG9yDcTe9zfJp
+      3E5ZC+CjuLepC65Xoqi32+uT0ifEBGgM2oongMXNxF6Cg6Je/ah/v6eNl3AFGofac3BQ3PvMqFAgHo3A
+      q8NBARpjV224uatQ1Evs6dgkbs03XGu+Qa1qU2huEdEsahbxZVyMKePqSzE1wIkPRoguj7YkGEttRcuv
+      MA0DGCWqfR1oW7n5gKd/TE0TrmWicnQgJ5k1C1qr8O59/76nd3ugvo7+26e8TAvCPlo+CVln1AbrRGE2
+      1iV2IOT8SjpNx+Vs4022ljn+MRXZh18oRpMDjeouZQgVBvl0jtF9GoN81FzuKchGzxGTg4ybW3K9YIGe
+      U/VgOTeMg4JeRmIeMdTHu0zwruk+Y2VSDzrO/DETtB+tCchCL9s9hvr+uv/EVEoStVJzxSIhK7nonCjM
+      xrpEuNzojxaUVWwWhdmY+X1CMS8vLY8kZmXcNg4LmblW3PgnbY2gw+FGZm4ZMO7m5VjP4mZu+pq0bZ+W
+      rHbdwCAfOXUNDPJRU7SnIBs9FU0OMjLadQv0nNx23UFBLyMx4Xbd+IB3mWD93H3GyiSsXf/88Me0nXem
+      Pky0ScyaM505ZOQ887RAxMmYP3ZZxJz93Fd1wxK3KOKlzpJaIOL8vtmylJJDjNynN6AAiUGc+TM5xEh9
+      xmmBiJP6BNICUWej3wZd5/s8Kxum3nIEI4ms3NCmMkDBiBjt0231kgVrIz2aFrke6hNSCwScf9x84lSG
+      LQb5pl9YPo2Bvm/setBgMTPxGZoFIk5WHQjsnmN+RD2HEoQRN/XJkAUizu/ZjqWUHGLk1Kf+Xh3mJ5z9
+      ARAei0DfIwDGET+rLjiCtvPLTcQTdw8G3Yy7+Etg/dbxM+IdbGCoj9g3tknYqs+g5kg1CDq7A6YZ0o4E
+      rdTa6wu2Fu4Lb8XaF2y9WvfBbsOw7Tawq3rm/FaFgT5iHfUFWdXW/Z38PNbkQCPr+ajLwmZejYHWFaSt
+      QmzM87HrtEB9xklFOPXU63TtHicMpQ17buKzwpbwLIyUA9OMkad+fj58nCaCdNawTTm2P64XVxeyVfxG
+      sp0o1zb9dqE/pNmOlG9jrceyQMS5obXDJocYqe2GBSLOdjdCYvfJp0P2WqRJlWb7pEhXWcGPY3vwiPqL
+      u8ftObEhwxwDkfQlRUbqHAORGCtVMMdQJCESkRYNcX1syBOIeDq3LSYZTQkSi9h3MDncSByJOyjiFW90
+      34jR943eO27d7gOoVoFyw1mSEbHkwLnfwCQ6qGULRFdJImst9XXSptIDnnER5Zgz+7l/i5itaSBqTE0o
+      RtWE4g1qQjGqJhRvUBOKUTWhMGqwLrUjf5llIkR9g+zzdePjxzQDuG5E/LcKPBwxuv0Rw+1PKgRxcYWB
+      ob7kZjFhOhWKe9stJ7nqlsbtc/5Vz8GrXqUi4zTEHQcZOc0C0gZQ9qY0GNjE2ekXxiG/ml+LCWDzQIRN
+      Rh9ZGhxuJM+CeTDoVgcBMKwKQ33cSz2xuFkvR89oj+ogHojQvRpENnccbuQlhwkDbtZYGRknk47rMyHE
+      RTj52eVQI6NGPYKYk9kGGCxmnnOvdo5d7TkzTc/RND3npuk5nqbnEWl6HkzTc26anofStCmEus/Ukiza
+      /qpBCxwtqdMX7vNCzBGKxHpuiCiAOIzOCNgPoZ9R4ZGAte2Mk5Uthvp4FbnBAuZdLvt95WNMp8RXAHE4
+      c0PwvJCa2Ikty4AjFIlfln0FEOc4tUK2H8GAk1dmLBqy69142qON6XIDxt1tznDlLY3bdXZw5RoG3ILb
+      qgm8VRMRrZoItmqC26oJvFUTb9KqiZGtmt7tmfhEzgIhJ2cWAZlD0ANq1v13IkHr34xf7D3N1H9mpR6S
+      csQzN2wM8D2TX8IwMNTHyw+Dxc11tlYLarnyDh/0R/0C02FHYr1NhLxHxHmDCH536PhX4nImA/N99EX+
+      2PtHzLd60Pd5eG/yYO/w9H8npp4FQk56CuLvAqntiNs9aJK0yFNSd8JlffOG/G5lTzk2tTtemonk/OIq
+      Wa/WiXhKdStFkmOSkbGSfLeXfY+cujPbKGHoGta7ZFUcsqaqaC8c4Zax0ZKrt4mXXIUiNnXytEt1ulxc
+      fuBHtD2BiI/rHTuKZMNmOeQoN3qzq5gYvWUgmogojB0/EEGW1POLqBjaMCLK++go77Eov13wc71lEbM6
+      sj66RnIlI2NF10ghYega3uCOBTyBiNy869iwOfKO9SwD0UREZoXv2OM3+HesZRgR5X10FOiOXT+l8n8X
+      75J9Vbyev393SY7iGYAoG3kl2SZ7H3f7gpax0aJu4EEjcBXloSj4v9WiAfvP+Iz7OZhzp34UzX3CEF9T
+      s3xNDfsyws7dNgb7yBUg2ltpP6i2rOuTGOCTDSQnP1oM8THyo8VgHyc/Wgz2cfID7ke0H3Dyo8V8X9eq
+      U30dhvjo+dFhsI+RHx0G+xj5gfQN2g8Y+dFhtm9VpN+zixWxl9RTto3xChz47ptqOoglpEN8DzEnOwTw
+      0Pa56xDQ854heg+bOMl05BAjJ8E6DjQyL9G/QnVst2riKbIjY5vUU+R2bmj1SjoWHmADZtpzaAf1ve3M
+      E++KTTZgpl+xgeLeavUvrleitvcpFbo6e0rrzUtak1LCZR3z/nvG7dC4LGJmNAUuC5ijurWwAYjy9H2z
+      ZYyoXRYw/2zP0YwJ4CvsOLu0ln8uumKVpMVjVefNEyknMAccibkEAcARP2vhgU879g1pe075dZe/pPGX
+      Hq9HcESJZmzTXv7SLCq/YQMUhZnXHgy6Wfnssra5Xl8kv7yjNsw95dsYKsDzC83hlD1qufHLjJ472Oqt
+      yro9a9a1er3gsN3mP6lqVOTFvLj4hSiXhG+hVZtQLSn/9v6Kei2S8CyXtPm9loAsCf1XdZRtU1NPah5K
+      L5LfpaTC6rKwuasn1EP0esPRWwI4RvvZ8ZvisFdblWWsaIgKi6uPAWO8+QUbjCh/Lad3N9MbvW3L18Xk
+      d+IJuzAe9BMeoENw0E1ZyQjSvf3T7GFB2l39BACOhLDVhgU5Ln0M3Lo6lITTlzywd/4+vZvOJ7eJOk18
+      Qcp4n8Ss47Pb5TAjIZM9EHZS3lJyOcRI2AHB5RAjN3sCudO+WFCpI8TuCIPagCIU5zktDhExNI74eYUM
+      LWPcIhYoYXp5KsupScQqTolfcvPPVoTi8PNPBPJv8fXjcj7lFW+Txc30wtGTuJVRRAy0937+42b0Du7q
+      uzaptktNyw1F0CGep6nTdUMUacYwfZlcjzbI79okZxc3l4OMhB3cLAhxERbsuRxgpBR7CwJclMWnFgS4
+      CMXbZAATaZ8xm3JspMWcPeFYZtRUmvkpRFy4aTKOibZc00AcD2Xl+QkwHPPFQr0QnI6/806EY8lKqkUT
+      juW4qShl4sUDHSd/6g7BHT93wgiEXXdVvL6XN+tzNn5fbQ8EnbtDwRBKqrfNFouv8qvJzWyxTB7uZ3dL
+      Ur2G4EH/+HsYhINuQt0H0739y83o6Rz5VYujVXcnwHZQKrvj923Dsk5Lsa3qHUVzgmwXrbLrCdNyOR6/
+      tDhqel766XlJTM9LLz0vOel5CafnJTk9L/30nC4/399QXg7qCc9yKOkezfQmPVy4vr9bLOcTeTMtkvVT
+      Nv4gEpgO2Cm1FAgH3OMLCoAGvITaCWINs/zkEy0JToRr0bvQ0Q5390DQ2dSEGU+Xc41FNf5Ahp6ALMkq
+      r+gmRbk2SnYeAcMxXS6uJw/TZPHwh+zUkTLTR1EvoSy7IOqk/HCPhK2zZPXhF9UpJUzbYnwoQvvuKz9C
+      y2MRuJk4C+ThTN8VsndJ6JZiPBaBV0hmaBmZcYvILFRCRGQ6iMF0oLym7JOYlfbKLcQa5vvl7Hoqv0or
+      axYF2QglwGAgEyXnTah33X/872S9EheENVUG4nhok1IG4nh2NMfO5Unb/PeEbdnQfsnG/RXyPzaqqOYb
+      tSpDUFwOinpXrzHqjrbt+hkC5YRwC7JdtMOce8KxlNTC2RK2Rf7hYr1aUTQd4nuKkqopSt9CWG1oIL5H
+      kK9GOFcjtdQk7hDf0/xsqB6J2B5BznEB5LjUUjUd4nuIedUhhudheqe+pN7MTouiX6YlknVVjh4MDmj8
+      eKtDXqj979odjwU1joP7fl19i4zq7TDER6h3bQz21aTW2ycBq0zr/JFs1BRg2x9kZaxPIiMre9T3cn41
+      /Hsfd02+I7taCrPJMvwvnlGRqHWTb7dMrUJ971Mqnt5fUJUt5dvy9P3FOt0nD1ThCQSc6oGJ3uiyIlt7
+      1PcWT3KIV2QNOeNPIOysdM1VP3K0RxY0cwp8h4G+XFZR458ieCDoJHTYbQq2HXZyYJDtBMd5ZEFznTV1
+      nj1z0vOIBr2U5z4IDvj13JFqs2STtas2h4Le5EEOP9JOlsNqTXW3FGYjPZcGUMCb7Tb0RqWlfFtZMRu+
+      E+g75bCLk5Ad5vtEU69TkVEGkB4JWhnp2FKgTTUPDJ3CQF+xThuGT2GIb//K8u1fQV/Jz5QylCslL1tK
+      LF9KwmECDub7mqqoXsavP3Uww7f8PJ1Tl19aEOQiNZYWBdkIFZfBQCZKA2lChmuflfAgabQYNeBR2lci
+      2SE6HPe3K+DZ/g73/c8yKuFplIOhPtW9YDoV2nsfpl+SyeLuXC/NHmu0IMRFeTTlgYDzRZaQjCzUFGZj
+      XeKJtK1/Xb77LZndfbonJ6RNhqzU6/VpzM5KDgC3/avXJhOsK7dJ2yr/M1nLe26Vjn8i73Ku8bvs4W0r
+      mq1lHFOVPMmLHt8qWZDtUk+61Lsz17MHWQ/rhKZYAdz272vZsaXs7mpBtota5v2SrvP65jNtv2gPhJyL
+      yUP7auUf44dEMA3bk4evHwlbLwMo7OUmxZEErNPriKQwYdDNTYgTCVjViaG/ko2aQmxXLNsVZpNfn/2p
+      X96i3qCYA4rES1g8VfmlIFgG5lH32nzgXlOf63WpXPkRht3cVJ6H7mPVRpKNCkJcyeTrXyyfAjHn9fyW
+      55Qg5pxP/8lzShBwEvsPcM/h+Fd+O2PCmDvqHvAMeBRuebVx3B+TRIE2SH0e1Q65AjRGTAKF2iT1Oa9d
+      OpEB6xXbehWyRrZTiAeLyE/4cKrHlZrBMjOPvnfnI+7dqHbMFeAxYnJhPlQ/sNq1Ixhwsto3Ew65Oe2c
+      CYfcnPbOhG03ebIDmOdoB+Wcps4mQSv3RgFwxM8ovi6LmNkJArdq7YfcJs2nYTs7OZCWrP2Q3IwZGOa7
+      4vmuUF9MwjqCETEoh6AHJWgsflOMSsBYzAITKC0xGRHMg3lcfTIfqk+4Ta5PI3Z2as+DtRW1me0pzEZt
+      YG0StRKbVptErcRG1SZD1uRu+j98s6IhO3GQisyan/4c0Xbj41Tj87h7bmCkan2JfXeExqrWN6ISKtSu
+      xwxXYQMeJSqZgu08a8jqoCHvFd97FfTGJvyI9h/4Gq8PgIiCMWP7AqPG5cZXIwrYQOmKzajBPJrH11fz
+      MfVVXF8hPD63vhOVG/PBWpHXd4DH6PZnvD4EPkp3Pmf1JfBxuvM5q08xMFK3Puf1LVyDEUXe3ucXycPH
+      qVptMtpsUZ6N9gqXBXkuylInA/E86on1d1lnpuUmWWf1+MU4GO9F0JubEK2a8UzdWZmELUQ90HZeyqz6
+      4+bTRULZvMoDA85k8XlyzhZr2rXvV9mFek1ZLXAnra5FcNCflVF+E7f9vyarQ7kpMlVjkIqaBSJOVf7y
+      bb6W9wvPbQrcGNQb7lfgfvtV3y70n36kIJuqzXjGI4lZ+ckJGaAocRGG7Op897gIrsGNQnnbuydci1rZ
+      k+SC9IKqT6JW0kmrEIuZu7s82/DkJxz3P2dFtef7Oxzzq7zgyls2bJ6Um2ncT/A9dkRnAEKuoyA+HIHW
+      HPh02E5YJ43grr9r6WjWDnJdXYGluTrIdR33kzvdBJxzDEao3LjtTnNvEDUg8mKq/qF6m54Y4YiBPsHz
+      Cdt3fzu7/ka/dWwM9BFuFBMCXZTbwqJc2z+/Tm6Zv9ZCUS/1Vxsg6iT/epN0rewdwBA86KemBroPGPAx
+      OVXwvcC6z79MHh4USb9sg8SsnLQ2UdTLvdjQtdLT1iAN6/z+L5ns0/mybZ70qQOL2f0dLTGCljHRCEkU
+      cIyJREm4kMSN1aUyPdkMEHFSE+eEIT5yEvRcb5xP7m6S7g2isTaTcUzyL1n6ShK1iOMhzIQdv+8Y9Csm
+      JIcmIEt7uI8600TtH6iOBiMMnwY0TjziBh4m45iyR1oKyu+7hjJdFVmyrervyaEU6TZLVoftNqNslTgo
+      cmJuc/lFyiEDNuXY2oF1uUl2WfNU0dLDYR2zfs1dhSU5T5Rj21fjj7s8Aa5DZIdNxSj2Jug4RZbREk0B
+      noOfByKYB6JJmwPtt7aI4bkevW+y/KrF6YsjjGUMxPCYD6woO6Z5oO08Pp2iKk3OMv5vcv7u4he1oYM6
+      1yFJn39eELwAbdmTh8UieZjMJ19oPWUARb3jW18PRJ2EFtgnbat60Xj/fS3O5fA2IxxDB7G2eZWPf9Jy
+      /L5jKPJSneeVjH/P2cFsn94uWdaDe9J19RRko9yJJmS7iHM4BuJ6tumhaKh1nkfaVuKskIHYnm2RPpKS
+      XgOOg3ib+vemeYIC4ZALAA14qYXMg1138y5Z101CW48EoIB3Q9ZtIMtuf04XSQh0/eC4fkCujCzKAMs2
+      XTdVTU/4jgOM+Y/dnqxTEOAiVkJHBjCVZE8JWOg/DPpVP8iWH55F3qW0UZONgT7ZhiayhaFWHTZrm3OR
+      VPv0x4FUWE+Q7Yo4IRrBET/5IBiYtu3Ero3Xn1EJTG/9esq2dQeK6p6OXmiR3E+mD8nucUuqnwKaoXiq
+      7xYf7mgZiqafykXGah2jIl28QaQLPFJZlRk3gmJhc9uFe4PSAIqGY/LzyLeMjHbxJtG8nGKebQ7CoJtV
+      Q+EnVelPKQddngDPoS+b0et3UNjL6K87KOzVfdO62hEne1ADHqWp4mI0VShCQz2jCIQdd1teOFlqkaCV
+      k6EWCVojshMSoDFYmenjtl/wR0QiNCISzN6+QHv7gtFDF2APXfD6swLrz1LWdh2/7xuSvRDkNtACAWed
+      vpB1knFNf2c0y99Om3/YU84O6wnbQjvbpCcgS0S3EBSAMTg56qCgl5irPdXbKKuN7bXF6l+0Q/J6wrFQ
+      jsk7AY6DfFCeTTk22lF5BmJ5Li5+ISjkt12anL4nxjMR0/iIeB5yyvSQ7br8QJFcfnBpetocGc9ETZsO
+      8TycMmhxuPFjUa2/C663pT07PS9PkOV6f0Up5/LbLk3OyxPjmYh5eUQ8DzlteshyXZ5fECTy2y6d0O6U
+      joAs5FS2ONBITG0TA33kVLdBz8n5xfCvZfxS8Fdy6giL84ysNPPSa/bwebL4nBBarBNhWB4mf0wvyCfV
+      OxjoI0xk2pRnOz0b2olHotJEPa/aczVT3TWy1iANK2kJlrv6qv03dVtrm+pty/nXxTJZ3v8xvUuub2fT
+      u6We1COMwnBDMMoqe8zLJBfikJbrLCKYLRoRs8422W5POaF2hCoYV/49F09v8WMd05iob/JzPVc4MqGG
+      QPCgn1BjwHTQrmYBRF1H3gOGBY6mToyfzmPuNtsQjMLNEQMP+lWBjAmg+WAEZp73dNCuCna2iwjQCkbE
+      oAztg5JgLFX6dlmTqqmsyOLlqgbjRtw7vgWOJtn2P7jl2hLAMdrTn0+z2cck4ERDVHDc7Oc+q/NdVjbJ
+      8zknmiUYjiE7KbtVbBwtGRPrudrX2/hoWgPH4xYJvCSYS444ZpOHIzArN6tW+7qYztsjkElJ4GCgb/z4
+      yIJAF+Gn2pRhW366UstERu/8cAIcx/5AdCigd/x1cXl5PnqHl/bbLq3KxD7Na5rlSHm27mmQftbUVTdE
+      M2Awoly+++3P9+r9HLVZQPv4n3K8K8aDEdQ+LDERLB6MQHiHxaYwW5IWeSp4zpZFzUU+/sV9AEW93NQd
+      TNn200R8j5FLHPQT38LxSdC6ucgZRkmBNkot7GCgT1ZgDJ2kMBtlkzWfBK35BccoKdDGLZt4uWwLFe93
+      n1jQTFru4nK4MdnuuVKJgt5nvWaxZGg70rN2J+fJFkNka8pMA8Z7EWSFcM4oXEcM8qlXjcpNWqs3Xpqs
+      VNNigq6HLGA0mXaHjOHXHG5MVlVVcLUaHnAn5DvQ4wMR6PeMxQbMh/VTWrPdmvbsugJgVOsnzjP2hYZV
+      gbi451d1Nb1V6yjQxrvDDRK2NpR3Vj0QdLLvDxsOuOkZZrGeuV1Qyejp9aDn7FKdU2xNFPA2ybr5SVZq
+      CrRxWvsT5xt1wWD97J60rcnk9vf7OeVFRZuCbJQjb20KtG0OHNvmANuoiWdgoI+y74+DgT5ORmD5QJiX
+      sCnQJni/VGC/VE/CbnhGCbrO5XI++/h1OZUt06EkJqLN4mbS/qYgPOBOVq/J3ewmKkTnGBHp/uN/R0eS
+      jhGRmp9NdCTpQCOR6wiTRK30usJCUW/7xiJh4h3jwxGq1b9kaxcTozWEo1AOe8V4NELOvfwcv2pyrWiS
+      qFVWSucxeXriwxGi8tQwOFH0PkWTr3/Ri7xFYlZiNhocZqRmogliTvJoxUFd7+zuEyM9jxRko6Zjy0Am
+      cvp1kOua39J35vRJzEr9vT2HGcm/2wAB55fp8vP9De/XGyxu5lxvjwLedLN5l9TZc/U925DNJgy7z9X4
+      nTqr5cGwW33K0SoOMLavKIpD3mQrstaEITdxBNQxgGmTFZl6NY/x03sU8ubbLd0oIdBF2YLZwSDfgZ56
+      fj9O/ZV1YyJ3pO6tyH6o2jCb7DThgFtkdZ4WbHuLY37enDDEYxGKVDS0Bb4Yj0Uo5UXEROh5LIJ6myxt
+      DjUzwAmH/cl8+uf9H9MbjvzIImZOFdFxuJEzIPXxsJ86DPXxsH9d502+5t1WriMQiT7v4NEBO3HG22UR
+      s16jWLPELYp44yqCwXpAb9dBH215NGKPq2QG65i+jqA+tYUNSBTianqIBcyMLjnYG9+lzfqJrNIUYON0
+      k+H+MWMQeKQwG/F5twUCTj2Kj7jBHB6LEHETODwWoS/EafFY8aLYjuFI5EfWqASOxdyEL6BA4rTVL2nX
+      WoxHIvDrWDFQx4qI2kkEayfKpgYWhLiojwMtEHJWjLGDggAXbXsCBwN8tI0KHMzxnXY7Jz9ZtEjMGvG0
+      BHGMiETtpiIONBJ11GuRqJU8Asb233c+1AdUcTrWsCIYh1wJ+XjQz5hUhwRoDO4tELoDqD0e5PwB5zMR
+      n6tiTK6KuFwVQ7kqYnNVYLnKm+3GZrpZc9LIfPTt/f0fXx9ULUNese2yqFn+7TGr6X1k0IBG6fomjMkw
+      xIFGEgd6IfFo2L5uata1Kw42Unb+dznESC3HBgcbn1Ihu315zbEeWdhMOarT5WAj9b7rMdgnng7Npnop
+      OdIj65j1KuLp3XI+m5J7Ug6Lmb9FdKYwyZhY1O4UJhkTi7r8BJPgsaidNxvFveQ71GFxM6tjBfDhCIxG
+      GDTgUXK2PXRPUOsGG8W9ImNfrsiaoDcqN8Vgboro3BTB3JzdLafzu8ktK0MNGHLrh8BlU7/SzSc06GVX
+      nq5hMAqr2nQNg1FYFaZrgKJQH4wfIch1fL7Ny1iTBu30h9oGBxo5bQTSOrTpTH/k5MKQm9fmYK1Nu1iR
+      +JDJIhErN+NPKObVW/Sz72jXMBiFdUe7BixKw3yGCwmGYrB/SIM+ydVfUeMCulhRmC2pig3PqEjIymm0
+      4LaK1fNA+hxVmRV5ybiZOxBy0gf/PYb6CEfx+GTISn325sKQm9WH83tvsrRPr9t3o9XbdI2sk2iTNpAA
+      jqFrUvUHjv8Eo276GnCHhc355id3jgY0wFHqrKnz7DmLDAVoBuLRn4CDBjhK+5SH0UEAeCfCgzqPntxH
+      OFGQjVrnHSHX1R41e3d/w6mmPNq1f/3I++U9BxuJmyAYGOp7125vz9R2dMhOPlwjoIDj5KxEyZE0IZew
+      Ewb7BC/PBJZnIirPBJ5n84f7xZS6K4zJIUbGbiUui5jJb1SaYMBJXyvh0SG7iNOLsF8/0thw9S0dtkdd
+      /0kQiEFvizw6YI9InGDKNPVB8K9a04idXoWcOMeodoXiPZe0SMxKrIkNDjNSa2MTBJz61ZG0aWqy9ESG
+      rJzxMyQYikEdP0OCoRjUiT1IAMfgvl7g44N+8rJZWAHEaV/rYRxLhhuAKN3UI6vEGixkpk9a9hjkI7bw
+      HQOYTknPyjyLBuysig+p8yLeAvFx2H+eZLs0LzjuDoW9vCJ1BANObhXo8AMROBWgw4ci0DsgPo74I+o+
+      G0f8crDEqYx6FPHy30QADViUdj6E3gGHBEgMznpihwXMjK4P2OvhdHjgvg59XuNEYTbq5KsJos7tnunc
+      Qq2H4N8DInQPiNjSKYZLp4gonSJYOsmr3Y8Q4iKvdjdBwMlYUd5jnk+/+8h/xxwS4DHIb1M6LGJmvs3t
+      45if3F87cYiR0bPqQcQZ8zYy4ghFUhsWrFO17dsN9W2mgCcUsV11enfYrbKaH8+04NHYhQl+99f5lNfx
+      gxTDcejdP0gxHIe1wD3gGYjI6XYChoEo1PeDAR6JkPMuPseumN4XOnGIUbWSb3CT+5pAvOhb3JU4sRaz
+      3+l17xECXORZ9SMEu3Yc1w5wEUtXiwAeaqnqGNe0vJ9P9VlsnOcbHo3a6TlroahXtxvkDUoAfiDCU5qX
+      USGUYCDGoa7VyShr4msUuGZcPMaWCEFTOCr9kR8kGIyhU4DYuUctA9GqIl+/Jg2/hLuacDzRVHVUJC0I
+      x5DNr3qQQ9wxC5OEYp3H3lvnw/fWeXQZPx9RtmN/yPDv6O/tqArP0gTjZXVdRaRayw9HkMO8ffMUG6e1
+      hKP9pL8zABqGosiGtl2tGhfqpBmIt5dVR950VUhUSMuERiW/mmajqJfcpzFJ1Lo/1PtKqN3an2T3k3vh
+      jgWNppemyMZXMOOc+HCEmHZUDLej+qVmfi1zxMP+iPpSDNaXxsYiETE6w0AUfu114oMRYuphMVgPi+ia
+      UYyoGdV3tkX6GHFftHwwQneXRsToDMEoTb6LCaHwsJ+8BgfggxHaKedkvYqIcnKgkbr+nzpfZ/2dGcly
+      oJH+zuqKGUChoFfNbDPrwCOKe1mDvI5ErUVVfWcN4XsYdDNH7+jI3dhrnVMdmDju57aQA6PMdsgh85Z5
+      5R0ccPP6DicWM3PX+0MCNIb6bczCbeK4X682ighw5Aci6OHeJipIqxiI00+/RsXqNXg89vyeQaP2dmsj
+      bq50dNDOHsLbAjRGW/3F3NmWYjAO+y43DWgUxpNoFx5w8/oOj4P9hqJKVVvUlmZOEtkCMAZvnImNMfVw
+      SraguQqYFlGTZ6gLi3zObud6GHPH1OZiqDYXkbW5GKzNRXxtLsbU5uJtanMxtjYXUbW5GKjNzQ0592nz
+      JJgxLEcgEm/sHB43x4w1w+NMEdXWiYG2TsS2dWK4rRPxbZ0Y09aJ6LZOjGjr4sb8Q+P9mLF4eBwuYtpo
+      EW6jY8f3w2N7xk6sJug4l/OvC/I57j0F2jj1o0WCVvKagh5DffRlmA6LmRlv0Dksaqav8HFY1EyvtR0W
+      NdPvY4cFzdR32k4UZmPNWXu0Y/9zwjgZ5ggBLuJDlD+hfarUH6n98I5xTdP57NO35GEyn3xpT2xiPAjD
+      JIOxmnRF3KUScQxEOk+eKmIBhhWhOKryqxk3ISYJxaIXSJcO2clVtUcP2ekVN6wYjLPPsvoNYh01A/EY
+      lTusGIpD7/rDiqE4kaUZa1msL3EeLUOCUAzG5D7AhyKQq2MHDrnVbANfrughO+MVQ8QxGCmuJj4pBuPk
+      +8go+X5EjCQV6+g4SjIYK64WOykG4+imO89EZKyjZiBebE0mxtRkIr4mE2NqMvUlVTbfINZJMxSPM4DH
+      JEOxyI/uQcNgFPJgA1aE4uhOI2ugi2uceOx3zwLvnOmP6ky/QMjYXtfHIb9OPLbepH07+f0j+A05fe4A
+      vZvaY6CP3Mz2mOPTq6v4Z8b6OOhnzCSZoOdU4dLvxGmPHgN965RhW6egi95HMTjQSO6L9BjoI/Y5jhDi
+      IvctTBB20p/lBJ7gxO1/MrT3Sfc5o3mzSNBKb2IMzjUSN6n296eWfzktKyc3sS4MuFlOwMV8Hxl9D5mx
+      /wy49wz1PWb//WVdQ9AnVXrM8cn/2hjnyqTyX4zzaVALEo2zQMlhXTM1RYC00PMn6aF5quQY/ZXzeA40
+      hKPI6oQ6fw8awlEYeQoaoCjMN97Db7q382ZVM9k2nDw4koj1Y7alvl1lo5C33Y0jWeWNaBiXbOGQn/1q
+      7tBb9xE7QwV3hWo/7HYR4ZZzm4ciNCuhLiEtHun2noXMh3zDKNOK8m2ciSt0Xyz9QbUWe7pOUb4tMbZd
+      pTpNFjAfV4joZUJpnaVkv2cYikI9qAsSjIiRZOVzdBwlGYpFPiENNIyJEv+TjpZAtGNPOiabDAcQifOe
+      C/7eX9TbfgPv+HF2OoF3OInY2SS4o0nETibBHUxidy4Z3rGEv1NJaIcS7s4k+I4kp63yNtlGt3MHkT5m
+      HLmjwOLoHSfpU78AD0TgnuD9GDy9W33KT5pQinA7mYE+Jr+LGeph6jWWRVaSnR0HGel7z6F7Lz7G7B7z
+      GN41Jm5Px6H9HKP2chzYx5G7hyO+f6PacIZdaHeBUrvjF9sdXm53anomSTf/ojlPmOPzZhjIs1qgAY6i
+      8pPrP7IBM/kAKBcecJOPg4IEbgxaQ+qtdZD1Rr6hPw/pMdBHfh7SY45Pv1ZyfKOB3vH2cdQf4Ua9/EuG
+      r5a6VMRfHaKGmzKl6du7mqDj3Ke1yJJtXe2S1WG7JdaCHu3a2x169DQ6TWyAsLPInrPiOJO0yTh2RxGK
+      oz5n9H0RBxxJf27so8SJ5DoGI9GXfSKOoUg/DmmRb3PZDMdF6z1wRLUbFH0G24UDbn0VOkfZEXrFUBzW
+      shzUMhTtIBvxNwppqQJx21uDfWe5DjcSuaoE60jODtjI7tfcQwfx8wZZe2kj+2h38+aMR3QW6Vi7tSd6
+      kTNJaoKOs13Zxum5WyRiZfTcbRTy9sOmtHis6HKbD0d4TotDFhNCC/wYrNlAfK8bETHHIYJzHII7GyHw
+      2QjBno0QgdkI5r716J71UTvPDuw4G7UX/sA++Nw98PH978l73wP73rP2vEf2u+/vrs2BOBC2UdRLb+8c
+      1jUb2UUevLtwyE0evnv0kJ08gAcNXpT9vqrVXkunuVxiDI93IrBmfJD5nuOfqV0Zg3ONVXI8koFm7DnX
+      qBeS0rsKBucYGeslwZWSjHePwTeOj+8JU7fJMjjc2O3rKRp5Mz9y9ZbEjpU2vJP0TA43Mp63AXjYT3zu
+      BuBhP/H0PAD3/Myz4GzSs3LOAjMw1MfLxOApYM7n9CwMngBmfk4eiHqw7X5+z1n/3lOejbca0wI9J+O5
+      eU9hNkYx8OCQm1gIPDjk5jxDhw1oFHJBc9nenF7kye/Tu+l8cpvcTb5Mx1pdzjbOHiQ8ny4WFN0JQlzJ
+      3TVLJznDuMqTJpOt/SrdJIfyRa1lbbKd7Eil9ej2OSgJx3qpq/JRdhAec0EYXA6bgKjrolrJUVhSn78j
+      xzHYoPk8wnweNF9EmC+C5vcR5vdB8y8R5l+C5ssI82XIfMUXX4W8v/G9v4W86U++OP0ZMq/2fPNqHzRH
+      XPMqeM3rCPM6aN7kfPMmD5ojrnkTvGYRcc0idM0/dzt+FargsPs8xn0+4I668POhK4+79KFrv4iyXwzY
+      30fZ3w/Yf4my/zJgv4yyX4btUck+kOpRiT6Q5lFJPpDiUQk+kN4fYtwfwu5fY9y/ht1XMe6rsPu3GDfU
+      g9ADbdltbndL2uR1tm6Oq2fJsUIyILbecSIuoq8A4jR1ulPPtsuM7O9RwNuNOOqsOdQlWW3RuF006fhJ
+      TRAOuas9X12ZvbtMnF9cPa53In9O5D+S76PXOgBo0Jtk5Tr5eR6h7wxIlE22Zrklhxiz9UqHXBXV+CVb
+      uAGLIj/ficfk5y+8ECd8yH8V579C/N83W5ZYcpbx4vIDtxy6aNBLL4eIAYlCK4cWhxi55RAxYFE45RDC
+      h/xXcf4rxE8rhxZnGZN1U+v2ibAKwcFs39NLsl6t1Q+oX/cNRWmTvrWp318cP23zVlD1gMKLI0sm48o7
+      yrN1ZZFhNEjfyjMitnZPrTZRiMXAp0H7Mcl5doO27WXFL20uC5kjSxwqAWIxSp3JAUZumuDpEVFOIB6J
+      wCwrEG9F6CrAJ72H1wfSsYwwjduj5ENu2dF/fR7/hArjoQjdR8lTVZeE5xsIb0Uo80R+iVHMbRBy0gu6
+      DRpOUZ4nmypJN6P37zIQx6OacMpqdAsCXKQyZUKAq85IByO7HGAU6TNdpyDH9ZjJkpMW+d/ZRi8+aqpk
+      /HHyuMGLoo4PqfJ1JquMQo7Lx58YifFAhG2eFZtk39DdJ9Kx5k22S9bVbiX/Qi9cHu3Y62yrHzCrm03P
+      kOiRNOW0wAENFk9V21WZ8aJ0sOMWkTksBnO4ed13i6WTVMiqLy8pz4RRgxPl0KyZ94FF9tZVlh2SXbWR
+      VYNaO6suoKZsGIbxRoS86ubWhOzsUE9khWnbvt0k4qk6FHpeavyTfwC1vWonPVle1cJMlWzdBag/pZsN
+      6ReETXZU9SE9jXrKt6k15/K/qboOM3xlkqqtfQ4rWW2UoiGVE4C1zZtN8lLV4/cGMhnLtK72r2RVD1mu
+      jezGcH6rxVnG7Ode5jtB1QKWY5s3Qt5w5B9pcbZRvbm5q8rmsdplhFvII0PWROzSouC7W96K8Jg2T1l9
+      SXB2hGWRSVKn5WNGTlAbtJ1C7TqmGw6y1UFdb50VaZM/Z8WrWqtPKpcAbdn/la6rVU4QtoDlKNY71j1j
+      cbYxEyJpntLSLAxzihoUIDGo2eWQlnWXF4VeriI7WaQuO8QGzLKnQDo7DxU4Mcpc3nLJS74Zv0m7y9nG
+      atOexMwoHx4Lmqm5Z3GeUVa+ySqV3ZoL9iVDCjCOKprkKtKHPXfXM3vX3u78MKgHi8hOMo9HI1DrP49F
+      zSJb11kTFcBUeHEK8ZRv1bHTzDTyeCRCZICAf3coYhp3TOHF4fY3PRY0c+qLE+cZD+cf2NdqsY5Z3mrl
+      O5JPE7ZFJjarhjQ5z6gmENJfiLoWgl1XHNcV4GLkgsl5RpWmRJlCQA+j4+qinpd8Ax4Zz8QpIX7pqGSZ
+      KfXLw6rbWa2e8+ogZK9TZti+ErLHQYgw6LIjl3qegzWe8VjLvK9eaLnWApajVuN+3njDRX1v1+bo71DF
+      Jmubs81hncmkWZOcPYXZ1ABqX6Rc7Ql3/CL/m5G2Bmb7upaWLDQ5wHhMb/0PsteiITvvcoGrFeu0aWil
+      /ojYHj1xSr4uE3N8DXuE4rGeWTRyPLRmXK2Nel6OEDD9qK9+JnqGuEwplb4Nuk56a95DsOuK47oCXPTW
+      3OI8I7W1PDGeiZyjR8Y1/WRn6U80Txk9XLh3a7WJ5NQDaMt+4E4KHPAZgQN34HDARw0v5OnbF2/+tlJv
+      0wuh9gbcq+Ojiq1+JDbaifB9hPVFnkwWd+fJx9kyWSyVYKwcQAHv7G45/X06J0s7DjDef/zv6fWSLGwx
+      w7da6aGKmuEsR69ytCnfdliLi2SVUXUdBvia7XuWsONA4xXDdmWb1KNm9deEsB+yy5lGfdYaOS9MyreR
+      88LCAB85L2wONF4xbGZePKXyfxd6u77X8/fvLpNqT8gRkA7ZRTa+vYFpw66W0FR6Pc26UOPCrFTLjEbX
+      mBjfR9iom//6Wr0MfjNdXM9nD8vZ/d1YP0w7dl7duQnVnf2HXx642iMJWe/vb6eTO7qz5QDj9O7rl+l8
+      spzekKU9Cni7jQZm/zu9Wc7G71GA8XgEZipbNGCfTS6Z5hMJWWkt6gZtUU+f3H29vSXrFAS4aK3zBmud
+      +w+ul1P23WXCgPtB/n05+XhLL1knMmRlXrTDAxEW039+nd5dT5PJ3Tey3oRB95KpXSLG5YdzZkqcSMjK
+      qRCQWmD57YHhkhDg+no3+3M6X7DrFIeHIiyvWT++40Djpyvu5Z5QwPvnbDHj3wcW7di/Lj9LcPlNVmqf
+      7rtGmhQAEmAx/ph+m93w7Bp1vIememgPT/pj/Dp1n7StHyeL2XVyfX8nk2si6w9Saniw7b6ezpezT7Nr
+      2Uo/3N/OrmdTkh3AHf/8NrmZLZbJwz31yh3U9t583qd1uhMU4ZGBTQlhaZzLOcbZXLZ39/Nv9JvDQV3v
+      4uF28m05/WtJc54wz9clLlHXUZiNtOkUgDrexYR3S1lgwEnOeBcOucdvww2xvvmwKvI1IyGOnGcknkto
+      U5iNkaQGiVrJidmDvnMx+51qk4jnYVRDR8h2Ta8ZV3WCXNeDipA1hNMVXM4zsm5Ck8ON1PLisgEzrcw4
+      qOtl3CwnCHHRfzp6p/QfUX80dp9Mb2YPk/nyG7VCNznH+NdyenczvVG9p+TrYvI7zevRtp2z6+EG3fXQ
+      /WTBVTp9l9li8VUSzPbXp2373XS5uJ48TJPFwx+Ta4rZJnHrjCudOc775Ux2IKefSL4jZLvul5+nc2q2
+      nyDb9fDH9WL8PlU9AVmot3dPgTbajX2CfNevVM+vgIPz436Ff9sVvzEA8LCfnohXgVZBf64mdv7UtZIa
+      c5L1Nj7oZ6WQrxiOw0gpzwBFYV0/csWca/SuSo1dv5Gz7kRBtn9+ndzyjEfSsc7v//qmB9xtyuq2cEF8
+      5IFKoFjt1dD1LecYyR0nqNfE6zJh/SVWZwnpKfF6x1jfOKIyDNWD7CowUPtxBqTIaHTOHenP8ZH+PGak
+      Pw+P9OcRI/15cKQ/Z4705+hI3/yEkwwmGzDTE8FAPW/ysFgkciAx+bIgag0SsJLrojky4zFnz3jMAzMe
+      c+6Mxxyf8fi6kD1d3XWmCHvKtqn95yke9X3fkExuf7+fUz0thdkWPN0C8i2X89nHr8spXXkkIevXv+i+
+      r38BJt2Kc3RHEHLKXgHdJyHINb+lq+a3sIncr7ZAxEm8Z00OMdLuVwMDfKwOnk2GrAu+FrpbqGPvE4S4
+      kundcv6NZWxRwEuv+A0M8BFOuTIZ2MQr4UcQcXJKeMchRkYJbzHQ9+f9H7SFRSYHGInT50cGMP05odde
+      kgFMnDyA05+R9la6izTRe8DssvEvSViQ7dKHcSd7+pMGgO3N2Tr5/VP3InO6Gb1g0MFg32ZVcHwSg33b
+      rMh23XHnr834I5JDjlCk3aHgh5BwyC1+1Hy3hEPupopNn6MBjvJYV4d9Iv+cjz81EuNDESg7N8B0yK43
+      lzrU43dMCyjgOOoKkn2dqdclOUFMHo7ALKFo2VRLf9WuCUypZkPmZv3EV0sYd0cks4EH/HrkHPcTTIcX
+      Sd4MjTr3cl1tMvUmX5HWaj8a6k2Mabx4It/tC30wbPIzWVdVvcnLtKHmPGLBokXW4IglHI1ZG4IOLFJE
+      jQgYwlEemfUWLAnHYtTAHh+OIN7i14ihX6P3BmH+kpZFzSJJVU2tcq55ZUawHIFIVRmTVoYAi6G3P9S7
+      svFC9Hw4Ar9c9Xw4gioS8q6NyxhQFYwrkuzHIS0iwnUGK0q6Vf/V7fqVluQYIA9FaN/6pptbDjLKhDuG
+      pWsN2HZTh1UmY5lW+WN50PW7rugJPodErG0LzNK2qOWNaKyDLbTq+hyaLHm5m3yiOA3M8rWNJm04eWIA
+      E7W8GxRgY3U/gn2O9sMyeyQLJQOZZD2ttupNdqn4TneaNGAn3+QmBvkOK7rssAJMqpulyz/ZdyIRKyu3
+      wV6f6jmZN5LaNZiqRx2Dkcj1CS6xY+l+VJm9UNRHxjI9peJJpZzuZyT791e/JD93ar/f9PL8IhHi5ZBs
+      6nTbvPuVEGq8FLyWbhzkcvzrCAuta2BOAqBj/1MjLi+jbSYJVh8ecJMHvJjCirP/nr1S2+8TY5t0D01X
+      y4dSpVWdCZFR2h3EAETRO3dR7z8XDXqpcy8gPxSBlp+wIByDXtoxxUAcPZ8SFUYbxkSJTzh09uc4yiC2
+      yiYG+prjDdjX/oLhhzRAPEYra4O2s81/RqpYoOVUu61Vunuke0fkWxnkrQhdTtM6vj0EuXQnlno8AIJD
+      flZn2GNRM30zQFQAxcjL53dRMRwBGEOQTt/wQMhp78BKV9s8FIE2GOkhyNXu/UfXtRxkJN/WFgcaSYOQ
+      HoJcjKrMIRFrTJYju2MiX1AFm19roCo7bjsvJtJtN3VFCeSytrmdD4u/yUOeQMQ3ScpxRvMq1JN6IUex
+      yUvePKl2Zp0l26pOvpfVS5mkpXjJatKmZQSleR3tU6S/Ly4/JOnzz4vTXpCEkRKqQOJQd/oFYcRNqgpt
+      DjHKflDcFZuCQAy1Z2FUjKMAidF2wEjdFYgespPHqQFJMNamkn3smDitAIlxLMOXrAAnesD+a5Qdu7+i
+      ShJQijYXl5fnvzEm4l3Qd9InB1ywd6oNzR71pI2shcb6LAhy6S3S/n9rZ7DjKA5F0f38yeymqGnVrEez
+      aamlkVKt2SICTgVVAjQm6VR//dgkAZ79HuE+alcqOMfEwcTYcI3beozz+VUzcZ2nOJu11jzjuh4LfO54
+      O7jm7hDnwmtuxDgfXHMDxdnwmhsx6utH78CKuzOMCa62kWJsaKUNEOOCq2ykRluZZCuyBXk6sOuy9RiU
+      8YIpciHHGLHktwBjfFgyToBNfbk2pZFBGS9ck7lYk8WqM6p4cEYV+noo5uqhUKZVxiRnxdIqQ44xalpU
+      MdeiilVplRIvl6CsZSGtctgOp1XGJGdFW0cx1zrQtEoCMS70mlVI16xCn1bJwowbTquMyTmr8qDFtMph
+      D01aJQuz7u9K7XfBCKdVxiRn1VwQhKsAklZJIMalTKuUeK4ELK0y5FgjmlbJoIxXlVbJ04F9TVqlKJDK
+      gNIqGZR61bmSLEzdK3IlBTzw63IlGZR60VzJKcObkPe/Qi4w6nIlGTT0wrmSARb5wFwrSkk26B1TBg28
+      mrSJCJxxwl+8nDYRb17+KiDHxmY0bSLkIiP4si2lJJuiStmUhWAbXJlcysJ9E/AK6gSJPIrLUJwr6f8N
+      50oSKHThuZIhFxlVjZDPlQy3oOeLnCsZbcXOGTFX8rpR0ViYXEnyb/yjiy1FkysZcoFRkSsZcoFRnSvJ
+      09SuyZUMOdn4qlUGfRd9riRPU7suVzImZetXrfRr4ERzJQlEXXCuJIGoC8uVHAnOgjZvLldy8n+sYTO5
+      kvd/v6CeF8ah+XAv/GebJDd+rXa1xswoHpeDV2hsmC1l5Sd5+CnWfYKHR1+VxdpPcFM8LmfdJ7kamFJ0
+      mZ8C/tCvqq25zE9pJ0VtzWR+jvuojl84Ys0xRkcFZ35SirOhmZ8xGVjXZn7OSriysMzPkAuMcKeW69Hq
+      urNSX1bVkRV6sbo7F+m+ZcWlfe6qrr6gz1zLNYMFwkjBRjsKs5FHYTZrRmE286MwmxWjMJvZUZiNchRm
+      I47CaDM/OXbGjFcCm/l526jI/IxJxgpfizbCaNRGPRq1mRmN2mhHozbyaBSe+UkpakMyP+/7xwYs85NS
+      ku1Vp3vlfGjmZ0xy1uUhnVOGMaGZnxHIOYHMTwJxrs03XLX5xpvgfrWQ+Uk2gW2Wz/wkW7D2ymZ+kg3d
+      1qqEjmOMqi6jlCIab3vVa7n2h460MCmi5N9YiiiDMl78p4RNER02ACmiU4Y36dpMnCJKNmnaTJQiSrYo
+      2kyYIjrZAKWIhhxjBCdL4hTR4b9AiuiUYUya74Cvf0Xds/WuuU5F16jWqC98Acp7/Vmj9N5Q3qt0Br7a
+      TwzhnX6CTX1W/xSknXsKMtqYgg+rCQKmDPiZQis+U2jXPLdn55/b63TPGHbSM4Zn/fO757nnd8/Kuauz
+      OHd11s5dnaW5q/e/67as3tze7mbm9Ufbff+5+FrHsfPmb6ZaI3f4xP9vYyq/2WS2rl47v/c/WZctLkDg
+      pRL+yw6n5W8Bc+y8GakbHh/9B3M2h/49uaouFr8CR6nQ5v7U6AZs9B2LP9Ptoc7f08LVt3810SxOXuDY
+      qfnLbWtmjyo7z48l1NeFKtHfjQAbfc17bp+StOxMm3VlXdk0y3PTdBnw6uKcIyrJvxb3tvxUo1Rka7Ym
+      NVXefjRYjKOAU/9Luj1VBVYPdyY0NVlrTbo3GXA2xCS1/tUff2H640ekBJw4j9uufjdVai7NkzsPXctZ
+      bI1RyZsfSlN1/TeKx30sUEnlutPHn5/G764rbmqQS+nSff9Su3+P3V3StUUFGqm80tqTaT+lNlmVVG7r
+      zkddMZ6UrD4cQGf1pGQ9VSvO5RvMuxN9K0nSWe+ntZIEaSXJ6laSLGglyee0kmRpK0k+r5UkSCtJ1K0k
+      mWklibqVJDOtJFnTShKmldSup/GR5lm+N9c+WAH0jXlasrfG6MQOFJzWdCql42RjesyaBjnZBT4qoe8o
+      Kqph4HgjEMAZYJHPd8D71F/cOUV5r+KTDxxvPCLxehFInB/p5geyMsYEGT0+7M1f595dQ+tTiran3c74
+      O0bXffXd7MXN9rFpUqpmzaCWXzOoHdf9uSYPAr8vHEvN7s/Mhx+AfWEG5b3Ndeo+7Vz1WVd7R00JkYQv
+      qw9IarOfmiLurGT+ZXTWX4Ya4VQUAhHXr/Tpj+TP9C3r9qb90uczAVKG5uw+3UhnvpOctXLfYdKaQqkm
+      OOd32xK/k9JPcM5v86zr9JVOcNb/o9Wqb+RotUmpGiMOOcaoGSNm4Yl7nz2ph5hYmLh9DNIKO4cTv0+P
+      XuHn8Inf/duYBlrXY8oEpoNZvvLAADCOtOla2OMh6jo1iOTUEHoH9L9vu1Me6Ajddid8WVlgYZoBoA6b
+      2rrtDPJBBoaYgK7ide+QTqvT4YApeoR6luf/X/cmdFMj54PbO6TR7/SOsB53r6ZQOYraTsuXlbrtTnjg
+      3uq6d0j3dwO7U5VjmgGjvn25g47H708NNdRm/O6EP/v5E0DQ708MSCLwbfeR7/xX3N9jL1/dY8qMpvP9
+      RxGfyWRQ6tXMZIacbHzVKl9lJ9DYGHTifU4z33MuF19RR4JaDh1iOHSE3uZ1ZQG+358Ycndrixj6/amh
+      Pfi02gJYbIhSkQ24uo9EZGn7eVBQdIVCV4FZ6DfsOiWuv+X+DUgGhpjMpUvfT4DmChCH++2we2M78ICm
+      GPGVRQNo3N6UrnY1grvdA35fbn0mYvUBHcYEIz7fQE82e0PO5IEhpio7+uUQKtu1mV+yDRCGKPXatMy+
+      pIfSIteNCRXYcqBvOQDEUee28XPL7gxBvoMpFvuquh9bQn03jPiavAQ0bm9K34Z7Vd9kDHPu2wCyQnwn
+      idWCjcpGrcrCv2w2+mWrm3anmIwLOda4ahrukYctUTMBJ+Csf9VU2CMPWyIyCRZgrA+Z/gow1gdOfMXk
+      xNpkxqb5Nr8/VbJYGoKRs2ufk+FZlX50xYJyxhCWAo6fEyh0qWpA+PT+7u1WDNQuOJhz32tF5Z7Ao/ui
+      jCS/iInkty1vBonIJxDn8m23b7roohIzCq6c5ql58utONAlewMjOmp9XmJ9Z83O/yp+fflVU+JTm7Ne1
+      OHxmN+4e2XkztISbKHhQhj1mB3jJ+8cmttTl6+oQiHN1NfTTF4GRE54Uu4grBdy22Bxc7SjkJkb/BkJR
+      vvkbq36WMDu81W3Z7Rff/8oGvpSzacvdB/RUpoAH/qb1i2P0M4rWplhWmigIyuinnLtLf22wmJ2ijNcX
+      6q8M3QX2jij1+vGapEzLBvlpCLjIeL2mu+L25gJKp2jkvT7PYi6dqWwJDCoJeOR3ZcKLZjFo5D3U9bt1
+      N7bvJi3cXa6/dwb1jCEq5XpLDlxIKfb7b/8D3Dbq90mgBAA=
     EOF
 
     # We are renaming openssl to openssl_grpc so that there is no conflict with openssl if it exists
index 88dcc20..94deeef 100644 (file)
@@ -66,7 +66,7 @@
  * The value of this property is nil until all response headers are received, and will change before
  * any of -writeValue: or -writesFinishedWithError: are sent to the writeable.
  */
-@property(atomic, readonly) NSDictionary *responseHeaders;
+@property(atomic, copy, readonly) NSDictionary *responseHeaders;
 
 /**
  * Same as responseHeaders, but populated with the HTTP trailers received from the server before the
@@ -75,7 +75,7 @@
  * The value of this property is nil until all response trailers are received, and will change
  * before -writesFinishedWithError: is sent to the writeable.
  */
-@property(atomic, readonly) NSDictionary *responseTrailers;
+@property(atomic, copy, readonly) NSDictionary *responseTrailers;
 
 /**
  * The request writer has to write NSData objects into the provided Writeable. The server will
index 0b028e9..c33f3a6 100644 (file)
@@ -48,8 +48,8 @@ static NSString *const kBearerPrefix = @"Bearer ";
 
 @interface GRPCCall () <GRXWriteable>
 // Make them read-write.
-@property(atomic, strong) NSDictionary *responseHeaders;
-@property(atomic, strong) NSDictionary *responseTrailers;
+@property(atomic, copy) NSDictionary *responseHeaders;
+@property(atomic, copy) NSDictionary *responseTrailers;
 
 - (void)receiveNextMessages:(NSUInteger)numberOfMessages;
 
index 92f52e6..b42fd6e 100644 (file)
@@ -225,10 +225,13 @@ static const NSTimeInterval kDefaultChannelDestroyDelay = 30;
     return nil;
   }
 
-  // remove trailing slash of hostname
-  NSURL *hostURL = [NSURL URLWithString:[@"https://" stringByAppendingString:host]];
-  if (hostURL.host && hostURL.port == nil) {
-    host = [hostURL.host stringByAppendingString:@":443"];
+  // remove trailing slash of hostname if a supported scheme is not provided
+  if (![host hasPrefix:@"dns:"] && ![host hasPrefix:@"unix:"] && ![host hasPrefix:@"ipv4:"] &&
+      ![host hasPrefix:@"ipv6:"]) {
+    NSURL *hostURL = [NSURL URLWithString:[@"https://" stringByAppendingString:host]];
+    if (hostURL.host && hostURL.port == nil) {
+      host = [hostURL.host stringByAppendingString:@":443"];
+    }
   }
 
   GRPCPooledChannel *pooledChannel = nil;
index 9b20513..07d3125 100644 (file)
@@ -56,9 +56,12 @@ static NSMutableDictionary *gHostCache;
   // scheme and without port, we'll use port 443. If it has a scheme, we pass it untouched to the C
   // gRPC library.
   // TODO(jcanizales): Add unit tests for the types of addresses we want to let pass untouched.
-  NSURL *hostURL = [NSURL URLWithString:[@"https://" stringByAppendingString:address]];
-  if (hostURL.host && hostURL.port == nil) {
-    address = [hostURL.host stringByAppendingString:@":443"];
+  if (![address hasPrefix:@"dns:"] && ![address hasPrefix:@"unix:"] &&
+      ![address hasPrefix:@"ipv4:"] && ![address hasPrefix:@"ipv6:"]) {
+    NSURL *hostURL = [NSURL URLWithString:[@"https://" stringByAppendingString:address]];
+    if (hostURL.host && hostURL.port == nil) {
+      address = [hostURL.host stringByAppendingString:@":443"];
+    }
   }
 
   // Look up the GRPCHost in the cache.
index e6522d7..b718a52 100644 (file)
@@ -18,6 +18,7 @@
 
 #import "GRPCSecureChannelFactory.h"
 
+#import <GRPCClient/GRPCTypes.h>
 #include <grpc/grpc_security.h>
 
 #import "ChannelArgsUtil.h"
 
 @implementation GRPCSecureChannelFactory {
   grpc_channel_credentials *_channelCreds;
+  NSString *_sslRootPathStr;
 }
 
 + (instancetype)factoryWithPEMRootCertificates:(NSString *)rootCerts
                                     privateKey:(NSString *)privateKey
                                      certChain:(NSString *)certChain
-                                         error:(NSError **)errorPtr {
+                                         error:(NSError *__autoreleasing *)errorPtr {
   return [[self alloc] initWithPEMRootCerts:rootCerts
                                  privateKey:privateKey
                                   certChain:certChain
@@ -51,7 +53,7 @@
 - (instancetype)initWithPEMRootCerts:(NSString *)rootCerts
                           privateKey:(NSString *)privateKey
                            certChain:(NSString *)certChain
-                               error:(NSError **)errorPtr {
+                               error:(NSError *__autoreleasing *)errorPtr {
   static dispatch_once_t loading;
   dispatch_once(&loading, ^{
     NSString *rootsPEM = @"roots";
     NSBundle *bundle = [NSBundle bundleForClass:[self class]];
     NSBundle *resourceBundle = [NSBundle
         bundleWithURL:[[bundle resourceURL] URLByAppendingPathComponent:resourceBundlePath]];
-    NSString *path = [resourceBundle pathForResource:rootsPEM ofType:@"pem"];
-    setenv("GRPC_DEFAULT_SSL_ROOTS_FILE_PATH", [path cStringUsingEncoding:NSUTF8StringEncoding], 1);
+    _sslRootPathStr = [resourceBundle pathForResource:rootsPEM ofType:@"pem"];
+    const char *utf8Str = [_sslRootPathStr cStringUsingEncoding:NSUTF8StringEncoding];
+    if (utf8Str != NULL) {
+      setenv("GRPC_DEFAULT_SSL_ROOTS_FILE_PATH", utf8Str, 1);
+    } else {
+      if (errorPtr) {
+        *errorPtr = [NSError
+            errorWithDomain:kGRPCErrorDomain
+                       code:GRPCErrorCodeInternal
+                   userInfo:@{
+                     NSLocalizedDescriptionKey : @"Failed to set default ssl root file path."
+                   }];
+      }
+    }
   });
 
   NSData *rootsASCII = nil;
index 7d7e77f..cf3b036 100644 (file)
       __weak typeof(self) weakSelf = self;
       _handler = ^{
         __strong typeof(self) strongSelf = weakSelf;
-        NSDictionary *metadata =
-            [NSDictionary grpc_dictionaryFromMetadataArray:strongSelf->_headers];
-        handler(metadata);
+        if (strongSelf) {
+          NSDictionary *metadata =
+              [NSDictionary grpc_dictionaryFromMetadataArray:strongSelf->_headers];
+          handler(metadata);
+        }
       };
     }
   }
       __weak typeof(self) weakSelf = self;
       _handler = ^{
         __strong typeof(self) strongSelf = weakSelf;
-        handler(strongSelf->_receivedMessage);
+        if (strongSelf) {
+          handler(strongSelf->_receivedMessage);
+        }
       };
     }
   }
index 80279a0..7ad58e1 100644 (file)
@@ -22,4 +22,4 @@
 // instead. This file can be regenerated from the template by running
 // `tools/buildgen/generate_projects.sh`.
 
-#define GRPC_OBJC_VERSION_STRING @"1.40.0"
+#define GRPC_OBJC_VERSION_STRING @"1.41.0"
index bae94ef..34abc04 100644 (file)
 
 #import "InteropTestsBlockCallbacks.h"
 
-#define TEST_TIMEOUT 32
-#define STREAMING_CALL_TEST_TIMEOUT 64
+#define TEST_TIMEOUT 64
+
+#define SMALL_PAYLOAD_SIZE 10
+#define LARGE_REQUEST_PAYLOAD_SIZE 271828
+#define LARGE_RESPONSE_PAYLOAD_SIZE 314159
 
 static const int kTestRetries = 3;
 extern const char *kCFStreamVarName;
@@ -579,8 +582,8 @@ static dispatch_once_t initGlobalInterceptorFactory;
 
   RMTSimpleRequest *request = [RMTSimpleRequest message];
   request.responseType = RMTPayloadType_Compressable;
-  request.responseSize = 314159;
-  request.payload.body = [NSMutableData dataWithLength:271828];
+  request.responseSize = LARGE_RESPONSE_PAYLOAD_SIZE;
+  request.payload.body = [NSMutableData dataWithLength:LARGE_REQUEST_PAYLOAD_SIZE];
 
   [_service unaryCallWithRequest:request
                          handler:^(RMTSimpleResponse *response, NSError *error) {
@@ -588,7 +591,8 @@ static dispatch_once_t initGlobalInterceptorFactory;
 
                            RMTSimpleResponse *expectedResponse = [RMTSimpleResponse message];
                            expectedResponse.payload.type = RMTPayloadType_Compressable;
-                           expectedResponse.payload.body = [NSMutableData dataWithLength:314159];
+                           expectedResponse.payload.body =
+                               [NSMutableData dataWithLength:LARGE_RESPONSE_PAYLOAD_SIZE];
                            XCTAssertEqualObjects(response, expectedResponse);
 
                            [expectation fulfill];
@@ -607,8 +611,8 @@ static dispatch_once_t initGlobalInterceptorFactory;
 
   RMTSimpleRequest *request = [RMTSimpleRequest message];
   request.responseType = RMTPayloadType_Compressable;
-  request.responseSize = 314159;
-  request.payload.body = [NSMutableData dataWithLength:271828];
+  request.responseSize = LARGE_RESPONSE_PAYLOAD_SIZE;
+  request.payload.body = [NSMutableData dataWithLength:LARGE_REQUEST_PAYLOAD_SIZE];
 
   GRPCMutableCallOptions *options = [[GRPCMutableCallOptions alloc] init];
   // For backwards compatibility
@@ -628,7 +632,7 @@ static dispatch_once_t initGlobalInterceptorFactory;
         XCTAssertNil(error, @"Unexpected error: %@", error);
         RMTSimpleResponse *expectedResponse = [RMTSimpleResponse message];
         expectedResponse.payload.type = RMTPayloadType_Compressable;
-        expectedResponse.payload.body = [NSMutableData dataWithLength:314159];
+        expectedResponse.payload.body = [NSMutableData dataWithLength:LARGE_RESPONSE_PAYLOAD_SIZE];
         XCTAssertEqualObjects(response, expectedResponse);
         XCTAssertEqualObjects(handler.responseHeaders[@"x-grpc-test-echo-initial"], @"test-header");
         XCTAssertEqualObjects(handler.responseTrailers[@"x-grpc-test-echo-trailing-bin"],
@@ -641,7 +645,7 @@ static dispatch_once_t initGlobalInterceptorFactory;
         XCTAssertNil(error, @"Unexpected error: %@", error);
         RMTSimpleResponse *expectedResponse = [RMTSimpleResponse message];
         expectedResponse.payload.type = RMTPayloadType_Compressable;
-        expectedResponse.payload.body = [NSMutableData dataWithLength:314159];
+        expectedResponse.payload.body = [NSMutableData dataWithLength:LARGE_RESPONSE_PAYLOAD_SIZE];
         XCTAssertEqualObjects(response, expectedResponse);
         XCTAssertEqualObjects(handlerMainQueue.responseHeaders[@"x-grpc-test-echo-initial"],
                               @"test-header");
@@ -666,8 +670,8 @@ static dispatch_once_t initGlobalInterceptorFactory;
 
   RMTSimpleRequest *request = [RMTSimpleRequest message];
   request.responseType = RMTPayloadType_Compressable;
-  request.responseSize = 314159;
-  request.payload.body = [NSMutableData dataWithLength:271828];
+  request.responseSize = LARGE_RESPONSE_PAYLOAD_SIZE;
+  request.payload.body = [NSMutableData dataWithLength:LARGE_REQUEST_PAYLOAD_SIZE];
 
   GRPCMutableCallOptions *options = [[GRPCMutableCallOptions alloc] init];
   // For backwards compatibility
@@ -686,7 +690,7 @@ static dispatch_once_t initGlobalInterceptorFactory;
                                        [RMTSimpleResponse message];
                                    expectedResponse.payload.type = RMTPayloadType_Compressable;
                                    expectedResponse.payload.body =
-                                       [NSMutableData dataWithLength:314159];
+                                       [NSMutableData dataWithLength:LARGE_RESPONSE_PAYLOAD_SIZE];
                                    XCTAssertEqualObjects(message, expectedResponse);
 
                                    [expectReceive fulfill];
@@ -712,8 +716,8 @@ static dispatch_once_t initGlobalInterceptorFactory;
 
     RMTSimpleRequest *request = [RMTSimpleRequest message];
     request.responseType = RMTPayloadType_Compressable;
-    request.responseSize = 314159;
-    request.payload.body = [NSMutableData dataWithLength:271828];
+    request.responseSize = SMALL_PAYLOAD_SIZE;
+    request.payload.body = [NSMutableData dataWithLength:SMALL_PAYLOAD_SIZE];
     if (i % 3 == 0) {
       request.responseStatus.code = GRPC_STATUS_UNAVAILABLE;
     } else if (i % 7 == 0) {
@@ -735,7 +739,7 @@ static dispatch_once_t initGlobalInterceptorFactory;
                                          [RMTSimpleResponse message];
                                      expectedResponse.payload.type = RMTPayloadType_Compressable;
                                      expectedResponse.payload.body =
-                                         [NSMutableData dataWithLength:314159];
+                                         [NSMutableData dataWithLength:SMALL_PAYLOAD_SIZE];
                                      XCTAssertEqualObjects(message, expectedResponse);
                                    }
                                  }
@@ -750,7 +754,8 @@ static dispatch_once_t initGlobalInterceptorFactory;
     GRPCUnaryProtoCall *call = calls[i];
     [call start];
   }
-  [self waitForExpectationsWithTimeout:STREAMING_CALL_TEST_TIMEOUT handler:nil];
+
+  [self waitForExpectations:completeExpectations timeout:TEST_TIMEOUT];
 }
 
 - (void)concurrentRPCsWithErrors {
@@ -762,8 +767,8 @@ static dispatch_once_t initGlobalInterceptorFactory;
   for (int i = 0; i < kNumRpcs; ++i) {
     RMTSimpleRequest *request = [RMTSimpleRequest message];
     request.responseType = RMTPayloadType_Compressable;
-    request.responseSize = 314159;
-    request.payload.body = [NSMutableData dataWithLength:271828];
+    request.responseSize = SMALL_PAYLOAD_SIZE;
+    request.payload.body = [NSMutableData dataWithLength:SMALL_PAYLOAD_SIZE];
     if (i % 3 == 0) {
       request.responseStatus.code = GRPC_STATUS_UNAVAILABLE;
     } else if (i % 7 == 0) {
@@ -776,7 +781,8 @@ static dispatch_once_t initGlobalInterceptorFactory;
                             if (error == nil) {
                               RMTSimpleResponse *expectedResponse = [RMTSimpleResponse message];
                               expectedResponse.payload.type = RMTPayloadType_Compressable;
-                              expectedResponse.payload.body = [NSMutableData dataWithLength:314159];
+                              expectedResponse.payload.body =
+                                  [NSMutableData dataWithLength:SMALL_PAYLOAD_SIZE];
                               XCTAssertEqualObjects(response, expectedResponse);
                             }
                             // DEBUG
@@ -805,8 +811,8 @@ static dispatch_once_t initGlobalInterceptorFactory;
 
   RMTSimpleRequest *request = [RMTSimpleRequest message];
   request.responseType = RMTPayloadType_Compressable;
-  request.responseSize = 10;
-  request.payload.body = [NSMutableData dataWithLength:10];
+  request.responseSize = SMALL_PAYLOAD_SIZE;
+  request.payload.body = [NSMutableData dataWithLength:SMALL_PAYLOAD_SIZE];
 
   [GRPCCall enableOpBatchLog:YES];
   [_service unaryCallWithRequest:request
@@ -935,7 +941,7 @@ static dispatch_once_t initGlobalInterceptorFactory;
                                            [expectation fulfill];
                                          }];
 
-  [self waitForExpectationsWithTimeout:STREAMING_CALL_TEST_TIMEOUT handler:nil];
+  [self waitForExpectationsWithTimeout:TEST_TIMEOUT handler:nil];
 }
 
 - (void)testServerStreamingRPC {
@@ -974,7 +980,7 @@ static dispatch_once_t initGlobalInterceptorFactory;
                           }
                         }];
 
-  [self waitForExpectationsWithTimeout:STREAMING_CALL_TEST_TIMEOUT handler:nil];
+  [self waitForExpectationsWithTimeout:TEST_TIMEOUT handler:nil];
 }
 
 - (void)testPingPongRPC {
@@ -1021,7 +1027,7 @@ static dispatch_once_t initGlobalInterceptorFactory;
                                     [expectation fulfill];
                                   }
                                 }];
-  [self waitForExpectationsWithTimeout:STREAMING_CALL_TEST_TIMEOUT handler:nil];
+  [self waitForExpectationsWithTimeout:TEST_TIMEOUT handler:nil];
 }
 
 - (void)testPingPongRPCWithV2API {
@@ -1075,7 +1081,7 @@ static dispatch_once_t initGlobalInterceptorFactory;
   [call start];
   [call writeMessage:request];
 
-  [self waitForExpectationsWithTimeout:STREAMING_CALL_TEST_TIMEOUT handler:nil];
+  [self waitForExpectationsWithTimeout:TEST_TIMEOUT handler:nil];
 }
 
 - (void)testPingPongRPCWithFlowControl {
@@ -1112,9 +1118,6 @@ static dispatch_once_t initGlobalInterceptorFactory;
                                                 id request = [RMTStreamingOutputCallRequest
                                                     messageWithPayloadSize:requests[index]
                                                      requestedResponseSize:responses[index]];
-                                                XCTAssertLessThanOrEqual(
-                                                    index, writeMessageCount,
-                                                    @"Message received before writing message.");
                                                 [call writeMessage:request];
                                                 [call receiveNextMessage];
                                               } else {
@@ -1139,7 +1142,8 @@ static dispatch_once_t initGlobalInterceptorFactory;
   [call receiveNextMessage];
   [call writeMessage:request];
 
-  [self waitForExpectationsWithTimeout:STREAMING_CALL_TEST_TIMEOUT handler:nil];
+  [self waitForExpectationsWithTimeout:TEST_TIMEOUT handler:nil];
+  XCTAssertEqual(writeMessageCount, 4);
 }
 
 - (void)testEmptyStreamRPC {
@@ -1339,7 +1343,7 @@ static dispatch_once_t initGlobalInterceptorFactory;
                                       }];
                    }];
 
-  [self waitForExpectationsWithTimeout:STREAMING_CALL_TEST_TIMEOUT handler:nil];
+  [self waitForExpectationsWithTimeout:TEST_TIMEOUT handler:nil];
 }
 
 - (void)testCompressedUnaryRPC {
@@ -1353,8 +1357,8 @@ static dispatch_once_t initGlobalInterceptorFactory;
 
   RMTSimpleRequest *request = [RMTSimpleRequest message];
   request.responseType = RMTPayloadType_Compressable;
-  request.responseSize = 314159;
-  request.payload.body = [NSMutableData dataWithLength:271828];
+  request.responseSize = LARGE_RESPONSE_PAYLOAD_SIZE;
+  request.payload.body = [NSMutableData dataWithLength:LARGE_REQUEST_PAYLOAD_SIZE];
   request.expectCompressed.value = YES;
   [GRPCCall setDefaultCompressMethod:GRPCCompressGzip forhost:[[self class] host]];
 
@@ -1364,7 +1368,8 @@ static dispatch_once_t initGlobalInterceptorFactory;
 
                            RMTSimpleResponse *expectedResponse = [RMTSimpleResponse message];
                            expectedResponse.payload.type = RMTPayloadType_Compressable;
-                           expectedResponse.payload.body = [NSMutableData dataWithLength:314159];
+                           expectedResponse.payload.body =
+                               [NSMutableData dataWithLength:LARGE_RESPONSE_PAYLOAD_SIZE];
                            XCTAssertEqualObjects(response, expectedResponse);
 
                            [expectation fulfill];
@@ -1468,7 +1473,7 @@ static dispatch_once_t initGlobalInterceptorFactory;
   [call start];
   [call writeMessage:request];
 
-  [self waitForExpectationsWithTimeout:STREAMING_CALL_TEST_TIMEOUT handler:nil];
+  [self waitForExpectationsWithTimeout:TEST_TIMEOUT handler:nil];
 }
 
 - (void)testLoggingInterceptor {
@@ -1557,9 +1562,6 @@ static dispatch_once_t initGlobalInterceptorFactory;
                                                 id request = [RMTStreamingOutputCallRequest
                                                     messageWithPayloadSize:requests[messageIndex]
                                                      requestedResponseSize:responses[messageIndex]];
-                                                XCTAssertLessThanOrEqual(
-                                                    messageIndex, writeMessageCount,
-                                                    @"Message received before writing message.");
                                                 [call writeMessage:request];
                                                 [call receiveNextMessage];
                                               } else {
@@ -1585,7 +1587,6 @@ static dispatch_once_t initGlobalInterceptorFactory;
   [call writeMessage:request];
 
   [self waitForExpectationsWithTimeout:TEST_TIMEOUT handler:nil];
-  XCTAssertEqual(writeMessageCount, 4);
   XCTAssertEqual(startCount, 1);
   XCTAssertEqual(writeDataCount, 4);
   XCTAssertEqual(finishCount, 1);
@@ -1594,6 +1595,7 @@ static dispatch_once_t initGlobalInterceptorFactory;
   XCTAssertEqual(responseDataCount, 4);
   XCTAssertEqual(responseCloseCount, 1);
   XCTAssertEqual(didWriteDataCount, 4);
+  XCTAssertEqual(writeMessageCount, 4);
 }
 
 // Chain a default interceptor and a hook interceptor which, after one write, cancels the call
@@ -1603,6 +1605,8 @@ static dispatch_once_t initGlobalInterceptorFactory;
   XCTAssertNotNil([[self class] host]);
   __weak XCTestExpectation *expectUserCallComplete =
       [self expectationWithDescription:@"User call completed."];
+  __weak XCTestExpectation *expectResponseCallbackComplete =
+      [self expectationWithDescription:@"Hook interceptor response callback completed"];
 
   NSArray *responses = @[ @1, @2, @3, @4 ];
   __block int index = 0;
@@ -1659,6 +1663,7 @@ static dispatch_once_t initGlobalInterceptorFactory;
         XCTAssertNil(trailingMetadata);
         XCTAssertNotNil(error);
         XCTAssertEqual(error.code, GRPC_STATUS_CANCELLED);
+        [expectResponseCallbackComplete fulfill];
       }
       didWriteDataHook:nil];
 
@@ -1709,7 +1714,7 @@ static dispatch_once_t initGlobalInterceptorFactory;
   [call receiveNextMessage];
   [call writeMessage:request];
 
-  [self waitForExpectationsWithTimeout:STREAMING_CALL_TEST_TIMEOUT handler:nil];
+  [self waitForExpectationsWithTimeout:TEST_TIMEOUT handler:nil];
   XCTAssertEqual(startCount, 1);
   XCTAssertEqual(writeDataCount, 4);
   XCTAssertEqual(finishCount, 1);
@@ -1799,9 +1804,6 @@ static dispatch_once_t initGlobalInterceptorFactory;
                                                 id request = [RMTStreamingOutputCallRequest
                                                     messageWithPayloadSize:requests[index]
                                                      requestedResponseSize:responses[index]];
-                                                XCTAssertLessThanOrEqual(
-                                                    index, writeMessageCount,
-                                                    @"Message received before writing message.");
                                                 [call writeMessage:request];
                                                 [call receiveNextMessage];
                                               } else {
@@ -1823,7 +1825,7 @@ static dispatch_once_t initGlobalInterceptorFactory;
   [call receiveNextMessage];
   [call writeMessage:request];
 
-  [self waitForExpectationsWithTimeout:STREAMING_CALL_TEST_TIMEOUT handler:nil];
+  [self waitForExpectationsWithTimeout:TEST_TIMEOUT handler:nil];
   XCTAssertEqual(startCount, 1);
   XCTAssertEqual(writeDataCount, 4);
   XCTAssertEqual(finishCount, 1);
@@ -1832,6 +1834,7 @@ static dispatch_once_t initGlobalInterceptorFactory;
   XCTAssertEqual(responseDataCount, 4);
   XCTAssertEqual(responseCloseCount, 1);
   XCTAssertEqual(didWriteDataCount, 4);
+  XCTAssertEqual(writeMessageCount, 4);
   globalInterceptorFactory.enabled = NO;
 }
 
@@ -1985,9 +1988,6 @@ static dispatch_once_t initGlobalInterceptorFactory;
                                                 id request = [RMTStreamingOutputCallRequest
                                                     messageWithPayloadSize:requests[index]
                                                      requestedResponseSize:responses[index]];
-                                                XCTAssertLessThanOrEqual(
-                                                    index, writeMessageCount,
-                                                    @"Message received before writing message.");
                                                 [call writeMessage:request];
                                                 [call receiveNextMessage];
                                               } else {
@@ -2006,7 +2006,7 @@ static dispatch_once_t initGlobalInterceptorFactory;
   [call receiveNextMessage];
   [call writeMessage:request];
 
-  [self waitForExpectationsWithTimeout:STREAMING_CALL_TEST_TIMEOUT handler:nil];
+  [self waitForExpectationsWithTimeout:TEST_TIMEOUT handler:nil];
   XCTAssertEqual(startCount, 1);
   XCTAssertEqual(writeDataCount, 4);
   XCTAssertEqual(finishCount, 1);
@@ -2023,6 +2023,7 @@ static dispatch_once_t initGlobalInterceptorFactory;
   XCTAssertEqual(globalResponseDataCount, 4);
   XCTAssertEqual(globalResponseCloseCount, 1);
   XCTAssertEqual(globalDidWriteDataCount, 4);
+  XCTAssertEqual(writeMessageCount, 4);
   globalInterceptorFactory.enabled = NO;
 }
 
index 6dff1ff..41475b2 100755 (executable)
@@ -29,7 +29,7 @@ INTEROP=../../../bazel-out/darwin-fastbuild/bin/test/cpp/interop/interop_server
 }
 
 [ -f $INTEROP ] || {
-    BAZEL build //test/cpp/interop:interop_server
+    $BAZEL build //test/cpp/interop:interop_server
 }
 
 [ -z "$(ps aux |egrep 'port_server\.py.*-p\s32766')" ] && {
index 9fddeed..33b7a4c 100644 (file)
@@ -22,5 +22,5 @@
 // instead. This file can be regenerated from the template by running
 // `tools/buildgen/generate_projects.sh`.
 
-#define GRPC_OBJC_VERSION_STRING @"1.40.0"
-#define GRPC_C_VERSION_STRING @"18.0.0"
+#define GRPC_OBJC_VERSION_STRING @"1.41.0"
+#define GRPC_C_VERSION_STRING @"19.0.0"
index da7ea66..8ba6733 100755 (executable)
@@ -71,7 +71,7 @@ if __name__ == '__main__':
                         'extension=pthreads.so',
                         'src/php/tests/interop/xds_empty_call.php',
                         '--server=' + server_address, '--num=' + str(num),
-                        '--metadata=' + metadata, '--timeout=' + timeout_sec
+                        '--metadata=' + metadata, '--timeout_sec=' + timeout_sec
                     ],
                                          env=client_env)
                 else:
index 6e8c002..07437e2 100644 (file)
@@ -2,7 +2,7 @@
   "name": "grpc/grpc-dev",
   "description": "gRPC library for PHP - for Development use only",
   "license": "Apache-2.0",
-  "version": "1.40.0",
+  "version": "1.41.0",
   "require": {
     "php": ">=7.0.0",
     "google/protobuf": "^v3.3.0"
index 8d62508..d8079ba 100644 (file)
@@ -20,6 +20,6 @@
 #ifndef VERSION_H
 #define VERSION_H
 
-#define PHP_GRPC_VERSION "1.40.0"
+#define PHP_GRPC_VERSION "1.41.0"
 
 #endif /* VERSION_H */
index 09beb88..d91a5a5 100644 (file)
  *
  */
 
-require dirname(__FILE__) . '/../../lib/Grpc/MethodDescriptor.php';
-require dirname(__FILE__) . '/../../lib/Grpc/Status.php';
-require dirname(__FILE__) . '/../../lib/Grpc/ServerCallReader.php';
-require dirname(__FILE__) . '/../../lib/Grpc/ServerCallWriter.php';
-require dirname(__FILE__) . '/../../lib/Grpc/ServerContext.php';
-require dirname(__FILE__) . '/../../lib/Grpc/RpcServer.php';
 include 'vendor/autoload.php';
 
 class MathService extends Math\MathStub
index 5cc28be..c3db442 100644 (file)
@@ -3,6 +3,6 @@
   "version": "0.1.0",
   "dependencies": {
     "@grpc/proto-loader": "^0.1.0",
-    "grpc": "^1.11.0"
+    "grpc": "^1.39.0"
   }
 }
index e261009..654c70f 100644 (file)
@@ -126,7 +126,7 @@ class ResponseParameters extends \Google\Protobuf\Internal\Message
      */
     public function getCompressed()
     {
-        return isset($this->compressed) ? $this->compressed : null;
+        return $this->compressed;
     }
 
     public function hasCompressed()
index 3246941..2f2e504 100644 (file)
@@ -179,7 +179,7 @@ class SimpleRequest extends \Google\Protobuf\Internal\Message
      */
     public function getPayload()
     {
-        return isset($this->payload) ? $this->payload : null;
+        return $this->payload;
     }
 
     public function hasPayload()
@@ -270,7 +270,7 @@ class SimpleRequest extends \Google\Protobuf\Internal\Message
      */
     public function getResponseCompressed()
     {
-        return isset($this->response_compressed) ? $this->response_compressed : null;
+        return $this->response_compressed;
     }
 
     public function hasResponseCompressed()
@@ -309,7 +309,7 @@ class SimpleRequest extends \Google\Protobuf\Internal\Message
      */
     public function getResponseStatus()
     {
-        return isset($this->response_status) ? $this->response_status : null;
+        return $this->response_status;
     }
 
     public function hasResponseStatus()
@@ -345,7 +345,7 @@ class SimpleRequest extends \Google\Protobuf\Internal\Message
      */
     public function getExpectCompressed()
     {
-        return isset($this->expect_compressed) ? $this->expect_compressed : null;
+        return $this->expect_compressed;
     }
 
     public function hasExpectCompressed()
index 79b1081..7ce45aa 100644 (file)
@@ -89,7 +89,7 @@ class SimpleResponse extends \Google\Protobuf\Internal\Message
      */
     public function getPayload()
     {
-        return isset($this->payload) ? $this->payload : null;
+        return $this->payload;
     }
 
     public function hasPayload()
index 72be29d..e170ea1 100644 (file)
@@ -59,7 +59,7 @@ class StreamingInputCallRequest extends \Google\Protobuf\Internal\Message
      */
     public function getPayload()
     {
-        return isset($this->payload) ? $this->payload : null;
+        return $this->payload;
     }
 
     public function hasPayload()
@@ -98,7 +98,7 @@ class StreamingInputCallRequest extends \Google\Protobuf\Internal\Message
      */
     public function getExpectCompressed()
     {
-        return isset($this->expect_compressed) ? $this->expect_compressed : null;
+        return $this->expect_compressed;
     }
 
     public function hasExpectCompressed()
index d6f8aaa..948768c 100644 (file)
@@ -133,7 +133,7 @@ class StreamingOutputCallRequest extends \Google\Protobuf\Internal\Message
      */
     public function getPayload()
     {
-        return isset($this->payload) ? $this->payload : null;
+        return $this->payload;
     }
 
     public function hasPayload()
@@ -169,7 +169,7 @@ class StreamingOutputCallRequest extends \Google\Protobuf\Internal\Message
      */
     public function getResponseStatus()
     {
-        return isset($this->response_status) ? $this->response_status : null;
+        return $this->response_status;
     }
 
     public function hasResponseStatus()
index 4b5f048..05623aa 100644 (file)
@@ -45,7 +45,7 @@ class StreamingOutputCallResponse extends \Google\Protobuf\Internal\Message
      */
     public function getPayload()
     {
-        return isset($this->payload) ? $this->payload : null;
+        return $this->payload;
     }
 
     public function hasPayload()
index 0a6a2dc..0d79e5e 100644 (file)
@@ -105,6 +105,14 @@ grpc_proto_library(
 )
 
 grpc_proto_library(
+    name = "extension_proto",
+    srcs = [
+        "extension.proto",
+    ],
+    well_known_protos = True,
+)
+
+grpc_proto_library(
     name = "listener_proto",
     srcs = [
         "listener.proto",
@@ -244,6 +252,8 @@ grpc_proto_library(
     ],
     well_known_protos = True,
     deps = [
+        "base_proto",
+        "extension_proto",
         "string_proto",
     ],
 )
index b5acb09..33719f6 100644 (file)
@@ -96,6 +96,9 @@ message Node {
   repeated string client_features = 10;
 }
 
+// Data source consisting of either a file or an inline value.
+message DataSource {}
+
 // Runtime derived FractionalPercent with defaults for when the numerator or denominator is not
 // specified via a runtime key.
 //
diff --git a/src/proto/grpc/testing/xds/v3/extension.proto b/src/proto/grpc/testing/xds/v3/extension.proto
new file mode 100644 (file)
index 0000000..10f4b00
--- /dev/null
@@ -0,0 +1,38 @@
+// Copyright 2021 The gRPC Authors
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+// Local copy of Envoy xDS proto file, used for testing only.
+
+syntax = "proto3";
+
+package envoy.config.core.v3;
+
+import "google/protobuf/any.proto";
+
+// [#protodoc-title: Extension configuration]
+
+// Message type for extension configuration.
+// [#next-major-version: revisit all existing typed_config that doesn't use this wrapper.].
+message TypedExtensionConfig {
+  // The name of an extension. This is not used to select the extension, instead
+  // it serves the role of an opaque identifier.
+  string name = 1;
+
+  // The typed config for the extension. The type URL will be used to identify
+  // the extension. In the case that the type URL is *udpa.type.v1.TypedStruct*,
+  // the inner type URL of *TypedStruct* will be utilized. See the
+  // :ref:`extension configuration overview
+  // <config_overview_extension_configuration>` for further details.
+  google.protobuf.Any typed_config = 2;
+}
index e9acfb5..b2fc453 100644 (file)
@@ -18,16 +18,104 @@ syntax = "proto3";
 
 package envoy.extensions.transport_sockets.tls.v3;
 
+import "src/proto/grpc/testing/xds/v3/base.proto";
+import "src/proto/grpc/testing/xds/v3/extension.proto";
 import "src/proto/grpc/testing/xds/v3/string.proto";
 
 import "google/protobuf/wrappers.proto";
 
+// Indicates a certificate to be obtained from a named CertificateProvider plugin instance.
+// The plugin instances are defined in the client's bootstrap file.
+// The plugin allows certificates to be fetched/refreshed over the network asynchronously with
+// respect to the TLS handshake.
+// [#not-implemented-hide:]
+message CertificateProviderPluginInstance {
+  // Provider instance name. If not present, defaults to "default".
+  //
+  // Instance names should generally be defined not in terms of the underlying provider
+  // implementation (e.g., "file_watcher") but rather in terms of the function of the
+  // certificates (e.g., "foo_deployment_identity").
+  string instance_name = 1;
+
+  // Opaque name used to specify certificate instances or types. For example, "ROOTCA" to specify
+  // a root-certificate (validation context) or "example.com" to specify a certificate for a
+  // particular domain. Not all provider instances will actually use this field, so the value
+  // defaults to the empty string.
+  string certificate_name = 2;
+}
+
 message CertificateValidationContext {
+  // Certificate provider instance for fetching TLS certificates.
+  //
+  // Only one of *trusted_ca* and *ca_certificate_provider_instance* may be specified.
+  // [#not-implemented-hide:]
+  CertificateProviderPluginInstance ca_certificate_provider_instance = 13;
+
+  // An optional list of base64-encoded SHA-256 hashes. If specified, Envoy will verify that the
+  // SHA-256 of the DER-encoded Subject Public Key Information (SPKI) of the presented certificate
+  // matches one of the specified values.
+  //
+  // A base64-encoded SHA-256 of the Subject Public Key Information (SPKI) of the certificate
+  // can be generated with the following command:
+  //
+  // .. code-block:: bash
+  //
+  //   $ openssl x509 -in path/to/client.crt -noout -pubkey
+  //     | openssl pkey -pubin -outform DER
+  //     | openssl dgst -sha256 -binary
+  //     | openssl enc -base64
+  //   NvqYIYSbgK2vCJpQhObf77vv+bQWtc5ek5RIOwPiC9A=
+  //
+  // This is the format used in HTTP Public Key Pinning.
+  //
+  // When both:
+  // :ref:`verify_certificate_hash
+  // <envoy_v3_api_field_extensions.transport_sockets.tls.v3.CertificateValidationContext.verify_certificate_hash>` and
+  // :ref:`verify_certificate_spki
+  // <envoy_v3_api_field_extensions.transport_sockets.tls.v3.CertificateValidationContext.verify_certificate_spki>` are specified,
+  // a hash matching value from either of the lists will result in the certificate being accepted.
+  //
+  // .. attention::
+  //
+  //   This option is preferred over :ref:`verify_certificate_hash
+  //   <envoy_v3_api_field_extensions.transport_sockets.tls.v3.CertificateValidationContext.verify_certificate_hash>`,
+  //   because SPKI is tied to a private key, so it doesn't change when the certificate
+  //   is renewed using the same private key.
+  repeated string verify_certificate_spki = 3;
+
+  // An optional list of hex-encoded SHA-256 hashes. If specified, Envoy will verify that
+  // the SHA-256 of the DER-encoded presented certificate matches one of the specified values.
+  //
+  // A hex-encoded SHA-256 of the certificate can be generated with the following command:
+  //
+  // .. code-block:: bash
+  //
+  //   $ openssl x509 -in path/to/client.crt -outform DER | openssl dgst -sha256 | cut -d" " -f2
+  //   df6ff72fe9116521268f6f2dd4966f51df479883fe7037b39f75916ac3049d1a
+  //
+  // A long hex-encoded and colon-separated SHA-256 (a.k.a. "fingerprint") of the certificate
+  // can be generated with the following command:
+  //
+  // .. code-block:: bash
+  //
+  //   $ openssl x509 -in path/to/client.crt -noout -fingerprint -sha256 | cut -d"=" -f2
+  //   DF:6F:F7:2F:E9:11:65:21:26:8F:6F:2D:D4:96:6F:51:DF:47:98:83:FE:70:37:B3:9F:75:91:6A:C3:04:9D:1A
+  //
+  // Both of those formats are acceptable.
+  //
+  // When both:
+  // :ref:`verify_certificate_hash
+  // <envoy_v3_api_field_extensions.transport_sockets.tls.v3.CertificateValidationContext.verify_certificate_hash>` and
+  // :ref:`verify_certificate_spki
+  // <envoy_v3_api_field_extensions.transport_sockets.tls.v3.CertificateValidationContext.verify_certificate_spki>` are specified,
+  // a hash matching value from either of the lists will result in the certificate being accepted.
+  repeated string verify_certificate_hash = 2;
+
   // An optional list of Subject Alternative name matchers. If specified, Envoy will verify that the
   // Subject Alternative Name of the presented certificate matches one of the specified matchers.
   //
   // When a certificate has wildcard DNS SAN entries, to match a specific client, it should be
-  // configured with exact match type in the :ref:`string matcher <envoy_api_msg_type.matcher.v3.StringMatcher>`.
+  // configured with exact match type in the :ref:`string matcher <envoy_v3_api_msg_type.matcher.v3.StringMatcher>`.
   // For example if the certificate has "\*.example.com" as DNS SAN entry, to allow only "api.example.com",
   // it should be configured as shown below.
   //
@@ -40,8 +128,29 @@ message CertificateValidationContext {
   //
   //   Subject Alternative Names are easily spoofable and verifying only them is insecure,
   //   therefore this option must be used together with :ref:`trusted_ca
-  //   <envoy_api_field_extensions.transport_sockets.tls.v3.CertificateValidationContext.trusted_ca>`.
+  //   <envoy_v3_api_field_extensions.transport_sockets.tls.v3.CertificateValidationContext.trusted_ca>`.
   repeated type.matcher.v3.StringMatcher match_subject_alt_names = 9;
+
+  // [#not-implemented-hide:] Must present signed certificate time-stamp.
+  google.protobuf.BoolValue require_signed_certificate_timestamp = 6;
+
+  // An optional `certificate revocation list
+  // <https://en.wikipedia.org/wiki/Certificate_revocation_list>`_
+  // (in PEM format). If specified, Envoy will verify that the presented peer
+  // certificate has not been revoked by this CRL. If this DataSource contains
+  // multiple CRLs, all of them will be used. Note that if a CRL is provided
+  // for any certificate authority in a trust chain, a CRL must be provided
+  // for all certificate authorities in that chain. Failure to do so will
+  // result in verification failure for both revoked and unrevoked certificates
+  // from that chain.
+  config.core.v3.DataSource crl = 7;
+
+  // The configuration of an extension specific certificate validator.
+  // If specified, all validation is done by the specified validator,
+  // and the behavior of all other validation settings is defined by the specified validator (and may be entirely ignored, unused, and unvalidated).
+  // Refer to the documentation for the specified validator. If you do not want a custom validation algorithm, do not set this field.
+  // [#extension-category: envoy.tls.cert_validator]
+  config.core.v3.TypedExtensionConfig custom_validator_config = 12;
 }
 
 message UpstreamTlsContext {
@@ -56,12 +165,43 @@ message UpstreamTlsContext {
 }
 
 message DownstreamTlsContext {
+  enum OcspStaplePolicy {
+    // OCSP responses are optional. If an OCSP response is absent
+    // or expired, the associated certificate will be used for
+    // connections without an OCSP staple.
+    LENIENT_STAPLING = 0;
+
+    // OCSP responses are optional. If an OCSP response is absent,
+    // the associated certificate will be used without an
+    // OCSP staple. If a response is provided but is expired,
+    // the associated certificate will not be used for
+    // subsequent connections. If no suitable certificate is found,
+    // the connection is rejected.
+    STRICT_STAPLING = 1;
+
+    // OCSP responses are required. Configuration will fail if
+    // a certificate is provided without an OCSP response. If a
+    // response expires, the associated certificate will not be
+    // used connections. If no suitable certificate is found, the
+    // connection is rejected.
+    MUST_STAPLE = 2;
+  }
+
   // Common TLS context settings.
   CommonTlsContext common_tls_context = 1;
 
   // If specified, Envoy will reject connections without a valid client
   // certificate.
   google.protobuf.BoolValue require_client_certificate = 2;
+
+  // If specified, Envoy will reject connections without a valid and matching SNI.
+  // [#not-implemented-hide:]
+  google.protobuf.BoolValue require_sni = 3;
+
+  // Config for whether to use certificates if they do not have
+  // an accompanying OCSP response or if the response expires at runtime.
+  // Defaults to LENIENT_STAPLING
+  OcspStaplePolicy ocsp_staple_policy = 8;
 }
 
 
@@ -98,10 +238,60 @@ message CommonTlsContext {
     CertificateProviderInstance validation_context_certificate_provider_instance = 4;
   }
 
+  message TlsParameters {}
+
+  // TLS protocol versions, cipher suites etc.
+  TlsParameters tls_params = 1;
+
+  message TlsCertificate {}
+
+  // :ref:`Multiple TLS certificates <arch_overview_ssl_cert_select>` can be associated with the
+  // same context to allow both RSA and ECDSA certificates.
+  //
+  // Only a single TLS certificate is supported in client contexts. In server contexts, the first
+  // RSA certificate is used for clients that only support RSA and the first ECDSA certificate is
+  // used for clients that support ECDSA.
+  //
+  // Only one of *tls_certificates*, *tls_certificate_sds_secret_configs*,
+  // and *tls_certificate_provider_instance* may be used.
+  // [#next-major-version: These mutually exclusive fields should ideally be in a oneof, but it's
+  // not legal to put a repeated field in a oneof. In the next major version, we should rework
+  // this to avoid this problem.]
+  repeated TlsCertificate tls_certificates = 2;
+
+  message SdsSecretConfig {}
+
+  // Configs for fetching TLS certificates via SDS API. Note SDS API allows certificates to be
+  // fetched/refreshed over the network asynchronously with respect to the TLS handshake.
+  //
+  // The same number and types of certificates as :ref:`tls_certificates <envoy_v3_api_field_extensions.transport_sockets.tls.v3.CommonTlsContext.tls_certificates>`
+  // are valid in the the certificates fetched through this setting.
+  //
+  // Only one of *tls_certificates*, *tls_certificate_sds_secret_configs*,
+  // and *tls_certificate_provider_instance* may be used.
+  // [#next-major-version: These mutually exclusive fields should ideally be in a oneof, but it's
+  // not legal to put a repeated field in a oneof. In the next major version, we should rework
+  // this to avoid this problem.]
+  repeated SdsSecretConfig tls_certificate_sds_secret_configs = 6;
+
+  // Certificate provider instance for fetching TLS certs.
+  //
+  // Only one of *tls_certificates*, *tls_certificate_sds_secret_configs*,
+  // and *tls_certificate_provider_instance* may be used.
+  // [#not-implemented-hide:]
+  CertificateProviderPluginInstance tls_certificate_provider_instance = 14;
+
   // Certificate provider instance for fetching TLS certificates.
   CertificateProviderInstance tls_certificate_certificate_provider_instance = 11;
 
   oneof validation_context_type {
+    // How to validate peer certificates.
+    CertificateValidationContext validation_context = 3;
+
+    // Config for fetching validation context via SDS API. Note SDS API allows certificates to be
+    // fetched/refreshed over the network asynchronously with respect to the TLS handshake.
+    SdsSecretConfig validation_context_sds_secret_config = 7;
+
     // Combined certificate validation context holds a default CertificateValidationContext
     // and SDS config. When SDS server returns dynamic CertificateValidationContext, both dynamic
     // and default CertificateValidationContext are merged into a new CertificateValidationContext
@@ -111,4 +301,8 @@ message CommonTlsContext {
     // CertificateValidationContext, and logical OR is applied to boolean fields.
     CombinedCertificateValidationContext combined_validation_context = 8;
   }
+
+  // Custom TLS handshaker. If empty, defaults to native TLS handshaking
+  // behavior.
+  config.core.v3.TypedExtensionConfig custom_handshaker = 13;
 }
index fe34ad5..0beb029 100644 (file)
@@ -10,7 +10,7 @@ Package for gRPC Python.
 
 Supported Python Versions
 -------------------------
-Python >= 3.5
+Python >= 3.6
 
 Installation
 ------------
index 628535d..bc645e5 100644 (file)
@@ -2144,6 +2144,7 @@ __all__ = (
     'access_token_call_credentials',
     'composite_call_credentials',
     'composite_channel_credentials',
+    'compute_engine_channel_credentials',
     'local_channel_credentials',
     'local_server_credentials',
     'alts_channel_credentials',
index a5189ad..712a589 100644 (file)
@@ -68,9 +68,3 @@ cdef class PollerCompletionQueue(BaseCompletionQueue):
 
     cdef void _poll(self) nogil
     cdef shutdown(self)
-
-
-cdef class CallbackCompletionQueue(BaseCompletionQueue):
-    cdef object _shutdown_completed  # asyncio.Future
-    cdef CallbackWrapper _wrapper
-    cdef object _loop
index e3c3188..eb33e41 100644 (file)
@@ -172,23 +172,3 @@ cdef class PollerCompletionQueue(BaseCompletionQueue):
                     <CallbackWrapper>context.callback_wrapper,
                     event.success
                 )
-
-
-cdef class CallbackCompletionQueue(BaseCompletionQueue):
-
-    def __cinit__(self):
-        self._loop = get_working_loop()
-        self._shutdown_completed = self._loop.create_future()
-        self._wrapper = CallbackWrapper(
-            self._shutdown_completed,
-            self._loop,
-            CQ_SHUTDOWN_FAILURE_HANDLER)
-        self._cq = grpc_completion_queue_create_for_callback(
-            self._wrapper.c_functor(),
-            NULL
-        )
-
-    async def shutdown(self):
-        grpc_completion_queue_shutdown(self._cq)
-        await self._shutdown_completed
-        grpc_completion_queue_destroy(self._cq)
index 9aec955..7f9f52d 100644 (file)
@@ -19,6 +19,8 @@ cdef _AioState _global_aio_state = _AioState()
 
 
 class AsyncIOEngine(enum.Enum):
+    # NOTE(lidiz) the support for custom_io_manager is removed in favor of the
+    # EventEngine project, which will be the only IO platform in Core.
     CUSTOM_IO_MANAGER = 'custom_io_manager'
     POLLER = 'poller'
 
@@ -40,29 +42,6 @@ cdef class _AioState:
         self.cq = None
 
 
-cdef _initialize_custom_io_manager():
-    # Activates asyncio IO manager.
-    # NOTE(lidiz) Custom IO manager must be activated before the first
-    # `grpc_init()`. Otherwise, some special configurations in Core won't
-    # pick up the change, and resulted in SEGFAULT or ABORT.
-    install_asyncio_iomgr()
-
-    # Initializes gRPC Core, must be called before other Core API
-    grpc_init()
-
-    # Timers are triggered by the Asyncio loop. We disable
-    # the background thread that is being used by the native
-    # gRPC iomgr.
-    grpc_timer_manager_set_threading(False)
-
-    # gRPC callbaks are executed within the same thread used by the Asyncio
-    # event loop, as it is being done by the other Asyncio callbacks.
-    Executor.SetThreadingAll(False)
-
-    # Creates the only completion queue
-    _global_aio_state.cq = CallbackCompletionQueue()
-
-
 cdef _initialize_poller():
     # Initializes gRPC Core, must be called before other Core API
     grpc_init()
@@ -80,9 +59,7 @@ cdef _actual_aio_initialization():
     _LOGGER.debug('Using %s as I/O engine', _global_aio_state.engine)
 
     # Initializes the process-level state accordingly
-    if _global_aio_state.engine is AsyncIOEngine.CUSTOM_IO_MANAGER:
-        _initialize_custom_io_manager()
-    elif _global_aio_state.engine is AsyncIOEngine.POLLER:
+    if _global_aio_state.engine is AsyncIOEngine.POLLER:
         _initialize_poller()
     else:
         raise ValueError('Unsupported engine type [%s]' % _global_aio_state.engine)
@@ -98,13 +75,7 @@ def _grpc_shutdown_wrapper(_):
 
 
 cdef _actual_aio_shutdown():
-    if _global_aio_state.engine is AsyncIOEngine.CUSTOM_IO_MANAGER:
-        future = schedule_coro_threadsafe(
-            _global_aio_state.cq.shutdown(),
-            (<CallbackCompletionQueue>_global_aio_state.cq)._loop
-        )
-        future.add_done_callback(_grpc_shutdown_wrapper)
-    elif _global_aio_state.engine is AsyncIOEngine.POLLER:
+    if _global_aio_state.engine is AsyncIOEngine.POLLER:
         (<PollerCompletionQueue>_global_aio_state.cq).shutdown()
         grpc_shutdown()
     else:
diff --git a/src/python/grpcio/grpc/_cython/_cygrpc/aio/iomgr/iomgr.pyx.pxi b/src/python/grpcio/grpc/_cython/_cygrpc/aio/iomgr/iomgr.pyx.pxi
deleted file mode 100644 (file)
index 0923276..0000000
+++ /dev/null
@@ -1,256 +0,0 @@
-# Copyright 2019 gRPC authors.
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-
-import platform
-
-from cpython cimport Py_INCREF, Py_DECREF
-from libc cimport string
-
-import socket as native_socket
-try:
-    import ipaddress  # CPython 3.3 and above
-except ImportError:
-    pass
-
-cdef grpc_socket_vtable asyncio_socket_vtable
-cdef grpc_custom_resolver_vtable asyncio_resolver_vtable
-cdef grpc_custom_timer_vtable asyncio_timer_vtable
-cdef grpc_custom_poller_vtable asyncio_pollset_vtable
-cdef bint so_reuse_port
-
-
-cdef grpc_error_handle asyncio_socket_init(
-        grpc_custom_socket* grpc_socket,
-        int domain) with gil:
-    socket = _AsyncioSocket.create(grpc_socket, None, None)
-    Py_INCREF(socket)
-    grpc_socket.impl = <void*>socket
-    return <grpc_error_handle>0
-
-
-cdef void asyncio_socket_destroy(grpc_custom_socket* grpc_socket) with gil:
-    Py_DECREF(<_AsyncioSocket>grpc_socket.impl)
-
-
-cdef void asyncio_socket_connect(
-        grpc_custom_socket* grpc_socket,
-        const grpc_sockaddr* addr,
-        size_t addr_len,
-        grpc_custom_connect_callback connect_cb) with gil:
-    host, port = sockaddr_to_tuple(addr, addr_len)
-    socket = <_AsyncioSocket>grpc_socket.impl
-    socket.connect(host, port, connect_cb)
-
-
-cdef void asyncio_socket_close(
-        grpc_custom_socket* grpc_socket,
-        grpc_custom_close_callback close_cb) with gil:
-    socket = (<_AsyncioSocket>grpc_socket.impl)
-    socket.close()
-    close_cb(grpc_socket)
-
-
-cdef void asyncio_socket_shutdown(grpc_custom_socket* grpc_socket) with gil:
-    socket = (<_AsyncioSocket>grpc_socket.impl)
-    socket.close()
-
-
-cdef void asyncio_socket_write(
-        grpc_custom_socket* grpc_socket,
-        grpc_slice_buffer* slice_buffer,
-        grpc_custom_write_callback write_cb) with gil:
-    socket = (<_AsyncioSocket>grpc_socket.impl)
-    socket.write(slice_buffer, write_cb)
-
-
-cdef void asyncio_socket_read(
-        grpc_custom_socket* grpc_socket,
-        char* buffer_,
-        size_t length,
-        grpc_custom_read_callback read_cb) with gil:
-    socket = (<_AsyncioSocket>grpc_socket.impl)
-    socket.read(buffer_, length, read_cb)
-
-
-cdef grpc_error_handle asyncio_socket_getpeername(
-        grpc_custom_socket* grpc_socket,
-        const grpc_sockaddr* addr,
-        int* length) with gil:
-    peer = (<_AsyncioSocket>grpc_socket.impl).peername()
-
-    cdef grpc_resolved_address c_addr
-    hostname = str_to_bytes(peer[0])
-    grpc_string_to_sockaddr(&c_addr, hostname, peer[1])
-    # TODO(https://github.com/grpc/grpc/issues/20684) Remove the memcpy
-    string.memcpy(<void*>addr, <void*>c_addr.addr, c_addr.len)
-    length[0] = c_addr.len
-    return grpc_error_none()
-
-
-cdef grpc_error_handle asyncio_socket_getsockname(
-        grpc_custom_socket* grpc_socket,
-        const grpc_sockaddr* addr,
-        int* length) with gil:
-    """Supplies sock_addr in add_socket_to_server."""
-    cdef grpc_resolved_address c_addr
-    socket = (<_AsyncioSocket>grpc_socket.impl)
-    if socket is None:
-        peer = ('0.0.0.0', 0)
-    else:
-        peer = socket.sockname()
-    hostname = str_to_bytes(peer[0])
-    grpc_string_to_sockaddr(&c_addr, hostname, peer[1])
-    # TODO(https://github.com/grpc/grpc/issues/20684) Remove the memcpy
-    string.memcpy(<void*>addr, <void*>c_addr.addr, c_addr.len)
-    length[0] = c_addr.len
-    return grpc_error_none()
-
-
-cdef grpc_error_handle asyncio_socket_listen(grpc_custom_socket* grpc_socket) with gil:
-    (<_AsyncioSocket>grpc_socket.impl).listen()
-    return grpc_error_none()
-
-
-def _asyncio_apply_socket_options(object s, int flags):
-    # Turn SO_REUSEADDR on for TCP sockets; if we want to support UDS, we will
-    # need to update this function.
-    s.setsockopt(native_socket.SOL_SOCKET, native_socket.SO_REUSEADDR, 1)
-    # SO_REUSEPORT only available in POSIX systems.
-    if platform.system() != 'Windows':
-        if GRPC_CUSTOM_SOCKET_OPT_SO_REUSEPORT & flags:
-            s.setsockopt(native_socket.SOL_SOCKET, native_socket.SO_REUSEPORT, 1)
-    s.setsockopt(native_socket.IPPROTO_TCP, native_socket.TCP_NODELAY, True)
-
-
-cdef grpc_error_handle asyncio_socket_bind(
-        grpc_custom_socket* grpc_socket,
-        const grpc_sockaddr* addr,
-        size_t len, int flags) with gil:
-    host, port = sockaddr_to_tuple(addr, len)
-    try:
-        ip = ipaddress.ip_address(host)
-        if isinstance(ip, ipaddress.IPv6Address):
-            family = native_socket.AF_INET6
-        else:
-            family = native_socket.AF_INET
-
-        socket = native_socket.socket(family=family)
-        _asyncio_apply_socket_options(socket, flags)
-        socket.bind((host, port))
-    except IOError as io_error:
-        socket.close()
-        return socket_error("bind", str(io_error))
-    else:
-        aio_socket = _AsyncioSocket.create_with_py_socket(grpc_socket, socket)
-        cpython.Py_INCREF(aio_socket)  # Py_DECREF in asyncio_socket_destroy
-        grpc_socket.impl = <void*>aio_socket
-        return grpc_error_none()
-
-
-cdef void asyncio_socket_accept(
-        grpc_custom_socket* grpc_socket,
-        grpc_custom_socket* grpc_socket_client,
-        grpc_custom_accept_callback accept_cb) with gil:
-    (<_AsyncioSocket>grpc_socket.impl).accept(grpc_socket_client, accept_cb)
-
-
-cdef grpc_error_handle asyncio_resolve(
-        const char* host,
-        const char* port,
-        grpc_resolved_addresses** res) with gil:
-    result = native_socket.getaddrinfo(host, port)
-    res[0] = tuples_to_resolvaddr(result)
-
-
-cdef void asyncio_resolve_async(
-        grpc_custom_resolver* grpc_resolver,
-        const char* host,
-        const char* port) with gil:
-    resolver = _AsyncioResolver.create(grpc_resolver)
-    resolver.resolve(host, port)
-
-
-cdef void asyncio_timer_start(grpc_custom_timer* grpc_timer) with gil:
-    timer = _AsyncioTimer.create(grpc_timer, grpc_timer.timeout_ms / 1000.0)
-    grpc_timer.timer = <void*>timer
-
-
-cdef void asyncio_timer_stop(grpc_custom_timer* grpc_timer) with gil:
-    # TODO(https://github.com/grpc/grpc/issues/22278) remove this if condition
-    if grpc_timer.timer == NULL:
-        return
-    else:
-        timer = <_AsyncioTimer>grpc_timer.timer
-        timer.stop()
-
-
-cdef void asyncio_init_loop() with gil:
-    pass
-
-
-cdef void asyncio_destroy_loop() with gil:
-    pass
-
-
-cdef void asyncio_kick_loop() with gil:
-    pass
-
-
-cdef grpc_error* asyncio_run_loop(size_t timeout_ms) with gil:
-    return grpc_error_none()
-
-
-def _auth_plugin_callback_wrapper(object cb,
-                                  str service_url,
-                                  str method_name,
-                                  object callback):
-    get_working_loop().call_soon(cb, service_url, method_name, callback)
-
-
-def install_asyncio_iomgr():
-    # Auth plugins invoke user provided logic in another thread by default. We
-    # need to override that behavior by registering the call to the event loop.
-    set_async_callback_func(_auth_plugin_callback_wrapper)
-
-    asyncio_resolver_vtable.resolve = asyncio_resolve
-    asyncio_resolver_vtable.resolve_async = asyncio_resolve_async
-
-    asyncio_socket_vtable.init = asyncio_socket_init
-    asyncio_socket_vtable.connect = asyncio_socket_connect
-    asyncio_socket_vtable.destroy = asyncio_socket_destroy
-    asyncio_socket_vtable.shutdown = asyncio_socket_shutdown
-    asyncio_socket_vtable.close = asyncio_socket_close
-    asyncio_socket_vtable.write = asyncio_socket_write
-    asyncio_socket_vtable.read = asyncio_socket_read
-    asyncio_socket_vtable.getpeername = asyncio_socket_getpeername
-    asyncio_socket_vtable.getsockname = asyncio_socket_getsockname
-    asyncio_socket_vtable.bind = asyncio_socket_bind
-    asyncio_socket_vtable.listen = asyncio_socket_listen
-    asyncio_socket_vtable.accept = asyncio_socket_accept
-
-    asyncio_timer_vtable.start = asyncio_timer_start
-    asyncio_timer_vtable.stop = asyncio_timer_stop
-
-    asyncio_pollset_vtable.init = asyncio_init_loop
-    asyncio_pollset_vtable.poll = asyncio_run_loop
-    asyncio_pollset_vtable.kick = asyncio_kick_loop
-    asyncio_pollset_vtable.shutdown = asyncio_destroy_loop
-
-    grpc_custom_iomgr_init(
-        &asyncio_socket_vtable,
-        &asyncio_resolver_vtable,
-        &asyncio_timer_vtable,
-        &asyncio_pollset_vtable
-    )
diff --git a/src/python/grpcio/grpc/_cython/_cygrpc/aio/iomgr/resolver.pyx.pxi b/src/python/grpcio/grpc/_cython/_cygrpc/aio/iomgr/resolver.pyx.pxi
deleted file mode 100644 (file)
index 64e3e63..0000000
+++ /dev/null
@@ -1,56 +0,0 @@
-# Copyright 2019 gRPC authors.
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-
-cdef class _AsyncioResolver:
-    def __cinit__(self):
-        self._loop = get_working_loop()
-        self._grpc_resolver = NULL
-        self._task_resolve = None
-
-    @staticmethod
-    cdef _AsyncioResolver create(grpc_custom_resolver* grpc_resolver):
-        resolver = _AsyncioResolver()
-        resolver._grpc_resolver = grpc_resolver
-        return resolver
-
-    def __repr__(self):
-        class_name = self.__class__.__name__ 
-        id_ = id(self)
-        return f"<{class_name} {id_}>"
-
-    async def _async_resolve(self, bytes host, bytes port):
-        self._task_resolve = None
-        try:
-            resolved = await self._loop.getaddrinfo(host, port)
-        except Exception as e:
-            grpc_custom_resolve_callback(
-                <grpc_custom_resolver*>self._grpc_resolver,
-                NULL,
-                grpc_socket_error("Resolve address [{}:{}] failed: {}: {}".format(
-                    host, port, type(e), str(e)).encode())
-            )
-        else:
-            grpc_custom_resolve_callback(
-                <grpc_custom_resolver*>self._grpc_resolver,
-                tuples_to_resolvaddr(resolved),
-                <grpc_error_handle>0
-            )
-
-    cdef void resolve(self, const char* host, const char* port):
-        assert not self._task_resolve
-
-        self._task_resolve = self._loop.create_task(
-            self._async_resolve(host, port)
-        )
diff --git a/src/python/grpcio/grpc/_cython/_cygrpc/aio/iomgr/socket.pxd.pxi b/src/python/grpcio/grpc/_cython/_cygrpc/aio/iomgr/socket.pxd.pxi
deleted file mode 100644 (file)
index cfab554..0000000
+++ /dev/null
@@ -1,63 +0,0 @@
-# Copyright 2019 gRPC authors.
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-
-cdef class _AsyncioSocket:
-    cdef:
-        # Common attributes
-        grpc_custom_socket * _grpc_socket
-        grpc_custom_read_callback _grpc_read_cb
-        grpc_custom_write_callback _grpc_write_cb
-        object _reader
-        object _writer
-        object _task_read
-        object _task_write
-        object _task_connect
-        object _task_listen
-        char * _read_buffer
-        # Caches the picked event loop, so we can avoid the 30ns overhead each
-        # time we need access to the event loop.
-        object _loop
-        # TODO(lidiz) Drop after 3.6 deprecation. Python 3.7 introduces methods
-        # like `is_closing()` to help graceful shutdown.
-        bint _closed
-
-        # Client-side attributes
-        grpc_custom_connect_callback _grpc_connect_cb
-        
-        # Server-side attributes
-        grpc_custom_accept_callback _grpc_accept_cb
-        grpc_custom_socket * _grpc_client_socket
-        object _server
-        object _py_socket
-        object _peername
-
-    @staticmethod
-    cdef _AsyncioSocket create(
-            grpc_custom_socket * grpc_socket,
-            object reader,
-            object writer)
-    @staticmethod
-    cdef _AsyncioSocket create_with_py_socket(grpc_custom_socket * grpc_socket, object py_socket)
-
-    cdef void connect(self, object host, object port, grpc_custom_connect_callback grpc_connect_cb)
-    cdef void write(self, grpc_slice_buffer * g_slice_buffer, grpc_custom_write_callback grpc_write_cb)
-    cdef void read(self, char * buffer_, size_t length, grpc_custom_read_callback grpc_read_cb)
-    cdef bint is_connected(self)
-    cdef void close(self)
-
-    cdef accept(self, grpc_custom_socket* grpc_socket_client, grpc_custom_accept_callback grpc_accept_cb)
-    cdef listen(self)
-    cdef tuple peername(self)
-    cdef tuple sockname(self)
diff --git a/src/python/grpcio/grpc/_cython/_cygrpc/aio/iomgr/socket.pyx.pxi b/src/python/grpcio/grpc/_cython/_cygrpc/aio/iomgr/socket.pyx.pxi
deleted file mode 100644 (file)
index 43817ef..0000000
+++ /dev/null
@@ -1,225 +0,0 @@
-# Copyright 2019 gRPC authors.
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-import socket as native_socket
-
-from libc cimport string
-
-cdef int _ASYNCIO_STREAM_DEFAULT_SOCKET_BACKLOG = 100
-
-
-# TODO(https://github.com/grpc/grpc/issues/21348) Better flow control needed.
-cdef class _AsyncioSocket:
-    def __cinit__(self):
-        self._grpc_socket = NULL
-        self._grpc_connect_cb = NULL
-        self._grpc_read_cb = NULL
-        self._grpc_write_cb = NULL
-        self._reader = None
-        self._writer = None
-        self._task_connect = None
-        self._task_read = None
-        self._task_write = None
-        self._task_listen = None
-        self._read_buffer = NULL
-        self._server = None
-        self._py_socket = None
-        self._peername = None
-        self._closed = False
-        self._loop = get_working_loop()
-
-    @staticmethod
-    cdef _AsyncioSocket create(grpc_custom_socket * grpc_socket,
-                               object reader,
-                               object writer):
-        socket = _AsyncioSocket()
-        socket._grpc_socket = grpc_socket
-        socket._reader = reader
-        socket._writer = writer
-        if writer is not None:
-            socket._peername = writer.get_extra_info('peername')
-        return socket
-
-    @staticmethod
-    cdef _AsyncioSocket create_with_py_socket(grpc_custom_socket * grpc_socket, object py_socket):
-        socket = _AsyncioSocket()
-        socket._grpc_socket = grpc_socket
-        socket._py_socket = py_socket
-        return socket
-
-    def __repr__(self):
-        class_name = self.__class__.__name__ 
-        id_ = id(self)
-        connected = self.is_connected()
-        return f"<{class_name} {id_} connected={connected}>"
-
-    async def _async_connect(self, object host, object port,):
-        self._task_connect = None
-        try:
-            self._reader, self._writer = await asyncio.open_connection(host, port)
-        except Exception as e:
-            self._grpc_connect_cb(
-                <grpc_custom_socket*>self._grpc_socket,
-                grpc_socket_error("Socket connect failed: {}: {}".format(type(e), str(e)).encode())
-            )
-        else:
-            # gRPC default posix implementation disables nagle
-            # algorithm.
-            sock = self._writer.transport.get_extra_info('socket')
-            sock.setsockopt(native_socket.IPPROTO_TCP, native_socket.TCP_NODELAY, True)
-
-            self._grpc_connect_cb(
-                <grpc_custom_socket*>self._grpc_socket,
-                <grpc_error_handle>0
-            )
-
-    cdef void connect(self,
-                      object host,
-                      object port,
-                      grpc_custom_connect_callback grpc_connect_cb):
-        assert not self._reader
-        assert not self._task_connect
-
-        self._task_connect = self._loop.create_task(
-            self._async_connect(host, port)
-        )
-        self._grpc_connect_cb = grpc_connect_cb
-
-    async def _async_read(self, size_t length):
-        self._task_read = None
-        try:
-            inbound_buffer = await self._reader.read(n=length)
-        except ConnectionError as e:
-            self._grpc_read_cb(
-                <grpc_custom_socket*>self._grpc_socket,
-                -1,
-                grpc_socket_error("Read failed: {}".format(e).encode())
-            )
-        else:
-            string.memcpy(
-                <void*>self._read_buffer,
-                <char*>inbound_buffer,
-                len(inbound_buffer)
-            )
-            self._grpc_read_cb(
-                <grpc_custom_socket*>self._grpc_socket,
-                len(inbound_buffer),
-                <grpc_error_handle>0
-            )
-
-    cdef void read(self, char * buffer_, size_t length, grpc_custom_read_callback grpc_read_cb):
-        assert not self._task_read
-
-        self._grpc_read_cb = grpc_read_cb
-        self._read_buffer = buffer_
-        self._task_read = self._loop.create_task(self._async_read(length))
-
-    async def _async_write(self, bytearray outbound_buffer):
-        self._writer.write(outbound_buffer)
-        self._task_write = None
-        try:
-            await self._writer.drain()
-            self._grpc_write_cb(
-                <grpc_custom_socket*>self._grpc_socket,
-                <grpc_error_handle>0
-            )
-        except ConnectionError as connection_error:
-            self._grpc_write_cb(
-                <grpc_custom_socket*>self._grpc_socket,
-                grpc_socket_error("Socket write failed: {}".format(connection_error).encode()),
-            )
-
-    cdef void write(self, grpc_slice_buffer * g_slice_buffer, grpc_custom_write_callback grpc_write_cb):
-        """Performs write to network socket in AsyncIO.
-        
-        For each socket, Core guarantees there'll be only one ongoing write.
-        When the write is finished, we need to call grpc_write_cb to notify
-        Core that the work is done.
-        """
-        assert not self._task_write
-        cdef char* start
-        cdef bytearray outbound_buffer = bytearray()
-        for i in range(g_slice_buffer.count):
-            start = grpc_slice_buffer_start(g_slice_buffer, i)
-            length = grpc_slice_buffer_length(g_slice_buffer, i)
-            outbound_buffer.extend(<bytes>start[:length])
-
-        self._grpc_write_cb = grpc_write_cb
-        self._task_write = self._loop.create_task(self._async_write(outbound_buffer))
-
-    cdef bint is_connected(self):
-        return self._reader and not self._reader._transport.is_closing()
-
-    cdef void close(self):
-        if self._closed:
-            return
-        else:
-            self._closed = True
-        if self.is_connected():
-            self._writer.close()
-        if self._task_listen and not self._task_listen.done():
-            self._task_listen.close()
-        if self._server:
-            self._server.close()
-        # NOTE(lidiz) If the asyncio.Server is created from a Python socket,
-        # the server.close() won't release the fd until the close() is called
-        # for the Python socket.
-        if self._py_socket:
-            self._py_socket.close()
-
-    def _new_connection_callback(self, object reader, object writer):
-        # If the socket is closed, stop.
-        if self._closed:
-            return
-
-        # Close the connection if server is not started yet.
-        if self._grpc_accept_cb == NULL:
-            writer.close()
-            return
-
-        client_socket = _AsyncioSocket.create(
-            self._grpc_client_socket,
-            reader,
-            writer,
-        )
-
-        self._grpc_client_socket.impl = <void*>client_socket
-        cpython.Py_INCREF(client_socket)  # Py_DECREF in asyncio_socket_destroy
-        # Accept callback expects to be called with:
-        # * grpc_custom_socket: A grpc custom socket for server
-        # * grpc_custom_socket: A grpc custom socket for client (with new Socket instance)
-        # * grpc_error: An error object
-        self._grpc_accept_cb(self._grpc_socket, self._grpc_client_socket, grpc_error_none())
-
-    cdef listen(self):
-        self._py_socket.listen(_ASYNCIO_STREAM_DEFAULT_SOCKET_BACKLOG)
-        async def create_asyncio_server():
-            self._server = await asyncio.start_server(
-                self._new_connection_callback,
-                sock=self._py_socket,
-            )
-
-        self._task_listen = self._loop.create_task(create_asyncio_server())
-
-    cdef accept(self,
-                grpc_custom_socket* grpc_socket_client,
-                grpc_custom_accept_callback grpc_accept_cb):
-        self._grpc_client_socket = grpc_socket_client
-        self._grpc_accept_cb = grpc_accept_cb
-
-    cdef tuple peername(self):
-        return self._peername
-
-    cdef tuple sockname(self):
-        return self._py_socket.getsockname()
diff --git a/src/python/grpcio/grpc/_cython/_cygrpc/aio/iomgr/timer.pyx.pxi b/src/python/grpcio/grpc/_cython/_cygrpc/aio/iomgr/timer.pyx.pxi
deleted file mode 100644 (file)
index f2f7f49..0000000
+++ /dev/null
@@ -1,48 +0,0 @@
-# Copyright 2019 gRPC authors.
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-
-cdef class _AsyncioTimer:
-    def __cinit__(self):
-        self._grpc_timer = NULL
-        self._timer_future = None
-        self._active = False
-        self._loop = get_working_loop()
-        cpython.Py_INCREF(self)
-
-    @staticmethod
-    cdef _AsyncioTimer create(grpc_custom_timer * grpc_timer, float timeout):
-        timer = _AsyncioTimer()
-        timer._grpc_timer = grpc_timer
-        timer._timer_future = timer._loop.call_later(timeout, timer.on_time_up)
-        timer._active = True
-        return timer
-
-    def on_time_up(self):
-        self._active = False
-        grpc_custom_timer_callback(self._grpc_timer, <grpc_error_handle>0)
-        cpython.Py_DECREF(self)
-
-    def __repr__(self):
-        class_name = self.__class__.__name__ 
-        id_ = id(self)
-        return f"<{class_name} {id_} deadline={self._deadline} active={self._active}>"
-
-    cdef stop(self):
-        if not self._active:
-            return
-
-        self._timer_future.cancel()
-        self._active = False
-        cpython.Py_DECREF(self)
index 166be37..70c5b5d 100644 (file)
@@ -42,9 +42,6 @@ IF UNAME_SYSNAME != "Windows":
     include "_cygrpc/fork_posix.pxd.pxi"
 
 # Following pxi files are part of the Aio module
-include "_cygrpc/aio/iomgr/socket.pxd.pxi"
-include "_cygrpc/aio/iomgr/timer.pxd.pxi"
-include "_cygrpc/aio/iomgr/resolver.pxd.pxi"
 include "_cygrpc/aio/completion_queue.pxd.pxi"
 include "_cygrpc/aio/rpc_status.pxd.pxi"
 include "_cygrpc/aio/grpc_aio.pxd.pxi"
index b958975..4c0452d 100644 (file)
@@ -68,10 +68,6 @@ ELSE:
     include "_cygrpc/fork_posix.pyx.pxi"
 
 # Following pxi files are part of the Aio module
-include "_cygrpc/aio/iomgr/iomgr.pyx.pxi"
-include "_cygrpc/aio/iomgr/socket.pyx.pxi"
-include "_cygrpc/aio/iomgr/timer.pyx.pxi"
-include "_cygrpc/aio/iomgr/resolver.pyx.pxi"
 include "_cygrpc/aio/common.pyx.pxi"
 include "_cygrpc/aio/rpc_status.pyx.pxi"
 include "_cygrpc/aio/completion_queue.pyx.pxi"
index ac6d36e..3b14823 100644 (file)
@@ -14,4 +14,4 @@
 
 # AUTO-GENERATED FROM `$REPO_ROOT/templates/src/python/grpcio/grpc/_grpcio_metadata.py.template`!!!
 
-__version__ = """1.40.0"""
+__version__ = """1.41.0"""
index cddaf4a..225def4 100644 (file)
@@ -206,7 +206,7 @@ class ServicerContext(Generic[RequestType, ResponseType], abc.ABC):
 
     @abc.abstractmethod
     def invocation_metadata(self) -> Optional[Metadata]:
-        """Accesses the metadata from the sent by the client.
+        """Accesses the metadata sent by the client.
 
         Returns:
           The invocation :term:`metadata`.
index 8eb2f86..5c6dcc1 100644 (file)
@@ -53,12 +53,10 @@ CORE_SOURCE_FILES = [
     'src/core/ext/filters/client_channel/resolver.cc',
     'src/core/ext/filters/client_channel/resolver/dns/c_ares/dns_resolver_ares.cc',
     'src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_event_engine.cc',
-    'src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_libuv.cc',
     'src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_posix.cc',
     'src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_windows.cc',
     'src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper.cc',
     'src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_event_engine.cc',
-    'src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_libuv.cc',
     'src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_posix.cc',
     'src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_windows.cc',
     'src/core/ext/filters/client_channel/resolver/dns/dns_resolver_selection.cc',
@@ -116,8 +114,10 @@ CORE_SOURCE_FILES = [
     'src/core/ext/transport/chttp2/transport/frame_settings.cc',
     'src/core/ext/transport/chttp2/transport/frame_window_update.cc',
     'src/core/ext/transport/chttp2/transport/hpack_encoder.cc',
+    'src/core/ext/transport/chttp2/transport/hpack_encoder_table.cc',
     'src/core/ext/transport/chttp2/transport/hpack_parser.cc',
-    'src/core/ext/transport/chttp2/transport/hpack_table.cc',
+    'src/core/ext/transport/chttp2/transport/hpack_parser_table.cc',
+    'src/core/ext/transport/chttp2/transport/hpack_utils.cc',
     'src/core/ext/transport/chttp2/transport/http2_settings.cc',
     'src/core/ext/transport/chttp2/transport/huffsyms.cc',
     'src/core/ext/transport/chttp2/transport/incoming_metadata.cc',
@@ -357,6 +357,7 @@ CORE_SOURCE_FILES = [
     'src/core/lib/compression/stream_compression.cc',
     'src/core/lib/compression/stream_compression_gzip.cc',
     'src/core/lib/compression/stream_compression_identity.cc',
+    'src/core/lib/config/core_configuration.cc',
     'src/core/lib/debug/stats.cc',
     'src/core/lib/debug/stats_data.cc',
     'src/core/lib/debug/trace.cc',
@@ -390,7 +391,6 @@ CORE_SOURCE_FILES = [
     'src/core/lib/gpr/time_posix.cc',
     'src/core/lib/gpr/time_precise.cc',
     'src/core/lib/gpr/time_windows.cc',
-    'src/core/lib/gpr/tls_pthread.cc',
     'src/core/lib/gpr/tmpfile_msys.cc',
     'src/core/lib/gpr/tmpfile_posix.cc',
     'src/core/lib/gpr/tmpfile_windows.cc',
@@ -420,7 +420,6 @@ CORE_SOURCE_FILES = [
     'src/core/lib/iomgr/endpoint_cfstream.cc',
     'src/core/lib/iomgr/endpoint_pair_event_engine.cc',
     'src/core/lib/iomgr/endpoint_pair_posix.cc',
-    'src/core/lib/iomgr/endpoint_pair_uv.cc',
     'src/core/lib/iomgr/endpoint_pair_windows.cc',
     'src/core/lib/iomgr/error.cc',
     'src/core/lib/iomgr/error_cfstream.cc',
@@ -456,7 +455,6 @@ CORE_SOURCE_FILES = [
     'src/core/lib/iomgr/iomgr_internal.cc',
     'src/core/lib/iomgr/iomgr_posix.cc',
     'src/core/lib/iomgr/iomgr_posix_cfstream.cc',
-    'src/core/lib/iomgr/iomgr_uv.cc',
     'src/core/lib/iomgr/iomgr_windows.cc',
     'src/core/lib/iomgr/is_epollexclusive_available.cc',
     'src/core/lib/iomgr/load_file.cc',
@@ -467,7 +465,6 @@ CORE_SOURCE_FILES = [
     'src/core/lib/iomgr/pollset_set.cc',
     'src/core/lib/iomgr/pollset_set_custom.cc',
     'src/core/lib/iomgr/pollset_set_windows.cc',
-    'src/core/lib/iomgr/pollset_uv.cc',
     'src/core/lib/iomgr/pollset_windows.cc',
     'src/core/lib/iomgr/resolve_address.cc',
     'src/core/lib/iomgr/resolve_address_custom.cc',
@@ -479,7 +476,6 @@ CORE_SOURCE_FILES = [
     'src/core/lib/iomgr/socket_utils_common_posix.cc',
     'src/core/lib/iomgr/socket_utils_linux.cc',
     'src/core/lib/iomgr/socket_utils_posix.cc',
-    'src/core/lib/iomgr/socket_utils_uv.cc',
     'src/core/lib/iomgr/socket_utils_windows.cc',
     'src/core/lib/iomgr/socket_windows.cc',
     'src/core/lib/iomgr/tcp_client.cc',
@@ -496,7 +492,6 @@ CORE_SOURCE_FILES = [
     'src/core/lib/iomgr/tcp_server_utils_posix_ifaddrs.cc',
     'src/core/lib/iomgr/tcp_server_utils_posix_noifaddrs.cc',
     'src/core/lib/iomgr/tcp_server_windows.cc',
-    'src/core/lib/iomgr/tcp_uv.cc',
     'src/core/lib/iomgr/tcp_windows.cc',
     'src/core/lib/iomgr/time_averaged_stats.cc',
     'src/core/lib/iomgr/timer.cc',
@@ -504,7 +499,6 @@ CORE_SOURCE_FILES = [
     'src/core/lib/iomgr/timer_generic.cc',
     'src/core/lib/iomgr/timer_heap.cc',
     'src/core/lib/iomgr/timer_manager.cc',
-    'src/core/lib/iomgr/timer_uv.cc',
     'src/core/lib/iomgr/udp_server.cc',
     'src/core/lib/iomgr/unix_sockets_posix.cc',
     'src/core/lib/iomgr/unix_sockets_posix_noop.cc',
@@ -521,6 +515,7 @@ CORE_SOURCE_FILES = [
     'src/core/lib/profiling/stap_timers.cc',
     'src/core/lib/security/authorization/authorization_policy_provider_vtable.cc',
     'src/core/lib/security/authorization/evaluate_args.cc',
+    'src/core/lib/security/authorization/sdk_server_authz_filter.cc',
     'src/core/lib/security/context/security_context.cc',
     'src/core/lib/security/credentials/alts/alts_credentials.cc',
     'src/core/lib/security/credentials/alts/check_gcp_environment.cc',
@@ -960,6 +955,7 @@ CORE_SOURCE_FILES = [
     'third_party/boringssl-with-bazel/src/ssl/dtls_method.cc',
     'third_party/boringssl-with-bazel/src/ssl/dtls_record.cc',
     'third_party/boringssl-with-bazel/src/ssl/encrypted_client_hello.cc',
+    'third_party/boringssl-with-bazel/src/ssl/extensions.cc',
     'third_party/boringssl-with-bazel/src/ssl/handoff.cc',
     'third_party/boringssl-with-bazel/src/ssl/handshake.cc',
     'third_party/boringssl-with-bazel/src/ssl/handshake_client.cc',
@@ -982,7 +978,6 @@ CORE_SOURCE_FILES = [
     'third_party/boringssl-with-bazel/src/ssl/ssl_versions.cc',
     'third_party/boringssl-with-bazel/src/ssl/ssl_x509.cc',
     'third_party/boringssl-with-bazel/src/ssl/t1_enc.cc',
-    'third_party/boringssl-with-bazel/src/ssl/t1_lib.cc',
     'third_party/boringssl-with-bazel/src/ssl/tls13_both.cc',
     'third_party/boringssl-with-bazel/src/ssl/tls13_client.cc',
     'third_party/boringssl-with-bazel/src/ssl/tls13_enc.cc',
index 96693cf..a92a024 100644 (file)
@@ -14,4 +14,4 @@
 
 # AUTO-GENERATED FROM `$REPO_ROOT/templates/src/python/grpcio/grpc_version.py.template`!!!
 
-VERSION = '1.40.0'
+VERSION = '1.41.0'
index 4b5a8b2..6402297 100644 (file)
@@ -14,4 +14,4 @@
 
 # AUTO-GENERATED FROM `$REPO_ROOT/templates/src/python/grpcio_admin/grpc_version.py.template`!!!
 
-VERSION = '1.40.0'
+VERSION = '1.41.0'
index d66d0c4..526b34a 100644 (file)
@@ -5,11 +5,7 @@ Channelz is a live debug tool in gRPC Python.
 
 Supported Python Versions
 -------------------------
-Python >= 3.5
-
-Deprecated Python Versions
---------------------------
-Python == 2.7. Python 2.7 support will be removed on January 1, 2020.
+Python >= 3.6
 
 Dependencies
 ------------
index 4c490a2..58a79c6 100644 (file)
@@ -14,4 +14,4 @@
 
 # AUTO-GENERATED FROM `$REPO_ROOT/templates/src/python/grpcio_channelz/grpc_version.py.template`!!!
 
-VERSION = '1.40.0'
+VERSION = '1.41.0'
index 8982a4a..fc0f157 100644 (file)
@@ -54,6 +54,7 @@ CLASSIFIERS = [
     'Programming Language :: Python :: 3.7',
     'Programming Language :: Python :: 3.8',
     'Programming Language :: Python :: 3.9',
+    'Programming Language :: Python :: 3.10',
     'License :: OSI Approved :: Apache Software License',
 ]
 
index 7bb8687..215ecd5 100644 (file)
@@ -14,4 +14,4 @@
 
 # AUTO-GENERATED FROM `$REPO_ROOT/templates/src/python/grpcio_csds/grpc_version.py.template`!!!
 
-VERSION = '1.40.0'
+VERSION = '1.41.0'
index 044377a..bb4ff86 100644 (file)
@@ -5,11 +5,7 @@ Reference package for GRPC Python health checking.
 
 Supported Python Versions
 -------------------------
-Python >= 3.5
-
-Deprecated Python Versions
---------------------------
-Python == 2.7. Python 2.7 support will be removed on January 1, 2020.
+Python >= 3.6
 
 Dependencies
 ------------
index 7ef3035..66e1c8b 100644 (file)
@@ -14,4 +14,4 @@
 
 # AUTO-GENERATED FROM `$REPO_ROOT/templates/src/python/grpcio_health_checking/grpc_version.py.template`!!!
 
-VERSION = '1.40.0'
+VERSION = '1.41.0'
index d2ed495..4570e5c 100644 (file)
@@ -53,6 +53,7 @@ CLASSIFIERS = [
     'Programming Language :: Python :: 3.7',
     'Programming Language :: Python :: 3.8',
     'Programming Language :: Python :: 3.9',
+    'Programming Language :: Python :: 3.10',
     'License :: OSI Approved :: Apache Software License',
 ]
 
index 56f9953..f8c4c54 100644 (file)
@@ -5,11 +5,7 @@ Reference package for reflection in GRPC Python.
 
 Supported Python Versions
 -------------------------
-Python >= 3.5
-
-Deprecated Python Versions
---------------------------
-Python == 2.7. Python 2.7 support will be removed on January 1, 2020.
+Python >= 3.6
 
 Dependencies
 ------------
index 647fabb..291091d 100644 (file)
@@ -14,4 +14,4 @@
 
 # AUTO-GENERATED FROM `$REPO_ROOT/templates/src/python/grpcio_reflection/grpc_version.py.template`!!!
 
-VERSION = '1.40.0'
+VERSION = '1.41.0'
index c88bfd1..991bf38 100644 (file)
@@ -54,6 +54,7 @@ CLASSIFIERS = [
     'Programming Language :: Python :: 3.7',
     'Programming Language :: Python :: 3.8',
     'Programming Language :: Python :: 3.9',
+    'Programming Language :: Python :: 3.10',
     'License :: OSI Approved :: Apache Software License',
 ]
 
index 16c5938..e9483d0 100644 (file)
@@ -5,11 +5,7 @@ Reference package for GRPC Python status proto mapping.
 
 Supported Python Versions
 -------------------------
-Python >= 3.5
-
-Deprecated Python Versions
---------------------------
-Python == 2.7. Python 2.7 support will be removed on January 1, 2020.
+Python >= 3.6
 
 Dependencies
 ------------
index 49380ad..cd0ed6c 100644 (file)
@@ -14,4 +14,4 @@
 
 # AUTO-GENERATED FROM `$REPO_ROOT/templates/src/python/grpcio_status/grpc_version.py.template`!!!
 
-VERSION = '1.40.0'
+VERSION = '1.41.0'
index 5f1633a..da9414c 100644 (file)
@@ -53,6 +53,7 @@ CLASSIFIERS = [
     'Programming Language :: Python :: 3.7',
     'Programming Language :: Python :: 3.8',
     'Programming Language :: Python :: 3.9',
+    'Programming Language :: Python :: 3.10',
     'License :: OSI Approved :: Apache Software License',
 ]
 
index 968dec8..66d80b1 100644 (file)
@@ -5,11 +5,7 @@ Testing utilities for gRPC Python
 
 Supported Python Versions
 -------------------------
-Python >= 3.5
-
-Deprecated Python Versions
---------------------------
-Python == 2.7. Python 2.7 support will be removed on January 1, 2020.
+Python >= 3.6
 
 Dependencies
 ------------
index 020a2f6..8326065 100644 (file)
@@ -14,4 +14,4 @@
 
 # AUTO-GENERATED FROM `$REPO_ROOT/templates/src/python/grpcio_testing/grpc_version.py.template`!!!
 
-VERSION = '1.40.0'
+VERSION = '1.41.0'
index c2f5963..368b084 100644 (file)
@@ -14,4 +14,4 @@
 
 # AUTO-GENERATED FROM `$REPO_ROOT/templates/src/python/grpcio_tests/grpc_version.py.template`!!!
 
-VERSION = '1.40.0'
+VERSION = '1.41.0'
index bf3c72d..c536328 100644 (file)
@@ -75,6 +75,7 @@ class AllTest(unittest.TestCase):
             'access_token_call_credentials',
             'composite_call_credentials',
             'composite_channel_credentials',
+            'compute_engine_channel_credentials',
             'ssl_server_credentials',
             'ssl_server_certificate_configuration',
             'dynamic_ssl_server_credentials',
index 22c4d52..f38a83b 100644 (file)
@@ -49,7 +49,7 @@ class DNSResolverTest(unittest.TestCase):
     def test_connect_loopback(self):
         # NOTE(https://github.com/grpc/grpc/issues/18422)
         # In short, Gevent + C-Ares = Segfault. The C-Ares driver is not
-        # supported by custom io manager like "gevent" or "libuv".
+        # supported by custom io manager like "gevent"
         with grpc.insecure_channel('loopback4.unittest.grpc.io:%d' %
                                    self._port) as channel:
             self.assertEqual(
index e796eb5..c98bba3 100644 (file)
@@ -123,6 +123,7 @@ _global_rpc_statuses: Mapping[str, Mapping[int, int]] = collections.defaultdict(
 
 
 def _handle_sigint(sig, frame) -> None:
+    logger.warning("Received SIGINT")
     _stop_event.set()
     _global_server.stop(None)
 
index 93fbdff..db8dc45 100644 (file)
@@ -57,7 +57,7 @@ end
 
 ENV['CPPFLAGS'] = '-DGPR_BACKWARDS_COMPATIBILITY_MODE'
 ENV['CPPFLAGS'] += ' -DGRPC_XDS_USER_AGENT_NAME_SUFFIX="\"RUBY\"" '
-ENV['CPPFLAGS'] += ' -DGRPC_XDS_USER_AGENT_VERSION_SUFFIX="\"1.40.0\"" '
+ENV['CPPFLAGS'] += ' -DGRPC_XDS_USER_AGENT_VERSION_SUFFIX="\"1.41.0\"" '
 
 output_dir = File.expand_path(RbConfig::CONFIG['topdir'])
 grpc_lib_dir = File.join(output_dir, 'libs', grpc_config)
index e11c7e8..ffd9533 100644 (file)
 #include <ruby/ruby.h>
 
 #include "rb_byte_buffer.h"
+
+#include "rb_grpc.h"
 #include "rb_grpc_imports.generated.h"
 
 #include <grpc/byte_buffer_reader.h>
 #include <grpc/grpc.h>
 #include <grpc/slice.h>
-#include "rb_grpc.h"
 
 grpc_byte_buffer* grpc_rb_s_to_byte_buffer(char* string, size_t length) {
   grpc_slice slice = grpc_slice_from_copied_buffer(string, length);
index 117ab63..090fe0a 100644 (file)
 #include <ruby/ruby.h>
 
 #include "rb_call.h"
+
+#include "rb_byte_buffer.h"
+#include "rb_call_credentials.h"
+#include "rb_completion_queue.h"
+#include "rb_grpc.h"
 #include "rb_grpc_imports.generated.h"
 
 #include <grpc/grpc.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 
-#include "rb_byte_buffer.h"
-#include "rb_call_credentials.h"
-#include "rb_completion_queue.h"
-#include "rb_grpc.h"
-
 /* grpc_rb_cCall is the Call class whose instances proxy grpc_call. */
 static VALUE grpc_rb_cCall;
 
index 76e5159..5f305fa 100644 (file)
 #include <ruby/ruby.h>
 
 #include "rb_call_credentials.h"
-#include "rb_grpc_imports.generated.h"
 
 #include <ruby/thread.h>
 
+#include "rb_call.h"
+#include "rb_event_thread.h"
+#include "rb_grpc.h"
+#include "rb_grpc_imports.generated.h"
+
 #include <grpc/grpc.h>
 #include <grpc/grpc_security.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 
-#include "rb_call.h"
-#include "rb_event_thread.h"
-#include "rb_grpc.h"
-
 /* grpc_rb_cCallCredentials is the ruby class that proxies
  * grpc_call_credentials */
 static VALUE grpc_rb_cCallCredentials = Qnil;
index 6a665b2..dc833f4 100644 (file)
  */
 
 #include <ruby/ruby.h>
-#include <ruby/thread.h>
 
-#include "rb_byte_buffer.h"
 #include "rb_channel.h"
-#include "rb_grpc_imports.generated.h"
 
-#include <grpc/grpc.h>
-#include <grpc/grpc_security.h>
-#include <grpc/support/alloc.h>
-#include <grpc/support/log.h>
-#include <grpc/support/time.h>
+#include <ruby/thread.h>
+
+#include "rb_byte_buffer.h"
 #include "rb_call.h"
 #include "rb_channel_args.h"
 #include "rb_channel_credentials.h"
 #include "rb_completion_queue.h"
 #include "rb_grpc.h"
+#include "rb_grpc_imports.generated.h"
 #include "rb_server.h"
 #include "rb_xds_channel_credentials.h"
 
+#include <grpc/grpc.h>
+#include <grpc/grpc_security.h>
+#include <grpc/support/alloc.h>
+#include <grpc/support/log.h>
+#include <grpc/support/time.h>
+
 /* id_channel is the name of the hidden ivar that preserves a reference to the
  * channel on a call, so that calls are not GCed before their channel.  */
 static ID id_channel;
index 6aaf240..666a994 100644 (file)
 #include <ruby/ruby.h>
 
 #include "rb_channel_args.h"
+
+#include "rb_grpc.h"
 #include "rb_grpc_imports.generated.h"
 
 #include <grpc/grpc.h>
 
-#include "rb_grpc.h"
-
 static rb_data_type_t grpc_rb_channel_args_data_type = {
     "grpc_channel_args",
     {GRPC_RB_GC_NOT_MARKED,
index d65d049..368ad14 100644 (file)
 
 #include <ruby/ruby.h>
 
+#include "rb_channel_credentials.h"
+
 #include <string.h>
 
-#include "rb_channel_credentials.h"
+#include "rb_call_credentials.h"
+#include "rb_grpc.h"
 #include "rb_grpc_imports.generated.h"
 
 #include <grpc/grpc.h>
@@ -28,9 +31,6 @@
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 
-#include "rb_call_credentials.h"
-#include "rb_grpc.h"
-
 /* grpc_rb_cChannelCredentials is the ruby class that proxies
    grpc_channel_credentials. */
 static VALUE grpc_rb_cChannelCredentials = Qnil;
index 56856df..75bda4b 100644 (file)
@@ -20,6 +20,7 @@
 #define GRPC_RB_CREDENTIALS_H_
 
 #include <ruby/ruby.h>
+
 #include <stdbool.h>
 
 #include <grpc/grpc_security.h>
index 64264f5..8c0af2e 100644 (file)
 #include <ruby/ruby.h>
 
 #include "rb_completion_queue.h"
-#include "rb_grpc_imports.generated.h"
 
 #include <ruby/thread.h>
 
+#include "rb_grpc.h"
+#include "rb_grpc_imports.generated.h"
+
 #include <grpc/grpc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/time.h>
-#include "rb_grpc.h"
 
 /* Used to allow grpc_completion_queue_next call to release the GIL */
 typedef struct next_call_stack {
index 53b71e2..0c0e5a9 100644 (file)
 
 #include <ruby/ruby.h>
 
-#include "rb_byte_buffer.h"
 #include "rb_compression_options.h"
+
+#include <string.h>
+
+#include "rb_byte_buffer.h"
+#include "rb_grpc.h"
 #include "rb_grpc_imports.generated.h"
 
 #include <grpc/compression.h>
@@ -29,9 +33,6 @@
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/string_util.h>
-#include <string.h>
-
-#include "rb_grpc.h"
 
 static VALUE grpc_rb_cCompressionOptions = Qnil;
 
index 0bdf725..0f2461e 100644 (file)
 #include <ruby/ruby.h>
 
 #include "rb_event_thread.h"
-#include "rb_grpc_imports.generated.h"
 
+#include <ruby/thread.h>
 #include <stdbool.h>
 
+#include "rb_grpc.h"
+#include "rb_grpc_imports.generated.h"
+
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/sync.h>
 #include <grpc/support/time.h>
-#include <ruby/thread.h>
-
-#include "rb_grpc.h"
 
 typedef struct grpc_rb_event {
   // callback will be called with argument while holding the GVL
index 8b230ea..ab10af5 100644 (file)
@@ -19,7 +19,6 @@
 #include <ruby/ruby.h>
 
 #include "rb_grpc.h"
-#include "rb_grpc_imports.generated.h"
 
 #include <math.h>
 #include <ruby/vm.h>
 #include <sys/types.h>
 #include <unistd.h>
 
-#include <grpc/grpc.h>
-#include <grpc/support/log.h>
-#include <grpc/support/time.h>
 #include "rb_call.h"
 #include "rb_call_credentials.h"
 #include "rb_channel.h"
 #include "rb_channel_credentials.h"
 #include "rb_compression_options.h"
 #include "rb_event_thread.h"
+#include "rb_grpc_imports.generated.h"
 #include "rb_loader.h"
 #include "rb_server.h"
 #include "rb_server_credentials.h"
 #include "rb_xds_channel_credentials.h"
 #include "rb_xds_server_credentials.h"
 
+#include <grpc/grpc.h>
+#include <grpc/support/log.h>
+#include <grpc/support/time.h>
+
 static VALUE grpc_rb_cTimeVal = Qnil;
 
 static rb_data_type_t grpc_rb_timespec_data_type = {
index 2c46758..716e779 100644 (file)
@@ -20,6 +20,7 @@
 #define GRPC_RB_H_
 
 #include <ruby/ruby.h>
+
 #include <sys/time.h>
 
 #include <grpc/support/time.h>
index 31434a3..0b19328 100644 (file)
 
 #include <ruby/ruby.h>
 
-#include "rb_grpc_imports.generated.h"
 #include "rb_server.h"
 
-#include <grpc/grpc.h>
-#include <grpc/grpc_security.h>
-#include <grpc/support/atm.h>
-#include <grpc/support/log.h>
 #include "rb_byte_buffer.h"
 #include "rb_call.h"
 #include "rb_channel_args.h"
 #include "rb_completion_queue.h"
 #include "rb_grpc.h"
+#include "rb_grpc_imports.generated.h"
 #include "rb_server_credentials.h"
 #include "rb_xds_server_credentials.h"
 
+#include <grpc/grpc.h>
+#include <grpc/grpc_security.h>
+#include <grpc/support/atm.h>
+#include <grpc/support/log.h>
+
 /* grpc_rb_cServer is the ruby class that proxies grpc_server. */
 static VALUE grpc_rb_cServer = Qnil;
 
index 7c68cfd..ccd8a28 100644 (file)
 
 #include <ruby/ruby.h>
 
-#include "rb_grpc_imports.generated.h"
 #include "rb_server_credentials.h"
 
+#include "rb_grpc.h"
+#include "rb_grpc_imports.generated.h"
+
 #include <grpc/grpc.h>
 #include <grpc/grpc_security.h>
 #include <grpc/support/log.h>
 
-#include "rb_grpc.h"
-
 /* grpc_rb_cServerCredentials is the ruby class that proxies
    grpc_server_credentials. */
 static VALUE grpc_rb_cServerCredentials = Qnil;
index 35c2ef0..bb14b57 100644 (file)
@@ -20,6 +20,7 @@
 #define GRPC_RB_SERVER_CREDENTIALS_H_
 
 #include <ruby/ruby.h>
+
 #include <stdbool.h>
 
 #include <grpc/grpc_security.h>
index b65a3e8..71f94af 100644 (file)
  *
  */
 
-#include <grpc/grpc.h>
-#include <grpc/grpc_security.h>
-#include <grpc/support/alloc.h>
-#include <grpc/support/log.h>
 #include <ruby/ruby.h>
+
+#include "rb_xds_channel_credentials.h"
+
 #include <string.h>
 
 #include "rb_call_credentials.h"
 #include "rb_channel_credentials.h"
 #include "rb_grpc.h"
 #include "rb_grpc_imports.generated.h"
-#include "rb_xds_channel_credentials.h"
+
+#include <grpc/grpc.h>
+#include <grpc/grpc_security.h>
+#include <grpc/support/alloc.h>
+#include <grpc/support/log.h>
 
 /* grpc_rb_cXdsChannelCredentials is the ruby class that proxies
    grpc_channel_credentials. */
index 2dc655e..5eba040 100644 (file)
 #ifndef GRPC_RB_XDS_CHANNEL_CREDENTIALS_H_
 #define GRPC_RB_XDS_CHANNEL_CREDENTIALS_H_
 
-#include <grpc/grpc_security.h>
 #include <ruby/ruby.h>
+
 #include <stdbool.h>
 
+#include <grpc/grpc_security.h>
+
 /* Initializes the ruby ChannelCredentials class. */
 void Init_grpc_xds_channel_credentials();
 
index 54f1ecb..4d877d1 100644 (file)
  *
  */
 
-#include "rb_xds_server_credentials.h"
-
-#include <grpc/grpc.h>
-#include <grpc/grpc_security.h>
-#include <grpc/support/log.h>
 #include <ruby/ruby.h>
 
+#include "rb_xds_server_credentials.h"
+
 #include "rb_grpc.h"
 #include "rb_grpc_imports.generated.h"
 #include "rb_server_credentials.h"
 
+#include <grpc/grpc.h>
+#include <grpc/grpc_security.h>
+#include <grpc/support/log.h>
+
 /* grpc_rb_cXdsServerCredentials is the ruby class that proxies
    grpc_server_credentials. */
 static VALUE grpc_rb_cXdsServerCredentials = Qnil;
index 398ab47..eff00c7 100644 (file)
 #ifndef GRPC_RB_XDS_SERVER_CREDENTIALS_H_
 #define GRPC_RB_XDS_SERVER_CREDENTIALS_H_
 
-#include <grpc/grpc_security.h>
 #include <ruby/ruby.h>
+
 #include <stdbool.h>
 
+#include <grpc/grpc_security.h>
+
 /* Initializes the ruby XdsServerCredentials class. */
 void Init_grpc_xds_server_credentials();
 
index e72d84a..b0b6299 100644 (file)
@@ -14,5 +14,5 @@
 
 # GRPC contains the General RPC module.
 module GRPC
-  VERSION = '1.40.0'
+  VERSION = '1.41.0'
 end
index 144a867..11dbe76 100644 (file)
@@ -14,6 +14,6 @@
 
 module GRPC
   module Tools
-    VERSION = '1.40.0'
+    VERSION = '1.41.0'
   end
 end
index b556c3d..5b528ef 100755 (executable)
@@ -43,21 +43,22 @@ try:
         ],
         'headers': [
             "third_party/upb/upb/decode_fast.h",
+            "third_party/upb/upb/decode_internal.h",
             "third_party/upb/upb/decode.h",
-            "third_party/upb/upb/decode.int.h",
             "third_party/upb/upb/def.h",
             "third_party/upb/upb/def.hpp",
             "third_party/upb/upb/encode.h",
+            "third_party/upb/upb/msg_internal.h",
             "third_party/upb/upb/msg.h",
             "third_party/upb/upb/port_def.inc",
             "third_party/upb/upb/port_undef.inc",
             "third_party/upb/upb/reflection.h",
-            "third_party/upb/upb/table.int.h",
+            "third_party/upb/upb/reflection.hpp",
+            "third_party/upb/upb/table_internal.h",
             "third_party/upb/upb/text_encode.h",
+            "third_party/upb/upb/upb_internal.h",
             "third_party/upb/upb/upb.h",
             "third_party/upb/upb/upb.hpp",
-            "third_party/upb/upb/upb.int.h",
-            "third_party/upb/third_party/wyhash/wyhash.h",
             "src/core/ext/upb-generated/google/protobuf/descriptor.upb.h",
             "src/core/ext/upbdefs-generated/google/protobuf/descriptor.upbdefs.h",
         ],
index 001a2e5..b2b6279 100644 (file)
       ss.header_mappings_dir = '.'
       ss.libraries = 'z'
       ss.dependency "#{s.name}/Interface", version
-      ss.dependency 'BoringSSL-GRPC', '0.0.19'
+      ss.dependency 'BoringSSL-GRPC', '0.0.20'
       % for abseil_spec in grpc_abseil_specs:
       ss.dependency '${abseil_spec}', abseil_version
       % endfor
index 16c28a0..d5534ce 100644 (file)
@@ -69,7 +69,7 @@
 
   Pod::Spec.new do |s|
     s.name     = 'BoringSSL-GRPC'
-    version = '0.0.19'
+    version = '0.0.20'
     s.version  = version
     s.summary  = 'BoringSSL is a fork of OpenSSL that is designed to meet Google\'s needs.'
     # Adapted from the homepage:
 
     s.prepare_command = <<-END_OF_COMMAND
       # Add a module map and an umbrella header
+      mkdir -p src/include/openssl
       cat > src/include/openssl/umbrella.h <<EOF
         #include "ssl.h"
         #include "crypto.h"
         #include "aes.h"
-        /* The following macros are defined by base.h. The latter is the first file included by the    
-           other headers. */    
-        #if defined(OPENSSL_ARM) || defined(OPENSSL_AARCH64)    
-        #  include "arm_arch.h"   
+        /* The following macros are defined by base.h. The latter is the first file included by the
+           other headers. */
+        #if defined(OPENSSL_ARM) || defined(OPENSSL_AARCH64)
+        #  include "arm_arch.h"
         #endif
         #include "asn1.h"
         #include "asn1_mac.h"
       # limit on the 'prepare_command' field length. The encoded header is generated from
       # /src/boringssl/boringssl_prefix_symbols.h. Here we decode the content and inject the header to
       # the correct location in BoringSSL.
-      base64 -D <<EOF | gunzip > src/include/openssl/boringssl_prefix_symbols.h
+      case "$(uname)" in
+        Darwin) opts="" ;;
+             *) opts="--ignore-garbage" ;;
+      esac
+      base64 --decode $opts <<EOF | gunzip > src/include/openssl/boringssl_prefix_symbols.h
         % for line in compress_boringssl_prefix_header():
         ${line.decode('utf-8')}
         % endfor
diff --git a/templates/tools/dockerfile/debian_8_header.include b/templates/tools/dockerfile/debian_8_header.include
new file mode 100644 (file)
index 0000000..e6d0933
--- /dev/null
@@ -0,0 +1 @@
+FROM debian:8
diff --git a/templates/tools/dockerfile/debian_9_header.include b/templates/tools/dockerfile/debian_9_header.include
new file mode 100644 (file)
index 0000000..2479731
--- /dev/null
@@ -0,0 +1 @@
+FROM debian:9
diff --git a/templates/tools/dockerfile/debian_jessie_header.include b/templates/tools/dockerfile/debian_jessie_header.include
deleted file mode 100644 (file)
index f71f986..0000000
+++ /dev/null
@@ -1 +0,0 @@
-FROM debian:jessie
index ee3c4b6..829bb42 100644 (file)
@@ -17,7 +17,7 @@
   FROM debian:bullseye
   
   # Install clang-tidy 11
-  RUN apt-get update && apt-get install -y clang-tidy-11 jq
+  RUN apt-get update && apt-get install -y clang-tidy-11 jq git
   ENV CLANG_TIDY=clang-tidy-11
 
   ADD clang_tidy_all_the_things.sh /
index 89ddb2c..e234aa5 100644 (file)
@@ -14,7 +14,7 @@
   # See the License for the specific language governing permissions and
   # limitations under the License.
   
-  <%include file="../../debian_jessie_header.include"/>
+  <%include file="../../debian_8_header.include"/>
   
   <%include file="../../apt_get_basic.include"/>
   <%include file="../../python_deps.include"/>
index c0b2b74..dc0ffda 100644 (file)
@@ -12,7 +12,7 @@
 # See the License for the specific language governing permissions and
 # limitations under the License.
 
-<%include file="../../debian_jessie_header.include"/>
+<%include file="../../debian_8_header.include"/>
 
 RUN echo "deb http://archive.debian.org/debian/ jessie-backports main contrib non-free" > /etc/apt/sources.list.d/jessie-backports.list && ${'\\'}
     echo 'Acquire::Check-Valid-Until no;' > /etc/apt/apt.conf.d/99no-check-valid-until && ${'\\'}
index ec6cd29..d19ae52 100644 (file)
@@ -14,7 +14,7 @@
   # See the License for the specific language governing permissions and
   # limitations under the License.
   
-  <%include file="../../debian_jessie_header.include"/>
+  <%include file="../../debian_8_header.include"/>
   
   <%include file="../../apt_get_basic.include"/>
   <%include file="../../python_deps.include"/>
index 1b761c3..9bcc1b6 100644 (file)
@@ -14,7 +14,7 @@
   # See the License for the specific language governing permissions and
   # limitations under the License.
 
-  <%include file="../../debian_jessie_header.include"/>
+  <%include file="../../debian_8_header.include"/>
 
   <%include file="../../apt_get_basic.include"/>
   <%include file="../../node_deps.include"/>
index fe71c76..589084d 100644 (file)
@@ -14,7 +14,7 @@
   # See the License for the specific language governing permissions and
   # limitations under the License.
   
-  <%include file="../../debian_jessie_header.include"/>
+  <%include file="../../debian_8_header.include"/>
   
   <%include file="../../php7_deps.include"/>
   <%include file="../../run_tests_addons.include"/>
index e05e6a1..76c2cc4 100644 (file)
@@ -12,4 +12,4 @@ RUN apt-get update && apt-get install -y ${'\\'}
 RUN curl https://bootstrap.pypa.io/pip/2.7/get-pip.py | python2.7
 RUN pip install --upgrade pip==19.3.1
 RUN pip install virtualenv==16.7.9
-RUN pip install futures==2.2.0 enum34==1.0.4 protobuf==3.5.2.post1 six==1.15.0 twisted==17.5.0
+RUN pip install futures==3.1.1 enum34==1.1.10 protobuf==3.5.2.post1 six==1.16.0 twisted==19.10.0
index 496c263..ca2e750 100644 (file)
@@ -3,7 +3,7 @@
 
 # Install rvm
 RUN apt-get update && apt-get install -y gnupg2 && apt-get clean
-RUN gpg2 --keyserver hkp://pool.sks-keyservers.net --recv-keys 409B6B1796C275462A1703113804BB82D39DC0E3 7D2BAF1CF37B13E2069D6956105BD0E739499BDB
+RUN gpg2 --recv-keys 409B6B1796C275462A1703113804BB82D39DC0E3 7D2BAF1CF37B13E2069D6956105BD0E739499BDB
 RUN \curl -sSL https://get.rvm.io | bash -s stable
 
 # Install Ruby 2.5
index 966d94b..2f2e3d7 100644 (file)
@@ -41,7 +41,7 @@
   # Install Python packages from PyPI
   RUN pip install --upgrade pip==19.3.1
   RUN pip install virtualenv
-  RUN pip install futures==2.2.0 enum34==1.0.4 protobuf==3.5.2.post1 six==1.15.0 twisted==17.5.0
+  RUN pip install futures==3.1.1 enum34==1.1.10 protobuf==3.5.2.post1 six==1.16.0 twisted==19.10.0
   RUN pip install --upgrade --ignore-installed PyYAML==5.4.1 --user
 
   # Google Cloud platform API libraries
index 1fa7c3b..8b8f18f 100644 (file)
@@ -14,7 +14,7 @@
   # See the License for the specific language governing permissions and
   # limitations under the License.
 
-  <%include file="../../debian_jessie_header.include"/>
+  <%include file="../../debian_8_header.include"/>
 
   <%include file="../../apt_get_basic.include"/>
   <%include file="../../python_deps.include"/>
index d5c4153..1777263 100644 (file)
@@ -14,7 +14,7 @@
   # See the License for the specific language governing permissions and
   # limitations under the License.
 
-  <%include file="../../debian_jessie_header.include"/>
+  <%include file="../../debian_8_header.include"/>
 
   <%include file="../../apt_get_basic.include"/>
 
index cf83681..8d8b34b 100644 (file)
@@ -14,7 +14,7 @@
   # See the License for the specific language governing permissions and
   # limitations under the License.
   
-  <%include file="../../debian_jessie_header.include"/>
+  <%include file="../../debian_8_header.include"/>
   
   <%include file="../../php7_deps.include"/>
   <%include file="../../python_deps.include"/>
index a1730ff..f92a97b 100644 (file)
@@ -17,8 +17,6 @@
  */
 
 #include "src/core/lib/address_utils/parse_address.h"
-#include "src/core/lib/address_utils/sockaddr_utils.h"
-#include "src/core/lib/iomgr/sockaddr.h"
 
 #include <string.h>
 #ifdef GRPC_HAVE_UNIX_SOCKET
@@ -28,7 +26,9 @@
 #include <grpc/grpc.h>
 #include <grpc/support/log.h>
 
+#include "src/core/lib/address_utils/sockaddr_utils.h"
 #include "src/core/lib/iomgr/exec_ctx.h"
+#include "src/core/lib/iomgr/sockaddr.h"
 #include "src/core/lib/iomgr/socket_utils.h"
 #include "test/core/util/test_config.h"
 
index cd4f1a5..caec8bf 100644 (file)
  *
  */
 
-#include "src/core/lib/address_utils/parse_address.h"
-#include "src/core/lib/address_utils/sockaddr_utils.h"
-#include "src/core/lib/iomgr/sockaddr.h"
-
 #include <net/if.h>
 #include <string.h>
 #ifdef GRPC_HAVE_UNIX_SOCKET
 #include <grpc/grpc.h>
 #include <grpc/support/log.h>
 
+#include "src/core/lib/address_utils/parse_address.h"
+#include "src/core/lib/address_utils/sockaddr_utils.h"
 #include "src/core/lib/gprpp/host_port.h"
 #include "src/core/lib/gprpp/memory.h"
 #include "src/core/lib/iomgr/exec_ctx.h"
+#include "src/core/lib/iomgr/sockaddr.h"
 #include "src/core/lib/iomgr/socket_utils.h"
 #include "test/core/util/test_config.h"
 
index 208fb22..2c615f1 100644 (file)
 // limitations under the License.
 //
 
-// With the addition of a libuv endpoint, sockaddr.h now includes uv.h when
-// using that endpoint. Because of various transitive includes in uv.h,
-// including windows.h on Windows, uv.h must be included before other system
-// headers. Therefore, sockaddr.h must always be included first
+#include <grpc/support/port_platform.h>
+
 #include "src/core/lib/address_utils/sockaddr_utils.h"
-#include "src/core/lib/iomgr/sockaddr.h"
-#include "src/core/lib/iomgr/socket_utils.h"
 
 #include <errno.h>
 #include <string.h>
@@ -29,7 +25,9 @@
 
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
-#include <grpc/support/port_platform.h>
+
+#include "src/core/lib/iomgr/sockaddr.h"
+#include "src/core/lib/iomgr/socket_utils.h"
 #include "test/core/util/test_config.h"
 
 namespace {
index 62d6059..0a44374 100644 (file)
 
 #include <algorithm>
 
+#include <gtest/gtest.h>
+
 #include <grpc/grpc.h>
 #include <grpc/support/log.h>
 
-#include <gtest/gtest.h>
 #include "test/core/util/test_config.h"
 
 namespace grpc {
index c3a61ed..d2cdb2b 100644 (file)
@@ -35,6 +35,7 @@
 #include "src/core/lib/surface/completion_queue.h"
 #include "src/core/lib/surface/server.h"
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/util/resource_user_util.h"
 
 #define MIN_HTTP2_FRAME_SIZE 9
 
@@ -65,8 +66,10 @@ static void set_done_write(void* arg, grpc_error_handle /*error*/) {
 static void server_setup_transport(void* ts, grpc_transport* transport) {
   thd_args* a = static_cast<thd_args*>(ts);
   grpc_core::ExecCtx exec_ctx;
-  a->server->core_server->SetupTransport(
-      transport, nullptr, a->server->core_server->channel_args(), nullptr);
+  a->server->core_server->SetupTransport(transport,
+                                         /*accepting_pollset=*/nullptr,
+                                         a->server->core_server->channel_args(),
+                                         /*socket_node=*/nullptr);
 }
 
 /* Sets the read_done event */
@@ -196,21 +199,19 @@ void grpc_run_bad_client_test(
   /* Init grpc */
   grpc_init();
 
-  /* Create endpoints */
   sfd = grpc_iomgr_create_endpoint_pair("fixture", nullptr);
-
   /* Create server, completion events */
   a.server = grpc_server_create(nullptr, nullptr);
   a.cq = grpc_completion_queue_create_for_next(nullptr);
   client_cq = grpc_completion_queue_create_for_next(nullptr);
-
   grpc_server_register_completion_queue(a.server, a.cq, nullptr);
   a.registered_method =
       grpc_server_register_method(a.server, GRPC_BAD_CLIENT_REGISTERED_METHOD,
                                   GRPC_BAD_CLIENT_REGISTERED_HOST,
                                   GRPC_SRM_PAYLOAD_READ_INITIAL_BYTE_BUFFER, 0);
   grpc_server_start(a.server);
-  transport = grpc_create_chttp2_transport(nullptr, sfd.server, false);
+  transport = grpc_create_chttp2_transport(
+      nullptr, sfd.server, false, grpc_resource_user_create_unlimited());
   server_setup_transport(&a, transport);
   grpc_chttp2_transport_start_reading(transport, nullptr, nullptr, nullptr);
 
@@ -237,7 +238,6 @@ void grpc_run_bad_client_test(
   /* Shutdown. */
   shutdown_client(&sfd.client);
   server_validator_thd.Join();
-
   shutdown_cq = grpc_completion_queue_create_for_pluck(nullptr);
   grpc_server_shutdown_and_notify(a.server, shutdown_cq, nullptr);
   GPR_ASSERT(grpc_completion_queue_pluck(shutdown_cq, nullptr,
index de7d830..fcd998e 100644 (file)
 #ifndef GRPC_TEST_CORE_BAD_CLIENT_BAD_CLIENT_H
 #define GRPC_TEST_CORE_BAD_CLIENT_BAD_CLIENT_H
 
-#include <grpc/grpc.h>
-
 #include <stdbool.h>
 
+#include <grpc/grpc.h>
+
 #include "test/core/util/test_config.h"
 
 #define GRPC_BAD_CLIENT_REGISTERED_METHOD "/registered/bar"
index 3efc3eb..a76f55d 100644 (file)
@@ -21,6 +21,7 @@
 #include <gtest/gtest.h>
 
 #include <grpc/support/string_util.h>
+
 #include "src/core/lib/surface/server.h"
 #include "test/core/bad_client/bad_client.h"
 
index ab322b2..8c3c5a3 100644 (file)
  *
  */
 
-#include "test/core/bad_client/bad_client.h"
-
 #include <string.h>
 
 #include <grpc/grpc.h>
 
 #include "src/core/lib/surface/server.h"
+#include "test/core/bad_client/bad_client.h"
 #include "test/core/end2end/cq_verifier.h"
 
 #define PFX_STR                      \
index 1fa1fd2..de27663 100644 (file)
  *
  */
 
-#include "test/core/bad_client/bad_client.h"
-
 #include <string.h>
 
 #include <grpc/grpc.h>
 
 #include "src/core/lib/surface/server.h"
+#include "test/core/bad_client/bad_client.h"
 #include "test/core/end2end/cq_verifier.h"
 
 #define PFX_STR                      \
index 08d7bb8..188de86 100644 (file)
  *
  */
 
-#include "test/core/bad_client/bad_client.h"
-
 #include <string.h>
 
 #include <grpc/grpc.h>
 #include <grpc/support/alloc.h>
 
 #include "src/core/lib/surface/server.h"
+#include "test/core/bad_client/bad_client.h"
 #include "test/core/end2end/cq_verifier.h"
 
 static const char prefix[] =
index c1c4fd2..5b45617 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/bad_client/bad_client.h"
-
 #include <string.h>
 
 #include "absl/strings/str_format.h"
 
 #include <grpc/support/alloc.h>
 #include <grpc/support/string_util.h>
+
 #include "src/core/lib/gpr/string.h"
 #include "src/core/lib/surface/server.h"
+#include "test/core/bad_client/bad_client.h"
 #include "test/core/end2end/cq_verifier.h"
 
 // The large-metadata headers that we're adding for this test are not
index 0e38223..ce3f1d8 100644 (file)
@@ -21,6 +21,7 @@
 #include <gtest/gtest.h>
 
 #include <grpc/support/string_util.h>
+
 #include "src/core/lib/surface/server.h"
 #include "test/core/bad_client/bad_client.h"
 
index 69e2692..e176f61 100644 (file)
  *
  */
 
-#include "test/core/bad_client/bad_client.h"
-
 #include <string.h>
 
 #include "src/core/lib/surface/server.h"
+#include "test/core/bad_client/bad_client.h"
 #include "test/core/end2end/cq_verifier.h"
 
 #define PFX_STR                                               \
index a4aacc2..3c4bd84 100644 (file)
  *
  */
 
-#include "test/core/bad_client/bad_client.h"
-
 #include <string.h>
 
 #include <grpc/grpc.h>
 
 #include "src/core/lib/surface/server.h"
+#include "test/core/bad_client/bad_client.h"
 #include "test/core/end2end/cq_verifier.h"
 
 #define PFX_STR                                                            \
index 645c08f..04ce10e 100644 (file)
@@ -21,6 +21,7 @@
 #include <gtest/gtest.h>
 
 #include <grpc/support/string_util.h>
+
 #include "src/core/lib/surface/server.h"
 #include "test/core/bad_client/bad_client.h"
 
index dbb98a2..cff0cfb 100644 (file)
  *
  */
 
-#include "test/core/bad_client/bad_client.h"
-
 #include <string.h>
 
 #include <grpc/grpc.h>
 #include <grpc/support/alloc.h>
 
 #include "src/core/lib/surface/server.h"
+#include "test/core/bad_client/bad_client.h"
 
 #define PFX_STR                                                            \
   "\x00\x00\x00\x04\x01\x00\x00\x00\x00"                                   \
index 2be36fc..4b4c1a7 100644 (file)
@@ -26,8 +26,6 @@
 // This test won't work except with posix sockets enabled
 #ifdef GRPC_POSIX_SOCKET_TCP
 
-#include "test/core/util/test_config.h"
-
 #include <stdio.h>
 #include <string.h>
 #include <unistd.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/time.h>
+
 #include "src/core/ext/transport/chttp2/transport/chttp2_transport.h"
 #include "src/core/lib/iomgr/endpoint_pair.h"
 #include "src/core/lib/surface/channel.h"
 #include "src/core/lib/surface/completion_queue.h"
 #include "src/core/lib/surface/server.h"
+#include "test/core/util/resource_user_util.h"
+#include "test/core/util/test_config.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
 
@@ -88,15 +89,17 @@ static void client_setup_transport(grpc_transport* transport) {
       grpc_channel_args_copy_and_add(nullptr, &authority_arg, 1);
   /* TODO (pjaikumar): use GRPC_CLIENT_CHANNEL instead of
    * GRPC_CLIENT_DIRECT_CHANNEL */
-  g_ctx.client = grpc_channel_create("socketpair-target", args,
-                                     GRPC_CLIENT_DIRECT_CHANNEL, transport);
+  g_ctx.client =
+      grpc_channel_create("socketpair-target", args, GRPC_CLIENT_DIRECT_CHANNEL,
+                          transport, nullptr, 0, nullptr);
   grpc_channel_args_destroy(args);
 }
 
 static void init_client() {
   grpc_core::ExecCtx exec_ctx;
   grpc_transport* transport;
-  transport = grpc_create_chttp2_transport(nullptr, g_ctx.ep->client, true);
+  transport = grpc_create_chttp2_transport(
+      nullptr, g_ctx.ep->client, true, grpc_resource_user_create_unlimited());
   client_setup_transport(transport);
   GPR_ASSERT(g_ctx.client);
   grpc_chttp2_transport_start_reading(transport, nullptr, nullptr, nullptr);
@@ -109,7 +112,8 @@ static void init_server() {
   g_ctx.server = grpc_server_create(nullptr, nullptr);
   grpc_server_register_completion_queue(g_ctx.server, g_ctx.cq, nullptr);
   grpc_server_start(g_ctx.server);
-  transport = grpc_create_chttp2_transport(nullptr, g_ctx.ep->server, false);
+  transport = grpc_create_chttp2_transport(
+      nullptr, g_ctx.ep->server, false, grpc_resource_user_create_unlimited());
   server_setup_transport(transport);
   grpc_chttp2_transport_start_reading(transport, nullptr, nullptr, nullptr);
 }
index 88740a4..d3e1a34 100644 (file)
  *
  */
 
-#include <grpc/support/log.h>
+#include "test/core/bad_ssl/server_common.h"
+
 #include <signal.h>
 
-#include "test/core/bad_ssl/server_common.h"
+#include <grpc/support/log.h>
+
 #include "test/core/util/cmdline.h"
 #include "test/core/util/test_config.h"
 
index 795a856..27a9aa4 100644 (file)
 
 #include "src/core/ext/transport/chttp2/alpn/alpn.h"
 
+#include <string.h>
+
 #include <grpc/grpc.h>
 #include <grpc/grpc_security.h>
 #include <grpc/support/log.h>
-#include <string.h>
 
 #include "src/core/lib/gpr/useful.h"
 #include "src/core/lib/iomgr/load_file.h"
index 785e10b..7b95eb3 100644 (file)
@@ -23,7 +23,6 @@
 #include <grpc/support/log.h>
 
 #include "src/core/lib/iomgr/load_file.h"
-
 #include "test/core/bad_ssl/server_common.h"
 
 /* This server will present an untrusted cert to the connecting client,
index 6f7ebc6..8680d3c 100644 (file)
  *
  */
 
-#include <grpc/impl/codegen/grpc_types.h>
-#include <grpc/impl/codegen/log.h>
+#include "src/core/lib/channel/channel_args.h"
+
 #include <string.h>
 
+#include <grpc/impl/codegen/grpc_types.h>
+#include <grpc/impl/codegen/log.h>
 #include <grpc/support/log.h>
 
-#include "src/core/lib/channel/channel_args.h"
 #include "src/core/lib/channel/channel_stack.h"
 #include "src/core/lib/gpr/useful.h"
 #include "src/core/lib/iomgr/exec_ctx.h"
index 0ecefed..824bd21 100644 (file)
@@ -16,6 +16,8 @@
  *
  */
 
+#include "src/core/lib/channel/channel_trace.h"
+
 #include <stdlib.h>
 #include <string.h>
 
 #include <grpc/support/log.h>
 #include <grpc/support/string_util.h>
 
-#include "src/core/lib/channel/channel_trace.h"
 #include "src/core/lib/channel/channelz.h"
 #include "src/core/lib/channel/channelz_registry.h"
 #include "src/core/lib/gpr/useful.h"
 #include "src/core/lib/iomgr/exec_ctx.h"
 #include "src/core/lib/json/json.h"
 #include "src/core/lib/surface/channel.h"
-
 #include "test/core/util/test_config.h"
 #include "test/cpp/util/channel_trace_proto_helper.h"
 
-#include <stdlib.h>
-#include <string.h>
-
 namespace grpc_core {
 namespace channelz {
 namespace testing {
index eca7f20..166dcdf 100644 (file)
  *
  */
 
+#include "src/core/lib/channel/channelz_registry.h"
+
 #include <stdlib.h>
 #include <string.h>
 
-#include <grpc/grpc.h>
 #include <gtest/gtest.h>
 
+#include <grpc/grpc.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/string_util.h>
 
 #include "src/core/lib/channel/channel_trace.h"
 #include "src/core/lib/channel/channelz.h"
-#include "src/core/lib/channel/channelz_registry.h"
 #include "src/core/lib/gpr/useful.h"
 #include "src/core/lib/gprpp/memory.h"
 #include "src/core/lib/iomgr/exec_ctx.h"
@@ -36,9 +37,6 @@
 #include "src/core/lib/surface/channel.h"
 #include "test/core/util/test_config.h"
 
-#include <stdlib.h>
-#include <string.h>
-
 namespace grpc_core {
 namespace channelz {
 namespace testing {
index cc17a33..bd59ea4 100644 (file)
@@ -16,6 +16,8 @@
  *
  */
 
+#include "src/core/lib/channel/channelz.h"
+
 #include <stdlib.h>
 #include <string.h>
 
 
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
+#include <grpc/support/string_util.h>
 
 #include "src/core/lib/channel/channel_trace.h"
-#include "src/core/lib/channel/channelz.h"
 #include "src/core/lib/channel/channelz_registry.h"
 #include "src/core/lib/gpr/useful.h"
 #include "src/core/lib/iomgr/exec_ctx.h"
 #include "src/core/lib/json/json.h"
 #include "src/core/lib/surface/channel.h"
 #include "src/core/lib/surface/server.h"
-
 #include "test/core/util/test_config.h"
 #include "test/cpp/util/channel_trace_proto_helper.h"
 
-#include <grpc/support/string_util.h>
-#include <stdlib.h>
-#include <string.h>
-
 namespace grpc_core {
 namespace channelz {
 namespace testing {
index a222242..5aca1fe 100644 (file)
  * configurations and assess whether such a change is correct and desirable.
  */
 
-#include <grpc/grpc.h>
-#include <grpc/support/alloc.h>
-#include <grpc/support/string_util.h>
 #include <string.h>
 
 #include "absl/strings/str_cat.h"
 #include "absl/strings/str_format.h"
 #include "absl/strings/str_join.h"
 
+#include <grpc/grpc.h>
+#include <grpc/support/alloc.h>
+#include <grpc/support/string_util.h>
+
 #include "src/core/lib/channel/channel_stack_builder.h"
 #include "src/core/lib/gpr/string.h"
 #include "src/core/lib/surface/channel_init.h"
index ef33b14..3717d8b 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include <gmock/gmock.h>
-
 #include "src/core/ext/xds/certificate_provider_registry.h"
 
+#include <gmock/gmock.h>
+
 #include "test/core/util/test_config.h"
 
 namespace grpc_core {
index 0d20844..010fb1c 100644 (file)
@@ -16,6 +16,8 @@
  *
  */
 
+#include "src/core/ext/filters/client_channel/resolver/fake/fake_resolver.h"
+
 #include <string.h>
 
 #include <string>
@@ -25,7 +27,6 @@
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 
-#include "src/core/ext/filters/client_channel/resolver/fake/fake_resolver.h"
 #include "src/core/ext/filters/client_channel/resolver_registry.h"
 #include "src/core/ext/filters/client_channel/server_address.h"
 #include "src/core/lib/address_utils/parse_address.h"
@@ -33,7 +34,6 @@
 #include "src/core/lib/gprpp/ref_counted_ptr.h"
 #include "src/core/lib/iomgr/work_serializer.h"
 #include "src/core/lib/security/credentials/fake/fake_credentials.h"
-
 #include "test/core/util/test_config.h"
 
 class ResultHandler : public grpc_core::Resolver::ResultHandler {
index 8b06925..5c77d31 100644 (file)
@@ -25,7 +25,6 @@
 #include "src/core/ext/filters/client_channel/resolver_registry.h"
 #include "src/core/lib/channel/channel_args.h"
 #include "src/core/lib/iomgr/work_serializer.h"
-
 #include "test/core/util/test_config.h"
 
 static std::shared_ptr<grpc_core::WorkSerializer>* g_work_serializer;
index e22a26f..d281ccf 100644 (file)
  *
  */
 
-#include "absl/strings/str_cat.h"
+#include "src/core/ext/filters/client_channel/service_config.h"
 
 #include <gmock/gmock.h>
 #include <gtest/gtest.h>
 
+#include "absl/strings/str_cat.h"
+
 #include <grpc/grpc.h>
+
 #include "src/core/ext/filters/client_channel/resolver_result_parsing.h"
 #include "src/core/ext/filters/client_channel/retry_service_config.h"
-#include "src/core/ext/filters/client_channel/service_config.h"
 #include "src/core/ext/filters/client_channel/service_config_parser.h"
 #include "src/core/ext/filters/message_size/message_size_filter.h"
 #include "src/core/lib/gpr/string.h"
diff --git a/test/core/compiler_bugs/BUILD b/test/core/compiler_bugs/BUILD
new file mode 100644 (file)
index 0000000..aeb64e0
--- /dev/null
@@ -0,0 +1,31 @@
+# Copyright 2021 gRPC authors.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+load("//bazel:grpc_build_system.bzl", "grpc_cc_test", "grpc_package")
+
+licenses(["notice"])
+
+grpc_package(name = "test/core/compiler_bugs")
+
+grpc_cc_test(
+    name = "miscompile_with_no_unique_address_test",
+    srcs = ["miscompile_with_no_unique_address_test.cc"],
+    external_deps = ["gtest"],
+    language = "c++",
+    uses_polling = False,
+    deps = [
+        "//:gpr_platform",
+        "//test/core/util:grpc_suppressions",
+    ],
+)
diff --git a/test/core/compiler_bugs/miscompile_with_no_unique_address_test.cc b/test/core/compiler_bugs/miscompile_with_no_unique_address_test.cc
new file mode 100644 (file)
index 0000000..73e39f5
--- /dev/null
@@ -0,0 +1,59 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#include <grpc/impl/codegen/port_platform.h>
+
+#include <gtest/gtest.h>
+
+// Make a template argument to test which bit pattern remains in A's destructor
+// to try and detect similar bugs in non-MSAN builds (none have been detected
+// yet thankfully)
+template <int kInit>
+class A {
+ public:
+  ~A() { EXPECT_EQ(a_, kInit); }
+  int a_ = kInit;
+};
+template <class T, int kInit>
+class P : A<kInit> {
+ public:
+  explicit P(T b) : b_(b) {}
+  // clang 11 with MSAN miscompiles this and marks A::a_ as uninitialized during
+  // P::~P() if GPR_NO_UNIQUE_ADDRESS is [[no_unique_address]] - so this test
+  // stands to ensure that we have a working definition for this compiler so
+  // that we don't flag false negatives elsewhere in the codebase.
+  GPR_NO_UNIQUE_ADDRESS T b_;
+};
+
+template <int kInit, class T>
+void c(T a) {
+  P<T, kInit> _(a);
+}
+
+TEST(Miscompile, Zero) {
+  c<0>([] {});
+}
+
+TEST(Miscompile, One) {
+  c<1>([] {});
+}
+
+TEST(Miscompile, MinusOne) {
+  c<-1>([] {});
+}
+
+int main(int argc, char** argv) {
+  ::testing::InitGoogleTest(&argc, argv);
+  return RUN_ALL_TESTS();
+}
index c32820f..b28aaf5 100644 (file)
  *
  */
 
-#include "src/core/lib/compression/algorithm_metadata.h"
-
 #include <stdlib.h>
 #include <string.h>
 
 #include <grpc/grpc.h>
 #include <grpc/support/log.h>
 
+#include "src/core/lib/compression/algorithm_metadata.h"
 #include "src/core/lib/iomgr/exec_ctx.h"
 #include "src/core/lib/slice/slice_internal.h"
 #include "src/core/lib/transport/static_metadata.h"
index ebc947a..c698e90 100644 (file)
  *
  */
 
-#include <grpc/grpc.h>
 #include <stdbool.h>
 #include <stdint.h>
 #include <string.h>
 
+#include <grpc/grpc.h>
+
 #include "src/core/lib/compression/message_compress.h"
 #include "src/core/lib/security/credentials/credentials.h"
 #include "test/core/util/memory_counters.h"
index 9615582..d11e8e4 100644 (file)
@@ -124,7 +124,6 @@ static compressability get_compressability(
       return SHOULD_COMPRESS;
     case TEST_VALUE_COUNT:
       abort();
-      break;
   }
   return MAYBE_COMPRESSES;
 }
@@ -139,7 +138,6 @@ static grpc_slice create_test_value(test_value id) {
       return repeated('a', 1024 * 1024);
     case TEST_VALUE_COUNT:
       abort();
-      break;
   }
   return grpc_slice_from_copied_string("bad value");
 }
index 3f78caa..1d6eb45 100644 (file)
  *
  */
 
-#include <grpc/grpc.h>
 #include <stdbool.h>
 #include <stdint.h>
 #include <string.h>
 
+#include <grpc/grpc.h>
+
 #include "src/core/lib/compression/message_compress.h"
 #include "src/core/lib/security/credentials/credentials.h"
 #include "test/core/util/memory_counters.h"
index 0f123a1..55bc4d6 100644 (file)
  *
  */
 
-#include <grpc/grpc.h>
 #include <stdbool.h>
 #include <stdint.h>
 #include <string.h>
 
+#include <grpc/grpc.h>
+
 #include "src/core/lib/compression/stream_compression.h"
 #include "src/core/lib/security/credentials/credentials.h"
 #include "test/core/util/memory_counters.h"
index 9d5e137..252652f 100644 (file)
@@ -16,6 +16,8 @@
  *
  */
 
+#include "src/core/lib/compression/stream_compression.h"
+
 #include <string.h>
 
 #include <grpc/grpc.h>
@@ -23,7 +25,6 @@
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 
-#include "src/core/lib/compression/stream_compression.h"
 #include "test/core/util/test_config.h"
 
 static void generate_random_payload(char* payload, size_t size) {
index 14695cb..cbfbd5d 100644 (file)
  *
  */
 
-#include <grpc/grpc.h>
 #include <stdbool.h>
 #include <stdint.h>
 #include <string.h>
 
+#include <grpc/grpc.h>
+
 #include "src/core/lib/compression/stream_compression.h"
 #include "src/core/lib/security/credentials/credentials.h"
 #include "test/core/util/memory_counters.h"
diff --git a/test/core/config/BUILD b/test/core/config/BUILD
new file mode 100644 (file)
index 0000000..0d4ac2c
--- /dev/null
@@ -0,0 +1,31 @@
+# Copyright 2021 gRPC authors.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+load("//bazel:grpc_build_system.bzl", "grpc_cc_test", "grpc_package")
+
+licenses(["notice"])
+
+grpc_package(name = "test/core/config")
+
+grpc_cc_test(
+    name = "core_configuration_test",
+    srcs = ["core_configuration_test.cc"],
+    external_deps = ["gtest"],
+    language = "c++",
+    uses_polling = False,
+    deps = [
+        "//:config",
+        "//test/core/util:grpc_suppressions",
+    ],
+)
diff --git a/test/core/config/core_configuration_test.cc b/test/core/config/core_configuration_test.cc
new file mode 100644 (file)
index 0000000..814c383
--- /dev/null
@@ -0,0 +1,73 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#include "src/core/lib/config/core_configuration.h"
+
+#include <chrono>
+#include <thread>
+
+#include <gtest/gtest.h>
+
+namespace grpc_core {
+
+// Allow substitution of config builder - in real code this would iterate
+// through all plugins
+namespace testing {
+using ConfigBuilderFunction = std::function<void(CoreConfiguration::Builder*)>;
+static ConfigBuilderFunction g_mock_builder;
+}  // namespace testing
+
+void BuildCoreConfiguration(CoreConfiguration::Builder* builder) {
+  ::grpc_core::testing::g_mock_builder(builder);
+}
+
+namespace testing {
+// Helper for testing - clear out any state, rebuild configuration with fn being
+// the initializer
+void InitConfigWithBuilder(ConfigBuilderFunction fn) {
+  CoreConfiguration::Reset();
+  g_mock_builder = fn;
+  CoreConfiguration::Get();
+  g_mock_builder = nullptr;
+}
+
+TEST(ConfigTest, NoopConfig) {
+  InitConfigWithBuilder([](CoreConfiguration::Builder*) {});
+  CoreConfiguration::Get();
+}
+
+TEST(ConfigTest, ThreadedInit) {
+  CoreConfiguration::Reset();
+  g_mock_builder = [](CoreConfiguration::Builder*) {
+    std::this_thread::sleep_for(std::chrono::seconds(1));
+  };
+  std::vector<std::thread> threads;
+  threads.reserve(64);
+  for (int i = 0; i < 64; i++) {
+    threads.push_back(std::thread([]() { CoreConfiguration::Get(); }));
+  }
+  for (auto& t : threads) {
+    t.join();
+  }
+  g_mock_builder = nullptr;
+  CoreConfiguration::Get();
+}
+}  // namespace testing
+
+}  // namespace grpc_core
+
+int main(int argc, char** argv) {
+  ::testing::InitGoogleTest(&argc, argv);
+  return RUN_ALL_TESTS();
+}
index 252dbd4..fe8fe49 100644 (file)
 #include <mutex>
 #include <thread>
 
+#include <gtest/gtest.h>
+
 #include <grpc/grpc.h>
 #include <grpc/support/cpu.h>
 #include <grpc/support/log.h>
-#include <gtest/gtest.h>
 
 #include "test/core/util/test_config.h"
 
index b4e2707..c906ad5 100644 (file)
  *
  */
 
-/* With the addition of a libuv endpoint, sockaddr.h now includes uv.h when
-   using that endpoint. Because of various transitive includes in uv.h,
-   including windows.h on Windows, uv.h must be included before other system
-   headers. Therefore, sockaddr.h must always be included first */
-#include "src/core/lib/iomgr/sockaddr.h"
-
 #include <string.h>
 
 #include <grpc/grpc.h>
index 59d7c69..6fd40fd 100644 (file)
@@ -28,7 +28,6 @@
 #include "src/core/lib/iomgr/exec_ctx.h"
 #include "src/core/lib/slice/slice_internal.h"
 #include "src/core/lib/transport/metadata.h"
-
 #include "test/core/end2end/cq_verifier.h"
 #include "test/core/util/port.h"
 #include "test/core/util/test_config.h"
index b110ed6..7d84727 100644 (file)
@@ -36,6 +36,7 @@
 #include <grpc/support/log.h>
 #include <grpc/support/string_util.h>
 #include <grpc/support/time.h>
+
 #include "src/core/lib/compression/compression_internal.h"
 #include "src/core/lib/compression/message_compress.h"
 #include "src/core/lib/gpr/string.h"
@@ -209,7 +210,6 @@ std::string ExpectationString(const Expectation& e) {
     case GRPC_QUEUE_SHUTDOWN:
       gpr_log(GPR_ERROR, "not implemented");
       abort();
-      break;
   }
   return out;
 }
@@ -243,11 +243,9 @@ static void verify_matches(const Expectation& e, const grpc_event& ev) {
     case GRPC_QUEUE_SHUTDOWN:
       gpr_log(GPR_ERROR, "premature queue shutdown");
       abort();
-      break;
     case GRPC_QUEUE_TIMEOUT:
       gpr_log(GPR_ERROR, "not implemented");
       abort();
-      break;
   }
 }
 
index 48bf018..9e6b3ab 100644 (file)
@@ -22,6 +22,7 @@
 #include <stdbool.h>
 
 #include <grpc/grpc.h>
+
 #include "test/core/util/test_config.h"
 
 /* A cq_verifier can verify that expected events arrive in a timely fashion
index e93956b..d65dbca 100644 (file)
@@ -16,9 +16,6 @@
  *
  */
 
-/* This check is for testing only. */
-#ifndef GRPC_UV
-
 #include <grpc/support/alloc.h>
 
 #include "test/core/end2end/cq_verifier_internal.h"
@@ -56,5 +53,3 @@ grpc_event cq_verifier_next_event(cq_verifier* v, int timeout_seconds) {
       grpc_timeout_seconds_to_deadline(timeout_seconds);
   return grpc_completion_queue_next(v->cq, deadline, nullptr);
 }
-
-#endif /* GRPC_UV */
diff --git a/test/core/end2end/cq_verifier_uv.cc b/test/core/end2end/cq_verifier_uv.cc
deleted file mode 100644 (file)
index 45d827e..0000000
+++ /dev/null
@@ -1,97 +0,0 @@
-/*
- *
- * Copyright 2016 gRPC authors.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- *
- */
-
-#include <grpc/support/port_platform.h>
-
-#ifdef GRPC_UV
-
-#include <uv.h>
-
-#include <grpc/support/alloc.h>
-#include <grpc/support/log.h>
-
-#include "test/core/end2end/cq_verifier_internal.h"
-
-typedef enum timer_state {
-  TIMER_STARTED,
-  TIMER_TRIGGERED,
-  TIMER_CLOSED
-} timer_state;
-
-/* the verifier itself */
-struct cq_verifier {
-  /* bound completion queue */
-  grpc_completion_queue* cq;
-  /* start of expectation list */
-  expectation* first_expectation;
-  uv_timer_t timer;
-};
-
-cq_verifier* cq_verifier_create(grpc_completion_queue* cq) {
-  cq_verifier* v = static_cast<cq_verifier*>(gpr_malloc(sizeof(cq_verifier)));
-  v->cq = cq;
-  v->first_expectation = NULL;
-  uv_timer_init(uv_default_loop(), &v->timer);
-  v->timer.data = (void*)TIMER_STARTED;
-  return v;
-}
-
-static void timer_close_cb(uv_handle_t* handle) {
-  handle->data = (void*)TIMER_CLOSED;
-}
-
-void cq_verifier_destroy(cq_verifier* v) {
-  cq_verify(v);
-  uv_close((uv_handle_t*)&v->timer, timer_close_cb);
-  while (static_cast<timer_state>(v->timer.data) != TIMER_CLOSED) {
-    uv_run(uv_default_loop(), UV_RUN_NOWAIT);
-  }
-  gpr_free(v);
-}
-
-expectation* cq_verifier_get_first_expectation(cq_verifier* v) {
-  return v->first_expectation;
-}
-
-void cq_verifier_set_first_expectation(cq_verifier* v, expectation* e) {
-  v->first_expectation = e;
-}
-
-static void timer_run_cb(uv_timer_t* timer) {
-  timer->data = (void*)TIMER_TRIGGERED;
-}
-
-grpc_event cq_verifier_next_event(cq_verifier* v, int timeout_seconds) {
-  uint64_t timeout_ms =
-      timeout_seconds < 0 ? 0 : (uint64_t)timeout_seconds * 1000;
-  grpc_event ev;
-  v->timer.data = (void*)TIMER_STARTED;
-  uv_timer_start(&v->timer, timer_run_cb, timeout_ms, 0);
-  ev = grpc_completion_queue_next(v->cq, gpr_inf_past(GPR_CLOCK_MONOTONIC),
-                                  NULL);
-  // Stop the loop if the timer goes off or we get a non-timeout event
-  while ((static_cast<timer_state>(v->timer.data) != TIMER_TRIGGERED) &&
-         ev.type == GRPC_QUEUE_TIMEOUT) {
-    uv_run(uv_default_loop(), UV_RUN_ONCE);
-    ev = grpc_completion_queue_next(v->cq, gpr_inf_past(GPR_CLOCK_MONOTONIC),
-                                    NULL);
-  }
-  return ev;
-}
-
-#endif /* GRPC_UV */
index 51d2730..c592761 100644 (file)
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <string.h>
 
 #include <grpc/support/log.h>
 
+#include "test/core/end2end/end2end_tests.h"
+
 const char* get_host_override_string(const char* str,
                                      grpc_end2end_test_config config) {
   if (config.feature_mask & FEATURE_MASK_SUPPORTS_AUTHORITY_HEADER) {
index f99a626..3908936 100644 (file)
@@ -177,6 +177,8 @@ extern void retry_throttled(grpc_end2end_test_config config);
 extern void retry_throttled_pre_init(void);
 extern void retry_too_many_attempts(grpc_end2end_test_config config);
 extern void retry_too_many_attempts_pre_init(void);
+extern void sdk_authz(grpc_end2end_test_config config);
+extern void sdk_authz_pre_init(void);
 extern void server_finishes_request(grpc_end2end_test_config config);
 extern void server_finishes_request_pre_init(void);
 extern void server_streaming(grpc_end2end_test_config config);
@@ -287,6 +289,7 @@ void grpc_end2end_tests_pre_init(void) {
   retry_streaming_succeeds_before_replay_finished_pre_init();
   retry_throttled_pre_init();
   retry_too_many_attempts_pre_init();
+  sdk_authz_pre_init();
   server_finishes_request_pre_init();
   server_streaming_pre_init();
   shutdown_finishes_calls_pre_init();
@@ -387,6 +390,7 @@ void grpc_end2end_tests(int argc, char **argv,
     retry_streaming_succeeds_before_replay_finished(config);
     retry_throttled(config);
     retry_too_many_attempts(config);
+    sdk_authz(config);
     server_finishes_request(config);
     server_streaming(config);
     shutdown_finishes_calls(config);
@@ -703,6 +707,10 @@ void grpc_end2end_tests(int argc, char **argv,
       retry_too_many_attempts(config);
       continue;
     }
+    if (0 == strcmp("sdk_authz", argv[i])) {
+      sdk_authz(config);
+      continue;
+    }
     if (0 == strcmp("server_finishes_request", argv[i])) {
       server_finishes_request(config);
       continue;
index 2e84296..6ab374e 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <string.h>
 
 #include <grpc/support/alloc.h>
@@ -32,6 +30,7 @@
 #include "src/core/lib/gprpp/host_port.h"
 #include "src/core/lib/surface/channel.h"
 #include "src/core/lib/surface/server.h"
+#include "test/core/end2end/end2end_tests.h"
 #include "test/core/util/port.h"
 #include "test/core/util/test_config.h"
 
index 9bc359a..f0de5c6 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <string.h>
 
 #include <grpc/support/alloc.h>
@@ -33,6 +31,7 @@
 #include "src/core/lib/gprpp/host_port.h"
 #include "src/core/lib/surface/channel.h"
 #include "src/core/lib/surface/server.h"
+#include "test/core/end2end/end2end_tests.h"
 #include "test/core/util/port.h"
 #include "test/core/util/test_config.h"
 
index b38e90c..156185a 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -27,6 +25,7 @@
 #include "src/core/lib/channel/channel_args.h"
 #include "src/core/lib/gprpp/host_port.h"
 #include "src/core/lib/security/credentials/fake/fake_credentials.h"
+#include "test/core/end2end/end2end_tests.h"
 #include "test/core/util/port.h"
 #include "test/core/util/test_config.h"
 
index 9ef0375..bd977c9 100644 (file)
@@ -21,8 +21,6 @@
 // This test won't work except with posix sockets enabled
 #ifdef GRPC_POSIX_SOCKET
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <fcntl.h>
 #include <string.h>
 
 #include <grpc/grpc_posix.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
+
 #include "src/core/lib/iomgr/exec_ctx.h"
 #include "src/core/lib/iomgr/socket_utils_posix.h"
 #include "src/core/lib/iomgr/unix_sockets_posix.h"
+#include "test/core/end2end/end2end_tests.h"
 #include "test/core/util/test_config.h"
 
 typedef struct {
index dd5ae5b..f26c390 100644 (file)
@@ -21,8 +21,6 @@
 // This test requires posix wakeup fds
 #ifdef GRPC_POSIX_WAKEUP_FD
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <string.h>
 
 #include <grpc/support/alloc.h>
@@ -37,6 +35,7 @@
 #include "src/core/lib/iomgr/wakeup_fd_posix.h"
 #include "src/core/lib/surface/channel.h"
 #include "src/core/lib/surface/server.h"
+#include "test/core/end2end/end2end_tests.h"
 #include "test/core/util/port.h"
 #include "test/core/util/test_config.h"
 
index 68cf39a..48085e9 100644 (file)
  *
  */
 
-#include "src/core/lib/iomgr/port.h"
-
-#include "test/core/end2end/end2end_tests.h"
-
 #include <string.h>
 #ifdef GRPC_POSIX_SOCKET
 #include <unistd.h>
 #include "src/core/lib/channel/connected_channel.h"
 #include "src/core/lib/debug/trace.h"
 #include "src/core/lib/gprpp/host_port.h"
+#include "src/core/lib/iomgr/port.h"
 #include "src/core/lib/surface/channel.h"
 #include "src/core/lib/surface/server.h"
+#include "test/core/end2end/end2end_tests.h"
 #include "test/core/util/port.h"
 #include "test/core/util/test_config.h"
 
index 13c1f1f..55a7354 100644 (file)
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <string.h>
 
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/sync.h>
-
 #include <grpc/support/workaround_list.h>
 
 #include "src/core/ext/filters/client_channel/client_channel.h"
@@ -33,6 +30,7 @@
 #include "src/core/lib/gprpp/host_port.h"
 #include "src/core/lib/surface/channel.h"
 #include "src/core/lib/surface/server.h"
+#include "test/core/end2end/end2end_tests.h"
 #include "test/core/util/port.h"
 #include "test/core/util/test_config.h"
 
index 16c9128..074ec7f 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <string.h>
 
 #include <grpc/support/alloc.h>
@@ -31,6 +29,7 @@
 #include "src/core/lib/gprpp/host_port.h"
 #include "src/core/lib/surface/channel.h"
 #include "src/core/lib/surface/server.h"
+#include "test/core/end2end/end2end_tests.h"
 #include "test/core/util/port.h"
 #include "test/core/util/test_config.h"
 
index 957beb3..61a3955 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <string.h>
 
 #include <string>
@@ -36,6 +34,7 @@
 #include "src/core/lib/gprpp/host_port.h"
 #include "src/core/lib/surface/channel.h"
 #include "src/core/lib/surface/server.h"
+#include "test/core/end2end/end2end_tests.h"
 #include "test/core/end2end/fixtures/http_proxy_fixture.h"
 #include "test/core/util/port.h"
 #include "test/core/util/test_config.h"
index f6d6d23..13ac3e8 100644 (file)
@@ -16,8 +16,6 @@
 //
 //
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <string.h>
 
 #include <grpc/grpc_security.h>
@@ -26,6 +24,7 @@
 
 #include "src/core/lib/channel/channel_args.h"
 #include "src/core/lib/gprpp/host_port.h"
+#include "test/core/end2end/end2end_tests.h"
 #include "test/core/util/port.h"
 #include "test/core/util/test_config.h"
 
index 2cc53d0..1f71fda 100644 (file)
  *
  */
 
-#include <grpc/support/alloc.h>
-#include <grpc/support/log.h>
 #include <stdio.h>
 #include <string.h>
 
+#include <grpc/support/alloc.h>
+#include <grpc/support/log.h>
+
 #include "src/core/lib/channel/channel_args.h"
 #include "src/core/lib/gprpp/host_port.h"
 #include "src/core/lib/iomgr/iomgr.h"
index fcc508e..134a65c 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <string.h>
 
 #include <grpc/support/alloc.h>
@@ -30,6 +28,7 @@
 #include "src/core/lib/channel/connected_channel.h"
 #include "src/core/lib/surface/channel.h"
 #include "src/core/lib/surface/server.h"
+#include "test/core/end2end/end2end_tests.h"
 #include "test/core/end2end/fixtures/proxy.h"
 #include "test/core/util/port.h"
 #include "test/core/util/test_config.h"
index 67ac6fe..c3e3355 100644 (file)
  *
  */
 
-#include "src/core/lib/iomgr/port.h"
-
-#include "test/core/end2end/end2end_tests.h"
-
 #include <string.h>
 #ifdef GRPC_POSIX_SOCKET
 #include <unistd.h>
 #include "src/core/lib/debug/trace.h"
 #include "src/core/lib/iomgr/endpoint_pair.h"
 #include "src/core/lib/iomgr/iomgr.h"
+#include "src/core/lib/iomgr/port.h"
 #include "src/core/lib/surface/channel.h"
 #include "src/core/lib/surface/completion_queue.h"
 #include "src/core/lib/surface/server.h"
+#include "test/core/end2end/end2end_tests.h"
 #include "test/core/util/port.h"
 #include "test/core/util/test_config.h"
 
 /* chttp2 transport that is immediately available (used for testing
    connected_channel without a client_channel */
 
+struct custom_fixture_data {
+  grpc_endpoint_pair ep;
+  grpc_resource_quota* resource_quota;
+};
+
 static void server_setup_transport(void* ts, grpc_transport* transport) {
   grpc_end2end_test_fixture* f = static_cast<grpc_end2end_test_fixture*>(ts);
   grpc_core::ExecCtx exec_ctx;
-  grpc_endpoint_pair* sfd = static_cast<grpc_endpoint_pair*>(f->fixture_data);
-  grpc_endpoint_add_to_pollset(sfd->server, grpc_cq_pollset(f->cq));
+  custom_fixture_data* fixture_data =
+      static_cast<custom_fixture_data*>(f->fixture_data);
+  grpc_endpoint_add_to_pollset(fixture_data->ep.server, grpc_cq_pollset(f->cq));
   grpc_error_handle error = f->server->core_server->SetupTransport(
       transport, nullptr, f->server->core_server->channel_args(), nullptr);
   if (error == GRPC_ERROR_NONE) {
@@ -77,7 +81,7 @@ static void client_setup_transport(void* ts, grpc_transport* transport) {
   grpc_error_handle error = GRPC_ERROR_NONE;
   cs->f->client =
       grpc_channel_create("socketpair-target", args, GRPC_CLIENT_DIRECT_CHANNEL,
-                          transport, nullptr, &error);
+                          transport, nullptr, 0, &error);
   grpc_channel_args_destroy(args);
   if (cs->f->client != nullptr) {
     grpc_chttp2_transport_start_reading(transport, nullptr, nullptr, nullptr);
@@ -95,30 +99,32 @@ static void client_setup_transport(void* ts, grpc_transport* transport) {
 }
 
 static grpc_end2end_test_fixture chttp2_create_fixture_socketpair(
-    grpc_channel_args* /*client_args*/, grpc_channel_args* /*server_args*/) {
-  grpc_endpoint_pair* sfd =
-      static_cast<grpc_endpoint_pair*>(gpr_malloc(sizeof(grpc_endpoint_pair)));
-
+    grpc_channel_args* client_args, grpc_channel_args* /*server_args*/) {
+  custom_fixture_data* fixture_data = static_cast<custom_fixture_data*>(
+      gpr_malloc(sizeof(custom_fixture_data)));
   grpc_end2end_test_fixture f;
   memset(&f, 0, sizeof(f));
-  f.fixture_data = sfd;
+  f.fixture_data = fixture_data;
   f.cq = grpc_completion_queue_create_for_next(nullptr);
   f.shutdown_cq = grpc_completion_queue_create_for_pluck(nullptr);
-
-  *sfd = grpc_iomgr_create_endpoint_pair("fixture", nullptr);
-
+  fixture_data->resource_quota =
+      grpc_resource_quota_from_channel_args(client_args, true);
+  fixture_data->ep = grpc_iomgr_create_endpoint_pair("fixture", nullptr);
   return f;
 }
 
 static void chttp2_init_client_socketpair(grpc_end2end_test_fixture* f,
                                           grpc_channel_args* client_args) {
   grpc_core::ExecCtx exec_ctx;
-  grpc_endpoint_pair* sfd = static_cast<grpc_endpoint_pair*>(f->fixture_data);
+  auto* fixture_data = static_cast<custom_fixture_data*>(f->fixture_data);
   grpc_transport* transport;
   sp_client_setup cs;
   cs.client_args = client_args;
   cs.f = f;
-  transport = grpc_create_chttp2_transport(client_args, sfd->client, true);
+  transport = grpc_create_chttp2_transport(
+      client_args, fixture_data->ep.client, true,
+      grpc_resource_user_create(fixture_data->resource_quota,
+                                "client_transport"));
   client_setup_transport(&cs, transport);
   GPR_ASSERT(f->client);
 }
@@ -126,17 +132,23 @@ static void chttp2_init_client_socketpair(grpc_end2end_test_fixture* f,
 static void chttp2_init_server_socketpair(grpc_end2end_test_fixture* f,
                                           grpc_channel_args* server_args) {
   grpc_core::ExecCtx exec_ctx;
-  grpc_endpoint_pair* sfd = static_cast<grpc_endpoint_pair*>(f->fixture_data);
+  auto* fixture_data = static_cast<custom_fixture_data*>(f->fixture_data);
   grpc_transport* transport;
   GPR_ASSERT(!f->server);
   f->server = grpc_server_create(server_args, nullptr);
   grpc_server_register_completion_queue(f->server, f->cq, nullptr);
   grpc_server_start(f->server);
-  transport = grpc_create_chttp2_transport(server_args, sfd->server, false);
+  transport = grpc_create_chttp2_transport(
+      server_args, fixture_data->ep.server, false,
+      grpc_resource_user_create(fixture_data->resource_quota,
+                                "server_transport"));
   server_setup_transport(f, transport);
 }
 
 static void chttp2_tear_down_socketpair(grpc_end2end_test_fixture* f) {
+  grpc_core::ExecCtx exec_ctx;
+  auto* fixture_data = static_cast<custom_fixture_data*>(f->fixture_data);
+  grpc_resource_quota_unref(fixture_data->resource_quota);
   gpr_free(f->fixture_data);
 }
 
index 5d5fb0b..a8b6115 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <string.h>
 
 #include <grpc/support/alloc.h>
 #include "src/core/lib/surface/channel.h"
 #include "src/core/lib/surface/completion_queue.h"
 #include "src/core/lib/surface/server.h"
+#include "test/core/end2end/end2end_tests.h"
 #include "test/core/util/port.h"
 #include "test/core/util/test_config.h"
 
 /* chttp2 transport that is immediately available (used for testing
    connected_channel without a client_channel */
 
+struct custom_fixture_data {
+  grpc_endpoint_pair ep;
+  grpc_resource_quota* resource_quota;
+};
+
 static void server_setup_transport(void* ts, grpc_transport* transport) {
   grpc_end2end_test_fixture* f = static_cast<grpc_end2end_test_fixture*>(ts);
   grpc_core::ExecCtx exec_ctx;
-  grpc_endpoint_pair* sfd = static_cast<grpc_endpoint_pair*>(f->fixture_data);
-  grpc_endpoint_add_to_pollset(sfd->server, grpc_cq_pollset(f->cq));
+  custom_fixture_data* fixture_data =
+      static_cast<custom_fixture_data*>(f->fixture_data);
+  grpc_endpoint_add_to_pollset(fixture_data->ep.server, grpc_cq_pollset(f->cq));
   grpc_error_handle error = f->server->core_server->SetupTransport(
       transport, nullptr, f->server->core_server->channel_args(), nullptr);
   if (error == GRPC_ERROR_NONE) {
@@ -72,7 +77,7 @@ static void client_setup_transport(void* ts, grpc_transport* transport) {
   grpc_error_handle error = GRPC_ERROR_NONE;
   cs->f->client =
       grpc_channel_create("socketpair-target", args, GRPC_CLIENT_DIRECT_CHANNEL,
-                          transport, nullptr, &error);
+                          transport, nullptr, 0, &error);
   grpc_channel_args_destroy(args);
   if (cs->f->client != nullptr) {
     grpc_chttp2_transport_start_reading(transport, nullptr, nullptr, nullptr);
@@ -90,30 +95,32 @@ static void client_setup_transport(void* ts, grpc_transport* transport) {
 }
 
 static grpc_end2end_test_fixture chttp2_create_fixture_socketpair(
-    grpc_channel_args* /*client_args*/, grpc_channel_args* /*server_args*/) {
-  grpc_endpoint_pair* sfd =
-      static_cast<grpc_endpoint_pair*>(gpr_malloc(sizeof(grpc_endpoint_pair)));
-
+    grpc_channel_args* client_args, grpc_channel_args* /*server_args*/) {
+  custom_fixture_data* fixture_data = static_cast<custom_fixture_data*>(
+      gpr_malloc(sizeof(custom_fixture_data)));
   grpc_end2end_test_fixture f;
   memset(&f, 0, sizeof(f));
-  f.fixture_data = sfd;
+  f.fixture_data = fixture_data;
   f.cq = grpc_completion_queue_create_for_next(nullptr);
   f.shutdown_cq = grpc_completion_queue_create_for_pluck(nullptr);
-
-  *sfd = grpc_iomgr_create_endpoint_pair("fixture", nullptr);
-
+  fixture_data->resource_quota =
+      grpc_resource_quota_from_channel_args(client_args, true);
+  fixture_data->ep = grpc_iomgr_create_endpoint_pair("fixture", nullptr);
   return f;
 }
 
 static void chttp2_init_client_socketpair(grpc_end2end_test_fixture* f,
                                           grpc_channel_args* client_args) {
   grpc_core::ExecCtx exec_ctx;
-  grpc_endpoint_pair* sfd = static_cast<grpc_endpoint_pair*>(f->fixture_data);
+  auto* fixture_data = static_cast<custom_fixture_data*>(f->fixture_data);
   grpc_transport* transport;
   sp_client_setup cs;
   cs.client_args = client_args;
   cs.f = f;
-  transport = grpc_create_chttp2_transport(client_args, sfd->client, true);
+  transport = grpc_create_chttp2_transport(
+      client_args, fixture_data->ep.client, true,
+      grpc_resource_user_create(fixture_data->resource_quota,
+                                "client_transport"));
   client_setup_transport(&cs, transport);
   GPR_ASSERT(f->client);
 }
@@ -121,17 +128,23 @@ static void chttp2_init_client_socketpair(grpc_end2end_test_fixture* f,
 static void chttp2_init_server_socketpair(grpc_end2end_test_fixture* f,
                                           grpc_channel_args* server_args) {
   grpc_core::ExecCtx exec_ctx;
-  grpc_endpoint_pair* sfd = static_cast<grpc_endpoint_pair*>(f->fixture_data);
+  auto* fixture_data = static_cast<custom_fixture_data*>(f->fixture_data);
   grpc_transport* transport;
   GPR_ASSERT(!f->server);
   f->server = grpc_server_create(server_args, nullptr);
   grpc_server_register_completion_queue(f->server, f->cq, nullptr);
   grpc_server_start(f->server);
-  transport = grpc_create_chttp2_transport(server_args, sfd->server, false);
+  transport = grpc_create_chttp2_transport(
+      server_args, fixture_data->ep.server, false,
+      grpc_resource_user_create(fixture_data->resource_quota,
+                                "server_transport"));
   server_setup_transport(f, transport);
 }
 
 static void chttp2_tear_down_socketpair(grpc_end2end_test_fixture* f) {
+  grpc_core::ExecCtx exec_ctx;
+  auto* fixture_data = static_cast<custom_fixture_data*>(f->fixture_data);
+  grpc_resource_quota_unref(fixture_data->resource_quota);
   gpr_free(f->fixture_data);
 }
 
index 434a614..3558626 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <string.h>
 
 #include <grpc/support/alloc.h>
 #include "src/core/lib/surface/channel.h"
 #include "src/core/lib/surface/completion_queue.h"
 #include "src/core/lib/surface/server.h"
+#include "test/core/end2end/end2end_tests.h"
 #include "test/core/util/port.h"
 #include "test/core/util/test_config.h"
 
 /* chttp2 transport that is immediately available (used for testing
    connected_channel without a client_channel */
 
+struct custom_fixture_data {
+  grpc_endpoint_pair ep;
+  grpc_resource_quota* resource_quota;
+};
+
 static void server_setup_transport(void* ts, grpc_transport* transport) {
   grpc_end2end_test_fixture* f = static_cast<grpc_end2end_test_fixture*>(ts);
   grpc_core::ExecCtx exec_ctx;
-  grpc_endpoint_pair* sfd = static_cast<grpc_endpoint_pair*>(f->fixture_data);
-  grpc_endpoint_add_to_pollset(sfd->server, grpc_cq_pollset(f->cq));
+  custom_fixture_data* fixture_data =
+      static_cast<custom_fixture_data*>(f->fixture_data);
+  grpc_endpoint_add_to_pollset(fixture_data->ep.server, grpc_cq_pollset(f->cq));
   grpc_error_handle error = f->server->core_server->SetupTransport(
       transport, nullptr, f->server->core_server->channel_args(), nullptr);
   if (error == GRPC_ERROR_NONE) {
@@ -72,7 +77,7 @@ static void client_setup_transport(void* ts, grpc_transport* transport) {
   grpc_error_handle error = GRPC_ERROR_NONE;
   cs->f->client =
       grpc_channel_create("socketpair-target", args, GRPC_CLIENT_DIRECT_CHANNEL,
-                          transport, nullptr, &error);
+                          transport, nullptr, 0, &error);
   grpc_channel_args_destroy(args);
   if (cs->f->client != nullptr) {
     grpc_chttp2_transport_start_reading(transport, nullptr, nullptr, nullptr);
@@ -91,15 +96,13 @@ static void client_setup_transport(void* ts, grpc_transport* transport) {
 
 static grpc_end2end_test_fixture chttp2_create_fixture_socketpair(
     grpc_channel_args* /*client_args*/, grpc_channel_args* /*server_args*/) {
-  grpc_endpoint_pair* sfd =
-      static_cast<grpc_endpoint_pair*>(gpr_malloc(sizeof(grpc_endpoint_pair)));
-
+  custom_fixture_data* fixture_data = static_cast<custom_fixture_data*>(
+      gpr_malloc(sizeof(custom_fixture_data)));
   grpc_end2end_test_fixture f;
   memset(&f, 0, sizeof(f));
-  f.fixture_data = sfd;
+  f.fixture_data = fixture_data;
   f.cq = grpc_completion_queue_create_for_next(nullptr);
   f.shutdown_cq = grpc_completion_queue_create_for_pluck(nullptr);
-
   grpc_arg a[3];
   a[0].key = const_cast<char*>(GRPC_ARG_TCP_READ_CHUNK_SIZE);
   a[0].type = GRPC_ARG_INTEGER;
@@ -111,20 +114,24 @@ static grpc_end2end_test_fixture chttp2_create_fixture_socketpair(
   a[2].type = GRPC_ARG_INTEGER;
   a[2].value.integer = 1;
   grpc_channel_args args = {GPR_ARRAY_SIZE(a), a};
-  *sfd = grpc_iomgr_create_endpoint_pair("fixture", &args);
-
+  fixture_data->resource_quota =
+      grpc_resource_quota_from_channel_args(&args, true);
+  fixture_data->ep = grpc_iomgr_create_endpoint_pair("fixture", &args);
   return f;
 }
 
 static void chttp2_init_client_socketpair(grpc_end2end_test_fixture* f,
                                           grpc_channel_args* client_args) {
   grpc_core::ExecCtx exec_ctx;
-  grpc_endpoint_pair* sfd = static_cast<grpc_endpoint_pair*>(f->fixture_data);
+  auto* fixture_data = static_cast<custom_fixture_data*>(f->fixture_data);
   grpc_transport* transport;
   sp_client_setup cs;
   cs.client_args = client_args;
   cs.f = f;
-  transport = grpc_create_chttp2_transport(client_args, sfd->client, true);
+  transport = grpc_create_chttp2_transport(
+      client_args, fixture_data->ep.client, true,
+      grpc_resource_user_create(fixture_data->resource_quota,
+                                "client_transport"));
   client_setup_transport(&cs, transport);
   GPR_ASSERT(f->client);
 }
@@ -132,17 +139,23 @@ static void chttp2_init_client_socketpair(grpc_end2end_test_fixture* f,
 static void chttp2_init_server_socketpair(grpc_end2end_test_fixture* f,
                                           grpc_channel_args* server_args) {
   grpc_core::ExecCtx exec_ctx;
-  grpc_endpoint_pair* sfd = static_cast<grpc_endpoint_pair*>(f->fixture_data);
+  auto* fixture_data = static_cast<custom_fixture_data*>(f->fixture_data);
   grpc_transport* transport;
   GPR_ASSERT(!f->server);
   f->server = grpc_server_create(server_args, nullptr);
   grpc_server_register_completion_queue(f->server, f->cq, nullptr);
   grpc_server_start(f->server);
-  transport = grpc_create_chttp2_transport(server_args, sfd->server, false);
+  transport = grpc_create_chttp2_transport(
+      server_args, fixture_data->ep.server, false,
+      grpc_resource_user_create(fixture_data->resource_quota,
+                                "server_transport"));
   server_setup_transport(f, transport);
 }
 
 static void chttp2_tear_down_socketpair(grpc_end2end_test_fixture* f) {
+  grpc_core::ExecCtx exec_ctx;
+  auto* fixture_data = static_cast<custom_fixture_data*>(f->fixture_data);
+  grpc_resource_quota_unref(fixture_data->resource_quota);
   gpr_free(f->fixture_data);
 }
 
index 2d1ef42..e66565f 100644 (file)
  *
  */
 
-#include <grpc/support/alloc.h>
-#include <grpc/support/log.h>
 #include <stdio.h>
 #include <string.h>
 
+#include <grpc/support/alloc.h>
+#include <grpc/support/log.h>
+
 #include "src/core/lib/channel/channel_args.h"
 #include "src/core/lib/gpr/string.h"
 #include "src/core/lib/gpr/tmpfile.h"
index bf78cda..433e443 100644 (file)
  *
  */
 
-#include <grpc/support/alloc.h>
-#include <grpc/support/log.h>
 #include <stdio.h>
 #include <string.h>
 
+#include <grpc/support/alloc.h>
+#include <grpc/support/log.h>
+
 #include "src/core/lib/channel/channel_args.h"
 #include "src/core/lib/gpr/string.h"
 #include "src/core/lib/gpr/tmpfile.h"
index ecccda3..9980c09 100644 (file)
  *
  */
 
-#include <grpc/support/alloc.h>
-#include <grpc/support/log.h>
 #include <stdio.h>
 #include <string.h>
 
+#include <grpc/support/alloc.h>
+#include <grpc/support/log.h>
+
 #include "src/core/lib/channel/channel_args.h"
 #include "src/core/lib/gpr/string.h"
 #include "src/core/lib/gpr/tmpfile.h"
index 9157e1e..2254e1c 100644 (file)
  *
  */
 
-#include <grpc/grpc_security.h>
-#include <grpc/support/alloc.h>
-#include <grpc/support/log.h>
-#include <grpc/support/string_util.h>
 #include <stdio.h>
 #include <string.h>
 
 #include "absl/container/inlined_vector.h"
 
+#include <grpc/grpc_security.h>
+#include <grpc/support/alloc.h>
+#include <grpc/support/log.h>
+#include <grpc/support/string_util.h>
+
 #include "src/core/lib/channel/channel_args.h"
 #include "src/core/lib/gpr/env.h"
 #include "src/core/lib/gpr/string.h"
index 1087b74..f42667e 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <inttypes.h>
 #include <stdlib.h>
 #include <string.h>
@@ -38,6 +36,7 @@
 #include "src/core/lib/gpr/string.h"
 #include "src/core/lib/surface/channel.h"
 #include "src/core/lib/surface/server.h"
+#include "test/core/end2end/end2end_tests.h"
 #include "test/core/util/port.h"
 #include "test/core/util/test_config.h"
 
index 83db10b..d4fc912 100644 (file)
@@ -18,8 +18,6 @@
 
 #include "test/core/end2end/fixtures/http_proxy_fixture.h"
 
-#include "src/core/lib/iomgr/sockaddr.h"
-
 #include <string.h>
 
 #include "absl/strings/str_cat.h"
 #include "src/core/lib/iomgr/pollset.h"
 #include "src/core/lib/iomgr/pollset_set.h"
 #include "src/core/lib/iomgr/resolve_address.h"
+#include "src/core/lib/iomgr/sockaddr.h"
 #include "src/core/lib/iomgr/tcp_client.h"
 #include "src/core/lib/iomgr/tcp_server.h"
 #include "src/core/lib/iomgr/timer.h"
 #include "src/core/lib/slice/b64.h"
 #include "src/core/lib/slice/slice_internal.h"
 #include "test/core/util/port.h"
+#include "test/core/util/resource_user_util.h"
 
 struct grpc_end2end_http_proxy {
   grpc_end2end_http_proxy()
@@ -489,10 +489,8 @@ static void on_read_request_done_locked(void* arg, grpc_error_handle error) {
   }
   // Make sure we got a CONNECT request.
   if (strcmp(conn->http_request.method, "CONNECT") != 0) {
-    error = GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-        absl::StrCat("HTTP proxy got request method ",
-                     conn->http_request.method)
-            .c_str());
+    error = GRPC_ERROR_CREATE_FROM_CPP_STRING(absl::StrCat(
+        "HTTP proxy got request method ", conn->http_request.method));
     proxy_connection_failed(conn, SETUP_FAILED, "HTTP proxy read request",
                             GRPC_ERROR_REF(error));
     GRPC_ERROR_UNREF(error);
@@ -538,6 +536,7 @@ static void on_read_request_done_locked(void* arg, grpc_error_handle error) {
   GRPC_CLOSURE_INIT(&conn->on_server_connect_done, on_server_connect_done, conn,
                     grpc_schedule_on_exec_ctx);
   grpc_tcp_client_connect(&conn->on_server_connect_done, &conn->server_endpoint,
+                          grpc_slice_allocator_create_unlimited(),
                           conn->pollset_set, nullptr,
                           &resolved_addresses->addrs[0], deadline);
   grpc_resolved_addresses_destroy(resolved_addresses);
@@ -612,8 +611,11 @@ grpc_end2end_http_proxy* grpc_end2end_http_proxy_create(
   gpr_log(GPR_INFO, "Proxy address: %s", proxy->proxy_name.c_str());
   // Create TCP server.
   proxy->channel_args = grpc_channel_args_copy(args);
-  grpc_error_handle error =
-      grpc_tcp_server_create(nullptr, proxy->channel_args, &proxy->server);
+  grpc_error_handle error = grpc_tcp_server_create(
+      nullptr, proxy->channel_args,
+      grpc_slice_allocator_factory_create(
+          grpc_resource_quota_from_channel_args(args, true)),
+      &proxy->server);
   GPR_ASSERT(error == GRPC_ERROR_NONE);
   // Bind to port.
   grpc_resolved_address resolved_addr;
index 2bd25c0..71f8d35 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <string.h>
 
 #include <grpc/support/alloc.h>
@@ -30,6 +28,7 @@
 #include "src/core/lib/channel/connected_channel.h"
 #include "src/core/lib/surface/channel.h"
 #include "src/core/lib/surface/server.h"
+#include "test/core/end2end/end2end_tests.h"
 #include "test/core/util/port.h"
 #include "test/core/util/test_config.h"
 
index 9e7a334..9775a99 100644 (file)
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <grpc/grpc_security.h>
 
 #include "src/core/lib/surface/channel.h"
+#include "test/core/end2end/end2end_tests.h"
 
 struct grpc_end2end_local_fullstack_fixture_data {
   std::string localaddr;
index 31ec466..bfc1c18 100644 (file)
@@ -46,23 +46,24 @@ extern "C" int LLVMFuzzerTestOneInput(const uint8_t* data, size_t size) {
     grpc_core::Executor::SetThreadingAll(false);
 
     grpc_resource_quota* resource_quota =
-        grpc_resource_quota_create("client_fuzzer");
-    grpc_endpoint* mock_endpoint =
-        grpc_mock_endpoint_create(discard_write, resource_quota);
-    grpc_resource_quota_unref_internal(resource_quota);
-
+        grpc_resource_quota_create("context_list_test");
+    grpc_endpoint* mock_endpoint = grpc_mock_endpoint_create(
+        discard_write,
+        grpc_slice_allocator_create(resource_quota, "mock_endpoint"));
     grpc_completion_queue* cq = grpc_completion_queue_create_for_next(nullptr);
-    grpc_transport* transport =
-        grpc_create_chttp2_transport(nullptr, mock_endpoint, true);
+    grpc_transport* transport = grpc_create_chttp2_transport(
+        nullptr, mock_endpoint, true,
+        grpc_resource_user_create(resource_quota, "mock_transport"));
+    grpc_resource_quota_unref(resource_quota);
     grpc_chttp2_transport_start_reading(transport, nullptr, nullptr, nullptr);
-
     grpc_arg authority_arg = grpc_channel_arg_string_create(
         const_cast<char*>(GRPC_ARG_DEFAULT_AUTHORITY),
         const_cast<char*>("test-authority"));
     grpc_channel_args* args =
         grpc_channel_args_copy_and_add(nullptr, &authority_arg, 1);
-    grpc_channel* channel = grpc_channel_create(
-        "test-target", args, GRPC_CLIENT_DIRECT_CHANNEL, transport);
+    grpc_channel* channel =
+        grpc_channel_create("test-target", args, GRPC_CLIENT_DIRECT_CHANNEL,
+                            transport, nullptr, 0, nullptr);
     grpc_channel_args_destroy(args);
     grpc_slice host = grpc_slice_from_static_string("localhost");
     grpc_call* call = grpc_channel_create_call(
index 8651b2e..4fc9ef2 100644 (file)
@@ -40,23 +40,23 @@ extern "C" int LLVMFuzzerTestOneInput(const uint8_t* data, size_t size) {
   {
     grpc_core::ExecCtx exec_ctx;
     grpc_core::Executor::SetThreadingAll(false);
-
     grpc_resource_quota* resource_quota =
-        grpc_resource_quota_create("server_fuzzer");
-    grpc_endpoint* mock_endpoint =
-        grpc_mock_endpoint_create(discard_write, resource_quota);
-    grpc_resource_quota_unref_internal(resource_quota);
+        grpc_resource_quota_create("context_list_test");
+    grpc_endpoint* mock_endpoint = grpc_mock_endpoint_create(
+        discard_write,
+        grpc_slice_allocator_create(resource_quota, "mock_endpoint"));
     grpc_mock_endpoint_put_read(
         mock_endpoint, grpc_slice_from_copied_buffer((const char*)data, size));
-
     grpc_server* server = grpc_server_create(nullptr, nullptr);
     grpc_completion_queue* cq = grpc_completion_queue_create_for_next(nullptr);
     grpc_server_register_completion_queue(server, cq, nullptr);
     // TODO(ctiller): add more registered methods (one for POST, one for PUT)
     grpc_server_register_method(server, "/reg", nullptr, {}, 0);
     grpc_server_start(server);
-    grpc_transport* transport =
-        grpc_create_chttp2_transport(nullptr, mock_endpoint, false);
+    grpc_transport* transport = grpc_create_chttp2_transport(
+        nullptr, mock_endpoint, false,
+        grpc_resource_user_create(resource_quota, "mock_transport"));
+    grpc_resource_quota_unref(resource_quota);
     server->core_server->SetupTransport(transport, nullptr, nullptr, nullptr);
     grpc_chttp2_transport_start_reading(transport, nullptr, nullptr, nullptr);
 
index 4066a54..9886135 100755 (executable)
@@ -336,6 +336,7 @@ END2END_TESTS = {
     ),
     "retry_throttled": _test_options(needs_client_channel = True),
     "retry_too_many_attempts": _test_options(needs_client_channel = True),
+    "sdk_authz": _test_options(secure = True),
     "server_finishes_request": _test_options(),
     "server_streaming": _test_options(needs_http2 = True),
     "shutdown_finishes_calls": _test_options(),
@@ -423,6 +424,7 @@ def grpc_end2end_tests():
             ":proxy",
             ":local_util",
             "//test/core/util:test_lb_policies",
+            "//:grpc_authorization_provider",
         ],
     )
 
index 679000d..e0aaef6 100644 (file)
  *
  */
 
-/* With the addition of a libuv endpoint, sockaddr.h now includes uv.h when
-   using that endpoint. Because of various transitive includes in uv.h,
-   including windows.h on Windows, uv.h must be included before other system
-   headers. Therefore, sockaddr.h must always be included first */
-#include "src/core/lib/iomgr/sockaddr.h"
-#include "src/core/lib/iomgr/socket_utils.h"
-
 #include <string.h>
 
 #include <string>
@@ -37,6 +30,7 @@
 #include "src/core/ext/filters/client_channel/server_address.h"
 #include "src/core/lib/iomgr/resolve_address.h"
 #include "src/core/lib/iomgr/sockaddr.h"
+#include "src/core/lib/iomgr/socket_utils.h"
 #include "test/core/end2end/cq_verifier.h"
 #include "test/core/util/port.h"
 #include "test/core/util/test_config.h"
index 46d38a6..7702672 100644 (file)
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
+#include <gtest/gtest.h>
+
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpcpp/support/string_ref.h>
 #include "src/core/lib/security/security_connector/ssl_utils_config.h"
 #include "test/core/end2end/cq_verifier.h"
 #include "test/core/end2end/data/ssl_test_data.h"
+#include "test/core/end2end/end2end_tests.h"
 #include "test/core/util/port.h"
 #include "test/core/util/test_config.h"
 
-#include <gtest/gtest.h>
-
 extern "C" {
 #include <openssl/crypto.h>
 }
index 9230a56..6b88a1d 100644 (file)
  *
  */
 
-#include <grpc/support/alloc.h>
-#include <grpc/support/log.h>
-#include <gtest/gtest.h>
 #include <stdio.h>
 #include <string.h>
 
+#include <gtest/gtest.h>
+
+#include <grpc/support/alloc.h>
+#include <grpc/support/log.h>
+
 #include "src/core/lib/channel/channel_args.h"
 #include "src/core/lib/gpr/string.h"
 #include "src/core/lib/gpr/tmpfile.h"
index 327affa..18493e9 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <string.h>
 
 #include <grpc/support/alloc.h>
@@ -28,6 +26,7 @@
 #include "src/core/lib/surface/channel.h"
 #include "src/core/lib/surface/completion_queue.h"
 #include "src/core/lib/surface/server.h"
+#include "test/core/end2end/end2end_tests.h"
 #include "test/core/util/port.h"
 #include "test/core/util/test_config.h"
 
index bb4e3da..9873837 100644 (file)
@@ -17,6 +17,7 @@
  */
 
 #include <grpc/grpc.h>
+
 #include "test/core/util/test_config.h"
 
 int main(int argc, char** argv) {
index 95e38f5..806215e 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -25,7 +23,9 @@
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/time.h>
+
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
 
index 33281ab..a2caf88 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/time.h>
+
 #include "src/core/lib/gpr/string.h"
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
 
index 6d927ee..d957f58 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <string.h>
 
 #include <grpc/support/alloc.h>
@@ -29,6 +27,7 @@
 #include "src/core/lib/gpr/useful.h"
 #include "src/core/lib/surface/channel.h"
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 
 #define MAX_PING_STRIKES 2
 
index 96c3861..ebc64a9 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -25,7 +23,9 @@
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/time.h>
+
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
 
index a11c95e..8d64b55 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -30,6 +28,7 @@
 #include "src/core/lib/gpr/string.h"
 #include "src/core/lib/security/credentials/credentials.h"
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 
 static const char iam_token[] = "token";
 static const char iam_selector[] = "selector";
index 2538999..04d718d 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -30,6 +28,7 @@
 #include "src/core/lib/channel/channel_args.h"
 #include "src/core/lib/gpr/string.h"
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
 
index d80f524..459cdc8 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -30,8 +28,8 @@
 #include "src/core/lib/iomgr/exec_ctx.h"
 #include "src/core/lib/slice/slice_internal.h"
 #include "src/core/lib/transport/metadata.h"
-
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 #include "test/core/end2end/tests/cancel_test_helpers.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
index 5ff9dd0..1039d9b 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -28,6 +26,7 @@
 
 #include "src/core/lib/gpr/useful.h"
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 #include "test/core/end2end/tests/cancel_test_helpers.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
index 2d58b99..0195dd1 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <inttypes.h>
 #include <stdio.h>
 #include <string.h>
@@ -29,6 +27,7 @@
 
 #include "src/core/lib/gpr/useful.h"
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 #include "test/core/end2end/tests/cancel_test_helpers.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
index ea03dae..bb579d0 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -30,8 +28,8 @@
 #include "src/core/lib/iomgr/exec_ctx.h"
 #include "src/core/lib/slice/slice_internal.h"
 #include "src/core/lib/transport/metadata.h"
-
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 #include "test/core/end2end/tests/cancel_test_helpers.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
index f118fff..7482193 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <inttypes.h>
 #include <stdio.h>
 #include <string.h>
@@ -26,7 +24,9 @@
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/time.h>
+
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
 
index 4b530f1..e004cee 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -28,6 +26,7 @@
 
 #include "src/core/lib/gpr/useful.h"
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 #include "test/core/end2end/tests/cancel_test_helpers.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
index 80eb5e0..98c83c5 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <inttypes.h>
 #include <stdio.h>
 #include <string.h>
 #include <grpc/support/log.h>
 #include <grpc/support/string_util.h>
 #include <grpc/support/time.h>
+
 #include "src/core/lib/gpr/string.h"
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
 
index 2061873..d508fc1 100644 (file)
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
-#include "src/core/lib/surface/channel.h"
-#include "src/core/lib/surface/server.h"
-
 #include <grpc/byte_buffer.h>
 #include <grpc/grpc.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/time.h>
+
 #include "src/core/lib/channel/channelz_registry.h"
 #include "src/core/lib/gpr/string.h"
+#include "src/core/lib/surface/channel.h"
+#include "src/core/lib/surface/server.h"
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
 
index f9cfaff..6b62a01 100644 (file)
@@ -16,8 +16,6 @@
 //
 //
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -25,7 +23,9 @@
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/time.h>
+
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
 
index 05ffb50..4185d84 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -38,6 +36,7 @@
 #include "src/core/lib/surface/call_test_only.h"
 #include "src/core/lib/transport/static_metadata.h"
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
 
index 4175eae..326b7bf 100644 (file)
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <grpc/support/log.h>
 #include <grpc/support/sync.h>
 #include <grpc/support/time.h>
 
 #include "src/core/lib/gprpp/thd.h"
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
 
index 3527073..efd4fea 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/time.h>
+
 #include "src/core/lib/gpr/string.h"
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
 
index e8fa4e4..6f4493c 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -25,7 +23,9 @@
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/time.h>
+
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
 
index 7325616..3104c5d 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/time.h>
+
 #include "src/core/lib/gpr/string.h"
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
 
index f7471c1..c951174 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdbool.h>
 #include <stdio.h>
 #include <string.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/time.h>
+
 #include "src/core/lib/channel/channel_stack_builder.h"
 #include "src/core/lib/surface/channel_init.h"
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 
 static bool g_enable_filter = false;
 
index 0b97dc4..d9528bc 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <limits.h>
 #include <stdbool.h>
 #include <stdio.h>
@@ -31,6 +29,7 @@
 #include "src/core/lib/channel/channel_stack_builder.h"
 #include "src/core/lib/surface/channel_init.h"
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 
 enum { TIMEOUT = 200000 };
 
index 43da690..30ee08d 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <limits.h>
 #include <stdbool.h>
 #include <stdio.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/time.h>
+
 #include "src/core/lib/channel/channel_stack_builder.h"
 #include "src/core/lib/surface/channel_init.h"
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 
 enum { TIMEOUT = 200000 };
 
index 6b94d94..7dfaca5 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <limits.h>
 #include <stdbool.h>
 #include <stdio.h>
@@ -31,6 +29,7 @@
 #include "src/core/lib/channel/channel_stack_builder.h"
 #include "src/core/lib/surface/channel_init.h"
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 
 enum { TIMEOUT = 200000 };
 
index 6359980..db9d5cb 100644 (file)
@@ -24,8 +24,6 @@
  * https://github.com/grpc/grpc/blob/master/doc/http-grpc-status-mapping.md
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <limits.h>
 #include <stdbool.h>
 #include <stdio.h>
@@ -40,6 +38,7 @@
 #include "src/core/lib/surface/call.h"
 #include "src/core/lib/surface/channel_init.h"
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 
 static bool g_enable_filter = false;
 static gpr_mu g_mu;
index 93561bf..8dc56ff 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -25,7 +23,9 @@
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/time.h>
+
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
 
index 5500594..9772601 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -33,6 +31,7 @@
 
 #include "src/core/lib/gpr/string.h"
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
 
index a9be014..ca14102 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -34,6 +32,7 @@
 #include "src/core/lib/gpr/string.h"
 #include "src/core/lib/gpr/useful.h"
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
 
index 294b94c..a271c96 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -29,6 +27,7 @@
 
 #include "src/core/lib/gpr/string.h"
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
 
index 987125f..2fff0cc 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -32,6 +30,7 @@
 
 #include "src/core/lib/gpr/useful.h"
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
 
index a1aacd0..6db92f2 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -32,6 +30,7 @@
 #include "src/core/lib/iomgr/exec_ctx.h"
 #include "src/core/lib/iomgr/iomgr.h"
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 
 #ifdef GRPC_POSIX_SOCKET
 #include "src/core/lib/iomgr/ev_posix.h"
index 07983d8..19ac61a 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -25,7 +23,9 @@
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/time.h>
+
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
 
index 4324e9d..f96cda3 100644 (file)
@@ -29,7 +29,6 @@
 #include "src/core/ext/filters/load_reporting/server_load_reporting_plugin.h"
 #include "src/core/lib/channel/channel_args.h"
 #include "src/core/lib/transport/static_metadata.h"
-
 #include "test/core/end2end/cq_verifier.h"
 #include "test/core/end2end/end2end_tests.h"
 
index bd7d7cd..3d3e406 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -25,7 +23,9 @@
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/time.h>
+
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
 
index 63b8042..3219b60 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <limits.h>
 #include <string.h>
 
@@ -27,6 +25,7 @@
 
 #include "src/core/lib/gpr/useful.h"
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 
 #define MAX_CONNECTION_AGE_MS 500
 #define MAX_CONNECTION_AGE_GRACE_MS 1000
index 6df32f4..ecc51b5 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <limits.h>
 #include <string.h>
 
@@ -28,6 +26,7 @@
 
 #include "src/core/lib/gpr/useful.h"
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 
 #define MAX_CONNECTION_IDLE_MS 500
 #define MAX_CONNECTION_AGE_MS 9999
index ca9f860..c36d370 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -31,8 +29,8 @@
 #include "src/core/lib/slice/slice_internal.h"
 #include "src/core/lib/slice/slice_string_helpers.h"
 #include "src/core/lib/transport/metadata.h"
-
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
 
index e975f37..a2d1528 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <inttypes.h>
 #include <stdio.h>
 #include <string.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/time.h>
+
 #include "src/core/lib/gpr/string.h"
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
 
index 411ed93..59ea65b 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
 #include <grpc/support/log.h>
 #include <grpc/support/string_util.h>
 #include <grpc/support/time.h>
+
 #include "src/core/lib/gpr/string.h"
 #include "src/core/lib/iomgr/error.h"
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
 
index 5f32527..7ca364c 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/time.h>
+
 #include "src/core/lib/gpr/string.h"
 #include "src/core/lib/iomgr/error.h"
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 
 enum { TIMEOUT = 200000 };
 
index 2c515f1..1f3343c 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -25,7 +23,9 @@
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/time.h>
+
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
 
index fab5daf..fd4565c 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -25,7 +23,9 @@
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/time.h>
+
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
 
index 28bef18..db4d545 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <grpc/support/log.h>
 #include <grpc/support/sync.h>
 #include <grpc/support/time.h>
@@ -26,6 +24,7 @@
 #include "src/core/lib/gpr/useful.h"
 #include "src/core/lib/surface/channel.h"
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 
 #define PING_NUM 5
 
index 4e030e0..66c60c3 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -25,7 +23,9 @@
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/time.h>
+
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
 
index 3684b27..738387a 100644 (file)
@@ -20,9 +20,6 @@
  * This test is for checking whether proxy authentication is working with HTTP
  * Connect.
  */
-#include "test/core/end2end/end2end_tests.h"
-#include "test/core/end2end/fixtures/http_proxy_fixture.h"
-
 #include <stdio.h>
 #include <string.h>
 
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/time.h>
+
 #include "src/core/lib/gpr/string.h"
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
+#include "test/core/end2end/fixtures/http_proxy_fixture.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
 
index 719758e..b7c0258 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -29,6 +27,7 @@
 
 #include "src/core/lib/gpr/string.h"
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
 
index 348e0b6..3f42b60 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -29,6 +27,7 @@
 #include "src/core/lib/gpr/useful.h"
 #include "src/core/lib/transport/byte_stream.h"
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
 
index 404c3bf..1a655c1 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -25,7 +23,9 @@
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/time.h>
+
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
 
index 96c0686..0e5e50d 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -27,6 +25,7 @@
 #include <grpc/support/time.h>
 
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
 
index 5e75494..68b22ac 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -33,8 +31,8 @@
 #include "src/core/lib/gpr/useful.h"
 #include "src/core/lib/iomgr/exec_ctx.h"
 #include "src/core/lib/transport/static_metadata.h"
-
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 #include "test/core/end2end/tests/cancel_test_helpers.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
index 05d1f94..b0cafab 100644 (file)
@@ -14,8 +14,6 @@
 // limitations under the License.
 //
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -34,8 +32,8 @@
 #include "src/core/lib/gpr/useful.h"
 #include "src/core/lib/iomgr/exec_ctx.h"
 #include "src/core/lib/transport/static_metadata.h"
-
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 #include "test/core/end2end/tests/cancel_test_helpers.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
index a86e23b..320816f 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -38,8 +36,8 @@
 #include "src/core/lib/iomgr/exec_ctx.h"
 #include "src/core/lib/surface/channel_init.h"
 #include "src/core/lib/transport/static_metadata.h"
-
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 #include "test/core/end2end/tests/cancel_test_helpers.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
index 654ad59..64108c8 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -36,8 +34,8 @@
 #include "src/core/lib/gpr/useful.h"
 #include "src/core/lib/iomgr/exec_ctx.h"
 #include "src/core/lib/transport/static_metadata.h"
-
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 #include "test/core/end2end/tests/cancel_test_helpers.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
index 83deb41..dc1d99f 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -33,8 +31,8 @@
 #include "src/core/lib/gpr/useful.h"
 #include "src/core/lib/iomgr/exec_ctx.h"
 #include "src/core/lib/transport/static_metadata.h"
-
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 #include "test/core/end2end/tests/cancel_test_helpers.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
index d515bc4..7467113 100644 (file)
@@ -14,8 +14,6 @@
 // limitations under the License.
 //
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -31,8 +29,8 @@
 #include "src/core/lib/gpr/useful.h"
 #include "src/core/lib/iomgr/exec_ctx.h"
 #include "src/core/lib/transport/static_metadata.h"
-
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 #include "test/core/end2end/tests/cancel_test_helpers.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
index 286e81e..f20bc69 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -33,8 +31,8 @@
 #include "src/core/lib/gpr/useful.h"
 #include "src/core/lib/iomgr/exec_ctx.h"
 #include "src/core/lib/transport/static_metadata.h"
-
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 #include "test/core/end2end/tests/cancel_test_helpers.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
index 6c2abcc..f4630fd 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -33,8 +31,8 @@
 #include "src/core/lib/gpr/useful.h"
 #include "src/core/lib/iomgr/exec_ctx.h"
 #include "src/core/lib/transport/static_metadata.h"
-
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 #include "test/core/end2end/tests/cancel_test_helpers.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
index 2a72910..4e0dc32 100644 (file)
@@ -14,8 +14,6 @@
 // limitations under the License.
 //
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -32,8 +30,8 @@
 #include "src/core/lib/gpr/useful.h"
 #include "src/core/lib/iomgr/exec_ctx.h"
 #include "src/core/lib/transport/static_metadata.h"
-
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 #include "test/core/end2end/tests/cancel_test_helpers.h"
 #include "test/core/util/test_lb_policies.h"
 
index ba77767..e97567d 100644 (file)
@@ -14,8 +14,6 @@
 // limitations under the License.
 //
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -33,8 +31,8 @@
 #include "src/core/lib/iomgr/exec_ctx.h"
 #include "src/core/lib/transport/error_utils.h"
 #include "src/core/lib/transport/static_metadata.h"
-
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 #include "test/core/end2end/tests/cancel_test_helpers.h"
 
 namespace grpc_core {
@@ -42,7 +40,7 @@ namespace {
 
 const char* kFailPolicyName = "fail_lb";
 
-Atomic<int> g_num_lb_picks;
+std::atomic<int> g_num_lb_picks;
 
 class FailPolicy : public LoadBalancingPolicy {
  public:
@@ -66,7 +64,7 @@ class FailPolicy : public LoadBalancingPolicy {
     explicit FailPicker(absl::Status status) : status_(status) {}
 
     PickResult Pick(PickArgs /*args*/) override {
-      g_num_lb_picks.FetchAdd(1);
+      g_num_lb_picks.fetch_add(1);
       return PickResult::Fail(status_);
     }
 
@@ -179,7 +177,7 @@ static void test_retry_lb_fail(grpc_end2end_test_config config) {
   grpc_call_error error;
   grpc_slice details;
 
-  grpc_core::g_num_lb_picks.Store(0, grpc_core::MemoryOrder::RELAXED);
+  grpc_core::g_num_lb_picks.store(0, std::memory_order_relaxed);
 
   grpc_arg args[] = {
       grpc_channel_arg_integer_create(
@@ -259,8 +257,7 @@ static void test_retry_lb_fail(grpc_end2end_test_config config) {
 
   cq_verifier_destroy(cqv);
 
-  int num_picks =
-      grpc_core::g_num_lb_picks.Load(grpc_core::MemoryOrder::RELAXED);
+  int num_picks = grpc_core::g_num_lb_picks.load(std::memory_order_relaxed);
   gpr_log(GPR_INFO, "NUM LB PICKS: %d", num_picks);
   GPR_ASSERT(num_picks == 2);
 
index aeab877..7771073 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -33,8 +31,8 @@
 #include "src/core/lib/gpr/useful.h"
 #include "src/core/lib/iomgr/exec_ctx.h"
 #include "src/core/lib/transport/static_metadata.h"
-
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 #include "test/core/end2end/tests/cancel_test_helpers.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
index 6436553..657c206 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -33,8 +31,8 @@
 #include "src/core/lib/gpr/useful.h"
 #include "src/core/lib/iomgr/exec_ctx.h"
 #include "src/core/lib/transport/static_metadata.h"
-
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 #include "test/core/end2end/tests/cancel_test_helpers.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
index 74a09ba..5dc1a7d 100644 (file)
@@ -14,8 +14,6 @@
 // limitations under the License.
 //
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -31,8 +29,8 @@
 #include "src/core/lib/gpr/useful.h"
 #include "src/core/lib/iomgr/exec_ctx.h"
 #include "src/core/lib/transport/static_metadata.h"
-
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 #include "test/core/end2end/tests/cancel_test_helpers.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
index 597b167..572727b 100644 (file)
@@ -14,8 +14,6 @@
 // limitations under the License.
 //
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -31,8 +29,8 @@
 #include "src/core/lib/gpr/useful.h"
 #include "src/core/lib/iomgr/exec_ctx.h"
 #include "src/core/lib/transport/static_metadata.h"
-
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 #include "test/core/end2end/tests/cancel_test_helpers.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
index b58b33d..24f9993 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -33,8 +31,8 @@
 #include "src/core/lib/gpr/useful.h"
 #include "src/core/lib/iomgr/exec_ctx.h"
 #include "src/core/lib/transport/static_metadata.h"
-
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 #include "test/core/end2end/tests/cancel_test_helpers.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
index a6fb07c..347c148 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -33,8 +31,8 @@
 #include "src/core/lib/gpr/useful.h"
 #include "src/core/lib/iomgr/exec_ctx.h"
 #include "src/core/lib/transport/static_metadata.h"
-
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 #include "test/core/end2end/tests/cancel_test_helpers.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
index c91c7c8..a8f20e0 100644 (file)
@@ -14,8 +14,6 @@
 // limitations under the License.
 //
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -34,8 +32,8 @@
 #include "src/core/lib/iomgr/exec_ctx.h"
 #include "src/core/lib/surface/channel_init.h"
 #include "src/core/lib/transport/static_metadata.h"
-
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 #include "test/core/end2end/tests/cancel_test_helpers.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
index 08a3691..b9eeafe 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -33,8 +31,8 @@
 #include "src/core/lib/gpr/useful.h"
 #include "src/core/lib/iomgr/exec_ctx.h"
 #include "src/core/lib/transport/static_metadata.h"
-
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 #include "test/core/end2end/tests/cancel_test_helpers.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
index 61e6743..6abcc12 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -36,8 +34,8 @@
 #include "src/core/lib/iomgr/exec_ctx.h"
 #include "src/core/lib/surface/channel_init.h"
 #include "src/core/lib/transport/static_metadata.h"
-
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 #include "test/core/end2end/tests/cancel_test_helpers.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
index c7d25da..b571674 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -33,8 +31,8 @@
 #include "src/core/lib/gpr/useful.h"
 #include "src/core/lib/iomgr/exec_ctx.h"
 #include "src/core/lib/transport/static_metadata.h"
-
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 #include "test/core/end2end/tests/cancel_test_helpers.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
index 580f75a..cc80510 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -33,8 +31,8 @@
 #include "src/core/lib/gpr/useful.h"
 #include "src/core/lib/iomgr/exec_ctx.h"
 #include "src/core/lib/transport/static_metadata.h"
-
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 #include "test/core/end2end/tests/cancel_test_helpers.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
index 2521910..fdd8e59 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
 #include <grpc/support/string_util.h>
 #include <grpc/support/time.h>
 
-#include "src/core/lib/surface/channel.h"
-#include "src/core/lib/surface/server.h"
-
 #include "src/core/lib/channel/channel_args.h"
 #include "src/core/lib/gpr/string.h"
 #include "src/core/lib/gpr/useful.h"
 #include "src/core/lib/iomgr/exec_ctx.h"
+#include "src/core/lib/surface/channel.h"
+#include "src/core/lib/surface/server.h"
 #include "src/core/lib/transport/static_metadata.h"
-
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 #include "test/core/end2end/tests/cancel_test_helpers.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
index 4fc3aaa..5829edb 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -33,8 +31,8 @@
 #include "src/core/lib/gpr/useful.h"
 #include "src/core/lib/iomgr/exec_ctx.h"
 #include "src/core/lib/transport/static_metadata.h"
-
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 #include "test/core/end2end/tests/cancel_test_helpers.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
index f3e90d3..4c2faca 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -33,8 +31,8 @@
 #include "src/core/lib/gpr/useful.h"
 #include "src/core/lib/iomgr/exec_ctx.h"
 #include "src/core/lib/transport/static_metadata.h"
-
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 #include "test/core/end2end/tests/cancel_test_helpers.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
index 1ff6dda..a9051ba 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -33,8 +31,8 @@
 #include "src/core/lib/gpr/useful.h"
 #include "src/core/lib/iomgr/exec_ctx.h"
 #include "src/core/lib/transport/static_metadata.h"
-
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 #include "test/core/end2end/tests/cancel_test_helpers.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
index 15ec44f..1048334 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -33,8 +31,8 @@
 #include "src/core/lib/gpr/useful.h"
 #include "src/core/lib/iomgr/exec_ctx.h"
 #include "src/core/lib/transport/static_metadata.h"
-
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 #include "test/core/end2end/tests/cancel_test_helpers.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
diff --git a/test/core/end2end/tests/sdk_authz.cc b/test/core/end2end/tests/sdk_authz.cc
new file mode 100644 (file)
index 0000000..6ab5e0b
--- /dev/null
@@ -0,0 +1,438 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#include <stdio.h>
+#include <string.h>
+
+#include <grpc/byte_buffer.h>
+#include <grpc/grpc_security.h>
+#include <grpc/support/alloc.h>
+#include <grpc/support/log.h>
+#include <grpc/support/time.h>
+
+#include "src/core/lib/channel/channel_args.h"
+#include "src/core/lib/gpr/string.h"
+#include "src/core/lib/security/authorization/grpc_authorization_policy_provider.h"
+#include "src/core/lib/security/credentials/credentials.h"
+#include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
+
+static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
+
+static grpc_end2end_test_fixture begin_test(grpc_end2end_test_config config,
+                                            const char* test_name,
+                                            grpc_channel_args* client_args,
+                                            grpc_channel_args* server_args) {
+  grpc_end2end_test_fixture f;
+  gpr_log(GPR_INFO, "Running test: %s/%s", test_name, config.name);
+  f = config.create_fixture(client_args, server_args);
+  config.init_server(&f, server_args);
+  config.init_client(&f, client_args);
+  return f;
+}
+
+static gpr_timespec n_seconds_from_now(int n) {
+  return grpc_timeout_seconds_to_deadline(n);
+}
+
+static gpr_timespec five_seconds_from_now(void) {
+  return n_seconds_from_now(5);
+}
+
+static void drain_cq(grpc_completion_queue* cq) {
+  grpc_event ev;
+  do {
+    ev = grpc_completion_queue_next(cq, five_seconds_from_now(), nullptr);
+  } while (ev.type != GRPC_QUEUE_SHUTDOWN);
+}
+
+static void shutdown_server(grpc_end2end_test_fixture* f) {
+  if (!f->server) return;
+  grpc_server_shutdown_and_notify(f->server, f->shutdown_cq, tag(1000));
+  GPR_ASSERT(grpc_completion_queue_pluck(f->shutdown_cq, tag(1000),
+                                         grpc_timeout_seconds_to_deadline(5),
+                                         nullptr)
+                 .type == GRPC_OP_COMPLETE);
+  grpc_server_destroy(f->server);
+  f->server = nullptr;
+}
+
+static void shutdown_client(grpc_end2end_test_fixture* f) {
+  if (!f->client) return;
+  grpc_channel_destroy(f->client);
+  f->client = nullptr;
+}
+
+static void end_test(grpc_end2end_test_fixture* f) {
+  shutdown_server(f);
+  shutdown_client(f);
+
+  grpc_completion_queue_shutdown(f->cq);
+  drain_cq(f->cq);
+  grpc_completion_queue_destroy(f->cq);
+  grpc_completion_queue_destroy(f->shutdown_cq);
+}
+
+static void test_allow_authorized_request(grpc_end2end_test_config config) {
+  grpc_call* c;
+  grpc_call* s;
+  grpc_op ops[6];
+  grpc_op* op;
+  grpc_metadata_array initial_metadata_recv;
+  grpc_metadata_array trailing_metadata_recv;
+  grpc_metadata_array request_metadata_recv;
+  grpc_call_details call_details;
+  grpc_status_code status;
+  const char* error_string = nullptr;
+  grpc_call_error error;
+  grpc_slice details = grpc_empty_slice();
+  int was_cancelled = 2;
+
+  const char* authz_policy =
+      "{"
+      "  \"name\": \"authz\","
+      "  \"allow_rules\": ["
+      "    {"
+      "      \"name\": \"allow_foo\","
+      "      \"request\": {"
+      "        \"paths\": ["
+      "          \"*/foo\""
+      "        ]"
+      "      }"
+      "    }"
+      "  ]"
+      "}";
+  grpc_status_code code;
+  const char* error_details;
+  grpc_authorization_policy_provider* provider =
+      grpc_authorization_policy_provider_static_data_create(authz_policy, &code,
+                                                            &error_details);
+  GPR_ASSERT(GRPC_STATUS_OK == code);
+  grpc_arg args[] = {
+      grpc_channel_arg_pointer_create(
+          const_cast<char*>(GRPC_ARG_AUTHORIZATION_POLICY_PROVIDER), provider,
+          grpc_authorization_policy_provider_arg_vtable()),
+  };
+  grpc_channel_args server_args = {GPR_ARRAY_SIZE(args), args};
+
+  grpc_end2end_test_fixture f = begin_test(
+      config, "test_allow_authorized_request", nullptr, &server_args);
+  grpc_authorization_policy_provider_release(provider);
+  cq_verifier* cqv = cq_verifier_create(f.cq);
+
+  gpr_timespec deadline = five_seconds_from_now();
+  c = grpc_channel_create_call(f.client, nullptr, GRPC_PROPAGATE_DEFAULTS, f.cq,
+                               grpc_slice_from_static_string("/foo"), nullptr,
+                               deadline, nullptr);
+  GPR_ASSERT(c);
+
+  grpc_metadata_array_init(&initial_metadata_recv);
+  grpc_metadata_array_init(&trailing_metadata_recv);
+  grpc_metadata_array_init(&request_metadata_recv);
+  grpc_call_details_init(&call_details);
+
+  memset(ops, 0, sizeof(ops));
+  op = ops;
+  op->op = GRPC_OP_SEND_INITIAL_METADATA;
+  op->data.send_initial_metadata.count = 0;
+  op->flags = 0;
+  op->reserved = nullptr;
+  op++;
+  op->op = GRPC_OP_SEND_CLOSE_FROM_CLIENT;
+  op->flags = 0;
+  op->reserved = nullptr;
+  op++;
+  op->op = GRPC_OP_RECV_INITIAL_METADATA;
+  op->data.recv_initial_metadata.recv_initial_metadata = &initial_metadata_recv;
+  op->flags = 0;
+  op->reserved = nullptr;
+  op++;
+  op->op = GRPC_OP_RECV_STATUS_ON_CLIENT;
+  op->data.recv_status_on_client.trailing_metadata = &trailing_metadata_recv;
+  op->data.recv_status_on_client.status = &status;
+  op->data.recv_status_on_client.status_details = &details;
+  op->data.recv_status_on_client.error_string = &error_string;
+  op->flags = 0;
+  op->reserved = nullptr;
+  op++;
+  error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1),
+                                nullptr);
+  GPR_ASSERT(GRPC_CALL_OK == error);
+
+  error =
+      grpc_server_request_call(f.server, &s, &call_details,
+                               &request_metadata_recv, f.cq, f.cq, tag(101));
+  GPR_ASSERT(GRPC_CALL_OK == error);
+  CQ_EXPECT_COMPLETION(cqv, tag(101), 1);
+  cq_verify(cqv);
+
+  memset(ops, 0, sizeof(ops));
+  op = ops;
+  op->op = GRPC_OP_SEND_INITIAL_METADATA;
+  op->data.send_initial_metadata.count = 0;
+  op->flags = 0;
+  op->reserved = nullptr;
+  op++;
+  op->op = GRPC_OP_SEND_STATUS_FROM_SERVER;
+  op->data.send_status_from_server.trailing_metadata_count = 0;
+  op->data.send_status_from_server.status = GRPC_STATUS_OK;
+  grpc_slice status_details = grpc_slice_from_static_string("xyz");
+  op->data.send_status_from_server.status_details = &status_details;
+  op->flags = 0;
+  op->reserved = nullptr;
+  op++;
+  op->op = GRPC_OP_RECV_CLOSE_ON_SERVER;
+  op->data.recv_close_on_server.cancelled = &was_cancelled;
+  op->flags = 0;
+  op->reserved = nullptr;
+  op++;
+  error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102),
+                                nullptr);
+  GPR_ASSERT(GRPC_CALL_OK == error);
+
+  CQ_EXPECT_COMPLETION(cqv, tag(102), 1);
+  CQ_EXPECT_COMPLETION(cqv, tag(1), 1);
+  cq_verify(cqv);
+  GPR_ASSERT(GRPC_STATUS_OK == status);
+  GPR_ASSERT(0 == grpc_slice_str_cmp(details, "xyz"));
+
+  grpc_slice_unref(details);
+  gpr_free(const_cast<char*>(error_string));
+  grpc_metadata_array_destroy(&initial_metadata_recv);
+  grpc_metadata_array_destroy(&trailing_metadata_recv);
+  grpc_metadata_array_destroy(&request_metadata_recv);
+  grpc_call_details_destroy(&call_details);
+
+  grpc_call_unref(c);
+  grpc_call_unref(s);
+  cq_verifier_destroy(cqv);
+
+  end_test(&f);
+  config.tear_down_data(&f);
+}
+
+static void test_deny_unauthorized_request(grpc_end2end_test_config config) {
+  grpc_call* c;
+  grpc_op ops[6];
+  grpc_op* op;
+  grpc_metadata_array initial_metadata_recv;
+  grpc_metadata_array trailing_metadata_recv;
+  grpc_status_code status;
+  const char* error_string = nullptr;
+  grpc_call_error error;
+  grpc_slice details = grpc_empty_slice();
+
+  const char* authz_policy =
+      "{"
+      "  \"name\": \"authz\","
+      "  \"allow_rules\": ["
+      "    {"
+      "      \"name\": \"allow_foo\","
+      "      \"request\": {"
+      "        \"paths\": ["
+      "          \"*/foo\""
+      "        ]"
+      "      }"
+      "    }"
+      "  ],"
+      "  \"deny_rules\": ["
+      "    {"
+      "      \"name\": \"deny_bar\","
+      "      \"request\": {"
+      "        \"paths\": ["
+      "          \"*/bar\""
+      "        ]"
+      "      }"
+      "    }"
+      "  ]"
+      "}";
+  grpc_status_code code;
+  const char* error_details;
+  grpc_authorization_policy_provider* provider =
+      grpc_authorization_policy_provider_static_data_create(authz_policy, &code,
+                                                            &error_details);
+  GPR_ASSERT(GRPC_STATUS_OK == code);
+  grpc_arg args[] = {
+      grpc_channel_arg_pointer_create(
+          const_cast<char*>(GRPC_ARG_AUTHORIZATION_POLICY_PROVIDER), provider,
+          grpc_authorization_policy_provider_arg_vtable()),
+  };
+  grpc_channel_args server_args = {GPR_ARRAY_SIZE(args), args};
+
+  grpc_end2end_test_fixture f = begin_test(
+      config, "test_deny_unauthorized_request", nullptr, &server_args);
+  grpc_authorization_policy_provider_release(provider);
+  cq_verifier* cqv = cq_verifier_create(f.cq);
+
+  gpr_timespec deadline = five_seconds_from_now();
+  c = grpc_channel_create_call(f.client, nullptr, GRPC_PROPAGATE_DEFAULTS, f.cq,
+                               grpc_slice_from_static_string("/bar"), nullptr,
+                               deadline, nullptr);
+  GPR_ASSERT(c);
+
+  grpc_metadata_array_init(&initial_metadata_recv);
+  grpc_metadata_array_init(&trailing_metadata_recv);
+
+  memset(ops, 0, sizeof(ops));
+  op = ops;
+  op->op = GRPC_OP_SEND_INITIAL_METADATA;
+  op->data.send_initial_metadata.count = 0;
+  op->flags = 0;
+  op->reserved = nullptr;
+  op++;
+  op->op = GRPC_OP_SEND_CLOSE_FROM_CLIENT;
+  op->flags = 0;
+  op->reserved = nullptr;
+  op++;
+  op->op = GRPC_OP_RECV_INITIAL_METADATA;
+  op->data.recv_initial_metadata.recv_initial_metadata = &initial_metadata_recv;
+  op->flags = 0;
+  op->reserved = nullptr;
+  op++;
+  op->op = GRPC_OP_RECV_STATUS_ON_CLIENT;
+  op->data.recv_status_on_client.trailing_metadata = &trailing_metadata_recv;
+  op->data.recv_status_on_client.status = &status;
+  op->data.recv_status_on_client.status_details = &details;
+  op->data.recv_status_on_client.error_string = &error_string;
+  op->flags = 0;
+  op->reserved = nullptr;
+  op++;
+  error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1),
+                                nullptr);
+  GPR_ASSERT(GRPC_CALL_OK == error);
+  CQ_EXPECT_COMPLETION(cqv, tag(1), 1);
+  cq_verify(cqv);
+
+  GPR_ASSERT(GRPC_STATUS_PERMISSION_DENIED == status);
+  GPR_ASSERT(0 ==
+             grpc_slice_str_cmp(details, "Unauthorized RPC request rejected."));
+
+  grpc_slice_unref(details);
+  gpr_free(const_cast<char*>(error_string));
+  grpc_metadata_array_destroy(&initial_metadata_recv);
+  grpc_metadata_array_destroy(&trailing_metadata_recv);
+
+  grpc_call_unref(c);
+  cq_verifier_destroy(cqv);
+
+  end_test(&f);
+  config.tear_down_data(&f);
+}
+
+static void test_deny_request_no_match_in_policy(
+    grpc_end2end_test_config config) {
+  grpc_call* c;
+  grpc_op ops[6];
+  grpc_op* op;
+  grpc_metadata_array initial_metadata_recv;
+  grpc_metadata_array trailing_metadata_recv;
+  grpc_status_code status;
+  const char* error_string = nullptr;
+  grpc_call_error error;
+  grpc_slice details = grpc_empty_slice();
+
+  const char* authz_policy =
+      "{"
+      "  \"name\": \"authz\","
+      "  \"allow_rules\": ["
+      "    {"
+      "      \"name\": \"allow_foo\","
+      "      \"request\": {"
+      "        \"paths\": ["
+      "          \"*/foo\""
+      "        ]"
+      "      }"
+      "    }"
+      "  ]"
+      "}";
+  grpc_status_code code;
+  const char* error_details;
+  grpc_authorization_policy_provider* provider =
+      grpc_authorization_policy_provider_static_data_create(authz_policy, &code,
+                                                            &error_details);
+  GPR_ASSERT(GRPC_STATUS_OK == code);
+  grpc_arg args[] = {
+      grpc_channel_arg_pointer_create(
+          const_cast<char*>(GRPC_ARG_AUTHORIZATION_POLICY_PROVIDER), provider,
+          grpc_authorization_policy_provider_arg_vtable()),
+  };
+  grpc_channel_args server_args = {GPR_ARRAY_SIZE(args), args};
+
+  grpc_end2end_test_fixture f = begin_test(
+      config, "test_deny_request_no_match_in_policy", nullptr, &server_args);
+  grpc_authorization_policy_provider_release(provider);
+  cq_verifier* cqv = cq_verifier_create(f.cq);
+
+  gpr_timespec deadline = five_seconds_from_now();
+  c = grpc_channel_create_call(f.client, nullptr, GRPC_PROPAGATE_DEFAULTS, f.cq,
+                               grpc_slice_from_static_string("/bar"), nullptr,
+                               deadline, nullptr);
+  GPR_ASSERT(c);
+
+  grpc_metadata_array_init(&initial_metadata_recv);
+  grpc_metadata_array_init(&trailing_metadata_recv);
+
+  memset(ops, 0, sizeof(ops));
+  op = ops;
+  op->op = GRPC_OP_SEND_INITIAL_METADATA;
+  op->data.send_initial_metadata.count = 0;
+  op->flags = 0;
+  op->reserved = nullptr;
+  op++;
+  op->op = GRPC_OP_SEND_CLOSE_FROM_CLIENT;
+  op->flags = 0;
+  op->reserved = nullptr;
+  op++;
+  op->op = GRPC_OP_RECV_INITIAL_METADATA;
+  op->data.recv_initial_metadata.recv_initial_metadata = &initial_metadata_recv;
+  op->flags = 0;
+  op->reserved = nullptr;
+  op++;
+  op->op = GRPC_OP_RECV_STATUS_ON_CLIENT;
+  op->data.recv_status_on_client.trailing_metadata = &trailing_metadata_recv;
+  op->data.recv_status_on_client.status = &status;
+  op->data.recv_status_on_client.status_details = &details;
+  op->data.recv_status_on_client.error_string = &error_string;
+  op->flags = 0;
+  op->reserved = nullptr;
+  op++;
+  error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1),
+                                nullptr);
+  GPR_ASSERT(GRPC_CALL_OK == error);
+  CQ_EXPECT_COMPLETION(cqv, tag(1), 1);
+  cq_verify(cqv);
+
+  GPR_ASSERT(GRPC_STATUS_PERMISSION_DENIED == status);
+  GPR_ASSERT(0 ==
+             grpc_slice_str_cmp(details, "Unauthorized RPC request rejected."));
+
+  grpc_slice_unref(details);
+  gpr_free(const_cast<char*>(error_string));
+  grpc_metadata_array_destroy(&initial_metadata_recv);
+  grpc_metadata_array_destroy(&trailing_metadata_recv);
+
+  grpc_call_unref(c);
+  cq_verifier_destroy(cqv);
+
+  end_test(&f);
+  config.tear_down_data(&f);
+}
+
+void sdk_authz(grpc_end2end_test_config config) {
+  test_allow_authorized_request(config);
+  test_deny_unauthorized_request(config);
+  test_deny_request_no_match_in_policy(config);
+}
+
+void sdk_authz_pre_init(void) {}
index 859fa61..3c16b57 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/time.h>
+
 #include "src/core/lib/gpr/string.h"
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
 
index f457e65..f7dcf0f 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -25,7 +23,9 @@
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/time.h>
+
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
 
index 443c3ce..63f66a7 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -25,7 +23,9 @@
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/time.h>
+
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
 
index 92f45e5..4c4128e 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -25,7 +23,9 @@
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/time.h>
+
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
 
index 8817da1..f14df66 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -25,7 +23,9 @@
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/time.h>
+
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 
 enum { TIMEOUT = 200000 };
 
index 947e397..1017012 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -25,7 +23,9 @@
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/time.h>
+
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
 
index e56ed53..74c28d4 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -25,7 +23,9 @@
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/time.h>
+
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
 
index c9782a1..df5d40e 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/time.h>
+
 #include "src/core/lib/debug/stats.h"
 #include "src/core/lib/gpr/string.h"
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
 
index 3bb481a..965b7e5 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -38,6 +36,7 @@
 #include "src/core/lib/surface/call_test_only.h"
 #include "src/core/lib/transport/static_metadata.h"
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
 
index cf29185..f552294 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/time.h>
+
 #include "src/core/lib/channel/channel_args.h"
 #include "src/core/lib/compression/compression_args.h"
 #include "src/core/lib/surface/call.h"
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
 
index 36c6cd2..c7e131a 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -31,6 +29,7 @@
 #include "src/core/lib/compression/compression_args.h"
 #include "src/core/lib/surface/call.h"
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
 
index df0c778..178eb68 100644 (file)
@@ -19,8 +19,6 @@
 /** \file Verify that status ordering rules are obeyed.
     \ref doc/status_ordering.md */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -28,7 +26,9 @@
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/time.h>
+
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
 
index a674bb7..1d1b883 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -25,7 +23,9 @@
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/time.h>
+
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
 
index 69b33eb..a2e7476 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -35,6 +33,7 @@
 #include "src/core/lib/surface/call_test_only.h"
 #include "src/core/lib/transport/static_metadata.h"
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
 
index 2f1b297..d3536a9 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -25,7 +23,9 @@
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/time.h>
+
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
 
index 55c208f..c0114d9 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "test/core/end2end/end2end_tests.h"
-
 #include <stdio.h>
 #include <string.h>
 
@@ -25,7 +23,9 @@
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/time.h>
+
 #include "test/core/end2end/cq_verifier.h"
+#include "test/core/end2end/end2end_tests.h"
 
 static void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
 
index bcae9c0..f6e5814 100644 (file)
 // limitations under the License.
 #include <grpc/support/port_platform.h>
 
-#include "grpc/event_engine/endpoint_config.h"
-
 #include <gmock/gmock.h>
-#include <grpc/grpc.h>
 #include <gtest/gtest.h>
 
-#include "test/core/util/test_config.h"
+#include <grpc/event_engine/endpoint_config.h>
+#include <grpc/grpc.h>
 
 #include "src/core/lib/channel/channel_args.h"
 #include "src/core/lib/event_engine/endpoint_config_internal.h"
+#include "test/core/util/test_config.h"
 
 using ::grpc_event_engine::experimental::ChannelArgsEndpointConfig;
 
index c9db195..5fa5ecc 100644 (file)
  *
  */
 
-#include <grpc/grpc.h>
-
 #include <stdio.h>
 #include <string.h>
 
+#include <grpc/grpc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/time.h>
 
index af9bd55..441cf00 100644 (file)
  *
  */
 
-#include <grpc/grpc.h>
-#include <grpc/grpc_security.h>
-
 #include <signal.h>
 #include <stdio.h>
 #include <stdlib.h>
 #include <string.h>
 #include <time.h>
+
+#include <grpc/grpc.h>
+#include <grpc/grpc_security.h>
 #ifndef _WIN32
 /* This is for _exit() below, which is temporary. */
 #include <unistd.h>
index 83f3e3c..21b5891 100644 (file)
@@ -134,6 +134,9 @@ grpc_cc_test(
 grpc_cc_test(
     name = "tls_test",
     srcs = ["tls_test.cc"],
+    external_deps = [
+        "gtest",
+    ],
     language = "C++",
     uses_polling = False,
     deps = [
index 316a4c6..90c72ba 100644 (file)
    gpr_cpu_current_cpu()
 */
 
-#include <grpc/support/cpu.h>
-
 #include <stdio.h>
 #include <string.h>
 
 #include <grpc/support/alloc.h>
+#include <grpc/support/cpu.h>
 #include <grpc/support/log.h>
 #include <grpc/support/sync.h>
 #include <grpc/support/time.h>
index 3883a5d..89237cd 100644 (file)
  *
  */
 
+#include "src/core/lib/gpr/env.h"
+
 #include <stdio.h>
 #include <string.h>
 
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 
-#include "src/core/lib/gpr/env.h"
 #include "src/core/lib/gpr/string.h"
 #include "test/core/util/test_config.h"
 
index fdc2cfa..1756496 100644 (file)
  */
 
 #include "src/core/lib/gpr/murmur_hash.h"
+
+#include <string.h>
+
 #include <grpc/support/log.h>
 #include <grpc/support/string_util.h>
-#include "test/core/util/test_config.h"
 
-#include <string.h>
+#include "test/core/util/test_config.h"
 
 typedef uint32_t (*hash_func)(const void* key, size_t len, uint32_t seed);
 
index ae0025f..b38180d 100644 (file)
 
 /* Test of gpr synchronization support. */
 
-#include <grpc/support/sync.h>
-
 #include <stdio.h>
 #include <stdlib.h>
 
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
+#include <grpc/support/sync.h>
 #include <grpc/support/time.h>
 
 #include "src/core/lib/gprpp/thd.h"
index a32cbfb..4631ae8 100644 (file)
 
 /* Test of gpr time support. */
 
-#include <grpc/support/log.h>
-#include <grpc/support/sync.h>
-#include <grpc/support/time.h>
 #include <inttypes.h>
 #include <limits.h>
 #include <stdio.h>
 #include <stdlib.h>
 #include <string.h>
 
+#include <grpc/support/log.h>
+#include <grpc/support/sync.h>
+#include <grpc/support/time.h>
+
 #include "test/core/util/test_config.h"
 
 static void to_fp(void* arg, const char* buf, size_t len) {
index 58b2a25..1642580 100644 (file)
 
 #include "src/core/lib/gpr/tls.h"
 
-#include <stdio.h>
-#include <stdlib.h>
+#include <array>
 
-#include <grpc/support/log.h>
-#include <grpc/support/sync.h>
+#include <gtest/gtest.h>
 
 #include "src/core/lib/gprpp/thd.h"
 #include "test/core/util/test_config.h"
 
-#define NUM_THREADS 100
-
-GPR_TLS_DECL(test_var);
-
-static void thd_body(void* /*arg*/) {
-  intptr_t i;
-
-  GPR_ASSERT(gpr_tls_get(&test_var) == 0);
-
-  for (i = 0; i < 100000; i++) {
-    gpr_tls_set(&test_var, i);
-    GPR_ASSERT(gpr_tls_get(&test_var) == i);
+struct BiggerThanMachineWord {
+  size_t a, b;
+  uint8_t c;
+};
+
+static GPR_THREAD_LOCAL(BiggerThanMachineWord) test_var;
+// Fails to compile: static GPR_THREAD_LOCAL(std::unique_ptr<char>) non_trivial;
+
+namespace {
+void thd_body(void*) {
+  for (size_t i = 0; i < 100000; i++) {
+    BiggerThanMachineWord next = {i, i, uint8_t(i)};
+    test_var = next;
+    BiggerThanMachineWord read = test_var;
+    ASSERT_EQ(read.a, i);
+    ASSERT_EQ(read.b, i);
+    ASSERT_EQ(read.c, uint8_t(i)) << i;
   }
-  gpr_tls_set(&test_var, 0);
 }
 
-/* ------------------------------------------------- */
-
-int main(int argc, char* argv[]) {
-  grpc_core::Thread threads[NUM_THREADS];
-
-  grpc::testing::TestEnvironment env(argc, argv);
-
-  gpr_tls_init(&test_var);
-
-  for (auto& th : threads) {
+TEST(ThreadLocal, ReadWrite) {
+  std::array<grpc_core::Thread, 100> threads;
+  for (grpc_core::Thread& th : threads) {
     th = grpc_core::Thread("grpc_tls_test", thd_body, nullptr);
     th.Start();
   }
-  for (auto& th : threads) {
+  for (grpc_core::Thread& th : threads) {
     th.Join();
   }
+}
 
-  gpr_tls_destroy(&test_var);
+}  // namespace
 
-  return 0;
+int main(int argc, char* argv[]) {
+  grpc::testing::TestEnvironment env(argc, argv);
+  ::testing::InitGoogleTest(&argc, argv);
+  return RUN_ALL_TESTS();
 }
index 4f8582a..8be6100 100644 (file)
  *
  */
 
-#include <grpc/support/log.h>
 #include <grpc/support/port_platform.h>
 
 #include "src/core/lib/gpr/useful.h"
+
+#include <grpc/support/log.h>
+
 #include "test/core/util/test_config.h"
 
 int main(int argc, char** argv) {
index 7408a17..5401357 100644 (file)
@@ -271,3 +271,15 @@ grpc_cc_test(
         "//test/core/util:grpc_test_util",
     ],
 )
+
+grpc_cc_test(
+    name = "capture_test",
+    srcs = ["capture_test.cc"],
+    external_deps = ["gtest"],
+    language = "c++",
+    uses_polling = False,
+    deps = [
+        "//:capture",
+        "//test/core/util:grpc_suppressions",
+    ],
+)
index bbd0a70..88f365c 100644 (file)
@@ -13,6 +13,7 @@
 // limitations under the License.
 
 #include "src/core/lib/gprpp/bitset.h"
+
 #include <gtest/gtest.h>
 
 namespace grpc_core {
diff --git a/test/core/gprpp/capture_test.cc b/test/core/gprpp/capture_test.cc
new file mode 100644 (file)
index 0000000..0cb68ef
--- /dev/null
@@ -0,0 +1,39 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#include "src/core/lib/gprpp/capture.h"
+
+#include <gtest/gtest.h>
+
+namespace grpc_core {
+
+TEST(CaptureTest, Capture) {
+  auto f = Capture([](int* p) { EXPECT_EQ(*p, 42); }, 42);
+  f();
+}
+
+TEST(CaptureTest, WithArgsAndReturn) {
+  int captured = 1;
+  auto f =
+      Capture([captured](int* p, int arg) { return (captured + *p) * arg; }, 2);
+  EXPECT_EQ(f(2), 6);
+  EXPECT_EQ(f(3), 9);
+}
+
+}  // namespace grpc_core
+
+int main(int argc, char** argv) {
+  ::testing::InitGoogleTest(&argc, argv);
+  return RUN_ALL_TESTS();
+}
index d67dd42..519c242 100644 (file)
@@ -16,6 +16,8 @@
  *
  */
 
+#include "src/core/lib/gprpp/global_config_env.h"
+
 #include <stdio.h>
 #include <string.h>
 
@@ -25,7 +27,6 @@
 #include <grpc/support/log.h>
 
 #include "src/core/lib/gpr/env.h"
-#include "src/core/lib/gprpp/global_config_env.h"
 #include "src/core/lib/gprpp/memory.h"
 
 namespace {
index 7da78b6..31ab94b 100644 (file)
@@ -16,6 +16,8 @@
  *
  */
 
+#include "src/core/lib/gprpp/global_config.h"
+
 #include <stdio.h>
 #include <string.h>
 
@@ -25,7 +27,6 @@
 #include <grpc/support/log.h>
 
 #include "src/core/lib/gpr/env.h"
-#include "src/core/lib/gprpp/global_config.h"
 #include "src/core/lib/gprpp/memory.h"
 
 GPR_GLOBAL_CONFIG_DECLARE_BOOL(bool_var);
index 0cff997..a63065c 100644 (file)
  *
  */
 
+#include "src/core/lib/gprpp/host_port.h"
+
 #include <string.h>
 
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 
-#include "src/core/lib/gprpp/host_port.h"
 #include "test/core/util/test_config.h"
 
 static void join_host_port_expect(const char* host, int port,
index 828f2f8..04ad592 100644 (file)
 /* Test of gpr synchronization support. */
 
 #include "src/core/lib/gprpp/manual_constructor.h"
-#include <grpc/support/alloc.h>
-#include <grpc/support/log.h>
-#include <grpc/support/sync.h>
+
 #include <stdio.h>
 #include <stdlib.h>
+
 #include <cstring>
 
+#include <grpc/support/alloc.h>
+#include <grpc/support/log.h>
+#include <grpc/support/sync.h>
+
 #include "test/core/util/test_config.h"
 
 class A {
index a3b9cd7..f0ea8a0 100644 (file)
@@ -13,6 +13,7 @@
 // limitations under the License.
 
 #include "src/core/lib/gprpp/match.h"
+
 #include <gtest/gtest.h>
 
 namespace grpc_core {
index 1e7f346..2bbc331 100644 (file)
@@ -13,6 +13,7 @@
 // limitations under the License.
 
 #include "src/core/lib/gprpp/overload.h"
+
 #include <gtest/gtest.h>
 
 namespace grpc_core {
index a807717..7f3a007 100644 (file)
@@ -14,6 +14,8 @@
 // limitations under the License.
 //
 
+#include "src/core/lib/gprpp/stat.h"
+
 #include <stdio.h>
 #include <string.h>
 
@@ -27,7 +29,6 @@
 
 #include "src/core/lib/gpr/string.h"
 #include "src/core/lib/gpr/tmpfile.h"
-#include "src/core/lib/gprpp/stat.h"
 #include "src/core/lib/iomgr/load_file.h"
 #include "test/core/util/test_config.h"
 
index 0f3957b..22cb905 100644 (file)
 // limitations under the License.
 
 #include "src/core/lib/gprpp/table.h"
-#include <gtest/gtest.h>
+
 #include <string>
 #include <tuple>
+
+#include <gtest/gtest.h>
+
 #include "absl/types/optional.h"
 
 namespace grpc_core {
index 4529147..0fbbce5 100644 (file)
 // limitations under the License.
 //
 
+#include "src/core/lib/gprpp/time_util.h"
+
 #include <stdio.h>
 #include <string.h>
 
 #include <gtest/gtest.h>
 
-#include <grpc/support/time.h>
-
 #include "absl/time/time.h"
 
-#include "src/core/lib/gprpp/time_util.h"
+#include <grpc/support/time.h>
 
 TEST(TimeUtilTest, ToGprTimeSpecFromAbslDurationWithRegularValues) {
   std::vector<int> times = {-10, -1, 0, 1, 10};
index 78413cc..a18e971 100644 (file)
@@ -22,8 +22,6 @@
 #ifdef GRPC_POSIX_SOCKET_TCP
 
 #include <arpa/inet.h>
-#include <openssl/err.h>
-#include <openssl/ssl.h>
 #include <stdlib.h>
 #include <string.h>
 #include <sys/socket.h>
@@ -31,6 +29,9 @@
 
 #include <string>
 
+#include <openssl/err.h>
+#include <openssl/ssl.h>
+
 #include "absl/strings/str_cat.h"
 
 #include <grpc/grpc.h>
index a70ba39..120490e 100644 (file)
  */
 
 #include <arpa/inet.h>
-#include <openssl/err.h>
-#include <openssl/ssl.h>
 #include <string.h>
 #include <sys/socket.h>
 #include <unistd.h>
 
+#include <openssl/err.h>
+#include <openssl/ssl.h>
+
 #include <grpc/grpc.h>
 #include <grpc/grpc_security.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/string_util.h>
 #include <grpc/support/sync.h>
 
-#include "src/core/lib/iomgr/load_file.h"
-#include "test/core/util/port.h"
-#include "test/core/util/test_config.h"
-
 #include "src/core/lib/channel/handshaker_factory.h"
 #include "src/core/lib/channel/handshaker_registry.h"
+#include "src/core/lib/config/core_configuration.h"
+#include "src/core/lib/iomgr/load_file.h"
 #include "src/core/lib/security/transport/security_handshaker.h"
-
 #include "test/core/handshake/server_ssl_common.h"
+#include "test/core/util/port.h"
+#include "test/core/util/test_config.h"
 
 /* The purpose of this test is to exercise the case when a
  * grpc *security_handshaker* begins its handshake with data already
@@ -77,10 +77,15 @@ class ReadAheadHandshakerFactory : public HandshakerFactory {
 }  // namespace grpc_core
 
 int main(int /*argc*/, char* /*argv*/[]) {
+  grpc_core::CoreConfiguration::BuildSpecialConfiguration(
+      [](grpc_core::CoreConfiguration::Builder* builder) {
+        BuildCoreConfiguration(builder);
+        builder->handshaker_registry()->RegisterHandshakerFactory(
+            true /* at_start */, grpc_core::HANDSHAKER_SERVER,
+            absl::make_unique<grpc_core::ReadAheadHandshakerFactory>());
+      });
+
   grpc_init();
-  grpc_core::HandshakerRegistry::RegisterHandshakerFactory(
-      true /* at_start */, grpc_core::HANDSHAKER_SERVER,
-      absl::make_unique<grpc_core::ReadAheadHandshakerFactory>());
   const char* full_alpn_list[] = {"grpc-exp", "h2"};
   GPR_ASSERT(server_ssl_test(full_alpn_list, 2, "grpc-exp"));
   CleanupSslLibrary();
index 3358022..f759b70 100644 (file)
  */
 
 #include <arpa/inet.h>
-#include <openssl/err.h>
-#include <openssl/ssl.h>
 #include <string.h>
 #include <sys/socket.h>
 #include <unistd.h>
 
+#include <openssl/err.h>
+#include <openssl/ssl.h>
+
 #include <grpc/grpc.h>
 #include <grpc/grpc_security.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/sync.h>
 
 #include "src/core/lib/iomgr/load_file.h"
+#include "test/core/handshake/server_ssl_common.h"
 #include "test/core/util/port.h"
 #include "test/core/util/test_config.h"
 
-#include "test/core/handshake/server_ssl_common.h"
-
 int main(int argc, char* argv[]) {
   grpc::testing::TestEnvironment env(argc, argv);
   // Handshake succeeeds when the client supplies the standard ALPN list.
index ce41052..7b89146 100644 (file)
 #include "test/core/handshake/server_ssl_common.h"
 
 #include <arpa/inet.h>
-#include <openssl/err.h>
-#include <openssl/ssl.h>
 #include <string.h>
 #include <sys/socket.h>
 #include <unistd.h>
 
 #include <string>
 
+#include <openssl/err.h>
+#include <openssl/ssl.h>
+
 #include "absl/strings/str_cat.h"
 
 #include <grpc/grpc.h>
index 4cac435..606fb2c 100644 (file)
@@ -22,8 +22,6 @@
 #ifdef GRPC_POSIX_SOCKET_TCP
 
 #include <arpa/inet.h>
-#include <openssl/err.h>
-#include <openssl/ssl.h>
 #include <stdlib.h>
 #include <string.h>
 #include <sys/socket.h>
@@ -31,6 +29,9 @@
 
 #include <string>
 
+#include <openssl/err.h>
+#include <openssl/ssl.h>
+
 #include "absl/strings/str_cat.h"
 
 #include <grpc/grpc.h>
index b0a90c4..d4d1be8 100644 (file)
@@ -21,6 +21,7 @@
 #include <string.h>
 
 #include <grpc/support/log.h>
+
 #include "test/core/util/test_config.h"
 
 static void test_format_get_request(void) {
index f9fd311..dbc0471 100644 (file)
@@ -83,7 +83,6 @@ static void test_get(int port) {
       &g_context, &g_pops, resource_quota, &req, n_seconds_time(15),
       GRPC_CLOSURE_CREATE(on_finish, &response, grpc_schedule_on_exec_ctx),
       &response);
-  grpc_resource_quota_unref_internal(resource_quota);
   gpr_mu_lock(g_mu);
   while (!g_done) {
     grpc_pollset_worker* worker = nullptr;
@@ -122,7 +121,6 @@ static void test_post(int port) {
       &g_context, &g_pops, resource_quota, &req, "hello", 5, n_seconds_time(15),
       GRPC_CLOSURE_CREATE(on_finish, &response, grpc_schedule_on_exec_ctx),
       &response);
-  grpc_resource_quota_unref_internal(resource_quota);
   gpr_mu_lock(g_mu);
   while (!g_done) {
     grpc_pollset_worker* worker = nullptr;
index a94a67b..07e46ff 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "src/core/lib/http/httpcli.h"
-
 #include <string.h>
 
 #include <grpc/grpc.h>
@@ -28,6 +26,7 @@
 #include <grpc/support/sync.h>
 
 #include "src/core/lib/gpr/env.h"
+#include "src/core/lib/http/httpcli.h"
 #include "src/core/lib/iomgr/iomgr.h"
 #include "src/core/lib/security/security_connector/ssl_utils_config.h"
 #include "test/core/util/port.h"
@@ -87,7 +86,6 @@ static void test_get(int port) {
       &g_context, &g_pops, resource_quota, &req, n_seconds_time(15),
       GRPC_CLOSURE_CREATE(on_finish, &response, grpc_schedule_on_exec_ctx),
       &response);
-  grpc_resource_quota_unref_internal(resource_quota);
   gpr_mu_lock(g_mu);
   while (!g_done) {
     grpc_pollset_worker* worker = nullptr;
@@ -127,7 +125,6 @@ static void test_post(int port) {
       &g_context, &g_pops, resource_quota, &req, "hello", 5, n_seconds_time(15),
       GRPC_CLOSURE_CREATE(on_finish, &response, grpc_schedule_on_exec_ctx),
       &response);
-  grpc_resource_quota_unref_internal(resource_quota);
   gpr_mu_lock(g_mu);
   while (!g_done) {
     grpc_pollset_worker* worker = nullptr;
index 6df4156..c7ac823 100644 (file)
  *
  */
 
-#include "src/core/lib/iomgr/port.h"
-
 #include "src/core/lib/iomgr/buffer_list.h"
 
 #include <grpc/grpc.h>
 
+#include "src/core/lib/iomgr/port.h"
 #include "test/core/util/test_config.h"
 
 #ifdef GRPC_LINUX_ERRQUEUE
index fb7686b..d97a3c7 100644 (file)
@@ -17,6 +17,7 @@
  */
 
 #include "src/core/lib/iomgr/endpoint_pair.h"
+
 #include <grpc/grpc.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
@@ -41,7 +42,6 @@ static grpc_endpoint_test_fixture create_fixture_endpoint_pair(
   a[0].value.integer = static_cast<int>(slice_size);
   grpc_channel_args args = {GPR_ARRAY_SIZE(a), a};
   grpc_endpoint_pair p = grpc_iomgr_create_endpoint_pair("test", &args);
-
   f.client_ep = p.client;
   f.server_ep = p.server;
   grpc_endpoint_add_to_pollset(f.client_ep, g_pollset);
index e50a5f0..cb3e30e 100644 (file)
 
 #include "src/core/lib/iomgr/error.h"
 
+#include <string.h>
+
 #include <grpc/grpc.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 
-#include <string.h>
-
 #include "test/core/util/test_config.h"
 
 static void test_set_get_int() {
index 35c27ec..5656efa 100644 (file)
 
 /* This test only relevant on linux systems where epoll() is available */
 #if defined(GRPC_LINUX_EPOLL_CREATE1) && defined(GRPC_LINUX_EVENTFD)
-#include "src/core/lib/iomgr/ev_epollex_linux.h"
-
-#include <grpc/grpc.h>
 #include <string.h>
 #include <sys/eventfd.h>
 
+#include <grpc/grpc.h>
+
+#include "src/core/lib/iomgr/ev_epollex_linux.h"
 #include "test/core/util/test_config.h"
 
 static void pollset_destroy(void* ps, grpc_error_handle /*error*/) {
index 0d27b94..8af8949 100644 (file)
@@ -39,17 +39,12 @@ int main(int argc, char** argv) {
        of descriptors */
     rlim.rlim_cur = rlim.rlim_max = 10;
     GPR_ASSERT(0 == setrlimit(RLIMIT_NOFILE, &rlim));
-    grpc_resource_quota* resource_quota =
-        grpc_resource_quota_create("fd_conservation_posix_test");
-
     for (i = 0; i < 100; i++) {
       p = grpc_iomgr_create_endpoint_pair("test", nullptr);
       grpc_endpoint_destroy(p.client);
       grpc_endpoint_destroy(p.server);
       grpc_core::ExecCtx::Get()->Flush();
     }
-
-    grpc_resource_quota_unref(resource_quota);
   }
 
   grpc_shutdown();
index 9ca837e..7c2ec73 100644 (file)
@@ -21,8 +21,6 @@
 // This test won't work except with posix sockets enabled
 #ifdef GRPC_POSIX_SOCKET_EV
 
-#include "src/core/lib/iomgr/ev_posix.h"
-
 #include <ctype.h>
 #include <errno.h>
 #include <fcntl.h>
index 2ef1f19..efda72e 100644 (file)
  *
  */
 
-#include "src/core/lib/iomgr/port.h"
-
-// grpc_ipv6_loopback_available isn't currently available on UV.
-#ifndef GRPC_UV
-
 #include <grpc/grpc.h>
 #include <grpc/support/log.h>
+
+#include "src/core/lib/iomgr/port.h"
 #include "test/core/util/test_config.h"
 
 #ifdef GPR_WINDOWS
@@ -40,9 +37,3 @@ int main(int argc, char** argv) {
   grpc_shutdown();
   return 0;
 }
-
-#else
-
-int main(int argc, char** argv) { return 0; }
-
-#endif /* GRPC_UV */
index a826f04..fd3253f 100644 (file)
@@ -30,6 +30,7 @@
 #include "src/core/lib/iomgr/endpoint.h"
 #include "src/core/lib/iomgr/resolve_address.h"
 #include "src/core/lib/iomgr/tcp_client.h"
+#include "test/core/util/resource_user_util.h"
 #include "test/core/util/test_config.h"
 
 // static int g_connections_complete = 0;
@@ -102,8 +103,8 @@ static void must_fail(void* arg, grpc_error_handle error) {
   /* connect to it */
   GPR_ASSERT(getsockname(svr_fd, (struct sockaddr*)addr, (socklen_t*)&resolved_addr.len) == 0);
   GRPC_CLOSURE_INIT(&done, must_succeed, nullptr, grpc_schedule_on_exec_ctx);
-  grpc_tcp_client_connect(&done, &g_connecting, nullptr, nullptr, &resolved_addr,
-                          GRPC_MILLIS_INF_FUTURE);
+  grpc_tcp_client_connect(&done, &g_connecting, grpc_slice_allocator_create_unlimited(), nullptr,
+                          nullptr, &resolved_addr, GRPC_MILLIS_INF_FUTURE);
 
   /* await the connection */
   do {
@@ -157,8 +158,8 @@ static void must_fail(void* arg, grpc_error_handle error) {
 
   /* connect to a broken address */
   GRPC_CLOSURE_INIT(&done, must_fail, nullptr, grpc_schedule_on_exec_ctx);
-  grpc_tcp_client_connect(&done, &g_connecting, nullptr, nullptr, &resolved_addr,
-                          GRPC_MILLIS_INF_FUTURE);
+  grpc_tcp_client_connect(&done, &g_connecting, grpc_slice_allocator_create_unlimited(), nullptr,
+                          nullptr, &resolved_addr, GRPC_MILLIS_INF_FUTURE);
 
   grpc_core::ExecCtx::Get()->Flush();
 
index a4a8555..faaafc9 100644 (file)
@@ -30,6 +30,7 @@
 #include "src/core/lib/iomgr/endpoint.h"
 #include "src/core/lib/iomgr/resolve_address.h"
 #include "src/core/lib/iomgr/tcp_client.h"
+#include "test/core/util/resource_user_util.h"
 #include "test/core/util/test_config.h"
 
 static const int kConnectTimeout = 5;
@@ -125,7 +126,8 @@ static bool compare_slice_buffer_with_buffer(grpc_slice_buffer *slices, const ch
   /* connect to it */
   XCTAssertEqual(getsockname(svr_fd, (struct sockaddr *)addr, (socklen_t *)&resolved_addr.len), 0);
   init_event_closure(&done, &connected);
-  grpc_tcp_client_connect(&done, &ep_, nullptr, nullptr, &resolved_addr, GRPC_MILLIS_INF_FUTURE);
+  grpc_tcp_client_connect(&done, &ep_, grpc_slice_allocator_create_unlimited(), nullptr, nullptr,
+                          &resolved_addr, GRPC_MILLIS_INF_FUTURE);
 
   /* await the connection */
   do {
index 69e9bf4..b47e02f 100644 (file)
@@ -9,6 +9,7 @@ GRPC_LOCAL_SRC = '../../../../..'
 # Install the dependencies in the main target plus all test targets.
 target 'CFStreamTests' do
   pod 'gRPC-Core', :path => GRPC_LOCAL_SRC
+  pod 'gRPC-Core/Tests', :path => GRPC_LOCAL_SRC
   pod 'BoringSSL-GRPC', :podspec => "#{GRPC_LOCAL_SRC}/src/objective-c", :inhibit_warnings => true
 end
 
index 6974ced..1e46ab4 100644 (file)
@@ -16,6 +16,8 @@
  *
  */
 
+#include "src/core/lib/iomgr/load_file.h"
+
 #include <stdio.h>
 #include <string.h>
 
@@ -26,7 +28,6 @@
 
 #include "src/core/lib/gpr/string.h"
 #include "src/core/lib/gpr/tmpfile.h"
-#include "src/core/lib/iomgr/load_file.h"
 #include "test/core/util/test_config.h"
 
 #define LOG_TEST_NAME(x) gpr_log(GPR_INFO, "%s", x)
index 6924a35..7e34a02 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "src/core/lib/iomgr/resolve_address.h"
-
 #include <net/if.h>
 #include <string.h>
 #include <sys/un.h>
@@ -39,6 +37,7 @@
 #include "src/core/lib/gprpp/thd.h"
 #include "src/core/lib/iomgr/executor.h"
 #include "src/core/lib/iomgr/iomgr.h"
+#include "src/core/lib/iomgr/resolve_address.h"
 #include "test/core/util/cmdline.h"
 #include "test/core/util/test_config.h"
 
index 4a2c714..6e633f5 100644 (file)
  */
 
 #include "src/core/lib/iomgr/resolve_address.h"
+
+#include <string.h>
+
+#include <address_sorting/address_sorting.h>
+
 #include <grpc/grpc.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/sync.h>
 #include <grpc/support/time.h>
 
-#include <address_sorting/address_sorting.h>
-
-#include <string.h>
-
 #include "src/core/ext/filters/client_channel/resolver/dns/dns_resolver_selection.h"
 #include "src/core/lib/event_engine/sockaddr.h"
 #include "src/core/lib/gpr/string.h"
@@ -355,9 +356,7 @@ int main(int argc, char** argv) {
     GPR_GLOBAL_CONFIG_SET(grpc_dns_resolver, "native");
   } else if (resolver_type != nullptr &&
              gpr_stricmp(resolver_type, "ares") == 0) {
-#ifndef GRPC_UV
     GPR_GLOBAL_CONFIG_SET(grpc_dns_resolver, "ares");
-#endif
   } else {
     gpr_log(GPR_ERROR, "--resolver_type was not set to ares or native");
     abort();
index 5d71af1..959542d 100644 (file)
@@ -21,6 +21,7 @@
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 
+#include "src/core/lib/channel/channel_args.h"
 #include "src/core/lib/iomgr/exec_ctx.h"
 #include "src/core/lib/slice/slice_internal.h"
 #include "test/core/util/test_config.h"
@@ -686,67 +687,167 @@ static void test_reclaimers_can_be_posted_repeatedly(void) {
 
 static void test_one_slice(void) {
   gpr_log(GPR_INFO, "** test_one_slice **");
-
   grpc_resource_quota* q = grpc_resource_quota_create("test_one_slice");
   grpc_resource_quota_resize(q, 1024);
-
-  grpc_resource_user* usr = grpc_resource_user_create(q, "usr");
-
-  grpc_resource_user_slice_allocator alloc;
+  grpc_slice_allocator* alloc = grpc_slice_allocator_create(q, "usr");
   int num_allocs = 0;
-  grpc_resource_user_slice_allocator_init(&alloc, usr, inc_int_cb, &num_allocs);
-
   grpc_slice_buffer buffer;
   grpc_slice_buffer_init(&buffer);
+  {
+    const int start_allocs = num_allocs;
+    grpc_core::ExecCtx exec_ctx;
+    GPR_ASSERT(!grpc_slice_allocator_allocate(
+        alloc, 1024, 1, grpc_slice_allocator_intent::kDefault, &buffer,
+        inc_int_cb, &num_allocs));
+    grpc_core::ExecCtx::Get()->Flush();
+    assert_counter_becomes(&num_allocs, start_allocs + 1);
+  }
+  {
+    grpc_core::ExecCtx exec_ctx;
+    grpc_slice_buffer_destroy_internal(&buffer);
+    grpc_slice_allocator_destroy(alloc);
+  }
+  grpc_resource_quota_unref(q);
+}
 
+static void test_one_slice_through_slice_allocator_factory(void) {
+  gpr_log(GPR_INFO, "** test_one_slice_through_slice_allocator_factory **");
+  grpc_resource_quota* resource_quota = grpc_resource_quota_create(
+      "test_one_slice_through_slice_allocator_factory");
+  int num_allocs = 0;
+  grpc_resource_quota_resize(resource_quota, 1024);
+  grpc_slice_allocator_factory* slice_allocator_factory =
+      grpc_slice_allocator_factory_create(resource_quota);
+  grpc_slice_allocator* slice_allocator =
+      grpc_slice_allocator_factory_create_slice_allocator(
+          slice_allocator_factory, "usr");
+  grpc_slice_buffer buffer;
+  grpc_slice_buffer_init(&buffer);
   {
     const int start_allocs = num_allocs;
     grpc_core::ExecCtx exec_ctx;
-    GPR_ASSERT(!grpc_resource_user_alloc_slices(&alloc, 1024, 1, &buffer));
+    GPR_ASSERT(!grpc_slice_allocator_allocate(
+        slice_allocator, 1024, 1, grpc_slice_allocator_intent::kDefault,
+        &buffer, inc_int_cb, &num_allocs));
     grpc_core::ExecCtx::Get()->Flush();
     assert_counter_becomes(&num_allocs, start_allocs + 1);
   }
+  {
+    grpc_core::ExecCtx exec_ctx;
+    grpc_slice_buffer_destroy_internal(&buffer);
+    grpc_slice_allocator_destroy(slice_allocator);
+    grpc_slice_allocator_factory_destroy(slice_allocator_factory);
+  }
+}
 
+static void test_slice_allocator_pressure_adjusted_allocation() {
+  gpr_log(GPR_INFO, "** test_slice_allocator_pressure_adjusted_allocation **");
+  // Quota large enough to avoid the 1/16 maximum allocation limit.
+  grpc_resource_quota* resource_quota = grpc_resource_quota_create(
+      "test_one_slice_through_slice_allocator_factory");
+  grpc_resource_quota_resize(resource_quota, 32 * 1024);
+  grpc_resource_user* black_hole_resource_user =
+      grpc_resource_user_create(resource_quota, "black hole");
+  {
+    // Consume ~95% of the quota
+    grpc_core::ExecCtx exec_ctx;
+    grpc_resource_user_safe_alloc(black_hole_resource_user, 31 * 1024);
+  }
+  GPR_ASSERT(grpc_resource_quota_get_memory_pressure(resource_quota) > 0.95);
+  grpc_slice_buffer buffer;
+  grpc_slice_buffer_init(&buffer);
+  grpc_slice_allocator* constrained_allocator =
+      grpc_slice_allocator_create(resource_quota, "constrained user");
+  {
+    // Attempt to get 512 bytes
+    grpc_core::ExecCtx exec_ctx;
+    GPR_ASSERT(!grpc_slice_allocator_allocate(
+        constrained_allocator, 2 * 1024, 1,
+        grpc_slice_allocator_intent::kReadBuffer, &buffer,
+        [](void*, grpc_error_handle) {}, nullptr));
+  }
+  grpc_slice slice = grpc_slice_buffer_take_first(&buffer);
+  GPR_ASSERT(grpc_refcounted_slice_length(slice) < 2 * 1024);
+  GPR_ASSERT(grpc_refcounted_slice_length(slice) >= 256);
   {
     grpc_core::ExecCtx exec_ctx;
+    grpc_slice_unref(slice);
+    grpc_resource_user_free(black_hole_resource_user, 31 * 1024);
+    grpc_resource_user_unref(black_hole_resource_user);
+    grpc_slice_allocator_destroy(constrained_allocator);
+    grpc_resource_quota_unref(resource_quota);
     grpc_slice_buffer_destroy_internal(&buffer);
   }
-  destroy_user(usr);
-  grpc_resource_quota_unref(q);
+}
+
+static void test_slice_allocator_capped_allocation() {
+  gpr_log(GPR_INFO, "** test_slice_allocator_pressure_adjusted_allocation **");
+  grpc_resource_quota* resource_quota = grpc_resource_quota_create(
+      "test_one_slice_through_slice_allocator_factory");
+  grpc_resource_quota_resize(resource_quota, 32 * 1024);
+  grpc_arg to_add[2];
+  grpc_channel_args* ch_args;
+  to_add[0] = grpc_channel_arg_integer_create(
+      const_cast<char*>(GRPC_ARG_TCP_MIN_READ_CHUNK_SIZE), 1024);
+  to_add[1] = grpc_channel_arg_integer_create(
+      const_cast<char*>(GRPC_ARG_TCP_MAX_READ_CHUNK_SIZE), 2048);
+  ch_args = grpc_channel_args_copy_and_add(nullptr, to_add, 2);
+  grpc_slice_allocator* slice_allocator =
+      grpc_slice_allocator_create(resource_quota, "capped user", ch_args);
+  grpc_slice_buffer buffer;
+  grpc_slice_buffer_init(&buffer);
+  {
+    // Attempt to get more than the maximum
+    grpc_core::ExecCtx exec_ctx;
+    GPR_ASSERT(!grpc_slice_allocator_allocate(
+        slice_allocator, 4 * 1024, 1, grpc_slice_allocator_intent::kReadBuffer,
+        &buffer, [](void*, grpc_error_handle) {}, nullptr));
+  }
+  grpc_slice max_slice = grpc_slice_buffer_take_first(&buffer);
+  GPR_ASSERT(grpc_refcounted_slice_length(max_slice) == 2048);
+  {
+    // Attempt to get less than the minimum
+    grpc_core::ExecCtx exec_ctx;
+    GPR_ASSERT(!grpc_slice_allocator_allocate(
+        slice_allocator, 512, 1, grpc_slice_allocator_intent::kReadBuffer,
+        &buffer, [](void*, grpc_error_handle) {}, nullptr));
+  }
+  grpc_slice min_slice = grpc_slice_buffer_take_first(&buffer);
+  GPR_ASSERT(grpc_refcounted_slice_length(min_slice) == 1024);
+  {
+    grpc_core::ExecCtx exec_ctx;
+    grpc_slice_unref(max_slice);
+    grpc_slice_unref(min_slice);
+    grpc_slice_allocator_destroy(slice_allocator);
+    grpc_resource_quota_unref(resource_quota);
+    grpc_slice_buffer_destroy_internal(&buffer);
+    grpc_channel_args_destroy(ch_args);
+  }
 }
 
 static void test_one_slice_deleted_late(void) {
   gpr_log(GPR_INFO, "** test_one_slice_deleted_late **");
-
   grpc_resource_quota* q =
       grpc_resource_quota_create("test_one_slice_deleted_late");
   grpc_resource_quota_resize(q, 1024);
-
-  grpc_resource_user* usr = grpc_resource_user_create(q, "usr");
-
-  grpc_resource_user_slice_allocator alloc;
+  grpc_slice_allocator* alloc = grpc_slice_allocator_create(q, "usr");
   int num_allocs = 0;
-  grpc_resource_user_slice_allocator_init(&alloc, usr, inc_int_cb, &num_allocs);
-
   grpc_slice_buffer buffer;
   grpc_slice_buffer_init(&buffer);
-
   {
     const int start_allocs = num_allocs;
     grpc_core::ExecCtx exec_ctx;
-    GPR_ASSERT(!grpc_resource_user_alloc_slices(&alloc, 1024, 1, &buffer));
+    GPR_ASSERT(!grpc_slice_allocator_allocate(
+        alloc, 1024, 1, grpc_slice_allocator_intent::kDefault, &buffer,
+        inc_int_cb, &num_allocs));
     grpc_core::ExecCtx::Get()->Flush();
     assert_counter_becomes(&num_allocs, start_allocs + 1);
   }
 
   {
     grpc_core::ExecCtx exec_ctx;
-    grpc_resource_user_unref(usr);
-  }
-
-  grpc_resource_quota_unref(q);
-  {
-    grpc_core::ExecCtx exec_ctx;
+    grpc_slice_allocator_destroy(alloc);
+    grpc_resource_quota_unref(q);
     grpc_slice_buffer_destroy_internal(&buffer);
   }
 }
@@ -763,20 +864,17 @@ static void test_negative_rq_free_pool(void) {
   grpc_resource_quota* q =
       grpc_resource_quota_create("test_negative_rq_free_pool");
   grpc_resource_quota_resize(q, 1024);
-
-  grpc_resource_user* usr = grpc_resource_user_create(q, "usr");
-
-  grpc_resource_user_slice_allocator alloc;
+  grpc_slice_allocator* alloc = grpc_slice_allocator_create(q, "usr");
   int num_allocs = 0;
-  grpc_resource_user_slice_allocator_init(&alloc, usr, inc_int_cb, &num_allocs);
-
   grpc_slice_buffer buffer;
   grpc_slice_buffer_init(&buffer);
 
   {
     const int start_allocs = num_allocs;
     grpc_core::ExecCtx exec_ctx;
-    GPR_ASSERT(!grpc_resource_user_alloc_slices(&alloc, 1024, 1, &buffer));
+    GPR_ASSERT(!grpc_slice_allocator_allocate(
+        alloc, 1024, 1, grpc_slice_allocator_intent::kDefault, &buffer,
+        inc_int_cb, &num_allocs));
     grpc_core::ExecCtx::Get()->Flush();
     assert_counter_becomes(&num_allocs, start_allocs + 1);
   }
@@ -789,12 +887,8 @@ static void test_negative_rq_free_pool(void) {
 
   {
     grpc_core::ExecCtx exec_ctx;
-    grpc_resource_user_unref(usr);
-  }
-
-  grpc_resource_quota_unref(q);
-  {
-    grpc_core::ExecCtx exec_ctx;
+    grpc_slice_allocator_destroy(alloc);
+    grpc_resource_quota_unref(q);
     grpc_slice_buffer_destroy_internal(&buffer);
   }
 }
@@ -867,8 +961,8 @@ static void test_thread_maxquota_change() {
   grpc_resource_quota_set_max_threads(rq, 150);
   GPR_ASSERT(grpc_resource_user_allocate_threads(ru2, 20));  // ru2=70, ru1=50
 
-  // Decrease maxquota (Note: Quota already given to ru1 and ru2 is unaffected)
-  // Max threads = 10;
+  // Decrease maxquota (Note: Quota already given to ru1 and ru2 is
+  // unaffected) Max threads = 10;
   grpc_resource_quota_set_max_threads(rq, 10);
 
   // New requests will fail until quota is available
@@ -918,6 +1012,9 @@ int main(int argc, char** argv) {
   test_one_slice_deleted_late();
   test_resize_to_zero();
   test_negative_rq_free_pool();
+  test_one_slice_through_slice_allocator_factory();
+  test_slice_allocator_pressure_adjusted_allocation();
+  test_slice_allocator_capped_allocation();
   gpr_mu_destroy(&g_mu);
   gpr_cv_destroy(&g_cv);
 
index 899eeb4..b960fc1 100644 (file)
@@ -21,8 +21,6 @@
 // This test won't work except with posix sockets enabled
 #ifdef GRPC_POSIX_SOCKET_UTILS_COMMON
 
-#include "src/core/lib/iomgr/socket_utils_posix.h"
-
 #include <errno.h>
 #include <netinet/in.h>
 #include <netinet/ip.h>
@@ -34,6 +32,7 @@
 
 #include "src/core/lib/gpr/useful.h"
 #include "src/core/lib/iomgr/socket_mutator.h"
+#include "src/core/lib/iomgr/socket_utils_posix.h"
 #include "test/core/util/test_config.h"
 
 struct test_socket_mutator {
index 4511823..3634b2c 100644 (file)
 
 #include <gmock/gmock.h>
 
+#include "absl/strings/str_cat.h"
+#include "absl/strings/str_format.h"
+#include "absl/types/optional.h"
+
 #include <grpc/grpc.h>
 #include <grpc/grpc_security.h>
 #include <grpc/impl/codegen/grpc_types.h>
 #include <grpc/support/string_util.h>
 #include <grpc/support/time.h>
 
-#include "absl/strings/str_cat.h"
-#include "absl/strings/str_format.h"
-#include "absl/types/optional.h"
-
 #include "src/core/ext/filters/client_channel/resolver/fake/fake_resolver.h"
 #include "src/core/lib/address_utils/parse_address.h"
 #include "src/core/lib/gpr/useful.h"
 #include "src/core/lib/security/security_connector/alts/alts_security_connector.h"
 #include "src/core/lib/slice/slice_string_helpers.h"
 #include "src/core/lib/uri/uri_parser.h"
-
+#include "test/core/end2end/cq_verifier.h"
 #include "test/core/util/memory_counters.h"
 #include "test/core/util/port.h"
 #include "test/core/util/test_config.h"
 
-#include "test/core/end2end/cq_verifier.h"
-
 namespace {
 
 const int kNumMessagePingPongsPerCall = 4000;
index 247753e..e5ec7bc 100644 (file)
@@ -21,8 +21,6 @@
 // This test won't work except with posix sockets enabled
 #ifdef GRPC_POSIX_SOCKET_TCP_CLIENT
 
-#include "src/core/lib/iomgr/tcp_client.h"
-
 #include <errno.h>
 #include <netinet/in.h>
 #include <string.h>
@@ -37,7 +35,9 @@
 #include "src/core/lib/iomgr/iomgr.h"
 #include "src/core/lib/iomgr/pollset_set.h"
 #include "src/core/lib/iomgr/socket_utils_posix.h"
+#include "src/core/lib/iomgr/tcp_client.h"
 #include "src/core/lib/iomgr/timer.h"
+#include "test/core/util/resource_user_util.h"
 #include "test/core/util/test_config.h"
 
 static grpc_pollset_set* g_pollset_set;
@@ -77,6 +77,7 @@ static void must_fail(void* /*arg*/, grpc_error_handle error) {
 }
 
 void test_succeeds(void) {
+  gpr_log(GPR_ERROR, "---- starting test_succeeds() ----");
   grpc_resolved_address resolved_addr;
   struct sockaddr_in* addr =
       reinterpret_cast<struct sockaddr_in*>(resolved_addr.addr);
@@ -86,8 +87,6 @@ void test_succeeds(void) {
   grpc_closure done;
   grpc_core::ExecCtx exec_ctx;
 
-  gpr_log(GPR_DEBUG, "test_succeeds");
-
   memset(&resolved_addr, 0, sizeof(resolved_addr));
   resolved_addr.len = static_cast<socklen_t>(sizeof(struct sockaddr_in));
   addr->sin_family = AF_INET;
@@ -107,9 +106,9 @@ void test_succeeds(void) {
   GPR_ASSERT(getsockname(svr_fd, (struct sockaddr*)addr,
                          (socklen_t*)&resolved_addr.len) == 0);
   GRPC_CLOSURE_INIT(&done, must_succeed, nullptr, grpc_schedule_on_exec_ctx);
-  grpc_tcp_client_connect(&done, &g_connecting, g_pollset_set, nullptr,
-                          &resolved_addr, GRPC_MILLIS_INF_FUTURE);
-
+  grpc_tcp_client_connect(
+      &done, &g_connecting, grpc_slice_allocator_create_unlimited(),
+      g_pollset_set, nullptr, &resolved_addr, GRPC_MILLIS_INF_FUTURE);
   /* await the connection */
   do {
     resolved_addr.len = static_cast<socklen_t>(sizeof(addr));
@@ -134,9 +133,11 @@ void test_succeeds(void) {
   }
 
   gpr_mu_unlock(g_mu);
+  gpr_log(GPR_ERROR, "---- finished test_succeeds() ----");
 }
 
 void test_fails(void) {
+  gpr_log(GPR_ERROR, "---- starting test_fails() ----");
   grpc_resolved_address resolved_addr;
   struct sockaddr_in* addr =
       reinterpret_cast<struct sockaddr_in*>(resolved_addr.addr);
@@ -144,8 +145,6 @@ void test_fails(void) {
   grpc_closure done;
   grpc_core::ExecCtx exec_ctx;
 
-  gpr_log(GPR_DEBUG, "test_fails");
-
   memset(&resolved_addr, 0, sizeof(resolved_addr));
   resolved_addr.len = static_cast<socklen_t>(sizeof(struct sockaddr_in));
   addr->sin_family = AF_INET;
@@ -156,9 +155,9 @@ void test_fails(void) {
 
   /* connect to a broken address */
   GRPC_CLOSURE_INIT(&done, must_fail, nullptr, grpc_schedule_on_exec_ctx);
-  grpc_tcp_client_connect(&done, &g_connecting, g_pollset_set, nullptr,
-                          &resolved_addr, GRPC_MILLIS_INF_FUTURE);
-
+  grpc_tcp_client_connect(
+      &done, &g_connecting, grpc_slice_allocator_create_unlimited(),
+      g_pollset_set, nullptr, &resolved_addr, GRPC_MILLIS_INF_FUTURE);
   gpr_mu_lock(g_mu);
 
   /* wait for the connection callback to finish */
@@ -183,6 +182,51 @@ void test_fails(void) {
   }
 
   gpr_mu_unlock(g_mu);
+  gpr_log(GPR_ERROR, "---- finished test_fails() ----");
+}
+
+void test_fails_bad_addr_no_leak(void) {
+  gpr_log(GPR_ERROR, "---- starting test_fails_bad_addr_no_leak() ----");
+  grpc_resolved_address resolved_addr;
+  struct sockaddr_in* addr =
+      reinterpret_cast<struct sockaddr_in*>(resolved_addr.addr);
+  int connections_complete_before;
+  grpc_closure done;
+  grpc_core::ExecCtx exec_ctx;
+  memset(&resolved_addr, 0, sizeof(resolved_addr));
+  resolved_addr.len = static_cast<socklen_t>(sizeof(struct sockaddr_in));
+  // force `grpc_tcp_client_prepare_fd` to fail. contrived, but effective.
+  addr->sin_family = AF_IPX;
+  gpr_mu_lock(g_mu);
+  connections_complete_before = g_connections_complete;
+  gpr_mu_unlock(g_mu);
+  // connect to an invalid address.
+  GRPC_CLOSURE_INIT(&done, must_fail, nullptr, grpc_schedule_on_exec_ctx);
+  grpc_tcp_client_connect(
+      &done, &g_connecting, grpc_slice_allocator_create_unlimited(),
+      g_pollset_set, nullptr, &resolved_addr, GRPC_MILLIS_INF_FUTURE);
+  gpr_mu_lock(g_mu);
+  while (g_connections_complete == connections_complete_before) {
+    grpc_pollset_worker* worker = nullptr;
+    grpc_millis polling_deadline = test_deadline();
+    switch (grpc_timer_check(&polling_deadline)) {
+      case GRPC_TIMERS_FIRED:
+        break;
+      case GRPC_TIMERS_NOT_CHECKED:
+        polling_deadline = 0;
+        ABSL_FALLTHROUGH_INTENDED;
+      case GRPC_TIMERS_CHECKED_AND_EMPTY:
+        GPR_ASSERT(GRPC_LOG_IF_ERROR(
+            "pollset_work",
+            grpc_pollset_work(g_pollset, &worker, polling_deadline)));
+        break;
+    }
+    gpr_mu_unlock(g_mu);
+    grpc_core::ExecCtx::Get()->Flush();
+    gpr_mu_lock(g_mu);
+  }
+  gpr_mu_unlock(g_mu);
+  gpr_log(GPR_ERROR, "---- finished test_fails_bad_addr_no_leak() ----");
 }
 
 static void destroy_pollset(void* p, grpc_error_handle /*error*/) {
@@ -202,8 +246,8 @@ int main(int argc, char** argv) {
     grpc_pollset_set_add_pollset(g_pollset_set, g_pollset);
 
     test_succeeds();
-    gpr_log(GPR_ERROR, "End of first test");
     test_fails();
+    test_fails_bad_addr_no_leak();
     grpc_pollset_set_destroy(g_pollset_set);
     GRPC_CLOSURE_INIT(&destroyed, destroy_pollset, g_pollset,
                       grpc_schedule_on_exec_ctx);
diff --git a/test/core/iomgr/tcp_client_uv_test.cc b/test/core/iomgr/tcp_client_uv_test.cc
deleted file mode 100644 (file)
index d6e3a5e..0000000
+++ /dev/null
@@ -1,214 +0,0 @@
-/*
- *
- * Copyright 2017 gRPC authors.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- *
- */
-
-#include "src/core/lib/iomgr/port.h"
-
-// This test won't work except with libuv
-#ifdef GRPC_UV
-
-#include <uv.h>
-
-#include <string.h>
-
-#include "src/core/lib/iomgr/tcp_client.h"
-
-#include <grpc/grpc.h>
-#include <grpc/support/alloc.h>
-#include <grpc/support/log.h>
-#include <grpc/support/time.h>
-
-#include "src/core/lib/iomgr/iomgr.h"
-#include "src/core/lib/iomgr/pollset.h"
-#include "src/core/lib/iomgr/timer.h"
-#include "test/core/util/test_config.h"
-
-static gpr_mu* g_mu;
-static grpc_pollset* g_pollset;
-static int g_connections_complete = 0;
-static grpc_endpoint* g_connecting = NULL;
-
-static grpc_millis test_deadline(void) {
-  return grpc_timespec_to_millis_round_up(grpc_timeout_seconds_to_deadline(10));
-}
-
-static void finish_connection() {
-  gpr_mu_lock(g_mu);
-  g_connections_complete++;
-  GPR_ASSERT(
-      GRPC_LOG_IF_ERROR("pollset_kick", grpc_pollset_kick(g_pollset, NULL)));
-  gpr_mu_unlock(g_mu);
-}
-
-static void must_succeed(void* arg, grpc_error_handle error) {
-  GPR_ASSERT(g_connecting != NULL);
-  GPR_ASSERT(error == GRPC_ERROR_NONE);
-  grpc_endpoint_shutdown(g_connecting, GRPC_ERROR_CREATE_FROM_STATIC_STRING(
-                                           "must_succeed called"));
-  grpc_endpoint_destroy(g_connecting);
-  g_connecting = NULL;
-  finish_connection();
-}
-
-static void must_fail(void* arg, grpc_error_handle error) {
-  GPR_ASSERT(g_connecting == NULL);
-  GPR_ASSERT(error != GRPC_ERROR_NONE);
-  finish_connection();
-}
-
-static void close_cb(uv_handle_t* handle) { gpr_free(handle); }
-
-static void connection_cb(uv_stream_t* server, int status) {
-  uv_tcp_t* client_handle =
-      static_cast<uv_tcp_t*>(gpr_malloc(sizeof(uv_tcp_t)));
-  GPR_ASSERT(0 == status);
-  GPR_ASSERT(0 == uv_tcp_init(uv_default_loop(), client_handle));
-  GPR_ASSERT(0 == uv_accept(server, (uv_stream_t*)client_handle));
-  uv_close((uv_handle_t*)client_handle, close_cb);
-}
-
-void test_succeeds(void) {
-  grpc_resolved_address resolved_addr;
-  struct sockaddr_in* addr = (struct sockaddr_in*)resolved_addr.addr;
-  uv_tcp_t* svr_handle = static_cast<uv_tcp_t*>(gpr_malloc(sizeof(uv_tcp_t)));
-  int connections_complete_before;
-  grpc_closure done;
-  grpc_core::ExecCtx exec_ctx;
-
-  gpr_log(GPR_DEBUG, "test_succeeds");
-
-  memset(&resolved_addr, 0, sizeof(resolved_addr));
-  resolved_addr.len = sizeof(struct sockaddr_in);
-  addr->sin_family = AF_INET;
-
-  /* create a phony server */
-  GPR_ASSERT(0 == uv_tcp_init(uv_default_loop(), svr_handle));
-  GPR_ASSERT(0 == uv_tcp_bind(svr_handle, (struct sockaddr*)addr, 0));
-  GPR_ASSERT(0 == uv_listen((uv_stream_t*)svr_handle, 1, connection_cb));
-
-  gpr_mu_lock(g_mu);
-  connections_complete_before = g_connections_complete;
-  gpr_mu_unlock(g_mu);
-
-  /* connect to it */
-  GPR_ASSERT(uv_tcp_getsockname(svr_handle, (struct sockaddr*)addr,
-                                (int*)&resolved_addr.len) == 0);
-  GRPC_CLOSURE_INIT(&done, must_succeed, NULL, grpc_schedule_on_exec_ctx);
-  grpc_tcp_client_connect(&done, &g_connecting, NULL, NULL, &resolved_addr,
-                          GRPC_MILLIS_INF_FUTURE);
-
-  gpr_mu_lock(g_mu);
-
-  while (g_connections_complete == connections_complete_before) {
-    grpc_pollset_worker* worker = NULL;
-    GPR_ASSERT(GRPC_LOG_IF_ERROR(
-        "pollset_work",
-        grpc_pollset_work(g_pollset, &worker,
-                          grpc_timespec_to_millis_round_up(
-                              grpc_timeout_seconds_to_deadline(5)))));
-    gpr_mu_unlock(g_mu);
-    grpc_core::ExecCtx::Get()->Flush();
-    gpr_mu_lock(g_mu);
-  }
-
-  // This will get cleaned up when the pollset runs again or gets shutdown
-  uv_close((uv_handle_t*)svr_handle, close_cb);
-
-  gpr_mu_unlock(g_mu);
-  grpc_core::ExecCtx::Get()->Flush();
-}
-
-void test_fails(void) {
-  grpc_resolved_address resolved_addr;
-  struct sockaddr_in* addr = (struct sockaddr_in*)resolved_addr.addr;
-  int connections_complete_before;
-  grpc_closure done;
-  grpc_core::ExecCtx exec_ctx;
-
-  gpr_log(GPR_DEBUG, "test_fails");
-
-  memset(&resolved_addr, 0, sizeof(resolved_addr));
-  resolved_addr.len = sizeof(struct sockaddr_in);
-  addr->sin_family = AF_INET;
-
-  gpr_mu_lock(g_mu);
-  connections_complete_before = g_connections_complete;
-  gpr_mu_unlock(g_mu);
-
-  /* connect to a broken address */
-  GRPC_CLOSURE_INIT(&done, must_fail, NULL, grpc_schedule_on_exec_ctx);
-  grpc_tcp_client_connect(&done, &g_connecting, NULL, NULL, &resolved_addr,
-                          GRPC_MILLIS_INF_FUTURE);
-
-  gpr_mu_lock(g_mu);
-
-  /* wait for the connection callback to finish */
-  while (g_connections_complete == connections_complete_before) {
-    grpc_pollset_worker* worker = NULL;
-    gpr_timespec now = gpr_now(GPR_CLOCK_MONOTONIC);
-    grpc_millis polling_deadline = test_deadline();
-    switch (grpc_timer_check(&polling_deadline)) {
-      case GRPC_TIMERS_FIRED:
-        break;
-      case GRPC_TIMERS_NOT_CHECKED:
-        polling_deadline = grpc_timespec_to_millis_round_up(now);
-        ABSL_FALLTHROUGH_INTENDED;
-      case GRPC_TIMERS_CHECKED_AND_EMPTY:
-        GPR_ASSERT(GRPC_LOG_IF_ERROR(
-            "pollset_work",
-            grpc_pollset_work(g_pollset, &worker, polling_deadline)));
-        break;
-    }
-    gpr_mu_unlock(g_mu);
-    grpc_core::ExecCtx::Get()->Flush();
-    gpr_mu_lock(g_mu);
-  }
-
-  gpr_mu_unlock(g_mu);
-  grpc_core::ExecCtx::Get()->Flush();
-}
-
-static void destroy_pollset(void* p, grpc_error_handle error) {
-  grpc_pollset_destroy(static_cast<grpc_pollset*>(p));
-}
-
-int main(int argc, char** argv) {
-  grpc_closure destroyed;
-  grpc::testing::TestEnvironment env(argc, argv);
-  grpc_init();
-  {
-    grpc_core::ExecCtx exec_ctx;
-    g_pollset = static_cast<grpc_pollset*>(gpr_malloc(grpc_pollset_size()));
-    grpc_pollset_init(g_pollset, &g_mu);
-
-    test_succeeds();
-    gpr_log(GPR_ERROR, "End of first test");
-    test_fails();
-    GRPC_CLOSURE_INIT(&destroyed, destroy_pollset, g_pollset,
-                      grpc_schedule_on_exec_ctx);
-    grpc_pollset_shutdown(g_pollset, &destroyed);
-    gpr_free(g_pollset);
-  }
-  grpc_shutdown();
-  return 0;
-}
-
-#else /* GRPC_UV */
-
-int main(int /*argc*/, char** /*argv*/) { return 1; }
-
-#endif /* GRPC_UV */
index 17c81b8..26ca182 100644 (file)
@@ -21,8 +21,6 @@
 // This test won't work except with posix sockets enabled
 #ifdef GRPC_POSIX_SOCKET_TCP
 
-#include "src/core/lib/iomgr/tcp_posix.h"
-
 #include <errno.h>
 #include <fcntl.h>
 #include <string.h>
 #include "src/core/lib/iomgr/buffer_list.h"
 #include "src/core/lib/iomgr/ev_posix.h"
 #include "src/core/lib/iomgr/sockaddr_posix.h"
+#include "src/core/lib/iomgr/tcp_posix.h"
 #include "src/core/lib/slice/slice_internal.h"
 #include "test/core/iomgr/endpoint_tests.h"
+#include "test/core/util/resource_user_util.h"
 #include "test/core/util/test_config.h"
 
 static gpr_mu* g_mu;
@@ -218,8 +218,8 @@ static void read_test(size_t num_bytes, size_t slice_size) {
   a[0].type = GRPC_ARG_INTEGER,
   a[0].value.integer = static_cast<int>(slice_size);
   grpc_channel_args args = {GPR_ARRAY_SIZE(a), a};
-  ep =
-      grpc_tcp_create(grpc_fd_create(sv[1], "read_test", false), &args, "test");
+  ep = grpc_tcp_create(grpc_fd_create(sv[1], "read_test", false), &args, "test",
+                       grpc_slice_allocator_create_unlimited());
   grpc_endpoint_add_to_pollset(ep, g_pollset);
 
   written_bytes = fill_socket_partial(sv[0], num_bytes);
@@ -270,7 +270,7 @@ static void large_read_test(size_t slice_size) {
   a[0].value.integer = static_cast<int>(slice_size);
   grpc_channel_args args = {GPR_ARRAY_SIZE(a), a};
   ep = grpc_tcp_create(grpc_fd_create(sv[1], "large_read_test", false), &args,
-                       "test");
+                       "test", grpc_slice_allocator_create_unlimited());
   grpc_endpoint_add_to_pollset(ep, g_pollset);
 
   written_bytes = fill_socket(sv[0]);
@@ -431,7 +431,7 @@ static void write_test(size_t num_bytes, size_t slice_size,
   a[0].value.integer = static_cast<int>(slice_size);
   grpc_channel_args args = {GPR_ARRAY_SIZE(a), a};
   ep = grpc_tcp_create(grpc_fd_create(sv[1], "write_test", collect_timestamps),
-                       &args, "test");
+                       &args, "test", grpc_slice_allocator_create_unlimited());
   grpc_endpoint_add_to_pollset(ep, g_pollset);
 
   state.ep = ep;
@@ -507,8 +507,8 @@ static void release_fd_test(size_t num_bytes, size_t slice_size) {
   a[0].type = GRPC_ARG_INTEGER;
   a[0].value.integer = static_cast<int>(slice_size);
   grpc_channel_args args = {GPR_ARRAY_SIZE(a), a};
-  ep =
-      grpc_tcp_create(grpc_fd_create(sv[1], "read_test", false), &args, "test");
+  ep = grpc_tcp_create(grpc_fd_create(sv[1], "read_test", false), &args, "test",
+                       grpc_slice_allocator_create_unlimited());
   GPR_ASSERT(grpc_tcp_fd(ep) == sv[1] && sv[1] >= 0);
   grpc_endpoint_add_to_pollset(ep, g_pollset);
 
@@ -597,18 +597,17 @@ static grpc_endpoint_test_fixture create_fixture_tcp_socketpair(
   grpc_core::ExecCtx exec_ctx;
 
   create_sockets(sv);
-  grpc_resource_quota* resource_quota =
-      grpc_resource_quota_create("tcp_posix_test_socketpair");
   grpc_arg a[1];
   a[0].key = const_cast<char*>(GRPC_ARG_TCP_READ_CHUNK_SIZE);
   a[0].type = GRPC_ARG_INTEGER;
   a[0].value.integer = static_cast<int>(slice_size);
   grpc_channel_args args = {GPR_ARRAY_SIZE(a), a};
-  f.client_ep = grpc_tcp_create(grpc_fd_create(sv[0], "fixture:client", false),
-                                &args, "test");
-  f.server_ep = grpc_tcp_create(grpc_fd_create(sv[1], "fixture:server", false),
-                                &args, "test");
-  grpc_resource_quota_unref_internal(resource_quota);
+  f.client_ep =
+      grpc_tcp_create(grpc_fd_create(sv[0], "fixture:client", false), &args,
+                      "test", grpc_slice_allocator_create_unlimited());
+  f.server_ep =
+      grpc_tcp_create(grpc_fd_create(sv[1], "fixture:server", false), &args,
+                      "test", grpc_slice_allocator_create_unlimited());
   grpc_endpoint_add_to_pollset(f.client_ep, g_pollset);
   grpc_endpoint_add_to_pollset(f.server_ep, g_pollset);
 
index 2e54266..9c116d1 100644 (file)
@@ -21,8 +21,6 @@
 // This test won't work except with posix sockets enabled
 #ifdef GRPC_POSIX_SOCKET_TCP_SERVER
 
-#include "src/core/lib/iomgr/tcp_server.h"
-
 #include <errno.h>
 #include <ifaddrs.h>
 #include <netinet/in.h>
@@ -44,6 +42,7 @@
 #include "src/core/lib/iomgr/error.h"
 #include "src/core/lib/iomgr/iomgr.h"
 #include "src/core/lib/iomgr/resolve_address.h"
+#include "src/core/lib/iomgr/tcp_server.h"
 #include "test/core/util/port.h"
 #include "test/core/util/test_config.h"
 
@@ -163,14 +162,22 @@ static void on_connect(void* /*arg*/, grpc_endpoint* tcp,
 static void test_no_op(void) {
   grpc_core::ExecCtx exec_ctx;
   grpc_tcp_server* s;
-  GPR_ASSERT(GRPC_ERROR_NONE == grpc_tcp_server_create(nullptr, nullptr, &s));
+  GPR_ASSERT(GRPC_ERROR_NONE ==
+             grpc_tcp_server_create(nullptr, nullptr,
+                                    grpc_slice_allocator_factory_create(
+                                        grpc_resource_quota_create(nullptr)),
+                                    &s));
   grpc_tcp_server_unref(s);
 }
 
 static void test_no_op_with_start(void) {
   grpc_core::ExecCtx exec_ctx;
   grpc_tcp_server* s;
-  GPR_ASSERT(GRPC_ERROR_NONE == grpc_tcp_server_create(nullptr, nullptr, &s));
+  GPR_ASSERT(GRPC_ERROR_NONE ==
+             grpc_tcp_server_create(nullptr, nullptr,
+                                    grpc_slice_allocator_factory_create(
+                                        grpc_resource_quota_create(nullptr)),
+                                    &s));
   LOG_TEST("test_no_op_with_start");
   std::vector<grpc_pollset*> empty_pollset;
   grpc_tcp_server_start(s, &empty_pollset, on_connect, nullptr);
@@ -183,7 +190,11 @@ static void test_no_op_with_port(void) {
   struct sockaddr_in* addr =
       reinterpret_cast<struct sockaddr_in*>(resolved_addr.addr);
   grpc_tcp_server* s;
-  GPR_ASSERT(GRPC_ERROR_NONE == grpc_tcp_server_create(nullptr, nullptr, &s));
+  GPR_ASSERT(GRPC_ERROR_NONE ==
+             grpc_tcp_server_create(nullptr, nullptr,
+                                    grpc_slice_allocator_factory_create(
+                                        grpc_resource_quota_create(nullptr)),
+                                    &s));
   LOG_TEST("test_no_op_with_port");
 
   memset(&resolved_addr, 0, sizeof(resolved_addr));
@@ -203,7 +214,11 @@ static void test_no_op_with_port_and_start(void) {
   struct sockaddr_in* addr =
       reinterpret_cast<struct sockaddr_in*>(resolved_addr.addr);
   grpc_tcp_server* s;
-  GPR_ASSERT(GRPC_ERROR_NONE == grpc_tcp_server_create(nullptr, nullptr, &s));
+  GPR_ASSERT(GRPC_ERROR_NONE ==
+             grpc_tcp_server_create(nullptr, nullptr,
+                                    grpc_slice_allocator_factory_create(
+                                        grpc_resource_quota_create(nullptr)),
+                                    &s));
   LOG_TEST("test_no_op_with_port_and_start");
   int port = -1;
 
@@ -300,7 +315,11 @@ static void test_connect(size_t num_connects,
   grpc_tcp_server* s;
   const unsigned num_ports = 2;
   GPR_ASSERT(GRPC_ERROR_NONE ==
-             grpc_tcp_server_create(nullptr, channel_args, &s));
+             grpc_tcp_server_create(
+                 nullptr, channel_args,
+                 grpc_slice_allocator_factory_create(
+                     grpc_resource_quota_from_channel_args(channel_args, true)),
+                 &s));
   unsigned port_num;
   server_weak_ref weak_ref;
   server_weak_ref_init(&weak_ref);
diff --git a/test/core/iomgr/tcp_server_uv_test.cc b/test/core/iomgr/tcp_server_uv_test.cc
deleted file mode 100644 (file)
index 0bc0beb..0000000
+++ /dev/null
@@ -1,319 +0,0 @@
-/*
- *
- * Copyright 2017 gRPC authors.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- *
- */
-
-#include "src/core/lib/iomgr/port.h"
-
-// This test won't work except with libuv
-#ifdef GRPC_UV
-
-#include <uv.h>
-
-#include "src/core/lib/iomgr/tcp_server.h"
-
-#include <string.h>
-
-#include <grpc/grpc.h>
-#include <grpc/support/alloc.h>
-#include <grpc/support/log.h>
-#include <grpc/support/sync.h>
-#include <grpc/support/time.h>
-
-#include "src/core/lib/address_utils/sockaddr_utils.h"
-#include "src/core/lib/iomgr/iomgr.h"
-#include "src/core/lib/iomgr/resolve_address.h"
-#include "test/core/util/port.h"
-#include "test/core/util/test_config.h"
-
-#define LOG_TEST(x) gpr_log(GPR_INFO, "%s", #x)
-
-static gpr_mu* g_mu;
-static grpc_pollset* g_pollset;
-static int g_nconnects = 0;
-
-typedef struct on_connect_result {
-  /* Owns a ref to server. */
-  grpc_tcp_server* server;
-  unsigned port_index;
-  unsigned fd_index;
-} on_connect_result;
-
-typedef struct server_weak_ref {
-  grpc_tcp_server* server;
-
-  /* arg is this server_weak_ref. */
-  grpc_closure server_shutdown;
-} server_weak_ref;
-
-static on_connect_result g_result = {NULL, 0, 0};
-
-static void on_connect_result_init(on_connect_result* result) {
-  result->server = NULL;
-  result->port_index = 0;
-  result->fd_index = 0;
-}
-
-static void on_connect_result_set(on_connect_result* result,
-                                  const grpc_tcp_server_acceptor* acceptor) {
-  result->server = grpc_tcp_server_ref(acceptor->from_server);
-  result->port_index = acceptor->port_index;
-  result->fd_index = acceptor->fd_index;
-}
-
-static void server_weak_ref_shutdown(void* arg, grpc_error_handle error) {
-  server_weak_ref* weak_ref = static_cast<server_weak_ref*>(arg);
-  weak_ref->server = NULL;
-}
-
-static void server_weak_ref_init(server_weak_ref* weak_ref) {
-  weak_ref->server = NULL;
-  GRPC_CLOSURE_INIT(&weak_ref->server_shutdown, server_weak_ref_shutdown,
-                    weak_ref, grpc_schedule_on_exec_ctx);
-}
-
-/* Make weak_ref->server_shutdown a shutdown_starting cb on server.
-   grpc_tcp_server promises that the server object will live until
-   weak_ref->server_shutdown has returned. A strong ref on grpc_tcp_server
-   should be held until server_weak_ref_set() returns to avoid a race where the
-   server is deleted before the shutdown_starting cb is added. */
-static void server_weak_ref_set(server_weak_ref* weak_ref,
-                                grpc_tcp_server* server) {
-  grpc_tcp_server_shutdown_starting_add(server, &weak_ref->server_shutdown);
-  weak_ref->server = server;
-}
-
-static void on_connect(void* arg, grpc_endpoint* tcp, grpc_pollset* pollset,
-                       grpc_tcp_server_acceptor* acceptor) {
-  grpc_endpoint_shutdown(tcp,
-                         GRPC_ERROR_CREATE_FROM_STATIC_STRING("Connected"));
-  grpc_endpoint_destroy(tcp);
-
-  on_connect_result temp_result;
-  on_connect_result_set(&temp_result, acceptor);
-  gpr_free(acceptor);
-
-  gpr_mu_lock(g_mu);
-  g_result = temp_result;
-  g_nconnects++;
-  GPR_ASSERT(
-      GRPC_LOG_IF_ERROR("pollset_kick", grpc_pollset_kick(g_pollset, NULL)));
-  gpr_mu_unlock(g_mu);
-}
-
-static void test_no_op(void) {
-  grpc_core::ExecCtx exec_ctx;
-  grpc_tcp_server* s;
-  GPR_ASSERT(GRPC_ERROR_NONE == grpc_tcp_server_create(NULL, NULL, &s));
-  grpc_tcp_server_unref(s);
-  grpc_core::ExecCtx::Get()->Flush();
-}
-
-static void test_no_op_with_start(void) {
-  grpc_core::ExecCtx exec_ctx;
-  grpc_tcp_server* s;
-  GPR_ASSERT(GRPC_ERROR_NONE == grpc_tcp_server_create(NULL, NULL, &s));
-  LOG_TEST("test_no_op_with_start");
-  grpc_tcp_server_start(s, NULL, 0, on_connect, NULL);
-  grpc_tcp_server_unref(s);
-  grpc_core::ExecCtx::Get()->Flush();
-}
-
-static void test_no_op_with_port(void) {
-  grpc_core::ExecCtx exec_ctx;
-  grpc_resolved_address resolved_addr;
-  struct sockaddr_in* addr = (struct sockaddr_in*)resolved_addr.addr;
-  grpc_tcp_server* s;
-  GPR_ASSERT(GRPC_ERROR_NONE == grpc_tcp_server_create(NULL, NULL, &s));
-  LOG_TEST("test_no_op_with_port");
-
-  memset(&resolved_addr, 0, sizeof(resolved_addr));
-  resolved_addr.len = sizeof(struct sockaddr_in);
-  addr->sin_family = AF_INET;
-  int port;
-  GPR_ASSERT(grpc_tcp_server_add_port(s, &resolved_addr, &port) ==
-                 GRPC_ERROR_NONE &&
-             port > 0);
-
-  grpc_tcp_server_unref(s);
-  grpc_core::ExecCtx::Get()->Flush();
-}
-
-static void test_no_op_with_port_and_start(void) {
-  grpc_core::ExecCtx exec_ctx;
-  grpc_resolved_address resolved_addr;
-  struct sockaddr_in* addr = (struct sockaddr_in*)resolved_addr.addr;
-  grpc_tcp_server* s;
-  GPR_ASSERT(GRPC_ERROR_NONE == grpc_tcp_server_create(NULL, NULL, &s));
-  LOG_TEST("test_no_op_with_port_and_start");
-  int port;
-
-  memset(&resolved_addr, 0, sizeof(resolved_addr));
-  resolved_addr.len = sizeof(struct sockaddr_in);
-  addr->sin_family = AF_INET;
-  GPR_ASSERT(grpc_tcp_server_add_port(s, &resolved_addr, &port) ==
-                 GRPC_ERROR_NONE &&
-             port > 0);
-
-  grpc_tcp_server_start(s, NULL, 0, on_connect, NULL);
-
-  grpc_tcp_server_unref(s);
-  grpc_core::ExecCtx::Get()->Flush();
-}
-
-static void connect_cb(uv_connect_t* req, int status) {
-  GPR_ASSERT(status == 0);
-  gpr_free(req);
-}
-
-static void close_cb(uv_handle_t* handle) { gpr_free(handle); }
-
-static void tcp_connect(const struct sockaddr* remote, socklen_t remote_len,
-                        on_connect_result* result) {
-  gpr_timespec deadline = grpc_timeout_seconds_to_deadline(10);
-  uv_tcp_t* client_handle =
-      static_cast<uv_tcp_t*>(gpr_malloc(sizeof(uv_tcp_t)));
-  uv_connect_t* req =
-      static_cast<uv_connect_t*>(gpr_malloc(sizeof(uv_connect_t)));
-  int nconnects_before;
-
-  gpr_mu_lock(g_mu);
-  nconnects_before = g_nconnects;
-  on_connect_result_init(&g_result);
-  GPR_ASSERT(uv_tcp_init(uv_default_loop(), client_handle) == 0);
-  gpr_log(GPR_DEBUG, "start connect");
-  GPR_ASSERT(uv_tcp_connect(req, client_handle, remote, connect_cb) == 0);
-  gpr_log(GPR_DEBUG, "wait");
-  while (g_nconnects == nconnects_before &&
-         gpr_time_cmp(deadline, gpr_now(deadline.clock_type)) > 0) {
-    grpc_pollset_worker* worker = NULL;
-    GPR_ASSERT(GRPC_LOG_IF_ERROR(
-        "pollset_work",
-        grpc_pollset_work(g_pollset, &worker,
-                          grpc_timespec_to_millis_round_up(deadline))));
-    gpr_mu_unlock(g_mu);
-
-    gpr_mu_lock(g_mu);
-  }
-  gpr_log(GPR_DEBUG, "wait done");
-  GPR_ASSERT(g_nconnects == nconnects_before + 1);
-  uv_close((uv_handle_t*)client_handle, close_cb);
-  *result = g_result;
-
-  gpr_mu_unlock(g_mu);
-}
-
-/* Tests a tcp server with multiple ports. */
-static void test_connect(unsigned n) {
-  grpc_core::ExecCtx exec_ctx;
-  grpc_resolved_address resolved_addr;
-  grpc_resolved_address resolved_addr1;
-  struct sockaddr_storage* addr = (struct sockaddr_storage*)resolved_addr.addr;
-  struct sockaddr_storage* addr1 =
-      (struct sockaddr_storage*)resolved_addr1.addr;
-  int svr_port;
-  int svr1_port;
-  grpc_tcp_server* s;
-  GPR_ASSERT(GRPC_ERROR_NONE == grpc_tcp_server_create(NULL, NULL, &s));
-  unsigned i;
-  server_weak_ref weak_ref;
-  server_weak_ref_init(&weak_ref);
-  LOG_TEST("test_connect");
-  gpr_log(GPR_INFO, "clients=%d", n);
-  memset(&resolved_addr, 0, sizeof(resolved_addr));
-  memset(&resolved_addr1, 0, sizeof(resolved_addr1));
-  resolved_addr.len = sizeof(struct sockaddr_storage);
-  resolved_addr1.len = sizeof(struct sockaddr_storage);
-  addr->ss_family = addr1->ss_family = AF_INET;
-  GPR_ASSERT(GRPC_ERROR_NONE ==
-             grpc_tcp_server_add_port(s, &resolved_addr, &svr_port));
-  GPR_ASSERT(svr_port > 0);
-  GPR_ASSERT((uv_ip6_addr("::", svr_port, (struct sockaddr_in6*)addr)) == 0);
-  /* Cannot use wildcard (port==0), because add_port() will try to reuse the
-     same port as a previous add_port(). */
-  svr1_port = grpc_pick_unused_port_or_die();
-  grpc_sockaddr_set_port(&resolved_addr1, svr1_port);
-  GPR_ASSERT(grpc_tcp_server_add_port(s, &resolved_addr1, &svr_port) ==
-                 GRPC_ERROR_NONE &&
-             svr_port == svr1_port);
-
-  grpc_tcp_server_start(s, &g_pollset, 1, on_connect, NULL);
-
-  GPR_ASSERT(uv_ip6_addr("::", svr_port, (struct sockaddr_in6*)addr1) == 0);
-
-  for (i = 0; i < n; i++) {
-    on_connect_result result;
-    on_connect_result_init(&result);
-    tcp_connect((struct sockaddr*)addr, (socklen_t)resolved_addr.len, &result);
-    GPR_ASSERT(result.port_index == 0);
-    GPR_ASSERT(result.server == s);
-    if (weak_ref.server == NULL) {
-      server_weak_ref_set(&weak_ref, result.server);
-    }
-    grpc_tcp_server_unref(result.server);
-
-    on_connect_result_init(&result);
-    tcp_connect((struct sockaddr*)addr1, (socklen_t)resolved_addr1.len,
-                &result);
-    GPR_ASSERT(result.port_index == 1);
-    GPR_ASSERT(result.server == s);
-    grpc_tcp_server_unref(result.server);
-  }
-
-  /* Weak ref to server valid until final unref. */
-  GPR_ASSERT(weak_ref.server != NULL);
-
-  grpc_tcp_server_unref(s);
-  grpc_core::ExecCtx::Get()->Flush();
-  /* Weak ref lost. */
-  GPR_ASSERT(weak_ref.server == NULL);
-}
-
-static void destroy_pollset(void* p, grpc_error_handle error) {
-  grpc_pollset_destroy(static_cast<grpc_pollset*>(p));
-}
-
-int main(int argc, char** argv) {
-  grpc_closure destroyed;
-  grpc::testing::TestEnvironment env(argc, argv);
-  grpc_init();
-  {
-    grpc_core::ExecCtx exec_ctx;
-    g_pollset = static_cast<grpc_pollset*>(gpr_malloc(grpc_pollset_size()));
-    grpc_pollset_init(g_pollset, &g_mu);
-
-    test_no_op();
-    test_no_op_with_start();
-    test_no_op_with_port();
-    test_no_op_with_port_and_start();
-    test_connect(1);
-    test_connect(10);
-
-    GRPC_CLOSURE_INIT(&destroyed, destroy_pollset, g_pollset,
-                      grpc_schedule_on_exec_ctx);
-    grpc_pollset_shutdown(g_pollset, &destroyed);
-
-    gpr_free(g_pollset);
-  }
-  grpc_shutdown();
-  return 0;
-}
-
-#else /* GRPC_UV */
-
-int main(int /*argc*/, char** /*argv*/) { return 1; }
-
-#endif /* GRPC_UV */
index 1b8c697..1324b27 100644 (file)
@@ -56,13 +56,13 @@ class SimpleFunctorForAdd : public grpc_completion_queue_functor {
   ~SimpleFunctorForAdd() {}
   static void Run(struct grpc_completion_queue_functor* cb, int /*ok*/) {
     auto* callback = static_cast<SimpleFunctorForAdd*>(cb);
-    callback->count_.FetchAdd(1, grpc_core::MemoryOrder::RELAXED);
+    callback->count_.fetch_add(1, std::memory_order_relaxed);
   }
 
-  int count() { return count_.Load(grpc_core::MemoryOrder::RELAXED); }
+  int count() { return count_.load(std::memory_order_relaxed); }
 
  private:
-  grpc_core::Atomic<int> count_{0};
+  std::atomic<int> count_{0};
 };
 
 static void test_add(void) {
index 2923a35..6851353 100644 (file)
@@ -21,6 +21,7 @@
 #include <math.h>
 
 #include <grpc/support/log.h>
+
 #include "test/core/util/test_config.h"
 
 #define EXPECT_EQ(a, b) GPR_ASSERT((a) == (b))
index b574e0a..60f4bdd 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "src/core/lib/iomgr/port.h"
-
 #include "src/core/lib/iomgr/timer_heap.h"
 
 #include <stdlib.h>
@@ -27,6 +25,7 @@
 #include <grpc/support/log.h>
 
 #include "src/core/lib/gpr/useful.h"
+#include "src/core/lib/iomgr/port.h"
 #include "test/core/util/test_config.h"
 
 static gpr_atm random_deadline(void) { return rand(); }
index f4a1b20..3113907 100644 (file)
 // This test only works with the generic timer implementation
 #ifndef GRPC_CUSTOM_SOCKET
 
-#include "src/core/lib/iomgr/iomgr_internal.h"
-#include "src/core/lib/iomgr/timer.h"
-
 #include <string.h>
 
 #include <grpc/grpc.h>
 #include <grpc/support/log.h>
+
 #include "src/core/lib/debug/trace.h"
+#include "src/core/lib/iomgr/iomgr_internal.h"
+#include "src/core/lib/iomgr/timer.h"
 #include "test/core/util/test_config.h"
 #include "test/core/util/tracer_util.h"
 
index a036b0c..6eb1232 100644 (file)
@@ -21,8 +21,6 @@
 // This test won't work except with posix sockets enabled
 #ifdef GRPC_POSIX_SOCKET_UDP_SERVER
 
-#include "src/core/lib/iomgr/udp_server.h"
-
 #include <netinet/in.h>
 #include <string.h>
 #include <sys/socket.h>
@@ -43,6 +41,7 @@
 #include "src/core/lib/iomgr/iomgr.h"
 #include "src/core/lib/iomgr/socket_factory_posix.h"
 #include "src/core/lib/iomgr/socket_utils_posix.h"
+#include "src/core/lib/iomgr/udp_server.h"
 #include "test/core/util/test_config.h"
 
 #define LOG_TEST(x) gpr_log(GPR_INFO, "%s", #x)
index bbc9e3f..7a5ce5b 100644 (file)
  *
  */
 
+#include "src/core/lib/iomgr/work_serializer.h"
+
 #include <memory>
 
 #include <gtest/gtest.h>
 
+#include "absl/memory/memory.h"
+
 #include <grpc/grpc.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 
-#include "absl/memory/memory.h"
-
 #include "src/core/lib/gpr/useful.h"
 #include "src/core/lib/gprpp/thd.h"
-#include "src/core/lib/iomgr/work_serializer.h"
 #include "test/core/util/test_config.h"
 
 namespace {
index c724f1b..6821648 100644 (file)
  *
  */
 
+#include "src/core/lib/json/json.h"
+
 #include <string.h>
 
+#include <gmock/gmock.h>
+#include <gtest/gtest.h>
+
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/string_util.h>
 
-#include <gmock/gmock.h>
-#include <gtest/gtest.h>
-
 #include "src/core/lib/gpr/string.h"
 #include "src/core/lib/gpr/useful.h"
-#include "src/core/lib/json/json.h"
-
 #include "test/core/util/test_config.h"
 
 namespace grpc_core {
diff --git a/test/core/promise/BUILD b/test/core/promise/BUILD
new file mode 100644 (file)
index 0000000..3382027
--- /dev/null
@@ -0,0 +1,250 @@
+# Copyright 2021 gRPC authors.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+load("//bazel:grpc_build_system.bzl", "grpc_cc_test", "grpc_package")
+
+licenses(["notice"])
+
+grpc_package(name = "test/core/promise")
+
+grpc_cc_test(
+    name = "poll_test",
+    srcs = ["poll_test.cc"],
+    external_deps = ["gtest"],
+    language = "c++",
+    uses_polling = False,
+    deps = [
+        "//:poll",
+        "//test/core/util:grpc_suppressions",
+    ],
+)
+
+grpc_cc_test(
+    name = "context_test",
+    srcs = ["context_test.cc"],
+    external_deps = ["gtest"],
+    language = "c++",
+    uses_polling = False,
+    deps = [
+        "//:context",
+        "//test/core/util:grpc_suppressions",
+    ],
+)
+
+grpc_cc_test(
+    name = "promise_test",
+    srcs = ["promise_test.cc"],
+    external_deps = ["gtest"],
+    language = "c++",
+    uses_polling = False,
+    deps = [
+        "//:promise",
+        "//test/core/util:grpc_suppressions",
+    ],
+)
+
+grpc_cc_test(
+    # Why promise_map_test and not map_test?
+    # third_party/benchmark defines a map_test in its cmakefile, and we depend
+    # on that from our cmakefile, and cmake wants to have a flat namespace to
+    # deal with xcode/visual studio limitations... sooo... promise_map_test it
+    # is.
+    name = "promise_map_test",
+    srcs = ["map_test.cc"],
+    external_deps = ["gtest"],
+    language = "c++",
+    uses_polling = False,
+    deps = [
+        "//:map",
+        "//:promise",
+        "//test/core/util:grpc_suppressions",
+    ],
+)
+
+grpc_cc_test(
+    name = "race_test",
+    srcs = ["race_test.cc"],
+    external_deps = ["gtest"],
+    language = "c++",
+    uses_polling = False,
+    deps = [
+        "//:race",
+        "//test/core/util:grpc_suppressions",
+    ],
+)
+
+grpc_cc_test(
+    name = "promise_factory_test",
+    srcs = ["promise_factory_test.cc"],
+    external_deps = [
+        "gtest",
+        "absl/functional:bind_front",
+    ],
+    language = "c++",
+    uses_polling = False,
+    deps = [
+        "//:capture",
+        "//:promise",
+        "//:promise_factory",
+        "//test/core/util:grpc_suppressions",
+    ],
+)
+
+grpc_cc_test(
+    name = "if_test",
+    srcs = ["if_test.cc"],
+    external_deps = ["gtest"],
+    language = "c++",
+    uses_polling = False,
+    deps = [
+        "//:if",
+        "//test/core/util:grpc_suppressions",
+    ],
+)
+
+grpc_cc_test(
+    name = "loop_test",
+    srcs = ["loop_test.cc"],
+    external_deps = ["gtest"],
+    language = "c++",
+    uses_polling = False,
+    deps = [
+        "//:loop",
+        "//test/core/util:grpc_suppressions",
+    ],
+)
+
+grpc_cc_test(
+    name = "join_test",
+    srcs = ["join_test.cc"],
+    external_deps = ["gtest"],
+    language = "c++",
+    uses_polling = False,
+    deps = [
+        "//:join",
+        "//test/core/util:grpc_suppressions",
+    ],
+)
+
+grpc_cc_test(
+    name = "try_join_test",
+    srcs = ["try_join_test.cc"],
+    external_deps = ["gtest"],
+    language = "c++",
+    uses_polling = False,
+    deps = [
+        "//:try_join",
+        "//test/core/util:grpc_suppressions",
+    ],
+)
+
+grpc_cc_test(
+    name = "seq_test",
+    srcs = ["seq_test.cc"],
+    external_deps = ["gtest"],
+    language = "c++",
+    uses_polling = False,
+    deps = [
+        "//:seq",
+        "//test/core/util:grpc_suppressions",
+    ],
+)
+
+grpc_cc_test(
+    name = "try_seq_test",
+    srcs = ["try_seq_test.cc"],
+    external_deps = ["gtest"],
+    language = "c++",
+    uses_polling = False,
+    deps = [
+        "//:try_seq",
+        "//test/core/util:grpc_suppressions",
+    ],
+)
+
+grpc_cc_test(
+    name = "activity_test",
+    srcs = ["activity_test.cc"],
+    external_deps = ["gtest"],
+    language = "c++",
+    uses_polling = False,
+    deps = [
+        "//:activity",
+        "//:join",
+        "//:promise",
+        "//:seq",
+        "//:wait_set",
+        "//test/core/util:grpc_suppressions",
+    ],
+)
+
+grpc_cc_test(
+    name = "latch_test",
+    srcs = ["latch_test.cc"],
+    external_deps = ["gtest"],
+    language = "c++",
+    uses_polling = False,
+    deps = [
+        "//:join",
+        "//:latch",
+        "//:seq",
+        "//test/core/util:grpc_suppressions",
+    ],
+)
+
+grpc_cc_test(
+    name = "observable_test",
+    srcs = ["observable_test.cc"],
+    external_deps = ["gtest"],
+    language = "c++",
+    uses_polling = False,
+    deps = [
+        "//:observable",
+        "//:promise",
+        "//:seq",
+        "//test/core/util:grpc_suppressions",
+    ],
+)
+
+grpc_cc_test(
+    name = "for_each_test",
+    srcs = ["for_each_test.cc"],
+    external_deps = ["gtest"],
+    language = "c++",
+    uses_polling = False,
+    deps = [
+        "//:for_each",
+        "//:join",
+        "//:map",
+        "//:observable",
+        "//:pipe",
+        "//:seq",
+        "//test/core/util:grpc_suppressions",
+    ],
+)
+
+grpc_cc_test(
+    name = "pipe_test",
+    srcs = ["pipe_test.cc"],
+    external_deps = ["gtest"],
+    language = "c++",
+    uses_polling = False,
+    deps = [
+        "//:join",
+        "//:pipe",
+        "//:promise",
+        "//:seq",
+        "//test/core/util:grpc_suppressions",
+    ],
+)
diff --git a/test/core/promise/activity_test.cc b/test/core/promise/activity_test.cc
new file mode 100644 (file)
index 0000000..3375b2f
--- /dev/null
@@ -0,0 +1,260 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#include "src/core/lib/promise/activity.h"
+
+#include <gmock/gmock.h>
+#include <gtest/gtest.h>
+
+#include "src/core/lib/promise/join.h"
+#include "src/core/lib/promise/promise.h"
+#include "src/core/lib/promise/seq.h"
+#include "src/core/lib/promise/wait_set.h"
+
+using testing::_;
+using testing::Mock;
+using testing::MockFunction;
+using testing::SaveArg;
+using testing::StrictMock;
+
+namespace grpc_core {
+
+class MockCallbackScheduler {
+ public:
+  MOCK_METHOD(void, Schedule, (std::function<void()>));
+};
+
+// A simple Barrier type: stalls progress until it is 'cleared'.
+class Barrier {
+ public:
+  struct Result {};
+
+  Promise<Result> Wait() {
+    return [this]() -> Poll<Result> {
+      absl::MutexLock lock(&mu_);
+      if (cleared_) {
+        return Result{};
+      } else {
+        return wait_set_.AddPending(Activity::current()->MakeOwningWaker());
+      }
+    };
+  }
+
+  void Clear() {
+    mu_.Lock();
+    cleared_ = true;
+    auto wakeup = wait_set_.TakeWakeupSet();
+    mu_.Unlock();
+    wakeup.Wakeup();
+  }
+
+ private:
+  absl::Mutex mu_;
+  WaitSet wait_set_ ABSL_GUARDED_BY(mu_);
+  bool cleared_ ABSL_GUARDED_BY(mu_) = false;
+};
+
+// A simple Barrier type: stalls progress until it is 'cleared'.
+// This variant supports only a single waiter.
+class SingleBarrier {
+ public:
+  struct Result {};
+
+  Promise<Result> Wait() {
+    return [this]() -> Poll<Result> {
+      absl::MutexLock lock(&mu_);
+      if (cleared_) {
+        return Result{};
+      } else {
+        waker_ = Activity::current()->MakeOwningWaker();
+        return Pending();
+      }
+    };
+  }
+
+  void Clear() {
+    mu_.Lock();
+    cleared_ = true;
+    auto waker = std::move(waker_);
+    mu_.Unlock();
+    waker.Wakeup();
+  }
+
+ private:
+  absl::Mutex mu_;
+  Waker waker_ ABSL_GUARDED_BY(mu_);
+  bool cleared_ ABSL_GUARDED_BY(mu_) = false;
+};
+
+TEST(ActivityTest, ImmediatelyCompleteWithSuccess) {
+  StrictMock<MockFunction<void(absl::Status)>> on_done;
+  EXPECT_CALL(on_done, Call(absl::OkStatus()));
+  MakeActivity(
+      [] { return [] { return absl::OkStatus(); }; }, NoCallbackScheduler(),
+      [&on_done](absl::Status status) { on_done.Call(std::move(status)); });
+}
+
+TEST(ActivityTest, ImmediatelyCompleteWithFailure) {
+  StrictMock<MockFunction<void(absl::Status)>> on_done;
+  EXPECT_CALL(on_done, Call(absl::CancelledError()));
+  MakeActivity(
+      [] { return [] { return absl::CancelledError(); }; },
+      NoCallbackScheduler(),
+      [&on_done](absl::Status status) { on_done.Call(std::move(status)); });
+}
+
+TEST(ActivityTest, DropImmediately) {
+  StrictMock<MockFunction<void(absl::Status)>> on_done;
+  EXPECT_CALL(on_done, Call(absl::CancelledError()));
+  MakeActivity(
+      [] { return []() -> Poll<absl::Status> { return Pending(); }; },
+      NoCallbackScheduler(),
+      [&on_done](absl::Status status) { on_done.Call(std::move(status)); });
+}
+
+TEST(ActivityTest, Cancel) {
+  StrictMock<MockFunction<void(absl::Status)>> on_done;
+  auto activity = MakeActivity(
+      [] { return []() -> Poll<absl::Status> { return Pending(); }; },
+      NoCallbackScheduler(),
+      [&on_done](absl::Status status) { on_done.Call(std::move(status)); });
+  EXPECT_CALL(on_done, Call(absl::CancelledError()));
+  activity->Cancel();
+  Mock::VerifyAndClearExpectations(&on_done);
+  activity.reset();
+}
+
+template <typename B>
+class BarrierTest : public testing::Test {
+ public:
+  using Type = B;
+};
+
+using BarrierTestTypes = testing::Types<Barrier, SingleBarrier>;
+TYPED_TEST_SUITE(BarrierTest, BarrierTestTypes);
+
+TYPED_TEST(BarrierTest, Barrier) {
+  typename TestFixture::Type b;
+  StrictMock<MockFunction<void(absl::Status)>> on_done;
+  auto activity = MakeActivity(
+      [&b] {
+        return Seq(b.Wait(), [](typename TestFixture::Type::Result) {
+          return absl::OkStatus();
+        });
+      },
+      NoCallbackScheduler(),
+      [&on_done](absl::Status status) { on_done.Call(std::move(status)); });
+  // Clearing the barrier should let the activity proceed to return a result.
+  EXPECT_CALL(on_done, Call(absl::OkStatus()));
+  b.Clear();
+}
+
+TYPED_TEST(BarrierTest, BarrierPing) {
+  typename TestFixture::Type b1;
+  typename TestFixture::Type b2;
+  StrictMock<MockFunction<void(absl::Status)>> on_done1;
+  StrictMock<MockFunction<void(absl::Status)>> on_done2;
+  MockCallbackScheduler scheduler;
+  auto activity1 = MakeActivity(
+      [&b1, &b2] {
+        return Seq(b1.Wait(), [&b2](typename TestFixture::Type::Result) {
+          // Clear the barrier whilst executing an activity
+          b2.Clear();
+          return absl::OkStatus();
+        });
+      },
+      [&scheduler](std::function<void()> f) { scheduler.Schedule(f); },
+      [&on_done1](absl::Status status) { on_done1.Call(std::move(status)); });
+  auto activity2 = MakeActivity(
+      [&b2] {
+        return Seq(b2.Wait(), [](typename TestFixture::Type::Result) {
+          return absl::OkStatus();
+        });
+      },
+      [&scheduler](std::function<void()> f) { scheduler.Schedule(f); },
+      [&on_done2](absl::Status status) { on_done2.Call(std::move(status)); });
+  EXPECT_CALL(on_done1, Call(absl::OkStatus()));
+  // Since barrier triggers inside activity1 promise, activity2 wakeup will be
+  // scheduled from a callback.
+  std::function<void()> cb;
+  EXPECT_CALL(scheduler, Schedule(_)).WillOnce(SaveArg<0>(&cb));
+  b1.Clear();
+  Mock::VerifyAndClearExpectations(&on_done1);
+  EXPECT_CALL(on_done2, Call(absl::OkStatus()));
+  cb();
+}
+
+TYPED_TEST(BarrierTest, WakeSelf) {
+  typename TestFixture::Type b;
+  StrictMock<MockFunction<void(absl::Status)>> on_done;
+  EXPECT_CALL(on_done, Call(absl::OkStatus()));
+  MakeActivity(
+      [&b] {
+        return Seq(Join(b.Wait(),
+                        [&b] {
+                          b.Clear();
+                          return 1;
+                        }),
+                   [](std::tuple<typename TestFixture::Type::Result, int>) {
+                     return absl::OkStatus();
+                   });
+      },
+      NoCallbackScheduler(),
+      [&on_done](absl::Status status) { on_done.Call(std::move(status)); });
+}
+
+TYPED_TEST(BarrierTest, WakeAfterDestruction) {
+  typename TestFixture::Type b;
+  {
+    StrictMock<MockFunction<void(absl::Status)>> on_done;
+    EXPECT_CALL(on_done, Call(absl::CancelledError()));
+    MakeActivity(
+        [&b] {
+          return Seq(b.Wait(), [](typename TestFixture::Type::Result) {
+            return absl::OkStatus();
+          });
+        },
+        NoCallbackScheduler(),
+        [&on_done](absl::Status status) { on_done.Call(std::move(status)); });
+  }
+  b.Clear();
+}
+
+struct TestContext {
+  bool* done;
+};
+template <>
+struct ContextType<TestContext> {};
+
+TEST(ActivityTest, WithContext) {
+  bool done = false;
+  StrictMock<MockFunction<void(absl::Status)>> on_done;
+  EXPECT_CALL(on_done, Call(absl::OkStatus()));
+  MakeActivity(
+      [] {
+        *GetContext<TestContext>()->done = true;
+        return Immediate(absl::OkStatus());
+      },
+      NoCallbackScheduler(),
+      [&on_done](absl::Status status) { on_done.Call(std::move(status)); },
+      TestContext{&done});
+  EXPECT_TRUE(done);
+}
+
+}  // namespace grpc_core
+
+int main(int argc, char** argv) {
+  ::testing::InitGoogleTest(&argc, argv);
+  return RUN_ALL_TESTS();
+}
diff --git a/test/core/promise/context_test.cc b/test/core/promise/context_test.cc
new file mode 100644 (file)
index 0000000..b4f4afe
--- /dev/null
@@ -0,0 +1,42 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#include "src/core/lib/promise/context.h"
+
+#include <gtest/gtest.h>
+
+namespace grpc_core {
+
+struct TestContext {
+  bool done = false;
+};
+
+template <>
+struct ContextType<TestContext> {};
+
+TEST(Context, WithContext) {
+  EXPECT_EQ(GetContext<TestContext>(), nullptr);
+  TestContext test;
+  EXPECT_EQ(GetContext<TestContext>(), nullptr);
+  EXPECT_EQ(test.done, false);
+  WithContext([]() { GetContext<TestContext>()->done = true; }, &test)();
+  EXPECT_EQ(test.done, true);
+}
+
+}  // namespace grpc_core
+
+int main(int argc, char** argv) {
+  ::testing::InitGoogleTest(&argc, argv);
+  return RUN_ALL_TESTS();
+}
diff --git a/test/core/promise/for_each_test.cc b/test/core/promise/for_each_test.cc
new file mode 100644 (file)
index 0000000..1d112e5
--- /dev/null
@@ -0,0 +1,71 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#include "src/core/lib/promise/for_each.h"
+
+#include <gmock/gmock.h>
+#include <gtest/gtest.h>
+
+#include "src/core/lib/promise/join.h"
+#include "src/core/lib/promise/map.h"
+#include "src/core/lib/promise/observable.h"
+#include "src/core/lib/promise/pipe.h"
+#include "src/core/lib/promise/seq.h"
+
+using testing::Mock;
+using testing::MockFunction;
+using testing::StrictMock;
+
+namespace grpc_core {
+
+TEST(ForEachTest, SendThriceWithPipe) {
+  Pipe<int> pipe;
+  int num_received = 0;
+  StrictMock<MockFunction<void(absl::Status)>> on_done;
+  EXPECT_CALL(on_done, Call(absl::OkStatus()));
+  MakeActivity(
+      [&pipe, &num_received] {
+        return Map(
+            Join(
+                // Push 3 things into a pipe -- 1, 2, then 3 -- then close.
+                Seq(
+                    pipe.sender.Push(1),
+                    [&pipe] { return pipe.sender.Push(2); },
+                    [&pipe] { return pipe.sender.Push(3); },
+                    [&pipe] {
+                      auto drop = std::move(pipe.sender);
+                      return absl::OkStatus();
+                    }),
+                // Use a ForEach loop to read them out and verify all values are
+                // seen.
+                ForEach(std::move(pipe.receiver),
+                        [&num_received](int i) {
+                          num_received++;
+                          EXPECT_EQ(num_received, i);
+                          return absl::OkStatus();
+                        })),
+            JustElem<1>());
+      },
+      NoCallbackScheduler(),
+      [&on_done](absl::Status status) { on_done.Call(std::move(status)); });
+  Mock::VerifyAndClearExpectations(&on_done);
+  EXPECT_EQ(num_received, 3);
+}
+
+}  // namespace grpc_core
+
+int main(int argc, char** argv) {
+  ::testing::InitGoogleTest(&argc, argv);
+  return RUN_ALL_TESTS();
+}
diff --git a/test/core/promise/if_test.cc b/test/core/promise/if_test.cc
new file mode 100644 (file)
index 0000000..f0ec437
--- /dev/null
@@ -0,0 +1,58 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#include "src/core/lib/promise/if.h"
+
+#include <gtest/gtest.h>
+
+namespace grpc_core {
+
+TEST(IfTest, ChooseTrue) {
+  EXPECT_EQ(If([]() { return true; }, []() { return 1; }, []() { return 2; })(),
+            Poll<int>(1));
+}
+
+TEST(IfTest, ChooseFalse) {
+  EXPECT_EQ(
+      If([]() { return false; }, []() { return 1; }, []() { return 2; })(),
+      Poll<int>(2));
+}
+
+TEST(IfTest, ChooseSuccesfulTrue) {
+  EXPECT_EQ(If([]() { return absl::StatusOr<bool>(true); },
+               []() { return absl::StatusOr<int>(1); },
+               []() { return absl::StatusOr<int>(2); })(),
+            Poll<absl::StatusOr<int>>(absl::StatusOr<int>(1)));
+}
+
+TEST(IfTest, ChooseSuccesfulFalse) {
+  EXPECT_EQ(If([]() { return absl::StatusOr<bool>(false); },
+               []() { return absl::StatusOr<int>(1); },
+               []() { return absl::StatusOr<int>(2); })(),
+            Poll<absl::StatusOr<int>>(absl::StatusOr<int>(2)));
+}
+
+TEST(IfTest, ChooseFailure) {
+  EXPECT_EQ(If([]() { return absl::StatusOr<bool>(); },
+               []() { return absl::StatusOr<int>(1); },
+               []() { return absl::StatusOr<int>(2); })(),
+            Poll<absl::StatusOr<int>>(absl::StatusOr<int>()));
+}
+
+}  // namespace grpc_core
+
+int main(int argc, char** argv) {
+  ::testing::InitGoogleTest(&argc, argv);
+  return RUN_ALL_TESTS();
+}
diff --git a/test/core/promise/join_test.cc b/test/core/promise/join_test.cc
new file mode 100644 (file)
index 0000000..df3ab83
--- /dev/null
@@ -0,0 +1,41 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#include "src/core/lib/promise/join.h"
+
+#include <gtest/gtest.h>
+
+namespace grpc_core {
+
+TEST(JoinTest, Join1) {
+  EXPECT_EQ(Join([] { return 3; })(),
+            (Poll<std::tuple<int>>(std::make_tuple(3))));
+}
+
+TEST(JoinTest, Join2) {
+  EXPECT_EQ(Join([] { return 3; }, [] { return 4; })(),
+            (Poll<std::tuple<int, int>>(std::make_tuple(3, 4))));
+}
+
+TEST(JoinTest, Join3) {
+  EXPECT_EQ(Join([] { return 3; }, [] { return 4; }, [] { return 5; })(),
+            (Poll<std::tuple<int, int, int>>(std::make_tuple(3, 4, 5))));
+}
+
+}  // namespace grpc_core
+
+int main(int argc, char** argv) {
+  ::testing::InitGoogleTest(&argc, argv);
+  return RUN_ALL_TESTS();
+}
diff --git a/test/core/promise/latch_test.cc b/test/core/promise/latch_test.cc
new file mode 100644 (file)
index 0000000..c1032df
--- /dev/null
@@ -0,0 +1,53 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#include "src/core/lib/promise/latch.h"
+
+#include <gmock/gmock.h>
+#include <gtest/gtest.h>
+
+#include "src/core/lib/promise/join.h"
+#include "src/core/lib/promise/seq.h"
+
+using testing::MockFunction;
+using testing::StrictMock;
+
+namespace grpc_core {
+
+TEST(LatchTest, Works) {
+  Latch<int> latch;
+  StrictMock<MockFunction<void(absl::Status)>> on_done;
+  EXPECT_CALL(on_done, Call(absl::OkStatus()));
+  MakeActivity(
+      [&latch] {
+        return Seq(Join(latch.Wait(),
+                        [&latch]() {
+                          latch.Set(42);
+                          return true;
+                        }),
+                   [](std::tuple<int*, bool> result) {
+                     EXPECT_EQ(*std::get<0>(result), 42);
+                     return absl::OkStatus();
+                   });
+      },
+      NoCallbackScheduler(),
+      [&on_done](absl::Status status) { on_done.Call(std::move(status)); });
+}
+
+}  // namespace grpc_core
+
+int main(int argc, char** argv) {
+  ::testing::InitGoogleTest(&argc, argv);
+  return RUN_ALL_TESTS();
+}
diff --git a/test/core/promise/loop_test.cc b/test/core/promise/loop_test.cc
new file mode 100644 (file)
index 0000000..4d7b846
--- /dev/null
@@ -0,0 +1,48 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#include "src/core/lib/promise/loop.h"
+
+#include <gtest/gtest.h>
+
+namespace grpc_core {
+
+TEST(LoopTest, CountToFive) {
+  int i = 0;
+  Loop([&i]() -> LoopCtl<int> {
+    i++;
+    if (i < 5) return Continue();
+    return i;
+  })();
+  EXPECT_EQ(i, 5);
+}
+
+TEST(LoopTest, FactoryCountToFive) {
+  int i = 0;
+  Loop([&i]() {
+    return [&i]() -> LoopCtl<int> {
+      i++;
+      if (i < 5) return Continue();
+      return i;
+    };
+  })();
+  EXPECT_EQ(i, 5);
+}
+
+}  // namespace grpc_core
+
+int main(int argc, char** argv) {
+  ::testing::InitGoogleTest(&argc, argv);
+  return RUN_ALL_TESTS();
+}
diff --git a/test/core/promise/map_test.cc b/test/core/promise/map_test.cc
new file mode 100644 (file)
index 0000000..d60d836
--- /dev/null
@@ -0,0 +1,39 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#include "src/core/lib/promise/map.h"
+
+#include <gtest/gtest.h>
+
+#include "src/core/lib/promise/promise.h"
+
+namespace grpc_core {
+
+TEST(MapTest, Works) {
+  Promise<int> x = Map([]() { return 42; }, [](int i) { return i / 2; });
+  EXPECT_EQ(x(), Poll<int>(21));
+}
+
+TEST(MapTest, JustElem) {
+  std::tuple<int, double> t(1, 3.2);
+  EXPECT_EQ(JustElem<1>()(t), 3.2);
+  EXPECT_EQ(JustElem<0>()(t), 1);
+}
+
+}  // namespace grpc_core
+
+int main(int argc, char** argv) {
+  ::testing::InitGoogleTest(&argc, argv);
+  return RUN_ALL_TESTS();
+}
diff --git a/test/core/promise/observable_test.cc b/test/core/promise/observable_test.cc
new file mode 100644 (file)
index 0000000..9044366
--- /dev/null
@@ -0,0 +1,130 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#include "src/core/lib/promise/observable.h"
+
+#include <gmock/gmock.h>
+#include <gtest/gtest.h>
+
+#include "src/core/lib/promise/promise.h"
+#include "src/core/lib/promise/seq.h"
+
+using testing::MockFunction;
+using testing::StrictMock;
+
+namespace grpc_core {
+
+// A simple Barrier type: stalls progress until it is 'cleared'.
+class Barrier {
+ public:
+  struct Result {};
+
+  Promise<Result> Wait() {
+    return [this]() -> Poll<Result> {
+      absl::MutexLock lock(&mu_);
+      if (cleared_) {
+        return Result{};
+      } else {
+        return wait_set_.AddPending(Activity::current()->MakeOwningWaker());
+      }
+    };
+  }
+
+  void Clear() {
+    mu_.Lock();
+    cleared_ = true;
+    auto wakeup = wait_set_.TakeWakeupSet();
+    mu_.Unlock();
+    wakeup.Wakeup();
+  }
+
+ private:
+  absl::Mutex mu_;
+  WaitSet wait_set_ ABSL_GUARDED_BY(mu_);
+  bool cleared_ ABSL_GUARDED_BY(mu_) = false;
+};
+
+TEST(ObservableTest, CanPushAndGet) {
+  StrictMock<MockFunction<void(absl::Status)>> on_done;
+  Observable<int> observable;
+  auto observer = observable.MakeObserver();
+  auto activity = MakeActivity(
+      [&observer]() {
+        return Seq(observer.Get(), [](absl::optional<int> i) {
+          return i == 42 ? absl::OkStatus() : absl::UnknownError("expected 42");
+        });
+      },
+      NoCallbackScheduler(),
+      [&on_done](absl::Status status) { on_done.Call(std::move(status)); });
+  EXPECT_CALL(on_done, Call(absl::OkStatus()));
+  observable.Push(42);
+}
+
+TEST(ObservableTest, CanNext) {
+  StrictMock<MockFunction<void(absl::Status)>> on_done;
+  Observable<int> observable;
+  auto observer = observable.MakeObserver();
+  auto activity = MakeActivity(
+      [&observer]() {
+        return Seq(
+            observer.Get(),
+            [&observer](absl::optional<int> i) {
+              EXPECT_EQ(i, 42);
+              return observer.Next();
+            },
+            [](absl::optional<int> i) {
+              return i == 1 ? absl::OkStatus()
+                            : absl::UnknownError("expected 1");
+            });
+      },
+      NoCallbackScheduler(),
+      [&on_done](absl::Status status) { on_done.Call(std::move(status)); });
+  observable.Push(42);
+  EXPECT_CALL(on_done, Call(absl::OkStatus()));
+  observable.Push(1);
+}
+
+TEST(ObservableTest, CanWatch) {
+  StrictMock<MockFunction<void(absl::Status)>> on_done;
+  Observable<int> observable;
+  Barrier barrier;
+  auto activity = MakeActivity(
+      [&observable, &barrier]() {
+        return observable.Watch(
+            [&barrier](int x,
+                       WatchCommitter* committer) -> Promise<absl::Status> {
+              if (x == 3) {
+                committer->Commit();
+                return Seq(barrier.Wait(), Immediate(absl::OkStatus()));
+              } else {
+                return Never<absl::Status>();
+              }
+            });
+      },
+      NoCallbackScheduler(),
+      [&on_done](absl::Status status) { on_done.Call(std::move(status)); });
+  observable.Push(1);
+  observable.Push(2);
+  observable.Push(3);
+  observable.Push(4);
+  EXPECT_CALL(on_done, Call(absl::OkStatus()));
+  barrier.Clear();
+}
+
+}  // namespace grpc_core
+
+int main(int argc, char** argv) {
+  ::testing::InitGoogleTest(&argc, argv);
+  return RUN_ALL_TESTS();
+}
diff --git a/test/core/promise/pipe_test.cc b/test/core/promise/pipe_test.cc
new file mode 100644 (file)
index 0000000..c6c699e
--- /dev/null
@@ -0,0 +1,179 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#include "src/core/lib/promise/pipe.h"
+
+#include <gmock/gmock.h>
+#include <gtest/gtest.h>
+
+#include "absl/memory/memory.h"
+
+#include "src/core/lib/promise/join.h"
+#include "src/core/lib/promise/promise.h"
+#include "src/core/lib/promise/seq.h"
+
+using testing::MockFunction;
+using testing::StrictMock;
+
+namespace grpc_core {
+
+TEST(PipeTest, CanSendAndReceive) {
+  Pipe<int> pipe;
+  StrictMock<MockFunction<void(absl::Status)>> on_done;
+  EXPECT_CALL(on_done, Call(absl::OkStatus()));
+  MakeActivity(
+      [&pipe] {
+        return Seq(
+            // Concurrently: send 42 into the pipe, and receive from the pipe.
+            Join(pipe.sender.Push(42), pipe.receiver.Next()),
+            // Once complete, verify successful sending and the received value
+            // is 42.
+            [](std::tuple<bool, absl::optional<int>> result) {
+              EXPECT_EQ(result, std::make_tuple(true, absl::optional<int>(42)));
+              return absl::OkStatus();
+            });
+      },
+      NoCallbackScheduler(),
+      [&on_done](absl::Status status) { on_done.Call(std::move(status)); });
+}
+
+TEST(PipeTest, CanReceiveAndSend) {
+  Pipe<int> pipe;
+  StrictMock<MockFunction<void(absl::Status)>> on_done;
+  EXPECT_CALL(on_done, Call(absl::OkStatus()));
+  MakeActivity(
+      [&pipe] {
+        return Seq(
+            // Concurrently: receive from the pipe, and send 42 into the pipe.
+            Join(pipe.receiver.Next(), pipe.sender.Push(42)),
+            // Once complete, verify the received value is 42 and successful
+            // sending.
+            [](std::tuple<absl::optional<int>, bool> result) {
+              EXPECT_EQ(result, std::make_tuple(absl::optional<int>(42), true));
+              return absl::OkStatus();
+            });
+      },
+      NoCallbackScheduler(),
+      [&on_done](absl::Status status) { on_done.Call(std::move(status)); });
+}
+
+TEST(PipeTest, CanSeeClosedOnSend) {
+  Pipe<int> pipe;
+  StrictMock<MockFunction<void(absl::Status)>> on_done;
+  auto sender = std::move(pipe.sender);
+  auto receiver =
+      absl::make_unique<PipeReceiver<int>>(std::move(pipe.receiver));
+  EXPECT_CALL(on_done, Call(absl::OkStatus()));
+  // Push 42 onto the pipe - this will the pipe's one-deep send buffer.
+  EXPECT_TRUE(NowOrNever(sender.Push(42)).has_value());
+  MakeActivity(
+      [&sender, &receiver] {
+        return Seq(
+            // Concurrently:
+            // - push 43 into the sender, which will stall because the buffer is
+            //   full
+            // - and close the receiver, which will fail the pending send.
+            Join(sender.Push(43),
+                 [&receiver] {
+                   receiver.reset();
+                   return absl::OkStatus();
+                 }),
+            // Verify both that the send failed and that we executed the close.
+            [](std::tuple<bool, absl::Status> result) {
+              EXPECT_EQ(result, std::make_tuple(false, absl::OkStatus()));
+              return absl::OkStatus();
+            });
+      },
+      NoCallbackScheduler(),
+      [&on_done](absl::Status status) { on_done.Call(std::move(status)); });
+}
+
+TEST(PipeTest, CanSeeClosedOnReceive) {
+  Pipe<int> pipe;
+  StrictMock<MockFunction<void(absl::Status)>> on_done;
+  auto sender = absl::make_unique<PipeSender<int>>(std::move(pipe.sender));
+  auto receiver = std::move(pipe.receiver);
+  EXPECT_CALL(on_done, Call(absl::OkStatus()));
+  MakeActivity(
+      [&sender, &receiver] {
+        return Seq(
+            // Concurrently:
+            // - wait for a received value (will stall forever since we push
+            //   nothing into the queue)
+            // - close the sender, which will signal the receiver to return an
+            //   end-of-stream.
+            Join(receiver.Next(),
+                 [&sender] {
+                   sender.reset();
+                   return absl::OkStatus();
+                 }),
+            // Verify we received end-of-stream and closed the sender.
+            [](std::tuple<absl::optional<int>, absl::Status> result) {
+              EXPECT_EQ(result, std::make_tuple(absl::optional<int>(),
+                                                absl::OkStatus()));
+              return absl::OkStatus();
+            });
+      },
+      NoCallbackScheduler(),
+      [&on_done](absl::Status status) { on_done.Call(std::move(status)); });
+}
+
+TEST(PipeTest, CanFilter) {
+  Pipe<int> pipe;
+  StrictMock<MockFunction<void(absl::Status)>> on_done;
+  EXPECT_CALL(on_done, Call(absl::OkStatus()));
+  MakeActivity(
+      [&pipe] {
+        // Setup some filters here, carefully getting ordering correct by doing
+        // so outside of the Join() since C++ does not define execution order
+        // between arguments.
+        // TODO(ctiller): A future change to Pipe will specify an ordering
+        // between filters added to sender and receiver, at which point these
+        // should move back.
+        auto doubler = pipe.receiver.Filter(
+            [](int p) { return absl::StatusOr<int>(p * 2); });
+        auto adder = pipe.sender.Filter(
+            [](int p) { return absl::StatusOr<int>(p + 1); });
+        return Seq(
+            // Concurrently:
+            // - push 42 into the pipe
+            // - wait for a value to be received, and filter it by doubling it
+            // - wait for a value to be received, and filter it by adding one to
+            //   it
+            // - wait for a value to be received and close the pipe.
+            Join(pipe.sender.Push(42), std::move(doubler), std::move(adder),
+                 Seq(pipe.receiver.Next(),
+                     [&pipe](absl::optional<int> i) {
+                       auto x = std::move(pipe.receiver);
+                       return i;
+                     })),
+            // Verify all of the above happened correctly.
+            [](std::tuple<bool, absl::Status, absl::Status, absl::optional<int>>
+                   result) {
+              EXPECT_EQ(result, std::make_tuple(true, absl::OkStatus(),
+                                                absl::OkStatus(),
+                                                absl::optional<int>(85)));
+              return absl::OkStatus();
+            });
+      },
+      NoCallbackScheduler(),
+      [&on_done](absl::Status status) { on_done.Call(std::move(status)); });
+}
+
+}  // namespace grpc_core
+
+int main(int argc, char** argv) {
+  ::testing::InitGoogleTest(&argc, argv);
+  return RUN_ALL_TESTS();
+}
diff --git a/test/core/promise/poll_test.cc b/test/core/promise/poll_test.cc
new file mode 100644 (file)
index 0000000..3a44f50
--- /dev/null
@@ -0,0 +1,45 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#include "src/core/lib/promise/poll.h"
+
+#include <gtest/gtest.h>
+
+namespace grpc_core {
+
+TEST(PollTest, IsItPoll) {
+  EXPECT_EQ(PollTraits<Poll<int>>::is_poll(), true);
+  EXPECT_EQ(PollTraits<Poll<bool>>::is_poll(), true);
+  EXPECT_EQ(PollTraits<Poll<std::unique_ptr<int>>>::is_poll(), true);
+  EXPECT_EQ(PollTraits<int>::is_poll(), false);
+  EXPECT_EQ(PollTraits<bool>::is_poll(), false);
+  EXPECT_EQ(PollTraits<std::unique_ptr<int>>::is_poll(), false);
+}
+
+TEST(PollTest, Pending) {
+  Poll<int> i = Pending();
+  EXPECT_TRUE(absl::holds_alternative<Pending>(i));
+}
+
+TEST(PollTest, Ready) {
+  Poll<int> i = 1;
+  EXPECT_TRUE(absl::holds_alternative<int>(i));
+}
+
+}  // namespace grpc_core
+
+int main(int argc, char** argv) {
+  ::testing::InitGoogleTest(&argc, argv);
+  return RUN_ALL_TESTS();
+}
diff --git a/test/core/promise/promise_factory_test.cc b/test/core/promise/promise_factory_test.cc
new file mode 100644 (file)
index 0000000..b354dbe
--- /dev/null
@@ -0,0 +1,72 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#include "src/core/lib/promise/detail/promise_factory.h"
+
+#include <gtest/gtest.h>
+
+#include "absl/functional/bind_front.h"
+
+#include "src/core/lib/gprpp/capture.h"
+#include "src/core/lib/promise/promise.h"
+
+namespace grpc_core {
+namespace promise_detail {
+namespace testing {
+
+template <typename Arg, typename F>
+PromiseFactory<Arg, F> MakeFactory(F f) {
+  return PromiseFactory<Arg, F>(std::move(f));
+}
+
+TEST(AdaptorTest, FactoryFromPromise) {
+  EXPECT_EQ(
+      MakeFactory<void>([]() { return Poll<int>(Poll<int>(42)); }).Once()(),
+      Poll<int>(42));
+  EXPECT_EQ(
+      MakeFactory<void>([]() { return Poll<int>(Poll<int>(42)); }).Repeated()(),
+      Poll<int>(42));
+  EXPECT_EQ(MakeFactory<void>(Promise<int>([]() {
+              return Poll<int>(Poll<int>(42));
+            })).Once()(),
+            Poll<int>(42));
+  EXPECT_EQ(MakeFactory<void>(Promise<int>([]() {
+              return Poll<int>(Poll<int>(42));
+            })).Repeated()(),
+            Poll<int>(42));
+}
+
+TEST(AdaptorTest, FactoryFromBindFrontPromise) {
+  EXPECT_EQ(MakeFactory<void>(
+                absl::bind_front([](int i) { return Poll<int>(i); }, 42))
+                .Once()(),
+            Poll<int>(42));
+}
+
+TEST(AdaptorTest, FactoryFromCapturePromise) {
+  EXPECT_EQ(MakeFactory<void>(
+                grpc_core::Capture([](int* i) { return Poll<int>(*i); }, 42))
+                .Once()(),
+            Poll<int>(42));
+}
+
+}  // namespace testing
+}  // namespace promise_detail
+
+}  // namespace grpc_core
+
+int main(int argc, char** argv) {
+  ::testing::InitGoogleTest(&argc, argv);
+  return RUN_ALL_TESTS();
+}
diff --git a/test/core/promise/promise_test.cc b/test/core/promise/promise_test.cc
new file mode 100644 (file)
index 0000000..aa1a814
--- /dev/null
@@ -0,0 +1,43 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#include "src/core/lib/promise/promise.h"
+
+#include <gtest/gtest.h>
+
+namespace grpc_core {
+
+TEST(PromiseTest, Works) {
+  Promise<int> x = []() { return 42; };
+  EXPECT_EQ(x(), Poll<int>(42));
+}
+
+TEST(PromiseTest, Immediate) { EXPECT_EQ(Immediate(42)(), Poll<int>(42)); }
+
+TEST(PromiseTest, WithResult) {
+  EXPECT_EQ(WithResult<int>(Immediate(42))(), Poll<int>(42));
+  // Fails to compile: WithResult<int>(Immediate(std::string("hello")));
+  // Fails to compile: WithResult<int>(Immediate(42.9));
+}
+
+TEST(PromiseTest, NowOrNever) {
+  EXPECT_EQ(NowOrNever(Immediate(42)), absl::optional<int>(42));
+}
+
+}  // namespace grpc_core
+
+int main(int argc, char** argv) {
+  ::testing::InitGoogleTest(&argc, argv);
+  return RUN_ALL_TESTS();
+}
similarity index 67%
rename from test/core/transport/binder/binder_smoke_test.cc
rename to test/core/promise/race_test.cc
index 565d676..7928b9f 100644 (file)
@@ -1,4 +1,3 @@
-//
 // Copyright 2021 gRPC authors.
 //
 // Licensed under the Apache License, Version 2.0 (the "License");
 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 // See the License for the specific language governing permissions and
 // limitations under the License.
-//
 
-#include <grpc/grpc.h>
-#include <grpc/support/log.h>
-#include <gtest/gtest.h>
+#include "src/core/lib/promise/race.h"
 
-#include "test/core/util/test_config.h"
+#include <gtest/gtest.h>
 
 namespace grpc_core {
-namespace testing {
-namespace {
-TEST(SmokeTest, Empty) { gpr_log(GPR_INFO, __func__); }
-}  // namespace
-}  // namespace testing
+
+Poll<int> instant() { return 1; }
+Poll<int> never() { return Pending(); }
+
+TEST(RaceTest, Race1) { EXPECT_EQ(Race(instant)(), Poll<int>(1)); }
+TEST(RaceTest, Race2A) { EXPECT_EQ(Race(instant, never)(), Poll<int>(1)); }
+TEST(RaceTest, Race2B) { EXPECT_EQ(Race(never, instant)(), Poll<int>(1)); }
+
 }  // namespace grpc_core
 
 int main(int argc, char** argv) {
   ::testing::InitGoogleTest(&argc, argv);
-  grpc::testing::TestEnvironment env(argc, argv);
-  grpc_init();
-  int ret = RUN_ALL_TESTS();
-  grpc_shutdown();
-  return ret;
+  return RUN_ALL_TESTS();
 }
diff --git a/test/core/promise/seq_test.cc b/test/core/promise/seq_test.cc
new file mode 100644 (file)
index 0000000..15b2fd3
--- /dev/null
@@ -0,0 +1,94 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#include "src/core/lib/promise/seq.h"
+
+#include <gtest/gtest.h>
+
+namespace grpc_core {
+
+TEST(PromiseTest, Immediate) {
+  EXPECT_EQ(Seq([] { return 3; })(), 3);
+}
+
+TEST(PromiseTest, OneThen) {
+  auto initial = [] { return 3; };
+  auto then = [](int i) { return [i]() { return i + 4; }; };
+  EXPECT_EQ(Seq(initial, then)(), Poll<int>(7));
+}
+
+TEST(PromiseTest, TwoTypedThens) {
+  struct A {};
+  struct B {};
+  struct C {};
+  auto initial = [] { return A{}; };
+  auto next1 = [](A) { return []() { return B{}; }; };
+  auto next2 = [](B) { return []() { return C{}; }; };
+  EXPECT_FALSE(absl::holds_alternative<Pending>(Seq(initial, next1, next2)()));
+}
+
+/* This does not compile, but is useful for testing error messages generated
+TEST(PromiseTest, MisTypedThen) {
+  struct A {};
+  struct B {};
+  auto initial = [] { return A{}; };
+  auto next = [](B) { return []() { return B{}; }; };
+  Seq(initial, next)().take();
+}
+*/
+
+TEST(PromiseTest, TwoThens) {
+  auto initial = [] { return std::string("a"); };
+  auto next1 = [](std::string i) { return [i]() { return i + "b"; }; };
+  auto next2 = [](std::string i) { return [i]() { return i + "c"; }; };
+  EXPECT_EQ(Seq(initial, next1, next2)(), Poll<std::string>("abc"));
+}
+
+TEST(PromiseTest, ThreeThens) {
+  EXPECT_EQ(Seq([] { return std::string("a"); },
+                [](std::string i) { return [i]() { return i + "b"; }; },
+                [](std::string i) { return [i]() { return i + "c"; }; },
+                [](std::string i) { return [i]() { return i + "d"; }; })(),
+            Poll<std::string>("abcd"));
+}
+
+struct Big {
+  int x[256];
+  void YesItIsUnused() const {}
+};
+
+TEST(PromiseTest, SaneSizes) {
+  auto x = Big();
+  auto p1 = Seq(
+      [x] {
+        x.YesItIsUnused();
+        return 1;
+      },
+      [](int) {
+        auto y = Big();
+        return [y]() {
+          y.YesItIsUnused();
+          return 2;
+        };
+      });
+  EXPECT_GE(sizeof(p1), sizeof(Big));
+  EXPECT_LT(sizeof(p1), 2 * sizeof(Big));
+}
+
+}  // namespace grpc_core
+
+int main(int argc, char** argv) {
+  ::testing::InitGoogleTest(&argc, argv);
+  return RUN_ALL_TESTS();
+}
diff --git a/test/core/promise/try_join_test.cc b/test/core/promise/try_join_test.cc
new file mode 100644 (file)
index 0000000..2f880ad
--- /dev/null
@@ -0,0 +1,80 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#include "src/core/lib/promise/try_join.h"
+
+#include <gtest/gtest.h>
+
+namespace grpc_core {
+
+template <typename T>
+using P = std::function<Poll<absl::StatusOr<T>>()>;
+
+template <typename T>
+P<T> instant_ok(T x) {
+  return [x] { return absl::StatusOr<T>(x); };
+}
+
+template <typename T>
+P<T> instant_fail() {
+  return [] { return absl::StatusOr<T>(); };
+}
+
+template <typename... T>
+Poll<absl::StatusOr<std::tuple<T...>>> ok(T... x) {
+  return absl::StatusOr<std::tuple<T...>>(absl::in_place, x...);
+}
+
+template <typename... T>
+Poll<absl::StatusOr<std::tuple<T...>>> fail() {
+  return absl::StatusOr<std::tuple<T...>>();
+}
+
+template <typename T>
+P<T> pending() {
+  return []() -> Poll<absl::StatusOr<T>> { return Pending(); };
+}
+
+TEST(TryJoinTest, Join1) { EXPECT_EQ(TryJoin(instant_ok(1))(), ok(1)); }
+
+TEST(TryJoinTest, Join1Fail) {
+  EXPECT_EQ(TryJoin(instant_fail<int>())(), fail<int>());
+}
+
+TEST(TryJoinTest, Join2Success) {
+  EXPECT_EQ(TryJoin(instant_ok(1), instant_ok(2))(), ok(1, 2));
+}
+
+TEST(TryJoinTest, Join2Fail1) {
+  EXPECT_EQ(TryJoin(instant_ok(1), instant_fail<int>())(), (fail<int, int>()));
+}
+
+TEST(TryJoinTest, Join2Fail2) {
+  EXPECT_EQ(TryJoin(instant_fail<int>(), instant_ok(2))(), (fail<int, int>()));
+}
+
+TEST(TryJoinTest, Join2Fail1P) {
+  EXPECT_EQ(TryJoin(pending<int>(), instant_fail<int>())(), (fail<int, int>()));
+}
+
+TEST(TryJoinTest, Join2Fail2P) {
+  EXPECT_EQ(TryJoin(instant_fail<int>(), pending<int>())(), (fail<int, int>()));
+}
+
+}  // namespace grpc_core
+
+int main(int argc, char** argv) {
+  ::testing::InitGoogleTest(&argc, argv);
+  return RUN_ALL_TESTS();
+}
diff --git a/test/core/promise/try_seq_test.cc b/test/core/promise/try_seq_test.cc
new file mode 100644 (file)
index 0000000..97034b5
--- /dev/null
@@ -0,0 +1,78 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#include "src/core/lib/promise/try_seq.h"
+
+#include <gtest/gtest.h>
+
+namespace grpc_core {
+
+TEST(PromiseTest, SucceedAndThen) {
+  EXPECT_EQ(TrySeq([] { return absl::StatusOr<int>(1); },
+                   [](int i) {
+                     return [i]() { return absl::StatusOr<int>(i + 1); };
+                   })(),
+            Poll<absl::StatusOr<int>>(absl::StatusOr<int>(2)));
+}
+
+TEST(PromiseTest, SucceedDirectlyAndThenDirectly) {
+  EXPECT_EQ(
+      TrySeq([] { return 1; }, [](int i) { return [i]() { return i + 1; }; })(),
+      Poll<absl::StatusOr<int>>(absl::StatusOr<int>(2)));
+}
+
+TEST(PromiseTest, SucceedAndThenChangeType) {
+  EXPECT_EQ(
+      TrySeq([] { return absl::StatusOr<int>(42); },
+             [](int i) {
+               return [i]() {
+                 return absl::StatusOr<std::string>(std::to_string(i));
+               };
+             })(),
+      Poll<absl::StatusOr<std::string>>(absl::StatusOr<std::string>("42")));
+}
+
+TEST(PromiseTest, FailAndThen) {
+  EXPECT_EQ(TrySeq([]() { return absl::StatusOr<int>(absl::CancelledError()); },
+                   [](int) {
+                     return []() -> Poll<absl::StatusOr<double>> { abort(); };
+                   })(),
+            Poll<absl::StatusOr<double>>(
+                absl::StatusOr<double>(absl::CancelledError())));
+}
+
+TEST(PromiseTest, RawSucceedAndThen) {
+  EXPECT_EQ(TrySeq([] { return absl::OkStatus(); },
+                   [] { return []() { return absl::OkStatus(); }; })(),
+            Poll<absl::Status>(absl::OkStatus()));
+}
+
+TEST(PromiseTest, RawFailAndThen) {
+  EXPECT_EQ(TrySeq([] { return absl::CancelledError(); },
+                   []() { return []() -> Poll<absl::Status> { abort(); }; })(),
+            Poll<absl::Status>(absl::CancelledError()));
+}
+
+TEST(PromiseTest, RawSucceedAndThenValue) {
+  EXPECT_EQ(TrySeq([] { return absl::OkStatus(); },
+                   [] { return []() { return absl::StatusOr<int>(42); }; })(),
+            Poll<absl::StatusOr<int>>(absl::StatusOr<int>(42)));
+}
+
+}  // namespace grpc_core
+
+int main(int argc, char** argv) {
+  ::testing::InitGoogleTest(&argc, argv);
+  return RUN_ALL_TESTS();
+}
index 42e683f..1f2aa60 100644 (file)
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/string_util.h>
-#include "test/core/util/fuzzer_util.h"
 
 #include "src/core/lib/gpr/env.h"
 #include "src/core/lib/security/credentials/alts/alts_credentials.h"
 #include "src/core/lib/security/credentials/alts/check_gcp_environment.h"
 #include "src/core/lib/security/credentials/alts/grpc_alts_credentials_options.h"
+#include "test/core/util/fuzzer_util.h"
 
 using grpc_core::testing::grpc_fuzzer_get_next_byte;
 using grpc_core::testing::grpc_fuzzer_get_next_string;
index ec1b1d3..becd4e6 100644 (file)
@@ -16,6 +16,8 @@
  *
  */
 
+#include "src/core/lib/security/security_connector/alts/alts_security_connector.h"
+
 #include <stdio.h>
 #include <stdlib.h>
 #include <string.h>
@@ -24,7 +26,6 @@
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 
-#include "src/core/lib/security/security_connector/alts/alts_security_connector.h"
 #include "src/core/lib/transport/transport.h"
 #include "src/core/tsi/alts/handshaker/alts_tsi_handshaker.h"
 #include "src/core/tsi/transport_security.h"
index e7e0cb2..142cc60 100644 (file)
 
 #include <string.h>
 
+#include <grpc/support/log.h>
+
 #include "src/core/lib/gpr/string.h"
 #include "src/core/lib/gprpp/ref_counted_ptr.h"
 #include "src/core/lib/security/context/security_context.h"
 #include "test/core/util/test_config.h"
 
-#include <grpc/support/log.h>
-
 static void test_empty_context(void) {
   grpc_core::RefCountedPtr<grpc_auth_context> ctx =
       grpc_core::MakeRefCounted<grpc_auth_context>(nullptr);
index bc5780f..cb97292 100644 (file)
@@ -17,6 +17,7 @@
 #include "src/core/lib/security/credentials/external/aws_request_signer.h"
 
 #include <gmock/gmock.h>
+
 #include <grpc/grpc_security.h>
 
 #include "test/core/util/test_config.h"
index 20b6d54..1934173 100644 (file)
@@ -27,6 +27,7 @@
 
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
+
 #include "src/core/lib/gpr/tmpfile.h"
 
 namespace grpc_core {
index 2ea640b..a82e07a 100644 (file)
 #include <stdio.h>
 #include <string.h>
 
-#include "src/core/lib/iomgr/load_file.h"
-#include "src/core/lib/security/credentials/jwt/jwt_credentials.h"
-
 #include <grpc/slice.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 
+#include "src/core/lib/iomgr/load_file.h"
+#include "src/core/lib/security/credentials/jwt/jwt_credentials.h"
 #include "test/core/util/cmdline.h"
 
 void create_jwt(const char* json_key_file_path, const char* service_url,
index 0533247..cb5bc3a 100644 (file)
 
 #include "src/core/lib/security/credentials/credentials.h"
 
-#include <openssl/rsa.h>
 #include <stdlib.h>
 #include <string.h>
 
 #include <string>
 
+#include <openssl/rsa.h>
+
 #include "absl/strings/match.h"
 #include "absl/strings/str_cat.h"
 #include "absl/strings/str_format.h"
@@ -108,6 +109,43 @@ static const char test_refresh_token_str[] =
     "  \"refresh_token\": \"1/Blahblasj424jladJDSGNf-u4Sua3HDA2ngjd42\","
     "  \"type\": \"authorized_user\"}";
 
+/* Test external account credentials. */
+static const char test_external_account_credentials_str[] =
+    "{\"type\":\"external_account\",\"audience\":\"audience\",\"subject_"
+    "token_type\":\"subject_token_type\",\"service_account_impersonation_"
+    "url\":\"\",\"token_url\":\"https://"
+    "sts.googleapis.com:5555/"
+    "token\",\"token_info_url\":\"\",\"credential_source\":{\"file\":"
+    "\"credentials_file_path\"},"
+    "\"quota_project_id\":\"quota_"
+    "project_id\",\"client_id\":\"client_id\",\"client_secret\":\"client_"
+    "secret\"}";
+
+static const char test_external_account_credentials_multi_pattern_sts_str[] =
+    "{\"type\":\"external_account\",\"audience\":\"audience\",\"subject_"
+    "token_type\":\"subject_token_type\",\"service_account_impersonation_"
+    "url\":\"https://sts.test.googleapis.com:5555/"
+    "service_account_impersonation_url\",\"token_url\":\"https://"
+    "test.sts.googleapis.com:5555/token\",\"token_info_url\":\"https://"
+    "test-sts.googleapis.com:5555/"
+    "token_info\",\"credential_source\":{\"file\":\"credentials_file_path\"},"
+    "\"quota_project_id\":\"quota_"
+    "project_id\",\"client_id\":\"client_id\",\"client_secret\":\"client_"
+    "secret\"}";
+
+static const char test_external_account_credentials_multi_pattern_iam_str[] =
+    "{\"type\":\"external_account\",\"audience\":\"audience\",\"subject_"
+    "token_type\":\"subject_token_type\",\"service_account_impersonation_"
+    "url\":\"https://iamcredentials.test.googleapis.com:5555/"
+    "service_account_impersonation_url\",\"token_url\":\"https://"
+    "test.iamcredentials.googleapis.com:5555/"
+    "token\",\"token_info_url\":\"https://"
+    "test-iamcredentials.googleapis.com:5555/"
+    "token_info\",\"credential_source\":{\"file\":\"credentials_file_path\"},"
+    "\"quota_project_id\":\"quota_"
+    "project_id\",\"client_id\":\"client_id\",\"client_secret\":\"client_"
+    "secret\"}";
+
 static const char valid_oauth2_json_response[] =
     "{\"access_token\":\"ya29.AHES6ZRN3-HlhAPya30GnW_bHSb_\","
     " \"expires_in\":3599, "
@@ -134,7 +172,9 @@ static const char test_signed_jwt_token_type2[] =
 static const char test_signed_jwt_path_prefix[] = "test_sign_jwt";
 
 static const char test_service_url[] = "https://foo.com/foo.v1";
+static const char test_service_url_no_service_name[] = "https://foo.com/";
 static const char other_test_service_url[] = "https://bar.com/bar.v1";
+static const char other_test_service_url_no_service_name[] = "https://bar.com/";
 
 static const char test_sts_endpoint_url[] =
     "https://foo.com:5555/v1/token-exchange";
@@ -1289,9 +1329,13 @@ static void validate_jwt_encode_and_sign_params(
 }
 
 static char* encode_and_sign_jwt_success(const grpc_auth_json_key* json_key,
-                                         const char* /*audience*/,
+                                         const char* audience,
                                          gpr_timespec token_lifetime,
                                          const char* scope) {
+  if (strcmp(audience, test_service_url_no_service_name) != 0 &&
+      strcmp(audience, other_test_service_url_no_service_name) != 0) {
+    return nullptr;
+  }
   validate_jwt_encode_and_sign_params(json_key, scope, token_lifetime);
   return gpr_strdup(test_signed_jwt);
 }
@@ -1362,6 +1406,16 @@ static void test_jwt_creds_lifetime(void) {
   gpr_free(json_key_string);
 }
 
+static void test_remove_service_from_jwt_uri(void) {
+  const char wrong_uri[] = "hello world";
+  GPR_ASSERT(!grpc_core::RemoveServiceNameFromJwtUri(wrong_uri).ok());
+  const char valid_uri[] = "https://foo.com/get/";
+  const char expected_uri[] = "https://foo.com/";
+  auto output = grpc_core::RemoveServiceNameFromJwtUri(valid_uri);
+  GPR_ASSERT(output.ok());
+  GPR_ASSERT(strcmp(output->c_str(), expected_uri) == 0);
+}
+
 static void test_jwt_creds_success(void) {
   const char expected_creds_debug_string_prefix[] =
       "JWTAccessCredentials{ExpirationTime:";
@@ -1502,6 +1556,71 @@ static void test_google_default_creds_refresh_token(void) {
   gpr_setenv(GRPC_GOOGLE_CREDENTIALS_ENV_VAR, ""); /* Reset. */
 }
 
+static void test_google_default_creds_external_account_credentials(void) {
+  grpc_core::ExecCtx exec_ctx;
+  grpc_composite_channel_credentials* creds;
+  grpc_flush_cached_google_default_credentials();
+  set_google_default_creds_env_var_with_file_contents(
+      "google_default_creds_external_account_credentials",
+      test_external_account_credentials_str);
+  creds = reinterpret_cast<grpc_composite_channel_credentials*>(
+      grpc_google_default_credentials_create(nullptr));
+  auto* default_creds =
+      reinterpret_cast<const grpc_google_default_channel_credentials*>(
+          creds->inner_creds());
+  GPR_ASSERT(default_creds->ssl_creds() != nullptr);
+  auto* external =
+      reinterpret_cast<const grpc_core::ExternalAccountCredentials*>(
+          creds->call_creds());
+  GPR_ASSERT(external != nullptr);
+  creds->Unref();
+  gpr_setenv(GRPC_GOOGLE_CREDENTIALS_ENV_VAR, ""); /* Reset. */
+}
+
+static void
+test_google_default_creds_external_account_credentials_multi_pattern_sts(void) {
+  grpc_core::ExecCtx exec_ctx;
+  grpc_composite_channel_credentials* creds;
+  grpc_flush_cached_google_default_credentials();
+  set_google_default_creds_env_var_with_file_contents(
+      "google_default_creds_external_account_credentials",
+      test_external_account_credentials_multi_pattern_sts_str);
+  creds = reinterpret_cast<grpc_composite_channel_credentials*>(
+      grpc_google_default_credentials_create(nullptr));
+  auto* default_creds =
+      reinterpret_cast<const grpc_google_default_channel_credentials*>(
+          creds->inner_creds());
+  GPR_ASSERT(default_creds->ssl_creds() != nullptr);
+  auto* external =
+      reinterpret_cast<const grpc_core::ExternalAccountCredentials*>(
+          creds->call_creds());
+  GPR_ASSERT(external != nullptr);
+  creds->Unref();
+  gpr_setenv(GRPC_GOOGLE_CREDENTIALS_ENV_VAR, ""); /* Reset. */
+}
+
+static void
+test_google_default_creds_external_account_credentials_multi_pattern_iam(void) {
+  grpc_core::ExecCtx exec_ctx;
+  grpc_composite_channel_credentials* creds;
+  grpc_flush_cached_google_default_credentials();
+  set_google_default_creds_env_var_with_file_contents(
+      "google_default_creds_external_account_credentials",
+      test_external_account_credentials_multi_pattern_iam_str);
+  creds = reinterpret_cast<grpc_composite_channel_credentials*>(
+      grpc_google_default_credentials_create(nullptr));
+  auto* default_creds =
+      reinterpret_cast<const grpc_google_default_channel_credentials*>(
+          creds->inner_creds());
+  GPR_ASSERT(default_creds->ssl_creds() != nullptr);
+  auto* external =
+      reinterpret_cast<const grpc_core::ExternalAccountCredentials*>(
+          creds->call_creds());
+  GPR_ASSERT(external != nullptr);
+  creds->Unref();
+  gpr_setenv(GRPC_GOOGLE_CREDENTIALS_ENV_VAR, ""); /* Reset. */
+}
+
 static int default_creds_metadata_server_detection_httpcli_get_success_override(
     const grpc_httpcli_request* request, grpc_millis /*deadline*/,
     grpc_closure* on_done, grpc_httpcli_response* response) {
@@ -1829,10 +1948,11 @@ static void test_metadata_plugin_failure(void) {
   grpc_core::ExecCtx exec_ctx;
   grpc_auth_metadata_context auth_md_ctx = {test_service_url, test_method,
                                             nullptr, nullptr};
-  std::string expected_error = absl::StrCat(
-      "Getting metadata from plugin failed with error: ", plugin_error_details);
   request_metadata_state* md_state = make_request_metadata_state(
-      GRPC_ERROR_CREATE_FROM_COPIED_STRING(expected_error.c_str()), nullptr, 0);
+      GRPC_ERROR_CREATE_FROM_CPP_STRING(
+          absl::StrCat("Getting metadata from plugin failed with error: ",
+                       plugin_error_details)),
+      nullptr, 0);
 
   plugin.state = &state;
   plugin.get_metadata = plugin_get_metadata_failure;
@@ -3391,8 +3511,12 @@ int main(int argc, char** argv) {
   test_jwt_creds_lifetime();
   test_jwt_creds_success();
   test_jwt_creds_signing_failure();
+  test_remove_service_from_jwt_uri();
   test_google_default_creds_auth_key();
   test_google_default_creds_refresh_token();
+  test_google_default_creds_external_account_credentials();
+  test_google_default_creds_external_account_credentials_multi_pattern_sts();
+  test_google_default_creds_external_account_credentials_multi_pattern_iam();
   test_google_default_creds_gce();
   test_google_default_creds_non_gce();
   test_no_google_default_creds();
index c0d0a9e..a8df9b3 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
+#include "src/core/lib/security/authorization/evaluate_args.h"
+
 #include <gmock/gmock.h>
 #include <gtest/gtest.h>
 
 #include "src/core/lib/address_utils/sockaddr_utils.h"
-#include "src/core/lib/security/authorization/evaluate_args.h"
 #include "test/core/util/evaluate_args_test_util.h"
 #include "test/core/util/test_config.h"
 
index 99d7c76..b9f08dc 100644 (file)
@@ -25,8 +25,8 @@
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/sync.h>
+#include <grpcpp/security/credentials.h>
 
-#include "grpcpp/security/credentials.h"
 #include "src/core/lib/iomgr/error.h"
 #include "src/core/lib/iomgr/load_file.h"
 #include "src/core/lib/security/credentials/credentials.h"
index d33b591..0e4c2fe 100644 (file)
@@ -16,6 +16,8 @@
  *
  */
 
+#include "src/core/lib/security/credentials/alts/grpc_alts_credentials_options.h"
+
 #include <stdio.h>
 #include <stdlib.h>
 #include <string.h>
@@ -23,8 +25,6 @@
 #include <grpc/grpc.h>
 #include <grpc/support/log.h>
 
-#include "src/core/lib/security/credentials/alts/grpc_alts_credentials_options.h"
-
 #define ALTS_CLIENT_OPTIONS_TEST_TARGET_SERVICE_ACCOUNT_1 "abc@google.com"
 #define ALTS_CLIENT_OPTIONS_TEST_TARGET_SERVICE_ACCOUNT_2 "def@google.com"
 
index e6dd4ad..f85482e 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
+#include "src/core/lib/security/authorization/grpc_authorization_engine.h"
+
 #include <gmock/gmock.h>
 #include <gtest/gtest.h>
 
-#include "src/core/lib/security/authorization/grpc_authorization_engine.h"
-
 namespace grpc_core {
 
 TEST(GrpcAuthorizationEngineTest, AllowEngineWithMatchingPolicy) {
index 40f008d..f298a35 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
+#include "src/core/lib/security/authorization/grpc_authorization_policy_provider.h"
+
 #include <gmock/gmock.h>
-#include <grpc/grpc_security.h>
 #include <gtest/gtest.h>
 
+#include <grpc/grpc_security.h>
+
 #include "src/core/lib/security/authorization/grpc_authorization_engine.h"
-#include "src/core/lib/security/authorization/grpc_authorization_policy_provider.h"
 #include "test/core/util/test_config.h"
 
 namespace grpc_core {
@@ -36,14 +38,15 @@ TEST(AuthorizationPolicyProviderTest, StaticDataInitializationSuccessful) {
       "}";
   auto provider = StaticDataAuthorizationPolicyProvider::Create(authz_policy);
   ASSERT_TRUE(provider.ok());
-  auto* allow_engine =
-      dynamic_cast<GrpcAuthorizationEngine*>((*provider)->allow_engine().get());
-  ASSERT_NE(allow_engine, nullptr);
-  EXPECT_EQ(allow_engine->action(), Rbac::Action::kAllow);
-  auto* deny_engine =
-      dynamic_cast<GrpcAuthorizationEngine*>((*provider)->deny_engine().get());
-  ASSERT_NE(deny_engine, nullptr);
-  EXPECT_EQ(deny_engine->action(), Rbac::Action::kDeny);
+  auto engines = (*provider)->engines();
+  ASSERT_NE(engines.allow_engine, nullptr);
+  EXPECT_EQ(dynamic_cast<GrpcAuthorizationEngine*>(engines.allow_engine.get())
+                ->action(),
+            Rbac::Action::kAllow);
+  ASSERT_NE(engines.deny_engine, nullptr);
+  EXPECT_EQ(dynamic_cast<GrpcAuthorizationEngine*>(engines.deny_engine.get())
+                ->action(),
+            Rbac::Action::kDeny);
 }
 
 TEST(AuthorizationPolicyProviderTest,
index 92123a1..17aac54 100644 (file)
 
 #include "src/core/lib/security/credentials/tls/grpc_tls_certificate_distributor.h"
 
-#include <gmock/gmock.h>
-#include <grpc/support/alloc.h>
-#include <grpc/support/log.h>
-#include <grpc/support/string_util.h>
-#include <gtest/gtest.h>
-
 #include <deque>
 #include <list>
 #include <string>
 #include <thread>
 
+#include <gmock/gmock.h>
+#include <gtest/gtest.h>
+
+#include <grpc/support/alloc.h>
+#include <grpc/support/log.h>
+#include <grpc/support/string_util.h>
+
 #include "src/core/lib/slice/slice_internal.h"
 #include "test/core/util/test_config.h"
 #include "test/core/util/tls_utils.h"
index fe65c60..40e6f03 100644 (file)
 
 #include "src/core/lib/security/credentials/tls/grpc_tls_certificate_provider.h"
 
+#include <deque>
+#include <list>
+
 #include <gmock/gmock.h>
+#include <gtest/gtest.h>
 
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/string_util.h>
-#include <gtest/gtest.h>
-
-#include <deque>
-#include <list>
 
 #include "src/core/lib/gpr/tmpfile.h"
 #include "src/core/lib/iomgr/load_file.h"
index c5736ca..761effd 100644 (file)
 #include "src/core/lib/security/credentials/tls/grpc_tls_credentials_options.h"
 
 #include <gmock/gmock.h>
+#include <gtest/gtest.h>
+
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/string_util.h>
-#include <gtest/gtest.h>
 
 #include "src/core/lib/gpr/tmpfile.h"
 #include "src/core/lib/iomgr/load_file.h"
index dfdb28b..0955eeb 100644 (file)
 //
 //
 
+#include "src/core/lib/security/security_connector/insecure/insecure_security_connector.h"
+
 #include <gmock/gmock.h>
 #include <gtest/gtest.h>
 
 #include <grpc/grpc_security.h>
 
-#include "src/core/lib/security/security_connector/insecure/insecure_security_connector.h"
 #include "src/core/lib/security/security_connector/ssl_utils.h"
 #include "src/core/tsi/transport_security.h"
 #include "test/core/util/test_config.h"
index 1ded259..9f855a8 100644 (file)
 
 #include "src/core/lib/security/credentials/jwt/json_token.h"
 
-#include <openssl/evp.h>
 #include <string.h>
 
+#include <openssl/evp.h>
+
 #include <grpc/grpc_security.h>
 #include <grpc/slice.h>
 #include <grpc/support/alloc.h>
index 21ed63f..933c413 100644 (file)
@@ -21,7 +21,6 @@
 #include <string.h>
 
 #include <grpc/grpc.h>
-
 #include <grpc/slice.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
index cd8bd3b..318f27d 100644 (file)
  */
 
 #include <grpc/support/port_platform.h>
+
 #include <stdio.h>
 
 #ifdef GPR_LINUX
+#include <string.h>
+#include <sys/param.h>
+
+#include "gtest/gtest.h"
+
 #include <grpc/grpc_security.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/string_util.h>
-#include <string.h>
-#include <sys/param.h>
 
 #include "src/core/lib/gpr/env.h"
 #include "src/core/lib/gpr/tmpfile.h"
@@ -39,8 +43,6 @@
 #include "src/core/tsi/transport_security.h"
 #include "test/core/util/test_config.h"
 
-#include "gtest/gtest.h"
-
 namespace grpc {
 namespace {
 
index 337f471..ecc3f8e 100644 (file)
@@ -553,32 +553,6 @@ TEST(GenerateRbacPoliciesTest, UnsupportedPseudoHeaders) {
             "allow_rules 0: \"headers\" 0: Unsupported \"key\" :method.");
 }
 
-TEST(GenerateRbacPoliciesTest, UnsupportedhostHeader) {
-  const char* authz_policy =
-      "{"
-      "  \"name\": \"authz\","
-      "  \"deny_rules\": ["
-      "    {"
-      "      \"name\": \"policy\","
-      "      \"request\": {"
-      "        \"headers\": ["
-      "          {"
-      "            \"key\": \"host\","
-      "            \"values\": ["
-      "              \"*\""
-      "            ]"
-      "          }"
-      "        ]"
-      "      }"
-      "    }"
-      "  ]"
-      "}";
-  auto rbac_policies = GenerateRbacPolicies(authz_policy);
-  EXPECT_EQ(rbac_policies.status().code(), absl::StatusCode::kInvalidArgument);
-  EXPECT_EQ(rbac_policies.status().message(),
-            "deny_rules 0: \"headers\" 0: Unsupported \"key\" host.");
-}
-
 TEST(GenerateRbacPoliciesTest, UnsupportedHostHeader) {
   const char* authz_policy =
       "{"
index c5621d9..0b3e98c 100644 (file)
@@ -16,7 +16,7 @@
  *
  */
 
-#include "test/core/iomgr/endpoint_tests.h"
+#include "src/core/lib/security/transport/secure_endpoint.h"
 
 #include <fcntl.h>
 #include <sys/types.h>
 #include <grpc/grpc.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
+
 #include "src/core/lib/gpr/useful.h"
 #include "src/core/lib/iomgr/endpoint_pair.h"
 #include "src/core/lib/iomgr/iomgr.h"
-#include "src/core/lib/security/transport/secure_endpoint.h"
 #include "src/core/lib/slice/slice_internal.h"
 #include "src/core/tsi/fake_transport_security.h"
+#include "test/core/iomgr/endpoint_tests.h"
+#include "test/core/util/resource_user_util.h"
 #include "test/core/util/test_config.h"
 
 static gpr_mu* g_mu;
index 5e9bf0a..fd0555b 100644 (file)
 
 #include "src/core/lib/security/security_connector/security_connector.h"
 
+#include <stdio.h>
+#include <string.h>
+
 #include <grpc/grpc_security.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/string_util.h>
-#include <stdio.h>
-#include <string.h>
 
 #include "src/core/lib/gpr/string.h"
 #include "src/core/lib/gpr/tmpfile.h"
index 7c9f561..a983301 100644 (file)
@@ -16,6 +16,8 @@
  *
  */
 
+#include "src/core/lib/security/credentials/ssl/ssl_credentials.h"
+
 #include <stdio.h>
 #include <string.h>
 
@@ -23,7 +25,6 @@
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 
-#include "src/core/lib/security/credentials/ssl/ssl_credentials.h"
 #include "src/core/tsi/ssl_transport_security.h"
 #include "test/core/util/test_config.h"
 
index 6401f8e..08a696c 100644 (file)
@@ -24,6 +24,7 @@
 #include "src/core/lib/security/credentials/credentials.h"
 #include "src/core/lib/security/security_connector/security_connector.h"
 #include "test/core/util/mock_endpoint.h"
+#include "test/core/util/resource_user_util.h"
 
 #define CA_CERT_PATH "src/core/tsi/test_creds/ca.pem"
 #define SERVER_CERT_PATH "src/core/tsi/test_creds/server1.pem"
@@ -59,11 +60,10 @@ extern "C" int LLVMFuzzerTestOneInput(const uint8_t* data, size_t size) {
   {
     grpc_core::ExecCtx exec_ctx;
 
-    grpc_resource_quota* resource_quota =
-        grpc_resource_quota_create("ssl_server_fuzzer");
+    grpc_slice_allocator* slice_allocator =
+        grpc_slice_allocator_create_unlimited();
     grpc_endpoint* mock_endpoint =
-        grpc_mock_endpoint_create(discard_write, resource_quota);
-    grpc_resource_quota_unref_internal(resource_quota);
+        grpc_mock_endpoint_create(discard_write, slice_allocator);
 
     grpc_mock_endpoint_put_read(
         mock_endpoint, grpc_slice_from_copied_buffer((const char*)data, size));
@@ -114,7 +114,6 @@ extern "C" int LLVMFuzzerTestOneInput(const uint8_t* data, size_t size) {
           GRPC_ERROR_CREATE_FROM_STATIC_STRING("Explicit close"));
       grpc_core::ExecCtx::Get()->Flush();
     }
-
     GPR_ASSERT(state.done_callback_called);
 
     sc.reset(DEBUG_LOCATION, "test");
index c041fd9..1ede053 100644 (file)
 
 #include "src/core/lib/security/security_connector/tls/tls_security_connector.h"
 
+#include <stdlib.h>
+#include <string.h>
+
 #include <gmock/gmock.h>
+#include <gtest/gtest.h>
+
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/string_util.h>
-#include <gtest/gtest.h>
-#include <stdlib.h>
-#include <string.h>
 
 #include "src/core/lib/iomgr/load_file.h"
 #include "src/core/lib/security/credentials/tls/grpc_tls_certificate_provider.h"
index 9454879..5b62fde 100644 (file)
@@ -19,7 +19,8 @@
 #include <stdbool.h>
 #include <stdint.h>
 
-#include "include/grpc/support/alloc.h"
+#include <grpc/support/alloc.h>
+
 #include "src/core/lib/slice/b64.h"
 
 bool squelch = true;
index 6677150..28c299f 100644 (file)
@@ -24,6 +24,7 @@
 #include <grpc/slice.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
+
 #include "src/core/lib/iomgr/exec_ctx.h"
 #include "src/core/lib/slice/slice_internal.h"
 #include "test/core/util/test_config.h"
index 06d7347..25d90a3 100644 (file)
@@ -32,16 +32,18 @@ bool leak_check = true;
 extern "C" int LLVMFuzzerTestOneInput(const uint8_t* data, size_t size) {
   grpc_init();
   grpc_slice input = grpc_slice_from_copied_buffer((const char*)data, size);
-  grpc_slice output;
-  if (grpc_strict_percent_decode_slice(
-          input, grpc_url_percent_encoding_unreserved_bytes, &output)) {
-    grpc_slice_unref(output);
+  absl::optional<grpc_slice> output;
+  output =
+      grpc_core::PercentDecodeSlice(input, grpc_core::PercentEncodingType::URL);
+  if (output.has_value()) {
+    grpc_slice_unref(*output);
   }
-  if (grpc_strict_percent_decode_slice(
-          input, grpc_compatible_percent_encoding_unreserved_bytes, &output)) {
-    grpc_slice_unref(output);
+  output = grpc_core::PercentDecodeSlice(
+      input, grpc_core::PercentEncodingType::Compatible);
+  if (output.has_value()) {
+    grpc_slice_unref(*output);
   }
-  grpc_slice_unref(grpc_permissive_percent_decode_slice(input));
+  grpc_slice_unref(grpc_core::PermissivePercentDecodeSlice(input));
   grpc_slice_unref(input);
   grpc_shutdown();
   return 0;
index e988ad0..782d1f9 100644 (file)
 bool squelch = true;
 bool leak_check = true;
 
-static void test(const uint8_t* data, size_t size, const uint8_t* dict) {
+static void test(const uint8_t* data, size_t size,
+                 grpc_core::PercentEncodingType type) {
   grpc_init();
   grpc_slice input =
       grpc_slice_from_copied_buffer(reinterpret_cast<const char*>(data), size);
-  grpc_slice output = grpc_percent_encode_slice(input, dict);
-  grpc_slice decoded_output;
+  grpc_slice output = grpc_core::PercentEncodeSlice(input, type);
+  absl::optional<grpc_slice> decoded_output =
+      grpc_core::PercentDecodeSlice(output, type);
   // encoder must always produce decodable output
-  GPR_ASSERT(grpc_strict_percent_decode_slice(output, dict, &decoded_output));
+  GPR_ASSERT(decoded_output.has_value());
   grpc_slice permissive_decoded_output =
-      grpc_permissive_percent_decode_slice(output);
+      grpc_core::PermissivePercentDecodeSlice(output);
   // and decoded output must always match the input
-  GPR_ASSERT(grpc_slice_eq(input, decoded_output));
+  GPR_ASSERT(grpc_slice_eq(input, *decoded_output));
   GPR_ASSERT(grpc_slice_eq(input, permissive_decoded_output));
   grpc_slice_unref(input);
   grpc_slice_unref(output);
-  grpc_slice_unref(decoded_output);
+  grpc_slice_unref(*decoded_output);
   grpc_slice_unref(permissive_decoded_output);
   grpc_shutdown();
 }
 
 extern "C" int LLVMFuzzerTestOneInput(const uint8_t* data, size_t size) {
-  test(data, size, grpc_url_percent_encoding_unreserved_bytes);
-  test(data, size, grpc_compatible_percent_encoding_unreserved_bytes);
+  test(data, size, grpc_core::PercentEncodingType::URL);
+  test(data, size, grpc_core::PercentEncodingType::Compatible);
   return 0;
 }
index ae6c39e..d756637 100644 (file)
@@ -35,7 +35,8 @@
                             sizeof(permissive_unencoded) - 1, dict)
 
 static void test_vector(const char* raw, size_t raw_length, const char* encoded,
-                        size_t encoded_length, const uint8_t* dict) {
+                        size_t encoded_length,
+                        grpc_core::PercentEncodingType type) {
   char* raw_msg = gpr_dump(raw, raw_length, GPR_DUMP_HEX | GPR_DUMP_ASCII);
   char* encoded_msg =
       gpr_dump(encoded, encoded_length, GPR_DUMP_HEX | GPR_DUMP_ASCII);
@@ -46,17 +47,17 @@ static void test_vector(const char* raw, size_t raw_length, const char* encoded,
   grpc_slice raw_slice = grpc_slice_from_copied_buffer(raw, raw_length);
   grpc_slice encoded_slice =
       grpc_slice_from_copied_buffer(encoded, encoded_length);
-  grpc_slice raw2encoded_slice = grpc_percent_encode_slice(raw_slice, dict);
-  grpc_slice encoded2raw_slice;
-  GPR_ASSERT(grpc_strict_percent_decode_slice(encoded_slice, dict,
-                                              &encoded2raw_slice));
+  grpc_slice raw2encoded_slice = grpc_core::PercentEncodeSlice(raw_slice, type);
+  absl::optional<grpc_slice> encoded2raw_slice =
+      grpc_core::PercentDecodeSlice(encoded_slice, type);
+  GPR_ASSERT(encoded2raw_slice.has_value());
   grpc_slice encoded2raw_permissive_slice =
-      grpc_permissive_percent_decode_slice(encoded_slice);
+      grpc_core::PermissivePercentDecodeSlice(encoded_slice);
 
   char* raw2encoded_msg =
       grpc_dump_slice(raw2encoded_slice, GPR_DUMP_HEX | GPR_DUMP_ASCII);
   char* encoded2raw_msg =
-      grpc_dump_slice(encoded2raw_slice, GPR_DUMP_HEX | GPR_DUMP_ASCII);
+      grpc_dump_slice(*encoded2raw_slice, GPR_DUMP_HEX | GPR_DUMP_ASCII);
   char* encoded2raw_permissive_msg = grpc_dump_slice(
       encoded2raw_permissive_slice, GPR_DUMP_HEX | GPR_DUMP_ASCII);
   gpr_log(GPR_DEBUG,
@@ -67,11 +68,11 @@ static void test_vector(const char* raw, size_t raw_length, const char* encoded,
   gpr_free(encoded2raw_msg);
   gpr_free(encoded2raw_permissive_msg);
 
-  GPR_ASSERT(grpc_slice_eq(raw_slice, encoded2raw_slice));
+  GPR_ASSERT(grpc_slice_eq(raw_slice, *encoded2raw_slice));
   GPR_ASSERT(grpc_slice_eq(raw_slice, encoded2raw_permissive_slice));
   GPR_ASSERT(grpc_slice_eq(encoded_slice, raw2encoded_slice));
 
-  grpc_slice_unref(encoded2raw_slice);
+  grpc_slice_unref(*encoded2raw_slice);
   grpc_slice_unref(encoded2raw_permissive_slice);
   grpc_slice_unref(raw2encoded_slice);
   grpc_slice_unref(raw_slice);
@@ -82,7 +83,7 @@ static void test_nonconformant_vector(const char* encoded,
                                       size_t encoded_length,
                                       const char* permissive_unencoded,
                                       size_t permissive_unencoded_length,
-                                      const uint8_t* dict) {
+                                      grpc_core::PercentEncodingType type) {
   char* permissive_unencoded_msg =
       gpr_dump(permissive_unencoded, permissive_unencoded_length,
                GPR_DUMP_HEX | GPR_DUMP_ASCII);
@@ -97,11 +98,11 @@ static void test_nonconformant_vector(const char* encoded,
       permissive_unencoded, permissive_unencoded_length);
   grpc_slice encoded_slice =
       grpc_slice_from_copied_buffer(encoded, encoded_length);
-  grpc_slice encoded2raw_slice;
-  GPR_ASSERT(!grpc_strict_percent_decode_slice(encoded_slice, dict,
-                                               &encoded2raw_slice));
+  absl::optional<grpc_slice> encoded2raw_slice =
+      grpc_core::PercentDecodeSlice(encoded_slice, type);
+  GPR_ASSERT(!encoded2raw_slice.has_value());
   grpc_slice encoded2raw_permissive_slice =
-      grpc_permissive_percent_decode_slice(encoded_slice);
+      grpc_core::PermissivePercentDecodeSlice(encoded_slice);
 
   char* encoded2raw_permissive_msg = grpc_dump_slice(
       encoded2raw_permissive_slice, GPR_DUMP_HEX | GPR_DUMP_ASCII);
@@ -123,25 +124,21 @@ int main(int argc, char** argv) {
   TEST_VECTOR(
       "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789-_.~",
       "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789-_.~",
-      grpc_url_percent_encoding_unreserved_bytes);
-  TEST_VECTOR("\x00", "%00", grpc_url_percent_encoding_unreserved_bytes);
-  TEST_VECTOR("\x01", "%01", grpc_url_percent_encoding_unreserved_bytes);
-  TEST_VECTOR("a b", "a%20b", grpc_url_percent_encoding_unreserved_bytes);
-  TEST_VECTOR(" b", "%20b", grpc_url_percent_encoding_unreserved_bytes);
-  TEST_VECTOR("a b", "a b", grpc_compatible_percent_encoding_unreserved_bytes);
-  TEST_VECTOR(" b", " b", grpc_compatible_percent_encoding_unreserved_bytes);
-  TEST_VECTOR("\x0f", "%0F", grpc_url_percent_encoding_unreserved_bytes);
-  TEST_VECTOR("\xff", "%FF", grpc_url_percent_encoding_unreserved_bytes);
-  TEST_VECTOR("\xee", "%EE", grpc_url_percent_encoding_unreserved_bytes);
-  TEST_VECTOR("%2", "%252", grpc_url_percent_encoding_unreserved_bytes);
-  TEST_NONCONFORMANT_VECTOR("%", "%",
-                            grpc_url_percent_encoding_unreserved_bytes);
-  TEST_NONCONFORMANT_VECTOR("%A", "%A",
-                            grpc_url_percent_encoding_unreserved_bytes);
-  TEST_NONCONFORMANT_VECTOR("%AG", "%AG",
-                            grpc_url_percent_encoding_unreserved_bytes);
-  TEST_NONCONFORMANT_VECTOR("\0", "\0",
-                            grpc_url_percent_encoding_unreserved_bytes);
+      grpc_core::PercentEncodingType::URL);
+  TEST_VECTOR("\x00", "%00", grpc_core::PercentEncodingType::URL);
+  TEST_VECTOR("\x01", "%01", grpc_core::PercentEncodingType::URL);
+  TEST_VECTOR("a b", "a%20b", grpc_core::PercentEncodingType::URL);
+  TEST_VECTOR(" b", "%20b", grpc_core::PercentEncodingType::URL);
+  TEST_VECTOR("a b", "a b", grpc_core::PercentEncodingType::Compatible);
+  TEST_VECTOR(" b", " b", grpc_core::PercentEncodingType::Compatible);
+  TEST_VECTOR("\x0f", "%0F", grpc_core::PercentEncodingType::URL);
+  TEST_VECTOR("\xff", "%FF", grpc_core::PercentEncodingType::URL);
+  TEST_VECTOR("\xee", "%EE", grpc_core::PercentEncodingType::URL);
+  TEST_VECTOR("%2", "%252", grpc_core::PercentEncodingType::URL);
+  TEST_NONCONFORMANT_VECTOR("%", "%", grpc_core::PercentEncodingType::URL);
+  TEST_NONCONFORMANT_VECTOR("%A", "%A", grpc_core::PercentEncodingType::URL);
+  TEST_NONCONFORMANT_VECTOR("%AG", "%AG", grpc_core::PercentEncodingType::URL);
+  TEST_NONCONFORMANT_VECTOR("\0", "\0", grpc_core::PercentEncodingType::URL);
   grpc_shutdown();
   return 0;
 }
index 7d4acfe..ffa2c7f 100644 (file)
@@ -19,6 +19,7 @@
 #include <grpc/grpc.h>
 #include <grpc/slice_buffer.h>
 #include <grpc/support/log.h>
+
 #include "src/core/lib/slice/slice_internal.h"
 #include "test/core/util/test_config.h"
 
index 975bedf..c5c8c5c 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include <grpc/slice.h>
-
 #include <inttypes.h>
 #include <string.h>
 
 #include <grpc/grpc.h>
+#include <grpc/slice.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 
index 47d76f4..89f5082 100644 (file)
  *
  */
 
+#include <string.h>
+
 #include <grpc/byte_buffer.h>
 #include <grpc/byte_buffer_reader.h>
 #include <grpc/grpc.h>
 #include <grpc/slice.h>
-
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/time.h>
@@ -29,8 +30,6 @@
 #include "src/core/lib/iomgr/exec_ctx.h"
 #include "test/core/util/test_config.h"
 
-#include <string.h>
-
 #define LOG_TEST(x) gpr_log(GPR_INFO, "%s", x)
 
 static void test_read_one_slice(void) {
index e3001c7..0a8bee7 100644 (file)
@@ -21,6 +21,7 @@
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/time.h>
+
 #include "src/core/lib/gpr/useful.h"
 #include "src/core/lib/gprpp/memory.h"
 #include "src/core/lib/gprpp/sync.h"
index a466cd2..c7379dc 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include "src/core/lib/surface/completion_queue.h"
-
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/time.h>
@@ -25,6 +23,7 @@
 #include "src/core/lib/gpr/useful.h"
 #include "src/core/lib/gprpp/thd.h"
 #include "src/core/lib/iomgr/iomgr.h"
+#include "src/core/lib/surface/completion_queue.h"
 #include "test/core/util/test_config.h"
 
 #define LOG_TEST(x) gpr_log(GPR_INFO, "%s", x)
index 5cf6931..f63ee87 100644 (file)
  *
  */
 
-/* With the addition of a libuv endpoint, sockaddr.h now includes uv.h when
-   using that endpoint. Because of various transitive includes in uv.h,
-   including windows.h on Windows, uv.h must be included before other system
-   headers. Therefore, sockaddr.h must always be included first */
-#include "src/core/lib/iomgr/sockaddr.h"
-
 #include <memory.h>
 #include <stdio.h>
-#include <atomic>
 
+#include <atomic>
 #include <string>
 
 #include "absl/strings/str_cat.h"
@@ -39,8 +33,8 @@
 #include "src/core/lib/iomgr/exec_ctx.h"
 #include "src/core/lib/iomgr/iomgr.h"
 #include "src/core/lib/iomgr/resolve_address.h"
+#include "src/core/lib/iomgr/sockaddr.h"
 #include "src/core/lib/iomgr/tcp_server.h"
-
 #include "test/core/util/port.h"
 #include "test/core/util/test_config.h"
 
@@ -137,7 +131,10 @@ void bad_server_thread(void* vargs) {
   grpc_sockaddr* addr = reinterpret_cast<grpc_sockaddr*>(resolved_addr.addr);
   int port;
   grpc_tcp_server* s;
-  grpc_error_handle error = grpc_tcp_server_create(nullptr, nullptr, &s);
+  grpc_error_handle error = grpc_tcp_server_create(
+      nullptr, nullptr,
+      grpc_slice_allocator_factory_create(grpc_resource_quota_create(nullptr)),
+      &s);
   GPR_ASSERT(error == GRPC_ERROR_NONE);
   memset(&resolved_addr, 0, sizeof(resolved_addr));
   addr->sa_family = GRPC_AF_INET;
index 4862e3a..f99ba1e 100644 (file)
 
 #include "src/core/lib/surface/init.h"
 
+#include <gtest/gtest.h>
+
 #include <grpc/grpc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/time.h>
-#include <gtest/gtest.h>
 
 #include "src/core/lib/iomgr/exec_ctx.h"
 #include "test/core/util/test_config.h"
index bd443a7..7b89ab3 100644 (file)
@@ -21,6 +21,7 @@
 #include <grpc/grpc.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
+
 #include "src/core/lib/channel/channel_stack.h"
 #include "src/core/lib/iomgr/closure.h"
 #include "src/core/lib/surface/channel.h"
index e9bb815..a0d5a54 100644 (file)
@@ -21,6 +21,7 @@
 #include <grpc/grpc.h>
 #include <grpc/grpc_security.h>
 #include <grpc/support/log.h>
+
 #include "src/core/ext/filters/client_channel/resolver_registry.h"
 #include "src/core/lib/security/credentials/fake/fake_credentials.h"
 #include "src/core/lib/security/security_connector/security_connector.h"
index e74b0e7..e85c1d5 100644 (file)
@@ -39,8 +39,6 @@ TEST(ServerChttp2, UnparseableTarget) {
   grpc_server_destroy(server);
 }
 
-// GRPC_ARG_ALLOW_REUSEPORT isn't supported for custom servers
-#ifndef GRPC_UV
 TEST(ServerChttp2, AddSamePortTwice) {
   grpc_arg a = grpc_channel_arg_integer_create(
       const_cast<char*>(GRPC_ARG_ALLOW_REUSEPORT), 0);
@@ -64,7 +62,6 @@ TEST(ServerChttp2, AddSamePortTwice) {
   grpc_server_destroy(server);
   grpc_completion_queue_destroy(cq);
 }
-#endif
 
 int main(int argc, char** argv) {
   grpc::testing::TestEnvironment env(argc, argv);
index 2aa962a..630d9f8 100644 (file)
@@ -72,8 +72,6 @@ void test_request_call_on_no_server_cq(void) {
   grpc_server_destroy(server);
 }
 
-// GRPC_ARG_ALLOW_REUSEPORT isn't supported for custom servers
-#ifndef GRPC_UV
 void test_bind_server_twice(void) {
   grpc_arg a = grpc_channel_arg_integer_create(
       const_cast<char*>(GRPC_ARG_ALLOW_REUSEPORT), 0);
@@ -104,7 +102,6 @@ void test_bind_server_twice(void) {
   grpc_server_destroy(server2);
   grpc_completion_queue_destroy(cq);
 }
-#endif
 
 void test_bind_server_to_addr(const char* host, bool secure) {
   int port = grpc_pick_unused_port_or_die();
@@ -153,9 +150,7 @@ int main(int argc, char** argv) {
   grpc_init();
   test_register_method_fail();
   test_request_call_on_no_server_cq();
-#ifndef GRPC_UV
   test_bind_server_twice();
-#endif
 
   static const char* addrs[] = {
       "::1", "127.0.0.1", "::ffff:127.0.0.1", "localhost", "0.0.0.0", "::",
index c6426fe..1f1e226 100644 (file)
 
 #include "src/core/lib/transport/bdp_estimator.h"
 
+#include <limits.h>
+
+#include <gtest/gtest.h>
+
 #include <grpc/grpc.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/string_util.h>
 
-#include <gtest/gtest.h>
-#include <limits.h>
-
 #include "src/core/lib/gpr/string.h"
 #include "src/core/lib/gpr/useful.h"
 #include "src/core/lib/iomgr/timer_manager.h"
index 7478fb6..8ccb707 100644 (file)
 # See the License for the specific language governing permissions and
 # limitations under the License.
 
-load("//bazel:grpc_build_system.bzl", "grpc_cc_test", "grpc_package")
+load("//bazel:grpc_build_system.bzl", "grpc_cc_library", "grpc_cc_test", "grpc_package")
 
 licenses(["notice"])
 
-grpc_package(name = "test/core/transport/binder")
+grpc_package(
+    name = "test/core/transport/binder",
+    visibility = "tests",
+)
+
+grpc_cc_library(
+    name = "mock_objects",
+    testonly = 1,
+    srcs = ["mock_objects.cc"],
+    hdrs = ["mock_objects.h"],
+    external_deps = [
+        "absl/memory",
+        "gtest",
+    ],
+    language = "C++",
+    deps = [
+        "//src/core/ext/transport/binder/wire_format:binder",
+        "//src/core/ext/transport/binder/wire_format:wire_reader",
+        "//src/core/ext/transport/binder/wire_format:wire_writer",
+    ],
+)
+
+grpc_cc_test(
+    name = "wire_writer_test",
+    srcs = ["wire_writer_test.cc"],
+    external_deps = [
+        "absl/memory",
+        "gtest",
+    ],
+    language = "C++",
+    uses_polling = False,
+    deps = [
+        ":mock_objects",
+        "//src/core/ext/transport/binder/wire_format:wire_writer",
+        "//test/core/util:grpc_test_util",
+    ],
+)
+
+grpc_cc_test(
+    name = "wire_reader_test",
+    srcs = ["wire_reader_test.cc"],
+    external_deps = [
+        "absl/memory",
+        "gtest",
+    ],
+    language = "C++",
+    uses_polling = False,
+    deps = [
+        ":mock_objects",
+        "//src/core/ext/transport/binder/wire_format:wire_reader",
+        "//test/core/util:grpc_test_util",
+    ],
+)
+
+grpc_cc_test(
+    name = "transport_stream_receiver_test",
+    srcs = ["transport_stream_receiver_test.cc"],
+    external_deps = [
+        "absl/memory",
+        "gtest",
+    ],
+    language = "C++",
+    uses_polling = False,
+    deps = [
+        "//src/core/ext/transport/binder/utils:transport_stream_receiver",
+        "//test/core/util:grpc_test_util",
+    ],
+)
 
 grpc_cc_test(
-    name = "binder_smoke_test",
-    srcs = ["binder_smoke_test.cc"],
+    name = "binder_transport_test",
+    srcs = ["binder_transport_test.cc"],
     external_deps = [
+        "absl/memory",
+        "absl/strings",
         "gtest",
     ],
     language = "C++",
     uses_polling = False,
     deps = [
-        "//:gpr",
+        ":mock_objects",
         "//:grpc",
+        "//src/core/ext/transport/binder/transport:binder_transport",
         "//test/core/util:grpc_test_util",
     ],
 )
diff --git a/test/core/transport/binder/binder_transport_test.cc b/test/core/transport/binder/binder_transport_test.cc
new file mode 100644 (file)
index 0000000..56084bc
--- /dev/null
@@ -0,0 +1,714 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+// Unit-tests for grpc_binder_transport
+//
+// Verify that a calls to the perform_stream_op of grpc_binder_transport
+// transform into the correct sequence of binder transactions.
+#include "src/core/ext/transport/binder/transport/binder_transport.h"
+
+#include <memory>
+#include <string>
+#include <vector>
+
+#include <gtest/gtest.h>
+
+#include "absl/memory/memory.h"
+#include "absl/strings/match.h"
+#include "absl/synchronization/notification.h"
+
+#include <grpc/grpc.h>
+
+#include "src/core/ext/transport/binder/transport/binder_stream.h"
+#include "test/core/transport/binder/mock_objects.h"
+#include "test/core/util/test_config.h"
+
+namespace grpc_binder {
+namespace {
+
+using ::testing::Expectation;
+using ::testing::NiceMock;
+using ::testing::Return;
+
+class BinderTransportTest : public ::testing::Test {
+ public:
+  BinderTransportTest()
+      : arena_(grpc_core::Arena::Create(/* initial_size = */ 1)),
+        transport_(grpc_create_binder_transport_client(
+            absl::make_unique<NiceMock<MockBinder>>())) {
+    auto* gbt = reinterpret_cast<grpc_binder_transport*>(transport_);
+    gbt->wire_writer = absl::make_unique<MockWireWriter>();
+    GRPC_STREAM_REF_INIT(&ref_, 1, nullptr, nullptr, "phony ref");
+  }
+
+  ~BinderTransportTest() override {
+    grpc_core::ExecCtx exec_ctx;
+    grpc_transport_destroy(transport_);
+    grpc_core::ExecCtx::Get()->Flush();
+    for (grpc_binder_stream* gbs : stream_buffer_) {
+      gbs->~grpc_binder_stream();
+      gpr_free(gbs);
+    }
+    arena_->Destroy();
+  }
+
+  void PerformStreamOp(grpc_binder_stream* gbs,
+                       grpc_transport_stream_op_batch* op) {
+    grpc_transport_perform_stream_op(transport_,
+                                     reinterpret_cast<grpc_stream*>(gbs), op);
+  }
+
+  grpc_binder_transport* GetBinderTransport() {
+    return reinterpret_cast<grpc_binder_transport*>(transport_);
+  }
+
+  grpc_binder_stream* InitNewBinderStream() {
+    grpc_binder_stream* gbs = static_cast<grpc_binder_stream*>(
+        gpr_malloc(grpc_transport_stream_size(transport_)));
+    grpc_transport_init_stream(transport_, reinterpret_cast<grpc_stream*>(gbs),
+                               &ref_, nullptr, arena_);
+    stream_buffer_.push_back(gbs);
+    return gbs;
+  }
+
+  MockWireWriter& GetWireWriter() {
+    return *reinterpret_cast<MockWireWriter*>(
+        GetBinderTransport()->wire_writer.get());
+  }
+
+  static void SetUpTestSuite() { grpc_init(); }
+  static void TearDownTestSuite() { grpc_shutdown(); }
+
+ protected:
+  grpc_core::Arena* arena_;
+  grpc_transport* transport_;
+  grpc_stream_refcount ref_;
+  std::vector<grpc_binder_stream*> stream_buffer_;
+};
+
+void MockCallback(void* arg, grpc_error_handle error);
+
+class MockGrpcClosure {
+ public:
+  explicit MockGrpcClosure(absl::Notification* notification = nullptr)
+      : notification_(notification) {
+    GRPC_CLOSURE_INIT(&closure_, MockCallback, this, nullptr);
+  }
+
+  grpc_closure* GetGrpcClosure() { return &closure_; }
+  MOCK_METHOD(void, Callback, (grpc_error_handle), ());
+
+  absl::Notification* notification_;
+
+ private:
+  grpc_closure closure_;
+};
+
+void MockCallback(void* arg, grpc_error_handle error) {
+  MockGrpcClosure* mock_closure = static_cast<MockGrpcClosure*>(arg);
+  mock_closure->Callback(error);
+  if (mock_closure->notification_) {
+    mock_closure->notification_->Notify();
+  }
+}
+
+// Matches with transactions having the desired flag, method_ref,
+// initial_metadata, and message_data.
+MATCHER_P4(TransactionMatches, flag, method_ref, initial_metadata, message_data,
+           "") {
+  if (arg.GetFlags() != flag) return false;
+  if (flag & kFlagPrefix) {
+    if (arg.GetMethodRef() != method_ref) return false;
+    if (arg.GetPrefixMetadata() != initial_metadata) return false;
+  }
+  if (flag & kFlagMessageData) {
+    if (arg.GetMessageData() != message_data) return false;
+  }
+  return true;
+}
+
+// Matches with grpc_error having error message containing |msg|.
+MATCHER_P(GrpcErrorMessageContains, msg, "") {
+  return absl::StrContains(grpc_error_std_string(arg), msg);
+}
+
+// Verify that the lower-level metadata has the same content as the gRPC
+// metadata.
+void VerifyMetadataEqual(const Metadata& md, grpc_metadata_batch grpc_md) {
+  grpc_linked_mdelem* elm = grpc_md.list.head;
+  for (size_t i = 0; i < md.size(); ++i) {
+    ASSERT_NE(elm, nullptr);
+    EXPECT_EQ(grpc_core::StringViewFromSlice(GRPC_MDKEY(elm->md)), md[i].first);
+    EXPECT_EQ(grpc_core::StringViewFromSlice(GRPC_MDVALUE(elm->md)),
+              md[i].second);
+    elm = elm->next;
+  }
+  EXPECT_EQ(elm, nullptr);
+}
+
+// RAII helper classes for constructing gRPC metadata and receiving callbacks.
+struct MakeSendInitialMetadata {
+  MakeSendInitialMetadata(const Metadata& initial_metadata,
+                          const std::string& method_ref,
+                          grpc_transport_stream_op_batch* op)
+      : storage(initial_metadata.size()) {
+    grpc_metadata_batch_init(&grpc_initial_metadata);
+    size_t i = 0;
+    for (const auto& md : initial_metadata) {
+      const std::string& key = md.first;
+      const std::string& value = md.second;
+      EXPECT_EQ(grpc_metadata_batch_add_tail(
+                    &grpc_initial_metadata, &storage[i],
+                    grpc_mdelem_from_slices(grpc_slice_from_cpp_string(key),
+                                            grpc_slice_from_cpp_string(value))),
+                GRPC_ERROR_NONE);
+      i++;
+    }
+    if (!method_ref.empty()) {
+      EXPECT_EQ(
+          grpc_metadata_batch_add_tail(
+              &grpc_initial_metadata, &method_ref_storage,
+              grpc_mdelem_from_slices(GRPC_MDSTR_PATH,
+                                      grpc_slice_from_cpp_string(method_ref))),
+          GRPC_ERROR_NONE);
+    }
+    op->send_initial_metadata = true;
+    op->payload->send_initial_metadata.send_initial_metadata =
+        &grpc_initial_metadata;
+  }
+  ~MakeSendInitialMetadata() {
+    grpc_metadata_batch_destroy(&grpc_initial_metadata);
+  }
+
+  std::vector<grpc_linked_mdelem> storage;
+  grpc_linked_mdelem method_ref_storage;
+  grpc_metadata_batch grpc_initial_metadata{};
+};
+
+struct MakeSendMessage {
+  MakeSendMessage(const std::string& message,
+                  grpc_transport_stream_op_batch* op) {
+    grpc_slice_buffer send_buffer;
+    grpc_slice_buffer_init(&send_buffer);
+    grpc_slice send_slice = grpc_slice_from_cpp_string(message);
+    grpc_slice_buffer_add(&send_buffer, send_slice);
+
+    send_stream.Init(&send_buffer, 0);
+    grpc_slice_buffer_destroy(&send_buffer);
+
+    op->send_message = true;
+    op->payload->send_message.send_message.reset(send_stream.get());
+  }
+
+  grpc_core::ManualConstructor<grpc_core::SliceBufferByteStream> send_stream;
+};
+
+struct MakeSendTrailingMetadata {
+  explicit MakeSendTrailingMetadata(const Metadata& trailing_metadata,
+                                    grpc_transport_stream_op_batch* op) {
+    EXPECT_TRUE(trailing_metadata.empty());
+    grpc_metadata_batch_init(&grpc_trailing_metadata);
+
+    op->send_trailing_metadata = true;
+    op->payload->send_trailing_metadata.send_trailing_metadata =
+        &grpc_trailing_metadata;
+  }
+
+  grpc_metadata_batch grpc_trailing_metadata{};
+};
+
+struct MakeRecvInitialMetadata {
+  explicit MakeRecvInitialMetadata(grpc_transport_stream_op_batch* op,
+                                   Expectation* call_before = nullptr)
+      : ready(&notification) {
+    grpc_metadata_batch_init(&grpc_initial_metadata);
+    op->recv_initial_metadata = true;
+    op->payload->recv_initial_metadata.recv_initial_metadata =
+        &grpc_initial_metadata;
+    op->payload->recv_initial_metadata.recv_initial_metadata_ready =
+        ready.GetGrpcClosure();
+    if (call_before) {
+      EXPECT_CALL(ready, Callback).After(*call_before);
+    } else {
+      EXPECT_CALL(ready, Callback);
+    }
+  }
+
+  ~MakeRecvInitialMetadata() {
+    grpc_metadata_batch_destroy(&grpc_initial_metadata);
+  }
+
+  MockGrpcClosure ready;
+  grpc_metadata_batch grpc_initial_metadata;
+  absl::Notification notification;
+};
+
+struct MakeRecvMessage {
+  explicit MakeRecvMessage(grpc_transport_stream_op_batch* op,
+                           Expectation* call_before = nullptr)
+      : ready(&notification) {
+    op->recv_message = true;
+    op->payload->recv_message.recv_message = &grpc_message;
+    op->payload->recv_message.recv_message_ready = ready.GetGrpcClosure();
+    if (call_before) {
+      EXPECT_CALL(ready, Callback).After(*call_before);
+    } else {
+      EXPECT_CALL(ready, Callback);
+    }
+  }
+
+  MockGrpcClosure ready;
+  absl::Notification notification;
+  grpc_core::OrphanablePtr<grpc_core::ByteStream> grpc_message;
+};
+
+struct MakeRecvTrailingMetadata {
+  explicit MakeRecvTrailingMetadata(grpc_transport_stream_op_batch* op,
+                                    Expectation* call_before = nullptr)
+      : ready(&notification) {
+    grpc_metadata_batch_init(&grpc_trailing_metadata);
+    op->recv_trailing_metadata = true;
+    op->payload->recv_trailing_metadata.recv_trailing_metadata =
+        &grpc_trailing_metadata;
+    op->payload->recv_trailing_metadata.recv_trailing_metadata_ready =
+        ready.GetGrpcClosure();
+    if (call_before) {
+      EXPECT_CALL(ready, Callback).After(*call_before);
+    } else {
+      EXPECT_CALL(ready, Callback);
+    }
+  }
+
+  ~MakeRecvTrailingMetadata() {
+    grpc_metadata_batch_destroy(&grpc_trailing_metadata);
+  }
+
+  MockGrpcClosure ready;
+  grpc_metadata_batch grpc_trailing_metadata;
+  absl::Notification notification;
+};
+
+const Metadata kDefaultMetadata = {
+    {"", ""},
+    {"", "value"},
+    {"key", ""},
+    {"key", "value"},
+};
+
+constexpr char kDefaultMethodRef[] = "/some/path";
+constexpr char kDefaultMessage[] = "binder transport message";
+constexpr int kDefaultStatus = 0x1234;
+
+Metadata AppendMethodRef(const Metadata& md, const std::string& method_ref) {
+  Metadata result = md;
+  result.emplace_back(":path", method_ref);
+  return result;
+}
+
+Metadata AppendStatus(const Metadata& md, int status) {
+  Metadata result = md;
+  result.emplace_back("grpc-status", std::to_string(status));
+  return result;
+}
+
+}  // namespace
+
+TEST_F(BinderTransportTest, CreateBinderTransport) {
+  EXPECT_NE(transport_, nullptr);
+}
+
+TEST_F(BinderTransportTest, TransactionIdIncrement) {
+  grpc_binder_stream* gbs0 = InitNewBinderStream();
+  EXPECT_EQ(gbs0->t, GetBinderTransport());
+  EXPECT_EQ(gbs0->tx_code, kFirstCallId);
+  grpc_binder_stream* gbs1 = InitNewBinderStream();
+  EXPECT_EQ(gbs1->t, GetBinderTransport());
+  EXPECT_EQ(gbs1->tx_code, kFirstCallId + 1);
+  grpc_binder_stream* gbs2 = InitNewBinderStream();
+  EXPECT_EQ(gbs2->t, GetBinderTransport());
+  EXPECT_EQ(gbs2->tx_code, kFirstCallId + 2);
+}
+
+TEST_F(BinderTransportTest, PerformSendInitialMetadata) {
+  grpc_core::ExecCtx exec_ctx;
+  grpc_binder_stream* gbs = InitNewBinderStream();
+  grpc_transport_stream_op_batch op{};
+  grpc_transport_stream_op_batch_payload payload(nullptr);
+  op.payload = &payload;
+  const Metadata kInitialMetadata = kDefaultMetadata;
+  MakeSendInitialMetadata send_initial_metadata(kInitialMetadata, "", &op);
+  MockGrpcClosure mock_on_complete;
+  op.on_complete = mock_on_complete.GetGrpcClosure();
+
+  ::testing::InSequence sequence;
+  EXPECT_CALL(GetWireWriter(), RpcCall(TransactionMatches(
+                                   kFlagPrefix, "", kInitialMetadata, "")));
+  EXPECT_CALL(mock_on_complete, Callback);
+
+  PerformStreamOp(gbs, &op);
+  grpc_core::ExecCtx::Get()->Flush();
+}
+
+TEST_F(BinderTransportTest, PerformSendInitialMetadataMethodRef) {
+  grpc_core::ExecCtx exec_ctx;
+  grpc_binder_stream* gbs = InitNewBinderStream();
+  grpc_transport_stream_op_batch op{};
+  grpc_transport_stream_op_batch_payload payload(nullptr);
+  op.payload = &payload;
+  const Metadata kInitialMetadata = kDefaultMetadata;
+  const std::string kMethodRef = kDefaultMethodRef;
+  MakeSendInitialMetadata send_initial_metadata(kInitialMetadata, kMethodRef,
+                                                &op);
+  MockGrpcClosure mock_on_complete;
+  op.on_complete = mock_on_complete.GetGrpcClosure();
+
+  ::testing::InSequence sequence;
+  EXPECT_CALL(GetWireWriter(),
+              RpcCall(TransactionMatches(kFlagPrefix, kMethodRef.substr(1),
+                                         kInitialMetadata, "")));
+  EXPECT_CALL(mock_on_complete, Callback);
+
+  PerformStreamOp(gbs, &op);
+  grpc_core::ExecCtx::Get()->Flush();
+}
+
+TEST_F(BinderTransportTest, PerformSendMessage) {
+  grpc_core::ExecCtx exec_ctx;
+  grpc_binder_stream* gbs = InitNewBinderStream();
+  grpc_transport_stream_op_batch op{};
+  grpc_transport_stream_op_batch_payload payload(nullptr);
+  op.payload = &payload;
+
+  const std::string kMessage = kDefaultMessage;
+  MakeSendMessage send_message(kMessage, &op);
+  MockGrpcClosure mock_on_complete;
+  op.on_complete = mock_on_complete.GetGrpcClosure();
+
+  ::testing::InSequence sequence;
+  EXPECT_CALL(
+      GetWireWriter(),
+      RpcCall(TransactionMatches(kFlagMessageData, "", Metadata{}, kMessage)));
+  EXPECT_CALL(mock_on_complete, Callback);
+
+  PerformStreamOp(gbs, &op);
+  grpc_core::ExecCtx::Get()->Flush();
+}
+
+TEST_F(BinderTransportTest, PerformSendTrailingMetadata) {
+  grpc_core::ExecCtx exec_ctx;
+  grpc_binder_stream* gbs = InitNewBinderStream();
+  grpc_transport_stream_op_batch op{};
+  grpc_transport_stream_op_batch_payload payload(nullptr);
+  op.payload = &payload;
+  // The wireformat guarantees that suffix metadata will always be empty.
+  // TODO(waynetu): Check whether gRPC can internally add extra trailing
+  // metadata.
+  const Metadata kTrailingMetadata = {};
+  MakeSendTrailingMetadata send_trailing_metadata(kTrailingMetadata, &op);
+  MockGrpcClosure mock_on_complete;
+  op.on_complete = mock_on_complete.GetGrpcClosure();
+
+  ::testing::InSequence sequence;
+  EXPECT_CALL(GetWireWriter(), RpcCall(TransactionMatches(
+                                   kFlagSuffix, "", kTrailingMetadata, "")));
+  EXPECT_CALL(mock_on_complete, Callback);
+
+  PerformStreamOp(gbs, &op);
+  grpc_core::ExecCtx::Get()->Flush();
+}
+
+TEST_F(BinderTransportTest, PerformSendAll) {
+  grpc_core::ExecCtx exec_ctx;
+  grpc_binder_stream* gbs = InitNewBinderStream();
+  grpc_transport_stream_op_batch op{};
+  grpc_transport_stream_op_batch_payload payload(nullptr);
+  op.payload = &payload;
+
+  const Metadata kInitialMetadata = kDefaultMetadata;
+  const std::string kMethodRef = kDefaultMethodRef;
+  MakeSendInitialMetadata send_initial_metadata(kInitialMetadata, kMethodRef,
+                                                &op);
+
+  const std::string kMessage = kDefaultMessage;
+  MakeSendMessage send_message(kMessage, &op);
+
+  // The wireformat guarantees that suffix metadata will always be empty.
+  // TODO(waynetu): Check whether gRPC can internally add extra trailing
+  // metadata.
+  const Metadata kTrailingMetadata = {};
+  MakeSendTrailingMetadata send_trailing_metadata(kTrailingMetadata, &op);
+
+  MockGrpcClosure mock_on_complete;
+  op.on_complete = mock_on_complete.GetGrpcClosure();
+
+  ::testing::InSequence sequence;
+  EXPECT_CALL(GetWireWriter(),
+              RpcCall(TransactionMatches(
+                  kFlagPrefix | kFlagMessageData | kFlagSuffix,
+                  kMethodRef.substr(1), kInitialMetadata, kMessage)));
+  EXPECT_CALL(mock_on_complete, Callback);
+
+  PerformStreamOp(gbs, &op);
+  grpc_core::ExecCtx::Get()->Flush();
+}
+
+TEST_F(BinderTransportTest, PerformRecvInitialMetadata) {
+  grpc_core::ExecCtx exec_ctx;
+  grpc_binder_stream* gbs = InitNewBinderStream();
+  grpc_transport_stream_op_batch op{};
+  grpc_transport_stream_op_batch_payload payload(nullptr);
+  op.payload = &payload;
+
+  MakeRecvInitialMetadata recv_initial_metadata(&op);
+
+  const Metadata kInitialMetadata = kDefaultMetadata;
+  auto* gbt = reinterpret_cast<grpc_binder_transport*>(transport_);
+  gbt->transport_stream_receiver->NotifyRecvInitialMetadata(gbs->tx_code,
+                                                            kInitialMetadata);
+  PerformStreamOp(gbs, &op);
+  grpc_core::ExecCtx::Get()->Flush();
+  recv_initial_metadata.notification.WaitForNotification();
+
+  VerifyMetadataEqual(kInitialMetadata,
+                      recv_initial_metadata.grpc_initial_metadata);
+}
+
+TEST_F(BinderTransportTest, PerformRecvInitialMetadataWithMethodRef) {
+  grpc_core::ExecCtx exec_ctx;
+  grpc_binder_stream* gbs = InitNewBinderStream();
+  grpc_transport_stream_op_batch op{};
+  grpc_transport_stream_op_batch_payload payload(nullptr);
+  op.payload = &payload;
+
+  MakeRecvInitialMetadata recv_initial_metadata(&op);
+
+  auto* gbt = reinterpret_cast<grpc_binder_transport*>(transport_);
+  const Metadata kInitialMetadataWithMethodRef =
+      AppendMethodRef(kDefaultMetadata, kDefaultMethodRef);
+  gbt->transport_stream_receiver->NotifyRecvInitialMetadata(
+      gbs->tx_code, kInitialMetadataWithMethodRef);
+  PerformStreamOp(gbs, &op);
+  grpc_core::ExecCtx::Get()->Flush();
+  recv_initial_metadata.notification.WaitForNotification();
+
+  VerifyMetadataEqual(kInitialMetadataWithMethodRef,
+                      recv_initial_metadata.grpc_initial_metadata);
+}
+
+TEST_F(BinderTransportTest, PerformRecvMessage) {
+  grpc_core::ExecCtx exec_ctx;
+  grpc_binder_stream* gbs = InitNewBinderStream();
+  grpc_transport_stream_op_batch op{};
+  grpc_transport_stream_op_batch_payload payload(nullptr);
+  op.payload = &payload;
+
+  MakeRecvMessage recv_message(&op);
+
+  auto* gbt = reinterpret_cast<grpc_binder_transport*>(transport_);
+  const std::string kMessage = kDefaultMessage;
+  gbt->transport_stream_receiver->NotifyRecvMessage(gbs->tx_code, kMessage);
+
+  PerformStreamOp(gbs, &op);
+  grpc_core::ExecCtx::Get()->Flush();
+  recv_message.notification.WaitForNotification();
+
+  EXPECT_TRUE(recv_message.grpc_message->Next(SIZE_MAX, nullptr));
+  grpc_slice slice;
+  recv_message.grpc_message->Pull(&slice);
+  EXPECT_EQ(kMessage,
+            std::string(reinterpret_cast<char*>(GRPC_SLICE_START_PTR(slice)),
+                        GRPC_SLICE_LENGTH(slice)));
+  grpc_slice_unref_internal(slice);
+}
+
+TEST_F(BinderTransportTest, PerformRecvTrailingMetadata) {
+  grpc_core::ExecCtx exec_ctx;
+  grpc_binder_stream* gbs = InitNewBinderStream();
+  grpc_transport_stream_op_batch op{};
+  grpc_transport_stream_op_batch_payload payload(nullptr);
+  op.payload = &payload;
+
+  MakeRecvTrailingMetadata recv_trailing_metadata(&op);
+
+  const Metadata kTrailingMetadata = kDefaultMetadata;
+  auto* gbt = reinterpret_cast<grpc_binder_transport*>(transport_);
+  constexpr int kStatus = kDefaultStatus;
+  gbt->transport_stream_receiver->NotifyRecvTrailingMetadata(
+      gbs->tx_code, kTrailingMetadata, kStatus);
+  PerformStreamOp(gbs, &op);
+  grpc_core::ExecCtx::Get()->Flush();
+  recv_trailing_metadata.notification.WaitForNotification();
+
+  VerifyMetadataEqual(AppendStatus(kTrailingMetadata, kStatus),
+                      recv_trailing_metadata.grpc_trailing_metadata);
+}
+
+TEST_F(BinderTransportTest, PerformRecvAll) {
+  grpc_core::ExecCtx exec_ctx;
+  grpc_binder_stream* gbs = InitNewBinderStream();
+  grpc_transport_stream_op_batch op{};
+  grpc_transport_stream_op_batch_payload payload(nullptr);
+  op.payload = &payload;
+
+  MakeRecvInitialMetadata recv_initial_metadata(&op);
+  MakeRecvMessage recv_message(&op);
+  MakeRecvTrailingMetadata recv_trailing_metadata(&op);
+
+  auto* gbt = reinterpret_cast<grpc_binder_transport*>(transport_);
+  const Metadata kInitialMetadataWithMethodRef =
+      AppendMethodRef(kDefaultMetadata, kDefaultMethodRef);
+  gbt->transport_stream_receiver->NotifyRecvInitialMetadata(
+      gbs->tx_code, kInitialMetadataWithMethodRef);
+
+  const std::string kMessage = kDefaultMessage;
+  gbt->transport_stream_receiver->NotifyRecvMessage(gbs->tx_code, kMessage);
+
+  Metadata trailing_metadata = kDefaultMetadata;
+  constexpr int kStatus = kDefaultStatus;
+  gbt->transport_stream_receiver->NotifyRecvTrailingMetadata(
+      gbs->tx_code, trailing_metadata, kStatus);
+  PerformStreamOp(gbs, &op);
+  grpc_core::ExecCtx::Get()->Flush();
+  recv_trailing_metadata.notification.WaitForNotification();
+
+  VerifyMetadataEqual(kInitialMetadataWithMethodRef,
+                      recv_initial_metadata.grpc_initial_metadata);
+  trailing_metadata.emplace_back("grpc-status", std::to_string(kStatus));
+  VerifyMetadataEqual(trailing_metadata,
+                      recv_trailing_metadata.grpc_trailing_metadata);
+  EXPECT_TRUE(recv_message.grpc_message->Next(SIZE_MAX, nullptr));
+  grpc_slice slice;
+  recv_message.grpc_message->Pull(&slice);
+  EXPECT_EQ(kMessage,
+            std::string(reinterpret_cast<char*>(GRPC_SLICE_START_PTR(slice)),
+                        GRPC_SLICE_LENGTH(slice)));
+  grpc_slice_unref_internal(slice);
+}
+
+TEST_F(BinderTransportTest, PerformAllOps) {
+  grpc_core::ExecCtx exec_ctx;
+  grpc_binder_stream* gbs = InitNewBinderStream();
+  grpc_transport_stream_op_batch op{};
+  grpc_transport_stream_op_batch_payload payload(nullptr);
+  op.payload = &payload;
+
+  const Metadata kSendInitialMetadata = kDefaultMetadata;
+  const std::string kMethodRef = kDefaultMethodRef;
+  MakeSendInitialMetadata send_initial_metadata(kSendInitialMetadata,
+                                                kMethodRef, &op);
+
+  const std::string kSendMessage = kDefaultMessage;
+  MakeSendMessage send_message(kSendMessage, &op);
+
+  // The wireformat guarantees that suffix metadata will always be empty.
+  // TODO(waynetu): Check whether gRPC can internally add extra trailing
+  // metadata.
+  const Metadata kSendTrailingMetadata = {};
+  MakeSendTrailingMetadata send_trailing_metadata(kSendTrailingMetadata, &op);
+
+  MockGrpcClosure mock_on_complete;
+  op.on_complete = mock_on_complete.GetGrpcClosure();
+
+  // TODO(waynetu): Currently, we simply drop the prefix '/' from the :path
+  // argument to obtain the method name. Update the test if this turns out to be
+  // incorrect.
+  EXPECT_CALL(GetWireWriter(),
+              RpcCall(TransactionMatches(
+                  kFlagPrefix | kFlagMessageData | kFlagSuffix,
+                  kMethodRef.substr(1), kSendInitialMetadata, kSendMessage)));
+  Expectation on_complete = EXPECT_CALL(mock_on_complete, Callback);
+
+  // Recv callbacks can happen after the on_complete callback.
+  MakeRecvInitialMetadata recv_initial_metadata(
+      &op, /* call_before = */ &on_complete);
+  MakeRecvMessage recv_message(&op, /* call_before = */ &on_complete);
+  MakeRecvTrailingMetadata recv_trailing_metadata(
+      &op, /* call_before = */ &on_complete);
+
+  PerformStreamOp(gbs, &op);
+
+  // Flush the execution context to force on_complete to run before recv
+  // callbacks get scheduled.
+  grpc_core::ExecCtx::Get()->Flush();
+
+  auto* gbt = reinterpret_cast<grpc_binder_transport*>(transport_);
+  const Metadata kRecvInitialMetadata =
+      AppendMethodRef(kDefaultMetadata, kDefaultMethodRef);
+  gbt->transport_stream_receiver->NotifyRecvInitialMetadata(
+      gbs->tx_code, kRecvInitialMetadata);
+  const std::string kRecvMessage = kDefaultMessage;
+  gbt->transport_stream_receiver->NotifyRecvMessage(gbs->tx_code, kRecvMessage);
+  const Metadata kRecvTrailingMetadata = kDefaultMetadata;
+  constexpr int kStatus = 0x1234;
+  gbt->transport_stream_receiver->NotifyRecvTrailingMetadata(
+      gbs->tx_code, kRecvTrailingMetadata, kStatus);
+
+  grpc_core::ExecCtx::Get()->Flush();
+  recv_initial_metadata.notification.WaitForNotification();
+  recv_message.notification.WaitForNotification();
+  recv_trailing_metadata.notification.WaitForNotification();
+
+  VerifyMetadataEqual(kRecvInitialMetadata,
+                      recv_initial_metadata.grpc_initial_metadata);
+  VerifyMetadataEqual(AppendStatus(kRecvTrailingMetadata, kStatus),
+                      recv_trailing_metadata.grpc_trailing_metadata);
+
+  EXPECT_TRUE(recv_message.grpc_message->Next(SIZE_MAX, nullptr));
+  grpc_slice slice;
+  recv_message.grpc_message->Pull(&slice);
+  EXPECT_EQ(kRecvMessage,
+            std::string(reinterpret_cast<char*>(GRPC_SLICE_START_PTR(slice)),
+                        GRPC_SLICE_LENGTH(slice)));
+  grpc_slice_unref_internal(slice);
+}
+
+TEST_F(BinderTransportTest, WireWriterRpcCallErrorPropagates) {
+  grpc_core::ExecCtx exec_ctx;
+  grpc_binder_stream* gbs = InitNewBinderStream();
+
+  MockGrpcClosure mock_on_complete1;
+  MockGrpcClosure mock_on_complete2;
+
+  EXPECT_CALL(GetWireWriter(), RpcCall)
+      .WillOnce(Return(absl::OkStatus()))
+      .WillOnce(Return(absl::InternalError("WireWriter::RpcCall failed")));
+  EXPECT_CALL(mock_on_complete1, Callback(GRPC_ERROR_NONE));
+  EXPECT_CALL(mock_on_complete2,
+              Callback(GrpcErrorMessageContains("WireWriter::RpcCall failed")));
+
+  const Metadata kInitialMetadata = {};
+  grpc_transport_stream_op_batch op1{};
+  grpc_transport_stream_op_batch_payload payload1(nullptr);
+  op1.payload = &payload1;
+  MakeSendInitialMetadata send_initial_metadata1(kInitialMetadata, "", &op1);
+  op1.on_complete = mock_on_complete1.GetGrpcClosure();
+
+  grpc_transport_stream_op_batch op2{};
+  grpc_transport_stream_op_batch_payload payload2(nullptr);
+  op2.payload = &payload2;
+  MakeSendInitialMetadata send_initial_metadata2(kInitialMetadata, "", &op2);
+  op2.on_complete = mock_on_complete2.GetGrpcClosure();
+
+  PerformStreamOp(gbs, &op1);
+  PerformStreamOp(gbs, &op2);
+  grpc_core::ExecCtx::Get()->Flush();
+}
+
+}  // namespace grpc_binder
+
+int main(int argc, char** argv) {
+  ::testing::InitGoogleTest(&argc, argv);
+  grpc::testing::TestEnvironment env(argc, argv);
+  return RUN_ALL_TESTS();
+}
diff --git a/test/core/transport/binder/end2end/BUILD b/test/core/transport/binder/end2end/BUILD
new file mode 100644 (file)
index 0000000..15b242e
--- /dev/null
@@ -0,0 +1,129 @@
+# Copyright 2021 gRPC authors.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+load("//bazel:grpc_build_system.bzl", "grpc_cc_library", "grpc_cc_test", "grpc_package", "grpc_proto_library")
+
+licenses(["notice"])
+
+grpc_package(
+    name = "test/core/transport/binder/end2end",
+    visibility = "tests",
+)
+
+grpc_cc_library(
+    name = "fake_binder",
+    testonly = 1,
+    srcs = ["fake_binder.cc"],
+    hdrs = ["fake_binder.h"],
+    external_deps = [
+        "absl/memory",
+        "absl/random",
+        "absl/strings",
+        "absl/strings:str_format",
+        "absl/time",
+        "absl/types:variant",
+    ],
+    deps = [
+        "//:gpr_base",
+        "//src/core/ext/transport/binder/wire_format:binder",
+        "//src/core/ext/transport/binder/wire_format:wire_reader",
+    ],
+)
+
+grpc_cc_test(
+    name = "fake_binder_test",
+    srcs = ["fake_binder_test.cc"],
+    external_deps = [
+        "absl/strings",
+        "absl/time",
+        "gtest",
+    ],
+    language = "C++",
+    uses_polling = False,
+    deps = [
+        ":fake_binder",
+        "//test/core/util:grpc_test_util",
+    ],
+)
+
+grpc_cc_library(
+    name = "end2end_binder_channel",
+    testonly = 1,
+    srcs = ["testing_channel_create.cc"],
+    hdrs = ["testing_channel_create.h"],
+    external_deps = [],
+    deps = [
+        ":fake_binder",
+        "//:grpc++_base",
+        "//:grpc_base_c",
+        "//src/core/ext/transport/binder/transport:binder_transport",
+        "//src/core/ext/transport/binder/wire_format:wire_reader",
+    ],
+)
+
+grpc_proto_library(
+    name = "echo_grpc_proto",
+    srcs = ["echo.proto"],
+)
+
+grpc_cc_library(
+    name = "echo_service",
+    testonly = 1,
+    srcs = ["echo_service.cc"],
+    hdrs = ["echo_service.h"],
+    external_deps = [
+        "absl/strings",
+        "absl/strings:str_format",
+        "absl/time",
+    ],
+    deps = [
+        ":echo_grpc_proto",
+    ],
+)
+
+grpc_cc_test(
+    name = "end2end_binder_transport_test",
+    srcs = ["end2end_binder_transport_test.cc"],
+    external_deps = [
+        "absl/memory",
+        "absl/time",
+        "gtest",
+    ],
+    language = "C++",
+    deps = [
+        ":echo_service",
+        ":end2end_binder_channel",
+        ":fake_binder",
+        "//src/core/ext/transport/binder/transport:binder_transport",
+        "//src/core/ext/transport/binder/wire_format:wire_reader",
+        "//test/core/util:grpc_test_util",
+    ],
+)
+
+grpc_cc_test(
+    name = "binder_server_test",
+    srcs = ["binder_server_test.cc"],
+    external_deps = [
+        "gtest",
+    ],
+    deps = [
+        "//:grpc++",
+        "//src/core/ext/transport/binder/client:grpc_transport_binder_client_impl",
+        "//src/core/ext/transport/binder/server:grpc_transport_binder_server",
+        "//test/core/transport/binder/end2end:echo_service",
+        "//test/core/transport/binder/end2end:fake_binder",
+        "//test/core/util:grpc_test_util",
+        "//test/cpp/end2end:test_service_impl",
+    ],
+)
diff --git a/test/core/transport/binder/end2end/binder_server_test.cc b/test/core/transport/binder/end2end/binder_server_test.cc
new file mode 100644 (file)
index 0000000..46f5d1b
--- /dev/null
@@ -0,0 +1,208 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#include "src/core/ext/transport/binder/server/binder_server.h"
+
+#include <memory>
+#include <thread>
+#include <vector>
+
+#include <gtest/gtest.h>
+
+#include "absl/memory/memory.h"
+
+#include <grpcpp/grpcpp.h>
+#include <grpcpp/impl/grpc_library.h>
+
+#include "src/core/ext/transport/binder/client/channel_create_impl.h"
+#include "src/core/ext/transport/binder/server/binder_server.h"
+#include "src/core/ext/transport/binder/server/binder_server_credentials.h"
+#include "test/core/transport/binder/end2end/echo_service.h"
+#include "test/core/transport/binder/end2end/fake_binder.h"
+#include "test/core/util/test_config.h"
+#include "test/cpp/end2end/test_service_impl.h"
+
+namespace grpc {
+namespace testing {
+
+namespace {
+
+class BinderServerCredentialsImpl final : public ServerCredentials {
+ public:
+  int AddPortToServer(const std::string& addr, grpc_server* server) override {
+    return grpc_core::AddBinderPort(
+        addr, server,
+        [](grpc_binder::TransactionReceiver::OnTransactCb transact_cb) {
+          return absl::make_unique<
+              grpc_binder::end2end_testing::FakeTransactionReceiver>(
+              nullptr, std::move(transact_cb));
+        });
+  }
+
+  void SetAuthMetadataProcessor(
+      const std::shared_ptr<AuthMetadataProcessor>& /*processor*/) override {
+    GPR_ASSERT(false);
+  }
+
+ private:
+  bool IsInsecure() const override { return true; }
+};
+
+}  // namespace
+
+std::shared_ptr<ServerCredentials> BinderServerCredentials() {
+  return std::shared_ptr<ServerCredentials>(new BinderServerCredentialsImpl());
+}
+
+std::shared_ptr<grpc::Channel> CreateBinderChannel(
+    std::unique_ptr<grpc_binder::Binder> endpoint_binder) {
+  grpc::internal::GrpcLibrary init_lib;
+  init_lib.init();
+
+  return grpc::CreateChannelInternal(
+      "",
+      grpc::internal::CreateChannelFromBinderImpl(std::move(endpoint_binder),
+                                                  nullptr),
+      std::vector<std::unique_ptr<
+          grpc::experimental::ClientInterceptorFactoryInterface>>());
+}
+
+}  // namespace testing
+}  // namespace grpc
+
+namespace {
+
+class BinderServerTest : public ::testing::Test {
+ public:
+  BinderServerTest() {
+    grpc_binder::end2end_testing::g_transaction_processor =
+        new grpc_binder::end2end_testing::TransactionProcessor();
+  }
+  ~BinderServerTest() override {
+    delete grpc_binder::end2end_testing::g_transaction_processor;
+  }
+  static void SetUpTestSuite() { grpc_init(); }
+  static void TearDownTestSuite() { grpc_shutdown(); }
+};
+
+#ifndef GPR_ANDROID
+TEST(BinderServerCredentialsTest, FailedInNonAndroidEnvironments) {
+  grpc::ServerBuilder server_builder;
+  grpc::testing::TestServiceImpl service;
+  server_builder.RegisterService(&service);
+  server_builder.AddListeningPort(
+      "binder://fail", grpc::experimental::BinderServerCredentials());
+  EXPECT_EQ(server_builder.BuildAndStart(), nullptr);
+}
+#endif  // !GPR_ANDROID
+
+TEST_F(BinderServerTest, BuildAndStart) {
+  grpc::ServerBuilder server_builder;
+  grpc_binder::end2end_testing::EchoServer service;
+  server_builder.RegisterService(&service);
+  server_builder.AddListeningPort("binder://example.service",
+                                  grpc::testing::BinderServerCredentials());
+  std::unique_ptr<grpc::Server> server = server_builder.BuildAndStart();
+  EXPECT_NE(grpc::experimental::binder::GetEndpointBinder("example.service"),
+            nullptr);
+  server->Shutdown();
+  EXPECT_EQ(grpc::experimental::binder::GetEndpointBinder("example.service"),
+            nullptr);
+}
+
+TEST_F(BinderServerTest, BuildAndStartFailed) {
+  grpc::ServerBuilder server_builder;
+  grpc_binder::end2end_testing::EchoServer service;
+  server_builder.RegisterService(&service);
+  // Error: binder address should begin with binder:
+  server_builder.AddListeningPort("localhost:12345",
+                                  grpc::testing::BinderServerCredentials());
+  std::unique_ptr<grpc::Server> server = server_builder.BuildAndStart();
+  EXPECT_EQ(server, nullptr);
+}
+
+TEST_F(BinderServerTest, CreateChannelWithEndpointBinder) {
+  grpc::ServerBuilder server_builder;
+  grpc_binder::end2end_testing::EchoServer service;
+  server_builder.RegisterService(&service);
+  server_builder.AddListeningPort("binder://example.service",
+                                  grpc::testing::BinderServerCredentials());
+  std::unique_ptr<grpc::Server> server = server_builder.BuildAndStart();
+  void* raw_endpoint_binder =
+      grpc::experimental::binder::GetEndpointBinder("example.service");
+  std::unique_ptr<grpc_binder::Binder> endpoint_binder =
+      absl::make_unique<grpc_binder::end2end_testing::FakeBinder>(
+          static_cast<grpc_binder::end2end_testing::FakeEndpoint*>(
+              raw_endpoint_binder));
+  std::shared_ptr<grpc::Channel> channel =
+      grpc::testing::CreateBinderChannel(std::move(endpoint_binder));
+  std::unique_ptr<grpc_binder::end2end_testing::EchoService::Stub> stub =
+      grpc_binder::end2end_testing::EchoService::NewStub(channel);
+  grpc_binder::end2end_testing::EchoRequest request;
+  grpc_binder::end2end_testing::EchoResponse response;
+  grpc::ClientContext context;
+  request.set_text("BinderServerBuilder");
+  grpc::Status status = stub->EchoUnaryCall(&context, request, &response);
+  EXPECT_TRUE(status.ok());
+  EXPECT_EQ(response.text(), "BinderServerBuilder");
+  server->Shutdown();
+}
+
+TEST_F(BinderServerTest, CreateChannelWithEndpointBinderMultipleConnections) {
+  grpc::ServerBuilder server_builder;
+  grpc_binder::end2end_testing::EchoServer service;
+  server_builder.RegisterService(&service);
+  server_builder.AddListeningPort(
+      "binder://example.service.multiple.connections",
+      grpc::testing::BinderServerCredentials());
+  std::unique_ptr<grpc::Server> server = server_builder.BuildAndStart();
+  void* raw_endpoint_binder = grpc::experimental::binder::GetEndpointBinder(
+      "example.service.multiple.connections");
+  constexpr size_t kNumThreads = 128;
+
+  auto thread_fn = [&](size_t id) {
+    std::unique_ptr<grpc_binder::Binder> endpoint_binder =
+        absl::make_unique<grpc_binder::end2end_testing::FakeBinder>(
+            static_cast<grpc_binder::end2end_testing::FakeEndpoint*>(
+                raw_endpoint_binder));
+    std::shared_ptr<grpc::Channel> channel =
+        grpc::testing::CreateBinderChannel(std::move(endpoint_binder));
+    std::unique_ptr<grpc_binder::end2end_testing::EchoService::Stub> stub =
+        grpc_binder::end2end_testing::EchoService::NewStub(channel);
+    grpc_binder::end2end_testing::EchoRequest request;
+    grpc_binder::end2end_testing::EchoResponse response;
+    grpc::ClientContext context;
+    request.set_text(absl::StrFormat("BinderServerBuilder-%d", id));
+    grpc::Status status = stub->EchoUnaryCall(&context, request, &response);
+    EXPECT_TRUE(status.ok());
+    EXPECT_EQ(response.text(), absl::StrFormat("BinderServerBuilder-%d", id));
+  };
+
+  std::vector<std::thread> threads(kNumThreads);
+  for (size_t i = 0; i < kNumThreads; ++i) {
+    threads[i] = std::thread(thread_fn, i);
+  }
+  for (auto& thr : threads) {
+    thr.join();
+  }
+  server->Shutdown();
+}
+
+}  // namespace
+
+int main(int argc, char** argv) {
+  ::testing::InitGoogleTest(&argc, argv);
+  grpc::testing::TestEnvironment env(argc, argv);
+  return RUN_ALL_TESTS();
+}
diff --git a/test/core/transport/binder/end2end/echo.proto b/test/core/transport/binder/end2end/echo.proto
new file mode 100644 (file)
index 0000000..6669e1f
--- /dev/null
@@ -0,0 +1,38 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+// A simple RPC service that echos what the client passes in. The request and
+// the response simply contains the text represented in a string.
+//
+// This service is for end-to-end testing with fake binder tunnels.
+syntax = "proto3";
+
+// TODO(waynetu): This can be replaced by EchoTestService in
+// src/proto/grpc/testing/echo.proto
+package grpc_binder.end2end_testing;
+
+message EchoRequest {
+  string text = 1;
+}
+
+message EchoResponse {
+  string text = 1;
+}
+
+service EchoService {
+  rpc EchoUnaryCall(EchoRequest) returns (EchoResponse);
+  rpc EchoServerStreamingCall(EchoRequest) returns (stream EchoResponse);
+  rpc EchoClientStreamingCall(stream EchoRequest) returns (EchoResponse);
+  rpc EchoBiDirStreamingCall(stream EchoRequest) returns (stream EchoResponse);
+}
diff --git a/test/core/transport/binder/end2end/echo_service.cc b/test/core/transport/binder/end2end/echo_service.cc
new file mode 100644 (file)
index 0000000..def23f5
--- /dev/null
@@ -0,0 +1,83 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#include "test/core/transport/binder/end2end/echo_service.h"
+
+#include <string>
+
+#include "absl/strings/str_format.h"
+#include "absl/time/time.h"
+
+namespace grpc_binder {
+namespace end2end_testing {
+
+const absl::string_view EchoServer::kCancelledText = "cancel";
+const absl::string_view EchoServer::kTimeoutText = "timeout";
+const size_t EchoServer::kServerStreamingCounts = 100;
+
+grpc::Status EchoServer::EchoUnaryCall(grpc::ServerContext* /*context*/,
+                                       const EchoRequest* request,
+                                       EchoResponse* response) {
+  const std::string& data = request->text();
+  if (data == kCancelledText) {
+    return grpc::Status::CANCELLED;
+  }
+  if (data == kTimeoutText) {
+    absl::SleepFor(absl::Seconds(5));
+  }
+  response->set_text(data);
+  return grpc::Status::OK;
+}
+
+grpc::Status EchoServer::EchoServerStreamingCall(
+    grpc::ServerContext* /*context*/, const EchoRequest* request,
+    grpc::ServerWriter<EchoResponse>* writer) {
+  const std::string& data = request->text();
+  if (data == kTimeoutText) {
+    absl::SleepFor(absl::Seconds(5));
+  }
+  for (size_t i = 0; i < kServerStreamingCounts; ++i) {
+    EchoResponse response;
+    response.set_text(absl::StrFormat("%s(%d)", data, i));
+    writer->Write(response);
+  }
+  return grpc::Status::OK;
+}
+
+grpc::Status EchoServer::EchoClientStreamingCall(
+    grpc::ServerContext* /*context*/, grpc::ServerReader<EchoRequest>* reader,
+    EchoResponse* response) {
+  EchoRequest request;
+  std::string result = "";
+  while (reader->Read(&request)) {
+    result += request.text();
+  }
+  response->set_text(result);
+  return grpc::Status::OK;
+}
+
+grpc::Status EchoServer::EchoBiDirStreamingCall(
+    grpc::ServerContext* /*context*/,
+    grpc::ServerReaderWriter<EchoResponse, EchoRequest>* stream) {
+  EchoRequest request;
+  while (stream->Read(&request)) {
+    EchoResponse response;
+    response.set_text(request.text());
+    stream->Write(response);
+  }
+  return grpc::Status::OK;
+}
+
+}  // namespace end2end_testing
+}  // namespace grpc_binder
diff --git a/test/core/transport/binder/end2end/echo_service.h b/test/core/transport/binder/end2end/echo_service.h
new file mode 100644 (file)
index 0000000..1dbfe39
--- /dev/null
@@ -0,0 +1,52 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#ifndef TEST_CORE_TRANSPORT_BINDER_END2END_ECHO_SERVICE_H
+#define TEST_CORE_TRANSPORT_BINDER_END2END_ECHO_SERVICE_H
+
+#include "absl/strings/string_view.h"
+
+#include "test/core/transport/binder/end2end/echo.grpc.pb.h"
+
+namespace grpc_binder {
+namespace end2end_testing {
+
+// TODO(waynetu): Replace this with TestServiceImpl declared in
+// test/cpp/end2end/test_service_impl.h
+class EchoServer final : public EchoService::Service {
+ public:
+  static const absl::string_view kCancelledText;
+  static const absl::string_view kTimeoutText;
+
+  grpc::Status EchoUnaryCall(grpc::ServerContext* context,
+                             const EchoRequest* request,
+                             EchoResponse* response) override;
+
+  static const size_t kServerStreamingCounts;
+
+  grpc::Status EchoServerStreamingCall(
+      grpc::ServerContext* context, const EchoRequest* request,
+      grpc::ServerWriter<EchoResponse>* writer) override;
+  grpc::Status EchoClientStreamingCall(grpc::ServerContext* context,
+                                       grpc::ServerReader<EchoRequest>* reader,
+                                       EchoResponse* response) override;
+  grpc::Status EchoBiDirStreamingCall(
+      grpc::ServerContext* context,
+      grpc::ServerReaderWriter<EchoResponse, EchoRequest>* stream) override;
+};
+
+}  // namespace end2end_testing
+}  // namespace grpc_binder
+
+#endif  // TEST_CORE_TRANSPORT_BINDER_END2END_ECHO_SERVICE_H_
diff --git a/test/core/transport/binder/end2end/end2end_binder_transport_test.cc b/test/core/transport/binder/end2end/end2end_binder_transport_test.cc
new file mode 100644 (file)
index 0000000..b3bb4c2
--- /dev/null
@@ -0,0 +1,331 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#include <string>
+#include <thread>
+#include <utility>
+
+#include <gmock/gmock.h>
+#include <gtest/gtest.h>
+
+#include "absl/memory/memory.h"
+#include "absl/time/time.h"
+
+#include <grpcpp/grpcpp.h>
+
+#include "src/core/ext/transport/binder/transport/binder_transport.h"
+#include "src/core/ext/transport/binder/wire_format/wire_reader_impl.h"
+#include "test/core/transport/binder/end2end/echo_service.h"
+#include "test/core/transport/binder/end2end/fake_binder.h"
+#include "test/core/transport/binder/end2end/testing_channel_create.h"
+#include "test/core/util/test_config.h"
+
+namespace grpc_binder {
+
+namespace {
+
+class End2EndBinderTransportTest
+    : public ::testing::TestWithParam<absl::Duration> {
+ public:
+  End2EndBinderTransportTest() {
+    end2end_testing::g_transaction_processor =
+        new end2end_testing::TransactionProcessor(GetParam());
+  }
+
+  ~End2EndBinderTransportTest() override {
+    delete end2end_testing::g_transaction_processor;
+  }
+
+  static void SetUpTestSuite() { grpc_init(); }
+  static void TearDownTestSuite() { grpc_shutdown(); }
+
+  std::shared_ptr<grpc::Channel> BinderChannel(
+      grpc::Server* server, const grpc::ChannelArguments& args) {
+    return end2end_testing::BinderChannelForTesting(server, args);
+  }
+};
+
+using end2end_testing::EchoRequest;
+using end2end_testing::EchoResponse;
+using end2end_testing::EchoService;
+
+}  // namespace
+
+TEST_P(End2EndBinderTransportTest, SetupTransport) {
+  grpc_core::ExecCtx exec_ctx;
+  grpc_transport *client_transport, *server_transport;
+  std::tie(client_transport, server_transport) =
+      end2end_testing::CreateClientServerBindersPairForTesting();
+  EXPECT_NE(client_transport, nullptr);
+  EXPECT_NE(server_transport, nullptr);
+
+  grpc_transport_destroy(client_transport);
+  grpc_transport_destroy(server_transport);
+}
+
+TEST_P(End2EndBinderTransportTest, UnaryCallThroughFakeBinderChannel) {
+  grpc::ChannelArguments args;
+  grpc::ServerBuilder builder;
+  end2end_testing::EchoServer service;
+  builder.RegisterService(&service);
+  std::unique_ptr<grpc::Server> server = builder.BuildAndStart();
+  std::shared_ptr<grpc::Channel> channel = BinderChannel(server.get(), args);
+  std::unique_ptr<EchoService::Stub> stub = EchoService::NewStub(channel);
+  grpc::ClientContext context;
+  EchoRequest request;
+  EchoResponse response;
+  request.set_text("it works!");
+  grpc::Status status = stub->EchoUnaryCall(&context, request, &response);
+  EXPECT_TRUE(status.ok());
+  EXPECT_EQ(response.text(), "it works!");
+
+  server->Shutdown();
+}
+
+TEST_P(End2EndBinderTransportTest,
+       UnaryCallThroughFakeBinderChannelNonOkStatus) {
+  grpc::ChannelArguments args;
+  grpc::ServerBuilder builder;
+  end2end_testing::EchoServer service;
+  builder.RegisterService(&service);
+  std::unique_ptr<grpc::Server> server = builder.BuildAndStart();
+  std::shared_ptr<grpc::Channel> channel = BinderChannel(server.get(), args);
+  std::unique_ptr<EchoService::Stub> stub = EchoService::NewStub(channel);
+  grpc::ClientContext context;
+  EchoRequest request;
+  EchoResponse response;
+  request.set_text(std::string(end2end_testing::EchoServer::kCancelledText));
+  // Server will not response the client with message data, however, since all
+  // callbacks after the trailing metadata are cancelled, we shall not be
+  // blocked here.
+  grpc::Status status = stub->EchoUnaryCall(&context, request, &response);
+  EXPECT_FALSE(status.ok());
+
+  server->Shutdown();
+}
+
+TEST_P(End2EndBinderTransportTest,
+       UnaryCallThroughFakeBinderChannelServerTimeout) {
+  grpc::ChannelArguments args;
+  grpc::ServerBuilder builder;
+  end2end_testing::EchoServer service;
+  builder.RegisterService(&service);
+  std::unique_ptr<grpc::Server> server = builder.BuildAndStart();
+  std::shared_ptr<grpc::Channel> channel = BinderChannel(server.get(), args);
+  std::unique_ptr<EchoService::Stub> stub = EchoService::NewStub(channel);
+  grpc::ClientContext context;
+  context.set_deadline(absl::ToChronoTime(absl::Now() + absl::Seconds(1)));
+  EchoRequest request;
+  EchoResponse response;
+  request.set_text(std::string(end2end_testing::EchoServer::kTimeoutText));
+  grpc::Status status = stub->EchoUnaryCall(&context, request, &response);
+  EXPECT_FALSE(status.ok());
+  EXPECT_EQ(status.error_message(), "Deadline Exceeded");
+
+  server->Shutdown();
+}
+
+// Temporarily disabled due to a potential deadlock in our design.
+// TODO(waynetu): Enable this test once the issue is resolved.
+TEST_P(End2EndBinderTransportTest,
+       UnaryCallThroughFakeBinderChannelClientTimeout) {
+  grpc::ChannelArguments args;
+  grpc::ServerBuilder builder;
+  end2end_testing::EchoServer service;
+  builder.RegisterService(&service);
+  std::unique_ptr<grpc::Server> server = builder.BuildAndStart();
+  std::shared_ptr<grpc::Channel> channel = BinderChannel(server.get(), args);
+  std::unique_ptr<EchoService::Stub> stub = EchoService::NewStub(channel);
+
+  // Set transaction delay to a large number. This happens after the channel
+  // creation so that we don't need to wait that long for client and server to
+  // be connected.
+  end2end_testing::g_transaction_processor->SetDelay(absl::Seconds(5));
+
+  grpc::ClientContext context;
+  context.set_deadline(absl::ToChronoTime(absl::Now() + absl::Seconds(1)));
+  EchoRequest request;
+  EchoResponse response;
+  request.set_text("normal-text");
+  grpc::Status status = stub->EchoUnaryCall(&context, request, &response);
+  EXPECT_FALSE(status.ok());
+  EXPECT_EQ(status.error_message(), "Deadline Exceeded");
+
+  server->Shutdown();
+}
+
+TEST_P(End2EndBinderTransportTest,
+       ServerStreamingCallThroughFakeBinderChannel) {
+  grpc::ChannelArguments args;
+  grpc::ServerBuilder builder;
+  end2end_testing::EchoServer service;
+  builder.RegisterService(&service);
+  std::unique_ptr<grpc::Server> server = builder.BuildAndStart();
+  std::shared_ptr<grpc::Channel> channel = BinderChannel(server.get(), args);
+  std::unique_ptr<EchoService::Stub> stub = EchoService::NewStub(channel);
+  grpc::ClientContext context;
+  EchoRequest request;
+  request.set_text("it works!");
+  std::unique_ptr<grpc::ClientReader<EchoResponse>> reader =
+      stub->EchoServerStreamingCall(&context, request);
+  EchoResponse response;
+  size_t cnt = 0;
+  while (reader->Read(&response)) {
+    EXPECT_EQ(response.text(), absl::StrFormat("it works!(%d)", cnt));
+    cnt++;
+  }
+  EXPECT_EQ(cnt, end2end_testing::EchoServer::kServerStreamingCounts);
+  grpc::Status status = reader->Finish();
+  EXPECT_TRUE(status.ok());
+
+  server->Shutdown();
+}
+
+TEST_P(End2EndBinderTransportTest,
+       ServerStreamingCallThroughFakeBinderChannelServerTimeout) {
+  grpc::ChannelArguments args;
+  grpc::ServerBuilder builder;
+  end2end_testing::EchoServer service;
+  builder.RegisterService(&service);
+  std::unique_ptr<grpc::Server> server = builder.BuildAndStart();
+  std::shared_ptr<grpc::Channel> channel = BinderChannel(server.get(), args);
+  std::unique_ptr<EchoService::Stub> stub = EchoService::NewStub(channel);
+  grpc::ClientContext context;
+  context.set_deadline(absl::ToChronoTime(absl::Now() + absl::Seconds(1)));
+  EchoRequest request;
+  request.set_text(std::string(end2end_testing::EchoServer::kTimeoutText));
+  std::unique_ptr<grpc::ClientReader<EchoResponse>> reader =
+      stub->EchoServerStreamingCall(&context, request);
+  EchoResponse response;
+  EXPECT_FALSE(reader->Read(&response));
+  grpc::Status status = reader->Finish();
+  EXPECT_FALSE(status.ok());
+  EXPECT_EQ(status.error_message(), "Deadline Exceeded");
+
+  server->Shutdown();
+}
+
+TEST_P(End2EndBinderTransportTest,
+       ClientStreamingCallThroughFakeBinderChannel) {
+  grpc::ChannelArguments args;
+  grpc::ServerBuilder builder;
+  end2end_testing::EchoServer service;
+  builder.RegisterService(&service);
+  std::unique_ptr<grpc::Server> server = builder.BuildAndStart();
+  std::shared_ptr<grpc::Channel> channel = BinderChannel(server.get(), args);
+  std::unique_ptr<EchoService::Stub> stub = EchoService::NewStub(channel);
+  grpc::ClientContext context;
+  EchoResponse response;
+  std::unique_ptr<grpc::ClientWriter<EchoRequest>> writer =
+      stub->EchoClientStreamingCall(&context, &response);
+  constexpr size_t kClientStreamingCounts = 100;
+  std::string expected = "";
+  for (size_t i = 0; i < kClientStreamingCounts; ++i) {
+    EchoRequest request;
+    request.set_text(absl::StrFormat("it works!(%d)", i));
+    writer->Write(request);
+    expected += absl::StrFormat("it works!(%d)", i);
+  }
+  writer->WritesDone();
+  grpc::Status status = writer->Finish();
+  EXPECT_TRUE(status.ok());
+  EXPECT_EQ(response.text(), expected);
+
+  server->Shutdown();
+}
+
+TEST_P(End2EndBinderTransportTest, BiDirStreamingCallThroughFakeBinderChannel) {
+  grpc::ChannelArguments args;
+  grpc::ServerBuilder builder;
+  end2end_testing::EchoServer service;
+  builder.RegisterService(&service);
+  std::unique_ptr<grpc::Server> server = builder.BuildAndStart();
+  std::shared_ptr<grpc::Channel> channel = BinderChannel(server.get(), args);
+  std::unique_ptr<EchoService::Stub> stub = EchoService::NewStub(channel);
+  grpc::ClientContext context;
+  EchoResponse response;
+  std::shared_ptr<grpc::ClientReaderWriter<EchoRequest, EchoResponse>> stream =
+      stub->EchoBiDirStreamingCall(&context);
+  constexpr size_t kBiDirStreamingCounts = 100;
+
+  struct WriterArgs {
+    std::shared_ptr<grpc::ClientReaderWriter<EchoRequest, EchoResponse>> stream;
+    size_t bi_dir_streaming_counts;
+  } writer_args;
+
+  writer_args.stream = stream;
+  writer_args.bi_dir_streaming_counts = kBiDirStreamingCounts;
+
+  auto writer_fn = [](void* arg) {
+    const WriterArgs& args = *static_cast<WriterArgs*>(arg);
+    EchoResponse response;
+    for (size_t i = 0; i < args.bi_dir_streaming_counts; ++i) {
+      EchoRequest request;
+      request.set_text(absl::StrFormat("it works!(%d)", i));
+      args.stream->Write(request);
+    }
+    args.stream->WritesDone();
+  };
+
+  grpc_core::Thread writer_thread("writer-thread", writer_fn,
+                                  static_cast<void*>(&writer_args));
+  writer_thread.Start();
+  for (size_t i = 0; i < kBiDirStreamingCounts; ++i) {
+    EchoResponse response;
+    EXPECT_TRUE(stream->Read(&response));
+    EXPECT_EQ(response.text(), absl::StrFormat("it works!(%d)", i));
+  }
+  grpc::Status status = stream->Finish();
+  EXPECT_TRUE(status.ok());
+  writer_thread.Join();
+
+  server->Shutdown();
+}
+
+TEST_P(End2EndBinderTransportTest, LargeMessages) {
+  grpc::ChannelArguments args;
+  grpc::ServerBuilder builder;
+  end2end_testing::EchoServer service;
+  builder.RegisterService(&service);
+  std::unique_ptr<grpc::Server> server = builder.BuildAndStart();
+  std::shared_ptr<grpc::Channel> channel = BinderChannel(server.get(), args);
+  std::unique_ptr<EchoService::Stub> stub = EchoService::NewStub(channel);
+  for (size_t size = 1; size <= 1024 * 1024; size *= 4) {
+    grpc::ClientContext context;
+    EchoRequest request;
+    EchoResponse response;
+    request.set_text(std::string(size, 'a'));
+    grpc::Status status = stub->EchoUnaryCall(&context, request, &response);
+    EXPECT_TRUE(status.ok());
+    EXPECT_EQ(response.text().size(), size);
+    EXPECT_TRUE(std::all_of(response.text().begin(), response.text().end(),
+                            [](char c) { return c == 'a'; }));
+  }
+  server->Shutdown();
+}
+
+INSTANTIATE_TEST_SUITE_P(
+    End2EndBinderTransportTestWithDifferentDelayTimes,
+    End2EndBinderTransportTest,
+    testing::Values(absl::ZeroDuration(), absl::Nanoseconds(10),
+                    absl::Microseconds(10), absl::Microseconds(100),
+                    absl::Milliseconds(1), absl::Milliseconds(20)));
+
+}  // namespace grpc_binder
+
+int main(int argc, char** argv) {
+  ::testing::InitGoogleTest(&argc, argv);
+  grpc::testing::TestEnvironment env(argc, argv);
+  return RUN_ALL_TESTS();
+}
diff --git a/test/core/transport/binder/end2end/fake_binder.cc b/test/core/transport/binder/end2end/fake_binder.cc
new file mode 100644 (file)
index 0000000..b455f94
--- /dev/null
@@ -0,0 +1,293 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#include "test/core/transport/binder/end2end/fake_binder.h"
+
+#include <string>
+#include <utility>
+
+#include <grpc/support/log.h>
+
+namespace grpc_binder {
+namespace end2end_testing {
+
+TransactionProcessor* g_transaction_processor = nullptr;
+
+FakeWritableParcel::FakeWritableParcel() : data_(1) {}
+
+int32_t FakeWritableParcel::GetDataPosition() const { return data_position_; }
+
+int32_t FakeWritableParcel::GetDataSize() const { return data_size_; }
+
+absl::Status FakeWritableParcel::SetDataPosition(int32_t pos) {
+  if (data_.size() < static_cast<size_t>(pos) + 1) {
+    data_.resize(pos + 1);
+  }
+  data_position_ = pos;
+  return absl::OkStatus();
+}
+
+absl::Status FakeWritableParcel::WriteInt32(int32_t data) {
+  data_[data_position_] = data;
+  SetDataPosition(data_position_ + 1).IgnoreError();
+  data_size_ += 4;
+  return absl::OkStatus();
+}
+
+absl::Status FakeWritableParcel::WriteInt64(int64_t data) {
+  data_[data_position_] = data;
+  SetDataPosition(data_position_ + 1).IgnoreError();
+  data_size_ += 8;
+  return absl::OkStatus();
+}
+
+absl::Status FakeWritableParcel::WriteBinder(HasRawBinder* binder) {
+  data_[data_position_] = binder->GetRawBinder();
+  SetDataPosition(data_position_ + 1).IgnoreError();
+  data_size_ += 8;
+  return absl::OkStatus();
+}
+
+absl::Status FakeWritableParcel::WriteString(absl::string_view s) {
+  data_[data_position_] = std::string(s);
+  SetDataPosition(data_position_ + 1).IgnoreError();
+  data_size_ += s.size();
+  return absl::OkStatus();
+}
+
+absl::Status FakeWritableParcel::WriteByteArray(const int8_t* buffer,
+                                                int32_t length) {
+  data_[data_position_] = std::vector<int8_t>(buffer, buffer + length);
+  SetDataPosition(data_position_ + 1).IgnoreError();
+  data_size_ += length;
+  return absl::OkStatus();
+}
+
+int32_t FakeReadableParcel::GetDataSize() const { return data_size_; }
+
+absl::Status FakeReadableParcel::ReadInt32(int32_t* data) const {
+  if (data_position_ >= data_.size() ||
+      !absl::holds_alternative<int32_t>(data_[data_position_])) {
+    return absl::InternalError("ReadInt32 failed");
+  }
+  *data = absl::get<int32_t>(data_[data_position_++]);
+  return absl::OkStatus();
+}
+
+absl::Status FakeReadableParcel::ReadInt64(int64_t* data) const {
+  if (data_position_ >= data_.size() ||
+      !absl::holds_alternative<int64_t>(data_[data_position_])) {
+    return absl::InternalError("ReadInt64 failed");
+  }
+  *data = absl::get<int64_t>(data_[data_position_++]);
+  return absl::OkStatus();
+}
+
+absl::Status FakeReadableParcel::ReadBinder(
+    std::unique_ptr<Binder>* data) const {
+  if (data_position_ >= data_.size() ||
+      !absl::holds_alternative<void*>(data_[data_position_])) {
+    return absl::InternalError("ReadBinder failed");
+  }
+  void* endpoint = absl::get<void*>(data_[data_position_++]);
+  if (!endpoint) return absl::InternalError("ReadBinder failed");
+  *data = absl::make_unique<FakeBinder>(static_cast<FakeEndpoint*>(endpoint));
+  return absl::OkStatus();
+}
+
+absl::Status FakeReadableParcel::ReadString(char data[111]) const {
+  if (data_position_ >= data_.size() ||
+      !absl::holds_alternative<std::string>(data_[data_position_])) {
+    return absl::InternalError("ReadString failed");
+  }
+  const std::string& s = absl::get<std::string>(data_[data_position_++]);
+  if (s.size() >= 100) return absl::InternalError("ReadString failed");
+  std::memcpy(data, s.data(), s.size());
+  return absl::OkStatus();
+}
+
+absl::Status FakeReadableParcel::ReadByteArray(std::string* data) const {
+  if (data_position_ >= data_.size() ||
+      !absl::holds_alternative<std::vector<int8_t>>(data_[data_position_])) {
+    return absl::InternalError("ReadByteArray failed");
+  }
+  const std::vector<int8_t>& byte_array =
+      absl::get<std::vector<int8_t>>(data_[data_position_++]);
+  data->resize(byte_array.size());
+  for (size_t i = 0; i < byte_array.size(); ++i) {
+    (*data)[i] = byte_array[i];
+  }
+  return absl::OkStatus();
+}
+
+absl::Status FakeBinder::Transact(BinderTransportTxCode tx_code) {
+  endpoint_->tunnel->EnQueueTransaction(endpoint_->other_end, tx_code,
+                                        input_->MoveData());
+  return absl::OkStatus();
+}
+
+FakeTransactionReceiver::FakeTransactionReceiver(
+    grpc_core::RefCountedPtr<WireReader> wire_reader_ref,
+    TransactionReceiver::OnTransactCb transact_cb) {
+  persistent_tx_receiver_ = &g_transaction_processor->NewPersistentTxReceiver(
+      std::move(wire_reader_ref), std::move(transact_cb),
+      absl::make_unique<FakeBinderTunnel>());
+}
+
+std::unique_ptr<TransactionReceiver> FakeBinder::ConstructTxReceiver(
+    grpc_core::RefCountedPtr<WireReader> wire_reader_ref,
+    TransactionReceiver::OnTransactCb cb) const {
+  return absl::make_unique<FakeTransactionReceiver>(wire_reader_ref, cb);
+}
+
+void* FakeTransactionReceiver::GetRawBinder() {
+  return persistent_tx_receiver_->tunnel_->GetSendEndpoint();
+}
+
+std::unique_ptr<Binder> FakeTransactionReceiver::GetSender() const {
+  return absl::make_unique<FakeBinder>(
+      persistent_tx_receiver_->tunnel_->GetSendEndpoint());
+}
+
+PersistentFakeTransactionReceiver::PersistentFakeTransactionReceiver(
+    grpc_core::RefCountedPtr<WireReader> wire_reader_ref,
+    TransactionReceiver::OnTransactCb cb,
+    std::unique_ptr<FakeBinderTunnel> tunnel)
+    : wire_reader_ref_(std::move(wire_reader_ref)),
+      callback_(std::move(cb)),
+      tunnel_(std::move(tunnel)) {
+  FakeEndpoint* recv_endpoint = tunnel_->GetRecvEndpoint();
+  recv_endpoint->owner = this;
+}
+
+TransactionProcessor::TransactionProcessor(absl::Duration delay)
+    : delay_nsec_(absl::ToInt64Nanoseconds(delay)),
+      tx_thread_(
+          "process-thread",
+          [](void* arg) {
+            auto* self = static_cast<TransactionProcessor*>(arg);
+            self->ProcessLoop();
+          },
+          this),
+      terminated_(false) {
+  tx_thread_.Start();
+}
+
+void TransactionProcessor::SetDelay(absl::Duration delay) {
+  delay_nsec_ = absl::ToInt64Nanoseconds(delay);
+}
+
+void TransactionProcessor::Terminate() {
+  if (!terminated_.load(std::memory_order_seq_cst)) {
+    gpr_log(GPR_INFO, "Terminating the processor");
+    terminated_.store(true, std::memory_order_seq_cst);
+    tx_thread_.Join();
+    gpr_log(GPR_INFO, "Processor terminated");
+  }
+}
+
+void TransactionProcessor::WaitForNextTransaction() {
+  absl::Time now = absl::Now();
+  if (now < deliver_time_) {
+    absl::Duration diff = deliver_time_ - now;
+    // Release the lock before going to sleep.
+    mu_.Unlock();
+    absl::SleepFor(diff);
+    mu_.Lock();
+  }
+}
+
+void TransactionProcessor::Flush() {
+  while (true) {
+    FakeEndpoint* target = nullptr;
+    BinderTransportTxCode tx_code{};
+    FakeData data;
+    mu_.Lock();
+    if (tx_queue_.empty()) {
+      mu_.Unlock();
+      break;
+    }
+    WaitForNextTransaction();
+    std::tie(target, tx_code, data) = std::move(tx_queue_.front());
+    tx_queue_.pop();
+    if (!tx_queue_.empty()) {
+      deliver_time_ = absl::Now() + GetRandomDelay();
+    }
+    mu_.Unlock();
+    auto* tx_receiver =
+        static_cast<PersistentFakeTransactionReceiver*>(target->owner);
+    auto parcel = absl::make_unique<FakeReadableParcel>(std::move(data));
+    tx_receiver->Receive(tx_code, parcel.get()).IgnoreError();
+  }
+}
+
+void TransactionProcessor::ProcessLoop() {
+  while (!terminated_.load(std::memory_order_seq_cst)) {
+    FakeEndpoint* target = nullptr;
+    BinderTransportTxCode tx_code{};
+    FakeData data;
+    mu_.Lock();
+    if (tx_queue_.empty()) {
+      mu_.Unlock();
+      continue;
+    }
+    WaitForNextTransaction();
+    std::tie(target, tx_code, data) = std::move(tx_queue_.front());
+    tx_queue_.pop();
+    if (!tx_queue_.empty()) {
+      deliver_time_ = absl::Now() + GetRandomDelay();
+    }
+    mu_.Unlock();
+    auto* tx_receiver =
+        static_cast<PersistentFakeTransactionReceiver*>(target->owner);
+    auto parcel = absl::make_unique<FakeReadableParcel>(std::move(data));
+    tx_receiver->Receive(tx_code, parcel.get()).IgnoreError();
+  }
+  Flush();
+}
+
+absl::Duration TransactionProcessor::GetRandomDelay() {
+  int64_t delay =
+      absl::Uniform<int64_t>(bit_gen_, delay_nsec_ / 2, delay_nsec_);
+  return absl::Nanoseconds(delay);
+}
+
+void TransactionProcessor::EnQueueTransaction(FakeEndpoint* target,
+                                              BinderTransportTxCode tx_code,
+                                              FakeData data) {
+  grpc_core::MutexLock lock(&mu_);
+  if (tx_queue_.empty()) {
+    // This is the first transaction in the queue. Compute its deliver time.
+    deliver_time_ = absl::Now() + GetRandomDelay();
+  }
+  tx_queue_.emplace(target, tx_code, std::move(data));
+}
+
+FakeBinderTunnel::FakeBinderTunnel()
+    : send_endpoint_(absl::make_unique<FakeEndpoint>(this)),
+      recv_endpoint_(absl::make_unique<FakeEndpoint>(this)) {
+  send_endpoint_->other_end = recv_endpoint_.get();
+  recv_endpoint_->other_end = send_endpoint_.get();
+}
+
+std::pair<std::unique_ptr<Binder>, std::unique_ptr<TransactionReceiver>>
+NewBinderPair(TransactionReceiver::OnTransactCb transact_cb) {
+  auto tx_receiver = absl::make_unique<FakeTransactionReceiver>(
+      nullptr, std::move(transact_cb));
+  std::unique_ptr<Binder> sender = tx_receiver->GetSender();
+  return std::make_pair(std::move(sender), std::move(tx_receiver));
+}
+
+}  // namespace end2end_testing
+}  // namespace grpc_binder
diff --git a/test/core/transport/binder/end2end/fake_binder.h b/test/core/transport/binder/end2end/fake_binder.h
new file mode 100644 (file)
index 0000000..c18149b
--- /dev/null
@@ -0,0 +1,314 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+// A collection of fake objects that offers in-memory simulation of data
+// transmission from one binder to another.
+//
+// Once the implementation of Binder is changed from BinderAndroid to
+// FakeBinder, we'll be able to test and fuzz our end-to-end binder transport in
+// a non-Android environment.
+//
+// The following diagram shows the high-level overview of how the in-memory
+// simulation works (FakeReceiver means FakeTransactionReceiver).
+//
+//                                        thread boundary
+//                                                |
+//                                                |
+// ----------------           ----------------    |  receive
+// |  FakeBinder  |           | FakeReceiver | <--|----------------
+// ----------------           ----------------    |               |
+//        |                           ^           |   ------------------------
+//        | endpoint            owner |           |   | TransactionProcessor |
+//        |                           |           |   ------------------------
+//        v                           |           |               ^
+// ----------------           ----------------    |               |
+// | FakeEndpoint | --------> | FakeEndpoint | ---|----------------
+// ---------------- other_end ----------------    |  enqueue
+//       | ^                         ^ |          |
+//       | |           recv_endpoint | |          |
+//       | |                         | |
+//       | | send_endpoint           | |
+//       v |                         | v
+// -------------------------------------------
+// |             FakeBinderTunnel            |
+// -------------------------------------------
+
+#ifndef GRPC_TEST_CORE_TRANSPORT_BINDER_END2END_FAKE_BINDER_H
+#define GRPC_TEST_CORE_TRANSPORT_BINDER_END2END_FAKE_BINDER_H
+
+#include <atomic>
+#include <forward_list>
+#include <memory>
+#include <queue>
+#include <string>
+#include <thread>
+#include <tuple>
+#include <utility>
+#include <vector>
+
+#include "absl/memory/memory.h"
+#include "absl/random/random.h"
+#include "absl/strings/str_format.h"
+#include "absl/strings/string_view.h"
+#include "absl/time/time.h"
+#include "absl/types/variant.h"
+
+#include "src/core/ext/transport/binder/wire_format/binder.h"
+#include "src/core/ext/transport/binder/wire_format/wire_reader.h"
+#include "src/core/lib/gprpp/sync.h"
+#include "src/core/lib/gprpp/thd.h"
+
+namespace grpc_binder {
+namespace end2end_testing {
+
+using FakeData = std::vector<
+    absl::variant<int32_t, int64_t, void*, std::string, std::vector<int8_t>>>;
+
+// A fake writable parcel.
+//
+// It simulates the functionalities of a real writable parcel and stores all
+// written data in memory. The data can then be transferred by calling
+// MoveData().
+class FakeWritableParcel final : public WritableParcel {
+ public:
+  FakeWritableParcel();
+  int32_t GetDataPosition() const override;
+  int32_t GetDataSize() const override;
+  absl::Status SetDataPosition(int32_t pos) override;
+  absl::Status WriteInt32(int32_t data) override;
+  absl::Status WriteInt64(int64_t data) override;
+  absl::Status WriteBinder(HasRawBinder* binder) override;
+  absl::Status WriteString(absl::string_view s) override;
+  absl::Status WriteByteArray(const int8_t* buffer, int32_t length) override;
+
+  FakeData MoveData() { return std::move(data_); }
+
+ private:
+  FakeData data_;
+  size_t data_position_ = 0;
+  int32_t data_size_ = 0;
+};
+
+// A fake readable parcel.
+//
+// It takes in the data transferred from a FakeWritableParcel and provides
+// methods to retrieve those data in the receiving end.
+class FakeReadableParcel final : public ReadableParcel {
+ public:
+  explicit FakeReadableParcel(FakeData data) : data_(std::move(data)) {
+    for (auto& d : data_) {
+      if (absl::holds_alternative<int32_t>(d)) {
+        data_size_ += 4;
+      } else if (absl::holds_alternative<int64_t>(d)) {
+        data_size_ += 8;
+      } else if (absl::holds_alternative<void*>(d)) {
+        data_size_ += 8;
+      } else if (absl::holds_alternative<std::string>(d)) {
+        data_size_ += absl::get<std::string>(d).size();
+      } else {
+        data_size_ += absl::get<std::vector<int8_t>>(d).size();
+      }
+    }
+  }
+
+  int32_t GetDataSize() const override;
+  absl::Status ReadInt32(int32_t* data) const override;
+  absl::Status ReadInt64(int64_t* data) const override;
+  absl::Status ReadBinder(std::unique_ptr<Binder>* data) const override;
+  absl::Status ReadByteArray(std::string* data) const override;
+  absl::Status ReadString(char data[111]) const override;
+
+ private:
+  const FakeData data_;
+  mutable size_t data_position_ = 0;
+  int32_t data_size_ = 0;
+};
+
+class FakeBinder;
+class FakeBinderTunnel;
+
+// FakeEndpoint is a simple struct that holds the pointer to the other end, a
+// pointer to the tunnel and a pointer to its owner. This tells the owner where
+// the data should be sent.
+struct FakeEndpoint {
+  explicit FakeEndpoint(FakeBinderTunnel* tunnel) : tunnel(tunnel) {}
+
+  FakeEndpoint* other_end;
+  FakeBinderTunnel* tunnel;
+  // The owner is either a FakeBinder (the sending part) or a
+  // FakeTransactionReceiver (the receiving part). Both parts hold an endpoint
+  // with |owner| pointing back to them and |other_end| pointing to each other.
+  void* owner;
+};
+
+class PersistentFakeTransactionReceiver;
+
+// A fake transaction receiver.
+//
+// This is the receiving part of a pair of binders. When constructed, a binder
+// tunnle is created, and the sending part can be retrieved by calling
+// GetSender().
+//
+// It also provides a Receive() function to simulate the on-transaction
+// callback of a real Android binder.
+class FakeTransactionReceiver : public TransactionReceiver {
+ public:
+  FakeTransactionReceiver(grpc_core::RefCountedPtr<WireReader> wire_reader_ref,
+                          TransactionReceiver::OnTransactCb cb);
+
+  void* GetRawBinder() override;
+
+  std::unique_ptr<Binder> GetSender() const;
+
+ private:
+  PersistentFakeTransactionReceiver* persistent_tx_receiver_;
+};
+
+// A "persistent" version of the FakeTransactionReceiver. That is, its lifetime
+// is managed by the processor and it outlives the wire reader and
+// grpc_binder_transport, so we can safely dereference a pointer to it in
+// ProcessLoop().
+class PersistentFakeTransactionReceiver {
+ public:
+  PersistentFakeTransactionReceiver(
+      grpc_core::RefCountedPtr<WireReader> wire_reader_ref,
+      TransactionReceiver::OnTransactCb cb,
+      std::unique_ptr<FakeBinderTunnel> tunnel);
+
+  absl::Status Receive(BinderTransportTxCode tx_code,
+                       const ReadableParcel* parcel) {
+    return callback_(static_cast<transaction_code_t>(tx_code), parcel);
+  }
+
+ private:
+  grpc_core::RefCountedPtr<WireReader> wire_reader_ref_;
+  TransactionReceiver::OnTransactCb callback_;
+  std::unique_ptr<FakeBinderTunnel> tunnel_;
+
+  friend class FakeTransactionReceiver;
+};
+
+// The sending part of a binders pair. It provides a FakeWritableParcel to the
+// user, and when Transact() is called, it transfers the written data to the
+// other end of the tunnel by following the information in its endpoint.
+class FakeBinder final : public Binder {
+ public:
+  explicit FakeBinder(FakeEndpoint* endpoint) : endpoint_(endpoint) {}
+
+  void Initialize() override {}
+  absl::Status PrepareTransaction() override {
+    input_ = absl::make_unique<FakeWritableParcel>();
+    return absl::OkStatus();
+  }
+
+  absl::Status Transact(BinderTransportTxCode tx_code) override;
+
+  WritableParcel* GetWritableParcel() const override { return input_.get(); }
+  ReadableParcel* GetReadableParcel() const override { return output_.get(); }
+
+  std::unique_ptr<TransactionReceiver> ConstructTxReceiver(
+      grpc_core::RefCountedPtr<WireReader> wire_reader_ref,
+      TransactionReceiver::OnTransactCb transact_cb) const override;
+
+  void* GetRawBinder() override { return endpoint_->other_end; }
+
+ private:
+  FakeEndpoint* endpoint_;
+  std::unique_ptr<FakeWritableParcel> input_;
+  std::unique_ptr<FakeReadableParcel> output_;
+};
+
+// A transaction processor.
+//
+// Once constructed, it'll create a another thread that deliver in-coming
+// transactions to their destinations.
+class TransactionProcessor {
+ public:
+  explicit TransactionProcessor(absl::Duration delay = absl::ZeroDuration());
+  ~TransactionProcessor() { Terminate(); }
+
+  void SetDelay(absl::Duration delay);
+
+  void Terminate();
+  void ProcessLoop();
+  void Flush();
+
+  // Issue a transaction with |target| pointing to the target endpoint. The
+  // transactions will be delivered in the same order they're issued, possibly
+  // with random delay to simulate real-world situation.
+  void EnQueueTransaction(FakeEndpoint* target, BinderTransportTxCode tx_code,
+                          FakeData data);
+
+  PersistentFakeTransactionReceiver& NewPersistentTxReceiver(
+      grpc_core::RefCountedPtr<WireReader> wire_reader_ref,
+      TransactionReceiver::OnTransactCb cb,
+      std::unique_ptr<FakeBinderTunnel> tunnel) {
+    grpc_core::MutexLock lock(&tx_receiver_mu_);
+    storage_.emplace_front(wire_reader_ref, cb, std::move(tunnel));
+    return storage_.front();
+  }
+
+ private:
+  absl::Duration GetRandomDelay();
+  void WaitForNextTransaction() ABSL_EXCLUSIVE_LOCKS_REQUIRED(mu_);
+
+  grpc_core::Mutex mu_;
+  std::queue<std::tuple<FakeEndpoint*, BinderTransportTxCode, FakeData>>
+      tx_queue_ ABSL_GUARDED_BY(mu_);
+  absl::Time deliver_time_ ABSL_GUARDED_BY(mu_);
+  int64_t delay_nsec_;
+  absl::BitGen bit_gen_;
+  grpc_core::Thread tx_thread_;
+  std::atomic<bool> terminated_;
+
+  grpc_core::Mutex tx_receiver_mu_;
+  // Use forward_list to avoid invalid pointers resulted by reallocation in
+  // containers such as std::vector.
+  std::forward_list<PersistentFakeTransactionReceiver> storage_
+      ABSL_GUARDED_BY(tx_receiver_mu_);
+};
+
+// The global (shared) processor. Test suite should be responsible of
+// creating/deleting it.
+extern TransactionProcessor* g_transaction_processor;
+
+// A binder tunnel.
+//
+// It is a simple helper that creates and links two endpoints.
+class FakeBinderTunnel {
+ public:
+  FakeBinderTunnel();
+
+  void EnQueueTransaction(FakeEndpoint* target, BinderTransportTxCode tx_code,
+                          FakeData data) {
+    g_transaction_processor->EnQueueTransaction(target, tx_code,
+                                                std::move(data));
+  }
+
+  FakeEndpoint* GetSendEndpoint() const { return send_endpoint_.get(); }
+  FakeEndpoint* GetRecvEndpoint() const { return recv_endpoint_.get(); }
+
+ private:
+  std::unique_ptr<FakeEndpoint> send_endpoint_;
+  std::unique_ptr<FakeEndpoint> recv_endpoint_;
+};
+
+// A helper function for constructing a pair of connected binders.
+std::pair<std::unique_ptr<Binder>, std::unique_ptr<TransactionReceiver>>
+NewBinderPair(TransactionReceiver::OnTransactCb transact_cb);
+
+}  // namespace end2end_testing
+}  // namespace grpc_binder
+
+#endif  // GRPC_TEST_CORE_TRANSPORT_BINDER_END2END_FAKE_BINDER_H
diff --git a/test/core/transport/binder/end2end/fake_binder_test.cc b/test/core/transport/binder/end2end/fake_binder_test.cc
new file mode 100644 (file)
index 0000000..b02e8bc
--- /dev/null
@@ -0,0 +1,375 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#include "test/core/transport/binder/end2end/fake_binder.h"
+
+#include <algorithm>
+#include <random>
+#include <string>
+#include <utility>
+
+#include <gmock/gmock.h>
+#include <gtest/gtest.h>
+
+#include "absl/strings/str_format.h"
+#include "absl/time/time.h"
+
+#include "test/core/util/test_config.h"
+
+namespace grpc_binder {
+namespace end2end_testing {
+
+TEST(FakeBinderTestWithoutTransaction, WritableParcelDataPosition) {
+  std::unique_ptr<WritableParcel> parcel =
+      absl::make_unique<FakeWritableParcel>();
+  EXPECT_EQ(parcel->GetDataPosition(), 0);
+  EXPECT_TRUE(parcel->WriteInt32(0).ok());
+  EXPECT_EQ(parcel->GetDataPosition(), 1);
+  EXPECT_TRUE(parcel->WriteInt32(1).ok());
+  EXPECT_TRUE(parcel->WriteInt32(2).ok());
+  EXPECT_EQ(parcel->GetDataPosition(), 3);
+  EXPECT_TRUE(parcel->WriteString("").ok());
+  EXPECT_EQ(parcel->GetDataPosition(), 4);
+  EXPECT_TRUE(parcel->SetDataPosition(0).ok());
+  const char kBuffer[] = "test";
+  EXPECT_TRUE(parcel
+                  ->WriteByteArray(reinterpret_cast<const int8_t*>(kBuffer),
+                                   strlen(kBuffer))
+                  .ok());
+  EXPECT_EQ(parcel->GetDataPosition(), 1);
+  EXPECT_TRUE(parcel->SetDataPosition(100).ok());
+  EXPECT_EQ(parcel->GetDataPosition(), 100);
+}
+
+namespace {
+
+class FakeBinderTest : public ::testing::TestWithParam<absl::Duration> {
+ public:
+  FakeBinderTest() {
+    g_transaction_processor = new TransactionProcessor(GetParam());
+  }
+  ~FakeBinderTest() override { delete g_transaction_processor; }
+};
+
+}  // namespace
+
+TEST_P(FakeBinderTest, SendInt32) {
+  constexpr int kValue = 0x1234;
+  constexpr int kTxCode = 0x4321;
+  int called = 0;
+  std::unique_ptr<Binder> sender;
+  std::unique_ptr<TransactionReceiver> tx_receiver;
+  std::tie(sender, tx_receiver) = NewBinderPair(
+      [&](transaction_code_t tx_code, const ReadableParcel* parcel) {
+        EXPECT_EQ(tx_code, kTxCode);
+        int value = 0;
+        EXPECT_TRUE(parcel->ReadInt32(&value).ok());
+        EXPECT_EQ(value, kValue);
+        called++;
+        return absl::OkStatus();
+      });
+
+  EXPECT_TRUE(sender->PrepareTransaction().ok());
+  WritableParcel* parcel = sender->GetWritableParcel();
+  EXPECT_TRUE(parcel->WriteInt32(kValue).ok());
+  EXPECT_TRUE(sender->Transact(BinderTransportTxCode(kTxCode)).ok());
+
+  g_transaction_processor->Terminate();
+  EXPECT_EQ(called, 1);
+}
+
+TEST_P(FakeBinderTest, SendString) {
+  constexpr char kValue[] = "example-string";
+  constexpr int kTxCode = 0x4321;
+  int called = 0;
+  std::unique_ptr<Binder> sender;
+  std::unique_ptr<TransactionReceiver> tx_receiver;
+  std::tie(sender, tx_receiver) = NewBinderPair(
+      [&](transaction_code_t tx_code, const ReadableParcel* parcel) {
+        EXPECT_EQ(tx_code, kTxCode);
+        char value[111];
+        memset(value, 0, sizeof(value));
+        EXPECT_TRUE(parcel->ReadString(value).ok());
+        EXPECT_STREQ(value, kValue);
+        called++;
+        return absl::OkStatus();
+      });
+
+  EXPECT_TRUE(sender->PrepareTransaction().ok());
+  WritableParcel* parcel = sender->GetWritableParcel();
+  EXPECT_TRUE(parcel->WriteString(kValue).ok());
+  EXPECT_TRUE(sender->Transact(BinderTransportTxCode(kTxCode)).ok());
+
+  g_transaction_processor->Terminate();
+  EXPECT_EQ(called, 1);
+}
+
+TEST_P(FakeBinderTest, SendByteArray) {
+  constexpr char kValue[] = "example-byte-array";
+  constexpr int kTxCode = 0x4321;
+  int called = 0;
+  std::unique_ptr<Binder> sender;
+  std::unique_ptr<TransactionReceiver> tx_receiver;
+  std::tie(sender, tx_receiver) = NewBinderPair(
+      [&](transaction_code_t tx_code, const ReadableParcel* parcel) {
+        EXPECT_EQ(tx_code, kTxCode);
+        std::string value;
+        EXPECT_TRUE(parcel->ReadByteArray(&value).ok());
+        EXPECT_EQ(value, kValue);
+        called++;
+        return absl::OkStatus();
+      });
+
+  EXPECT_TRUE(sender->PrepareTransaction().ok());
+  WritableParcel* parcel = sender->GetWritableParcel();
+  EXPECT_TRUE(parcel
+                  ->WriteByteArray(reinterpret_cast<const int8_t*>(kValue),
+                                   strlen(kValue))
+                  .ok());
+  EXPECT_TRUE(sender->Transact(BinderTransportTxCode(kTxCode)).ok());
+
+  g_transaction_processor->Terminate();
+  EXPECT_EQ(called, 1);
+}
+
+TEST_P(FakeBinderTest, SendMultipleItems) {
+  constexpr char kByteArray[] = "example-byte-array";
+  constexpr char kString[] = "example-string";
+  constexpr int kValue = 0x1234;
+  constexpr int kTxCode = 0x4321;
+  int called = 0;
+  std::unique_ptr<Binder> sender;
+  std::unique_ptr<TransactionReceiver> tx_receiver;
+  std::tie(sender, tx_receiver) = NewBinderPair(
+      [&](transaction_code_t tx_code, const ReadableParcel* parcel) {
+        int value_result;
+        EXPECT_EQ(tx_code, kTxCode);
+        EXPECT_TRUE(parcel->ReadInt32(&value_result).ok());
+        EXPECT_EQ(value_result, kValue);
+        std::string byte_array_result;
+        EXPECT_TRUE(parcel->ReadByteArray(&byte_array_result).ok());
+        EXPECT_EQ(byte_array_result, kByteArray);
+        char string_result[111];
+        memset(string_result, 0, sizeof(string_result));
+        EXPECT_TRUE(parcel->ReadString(string_result).ok());
+        EXPECT_STREQ(string_result, kString);
+        called++;
+        return absl::OkStatus();
+      });
+
+  EXPECT_TRUE(sender->PrepareTransaction().ok());
+  WritableParcel* parcel = sender->GetWritableParcel();
+  EXPECT_TRUE(parcel->WriteInt32(kValue).ok());
+  EXPECT_TRUE(parcel
+                  ->WriteByteArray(reinterpret_cast<const int8_t*>(kByteArray),
+                                   strlen(kByteArray))
+                  .ok());
+  EXPECT_TRUE(parcel->WriteString(kString).ok());
+  EXPECT_TRUE(sender->Transact(BinderTransportTxCode(kTxCode)).ok());
+
+  g_transaction_processor->Terminate();
+  EXPECT_EQ(called, 1);
+}
+
+TEST_P(FakeBinderTest, SendBinder) {
+  constexpr int kValue = 0x1234;
+  constexpr int kTxCode = 0x4321;
+  int called = 0;
+  std::unique_ptr<Binder> sender;
+  std::unique_ptr<TransactionReceiver> tx_receiver;
+  std::tie(sender, tx_receiver) = NewBinderPair(
+      [&](transaction_code_t tx_code, const ReadableParcel* parcel) {
+        EXPECT_EQ(tx_code, kTxCode);
+        std::unique_ptr<Binder> binder;
+        EXPECT_TRUE(parcel->ReadBinder(&binder).ok());
+        EXPECT_TRUE(binder->PrepareTransaction().ok());
+        WritableParcel* writable_parcel = binder->GetWritableParcel();
+        EXPECT_TRUE(writable_parcel->WriteInt32(kValue).ok());
+        EXPECT_TRUE(binder->Transact(BinderTransportTxCode(kTxCode + 1)).ok());
+        called++;
+        return absl::OkStatus();
+      });
+
+  int called2 = 0;
+  std::unique_ptr<TransactionReceiver> tx_receiver2 =
+      absl::make_unique<FakeTransactionReceiver>(
+          nullptr,
+          [&](transaction_code_t tx_code, const ReadableParcel* parcel) {
+            int value;
+            EXPECT_TRUE(parcel->ReadInt32(&value).ok());
+            EXPECT_EQ(value, kValue);
+            EXPECT_EQ(tx_code, kTxCode + 1);
+            called2++;
+            return absl::OkStatus();
+          });
+  EXPECT_TRUE(sender->PrepareTransaction().ok());
+  WritableParcel* parcel = sender->GetWritableParcel();
+  EXPECT_TRUE(parcel->WriteBinder(tx_receiver2.get()).ok());
+  EXPECT_TRUE(sender->Transact(BinderTransportTxCode(kTxCode)).ok());
+
+  g_transaction_processor->Terminate();
+  EXPECT_EQ(called, 1);
+  EXPECT_EQ(called2, 1);
+}
+
+TEST_P(FakeBinderTest, SendTransactionAfterDestruction) {
+  constexpr int kValue = 0x1234;
+  constexpr int kTxCode = 0x4321;
+  std::unique_ptr<Binder> sender;
+  int called = 0;
+  {
+    std::unique_ptr<TransactionReceiver> tx_receiver;
+    std::tie(sender, tx_receiver) = NewBinderPair(
+        [&](transaction_code_t tx_code, const ReadableParcel* parcel) {
+          EXPECT_EQ(tx_code, kTxCode);
+          int value;
+          EXPECT_TRUE(parcel->ReadInt32(&value).ok());
+          EXPECT_EQ(value, kValue + called);
+          called++;
+          return absl::OkStatus();
+        });
+    EXPECT_TRUE(sender->PrepareTransaction().ok());
+    WritableParcel* parcel = sender->GetWritableParcel();
+    EXPECT_TRUE(parcel->WriteInt32(kValue).ok());
+    EXPECT_TRUE(sender->Transact(BinderTransportTxCode(kTxCode)).ok());
+  }
+  // tx_receiver gets destructed here. This additional transaction should
+  // *still* be received.
+  EXPECT_TRUE(sender->PrepareTransaction().ok());
+  WritableParcel* parcel = sender->GetWritableParcel();
+  EXPECT_TRUE(parcel->WriteInt32(kValue + 1).ok());
+  EXPECT_TRUE(sender->Transact(BinderTransportTxCode(kTxCode)).ok());
+
+  g_transaction_processor->Terminate();
+  EXPECT_EQ(called, 2);
+}
+
+namespace {
+
+struct ThreadArgument {
+  int tid;
+  std::vector<std::vector<std::pair<std::unique_ptr<Binder>,
+                                    std::unique_ptr<TransactionReceiver>>>>*
+      global_binder_pairs;
+  std::vector<std::vector<int>>* global_cnts;
+  int tx_code;
+  int num_pairs_per_thread;
+  int num_transactions_per_pair;
+  grpc_core::Mutex* mu;
+};
+
+}  // namespace
+
+// Verify that this system works correctly in a concurrent environment.
+//
+// In end-to-end tests, there will be at least two threads, one from client to
+// server and vice versa. Thus, it's important for us to make sure that the
+// simulation is correct in such setup.
+TEST_P(FakeBinderTest, StressTest) {
+  constexpr int kTxCode = 0x4321;
+  constexpr int kNumThreads = 16;
+  constexpr int kNumPairsPerThread = 128;
+  constexpr int kNumTransactionsPerPair = 128;
+  std::vector<ThreadArgument> args(kNumThreads);
+
+  grpc_core::Mutex mu;
+  std::vector<std::vector<
+      std::pair<std::unique_ptr<Binder>, std::unique_ptr<TransactionReceiver>>>>
+      global_binder_pairs(kNumThreads);
+  std::vector<std::vector<int>> global_cnts(
+      kNumThreads, std::vector<int>(kNumPairsPerThread, 0));
+
+  auto th_function = [](void* arg) {
+    ThreadArgument* th_arg = static_cast<ThreadArgument*>(arg);
+    int tid = th_arg->tid;
+    std::vector<std::pair<std::unique_ptr<Binder>,
+                          std::unique_ptr<TransactionReceiver>>>
+        binder_pairs;
+    for (int p = 0; p < th_arg->num_pairs_per_thread; ++p) {
+      std::unique_ptr<Binder> binder;
+      std::unique_ptr<TransactionReceiver> tx_receiver;
+      int expected_tx_code = th_arg->tx_code;
+      std::vector<std::vector<int>>* cnt = th_arg->global_cnts;
+      std::tie(binder, tx_receiver) =
+          NewBinderPair([tid, p, cnt, expected_tx_code](
+                            transaction_code_t tx_code,
+                            const ReadableParcel* parcel) mutable {
+            EXPECT_EQ(tx_code, expected_tx_code);
+            int value;
+            EXPECT_TRUE(parcel->ReadInt32(&value).ok());
+            EXPECT_EQ(tid, value);
+            EXPECT_TRUE(parcel->ReadInt32(&value).ok());
+            EXPECT_EQ(p, value);
+            EXPECT_TRUE(parcel->ReadInt32(&value).ok());
+            EXPECT_EQ((*cnt)[tid][p], value);
+            (*cnt)[tid][p]++;
+            return absl::OkStatus();
+          });
+      binder_pairs.emplace_back(std::move(binder), std::move(tx_receiver));
+    }
+    std::vector<int> order;
+    for (int i = 0; i < th_arg->num_pairs_per_thread; ++i) {
+      for (int j = 0; j < th_arg->num_transactions_per_pair; ++j) {
+        order.emplace_back(i);
+      }
+    }
+    std::mt19937 rng(tid);
+    std::shuffle(order.begin(), order.end(), rng);
+    std::vector<int> tx_cnt(th_arg->num_pairs_per_thread);
+    for (int p : order) {
+      EXPECT_TRUE(binder_pairs[p].first->PrepareTransaction().ok());
+      WritableParcel* parcel = binder_pairs[p].first->GetWritableParcel();
+      EXPECT_TRUE(parcel->WriteInt32(th_arg->tid).ok());
+      EXPECT_TRUE(parcel->WriteInt32(p).ok());
+      EXPECT_TRUE(parcel->WriteInt32(tx_cnt[p]++).ok());
+      EXPECT_TRUE(binder_pairs[p]
+                      .first->Transact(BinderTransportTxCode(th_arg->tx_code))
+                      .ok());
+    }
+    th_arg->mu->Lock();
+    (*th_arg->global_binder_pairs)[tid] = std::move(binder_pairs);
+    th_arg->mu->Unlock();
+  };
+
+  std::vector<grpc_core::Thread> thrs(kNumThreads);
+  std::vector<std::string> thr_names(kNumThreads);
+  for (int i = 0; i < kNumThreads; ++i) {
+    args[i].tid = i;
+    args[i].global_binder_pairs = &global_binder_pairs;
+    args[i].global_cnts = &global_cnts;
+    args[i].tx_code = kTxCode;
+    args[i].num_pairs_per_thread = kNumPairsPerThread;
+    args[i].num_transactions_per_pair = kNumTransactionsPerPair;
+    args[i].mu = &mu;
+    thr_names[i] = absl::StrFormat("thread-%d", i);
+    thrs[i] = grpc_core::Thread(thr_names[i].c_str(), th_function, &args[i]);
+  }
+  for (auto& th : thrs) th.Start();
+  for (auto& th : thrs) th.Join();
+  g_transaction_processor->Terminate();
+}
+
+INSTANTIATE_TEST_SUITE_P(FakeBinderTestWithDifferentDelayTimes, FakeBinderTest,
+                         testing::Values(absl::ZeroDuration(),
+                                         absl::Nanoseconds(10),
+                                         absl::Microseconds(10)));
+
+}  // namespace end2end_testing
+}  // namespace grpc_binder
+
+int main(int argc, char** argv) {
+  ::testing::InitGoogleTest(&argc, argv);
+  grpc::testing::TestEnvironment env(argc, argv);
+  return RUN_ALL_TESTS();
+}
diff --git a/test/core/transport/binder/end2end/testing_channel_create.cc b/test/core/transport/binder/end2end/testing_channel_create.cc
new file mode 100644 (file)
index 0000000..04f09f5
--- /dev/null
@@ -0,0 +1,126 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#include "test/core/transport/binder/end2end/testing_channel_create.h"
+
+#include <utility>
+
+#include "src/core/ext/transport/binder/transport/binder_transport.h"
+#include "src/core/ext/transport/binder/wire_format/wire_reader_impl.h"
+#include "src/core/lib/channel/channel_args.h"
+#include "src/core/lib/surface/channel.h"
+#include "src/core/lib/transport/error_utils.h"
+
+namespace grpc_binder {
+namespace end2end_testing {
+
+namespace {
+// Since we assume the first half of the transport setup is completed before the
+// server side enters WireReader::SetupTransport, we need this helper to wait
+// and finish that part of the negotiation for us.
+class ServerSetupTransportHelper {
+ public:
+  ServerSetupTransportHelper()
+      : wire_reader_(absl::make_unique<WireReaderImpl>(
+            /*transport_stream_receiver=*/nullptr, /*is_client=*/false)) {
+    std::tie(endpoint_binder_, tx_receiver_) = NewBinderPair(
+        [this](transaction_code_t tx_code, const ReadableParcel* parcel) {
+          return this->wire_reader_->ProcessTransaction(tx_code, parcel);
+        });
+  }
+  std::unique_ptr<Binder> WaitForClientBinder() {
+    return wire_reader_->RecvSetupTransport();
+  }
+
+  std::unique_ptr<Binder> GetEndpointBinderForClient() {
+    return std::move(endpoint_binder_);
+  }
+
+ private:
+  std::unique_ptr<WireReaderImpl> wire_reader_;
+  // The endpoint binder for client.
+  std::unique_ptr<Binder> endpoint_binder_;
+  std::unique_ptr<TransactionReceiver> tx_receiver_;
+};
+}  // namespace
+
+std::pair<grpc_transport*, grpc_transport*>
+CreateClientServerBindersPairForTesting() {
+  ServerSetupTransportHelper helper;
+  std::unique_ptr<Binder> endpoint_binder = helper.GetEndpointBinderForClient();
+  grpc_transport* client_transport = nullptr;
+
+  struct ThreadArgs {
+    std::unique_ptr<Binder> endpoint_binder;
+    grpc_transport** client_transport;
+  } args;
+
+  args.endpoint_binder = std::move(endpoint_binder);
+  args.client_transport = &client_transport;
+
+  grpc_core::Thread client_thread(
+      "client-thread",
+      [](void* arg) {
+        ThreadArgs* args = static_cast<ThreadArgs*>(arg);
+        std::unique_ptr<Binder> endpoint_binder =
+            std::move(args->endpoint_binder);
+        *args->client_transport =
+            grpc_create_binder_transport_client(std::move(endpoint_binder));
+      },
+      &args);
+  client_thread.Start();
+  grpc_transport* server_transport =
+      grpc_create_binder_transport_server(helper.WaitForClientBinder());
+  client_thread.Join();
+  return std::make_pair(client_transport, server_transport);
+}
+
+std::shared_ptr<grpc::Channel> BinderChannelForTesting(
+    grpc::Server* server, const grpc::ChannelArguments& args) {
+  grpc_channel_args channel_args = args.c_channel_args();
+  return grpc::CreateChannelInternal(
+      "",
+      grpc_binder_channel_create_for_testing(server->c_server(), &channel_args,
+                                             nullptr),
+      std::vector<std::unique_ptr<
+          grpc::experimental::ClientInterceptorFactoryInterface>>());
+}
+
+}  // namespace end2end_testing
+}  // namespace grpc_binder
+
+grpc_channel* grpc_binder_channel_create_for_testing(grpc_server* server,
+                                                     grpc_channel_args* args,
+                                                     void* /*reserved*/) {
+  grpc_core::ExecCtx exec_ctx;
+
+  grpc_arg default_authority_arg = grpc_channel_arg_string_create(
+      const_cast<char*>(GRPC_ARG_DEFAULT_AUTHORITY),
+      const_cast<char*>("test.authority"));
+  grpc_channel_args* client_args =
+      grpc_channel_args_copy_and_add(args, &default_authority_arg, 1);
+
+  grpc_transport *client_transport, *server_transport;
+  std::tie(client_transport, server_transport) =
+      grpc_binder::end2end_testing::CreateClientServerBindersPairForTesting();
+  grpc_error_handle error = server->core_server->SetupTransport(
+      server_transport, nullptr, args, nullptr);
+  GPR_ASSERT(error == GRPC_ERROR_NONE);
+  grpc_channel* channel =
+      grpc_channel_create("binder", client_args, GRPC_CLIENT_DIRECT_CHANNEL,
+                          client_transport, nullptr, 0, &error);
+  GPR_ASSERT(error == GRPC_ERROR_NONE);
+  grpc_channel_args_destroy(client_args);
+  return channel;
+}
diff --git a/test/core/transport/binder/end2end/testing_channel_create.h b/test/core/transport/binder/end2end/testing_channel_create.h
new file mode 100644 (file)
index 0000000..97058c3
--- /dev/null
@@ -0,0 +1,42 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#ifndef GRPC_TEST_CORE_TRANSPORT_BINDER_END2END_TESTING_CHANNEL_CREATE_H
+#define GRPC_TEST_CORE_TRANSPORT_BINDER_END2END_TESTING_CHANNEL_CREATE_H
+
+#include <utility>
+
+#include <grpcpp/grpcpp.h>
+
+#include "src/core/ext/transport/binder/transport/binder_transport.h"
+#include "src/core/lib/surface/server.h"
+#include "test/core/transport/binder/end2end/fake_binder.h"
+
+namespace grpc_binder {
+namespace end2end_testing {
+
+std::pair<grpc_transport*, grpc_transport*>
+CreateClientServerBindersPairForTesting();
+
+std::shared_ptr<grpc::Channel> BinderChannelForTesting(
+    grpc::Server* server, const grpc::ChannelArguments& args);
+
+}  // namespace end2end_testing
+}  // namespace grpc_binder
+
+grpc_channel* grpc_binder_channel_create_for_testing(grpc_server* server,
+                                                     grpc_channel_args* args,
+                                                     void* /*reserved*/);
+
+#endif  // GRPC_TEST_CORE_TRANSPORT_BINDER_END2END_TESTING_CHANNEL_CREATE_H
diff --git a/test/core/transport/binder/mock_objects.cc b/test/core/transport/binder/mock_objects.cc
new file mode 100644 (file)
index 0000000..98261b0
--- /dev/null
@@ -0,0 +1,57 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#include "test/core/transport/binder/mock_objects.h"
+
+#include <memory>
+
+#include "absl/memory/memory.h"
+
+namespace grpc_binder {
+
+using ::testing::Return;
+
+MockReadableParcel::MockReadableParcel() {
+  ON_CALL(*this, ReadBinder).WillByDefault([](std::unique_ptr<Binder>* binder) {
+    *binder = absl::make_unique<MockBinder>();
+    return absl::OkStatus();
+  });
+  ON_CALL(*this, ReadInt32).WillByDefault(Return(absl::OkStatus()));
+  ON_CALL(*this, ReadByteArray).WillByDefault(Return(absl::OkStatus()));
+  ON_CALL(*this, ReadString).WillByDefault(Return(absl::OkStatus()));
+}
+
+MockWritableParcel::MockWritableParcel() {
+  ON_CALL(*this, SetDataPosition).WillByDefault(Return(absl::OkStatus()));
+  ON_CALL(*this, WriteInt32).WillByDefault(Return(absl::OkStatus()));
+  ON_CALL(*this, WriteBinder).WillByDefault(Return(absl::OkStatus()));
+  ON_CALL(*this, WriteString).WillByDefault(Return(absl::OkStatus()));
+  ON_CALL(*this, WriteByteArray).WillByDefault(Return(absl::OkStatus()));
+}
+
+MockBinder::MockBinder() {
+  ON_CALL(*this, PrepareTransaction).WillByDefault(Return(absl::OkStatus()));
+  ON_CALL(*this, Transact).WillByDefault(Return(absl::OkStatus()));
+  ON_CALL(*this, GetWritableParcel).WillByDefault(Return(&mock_input_));
+  ON_CALL(*this, GetReadableParcel).WillByDefault(Return(&mock_output_));
+  ON_CALL(*this, ConstructTxReceiver)
+      .WillByDefault(
+          [this](grpc_core::RefCountedPtr<WireReader> /*wire_reader_ref*/,
+                 TransactionReceiver::OnTransactCb cb) {
+            return absl::make_unique<MockTransactionReceiver>(
+                cb, BinderTransportTxCode::SETUP_TRANSPORT, &mock_output_);
+          });
+}
+
+}  // namespace grpc_binder
diff --git a/test/core/transport/binder/mock_objects.h b/test/core/transport/binder/mock_objects.h
new file mode 100644 (file)
index 0000000..39f70c3
--- /dev/null
@@ -0,0 +1,116 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#ifndef GRPC_TEST_CORE_TRANSPORT_BINDER_MOCK_OBJECTS_H
+#define GRPC_TEST_CORE_TRANSPORT_BINDER_MOCK_OBJECTS_H
+
+#include <gmock/gmock.h>
+
+#include "src/core/ext/transport/binder/utils/transport_stream_receiver.h"
+#include "src/core/ext/transport/binder/wire_format/binder.h"
+#include "src/core/ext/transport/binder/wire_format/wire_reader.h"
+#include "src/core/ext/transport/binder/wire_format/wire_writer.h"
+
+namespace grpc_binder {
+
+class MockWritableParcel : public WritableParcel {
+ public:
+  MOCK_METHOD(int32_t, GetDataPosition, (), (const, override));
+  MOCK_METHOD(int32_t, GetDataSize, (), (const, override));
+  MOCK_METHOD(absl::Status, SetDataPosition, (int32_t), (override));
+  MOCK_METHOD(absl::Status, WriteInt32, (int32_t), (override));
+  MOCK_METHOD(absl::Status, WriteInt64, (int64_t), (override));
+  MOCK_METHOD(absl::Status, WriteBinder, (HasRawBinder*), (override));
+  MOCK_METHOD(absl::Status, WriteString, (absl::string_view), (override));
+  MOCK_METHOD(absl::Status, WriteByteArray, (const int8_t*, int32_t),
+              (override));
+
+  MockWritableParcel();
+};
+
+class MockReadableParcel : public ReadableParcel {
+ public:
+  MOCK_METHOD(int32_t, GetDataSize, (), (const, override));
+  MOCK_METHOD(absl::Status, ReadInt32, (int32_t*), (const, override));
+  MOCK_METHOD(absl::Status, ReadInt64, (int64_t*), (const, override));
+  MOCK_METHOD(absl::Status, ReadBinder, (std::unique_ptr<Binder>*),
+              (const, override));
+  MOCK_METHOD(absl::Status, ReadByteArray, (std::string*), (const, override));
+  MOCK_METHOD(absl::Status, ReadString, (char[111]), (const, override));
+
+  MockReadableParcel();
+};
+
+class MockBinder : public Binder {
+ public:
+  MOCK_METHOD(void, Initialize, (), (override));
+  MOCK_METHOD(absl::Status, PrepareTransaction, (), (override));
+  MOCK_METHOD(absl::Status, Transact, (BinderTransportTxCode), (override));
+  MOCK_METHOD(WritableParcel*, GetWritableParcel, (), (const, override));
+  MOCK_METHOD(ReadableParcel*, GetReadableParcel, (), (const, override));
+  MOCK_METHOD(std::unique_ptr<TransactionReceiver>, ConstructTxReceiver,
+              (grpc_core::RefCountedPtr<WireReader>,
+               TransactionReceiver::OnTransactCb),
+              (const, override));
+  MOCK_METHOD(void*, GetRawBinder, (), (override));
+
+  MockBinder();
+  MockWritableParcel& GetWriter() { return mock_input_; }
+  MockReadableParcel& GetReader() { return mock_output_; }
+
+ private:
+  MockWritableParcel mock_input_;
+  MockReadableParcel mock_output_;
+};
+
+// TODO(waynetu): Implement transaction injection later for more thorough
+// testing.
+class MockTransactionReceiver : public TransactionReceiver {
+ public:
+  explicit MockTransactionReceiver(OnTransactCb transact_cb,
+                                   BinderTransportTxCode code,
+                                   const ReadableParcel* output) {
+    transact_cb(static_cast<transaction_code_t>(code), output).IgnoreError();
+  }
+
+  MOCK_METHOD(void*, GetRawBinder, (), (override));
+};
+
+class MockWireWriter : public WireWriter {
+ public:
+  MOCK_METHOD(absl::Status, RpcCall, (const Transaction&), (override));
+  MOCK_METHOD(absl::Status, SendAck, (int64_t), (override));
+  MOCK_METHOD(void, OnAckReceived, (int64_t), (override));
+};
+
+class MockTransportStreamReceiver : public TransportStreamReceiver {
+ public:
+  MOCK_METHOD(void, RegisterRecvInitialMetadata,
+              (StreamIdentifier, InitialMetadataCallbackType), (override));
+  MOCK_METHOD(void, RegisterRecvMessage,
+              (StreamIdentifier, MessageDataCallbackType), (override));
+  MOCK_METHOD(void, RegisterRecvTrailingMetadata,
+              (StreamIdentifier, TrailingMetadataCallbackType), (override));
+  MOCK_METHOD(void, NotifyRecvInitialMetadata,
+              (StreamIdentifier, absl::StatusOr<Metadata>), (override));
+  MOCK_METHOD(void, NotifyRecvMessage,
+              (StreamIdentifier, absl::StatusOr<std::string>), (override));
+  MOCK_METHOD(void, NotifyRecvTrailingMetadata,
+              (StreamIdentifier, absl::StatusOr<Metadata>, int), (override));
+  MOCK_METHOD(void, CancelStream, (StreamIdentifier), (override));
+};
+
+}  // namespace grpc_binder
+
+#endif  // GRPC_TEST_CORE_TRANSPORT_BINDER_MOCK_OBJECTS_H
diff --git a/test/core/transport/binder/transport_stream_receiver_test.cc b/test/core/transport/binder/transport_stream_receiver_test.cc
new file mode 100644 (file)
index 0000000..134a27a
--- /dev/null
@@ -0,0 +1,288 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#include <cassert>
+#include <string>
+#include <utility>
+#include <vector>
+
+#include <gmock/gmock.h>
+#include <gtest/gtest.h>
+
+#include "absl/memory/memory.h"
+
+#include "src/core/ext/transport/binder/utils/transport_stream_receiver_impl.h"
+#include "test/core/util/test_config.h"
+
+namespace grpc_binder {
+namespace {
+
+// TODO(waynetu): These are hacks to make callbacks aware of their stream IDs
+// and sequence numbers. Remove/Refactor these hacks when possible.
+template <typename T>
+std::pair<StreamIdentifier, int> Decode(const T& /*data*/) {
+  assert(false && "This should not be called");
+  return {};
+}
+
+template <>
+std::pair<StreamIdentifier, int> Decode<std::string>(const std::string& data) {
+  assert(data.size() == sizeof(StreamIdentifier) + sizeof(int));
+  StreamIdentifier id{};
+  int seq_num{};
+  std::memcpy(&id, data.data(), sizeof(StreamIdentifier));
+  std::memcpy(&seq_num, data.data() + sizeof(StreamIdentifier), sizeof(int));
+  return std::make_pair(id, seq_num);
+}
+
+template <>
+std::pair<StreamIdentifier, int> Decode<Metadata>(const Metadata& data) {
+  assert(data.size() == 1);
+  const std::string& encoding = data[0].first;
+  return Decode(encoding);
+}
+
+template <typename T>
+T Encode(StreamIdentifier /*id*/, int /*seq_num*/) {
+  assert(false && "This should not be called");
+  return {};
+}
+
+template <>
+std::string Encode<std::string>(StreamIdentifier id, int seq_num) {
+  char result[sizeof(StreamIdentifier) + sizeof(int)];
+  std::memcpy(result, &id, sizeof(StreamIdentifier));
+  std::memcpy(result + sizeof(StreamIdentifier), &seq_num, sizeof(int));
+  return std::string(result, sizeof(StreamIdentifier) + sizeof(int));
+}
+
+template <>
+Metadata Encode<Metadata>(StreamIdentifier id, int seq_num) {
+  return {{Encode<std::string>(id, seq_num), ""}};
+}
+
+MATCHER_P2(StreamIdAndSeqNumMatch, id, seq_num, "") {
+  auto p = Decode(arg.value());
+  return p.first == id && p.second == seq_num;
+}
+
+// MockCallback is used to verify the every callback passed to transaction
+// receiver will eventually be invoked with the artifact of its corresponding
+// binder transaction.
+template <typename FirstArg, typename... TrailingArgs>
+class MockCallback {
+ public:
+  explicit MockCallback(StreamIdentifier id, int seq_num)
+      : id_(id), seq_num_(seq_num) {}
+
+  MOCK_METHOD(void, ActualCallback, (FirstArg), ());
+
+  std::function<void(FirstArg, TrailingArgs...)> GetHandle() {
+    return [this](FirstArg first_arg, TrailingArgs...) {
+      this->ActualCallback(first_arg);
+    };
+  }
+
+  void ExpectCallbackInvocation() {
+    EXPECT_CALL(*this, ActualCallback(StreamIdAndSeqNumMatch(id_, seq_num_)));
+  }
+
+ private:
+  StreamIdentifier id_;
+  int seq_num_;
+};
+
+using MockInitialMetadataCallback = MockCallback<absl::StatusOr<Metadata>>;
+using MockMessageCallback = MockCallback<absl::StatusOr<std::string>>;
+using MockTrailingMetadataCallback =
+    MockCallback<absl::StatusOr<Metadata>, int>;
+
+class MockOpBatch {
+ public:
+  MockOpBatch(StreamIdentifier id, int flag, int seq_num)
+      : id_(id), flag_(flag), seq_num_(seq_num) {
+    if (flag_ & kFlagPrefix) {
+      initial_metadata_callback_ =
+          absl::make_unique<MockInitialMetadataCallback>(id_, seq_num_);
+    }
+    if (flag_ & kFlagMessageData) {
+      message_callback_ = absl::make_unique<MockMessageCallback>(id_, seq_num_);
+    }
+    if (flag_ & kFlagSuffix) {
+      trailing_metadata_callback_ =
+          absl::make_unique<MockTrailingMetadataCallback>(id_, seq_num_);
+    }
+  }
+
+  void Complete(TransportStreamReceiver& receiver) {
+    if (flag_ & kFlagPrefix) {
+      initial_metadata_callback_->ExpectCallbackInvocation();
+      receiver.NotifyRecvInitialMetadata(id_, Encode<Metadata>(id_, seq_num_));
+    }
+    if (flag_ & kFlagMessageData) {
+      message_callback_->ExpectCallbackInvocation();
+      receiver.NotifyRecvMessage(id_, Encode<std::string>(id_, seq_num_));
+    }
+    if (flag_ & kFlagSuffix) {
+      trailing_metadata_callback_->ExpectCallbackInvocation();
+      receiver.NotifyRecvTrailingMetadata(id_, Encode<Metadata>(id_, seq_num_),
+                                          0);
+    }
+  }
+
+  void RequestRecv(TransportStreamReceiver& receiver) {
+    if (flag_ & kFlagPrefix) {
+      receiver.RegisterRecvInitialMetadata(
+          id_, initial_metadata_callback_->GetHandle());
+    }
+    if (flag_ & kFlagMessageData) {
+      receiver.RegisterRecvMessage(id_, message_callback_->GetHandle());
+    }
+    if (flag_ & kFlagSuffix) {
+      receiver.RegisterRecvTrailingMetadata(
+          id_, trailing_metadata_callback_->GetHandle());
+    }
+  }
+
+  MockOpBatch NextBatch(int flag) const {
+    return MockOpBatch(id_, flag, seq_num_ + 1);
+  }
+
+ private:
+  std::unique_ptr<MockInitialMetadataCallback> initial_metadata_callback_;
+  std::unique_ptr<MockMessageCallback> message_callback_;
+  std::unique_ptr<MockTrailingMetadataCallback> trailing_metadata_callback_;
+  int id_, flag_, seq_num_;
+};
+
+class TransportStreamReceiverTest : public ::testing::Test {
+ protected:
+  MockOpBatch NewGrpcStream(int flag) {
+    return MockOpBatch(current_id_++, flag, 0);
+  }
+
+  StreamIdentifier current_id_ = 0;
+};
+
+const int kFlagAll = kFlagPrefix | kFlagMessageData | kFlagSuffix;
+
+}  // namespace
+
+TEST_F(TransportStreamReceiverTest, MultipleStreamRequestThenComplete) {
+  TransportStreamReceiverImpl receiver(/*is_client=*/true);
+  MockOpBatch t0 = NewGrpcStream(kFlagAll);
+  t0.RequestRecv(receiver);
+  t0.Complete(receiver);
+}
+
+TEST_F(TransportStreamReceiverTest, MultipleStreamCompleteThenRequest) {
+  TransportStreamReceiverImpl receiver(/*is_client=*/true);
+  MockOpBatch t0 = NewGrpcStream(kFlagAll);
+  t0.Complete(receiver);
+  t0.RequestRecv(receiver);
+}
+
+TEST_F(TransportStreamReceiverTest, MultipleStreamInterleaved) {
+  TransportStreamReceiverImpl receiver(/*is_client=*/true);
+  MockOpBatch t0 = NewGrpcStream(kFlagAll);
+  MockOpBatch t1 = NewGrpcStream(kFlagAll);
+  t1.Complete(receiver);
+  t0.Complete(receiver);
+  t0.RequestRecv(receiver);
+  t1.RequestRecv(receiver);
+}
+
+TEST_F(TransportStreamReceiverTest, MultipleStreamInterleavedReversed) {
+  TransportStreamReceiverImpl receiver(/*is_client=*/true);
+  MockOpBatch t0 = NewGrpcStream(kFlagAll);
+  MockOpBatch t1 = NewGrpcStream(kFlagAll);
+  t0.RequestRecv(receiver);
+  t1.RequestRecv(receiver);
+  t1.Complete(receiver);
+  t0.Complete(receiver);
+}
+
+TEST_F(TransportStreamReceiverTest, MultipleStreamMoreInterleaved) {
+  TransportStreamReceiverImpl receiver(/*is_client=*/true);
+  MockOpBatch t0 = NewGrpcStream(kFlagAll);
+  MockOpBatch t1 = NewGrpcStream(kFlagAll);
+  t0.RequestRecv(receiver);
+  t1.Complete(receiver);
+  MockOpBatch t2 = NewGrpcStream(kFlagAll);
+  t2.RequestRecv(receiver);
+  t0.Complete(receiver);
+  t1.RequestRecv(receiver);
+  t2.Complete(receiver);
+}
+
+TEST_F(TransportStreamReceiverTest, SingleStreamUnaryCall) {
+  TransportStreamReceiverImpl receiver(/*is_client=*/true);
+  MockOpBatch t0 = NewGrpcStream(kFlagPrefix);
+  MockOpBatch t1 = t0.NextBatch(kFlagMessageData);
+  MockOpBatch t2 = t1.NextBatch(kFlagSuffix);
+  t0.RequestRecv(receiver);
+  t1.RequestRecv(receiver);
+  t2.RequestRecv(receiver);
+  t0.Complete(receiver);
+  t1.Complete(receiver);
+  t2.Complete(receiver);
+}
+
+TEST_F(TransportStreamReceiverTest, SingleStreamStreamingCall) {
+  TransportStreamReceiverImpl receiver(/*is_client=*/true);
+  MockOpBatch t0 = NewGrpcStream(kFlagPrefix);
+  t0.RequestRecv(receiver);
+  t0.Complete(receiver);
+  MockOpBatch t1 = t0.NextBatch(kFlagMessageData);
+  t1.Complete(receiver);
+  t1.RequestRecv(receiver);
+  MockOpBatch t2 = t1.NextBatch(kFlagMessageData);
+  t2.RequestRecv(receiver);
+  t2.Complete(receiver);
+  MockOpBatch t3 = t2.NextBatch(kFlagMessageData);
+  MockOpBatch t4 = t3.NextBatch(kFlagMessageData);
+  t3.Complete(receiver);
+  t4.Complete(receiver);
+  t3.RequestRecv(receiver);
+  t4.RequestRecv(receiver);
+}
+
+TEST_F(TransportStreamReceiverTest, DISABLED_SingleStreamBufferedCallbacks) {
+  TransportStreamReceiverImpl receiver(/*is_client=*/true);
+  MockOpBatch t0 = NewGrpcStream(kFlagPrefix);
+  MockOpBatch t1 = t0.NextBatch(kFlagMessageData);
+  MockOpBatch t2 = t1.NextBatch(kFlagMessageData);
+  MockOpBatch t3 = t2.NextBatch(kFlagSuffix);
+  t0.RequestRecv(receiver);
+  // TODO(waynetu): Can gRPC issues recv_message before it actually receives the
+  // previous one?
+  t1.RequestRecv(receiver);
+  t2.RequestRecv(receiver);
+  t3.RequestRecv(receiver);
+  t0.Complete(receiver);
+  t1.Complete(receiver);
+  t2.Complete(receiver);
+  t3.Complete(receiver);
+}
+
+// TODO(waynetu): Should we have some concurrent stress tests to make sure that
+// thread safety is well taken care of?
+
+}  // namespace grpc_binder
+
+int main(int argc, char** argv) {
+  ::testing::InitGoogleTest(&argc, argv);
+  grpc::testing::TestEnvironment env(argc, argv);
+  return RUN_ALL_TESTS();
+}
diff --git a/test/core/transport/binder/wire_reader_test.cc b/test/core/transport/binder/wire_reader_test.cc
new file mode 100644 (file)
index 0000000..47c6d5d
--- /dev/null
@@ -0,0 +1,321 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+// Unit tests for WireReaderImpl.
+//
+// WireReaderImpl is responsible for turning incoming transactions into
+// top-level metadata. The following tests verify that the interactions between
+// WireReaderImpl and both the output (readable) parcel and the transport stream
+// receiver are correct in all possible situations.
+#include <memory>
+#include <string>
+#include <thread>
+#include <utility>
+
+#include <gtest/gtest.h>
+
+#include "absl/memory/memory.h"
+
+#include "src/core/ext/transport/binder/wire_format/wire_reader_impl.h"
+#include "test/core/transport/binder/mock_objects.h"
+#include "test/core/util/test_config.h"
+
+namespace grpc_binder {
+
+using ::testing::DoAll;
+using ::testing::Return;
+using ::testing::SetArgPointee;
+using ::testing::StrictMock;
+
+namespace {
+
+class WireReaderTest : public ::testing::Test {
+ public:
+  WireReaderTest()
+      : transport_stream_receiver_(
+            std::make_shared<StrictMock<MockTransportStreamReceiver>>()),
+        wire_reader_(transport_stream_receiver_, /*is_client=*/true) {}
+
+ protected:
+  void ExpectReadInt32(int result) {
+    EXPECT_CALL(mock_readable_parcel_, ReadInt32)
+        .WillOnce(DoAll(SetArgPointee<0>(result), Return(absl::OkStatus())));
+  }
+
+  void ExpectReadByteArray(const std::string& buffer) {
+    ExpectReadInt32(buffer.length());
+    if (!buffer.empty()) {
+      EXPECT_CALL(mock_readable_parcel_, ReadByteArray)
+          .WillOnce([buffer](std::string* data) {
+            *data = buffer;
+            return absl::OkStatus();
+          });
+    }
+  }
+
+  void UnblockSetupTransport() {
+    // SETUP_TRANSPORT should finish before we can proceed with any other
+    // requests and streaming calls. The MockBinder will construct a
+    // MockTransactionReceiver, which will then sends SETUP_TRANSPORT request
+    // back to us.
+    wire_reader_.SetupTransport(absl::make_unique<MockBinder>());
+  }
+
+  template <typename T>
+  absl::Status CallProcessTransaction(T tx_code) {
+    return wire_reader_.ProcessTransaction(
+        static_cast<transaction_code_t>(tx_code), &mock_readable_parcel_);
+  }
+
+  std::shared_ptr<StrictMock<MockTransportStreamReceiver>>
+      transport_stream_receiver_;
+  WireReaderImpl wire_reader_;
+  MockReadableParcel mock_readable_parcel_;
+};
+
+MATCHER_P(StatusOrStrEq, target, "") {
+  if (!arg.ok()) return false;
+  return arg.value() == target;
+}
+
+MATCHER_P(StatusOrContainerEq, target, "") {
+  if (!arg.ok()) return false;
+  return arg.value() == target;
+}
+
+}  // namespace
+
+TEST_F(WireReaderTest, SetupTransport) {
+  auto mock_binder = absl::make_unique<MockBinder>();
+  MockBinder& mock_binder_ref = *mock_binder;
+
+  ::testing::InSequence sequence;
+  EXPECT_CALL(mock_binder_ref, Initialize);
+  EXPECT_CALL(mock_binder_ref, PrepareTransaction);
+  const MockReadableParcel mock_readable_parcel;
+  EXPECT_CALL(mock_binder_ref, GetWritableParcel);
+
+  // Write version.
+  EXPECT_CALL(mock_binder_ref.GetWriter(), WriteInt32(77));
+
+  // The transaction receiver immediately informs the wire writer that the
+  // transport has been successfully set up.
+  EXPECT_CALL(mock_binder_ref, ConstructTxReceiver);
+
+  EXPECT_CALL(mock_binder_ref.GetReader(), ReadInt32);
+  EXPECT_CALL(mock_binder_ref.GetReader(), ReadBinder);
+
+  // Write transaction receiver.
+  EXPECT_CALL(mock_binder_ref.GetWriter(), WriteBinder);
+  // Perform transaction.
+  EXPECT_CALL(mock_binder_ref, Transact);
+
+  wire_reader_.SetupTransport(std::move(mock_binder));
+}
+
+TEST_F(WireReaderTest, ProcessTransactionControlMessageSetupTransport) {
+  ::testing::InSequence sequence;
+  UnblockSetupTransport();
+}
+
+TEST_F(WireReaderTest, ProcessTransactionControlMessagePingResponse) {
+  ::testing::InSequence sequence;
+  UnblockSetupTransport();
+  EXPECT_CALL(mock_readable_parcel_, ReadInt32);
+  EXPECT_TRUE(
+      CallProcessTransaction(BinderTransportTxCode::PING_RESPONSE).ok());
+}
+
+TEST_F(WireReaderTest, ProcessTransactionServerRpcDataEmptyFlagIgnored) {
+  ::testing::InSequence sequence;
+  UnblockSetupTransport();
+
+  // first transaction: empty flag
+  ExpectReadInt32(0);
+  // Won't further read sequence number.
+  EXPECT_TRUE(CallProcessTransaction(kFirstCallId).ok());
+}
+
+TEST_F(WireReaderTest,
+       ProcessTransactionServerRpcDataFlagPrefixWithoutMetadata) {
+  ::testing::InSequence sequence;
+  UnblockSetupTransport();
+
+  // flag
+  ExpectReadInt32(kFlagPrefix);
+  // sequence number
+  ExpectReadInt32(0);
+
+  // count
+  ExpectReadInt32(0);
+  EXPECT_CALL(
+      *transport_stream_receiver_,
+      NotifyRecvInitialMetadata(kFirstCallId, StatusOrContainerEq(Metadata{})));
+
+  EXPECT_TRUE(CallProcessTransaction(kFirstCallId).ok());
+}
+
+TEST_F(WireReaderTest, ProcessTransactionServerRpcDataFlagPrefixWithMetadata) {
+  ::testing::InSequence sequence;
+  UnblockSetupTransport();
+
+  // flag
+  ExpectReadInt32(kFlagPrefix);
+  // sequence number
+  ExpectReadInt32(0);
+
+  const std::vector<std::pair<std::string, std::string>> kMetadata = {
+      {"", ""},
+      {"", "value"},
+      {"key", ""},
+      {"key", "value"},
+      {"another-key", "another-value"},
+  };
+
+  // count
+  ExpectReadInt32(kMetadata.size());
+  for (const auto& md : kMetadata) {
+    // metadata key
+    ExpectReadByteArray(md.first);
+    // metadata val
+    // TODO(waynetu): metadata value can also be "parcelable".
+    ExpectReadByteArray(md.second);
+  }
+  EXPECT_CALL(
+      *transport_stream_receiver_,
+      NotifyRecvInitialMetadata(kFirstCallId, StatusOrContainerEq(kMetadata)));
+
+  EXPECT_TRUE(CallProcessTransaction(kFirstCallId).ok());
+}
+
+TEST_F(WireReaderTest, ProcessTransactionServerRpcDataFlagMessageDataNonEmpty) {
+  ::testing::InSequence sequence;
+  UnblockSetupTransport();
+
+  // flag
+  ExpectReadInt32(kFlagMessageData);
+  // sequence number
+  ExpectReadInt32(0);
+
+  // message data
+  // TODO(waynetu): message data can also be "parcelable".
+  const std::string kMessageData = "message data";
+  ExpectReadByteArray(kMessageData);
+  EXPECT_CALL(*transport_stream_receiver_,
+              NotifyRecvMessage(kFirstCallId, StatusOrStrEq(kMessageData)));
+
+  EXPECT_TRUE(CallProcessTransaction(kFirstCallId).ok());
+}
+
+TEST_F(WireReaderTest, ProcessTransactionServerRpcDataFlagMessageDataEmpty) {
+  ::testing::InSequence sequence;
+  UnblockSetupTransport();
+
+  // flag
+  ExpectReadInt32(kFlagMessageData);
+  // sequence number
+  ExpectReadInt32(0);
+
+  // message data
+  // TODO(waynetu): message data can also be "parcelable".
+  const std::string kMessageData = "";
+  ExpectReadByteArray(kMessageData);
+  EXPECT_CALL(*transport_stream_receiver_,
+              NotifyRecvMessage(kFirstCallId, StatusOrStrEq(kMessageData)));
+
+  EXPECT_TRUE(CallProcessTransaction(kFirstCallId).ok());
+}
+
+TEST_F(WireReaderTest, ProcessTransactionServerRpcDataFlagSuffixWithStatus) {
+  ::testing::InSequence sequence;
+  UnblockSetupTransport();
+
+  constexpr int kStatus = 0x1234;
+  // flag
+  ExpectReadInt32(kFlagSuffix | kFlagStatusDescription | (kStatus << 16));
+  // sequence number
+  ExpectReadInt32(0);
+  // status description
+  EXPECT_CALL(mock_readable_parcel_, ReadString);
+  // metadata count
+  ExpectReadInt32(0);
+  EXPECT_CALL(*transport_stream_receiver_,
+              NotifyRecvTrailingMetadata(
+                  kFirstCallId, StatusOrContainerEq(Metadata{}), kStatus));
+
+  EXPECT_TRUE(CallProcessTransaction(kFirstCallId).ok());
+}
+
+TEST_F(WireReaderTest, ProcessTransactionServerRpcDataFlagSuffixWithoutStatus) {
+  ::testing::InSequence sequence;
+  UnblockSetupTransport();
+
+  // flag
+  ExpectReadInt32(kFlagSuffix);
+  // sequence number
+  ExpectReadInt32(0);
+  // No status description
+  // metadata count
+  ExpectReadInt32(0);
+  EXPECT_CALL(*transport_stream_receiver_,
+              NotifyRecvTrailingMetadata(kFirstCallId,
+                                         StatusOrContainerEq(Metadata{}), 0));
+
+  EXPECT_TRUE(CallProcessTransaction(kFirstCallId).ok());
+}
+
+TEST_F(WireReaderTest, InBoundFlowControl) {
+  ::testing::InSequence sequence;
+  UnblockSetupTransport();
+
+  // data size
+  EXPECT_CALL(mock_readable_parcel_, GetDataSize).WillOnce(Return(1000));
+  // flag
+  ExpectReadInt32(kFlagMessageData | kFlagMessageDataIsPartial);
+  // sequence number
+  ExpectReadInt32(0);
+  // message size
+  ExpectReadInt32(1000);
+  EXPECT_CALL(mock_readable_parcel_, ReadByteArray)
+      .WillOnce(DoAll(SetArgPointee<0>(std::string(1000, 'a')),
+                      Return(absl::OkStatus())));
+
+  // Data is not completed. No callback will be triggered.
+  EXPECT_TRUE(CallProcessTransaction(kFirstCallId).ok());
+
+  EXPECT_CALL(mock_readable_parcel_, GetDataSize).WillOnce(Return(1000));
+  // flag
+  ExpectReadInt32(kFlagMessageData);
+  // sequence number
+  ExpectReadInt32(1);
+  // message size
+  ExpectReadInt32(1000);
+  EXPECT_CALL(mock_readable_parcel_, ReadByteArray)
+      .WillOnce(DoAll(SetArgPointee<0>(std::string(1000, 'b')),
+                      Return(absl::OkStatus())));
+
+  EXPECT_CALL(*transport_stream_receiver_,
+              NotifyRecvMessage(kFirstCallId,
+                                StatusOrContainerEq(std::string(1000, 'a') +
+                                                    std::string(1000, 'b'))));
+  EXPECT_TRUE(CallProcessTransaction(kFirstCallId).ok());
+}
+
+}  // namespace grpc_binder
+
+int main(int argc, char** argv) {
+  ::testing::InitGoogleTest(&argc, argv);
+  grpc::testing::TestEnvironment env(argc, argv);
+  return RUN_ALL_TESTS();
+}
diff --git a/test/core/transport/binder/wire_writer_test.cc b/test/core/transport/binder/wire_writer_test.cc
new file mode 100644 (file)
index 0000000..7b32069
--- /dev/null
@@ -0,0 +1,251 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#include "src/core/ext/transport/binder/wire_format/wire_writer.h"
+
+#include <string>
+#include <utility>
+
+#include <gtest/gtest.h>
+
+#include "absl/memory/memory.h"
+
+#include "test/core/transport/binder/mock_objects.h"
+#include "test/core/util/test_config.h"
+
+namespace grpc_binder {
+
+using ::testing::Return;
+
+MATCHER_P(StrEqInt8Ptr, target, "") {
+  return std::string(reinterpret_cast<const char*>(arg), target.size()) ==
+         target;
+}
+
+TEST(WireWriterTest, RpcCall) {
+  auto mock_binder = absl::make_unique<MockBinder>();
+  MockBinder& mock_binder_ref = *mock_binder;
+  MockWritableParcel mock_writable_parcel;
+  ON_CALL(mock_binder_ref, GetWritableParcel)
+      .WillByDefault(Return(&mock_writable_parcel));
+  WireWriterImpl wire_writer(std::move(mock_binder));
+
+  auto ExpectWriteByteArray = [&](const std::string& target) {
+    // length
+    EXPECT_CALL(mock_writable_parcel, WriteInt32(target.size()));
+    if (!target.empty()) {
+      // content
+      EXPECT_CALL(mock_writable_parcel,
+                  WriteByteArray(StrEqInt8Ptr(target), target.size()));
+    }
+  };
+
+  ::testing::InSequence sequence;
+  int sequence_number = 0;
+
+  {
+    // flag
+    EXPECT_CALL(mock_writable_parcel, WriteInt32(0));
+    // sequence number
+    EXPECT_CALL(mock_writable_parcel, WriteInt32(sequence_number));
+
+    EXPECT_CALL(mock_binder_ref, Transact(BinderTransportTxCode(kFirstCallId)));
+
+    Transaction tx(kFirstCallId, /*is_client=*/true);
+    EXPECT_TRUE(wire_writer.RpcCall(tx).ok());
+    sequence_number++;
+  }
+  {
+    // flag
+    EXPECT_CALL(mock_writable_parcel, WriteInt32(kFlagPrefix));
+    // sequence number. This is another stream so the sequence number starts
+    // with 0.
+    EXPECT_CALL(mock_writable_parcel, WriteInt32(0));
+
+    EXPECT_CALL(mock_writable_parcel,
+                WriteString(absl::string_view("/example/method/ref")));
+
+    const std::vector<std::pair<std::string, std::string>> kMetadata = {
+        {"", ""},
+        {"", "value"},
+        {"key", ""},
+        {"key", "value"},
+        {"another-key", "another-value"},
+    };
+
+    // Number of metadata
+    EXPECT_CALL(mock_writable_parcel, WriteInt32(kMetadata.size()));
+
+    for (const auto& md : kMetadata) {
+      ExpectWriteByteArray(md.first);
+      ExpectWriteByteArray(md.second);
+    }
+
+    EXPECT_CALL(mock_binder_ref,
+                Transact(BinderTransportTxCode(kFirstCallId + 1)));
+
+    Transaction tx(kFirstCallId + 1, /*is_client=*/true);
+    tx.SetPrefix(kMetadata);
+    tx.SetMethodRef("/example/method/ref");
+    EXPECT_TRUE(wire_writer.RpcCall(tx).ok());
+  }
+  {
+    // flag
+    EXPECT_CALL(mock_writable_parcel, WriteInt32(kFlagMessageData));
+    // sequence number
+    EXPECT_CALL(mock_writable_parcel, WriteInt32(sequence_number));
+
+    ExpectWriteByteArray("data");
+    EXPECT_CALL(mock_binder_ref, Transact(BinderTransportTxCode(kFirstCallId)));
+
+    Transaction tx(kFirstCallId, /*is_client=*/true);
+    tx.SetData("data");
+    EXPECT_TRUE(wire_writer.RpcCall(tx).ok());
+    sequence_number++;
+  }
+  {
+    // flag
+    EXPECT_CALL(mock_writable_parcel, WriteInt32(kFlagSuffix));
+    // sequence number
+    EXPECT_CALL(mock_writable_parcel, WriteInt32(sequence_number));
+
+    EXPECT_CALL(mock_binder_ref, Transact(BinderTransportTxCode(kFirstCallId)));
+
+    Transaction tx(kFirstCallId, /*is_client=*/true);
+    tx.SetSuffix({});
+    EXPECT_TRUE(wire_writer.RpcCall(tx).ok());
+    sequence_number++;
+  }
+  {
+    // flag
+    EXPECT_CALL(mock_writable_parcel,
+                WriteInt32(kFlagPrefix | kFlagMessageData | kFlagSuffix));
+    // sequence number
+    EXPECT_CALL(mock_writable_parcel, WriteInt32(sequence_number));
+
+    EXPECT_CALL(mock_writable_parcel,
+                WriteString(absl::string_view("/example/method/ref")));
+
+    const std::vector<std::pair<std::string, std::string>> kMetadata = {
+        {"", ""},
+        {"", "value"},
+        {"key", ""},
+        {"key", "value"},
+        {"another-key", "another-value"},
+    };
+
+    // Number of metadata
+    EXPECT_CALL(mock_writable_parcel, WriteInt32(kMetadata.size()));
+
+    for (const auto& md : kMetadata) {
+      ExpectWriteByteArray(md.first);
+      ExpectWriteByteArray(md.second);
+    }
+
+    // Empty message data
+    ExpectWriteByteArray("");
+
+    EXPECT_CALL(mock_binder_ref, Transact(BinderTransportTxCode(kFirstCallId)));
+
+    Transaction tx(kFirstCallId, /*is_client=*/true);
+    // TODO(waynetu): Implement a helper function that automatically creates
+    // EXPECT_CALL based on the tx object.
+    tx.SetPrefix(kMetadata);
+    tx.SetMethodRef("/example/method/ref");
+    tx.SetData("");
+    tx.SetSuffix({});
+    EXPECT_TRUE(wire_writer.RpcCall(tx).ok());
+    sequence_number++;
+  }
+
+  // Really large message
+  {
+    EXPECT_CALL(mock_writable_parcel,
+                WriteInt32(kFlagMessageData | kFlagMessageDataIsPartial));
+    EXPECT_CALL(mock_writable_parcel, WriteInt32(0));
+    ExpectWriteByteArray(std::string(WireWriterImpl::kBlockSize, 'a'));
+    EXPECT_CALL(mock_writable_parcel, GetDataSize)
+        .WillOnce(Return(WireWriterImpl::kBlockSize));
+    EXPECT_CALL(mock_binder_ref,
+                Transact(BinderTransportTxCode(kFirstCallId + 2)));
+
+    EXPECT_CALL(mock_writable_parcel,
+                WriteInt32(kFlagMessageData | kFlagMessageDataIsPartial));
+    EXPECT_CALL(mock_writable_parcel, WriteInt32(1));
+    ExpectWriteByteArray(std::string(WireWriterImpl::kBlockSize, 'a'));
+    EXPECT_CALL(mock_writable_parcel, GetDataSize)
+        .WillOnce(Return(WireWriterImpl::kBlockSize));
+    EXPECT_CALL(mock_binder_ref,
+                Transact(BinderTransportTxCode(kFirstCallId + 2)));
+
+    EXPECT_CALL(mock_writable_parcel, WriteInt32(kFlagMessageData));
+    EXPECT_CALL(mock_writable_parcel, WriteInt32(2));
+    ExpectWriteByteArray("a");
+    EXPECT_CALL(mock_writable_parcel, GetDataSize).WillOnce(Return(1));
+    EXPECT_CALL(mock_binder_ref,
+                Transact(BinderTransportTxCode(kFirstCallId + 2)));
+
+    // Use a new stream.
+    Transaction tx(kFirstCallId + 2, /*is_client=*/true);
+    tx.SetData(std::string(2 * WireWriterImpl::kBlockSize + 1, 'a'));
+    EXPECT_TRUE(wire_writer.RpcCall(tx).ok());
+  }
+  // Really large message with metadata
+  {
+    EXPECT_CALL(
+        mock_writable_parcel,
+        WriteInt32(kFlagPrefix | kFlagMessageData | kFlagMessageDataIsPartial));
+    EXPECT_CALL(mock_writable_parcel, WriteInt32(0));
+    EXPECT_CALL(mock_writable_parcel, WriteString(absl::string_view("123")));
+    EXPECT_CALL(mock_writable_parcel, WriteInt32(0));
+    ExpectWriteByteArray(std::string(WireWriterImpl::kBlockSize, 'a'));
+    EXPECT_CALL(mock_writable_parcel, GetDataSize)
+        .WillOnce(Return(WireWriterImpl::kBlockSize));
+    EXPECT_CALL(mock_binder_ref,
+                Transact(BinderTransportTxCode(kFirstCallId + 3)));
+
+    EXPECT_CALL(mock_writable_parcel,
+                WriteInt32(kFlagMessageData | kFlagMessageDataIsPartial));
+    EXPECT_CALL(mock_writable_parcel, WriteInt32(1));
+    ExpectWriteByteArray(std::string(WireWriterImpl::kBlockSize, 'a'));
+    EXPECT_CALL(mock_writable_parcel, GetDataSize)
+        .WillOnce(Return(WireWriterImpl::kBlockSize));
+    EXPECT_CALL(mock_binder_ref,
+                Transact(BinderTransportTxCode(kFirstCallId + 3)));
+
+    EXPECT_CALL(mock_writable_parcel,
+                WriteInt32(kFlagMessageData | kFlagSuffix));
+    EXPECT_CALL(mock_writable_parcel, WriteInt32(2));
+    ExpectWriteByteArray("a");
+    EXPECT_CALL(mock_writable_parcel, GetDataSize).WillOnce(Return(1));
+    EXPECT_CALL(mock_binder_ref,
+                Transact(BinderTransportTxCode(kFirstCallId + 3)));
+
+    // Use a new stream.
+    Transaction tx(kFirstCallId + 3, /*is_client=*/true);
+    tx.SetPrefix({});
+    tx.SetMethodRef("123");
+    tx.SetData(std::string(2 * WireWriterImpl::kBlockSize + 1, 'a'));
+    tx.SetSuffix({});
+    EXPECT_TRUE(wire_writer.RpcCall(tx).ok());
+  }
+}
+
+}  // namespace grpc_binder
+
+int main(int argc, char** argv) {
+  ::testing::InitGoogleTest(&argc, argv);
+  grpc::testing::TestEnvironment env(argc, argv);
+  return RUN_ALL_TESTS();
+}
index 32ee73f..014bb1d 100644 (file)
@@ -18,6 +18,8 @@
 
 #include "src/core/lib/transport/byte_stream.h"
 
+#include <gtest/gtest.h>
+
 #include <grpc/grpc.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include "src/core/lib/gpr/useful.h"
 #include "src/core/lib/iomgr/exec_ctx.h"
 #include "src/core/lib/slice/slice_internal.h"
-
 #include "test/core/util/test_config.h"
 
-#include <gtest/gtest.h>
-
 namespace grpc_core {
 namespace {
 
index b3d7aa8..ad6709a 100644 (file)
@@ -83,6 +83,22 @@ grpc_cc_test(
 )
 
 grpc_cc_test(
+    name = "flow_control_test",
+    size = "large",
+    srcs = ["flow_control_test.cc"],
+    external_deps = [
+        "gtest",
+    ],
+    language = "C++",
+    deps = [
+        "//:gpr",
+        "//:grpc",
+        "//test/core/end2end:cq_verifier",
+        "//test/core/util:grpc_test_util",
+    ],
+)
+
+grpc_cc_test(
     name = "hpack_encoder_test",
     srcs = ["hpack_encoder_test.cc"],
     language = "C++",
@@ -107,8 +123,8 @@ grpc_cc_test(
 )
 
 grpc_cc_test(
-    name = "hpack_table_test",
-    srcs = ["hpack_table_test.cc"],
+    name = "hpack_parser_table_test",
+    srcs = ["hpack_parser_table_test.cc"],
     language = "C++",
     uses_polling = False,
     deps = [
@@ -194,3 +210,29 @@ grpc_cc_test(
         "//test/core/util:grpc_test_util",
     ],
 )
+
+grpc_cc_test(
+    name = "popularity_count_test",
+    srcs = ["popularity_count_test.cc"],
+    external_deps = [
+        "gtest",
+    ],
+    deps = [
+        "//:gpr_platform",
+        "//:popularity_count",
+        "//test/core/util:grpc_suppressions",
+    ],
+)
+
+grpc_cc_test(
+    name = "hpack_encoder_index_test",
+    srcs = ["hpack_encoder_index_test.cc"],
+    external_deps = [
+        "gtest",
+    ],
+    deps = [
+        "//:gpr_platform",
+        "//:hpack_encoder_index",
+        "//test/core/util:grpc_suppressions",
+    ],
+)
index 6da5299..ffd1f66 100644 (file)
@@ -19,6 +19,7 @@
 #include "src/core/ext/transport/chttp2/alpn/alpn.h"
 
 #include <grpc/support/log.h>
+
 #include "test/core/util/test_config.h"
 
 static void test_alpn_success(void) {
index 17e7943..3db0fff 100644 (file)
@@ -23,6 +23,7 @@
 #include <grpc/grpc.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
+
 #include "src/core/ext/transport/chttp2/transport/bin_encoder.h"
 #include "src/core/lib/gpr/string.h"
 #include "src/core/lib/iomgr/exec_ctx.h"
index b7fe096..6cf53be 100644 (file)
@@ -26,6 +26,7 @@
 #include <grpc/grpc.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
+
 #include "src/core/lib/gpr/string.h"
 #include "src/core/lib/slice/slice_string_helpers.h"
 #include "test/core/util/test_config.h"
diff --git a/test/core/transport/chttp2/binary-metadata.headers b/test/core/transport/chttp2/binary-metadata.headers
new file mode 100644 (file)
index 0000000..2fa9eef
--- /dev/null
@@ -0,0 +1,2 @@
+a.b.c-bin: b21nMjAyMQ==
+
index d88d66c..89ac6ac 100644 (file)
  *
  */
 
-#include "src/core/lib/iomgr/port.h"
+#include "src/core/ext/transport/chttp2/transport/context_list.h"
 
-#include <gtest/gtest.h>
 #include <new>
 #include <vector>
 
+#include <gtest/gtest.h>
+
+#include <grpc/grpc.h>
+
 #include "src/core/ext/transport/chttp2/transport/chttp2_transport.h"
-#include "src/core/ext/transport/chttp2/transport/context_list.h"
+#include "src/core/lib/iomgr/port.h"
 #include "src/core/lib/transport/transport.h"
 #include "test/core/util/mock_endpoint.h"
 #include "test/core/util/test_config.h"
 
-#include <grpc/grpc.h>
-
 namespace grpc_core {
 namespace testing {
 namespace {
@@ -71,10 +72,13 @@ TEST_F(ContextListTest, ExecuteFlushesList) {
   GRPC_STREAM_REF_INIT(&ref, 1, nullptr, nullptr, "phony ref");
   grpc_resource_quota* resource_quota =
       grpc_resource_quota_create("context_list_test");
-  grpc_endpoint* mock_endpoint =
-      grpc_mock_endpoint_create(discard_write, resource_quota);
-  grpc_transport* t =
-      grpc_create_chttp2_transport(nullptr, mock_endpoint, true);
+  grpc_endpoint* mock_endpoint = grpc_mock_endpoint_create(
+      discard_write,
+      grpc_slice_allocator_create(resource_quota, "mock_endpoint"));
+  grpc_transport* t = grpc_create_chttp2_transport(
+      nullptr, mock_endpoint, true,
+      grpc_resource_user_create(resource_quota, "mock_transport"));
+  grpc_resource_quota_unref(resource_quota);
   std::vector<grpc_chttp2_stream*> s;
   s.reserve(kNumElems);
   gpr_atm verifier_called[kNumElems];
@@ -100,7 +104,6 @@ TEST_F(ContextListTest, ExecuteFlushesList) {
     gpr_free(s[i]);
   }
   grpc_transport_destroy(t);
-  grpc_resource_quota_unref(resource_quota);
   exec_ctx.Flush();
 }
 
@@ -127,10 +130,13 @@ TEST_F(ContextListTest, NonEmptyListEmptyTimestamp) {
   GRPC_STREAM_REF_INIT(&ref, 1, nullptr, nullptr, "phony ref");
   grpc_resource_quota* resource_quota =
       grpc_resource_quota_create("context_list_test");
-  grpc_endpoint* mock_endpoint =
-      grpc_mock_endpoint_create(discard_write, resource_quota);
-  grpc_transport* t =
-      grpc_create_chttp2_transport(nullptr, mock_endpoint, true);
+  grpc_endpoint* mock_endpoint = grpc_mock_endpoint_create(
+      discard_write,
+      grpc_slice_allocator_create(resource_quota, "mock_endpoint"));
+  grpc_transport* t = grpc_create_chttp2_transport(
+      nullptr, mock_endpoint, true,
+      grpc_resource_user_create(resource_quota, "mock_transport"));
+  grpc_resource_quota_unref(resource_quota);
   std::vector<grpc_chttp2_stream*> s;
   s.reserve(kNumElems);
   gpr_atm verifier_called[kNumElems];
@@ -155,7 +161,6 @@ TEST_F(ContextListTest, NonEmptyListEmptyTimestamp) {
     gpr_free(s[i]);
   }
   grpc_transport_destroy(t);
-  grpc_resource_quota_unref(resource_quota);
   exec_ctx.Flush();
 }
 
diff --git a/test/core/transport/chttp2/flow_control_test.cc b/test/core/transport/chttp2/flow_control_test.cc
new file mode 100644 (file)
index 0000000..54ef1d8
--- /dev/null
@@ -0,0 +1,366 @@
+/*
+ *
+ * Copyright 2021 gRPC authors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ *
+ */
+
+#include <grpc/support/port_platform.h>
+
+#include "src/core/ext/transport/chttp2/transport/flow_control.h"
+
+#include <stdlib.h>
+#include <string.h>
+
+#include <functional>
+#include <set>
+#include <thread>
+
+#include <gmock/gmock.h>
+
+#include <grpc/grpc.h>
+#include <grpc/impl/codegen/grpc_types.h>
+#include <grpc/slice.h>
+#include <grpc/support/alloc.h>
+#include <grpc/support/log.h>
+#include <grpc/support/string_util.h>
+#include <grpc/support/time.h>
+
+#include "src/core/ext/filters/client_channel/backup_poller.h"
+#include "src/core/lib/channel/channel_args.h"
+#include "src/core/lib/gprpp/host_port.h"
+#include "src/core/lib/surface/channel.h"
+#include "test/core/end2end/cq_verifier.h"
+#include "test/core/util/port.h"
+#include "test/core/util/test_config.h"
+
+namespace {
+
+class TransportTargetWindowSizeMocker
+    : public grpc_core::chttp2::TestOnlyTransportTargetWindowEstimatesMocker {
+ public:
+  static constexpr uint32_t kLargeInitialWindowSize = 1u << 31;
+  static constexpr uint32_t kSmallInitialWindowSize = 0;
+
+  double ComputeNextTargetInitialWindowSizeFromPeriodicUpdate(
+      double /* current_target */) override {
+    if (alternating_initial_window_sizes_) {
+      window_size_ = (window_size_ == kLargeInitialWindowSize)
+                         ? kSmallInitialWindowSize
+                         : kLargeInitialWindowSize;
+    }
+    return window_size_;
+  }
+
+  // Alternates the initial window size targets. Computes a low values if it was
+  // previously high, or a high value if it was previously low.
+  void AlternateTargetInitialWindowSizes() {
+    alternating_initial_window_sizes_ = true;
+  }
+
+  void Reset() {
+    alternating_initial_window_sizes_ = false;
+    window_size_ = kLargeInitialWindowSize;
+  }
+
+ private:
+  bool alternating_initial_window_sizes_ = false;
+  double window_size_ = kLargeInitialWindowSize;
+};
+
+TransportTargetWindowSizeMocker* g_target_initial_window_size_mocker;
+
+void* tag(intptr_t t) { return reinterpret_cast<void*>(t); }
+
+void VerifyChannelReady(grpc_channel* channel, grpc_completion_queue* cq) {
+  grpc_connectivity_state state =
+      grpc_channel_check_connectivity_state(channel, 1 /* try_to_connect */);
+  while (state != GRPC_CHANNEL_READY) {
+    grpc_channel_watch_connectivity_state(
+        channel, state, grpc_timeout_seconds_to_deadline(5), cq, nullptr);
+    grpc_completion_queue_next(cq, grpc_timeout_seconds_to_deadline(5),
+                               nullptr);
+    state = grpc_channel_check_connectivity_state(channel, 0);
+  }
+}
+
+void VerifyChannelConnected(grpc_channel* channel, grpc_completion_queue* cq) {
+  // Verify channel is connected. Use a ping to make sure that clients
+  // tries sending/receiving bytes if the channel is connected.
+  grpc_channel_ping(channel, cq, reinterpret_cast<void*>(2000), nullptr);
+  grpc_event ev = grpc_completion_queue_next(
+      cq, grpc_timeout_seconds_to_deadline(5), nullptr);
+  GPR_ASSERT(ev.type == GRPC_OP_COMPLETE);
+  GPR_ASSERT(ev.tag == reinterpret_cast<void*>(2000));
+  GPR_ASSERT(ev.success == 1);
+  GPR_ASSERT(grpc_channel_check_connectivity_state(channel, 0) ==
+             GRPC_CHANNEL_READY);
+}
+
+// Shuts down and destroys the server.
+void ServerShutdownAndDestroy(grpc_server* server, grpc_completion_queue* cq) {
+  // Shutdown and destroy server
+  grpc_server_shutdown_and_notify(server, cq, reinterpret_cast<void*>(1000));
+  while (grpc_completion_queue_next(cq, gpr_inf_future(GPR_CLOCK_REALTIME),
+                                    nullptr)
+             .tag != reinterpret_cast<void*>(1000)) {
+  }
+  grpc_server_destroy(server);
+}
+
+grpc_slice LargeSlice(void) {
+  grpc_slice slice = grpc_slice_malloc(10000000);  // ~10MB
+  memset(GRPC_SLICE_START_PTR(slice), 'x', GRPC_SLICE_LENGTH(slice));
+  return slice;
+}
+
+void PerformCallWithLargePayload(grpc_channel* channel, grpc_server* server,
+                                 grpc_completion_queue* cq) {
+  grpc_slice request_payload_slice = LargeSlice();
+  grpc_slice response_payload_slice = LargeSlice();
+  grpc_call* c;
+  grpc_call* s;
+  grpc_byte_buffer* request_payload =
+      grpc_raw_byte_buffer_create(&request_payload_slice, 1);
+  grpc_byte_buffer* response_payload =
+      grpc_raw_byte_buffer_create(&response_payload_slice, 1);
+  cq_verifier* cqv = cq_verifier_create(cq);
+  grpc_op ops[6];
+  grpc_op* op;
+  grpc_metadata_array initial_metadata_recv;
+  grpc_metadata_array trailing_metadata_recv;
+  grpc_metadata_array request_metadata_recv;
+  grpc_byte_buffer* request_payload_recv = nullptr;
+  grpc_byte_buffer* response_payload_recv = nullptr;
+  grpc_call_details call_details;
+  grpc_status_code status;
+  grpc_call_error error;
+  grpc_slice details;
+  int was_cancelled = 2;
+
+  gpr_timespec deadline = grpc_timeout_seconds_to_deadline(30);
+  c = grpc_channel_create_call(channel, nullptr, GRPC_PROPAGATE_DEFAULTS, cq,
+                               grpc_slice_from_static_string("/foo"), nullptr,
+                               deadline, nullptr);
+  GPR_ASSERT(c);
+
+  grpc_metadata_array_init(&initial_metadata_recv);
+  grpc_metadata_array_init(&trailing_metadata_recv);
+  grpc_metadata_array_init(&request_metadata_recv);
+  grpc_call_details_init(&call_details);
+
+  memset(ops, 0, sizeof(ops));
+  op = ops;
+  op->op = GRPC_OP_SEND_INITIAL_METADATA;
+  op->data.send_initial_metadata.count = 0;
+  op->flags = 0;
+  op->reserved = nullptr;
+  op++;
+  op->op = GRPC_OP_SEND_MESSAGE;
+  op->data.send_message.send_message = request_payload;
+  op->flags = 0;
+  op->reserved = nullptr;
+  op++;
+  op->op = GRPC_OP_SEND_CLOSE_FROM_CLIENT;
+  op->flags = 0;
+  op->reserved = nullptr;
+  op++;
+  op->op = GRPC_OP_RECV_INITIAL_METADATA;
+  op->data.recv_initial_metadata.recv_initial_metadata = &initial_metadata_recv;
+  op->flags = 0;
+  op->reserved = nullptr;
+  op++;
+  op->op = GRPC_OP_RECV_MESSAGE;
+  op->data.recv_message.recv_message = &response_payload_recv;
+  op->flags = 0;
+  op->reserved = nullptr;
+  op++;
+  op->op = GRPC_OP_RECV_STATUS_ON_CLIENT;
+  op->data.recv_status_on_client.trailing_metadata = &trailing_metadata_recv;
+  op->data.recv_status_on_client.status = &status;
+  op->data.recv_status_on_client.status_details = &details;
+  op->flags = 0;
+  op->reserved = nullptr;
+  op++;
+  error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1),
+                                nullptr);
+  GPR_ASSERT(GRPC_CALL_OK == error);
+
+  error = grpc_server_request_call(server, &s, &call_details,
+                                   &request_metadata_recv, cq, cq, tag(101));
+  GPR_ASSERT(GRPC_CALL_OK == error);
+  CQ_EXPECT_COMPLETION(cqv, tag(101), 1);
+  cq_verify(cqv);
+
+  memset(ops, 0, sizeof(ops));
+  op = ops;
+  op->op = GRPC_OP_SEND_INITIAL_METADATA;
+  op->data.send_initial_metadata.count = 0;
+  op->flags = 0;
+  op->reserved = nullptr;
+  op++;
+  op->op = GRPC_OP_RECV_MESSAGE;
+  op->data.recv_message.recv_message = &request_payload_recv;
+  op->flags = 0;
+  op->reserved = nullptr;
+  op++;
+  error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102),
+                                nullptr);
+  GPR_ASSERT(GRPC_CALL_OK == error);
+
+  CQ_EXPECT_COMPLETION(cqv, tag(102), 1);
+  cq_verify(cqv);
+
+  memset(ops, 0, sizeof(ops));
+  op = ops;
+  op->op = GRPC_OP_RECV_CLOSE_ON_SERVER;
+  op->data.recv_close_on_server.cancelled = &was_cancelled;
+  op->flags = 0;
+  op->reserved = nullptr;
+  op++;
+  op->op = GRPC_OP_SEND_MESSAGE;
+  op->data.send_message.send_message = response_payload;
+  op->flags = 0;
+  op->reserved = nullptr;
+  op++;
+  op->op = GRPC_OP_SEND_STATUS_FROM_SERVER;
+  op->data.send_status_from_server.trailing_metadata_count = 0;
+  op->data.send_status_from_server.status = GRPC_STATUS_UNIMPLEMENTED;
+  grpc_slice status_details = grpc_slice_from_static_string("xyz");
+  op->data.send_status_from_server.status_details = &status_details;
+  op->flags = 0;
+  op->reserved = nullptr;
+  op++;
+  error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(103),
+                                nullptr);
+  GPR_ASSERT(GRPC_CALL_OK == error);
+
+  CQ_EXPECT_COMPLETION(cqv, tag(103), 1);
+  CQ_EXPECT_COMPLETION(cqv, tag(1), 1);
+  cq_verify(cqv);
+
+  GPR_ASSERT(status == GRPC_STATUS_UNIMPLEMENTED);
+  GPR_ASSERT(0 == grpc_slice_str_cmp(details, "xyz"));
+  GPR_ASSERT(0 == grpc_slice_str_cmp(call_details.method, "/foo"));
+  GPR_ASSERT(was_cancelled == 0);
+
+  grpc_slice_unref(details);
+  grpc_metadata_array_destroy(&initial_metadata_recv);
+  grpc_metadata_array_destroy(&trailing_metadata_recv);
+  grpc_metadata_array_destroy(&request_metadata_recv);
+  grpc_call_details_destroy(&call_details);
+
+  grpc_call_unref(c);
+  grpc_call_unref(s);
+
+  cq_verifier_destroy(cqv);
+
+  grpc_byte_buffer_destroy(request_payload);
+  grpc_byte_buffer_destroy(response_payload);
+  grpc_byte_buffer_destroy(request_payload_recv);
+  grpc_byte_buffer_destroy(response_payload_recv);
+  grpc_slice_unref(request_payload_slice);
+  grpc_slice_unref(response_payload_slice);
+}
+
+class FlowControlTest : public ::testing::Test {
+ protected:
+  void SetUp() override {
+    cq_ = grpc_completion_queue_create_for_next(nullptr);
+    // create the server
+    std::string server_address =
+        grpc_core::JoinHostPort("localhost", grpc_pick_unused_port_or_die());
+    grpc_arg server_args[] = {
+        grpc_channel_arg_integer_create(
+            const_cast<char*>(GRPC_ARG_HTTP2_MAX_PING_STRIKES), 0),
+        grpc_channel_arg_integer_create(
+            const_cast<char*>(GRPC_ARG_MAX_RECEIVE_MESSAGE_LENGTH), -1),
+        grpc_channel_arg_integer_create(
+            const_cast<char*>(GRPC_ARG_MAX_SEND_MESSAGE_LENGTH), -1)};
+    grpc_channel_args server_channel_args = {GPR_ARRAY_SIZE(server_args),
+                                             server_args};
+    server_ = grpc_server_create(&server_channel_args, nullptr);
+    grpc_server_register_completion_queue(server_, cq_, nullptr);
+    GPR_ASSERT(
+        grpc_server_add_insecure_http2_port(server_, server_address.c_str()));
+    grpc_server_start(server_);
+    // create the channel (bdp pings are enabled by default)
+    grpc_arg client_args[] = {
+        grpc_channel_arg_integer_create(
+            const_cast<char*>(GRPC_ARG_HTTP2_MAX_PINGS_WITHOUT_DATA), 0),
+        grpc_channel_arg_integer_create(
+            const_cast<char*>(GRPC_ARG_KEEPALIVE_PERMIT_WITHOUT_CALLS), 1),
+        grpc_channel_arg_integer_create(
+            const_cast<char*>(GRPC_ARG_MAX_RECEIVE_MESSAGE_LENGTH), -1),
+        grpc_channel_arg_integer_create(
+            const_cast<char*>(GRPC_ARG_MAX_SEND_MESSAGE_LENGTH), -1)};
+    grpc_channel_args client_channel_args = {GPR_ARRAY_SIZE(client_args),
+                                             client_args};
+    channel_ = grpc_insecure_channel_create(server_address.c_str(),
+                                            &client_channel_args, nullptr);
+    VerifyChannelReady(channel_, cq_);
+    g_target_initial_window_size_mocker->Reset();
+  }
+
+  void TearDown() override {
+    // shutdown and destroy the client and server
+    grpc_channel_destroy(channel_);
+    ServerShutdownAndDestroy(server_, cq_);
+    grpc_completion_queue_shutdown(cq_);
+    while (grpc_completion_queue_next(cq_, gpr_inf_future(GPR_CLOCK_REALTIME),
+                                      nullptr)
+               .type != GRPC_QUEUE_SHUTDOWN) {
+    }
+    grpc_completion_queue_destroy(cq_);
+  }
+
+  grpc_server* server_ = nullptr;
+  grpc_channel* channel_ = nullptr;
+  grpc_completion_queue* cq_ = nullptr;
+};
+
+TEST_F(FlowControlTest,
+       TestLargeWindowSizeUpdatesDoNotCauseIllegalFlowControlWindows) {
+  for (int i = 0; i < 10; ++i) {
+    PerformCallWithLargePayload(channel_, server_, cq_);
+    VerifyChannelConnected(channel_, cq_);
+  }
+}
+
+TEST_F(FlowControlTest, TestWindowSizeUpdatesDoNotCauseStalledStreams) {
+  g_target_initial_window_size_mocker->AlternateTargetInitialWindowSizes();
+  for (int i = 0; i < 100; ++i) {
+    PerformCallWithLargePayload(channel_, server_, cq_);
+    VerifyChannelConnected(channel_, cq_);
+  }
+}
+
+}  // namespace
+
+int main(int argc, char** argv) {
+  ::testing::InitGoogleTest(&argc, argv);
+  // Make sure that we will have an active poller on all client-side fd's that
+  // are capable of sending and receiving even in the case that we don't have an
+  // active RPC operation on the fd.
+  GPR_GLOBAL_CONFIG_SET(grpc_client_channel_backup_poll_interval_ms, 1);
+  ::grpc_core::chttp2::g_test_only_transport_flow_control_window_check = true;
+  g_target_initial_window_size_mocker = new TransportTargetWindowSizeMocker();
+  grpc_core::chttp2::g_test_only_transport_target_window_estimates_mocker =
+      g_target_initial_window_size_mocker;
+  grpc::testing::TestEnvironment env(argc, argv);
+  grpc_init();
+  auto result = RUN_ALL_TESTS();
+  grpc_shutdown();
+  return result;
+}
diff --git a/test/core/transport/chttp2/hpack_encoder_index_test.cc b/test/core/transport/chttp2/hpack_encoder_index_test.cc
new file mode 100644 (file)
index 0000000..e7286fb
--- /dev/null
@@ -0,0 +1,63 @@
+/*
+ *
+ * Copyright 2021 gRPC authors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ *
+ */
+
+#include <grpc/impl/codegen/port_platform.h>
+
+#include "src/core/ext/transport/chttp2/transport/hpack_encoder_index.h"
+
+#include <random>
+#include <unordered_map>
+
+#include <gtest/gtest.h>
+
+namespace grpc_core {
+namespace testing {
+
+struct TestKey {
+  using Stored = uint32_t;
+  uint32_t value;
+  uint32_t stored() const { return value; }
+  uint32_t hash() const { return value; }
+  bool operator==(uint32_t other) const { return other == value; }
+};
+
+TEST(HPackEncoderIndexTest, SetAndGet) {
+  HPackEncoderIndex<TestKey, 64> index;
+  std::default_random_engine rng;
+  std::unordered_map<uint32_t, uint32_t> last_index;
+  for (uint32_t i = 0; i < 10000; i++) {
+    uint32_t key = rng();
+    index.Insert({key}, i);
+    EXPECT_EQ(index.Lookup({key}), i);
+    last_index[key] = i;
+  }
+  for (auto p : last_index) {
+    auto r = index.Lookup({p.first});
+    if (r.has_value()) {
+      EXPECT_EQ(*r, p.second);
+    }
+  }
+}
+
+}  // namespace testing
+}  // namespace grpc_core
+
+int main(int argc, char** argv) {
+  ::testing::InitGoogleTest(&argc, argv);
+  return RUN_ALL_TESTS();
+}
index 2ed16fe..e839c9f 100644 (file)
@@ -30,6 +30,7 @@
 #include <grpc/support/log.h>
 
 #include "src/core/ext/transport/chttp2/transport/hpack_parser.h"
+#include "src/core/ext/transport/chttp2/transport/hpack_utils.h"
 #include "src/core/lib/gpr/string.h"
 #include "src/core/lib/slice/slice_internal.h"
 #include "src/core/lib/slice/slice_string_helpers.h"
@@ -40,7 +41,7 @@
 
 #define TEST(x) run_test(x, #x)
 
-grpc_chttp2_hpack_compressor g_compressor;
+grpc_core::HPackCompressor* g_compressor;
 int g_failure = 0;
 
 void** to_delete = nullptr;
@@ -198,14 +199,14 @@ static void verify(const verify_params params, const char* expected,
 
   grpc_transport_one_way_stats stats;
   stats = {};
-  grpc_encode_header_options hopt = {
+  grpc_core::HPackCompressor::EncodeHeaderOptions hopt{
       0xdeadbeef,                      /* stream_id */
       params.eof,                      /* is_eof */
       params.use_true_binary_metadata, /* use_true_binary_metadata */
       16384,                           /* max_frame_size */
       &stats                           /* stats */
   };
-  grpc_chttp2_encode_header(&g_compressor, nullptr, 0, &b, &hopt, &output);
+  g_compressor->EncodeHeaders(hopt, b, &output);
   verify_frames(output, params.eof);
   merged = grpc_slice_merge(output.slices, output.count);
   grpc_slice_buffer_destroy_internal(&output);
@@ -272,12 +273,13 @@ static void verify_continuation_headers(const char* key, const char* value,
 
   grpc_transport_one_way_stats stats;
   stats = {};
-  grpc_encode_header_options hopt = {0xdeadbeef, /* stream_id */
-                                     is_eof,     /* is_eof */
-                                     false,      /* use_true_binary_metadata */
-                                     150,        /* max_frame_size */
-                                     &stats /* stats */};
-  grpc_chttp2_encode_header(&g_compressor, nullptr, 0, &b, &hopt, &output);
+  grpc_core::HPackCompressor::EncodeHeaderOptions hopt = {
+      0xdeadbeef, /* stream_id */
+      is_eof,     /* is_eof */
+      false,      /* use_true_binary_metadata */
+      150,        /* max_frame_size */
+      &stats /* stats */};
+  g_compressor->EncodeHeaders(hopt, b, &output);
   verify_frames(output, is_eof);
   grpc_slice_buffer_destroy_internal(&output);
   grpc_metadata_batch_destroy(&b);
@@ -306,7 +308,7 @@ static void encode_int_to_str(int i, char* p) {
 
 static void test_decode_table_overflow() {
   // Decrease the default table size to make decode table overflow easier.
-  grpc_chttp2_hpack_compressor_set_max_table_size(&g_compressor, 1024);
+  g_compressor->SetMaxTableSize(1024);
   int i;
   char key[3], value[3];
 
@@ -345,8 +347,8 @@ static void verify_table_size_change_match_elem_size(const char* key,
   grpc_mdelem elem = grpc_mdelem_from_slices(
       grpc_slice_intern(grpc_slice_from_static_string(key)),
       grpc_slice_intern(grpc_slice_from_static_string(value)));
-  size_t elem_size = grpc_chttp2_get_size_in_hpack_table(elem, use_true_binary);
-  size_t initial_table_size = g_compressor.table_size;
+  size_t elem_size = grpc_core::MetadataSizeInHPackTable(elem, use_true_binary);
+  size_t initial_table_size = g_compressor->test_only_table_size();
   grpc_linked_mdelem* e =
       static_cast<grpc_linked_mdelem*>(gpr_malloc(sizeof(*e)));
   grpc_metadata_batch b;
@@ -361,18 +363,19 @@ static void verify_table_size_change_match_elem_size(const char* key,
 
   grpc_transport_one_way_stats stats;
   stats = {};
-  grpc_encode_header_options hopt = {
+  grpc_core::HPackCompressor::EncodeHeaderOptions hopt = {
       0xdeadbeef,      /* stream_id */
       false,           /* is_eof */
       use_true_binary, /* use_true_binary_metadata */
       16384,           /* max_frame_size */
       &stats /* stats */};
-  grpc_chttp2_encode_header(&g_compressor, nullptr, 0, &b, &hopt, &output);
+  g_compressor->EncodeHeaders(hopt, b, &output);
   verify_frames(output, false);
   grpc_slice_buffer_destroy_internal(&output);
   grpc_metadata_batch_destroy(&b);
 
-  GPR_ASSERT(g_compressor.table_size == elem_size + initial_table_size);
+  GPR_ASSERT(g_compressor->test_only_table_size() ==
+             elem_size + initial_table_size);
   gpr_free(e);
 }
 
@@ -397,9 +400,9 @@ static void test_interned_key_indexed() {
 static void run_test(void (*test)(), const char* name) {
   gpr_log(GPR_INFO, "RUN TEST: %s", name);
   grpc_core::ExecCtx exec_ctx;
-  grpc_chttp2_hpack_compressor_init(&g_compressor);
+  g_compressor = new grpc_core::HPackCompressor();
   test();
-  grpc_chttp2_hpack_compressor_destroy(&g_compressor);
+  delete g_compressor;
 }
 
 int main(int argc, char** argv) {
index 7be46ab..3914fc7 100644 (file)
@@ -45,7 +45,8 @@ extern "C" int LLVMFuzzerTestOneInput(const uint8_t* data, size_t size) {
     grpc_core::HPackParser parser;
     parser.BeginFrame(onhdr, grpc_core::HPackParser::Boundary::None,
                       grpc_core::HPackParser::Priority::None);
-    GRPC_ERROR_UNREF(parser.Parse(grpc_slice_from_static_buffer(data, size)));
+    GRPC_ERROR_UNREF(
+        parser.Parse(grpc_slice_from_static_buffer(data, size), true));
   }
   grpc_shutdown();
   return 0;
@@ -16,7 +16,7 @@
  *
  */
 
-#include "src/core/ext/transport/chttp2/transport/hpack_table.h"
+#include "src/core/ext/transport/chttp2/transport/hpack_parser_table.h"
 
 #include <stdio.h>
 #include <string.h>
 
 #define LOG_TEST(x) gpr_log(GPR_INFO, "%s", x)
 
-static void assert_str(const grpc_chttp2_hptbl* /*tbl*/, grpc_slice mdstr,
+using grpc_core::HPackTable;
+
+static void assert_str(const HPackTable* /*tbl*/, grpc_slice mdstr,
                        const char* str) {
   GPR_ASSERT(grpc_slice_str_cmp(mdstr, str) == 0);
 }
 
-static void assert_index(const grpc_chttp2_hptbl* tbl, uint32_t idx,
-                         const char* key, const char* value) {
-  grpc_mdelem md = grpc_chttp2_hptbl_lookup(tbl, idx);
+static void assert_index(const HPackTable* tbl, uint32_t idx, const char* key,
+                         const char* value) {
+  grpc_mdelem md = tbl->Peek(idx);
   assert_str(tbl, GRPC_MDKEY(md), key);
   assert_str(tbl, GRPC_MDVALUE(md), value);
 }
 
 static void test_static_lookup(void) {
   grpc_core::ExecCtx exec_ctx;
-  grpc_chttp2_hptbl tbl;
+  HPackTable tbl;
 
   LOG_TEST("test_static_lookup");
   assert_index(&tbl, 1, ":authority", "");
@@ -114,12 +116,10 @@ static void test_static_lookup(void) {
   assert_index(&tbl, 59, "vary", "");
   assert_index(&tbl, 60, "via", "");
   assert_index(&tbl, 61, "www-authenticate", "");
-
-  grpc_chttp2_hptbl_destroy(&tbl);
 }
 
 static void test_many_additions(void) {
-  grpc_chttp2_hptbl tbl;
+  HPackTable tbl;
   int i;
 
   LOG_TEST("test_many_additions");
@@ -132,135 +132,17 @@ static void test_many_additions(void) {
     std::string value = absl::StrCat("VALUE:", i);
     elem = grpc_mdelem_from_slices(grpc_slice_from_cpp_string(key),
                                    grpc_slice_from_cpp_string(value));
-    GPR_ASSERT(grpc_chttp2_hptbl_add(&tbl, elem) == GRPC_ERROR_NONE);
+    GPR_ASSERT(tbl.Add(elem) == GRPC_ERROR_NONE);
     GRPC_MDELEM_UNREF(elem);
-    assert_index(&tbl, 1 + GRPC_CHTTP2_LAST_STATIC_ENTRY, key.c_str(),
-                 value.c_str());
+    assert_index(&tbl, 1 + grpc_core::hpack_constants::kLastStaticEntry,
+                 key.c_str(), value.c_str());
     if (i) {
       std::string key = absl::StrCat("K:", i - 1);
       std::string value = absl::StrCat("VALUE:", i - 1);
-      assert_index(&tbl, 2 + GRPC_CHTTP2_LAST_STATIC_ENTRY, key.c_str(),
-                   value.c_str());
+      assert_index(&tbl, 2 + grpc_core::hpack_constants::kLastStaticEntry,
+                   key.c_str(), value.c_str());
     }
   }
-
-  grpc_chttp2_hptbl_destroy(&tbl);
-}
-
-static grpc_chttp2_hptbl_find_result find_simple(grpc_chttp2_hptbl* tbl,
-                                                 const char* key,
-                                                 const char* value) {
-  grpc_core::ExecCtx exec_ctx;
-  grpc_mdelem md = grpc_mdelem_from_slices(
-      grpc_slice_from_copied_string(key), grpc_slice_from_copied_string(value));
-  grpc_chttp2_hptbl_find_result r = grpc_chttp2_hptbl_find(tbl, md);
-  GRPC_MDELEM_UNREF(md);
-
-  return r;
-}
-
-static void test_find(void) {
-  grpc_core::ExecCtx exec_ctx;
-  grpc_chttp2_hptbl tbl;
-  uint32_t i;
-  char buffer[32];
-  grpc_mdelem elem;
-  grpc_chttp2_hptbl_find_result r;
-
-  LOG_TEST("test_find");
-
-  elem = grpc_mdelem_from_slices(grpc_slice_from_static_string("abc"),
-                                 grpc_slice_from_static_string("xyz"));
-  GPR_ASSERT(grpc_chttp2_hptbl_add(&tbl, elem) == GRPC_ERROR_NONE);
-  GRPC_MDELEM_UNREF(elem);
-  elem = grpc_mdelem_from_slices(grpc_slice_from_static_string("abc"),
-                                 grpc_slice_from_static_string("123"));
-  GPR_ASSERT(grpc_chttp2_hptbl_add(&tbl, elem) == GRPC_ERROR_NONE);
-  GRPC_MDELEM_UNREF(elem);
-  elem = grpc_mdelem_from_slices(grpc_slice_from_static_string("x"),
-                                 grpc_slice_from_static_string("1"));
-  GPR_ASSERT(grpc_chttp2_hptbl_add(&tbl, elem) == GRPC_ERROR_NONE);
-  GRPC_MDELEM_UNREF(elem);
-
-  r = find_simple(&tbl, "abc", "123");
-  GPR_ASSERT(r.index == 2 + GRPC_CHTTP2_LAST_STATIC_ENTRY);
-  GPR_ASSERT(r.has_value == 1);
-
-  r = find_simple(&tbl, "abc", "xyz");
-  GPR_ASSERT(r.index == 3 + GRPC_CHTTP2_LAST_STATIC_ENTRY);
-  GPR_ASSERT(r.has_value == 1);
-
-  r = find_simple(&tbl, "x", "1");
-  GPR_ASSERT(r.index == 1 + GRPC_CHTTP2_LAST_STATIC_ENTRY);
-  GPR_ASSERT(r.has_value == 1);
-
-  r = find_simple(&tbl, "x", "2");
-  GPR_ASSERT(r.index == 1 + GRPC_CHTTP2_LAST_STATIC_ENTRY);
-  GPR_ASSERT(r.has_value == 0);
-
-  r = find_simple(&tbl, "vary", "some-vary-arg");
-  GPR_ASSERT(r.index == 59);
-  GPR_ASSERT(r.has_value == 0);
-
-  r = find_simple(&tbl, "accept-encoding", "gzip, deflate");
-  GPR_ASSERT(r.index == 16);
-  GPR_ASSERT(r.has_value == 1);
-
-  r = find_simple(&tbl, "accept-encoding", "gzip");
-  GPR_ASSERT(r.index == 16);
-  GPR_ASSERT(r.has_value == 0);
-
-  r = find_simple(&tbl, ":method", "GET");
-  GPR_ASSERT(r.index == 2);
-  GPR_ASSERT(r.has_value == 1);
-
-  r = find_simple(&tbl, ":method", "POST");
-  GPR_ASSERT(r.index == 3);
-  GPR_ASSERT(r.has_value == 1);
-
-  r = find_simple(&tbl, ":method", "PUT");
-  GPR_ASSERT(r.index == 2 || r.index == 3);
-  GPR_ASSERT(r.has_value == 0);
-
-  r = find_simple(&tbl, "this-does-not-exist", "");
-  GPR_ASSERT(r.index == 0);
-  GPR_ASSERT(r.has_value == 0);
-
-  /* overflow the string buffer, check find still works */
-  for (i = 0; i < 10000; i++) {
-    int64_ttoa(i, buffer);
-    elem = grpc_mdelem_from_slices(grpc_slice_from_static_string("test"),
-                                   grpc_slice_from_copied_string(buffer));
-    GPR_ASSERT(grpc_chttp2_hptbl_add(&tbl, elem) == GRPC_ERROR_NONE);
-    GRPC_MDELEM_UNREF(elem);
-  }
-
-  r = find_simple(&tbl, "abc", "123");
-  GPR_ASSERT(r.index == 0);
-  GPR_ASSERT(r.has_value == 0);
-
-  r = find_simple(&tbl, "test", "9999");
-  GPR_ASSERT(r.index == 1 + GRPC_CHTTP2_LAST_STATIC_ENTRY);
-  GPR_ASSERT(r.has_value == 1);
-
-  r = find_simple(&tbl, "test", "9998");
-  GPR_ASSERT(r.index == 2 + GRPC_CHTTP2_LAST_STATIC_ENTRY);
-  GPR_ASSERT(r.has_value == 1);
-
-  for (i = 0; i < tbl.num_ents; i++) {
-    uint32_t expect = 9999 - i;
-    int64_ttoa(expect, buffer);
-
-    r = find_simple(&tbl, "test", buffer);
-    GPR_ASSERT(r.index == i + 1 + GRPC_CHTTP2_LAST_STATIC_ENTRY);
-    GPR_ASSERT(r.has_value == 1);
-  }
-
-  r = find_simple(&tbl, "test", "10000");
-  GPR_ASSERT(r.index != 0);
-  GPR_ASSERT(r.has_value == 0);
-
-  grpc_chttp2_hptbl_destroy(&tbl);
 }
 
 int main(int argc, char** argv) {
@@ -268,7 +150,6 @@ int main(int argc, char** argv) {
   grpc_init();
   test_static_lookup();
   test_many_additions();
-  test_find();
   grpc_shutdown();
   return 0;
 }
index 1328366..6b052f9 100644 (file)
@@ -65,7 +65,11 @@ static void test_vector(grpc_core::HPackParser* parser,
 
   for (i = 0; i < nslices; i++) {
     grpc_core::ExecCtx exec_ctx;
-    GPR_ASSERT(parser->Parse(slices[i]) == GRPC_ERROR_NONE);
+    auto err = parser->Parse(slices[i], i == nslices - 1);
+    if (err != GRPC_ERROR_NONE) {
+      gpr_log(GPR_ERROR, "Unexpected parse error: %s", grpc_error_string(err));
+      abort();
+    }
   }
 
   for (i = 0; i < nslices; i++) {
@@ -158,8 +162,8 @@ static void test_vectors(grpc_slice_split_mode mode) {
 
   {
     grpc_core::HPackParser parser;
-    grpc_chttp2_hptbl_set_max_bytes(parser.hpack_table(), 256);
-    grpc_chttp2_hptbl_set_current_table_size(parser.hpack_table(), 256);
+    parser.hpack_table()->SetMaxBytes(256);
+    parser.hpack_table()->SetCurrentTableSize(256);
     /* D.5.1 */
     test_vector(&parser, mode,
                 "4803 3330 3258 0770 7269 7661 7465 611d"
@@ -199,8 +203,8 @@ static void test_vectors(grpc_slice_split_mode mode) {
 
   {
     grpc_core::HPackParser parser;
-    grpc_chttp2_hptbl_set_max_bytes(parser.hpack_table(), 256);
-    grpc_chttp2_hptbl_set_current_table_size(parser.hpack_table(), 256);
+    parser.hpack_table()->SetMaxBytes(256);
+    parser.hpack_table()->SetCurrentTableSize(256);
     /* D.6.1 */
     test_vector(&parser, mode,
                 "4882 6402 5885 aec3 771a 4b61 96d0 7abe"
@@ -234,6 +238,18 @@ static void test_vectors(grpc_slice_split_mode mode) {
              "set-cookie",
              "foo=ASDJKHQKBZXOQWEOPIUAXQWEOIU; max-age=3600; version=1")});
   }
+
+  {
+    grpc_core::HPackParser parser;
+    // Binary metadata: created using:
+    // tools/codegen/core/gen_header_frame.py
+    //    --compression inc --no_framing --hex
+    //    < test/core/transport/chttp2/binary-metadata.headers
+    test_vector(&parser, mode,
+                "40 09 61 2e 62 2e 63 2d 62 69 6e 0c 62 32 31 6e 4d 6a 41 79 "
+                "4d 51 3d 3d",
+                {std::make_pair("a.b.c-bin", "omg2021")});
+  }
 }
 
 int main(int argc, char** argv) {
diff --git a/test/core/transport/chttp2/hpack_utils_test.cc b/test/core/transport/chttp2/hpack_utils_test.cc
new file mode 100644 (file)
index 0000000..5cb8948
--- /dev/null
@@ -0,0 +1,122 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#include <grpc/impl/codegen/port_platform.h>
+
+#include <random>
+#include <unordered_map>
+
+#include <gtest/gtest.h>
+
+#include "src/core/ext/transport/chttp2/transport/hpack_encoder_index.h"
+
+namespace grpc_core {
+namespace testing {
+
+static void VerifyAsciiHeaderSize(const char* key, const char* value,
+                                  bool intern_key, bool intern_value) {
+  grpc_mdelem elem = grpc_mdelem_from_slices(
+      maybe_intern(grpc_slice_from_static_string(key), intern_key),
+      maybe_intern(grpc_slice_from_static_string(value), intern_value));
+  size_t elem_size = grpc_core::MetadataSizeInHPackTable(elem, false);
+  size_t expected_size = 32 + strlen(key) + strlen(value);
+  GPR_ASSERT(expected_size == elem_size);
+  GRPC_MDELEM_UNREF(elem);
+}
+
+static void VerifyBinaryHeaderSize(const char* key, const uint8_t* value,
+                                   size_t value_len, bool intern_key,
+                                   bool intern_value) {
+  grpc_mdelem elem = grpc_mdelem_from_slices(
+      maybe_intern(grpc_slice_from_static_string(key), intern_key),
+      maybe_intern(grpc_slice_from_static_buffer(value, value_len),
+                   intern_value));
+  GPR_ASSERT(grpc_is_binary_header(GRPC_MDKEY(elem)));
+  size_t elem_size = grpc_core::MetadataSizeInHPackTable(elem, false);
+  grpc_slice value_slice = grpc_slice_from_copied_buffer(
+      reinterpret_cast<const char*>(value), value_len);
+  grpc_slice base64_encoded = grpc_chttp2_base64_encode(value_slice);
+  size_t expected_size = 32 + strlen(key) + GRPC_SLICE_LENGTH(base64_encoded);
+  GPR_ASSERT(expected_size == elem_size);
+  grpc_slice_unref_internal(value_slice);
+  grpc_slice_unref_internal(base64_encoded);
+  GRPC_MDELEM_UNREF(elem);
+}
+
+struct Param {
+  bool intern_key;
+  bool intern_value;
+}
+
+class MetadataTest : public ::testing::TestWithParam<Param> {
+};
+
+#define BUFFER_SIZE 64
+TEST_P(MetadataTest, MetadataSize) {
+  const bool intern_key = GetParam().intern_key;
+  const bool intern_value = GetParam().intern_value;
+  gpr_log(GPR_INFO, "test_mdelem_size: intern_key=%d intern_value=%d",
+          intern_key, intern_value);
+  grpc_init();
+  grpc_core::ExecCtx exec_ctx;
+
+  uint8_t binary_value[BUFFER_SIZE] = {0};
+  for (uint8_t i = 0; i < BUFFER_SIZE; i++) {
+    binary_value[i] = i;
+  }
+
+  verify_ascii_header_size("hello", "world", intern_key, intern_value);
+  verify_ascii_header_size("hello", "worldxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx",
+                           intern_key, intern_value);
+  verify_ascii_header_size(":scheme", "http", intern_key, intern_value);
+
+  for (uint8_t i = 0; i < BUFFER_SIZE; i++) {
+    verify_binary_header_size("hello-bin", binary_value, i, intern_key,
+                              intern_value);
+  }
+
+  grpc_shutdown();
+}
+
+INSTANTIATE_TEST_SUITE_P(MetadataTestSuite, MetadataTest,
+                         ::testing::Values(Param{false, false},
+                                           Param{false, true},
+                                           Param{true, false},
+                                           Param{true, true}));
+
+TEST(HPackEncoderIndexTest, SetAndGet) {
+  HPackEncoderIndex<TestKey, 64> index;
+  std::default_random_engine rng;
+  std::unordered_map<uint32_t, uint32_t> last_index;
+  for (uint32_t i = 0; i < 10000; i++) {
+    uint32_t key = rng();
+    index.Insert({key}, i);
+    EXPECT_EQ(index.Lookup({key}), i);
+    last_index[key] = i;
+  }
+  for (auto p : last_index) {
+    auto r = index.Lookup({p.first});
+    if (r.has_value()) {
+      EXPECT_EQ(*r, p.second);
+    }
+  }
+}
+
+}  // namespace testing
+}  // namespace grpc_core
+
+int main(int argc, char** argv) {
+  ::testing::InitGoogleTest(&argc, argv);
+  return RUN_ALL_TESTS();
+}
diff --git a/test/core/transport/chttp2/popularity_count_test.cc b/test/core/transport/chttp2/popularity_count_test.cc
new file mode 100644 (file)
index 0000000..bcd03f1
--- /dev/null
@@ -0,0 +1,75 @@
+/*
+ *
+ * Copyright 2020 gRPC authors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ *
+ */
+
+#include <grpc/impl/codegen/port_platform.h>
+
+#include "src/core/ext/transport/chttp2/transport/popularity_count.h"
+
+#include <array>
+
+#include <gtest/gtest.h>
+
+namespace grpc_core {
+namespace testing {
+
+static constexpr uint8_t kTestSize = 4;
+
+struct Scenario {
+  std::array<uint8_t, kTestSize> initial_values;
+  uint8_t final_add;
+  bool expectation;
+};
+
+std::ostream& operator<<(std::ostream& out, Scenario s) {
+  out << "init:";
+  for (size_t i = 0; i < kTestSize; i++) {
+    if (i != 0) {
+      out << ",";
+    }
+    out << static_cast<int>(s.initial_values[i]);
+  }
+  out << " final:" << static_cast<int>(s.final_add);
+  out << " expect:" << (s.expectation ? "true" : "false");
+  return out;
+}
+
+struct PopularityCountTest : public ::testing::TestWithParam<Scenario> {};
+
+TEST_P(PopularityCountTest, Test) {
+  Scenario s = GetParam();
+  PopularityCount<kTestSize> pop;
+  for (size_t i = 0; i < kTestSize; i++) {
+    for (size_t j = 0; j < s.initial_values[i]; j++) {
+      pop.AddElement(i);
+    }
+  }
+  EXPECT_EQ(pop.AddElement(s.final_add), s.expectation);
+}
+
+INSTANTIATE_TEST_SUITE_P(InterestingTests, PopularityCountTest,
+                         ::testing::Values(Scenario{{0, 0, 0, 0}, 0, true},
+                                           Scenario{{64, 0, 0, 0}, 0, true},
+                                           Scenario{{64, 0, 0, 0}, 1, false}));
+
+}  // namespace testing
+}  // namespace grpc_core
+
+int main(int argc, char** argv) {
+  ::testing::InitGoogleTest(&argc, argv);
+  return RUN_ALL_TESTS();
+}
index 47b6ba2..8de3861 100644 (file)
@@ -39,7 +39,6 @@
 #include "src/core/ext/transport/chttp2/transport/flow_control.h"
 #include "src/core/lib/channel/channel_args.h"
 #include "src/core/lib/gprpp/host_port.h"
-
 #include "test/core/util/port.h"
 #include "test/core/util/test_config.h"
 
index b979020..7696d04 100644 (file)
@@ -37,8 +37,8 @@
 #include "src/core/lib/iomgr/resolve_address.h"
 #include "src/core/lib/iomgr/tcp_client.h"
 #include "src/core/lib/slice/slice_internal.h"
-
 #include "test/core/util/port.h"
+#include "test/core/util/resource_user_util.h"
 #include "test/core/util/test_config.h"
 
 namespace grpc_core {
@@ -113,9 +113,10 @@ class Client {
     grpc_pollset_set* pollset_set = grpc_pollset_set_create();
     grpc_pollset_set_add_pollset(pollset_set, pollset_);
     EventState state;
-    grpc_tcp_client_connect(state.closure(), &endpoint_, pollset_set,
-                            nullptr /* channel_args */, server_addresses->addrs,
-                            grpc_core::ExecCtx::Get()->Now() + 1000);
+    grpc_tcp_client_connect(
+        state.closure(), &endpoint_, grpc_slice_allocator_create_unlimited(),
+        pollset_set, nullptr /* channel_args */, server_addresses->addrs,
+        grpc_core::ExecCtx::Get()->Now() + 1000);
     ASSERT_TRUE(PollUntilDone(
         &state,
         grpc_timespec_to_millis_round_up(gpr_inf_future(GPR_CLOCK_MONOTONIC))));
index fb03732..3f63709 100644 (file)
@@ -17,7 +17,9 @@
  */
 
 #include "src/core/ext/transport/chttp2/transport/stream_map.h"
+
 #include <grpc/support/log.h>
+
 #include "test/core/util/test_config.h"
 
 #define LOG_TEST(x) gpr_log(GPR_INFO, "%s", x)
index 57e5fa8..d1a6ec7 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
-#include <gmock/gmock.h>
 #include <stdlib.h>
 #include <string.h>
+
 #include <functional>
 #include <set>
 #include <thread>
 
+#include <gmock/gmock.h>
+
 #include "absl/strings/str_cat.h"
 
 #include <grpc/grpc.h>
@@ -35,7 +37,6 @@
 #include <grpc/support/log.h>
 #include <grpc/support/string_util.h>
 #include <grpc/support/time.h>
-
 #include <grpcpp/impl/codegen/service_type.h>
 #include <grpcpp/server_builder.h>
 
 #include "src/core/lib/security/security_connector/alts/alts_security_connector.h"
 #include "src/core/lib/slice/slice_string_helpers.h"
 #include "src/core/lib/surface/channel.h"
-
+#include "test/core/end2end/cq_verifier.h"
 #include "test/core/util/memory_counters.h"
 #include "test/core/util/port.h"
 #include "test/core/util/test_config.h"
 
-#include "test/core/end2end/cq_verifier.h"
-
 namespace {
 
 class TransportCounter {
index 5e00cc3..400529b 100644 (file)
 
 #include "test/core/util/test_config.h"
 
-static void test_varint(uint32_t value, uint32_t prefix_bits, uint8_t prefix_or,
+template <uint8_t kPrefixBits>
+static void test_varint(uint32_t value, uint8_t prefix_or,
                         const char* expect_bytes, size_t expect_length) {
-  uint32_t nbytes = GRPC_CHTTP2_VARINT_LENGTH(value, prefix_bits);
+  grpc_core::VarintWriter<kPrefixBits> w(value);
   grpc_slice expect =
       grpc_slice_from_copied_buffer(expect_bytes, expect_length);
   grpc_slice slice;
   gpr_log(GPR_DEBUG, "Test: 0x%08x", value);
-  GPR_ASSERT(nbytes == expect_length);
-  slice = grpc_slice_malloc(nbytes);
-  GRPC_CHTTP2_WRITE_VARINT(value, prefix_bits, prefix_or,
-                           GRPC_SLICE_START_PTR(slice), nbytes);
+  GPR_ASSERT(w.length() == expect_length);
+  slice = grpc_slice_malloc(w.length());
+  w.Write(prefix_or, GRPC_SLICE_START_PTR(slice));
   GPR_ASSERT(grpc_slice_eq(expect, slice));
   grpc_slice_unref(expect);
   grpc_slice_unref(slice);
 }
 
 #define TEST_VARINT(value, prefix_bits, prefix_or, expect) \
-  test_varint(value, prefix_bits, prefix_or, expect, sizeof(expect) - 1)
+  test_varint<prefix_bits>(value, prefix_or, expect, sizeof(expect) - 1)
 
 int main(int argc, char** argv) {
   grpc::testing::TestEnvironment env(argc, argv);
index 909a5b8..d42a575 100644 (file)
@@ -17,6 +17,7 @@
 #include "src/core/lib/transport/error_utils.h"
 
 #include <gtest/gtest.h>
+
 #include "absl/status/status.h"
 
 #include "src/core/lib/slice/slice_internal.h"
index 42ada41..53ec92e 100644 (file)
@@ -31,7 +31,7 @@
 #include <grpc/support/log.h>
 
 #include "src/core/ext/transport/chttp2/transport/bin_encoder.h"
-#include "src/core/ext/transport/chttp2/transport/hpack_table.h"
+#include "src/core/ext/transport/chttp2/transport/hpack_utils.h"
 #include "src/core/lib/gpr/string.h"
 #include "src/core/lib/iomgr/exec_ctx.h"
 #include "src/core/lib/slice/slice_internal.h"
@@ -314,61 +314,6 @@ static void test_user_data_works_for_allocated_md(void) {
   grpc_shutdown();
 }
 
-static void verify_ascii_header_size(const char* key, const char* value,
-                                     bool intern_key, bool intern_value) {
-  grpc_mdelem elem = grpc_mdelem_from_slices(
-      maybe_intern(grpc_slice_from_static_string(key), intern_key),
-      maybe_intern(grpc_slice_from_static_string(value), intern_value));
-  size_t elem_size = grpc_chttp2_get_size_in_hpack_table(elem, false);
-  size_t expected_size = 32 + strlen(key) + strlen(value);
-  GPR_ASSERT(expected_size == elem_size);
-  GRPC_MDELEM_UNREF(elem);
-}
-
-static void verify_binary_header_size(const char* key, const uint8_t* value,
-                                      size_t value_len, bool intern_key,
-                                      bool intern_value) {
-  grpc_mdelem elem = grpc_mdelem_from_slices(
-      maybe_intern(grpc_slice_from_static_string(key), intern_key),
-      maybe_intern(grpc_slice_from_static_buffer(value, value_len),
-                   intern_value));
-  GPR_ASSERT(grpc_is_binary_header(GRPC_MDKEY(elem)));
-  size_t elem_size = grpc_chttp2_get_size_in_hpack_table(elem, false);
-  grpc_slice value_slice = grpc_slice_from_copied_buffer(
-      reinterpret_cast<const char*>(value), value_len);
-  grpc_slice base64_encoded = grpc_chttp2_base64_encode(value_slice);
-  size_t expected_size = 32 + strlen(key) + GRPC_SLICE_LENGTH(base64_encoded);
-  GPR_ASSERT(expected_size == elem_size);
-  grpc_slice_unref_internal(value_slice);
-  grpc_slice_unref_internal(base64_encoded);
-  GRPC_MDELEM_UNREF(elem);
-}
-
-#define BUFFER_SIZE 64
-static void test_mdelem_sizes_in_hpack(bool intern_key, bool intern_value) {
-  gpr_log(GPR_INFO, "test_mdelem_size: intern_key=%d intern_value=%d",
-          intern_key, intern_value);
-  grpc_init();
-  grpc_core::ExecCtx exec_ctx;
-
-  uint8_t binary_value[BUFFER_SIZE] = {0};
-  for (uint8_t i = 0; i < BUFFER_SIZE; i++) {
-    binary_value[i] = i;
-  }
-
-  verify_ascii_header_size("hello", "world", intern_key, intern_value);
-  verify_ascii_header_size("hello", "worldxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx",
-                           intern_key, intern_value);
-  verify_ascii_header_size(":scheme", "http", intern_key, intern_value);
-
-  for (uint8_t i = 0; i < BUFFER_SIZE; i++) {
-    verify_binary_header_size("hello-bin", binary_value, i, intern_key,
-                              intern_value);
-  }
-
-  grpc_shutdown();
-}
-
 static void test_copied_static_metadata(bool dup_key, bool dup_value) {
   gpr_log(GPR_INFO, "test_static_metadata: dup_key=%d dup_value=%d", dup_key,
           dup_value);
@@ -465,7 +410,6 @@ int main(int argc, char** argv) {
       test_create_many_ephemeral_metadata(k, v);
       test_identity_laws(k, v);
       test_spin_creating_the_same_thing(k, v);
-      test_mdelem_sizes_in_hpack(k, v);
       test_copied_static_metadata(k, v);
     }
   }
index ddc20da..b41a9b0 100644 (file)
 #include <float.h>
 #include <math.h>
 
+#include <gtest/gtest.h>
+
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/string_util.h>
 
-#include <gtest/gtest.h>
 #include "src/core/lib/gpr/string.h"
 #include "test/core/util/test_config.h"
 
index c094390..bf225dc 100644 (file)
  *
  */
 
+#include "src/core/lib/transport/static_metadata.h"
+
 #include <gtest/gtest.h>
 
 #include <grpc/grpc.h>
 
 #include "src/core/lib/transport/metadata.h"
-#include "src/core/lib/transport/static_metadata.h"
 #include "test/core/util/test_config.h"
 
 namespace grpc_core {
index 06deb1f..ef7e617 100644 (file)
@@ -17,7 +17,9 @@
  */
 
 #include "src/core/lib/transport/status_conversion.h"
+
 #include <grpc/support/log.h>
+
 #include "test/core/util/test_config.h"
 
 #define GRPC_STATUS_TO_HTTP2_ERROR(a, b) \
index d2e2631..720c3eb 100644 (file)
  */
 
 #include "src/core/lib/transport/status_metadata.h"
-#include "src/core/lib/transport/static_metadata.h"
-#include "test/core/util/test_config.h"
 
 #include <gtest/gtest.h>
 
+#include "src/core/lib/transport/static_metadata.h"
+#include "test/core/util/test_config.h"
+
 namespace {
 
 TEST(GetStatusCodeFromMetadata, OK) {
index ca8140c..e7b7604 100644 (file)
  *
  */
 
-#include "src/core/lib/transport/transport.h"
-
-#include "test/core/util/test_config.h"
-
 #include <grpc/grpc.h>
 #include <grpc/support/log.h>
 
+#include "src/core/lib/transport/transport.h"
+#include "test/core/util/test_config.h"
+
 static void do_nothing(void* /*arg*/, grpc_error_handle /*error*/) {}
 
 int main(int argc, char** argv) {
index bfe4a88..c7c86fb 100644 (file)
  *
  */
 
+#include <grpc/support/alloc.h>
+#include <grpc/support/log.h>
+
 #include "src/core/tsi/alts/crypt/gsec.h"
 #include "test/core/tsi/alts/crypt/gsec_test_util.h"
 #include "test/core/util/test_config.h"
 
-#include <grpc/support/alloc.h>
-#include <grpc/support/log.h>
-
 const size_t kTestMinTagLengthForCorruption = 8;
 const size_t kTestNumCrypters = 3;
 const size_t kTestMaxSlices = 5;
index 9e444e3..5f24e9a 100644 (file)
  * limitations under the License.
  *
  */
+#include <sstream>
+
+#include "absl/flags/flag.h"
+
 #include <grpc/support/log.h>
 #include <grpcpp/impl/codegen/service_type.h>
 #include <grpcpp/server_builder.h>
 
-#include <sstream>
-
-#include "absl/flags/flag.h"
 #include "test/core/tsi/alts/fake_handshaker/fake_handshaker_server.h"
 #include "test/core/util/test_config.h"
 #include "test/cpp/util/test_config.h"
index 9c5b790..80fd95f 100644 (file)
  *
  */
 
+#include "src/core/tsi/alts/frame_protector/alts_counter.h"
+
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 
-#include "src/core/tsi/alts/frame_protector/alts_counter.h"
 #include "test/core/tsi/alts/crypt/gsec_test_util.h"
 
 const size_t kSmallCounterSize = 4;
index 02b7ebd..0528544 100644 (file)
@@ -16,6 +16,8 @@
  *
  */
 
+#include "src/core/tsi/alts/frame_protector/alts_crypter.h"
+
 #include <stdio.h>
 #include <stdlib.h>
 #include <string.h>
@@ -23,7 +25,6 @@
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 
-#include "src/core/tsi/alts/frame_protector/alts_crypter.h"
 #include "test/core/tsi/alts/crypt/gsec_test_util.h"
 
 static void alts_crypter_test_random_seal_unseal(alts_crypter* server_seal,
index 7cca2c2..3b75ecf 100644 (file)
  *
  */
 
-#include <grpc/support/alloc.h>
-#include <grpc/support/log.h>
+#include "src/core/tsi/alts/frame_protector/alts_frame_protector.h"
 
 #include <stdbool.h>
 
+#include <grpc/support/alloc.h>
+#include <grpc/support/log.h>
+
 #include "src/core/tsi/alts/crypt/gsec.h"
-#include "src/core/tsi/alts/frame_protector/alts_frame_protector.h"
 #include "src/core/tsi/transport_security_interface.h"
 #include "test/core/tsi/alts/crypt/gsec_test_util.h"
 #include "test/core/tsi/transport_security_test_lib.h"
index 8bfa530..0dee7c2 100644 (file)
@@ -16,6 +16,8 @@
  *
  */
 
+#include "src/core/tsi/alts/frame_protector/frame_handler.h"
+
 #include <stdint.h>
 #include <stdio.h>
 #include <string.h>
@@ -24,7 +26,6 @@
 #include <grpc/support/log.h>
 
 #include "src/core/lib/gpr/useful.h"
-#include "src/core/tsi/alts/frame_protector/frame_handler.h"
 #include "test/core/tsi/alts/crypt/gsec_test_util.h"
 
 const size_t kFrameHandlerTestBufferSize = 1024;
index 4cd8782..a5a1269 100644 (file)
@@ -19,7 +19,6 @@
 #include <grpc/support/port_platform.h>
 
 #include <fcntl.h>
-#include <gmock/gmock.h>
 #include <netinet/in.h>
 #include <stdlib.h>
 #include <string.h>
 #include <sys/stat.h>
 #include <sys/types.h>
 #include <unistd.h>
+
 #include <functional>
 #include <set>
 #include <thread>
 
+#include <gmock/gmock.h>
+
 #include "absl/memory/memory.h"
 #include "absl/strings/str_cat.h"
 
@@ -41,7 +43,6 @@
 #include <grpc/support/log.h>
 #include <grpc/support/string_util.h>
 #include <grpc/support/time.h>
-
 #include <grpcpp/impl/codegen/service_type.h>
 #include <grpcpp/server_builder.h>
 
 #include "src/core/lib/security/credentials/credentials.h"
 #include "src/core/lib/security/security_connector/alts/alts_security_connector.h"
 #include "src/core/lib/slice/slice_string_helpers.h"
-
+#include "test/core/end2end/cq_verifier.h"
 #include "test/core/tsi/alts/fake_handshaker/fake_handshaker_server.h"
 #include "test/core/util/memory_counters.h"
 #include "test/core/util/port.h"
 #include "test/core/util/test_config.h"
 
-#include "test/core/end2end/cq_verifier.h"
-
 namespace {
 
 const int kFakeHandshakeServerMaxConcurrentStreams = 40;
index 80c0b5d..2a36f0a 100644 (file)
  *
  */
 
+#include "src/core/tsi/alts/handshaker/alts_handshaker_client.h"
+
 #include "upb/upb.hpp"
 
 #include <grpc/grpc.h>
 
-#include "src/core/tsi/alts/handshaker/alts_handshaker_client.h"
 #include "src/core/tsi/alts/handshaker/alts_shared_resource.h"
 #include "src/core/tsi/alts/handshaker/alts_tsi_handshaker.h"
 #include "src/core/tsi/alts/handshaker/alts_tsi_handshaker_private.h"
index 95a3dce..0e373a0 100644 (file)
@@ -16,6 +16,8 @@
  *
  */
 
+#include "src/core/tsi/alts/handshaker/alts_tsi_handshaker.h"
+
 #include <stdio.h>
 #include <stdlib.h>
 
@@ -27,7 +29,6 @@
 #include "src/core/lib/gprpp/thd.h"
 #include "src/core/tsi/alts/handshaker/alts_handshaker_client.h"
 #include "src/core/tsi/alts/handshaker/alts_shared_resource.h"
-#include "src/core/tsi/alts/handshaker/alts_tsi_handshaker.h"
 #include "src/core/tsi/alts/handshaker/alts_tsi_handshaker_private.h"
 #include "src/core/tsi/transport_security_grpc.h"
 #include "src/proto/grpc/gcp/altscontext.upb.h"
index 528cb9b..54fb0cd 100644 (file)
  *
  */
 
+#include "src/core/tsi/alts/handshaker/alts_tsi_utils.h"
+
 #include "upb/upb.hpp"
 
-#include "src/core/tsi/alts/handshaker/alts_tsi_utils.h"
 #include "test/core/tsi/alts/handshaker/alts_handshaker_service_api_test_lib.h"
 #include "test/core/util/test_config.h"
 
index bc147d2..7579ed1 100644 (file)
  *
  */
 
+#include "src/core/tsi/alts/handshaker/transport_security_common_api.h"
+
 #include <stdbool.h>
 #include <stdio.h>
 #include <stdlib.h>
 
-#include "src/core/tsi/alts/handshaker/transport_security_common_api.h"
-
 const size_t kMaxRpcVersionMajor = 3;
 const size_t kMaxRpcVersionMinor = 2;
 const size_t kMinRpcVersionMajor = 2;
index 7d7c518..8b14ea0 100644 (file)
@@ -16,6 +16,8 @@
  *
  */
 
+#include "src/core/tsi/alts/zero_copy_frame_protector/alts_grpc_record_protocol.h"
+
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 
@@ -23,7 +25,6 @@
 #include "src/core/lib/slice/slice_internal.h"
 #include "src/core/tsi/alts/zero_copy_frame_protector/alts_grpc_integrity_only_record_protocol.h"
 #include "src/core/tsi/alts/zero_copy_frame_protector/alts_grpc_privacy_integrity_record_protocol.h"
-#include "src/core/tsi/alts/zero_copy_frame_protector/alts_grpc_record_protocol.h"
 #include "src/core/tsi/alts/zero_copy_frame_protector/alts_iovec_record_protocol.h"
 #include "test/core/tsi/alts/crypt/gsec_test_util.h"
 #include "test/core/util/test_config.h"
index 8b0e39c..9096b66 100644 (file)
  *
  */
 
+#include "src/core/tsi/alts/zero_copy_frame_protector/alts_iovec_record_protocol.h"
+
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 
-#include "src/core/tsi/alts/zero_copy_frame_protector/alts_iovec_record_protocol.h"
 #include "test/core/tsi/alts/crypt/gsec_test_util.h"
 
 constexpr size_t kMaxDataSize = 1024;
index 8bd9eab..62b3a4b 100644 (file)
@@ -16,6 +16,8 @@
  *
  */
 
+#include "src/core/tsi/alts/zero_copy_frame_protector/alts_zero_copy_grpc_protector.h"
+
 #include <grpc/slice_buffer.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
@@ -23,7 +25,6 @@
 #include "src/core/lib/iomgr/exec_ctx.h"
 #include "src/core/lib/slice/slice_internal.h"
 #include "src/core/tsi/alts/crypt/gsec.h"
-#include "src/core/tsi/alts/zero_copy_frame_protector/alts_zero_copy_grpc_protector.h"
 #include "src/core/tsi/transport_security_grpc.h"
 #include "test/core/tsi/alts/crypt/gsec_test_util.h"
 #include "test/core/util/test_config.h"
index ac491ab..9e1aaf2 100644 (file)
  *
  */
 
+#include "src/core/tsi/fake_transport_security.h"
+
 #include <stdbool.h>
 #include <stdio.h>
 #include <string.h>
 
+#include <grpc/grpc.h>
+#include <grpc/support/alloc.h>
+#include <grpc/support/log.h>
+
 #include "src/core/lib/security/security_connector/security_connector.h"
-#include "src/core/tsi/fake_transport_security.h"
 #include "src/core/tsi/transport_security.h"
 #include "test/core/tsi/transport_security_test_lib.h"
 #include "test/core/util/test_config.h"
 
-#include <grpc/grpc.h>
-#include <grpc/support/alloc.h>
-#include <grpc/support/log.h>
-
 typedef struct fake_tsi_test_fixture {
   tsi_test_fixture base;
 } fake_tsi_test_fixture;
index 33f3467..353d75f 100644 (file)
  *
  */
 
+#include "src/core/tsi/ssl/session_cache/ssl_session_cache.h"
+
 #include <string>
 #include <unordered_set>
 
-#include "src/core/tsi/ssl/session_cache/ssl_session_cache.h"
-#include "test/core/util/test_config.h"
+#include <gtest/gtest.h>
 
 #include <grpc/grpc.h>
 #include <grpc/support/log.h>
-#include <gtest/gtest.h>
+
+#include "test/core/util/test_config.h"
 
 namespace grpc_core {
 
index 87f8dfb..eeec469 100644 (file)
 
 #include "src/core/tsi/ssl_transport_security.h"
 
+#include <stdbool.h>
+#include <stdio.h>
+#include <string.h>
+
 #include <grpc/grpc.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/string_util.h>
-#include <stdbool.h>
-#include <stdio.h>
-#include <string.h>
 
 #include "src/core/lib/iomgr/load_file.h"
 #include "src/core/lib/security/security_connector/security_connector.h"
@@ -35,6 +36,7 @@
 
 extern "C" {
 #include <openssl/crypto.h>
+#include <openssl/err.h>
 #include <openssl/pem.h>
 }
 
@@ -705,6 +707,17 @@ void ssl_tsi_test_do_round_trip_for_all_configs() {
   gpr_free(bit_array);
 }
 
+void ssl_tsi_test_do_round_trip_with_error_on_stack() {
+  gpr_log(GPR_INFO, "ssl_tsi_test_do_round_trip_with_error_on_stack");
+  // Invoke an SSL function that causes an error, and ensure the error
+  // makes it to the stack.
+  GPR_ASSERT(!EC_KEY_new_by_curve_name(NID_rsa));
+  GPR_ASSERT(ERR_peek_error() != 0);
+  tsi_test_fixture* fixture = ssl_tsi_test_fixture_create();
+  tsi_test_do_round_trip(fixture);
+  tsi_test_fixture_destroy(fixture);
+}
+
 static bool is_slow_build() {
 #if defined(GPR_ARCH_32) || defined(__APPLE__)
   return true;
@@ -1035,6 +1048,7 @@ int main(int argc, char** argv) {
     ssl_tsi_test_do_handshake_alpn_client_server_ok();
     ssl_tsi_test_do_handshake_session_cache();
     ssl_tsi_test_do_round_trip_for_all_configs();
+    ssl_tsi_test_do_round_trip_with_error_on_stack();
     ssl_tsi_test_do_round_trip_odd_buffer_size();
     ssl_tsi_test_handshaker_factory_internals();
     ssl_tsi_test_duplicate_root_certificates();
index eb88eaf..6000dae 100644 (file)
 
 #include <string>
 
+#include <openssl/crypto.h>
+
 #include "absl/strings/str_format.h"
 
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/string_util.h>
 
-#include <openssl/crypto.h>
-
 #include "src/core/lib/gpr/string.h"
 #include "src/core/lib/gpr/useful.h"
 #include "src/core/tsi/fake_transport_security.h"
index f0c428a..307ca57 100644 (file)
@@ -16,6 +16,8 @@
  *
  */
 
+#include "test/core/tsi/transport_security_test_lib.h"
+
 #include <stdio.h>
 #include <stdlib.h>
 #include <string.h>
@@ -25,7 +27,6 @@
 #include <grpc/support/log.h>
 
 #include "src/core/lib/security/transport/tsi_error.h"
-#include "test/core/tsi/transport_security_test_lib.h"
 
 static void notification_signal(tsi_test_fixture* fixture) {
   gpr_mu_lock(&fixture->mu);
index b6a431f..358b94d 100644 (file)
 #ifndef GRPC_TEST_CORE_TSI_TRANSPORT_SECURITY_TEST_LIB_H_
 #define GRPC_TEST_CORE_TSI_TRANSPORT_SECURITY_TEST_LIB_H_
 
-#include "src/core/tsi/transport_security_interface.h"
-
 #include <grpc/support/sync.h>
 
+#include "src/core/tsi/transport_security_interface.h"
+
 #define TSI_TEST_TINY_HANDSHAKE_BUFFER_SIZE 32
 #define TSI_TEST_SMALL_HANDSHAKE_BUFFER_SIZE 128
 #define TSI_TEST_SMALL_READ_BUFFER_ALLOCATED_SIZE 41
index 5f8fcee..71b32b2 100644 (file)
 
 #include "src/core/lib/uri/uri_parser.h"
 
+#include <gmock/gmock.h>
+#include <gtest/gtest.h>
+
 #include "absl/strings/str_join.h"
 #include "absl/strings/str_split.h"
 
-#include <gmock/gmock.h>
 #include <grpc/grpc.h>
 #include <grpc/support/log.h>
-#include <gtest/gtest.h>
 
 #include "test/core/util/test_config.h"
 
index 84eea84..be970d8 100644 (file)
@@ -46,6 +46,7 @@ grpc_cc_library(
         "port_server_client.cc",
         "reconnect_server.cc",
         "resolve_localhost_ip46.cc",
+        "resource_user_util.cc",
         "slice_splitter.cc",
         "subprocess_posix.cc",
         "subprocess_windows.cc",
@@ -69,6 +70,7 @@ grpc_cc_library(
         "port_server_client.h",
         "reconnect_server.h",
         "resolve_localhost_ip46.h",
+        "resource_user_util.h",
         "slice_splitter.h",
         "subprocess.h",
         "test_config.h",
@@ -79,6 +81,7 @@ grpc_cc_library(
     external_deps = [
         "absl/debugging:failure_signal_handler",
         "absl/debugging:symbolize",
+        "absl/strings:str_format",
     ],
     language = "C++",
     deps = [
index 23e52e6..c91a2f6 100644 (file)
@@ -31,6 +31,7 @@
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/string_util.h>
+
 #include "src/core/lib/gpr/string.h"
 
 typedef enum { ARGTYPE_INT, ARGTYPE_BOOL, ARGTYPE_STRING } argtype;
index c1eb5e3..3a1e6e7 100644 (file)
  *
  */
 
+#include "test/core/util/cmdline.h"
+
 #include <string.h>
 
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 
 #include "src/core/lib/gpr/useful.h"
-#include "test/core/util/cmdline.h"
 #include "test/core/util/test_config.h"
 
 #define LOG_TEST() gpr_log(GPR_INFO, "test at %s:%d", __FILE__, __LINE__)
index ca5201e..d2180c2 100644 (file)
  */
 
 #include <dirent.h>
-#include <grpc/grpc.h>
-#include <grpc/support/alloc.h>
-#include <grpc/support/log.h>
-#include <gtest/gtest.h>
 #include <stdbool.h>
 #include <stdio.h>
 #include <sys/types.h>
 
+#include <gtest/gtest.h>
+
 #include "absl/flags/flag.h"
+
+#include <grpc/grpc.h>
+#include <grpc/support/alloc.h>
+#include <grpc/support/log.h>
+
 #include "src/core/lib/gpr/env.h"
 #include "src/core/lib/iomgr/load_file.h"
 #include "test/core/util/test_config.h"
index afb2c16..f60f705 100644 (file)
@@ -16,6 +16,8 @@
  *
  */
 
+#include <grpc/support/port_platform.h>
+
 #include "test/core/util/histogram.h"
 
 #include <math.h>
@@ -24,7 +26,6 @@
 
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
-#include <grpc/support/port_platform.h>
 
 #include "src/core/lib/gpr/useful.h"
 
index 9d4985e..9e87286 100644 (file)
@@ -20,6 +20,7 @@
 #define GRPC_SUPPORT_HISTOGRAM_H
 
 #include <grpc/support/port_platform.h>
+
 #include <stddef.h>
 
 #ifdef __cplusplus
index b96ac7d..3ff92a3 100644 (file)
@@ -17,6 +17,7 @@
  */
 
 #include "test/core/util/histogram.h"
+
 #include <grpc/support/log.h>
 
 #define LOG_TEST(x) gpr_log(GPR_INFO, "%s", x);
index ddd8d2f..0deb1a4 100644 (file)
  *
  */
 
+#include "test/core/util/memory_counters.h"
+
 #include <inttypes.h>
 #include <stdint.h>
+#include <stdio.h>
 #include <string.h>
 
 #include <grpc/grpc.h>
@@ -28,9 +31,6 @@
 
 #include "src/core/lib/gpr/alloc.h"
 #include "src/core/lib/surface/init.h"
-#include "test/core/util/memory_counters.h"
-
-#include <stdio.h>
 
 static struct grpc_memory_counters g_memory_counters;
 static bool g_memory_counter_enabled;
index 7e6a712..3071b88 100644 (file)
@@ -27,8 +27,8 @@ class MockAuthorizationEndpoint : public grpc_endpoint {
                             absl::string_view peer_uri)
       : local_address_(local_uri), peer_address_(peer_uri) {
     static constexpr grpc_endpoint_vtable vtable = {
-        nullptr, nullptr, nullptr, nullptr,         nullptr, nullptr,
-        nullptr, nullptr, GetPeer, GetLocalAddress, nullptr, nullptr};
+        nullptr, nullptr, nullptr,         nullptr, nullptr, nullptr,
+        nullptr, GetPeer, GetLocalAddress, nullptr, nullptr};
     grpc_endpoint::vtable = &vtable;
   }
 
index af24d5f..f3fa7a3 100644 (file)
  *
  */
 
-/* With the addition of a libuv endpoint, sockaddr.h now includes uv.h when
-   using that endpoint. Because of various transitive includes in uv.h,
-   including windows.h on Windows, uv.h must be included before other system
-   headers. Therefore, sockaddr.h must always be included first */
-#include "src/core/lib/iomgr/sockaddr.h"
+#include "test/core/util/mock_endpoint.h"
 
 #include <inttypes.h>
 
 
 #include "absl/strings/str_format.h"
 
-#include "test/core/util/mock_endpoint.h"
-
 #include <grpc/support/alloc.h>
 #include <grpc/support/string_util.h>
+
 #include "src/core/lib/iomgr/sockaddr.h"
 
 typedef struct mock_endpoint {
@@ -41,7 +36,7 @@ typedef struct mock_endpoint {
   grpc_slice_buffer read_buffer;
   grpc_slice_buffer* on_read_out;
   grpc_closure* on_read;
-  grpc_resource_user* resource_user;
+  grpc_slice_allocator* slice_allocator;
 } mock_endpoint;
 
 static void me_read(grpc_endpoint* ep, grpc_slice_buffer* slices,
@@ -86,14 +81,13 @@ static void me_shutdown(grpc_endpoint* ep, grpc_error_handle why) {
     m->on_read = nullptr;
   }
   gpr_mu_unlock(&m->mu);
-  grpc_resource_user_shutdown(m->resource_user);
   GRPC_ERROR_UNREF(why);
 }
 
 static void me_destroy(grpc_endpoint* ep) {
   mock_endpoint* m = reinterpret_cast<mock_endpoint*>(ep);
   grpc_slice_buffer_destroy(&m->read_buffer);
-  grpc_resource_user_unref(m->resource_user);
+  grpc_slice_allocator_destroy(m->slice_allocator);
   gpr_mu_destroy(&m->mu);
   gpr_free(m);
 }
@@ -106,11 +100,6 @@ static absl::string_view me_get_local_address(grpc_endpoint* /*ep*/) {
   return "fake:mock_endpoint";
 }
 
-static grpc_resource_user* me_get_resource_user(grpc_endpoint* ep) {
-  mock_endpoint* m = reinterpret_cast<mock_endpoint*>(ep);
-  return m->resource_user;
-}
-
 static int me_get_fd(grpc_endpoint* /*ep*/) { return -1; }
 
 static bool me_can_track_err(grpc_endpoint* /*ep*/) { return false; }
@@ -122,19 +111,16 @@ static const grpc_endpoint_vtable vtable = {me_read,
                                             me_delete_from_pollset_set,
                                             me_shutdown,
                                             me_destroy,
-                                            me_get_resource_user,
                                             me_get_peer,
                                             me_get_local_address,
                                             me_get_fd,
                                             me_can_track_err};
 
-grpc_endpoint* grpc_mock_endpoint_create(void (*on_write)(grpc_slice slice),
-                                         grpc_resource_quota* resource_quota) {
+grpc_endpoint* grpc_mock_endpoint_create(
+    void (*on_write)(grpc_slice slice), grpc_slice_allocator* slice_allocator) {
   mock_endpoint* m = static_cast<mock_endpoint*>(gpr_malloc(sizeof(*m)));
   m->base.vtable = &vtable;
-  std::string name =
-      absl::StrFormat("mock_endpoint_%" PRIxPTR, reinterpret_cast<intptr_t>(m));
-  m->resource_user = grpc_resource_user_create(resource_quota, name.c_str());
+  m->slice_allocator = slice_allocator;
   grpc_slice_buffer_init(&m->read_buffer);
   gpr_mu_init(&m->mu);
   m->on_write = on_write;
index 8e58d65..dbb6c0f 100644 (file)
@@ -22,7 +22,7 @@
 #include "src/core/lib/iomgr/endpoint.h"
 
 grpc_endpoint* grpc_mock_endpoint_create(void (*on_write)(grpc_slice slice),
-                                         grpc_resource_quota* resource_quota);
+                                         grpc_slice_allocator* slice_allocator);
 void grpc_mock_endpoint_put_read(grpc_endpoint* ep, grpc_slice slice);
 
 #endif
index 2f376d6..fa0f04f 100644 (file)
@@ -19,8 +19,8 @@
 #include <stdbool.h>
 
 #include <grpc/grpc.h>
-
 #include <grpc/support/log.h>
+
 #include "src/core/lib/iomgr/exec_ctx.h"
 #include "src/core/lib/iomgr/load_file.h"
 
index cd64843..a65ef99 100644 (file)
@@ -17,6 +17,7 @@
  */
 
 #include "test/core/util/parse_hexstring.h"
+
 #include <grpc/support/log.h>
 
 grpc_slice parse_hexstring(const char* hexstring) {
index 635b0ba..50534f7 100644 (file)
  *
  */
 
-/* With the addition of a libuv endpoint, sockaddr.h now includes uv.h when
-   using that endpoint. Because of various transitive includes in uv.h,
-   including windows.h on Windows, uv.h must be included before other system
-   headers. Therefore, sockaddr.h must always be included first */
-#include "src/core/lib/iomgr/sockaddr.h"
-
 #include "test/core/util/passthru_endpoint.h"
 
 #include <inttypes.h>
 
 #include <grpc/support/alloc.h>
 #include <grpc/support/string_util.h>
-#include "src/core/lib/iomgr/sockaddr.h"
 
+#include "src/core/lib/iomgr/sockaddr.h"
 #include "src/core/lib/slice/slice_internal.h"
+#include "test/core/util/resource_user_util.h"
 
 typedef struct passthru_endpoint passthru_endpoint;
 
@@ -45,7 +40,7 @@ typedef struct {
   grpc_slice_buffer read_buffer;
   grpc_slice_buffer* on_read_out;
   grpc_closure* on_read;
-  grpc_resource_user* resource_user;
+  grpc_slice_allocator* slice_allocator;
 } half;
 
 struct passthru_endpoint {
@@ -131,7 +126,6 @@ static void me_shutdown(grpc_endpoint* ep, grpc_error_handle why) {
     m->on_read = nullptr;
   }
   gpr_mu_unlock(&m->parent->mu);
-  grpc_resource_user_shutdown(m->resource_user);
   GRPC_ERROR_UNREF(why);
 }
 
@@ -144,8 +138,8 @@ static void me_destroy(grpc_endpoint* ep) {
     grpc_passthru_endpoint_stats_destroy(p->stats);
     grpc_slice_buffer_destroy_internal(&p->client.read_buffer);
     grpc_slice_buffer_destroy_internal(&p->server.read_buffer);
-    grpc_resource_user_unref(p->client.resource_user);
-    grpc_resource_user_unref(p->server.resource_user);
+    grpc_slice_allocator_destroy(p->client.slice_allocator);
+    grpc_slice_allocator_destroy(p->server.slice_allocator);
     gpr_free(p);
   } else {
     gpr_mu_unlock(&p->mu);
@@ -170,11 +164,6 @@ static int me_get_fd(grpc_endpoint* /*ep*/) { return -1; }
 
 static bool me_can_track_err(grpc_endpoint* /*ep*/) { return false; }
 
-static grpc_resource_user* me_get_resource_user(grpc_endpoint* ep) {
-  half* m = reinterpret_cast<half*>(ep);
-  return m->resource_user;
-}
-
 static const grpc_endpoint_vtable vtable = {
     me_read,
     me_write,
@@ -183,7 +172,6 @@ static const grpc_endpoint_vtable vtable = {
     me_delete_from_pollset_set,
     me_shutdown,
     me_destroy,
-    me_get_resource_user,
     me_get_peer,
     me_get_local_address,
     me_get_fd,
@@ -191,7 +179,7 @@ static const grpc_endpoint_vtable vtable = {
 };
 
 static void half_init(half* m, passthru_endpoint* parent,
-                      grpc_resource_quota* resource_quota,
+                      grpc_slice_allocator* slice_allocator,
                       const char* half_name) {
   m->base.vtable = &vtable;
   m->parent = parent;
@@ -199,12 +187,11 @@ static void half_init(half* m, passthru_endpoint* parent,
   m->on_read = nullptr;
   std::string name =
       absl::StrFormat("passthru_endpoint_%s_%p", half_name, parent);
-  m->resource_user = grpc_resource_user_create(resource_quota, name.c_str());
+  m->slice_allocator = slice_allocator;
 }
 
 void grpc_passthru_endpoint_create(grpc_endpoint** client,
                                    grpc_endpoint** server,
-                                   grpc_resource_quota* resource_quota,
                                    grpc_passthru_endpoint_stats* stats) {
   passthru_endpoint* m =
       static_cast<passthru_endpoint*>(gpr_malloc(sizeof(*m)));
@@ -216,8 +203,8 @@ void grpc_passthru_endpoint_create(grpc_endpoint** client,
     gpr_ref(&stats->refs);
     m->stats = stats;
   }
-  half_init(&m->client, m, resource_quota, "client");
-  half_init(&m->server, m, resource_quota, "server");
+  half_init(&m->client, m, grpc_slice_allocator_create_unlimited(), "client");
+  half_init(&m->server, m, grpc_slice_allocator_create_unlimited(), "server");
   gpr_mu_init(&m->mu);
   *client = &m->client.base;
   *server = &m->server.base;
index a46c775..bc65355 100644 (file)
@@ -16,8 +16,8 @@
  *
  */
 
-#ifndef MOCK_ENDPOINT_H
-#define MOCK_ENDPOINT_H
+#ifndef PASSTHRU_ENDPOINT_H
+#define PASSTHRU_ENDPOINT_H
 
 #include <grpc/support/atm.h>
 
@@ -33,11 +33,10 @@ typedef struct {
 
 void grpc_passthru_endpoint_create(grpc_endpoint** client,
                                    grpc_endpoint** server,
-                                   grpc_resource_quota* resource_quota,
                                    grpc_passthru_endpoint_stats* stats);
 
 grpc_passthru_endpoint_stats* grpc_passthru_endpoint_stats_create();
 
 void grpc_passthru_endpoint_stats_destroy(grpc_passthru_endpoint_stats* stats);
 
-#endif
+#endif  // PASSTHRU_ENDPOINT_H
index 391f472..5a2e062 100644 (file)
  */
 
 #include "src/core/lib/iomgr/port.h"
+
 #include "test/core/util/test_config.h"
 #if defined(GRPC_TEST_PICK_PORT)
 
-#include "test/core/util/port.h"
-
 #include <stdbool.h>
 #include <stdio.h>
 #include <string.h>
@@ -34,6 +33,7 @@
 #include "src/core/lib/address_utils/sockaddr_utils.h"
 #include "src/core/lib/http/httpcli.h"
 #include "src/core/lib/iomgr/resolve_address.h"
+#include "test/core/util/port.h"
 #include "test/core/util/port_server_client.h"
 
 static int* chosen_ports = nullptr;
index 5e043e7..6d32aeb 100644 (file)
  * runs in a separate container) the framework takes a round-robin pick of a
  * port within certain range. There is no need to recycle ports.
  */
+#include <stdlib.h>
+
 #include <grpc/support/atm.h>
 #include <grpc/support/log.h>
 #include <grpc/support/time.h>
-#include <stdlib.h>
+
 #include "src/core/lib/iomgr/port.h"
 #include "test/core/util/test_config.h"
 #if defined(GRPC_PORT_ISOLATED_RUNTIME)
index 3747187..70a253f 100644 (file)
  */
 
 #include <grpc/support/port_platform.h>
+
 #include "test/core/util/test_config.h"
 
 #ifdef GRPC_TEST_PICK_PORT
-#include "test/core/util/port_server_client.h"
-
 #include <math.h>
 #include <string.h>
 
@@ -33,6 +32,7 @@
 #include <grpc/support/time.h>
 
 #include "src/core/lib/http/httpcli.h"
+#include "test/core/util/port_server_client.h"
 
 typedef struct freereq {
   gpr_mu* mu = nullptr;
@@ -92,7 +92,6 @@ void grpc_free_port_using_server(int port) {
                      GRPC_CLOSURE_CREATE(freed_port_from_server, &pr,
                                          grpc_schedule_on_exec_ctx),
                      &rsp);
-    grpc_resource_quota_unref_internal(resource_quota);
     grpc_core::ExecCtx::Get()->Flush();
     gpr_mu_lock(pr.mu);
     while (!pr.done) {
@@ -175,7 +174,6 @@ static void got_port_from_server(void* arg, grpc_error_handle error) {
                      GRPC_CLOSURE_CREATE(got_port_from_server, pr,
                                          grpc_schedule_on_exec_ctx),
                      &pr->response);
-    grpc_resource_quota_unref_internal(resource_quota);
     return;
   }
   GPR_ASSERT(response);
@@ -225,7 +223,6 @@ int grpc_pick_port_using_server(void) {
                      GRPC_CLOSURE_CREATE(got_port_from_server, &pr,
                                          grpc_schedule_on_exec_ctx),
                      &pr.response);
-    grpc_resource_quota_unref_internal(resource_quota);
     grpc_core::ExecCtx::Get()->Flush();
     gpr_mu_lock(pr.mu);
     while (pr.port == -1) {
index d23eb10..93a149b 100644 (file)
 
 #include "test/core/util/reconnect_server.h"
 
+#include <string.h>
+
+#include "absl/strings/string_view.h"
+
 #include <grpc/grpc.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/string_util.h>
 #include <grpc/support/sync.h>
 #include <grpc/support/time.h>
-#include <string.h>
 
-#include "absl/strings/string_view.h"
 #include "src/core/lib/iomgr/endpoint.h"
 #include "src/core/lib/iomgr/sockaddr.h"
 #include "src/core/lib/iomgr/tcp_server.h"
index f7264dd..912624f 100644 (file)
@@ -21,6 +21,7 @@
 
 #include <grpc/support/sync.h>
 #include <grpc/support/time.h>
+
 #include "test/core/util/test_tcp_server.h"
 
 typedef struct timestamp_list {
diff --git a/test/core/util/resource_user_util.cc b/test/core/util/resource_user_util.cc
new file mode 100644 (file)
index 0000000..2fa609c
--- /dev/null
@@ -0,0 +1,43 @@
+// Copyright 2021 The gRPC Authors
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#include "test/core/util/resource_user_util.h"
+
+#include "absl/strings/str_format.h"
+
+grpc_resource_user* grpc_resource_user_create_unlimited(
+    grpc_resource_quota* resource_quota) {
+  if (resource_quota == nullptr) {
+    resource_quota = grpc_resource_quota_create("anonymous mock quota");
+  } else {
+    grpc_resource_quota_ref_internal(resource_quota);
+  }
+  grpc_resource_user* ru = nullptr;
+  ru = grpc_resource_user_create(
+      resource_quota, absl::StrFormat("mock_resource_user_%" PRIxPTR,
+                                      reinterpret_cast<intptr_t>(&ru))
+                          .c_str());
+  grpc_resource_quota_unref_internal(resource_quota);
+  return ru;
+}
+
+grpc_slice_allocator* grpc_slice_allocator_create_unlimited() {
+  grpc_resource_quota* resource_quota =
+      grpc_resource_quota_create("anonymous mock quota");
+  grpc_slice_allocator* slice_allocator = grpc_slice_allocator_create(
+      resource_quota,
+      absl::StrFormat("mock_resource_user_from_quota:%p", resource_quota));
+  grpc_resource_quota_unref(resource_quota);
+  return slice_allocator;
+}
diff --git a/test/core/util/resource_user_util.h b/test/core/util/resource_user_util.h
new file mode 100644 (file)
index 0000000..397c0a5
--- /dev/null
@@ -0,0 +1,24 @@
+// Copyright 2021 The gRPC Authors
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+#ifndef GRPC_TEST_CORE_UTIL_RESOURCE_USER_UTIL_H
+#define GRPC_TEST_CORE_UTIL_RESOURCE_USER_UTIL_H
+
+#include "src/core/lib/iomgr/resource_quota.h"
+
+grpc_resource_user* grpc_resource_user_create_unlimited(
+    grpc_resource_quota* resource_quota = nullptr);
+
+grpc_slice_allocator* grpc_slice_allocator_create_unlimited();
+
+#endif  // GRPC_TEST_CORE_UTIL_RESOURCE_USER_UTIL_H
index d75df70..3687fdd 100644 (file)
 
 #include "test/core/util/stack_tracer.h"
 
-#include <gtest/gtest.h>
 #include <string>
 
+#include <gtest/gtest.h>
+
 #include "absl/debugging/symbolize.h"
 #include "absl/strings/match.h"
 
index ab288d7..186256f 100644 (file)
@@ -60,7 +60,6 @@ gpr_subprocess* gpr_subprocess_create(int argc, const char** argv) {
     /* if we reach here, an error has occurred */
     gpr_log(GPR_ERROR, "execv '%s' failed: %s", exec_args[0], strerror(errno));
     _exit(1);
-    return nullptr;
   } else {
     r = static_cast<gpr_subprocess*>(gpr_zalloc(sizeof(gpr_subprocess)));
     r->pid = pid;
index d329524..7d69af1 100644 (file)
@@ -26,6 +26,7 @@
 
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
+
 #include "src/core/lib/gpr/string.h"
 #include "src/core/lib/gpr/string_windows.h"
 #include "test/core/util/subprocess.h"
index 1516615..09952c0 100644 (file)
@@ -18,7 +18,6 @@
 
 #include "test/core/util/test_config.h"
 
-#include <grpc/impl/codegen/gpr_types.h>
 #include <inttypes.h>
 #include <signal.h>
 #include <stdbool.h>
 #include <stdlib.h>
 #include <string.h>
 
+#include "absl/debugging/failure_signal_handler.h"
+#include "absl/debugging/symbolize.h"
+
 #include <grpc/grpc.h>
+#include <grpc/impl/codegen/gpr_types.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 
@@ -36,9 +39,6 @@
 #include "src/core/lib/surface/init.h"
 #include "test/core/util/stack_tracer.h"
 
-#include "absl/debugging/failure_signal_handler.h"
-#include "absl/debugging/symbolize.h"
-
 int64_t g_fixture_slowdown_factor = 1;
 int64_t g_poller_slowdown_factor = 1;
 
index f8a19b7..cb5e516 100644 (file)
@@ -77,19 +77,6 @@ class ForwardingLoadBalancingPolicy : public LoadBalancingPolicy {
 };
 
 //
-// CopyMetadataToVector()
-//
-
-MetadataVector CopyMetadataToVector(
-    LoadBalancingPolicy::MetadataInterface* metadata) {
-  MetadataVector result;
-  for (const auto& p : *metadata) {
-    result.push_back({std::string(p.first), std::string(p.second)});
-  }
-  return result;
-}
-
-//
 // TestPickArgsLb
 //
 
@@ -119,7 +106,7 @@ class TestPickArgsLb : public ForwardingLoadBalancingPolicy {
       // Report args seen.
       PickArgsSeen args_seen;
       args_seen.path = std::string(args.path);
-      args_seen.metadata = CopyMetadataToVector(args.initial_metadata);
+      args_seen.metadata = args.initial_metadata->TestOnlyCopyToVector();
       cb_(args_seen);
       // Do pick.
       return delegate_picker_->Pick(args);
@@ -293,7 +280,7 @@ class InterceptRecvTrailingMetadataLoadBalancingPolicy
       TrailingMetadataArgsSeen args_seen;
       args_seen.backend_metric_data = call_state->GetBackendMetricData();
       GPR_ASSERT(recv_trailing_metadata != nullptr);
-      args_seen.metadata = CopyMetadataToVector(recv_trailing_metadata);
+      args_seen.metadata = recv_trailing_metadata->TestOnlyCopyToVector();
       cb_(args_seen);
       this->~TrailingMetadataHandler();
     }
index 3d8f33b..048d2f9 100644 (file)
  *
  */
 
-#include "src/core/lib/iomgr/sockaddr.h"
-#include "src/core/lib/iomgr/socket_utils.h"
-
 #include "test/core/util/test_tcp_server.h"
 
+#include <string.h>
+
 #include <grpc/grpc.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/sync.h>
 #include <grpc/support/time.h>
-#include <string.h>
 
 #include "src/core/lib/iomgr/endpoint.h"
 #include "src/core/lib/iomgr/resolve_address.h"
+#include "src/core/lib/iomgr/sockaddr.h"
+#include "src/core/lib/iomgr/socket_utils.h"
 #include "src/core/lib/iomgr/tcp_server.h"
 #include "test/core/util/port.h"
 #include "test/core/util/test_config.h"
@@ -66,7 +66,9 @@ void test_tcp_server_start(test_tcp_server* server, int port) {
   resolved_addr.len = static_cast<socklen_t>(sizeof(grpc_sockaddr_in));
 
   grpc_error_handle error = grpc_tcp_server_create(
-      &server->shutdown_complete, nullptr, &server->tcp_server);
+      &server->shutdown_complete, nullptr,
+      grpc_slice_allocator_factory_create(grpc_resource_quota_create(nullptr)),
+      &server->tcp_server);
   GPR_ASSERT(error == GRPC_ERROR_NONE);
   error =
       grpc_tcp_server_add_port(server->tcp_server, &resolved_addr, &port_added);
index 549b47b..a06dde8 100644 (file)
@@ -22,6 +22,7 @@
 #include <vector>
 
 #include <grpc/support/sync.h>
+
 #include "src/core/lib/iomgr/tcp_server.h"
 
 // test_tcp_server should be stack-allocated or new'ed, never gpr_malloc'ed
index dc5a455..e48ae0c 100644 (file)
@@ -16,9 +16,8 @@
  *
  */
 
-#include "test/core/util/test_config.h"
-
 #include "src/core/lib/debug/trace.h"
+#include "test/core/util/test_config.h"
 
 namespace grpc_core {
 namespace testing {
index 5b5199b..f0e872a 100644 (file)
  *
  */
 
-#include "src/core/lib/iomgr/sockaddr.h"
-
-#include "test/core/util/passthru_endpoint.h"
-
 #include <inttypes.h>
 #include <string.h>
 
@@ -28,7 +24,9 @@
 #include <grpc/support/string_util.h>
 
 #include "src/core/lib/gpr/useful.h"
+#include "src/core/lib/iomgr/sockaddr.h"
 #include "src/core/lib/slice/slice_internal.h"
+#include "test/core/util/passthru_endpoint.h"
 
 #define WRITE_BUFFER_SIZE (2 * 1024 * 1024)
 
@@ -117,11 +115,6 @@ static void te_destroy(grpc_endpoint* ep) {
   gpr_free(te);
 }
 
-static grpc_resource_user* te_get_resource_user(grpc_endpoint* ep) {
-  trickle_endpoint* te = reinterpret_cast<trickle_endpoint*>(ep);
-  return grpc_endpoint_get_resource_user(te->wrapped);
-}
-
 static absl::string_view te_get_peer(grpc_endpoint* ep) {
   trickle_endpoint* te = reinterpret_cast<trickle_endpoint*>(ep);
   return grpc_endpoint_get_peer(te->wrapped);
@@ -154,7 +147,6 @@ static const grpc_endpoint_vtable vtable = {te_read,
                                             te_delete_from_pollset_set,
                                             te_shutdown,
                                             te_destroy,
-                                            te_get_resource_user,
                                             te_get_peer,
                                             te_get_local_address,
                                             te_get_fd,
index 211e46e..b82bf0a 100644 (file)
 //
 //
 
+#include "src/core/ext/xds/certificate_provider_store.h"
+
 #include <thread>
 
 #include <gmock/gmock.h>
 
 #include "src/core/ext/xds/certificate_provider_registry.h"
-#include "src/core/ext/xds/certificate_provider_store.h"
-
 #include "test/core/util/test_config.h"
 
 namespace grpc_core {
index 5157634..bba2f37 100644 (file)
 
 #include "src/core/ext/xds/file_watcher_certificate_provider_factory.h"
 
-#include "absl/strings/str_format.h"
-
 #include <gmock/gmock.h>
 #include <gtest/gtest.h>
 
+#include "absl/strings/str_format.h"
+
 #include <grpc/grpc.h>
 
 #include "test/core/util/test_config.h"
index bf72df2..8c6af3e 100644 (file)
 //
 //
 
+#include "src/core/ext/xds/google_mesh_ca_certificate_provider_factory.h"
+
 #include <gmock/gmock.h>
 #include <gtest/gtest.h>
 
 #include <grpc/grpc.h>
 
-#include "src/core/ext/xds/google_mesh_ca_certificate_provider_factory.h"
 #include "test/core/util/test_config.h"
 
 namespace grpc_core {
index 2b90a5f..d007780 100644 (file)
 // limitations under the License.
 //
 
-#include <regex>
+#include "src/core/ext/xds/xds_bootstrap.h"
 
-#include "absl/strings/numbers.h"
-#include "absl/strings/str_format.h"
+#include <regex>
 
 #include <gmock/gmock.h>
 #include <gtest/gtest.h>
 
+#include "absl/strings/numbers.h"
+#include "absl/strings/str_format.h"
+
 #include <grpc/grpc.h>
 #include <grpc/slice.h>
 
 #include "src/core/ext/xds/certificate_provider_registry.h"
-#include "src/core/ext/xds/xds_bootstrap.h"
 #include "src/core/lib/gpr/env.h"
 #include "src/core/lib/gpr/tmpfile.h"
 #include "test/core/util/test_config.h"
 
 namespace grpc_core {
 namespace testing {
+namespace {
 
-class TestType {
- public:
-  explicit TestType(bool parse_xds_certificate_providers)
-      : parse_xds_certificate_providers_(parse_xds_certificate_providers) {}
-
-  bool parse_xds_certificate_providers() const {
-    return parse_xds_certificate_providers_;
-  }
-
-  std::string AsString() const {
-    return parse_xds_certificate_providers_
-               ? "WithCertificateProvidersParsing"
-               : "WithoutCertificateProvidersParsing";
-  }
-
- private:
-  const bool parse_xds_certificate_providers_;
-};
-
-class XdsBootstrapTest : public ::testing::TestWithParam<TestType> {
- public:
-  XdsBootstrapTest() {
-    if (GetParam().parse_xds_certificate_providers()) {
-      gpr_setenv("GRPC_XDS_EXPERIMENTAL_SECURITY_SUPPORT", "true");
-    } else {
-      gpr_unsetenv("GRPC_XDS_EXPERIMENTAL_SECURITY_SUPPORT");
-    }
-    grpc_init();
-  }
-
-  ~XdsBootstrapTest() override { grpc_shutdown_blocking(); }
-};
-
-TEST_P(XdsBootstrapTest, Basic) {
+TEST(XdsBootstrapTest, Basic) {
   const char* json_str =
       "{"
       "  \"xds_servers\": ["
@@ -145,7 +114,7 @@ TEST_P(XdsBootstrapTest, Basic) {
             "example/resource");
 }
 
-TEST_P(XdsBootstrapTest, ValidWithoutNode) {
+TEST(XdsBootstrapTest, ValidWithoutNode) {
   const char* json_str =
       "{"
       "  \"xds_servers\": ["
@@ -165,7 +134,7 @@ TEST_P(XdsBootstrapTest, ValidWithoutNode) {
   EXPECT_EQ(bootstrap.node(), nullptr);
 }
 
-TEST_P(XdsBootstrapTest, InsecureCreds) {
+TEST(XdsBootstrapTest, InsecureCreds) {
   const char* json_str =
       "{"
       "  \"xds_servers\": ["
@@ -185,7 +154,7 @@ TEST_P(XdsBootstrapTest, InsecureCreds) {
   EXPECT_EQ(bootstrap.node(), nullptr);
 }
 
-TEST_P(XdsBootstrapTest, GoogleDefaultCreds) {
+TEST(XdsBootstrapTest, GoogleDefaultCreds) {
   // Generate call creds file needed by GoogleDefaultCreds.
   const char token_str[] =
       "{ \"client_id\": \"32555999999.apps.googleusercontent.com\","
@@ -221,7 +190,7 @@ TEST_P(XdsBootstrapTest, GoogleDefaultCreds) {
   EXPECT_EQ(bootstrap.node(), nullptr);
 }
 
-TEST_P(XdsBootstrapTest, MissingChannelCreds) {
+TEST(XdsBootstrapTest, MissingChannelCreds) {
   const char* json_str =
       "{"
       "  \"xds_servers\": ["
@@ -239,7 +208,7 @@ TEST_P(XdsBootstrapTest, MissingChannelCreds) {
   GRPC_ERROR_UNREF(error);
 }
 
-TEST_P(XdsBootstrapTest, NoKnownChannelCreds) {
+TEST(XdsBootstrapTest, NoKnownChannelCreds) {
   const char* json_str =
       "{"
       "  \"xds_servers\": ["
@@ -259,7 +228,7 @@ TEST_P(XdsBootstrapTest, NoKnownChannelCreds) {
   GRPC_ERROR_UNREF(error);
 }
 
-TEST_P(XdsBootstrapTest, MissingXdsServers) {
+TEST(XdsBootstrapTest, MissingXdsServers) {
   grpc_error_handle error = GRPC_ERROR_NONE;
   Json json = Json::Parse("{}", &error);
   ASSERT_EQ(error, GRPC_ERROR_NONE) << grpc_error_std_string(error);
@@ -269,7 +238,7 @@ TEST_P(XdsBootstrapTest, MissingXdsServers) {
   GRPC_ERROR_UNREF(error);
 }
 
-TEST_P(XdsBootstrapTest, TopFieldsWrongTypes) {
+TEST(XdsBootstrapTest, TopFieldsWrongTypes) {
   const char* json_str =
       "{"
       "  \"xds_servers\":1,"
@@ -286,15 +255,13 @@ TEST_P(XdsBootstrapTest, TopFieldsWrongTypes) {
                                        "\"node\" field is not an object.*"
                                        "\"server_listener_resource_name_"
                                        "template\" field is not a string.*"));
-  if (GetParam().parse_xds_certificate_providers()) {
-    EXPECT_THAT(grpc_error_std_string(error),
-                ::testing::ContainsRegex(
-                    "\"certificate_providers\" field is not an object"));
-  }
+  EXPECT_THAT(grpc_error_std_string(error),
+              ::testing::ContainsRegex(
+                  "\"certificate_providers\" field is not an object"));
   GRPC_ERROR_UNREF(error);
 }
 
-TEST_P(XdsBootstrapTest, XdsServerMissingServerUri) {
+TEST(XdsBootstrapTest, XdsServerMissingServerUri) {
   const char* json_str =
       "{"
       "  \"xds_servers\":[{}]"
@@ -310,7 +277,7 @@ TEST_P(XdsBootstrapTest, XdsServerMissingServerUri) {
   GRPC_ERROR_UNREF(error);
 }
 
-TEST_P(XdsBootstrapTest, XdsServerUriAndCredsWrongTypes) {
+TEST(XdsBootstrapTest, XdsServerUriAndCredsWrongTypes) {
   const char* json_str =
       "{"
       "  \"xds_servers\":["
@@ -333,7 +300,7 @@ TEST_P(XdsBootstrapTest, XdsServerUriAndCredsWrongTypes) {
   GRPC_ERROR_UNREF(error);
 }
 
-TEST_P(XdsBootstrapTest, ChannelCredsFieldsWrongTypes) {
+TEST(XdsBootstrapTest, ChannelCredsFieldsWrongTypes) {
   const char* json_str =
       "{"
       "  \"xds_servers\":["
@@ -363,7 +330,7 @@ TEST_P(XdsBootstrapTest, ChannelCredsFieldsWrongTypes) {
   GRPC_ERROR_UNREF(error);
 }
 
-TEST_P(XdsBootstrapTest, NodeFieldsWrongTypes) {
+TEST(XdsBootstrapTest, NodeFieldsWrongTypes) {
   const char* json_str =
       "{"
       "  \"node\":{"
@@ -386,7 +353,7 @@ TEST_P(XdsBootstrapTest, NodeFieldsWrongTypes) {
   GRPC_ERROR_UNREF(error);
 }
 
-TEST_P(XdsBootstrapTest, LocalityFieldsWrongType) {
+TEST(XdsBootstrapTest, LocalityFieldsWrongType) {
   const char* json_str =
       "{"
       "  \"node\":{"
@@ -410,7 +377,7 @@ TEST_P(XdsBootstrapTest, LocalityFieldsWrongType) {
   GRPC_ERROR_UNREF(error);
 }
 
-TEST_P(XdsBootstrapTest, CertificateProvidersElementWrongType) {
+TEST(XdsBootstrapTest, CertificateProvidersElementWrongType) {
   const char* json_str =
       "{"
       "  \"xds_servers\": ["
@@ -427,18 +394,14 @@ TEST_P(XdsBootstrapTest, CertificateProvidersElementWrongType) {
   Json json = Json::Parse(json_str, &error);
   ASSERT_EQ(error, GRPC_ERROR_NONE) << grpc_error_std_string(error);
   XdsBootstrap bootstrap(std::move(json), &error);
-  if (GetParam().parse_xds_certificate_providers()) {
-    EXPECT_THAT(grpc_error_std_string(error),
-                ::testing::ContainsRegex(
-                    "errors parsing \"certificate_providers\" object.*"
-                    "element \"plugin\" is not an object"));
-  } else {
-    EXPECT_EQ(error, GRPC_ERROR_NONE) << grpc_error_std_string(error);
-  }
+  EXPECT_THAT(grpc_error_std_string(error),
+              ::testing::ContainsRegex(
+                  "errors parsing \"certificate_providers\" object.*"
+                  "element \"plugin\" is not an object"));
   GRPC_ERROR_UNREF(error);
 }
 
-TEST_P(XdsBootstrapTest, CertificateProvidersPluginNameWrongType) {
+TEST(XdsBootstrapTest, CertificateProvidersPluginNameWrongType) {
   const char* json_str =
       "{"
       "  \"xds_servers\": ["
@@ -457,19 +420,15 @@ TEST_P(XdsBootstrapTest, CertificateProvidersPluginNameWrongType) {
   Json json = Json::Parse(json_str, &error);
   ASSERT_EQ(error, GRPC_ERROR_NONE) << grpc_error_std_string(error);
   XdsBootstrap bootstrap(std::move(json), &error);
-  if (GetParam().parse_xds_certificate_providers()) {
-    EXPECT_THAT(grpc_error_std_string(error),
-                ::testing::ContainsRegex(
-                    "errors parsing \"certificate_providers\" object.*"
-                    "errors parsing element \"plugin\".*"
-                    "\"plugin_name\" field is not a string"));
-  } else {
-    EXPECT_EQ(error, GRPC_ERROR_NONE) << grpc_error_std_string(error);
-  }
+  EXPECT_THAT(grpc_error_std_string(error),
+              ::testing::ContainsRegex(
+                  "errors parsing \"certificate_providers\" object.*"
+                  "errors parsing element \"plugin\".*"
+                  "\"plugin_name\" field is not a string"));
   GRPC_ERROR_UNREF(error);
 }
 
-TEST_P(XdsBootstrapTest, CertificateProvidersUnrecognizedPluginName) {
+TEST(XdsBootstrapTest, CertificateProvidersUnrecognizedPluginName) {
   const char* json_str =
       "{"
       "  \"xds_servers\": ["
@@ -488,15 +447,11 @@ TEST_P(XdsBootstrapTest, CertificateProvidersUnrecognizedPluginName) {
   Json json = Json::Parse(json_str, &error);
   ASSERT_EQ(error, GRPC_ERROR_NONE) << grpc_error_std_string(error);
   XdsBootstrap bootstrap(std::move(json), &error);
-  if (GetParam().parse_xds_certificate_providers()) {
-    EXPECT_THAT(grpc_error_std_string(error),
-                ::testing::ContainsRegex(
-                    "errors parsing \"certificate_providers\" object.*"
-                    "errors parsing element \"plugin\".*"
-                    "Unrecognized plugin name: unknown"));
-  } else {
-    EXPECT_EQ(error, GRPC_ERROR_NONE) << grpc_error_std_string(error);
-  }
+  EXPECT_THAT(grpc_error_std_string(error),
+              ::testing::ContainsRegex(
+                  "errors parsing \"certificate_providers\" object.*"
+                  "errors parsing element \"plugin\".*"
+                  "Unrecognized plugin name: unknown"));
   GRPC_ERROR_UNREF(error);
 }
 
@@ -549,9 +504,7 @@ class FakeCertificateProviderFactory : public CertificateProviderFactory {
   }
 };
 
-TEST_P(XdsBootstrapTest, CertificateProvidersFakePluginParsingError) {
-  CertificateProviderRegistry::RegisterCertificateProviderFactory(
-      absl::make_unique<FakeCertificateProviderFactory>());
+TEST(XdsBootstrapTest, CertificateProvidersFakePluginParsingError) {
   const char* json_str =
       "{"
       "  \"xds_servers\": ["
@@ -573,21 +526,15 @@ TEST_P(XdsBootstrapTest, CertificateProvidersFakePluginParsingError) {
   Json json = Json::Parse(json_str, &error);
   ASSERT_EQ(error, GRPC_ERROR_NONE) << grpc_error_std_string(error);
   XdsBootstrap bootstrap(std::move(json), &error);
-  if (GetParam().parse_xds_certificate_providers()) {
-    EXPECT_THAT(grpc_error_std_string(error),
-                ::testing::ContainsRegex(
-                    "errors parsing \"certificate_providers\" object.*"
-                    "errors parsing element \"fake_plugin\".*"
-                    "field:config field:value not of type number"));
-  } else {
-    EXPECT_EQ(error, GRPC_ERROR_NONE) << grpc_error_std_string(error);
-  }
+  EXPECT_THAT(grpc_error_std_string(error),
+              ::testing::ContainsRegex(
+                  "errors parsing \"certificate_providers\" object.*"
+                  "errors parsing element \"fake_plugin\".*"
+                  "field:config field:value not of type number"));
   GRPC_ERROR_UNREF(error);
 }
 
-TEST_P(XdsBootstrapTest, CertificateProvidersFakePluginParsingSuccess) {
-  CertificateProviderRegistry::RegisterCertificateProviderFactory(
-      absl::make_unique<FakeCertificateProviderFactory>());
+TEST(XdsBootstrapTest, CertificateProvidersFakePluginParsingSuccess) {
   const char* json_str =
       "{"
       "  \"xds_servers\": ["
@@ -610,24 +557,17 @@ TEST_P(XdsBootstrapTest, CertificateProvidersFakePluginParsingSuccess) {
   ASSERT_EQ(error, GRPC_ERROR_NONE) << grpc_error_std_string(error);
   XdsBootstrap bootstrap(std::move(json), &error);
   ASSERT_TRUE(error == GRPC_ERROR_NONE) << grpc_error_std_string(error);
-  if (GetParam().parse_xds_certificate_providers()) {
-    const CertificateProviderStore::PluginDefinition& fake_plugin =
-        bootstrap.certificate_providers().at("fake_plugin");
-    ASSERT_EQ(fake_plugin.plugin_name, "fake");
-    ASSERT_STREQ(fake_plugin.config->name(), "fake");
-    ASSERT_EQ(
-        static_cast<RefCountedPtr<FakeCertificateProviderFactory::Config>>(
-            fake_plugin.config)
-            ->value(),
-        10);
-  } else {
-    EXPECT_TRUE(bootstrap.certificate_providers().empty());
-  }
+  const CertificateProviderStore::PluginDefinition& fake_plugin =
+      bootstrap.certificate_providers().at("fake_plugin");
+  ASSERT_EQ(fake_plugin.plugin_name, "fake");
+  ASSERT_STREQ(fake_plugin.config->name(), "fake");
+  ASSERT_EQ(static_cast<RefCountedPtr<FakeCertificateProviderFactory::Config>>(
+                fake_plugin.config)
+                ->value(),
+            10);
 }
 
-TEST_P(XdsBootstrapTest, CertificateProvidersFakePluginEmptyConfig) {
-  CertificateProviderRegistry::RegisterCertificateProviderFactory(
-      absl::make_unique<FakeCertificateProviderFactory>());
+TEST(XdsBootstrapTest, CertificateProvidersFakePluginEmptyConfig) {
   const char* json_str =
       "{"
       "  \"xds_servers\": ["
@@ -647,35 +587,27 @@ TEST_P(XdsBootstrapTest, CertificateProvidersFakePluginEmptyConfig) {
   ASSERT_EQ(error, GRPC_ERROR_NONE) << grpc_error_std_string(error);
   XdsBootstrap bootstrap(std::move(json), &error);
   ASSERT_TRUE(error == GRPC_ERROR_NONE) << grpc_error_std_string(error);
-  if (GetParam().parse_xds_certificate_providers()) {
-    const CertificateProviderStore::PluginDefinition& fake_plugin =
-        bootstrap.certificate_providers().at("fake_plugin");
-    ASSERT_EQ(fake_plugin.plugin_name, "fake");
-    ASSERT_STREQ(fake_plugin.config->name(), "fake");
-    ASSERT_EQ(
-        static_cast<RefCountedPtr<FakeCertificateProviderFactory::Config>>(
-            fake_plugin.config)
-            ->value(),
-        0);
-  } else {
-    EXPECT_TRUE(bootstrap.certificate_providers().empty());
-  }
+  const CertificateProviderStore::PluginDefinition& fake_plugin =
+      bootstrap.certificate_providers().at("fake_plugin");
+  ASSERT_EQ(fake_plugin.plugin_name, "fake");
+  ASSERT_STREQ(fake_plugin.config->name(), "fake");
+  ASSERT_EQ(static_cast<RefCountedPtr<FakeCertificateProviderFactory::Config>>(
+                fake_plugin.config)
+                ->value(),
+            0);
 }
 
-std::string TestTypeName(const ::testing::TestParamInfo<TestType>& info) {
-  return info.param.AsString();
-}
-
-INSTANTIATE_TEST_SUITE_P(XdsBootstrap, XdsBootstrapTest,
-                         ::testing::Values(TestType(false), TestType(true)),
-                         &TestTypeName);
-
+}  // namespace
 }  // namespace testing
 }  // namespace grpc_core
 
 int main(int argc, char** argv) {
   ::testing::InitGoogleTest(&argc, argv);
   grpc::testing::TestEnvironment env(argc, argv);
+  grpc_init();
+  grpc_core::CertificateProviderRegistry::RegisterCertificateProviderFactory(
+      absl::make_unique<grpc_core::testing::FakeCertificateProviderFactory>());
   int ret = RUN_ALL_TESTS();
+  grpc_shutdown();
   return ret;
 }
index 32e2bcb..147eff3 100644 (file)
 //
 //
 
+#include "src/core/ext/xds/xds_certificate_provider.h"
+
 #include <gmock/gmock.h>
 #include <gtest/gtest.h>
 
-#include "src/core/ext/xds/xds_certificate_provider.h"
 #include "test/core/util/test_config.h"
 #include "test/core/util/tls_utils.h"
 
index a3c5ed2..6a1b2ef 100644 (file)
 #include "src/core/lib/gprpp/thd.h"
 #include "src/core/lib/iomgr/sockaddr.h"
 #include "src/core/lib/transport/authority_override.h"
-
+#include "src/proto/grpc/lb/v1/load_balancer.grpc.pb.h"
+#include "src/proto/grpc/testing/echo.grpc.pb.h"
 #include "test/core/util/port.h"
 #include "test/core/util/test_config.h"
 #include "test/cpp/end2end/test_service_impl.h"
 
-#include "src/proto/grpc/lb/v1/load_balancer.grpc.pb.h"
-#include "src/proto/grpc/testing/echo.grpc.pb.h"
-
 using grpc::lb::v1::LoadBalancer;
 using grpc::lb::v1::LoadBalanceRequest;
 using grpc::lb::v1::LoadBalanceResponse;
index 122ba92..cc140da 100644 (file)
  *
  */
 
+#include <memory>
+
 #include <gmock/gmock.h>
+#include <gtest/gtest.h>
+
 #include <grpc/grpc.h>
 #include <grpc/grpc_security.h>
 #include <grpcpp/security/credentials.h>
 #include <grpcpp/security/server_credentials.h>
 #include <grpcpp/security/tls_credentials_options.h>
 #include <grpcpp/server_builder.h>
-#include <gtest/gtest.h>
-
-#include <memory>
 
 #include "src/core/lib/gpr/env.h"
 #include "src/core/lib/gpr/tmpfile.h"
index ab458d4..7b5fa99 100644 (file)
@@ -44,7 +44,6 @@
 #include "src/core/lib/gprpp/ref_counted_ptr.h"
 #include "src/core/lib/gprpp/thd.h"
 #include "src/core/lib/iomgr/sockaddr.h"
-
 #include "test/core/util/port.h"
 #include "test/core/util/test_config.h"
 
index a61e24b..b0b46b6 100644 (file)
  *
  */
 
+#include <gtest/gtest.h>
+
 #include <grpc/support/time.h>
 #include <grpcpp/completion_queue.h>
-#include <gtest/gtest.h>
 
 #include "test/core/util/test_config.h"
 
index bc87cc2..9af017e 100644 (file)
  *
  */
 
-#include <gtest/gtest.h>
-
 #include <fstream>
 #include <sstream>
 
+#include <gtest/gtest.h>
+
 #include "absl/flags/flag.h"
+
 #include "test/core/util/test_config.h"
 #include "test/cpp/util/test_config.h"
 
index 1013cce..da2ec63 100644 (file)
  *
  */
 
+#include <gtest/gtest.h>
+
 #include <grpc/impl/codegen/byte_buffer.h>
 #include <grpc/slice.h>
 #include <grpcpp/impl/codegen/grpc_library.h>
 #include <grpcpp/impl/codegen/proto_utils.h>
 #include <grpcpp/impl/grpc_library.h>
-#include <gtest/gtest.h>
 
 #include "test/core/util/test_config.h"
 
index 6238caa..4a347f1 100644 (file)
 #include <mutex>
 #include <thread>
 
+#include <gtest/gtest.h>
+
 #include <grpcpp/alarm.h>
 #include <grpcpp/completion_queue.h>
 
-#include <gtest/gtest.h>
-
 #include "test/core/util/test_config.h"
 
 namespace grpc {
index 67c24b2..f22385a 100644 (file)
  *
  */
 
+#include <gtest/gtest.h>
+
 #include "upb/upb.hpp"
 
 #include <grpcpp/security/alts_context.h>
 #include <grpcpp/security/alts_util.h>
 #include <grpcpp/security/auth_context.h>
-#include <gtest/gtest.h>
 
 #include "src/core/tsi/alts/handshaker/alts_tsi_handshaker.h"
 #include "src/cpp/common/secure_auth_context.h"
index 5a2844d..5a6084b 100644 (file)
  *
  */
 
+#include <gtest/gtest.h>
+
 #include <grpc/grpc_security.h>
 #include <grpcpp/security/auth_context.h>
-#include <gtest/gtest.h>
-#include "src/cpp/common/secure_auth_context.h"
-#include "test/cpp/util/string_ref_helper.h"
 
 #include "src/core/lib/security/context/security_context.h"
+#include "src/cpp/common/secure_auth_context.h"
+#include "test/cpp/util/string_ref_helper.h"
 
 using ::grpc::testing::ToString;
 
index 6765bb3..b1e7ee1 100644 (file)
  *
  */
 
-#include <grpcpp/support/channel_arguments.h>
+#include <gtest/gtest.h>
 
 #include <grpc/grpc.h>
 #include <grpcpp/grpcpp.h>
-#include <gtest/gtest.h>
+#include <grpcpp/support/channel_arguments.h>
 
 #include "src/core/lib/gpr/useful.h"
 #include "src/core/lib/iomgr/exec_ctx.h"
index c077930..139c031 100644 (file)
 
 #include <limits.h>
 
-#include <grpc/grpc.h>
 #include <gtest/gtest.h>
 
+#include <grpc/grpc.h>
+
 namespace grpc {
 namespace testing {
 
index 03b3a9f..fcae9ba 100644 (file)
  */
 
 #include "src/cpp/common/secure_auth_context.h"
+
+#include <gtest/gtest.h>
+
 #include <grpc/grpc_security.h>
 #include <grpcpp/security/auth_context.h>
-#include <gtest/gtest.h>
-#include "test/cpp/util/string_ref_helper.h"
 
 #include "src/core/lib/security/context/security_context.h"
+#include "test/cpp/util/string_ref_helper.h"
 
 using grpc::testing::ToString;
 
index f6ff40f..91643a7 100644 (file)
  */
 
 #include <spawn.h>
+
 #include <sstream>
 #include <string>
 #include <thread>
 #include <vector>
 
+#include <gtest/gtest.h>
+
+#include "absl/time/time.h"
+
 #include <grpc/grpc.h>
 #include <grpc/support/log.h>
-#include <gtest/gtest.h>
 
 #include "src/core/lib/gprpp/sync.h"
 #include "src/core/lib/iomgr/closure.h"
@@ -34,8 +38,6 @@
 #include "src/core/lib/iomgr/timer_manager.h"
 #include "test/core/util/test_config.h"
 
-#include "absl/time/time.h"
-
 extern char** environ;
 
 #ifdef GPR_ANDROID
index dca0215..2a80246 100644 (file)
  *
  */
 
+#include "src/core/lib/iomgr/timer.h"
+
+#include <gtest/gtest.h>
+
 #include <grpc/grpc.h>
 #include <grpc/support/log.h>
-#include <gtest/gtest.h>
 
 #include "src/core/lib/iomgr/closure.h"
 #include "src/core/lib/iomgr/error.h"
 #include "src/core/lib/iomgr/exec_ctx.h"
-#include "src/core/lib/iomgr/timer.h"
 #include "src/core/lib/iomgr/timer_manager.h"
 #include "test/core/util/test_config.h"
 
index af4fc4e..5237fe7 100644 (file)
@@ -506,6 +506,7 @@ grpc_cc_test(
         "//src/proto/grpc/testing:echo_proto",
         "//src/proto/grpc/testing/duplicate:echo_duplicate_proto",
         "//test/core/util:grpc_test_util",
+        "//test/cpp/util:test_config",
         "//test/cpp/util:test_util",
     ],
 )
@@ -561,6 +562,7 @@ grpc_cc_test(
         "//src/proto/grpc/testing/xds/v3:router_proto",
         "//src/proto/grpc/testing/xds/v3:tls_proto",
         "//test/core/util:grpc_test_util",
+        "//test/cpp/util:test_config",
         "//test/cpp/util:test_util",
     ],
 )
@@ -862,6 +864,7 @@ grpc_cc_test(
     external_deps = [
         "gtest",
     ],
+    tags = ["no_test_ios"],
     deps = [
         ":test_service_impl",
         "//:gpr",
@@ -888,3 +891,22 @@ grpc_cc_test(
         "//test/cpp/util:test_util",
     ],
 )
+
+grpc_cc_test(
+    name = "sdk_authz_end2end_test",
+    srcs = ["sdk_authz_end2end_test.cc"],
+    external_deps = [
+        "gtest",
+    ],
+    deps = [
+        ":test_service_impl",
+        "//:gpr",
+        "//:grpc",
+        "//:grpc++",
+        "//:grpc++_authorization_provider",
+        "//src/proto/grpc/testing:echo_messages_proto",
+        "//src/proto/grpc/testing:echo_proto",
+        "//test/core/util:grpc_test_util",
+        "//test/cpp/util:test_util",
+    ],
+)
index 4d9c389..b1baccc 100644 (file)
@@ -21,6 +21,7 @@
 
 #include "absl/strings/str_cat.h"
 
+#include <grpcpp/ext/admin_services.h>
 #include <grpcpp/ext/proto_server_reflection_plugin.h>
 #include <grpcpp/grpcpp.h>
 
@@ -28,8 +29,6 @@
 #include "test/core/util/port.h"
 #include "test/core/util/test_config.h"
 
-#include <grpcpp/ext/admin_services.h>
-
 namespace grpc {
 namespace testing {
 
index c97bd8a..71e8d2e 100644 (file)
@@ -20,6 +20,8 @@
 #include <memory>
 #include <thread>
 
+#include "absl/memory/memory.h"
+
 #include <grpc/grpc.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
@@ -32,8 +34,6 @@
 #include <grpcpp/server_builder.h>
 #include <grpcpp/server_context.h>
 
-#include "absl/memory/memory.h"
-
 #include "src/core/ext/filters/client_channel/backup_poller.h"
 #include "src/core/lib/gpr/tls.h"
 #include "src/core/lib/iomgr/port.h"
index 9d04020..a5e65cb 100644 (file)
  *
  */
 
-#include "src/core/lib/iomgr/port.h"
-
 #include <algorithm>
 #include <memory>
 #include <mutex>
 #include <random>
 #include <thread>
 
+#include <gtest/gtest.h>
+
 #include <grpc/grpc.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/atm.h>
 #include <grpcpp/health_check_service_interface.h>
 #include <grpcpp/server.h>
 #include <grpcpp/server_builder.h>
-#include <gtest/gtest.h>
 
 #include "src/core/lib/backoff/backoff.h"
 #include "src/core/lib/gpr/env.h"
-
+#include "src/core/lib/iomgr/port.h"
 #include "src/proto/grpc/testing/echo.grpc.pb.h"
 #include "test/core/util/port.h"
 #include "test/core/util/test_config.h"
index 3b5aa50..6395f7a 100644 (file)
 
 #include <grpc/support/port_platform.h>
 
+#include <gtest/gtest.h>
+
+#include "absl/memory/memory.h"
+
 #include <grpc/grpc.h>
 #include <grpc/grpc_security.h>
 #include <grpcpp/channel.h>
@@ -30,8 +34,6 @@
 #include <grpcpp/server_builder.h>
 #include <grpcpp/server_context.h>
 
-#include "absl/memory/memory.h"
-
 #include "src/core/lib/gpr/env.h"
 #include "src/core/lib/iomgr/load_file.h"
 #include "src/core/lib/security/credentials/tls/grpc_tls_certificate_provider.h"
@@ -45,8 +47,6 @@
 #include "test/cpp/end2end/test_service_impl.h"
 #include "test/cpp/util/test_credentials_provider.h"
 
-#include <gtest/gtest.h>
-
 using grpc::channelz::v1::Address;
 using grpc::channelz::v1::GetChannelRequest;
 using grpc::channelz::v1::GetChannelResponse;
index f4338e1..9118d96 100644 (file)
  *
  */
 
+#include <algorithm>
+#include <condition_variable>
+#include <functional>
+#include <mutex>
+#include <sstream>
+#include <thread>
+
+#include <gtest/gtest.h>
+
+#include "absl/memory/memory.h"
+
 #include <grpcpp/channel.h>
 #include <grpcpp/client_context.h>
 #include <grpcpp/create_channel.h>
 #include <grpcpp/server_builder.h>
 #include <grpcpp/server_context.h>
 #include <grpcpp/support/client_callback.h>
-#include <gtest/gtest.h>
-
-#include <algorithm>
-#include <condition_variable>
-#include <functional>
-#include <mutex>
-#include <sstream>
-#include <thread>
 
-#include "absl/memory/memory.h"
 #include "src/core/lib/gpr/env.h"
 #include "src/core/lib/iomgr/iomgr.h"
 #include "src/proto/grpc/testing/echo.grpc.pb.h"
index 5ac8f2e..e34186b 100644 (file)
  *
  */
 
+#include <gtest/gtest.h>
+
+#include "absl/memory/memory.h"
+
 #include <grpc/grpc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/time.h>
 #include <grpcpp/server_builder.h>
 #include <grpcpp/server_context.h>
 
-#include "absl/memory/memory.h"
-
 #include "src/proto/grpc/testing/duplicate/echo_duplicate.grpc.pb.h"
 #include "src/proto/grpc/testing/echo.grpc.pb.h"
 #include "test/core/util/port.h"
 #include "test/core/util/test_config.h"
 #include "test/cpp/util/subprocess.h"
 
-#include <gtest/gtest.h>
-
 using grpc::testing::EchoRequest;
 using grpc::testing::EchoResponse;
 
index 1adf98d..5b8a533 100644 (file)
  *
  */
 
-#include <grpc/support/log.h>
-#include <grpcpp/server.h>
-#include <grpcpp/server_builder.h>
-#include <grpcpp/server_context.h>
-
 #include <iostream>
 #include <memory>
 #include <string>
 
 #include "absl/flags/flag.h"
+
+#include <grpc/support/log.h>
+#include <grpcpp/server.h>
+#include <grpcpp/server_builder.h>
+#include <grpcpp/server_context.h>
+
 #include "src/proto/grpc/testing/echo.grpc.pb.h"
 #include "test/cpp/util/test_config.h"
 
index 8035134..9a792ca 100644 (file)
@@ -19,6 +19,8 @@
 #include <memory>
 #include <vector>
 
+#include <gtest/gtest.h>
+
 #include "absl/memory/memory.h"
 
 #include <grpcpp/channel.h>
 
 #ifdef GRPC_POSIX_SOCKET
 #include <fcntl.h>
+
 #include "src/core/lib/iomgr/socket_utils_posix.h"
 #endif /* GRPC_POSIX_SOCKET */
 
-#include <gtest/gtest.h>
-
 namespace grpc {
 namespace testing {
 namespace {
index 4e0ab6e..90f633d 100644 (file)
@@ -24,6 +24,9 @@
 #include <string>
 #include <thread>
 
+#include <gmock/gmock.h>
+#include <gtest/gtest.h>
+
 #include "absl/memory/memory.h"
 #include "absl/strings/str_cat.h"
 #include "absl/strings/str_format.h"
@@ -57,7 +60,6 @@
 #include "src/core/lib/security/credentials/fake/fake_credentials.h"
 #include "src/cpp/client/secure_credentials.h"
 #include "src/cpp/server/secure_server_credentials.h"
-
 #include "src/proto/grpc/testing/echo.grpc.pb.h"
 #include "src/proto/grpc/testing/xds/orca_load_report_for_test.pb.h"
 #include "test/core/util/port.h"
@@ -66,9 +68,6 @@
 #include "test/core/util/test_lb_policies.h"
 #include "test/cpp/end2end/test_service_impl.h"
 
-#include <gmock/gmock.h>
-#include <gtest/gtest.h>
-
 using grpc::testing::EchoRequest;
 using grpc::testing::EchoResponse;
 
@@ -84,6 +83,7 @@ namespace {
 gpr_atm g_connection_delay_ms;
 
 void tcp_client_connect_with_delay(grpc_closure* closure, grpc_endpoint** ep,
+                                   grpc_slice_allocator* slice_allocator,
                                    grpc_pollset_set* interested_parties,
                                    const grpc_channel_args* channel_args,
                                    const grpc_resolved_address* addr,
@@ -92,8 +92,8 @@ void tcp_client_connect_with_delay(grpc_closure* closure, grpc_endpoint** ep,
   if (delay_ms > 0) {
     gpr_sleep_until(grpc_timeout_milliseconds_to_deadline(delay_ms));
   }
-  default_client_impl->connect(closure, ep, interested_parties, channel_args,
-                               addr, deadline + delay_ms);
+  default_client_impl->connect(closure, ep, slice_allocator, interested_parties,
+                               channel_args, addr, deadline + delay_ms);
 }
 
 grpc_tcp_client_vtable delayed_connect = {tcp_client_connect_with_delay};
index a2e202d..67e8cdd 100644 (file)
  *
  */
 
+#include <algorithm>
+#include <atomic>
+#include <condition_variable>
+#include <functional>
+#include <memory>
+#include <mutex>
+#include <sstream>
+#include <thread>
+
+#include <gtest/gtest.h>
+
 #include <grpc/impl/codegen/log.h>
 #include <grpcpp/channel.h>
 #include <grpcpp/client_context.h>
 #include <grpcpp/server_context.h>
 #include <grpcpp/support/client_callback.h>
 #include <grpcpp/support/message_allocator.h>
-#include <gtest/gtest.h>
-
-#include <algorithm>
-#include <atomic>
-#include <condition_variable>
-#include <functional>
-#include <memory>
-#include <mutex>
-#include <sstream>
-#include <thread>
 
 #include "src/core/lib/iomgr/iomgr.h"
 #include "src/proto/grpc/testing/echo.grpc.pb.h"
index 5ff66d8..0c065e6 100644 (file)
@@ -19,6 +19,8 @@
 #include <memory>
 #include <vector>
 
+#include <gtest/gtest.h>
+
 #include <grpcpp/channel.h>
 #include <grpcpp/client_context.h>
 #include <grpcpp/create_channel.h>
@@ -37,8 +39,6 @@
 #include "test/cpp/util/byte_buffer_proto_helper.h"
 #include "test/cpp/util/string_ref_helper.h"
 
-#include <gtest/gtest.h>
-
 namespace grpc {
 namespace testing {
 namespace {
index 34183f2..c4a287e 100644 (file)
  *
  */
 
+#include <mutex>
+#include <thread>
+
+#include "absl/memory/memory.h"
+#include "absl/strings/match.h"
+#include "absl/strings/str_format.h"
+
 #include <grpc/grpc.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpcpp/support/string_ref.h>
 #include <grpcpp/test/channel_test_peer.h>
 
-#include <mutex>
-#include <thread>
-
-#include "absl/memory/memory.h"
-#include "absl/strings/match.h"
-#include "absl/strings/str_format.h"
-
 #include "src/core/ext/filters/client_channel/backup_poller.h"
 #include "src/core/lib/gpr/env.h"
 #include "src/core/lib/iomgr/iomgr.h"
index 404abfa..1a4c418 100644 (file)
  *
  */
 
+#include <grpc/impl/codegen/port_platform.h>
+
 #include <exception>
 #include <memory>
 
-#include <grpc/impl/codegen/port_platform.h>
+#include <gtest/gtest.h>
+
 #include <grpcpp/channel.h>
 #include <grpcpp/client_context.h>
 #include <grpcpp/server.h>
@@ -29,8 +32,6 @@
 #include "src/proto/grpc/testing/echo.grpc.pb.h"
 #include "test/core/util/test_config.h"
 
-#include <gtest/gtest.h>
-
 namespace grpc {
 namespace testing {
 
index 535ee29..93f07b0 100644 (file)
 #include <mutex>
 #include <thread>
 
+#include <gtest/gtest.h>
+
+#include "absl/memory/memory.h"
+
 #include <grpc/grpc.h>
 #include <grpc/support/time.h>
 #include <grpcpp/channel.h>
 #include <grpcpp/support/config.h>
 #include <grpcpp/support/slice.h>
 
-#include "absl/memory/memory.h"
-
 #include "src/cpp/common/channel_filter.h"
 #include "src/proto/grpc/testing/echo.grpc.pb.h"
 #include "test/core/util/port.h"
 #include "test/core/util/test_config.h"
 #include "test/cpp/util/byte_buffer_proto_helper.h"
 
-#include <gtest/gtest.h>
-
 using grpc::testing::EchoRequest;
 using grpc::testing::EchoResponse;
 
index 805770d..890d4a7 100644 (file)
  *
  */
 
+#include <grpc/support/port_platform.h>
+
+#include <algorithm>
+#include <condition_variable>
+#include <memory>
+#include <mutex>
+#include <random>
+#include <thread>
+
+#include <gtest/gtest.h>
+
+#include "absl/memory/memory.h"
+
 #include <grpc/grpc.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/atm.h>
 #include <grpc/support/log.h>
-#include <grpc/support/port_platform.h>
 #include <grpc/support/string_util.h>
 #include <grpc/support/time.h>
 #include <grpcpp/channel.h>
 #include <grpcpp/health_check_service_interface.h>
 #include <grpcpp/server.h>
 #include <grpcpp/server_builder.h>
-#include <gtest/gtest.h>
-
-#include <algorithm>
-#include <condition_variable>
-#include <memory>
-#include <mutex>
-#include <random>
-#include <thread>
-
-#include "absl/memory/memory.h"
 
 #include "src/core/lib/backoff/backoff.h"
 #include "src/core/lib/gpr/env.h"
index cff1cf8..0ebc863 100644 (file)
 #include <memory>
 #include <thread>
 
+#include <gtest/gtest.h>
+
+#include "absl/memory/memory.h"
+
 #include <grpc/grpc.h>
 #include <grpc/support/time.h>
 #include <grpcpp/channel.h>
 #include <grpcpp/server_context.h>
 #include <grpcpp/support/slice.h>
 
-#include "absl/memory/memory.h"
-
 #include "src/proto/grpc/testing/echo.grpc.pb.h"
 #include "test/core/util/port.h"
 #include "test/core/util/test_config.h"
 #include "test/cpp/util/byte_buffer_proto_helper.h"
 
-#include <gtest/gtest.h>
-
 using grpc::testing::EchoRequest;
 using grpc::testing::EchoResponse;
 
index e6e2e9f..9f0dddb 100644 (file)
@@ -24,6 +24,9 @@
 #include <string>
 #include <thread>
 
+#include <gmock/gmock.h>
+#include <gtest/gtest.h>
+
 #include "absl/memory/memory.h"
 #include "absl/strings/str_cat.h"
 #include "absl/strings/str_format.h"
 #include "src/core/lib/transport/authority_override.h"
 #include "src/cpp/client/secure_credentials.h"
 #include "src/cpp/server/secure_server_credentials.h"
-
+#include "src/proto/grpc/lb/v1/load_balancer.grpc.pb.h"
+#include "src/proto/grpc/testing/echo.grpc.pb.h"
 #include "test/core/util/port.h"
 #include "test/core/util/resolve_localhost_ip46.h"
 #include "test/core/util/test_config.h"
 #include "test/cpp/end2end/test_service_impl.h"
-
-#include "src/proto/grpc/lb/v1/load_balancer.grpc.pb.h"
-#include "src/proto/grpc/testing/echo.grpc.pb.h"
-
-#include <gmock/gmock.h>
-#include <gtest/gtest.h>
+#include "test/cpp/util/test_config.h"
 
 // TODO(dgq): Other scenarios in need of testing:
 // - Send a serverlist with faulty ip:port addresses (port > 2^16, etc).
@@ -958,7 +957,7 @@ TEST_F(SingleBalancerTest, SecureNaming) {
 }
 
 TEST_F(SingleBalancerTest, SecureNamingDeathTest) {
-  ::testing::FLAGS_gtest_death_test_style = "threadsafe";
+  GRPC_GTEST_FLAG_SET_DEATH_TEST_STYLE("threadsafe");
   // Make sure that we blow up (via abort() from the security connector) when
   // the name from the balancer doesn't match expectations.
   ASSERT_DEATH_IF_SUPPORTED(
index c36a7cd..efbdc36 100644 (file)
@@ -21,6 +21,8 @@
 #include <thread>
 #include <vector>
 
+#include <gtest/gtest.h>
+
 #include <grpc/grpc.h>
 #include <grpc/support/log.h>
 #include <grpcpp/channel.h>
@@ -40,8 +42,6 @@
 #include "test/cpp/end2end/test_health_check_service_impl.h"
 #include "test/cpp/end2end/test_service_impl.h"
 
-#include <gtest/gtest.h>
-
 using grpc::health::v1::Health;
 using grpc::health::v1::HealthCheckRequest;
 using grpc::health::v1::HealthCheckResponse;
index c399930..70c82c8 100644 (file)
@@ -19,6 +19,8 @@
 #include <memory>
 #include <thread>
 
+#include <gtest/gtest.h>
+
 #include <grpc/grpc.h>
 #include <grpcpp/channel.h>
 #include <grpcpp/client_context.h>
@@ -37,8 +39,6 @@
 #include "test/cpp/end2end/test_service_impl.h"
 #include "test/cpp/util/byte_buffer_proto_helper.h"
 
-#include <gtest/gtest.h>
-
 namespace grpc {
 namespace testing {
 namespace {
index 2c394bf..14f42e3 100644 (file)
 
 #include <condition_variable>
 
+#include <gtest/gtest.h>
+
 #include <grpcpp/channel.h>
 
 #include "src/proto/grpc/testing/echo.grpc.pb.h"
 #include "test/cpp/util/string_ref_helper.h"
 
-#include <gtest/gtest.h>
-
 namespace grpc {
 namespace testing {
 /* This interceptor does nothing. Just keeps a global count on the number of
index 7924715..f42ac3a 100644 (file)
 #include <thread>
 
 #include <google/protobuf/arena.h>
-
-#include <grpc/impl/codegen/log.h>
 #include <gtest/gtest.h>
 
+#include <grpc/impl/codegen/log.h>
 #include <grpcpp/channel.h>
 #include <grpcpp/client_context.h>
 #include <grpcpp/create_channel.h>
index 40a8b13..1443154 100644 (file)
  */
 
 #include <climits>
+#include <iostream>
+
+#include <gmock/gmock.h>
+#include <gtest/gtest.h>
+
+#include "absl/types/optional.h"
 
 #include <grpc/grpc.h>
 #include <grpc/support/log.h>
@@ -28,8 +34,7 @@
 #include <grpcpp/server_builder.h>
 #include <grpcpp/server_context.h>
 #include <grpcpp/test/default_reactor_test_peer.h>
-
-#include "absl/types/optional.h"
+#include <grpcpp/test/mock_stream.h>
 
 #include "src/proto/grpc/testing/duplicate/echo_duplicate.grpc.pb.h"
 #include "src/proto/grpc/testing/echo.grpc.pb.h"
 #include "test/core/util/port.h"
 #include "test/core/util/test_config.h"
 
-#include <grpcpp/test/mock_stream.h>
-
-#include <gmock/gmock.h>
-#include <gtest/gtest.h>
-
-#include <iostream>
-
 using grpc::testing::DefaultReactorTestPeer;
 using grpc::testing::EchoRequest;
 using grpc::testing::EchoResponse;
index 04446e5..cb00810 100644 (file)
@@ -18,6 +18,8 @@
 
 #include <memory>
 
+#include "absl/memory/memory.h"
+
 #include <grpcpp/channel.h>
 #include <grpcpp/client_context.h>
 #include <grpcpp/create_channel.h>
@@ -25,8 +27,6 @@
 #include <grpcpp/server_builder.h>
 #include <grpcpp/server_context.h>
 
-#include "absl/memory/memory.h"
-
 #include "src/core/lib/gpr/tls.h"
 #include "src/core/lib/iomgr/port.h"
 #include "src/proto/grpc/testing/echo.grpc.pb.h"
@@ -44,7 +44,7 @@
 // non-blocking (not polls from resolver, timer thread, etc), and only when the
 // thread is waiting on polls caused by CompletionQueue::AsyncNext (not for
 // picking a port or other reasons).
-GPR_TLS_DECL(g_is_nonblocking_poll);
+static GPR_THREAD_LOCAL(bool) g_is_nonblocking_poll;
 
 namespace {
 
@@ -52,7 +52,7 @@ int maybe_assert_non_blocking_poll(struct pollfd* pfds, nfds_t nfds,
                                    int timeout) {
   // Only assert that this poll should have zero timeout if we're in the
   // middle of a zero-timeout CQ Next.
-  if (gpr_tls_get(&g_is_nonblocking_poll)) {
+  if (g_is_nonblocking_poll) {
     GPR_ASSERT(timeout == 0);
   }
   return poll(pfds, nfds, timeout);
@@ -82,15 +82,15 @@ class NonblockingTest : public ::testing::Test {
   bool LoopForTag(void** tag, bool* ok) {
     // Temporarily set the thread-local nonblocking poll flag so that the polls
     // caused by this loop are indeed sent by the library with zero timeout.
-    intptr_t orig_val = gpr_tls_get(&g_is_nonblocking_poll);
-    gpr_tls_set(&g_is_nonblocking_poll, static_cast<intptr_t>(true));
+    bool orig_val = g_is_nonblocking_poll;
+    g_is_nonblocking_poll = true;
     for (;;) {
       auto r = cq_->AsyncNext(tag, ok, gpr_time_0(GPR_CLOCK_REALTIME));
       if (r == CompletionQueue::SHUTDOWN) {
-        gpr_tls_set(&g_is_nonblocking_poll, orig_val);
+        g_is_nonblocking_poll = orig_val;
         return false;
       } else if (r == CompletionQueue::GOT_EVENT) {
-        gpr_tls_set(&g_is_nonblocking_poll, orig_val);
+        g_is_nonblocking_poll = orig_val;
         return true;
       }
     }
@@ -201,15 +201,14 @@ int main(int argc, char** argv) {
 
   grpc::testing::TestEnvironment env(argc, argv);
   ::testing::InitGoogleTest(&argc, argv);
-  gpr_tls_init(&g_is_nonblocking_poll);
 
   // Start the nonblocking poll thread-local variable as false because the
   // thread that issues RPCs starts by picking a port (which has non-zero
   // timeout).
-  gpr_tls_set(&g_is_nonblocking_poll, static_cast<intptr_t>(false));
+  g_is_nonblocking_poll = false;
 
   int ret = RUN_ALL_TESTS();
-  gpr_tls_destroy(&g_is_nonblocking_poll);
+
   return ret;
 #else   // GRPC_POSIX_SOCKET
   (void)argc;
index e9fa826..1bc7a01 100644 (file)
  *
  */
 
+#include <mutex>
+#include <thread>
+
+#include <gtest/gtest.h>
+
 #include <grpc/grpc.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpcpp/server.h>
 #include <grpcpp/server_builder.h>
 #include <grpcpp/server_context.h>
-#include <gtest/gtest.h>
-
-#include <mutex>
-#include <thread>
 
 #include "src/core/lib/gpr/env.h"
 #include "src/core/lib/iomgr/endpoint.h"
index b3b68be..b9d14e4 100644 (file)
  *
  */
 
+#include <gtest/gtest.h>
+
+#include "absl/memory/memory.h"
+
 #include <grpc/grpc.h>
 #include <grpcpp/channel.h>
 #include <grpcpp/client_context.h>
 #include <grpcpp/server_builder.h>
 #include <grpcpp/server_context.h>
 
-#include "absl/memory/memory.h"
-
 #include "src/proto/grpc/testing/echo.grpc.pb.h"
 #include "test/core/util/port.h"
 #include "test/core/util/test_config.h"
 #include "test/cpp/end2end/test_service_impl.h"
 #include "test/cpp/util/proto_reflection_descriptor_database.h"
 
-#include <gtest/gtest.h>
-
 namespace grpc {
 namespace testing {
 
index d6300ec..e0c29cd 100644 (file)
@@ -20,6 +20,8 @@
 #include <memory>
 #include <thread>
 
+#include <gtest/gtest.h>
+
 #include <grpc/grpc.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
@@ -40,8 +42,6 @@
 #include "test/cpp/util/byte_buffer_proto_helper.h"
 #include "test/cpp/util/string_ref_helper.h"
 
-#include <gtest/gtest.h>
-
 using grpc::testing::EchoRequest;
 using grpc::testing::EchoResponse;
 
diff --git a/test/cpp/end2end/sdk_authz_end2end_test.cc b/test/cpp/end2end/sdk_authz_end2end_test.cc
new file mode 100644 (file)
index 0000000..853920a
--- /dev/null
@@ -0,0 +1,360 @@
+// Copyright 2021 gRPC authors.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#include <gmock/gmock.h>
+#include <gtest/gtest.h>
+
+#include <grpcpp/channel.h>
+#include <grpcpp/client_context.h>
+#include <grpcpp/create_channel.h>
+#include <grpcpp/security/authorization_policy_provider.h>
+#include <grpcpp/server.h>
+#include <grpcpp/server_builder.h>
+
+#include "src/core/lib/security/credentials/fake/fake_credentials.h"
+#include "src/cpp/client/secure_credentials.h"
+#include "src/cpp/server/secure_server_credentials.h"
+#include "src/proto/grpc/testing/echo.grpc.pb.h"
+#include "test/core/util/port.h"
+#include "test/core/util/test_config.h"
+#include "test/cpp/end2end/test_service_impl.h"
+
+namespace grpc {
+namespace testing {
+namespace {
+
+constexpr char kMessage[] = "Hello";
+
+class SdkAuthzEnd2EndTest : public ::testing::Test {
+ protected:
+  SdkAuthzEnd2EndTest()
+      : server_address_(
+            absl::StrCat("localhost:", grpc_pick_unused_port_or_die())),
+        server_creds_(
+            std::shared_ptr<ServerCredentials>(new SecureServerCredentials(
+                grpc_fake_transport_security_server_credentials_create()))),
+        channel_creds_(
+            std::shared_ptr<ChannelCredentials>(new SecureChannelCredentials(
+                grpc_fake_transport_security_credentials_create()))) {}
+
+  ~SdkAuthzEnd2EndTest() override { server_->Shutdown(); }
+
+  // Replaces existing credentials with insecure credentials.
+  void UseInsecureCredentials() {
+    server_creds_ = InsecureServerCredentials();
+    channel_creds_ = InsecureChannelCredentials();
+  }
+
+  // Creates server with sdk authorization enabled when provider is not null.
+  void InitServer(
+      std::shared_ptr<experimental::AuthorizationPolicyProviderInterface>
+          provider) {
+    ServerBuilder builder;
+    builder.AddListeningPort(server_address_, std::move(server_creds_));
+    builder.experimental().SetAuthorizationPolicyProvider(std::move(provider));
+    builder.RegisterService(&service_);
+    server_ = builder.BuildAndStart();
+  }
+
+  std::shared_ptr<experimental::AuthorizationPolicyProviderInterface>
+  CreateStaticAuthzPolicyProvider(const std::string& policy) {
+    grpc::Status status;
+    auto provider = experimental::StaticDataAuthorizationPolicyProvider::Create(
+        policy, &status);
+    EXPECT_TRUE(status.ok());
+    return provider;
+  }
+
+  std::shared_ptr<Channel> BuildChannel() {
+    ChannelArguments args;
+    return ::grpc::CreateCustomChannel(server_address_, channel_creds_, args);
+  }
+
+  grpc::Status SendRpc(const std::shared_ptr<Channel>& channel,
+                       ClientContext* context,
+                       grpc::testing::EchoResponse* response = nullptr) {
+    auto stub = grpc::testing::EchoTestService::NewStub(channel);
+    grpc::testing::EchoRequest request;
+    request.set_message(kMessage);
+    return stub->Echo(context, request, response);
+  }
+
+  std::string server_address_;
+  TestServiceImpl service_;
+  std::unique_ptr<Server> server_;
+  std::shared_ptr<ServerCredentials> server_creds_;
+  std::shared_ptr<ChannelCredentials> channel_creds_;
+};
+
+TEST_F(SdkAuthzEnd2EndTest,
+       StaticInitAllowsRpcRequestNoMatchInDenyMatchInAllow) {
+  std::string policy =
+      "{"
+      "  \"name\": \"authz\","
+      "  \"allow_rules\": ["
+      "    {"
+      "      \"name\": \"allow_echo\","
+      "      \"request\": {"
+      "        \"paths\": ["
+      "          \"*/Echo\""
+      "        ],"
+      "        \"headers\": ["
+      "          {"
+      "            \"key\": \"key-foo\","
+      "            \"values\": [\"foo1\", \"foo2\"]"
+      "          },"
+      "          {"
+      "            \"key\": \"key-bar\","
+      "            \"values\": [\"bar1\"]"
+      "          }"
+      "        ]"
+      "      }"
+      "    }"
+      "  ],"
+      "  \"deny_rules\": ["
+      "    {"
+      "      \"name\": \"deny_clientstreamingecho\","
+      "      \"request\": {"
+      "        \"paths\": ["
+      "          \"*/ClientStreamingEcho\""
+      "        ]"
+      "      }"
+      "    }"
+      "  ]"
+      "}";
+  InitServer(CreateStaticAuthzPolicyProvider(policy));
+  auto channel = BuildChannel();
+  ClientContext context;
+  context.AddMetadata("key-foo", "foo2");
+  context.AddMetadata("key-bar", "bar1");
+  context.AddMetadata("key-baz", "baz1");
+  grpc::testing::EchoResponse resp;
+  grpc::Status status = SendRpc(channel, &context, &resp);
+  EXPECT_TRUE(status.ok());
+  EXPECT_EQ(resp.message(), kMessage);
+}
+
+TEST_F(SdkAuthzEnd2EndTest, StaticInitDeniesRpcRequestNoMatchInAllowAndDeny) {
+  std::string policy =
+      "{"
+      "  \"name\": \"authz\","
+      "  \"allow_rules\": ["
+      "    {"
+      "      \"name\": \"allow_foo\","
+      "      \"request\": {"
+      "        \"paths\": ["
+      "          \"*/foo\""
+      "        ]"
+      "      }"
+      "    }"
+      "  ],"
+      "  \"deny_rules\": ["
+      "    {"
+      "      \"name\": \"deny_bar\","
+      "      \"source\": {"
+      "        \"principals\": ["
+      "          \"bar\""
+      "        ]"
+      "      }"
+      "    }"
+      "  ]"
+      "}";
+  InitServer(CreateStaticAuthzPolicyProvider(policy));
+  auto channel = BuildChannel();
+  ClientContext context;
+  grpc::testing::EchoResponse resp;
+  grpc::Status status = SendRpc(channel, &context, &resp);
+  EXPECT_EQ(status.error_code(), grpc::StatusCode::PERMISSION_DENIED);
+  EXPECT_EQ(status.error_message(), "Unauthorized RPC request rejected.");
+  EXPECT_TRUE(resp.message().empty());
+}
+
+TEST_F(SdkAuthzEnd2EndTest, StaticInitDeniesRpcRequestMatchInDenyMatchInAllow) {
+  std::string policy =
+      "{"
+      "  \"name\": \"authz\","
+      "  \"allow_rules\": ["
+      "    {"
+      "      \"name\": \"allow_all\""
+      "    }"
+      "  ],"
+      "  \"deny_rules\": ["
+      "    {"
+      "      \"name\": \"deny_echo\","
+      "      \"request\": {"
+      "        \"paths\": ["
+      "          \"*/Echo\""
+      "        ]"
+      "      }"
+      "    }"
+      "  ]"
+      "}";
+  InitServer(CreateStaticAuthzPolicyProvider(policy));
+  auto channel = BuildChannel();
+  ClientContext context;
+  grpc::testing::EchoResponse resp;
+  grpc::Status status = SendRpc(channel, &context, &resp);
+  EXPECT_EQ(status.error_code(), grpc::StatusCode::PERMISSION_DENIED);
+  EXPECT_EQ(status.error_message(), "Unauthorized RPC request rejected.");
+  EXPECT_TRUE(resp.message().empty());
+}
+
+TEST_F(SdkAuthzEnd2EndTest,
+       StaticInitDeniesRpcRequestMatchInDenyNoMatchInAllow) {
+  std::string policy =
+      "{"
+      "  \"name\": \"authz\","
+      "  \"allow_rules\": ["
+      "    {"
+      "      \"name\": \"allow_clientstreamingecho\","
+      "      \"request\": {"
+      "        \"paths\": ["
+      "          \"*/ClientStreamingEcho\""
+      "        ]"
+      "      }"
+      "    }"
+      "  ],"
+      "  \"deny_rules\": ["
+      "    {"
+      "      \"name\": \"deny_echo\","
+      "      \"request\": {"
+      "        \"paths\": ["
+      "          \"*/Echo\""
+      "        ]"
+      "      }"
+      "    }"
+      "  ]"
+      "}";
+  InitServer(CreateStaticAuthzPolicyProvider(policy));
+  auto channel = BuildChannel();
+  ClientContext context;
+  grpc::testing::EchoResponse resp;
+  grpc::Status status = SendRpc(channel, &context, &resp);
+  EXPECT_EQ(status.error_code(), grpc::StatusCode::PERMISSION_DENIED);
+  EXPECT_EQ(status.error_message(), "Unauthorized RPC request rejected.");
+  EXPECT_TRUE(resp.message().empty());
+}
+
+TEST_F(SdkAuthzEnd2EndTest, StaticInitAllowsRpcRequestEmptyDenyMatchInAllow) {
+  std::string policy =
+      "{"
+      "  \"name\": \"authz\","
+      "  \"allow_rules\": ["
+      "    {"
+      "      \"name\": \"allow_echo\","
+      "      \"request\": {"
+      "        \"paths\": ["
+      "          \"*/Echo\""
+      "        ],"
+      "        \"headers\": ["
+      "          {"
+      "            \"key\": \"key-foo\","
+      "            \"values\": [\"foo1\", \"foo2\"]"
+      "          },"
+      "          {"
+      "            \"key\": \"key-bar\","
+      "            \"values\": [\"bar1\"]"
+      "          }"
+      "        ]"
+      "      }"
+      "    }"
+      "  ]"
+      "}";
+  InitServer(CreateStaticAuthzPolicyProvider(policy));
+  auto channel = BuildChannel();
+  ClientContext context;
+  context.AddMetadata("key-foo", "foo2");
+  context.AddMetadata("key-bar", "bar1");
+  context.AddMetadata("key-baz", "baz1");
+  grpc::testing::EchoResponse resp;
+  grpc::Status status = SendRpc(channel, &context, &resp);
+  EXPECT_TRUE(status.ok());
+  EXPECT_EQ(resp.message(), kMessage);
+}
+
+TEST_F(SdkAuthzEnd2EndTest, StaticInitDeniesRpcRequestEmptyDenyNoMatchInAllow) {
+  std::string policy =
+      "{"
+      "  \"name\": \"authz\","
+      "  \"allow_rules\": ["
+      "    {"
+      "      \"name\": \"allow_echo\","
+      "      \"request\": {"
+      "        \"paths\": ["
+      "          \"*/Echo\""
+      "        ],"
+      "        \"headers\": ["
+      "          {"
+      "            \"key\": \"key-foo\","
+      "            \"values\": [\"foo1\"]"
+      "          }"
+      "        ]"
+      "      }"
+      "    }"
+      "  ]"
+      "}";
+  InitServer(CreateStaticAuthzPolicyProvider(policy));
+  auto channel = BuildChannel();
+  ClientContext context;
+  context.AddMetadata("key-bar", "bar1");
+  grpc::testing::EchoResponse resp;
+  grpc::Status status = SendRpc(channel, &context, &resp);
+  EXPECT_EQ(status.error_code(), grpc::StatusCode::PERMISSION_DENIED);
+  EXPECT_EQ(status.error_message(), "Unauthorized RPC request rejected.");
+  EXPECT_TRUE(resp.message().empty());
+}
+
+TEST_F(
+    SdkAuthzEnd2EndTest,
+    StaticInitDeniesRpcRequestWithPrincipalsFieldOnUnauthenticatedConnection) {
+  std::string policy =
+      "{"
+      "  \"name\": \"authz\","
+      "  \"allow_rules\": ["
+      "    {"
+      "      \"name\": \"allow_echo\","
+      "      \"source\": {"
+      "        \"principals\": ["
+      "          \"foo\""
+      "        ]"
+      "      },"
+      "      \"request\": {"
+      "        \"paths\": ["
+      "          \"*/Echo\""
+      "        ]"
+      "      }"
+      "    }"
+      "  ]"
+      "}";
+  UseInsecureCredentials();
+  InitServer(CreateStaticAuthzPolicyProvider(policy));
+  auto channel = BuildChannel();
+  ClientContext context;
+  grpc::testing::EchoResponse resp;
+  grpc::Status status = SendRpc(channel, &context, &resp);
+  EXPECT_EQ(status.error_code(), grpc::StatusCode::PERMISSION_DENIED);
+  EXPECT_EQ(status.error_message(), "Unauthorized RPC request rejected.");
+  EXPECT_TRUE(resp.message().empty());
+}
+
+}  // namespace
+}  // namespace testing
+}  // namespace grpc
+
+int main(int argc, char** argv) {
+  ::testing::InitGoogleTest(&argc, argv);
+  grpc::testing::TestEnvironment env(argc, argv);
+  const auto result = RUN_ALL_TESTS();
+  return result;
+}
index 8f36d0c..4aaf018 100644 (file)
 
 #include <thread>
 
+#include <gtest/gtest.h>
+
+#include "absl/memory/memory.h"
+
 #include <grpc/grpc.h>
 #include <grpcpp/channel.h>
 #include <grpcpp/client_context.h>
 #include <grpcpp/server_builder.h>
 #include <grpcpp/server_context.h>
 
-#include "absl/memory/memory.h"
-
 #include "src/proto/grpc/testing/echo.grpc.pb.h"
 #include "test/core/util/port.h"
 #include "test/core/util/test_config.h"
 #include "test/cpp/end2end/test_service_impl.h"
 
-#include <gtest/gtest.h>
-
 #define PLUGIN_NAME "TestServerBuilderPlugin"
 
 namespace grpc {
index b26ddaa..5b5d90b 100644 (file)
  *
  */
 
+#include <gtest/gtest.h>
+
+#include "absl/memory/memory.h"
+
 #include <grpc/grpc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/time.h>
 #include <grpcpp/server_builder.h>
 #include <grpcpp/server_context.h>
 
-#include "absl/memory/memory.h"
-
 #include "src/proto/grpc/testing/duplicate/echo_duplicate.grpc.pb.h"
 #include "src/proto/grpc/testing/echo.grpc.pb.h"
 #include "test/core/util/port.h"
 #include "test/core/util/test_config.h"
 #include "test/cpp/util/subprocess.h"
 
-#include <gtest/gtest.h>
-
 using grpc::testing::EchoRequest;
 using grpc::testing::EchoResponse;
 
index 57d04a1..102df3c 100644 (file)
  *
  */
 
-#include <grpc/support/log.h>
-#include <grpcpp/channel.h>
-#include <grpcpp/client_context.h>
-#include <grpcpp/create_channel.h>
-
 #include <iostream>
 #include <memory>
 #include <sstream>
 #include <string>
 
 #include "absl/flags/flag.h"
+
+#include <grpc/support/log.h>
+#include <grpcpp/channel.h>
+#include <grpcpp/client_context.h>
+#include <grpcpp/create_channel.h>
+
 #include "src/proto/grpc/testing/echo.grpc.pb.h"
 #include "test/cpp/util/test_config.h"
 
@@ -68,6 +69,4 @@ int main(int argc, char** argv) {
             absl::GetFlag(FLAGS_mode).c_str());
     return 1;
   }
-
-  return 0;
 }
index c8c5bbe..b318a26 100644 (file)
@@ -16,6 +16,8 @@
  *
  */
 
+#include <gtest/gtest.h>
+
 #include <grpc/grpc.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
@@ -34,8 +36,6 @@
 #include "test/core/util/test_config.h"
 #include "test/cpp/util/string_ref_helper.h"
 
-#include <gtest/gtest.h>
-
 namespace grpc {
 namespace testing {
 namespace {
index 8145c8c..3f303cd 100644 (file)
 #include <memory>
 #include <vector>
 
+#include <gtest/gtest.h>
+
+#include "absl/memory/memory.h"
+#include "absl/strings/match.h"
+
 #include <grpcpp/channel.h>
 #include <grpcpp/client_context.h>
 #include <grpcpp/create_channel.h>
@@ -29,9 +34,6 @@
 #include <grpcpp/server_context.h>
 #include <grpcpp/support/server_interceptor.h>
 
-#include "absl/memory/memory.h"
-#include "absl/strings/match.h"
-
 #include "src/proto/grpc/testing/echo.grpc.pb.h"
 #include "test/core/util/port.h"
 #include "test/core/util/test_config.h"
@@ -39,8 +41,6 @@
 #include "test/cpp/end2end/test_service_impl.h"
 #include "test/cpp/util/byte_buffer_proto_helper.h"
 
-#include <gtest/gtest.h>
-
 namespace grpc {
 namespace testing {
 namespace {
index 5b3f2f7..bd64e17 100644 (file)
@@ -24,6 +24,9 @@
 #include <string>
 #include <thread>
 
+#include <gmock/gmock.h>
+#include <gtest/gtest.h>
+
 #include "absl/memory/memory.h"
 #include "absl/strings/str_cat.h"
 
 #include "src/core/lib/security/credentials/fake/fake_credentials.h"
 #include "src/cpp/client/secure_credentials.h"
 #include "src/cpp/server/secure_server_credentials.h"
-
 #include "src/proto/grpc/testing/echo.grpc.pb.h"
 #include "test/core/util/port.h"
 #include "test/core/util/resolve_localhost_ip46.h"
 #include "test/core/util/test_config.h"
 #include "test/cpp/end2end/test_service_impl.h"
 
-#include <gmock/gmock.h>
-#include <gtest/gtest.h>
-
 using grpc::testing::EchoRequest;
 using grpc::testing::EchoResponse;
 
index ed86f8a..384b2e8 100644 (file)
@@ -18,6 +18,8 @@
 
 #include <thread>
 
+#include <gtest/gtest.h>
+
 #include <grpc/grpc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/sync.h>
@@ -34,8 +36,6 @@
 #include "test/core/util/test_config.h"
 #include "test/cpp/util/test_credentials_provider.h"
 
-#include <gtest/gtest.h>
-
 using grpc::testing::EchoRequest;
 using grpc::testing::EchoResponse;
 
index bfc0d1e..4172195 100644 (file)
  */
 
 #include <time.h>
+
 #include <mutex>
 #include <thread>
 
+#include <gtest/gtest.h>
+
 #include <grpc/grpc.h>
 #include <grpc/support/atm.h>
 #include <grpc/support/log.h>
@@ -38,8 +41,6 @@
 #include "test/core/util/port.h"
 #include "test/core/util/test_config.h"
 
-#include <gtest/gtest.h>
-
 using grpc::testing::EchoRequest;
 using grpc::testing::EchoResponse;
 
index d8d85fb..6bc18e1 100644 (file)
 
 #include "test/cpp/end2end/test_service_impl.h"
 
+#include <string>
+#include <thread>
+
+#include <gtest/gtest.h>
+
 #include <grpc/support/log.h>
 #include <grpcpp/alarm.h>
 #include <grpcpp/security/credentials.h>
 #include <grpcpp/server_context.h>
-#include <gtest/gtest.h>
-
-#include <string>
-#include <thread>
 
 #include "src/proto/grpc/testing/echo.grpc.pb.h"
 #include "test/cpp/util/string_ref_helper.h"
index 682ef31..2b6c41a 100644 (file)
 #include <condition_variable>
 #include <memory>
 #include <mutex>
+#include <string>
+#include <thread>
+
+#include <gtest/gtest.h>
 
 #include <grpc/grpc.h>
 #include <grpc/support/log.h>
 #include <grpcpp/alarm.h>
 #include <grpcpp/security/credentials.h>
 #include <grpcpp/server_context.h>
-#include <gtest/gtest.h>
-
-#include <string>
-#include <thread>
 
 #include "src/proto/grpc/testing/echo.grpc.pb.h"
 #include "test/cpp/util/string_ref_helper.h"
@@ -403,6 +403,7 @@ class TestMultipleServiceImpl : public RpcService {
       response.set_message(request.message());
       if (read_counts == server_write_last) {
         stream->WriteLast(response, WriteOptions());
+        break;
       } else {
         stream->Write(response);
       }
index 0e7da2e..8b5170b 100644 (file)
@@ -20,6 +20,8 @@
 #include <mutex>
 #include <thread>
 
+#include <gtest/gtest.h>
+
 #include <grpc/grpc.h>
 #include <grpc/support/time.h>
 #include <grpcpp/channel.h>
@@ -38,8 +40,6 @@
 #include "test/core/util/port.h"
 #include "test/core/util/test_config.h"
 
-#include <gtest/gtest.h>
-
 using grpc::testing::EchoRequest;
 using grpc::testing::EchoResponse;
 
index 1d4efcf..0ea080e 100644 (file)
  *
  */
 
+#include <sys/time.h>
+
+#include <thread>
+
+#include <gtest/gtest.h>
+
+#include "absl/memory/memory.h"
+
 #include <grpc/grpc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/time.h>
@@ -26,8 +34,6 @@
 #include <grpcpp/server_builder.h>
 #include <grpcpp/server_context.h>
 
-#include "absl/memory/memory.h"
-
 #include "src/core/lib/iomgr/timer.h"
 #include "src/proto/grpc/testing/echo.grpc.pb.h"
 #include "test/core/util/port.h"
 #include "test/cpp/end2end/test_service_impl.h"
 #include "test/cpp/util/subprocess.h"
 
-#include <gtest/gtest.h>
-#include <sys/time.h>
-#include <thread>
-
 using grpc::testing::EchoRequest;
 using grpc::testing::EchoResponse;
 
index fa9aa4a..a670471 100644 (file)
@@ -56,7 +56,7 @@ TEST_P(XdsCredentialsEnd2EndFallbackTest, NoXdsSchemeInTarget) {
   ChannelArguments args;
   auto channel = grpc::CreateCustomChannel(
       server_address_,
-      grpc::experimental::XdsCredentials(
+      grpc::XdsCredentials(
           GetCredentialsProvider()->GetChannelCredentials(GetParam(), &args)),
       args);
   auto stub = grpc::testing::EchoTestService::NewStub(channel);
@@ -79,7 +79,7 @@ class XdsServerCredentialsEnd2EndFallbackTest
     server_address_ = "localhost:" + std::to_string(port);
     builder.AddListeningPort(
         server_address_,
-        grpc::experimental::XdsServerCredentials(
+        grpc::XdsServerCredentials(
             GetCredentialsProvider()->GetServerCredentials(GetParam())));
     builder.RegisterService(&service_);
     server_ = builder.BuildAndStart();
index 8329d1b..8f48005 100644 (file)
@@ -94,6 +94,7 @@
 #include "test/core/util/resolve_localhost_ip46.h"
 #include "test/core/util/test_config.h"
 #include "test/cpp/end2end/test_service_impl.h"
+#include "test/cpp/util/test_config.h"
 
 #ifndef DISABLED_XDS_PROTO_IN_CC
 #include "src/cpp/server/csds/csds.h"
@@ -306,8 +307,8 @@ class CountedService : public ServiceType {
 
  private:
   grpc_core::Mutex mu_;
-  size_t request_count_ = 0;
-  size_t response_count_ = 0;
+  size_t request_count_ ABSL_GUARDED_BY(mu_) = 0;
+  size_t response_count_ ABSL_GUARDED_BY(mu_) = 0;
 };
 
 template <typename RpcService>
@@ -360,8 +361,8 @@ class BackendServiceImpl
 
  private:
   grpc_core::Mutex mu_;
-  std::set<std::string> clients_;
-  std::vector<std::string> last_peer_identity_;
+  std::set<std::string> clients_ ABSL_GUARDED_BY(mu_);
+  std::vector<std::string> last_peer_identity_ ABSL_GUARDED_BY(mu_);
 };
 
 class ClientStats {
@@ -643,7 +644,7 @@ class AdsServiceImpl : public std::enable_shared_from_this<AdsServiceImpl> {
     NotifyDoneWithAdsCallLocked();
   }
 
-  void NotifyDoneWithAdsCallLocked() {
+  void NotifyDoneWithAdsCallLocked() ABSL_EXCLUSIVE_LOCKS_REQUIRED(ads_mu_) {
     if (!ads_done_) {
       ads_done_ = true;
       ads_cond_.SignalAll();
@@ -830,6 +831,28 @@ class AdsServiceImpl : public std::enable_shared_from_this<AdsServiceImpl> {
     }
 
    private:
+    // NB: clang's annotalysis is confused by the use of inner template
+    // classes here and *ignores* the exclusive lock annotation on some
+    // functions. See https://bugs.llvm.org/show_bug.cgi?id=51368.
+    //
+    // This class is used for a dual purpose:
+    // - it convinces clang that the lock is held in a given scope
+    // - when used in a function that is annotated to require the inner lock it
+    //   will cause compilation to fail if the upstream bug is fixed!
+    //
+    // If you arrive here because of a compilation failure, that might mean the
+    // clang bug is fixed! Please report that on the ticket.
+    //
+    // Since the buggy compiler will still need to be supported, consider
+    // wrapping this class in a compiler version #if and replace its usage
+    // with a macro whose expansion is conditional on the compiler version. In
+    // time (years? decades?) this code can be deleted altogether.
+    class ABSL_SCOPED_LOCKABLE NoopMutexLock {
+     public:
+      explicit NoopMutexLock(grpc_core::Mutex& mu)
+          ABSL_EXCLUSIVE_LOCK_FUNCTION(mu) {}
+      ~NoopMutexLock() ABSL_UNLOCK_FUNCTION() {}
+    };
     // Processes a response read from the client.
     // Populates response if needed.
     void ProcessRequest(const DiscoveryRequest& request,
@@ -837,7 +860,9 @@ class AdsServiceImpl : public std::enable_shared_from_this<AdsServiceImpl> {
                         UpdateQueue* update_queue,
                         SubscriptionMap* subscription_map,
                         SentState* sent_state,
-                        absl::optional<DiscoveryResponse>* response) {
+                        absl::optional<DiscoveryResponse>* response)
+        ABSL_EXCLUSIVE_LOCKS_REQUIRED(parent_->ads_mu_) {
+      NoopMutexLock mu(parent_->ads_mu_);
       // Check the nonce sent by the client, if any.
       // (This will be absent on the first request on a stream.)
       if (request.response_nonce().empty()) {
@@ -936,7 +961,9 @@ class AdsServiceImpl : public std::enable_shared_from_this<AdsServiceImpl> {
     void ProcessUpdate(const std::string& resource_type,
                        const std::string& resource_name,
                        SubscriptionMap* subscription_map, SentState* sent_state,
-                       absl::optional<DiscoveryResponse>* response) {
+                       absl::optional<DiscoveryResponse>* response)
+        ABSL_EXCLUSIVE_LOCKS_REQUIRED(parent_->ads_mu_) {
+      NoopMutexLock mu(parent_->ads_mu_);
       const std::string v2_resource_type = TypeUrlToV2(resource_type);
       gpr_log(GPR_INFO, "ADS[%p]: Received update for type=%s name=%s", this,
               resource_type.c_str(), resource_name.c_str());
@@ -996,7 +1023,9 @@ class AdsServiceImpl : public std::enable_shared_from_this<AdsServiceImpl> {
         const std::string& resource_type, const std::string& v2_resource_type,
         const int version, const SubscriptionNameMap& subscription_name_map,
         const std::set<std::string>& resources_added_to_response,
-        SentState* sent_state, DiscoveryResponse* response) {
+        SentState* sent_state, DiscoveryResponse* response)
+        ABSL_EXCLUSIVE_LOCKS_REQUIRED(parent_->ads_mu_) {
+      NoopMutexLock mu(parent_->ads_mu_);
       auto& response_state =
           parent_->resource_type_response_state_[resource_type];
       if (response_state.state == ResponseState::NOT_SENT) {
@@ -1140,22 +1169,23 @@ class AdsServiceImpl : public std::enable_shared_from_this<AdsServiceImpl> {
   std::atomic_bool seen_v3_client_{false};
 
   grpc_core::CondVar ads_cond_;
-  // Protect the members below.
   grpc_core::Mutex ads_mu_;
-  bool ads_done_ = false;
+  bool ads_done_ ABSL_GUARDED_BY(ads_mu_) = false;
   std::map<std::string /* type_url */, ResponseState>
-      resource_type_response_state_;
-  std::set<std::string /*resource_type*/> resource_types_to_ignore_;
-  std::map<std::string /*resource_type*/, int> resource_type_min_versions_;
+      resource_type_response_state_ ABSL_GUARDED_BY(ads_mu_);
+  std::set<std::string /*resource_type*/> resource_types_to_ignore_
+      ABSL_GUARDED_BY(ads_mu_);
+  std::map<std::string /*resource_type*/, int> resource_type_min_versions_
+      ABSL_GUARDED_BY(ads_mu_);
   // An instance data member containing the current state of all resources.
   // Note that an entry will exist whenever either of the following is true:
   // - The resource exists (i.e., has been created by SetResource() and has not
   //   yet been destroyed by UnsetResource()).
   // - There is at least one subscription for the resource.
-  ResourceMap resource_map_;
+  ResourceMap resource_map_ ABSL_GUARDED_BY(ads_mu_);
 
   grpc_core::Mutex clients_mu_;
-  std::set<std::string> clients_;
+  std::set<std::string> clients_ ABSL_GUARDED_BY(clients_mu_);
 };
 
 class LrsServiceImpl : public std::enable_shared_from_this<LrsServiceImpl> {
@@ -1193,9 +1223,15 @@ class LrsServiceImpl : public std::enable_shared_from_this<LrsServiceImpl> {
     cluster_names_ = cluster_names;
   }
 
-  void Start() {
-    lrs_done_ = false;
-    result_queue_.clear();
+  void Start() ABSL_LOCKS_EXCLUDED(lrs_mu_, load_report_mu_) {
+    {
+      grpc_core::MutexLock lock(&lrs_mu_);
+      lrs_done_ = false;
+    }
+    {
+      grpc_core::MutexLock lock(&load_report_mu_);
+      result_queue_.clear();
+    }
   }
 
   void Shutdown() {
@@ -1292,7 +1328,7 @@ class LrsServiceImpl : public std::enable_shared_from_this<LrsServiceImpl> {
     LrsServiceImpl* parent_;
   };
 
-  void NotifyDoneWithLrsCallLocked() {
+  void NotifyDoneWithLrsCallLocked() ABSL_EXCLUSIVE_LOCKS_REQUIRED(lrs_mu_) {
     if (!lrs_done_) {
       lrs_done_ = true;
       lrs_cv_.SignalAll();
@@ -1313,12 +1349,14 @@ class LrsServiceImpl : public std::enable_shared_from_this<LrsServiceImpl> {
   std::set<std::string> cluster_names_;
 
   grpc_core::CondVar lrs_cv_;
-  grpc_core::Mutex lrs_mu_;  // Protects lrs_done_.
-  bool lrs_done_ = false;
-
-  grpc_core::Mutex load_report_mu_;  // Protects the members below.
-  grpc_core::CondVar* load_report_cond_ = nullptr;
-  std::deque<std::vector<ClientStats>> result_queue_;
+  grpc_core::Mutex lrs_mu_;
+  bool lrs_done_ ABSL_GUARDED_BY(lrs_mu_) = false;
+
+  grpc_core::Mutex load_report_mu_;
+  grpc_core::CondVar* load_report_cond_ ABSL_GUARDED_BY(load_report_mu_) =
+      nullptr;
+  std::deque<std::vector<ClientStats>> result_queue_
+      ABSL_GUARDED_BY(load_report_mu_);
 };
 
 class TestType {
@@ -1451,10 +1489,9 @@ class FakeCertificateProvider final : public grpc_tls_certificate_provider {
       if (!root_being_watched && !identity_being_watched) return;
       auto it = cert_data_map_.find(cert_name);
       if (it == cert_data_map_.end()) {
-        grpc_error_handle error = GRPC_ERROR_CREATE_FROM_COPIED_STRING(
-            absl::StrCat("No certificates available for cert_name \"",
-                         cert_name, "\"")
-                .c_str());
+        grpc_error_handle error =
+            GRPC_ERROR_CREATE_FROM_CPP_STRING(absl::StrCat(
+                "No certificates available for cert_name \"", cert_name, "\""));
         distributor_->SetErrorForCert(cert_name, GRPC_ERROR_REF(error),
                                       GRPC_ERROR_REF(error));
         GRPC_ERROR_UNREF(error);
@@ -1852,7 +1889,7 @@ class XdsEnd2endTest : public ::testing::TestWithParam<TestType> {
         GetParam().use_fake_resolver() ? "fake" : "xds", ":///", server_name);
     std::shared_ptr<ChannelCredentials> channel_creds =
         GetParam().use_xds_credentials()
-            ? experimental::XdsCredentials(CreateTlsFallbackCredentials())
+            ? XdsCredentials(CreateTlsFallbackCredentials())
             : std::make_shared<SecureChannelCredentials>(
                   grpc_fake_transport_security_credentials_create());
     return ::grpc::CreateCustomChannel(uri, channel_creds, args);
@@ -2453,9 +2490,10 @@ class XdsEnd2endTest : public ::testing::TestWithParam<TestType> {
   class XdsServingStatusNotifier
       : public grpc::experimental::XdsServerServingStatusNotifierInterface {
    public:
-    void OnServingStatusUpdate(std::string uri, grpc::Status status) override {
+    void OnServingStatusUpdate(std::string uri,
+                               ServingStatusUpdate update) override {
       grpc_core::MutexLock lock(&mu_);
-      status_map[uri] = status;
+      status_map[uri] = update.status;
       cond_.Signal();
     }
 
@@ -2472,7 +2510,7 @@ class XdsEnd2endTest : public ::testing::TestWithParam<TestType> {
    private:
     grpc_core::Mutex mu_;
     grpc_core::CondVar cond_;
-    std::map<std::string, grpc::Status> status_map;
+    std::map<std::string, grpc::Status> status_map ABSL_GUARDED_BY(mu_);
   };
 
   class ServerThread {
@@ -2507,7 +2545,7 @@ class XdsEnd2endTest : public ::testing::TestWithParam<TestType> {
       std::ostringstream server_address;
       server_address << "localhost:" << port_;
       if (use_xds_enabled_server_) {
-        experimental::XdsServerBuilder builder;
+        XdsServerBuilder builder;
         if (GetParam().bootstrap_source() ==
             TestType::kBootstrapFromChannelArg) {
           builder.SetOption(
@@ -2609,8 +2647,7 @@ class XdsEnd2endTest : public ::testing::TestWithParam<TestType> {
       if (GetParam().use_xds_credentials()) {
         if (use_xds_enabled_server()) {
           // We are testing server's use of XdsServerCredentials
-          return experimental::XdsServerCredentials(
-              InsecureServerCredentials());
+          return XdsServerCredentials(InsecureServerCredentials());
         } else {
           // We are testing client's use of XdsCredentials
           std::string root_cert = ReadFile(kCaCertPath);
@@ -3351,46 +3388,98 @@ TEST_P(GlobalXdsClientTest, MultipleChannelsShareXdsClient) {
 // Tests that the NACK for multiple bad LDS resources includes both errors.
 TEST_P(GlobalXdsClientTest, MultipleBadResources) {
   constexpr char kServerName2[] = "server.other.com";
+  constexpr char kServerName3[] = "server.another.com";
   auto listener = default_listener_;
   listener.clear_api_listener();
   balancers_[0]->ads_service()->SetLdsResource(listener);
   listener.set_name(kServerName2);
   balancers_[0]->ads_service()->SetLdsResource(listener);
+  listener = default_listener_;
+  listener.set_name(kServerName3);
+  SetListenerAndRouteConfiguration(0, listener, default_route_config_);
+  AdsServiceImpl::EdsResourceArgs args({
+      {"locality0", CreateEndpointsForBackends(0, 1)},
+  });
+  balancers_[0]->ads_service()->SetEdsResource(BuildEdsResource(args));
   SetNextResolutionForLbChannelAllBalancers();
   CheckRpcSendFailure();
   // Need to create a second channel to subscribe to a second LDS resource.
   auto channel2 = CreateChannel(0, kServerName2);
   auto stub2 = grpc::testing::EchoTestService::NewStub(channel2);
-  ClientContext context;
-  EchoRequest request;
-  request.set_message(kRequestMessage);
-  EchoResponse response;
-  grpc::Status status = stub2->Echo(&context, request, &response);
-  EXPECT_FALSE(status.ok());
-  // Wait for second NACK to be reported to xDS server.
+  {
+    ClientContext context;
+    EchoRequest request;
+    request.set_message(kRequestMessage);
+    EchoResponse response;
+    grpc::Status status = stub2->Echo(&context, request, &response);
+    EXPECT_FALSE(status.ok());
+    // Wait for second NACK to be reported to xDS server.
+    auto deadline = absl::Now() + absl::Seconds(30);
+    bool timed_out = false;
+    CheckRpcSendFailure(
+        CheckRpcSendFailureOptions().set_continue_predicate([&](size_t) {
+          if (absl::Now() >= deadline) {
+            timed_out = true;
+            return false;
+          }
+          const auto response_state =
+              balancers_[0]->ads_service()->lds_response_state();
+          return response_state.state !=
+                     AdsServiceImpl::ResponseState::NACKED ||
+                 ::testing::Matches(::testing::ContainsRegex(absl::StrCat(
+                     kServerName,
+                     ": validation error.*"
+                     "Listener has neither address nor ApiListener.*",
+                     kServerName2,
+                     ": validation error.*"
+                     "Listener has neither address nor ApiListener")))(
+                     response_state.error_message);
+        }));
+    ASSERT_FALSE(timed_out);
+  }
+  // Now start a new channel with a third server name, this one with a
+  // valid resource.
+  auto channel3 = CreateChannel(0, kServerName3);
+  auto stub3 = grpc::testing::EchoTestService::NewStub(channel3);
+  {
+    ClientContext context;
+    EchoRequest request;
+    request.set_message(kRequestMessage);
+    EchoResponse response;
+    grpc::Status status = stub3->Echo(&context, request, &response);
+    EXPECT_TRUE(status.ok()) << "code=" << status.error_code()
+                             << " message=" << status.error_message();
+  }
+}
+
+// Tests that we don't trigger does-not-exist callbacks for a resource
+// that was previously valid but is updated to be invalid.
+TEST_P(GlobalXdsClientTest, InvalidListenerStillExistsIfPreviouslyCached) {
+  // Set up valid resources and check that the channel works.
+  AdsServiceImpl::EdsResourceArgs args({
+      {"locality0", CreateEndpointsForBackends(0, 1)},
+  });
+  balancers_[0]->ads_service()->SetEdsResource(BuildEdsResource(args));
+  SetNextResolutionForLbChannelAllBalancers();
+  CheckRpcSendOk();
+  // Now send an update changing the Listener to be invalid.
+  auto listener = default_listener_;
+  listener.clear_api_listener();
+  balancers_[0]->ads_service()->SetLdsResource(listener);
+  // Wait for xDS server to see NACK.
   auto deadline = absl::Now() + absl::Seconds(30);
-  bool timed_out = false;
-  CheckRpcSendFailure(
-      CheckRpcSendFailureOptions().set_continue_predicate([&](size_t) {
-        if (absl::Now() >= deadline) {
-          timed_out = true;
-          return false;
-        }
-        const auto response_state =
-            balancers_[0]->ads_service()->lds_response_state();
-        return response_state.state != AdsServiceImpl::ResponseState::NACKED ||
-               !absl::StrContains(
-                   response_state.error_message,
-                   absl::StrCat(
-                       kServerName,
-                       ": Listener has neither address nor ApiListener")) ||
-               !absl::StrContains(
-                   response_state.error_message,
-                   absl::StrCat(
-                       kServerName2,
-                       ": Listener has neither address nor ApiListener"));
-      }));
-  ASSERT_FALSE(timed_out);
+  do {
+    CheckRpcSendOk();
+    ASSERT_LT(absl::Now(), deadline);
+  } while (balancers_[0]->ads_service()->lds_response_state().state !=
+           AdsServiceImpl::ResponseState::NACKED);
+  EXPECT_THAT(balancers_[0]->ads_service()->lds_response_state().error_message,
+              ::testing::ContainsRegex(absl::StrCat(
+                  kServerName,
+                  ": validation error.*"
+                  "Listener has neither address nor ApiListener")));
+  // Check one more time, just to make sure it still works after NACK.
+  CheckRpcSendOk();
 }
 
 class XdsResolverLoadReportingOnlyTest : public XdsEnd2endTest {
@@ -3542,7 +3631,7 @@ TEST_P(SecureNamingTest, TargetNameIsExpected) {
 
 // Tests that secure naming check fails if target name is unexpected.
 TEST_P(SecureNamingTest, TargetNameIsUnexpected) {
-  ::testing::FLAGS_gtest_death_test_style = "threadsafe";
+  GRPC_GTEST_FLAG_SET_DEATH_TEST_STYLE("threadsafe");
   SetNextResolution({});
   SetNextResolutionForLbChannel({balancers_[0]->port()}, nullptr,
                                 "incorrect_server_name");
@@ -7197,19 +7286,42 @@ TEST_P(CdsTest, UnsupportedClusterType) {
 // Tests that the NACK for multiple bad resources includes both errors.
 TEST_P(CdsTest, MultipleBadResources) {
   constexpr char kClusterName2[] = "cluster_name_2";
-  // Use unsupported type for default cluster.
+  constexpr char kClusterName3[] = "cluster_name_3";
+  // Add cluster with unsupported type.
   auto cluster = default_cluster_;
+  cluster.set_name(kClusterName2);
   cluster.set_type(Cluster::STATIC);
   balancers_[0]->ads_service()->SetCdsResource(cluster);
   // Add second cluster with the same error.
-  cluster.set_name(kClusterName2);
+  cluster.set_name(kClusterName3);
   balancers_[0]->ads_service()->SetCdsResource(cluster);
-  // Change RouteConfig to point to both clusters.
+  // Change RouteConfig to point to all clusters.
   RouteConfiguration route_config = default_route_config_;
+  route_config.mutable_virtual_hosts(0)->clear_routes();
+  // First route: default cluster, selected based on header.
   auto* route = route_config.mutable_virtual_hosts(0)->add_routes();
   route->mutable_match()->set_prefix("");
+  auto* header_matcher = route->mutable_match()->add_headers();
+  header_matcher->set_name("cluster");
+  header_matcher->set_exact_match(kDefaultClusterName);
+  route->mutable_route()->set_cluster(kDefaultClusterName);
+  // Second route: cluster 2, selected based on header.
+  route = route_config.mutable_virtual_hosts(0)->add_routes();
+  route->mutable_match()->set_prefix("");
+  header_matcher = route->mutable_match()->add_headers();
+  header_matcher->set_name("cluster");
+  header_matcher->set_exact_match(kClusterName2);
   route->mutable_route()->set_cluster(kClusterName2);
+  // Third route: cluster 3, used by default.
+  route = route_config.mutable_virtual_hosts(0)->add_routes();
+  route->mutable_match()->set_prefix("");
+  route->mutable_route()->set_cluster(kClusterName3);
   SetRouteConfiguration(0, route_config);
+  // Add EDS resource.
+  AdsServiceImpl::EdsResourceArgs args({
+      {"locality0", CreateEndpointsForBackends(0, 1)},
+  });
+  balancers_[0]->ads_service()->SetEdsResource(BuildEdsResource(args));
   // Send RPC.
   SetNextResolution({});
   SetNextResolutionForLbChannelAllBalancers();
@@ -7217,12 +7329,56 @@ TEST_P(CdsTest, MultipleBadResources) {
   const auto response_state =
       balancers_[0]->ads_service()->cds_response_state();
   EXPECT_EQ(response_state.state, AdsServiceImpl::ResponseState::NACKED);
-  EXPECT_THAT(response_state.error_message,
-              ::testing::AllOf(
-                  ::testing::HasSubstr(absl::StrCat(
-                      kDefaultClusterName, ": DiscoveryType is not valid.")),
-                  ::testing::HasSubstr(absl::StrCat(
-                      kClusterName2, ": DiscoveryType is not valid."))));
+  EXPECT_THAT(
+      response_state.error_message,
+      ::testing::ContainsRegex(absl::StrCat(kClusterName2,
+                                            ": validation error.*"
+                                            "DiscoveryType is not valid.*",
+                                            kClusterName3,
+                                            ": validation error.*"
+                                            "DiscoveryType is not valid")));
+  // RPCs for default cluster should succeed.
+  std::vector<std::pair<std::string, std::string>> metadata_default_cluster = {
+      {"cluster", kDefaultClusterName},
+  };
+  CheckRpcSendOk(
+      1, RpcOptions().set_metadata(std::move(metadata_default_cluster)));
+  // RPCs for cluster 2 should fail.
+  std::vector<std::pair<std::string, std::string>> metadata_cluster_2 = {
+      {"cluster", kClusterName2},
+  };
+  CheckRpcSendFailure(CheckRpcSendFailureOptions().set_rpc_options(
+      RpcOptions().set_metadata(std::move(metadata_cluster_2))));
+}
+
+// Tests that we don't trigger does-not-exist callbacks for a resource
+// that was previously valid but is updated to be invalid.
+TEST_P(CdsTest, InvalidClusterStillExistsIfPreviouslyCached) {
+  AdsServiceImpl::EdsResourceArgs args({
+      {"locality0", CreateEndpointsForBackends(0, 1)},
+  });
+  balancers_[0]->ads_service()->SetEdsResource(BuildEdsResource(args));
+  SetNextResolution({});
+  SetNextResolutionForLbChannelAllBalancers();
+  // Check that everything works.
+  CheckRpcSendOk();
+  // Now send an update changing the Cluster to be invalid.
+  auto cluster = default_cluster_;
+  cluster.set_type(Cluster::STATIC);
+  balancers_[0]->ads_service()->SetCdsResource(cluster);
+  // Wait for xDS server to see NACK.
+  auto deadline = absl::Now() + absl::Seconds(30);
+  do {
+    CheckRpcSendOk();
+    ASSERT_LT(absl::Now(), deadline);
+  } while (balancers_[0]->ads_service()->cds_response_state().state !=
+           AdsServiceImpl::ResponseState::NACKED);
+  EXPECT_THAT(balancers_[0]->ads_service()->cds_response_state().error_message,
+              ::testing::ContainsRegex(absl::StrCat(
+                  kDefaultClusterName,
+                  ": validation error.*DiscoveryType is not valid")));
+  // Check one more time, just to make sure it still works after NACK.
+  CheckRpcSendOk();
 }
 
 // Tests that CDS client should send a NACK if the eds_config in CDS response
@@ -8032,16 +8188,6 @@ TEST_P(CdsTest, RingHashPolicyHasInvalidRingSizeMinGreaterThanMax) {
 
 class XdsSecurityTest : public BasicTest {
  protected:
-  static void SetUpTestCase() {
-    gpr_setenv("GRPC_XDS_EXPERIMENTAL_SECURITY_SUPPORT", "true");
-    BasicTest::SetUpTestCase();
-  }
-
-  static void TearDownTestCase() {
-    BasicTest::TearDownTestCase();
-    gpr_unsetenv("GRPC_XDS_EXPERIMENTAL_SECURITY_SUPPORT");
-  }
-
   void SetUp() override {
     BasicTest::SetUp();
     root_cert_ = ReadFile(kCaCertPath);
@@ -8099,27 +8245,26 @@ class XdsSecurityTest : public BasicTest {
       UpstreamTlsContext upstream_tls_context;
       if (!identity_instance_name.empty()) {
         upstream_tls_context.mutable_common_tls_context()
-            ->mutable_tls_certificate_certificate_provider_instance()
+            ->mutable_tls_certificate_provider_instance()
             ->set_instance_name(std::string(identity_instance_name));
         upstream_tls_context.mutable_common_tls_context()
-            ->mutable_tls_certificate_certificate_provider_instance()
+            ->mutable_tls_certificate_provider_instance()
             ->set_certificate_name(std::string(identity_certificate_name));
       }
       if (!root_instance_name.empty()) {
         upstream_tls_context.mutable_common_tls_context()
-            ->mutable_combined_validation_context()
-            ->mutable_validation_context_certificate_provider_instance()
+            ->mutable_validation_context()
+            ->mutable_ca_certificate_provider_instance()
             ->set_instance_name(std::string(root_instance_name));
         upstream_tls_context.mutable_common_tls_context()
-            ->mutable_combined_validation_context()
-            ->mutable_validation_context_certificate_provider_instance()
+            ->mutable_validation_context()
+            ->mutable_ca_certificate_provider_instance()
             ->set_certificate_name(std::string(root_certificate_name));
       }
       if (!san_matchers.empty()) {
         auto* validation_context =
             upstream_tls_context.mutable_common_tls_context()
-                ->mutable_combined_validation_context()
-                ->mutable_default_validation_context();
+                ->mutable_validation_context();
         for (const auto& san_matcher : san_matchers) {
           *validation_context->add_match_subject_alt_names() = san_matcher;
         }
@@ -8209,9 +8354,8 @@ TEST_P(XdsSecurityTest,
       balancers_[0]->ads_service()->cds_response_state();
   EXPECT_EQ(response_state.state, AdsServiceImpl::ResponseState::NACKED);
   EXPECT_THAT(response_state.error_message,
-              ::testing::HasSubstr(
-                  "TLS configuration provided but no "
-                  "validation_context_certificate_provider_instance found."));
+              ::testing::HasSubstr("TLS configuration provided but no "
+                                   "ca_certificate_provider_instance found."));
 }
 
 TEST_P(
@@ -8222,8 +8366,7 @@ TEST_P(
   transport_socket->set_name("envoy.transport_sockets.tls");
   UpstreamTlsContext upstream_tls_context;
   auto* validation_context = upstream_tls_context.mutable_common_tls_context()
-                                 ->mutable_combined_validation_context()
-                                 ->mutable_default_validation_context();
+                                 ->mutable_validation_context();
   *validation_context->add_match_subject_alt_names() = server_san_exact_;
   transport_socket->mutable_typed_config()->PackFrom(upstream_tls_context);
   balancers_[0]->ads_service()->SetCdsResource(cluster);
@@ -8232,20 +8375,19 @@ TEST_P(
       balancers_[0]->ads_service()->cds_response_state();
   EXPECT_EQ(response_state.state, AdsServiceImpl::ResponseState::NACKED);
   EXPECT_THAT(response_state.error_message,
-              ::testing::HasSubstr(
-                  "TLS configuration provided but no "
-                  "validation_context_certificate_provider_instance found."));
+              ::testing::HasSubstr("TLS configuration provided but no "
+                                   "ca_certificate_provider_instance found."));
 }
 
 TEST_P(
     XdsSecurityTest,
-    TlsCertificateCertificateProviderInstanceWithoutValidationContextCertificateProviderInstance) {
+    TlsCertificateProviderInstanceWithoutValidationContextCertificateProviderInstance) {
   auto cluster = default_cluster_;
   auto* transport_socket = cluster.mutable_transport_socket();
   transport_socket->set_name("envoy.transport_sockets.tls");
   UpstreamTlsContext upstream_tls_context;
   upstream_tls_context.mutable_common_tls_context()
-      ->mutable_tls_certificate_certificate_provider_instance()
+      ->mutable_tls_certificate_provider_instance()
       ->set_instance_name(std::string("fake_plugin1"));
   transport_socket->mutable_typed_config()->PackFrom(upstream_tls_context);
   balancers_[0]->ads_service()->SetCdsResource(cluster);
@@ -8254,9 +8396,8 @@ TEST_P(
       balancers_[0]->ads_service()->cds_response_state();
   EXPECT_EQ(response_state.state, AdsServiceImpl::ResponseState::NACKED);
   EXPECT_THAT(response_state.error_message,
-              ::testing::HasSubstr(
-                  "TLS configuration provided but no "
-                  "validation_context_certificate_provider_instance found."));
+              ::testing::HasSubstr("TLS configuration provided but no "
+                                   "ca_certificate_provider_instance found."));
 }
 
 TEST_P(XdsSecurityTest, RegexSanMatcherDoesNotAllowIgnoreCase) {
@@ -8265,12 +8406,11 @@ TEST_P(XdsSecurityTest, RegexSanMatcherDoesNotAllowIgnoreCase) {
   transport_socket->set_name("envoy.transport_sockets.tls");
   UpstreamTlsContext upstream_tls_context;
   upstream_tls_context.mutable_common_tls_context()
-      ->mutable_combined_validation_context()
-      ->mutable_validation_context_certificate_provider_instance()
+      ->mutable_validation_context()
+      ->mutable_ca_certificate_provider_instance()
       ->set_instance_name(std::string("fake_plugin1"));
   auto* validation_context = upstream_tls_context.mutable_common_tls_context()
-                                 ->mutable_combined_validation_context()
-                                 ->mutable_default_validation_context();
+                                 ->mutable_validation_context();
   StringMatcher matcher;
   matcher.mutable_safe_regex()->mutable_google_re2();
   matcher.mutable_safe_regex()->set_regex(
@@ -8294,8 +8434,8 @@ TEST_P(XdsSecurityTest, UnknownRootCertificateProvider) {
   transport_socket->set_name("envoy.transport_sockets.tls");
   UpstreamTlsContext upstream_tls_context;
   upstream_tls_context.mutable_common_tls_context()
-      ->mutable_combined_validation_context()
-      ->mutable_validation_context_certificate_provider_instance()
+      ->mutable_validation_context()
+      ->mutable_ca_certificate_provider_instance()
       ->set_instance_name("unknown");
   transport_socket->mutable_typed_config()->PackFrom(upstream_tls_context);
   balancers_[0]->ads_service()->SetCdsResource(cluster);
@@ -8317,11 +8457,11 @@ TEST_P(XdsSecurityTest, UnknownIdentityCertificateProvider) {
   transport_socket->set_name("envoy.transport_sockets.tls");
   UpstreamTlsContext upstream_tls_context;
   upstream_tls_context.mutable_common_tls_context()
-      ->mutable_tls_certificate_certificate_provider_instance()
+      ->mutable_tls_certificate_provider_instance()
       ->set_instance_name("unknown");
   upstream_tls_context.mutable_common_tls_context()
-      ->mutable_combined_validation_context()
-      ->mutable_validation_context_certificate_provider_instance()
+      ->mutable_validation_context()
+      ->mutable_ca_certificate_provider_instance()
       ->set_instance_name("fake_plugin1");
   transport_socket->mutable_typed_config()->PackFrom(upstream_tls_context);
   balancers_[0]->ads_service()->SetCdsResource(cluster);
@@ -8335,6 +8475,304 @@ TEST_P(XdsSecurityTest, UnknownIdentityCertificateProvider) {
   g_fake1_cert_data_map = nullptr;
 }
 
+TEST_P(XdsSecurityTest,
+       NacksCertificateValidationContextWithVerifyCertificateSpki) {
+  FakeCertificateProvider::CertDataMap fake1_cert_map = {
+      {"", {root_cert_, identity_pair_}}};
+  g_fake1_cert_data_map = &fake1_cert_map;
+  auto cluster = default_cluster_;
+  auto* transport_socket = cluster.mutable_transport_socket();
+  transport_socket->set_name("envoy.transport_sockets.tls");
+  UpstreamTlsContext upstream_tls_context;
+  upstream_tls_context.mutable_common_tls_context()
+      ->mutable_validation_context()
+      ->mutable_ca_certificate_provider_instance()
+      ->set_instance_name("fake_plugin1");
+  upstream_tls_context.mutable_common_tls_context()
+      ->mutable_validation_context()
+      ->add_verify_certificate_spki("spki");
+  transport_socket->mutable_typed_config()->PackFrom(upstream_tls_context);
+  balancers_[0]->ads_service()->SetCdsResource(cluster);
+  ASSERT_TRUE(WaitForCdsNack()) << "timed out waiting for NACK";
+  const auto response_state =
+      balancers_[0]->ads_service()->cds_response_state();
+  EXPECT_EQ(response_state.state, AdsServiceImpl::ResponseState::NACKED);
+  EXPECT_THAT(
+      response_state.error_message,
+      ::testing::HasSubstr(
+          "CertificateValidationContext: verify_certificate_spki unsupported"));
+}
+
+TEST_P(XdsSecurityTest,
+       NacksCertificateValidationContextWithVerifyCertificateHash) {
+  FakeCertificateProvider::CertDataMap fake1_cert_map = {
+      {"", {root_cert_, identity_pair_}}};
+  g_fake1_cert_data_map = &fake1_cert_map;
+  auto cluster = default_cluster_;
+  auto* transport_socket = cluster.mutable_transport_socket();
+  transport_socket->set_name("envoy.transport_sockets.tls");
+  UpstreamTlsContext upstream_tls_context;
+  upstream_tls_context.mutable_common_tls_context()
+      ->mutable_validation_context()
+      ->mutable_ca_certificate_provider_instance()
+      ->set_instance_name("fake_plugin1");
+  upstream_tls_context.mutable_common_tls_context()
+      ->mutable_validation_context()
+      ->add_verify_certificate_hash("hash");
+  transport_socket->mutable_typed_config()->PackFrom(upstream_tls_context);
+  balancers_[0]->ads_service()->SetCdsResource(cluster);
+  ASSERT_TRUE(WaitForCdsNack()) << "timed out waiting for NACK";
+  const auto response_state =
+      balancers_[0]->ads_service()->cds_response_state();
+  EXPECT_EQ(response_state.state, AdsServiceImpl::ResponseState::NACKED);
+  EXPECT_THAT(
+      response_state.error_message,
+      ::testing::HasSubstr(
+          "CertificateValidationContext: verify_certificate_hash unsupported"));
+}
+
+TEST_P(XdsSecurityTest,
+       NacksCertificateValidationContextWithRequireSignedCertificateTimes) {
+  FakeCertificateProvider::CertDataMap fake1_cert_map = {
+      {"", {root_cert_, identity_pair_}}};
+  g_fake1_cert_data_map = &fake1_cert_map;
+  auto cluster = default_cluster_;
+  auto* transport_socket = cluster.mutable_transport_socket();
+  transport_socket->set_name("envoy.transport_sockets.tls");
+  UpstreamTlsContext upstream_tls_context;
+  upstream_tls_context.mutable_common_tls_context()
+      ->mutable_validation_context()
+      ->mutable_ca_certificate_provider_instance()
+      ->set_instance_name("fake_plugin1");
+  upstream_tls_context.mutable_common_tls_context()
+      ->mutable_validation_context()
+      ->mutable_require_signed_certificate_timestamp()
+      ->set_value(true);
+  transport_socket->mutable_typed_config()->PackFrom(upstream_tls_context);
+  balancers_[0]->ads_service()->SetCdsResource(cluster);
+  ASSERT_TRUE(WaitForCdsNack()) << "timed out waiting for NACK";
+  const auto response_state =
+      balancers_[0]->ads_service()->cds_response_state();
+  EXPECT_EQ(response_state.state, AdsServiceImpl::ResponseState::NACKED);
+  EXPECT_THAT(
+      response_state.error_message,
+      ::testing::HasSubstr("CertificateValidationContext: "
+                           "require_signed_certificate_timestamp unsupported"));
+}
+
+TEST_P(XdsSecurityTest, NacksCertificateValidationContextWithCrl) {
+  FakeCertificateProvider::CertDataMap fake1_cert_map = {
+      {"", {root_cert_, identity_pair_}}};
+  g_fake1_cert_data_map = &fake1_cert_map;
+  auto cluster = default_cluster_;
+  auto* transport_socket = cluster.mutable_transport_socket();
+  transport_socket->set_name("envoy.transport_sockets.tls");
+  UpstreamTlsContext upstream_tls_context;
+  upstream_tls_context.mutable_common_tls_context()
+      ->mutable_validation_context()
+      ->mutable_ca_certificate_provider_instance()
+      ->set_instance_name("fake_plugin1");
+  upstream_tls_context.mutable_common_tls_context()
+      ->mutable_validation_context()
+      ->mutable_crl();
+  transport_socket->mutable_typed_config()->PackFrom(upstream_tls_context);
+  balancers_[0]->ads_service()->SetCdsResource(cluster);
+  ASSERT_TRUE(WaitForCdsNack()) << "timed out waiting for NACK";
+  const auto response_state =
+      balancers_[0]->ads_service()->cds_response_state();
+  EXPECT_EQ(response_state.state, AdsServiceImpl::ResponseState::NACKED);
+  EXPECT_THAT(
+      response_state.error_message,
+      ::testing::HasSubstr("CertificateValidationContext: crl unsupported"));
+}
+
+TEST_P(XdsSecurityTest,
+       NacksCertificateValidationContextWithCustomValidatorConfig) {
+  FakeCertificateProvider::CertDataMap fake1_cert_map = {
+      {"", {root_cert_, identity_pair_}}};
+  g_fake1_cert_data_map = &fake1_cert_map;
+  auto cluster = default_cluster_;
+  auto* transport_socket = cluster.mutable_transport_socket();
+  transport_socket->set_name("envoy.transport_sockets.tls");
+  UpstreamTlsContext upstream_tls_context;
+  upstream_tls_context.mutable_common_tls_context()
+      ->mutable_validation_context()
+      ->mutable_ca_certificate_provider_instance()
+      ->set_instance_name("fake_plugin1");
+  upstream_tls_context.mutable_common_tls_context()
+      ->mutable_validation_context()
+      ->mutable_custom_validator_config();
+  transport_socket->mutable_typed_config()->PackFrom(upstream_tls_context);
+  balancers_[0]->ads_service()->SetCdsResource(cluster);
+  ASSERT_TRUE(WaitForCdsNack()) << "timed out waiting for NACK";
+  const auto response_state =
+      balancers_[0]->ads_service()->cds_response_state();
+  EXPECT_EQ(response_state.state, AdsServiceImpl::ResponseState::NACKED);
+  EXPECT_THAT(
+      response_state.error_message,
+      ::testing::HasSubstr(
+          "CertificateValidationContext: custom_validator_config unsupported"));
+}
+
+TEST_P(XdsSecurityTest, NacksValidationContextSdsSecretConfig) {
+  FakeCertificateProvider::CertDataMap fake1_cert_map = {
+      {"", {root_cert_, identity_pair_}}};
+  g_fake1_cert_data_map = &fake1_cert_map;
+  auto cluster = default_cluster_;
+  auto* transport_socket = cluster.mutable_transport_socket();
+  transport_socket->set_name("envoy.transport_sockets.tls");
+  UpstreamTlsContext upstream_tls_context;
+  upstream_tls_context.mutable_common_tls_context()
+      ->mutable_validation_context_sds_secret_config();
+  transport_socket->mutable_typed_config()->PackFrom(upstream_tls_context);
+  balancers_[0]->ads_service()->SetCdsResource(cluster);
+  ASSERT_TRUE(WaitForCdsNack()) << "timed out waiting for NACK";
+  const auto response_state =
+      balancers_[0]->ads_service()->cds_response_state();
+  EXPECT_EQ(response_state.state, AdsServiceImpl::ResponseState::NACKED);
+  EXPECT_THAT(
+      response_state.error_message,
+      ::testing::HasSubstr("validation_context_sds_secret_config unsupported"));
+}
+
+TEST_P(XdsSecurityTest, NacksTlsParams) {
+  FakeCertificateProvider::CertDataMap fake1_cert_map = {
+      {"", {root_cert_, identity_pair_}}};
+  g_fake1_cert_data_map = &fake1_cert_map;
+  auto cluster = default_cluster_;
+  auto* transport_socket = cluster.mutable_transport_socket();
+  transport_socket->set_name("envoy.transport_sockets.tls");
+  UpstreamTlsContext upstream_tls_context;
+  upstream_tls_context.mutable_common_tls_context()
+      ->mutable_validation_context()
+      ->mutable_ca_certificate_provider_instance()
+      ->set_instance_name("fake_plugin1");
+  upstream_tls_context.mutable_common_tls_context()->mutable_tls_params();
+  transport_socket->mutable_typed_config()->PackFrom(upstream_tls_context);
+  balancers_[0]->ads_service()->SetCdsResource(cluster);
+  ASSERT_TRUE(WaitForCdsNack()) << "timed out waiting for NACK";
+  const auto response_state =
+      balancers_[0]->ads_service()->cds_response_state();
+  EXPECT_EQ(response_state.state, AdsServiceImpl::ResponseState::NACKED);
+  EXPECT_THAT(response_state.error_message,
+              ::testing::HasSubstr("tls_params unsupported"));
+}
+
+TEST_P(XdsSecurityTest, NacksCustomHandshaker) {
+  FakeCertificateProvider::CertDataMap fake1_cert_map = {
+      {"", {root_cert_, identity_pair_}}};
+  g_fake1_cert_data_map = &fake1_cert_map;
+  auto cluster = default_cluster_;
+  auto* transport_socket = cluster.mutable_transport_socket();
+  transport_socket->set_name("envoy.transport_sockets.tls");
+  UpstreamTlsContext upstream_tls_context;
+  upstream_tls_context.mutable_common_tls_context()
+      ->mutable_validation_context()
+      ->mutable_ca_certificate_provider_instance()
+      ->set_instance_name("fake_plugin1");
+  upstream_tls_context.mutable_common_tls_context()
+      ->mutable_custom_handshaker();
+  transport_socket->mutable_typed_config()->PackFrom(upstream_tls_context);
+  balancers_[0]->ads_service()->SetCdsResource(cluster);
+  ASSERT_TRUE(WaitForCdsNack()) << "timed out waiting for NACK";
+  const auto response_state =
+      balancers_[0]->ads_service()->cds_response_state();
+  EXPECT_EQ(response_state.state, AdsServiceImpl::ResponseState::NACKED);
+  EXPECT_THAT(response_state.error_message,
+              ::testing::HasSubstr("custom_handshaker unsupported"));
+}
+
+TEST_P(XdsSecurityTest, NacksTlsCertificates) {
+  FakeCertificateProvider::CertDataMap fake1_cert_map = {
+      {"", {root_cert_, identity_pair_}}};
+  g_fake1_cert_data_map = &fake1_cert_map;
+  auto cluster = default_cluster_;
+  auto* transport_socket = cluster.mutable_transport_socket();
+  transport_socket->set_name("envoy.transport_sockets.tls");
+  UpstreamTlsContext upstream_tls_context;
+  upstream_tls_context.mutable_common_tls_context()
+      ->mutable_validation_context()
+      ->mutable_ca_certificate_provider_instance()
+      ->set_instance_name("fake_plugin1");
+  upstream_tls_context.mutable_common_tls_context()->add_tls_certificates();
+  transport_socket->mutable_typed_config()->PackFrom(upstream_tls_context);
+  balancers_[0]->ads_service()->SetCdsResource(cluster);
+  ASSERT_TRUE(WaitForCdsNack()) << "timed out waiting for NACK";
+  const auto response_state =
+      balancers_[0]->ads_service()->cds_response_state();
+  EXPECT_EQ(response_state.state, AdsServiceImpl::ResponseState::NACKED);
+  EXPECT_THAT(response_state.error_message,
+              ::testing::HasSubstr("tls_certificates unsupported"));
+}
+
+TEST_P(XdsSecurityTest, NacksTlsCertificateSdsSecretConfigs) {
+  FakeCertificateProvider::CertDataMap fake1_cert_map = {
+      {"", {root_cert_, identity_pair_}}};
+  g_fake1_cert_data_map = &fake1_cert_map;
+  auto cluster = default_cluster_;
+  auto* transport_socket = cluster.mutable_transport_socket();
+  transport_socket->set_name("envoy.transport_sockets.tls");
+  UpstreamTlsContext upstream_tls_context;
+  upstream_tls_context.mutable_common_tls_context()
+      ->mutable_validation_context()
+      ->mutable_ca_certificate_provider_instance()
+      ->set_instance_name("fake_plugin1");
+  upstream_tls_context.mutable_common_tls_context()
+      ->add_tls_certificate_sds_secret_configs();
+  transport_socket->mutable_typed_config()->PackFrom(upstream_tls_context);
+  balancers_[0]->ads_service()->SetCdsResource(cluster);
+  ASSERT_TRUE(WaitForCdsNack()) << "timed out waiting for NACK";
+  const auto response_state =
+      balancers_[0]->ads_service()->cds_response_state();
+  EXPECT_EQ(response_state.state, AdsServiceImpl::ResponseState::NACKED);
+  EXPECT_THAT(
+      response_state.error_message,
+      ::testing::HasSubstr("tls_certificate_sds_secret_configs unsupported"));
+}
+
+TEST_P(XdsSecurityTest, TestTlsConfigurationInCombinedValidationContext) {
+  FakeCertificateProvider::CertDataMap fake1_cert_map = {
+      {"", {root_cert_, identity_pair_}}};
+  g_fake1_cert_data_map = &fake1_cert_map;
+  auto cluster = default_cluster_;
+  auto* transport_socket = cluster.mutable_transport_socket();
+  transport_socket->set_name("envoy.transport_sockets.tls");
+  UpstreamTlsContext upstream_tls_context;
+  upstream_tls_context.mutable_common_tls_context()
+      ->mutable_combined_validation_context()
+      ->mutable_default_validation_context()
+      ->mutable_ca_certificate_provider_instance()
+      ->set_instance_name("fake_plugin1");
+  transport_socket->mutable_typed_config()->PackFrom(upstream_tls_context);
+  balancers_[0]->ads_service()->SetCdsResource(cluster);
+  WaitForBackend(0, WaitForBackendOptions().set_allow_failures(true));
+  Status status = SendRpc();
+  EXPECT_TRUE(status.ok()) << "code=" << status.error_code()
+                           << " message=" << status.error_message();
+}
+
+// TODO(yashykt): Remove this test once we stop supporting old fields
+TEST_P(XdsSecurityTest,
+       TestTlsConfigurationInValidationContextCertificateProviderInstance) {
+  FakeCertificateProvider::CertDataMap fake1_cert_map = {
+      {"", {root_cert_, identity_pair_}}};
+  g_fake1_cert_data_map = &fake1_cert_map;
+  auto cluster = default_cluster_;
+  auto* transport_socket = cluster.mutable_transport_socket();
+  transport_socket->set_name("envoy.transport_sockets.tls");
+  UpstreamTlsContext upstream_tls_context;
+  upstream_tls_context.mutable_common_tls_context()
+      ->mutable_combined_validation_context()
+      ->mutable_validation_context_certificate_provider_instance()
+      ->set_instance_name("fake_plugin1");
+  transport_socket->mutable_typed_config()->PackFrom(upstream_tls_context);
+  balancers_[0]->ads_service()->SetCdsResource(cluster);
+  WaitForBackend(0, WaitForBackendOptions().set_allow_failures(true));
+  Status status = SendRpc();
+  EXPECT_TRUE(status.ok()) << "code=" << status.error_code()
+                           << " message=" << status.error_message();
+}
+
 TEST_P(XdsSecurityTest, TestMtlsConfigurationWithNoSanMatchers) {
   FakeCertificateProvider::CertDataMap fake1_cert_map = {
       {"", {root_cert_, identity_pair_}}};
@@ -8731,7 +9169,6 @@ TEST_P(XdsEnabledServerTest, BadLdsUpdateBothApiListenerAndAddress) {
   listener.set_name(
       absl::StrCat("grpc/server?xds.resource.listening_address=",
                    ipv6_only_ ? "[::1]:" : "127.0.0.1:", backends_[0]->port()));
-  balancers_[0]->ads_service()->SetLdsResource(listener);
   listener.mutable_address()->mutable_socket_address()->set_address(
       ipv6_only_ ? "::1" : "127.0.0.1");
   listener.mutable_address()->mutable_socket_address()->set_port_value(
@@ -8755,7 +9192,6 @@ TEST_P(XdsEnabledServerTest, UnsupportedL4Filter) {
   listener.set_name(
       absl::StrCat("grpc/server?xds.resource.listening_address=",
                    ipv6_only_ ? "[::1]:" : "127.0.0.1:", backends_[0]->port()));
-  balancers_[0]->ads_service()->SetLdsResource(listener);
   listener.mutable_address()->mutable_socket_address()->set_address(
       ipv6_only_ ? "::1" : "127.0.0.1");
   listener.mutable_address()->mutable_socket_address()->set_port_value(
@@ -8787,10 +9223,6 @@ TEST_P(XdsEnabledServerTest, UnsupportedHttpFilter) {
   listener.add_filter_chains()->add_filters()->mutable_typed_config()->PackFrom(
       http_connection_manager);
   balancers_[0]->ads_service()->SetLdsResource(listener);
-  listener.set_name(
-      absl::StrCat("grpc/server?xds.resource.listening_address=[::1]:",
-                   backends_[0]->port()));
-  balancers_[0]->ads_service()->SetLdsResource(listener);
   ASSERT_TRUE(WaitForLdsNack()) << "timed out waiting for NACK";
   const auto response_state =
       balancers_[0]->ads_service()->lds_response_state();
@@ -8821,10 +9253,6 @@ TEST_P(XdsEnabledServerTest, HttpFilterNotSupportedOnServer) {
   listener.add_filter_chains()->add_filters()->mutable_typed_config()->PackFrom(
       http_connection_manager);
   balancers_[0]->ads_service()->SetLdsResource(listener);
-  listener.set_name(
-      absl::StrCat("grpc/server?xds.resource.listening_address=[::1]:",
-                   backends_[0]->port()));
-  balancers_[0]->ads_service()->SetLdsResource(listener);
   ASSERT_TRUE(WaitForLdsNack()) << "timed out waiting for NACK";
   const auto response_state =
       balancers_[0]->ads_service()->lds_response_state();
@@ -8854,10 +9282,6 @@ TEST_P(XdsEnabledServerTest,
   listener.add_filter_chains()->add_filters()->mutable_typed_config()->PackFrom(
       http_connection_manager);
   balancers_[0]->ads_service()->SetLdsResource(listener);
-  listener.set_name(
-      absl::StrCat("grpc/server?xds.resource.listening_address=[::1]:",
-                   backends_[0]->port()));
-  balancers_[0]->ads_service()->SetLdsResource(listener);
   WaitForBackend(0);
   const auto response_state =
       balancers_[0]->ads_service()->lds_response_state();
@@ -8871,18 +9295,14 @@ TEST_P(XdsEnabledServerTest, ListenerAddressMismatch) {
   listener.set_name(
       absl::StrCat("grpc/server?xds.resource.listening_address=",
                    ipv6_only_ ? "[::1]:" : "127.0.0.1:", backends_[0]->port()));
+  // Set a different listening address in the LDS update
   listener.mutable_address()->mutable_socket_address()->set_address(
-      ipv6_only_ ? "::1" : "127.0.0.1");
+      "192.168.1.1");
   listener.mutable_address()->mutable_socket_address()->set_port_value(
       backends_[0]->port());
   listener.add_filter_chains()->add_filters()->mutable_typed_config()->PackFrom(
       HttpConnectionManager());
   balancers_[0]->ads_service()->SetLdsResource(listener);
-  WaitForBackend(0);
-  // Set a different listening address in the LDS update
-  listener.mutable_address()->mutable_socket_address()->set_address(
-      "192.168.1.1");
-  balancers_[0]->ads_service()->SetLdsResource(listener);
   backends_[0]->notifier()->WaitOnServingStatusChange(
       absl::StrCat(ipv6_only_ ? "[::1]:" : "127.0.0.1:", backends_[0]->port()),
       grpc::StatusCode::FAILED_PRECONDITION);
@@ -8893,7 +9313,6 @@ TEST_P(XdsEnabledServerTest, UseOriginalDstNotSupported) {
   listener.set_name(
       absl::StrCat("grpc/server?xds.resource.listening_address=",
                    ipv6_only_ ? "[::1]:" : "127.0.0.1:", backends_[0]->port()));
-  balancers_[0]->ads_service()->SetLdsResource(listener);
   listener.mutable_address()->mutable_socket_address()->set_address(
       ipv6_only_ ? "::1" : "127.0.0.1");
   listener.mutable_address()->mutable_socket_address()->set_port_value(
@@ -8916,16 +9335,6 @@ class XdsServerSecurityTest : public XdsEnd2endTest {
   XdsServerSecurityTest()
       : XdsEnd2endTest(1, 1, 100, true /* use_xds_enabled_server */) {}
 
-  static void SetUpTestCase() {
-    gpr_setenv("GRPC_XDS_EXPERIMENTAL_SECURITY_SUPPORT", "true");
-    XdsEnd2endTest::SetUpTestCase();
-  }
-
-  static void TearDownTestCase() {
-    XdsEnd2endTest::TearDownTestCase();
-    gpr_unsetenv("GRPC_XDS_EXPERIMENTAL_SECURITY_SUPPORT");
-  }
-
   void SetUp() override {
     XdsEnd2endTest::SetUp();
     root_cert_ = ReadFile(kCaCertPath);
@@ -8978,19 +9387,19 @@ class XdsServerSecurityTest : public XdsEnd2endTest {
       transport_socket->set_name("envoy.transport_sockets.tls");
       DownstreamTlsContext downstream_tls_context;
       downstream_tls_context.mutable_common_tls_context()
-          ->mutable_tls_certificate_certificate_provider_instance()
+          ->mutable_tls_certificate_provider_instance()
           ->set_instance_name(std::string(identity_instance_name));
       downstream_tls_context.mutable_common_tls_context()
-          ->mutable_tls_certificate_certificate_provider_instance()
+          ->mutable_tls_certificate_provider_instance()
           ->set_certificate_name(std::string(identity_certificate_name));
       if (!root_instance_name.empty()) {
         downstream_tls_context.mutable_common_tls_context()
-            ->mutable_combined_validation_context()
-            ->mutable_validation_context_certificate_provider_instance()
+            ->mutable_validation_context()
+            ->mutable_ca_certificate_provider_instance()
             ->set_instance_name(std::string(root_instance_name));
         downstream_tls_context.mutable_common_tls_context()
-            ->mutable_combined_validation_context()
-            ->mutable_validation_context_certificate_provider_instance()
+            ->mutable_validation_context()
+            ->mutable_ca_certificate_provider_instance()
             ->set_certificate_name(std::string(root_certificate_name));
         downstream_tls_context.mutable_require_client_certificate()->set_value(
             require_client_certificates);
@@ -9169,6 +9578,67 @@ TEST_P(XdsServerSecurityTest, UnknownTransportSocket) {
                   "Unrecognized transport socket: unknown_transport_socket"));
 }
 
+TEST_P(XdsServerSecurityTest, NacksRequireSNI) {
+  Listener listener;
+  listener.set_name(
+      absl::StrCat("grpc/server?xds.resource.listening_address=",
+                   ipv6_only_ ? "[::1]:" : "127.0.0.1:", backends_[0]->port()));
+  auto* socket_address = listener.mutable_address()->mutable_socket_address();
+  socket_address->set_address(ipv6_only_ ? "::1" : "127.0.0.1");
+  socket_address->set_port_value(backends_[0]->port());
+  auto* filter_chain = listener.add_filter_chains();
+  filter_chain->add_filters()->mutable_typed_config()->PackFrom(
+      HttpConnectionManager());
+  auto* transport_socket = filter_chain->mutable_transport_socket();
+  transport_socket->set_name("envoy.transport_sockets.tls");
+  DownstreamTlsContext downstream_tls_context;
+  downstream_tls_context.mutable_common_tls_context()
+      ->mutable_tls_certificate_provider_instance()
+      ->set_instance_name("fake_plugin1");
+  downstream_tls_context.mutable_require_sni()->set_value(true);
+  transport_socket->mutable_typed_config()->PackFrom(downstream_tls_context);
+  balancers_[0]->ads_service()->SetLdsResource(listener);
+  ASSERT_TRUE(WaitForLdsNack(StatusCode::DEADLINE_EXCEEDED))
+      << "timed out waiting for NACK";
+  const auto response_state =
+      balancers_[0]->ads_service()->lds_response_state();
+  EXPECT_EQ(response_state.state, AdsServiceImpl::ResponseState::NACKED);
+  EXPECT_THAT(response_state.error_message,
+              ::testing::HasSubstr("require_sni: unsupported"));
+}
+
+TEST_P(XdsServerSecurityTest, NacksOcspStaplePolicyOtherThanLenientStapling) {
+  Listener listener;
+  listener.set_name(
+      absl::StrCat("grpc/server?xds.resource.listening_address=",
+                   ipv6_only_ ? "[::1]:" : "127.0.0.1:", backends_[0]->port()));
+  auto* socket_address = listener.mutable_address()->mutable_socket_address();
+  socket_address->set_address(ipv6_only_ ? "::1" : "127.0.0.1");
+  socket_address->set_port_value(backends_[0]->port());
+  auto* filter_chain = listener.add_filter_chains();
+  filter_chain->add_filters()->mutable_typed_config()->PackFrom(
+      HttpConnectionManager());
+  auto* transport_socket = filter_chain->mutable_transport_socket();
+  transport_socket->set_name("envoy.transport_sockets.tls");
+  DownstreamTlsContext downstream_tls_context;
+  downstream_tls_context.mutable_common_tls_context()
+      ->mutable_tls_certificate_provider_instance()
+      ->set_instance_name("fake_plugin1");
+  downstream_tls_context.set_ocsp_staple_policy(
+      envoy::extensions::transport_sockets::tls::v3::
+          DownstreamTlsContext_OcspStaplePolicy_STRICT_STAPLING);
+  transport_socket->mutable_typed_config()->PackFrom(downstream_tls_context);
+  balancers_[0]->ads_service()->SetLdsResource(listener);
+  ASSERT_TRUE(WaitForLdsNack(StatusCode::DEADLINE_EXCEEDED))
+      << "timed out waiting for NACK";
+  const auto response_state =
+      balancers_[0]->ads_service()->lds_response_state();
+  EXPECT_EQ(response_state.state, AdsServiceImpl::ResponseState::NACKED);
+  EXPECT_THAT(response_state.error_message,
+              ::testing::HasSubstr(
+                  "ocsp_staple_policy: Only LENIENT_STAPLING supported"));
+}
+
 TEST_P(
     XdsServerSecurityTest,
     NacksRequiringClientCertificateWithoutValidationCertificateProviderInstance) {
@@ -9186,7 +9656,7 @@ TEST_P(
   transport_socket->set_name("envoy.transport_sockets.tls");
   DownstreamTlsContext downstream_tls_context;
   downstream_tls_context.mutable_common_tls_context()
-      ->mutable_tls_certificate_certificate_provider_instance()
+      ->mutable_tls_certificate_provider_instance()
       ->set_instance_name("fake_plugin1");
   downstream_tls_context.mutable_require_client_certificate()->set_value(true);
   transport_socket->mutable_typed_config()->PackFrom(downstream_tls_context);
@@ -9225,9 +9695,41 @@ TEST_P(XdsServerSecurityTest,
       balancers_[0]->ads_service()->lds_response_state();
   EXPECT_EQ(response_state.state, AdsServiceImpl::ResponseState::NACKED);
   EXPECT_THAT(response_state.error_message,
-              ::testing::HasSubstr(
-                  "TLS configuration provided but no "
-                  "tls_certificate_certificate_provider_instance found."));
+              ::testing::HasSubstr("TLS configuration provided but no "
+                                   "tls_certificate_provider_instance found."));
+}
+
+TEST_P(XdsServerSecurityTest, NacksMatchSubjectAltNames) {
+  Listener listener;
+  listener.set_name(
+      absl::StrCat("grpc/server?xds.resource.listening_address=",
+                   ipv6_only_ ? "[::1]:" : "127.0.0.1:", backends_[0]->port()));
+  auto* socket_address = listener.mutable_address()->mutable_socket_address();
+  socket_address->set_address(ipv6_only_ ? "::1" : "127.0.0.1");
+  socket_address->set_port_value(backends_[0]->port());
+  auto* filter_chain = listener.add_filter_chains();
+  filter_chain->add_filters()->mutable_typed_config()->PackFrom(
+      HttpConnectionManager());
+  auto* transport_socket = filter_chain->mutable_transport_socket();
+  transport_socket->set_name("envoy.transport_sockets.tls");
+  DownstreamTlsContext downstream_tls_context;
+  downstream_tls_context.mutable_common_tls_context()
+      ->mutable_tls_certificate_provider_instance()
+      ->set_instance_name("fake_plugin1");
+  downstream_tls_context.mutable_common_tls_context()
+      ->mutable_validation_context()
+      ->add_match_subject_alt_names()
+      ->set_exact("*.test.google.fr");
+  transport_socket->mutable_typed_config()->PackFrom(downstream_tls_context);
+  balancers_[0]->ads_service()->SetLdsResource(listener);
+  ASSERT_TRUE(WaitForLdsNack(StatusCode::DEADLINE_EXCEEDED))
+      << "timed out waiting for NACK";
+  const auto response_state =
+      balancers_[0]->ads_service()->lds_response_state();
+  EXPECT_EQ(response_state.state, AdsServiceImpl::ResponseState::NACKED);
+  EXPECT_THAT(
+      response_state.error_message,
+      ::testing::HasSubstr("match_subject_alt_names not supported on servers"));
 }
 
 TEST_P(XdsServerSecurityTest, UnknownIdentityCertificateProvider) {
@@ -9258,6 +9760,35 @@ TEST_P(XdsServerSecurityTest, UnknownRootCertificateProvider) {
                   "Unrecognized certificate provider instance name: unknown"));
 }
 
+TEST_P(XdsServerSecurityTest,
+       TestDeprecateTlsCertificateCertificateProviderInstanceField) {
+  FakeCertificateProvider::CertDataMap fake1_cert_map = {
+      {"", {root_cert_, identity_pair_}}};
+  g_fake1_cert_data_map = &fake1_cert_map;
+  Listener listener;
+  listener.set_name(absl::StrCat(
+      ipv6_only_ ? "grpc/server?xds.resource.listening_address=[::1]:"
+                 : "grpc/server?xds.resource.listening_address=127.0.0.1:",
+      backends_[0]->port()));
+  listener.mutable_address()->mutable_socket_address()->set_address(
+      ipv6_only_ ? "[::1]" : "127.0.0.1");
+  listener.mutable_address()->mutable_socket_address()->set_port_value(
+      backends_[0]->port());
+  auto* filter_chain = listener.add_filter_chains();
+  filter_chain->add_filters()->mutable_typed_config()->PackFrom(
+      HttpConnectionManager());
+  auto* transport_socket = filter_chain->mutable_transport_socket();
+  transport_socket->set_name("envoy.transport_sockets.tls");
+  DownstreamTlsContext downstream_tls_context;
+  downstream_tls_context.mutable_common_tls_context()
+      ->mutable_tls_certificate_certificate_provider_instance()
+      ->set_instance_name("fake_plugin1");
+  transport_socket->mutable_typed_config()->PackFrom(downstream_tls_context);
+  balancers_[0]->ads_service()->SetLdsResource(listener);
+  SendRpc([this]() { return CreateTlsChannel(); },
+          server_authenticated_identity_, {});
+}
+
 TEST_P(XdsServerSecurityTest, CertificatesNotAvailable) {
   FakeCertificateProvider::CertDataMap fake1_cert_map;
   g_fake1_cert_data_map = &fake1_cert_map;
@@ -9996,7 +10527,7 @@ TEST_P(XdsServerFilterChainMatchTest,
   transport_socket->set_name("envoy.transport_sockets.tls");
   DownstreamTlsContext downstream_tls_context;
   downstream_tls_context.mutable_common_tls_context()
-      ->mutable_tls_certificate_certificate_provider_instance()
+      ->mutable_tls_certificate_provider_instance()
       ->set_instance_name("fake_plugin1");
   transport_socket->mutable_typed_config()->PackFrom(downstream_tls_context);
   balancers_[0]->ads_service()->SetLdsResource(listener);
@@ -12680,7 +13211,6 @@ TEST_P(ClientStatusDiscoveryServiceTest, XdsConfigDumpEndpointError) {
   CheckRpcSendOk();
   for (int o = 0; o < kFetchConfigRetries; o++) {
     auto csds_response = FetchCsdsResponse();
-
     // Check if error state is propagated
     bool ok = ::testing::Value(
         csds_response.config(0).xds_config(),
index 74ab365..a39ae72 100644 (file)
 #include "absl/strings/string_view.h"
 #include "gmock/gmock.h"
 #include "gtest/gtest.h"
-#include "include/grpc++/grpc++.h"
-#include "include/grpcpp/opencensus.h"
 #include "opencensus/stats/stats.h"
 #include "opencensus/stats/tag_key.h"
 #include "opencensus/stats/testing/test_utils.h"
 #include "opencensus/tags/tag_map.h"
 #include "opencensus/tags/with_tag_map.h"
+
+#include <grpc++/grpc++.h>
+#include <grpcpp/opencensus.h>
+
 #include "src/cpp/ext/filters/census/context.h"
 #include "src/cpp/ext/filters/census/grpc_plugin.h"
 #include "src/proto/grpc/testing/echo.grpc.pb.h"
index 412bbed..6e2d19f 100644 (file)
  *
  */
 
+#include <gtest/gtest.h>
+
 #include "google/protobuf/duration.upb.h"
 #include "upb/upb.hpp"
 
 #include <grpc/grpc.h>
 #include <grpcpp/impl/codegen/config.h>
-#include <gtest/gtest.h>
 
 #include "src/core/ext/filters/client_channel/lb_policy/grpclb/load_balancer_api.h"
 #include "src/core/lib/address_utils/sockaddr_utils.h"
 #include "src/core/lib/event_engine/sockaddr.h"
 #include "src/core/lib/iomgr/sockaddr.h"
 #include "src/proto/grpc/lb/v1/load_balancer.pb.h"  // C++ version
-
 #include "test/core/util/test_config.h"
 
 namespace grpc {
index a2f7903..ce7b149 100644 (file)
  *
  */
 
+#include <memory>
+#include <unordered_map>
+
+#include "absl/flags/flag.h"
+
 #include <grpc/grpc.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpcpp/channel.h>
 #include <grpcpp/client_context.h>
 
-#include <memory>
-#include <unordered_map>
-
-#include "absl/flags/flag.h"
 #include "src/core/lib/gpr/string.h"
 #include "test/core/util/test_config.h"
 #include "test/cpp/interop/client_helper.h"
index 4d25411..17f2ad2 100644 (file)
 
 #include "test/cpp/interop/client_helper.h"
 
+#include <fstream>
+#include <memory>
+#include <sstream>
+
+#include "absl/flags/declare.h"
+#include "absl/flags/flag.h"
+
 #include <grpc/grpc.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpcpp/create_channel.h>
 #include <grpcpp/security/credentials.h>
 
-#include <fstream>
-#include <memory>
-#include <sstream>
-
-#include "absl/flags/declare.h"
-#include "absl/flags/flag.h"
 #include "src/cpp/client/secure_credentials.h"
 #include "test/core/security/oauth2_utils.h"
 #include "test/cpp/util/create_test_channel.h"
index 1cee4eb..dc4c08a 100644 (file)
  *
  */
 
+#include <grpc/support/port_platform.h>
+
 #include <arpa/inet.h>
 #include <fcntl.h>
-#include <grpc/support/alloc.h>
-#include <grpc/support/log.h>
-#include <grpc/support/port_platform.h>
-#include <grpcpp/channel.h>
-#include <grpcpp/client_context.h>
-#include <grpcpp/grpcpp.h>
-#include <grpcpp/support/channel_arguments.h>
 #include <inttypes.h>
 #include <netinet/in.h>
 #include <netinet/tcp.h>
 #include <thread>
 
 #include "absl/flags/flag.h"
+
+#include <grpc/support/alloc.h>
+#include <grpc/support/log.h>
+#include <grpcpp/channel.h>
+#include <grpcpp/client_context.h>
+#include <grpcpp/grpcpp.h>
+#include <grpcpp/support/channel_arguments.h>
+
 #include "src/core/lib/gpr/string.h"
 #include "src/core/lib/iomgr/port.h"
 #include "src/core/lib/iomgr/socket_mutator.h"
index 5422fc8..d890d6a 100644 (file)
 
 #include "test/cpp/interop/http2_client.h"
 
+#include <thread>
+
+#include "absl/flags/flag.h"
+
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpcpp/channel.h>
 #include <grpcpp/client_context.h>
 
-#include <thread>
-
-#include "absl/flags/flag.h"
 #include "src/core/lib/gpr/string.h"
 #include "src/core/lib/gpr/useful.h"
 #include "src/core/lib/transport/byte_stream.h"
index 42728fc..3578392 100644 (file)
@@ -23,6 +23,7 @@
 
 #include <grpc/grpc.h>
 #include <grpcpp/channel.h>
+
 #include "src/proto/grpc/testing/messages.pb.h"
 #include "src/proto/grpc/testing/test.grpc.pb.h"
 
index 49a1252..c29f6eb 100644 (file)
@@ -16,6 +16,8 @@
  *
  */
 
+#include "test/cpp/interop/interop_client.h"
+
 #include <cinttypes>
 #include <fstream>
 #include <memory>
@@ -40,7 +42,6 @@
 #include "src/proto/grpc/testing/test.grpc.pb.h"
 #include "test/core/util/histogram.h"
 #include "test/cpp/interop/client_helper.h"
-#include "test/cpp/interop/interop_client.h"
 
 namespace grpc {
 namespace testing {
@@ -1108,9 +1109,9 @@ InteropClient::PerformOneSoakTestIteration(
   if (!s.ok()) {
     return std::make_tuple(false, elapsed_ms, context.debug_error_string());
   } else if (elapsed_ms > max_acceptable_per_iteration_latency_ms) {
-    std::string debug_string =
-        absl::StrFormat("%d ms exceeds max acceptable latency: %d ms.",
-                        elapsed_ms, max_acceptable_per_iteration_latency_ms);
+    std::string debug_string = absl::StrFormat(
+        "%d ms exceeds max acceptable latency: %d ms, peer: %s", elapsed_ms,
+        max_acceptable_per_iteration_latency_ms, context.peer());
     return std::make_tuple(false, elapsed_ms, std::move(debug_string));
   } else {
     return std::make_tuple(true, elapsed_ms, "");
index de564ca..8975815 100644 (file)
@@ -23,6 +23,7 @@
 
 #include <grpc/grpc.h>
 #include <grpcpp/channel.h>
+
 #include "src/proto/grpc/testing/messages.pb.h"
 #include "src/proto/grpc/testing/test.grpc.pb.h"
 
index 51f66d4..1066146 100644 (file)
  *
  */
 
+#include <fstream>
+#include <memory>
+#include <sstream>
+#include <thread>
+
+#include "absl/flags/flag.h"
+
 #include <grpc/grpc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/time.h>
 #include <grpcpp/server_builder.h>
 #include <grpcpp/server_context.h>
 
-#include <fstream>
-#include <memory>
-#include <sstream>
-#include <thread>
-
-#include "absl/flags/flag.h"
 #include "src/core/lib/gpr/string.h"
 #include "src/proto/grpc/testing/empty.pb.h"
 #include "src/proto/grpc/testing/messages.pb.h"
index 8a92892..f0985e7 100644 (file)
@@ -17,8 +17,6 @@
  */
 
 #include <assert.h>
-#include <grpc/support/alloc.h>
-#include <grpc/support/log.h>
 #include <signal.h>
 #include <stdio.h>
 #include <stdlib.h>
 
 #include "absl/flags/flag.h"
 #include "absl/strings/str_cat.h"
+
+#include <grpc/support/alloc.h>
+#include <grpc/support/log.h>
+
 #include "src/core/lib/gpr/string.h"
 #include "src/core/lib/iomgr/socket_utils_posix.h"
 #include "test/core/util/port.h"
index 736182c..f733dfc 100644 (file)
  *is % allowed in string
  */
 
-#include <grpc/support/log.h>
-#include <grpcpp/grpcpp.h>
-
 #include <memory>
 #include <string>
 
 #include "absl/flags/flag.h"
+
+#include <grpc/support/log.h>
+#include <grpcpp/grpcpp.h>
+
 #include "src/proto/grpc/testing/metrics.grpc.pb.h"
 #include "src/proto/grpc/testing/metrics.pb.h"
 #include "test/cpp/util/metrics_server.h"
index f24b841..9554c17 100644 (file)
  *
  */
 
+#include <memory>
+#include <sstream>
+
+#include "absl/flags/flag.h"
+
 #include <grpc/grpc.h>
 #include <grpc/support/log.h>
 #include <grpcpp/channel.h>
 #include <grpcpp/client_context.h>
 #include <grpcpp/support/channel_arguments.h>
 
-#include <memory>
-#include <sstream>
-
-#include "absl/flags/flag.h"
 #include "src/proto/grpc/testing/empty.pb.h"
 #include "src/proto/grpc/testing/messages.pb.h"
 #include "src/proto/grpc/testing/test.grpc.pb.h"
index 8e7ef41..6496f8f 100644 (file)
 
 // Test description at doc/connection-backoff-interop-test-description.md
 
-#include <grpc/grpc.h>
-#include <grpc/support/log.h>
-#include <grpcpp/server.h>
-#include <grpcpp/server_builder.h>
-#include <grpcpp/server_context.h>
 #include <signal.h>
 
 #include <condition_variable>
 #include <sstream>
 
 #include "absl/flags/flag.h"
+
+#include <grpc/grpc.h>
+#include <grpc/support/log.h>
+#include <grpcpp/server.h>
+#include <grpcpp/server_builder.h>
+#include <grpcpp/server_context.h>
+
 #include "src/proto/grpc/testing/empty.pb.h"
 #include "src/proto/grpc/testing/messages.pb.h"
 #include "src/proto/grpc/testing/test.grpc.pb.h"
index 7da24a4..4c7e7b5 100644 (file)
 
 #include "test/cpp/interop/server_helper.h"
 
-#include <grpcpp/security/server_credentials.h>
-
 #include <memory>
 
 #include "absl/flags/declare.h"
 #include "absl/flags/flag.h"
+
+#include <grpcpp/security/server_credentials.h>
+
 #include "src/core/lib/surface/call_test_only.h"
 #include "src/core/lib/transport/byte_stream.h"
 #include "test/cpp/util/test_credentials_provider.h"
index ee72697..65f6cfe 100644 (file)
@@ -24,7 +24,6 @@
 
 #include <grpc/compression.h>
 #include <grpc/impl/codegen/atm.h>
-
 #include <grpcpp/security/server_credentials.h>
 #include <grpcpp/server.h>
 #include <grpcpp/server_builder.h>
index cc7651e..1faed82 100644 (file)
  *is % allowed in string
  */
 
-#include <grpc/support/log.h>
-#include <grpc/support/time.h>
-#include <grpcpp/create_channel.h>
-#include <grpcpp/grpcpp.h>
-
 #include <memory>
 #include <string>
 #include <thread>
 #include <vector>
 
 #include "absl/flags/flag.h"
+
+#include <grpc/support/log.h>
+#include <grpc/support/time.h>
+#include <grpcpp/create_channel.h>
+#include <grpcpp/grpcpp.h>
+
 #include "src/proto/grpc/testing/metrics.grpc.pb.h"
 #include "src/proto/grpc/testing/metrics.pb.h"
 #include "test/cpp/interop/interop_client.h"
index 6204538..c688a2e 100644 (file)
  *
  */
 
-#include <grpcpp/ext/admin_services.h>
-#include <grpcpp/ext/proto_server_reflection_plugin.h>
-#include <grpcpp/grpcpp.h>
-#include <grpcpp/server.h>
-#include <grpcpp/server_builder.h>
-#include <grpcpp/server_context.h>
-
 #include <atomic>
 #include <chrono>
 #include <condition_variable>
 #include "absl/algorithm/container.h"
 #include "absl/flags/flag.h"
 #include "absl/strings/str_split.h"
+
+#include <grpcpp/ext/admin_services.h>
+#include <grpcpp/ext/proto_server_reflection_plugin.h>
+#include <grpcpp/grpcpp.h>
+#include <grpcpp/server.h>
+#include <grpcpp/server_builder.h>
+#include <grpcpp/server_context.h>
+
 #include "src/core/lib/channel/status_util.h"
 #include "src/core/lib/gpr/env.h"
 #include "src/proto/grpc/testing/empty.pb.h"
@@ -506,7 +507,7 @@ void RunTestLoop(std::chrono::duration<double> duration_per_query,
       }
     }
   }
-  thread.join();
+  GPR_UNREACHABLE_CODE(thread.join());
 }
 
 void RunServer(const int port, StatsWatchers* stats_watchers,
index ea7c6f2..7b6f5a6 100644 (file)
  *
  */
 
+#include <sstream>
+
+#include "absl/flags/flag.h"
+#include "absl/strings/str_cat.h"
+#include "absl/synchronization/mutex.h"
+
 #include <grpc/grpc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/time.h>
 #include <grpcpp/server_context.h>
 #include <grpcpp/xds_server_builder.h>
 
-#include <sstream>
-
-#include "absl/flags/flag.h"
-#include "absl/strings/str_cat.h"
-#include "absl/synchronization/mutex.h"
 #include "src/core/lib/gpr/string.h"
 #include "src/core/lib/iomgr/gethostname.h"
 #include "src/core/lib/transport/byte_stream.h"
@@ -55,7 +56,7 @@ using grpc::Server;
 using grpc::ServerBuilder;
 using grpc::ServerContext;
 using grpc::Status;
-using grpc::experimental::XdsServerBuilder;
+using grpc::XdsServerBuilder;
 using grpc::testing::Empty;
 using grpc::testing::HealthCheckServiceImpl;
 using grpc::testing::SimpleRequest;
@@ -128,11 +129,11 @@ void RunServer(bool secure_mode, const int port, const int maintenance_port,
   grpc::reflection::InitProtoReflectionServerBuilderPlugin();
   ServerBuilder builder;
   if (secure_mode) {
-    XdsServerBuilder xds_builder;
+    grpc::XdsServerBuilder xds_builder;
     xds_builder.RegisterService(&service);
-    xds_builder.AddListeningPort(absl::StrCat("0.0.0.0:", port),
-                                 grpc::experimental::XdsServerCredentials(
-                                     grpc::InsecureServerCredentials()));
+    xds_builder.AddListeningPort(
+        absl::StrCat("0.0.0.0:", port),
+        grpc::XdsServerCredentials(grpc::InsecureServerCredentials()));
     xds_enabled_server = xds_builder.BuildAndStart();
     gpr_log(GPR_INFO, "Server starting on 0.0.0.0:%d", port);
     builder.RegisterService(&health_check_service);
index f24dcd6..6c14809 100644 (file)
@@ -20,6 +20,7 @@
 #define TESTHELPER_H
 
 #import <XCTest/XCTest.h>
+
 #import <map>
 #import <sstream>
 
@@ -27,7 +28,8 @@
 #import <grpcpp/impl/codegen/config.h>
 #import <grpcpp/impl/codegen/string_ref.h>
 #import <grpcpp/support/client_interceptor.h>
-#import <src/proto/grpc/testing/echo.grpc.pb.h>
+
+#import "src/proto/grpc/testing/echo.grpc.pb.h"
 
 const char* const kServerFinishAfterNReads = "server_finish_after_n_reads";
 const char* const kServerResponseStreamsToSend = "server_responses_to_send";
index 3aaab53..83899d1 100644 (file)
 /* This benchmark exists to ensure that immediately-firing alarms are fast */
 
 #include <benchmark/benchmark.h>
+
 #include <grpc/grpc.h>
 #include <grpcpp/alarm.h>
 #include <grpcpp/completion_queue.h>
 #include <grpcpp/impl/grpc_library.h>
+
 #include "test/core/util/test_config.h"
 #include "test/cpp/microbenchmarks/helpers.h"
 #include "test/cpp/util/test_config.h"
index 90de554..aba5ceb 100644 (file)
@@ -19,6 +19,7 @@
 /* Benchmark arenas */
 
 #include <benchmark/benchmark.h>
+
 #include "src/core/lib/gprpp/arena.h"
 #include "test/core/util/test_config.h"
 #include "test/cpp/microbenchmarks/helpers.h"
index 3c416d8..78d87c6 100644 (file)
@@ -21,6 +21,7 @@
 #include <memory>
 
 #include <benchmark/benchmark.h>
+
 #include <grpcpp/impl/grpc_library.h>
 #include <grpcpp/support/byte_buffer.h>
 
index 81351f7..c08643c 100644 (file)
 /* This benchmark exists to ensure that the benchmark integration is
  * working */
 
-#include <benchmark/benchmark.h>
 #include <string.h>
+
 #include <sstream>
 
+#include <benchmark/benchmark.h>
+
 #include <grpc/grpc.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/string_util.h>
@@ -43,6 +45,7 @@
 #include "src/core/lib/transport/transport_impl.h"
 #include "src/cpp/client/create_channel_internal.h"
 #include "src/proto/grpc/testing/echo.grpc.pb.h"
+#include "test/core/util/resource_user_util.h"
 #include "test/core/util/test_config.h"
 #include "test/cpp/microbenchmarks/helpers.h"
 #include "test/cpp/util/test_config.h"
@@ -701,7 +704,9 @@ class IsolatedCallFixture : public TrackCounters {
         nullptr));
     {
       grpc_core::ExecCtx exec_ctx;
-      channel_ = grpc_channel_create_with_builder(builder, GRPC_CLIENT_CHANNEL);
+      channel_ = grpc_channel_create_with_builder(
+          builder, GRPC_CLIENT_CHANNEL, grpc_resource_user_create_unlimited(),
+          0);
     }
     cq_ = grpc_completion_queue_create_for_next(nullptr);
   }
index 0e2bfc1..b3e9b77 100644 (file)
@@ -19,7 +19,9 @@
 /* Benchmark channel */
 
 #include <benchmark/benchmark.h>
+
 #include <grpc/grpc.h>
+
 #include "test/core/util/test_config.h"
 #include "test/cpp/microbenchmarks/helpers.h"
 #include "test/cpp/util/test_config.h"
index 5a29df6..1615aa5 100644 (file)
 
 /* Microbenchmarks around CHTTP2 HPACK operations */
 
-#include <benchmark/benchmark.h>
-#include <grpc/support/alloc.h>
-#include <grpc/support/log.h>
 #include <string.h>
+
 #include <memory>
 #include <sstream>
 
+#include <benchmark/benchmark.h>
+
+#include <grpc/support/alloc.h>
+#include <grpc/support/log.h>
+
 #include "src/core/ext/transport/chttp2/transport/hpack_encoder.h"
 #include "src/core/ext/transport/chttp2/transport/hpack_parser.h"
 #include "src/core/ext/transport/chttp2/transport/incoming_metadata.h"
@@ -32,7 +35,6 @@
 #include "src/core/lib/slice/slice_string_helpers.h"
 #include "src/core/lib/transport/static_metadata.h"
 #include "src/core/lib/transport/timeout_encoding.h"
-
 #include "test/core/util/test_config.h"
 #include "test/cpp/microbenchmarks/helpers.h"
 #include "test/cpp/util/test_config.h"
@@ -53,11 +55,8 @@ static grpc_slice MakeSlice(std::vector<uint8_t> bytes) {
 static void BM_HpackEncoderInitDestroy(benchmark::State& state) {
   TrackCounters track_counters;
   grpc_core::ExecCtx exec_ctx;
-  std::unique_ptr<grpc_chttp2_hpack_compressor> c(
-      new grpc_chttp2_hpack_compressor);
   for (auto _ : state) {
-    grpc_chttp2_hpack_compressor_init(c.get());
-    grpc_chttp2_hpack_compressor_destroy(c.get());
+    grpc_core::HPackCompressor c;
     grpc_core::ExecCtx::Get()->Flush();
   }
 
@@ -74,27 +73,25 @@ static void BM_HpackEncoderEncodeDeadline(benchmark::State& state) {
   grpc_metadata_batch_init(&b);
   b.deadline = saved_now + 30 * 1000;
 
-  std::unique_ptr<grpc_chttp2_hpack_compressor> c(
-      new grpc_chttp2_hpack_compressor);
-  grpc_chttp2_hpack_compressor_init(c.get());
+  grpc_core::HPackCompressor c;
   grpc_transport_one_way_stats stats;
   stats = {};
   grpc_slice_buffer outbuf;
   grpc_slice_buffer_init(&outbuf);
   while (state.KeepRunning()) {
-    grpc_encode_header_options hopt = {
-        static_cast<uint32_t>(state.iterations()),
-        true,
-        false,
-        static_cast<size_t>(1024),
-        &stats,
-    };
-    grpc_chttp2_encode_header(c.get(), nullptr, 0, &b, &hopt, &outbuf);
+    c.EncodeHeaders(
+        grpc_core::HPackCompressor::EncodeHeaderOptions{
+            static_cast<uint32_t>(state.iterations()),
+            true,
+            false,
+            static_cast<size_t>(1024),
+            &stats,
+        },
+        b, &outbuf);
     grpc_slice_buffer_reset_and_unref_internal(&outbuf);
     grpc_core::ExecCtx::Get()->Flush();
   }
   grpc_metadata_batch_destroy(&b);
-  grpc_chttp2_hpack_compressor_destroy(c.get());
   grpc_slice_buffer_destroy_internal(&outbuf);
 
   std::ostringstream label;
@@ -124,23 +121,22 @@ static void BM_HpackEncoderEncodeHeader(benchmark::State& state) {
         "addmd", grpc_metadata_batch_add_tail(&b, &storage[i], elems[i])));
   }
 
-  std::unique_ptr<grpc_chttp2_hpack_compressor> c(
-      new grpc_chttp2_hpack_compressor);
-  grpc_chttp2_hpack_compressor_init(c.get());
+  grpc_core::HPackCompressor c;
   grpc_transport_one_way_stats stats;
   stats = {};
   grpc_slice_buffer outbuf;
   grpc_slice_buffer_init(&outbuf);
   while (state.KeepRunning()) {
     static constexpr int kEnsureMaxFrameAtLeast = 2;
-    grpc_encode_header_options hopt = {
-        static_cast<uint32_t>(state.iterations()),
-        state.range(0) != 0,
-        Fixture::kEnableTrueBinary,
-        static_cast<size_t>(state.range(1) + kEnsureMaxFrameAtLeast),
-        &stats,
-    };
-    grpc_chttp2_encode_header(c.get(), nullptr, 0, &b, &hopt, &outbuf);
+    c.EncodeHeaders(
+        grpc_core::HPackCompressor::EncodeHeaderOptions{
+            static_cast<uint32_t>(state.iterations()),
+            state.range(0) != 0,
+            Fixture::kEnableTrueBinary,
+            static_cast<size_t>(state.range(1) + kEnsureMaxFrameAtLeast),
+            &stats,
+        },
+        b, &outbuf);
     if (!logged_representative_output && state.iterations() > 3) {
       logged_representative_output = true;
       for (size_t i = 0; i < outbuf.count; i++) {
@@ -153,7 +149,6 @@ static void BM_HpackEncoderEncodeHeader(benchmark::State& state) {
     grpc_core::ExecCtx::Get()->Flush();
   }
   grpc_metadata_batch_destroy(&b);
-  grpc_chttp2_hpack_compressor_destroy(c.get());
   grpc_slice_buffer_destroy_internal(&outbuf);
 
   std::ostringstream label;
@@ -461,11 +456,11 @@ static void BM_HpackParserParseHeader(benchmark::State& state) {
                grpc_core::HPackParser::Boundary::None,
                grpc_core::HPackParser::Priority::None);
   for (auto slice : init_slices) {
-    GPR_ASSERT(GRPC_ERROR_NONE == p.Parse(slice));
+    GPR_ASSERT(GRPC_ERROR_NONE == p.Parse(slice, false));
   }
   while (state.KeepRunning()) {
     for (auto slice : benchmark_slices) {
-      GPR_ASSERT(GRPC_ERROR_NONE == p.Parse(slice));
+      GPR_ASSERT(GRPC_ERROR_NONE == p.Parse(slice, false));
     }
     grpc_core::ExecCtx::Get()->Flush();
     // Recreate arena every 4k iterations to avoid oom
index eeefe3e..2b992c1 100644 (file)
 
 /* Microbenchmarks around CHTTP2 transport operations */
 
+#include <string.h>
+
+#include <memory>
+#include <queue>
+#include <sstream>
+
 #include <benchmark/benchmark.h>
+
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/string_util.h>
 #include <grpcpp/support/channel_arguments.h>
-#include <string.h>
-#include <memory>
-#include <queue>
-#include <sstream>
+
 #include "src/core/ext/transport/chttp2/transport/chttp2_transport.h"
 #include "src/core/ext/transport/chttp2/transport/internal.h"
 #include "src/core/lib/iomgr/closure.h"
 #include "src/core/lib/iomgr/resource_quota.h"
 #include "src/core/lib/slice/slice_internal.h"
 #include "src/core/lib/transport/static_metadata.h"
+#include "test/core/util/resource_user_util.h"
 #include "test/core/util/test_config.h"
 #include "test/cpp/microbenchmarks/helpers.h"
 #include "test/cpp/util/test_config.h"
@@ -51,14 +56,11 @@ class PhonyEndpoint : public grpc_endpoint {
                                                    delete_from_pollset_set,
                                                    shutdown,
                                                    destroy,
-                                                   get_resource_user,
                                                    get_peer,
                                                    get_local_address,
                                                    get_fd,
                                                    can_track_err};
     grpc_endpoint::vtable = &my_vtable;
-    ru_ = grpc_resource_user_create(LibraryInitializer::get().rq(),
-                                    "phony_endpoint");
   }
 
   void PushInput(grpc_slice slice) {
@@ -74,7 +76,6 @@ class PhonyEndpoint : public grpc_endpoint {
   }
 
  private:
-  grpc_resource_user* ru_;
   grpc_closure* read_cb_ = nullptr;
   grpc_slice_buffer* slices_ = nullptr;
   bool have_slice_ = false;
@@ -112,19 +113,14 @@ class PhonyEndpoint : public grpc_endpoint {
                                       grpc_pollset_set* /*pollset*/) {}
 
   static void shutdown(grpc_endpoint* ep, grpc_error_handle why) {
-    grpc_resource_user_shutdown(static_cast<PhonyEndpoint*>(ep)->ru_);
     grpc_core::ExecCtx::Run(DEBUG_LOCATION,
                             static_cast<PhonyEndpoint*>(ep)->read_cb_, why);
   }
 
   static void destroy(grpc_endpoint* ep) {
-    grpc_resource_user_unref(static_cast<PhonyEndpoint*>(ep)->ru_);
     delete static_cast<PhonyEndpoint*>(ep);
   }
 
-  static grpc_resource_user* get_resource_user(grpc_endpoint* ep) {
-    return static_cast<PhonyEndpoint*>(ep)->ru_;
-  }
   static absl::string_view get_peer(grpc_endpoint* /*ep*/) { return "test"; }
   static absl::string_view get_local_address(grpc_endpoint* /*ep*/) {
     return "test";
@@ -138,7 +134,8 @@ class Fixture {
   Fixture(const grpc::ChannelArguments& args, bool client) {
     grpc_channel_args c_args = args.c_channel_args();
     ep_ = new PhonyEndpoint;
-    t_ = grpc_create_chttp2_transport(&c_args, ep_, client);
+    t_ = grpc_create_chttp2_transport(&c_args, ep_, client,
+                                      grpc_resource_user_create_unlimited());
     grpc_chttp2_transport_start_reading(t_, nullptr, nullptr, nullptr);
     FlushExecCtx();
   }
@@ -262,8 +259,8 @@ class Stream {
 std::vector<std::unique_ptr<gpr_event>> done_events;
 
 static void BM_StreamCreateDestroy(benchmark::State& state) {
-  TrackCounters track_counters;
   grpc_core::ExecCtx exec_ctx;
+  TrackCounters track_counters;
   Fixture f(grpc::ChannelArguments(), true);
   auto* s = new Stream(&f);
   grpc_transport_stream_op_batch op;
@@ -294,9 +291,9 @@ class RepresentativeClientInitialMetadata {
     return {
         GRPC_MDELEM_SCHEME_HTTP,
         GRPC_MDELEM_METHOD_POST,
-        grpc_mdelem_from_slices(
-            GRPC_MDSTR_PATH,
-            grpc_slice_intern(grpc_slice_from_static_string("/foo/bar"))),
+        grpc_mdelem_from_slices(GRPC_MDSTR_PATH,
+                                grpc_slice_intern(grpc_slice_from_static_string(
+                                    "/foo/bar/bm_chttp2_transport"))),
         grpc_mdelem_from_slices(GRPC_MDSTR_AUTHORITY,
                                 grpc_slice_intern(grpc_slice_from_static_string(
                                     "foo.test.google.fr:1234"))),
index e38f95f..4c643fc 100644 (file)
 
 /* Test various closure related operations */
 
+#include <sstream>
+
 #include <benchmark/benchmark.h>
+
 #include <grpc/grpc.h>
-#include <sstream>
 
 #include "src/core/lib/gpr/spinlock.h"
 #include "src/core/lib/iomgr/closure.h"
 #include "src/core/lib/iomgr/combiner.h"
 #include "src/core/lib/iomgr/exec_ctx.h"
-
 #include "test/core/util/test_config.h"
 #include "test/cpp/microbenchmarks/helpers.h"
 #include "test/cpp/util/test_config.h"
index 9a5c6e7..4b9aeef 100644 (file)
@@ -20,6 +20,7 @@
  * working */
 
 #include <benchmark/benchmark.h>
+
 #include <grpc/grpc.h>
 #include <grpc/support/log.h>
 #include <grpcpp/completion_queue.h>
index d57a021..66bc5d8 100644 (file)
  *
  */
 
-#include <benchmark/benchmark.h>
 #include <string.h>
+
 #include <atomic>
 
+#include <benchmark/benchmark.h>
+
 #include <grpc/grpc.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
index ecc39ac..1559e9c 100644 (file)
 
 /* Test various operations on grpc_error */
 
-#include <benchmark/benchmark.h>
 #include <memory>
 
+#include <benchmark/benchmark.h>
+
 #include "src/core/lib/iomgr/error.h"
 #include "src/core/lib/transport/error_utils.h"
-
 #include "test/core/util/test_config.h"
 #include "test/cpp/microbenchmarks/helpers.h"
 #include "test/cpp/util/test_config.h"
index de03128..4c3a6a1 100644 (file)
 
 /* Benchmark gRPC end2end in various configurations */
 
-#include <benchmark/benchmark.h>
-
 #include <fstream>
 
+#include <benchmark/benchmark.h>
+
 #include "absl/flags/flag.h"
 #include "absl/memory/memory.h"
+
 #include "src/core/ext/transport/chttp2/transport/chttp2_transport.h"
 #include "src/core/ext/transport/chttp2/transport/internal.h"
 #include "src/core/lib/iomgr/timer_manager.h"
 #include "src/core/lib/profiling/timers.h"
 #include "src/proto/grpc/testing/echo.grpc.pb.h"
+#include "test/core/util/resource_user_util.h"
 #include "test/core/util/test_config.h"
 #include "test/core/util/trickle_endpoint.h"
 #include "test/cpp/microbenchmarks/fullstack_context_mutators.h"
@@ -218,8 +220,7 @@ class TrickledCHTTP2 : public EndpointPairFixture {
   static grpc_endpoint_pair MakeEndpoints(size_t kilobits,
                                           grpc_passthru_endpoint_stats* stats) {
     grpc_endpoint_pair p;
-    grpc_passthru_endpoint_create(&p.client, &p.server,
-                                  LibraryInitializer::get().rq(), stats);
+    grpc_passthru_endpoint_create(&p.client, &p.server, stats);
     double bytes_per_second = 125.0 * kilobits;
     p.client = grpc_trickle_endpoint_create(p.client, bytes_per_second);
     p.server = grpc_trickle_endpoint_create(p.server, bytes_per_second);
index b23918a..ac48c09 100644 (file)
 /* Test out various metadata handling primitives */
 
 #include <benchmark/benchmark.h>
+
 #include <grpc/grpc.h>
 
 #include "src/core/lib/slice/slice_internal.h"
 #include "src/core/lib/transport/metadata.h"
 #include "src/core/lib/transport/static_metadata.h"
-
 #include "test/core/util/test_config.h"
 #include "test/cpp/microbenchmarks/helpers.h"
 #include "test/cpp/util/test_config.h"
index 1a5aa05..7a3aadb 100644 (file)
  *
  */
 
-#include <benchmark/benchmark.h>
 #include <string>
 #include <thread>  // NOLINT
 
+#include <benchmark/benchmark.h>
+
 #include "absl/base/call_once.h"
 #include "absl/strings/str_cat.h"
-#include "include/grpc/grpc.h"
-#include "include/grpcpp/grpcpp.h"
 #include "opencensus/stats/stats.h"
+
+#include <grpc/grpc.h>
+#include <grpcpp/grpcpp.h>
+
 #include "src/cpp/ext/filters/census/grpc_plugin.h"
 #include "src/proto/grpc/testing/echo.grpc.pb.h"
 #include "test/core/util/test_config.h"
index ee813aa..beb38d6 100644 (file)
 
 /* Test out pollset latencies */
 
+#include <string.h>
+
 #include <benchmark/benchmark.h>
+
 #include <grpc/grpc.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include "src/core/lib/iomgr/pollset.h"
 #include "src/core/lib/iomgr/port.h"
 #include "src/core/lib/iomgr/wakeup_fd_posix.h"
-
 #include "test/core/util/test_config.h"
 #include "test/cpp/microbenchmarks/helpers.h"
 #include "test/cpp/util/test_config.h"
 
-#include <string.h>
-
 #ifdef GRPC_LINUX_MULTIPOLL_WITH_EPOLL
 #include <sys/epoll.h>
 #include <sys/eventfd.h>
index b06deee..dd57bce 100644 (file)
  *
  */
 
-#include <benchmark/benchmark.h>
-#include <grpc/grpc.h>
-
 #include <condition_variable>
 #include <mutex>
 
+#include <benchmark/benchmark.h>
+
+#include <grpc/grpc.h>
+
 #include "src/core/lib/iomgr/executor/threadpool.h"
 #include "test/core/util/test_config.h"
 #include "test/cpp/microbenchmarks/helpers.h"
index 60bf65d..8e3a74a 100644 (file)
  *
  */
 
-#include <benchmark/benchmark.h>
 #include <string.h>
+
 #include <atomic>
 #include <vector>
 
+#include <benchmark/benchmark.h>
+
 #include <grpc/grpc.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
index 436286b..f2e6657 100644 (file)
 #ifndef TEST_CPP_MICROBENCHMARKS_CALLBACK_STREAMING_PING_PONG_H
 #define TEST_CPP_MICROBENCHMARKS_CALLBACK_STREAMING_PING_PONG_H
 
-#include <benchmark/benchmark.h>
 #include <sstream>
+
+#include <benchmark/benchmark.h>
+
 #include "src/core/lib/profiling/timers.h"
 #include "src/proto/grpc/testing/echo.grpc.pb.h"
+#include "test/core/util/resource_user_util.h"
 #include "test/cpp/microbenchmarks/callback_test_service.h"
 #include "test/cpp/microbenchmarks/fullstack_context_mutators.h"
 #include "test/cpp/microbenchmarks/fullstack_fixtures.h"
index 010c8e8..0268de6 100644 (file)
 #ifndef TEST_CPP_MICROBENCHMARKS_CALLBACK_TEST_SERVICE_H
 #define TEST_CPP_MICROBENCHMARKS_CALLBACK_TEST_SERVICE_H
 
-#include <benchmark/benchmark.h>
 #include <condition_variable>
 #include <memory>
 #include <mutex>
 #include <sstream>
+
+#include <benchmark/benchmark.h>
+
 #include "src/proto/grpc/testing/echo.grpc.pb.h"
 #include "test/cpp/util/string_ref_helper.h"
 
index 80e9310..b058611 100644 (file)
 #ifndef TEST_CPP_MICROBENCHMARKS_CALLBACK_UNARY_PING_PONG_H
 #define TEST_CPP_MICROBENCHMARKS_CALLBACK_UNARY_PING_PONG_H
 
-#include <benchmark/benchmark.h>
 #include <sstream>
+
+#include <benchmark/benchmark.h>
+
 #include "src/core/lib/profiling/timers.h"
 #include "src/proto/grpc/testing/echo.grpc.pb.h"
+#include "test/core/util/resource_user_util.h"
 #include "test/cpp/microbenchmarks/callback_test_service.h"
 #include "test/cpp/microbenchmarks/fullstack_context_mutators.h"
 #include "test/cpp/microbenchmarks/fullstack_fixtures.h"
index 4526dee..08ff75a 100644 (file)
 #include "src/core/lib/surface/channel.h"
 #include "src/core/lib/surface/completion_queue.h"
 #include "src/core/lib/surface/server.h"
+#include "src/cpp/client/create_channel_internal.h"
 #include "test/core/util/passthru_endpoint.h"
 #include "test/core/util/port.h"
-
-#include "src/cpp/client/create_channel_internal.h"
 #include "test/cpp/microbenchmarks/helpers.h"
 
 namespace grpc {
@@ -169,17 +168,18 @@ class EndpointPairFixture : public BaseFixture {
     b.RegisterService(service);
     fixture_configuration.ApplyCommonServerBuilderConfig(&b);
     server_ = b.BuildAndStart();
-
     grpc_core::ExecCtx exec_ctx;
-
     /* add server endpoint to server_
      * */
     {
       const grpc_channel_args* server_args =
           server_->c_server()->core_server->channel_args();
+      grpc_resource_quota* server_resource_quota =
+          grpc_resource_quota_from_channel_args(server_args, true);
       server_transport_ = grpc_create_chttp2_transport(
-          server_args, endpoints.server, false /* is_client */);
-
+          server_args, endpoints.server, false /* is_client */,
+          grpc_resource_user_create(server_resource_quota, "server_transport"));
+      grpc_resource_quota_unref(server_resource_quota);
       for (grpc_pollset* pollset :
            server_->c_server()->core_server->pollsets()) {
         grpc_endpoint_add_to_pollset(endpoints.server, pollset);
@@ -198,11 +198,16 @@ class EndpointPairFixture : public BaseFixture {
       fixture_configuration.ApplyCommonChannelArguments(&args);
 
       grpc_channel_args c_args = args.c_channel_args();
-      client_transport_ =
-          grpc_create_chttp2_transport(&c_args, endpoints.client, true);
+      grpc_resource_quota* client_resource_quota =
+          grpc_resource_quota_from_channel_args(&c_args, true);
+      client_transport_ = grpc_create_chttp2_transport(
+          &c_args, endpoints.client, true,
+          grpc_resource_user_create(client_resource_quota, "client_transport"));
+      grpc_resource_quota_unref(client_resource_quota);
       GPR_ASSERT(client_transport_);
-      grpc_channel* channel = grpc_channel_create(
-          "target", &c_args, GRPC_CLIENT_DIRECT_CHANNEL, client_transport_);
+      grpc_channel* channel =
+          grpc_channel_create("target", &c_args, GRPC_CLIENT_DIRECT_CHANNEL,
+                              client_transport_, nullptr, 0, nullptr);
       grpc_chttp2_transport_start_reading(client_transport_, nullptr, nullptr,
                                           nullptr);
 
@@ -284,8 +289,7 @@ class InProcessCHTTP2WithExplicitStats : public EndpointPairFixture {
 
   static grpc_endpoint_pair MakeEndpoints(grpc_passthru_endpoint_stats* stats) {
     grpc_endpoint_pair p;
-    grpc_passthru_endpoint_create(&p.client, &p.server,
-                                  LibraryInitializer::get().rq(), stats);
+    grpc_passthru_endpoint_create(&p.client, &p.server, stats);
     return p;
   }
 };
index 9ca213c..a8f80b9 100644 (file)
 #ifndef TEST_CPP_MICROBENCHMARKS_FULLSTACK_STREAMING_PING_PONG_H
 #define TEST_CPP_MICROBENCHMARKS_FULLSTACK_STREAMING_PING_PONG_H
 
-#include <benchmark/benchmark.h>
 #include <sstream>
+
+#include <benchmark/benchmark.h>
+
 #include "src/core/lib/profiling/timers.h"
 #include "src/proto/grpc/testing/echo.grpc.pb.h"
 #include "test/cpp/microbenchmarks/fullstack_context_mutators.h"
index d05258b..807e588 100644 (file)
 #ifndef TEST_CPP_MICROBENCHMARKS_FULLSTACK_STREAMING_PUMP_H
 #define TEST_CPP_MICROBENCHMARKS_FULLSTACK_STREAMING_PUMP_H
 
-#include <benchmark/benchmark.h>
 #include <sstream>
+
+#include <benchmark/benchmark.h>
+
 #include "src/core/lib/profiling/timers.h"
 #include "src/proto/grpc/testing/echo.grpc.pb.h"
 #include "test/cpp/microbenchmarks/fullstack_context_mutators.h"
index 604e0ed..6776408 100644 (file)
 #ifndef TEST_CPP_MICROBENCHMARKS_FULLSTACK_UNARY_PING_PONG_H
 #define TEST_CPP_MICROBENCHMARKS_FULLSTACK_UNARY_PING_PONG_H
 
-#include <benchmark/benchmark.h>
 #include <sstream>
+
+#include <benchmark/benchmark.h>
+
 #include "src/core/lib/profiling/timers.h"
 #include "src/proto/grpc/testing/echo.grpc.pb.h"
 #include "test/cpp/microbenchmarks/fullstack_context_mutators.h"
index 8f1ffb0..d46321c 100644 (file)
  *
  */
 
-#include <string.h>
-
 #include "test/cpp/microbenchmarks/helpers.h"
 
+#include <string.h>
+
 static grpc::internal::GrpcLibraryInitializer g_gli_initializer;
 static LibraryInitializer* g_libraryInitializer;
 
@@ -32,13 +32,11 @@ LibraryInitializer::LibraryInitializer() {
   grpc_memory_counters_init();
 #endif
   init_lib_.init();
-  rq_ = grpc_resource_quota_create("bm");
 }
 
 LibraryInitializer::~LibraryInitializer() {
   g_libraryInitializer = nullptr;
   init_lib_.shutdown();
-  grpc_resource_quota_unref(rq_);
 }
 
 LibraryInitializer& LibraryInitializer::get() {
index cd5b9d9..f8faa23 100644 (file)
 #ifndef TEST_CPP_MICROBENCHMARKS_COUNTERS_H
 #define TEST_CPP_MICROBENCHMARKS_COUNTERS_H
 
+#include <grpc/support/port_platform.h>
+
 #include <sstream>
 #include <vector>
 
-#include <grpc/support/port_platform.h>
-#include "src/core/lib/debug/stats.h"
-#include "test/core/util/memory_counters.h"
-
 #include <benchmark/benchmark.h>
+
 #include <grpcpp/impl/grpc_library.h>
 
+#include "src/core/lib/debug/stats.h"
+#include "test/core/util/memory_counters.h"
+
 class LibraryInitializer {
  public:
   LibraryInitializer();
   ~LibraryInitializer();
 
-  grpc_resource_quota* rq() { return rq_; }
-
   static LibraryInitializer& get();
 
  private:
   grpc::internal::GrpcLibrary init_lib_;
-  grpc_resource_quota* rq_;
 };
 
 #ifdef GPR_LOW_LEVEL_COUNTERS
index e2b56c9..3360366 100644 (file)
  *
  */
 
+#include <string.h>
+#include <sys/types.h>
+
+#include <vector>
+
 #include <address_sorting/address_sorting.h>
 #include <gmock/gmock.h>
+
 #include <grpc/grpc.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/log.h>
 #include <grpc/support/string_util.h>
 #include <grpc/support/sync.h>
 #include <grpc/support/time.h>
-#include <string.h>
-#include <sys/types.h>
-
-#include <vector>
 
 #include "src/core/ext/filters/client_channel/client_channel.h"
 #include "src/core/ext/filters/client_channel/resolver.h"
index 239d7d4..ff9ce38 100644 (file)
  *
  */
 
-#include <gmock/gmock.h>
-#include <grpc/byte_buffer.h>
-#include <grpc/grpc.h>
-#include <grpc/support/alloc.h>
-#include <grpc/support/log.h>
-#include <grpc/support/time.h>
 #include <stdio.h>
 #include <string.h>
 
 #include <string>
 
+#include <gmock/gmock.h>
+
 #include "absl/strings/str_cat.h"
 #include "absl/strings/str_format.h"
+
+#include <grpc/byte_buffer.h>
+#include <grpc/grpc.h>
+#include <grpc/support/alloc.h>
+#include <grpc/support/log.h>
+#include <grpc/support/time.h>
+
 #include "src/core/ext/filters/client_channel/resolver.h"
 #include "src/core/ext/filters/client_channel/resolver/dns/dns_resolver_selection.h"
 #include "src/core/ext/filters/client_channel/resolver_registry.h"
index 3230792..e0ea96f 100644 (file)
@@ -16,6 +16,8 @@
  *
  */
 
+#include "test/cpp/naming/dns_test_util.h"
+
 #include <stdio.h>
 #include <string.h>
 
@@ -23,7 +25,6 @@
 #include <grpc/support/log.h>
 
 #include "src/core/lib/event_engine/sockaddr.h"
-#include "test/cpp/naming/dns_test_util.h"
 
 #ifdef GPR_WINDOWS
 #include "src/core/lib/iomgr/sockaddr_windows.h"
index a8c39fc..a230b5a 100644 (file)
  *
  */
 
+#include <grpc/support/port_platform.h>
+
 #include <errno.h>
 #include <fcntl.h>
-#include <gmock/gmock.h>
-#include <grpc/grpc.h>
-#include <grpc/impl/codegen/grpc_types.h>
-#include <grpc/support/alloc.h>
-#include <grpc/support/log.h>
-#include <grpc/support/port_platform.h>
-#include <grpc/support/sync.h>
-#include <grpc/support/time.h>
 #include <string.h>
 
 #include <string>
 #include <thread>
 #include <vector>
 
+#include <gmock/gmock.h>
+
 #include "absl/flags/flag.h"
 #include "absl/memory/memory.h"
 #include "absl/strings/str_cat.h"
 #include "absl/strings/str_format.h"
+
+#include <grpc/grpc.h>
+#include <grpc/impl/codegen/grpc_types.h>
+#include <grpc/support/alloc.h>
+#include <grpc/support/log.h>
+#include <grpc/support/sync.h>
+#include <grpc/support/time.h>
+
 #include "src/core/ext/filters/client_channel/client_channel.h"
 #include "src/core/ext/filters/client_channel/lb_policy/grpclb/grpclb_balancer_addresses.h"
 #include "src/core/ext/filters/client_channel/resolver.h"
index 2ae8da9..d6f1217 100644 (file)
  *
  */
 
-#include <grpc/grpc.h>
-#include <grpc/support/alloc.h>
-#include <grpc/support/log.h>
-#include <grpc/support/string_util.h>
 #include <signal.h>
 #include <string.h>
 #include <unistd.h>
 
 #include "absl/flags/flag.h"
 
+#include <grpc/grpc.h>
+#include <grpc/support/alloc.h>
+#include <grpc/support/log.h>
+#include <grpc/support/string_util.h>
+
 #ifdef __FreeBSD__
 #include <sys/wait.h>
 #endif
index 045e297..f49795e 100644 (file)
@@ -16,6 +16,8 @@
  *
  */
 
+#include <gtest/gtest.h>
+
 #include <grpc/support/log.h>
 #include <grpcpp/channel.h>
 #include <grpcpp/create_channel.h>
@@ -24,7 +26,6 @@
 #include <grpcpp/security/server_credentials.h>
 #include <grpcpp/server.h>
 #include <grpcpp/server_builder.h>
-#include <gtest/gtest.h>
 
 #include "src/core/ext/transport/chttp2/transport/chttp2_transport.h"
 #include "src/core/lib/channel/channel_args.h"
 #include "src/core/lib/surface/channel.h"
 #include "src/core/lib/surface/completion_queue.h"
 #include "src/core/lib/surface/server.h"
-#include "test/core/util/passthru_endpoint.h"
-#include "test/core/util/port.h"
-
 #include "src/cpp/client/create_channel_internal.h"
 #include "src/proto/grpc/testing/echo.grpc.pb.h"
+#include "test/core/util/passthru_endpoint.h"
+#include "test/core/util/port.h"
+#include "test/core/util/resource_user_util.h"
 #include "test/core/util/test_config.h"
 
 namespace grpc {
@@ -73,8 +74,8 @@ class EndpointPairFixture {
       const grpc_channel_args* server_args =
           server_->c_server()->core_server->channel_args();
       grpc_transport* transport = grpc_create_chttp2_transport(
-          server_args, endpoints.server, false /* is_client */);
-
+          server_args, endpoints.server, false /* is_client */,
+          grpc_resource_user_create_unlimited());
       for (grpc_pollset* pollset :
            server_->c_server()->core_server->pollsets()) {
         grpc_endpoint_add_to_pollset(endpoints.server, pollset);
@@ -93,10 +94,12 @@ class EndpointPairFixture {
 
       grpc_channel_args c_args = args.c_channel_args();
       grpc_transport* transport =
-          grpc_create_chttp2_transport(&c_args, endpoints.client, true);
+          grpc_create_chttp2_transport(&c_args, endpoints.client, true,
+                                       grpc_resource_user_create_unlimited());
       GPR_ASSERT(transport);
-      grpc_channel* channel = grpc_channel_create(
-          "target", &c_args, GRPC_CLIENT_DIRECT_CHANNEL, transport);
+      grpc_channel* channel =
+          grpc_channel_create("target", &c_args, GRPC_CLIENT_DIRECT_CHANNEL,
+                              transport, nullptr, 0, nullptr);
       grpc_chttp2_transport_start_reading(transport, nullptr, nullptr, nullptr);
 
       channel_ = ::grpc::CreateChannelInternal(
@@ -141,9 +144,8 @@ class InProcessCHTTP2 : public EndpointPairFixture {
   grpc_passthru_endpoint_stats* stats_;
 
   static grpc_endpoint_pair MakeEndpoints(grpc_passthru_endpoint_stats* stats) {
-    static grpc_resource_quota* rq = grpc_resource_quota_create("bm");
     grpc_endpoint_pair p;
-    grpc_passthru_endpoint_create(&p.client, &p.server, rq, stats);
+    grpc_passthru_endpoint_create(&p.client, &p.server, stats);
     return p;
   }
 };
index 4ec07e9..3a44eab 100644 (file)
 
 #include "test/cpp/qps/benchmark_config.h"
 
+#include "absl/flags/flag.h"
+
 #include <grpc/support/log.h>
 #include <grpcpp/create_channel.h>
 #include <grpcpp/security/credentials.h>
 
-#include "absl/flags/flag.h"
 #include "test/cpp/util/test_credentials_provider.h"
 
 ABSL_FLAG(bool, enable_log_reporter, true,
index 5cb4d9d..9d2c723 100644 (file)
@@ -27,6 +27,9 @@
 #include <unordered_map>
 #include <vector>
 
+#include "absl/memory/memory.h"
+#include "absl/strings/match.h"
+
 #include <grpc/support/log.h>
 #include <grpc/support/time.h>
 #include <grpcpp/channel.h>
 #include <grpcpp/support/channel_arguments.h>
 #include <grpcpp/support/slice.h>
 
-#include "absl/memory/memory.h"
-#include "absl/strings/match.h"
-
-#include "src/proto/grpc/testing/benchmark_service.grpc.pb.h"
-#include "src/proto/grpc/testing/payloads.pb.h"
-
 #include "src/core/lib/gpr/env.h"
 #include "src/cpp/util/core_stats.h"
+#include "src/proto/grpc/testing/benchmark_service.grpc.pb.h"
+#include "src/proto/grpc/testing/payloads.pb.h"
 #include "test/cpp/qps/histogram.h"
 #include "test/cpp/qps/interarrival.h"
 #include "test/cpp/qps/qps_worker.h"
index f757b0c..4e57de3 100644 (file)
@@ -27,6 +27,8 @@
 #include <utility>
 #include <vector>
 
+#include "absl/memory/memory.h"
+
 #include <grpc/grpc.h>
 #include <grpc/support/cpu.h>
 #include <grpc/support/log.h>
@@ -35,8 +37,6 @@
 #include <grpcpp/client_context.h>
 #include <grpcpp/generic/generic_stub.h>
 
-#include "absl/memory/memory.h"
-
 #include "src/core/lib/surface/completion_queue.h"
 #include "src/proto/grpc/testing/benchmark_service.grpc.pb.h"
 #include "test/cpp/qps/client.h"
@@ -822,7 +822,6 @@ class ClientRpcContextGenericStreamingImpl : public ClientRpcContext {
           next_state_ = State::READ_DONE;
           stream_->Read(&response_, ClientRpcContext::tag(this));
           return true;
-          break;
         case State::READ_DONE:
           entry->set_value((UsageTimer::Now() - start_) * 1e9);
           callback_(status_, &response_);
@@ -841,7 +840,6 @@ class ClientRpcContextGenericStreamingImpl : public ClientRpcContext {
         case State::FINISH_DONE:
           next_state_ = State::INVALID;
           return false;
-          break;
         default:
           GPR_ASSERT(false);
           return false;
index 95e5a86..3119d2a 100644 (file)
@@ -25,6 +25,8 @@
 #include <utility>
 #include <vector>
 
+#include "absl/memory/memory.h"
+
 #include <grpc/grpc.h>
 #include <grpc/support/cpu.h>
 #include <grpc/support/log.h>
@@ -32,8 +34,6 @@
 #include <grpcpp/channel.h>
 #include <grpcpp/client_context.h>
 
-#include "absl/memory/memory.h"
-
 #include "src/proto/grpc/testing/benchmark_service.grpc.pb.h"
 #include "test/cpp/qps/client.h"
 #include "test/cpp/qps/usage_timer.h"
index 0ae8529..d2ecb63 100644 (file)
@@ -16,6 +16,8 @@
  *
  */
 
+#include "test/cpp/qps/driver.h"
+
 #include <cinttypes>
 #include <deque>
 #include <list>
@@ -37,7 +39,6 @@
 #include "test/core/util/port.h"
 #include "test/core/util/test_config.h"
 #include "test/cpp/qps/client.h"
-#include "test/cpp/qps/driver.h"
 #include "test/cpp/qps/histogram.h"
 #include "test/cpp/qps/qps_worker.h"
 #include "test/cpp/qps/stats.h"
index 2084eb1..6f4def9 100644 (file)
@@ -31,10 +31,10 @@ load("//test/cpp/qps:json_run_localhost_scenarios.bzl", "JSON_RUN_LOCALHOST_SCEN
 
 def add_suffix(name):
     # NOTE(https://github.com/grpc/grpc/issues/24178): Add the suffix to the name
-    # to avoid having the target name that 89 or 90 long.
-    m = len(name) - (89 - len("//test/cpp/qps:"))
-    if m == 0 or m == 1:
-        return name + "_" * (2 - m)
+    # to avoid having the target name that 87, 88, 89 or 90 long.
+    m = len(name) - (87 - len("//test/cpp/qps:"))
+    if m >= 0 and m <= 3:
+        return name + "_" * (4 - m)
     else:
         return name
 
index 1f29cd7..768c897 100644 (file)
@@ -21,7 +21,6 @@
 
 // Use the C histogram rather than C++ to avoid depending on proto
 #include "test/core/util/histogram.h"
-
 #include "test/core/util/test_config.h"
 #include "test/cpp/qps/interarrival.h"
 #include "test/cpp/util/test_config.h"
index 6dcb73d..2e8cb42 100644 (file)
  *
  */
 
-#include <grpc/support/log.h>
-#include <grpcpp/impl/codegen/config_protobuf.h>
-
 #include <fstream>
 #include <iostream>
 #include <memory>
 #include <set>
 
 #include "absl/flags/flag.h"
+
+#include <grpc/support/log.h>
+#include <grpcpp/impl/codegen/config_protobuf.h>
+
 #include "test/core/util/test_config.h"
 #include "test/cpp/qps/benchmark_config.h"
 #include "test/cpp/qps/driver.h"
index 99c0e34..cd916bf 100644 (file)
@@ -25,6 +25,8 @@
 #include <thread>
 #include <vector>
 
+#include "absl/memory/memory.h"
+
 #include <grpc/grpc.h>
 #include <grpc/support/alloc.h>
 #include <grpc/support/cpu.h>
@@ -34,8 +36,6 @@
 #include <grpcpp/server.h>
 #include <grpcpp/server_builder.h>
 
-#include "absl/memory/memory.h"
-
 #include "src/core/lib/gprpp/host_port.h"
 #include "src/proto/grpc/testing/worker_service.grpc.pb.h"
 #include "test/core/util/grpc_profiler.h"
@@ -67,7 +67,6 @@ static std::unique_ptr<Client> CreateClient(const ClientConfig& config) {
     default:
       abort();
   }
-  abort();
 }
 
 static std::unique_ptr<Server> CreateServer(const ServerConfig& config) {
@@ -86,7 +85,6 @@ static std::unique_ptr<Server> CreateServer(const ServerConfig& config) {
     default:
       abort();
   }
-  abort();
 }
 
 class ScopedProfile final {
index 858ccaa..b4299d2 100644 (file)
 #include <fstream>
 
 #include <grpc/support/log.h>
-#include "test/cpp/qps/driver.h"
-#include "test/cpp/qps/parse_json.h"
-#include "test/cpp/qps/stats.h"
-
 #include <grpcpp/client_context.h>
+
 #include "src/cpp/util/core_stats.h"
 #include "src/proto/grpc/testing/report_qps_scenario_service.grpc.pb.h"
+#include "test/cpp/qps/driver.h"
+#include "test/cpp/qps/parse_json.h"
+#include "test/cpp/qps/stats.h"
 
 namespace grpc {
 namespace testing {
index d85dea4..9cb837d 100644 (file)
 #include <set>
 #include <vector>
 
+#include <grpcpp/channel.h>
 #include <grpcpp/support/config.h>
 
-#include "test/cpp/qps/driver.h"
-
-#include <grpcpp/channel.h>
 #include "src/proto/grpc/testing/report_qps_scenario_service.grpc.pb.h"
+#include "test/cpp/qps/driver.h"
 
 namespace grpc {
 namespace testing {
index 9a90d17..533361d 100644 (file)
 #ifndef TEST_QPS_SERVER_H
 #define TEST_QPS_SERVER_H
 
+#include <vector>
+
 #include <grpc/support/cpu.h>
 #include <grpc/support/log.h>
 #include <grpcpp/channel.h>
 #include <grpcpp/resource_quota.h>
 #include <grpcpp/security/server_credentials.h>
 #include <grpcpp/server_builder.h>
-#include <vector>
 
 #include "src/cpp/util/core_stats.h"
 #include "src/proto/grpc/testing/control.pb.h"
index f2d34be..d57e5a8 100644 (file)
@@ -90,8 +90,12 @@ class AsyncQpsServerTest final : public grpc::testing::Server {
 
     int num_threads = config.async_server_threads();
     if (num_threads <= 0) {  // dynamic sizing
-      num_threads = cores();
-      gpr_log(GPR_INFO, "Sizing async server to %d threads", num_threads);
+      num_threads = std::min(64, cores());
+      gpr_log(GPR_INFO,
+              "Sizing async server to %d threads. Defaults to number of cores "
+              "in machine or 64 threads if machine has more than 64 cores to "
+              "avoid OOMs.",
+              num_threads);
     }
 
     int tpc = std::max(1, config.threads_per_cq());  // 1 if unspecified
index 0a758a6..1314ab5 100644 (file)
@@ -16,8 +16,6 @@
  *
  */
 
-#include <grpc/grpc.h>
-#include <grpc/support/time.h>
 #include <signal.h>
 
 #include <chrono>
 #include <vector>
 
 #include "absl/flags/flag.h"
+
+#include <grpc/grpc.h>
+#include <grpc/support/time.h>
+
 #include "test/core/util/test_config.h"
 #include "test/cpp/qps/qps_worker.h"
 #include "test/cpp/util/test_config.h"
index 16e2a5d..9b84af8 100644 (file)
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-#include <grpcpp/security/authorization_policy_provider.h>
 #include <gtest/gtest.h>
 
+#include <grpcpp/security/authorization_policy_provider.h>
+
 #include "test/core/util/test_config.h"
 
 namespace grpc {
index 3c8dcf7..f0a6e09 100644 (file)
 // limitations under the License.
 //
 
+#include <memory>
+
 #include <gmock/gmock.h>
+#include <gtest/gtest.h>
+
 #include <grpc/grpc.h>
 #include <grpc/grpc_security.h>
 #include <grpcpp/security/server_credentials.h>
 #include <grpcpp/security/tls_credentials_options.h>
-#include <gtest/gtest.h>
-
-#include <memory>
 
 #include "src/cpp/client/secure_credentials.h"
 #include "test/core/util/port.h"
index 98c15b2..9b821d2 100644 (file)
 
 #include <grpc/impl/codegen/port_platform.h>
 
-#include <grpc/grpc.h>
+#include "src/cpp/server/load_reporter/get_cpu_stats.h"
+
 #include <gtest/gtest.h>
 
+#include <grpc/grpc.h>
+
 #include "test/core/util/port.h"
 #include "test/core/util/test_config.h"
 
-#include "src/cpp/server/load_reporter/get_cpu_stats.h"
-
 namespace grpc {
 namespace testing {
 namespace {
index 74fd326..4d5a877 100644 (file)
 
 #include <grpc/impl/codegen/port_platform.h>
 
+#include "src/cpp/server/load_reporter/load_data_store.h"
+
 #include <set>
 #include <vector>
 
-#include <grpc/grpc.h>
 #include <gtest/gtest.h>
 
-#include "src/cpp/server/load_reporter/load_data_store.h"
+#include <grpc/grpc.h>
+
 #include "test/core/util/port.h"
 #include "test/core/util/test_config.h"
 
index 614a03b..9d84b04 100644 (file)
 
 #include <grpc/impl/codegen/port_platform.h>
 
+#include "src/cpp/server/load_reporter/load_reporter.h"
+
 #include <set>
 #include <vector>
 
 #include <gmock/gmock.h>
-#include <grpc/grpc.h>
 #include <gtest/gtest.h>
 
 #include "absl/memory/memory.h"
+#include "opencensus/stats/testing/test_utils.h"
+
+#include <grpc/grpc.h>
 
 #include "src/core/ext/filters/load_reporting/registered_opencensus_objects.h"
 #include "src/core/lib/iomgr/exec_ctx.h"
 #include "src/cpp/server/load_reporter/constants.h"
-#include "src/cpp/server/load_reporter/load_reporter.h"
 #include "test/core/util/port.h"
 #include "test/core/util/test_config.h"
 
-#include "opencensus/stats/testing/test_utils.h"
-
 namespace grpc {
 namespace testing {
 namespace {
index 5d9fb06..eb11e2d 100644 (file)
  *
  */
 
-#include <grpcpp/impl/codegen/config.h>
 #include <gtest/gtest.h>
 
+#include <grpc/grpc.h>
+#include <grpcpp/impl/codegen/config.h>
 #include <grpcpp/server.h>
 #include <grpcpp/server_builder.h>
 
-#include <grpc/grpc.h>
-
 #include "src/proto/grpc/testing/echo.grpc.pb.h"
 #include "test/core/util/port.h"
 #include "test/core/util/test_config.h"
index 285f68b..8ed5372 100644 (file)
  *
  */
 
-#include <grpcpp/impl/codegen/config.h>
+#include <memory>
+
 #include <gtest/gtest.h>
 
+#include <grpc/grpc.h>
+#include <grpcpp/impl/codegen/config.h>
 #include <grpcpp/server.h>
 #include <grpcpp/server_builder.h>
 
-#include <grpc/grpc.h>
-#include <memory>
-
 #include "src/core/lib/iomgr/socket_mutator.h"
 #include "src/proto/grpc/testing/echo.grpc.pb.h"
 #include "test/core/util/port.h"
index eaff051..a41d86c 100644 (file)
 
 #include <thread>
 
-#include <grpcpp/impl/codegen/config.h>
-
-#include <grpcpp/server.h>
-#include <grpcpp/server_builder.h>
+#include <gtest/gtest.h>
 
+#include <grpc/support/log.h>
 #include <grpcpp/create_channel.h>
+#include <grpcpp/impl/codegen/config.h>
 #include <grpcpp/security/credentials.h>
-
-#include <grpc/support/log.h>
+#include <grpcpp/server.h>
+#include <grpcpp/server_builder.h>
 
 #include "src/proto/grpc/testing/echo.grpc.pb.h"
 #include "test/core/util/port.h"
 #include "test/core/util/test_config.h"
 
-#include <gtest/gtest.h>
-
 namespace grpc {
 namespace {
 
index 35f376f..67ab62d 100644 (file)
  *
  */
 
-#include <grpcpp/test/client_context_test_peer.h>
-
 #include <cstring>
 #include <vector>
 
-#include <grpcpp/impl/grpc_library.h>
 #include <gtest/gtest.h>
 
+#include <grpcpp/impl/grpc_library.h>
+#include <grpcpp/test/client_context_test_peer.h>
+
 namespace grpc {
 namespace testing {
 
index 3338f32..646596b 100644 (file)
  *
  */
 
-#include <grpcpp/test/mock_stream.h>
 #include <gtest/gtest.h>
 
 #include "absl/memory/memory.h"
 
+#include <grpcpp/test/mock_stream.h>
+
 #include "src/proto/grpc/testing/echo.grpc.pb.h"
 
 using grpc::testing::EchoRequest;
index d4531a8..42e9e89 100644 (file)
  *
  */
 
-#include <grpcpp/test/server_context_test_spouse.h>
-
 #include <cstring>
 #include <vector>
 
-#include <grpcpp/impl/grpc_library.h>
 #include <gtest/gtest.h>
 
+#include <grpcpp/impl/grpc_library.h>
+#include <grpcpp/test/server_context_test_spouse.h>
+
 namespace grpc {
 namespace testing {
 
index 31d6ad5..9d8db74 100644 (file)
  *is % allowed in string
  */
 
+#include <grpc/support/port_platform.h>
+
+#include "src/cpp/thread_manager/thread_manager.h"
+
 #include <atomic>
 #include <chrono>
 #include <climits>
 #include <memory>
 #include <thread>
 
+#include <gtest/gtest.h>
+
 #include <grpc/support/log.h>
-#include <grpc/support/port_platform.h>
 #include <grpcpp/grpcpp.h>
 
-#include "src/cpp/thread_manager/thread_manager.h"
 #include "test/core/util/test_config.h"
 
-#include <gtest/gtest.h>
-
 namespace grpc {
 namespace {
 
index 4590e3c..f2f46da 100644 (file)
@@ -204,6 +204,7 @@ grpc_cc_test(
         "//src/proto/grpc/testing:echo_proto",
         "//src/proto/grpc/testing:simple_messages_proto",
         "//test/core/util:grpc_test_util",
+        "//test/cpp/util:test_config",
     ],
 )
 
index 5d6c183..ab18b5e 100644 (file)
  *
  */
 
-#include <grpc++/support/byte_buffer.h>
-#include <grpcpp/impl/grpc_library.h>
-
 #include <cstring>
 #include <vector>
 
+#include <gtest/gtest.h>
+
+#include <grpc++/support/byte_buffer.h>
 #include <grpc/grpc.h>
 #include <grpc/slice.h>
+#include <grpcpp/impl/grpc_library.h>
 #include <grpcpp/support/slice.h>
-#include <gtest/gtest.h>
 
 #include "test/core/util/test_config.h"
 
index 2e1c7be..770c9b0 100644 (file)
 
 #include "test/cpp/util/channel_trace_proto_helper.h"
 
+#include <gtest/gtest.h>
+
 #include <grpc/grpc.h>
 #include <grpc/support/log.h>
 #include <grpcpp/impl/codegen/config.h>
 #include <grpcpp/impl/codegen/config_protobuf.h>
-#include <gtest/gtest.h>
 
 #include "src/core/lib/iomgr/error.h"
 #include "src/core/lib/json/json.h"
index fc6afed..a63e6b7 100644 (file)
@@ -15,6 +15,8 @@
  * limitations under the License.
  *
  */
+#include <grpc/support/port_platform.h>
+
 #include <unistd.h>
 
 #include <cstdlib>
 #include "absl/strings/str_format.h"
 #include "absl/strings/str_join.h"
 #include "google/protobuf/text_format.h"
-#include "grpc/grpc.h"
-#include "grpc/support/port_platform.h"
-#include "grpcpp/channel.h"
-#include "grpcpp/client_context.h"
-#include "grpcpp/create_channel.h"
-#include "grpcpp/ext/channelz_service_plugin.h"
-#include "grpcpp/grpcpp.h"
-#include "grpcpp/security/credentials.h"
-#include "grpcpp/security/server_credentials.h"
-#include "grpcpp/server.h"
-#include "grpcpp/server_builder.h"
-#include "grpcpp/server_context.h"
+
+#include <grpc/grpc.h>
+#include <grpcpp/channel.h>
+#include <grpcpp/client_context.h>
+#include <grpcpp/create_channel.h>
+#include <grpcpp/ext/channelz_service_plugin.h>
+#include <grpcpp/grpcpp.h>
+#include <grpcpp/security/credentials.h>
+#include <grpcpp/security/server_credentials.h>
+#include <grpcpp/server.h>
+#include <grpcpp/server_builder.h>
+#include <grpcpp/server_context.h>
+
 #include "src/core/lib/json/json.h"
 #include "src/cpp/server/channelz/channelz_service.h"
 #include "src/proto/grpc/channelz/channelz.pb.h"
index 5dad070..c8519f6 100644 (file)
@@ -15,6 +15,8 @@
  * limitations under the License.
  *
  */
+#include <grpc/support/port_platform.h>
+
 #include <stdlib.h>
 #include <unistd.h>
 
 #include <string>
 #include <thread>
 
-#include "grpc/grpc.h"
-#include "grpc/support/alloc.h"
-#include "grpc/support/port_platform.h"
-#include "grpcpp/channel.h"
-#include "grpcpp/client_context.h"
-#include "grpcpp/create_channel.h"
-#include "grpcpp/ext/channelz_service_plugin.h"
-#include "grpcpp/grpcpp.h"
-#include "grpcpp/security/credentials.h"
-#include "grpcpp/security/server_credentials.h"
-#include "grpcpp/server.h"
-#include "grpcpp/server_builder.h"
-#include "grpcpp/server_context.h"
 #include "gtest/gtest.h"
+
+#include <grpc/grpc.h>
+#include <grpc/support/alloc.h>
+#include <grpcpp/channel.h>
+#include <grpcpp/client_context.h>
+#include <grpcpp/create_channel.h>
+#include <grpcpp/ext/channelz_service_plugin.h>
+#include <grpcpp/grpcpp.h>
+#include <grpcpp/security/credentials.h>
+#include <grpcpp/security/server_credentials.h>
+#include <grpcpp/server.h>
+#include <grpcpp/server_builder.h>
+#include <grpcpp/server_context.h>
+
 #include "src/core/lib/gpr/env.h"
 #include "src/cpp/server/channelz/channelz_service.h"
 #include "src/proto/grpc/testing/test.grpc.pb.h"
index 34def7a..f1dc741 100644 (file)
 
 #include "test/cpp/util/cli_call.h"
 
+#include <cmath>
+#include <iostream>
+#include <utility>
+
 #include <grpc/grpc.h>
 #include <grpc/slice.h>
 #include <grpc/support/log.h>
 #include <grpcpp/client_context.h>
 #include <grpcpp/support/byte_buffer.h>
 
-#include <cmath>
-#include <iostream>
-#include <utility>
-
 namespace grpc {
 namespace testing {
 namespace {
index 30271ae..f5454a1 100644 (file)
 #ifndef GRPC_TEST_CPP_UTIL_CLI_CALL_H
 #define GRPC_TEST_CPP_UTIL_CLI_CALL_H
 
+#include <map>
+
 #include <grpcpp/channel.h>
 #include <grpcpp/completion_queue.h>
 #include <grpcpp/generic/generic_stub.h>
 #include <grpcpp/support/status.h>
 #include <grpcpp/support/string_ref.h>
 
-#include <map>
-
 namespace grpc {
 
 class ClientContext;
index 51c2424..9f8288a 100644 (file)
@@ -18,6 +18,8 @@
 
 #include "test/cpp/util/cli_call.h"
 
+#include <gtest/gtest.h>
+
 #include <grpc/grpc.h>
 #include <grpcpp/channel.h>
 #include <grpcpp/client_context.h>
@@ -25,7 +27,6 @@
 #include <grpcpp/server.h>
 #include <grpcpp/server_builder.h>
 #include <grpcpp/server_context.h>
-#include <gtest/gtest.h>
 
 #include "src/proto/grpc/testing/echo.grpc.pb.h"
 #include "test/core/util/port.h"
index 0c09872..579276a 100644 (file)
 
 #include "test/cpp/util/cli_credentials.h"
 
+#include "absl/flags/flag.h"
+
 #include <grpc/slice.h>
 #include <grpc/support/log.h>
 #include <grpcpp/impl/codegen/slice.h>
 
-#include "absl/flags/flag.h"
 #include "src/core/lib/iomgr/load_file.h"
 
 ABSL_RETIRED_FLAG(bool, enable_ssl, false,
index 67b6bde..a391532 100644 (file)
 
 #include "test/cpp/util/create_test_channel.h"
 
+#include "absl/flags/flag.h"
+
 #include <grpc/support/log.h>
 #include <grpcpp/create_channel.h>
 #include <grpcpp/security/credentials.h>
 
-#include "absl/flags/flag.h"
 #include "test/cpp/util/test_credentials_provider.h"
 
 ABSL_FLAG(std::string, grpc_test_use_grpclb_with_child_policy, "",
index 438f75f..cfb5a2a 100644 (file)
  *
  */
 
-#include <grpcpp/support/error_details.h>
 #include <gtest/gtest.h>
 
+#include <grpcpp/support/error_details.h>
+
 #include "src/proto/grpc/status/status.pb.h"
 #include "src/proto/grpc/testing/echo_messages.pb.h"
 #include "test/core/util/test_config.h"
index a1b275a..88ce1b7 100644 (file)
        address of the connection that each RPC is made on to stderr.
 */
 
-#include <grpcpp/support/config.h>
-
 #include <fstream>
 #include <functional>
 #include <iostream>
 
 #include "absl/flags/flag.h"
+
+#include <grpcpp/support/config.h>
+
 #include "test/cpp/util/cli_credentials.h"
 #include "test/cpp/util/grpc_tool.h"
 #include "test/cpp/util/test_config.h"
index 0175b0c..bcfbbba 100644 (file)
  *
  */
 
-#include "test/cpp/util/grpc_tool.h"
-
-#include <grpc/grpc.h>
 #include <grpc/support/port_platform.h>
-#include <grpcpp/channel.h>
-#include <grpcpp/create_channel.h>
-#include <grpcpp/grpcpp.h>
-#include <grpcpp/security/credentials.h>
-#include <grpcpp/support/string_ref.h>
+
+#include "test/cpp/util/grpc_tool.h"
 
 #include <cstdio>
 #include <fstream>
 
 #include "absl/flags/flag.h"
 #include "absl/memory/memory.h"
+
+#include <grpc/grpc.h>
+#include <grpcpp/channel.h>
+#include <grpcpp/create_channel.h>
+#include <grpcpp/grpcpp.h>
+#include <grpcpp/security/credentials.h>
+#include <grpcpp/support/string_ref.h>
+
 #include "test/cpp/util/cli_call.h"
 #include "test/cpp/util/proto_file_parser.h"
 #include "test/cpp/util/proto_reflection_descriptor_database.h"
index bc45cbf..9dec8a2 100644 (file)
 
 #include "test/cpp/util/grpc_tool.h"
 
+#include <chrono>
+#include <sstream>
+
+#include <gtest/gtest.h>
+
+#include "absl/flags/declare.h"
+#include "absl/flags/flag.h"
+
 #include <grpc/grpc.h>
 #include <grpc/support/alloc.h>
 #include <grpcpp/channel.h>
 #include <grpcpp/server.h>
 #include <grpcpp/server_builder.h>
 #include <grpcpp/server_context.h>
-#include <gtest/gtest.h>
 
-#include <chrono>
-#include <sstream>
-
-#include "absl/flags/declare.h"
-#include "absl/flags/flag.h"
 #include "src/core/lib/gpr/env.h"
 #include "src/core/lib/iomgr/load_file.h"
 #include "src/proto/grpc/testing/echo.grpc.pb.h"
@@ -42,6 +44,7 @@
 #include "test/core/util/test_config.h"
 #include "test/cpp/util/cli_credentials.h"
 #include "test/cpp/util/string_ref_helper.h"
+#include "test/cpp/util/test_config.h"
 
 #define CA_CERT_PATH "src/core/tsi/test_creds/ca.pem"
 #define SERVER_CERT_PATH "src/core/tsi/test_creds/server1.pem"
@@ -1345,6 +1348,6 @@ TEST_F(GrpcToolTest, ConfiguringDefaultServiceConfig) {
 int main(int argc, char** argv) {
   grpc::testing::TestEnvironment env(argc, argv);
   ::testing::InitGoogleTest(&argc, argv);
-  ::testing::FLAGS_gtest_death_test_style = "threadsafe";
+  GRPC_GTEST_FLAG_SET_DEATH_TEST_STYLE("threadsafe");
   return RUN_ALL_TESTS();
 }
index f1f7521..b8c9bab 100644 (file)
@@ -25,6 +25,7 @@
 
 #include <grpcpp/grpcpp.h>
 #include <grpcpp/impl/codegen/config_protobuf.h>
+
 #include "src/proto/grpc/reflection/v1alpha/reflection.grpc.pb.h"
 
 namespace grpc {
index b342d4d..9e00eee 100644 (file)
@@ -20,6 +20,7 @@
 #define GRPC_TEST_CPP_UTIL_SERVICE_DESCRIBER_H
 
 #include <grpcpp/support/config.h>
+
 #include "test/cpp/util/config_grpc_cli.h"
 
 namespace grpc {
index 25041de..d74d3f8 100644 (file)
  *
  */
 
-#include <grpc++/support/slice.h>
-#include <grpcpp/impl/grpc_library.h>
+#include <gtest/gtest.h>
 
+#include <grpc++/support/slice.h>
 #include <grpc/grpc.h>
 #include <grpc/slice.h>
-#include <gtest/gtest.h>
+#include <grpcpp/impl/grpc_library.h>
 
 #include "test/core/util/test_config.h"
 
index 8e3259b..1537e18 100644 (file)
  *
  */
 
-#include <grpcpp/support/string_ref.h>
-
 #include <string.h>
 
 #include <gtest/gtest.h>
 
+#include <grpcpp/support/string_ref.h>
+
 #include "test/core/util/test_config.h"
 
 namespace grpc {
index 094ed44..fb2b257 100644 (file)
 #ifndef GRPC_TEST_CPP_UTIL_TEST_CONFIG_H
 #define GRPC_TEST_CPP_UTIL_TEST_CONFIG_H
 
+#ifndef GRPC_GTEST_FLAG_SET_DEATH_TEST_STYLE
+#define GRPC_GTEST_FLAG_SET_DEATH_TEST_STYLE(style) \
+  ::testing::FLAGS_gtest_death_test_style = style
+#endif  // GRPC_GTEST_FLAG_SET_DEATH_TEST_STYLE
+
 namespace grpc {
 namespace testing {
 
index d7d065c..866540d 100644 (file)
@@ -19,6 +19,7 @@
 #include <vector>
 
 #include "absl/flags/parse.h"
+
 #include "test/cpp/util/test_config.h"
 
 namespace grpc {
index 6ac7798..b635e27 100644 (file)
 
 #include "test/cpp/util/test_credentials_provider.h"
 
-#include <grpc/support/log.h>
-#include <grpc/support/sync.h>
-#include <grpcpp/security/server_credentials.h>
-
 #include <cstdio>
 #include <fstream>
 #include <iostream>
 #include <unordered_map>
 
 #include "absl/flags/flag.h"
+
+#include <grpc/support/log.h>
+#include <grpc/support/sync.h>
+#include <grpcpp/security/server_credentials.h>
+
 #include "test/core/end2end/data/ssl_test_data.h"
 
 ABSL_FLAG(std::string, tls_cert_file, "",
index a64bec7..4970f4b 100644 (file)
  *
  */
 
+#include <gtest/gtest.h>
+
 #include <grpc/support/time.h>
 #include <grpcpp/support/time.h>
-#include <gtest/gtest.h>
 
 #include "test/core/util/test_config.h"
 
index 4b8b522..2408395 100755 (executable)
@@ -53,17 +53,6 @@ set(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY)
 set(CMAKE_FIND_ROOT_PATH_MODE_PACKAGE ONLY)
 EOT
 
-# Build and install absl (absl won't be installed down below)
-mkdir -p "third_party/abseil-cpp/cmake/build_arm"
-pushd "third_party/abseil-cpp/cmake/build_arm"
-cmake -DCMAKE_TOOLCHAIN_FILE=/tmp/toolchain.cmake \
-      -DCMAKE_BUILD_TYPE=Release \
-      -DCMAKE_INSTALL_PREFIX=/tmp/install \
-      -DCMAKE_POSITION_INDEPENDENT_CODE=TRUE \
-      ../..
-make -j4 install
-popd
-
 # Build and install gRPC for ARM.
 # This build will use the host architecture copies of protoc and
 # grpc_cpp_plugin that we built earlier because we installed them
@@ -84,6 +73,7 @@ mkdir -p "examples/cpp/helloworld/cmake/build_arm"
 pushd "examples/cpp/helloworld/cmake/build_arm"
 cmake -DCMAKE_TOOLCHAIN_FILE=/tmp/toolchain.cmake \
       -DCMAKE_BUILD_TYPE=Release \
+      -Dabsl_DIR=/tmp/stage/lib/cmake/absl \
       -DProtobuf_DIR=/tmp/stage/lib/cmake/protobuf \
       -DgRPC_DIR=/tmp/stage/lib/cmake/grpc \
       ../..
index b669b99..96e63b1 100755 (executable)
@@ -26,13 +26,6 @@ wget -q -O cmake-linux.sh https://github.com/Kitware/CMake/releases/download/v3.
 sh cmake-linux.sh -- --skip-license --prefix=/usr
 rm cmake-linux.sh
 
-# Install absl (absl won't be installed down below)
-mkdir -p "third_party/abseil-cpp/cmake/build"
-pushd "third_party/abseil-cpp/cmake/build"
-cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_POSITION_INDEPENDENT_CODE=TRUE ../..
-make -j4 install
-popd
-
 # Install gRPC and its dependencies
 mkdir -p "cmake/build"
 pushd "cmake/build"
@@ -40,7 +33,6 @@ cmake \
   -DCMAKE_BUILD_TYPE=Release \
   -DgRPC_INSTALL=ON \
   -DgRPC_BUILD_TESTS=OFF \
-  -DgRPC_ABSL_PROVIDER=package \
   -DgRPC_SSL_PROVIDER=package \
   ../..
 make -j4 install
index fd08da6..ab61f16 100755 (executable)
@@ -26,13 +26,6 @@ wget -q -O cmake-linux.sh https://github.com/Kitware/CMake/releases/download/v3.
 sh cmake-linux.sh -- --skip-license --prefix=/usr
 rm cmake-linux.sh
 
-# Install absl (absl won't be installed down below)
-mkdir -p "third_party/abseil-cpp/cmake/build"
-pushd "third_party/abseil-cpp/cmake/build"
-cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_POSITION_INDEPENDENT_CODE=TRUE ../..
-make -j4 install
-popd
-
 # Install gRPC and its dependencies
 mkdir -p "cmake/build"
 pushd "cmake/build"
@@ -40,7 +33,6 @@ cmake \
   -DCMAKE_BUILD_TYPE=Release \
   -DgRPC_INSTALL=ON \
   -DgRPC_BUILD_TESTS=OFF \
-  -DgRPC_ABSL_PROVIDER=package \
   -DgRPC_SSL_PROVIDER=package \
   ../..
 make -j4 install
index 907f26d..edd3dc1 100644 (file)
@@ -128,12 +128,15 @@ Since upb is vendored in the gRPC repo, you cannot use submodule to update it. P
 
 ### Updating third_party/xxhash
 
+TODO(https://github.com/Cyan4973/xxHash/issues/548): revisit LICENSE
+instructions if upstream splits library and CLI.
+
 The upstream xxhash repository contains a bunch of files that we don't want, so
 we employ a rather manual update flow to pick up just the bits we care about:
 
 ```
 git remote add xxhash https://github.com/Cyan4973/xxHash.git
 git fetch xxhash
-for file in LICENSE xxhash.h; do git show xxhash/dev:$file > third_party/xxhash/$file; done
-git commit
+git show xxhash/dev:xxhash.h > third_party/xxhash/xxhash.h
+git show xxhash/dev:LICENSE | sed -nE '/^-+$/q;p' > third_party/xxhash/LICENSE
 ```
index f7ff1dd..6d6da06 100644 (file)
@@ -5,7 +5,7 @@ index 97ac28028..8b7585d9d 100644
 @@ -31,3 +31,9 @@
  # Copyright 2007 Google Inc. All Rights Reserved.
 
- __version__ = '3.15.8'
+ __version__ = '3.17.3'
 +
 +if __name__ != '__main__':
 +  try:
index 38ca793..a754f32 100644 (file)
@@ -1,7 +1,7 @@
 ---
 tasks:
   ubuntu:
-    platform: ubuntu1604
+    platform: ubuntu1804
     test_targets:
     - //...
   macos:
index 7b9da71..bfaa00c 100644 (file)
@@ -1,3 +1,6 @@
+# temporary fix for https://github.com/bazelbuild/bazel/issues/12905 on macOS
+build --features=-debug_prefix_map_pwd_is_dot
+
 # Use our custom-configured c++ toolchain.
 
 build:m32 --copt=-m32 --linkopt=-m32
@@ -8,6 +11,8 @@ build:ubsan --copt=-fsanitize=undefined --linkopt=-fsanitize=undefined --action_
 # Workaround for the fact that Bazel links with $CC, not $CXX
 # https://github.com/bazelbuild/bazel/issues/11122#issuecomment-613746748
 build:ubsan --copt=-fno-sanitize=function --copt=-fno-sanitize=vptr
+# Workaround for https://bugs.llvm.org/show_bug.cgi?id=16404
+build:ubsan --linkopt=--rtlib=compiler-rt --linkopt=-lunwind
 
 build:Werror --copt=-Werror
 build:Werror --per_file_copt=json/parser@-Wno-error
diff --git a/third_party/upb/.github/workflows/cifuzz.yml b/third_party/upb/.github/workflows/cifuzz.yml
new file mode 100644 (file)
index 0000000..092b107
--- /dev/null
@@ -0,0 +1,29 @@
+name: CIFuzz
+on: [pull_request]
+jobs:
+ Fuzzing:
+   runs-on: ubuntu-latest
+   strategy:
+     fail-fast: false
+     matrix:
+       sanitizer: [address, undefined]
+   steps:
+   - name: Build Fuzzers (${{ matrix.sanitizer }})
+     uses: google/oss-fuzz/infra/cifuzz/actions/build_fuzzers@master
+     with:
+       oss-fuzz-project-name: 'upb'
+       dry-run: false
+       sanitizer: ${{ matrix.sanitizer }}
+   - name: Run Fuzzers (${{ matrix.sanitizer }})
+     uses: google/oss-fuzz/infra/cifuzz/actions/run_fuzzers@master
+     with:
+       oss-fuzz-project-name: 'upb'
+       fuzz-seconds: 600
+       dry-run: false
+       sanitizer: ${{ matrix.sanitizer }}
+   - name: Upload Crash
+     uses: actions/upload-artifact@v1
+     if: failure()
+     with:
+       name: ${{ matrix.sanitizer }}-artifacts
+       path: ./out/artifacts
index 2e13326..719f2b4 100644 (file)
@@ -1,3 +1,28 @@
+# Copyright (c) 2009-2021, Google LLC
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions are met:
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in the
+#       documentation and/or other materials provided with the distribution.
+#     * Neither the name of Google LLC nor the
+#       names of its contributors may be used to endorse or promote products
+#       derived from this software without specific prior written permission.
+#
+# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+# DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+# DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+# (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+# ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
 load(
     "//bazel:build_defs.bzl",
     "UPB_DEFAULT_COPTS",
@@ -11,15 +36,7 @@ load(
     "upb_proto_reflection_library",
 )
 
-# copybara:strip_for_google3_begin
-load(
-    "@rules_proto//proto:defs.bzl",
-    "proto_library",
-)
-
-# copybara:strip_end
-
-licenses(["notice"])  # BSD (Google-authored w/ possible external contributions)
+licenses(["notice"])
 
 exports_files([
     "LICENSE",
@@ -64,18 +81,19 @@ cc_library(
     name = "upb",
     srcs = [
         "upb/decode.c",
-        "upb/decode.int.h",
+        "upb/decode_internal.h",
         "upb/encode.c",
         "upb/msg.c",
-        "upb/msg.h",
+        "upb/msg_internal.h",
         "upb/table.c",
-        "upb/table.int.h",
+        "upb/table_internal.h",
         "upb/upb.c",
-        "upb/upb.int.h",
+        "upb/upb_internal.h",
     ],
     hdrs = [
         "upb/decode.h",
         "upb/encode.h",
+        "upb/msg.h",
         "upb/upb.h",
         "upb/upb.hpp",
     ],
@@ -84,18 +102,18 @@ cc_library(
     deps = [
         ":fastdecode",
         ":port",
-        "//third_party/wyhash",
     ],
 )
 
 cc_library(
     name = "fastdecode",
     srcs = [
-        "upb/decode.int.h",
+        "upb/decode_internal.h",
         "upb/decode_fast.c",
         "upb/decode_fast.h",
         "upb/msg.h",
-        "upb/upb.int.h",
+        "upb/msg_internal.h",
+        "upb/upb_internal.h",
     ],
     copts = UPB_DEFAULT_COPTS,
     deps = [
@@ -115,6 +133,7 @@ cc_library(
     hdrs = [
         "upb/decode_fast.h",
         "upb/msg.h",
+        "upb/msg_internal.h",
         "upb/port_def.inc",
         "upb/port_undef.inc",
     ],
@@ -149,6 +168,7 @@ cc_library(
         "upb/def.h",
         "upb/def.hpp",
         "upb/reflection.h",
+        "upb/reflection.hpp",
     ],
     copts = UPB_DEFAULT_COPTS,
     visibility = ["//visibility:public"],
@@ -200,7 +220,7 @@ cc_library(
 cc_library(
     name = "table",
     hdrs = [
-        "upb/table.int.h",
+        "upb/table_internal.h",
         "upb/upb.h",
     ],
     visibility = ["//tests:__pkg__"],
@@ -209,86 +229,9 @@ cc_library(
     ],
 )
 
-# Legacy C/C++ Libraries (not recommended for new code) ########################
-
-cc_library(
-    name = "handlers",
-    srcs = [
-        "upb/handlers.c",
-        "upb/handlers-inl.h",
-        "upb/sink.c",
-    ],
-    hdrs = [
-        "upb/handlers.h",
-        "upb/sink.h",
-    ],
-    copts = UPB_DEFAULT_COPTS,
-    visibility = ["//tests:__pkg__"],
-    deps = [
-        ":port",
-        ":reflection",
-        ":table",
-        ":upb",
-    ],
-)
-
-cc_library(
-    name = "upb_pb",
-    srcs = [
-        "upb/pb/compile_decoder.c",
-        "upb/pb/decoder.c",
-        "upb/pb/decoder.int.h",
-        "upb/pb/encoder.c",
-        "upb/pb/textprinter.c",
-        "upb/pb/varint.c",
-        "upb/pb/varint.int.h",
-    ],
-    hdrs = [
-        "upb/pb/decoder.h",
-        "upb/pb/encoder.h",
-        "upb/pb/textprinter.h",
-    ],
-    copts = UPB_DEFAULT_COPTS,
-    visibility = ["//tests:__pkg__"],
-    deps = [
-        ":descriptor_upb_proto",
-        ":handlers",
-        ":port",
-        ":reflection",
-        ":table",
-        ":upb",
-    ],
-)
+# Amalgamation #################################################################
 
 # copybara:strip_for_google3_begin
-cc_library(
-    name = "upb_json",
-    srcs = [
-        "upb/json/parser.c",
-        "upb/json/printer.c",
-    ],
-    hdrs = [
-        "upb/json/parser.h",
-        "upb/json/printer.h",
-    ],
-    copts = UPB_DEFAULT_COPTS,
-    visibility = ["//tests:__pkg__"],
-    deps = [
-        ":upb",
-        ":upb_pb",
-    ],
-)
-
-genrule(
-    name = "generate_json_ragel",
-    srcs = ["//:upb/json/parser.rl"],
-    outs = ["upb/json/parser.c"],
-    cmd = "$(location @ragel//:ragelc) -C -o upb/json/parser.c $< && mv upb/json/parser.c $@",
-    tools = ["@ragel//:ragelc"],
-    visibility = ["//cmake:__pkg__"],
-)
-
-# Amalgamation #################################################################
 
 py_binary(
     name = "amalgamate",
@@ -307,10 +250,7 @@ upb_amalgamation(
         ":fastdecode",
         ":descriptor_upb_proto",
         ":reflection",
-        ":handlers",
         ":port",
-        ":upb_pb",
-        ":upb_json",
     ],
 )
 
@@ -319,7 +259,6 @@ cc_library(
     srcs = ["upb.c"],
     hdrs = ["upb.h"],
     copts = UPB_DEFAULT_COPTS,
-    deps = ["//third_party/wyhash"],
 )
 
 upb_amalgamation(
@@ -346,7 +285,6 @@ cc_library(
     srcs = ["php-upb.c"],
     hdrs = ["php-upb.h"],
     copts = UPB_DEFAULT_COPTS,
-    deps = ["//third_party/wyhash"],
 )
 
 upb_amalgamation(
@@ -372,7 +310,6 @@ cc_library(
     srcs = ["ruby-upb.c"],
     hdrs = ["ruby-upb.h"],
     copts = UPB_DEFAULT_COPTS,
-    deps = ["//third_party/wyhash"],
 )
 
 exports_files(
@@ -395,9 +332,6 @@ exports_files(
 filegroup(
     name = "cmake_files",
     srcs = glob([
-        "upb/json/parser.c",
-        "CMakeLists.txt",
-        "generated_for_cmake/**/*",
         "google/**/*",
         "upbc/**/*",
         "upb/**/*",
index da93984..7f3bd16 100644 (file)
@@ -1,5 +1,5 @@
 
-Copyright (c) 2009-2011, Google Inc.
+Copyright (c) 2009-2021, Google LLC
 All rights reserved.
 
 Redistribution and use in source and binary forms, with or without
@@ -10,14 +10,14 @@ modification, are permitted provided that the following conditions are met:
     * Redistributions in binary form must reproduce the above copyright
       notice, this list of conditions and the following disclaimer in the
       documentation and/or other materials provided with the distribution.
-    * Neither the name of Google Inc. nor the names of any other
+    * Neither the name of Google LLC nor the names of any other
       contributors may be used to endorse or promote products
       derived from this software without specific prior written permission.
 
 THIS SOFTWARE IS PROVIDED BY GOOGLE INC. ``AS IS'' AND ANY EXPRESS OR IMPLIED
 WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
 MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
-EVENT SHALL GOOGLE INC. BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+EVENT SHALL GOOGLE LLC BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
 SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
 PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR
 BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER
index a08aa0e..91147ea 100644 (file)
@@ -111,16 +111,6 @@ Then in your `.c` file you can #include the generated header:
 /* Insert code that uses generated types. */
 ```
 
-## Old "handlers" interfaces
-
-This library contains several semi-deprecated interfaces (see BUILD
-file for more info about which interfaces are deprecated).  These
-deprecated interfaces are still used in some significant projects,
-such as the Ruby and PHP C bindings for protobuf in the [main protobuf
-repo](https://github.com/protocolbuffers/protobuf).  The goal is to
-migrate the Ruby/PHP bindings to use the newer, simpler interfaces
-instead.  Please do not use the old interfaces in new code.
-
 ## Lua bindings
 
 This repo has some Lua bindings for the core library.  These are
index 870ebf7..eb3c0cc 100644 (file)
@@ -18,18 +18,10 @@ http_archive(
 )
 
 http_archive(
-    name = "ragel",
-    build_file = "//bazel:ragel.BUILD",
-    sha256 = "5f156edb65d20b856d638dd9ee2dfb43285914d9aa2b6ec779dac0270cd56c3f",
-    strip_prefix = "ragel-6.10",
-    urls = ["http://www.colm.net/files/ragel/ragel-6.10.tar.gz"],
-)
-
-http_archive(
-    name = "com_google_googletest",
-    sha256 = "ff7a82736e158c077e76188232eac77913a15dac0b22508c390ab3f88e6d6d86",
-    strip_prefix = "googletest-b6cd405286ed8635ece71c72f118e659f4ade3fb",
-    urls = ["https://github.com/google/googletest/archive/b6cd405286ed8635ece71c72f118e659f4ade3fb.zip"],  # 2019-01-07
+     name = "com_google_googletest",
+     urls = ["https://github.com/google/googletest/archive/b6cd405286ed8635ece71c72f118e659f4ade3fb.zip"],  # 2019-01-07
+     strip_prefix = "googletest-b6cd405286ed8635ece71c72f118e659f4ade3fb",
+     sha256 = "ff7a82736e158c077e76188232eac77913a15dac0b22508c390ab3f88e6d6d86",
 )
 
 http_archive(
index e69de29..371dd22 100644 (file)
@@ -0,0 +1,24 @@
+# Copyright (c) 2009-2021, Google LLC
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions are met:
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in the
+#       documentation and/or other materials provided with the distribution.
+#     * Neither the name of Google LLC nor the
+#       names of its contributors may be used to endorse or promote products
+#       derived from this software without specific prior written permission.
+#
+# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+# DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+# DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+# (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+# ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
index ae41577..acd474d 100644 (file)
@@ -1,3 +1,28 @@
+# Copyright (c) 2009-2021, Google LLC
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions are met:
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in the
+#       documentation and/or other materials provided with the distribution.
+#     * Neither the name of Google LLC nor the
+#       names of its contributors may be used to endorse or promote products
+#       derived from this software without specific prior written permission.
+#
+# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+# DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+# DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+# (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+# ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
 """Internal rules for building upb."""
 
 load(":upb_proto_library.bzl", "GeneratedSrcsInfo")
index 113c71f..11755a4 100644 (file)
@@ -1,3 +1,28 @@
+# Copyright (c) 2009-2021, Google LLC
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions are met:
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in the
+#       documentation and/or other materials provided with the distribution.
+#     * Neither the name of Google LLC nor the
+#       names of its contributors may be used to endorse or promote products
+#       derived from this software without specific prior written permission.
+#
+# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+# DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+# DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+# (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+# ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
 package(
     default_visibility = ["//visibility:public"],
 )
diff --git a/third_party/upb/bazel/ragel.BUILD b/third_party/upb/bazel/ragel.BUILD
deleted file mode 100644 (file)
index 5916bea..0000000
+++ /dev/null
@@ -1,195 +0,0 @@
-package(
-    default_visibility = ["//visibility:public"],
-)
-
-cc_binary(
-    name = "ragelc",
-    srcs = [
-        "ragel/rubycodegen.cpp",
-        "ragel/goipgoto.h",
-        "ragel/cdtable.h",
-        "ragel/rubycodegen.h",
-        "ragel/gotable.h",
-        "ragel/gocodegen.cpp",
-        "ragel/rubyfflat.cpp",
-        "ragel/common.cpp",
-        "ragel/gofflat.cpp",
-        "ragel/cdtable.cpp",
-        "ragel/cdsplit.cpp",
-        "ragel/rlparse.cpp",
-        "ragel/csfgoto.cpp",
-        "ragel/javacodegen.cpp",
-        "ragel/gocodegen.h",
-        "ragel/mlgoto.cpp",
-        "ragel/fsmgraph.cpp",
-        "ragel/version.h",
-        "ragel/mlfflat.h",
-        "ragel/fsmgraph.h",
-        "ragel/fsmbase.cpp",
-        "ragel/fsmstate.cpp",
-        "ragel/gotablish.cpp",
-        "ragel/rubyflat.cpp",
-        "ragel/cdfgoto.h",
-        "ragel/cscodegen.h",
-        "ragel/mlflat.cpp",
-        "ragel/rubyflat.h",
-        "ragel/goftable.h",
-        "ragel/rbxgoto.cpp",
-        "ragel/csfflat.cpp",
-        "ragel/gofgoto.cpp",
-        "ragel/gofgoto.h",
-        "ragel/ragel.h",
-        "ragel/goftable.cpp",
-        "ragel/cdcodegen.cpp",
-        "ragel/rlparse.h",
-        "ragel/cdsplit.h",
-        "ragel/xmlcodegen.cpp",
-        "ragel/goipgoto.cpp",
-        "ragel/dotcodegen.h",
-        "ragel/gogoto.cpp",
-        "ragel/csflat.h",
-        "ragel/csfflat.h",
-        #"ragel/config.h.in",
-        "ragel/csipgoto.cpp",
-        "ragel/mltable.cpp",
-        "ragel/mlflat.h",
-        "ragel/csftable.cpp",
-        "ragel/cdgoto.h",
-        "ragel/goflat.cpp",
-        "ragel/rubyfflat.h",
-        "ragel/mlftable.h",
-        "ragel/rubyftable.h",
-        "ragel/fsmap.cpp",
-        "ragel/redfsm.cpp",
-        "ragel/goflat.h",
-        "ragel/parsetree.cpp",
-        "ragel/fsmmin.cpp",
-        "ragel/dotcodegen.cpp",
-        "ragel/redfsm.h",
-        "ragel/mlcodegen.cpp",
-        "ragel/cdfgoto.cpp",
-        "ragel/cssplit.cpp",
-        "ragel/cstable.cpp",
-        "ragel/javacodegen.h",
-        "ragel/parsedata.cpp",
-        "ragel/buffer.h",
-        "ragel/gogoto.h",
-        "ragel/csgoto.h",
-        "ragel/pcheck.h",
-        "ragel/rubyftable.cpp",
-        "ragel/csfgoto.h",
-        "ragel/common.h",
-        "ragel/cdftable.h",
-        "ragel/mlgoto.h",
-        "ragel/csgoto.cpp",
-        "ragel/cdflat.h",
-        "ragel/cdipgoto.h",
-        "ragel/cstable.h",
-        "ragel/gendata.h",
-        "ragel/cdfflat.cpp",
-        "ragel/gotable.cpp",
-        "ragel/cdcodegen.h",
-        "ragel/gendata.cpp",
-        "ragel/rubytable.h",
-        "ragel/csflat.cpp",
-        "ragel/inputdata.h",
-        "ragel/inputdata.cpp",
-        "ragel/rubytable.cpp",
-        "ragel/fsmattach.cpp",
-        "ragel/csipgoto.h",
-        "ragel/cscodegen.cpp",
-        "ragel/cdfflat.h",
-        "ragel/rbxgoto.h",
-        "ragel/xmlcodegen.h",
-        "ragel/gofflat.h",
-        "ragel/parsedata.h",
-        "ragel/mlfgoto.h",
-        "ragel/cdflat.cpp",
-        "ragel/config.h",
-        "ragel/rlscan.cpp",
-        "ragel/mlcodegen.h",
-        "ragel/mlfflat.cpp",
-        "ragel/mlftable.cpp",
-        "ragel/mltable.h",
-        "ragel/cdipgoto.cpp",
-        "ragel/cdftable.cpp",
-        "ragel/parsetree.h",
-        "ragel/rlscan.h",
-        "ragel/main.cpp",
-        "ragel/cssplit.h",
-        "ragel/mlfgoto.cpp",
-        "ragel/csftable.h",
-        "ragel/gotablish.h",
-        "ragel/cdgoto.cpp",
-        "aapl/avlmelkey.h",
-        "aapl/dlistmel.h",
-        "aapl/avliset.h",
-        "aapl/avlkeyless.h",
-        "aapl/sbstset.h",
-        "aapl/sbsttable.h",
-        "aapl/quicksort.h",
-        "aapl/avlitree.h",
-        "aapl/avlcommon.h",
-        "aapl/bstset.h",
-        "aapl/avlmel.h",
-        "aapl/insertsort.h",
-        "aapl/dlist.h",
-        "aapl/avlmap.h",
-        "aapl/mergesort.h",
-        "aapl/resize.h",
-        "aapl/bstcommon.h",
-        "aapl/bstmap.h",
-        "aapl/compare.h",
-        "aapl/svector.h",
-        "aapl/avlset.h",
-        "aapl/bsttable.h",
-        "aapl/avlikeyless.h",
-        "aapl/bubblesort.h",
-        "aapl/table.h",
-        "aapl/avlbasic.h",
-        "aapl/vector.h",
-        "aapl/avlimap.h",
-        "aapl/dlistval.h",
-        "aapl/dlcommon.h",
-        "aapl/avlibasic.h",
-        "aapl/sbstmap.h",
-        "aapl/avlimel.h",
-        "aapl/avlimelkey.h",
-        "aapl/avltree.h",
-    ],
-    includes = [
-        "aapl",
-        "ragel",
-    ],
-)
-
-config_h_contents = """
-#define PACKAGE "ragel"
-
-/* Define to the address where bug reports for this package should be sent. */
-#define PACKAGE_BUGREPORT ""
-
-/* Define to the full name of this package. */
-#define PACKAGE_NAME "ragel"
-
-/* Define to the full name and version of this package. */
-#define PACKAGE_STRING "ragel 6.10"
-
-/* Define to the one symbol short name of this package. */
-#define PACKAGE_TARNAME "ragel"
-
-/* Define to the home page for this package. */
-#define PACKAGE_URL ""
-
-/* Define to the version of this package. */
-#define PACKAGE_VERSION "6.10"
-
-/* Version number of package */
-#define VERSION "6.10"
-"""
-
-genrule(
-    name = "gen_config_h",
-    outs = ["ragel/config.h"],
-    cmd = "(cat <<'HEREDOC'\n%s\nHEREDOC\n) > $@" % config_h_contents,
-)
index 155d18d..cc02a9a 100644 (file)
@@ -1,3 +1,28 @@
+# Copyright (c) 2009-2021, Google LLC
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions are met:
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in the
+#       documentation and/or other materials provided with the distribution.
+#     * Neither the name of Google LLC nor the
+#       names of its contributors may be used to endorse or promote products
+#       derived from this software without specific prior written permission.
+#
+# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+# DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+# DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+# (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+# ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
 """Public rules for using upb protos:
   - upb_proto_library()
   - upb_proto_reflection_library()
@@ -323,6 +348,7 @@ _upb_proto_reflection_library_aspect = aspect(
         ),
         "_upbdefs": attr.label_list(
             default = [
+                "//:generated_code_support__only_for_generated_code_do_not_use__i_give_permission_to_break_me",
                 "//:upb",
                 "//:reflection",
             ],
index c724d7c..b2f9499 100644 (file)
@@ -6,16 +6,20 @@ def upb_deps():
     maybe(
         git_repository,
         name = "com_google_absl",
-        commit = "df3ea785d8c30a9503321a3d35ee7d35808f190d",  # LTS 2020-02-25
+        commit = "998805a4c79d5d7a771f7e5a8ee3cbbbcba04f94",
         remote = "https://github.com/abseil/abseil-cpp.git",
         shallow_since = "1583355457 -0500",
     )
 
     maybe(
-        git_repository,
+        http_archive,
         name = "com_google_protobuf",
-        remote = "https://github.com/protocolbuffers/protobuf.git",
-        commit = "c8f76331abf682c289fa79f05b2ee39cc7bf5a48",  # Need to use Git until proto3 optional is released
+        sha256 = "cf63d46ef743f4c30b0e36a562caf83cabed3f10e6ca49eb476913c4655394d5",
+        strip_prefix = "protobuf-3.17.3",
+        urls = [
+            "https://mirror.bazel.build/github.com/protocolbuffers/protobuf/archive/v3.17.3.tar.gz",
+            "https://github.com/protocolbuffers/protobuf/archive/v3.17.3.tar.gz",
+        ],
     )
 
     maybe(
@@ -32,8 +36,8 @@ def upb_deps():
     maybe(
         http_archive,
         name = "bazel_skylib",
-        strip_prefix = "bazel-skylib-master",
-        urls = ["https://github.com/bazelbuild/bazel-skylib/archive/master.tar.gz"],
+        strip_prefix = "bazel-skylib-main",
+        urls = ["https://github.com/bazelbuild/bazel-skylib/archive/main.tar.gz"],
     )
 
     maybe(
index 2ab830f..19966f8 100644 (file)
@@ -1,3 +1,28 @@
+# Copyright (c) 2009-2021, Google LLC
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions are met:
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in the
+#       documentation and/or other materials provided with the distribution.
+#     * Neither the name of Google LLC nor the
+#       names of its contributors may be used to endorse or promote products
+#       derived from this software without specific prior written permission.
+#
+# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+# DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+# DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+# (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+# ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
 load(
     "//bazel:upb_proto_library.bzl",
     "upb_proto_library",
index 904bdec..a8f31b2 100644 (file)
@@ -1,3 +1,28 @@
+# Copyright (c) 2009-2021, Google LLC
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions are met:
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in the
+#       documentation and/or other materials provided with the distribution.
+#     * Neither the name of Google LLC nor the
+#       names of its contributors may be used to endorse or promote products
+#       derived from this software without specific prior written permission.
+#
+# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+# DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+# DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+# (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+# ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
 load(
     "@rules_proto//proto:defs.bzl",
     "proto_library",
@@ -6,7 +31,7 @@ load(
 proto_library(
     name = "ads_proto",
     srcs = glob([
-        "google/ads/googleads/v5/**/*.proto",
+        "google/ads/googleads/v7/**/*.proto",
         "google/api/**/*.proto",
         "google/rpc/**/*.proto",
         "google/longrunning/**/*.proto",
index 7f4765a..60e3b53 100644 (file)
@@ -1,3 +1,27 @@
+// Copyright (c) 2009-2021, Google LLC
+// All rights reserved.
+//
+// Redistribution and use in source and binary forms, with or without
+// modification, are permitted provided that the following conditions are met:
+//     * Redistributions of source code must retain the above copyright
+//       notice, this list of conditions and the following disclaimer.
+//     * Redistributions in binary form must reproduce the above copyright
+//       notice, this list of conditions and the following disclaimer in the
+//       documentation and/or other materials provided with the distribution.
+//     * Neither the name of Google LLC nor the
+//       names of its contributors may be used to endorse or promote products
+//       derived from this software without specific prior written permission.
+//
+// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+// WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+// DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+// DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+// (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+// LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+// ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+// SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 
 #include <benchmark/benchmark.h>
 #include <string.h>
@@ -7,7 +31,7 @@
 #include "benchmarks/descriptor.upb.h"
 #include "benchmarks/descriptor.upbdefs.h"
 #include "benchmarks/descriptor_sv.pb.h"
-#include "google/ads/googleads/v5/services/google_ads_service.upbdefs.h"
+#include "google/ads/googleads/v7/services/google_ads_service.upbdefs.h"
 #include "google/protobuf/descriptor.pb.h"
 #include "upb/def.hpp"
 
@@ -60,7 +84,7 @@ static void BM_LoadAdsDescriptor_Upb(benchmark::State& state) {
   size_t bytes_per_iter = 0;
   for (auto _ : state) {
     upb::SymbolTable symtab;
-    google_ads_googleads_v5_services_SearchGoogleAdsRequest_getmsgdef(
+    google_ads_googleads_v7_services_SearchGoogleAdsRequest_getmsgdef(
         symtab.ptr());
     bytes_per_iter = _upb_symtab_bytesloaded(symtab.ptr());
   }
@@ -87,11 +111,11 @@ static void BM_LoadDescriptor_Proto2(benchmark::State& state) {
 BENCHMARK(BM_LoadDescriptor_Proto2);
 
 static void BM_LoadAdsDescriptor_Proto2(benchmark::State& state) {
-  extern upb_def_init google_ads_googleads_v5_services_google_ads_service_proto_upbdefinit;
+  extern upb_def_init google_ads_googleads_v7_services_google_ads_service_proto_upbdefinit;
   std::vector<upb_strview> serialized_files;
   absl::flat_hash_set<const upb_def_init*> seen_files;
   CollectFileDescriptors(
-      &google_ads_googleads_v5_services_google_ads_service_proto_upbdefinit,
+      &google_ads_googleads_v7_services_google_ads_service_proto_upbdefinit,
       serialized_files, seen_files);
   size_t bytes_per_iter = 0;
   for (auto _ : state) {
@@ -138,8 +162,8 @@ static void BM_Parse_Upb_FileDesc(benchmark::State& state) {
     }
     upb_benchmark_FileDescriptorProto* set =
         upb_benchmark_FileDescriptorProto_parse_ex(
-            descriptor.data, descriptor.size, arena,
-            Copy == Alias ? UPB_DECODE_ALIAS : 0);
+            descriptor.data, descriptor.size, NULL,
+            Copy == Alias ? UPB_DECODE_ALIAS : 0, arena);
     if (!set) {
       printf("Failed to parse.\n");
       exit(1);
index ff534fb..f95a09e 100644 (file)
@@ -1,3 +1,27 @@
+# Copyright (c) 2009-2021, Google LLC
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions are met:
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in the
+#       documentation and/or other materials provided with the distribution.
+#     * Neither the name of Google LLC nor the
+#       names of its contributors may be used to endorse or promote products
+#       derived from this software without specific prior written permission.
+#
+# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+# DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+# DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+# (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+# ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 
 # copybara:insert_for_google3_begin
 # load("//tools/build_defs/proto/cpp:cc_proto_library.bzl", _cc_proto_library="cc_proto_library")
index 8d62d94..3827221 100755 (executable)
@@ -1,4 +1,30 @@
-#!/usr/bin/env python3
+#!/usr/bin/python
+#
+# Copyright (c) 2009-2021, Google LLC
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions are met:
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in the
+#       documentation and/or other materials provided with the distribution.
+#     * Neither the name of Google LLC nor the
+#       names of its contributors may be used to endorse or promote products
+#       derived from this software without specific prior written permission.
+#
+# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+# DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+# DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+# (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+# ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
 """Benchmarks the current working directory against a given baseline.
 
 This script benchmarks both size and speed. Sample output:
@@ -58,7 +84,7 @@ def Benchmark(outbase, bench_cpu=True, runs=12, fasttable=False):
 
 
 baseline = "master"
-bench_cpu = False
+bench_cpu = True
 fasttable = False
 
 if len(sys.argv) > 1:
index 787e391..66c2df6 100644 (file)
@@ -1,3 +1,29 @@
+#!/usr/bin/python
+#
+# Copyright (c) 2009-2021, Google LLC
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions are met:
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in the
+#       documentation and/or other materials provided with the distribution.
+#     * Neither the name of Google LLC nor the
+#       names of its contributors may be used to endorse or promote products
+#       derived from this software without specific prior written permission.
+#
+# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+# DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+# DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+# (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+# ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 
 import sys
 import re
index a95deff..54003d2 100644 (file)
@@ -1,3 +1,29 @@
+#!/usr/bin/python
+#
+# Copyright (c) 2009-2021, Google LLC
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions are met:
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in the
+#       documentation and/or other materials provided with the distribution.
+#     * Neither the name of Google LLC nor the
+#       names of its contributors may be used to endorse or promote products
+#       derived from this software without specific prior written permission.
+#
+# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+# DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+# DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+# (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+# ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 
 import sys
 import random
index 4df8fd7..d5c0d1d 100644 (file)
@@ -1,3 +1,29 @@
+#!/usr/bin/python
+#
+# Copyright (c) 2009-2021, Google LLC
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions are met:
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in the
+#       documentation and/or other materials provided with the distribution.
+#     * Neither the name of Google LLC nor the
+#       names of its contributors may be used to endorse or promote products
+#       derived from this software without specific prior written permission.
+#
+# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+# DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+# DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+# (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+# ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 
 import sys
 import re
index 53fbd07..cc825c4 100644 (file)
@@ -1,3 +1,28 @@
+# Copyright (c) 2009-2021, Google LLC
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions are met:
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in the
+#       documentation and/or other materials provided with the distribution.
+#     * Neither the name of Google LLC nor the
+#       names of its contributors may be used to endorse or promote products
+#       derived from this software without specific prior written permission.
+#
+# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+# DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+# DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+# (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+# ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
 load(
     ":build_defs.bzl",
     "generated_file_staleness_test",
@@ -28,7 +53,6 @@ genrule(
         "//:BUILD",
         "//:WORKSPACE",
         "//:cmake_files",
-        "//third_party/wyhash:cmake_files",
         ":cmake_files",
     ],
     outs = ["generated-in/CMakeLists.txt"],
@@ -37,13 +61,6 @@ genrule(
 )
 
 genrule(
-    name = "copy_json_ragel",
-    srcs = ["//:upb/json/parser.c"],
-    outs = ["generated-in/upb/json/parser.c"],
-    cmd = "cp $< $@",
-)
-
-genrule(
     name = "copy_protos",
     srcs = ["//:descriptor_upb_proto"],
     outs = [
@@ -59,7 +76,6 @@ generated_file_staleness_test(
         "CMakeLists.txt",
         "google/protobuf/descriptor.upb.c",
         "google/protobuf/descriptor.upb.h",
-        "upb/json/parser.c",
     ],
     generated_pattern = "generated-in/%s",
 )
@@ -85,7 +101,6 @@ sh_test(
     data = [
         ":cmake_files",
         "//:cmake_files",
-        "//third_party/wyhash:cmake_files",
     ],
     deps = ["@bazel_tools//tools/bash/runfiles"],
 )
index d4cbcc9..879fdb6 100644 (file)
@@ -64,28 +64,29 @@ enable_testing()
 add_library(port INTERFACE)
 add_library(upb
   ../upb/decode.c
-  ../upb/decode.int.h
+  ../upb/decode_internal.h
   ../upb/encode.c
   ../upb/msg.c
-  ../upb/msg.h
+  ../upb/msg_internal.h
   ../upb/table.c
-  ../upb/table.int.h
+  ../upb/table_internal.h
   ../upb/upb.c
-  ../upb/upb.int.h
+  ../upb/upb_internal.h
   ../upb/decode.h
   ../upb/encode.h
+  ../upb/msg.h
   ../upb/upb.h
   ../upb/upb.hpp)
 target_link_libraries(upb
   fastdecode
-  port
-  /third_party/wyhash)
+  port)
 add_library(fastdecode
-  ../upb/decode.int.h
+  ../upb/decode_internal.h
   ../upb/decode_fast.c
   ../upb/decode_fast.h
   ../upb/msg.h
-  ../upb/upb.int.h)
+  ../upb/msg_internal.h
+  ../upb/upb_internal.h)
 target_link_libraries(fastdecode
   port
   table)
@@ -99,7 +100,8 @@ add_library(reflection
   ../upb/reflection.c
   ../upb/def.h
   ../upb/def.hpp
-  ../upb/reflection.h)
+  ../upb/reflection.h
+  ../upb/reflection.hpp)
 target_link_libraries(reflection
   descriptor_upb_proto
   port
@@ -123,43 +125,5 @@ target_link_libraries(json
 add_library(table INTERFACE)
 target_link_libraries(table INTERFACE
   port)
-add_library(handlers
-  ../upb/handlers.c
-  ../upb/handlers-inl.h
-  ../upb/sink.c
-  ../upb/handlers.h
-  ../upb/sink.h)
-target_link_libraries(handlers
-  port
-  reflection
-  table
-  upb)
-add_library(upb_pb
-  ../upb/pb/compile_decoder.c
-  ../upb/pb/decoder.c
-  ../upb/pb/decoder.int.h
-  ../upb/pb/encoder.c
-  ../upb/pb/textprinter.c
-  ../upb/pb/varint.c
-  ../upb/pb/varint.int.h
-  ../upb/pb/decoder.h
-  ../upb/pb/encoder.h
-  ../upb/pb/textprinter.h)
-target_link_libraries(upb_pb
-  descriptor_upb_proto
-  handlers
-  port
-  reflection
-  table
-  upb)
-add_library(upb_json
-  ../cmake/upb/json/parser.c
-  ../upb/json/printer.c
-  ../upb/json/parser.h
-  ../upb/json/printer.h)
-target_link_libraries(upb_json
-  upb
-  upb_pb)
-add_library(wyhash INTERFACE)
 
 
index 34b4537..4a6264b 100644 (file)
@@ -1,3 +1,28 @@
+# Copyright (c) 2009-2021, Google LLC
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions are met:
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in the
+#       documentation and/or other materials provided with the distribution.
+#     * Neither the name of Google LLC nor the
+#       names of its contributors may be used to endorse or promote products
+#       derived from this software without specific prior written permission.
+#
+# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+# DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+# DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+# (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+# ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
 def generated_file_staleness_test(name, outs, generated_pattern):
     """Tests that checked-in file(s) match the contents of generated file(s).
 
index 339fafa..a6b9af9 100644 (file)
@@ -7,7 +7,7 @@
  * regenerated. */
 
 #include <stddef.h>
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "google/protobuf/descriptor.upb.h"
 
 #include "upb/port_def.inc"
@@ -17,13 +17,13 @@ static const upb_msglayout *const google_protobuf_FileDescriptorSet_submsgs[1] =
 };
 
 static const upb_msglayout_field google_protobuf_FileDescriptorSet__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 11, 3},
+  {1, UPB_SIZE(0, 0), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout google_protobuf_FileDescriptorSet_msginit = {
   &google_protobuf_FileDescriptorSet_submsgs[0],
   &google_protobuf_FileDescriptorSet__fields[0],
-  UPB_SIZE(8, 8), 1, false, 255,
+  UPB_SIZE(8, 8), 1, false, 1, 255,
 };
 
 static const upb_msglayout *const google_protobuf_FileDescriptorProto_submsgs[6] = {
@@ -36,24 +36,24 @@ static const upb_msglayout *const google_protobuf_FileDescriptorProto_submsgs[6]
 };
 
 static const upb_msglayout_field google_protobuf_FileDescriptorProto__fields[12] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 12, 1},
-  {2, UPB_SIZE(12, 24), 2, 0, 12, 1},
-  {3, UPB_SIZE(36, 72), 0, 0, 12, 3},
-  {4, UPB_SIZE(40, 80), 0, 0, 11, 3},
-  {5, UPB_SIZE(44, 88), 0, 1, 11, 3},
-  {6, UPB_SIZE(48, 96), 0, 4, 11, 3},
-  {7, UPB_SIZE(52, 104), 0, 2, 11, 3},
-  {8, UPB_SIZE(28, 56), 3, 3, 11, 1},
-  {9, UPB_SIZE(32, 64), 4, 5, 11, 1},
-  {10, UPB_SIZE(56, 112), 0, 0, 5, 3},
-  {11, UPB_SIZE(60, 120), 0, 0, 5, 3},
-  {12, UPB_SIZE(20, 40), 5, 0, 12, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 12, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(12, 24), 2, 0, 12, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(36, 72), 0, 0, 12, _UPB_MODE_ARRAY},
+  {4, UPB_SIZE(40, 80), 0, 0, 11, _UPB_MODE_ARRAY},
+  {5, UPB_SIZE(44, 88), 0, 1, 11, _UPB_MODE_ARRAY},
+  {6, UPB_SIZE(48, 96), 0, 4, 11, _UPB_MODE_ARRAY},
+  {7, UPB_SIZE(52, 104), 0, 2, 11, _UPB_MODE_ARRAY},
+  {8, UPB_SIZE(28, 56), 3, 3, 11, _UPB_MODE_SCALAR},
+  {9, UPB_SIZE(32, 64), 4, 5, 11, _UPB_MODE_SCALAR},
+  {10, UPB_SIZE(56, 112), 0, 0, 5, _UPB_MODE_ARRAY},
+  {11, UPB_SIZE(60, 120), 0, 0, 5, _UPB_MODE_ARRAY},
+  {12, UPB_SIZE(20, 40), 5, 0, 12, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_protobuf_FileDescriptorProto_msginit = {
   &google_protobuf_FileDescriptorProto_submsgs[0],
   &google_protobuf_FileDescriptorProto__fields[0],
-  UPB_SIZE(64, 128), 12, false, 255,
+  UPB_SIZE(64, 128), 12, false, 12, 255,
 };
 
 static const upb_msglayout *const google_protobuf_DescriptorProto_submsgs[7] = {
@@ -67,22 +67,22 @@ static const upb_msglayout *const google_protobuf_DescriptorProto_submsgs[7] = {
 };
 
 static const upb_msglayout_field google_protobuf_DescriptorProto__fields[10] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 12, 1},
-  {2, UPB_SIZE(16, 32), 0, 4, 11, 3},
-  {3, UPB_SIZE(20, 40), 0, 0, 11, 3},
-  {4, UPB_SIZE(24, 48), 0, 3, 11, 3},
-  {5, UPB_SIZE(28, 56), 0, 1, 11, 3},
-  {6, UPB_SIZE(32, 64), 0, 4, 11, 3},
-  {7, UPB_SIZE(12, 24), 2, 5, 11, 1},
-  {8, UPB_SIZE(36, 72), 0, 6, 11, 3},
-  {9, UPB_SIZE(40, 80), 0, 2, 11, 3},
-  {10, UPB_SIZE(44, 88), 0, 0, 12, 3},
+  {1, UPB_SIZE(4, 8), 1, 0, 12, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(16, 32), 0, 4, 11, _UPB_MODE_ARRAY},
+  {3, UPB_SIZE(20, 40), 0, 0, 11, _UPB_MODE_ARRAY},
+  {4, UPB_SIZE(24, 48), 0, 3, 11, _UPB_MODE_ARRAY},
+  {5, UPB_SIZE(28, 56), 0, 1, 11, _UPB_MODE_ARRAY},
+  {6, UPB_SIZE(32, 64), 0, 4, 11, _UPB_MODE_ARRAY},
+  {7, UPB_SIZE(12, 24), 2, 5, 11, _UPB_MODE_SCALAR},
+  {8, UPB_SIZE(36, 72), 0, 6, 11, _UPB_MODE_ARRAY},
+  {9, UPB_SIZE(40, 80), 0, 2, 11, _UPB_MODE_ARRAY},
+  {10, UPB_SIZE(44, 88), 0, 0, 12, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout google_protobuf_DescriptorProto_msginit = {
   &google_protobuf_DescriptorProto_submsgs[0],
   &google_protobuf_DescriptorProto__fields[0],
-  UPB_SIZE(48, 96), 10, false, 255,
+  UPB_SIZE(48, 96), 10, false, 10, 255,
 };
 
 static const upb_msglayout *const google_protobuf_DescriptorProto_ExtensionRange_submsgs[1] = {
@@ -90,26 +90,26 @@ static const upb_msglayout *const google_protobuf_DescriptorProto_ExtensionRange
 };
 
 static const upb_msglayout_field google_protobuf_DescriptorProto_ExtensionRange__fields[3] = {
-  {1, UPB_SIZE(4, 4), 1, 0, 5, 1},
-  {2, UPB_SIZE(8, 8), 2, 0, 5, 1},
-  {3, UPB_SIZE(12, 16), 3, 0, 11, 1},
+  {1, UPB_SIZE(4, 4), 1, 0, 5, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 8), 2, 0, 5, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(12, 16), 3, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_protobuf_DescriptorProto_ExtensionRange_msginit = {
   &google_protobuf_DescriptorProto_ExtensionRange_submsgs[0],
   &google_protobuf_DescriptorProto_ExtensionRange__fields[0],
-  UPB_SIZE(16, 24), 3, false, 255,
+  UPB_SIZE(16, 24), 3, false, 3, 255,
 };
 
 static const upb_msglayout_field google_protobuf_DescriptorProto_ReservedRange__fields[2] = {
-  {1, UPB_SIZE(4, 4), 1, 0, 5, 1},
-  {2, UPB_SIZE(8, 8), 2, 0, 5, 1},
+  {1, UPB_SIZE(4, 4), 1, 0, 5, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 8), 2, 0, 5, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_protobuf_DescriptorProto_ReservedRange_msginit = {
   NULL,
   &google_protobuf_DescriptorProto_ReservedRange__fields[0],
-  UPB_SIZE(16, 16), 2, false, 255,
+  UPB_SIZE(16, 16), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const google_protobuf_ExtensionRangeOptions_submsgs[1] = {
@@ -117,13 +117,13 @@ static const upb_msglayout *const google_protobuf_ExtensionRangeOptions_submsgs[
 };
 
 static const upb_msglayout_field google_protobuf_ExtensionRangeOptions__fields[1] = {
-  {999, UPB_SIZE(0, 0), 0, 0, 11, 3},
+  {999, UPB_SIZE(0, 0), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout google_protobuf_ExtensionRangeOptions_msginit = {
   &google_protobuf_ExtensionRangeOptions_submsgs[0],
   &google_protobuf_ExtensionRangeOptions__fields[0],
-  UPB_SIZE(8, 8), 1, false, 255,
+  UPB_SIZE(8, 8), 1, false, 0, 255,
 };
 
 static const upb_msglayout *const google_protobuf_FieldDescriptorProto_submsgs[1] = {
@@ -131,23 +131,23 @@ static const upb_msglayout *const google_protobuf_FieldDescriptorProto_submsgs[1
 };
 
 static const upb_msglayout_field google_protobuf_FieldDescriptorProto__fields[11] = {
-  {1, UPB_SIZE(24, 24), 1, 0, 12, 1},
-  {2, UPB_SIZE(32, 40), 2, 0, 12, 1},
-  {3, UPB_SIZE(12, 12), 3, 0, 5, 1},
-  {4, UPB_SIZE(4, 4), 4, 0, 14, 1},
-  {5, UPB_SIZE(8, 8), 5, 0, 14, 1},
-  {6, UPB_SIZE(40, 56), 6, 0, 12, 1},
-  {7, UPB_SIZE(48, 72), 7, 0, 12, 1},
-  {8, UPB_SIZE(64, 104), 8, 0, 11, 1},
-  {9, UPB_SIZE(16, 16), 9, 0, 5, 1},
-  {10, UPB_SIZE(56, 88), 10, 0, 12, 1},
-  {17, UPB_SIZE(20, 20), 11, 0, 8, 1},
+  {1, UPB_SIZE(24, 24), 1, 0, 12, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(32, 40), 2, 0, 12, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(12, 12), 3, 0, 5, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(4, 4), 4, 0, 14, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(8, 8), 5, 0, 14, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(40, 56), 6, 0, 12, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(48, 72), 7, 0, 12, _UPB_MODE_SCALAR},
+  {8, UPB_SIZE(64, 104), 8, 0, 11, _UPB_MODE_SCALAR},
+  {9, UPB_SIZE(16, 16), 9, 0, 5, _UPB_MODE_SCALAR},
+  {10, UPB_SIZE(56, 88), 10, 0, 12, _UPB_MODE_SCALAR},
+  {17, UPB_SIZE(20, 20), 11, 0, 8, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_protobuf_FieldDescriptorProto_msginit = {
   &google_protobuf_FieldDescriptorProto_submsgs[0],
   &google_protobuf_FieldDescriptorProto__fields[0],
-  UPB_SIZE(72, 112), 11, false, 255,
+  UPB_SIZE(72, 112), 11, false, 10, 255,
 };
 
 static const upb_msglayout *const google_protobuf_OneofDescriptorProto_submsgs[1] = {
@@ -155,14 +155,14 @@ static const upb_msglayout *const google_protobuf_OneofDescriptorProto_submsgs[1
 };
 
 static const upb_msglayout_field google_protobuf_OneofDescriptorProto__fields[2] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 12, 1},
-  {2, UPB_SIZE(12, 24), 2, 0, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 12, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(12, 24), 2, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_protobuf_OneofDescriptorProto_msginit = {
   &google_protobuf_OneofDescriptorProto_submsgs[0],
   &google_protobuf_OneofDescriptorProto__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const google_protobuf_EnumDescriptorProto_submsgs[3] = {
@@ -172,28 +172,28 @@ static const upb_msglayout *const google_protobuf_EnumDescriptorProto_submsgs[3]
 };
 
 static const upb_msglayout_field google_protobuf_EnumDescriptorProto__fields[5] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 12, 1},
-  {2, UPB_SIZE(16, 32), 0, 2, 11, 3},
-  {3, UPB_SIZE(12, 24), 2, 1, 11, 1},
-  {4, UPB_SIZE(20, 40), 0, 0, 11, 3},
-  {5, UPB_SIZE(24, 48), 0, 0, 12, 3},
+  {1, UPB_SIZE(4, 8), 1, 0, 12, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(16, 32), 0, 2, 11, _UPB_MODE_ARRAY},
+  {3, UPB_SIZE(12, 24), 2, 1, 11, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(20, 40), 0, 0, 11, _UPB_MODE_ARRAY},
+  {5, UPB_SIZE(24, 48), 0, 0, 12, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout google_protobuf_EnumDescriptorProto_msginit = {
   &google_protobuf_EnumDescriptorProto_submsgs[0],
   &google_protobuf_EnumDescriptorProto__fields[0],
-  UPB_SIZE(32, 64), 5, false, 255,
+  UPB_SIZE(32, 64), 5, false, 5, 255,
 };
 
 static const upb_msglayout_field google_protobuf_EnumDescriptorProto_EnumReservedRange__fields[2] = {
-  {1, UPB_SIZE(4, 4), 1, 0, 5, 1},
-  {2, UPB_SIZE(8, 8), 2, 0, 5, 1},
+  {1, UPB_SIZE(4, 4), 1, 0, 5, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(8, 8), 2, 0, 5, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_protobuf_EnumDescriptorProto_EnumReservedRange_msginit = {
   NULL,
   &google_protobuf_EnumDescriptorProto_EnumReservedRange__fields[0],
-  UPB_SIZE(16, 16), 2, false, 255,
+  UPB_SIZE(16, 16), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const google_protobuf_EnumValueDescriptorProto_submsgs[1] = {
@@ -201,15 +201,15 @@ static const upb_msglayout *const google_protobuf_EnumValueDescriptorProto_subms
 };
 
 static const upb_msglayout_field google_protobuf_EnumValueDescriptorProto__fields[3] = {
-  {1, UPB_SIZE(8, 8), 1, 0, 12, 1},
-  {2, UPB_SIZE(4, 4), 2, 0, 5, 1},
-  {3, UPB_SIZE(16, 24), 3, 0, 11, 1},
+  {1, UPB_SIZE(8, 8), 1, 0, 12, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(4, 4), 2, 0, 5, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(16, 24), 3, 0, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_protobuf_EnumValueDescriptorProto_msginit = {
   &google_protobuf_EnumValueDescriptorProto_submsgs[0],
   &google_protobuf_EnumValueDescriptorProto__fields[0],
-  UPB_SIZE(24, 32), 3, false, 255,
+  UPB_SIZE(24, 32), 3, false, 3, 255,
 };
 
 static const upb_msglayout *const google_protobuf_ServiceDescriptorProto_submsgs[2] = {
@@ -218,15 +218,15 @@ static const upb_msglayout *const google_protobuf_ServiceDescriptorProto_submsgs
 };
 
 static const upb_msglayout_field google_protobuf_ServiceDescriptorProto__fields[3] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 12, 1},
-  {2, UPB_SIZE(16, 32), 0, 0, 11, 3},
-  {3, UPB_SIZE(12, 24), 2, 1, 11, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 12, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(16, 32), 0, 0, 11, _UPB_MODE_ARRAY},
+  {3, UPB_SIZE(12, 24), 2, 1, 11, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_protobuf_ServiceDescriptorProto_msginit = {
   &google_protobuf_ServiceDescriptorProto_submsgs[0],
   &google_protobuf_ServiceDescriptorProto__fields[0],
-  UPB_SIZE(24, 48), 3, false, 255,
+  UPB_SIZE(24, 48), 3, false, 3, 255,
 };
 
 static const upb_msglayout *const google_protobuf_MethodDescriptorProto_submsgs[1] = {
@@ -234,18 +234,18 @@ static const upb_msglayout *const google_protobuf_MethodDescriptorProto_submsgs[
 };
 
 static const upb_msglayout_field google_protobuf_MethodDescriptorProto__fields[6] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 12, 1},
-  {2, UPB_SIZE(12, 24), 2, 0, 12, 1},
-  {3, UPB_SIZE(20, 40), 3, 0, 12, 1},
-  {4, UPB_SIZE(28, 56), 4, 0, 11, 1},
-  {5, UPB_SIZE(1, 1), 5, 0, 8, 1},
-  {6, UPB_SIZE(2, 2), 6, 0, 8, 1},
+  {1, UPB_SIZE(4, 8), 1, 0, 12, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(12, 24), 2, 0, 12, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(20, 40), 3, 0, 12, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(28, 56), 4, 0, 11, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(1, 1), 5, 0, 8, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(2, 2), 6, 0, 8, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_protobuf_MethodDescriptorProto_msginit = {
   &google_protobuf_MethodDescriptorProto_submsgs[0],
   &google_protobuf_MethodDescriptorProto__fields[0],
-  UPB_SIZE(32, 64), 6, false, 255,
+  UPB_SIZE(32, 64), 6, false, 6, 255,
 };
 
 static const upb_msglayout *const google_protobuf_FileOptions_submsgs[1] = {
@@ -253,33 +253,33 @@ static const upb_msglayout *const google_protobuf_FileOptions_submsgs[1] = {
 };
 
 static const upb_msglayout_field google_protobuf_FileOptions__fields[21] = {
-  {1, UPB_SIZE(20, 24), 1, 0, 12, 1},
-  {8, UPB_SIZE(28, 40), 2, 0, 12, 1},
-  {9, UPB_SIZE(4, 4), 3, 0, 14, 1},
-  {10, UPB_SIZE(8, 8), 4, 0, 8, 1},
-  {11, UPB_SIZE(36, 56), 5, 0, 12, 1},
-  {16, UPB_SIZE(9, 9), 6, 0, 8, 1},
-  {17, UPB_SIZE(10, 10), 7, 0, 8, 1},
-  {18, UPB_SIZE(11, 11), 8, 0, 8, 1},
-  {20, UPB_SIZE(12, 12), 9, 0, 8, 1},
-  {23, UPB_SIZE(13, 13), 10, 0, 8, 1},
-  {27, UPB_SIZE(14, 14), 11, 0, 8, 1},
-  {31, UPB_SIZE(15, 15), 12, 0, 8, 1},
-  {36, UPB_SIZE(44, 72), 13, 0, 12, 1},
-  {37, UPB_SIZE(52, 88), 14, 0, 12, 1},
-  {39, UPB_SIZE(60, 104), 15, 0, 12, 1},
-  {40, UPB_SIZE(68, 120), 16, 0, 12, 1},
-  {41, UPB_SIZE(76, 136), 17, 0, 12, 1},
-  {42, UPB_SIZE(16, 16), 18, 0, 8, 1},
-  {44, UPB_SIZE(84, 152), 19, 0, 12, 1},
-  {45, UPB_SIZE(92, 168), 20, 0, 12, 1},
-  {999, UPB_SIZE(100, 184), 0, 0, 11, 3},
+  {1, UPB_SIZE(20, 24), 1, 0, 12, _UPB_MODE_SCALAR},
+  {8, UPB_SIZE(28, 40), 2, 0, 12, _UPB_MODE_SCALAR},
+  {9, UPB_SIZE(4, 4), 3, 0, 14, _UPB_MODE_SCALAR},
+  {10, UPB_SIZE(8, 8), 4, 0, 8, _UPB_MODE_SCALAR},
+  {11, UPB_SIZE(36, 56), 5, 0, 12, _UPB_MODE_SCALAR},
+  {16, UPB_SIZE(9, 9), 6, 0, 8, _UPB_MODE_SCALAR},
+  {17, UPB_SIZE(10, 10), 7, 0, 8, _UPB_MODE_SCALAR},
+  {18, UPB_SIZE(11, 11), 8, 0, 8, _UPB_MODE_SCALAR},
+  {20, UPB_SIZE(12, 12), 9, 0, 8, _UPB_MODE_SCALAR},
+  {23, UPB_SIZE(13, 13), 10, 0, 8, _UPB_MODE_SCALAR},
+  {27, UPB_SIZE(14, 14), 11, 0, 8, _UPB_MODE_SCALAR},
+  {31, UPB_SIZE(15, 15), 12, 0, 8, _UPB_MODE_SCALAR},
+  {36, UPB_SIZE(44, 72), 13, 0, 12, _UPB_MODE_SCALAR},
+  {37, UPB_SIZE(52, 88), 14, 0, 12, _UPB_MODE_SCALAR},
+  {39, UPB_SIZE(60, 104), 15, 0, 12, _UPB_MODE_SCALAR},
+  {40, UPB_SIZE(68, 120), 16, 0, 12, _UPB_MODE_SCALAR},
+  {41, UPB_SIZE(76, 136), 17, 0, 12, _UPB_MODE_SCALAR},
+  {42, UPB_SIZE(16, 16), 18, 0, 8, _UPB_MODE_SCALAR},
+  {44, UPB_SIZE(84, 152), 19, 0, 12, _UPB_MODE_SCALAR},
+  {45, UPB_SIZE(92, 168), 20, 0, 12, _UPB_MODE_SCALAR},
+  {999, UPB_SIZE(100, 184), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout google_protobuf_FileOptions_msginit = {
   &google_protobuf_FileOptions_submsgs[0],
   &google_protobuf_FileOptions__fields[0],
-  UPB_SIZE(104, 192), 21, false, 255,
+  UPB_SIZE(104, 192), 21, false, 1, 255,
 };
 
 static const upb_msglayout *const google_protobuf_MessageOptions_submsgs[1] = {
@@ -287,17 +287,17 @@ static const upb_msglayout *const google_protobuf_MessageOptions_submsgs[1] = {
 };
 
 static const upb_msglayout_field google_protobuf_MessageOptions__fields[5] = {
-  {1, UPB_SIZE(1, 1), 1, 0, 8, 1},
-  {2, UPB_SIZE(2, 2), 2, 0, 8, 1},
-  {3, UPB_SIZE(3, 3), 3, 0, 8, 1},
-  {7, UPB_SIZE(4, 4), 4, 0, 8, 1},
-  {999, UPB_SIZE(8, 8), 0, 0, 11, 3},
+  {1, UPB_SIZE(1, 1), 1, 0, 8, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(2, 2), 2, 0, 8, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(3, 3), 3, 0, 8, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(4, 4), 4, 0, 8, _UPB_MODE_SCALAR},
+  {999, UPB_SIZE(8, 8), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout google_protobuf_MessageOptions_msginit = {
   &google_protobuf_MessageOptions_submsgs[0],
   &google_protobuf_MessageOptions__fields[0],
-  UPB_SIZE(16, 16), 5, false, 255,
+  UPB_SIZE(16, 16), 5, false, 3, 255,
 };
 
 static const upb_msglayout *const google_protobuf_FieldOptions_submsgs[1] = {
@@ -305,19 +305,19 @@ static const upb_msglayout *const google_protobuf_FieldOptions_submsgs[1] = {
 };
 
 static const upb_msglayout_field google_protobuf_FieldOptions__fields[7] = {
-  {1, UPB_SIZE(4, 4), 1, 0, 14, 1},
-  {2, UPB_SIZE(12, 12), 2, 0, 8, 1},
-  {3, UPB_SIZE(13, 13), 3, 0, 8, 1},
-  {5, UPB_SIZE(14, 14), 4, 0, 8, 1},
-  {6, UPB_SIZE(8, 8), 5, 0, 14, 1},
-  {10, UPB_SIZE(15, 15), 6, 0, 8, 1},
-  {999, UPB_SIZE(16, 16), 0, 0, 11, 3},
+  {1, UPB_SIZE(4, 4), 1, 0, 14, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(12, 12), 2, 0, 8, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(13, 13), 3, 0, 8, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(14, 14), 4, 0, 8, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(8, 8), 5, 0, 14, _UPB_MODE_SCALAR},
+  {10, UPB_SIZE(15, 15), 6, 0, 8, _UPB_MODE_SCALAR},
+  {999, UPB_SIZE(16, 16), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout google_protobuf_FieldOptions_msginit = {
   &google_protobuf_FieldOptions_submsgs[0],
   &google_protobuf_FieldOptions__fields[0],
-  UPB_SIZE(24, 24), 7, false, 255,
+  UPB_SIZE(24, 24), 7, false, 3, 255,
 };
 
 static const upb_msglayout *const google_protobuf_OneofOptions_submsgs[1] = {
@@ -325,13 +325,13 @@ static const upb_msglayout *const google_protobuf_OneofOptions_submsgs[1] = {
 };
 
 static const upb_msglayout_field google_protobuf_OneofOptions__fields[1] = {
-  {999, UPB_SIZE(0, 0), 0, 0, 11, 3},
+  {999, UPB_SIZE(0, 0), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout google_protobuf_OneofOptions_msginit = {
   &google_protobuf_OneofOptions_submsgs[0],
   &google_protobuf_OneofOptions__fields[0],
-  UPB_SIZE(8, 8), 1, false, 255,
+  UPB_SIZE(8, 8), 1, false, 0, 255,
 };
 
 static const upb_msglayout *const google_protobuf_EnumOptions_submsgs[1] = {
@@ -339,15 +339,15 @@ static const upb_msglayout *const google_protobuf_EnumOptions_submsgs[1] = {
 };
 
 static const upb_msglayout_field google_protobuf_EnumOptions__fields[3] = {
-  {2, UPB_SIZE(1, 1), 1, 0, 8, 1},
-  {3, UPB_SIZE(2, 2), 2, 0, 8, 1},
-  {999, UPB_SIZE(4, 8), 0, 0, 11, 3},
+  {2, UPB_SIZE(1, 1), 1, 0, 8, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(2, 2), 2, 0, 8, _UPB_MODE_SCALAR},
+  {999, UPB_SIZE(4, 8), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout google_protobuf_EnumOptions_msginit = {
   &google_protobuf_EnumOptions_submsgs[0],
   &google_protobuf_EnumOptions__fields[0],
-  UPB_SIZE(8, 16), 3, false, 255,
+  UPB_SIZE(8, 16), 3, false, 0, 255,
 };
 
 static const upb_msglayout *const google_protobuf_EnumValueOptions_submsgs[1] = {
@@ -355,14 +355,14 @@ static const upb_msglayout *const google_protobuf_EnumValueOptions_submsgs[1] =
 };
 
 static const upb_msglayout_field google_protobuf_EnumValueOptions__fields[2] = {
-  {1, UPB_SIZE(1, 1), 1, 0, 8, 1},
-  {999, UPB_SIZE(4, 8), 0, 0, 11, 3},
+  {1, UPB_SIZE(1, 1), 1, 0, 8, _UPB_MODE_SCALAR},
+  {999, UPB_SIZE(4, 8), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout google_protobuf_EnumValueOptions_msginit = {
   &google_protobuf_EnumValueOptions_submsgs[0],
   &google_protobuf_EnumValueOptions__fields[0],
-  UPB_SIZE(8, 16), 2, false, 255,
+  UPB_SIZE(8, 16), 2, false, 1, 255,
 };
 
 static const upb_msglayout *const google_protobuf_ServiceOptions_submsgs[1] = {
@@ -370,14 +370,14 @@ static const upb_msglayout *const google_protobuf_ServiceOptions_submsgs[1] = {
 };
 
 static const upb_msglayout_field google_protobuf_ServiceOptions__fields[2] = {
-  {33, UPB_SIZE(1, 1), 1, 0, 8, 1},
-  {999, UPB_SIZE(4, 8), 0, 0, 11, 3},
+  {33, UPB_SIZE(1, 1), 1, 0, 8, _UPB_MODE_SCALAR},
+  {999, UPB_SIZE(4, 8), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout google_protobuf_ServiceOptions_msginit = {
   &google_protobuf_ServiceOptions_submsgs[0],
   &google_protobuf_ServiceOptions__fields[0],
-  UPB_SIZE(8, 16), 2, false, 255,
+  UPB_SIZE(8, 16), 2, false, 0, 255,
 };
 
 static const upb_msglayout *const google_protobuf_MethodOptions_submsgs[1] = {
@@ -385,15 +385,15 @@ static const upb_msglayout *const google_protobuf_MethodOptions_submsgs[1] = {
 };
 
 static const upb_msglayout_field google_protobuf_MethodOptions__fields[3] = {
-  {33, UPB_SIZE(8, 8), 1, 0, 8, 1},
-  {34, UPB_SIZE(4, 4), 2, 0, 14, 1},
-  {999, UPB_SIZE(12, 16), 0, 0, 11, 3},
+  {33, UPB_SIZE(8, 8), 1, 0, 8, _UPB_MODE_SCALAR},
+  {34, UPB_SIZE(4, 4), 2, 0, 14, _UPB_MODE_SCALAR},
+  {999, UPB_SIZE(12, 16), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout google_protobuf_MethodOptions_msginit = {
   &google_protobuf_MethodOptions_submsgs[0],
   &google_protobuf_MethodOptions__fields[0],
-  UPB_SIZE(16, 24), 3, false, 255,
+  UPB_SIZE(16, 24), 3, false, 0, 255,
 };
 
 static const upb_msglayout *const google_protobuf_UninterpretedOption_submsgs[1] = {
@@ -401,30 +401,30 @@ static const upb_msglayout *const google_protobuf_UninterpretedOption_submsgs[1]
 };
 
 static const upb_msglayout_field google_protobuf_UninterpretedOption__fields[7] = {
-  {2, UPB_SIZE(56, 80), 0, 0, 11, 3},
-  {3, UPB_SIZE(32, 32), 1, 0, 12, 1},
-  {4, UPB_SIZE(8, 8), 2, 0, 4, 1},
-  {5, UPB_SIZE(16, 16), 3, 0, 3, 1},
-  {6, UPB_SIZE(24, 24), 4, 0, 1, 1},
-  {7, UPB_SIZE(40, 48), 5, 0, 12, 1},
-  {8, UPB_SIZE(48, 64), 6, 0, 12, 1},
+  {2, UPB_SIZE(56, 80), 0, 0, 11, _UPB_MODE_ARRAY},
+  {3, UPB_SIZE(32, 32), 1, 0, 12, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(8, 8), 2, 0, 4, _UPB_MODE_SCALAR},
+  {5, UPB_SIZE(16, 16), 3, 0, 3, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(24, 24), 4, 0, 1, _UPB_MODE_SCALAR},
+  {7, UPB_SIZE(40, 48), 5, 0, 12, _UPB_MODE_SCALAR},
+  {8, UPB_SIZE(48, 64), 6, 0, 12, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_protobuf_UninterpretedOption_msginit = {
   &google_protobuf_UninterpretedOption_submsgs[0],
   &google_protobuf_UninterpretedOption__fields[0],
-  UPB_SIZE(64, 96), 7, false, 255,
+  UPB_SIZE(64, 96), 7, false, 0, 255,
 };
 
 static const upb_msglayout_field google_protobuf_UninterpretedOption_NamePart__fields[2] = {
-  {1, UPB_SIZE(4, 8), 1, 0, 12, 2},
-  {2, UPB_SIZE(1, 1), 2, 0, 8, 2},
+  {1, UPB_SIZE(4, 8), 1, 0, 12, _UPB_MODE_SCALAR},
+  {2, UPB_SIZE(1, 1), 2, 0, 8, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_protobuf_UninterpretedOption_NamePart_msginit = {
   NULL,
   &google_protobuf_UninterpretedOption_NamePart__fields[0],
-  UPB_SIZE(16, 32), 2, false, 255,
+  UPB_SIZE(16, 32), 2, false, 2, 255,
 };
 
 static const upb_msglayout *const google_protobuf_SourceCodeInfo_submsgs[1] = {
@@ -432,27 +432,27 @@ static const upb_msglayout *const google_protobuf_SourceCodeInfo_submsgs[1] = {
 };
 
 static const upb_msglayout_field google_protobuf_SourceCodeInfo__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 11, 3},
+  {1, UPB_SIZE(0, 0), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout google_protobuf_SourceCodeInfo_msginit = {
   &google_protobuf_SourceCodeInfo_submsgs[0],
   &google_protobuf_SourceCodeInfo__fields[0],
-  UPB_SIZE(8, 8), 1, false, 255,
+  UPB_SIZE(8, 8), 1, false, 1, 255,
 };
 
 static const upb_msglayout_field google_protobuf_SourceCodeInfo_Location__fields[5] = {
-  {1, UPB_SIZE(20, 40), 0, 0, 5, _UPB_LABEL_PACKED},
-  {2, UPB_SIZE(24, 48), 0, 0, 5, _UPB_LABEL_PACKED},
-  {3, UPB_SIZE(4, 8), 1, 0, 12, 1},
-  {4, UPB_SIZE(12, 24), 2, 0, 12, 1},
-  {6, UPB_SIZE(28, 56), 0, 0, 12, 3},
+  {1, UPB_SIZE(20, 40), 0, 0, 5, _UPB_MODE_ARRAY | _UPB_MODE_IS_PACKED},
+  {2, UPB_SIZE(24, 48), 0, 0, 5, _UPB_MODE_ARRAY | _UPB_MODE_IS_PACKED},
+  {3, UPB_SIZE(4, 8), 1, 0, 12, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(12, 24), 2, 0, 12, _UPB_MODE_SCALAR},
+  {6, UPB_SIZE(28, 56), 0, 0, 12, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout google_protobuf_SourceCodeInfo_Location_msginit = {
   NULL,
   &google_protobuf_SourceCodeInfo_Location__fields[0],
-  UPB_SIZE(32, 64), 5, false, 255,
+  UPB_SIZE(32, 64), 5, false, 4, 255,
 };
 
 static const upb_msglayout *const google_protobuf_GeneratedCodeInfo_submsgs[1] = {
@@ -460,26 +460,26 @@ static const upb_msglayout *const google_protobuf_GeneratedCodeInfo_submsgs[1] =
 };
 
 static const upb_msglayout_field google_protobuf_GeneratedCodeInfo__fields[1] = {
-  {1, UPB_SIZE(0, 0), 0, 0, 11, 3},
+  {1, UPB_SIZE(0, 0), 0, 0, 11, _UPB_MODE_ARRAY},
 };
 
 const upb_msglayout google_protobuf_GeneratedCodeInfo_msginit = {
   &google_protobuf_GeneratedCodeInfo_submsgs[0],
   &google_protobuf_GeneratedCodeInfo__fields[0],
-  UPB_SIZE(8, 8), 1, false, 255,
+  UPB_SIZE(8, 8), 1, false, 1, 255,
 };
 
 static const upb_msglayout_field google_protobuf_GeneratedCodeInfo_Annotation__fields[4] = {
-  {1, UPB_SIZE(20, 32), 0, 0, 5, _UPB_LABEL_PACKED},
-  {2, UPB_SIZE(12, 16), 1, 0, 12, 1},
-  {3, UPB_SIZE(4, 4), 2, 0, 5, 1},
-  {4, UPB_SIZE(8, 8), 3, 0, 5, 1},
+  {1, UPB_SIZE(20, 32), 0, 0, 5, _UPB_MODE_ARRAY | _UPB_MODE_IS_PACKED},
+  {2, UPB_SIZE(12, 16), 1, 0, 12, _UPB_MODE_SCALAR},
+  {3, UPB_SIZE(4, 4), 2, 0, 5, _UPB_MODE_SCALAR},
+  {4, UPB_SIZE(8, 8), 3, 0, 5, _UPB_MODE_SCALAR},
 };
 
 const upb_msglayout google_protobuf_GeneratedCodeInfo_Annotation_msginit = {
   NULL,
   &google_protobuf_GeneratedCodeInfo_Annotation__fields[0],
-  UPB_SIZE(24, 48), 4, false, 255,
+  UPB_SIZE(24, 48), 4, false, 4, 255,
 };
 
 #include "upb/port_undef.inc"
index a8ed71a..4767b3a 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef GOOGLE_PROTOBUF_DESCRIPTOR_PROTO_UPB_H_
 #define GOOGLE_PROTOBUF_DESCRIPTOR_PROTO_UPB_H_
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/decode.h"
 #include "upb/decode_fast.h"
 #include "upb/encode.h"
@@ -162,13 +162,19 @@ UPB_INLINE google_protobuf_FileDescriptorSet *google_protobuf_FileDescriptorSet_
 UPB_INLINE google_protobuf_FileDescriptorSet *google_protobuf_FileDescriptorSet_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_FileDescriptorSet *ret = google_protobuf_FileDescriptorSet_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_FileDescriptorSet_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_FileDescriptorSet_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_FileDescriptorSet *google_protobuf_FileDescriptorSet_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_FileDescriptorSet *ret = google_protobuf_FileDescriptorSet_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_FileDescriptorSet_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_FileDescriptorSet_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_FileDescriptorSet_serialize(const google_protobuf_FileDescriptorSet *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_FileDescriptorSet_msginit, arena, len);
@@ -199,13 +205,19 @@ UPB_INLINE google_protobuf_FileDescriptorProto *google_protobuf_FileDescriptorPr
 UPB_INLINE google_protobuf_FileDescriptorProto *google_protobuf_FileDescriptorProto_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_FileDescriptorProto *ret = google_protobuf_FileDescriptorProto_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_FileDescriptorProto_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_FileDescriptorProto_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_FileDescriptorProto *google_protobuf_FileDescriptorProto_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_FileDescriptorProto *ret = google_protobuf_FileDescriptorProto_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_FileDescriptorProto_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_FileDescriptorProto_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_FileDescriptorProto_serialize(const google_protobuf_FileDescriptorProto *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_FileDescriptorProto_msginit, arena, len);
@@ -362,13 +374,19 @@ UPB_INLINE google_protobuf_DescriptorProto *google_protobuf_DescriptorProto_new(
 UPB_INLINE google_protobuf_DescriptorProto *google_protobuf_DescriptorProto_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_DescriptorProto *ret = google_protobuf_DescriptorProto_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_DescriptorProto_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_DescriptorProto_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_DescriptorProto *google_protobuf_DescriptorProto_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_DescriptorProto *ret = google_protobuf_DescriptorProto_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_DescriptorProto_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_DescriptorProto_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_DescriptorProto_serialize(const google_protobuf_DescriptorProto *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_DescriptorProto_msginit, arena, len);
@@ -521,13 +539,19 @@ UPB_INLINE google_protobuf_DescriptorProto_ExtensionRange *google_protobuf_Descr
 UPB_INLINE google_protobuf_DescriptorProto_ExtensionRange *google_protobuf_DescriptorProto_ExtensionRange_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_DescriptorProto_ExtensionRange *ret = google_protobuf_DescriptorProto_ExtensionRange_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_DescriptorProto_ExtensionRange_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_DescriptorProto_ExtensionRange_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_DescriptorProto_ExtensionRange *google_protobuf_DescriptorProto_ExtensionRange_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_DescriptorProto_ExtensionRange *ret = google_protobuf_DescriptorProto_ExtensionRange_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_DescriptorProto_ExtensionRange_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_DescriptorProto_ExtensionRange_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_DescriptorProto_ExtensionRange_serialize(const google_protobuf_DescriptorProto_ExtensionRange *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_DescriptorProto_ExtensionRange_msginit, arena, len);
@@ -570,13 +594,19 @@ UPB_INLINE google_protobuf_DescriptorProto_ReservedRange *google_protobuf_Descri
 UPB_INLINE google_protobuf_DescriptorProto_ReservedRange *google_protobuf_DescriptorProto_ReservedRange_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_DescriptorProto_ReservedRange *ret = google_protobuf_DescriptorProto_ReservedRange_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_DescriptorProto_ReservedRange_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_DescriptorProto_ReservedRange_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_DescriptorProto_ReservedRange *google_protobuf_DescriptorProto_ReservedRange_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_DescriptorProto_ReservedRange *ret = google_protobuf_DescriptorProto_ReservedRange_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_DescriptorProto_ReservedRange_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_DescriptorProto_ReservedRange_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_DescriptorProto_ReservedRange_serialize(const google_protobuf_DescriptorProto_ReservedRange *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_DescriptorProto_ReservedRange_msginit, arena, len);
@@ -604,13 +634,19 @@ UPB_INLINE google_protobuf_ExtensionRangeOptions *google_protobuf_ExtensionRange
 UPB_INLINE google_protobuf_ExtensionRangeOptions *google_protobuf_ExtensionRangeOptions_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_ExtensionRangeOptions *ret = google_protobuf_ExtensionRangeOptions_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_ExtensionRangeOptions_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_ExtensionRangeOptions_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_ExtensionRangeOptions *google_protobuf_ExtensionRangeOptions_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_ExtensionRangeOptions *ret = google_protobuf_ExtensionRangeOptions_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_ExtensionRangeOptions_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_ExtensionRangeOptions_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_ExtensionRangeOptions_serialize(const google_protobuf_ExtensionRangeOptions *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_ExtensionRangeOptions_msginit, arena, len);
@@ -641,13 +677,19 @@ UPB_INLINE google_protobuf_FieldDescriptorProto *google_protobuf_FieldDescriptor
 UPB_INLINE google_protobuf_FieldDescriptorProto *google_protobuf_FieldDescriptorProto_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_FieldDescriptorProto *ret = google_protobuf_FieldDescriptorProto_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_FieldDescriptorProto_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_FieldDescriptorProto_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_FieldDescriptorProto *google_protobuf_FieldDescriptorProto_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_FieldDescriptorProto *ret = google_protobuf_FieldDescriptorProto_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_FieldDescriptorProto_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_FieldDescriptorProto_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_FieldDescriptorProto_serialize(const google_protobuf_FieldDescriptorProto *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_FieldDescriptorProto_msginit, arena, len);
@@ -738,13 +780,19 @@ UPB_INLINE google_protobuf_OneofDescriptorProto *google_protobuf_OneofDescriptor
 UPB_INLINE google_protobuf_OneofDescriptorProto *google_protobuf_OneofDescriptorProto_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_OneofDescriptorProto *ret = google_protobuf_OneofDescriptorProto_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_OneofDescriptorProto_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_OneofDescriptorProto_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_OneofDescriptorProto *google_protobuf_OneofDescriptorProto_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_OneofDescriptorProto *ret = google_protobuf_OneofDescriptorProto_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_OneofDescriptorProto_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_OneofDescriptorProto_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_OneofDescriptorProto_serialize(const google_protobuf_OneofDescriptorProto *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_OneofDescriptorProto_msginit, arena, len);
@@ -781,13 +829,19 @@ UPB_INLINE google_protobuf_EnumDescriptorProto *google_protobuf_EnumDescriptorPr
 UPB_INLINE google_protobuf_EnumDescriptorProto *google_protobuf_EnumDescriptorProto_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_EnumDescriptorProto *ret = google_protobuf_EnumDescriptorProto_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_EnumDescriptorProto_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_EnumDescriptorProto_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_EnumDescriptorProto *google_protobuf_EnumDescriptorProto_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_EnumDescriptorProto *ret = google_protobuf_EnumDescriptorProto_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_EnumDescriptorProto_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_EnumDescriptorProto_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_EnumDescriptorProto_serialize(const google_protobuf_EnumDescriptorProto *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_EnumDescriptorProto_msginit, arena, len);
@@ -865,13 +919,19 @@ UPB_INLINE google_protobuf_EnumDescriptorProto_EnumReservedRange *google_protobu
 UPB_INLINE google_protobuf_EnumDescriptorProto_EnumReservedRange *google_protobuf_EnumDescriptorProto_EnumReservedRange_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_EnumDescriptorProto_EnumReservedRange *ret = google_protobuf_EnumDescriptorProto_EnumReservedRange_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_EnumDescriptorProto_EnumReservedRange_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_EnumDescriptorProto_EnumReservedRange_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_EnumDescriptorProto_EnumReservedRange *google_protobuf_EnumDescriptorProto_EnumReservedRange_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_EnumDescriptorProto_EnumReservedRange *ret = google_protobuf_EnumDescriptorProto_EnumReservedRange_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_EnumDescriptorProto_EnumReservedRange_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_EnumDescriptorProto_EnumReservedRange_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_EnumDescriptorProto_EnumReservedRange_serialize(const google_protobuf_EnumDescriptorProto_EnumReservedRange *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_EnumDescriptorProto_EnumReservedRange_msginit, arena, len);
@@ -899,13 +959,19 @@ UPB_INLINE google_protobuf_EnumValueDescriptorProto *google_protobuf_EnumValueDe
 UPB_INLINE google_protobuf_EnumValueDescriptorProto *google_protobuf_EnumValueDescriptorProto_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_EnumValueDescriptorProto *ret = google_protobuf_EnumValueDescriptorProto_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_EnumValueDescriptorProto_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_EnumValueDescriptorProto_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_EnumValueDescriptorProto *google_protobuf_EnumValueDescriptorProto_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_EnumValueDescriptorProto *ret = google_protobuf_EnumValueDescriptorProto_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_EnumValueDescriptorProto_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_EnumValueDescriptorProto_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_EnumValueDescriptorProto_serialize(const google_protobuf_EnumValueDescriptorProto *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_EnumValueDescriptorProto_msginit, arena, len);
@@ -948,13 +1014,19 @@ UPB_INLINE google_protobuf_ServiceDescriptorProto *google_protobuf_ServiceDescri
 UPB_INLINE google_protobuf_ServiceDescriptorProto *google_protobuf_ServiceDescriptorProto_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_ServiceDescriptorProto *ret = google_protobuf_ServiceDescriptorProto_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_ServiceDescriptorProto_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_ServiceDescriptorProto_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_ServiceDescriptorProto *google_protobuf_ServiceDescriptorProto_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_ServiceDescriptorProto *ret = google_protobuf_ServiceDescriptorProto_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_ServiceDescriptorProto_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_ServiceDescriptorProto_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_ServiceDescriptorProto_serialize(const google_protobuf_ServiceDescriptorProto *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_ServiceDescriptorProto_msginit, arena, len);
@@ -1006,13 +1078,19 @@ UPB_INLINE google_protobuf_MethodDescriptorProto *google_protobuf_MethodDescript
 UPB_INLINE google_protobuf_MethodDescriptorProto *google_protobuf_MethodDescriptorProto_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_MethodDescriptorProto *ret = google_protobuf_MethodDescriptorProto_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_MethodDescriptorProto_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_MethodDescriptorProto_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_MethodDescriptorProto *google_protobuf_MethodDescriptorProto_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_MethodDescriptorProto *ret = google_protobuf_MethodDescriptorProto_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_MethodDescriptorProto_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_MethodDescriptorProto_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_MethodDescriptorProto_serialize(const google_protobuf_MethodDescriptorProto *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_MethodDescriptorProto_msginit, arena, len);
@@ -1073,13 +1151,19 @@ UPB_INLINE google_protobuf_FileOptions *google_protobuf_FileOptions_new(upb_aren
 UPB_INLINE google_protobuf_FileOptions *google_protobuf_FileOptions_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_FileOptions *ret = google_protobuf_FileOptions_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_FileOptions_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_FileOptions_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_FileOptions *google_protobuf_FileOptions_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_FileOptions *ret = google_protobuf_FileOptions_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_FileOptions_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_FileOptions_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_FileOptions_serialize(const google_protobuf_FileOptions *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_FileOptions_msginit, arena, len);
@@ -1230,13 +1314,19 @@ UPB_INLINE google_protobuf_MessageOptions *google_protobuf_MessageOptions_new(up
 UPB_INLINE google_protobuf_MessageOptions *google_protobuf_MessageOptions_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_MessageOptions *ret = google_protobuf_MessageOptions_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_MessageOptions_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_MessageOptions_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_MessageOptions *google_protobuf_MessageOptions_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_MessageOptions *ret = google_protobuf_MessageOptions_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_MessageOptions_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_MessageOptions_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_MessageOptions_serialize(const google_protobuf_MessageOptions *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_MessageOptions_msginit, arena, len);
@@ -1291,13 +1381,19 @@ UPB_INLINE google_protobuf_FieldOptions *google_protobuf_FieldOptions_new(upb_ar
 UPB_INLINE google_protobuf_FieldOptions *google_protobuf_FieldOptions_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_FieldOptions *ret = google_protobuf_FieldOptions_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_FieldOptions_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_FieldOptions_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_FieldOptions *google_protobuf_FieldOptions_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_FieldOptions *ret = google_protobuf_FieldOptions_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_FieldOptions_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_FieldOptions_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_FieldOptions_serialize(const google_protobuf_FieldOptions *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_FieldOptions_msginit, arena, len);
@@ -1364,13 +1460,19 @@ UPB_INLINE google_protobuf_OneofOptions *google_protobuf_OneofOptions_new(upb_ar
 UPB_INLINE google_protobuf_OneofOptions *google_protobuf_OneofOptions_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_OneofOptions *ret = google_protobuf_OneofOptions_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_OneofOptions_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_OneofOptions_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_OneofOptions *google_protobuf_OneofOptions_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_OneofOptions *ret = google_protobuf_OneofOptions_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_OneofOptions_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_OneofOptions_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_OneofOptions_serialize(const google_protobuf_OneofOptions *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_OneofOptions_msginit, arena, len);
@@ -1401,13 +1503,19 @@ UPB_INLINE google_protobuf_EnumOptions *google_protobuf_EnumOptions_new(upb_aren
 UPB_INLINE google_protobuf_EnumOptions *google_protobuf_EnumOptions_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_EnumOptions *ret = google_protobuf_EnumOptions_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_EnumOptions_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_EnumOptions_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_EnumOptions *google_protobuf_EnumOptions_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_EnumOptions *ret = google_protobuf_EnumOptions_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_EnumOptions_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_EnumOptions_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_EnumOptions_serialize(const google_protobuf_EnumOptions *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_EnumOptions_msginit, arena, len);
@@ -1450,13 +1558,19 @@ UPB_INLINE google_protobuf_EnumValueOptions *google_protobuf_EnumValueOptions_ne
 UPB_INLINE google_protobuf_EnumValueOptions *google_protobuf_EnumValueOptions_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_EnumValueOptions *ret = google_protobuf_EnumValueOptions_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_EnumValueOptions_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_EnumValueOptions_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_EnumValueOptions *google_protobuf_EnumValueOptions_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_EnumValueOptions *ret = google_protobuf_EnumValueOptions_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_EnumValueOptions_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_EnumValueOptions_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_EnumValueOptions_serialize(const google_protobuf_EnumValueOptions *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_EnumValueOptions_msginit, arena, len);
@@ -1493,13 +1607,19 @@ UPB_INLINE google_protobuf_ServiceOptions *google_protobuf_ServiceOptions_new(up
 UPB_INLINE google_protobuf_ServiceOptions *google_protobuf_ServiceOptions_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_ServiceOptions *ret = google_protobuf_ServiceOptions_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_ServiceOptions_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_ServiceOptions_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_ServiceOptions *google_protobuf_ServiceOptions_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_ServiceOptions *ret = google_protobuf_ServiceOptions_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_ServiceOptions_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_ServiceOptions_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_ServiceOptions_serialize(const google_protobuf_ServiceOptions *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_ServiceOptions_msginit, arena, len);
@@ -1536,13 +1656,19 @@ UPB_INLINE google_protobuf_MethodOptions *google_protobuf_MethodOptions_new(upb_
 UPB_INLINE google_protobuf_MethodOptions *google_protobuf_MethodOptions_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_MethodOptions *ret = google_protobuf_MethodOptions_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_MethodOptions_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_MethodOptions_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_MethodOptions *google_protobuf_MethodOptions_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_MethodOptions *ret = google_protobuf_MethodOptions_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_MethodOptions_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_MethodOptions_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_MethodOptions_serialize(const google_protobuf_MethodOptions *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_MethodOptions_msginit, arena, len);
@@ -1585,13 +1711,19 @@ UPB_INLINE google_protobuf_UninterpretedOption *google_protobuf_UninterpretedOpt
 UPB_INLINE google_protobuf_UninterpretedOption *google_protobuf_UninterpretedOption_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_UninterpretedOption *ret = google_protobuf_UninterpretedOption_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_UninterpretedOption_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_UninterpretedOption_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_UninterpretedOption *google_protobuf_UninterpretedOption_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_UninterpretedOption *ret = google_protobuf_UninterpretedOption_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_UninterpretedOption_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_UninterpretedOption_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_UninterpretedOption_serialize(const google_protobuf_UninterpretedOption *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_UninterpretedOption_msginit, arena, len);
@@ -1658,13 +1790,19 @@ UPB_INLINE google_protobuf_UninterpretedOption_NamePart *google_protobuf_Uninter
 UPB_INLINE google_protobuf_UninterpretedOption_NamePart *google_protobuf_UninterpretedOption_NamePart_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_UninterpretedOption_NamePart *ret = google_protobuf_UninterpretedOption_NamePart_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_UninterpretedOption_NamePart_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_UninterpretedOption_NamePart_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_UninterpretedOption_NamePart *google_protobuf_UninterpretedOption_NamePart_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_UninterpretedOption_NamePart *ret = google_protobuf_UninterpretedOption_NamePart_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_UninterpretedOption_NamePart_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_UninterpretedOption_NamePart_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_UninterpretedOption_NamePart_serialize(const google_protobuf_UninterpretedOption_NamePart *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_UninterpretedOption_NamePart_msginit, arena, len);
@@ -1692,13 +1830,19 @@ UPB_INLINE google_protobuf_SourceCodeInfo *google_protobuf_SourceCodeInfo_new(up
 UPB_INLINE google_protobuf_SourceCodeInfo *google_protobuf_SourceCodeInfo_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_SourceCodeInfo *ret = google_protobuf_SourceCodeInfo_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_SourceCodeInfo_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_SourceCodeInfo_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_SourceCodeInfo *google_protobuf_SourceCodeInfo_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_SourceCodeInfo *ret = google_protobuf_SourceCodeInfo_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_SourceCodeInfo_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_SourceCodeInfo_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_SourceCodeInfo_serialize(const google_protobuf_SourceCodeInfo *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_SourceCodeInfo_msginit, arena, len);
@@ -1729,13 +1873,19 @@ UPB_INLINE google_protobuf_SourceCodeInfo_Location *google_protobuf_SourceCodeIn
 UPB_INLINE google_protobuf_SourceCodeInfo_Location *google_protobuf_SourceCodeInfo_Location_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_SourceCodeInfo_Location *ret = google_protobuf_SourceCodeInfo_Location_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_SourceCodeInfo_Location_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_SourceCodeInfo_Location_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_SourceCodeInfo_Location *google_protobuf_SourceCodeInfo_Location_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_SourceCodeInfo_Location *ret = google_protobuf_SourceCodeInfo_Location_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_SourceCodeInfo_Location_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_SourceCodeInfo_Location_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_SourceCodeInfo_Location_serialize(const google_protobuf_SourceCodeInfo_Location *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_SourceCodeInfo_Location_msginit, arena, len);
@@ -1796,13 +1946,19 @@ UPB_INLINE google_protobuf_GeneratedCodeInfo *google_protobuf_GeneratedCodeInfo_
 UPB_INLINE google_protobuf_GeneratedCodeInfo *google_protobuf_GeneratedCodeInfo_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_GeneratedCodeInfo *ret = google_protobuf_GeneratedCodeInfo_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_GeneratedCodeInfo_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_GeneratedCodeInfo_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_GeneratedCodeInfo *google_protobuf_GeneratedCodeInfo_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_GeneratedCodeInfo *ret = google_protobuf_GeneratedCodeInfo_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_GeneratedCodeInfo_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_GeneratedCodeInfo_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_GeneratedCodeInfo_serialize(const google_protobuf_GeneratedCodeInfo *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_GeneratedCodeInfo_msginit, arena, len);
@@ -1833,13 +1989,19 @@ UPB_INLINE google_protobuf_GeneratedCodeInfo_Annotation *google_protobuf_Generat
 UPB_INLINE google_protobuf_GeneratedCodeInfo_Annotation *google_protobuf_GeneratedCodeInfo_Annotation_parse(const char *buf, size_t size,
                         upb_arena *arena) {
   google_protobuf_GeneratedCodeInfo_Annotation *ret = google_protobuf_GeneratedCodeInfo_Annotation_new(arena);
-  return (ret && upb_decode(buf, size, ret, &google_protobuf_GeneratedCodeInfo_Annotation_msginit, arena)) ? ret : NULL;
+  if (!ret) return NULL;
+  if (!upb_decode(buf, size, ret, &google_protobuf_GeneratedCodeInfo_Annotation_msginit, arena)) return NULL;
+  return ret;
 }
 UPB_INLINE google_protobuf_GeneratedCodeInfo_Annotation *google_protobuf_GeneratedCodeInfo_Annotation_parse_ex(const char *buf, size_t size,
-                           upb_arena *arena, int options) {
+                           const upb_extreg *extreg, int options,
+                           upb_arena *arena) {
   google_protobuf_GeneratedCodeInfo_Annotation *ret = google_protobuf_GeneratedCodeInfo_Annotation_new(arena);
-  return (ret && _upb_decode(buf, size, ret, &google_protobuf_GeneratedCodeInfo_Annotation_msginit, arena, options))
-      ? ret : NULL;
+  if (!ret) return NULL;
+  if (!_upb_decode(buf, size, ret, &google_protobuf_GeneratedCodeInfo_Annotation_msginit, extreg, options, arena)) {
+    return NULL;
+  }
+  return ret;
 }
 UPB_INLINE char *google_protobuf_GeneratedCodeInfo_Annotation_serialize(const google_protobuf_GeneratedCodeInfo_Annotation *msg, upb_arena *arena, size_t *len) {
   return upb_encode(msg, &google_protobuf_GeneratedCodeInfo_Annotation_msginit, arena, len);
index 035debb..415f937 100755 (executable)
@@ -1,4 +1,29 @@
-#!/usr/bin/env python
+#!/usr/bin/python
+#
+# Copyright (c) 2009-2021, Google LLC
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions are met:
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in the
+#       documentation and/or other materials provided with the distribution.
+#     * Neither the name of Google LLC nor the
+#       names of its contributors may be used to endorse or promote products
+#       derived from this software without specific prior written permission.
+#
+# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+# DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+# DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+# (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+# ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 
 """TODO(haberman): DO NOT SUBMIT without one-line documentation for make_cmakelists.
 
@@ -283,7 +308,6 @@ globs = GetDict(converter)
 
 exec(open("WORKSPACE").read(), GetDict(WorkspaceFileFunctions(converter)))
 exec(open("BUILD").read(), GetDict(BuildFileFunctions(converter)))
-exec(open("third_party/wyhash/BUILD").read(), GetDict(BuildFileFunctions(converter)))
 
 with open(sys.argv[1], "w") as f:
   f.write(converter.convert())
index 5857307..58f1833 100644 (file)
@@ -1,3 +1,30 @@
+#!/usr/bin/python
+#
+# Copyright (c) 2009-2021, Google LLC
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions are met:
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in the
+#       documentation and/or other materials provided with the distribution.
+#     * Neither the name of Google LLC nor the
+#       names of its contributors may be used to endorse or promote products
+#       derived from this software without specific prior written permission.
+#
+# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+# DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+# DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+# (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+# ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
 """The py_test() script for generated_file_staleness_test() rules.
 
 Note that this file is preprocessed!  The INSERT_<...> text below is replaced
index cdfcc0d..0748969 100644 (file)
@@ -1,3 +1,30 @@
+#!/usr/bin/python
+#
+# Copyright (c) 2009-2021, Google LLC
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions are met:
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in the
+#       documentation and/or other materials provided with the distribution.
+#     * Neither the name of Google LLC nor the
+#       names of its contributors may be used to endorse or promote products
+#       derived from this software without specific prior written permission.
+#
+# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+# DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+# DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+# (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+# ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
 """Shared code for validating generated_file_staleness_test() rules.
 
 This code is used by test scripts generated from
diff --git a/third_party/upb/cmake/upb/json/parser.c b/third_party/upb/cmake/upb/json/parser.c
deleted file mode 100644 (file)
index 26996d8..0000000
+++ /dev/null
@@ -1,3433 +0,0 @@
-
-#line 1 "upb/json/parser.rl"
-/*
-** upb::json::Parser (upb_json_parser)
-**
-** A parser that uses the Ragel State Machine Compiler to generate
-** the finite automata.
-**
-** Ragel only natively handles regular languages, but we can manually
-** program it a bit to handle context-free languages like JSON, by using
-** the "fcall" and "fret" constructs.
-**
-** This parser can handle the basics, but needs several things to be fleshed
-** out:
-**
-** - handling of unicode escape sequences (including high surrogate pairs).
-** - properly check and report errors for unknown fields, stack overflow,
-**   improper array nesting (or lack of nesting).
-** - handling of base64 sequences with padding characters.
-** - handling of push-back (non-success returns from sink functions).
-** - handling of keys/escape-sequences/etc that span input buffers.
-*/
-
-#include <ctype.h>
-#include <errno.h>
-#include <float.h>
-#include <math.h>
-#include <stdint.h>
-#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
-
-#include <time.h>
-
-#include "upb/json/parser.h"
-#include "upb/pb/encoder.h"
-
-#include "upb/port_def.inc"
-
-#define UPB_JSON_MAX_DEPTH 64
-
-/* Type of value message */
-enum {
-  VALUE_NULLVALUE   = 0,
-  VALUE_NUMBERVALUE = 1,
-  VALUE_STRINGVALUE = 2,
-  VALUE_BOOLVALUE   = 3,
-  VALUE_STRUCTVALUE = 4,
-  VALUE_LISTVALUE   = 5
-};
-
-/* Forward declare */
-static bool is_top_level(upb_json_parser *p);
-static bool is_wellknown_msg(upb_json_parser *p, upb_wellknowntype_t type);
-static bool is_wellknown_field(upb_json_parser *p, upb_wellknowntype_t type);
-
-static bool is_number_wrapper_object(upb_json_parser *p);
-static bool does_number_wrapper_start(upb_json_parser *p);
-static bool does_number_wrapper_end(upb_json_parser *p);
-
-static bool is_string_wrapper_object(upb_json_parser *p);
-static bool does_string_wrapper_start(upb_json_parser *p);
-static bool does_string_wrapper_end(upb_json_parser *p);
-
-static bool does_fieldmask_start(upb_json_parser *p);
-static bool does_fieldmask_end(upb_json_parser *p);
-static void start_fieldmask_object(upb_json_parser *p);
-static void end_fieldmask_object(upb_json_parser *p);
-
-static void start_wrapper_object(upb_json_parser *p);
-static void end_wrapper_object(upb_json_parser *p);
-
-static void start_value_object(upb_json_parser *p, int value_type);
-static void end_value_object(upb_json_parser *p);
-
-static void start_listvalue_object(upb_json_parser *p);
-static void end_listvalue_object(upb_json_parser *p);
-
-static void start_structvalue_object(upb_json_parser *p);
-static void end_structvalue_object(upb_json_parser *p);
-
-static void start_object(upb_json_parser *p);
-static void end_object(upb_json_parser *p);
-
-static void start_any_object(upb_json_parser *p, const char *ptr);
-static bool end_any_object(upb_json_parser *p, const char *ptr);
-
-static bool start_subobject(upb_json_parser *p);
-static void end_subobject(upb_json_parser *p);
-
-static void start_member(upb_json_parser *p);
-static void end_member(upb_json_parser *p);
-static bool end_membername(upb_json_parser *p);
-
-static void start_any_member(upb_json_parser *p, const char *ptr);
-static void end_any_member(upb_json_parser *p, const char *ptr);
-static bool end_any_membername(upb_json_parser *p);
-
-size_t parse(void *closure, const void *hd, const char *buf, size_t size,
-             const upb_bufhandle *handle);
-static bool end(void *closure, const void *hd);
-
-static const char eof_ch = 'e';
-
-/* stringsink */
-typedef struct {
-  upb_byteshandler handler;
-  upb_bytessink sink;
-  char *ptr;
-  size_t len, size;
-} upb_stringsink;
-
-
-static void *stringsink_start(void *_sink, const void *hd, size_t size_hint) {
-  upb_stringsink *sink = _sink;
-  sink->len = 0;
-  UPB_UNUSED(hd);
-  UPB_UNUSED(size_hint);
-  return sink;
-}
-
-static size_t stringsink_string(void *_sink, const void *hd, const char *ptr,
-                                size_t len, const upb_bufhandle *handle) {
-  upb_stringsink *sink = _sink;
-  size_t new_size = sink->size;
-
-  UPB_UNUSED(hd);
-  UPB_UNUSED(handle);
-
-  while (sink->len + len > new_size) {
-    new_size *= 2;
-  }
-
-  if (new_size != sink->size) {
-    sink->ptr = realloc(sink->ptr, new_size);
-    sink->size = new_size;
-  }
-
-  memcpy(sink->ptr + sink->len, ptr, len);
-  sink->len += len;
-
-  return len;
-}
-
-void upb_stringsink_init(upb_stringsink *sink) {
-  upb_byteshandler_init(&sink->handler);
-  upb_byteshandler_setstartstr(&sink->handler, stringsink_start, NULL);
-  upb_byteshandler_setstring(&sink->handler, stringsink_string, NULL);
-
-  upb_bytessink_reset(&sink->sink, &sink->handler, sink);
-
-  sink->size = 32;
-  sink->ptr = malloc(sink->size);
-  sink->len = 0;
-}
-
-void upb_stringsink_uninit(upb_stringsink *sink) { free(sink->ptr); }
-
-typedef struct {
-  /* For encoding Any value field in binary format. */
-  upb_handlercache *encoder_handlercache;
-  upb_stringsink stringsink;
-
-  /* For decoding Any value field in json format. */
-  upb_json_codecache *parser_codecache;
-  upb_sink sink;
-  upb_json_parser *parser;
-
-  /* Mark the range of uninterpreted values in json input before type url. */
-  const char *before_type_url_start;
-  const char *before_type_url_end;
-
-  /* Mark the range of uninterpreted values in json input after type url. */
-  const char *after_type_url_start;
-} upb_jsonparser_any_frame;
-
-typedef struct {
-  upb_sink sink;
-
-  /* The current message in which we're parsing, and the field whose value we're
-   * expecting next. */
-  const upb_msgdef *m;
-  const upb_fielddef *f;
-
-  /* The table mapping json name to fielddef for this message. */
-  const upb_strtable *name_table;
-
-  /* We are in a repeated-field context. We need this flag to decide whether to
-   * handle the array as a normal repeated field or a
-   * google.protobuf.ListValue/google.protobuf.Value. */
-  bool is_repeated;
-
-  /* We are in a repeated-field context, ready to emit mapentries as
-   * submessages. This flag alters the start-of-object (open-brace) behavior to
-   * begin a sequence of mapentry messages rather than a single submessage. */
-  bool is_map;
-
-  /* We are in a map-entry message context. This flag is set when parsing the
-   * value field of a single map entry and indicates to all value-field parsers
-   * (subobjects, strings, numbers, and bools) that the map-entry submessage
-   * should end as soon as the value is parsed. */
-  bool is_mapentry;
-
-  /* If |is_map| or |is_mapentry| is true, |mapfield| refers to the parent
-   * message's map field that we're currently parsing. This differs from |f|
-   * because |f| is the field in the *current* message (i.e., the map-entry
-   * message itself), not the parent's field that leads to this map. */
-  const upb_fielddef *mapfield;
-
-  /* We are in an Any message context. This flag is set when parsing the Any
-   * message and indicates to all field parsers (subobjects, strings, numbers,
-   * and bools) that the parsed field should be serialized as binary data or
-   * cached (type url not found yet). */
-  bool is_any;
-
-  /* The type of packed message in Any. */
-  upb_jsonparser_any_frame *any_frame;
-
-  /* True if the field to be parsed is unknown. */
-  bool is_unknown_field;
-} upb_jsonparser_frame;
-
-static void init_frame(upb_jsonparser_frame* frame) {
-  frame->m = NULL;
-  frame->f = NULL;
-  frame->name_table = NULL;
-  frame->is_repeated = false;
-  frame->is_map = false;
-  frame->is_mapentry = false;
-  frame->mapfield = NULL;
-  frame->is_any = false;
-  frame->any_frame = NULL;
-  frame->is_unknown_field = false;
-}
-
-struct upb_json_parser {
-  upb_arena *arena;
-  const upb_json_parsermethod *method;
-  upb_bytessink input_;
-
-  /* Stack to track the JSON scopes we are in. */
-  upb_jsonparser_frame stack[UPB_JSON_MAX_DEPTH];
-  upb_jsonparser_frame *top;
-  upb_jsonparser_frame *limit;
-
-  upb_status *status;
-
-  /* Ragel's internal parsing stack for the parsing state machine. */
-  int current_state;
-  int parser_stack[UPB_JSON_MAX_DEPTH];
-  int parser_top;
-
-  /* The handle for the current buffer. */
-  const upb_bufhandle *handle;
-
-  /* Accumulate buffer.  See details in parser.rl. */
-  const char *accumulated;
-  size_t accumulated_len;
-  char *accumulate_buf;
-  size_t accumulate_buf_size;
-
-  /* Multi-part text data.  See details in parser.rl. */
-  int multipart_state;
-  upb_selector_t string_selector;
-
-  /* Input capture.  See details in parser.rl. */
-  const char *capture;
-
-  /* Intermediate result of parsing a unicode escape sequence. */
-  uint32_t digit;
-
-  /* For resolve type url in Any. */
-  const upb_symtab *symtab;
-
-  /* Whether to proceed if unknown field is met. */
-  bool ignore_json_unknown;
-
-  /* Cache for parsing timestamp due to base and zone are handled in different
-   * handlers. */
-  struct tm tm;
-};
-
-static upb_jsonparser_frame* start_jsonparser_frame(upb_json_parser *p) {
-  upb_jsonparser_frame *inner;
-  inner = p->top + 1;
-  init_frame(inner);
-  return inner;
-}
-
-struct upb_json_codecache {
-  upb_arena *arena;
-  upb_inttable methods;   /* upb_msgdef* -> upb_json_parsermethod* */
-};
-
-struct upb_json_parsermethod {
-  const upb_json_codecache *cache;
-  upb_byteshandler input_handler_;
-
-  /* Maps json_name -> fielddef */
-  upb_strtable name_table;
-};
-
-#define PARSER_CHECK_RETURN(x) if (!(x)) return false
-
-static upb_jsonparser_any_frame *json_parser_any_frame_new(
-    upb_json_parser *p) {
-  upb_jsonparser_any_frame *frame;
-
-  frame = upb_arena_malloc(p->arena, sizeof(upb_jsonparser_any_frame));
-
-  frame->encoder_handlercache = upb_pb_encoder_newcache();
-  frame->parser_codecache = upb_json_codecache_new();
-  frame->parser = NULL;
-  frame->before_type_url_start = NULL;
-  frame->before_type_url_end = NULL;
-  frame->after_type_url_start = NULL;
-
-  upb_stringsink_init(&frame->stringsink);
-
-  return frame;
-}
-
-static void json_parser_any_frame_set_payload_type(
-    upb_json_parser *p,
-    upb_jsonparser_any_frame *frame,
-    const upb_msgdef *payload_type) {
-  const upb_handlers *h;
-  const upb_json_parsermethod *parser_method;
-  upb_pb_encoder *encoder;
-
-  /* Initialize encoder. */
-  h = upb_handlercache_get(frame->encoder_handlercache, payload_type);
-  encoder = upb_pb_encoder_create(p->arena, h, frame->stringsink.sink);
-
-  /* Initialize parser. */
-  parser_method = upb_json_codecache_get(frame->parser_codecache, payload_type);
-  upb_sink_reset(&frame->sink, h, encoder);
-  frame->parser =
-      upb_json_parser_create(p->arena, parser_method, p->symtab, frame->sink,
-                             p->status, p->ignore_json_unknown);
-}
-
-static void json_parser_any_frame_free(upb_jsonparser_any_frame *frame) {
-  upb_handlercache_free(frame->encoder_handlercache);
-  upb_json_codecache_free(frame->parser_codecache);
-  upb_stringsink_uninit(&frame->stringsink);
-}
-
-static bool json_parser_any_frame_has_type_url(
-  upb_jsonparser_any_frame *frame) {
-  return frame->parser != NULL;
-}
-
-static bool json_parser_any_frame_has_value_before_type_url(
-  upb_jsonparser_any_frame *frame) {
-  return frame->before_type_url_start != frame->before_type_url_end;
-}
-
-static bool json_parser_any_frame_has_value_after_type_url(
-  upb_jsonparser_any_frame *frame) {
-  return frame->after_type_url_start != NULL;
-}
-
-static bool json_parser_any_frame_has_value(
-  upb_jsonparser_any_frame *frame) {
-  return json_parser_any_frame_has_value_before_type_url(frame) ||
-         json_parser_any_frame_has_value_after_type_url(frame);
-}
-
-static void json_parser_any_frame_set_before_type_url_end(
-    upb_jsonparser_any_frame *frame,
-    const char *ptr) {
-  if (frame->parser == NULL) {
-    frame->before_type_url_end = ptr;
-  }
-}
-
-static void json_parser_any_frame_set_after_type_url_start_once(
-    upb_jsonparser_any_frame *frame,
-    const char *ptr) {
-  if (json_parser_any_frame_has_type_url(frame) &&
-      frame->after_type_url_start == NULL) {
-    frame->after_type_url_start = ptr;
-  }
-}
-
-/* Used to signal that a capture has been suspended. */
-static char suspend_capture;
-
-static upb_selector_t getsel_for_handlertype(upb_json_parser *p,
-                                             upb_handlertype_t type) {
-  upb_selector_t sel;
-  bool ok = upb_handlers_getselector(p->top->f, type, &sel);
-  UPB_ASSUME(ok);
-  return sel;
-}
-
-static upb_selector_t parser_getsel(upb_json_parser *p) {
-  return getsel_for_handlertype(
-      p, upb_handlers_getprimitivehandlertype(p->top->f));
-}
-
-static bool check_stack(upb_json_parser *p) {
-  if ((p->top + 1) == p->limit) {
-    upb_status_seterrmsg(p->status, "Nesting too deep");
-    return false;
-  }
-
-  return true;
-}
-
-static void set_name_table(upb_json_parser *p, upb_jsonparser_frame *frame) {
-  upb_value v;
-  const upb_json_codecache *cache = p->method->cache;
-  bool ok;
-  const upb_json_parsermethod *method;
-
-  ok = upb_inttable_lookupptr(&cache->methods, frame->m, &v);
-  UPB_ASSUME(ok);
-  method = upb_value_getconstptr(v);
-
-  frame->name_table = &method->name_table;
-}
-
-/* There are GCC/Clang built-ins for overflow checking which we could start
- * using if there was any performance benefit to it. */
-
-static bool checked_add(size_t a, size_t b, size_t *c) {
-  if (SIZE_MAX - a < b) return false;
-  *c = a + b;
-  return true;
-}
-
-static size_t saturating_multiply(size_t a, size_t b) {
-  /* size_t is unsigned, so this is defined behavior even on overflow. */
-  size_t ret = a * b;
-  if (b != 0 && ret / b != a) {
-    ret = SIZE_MAX;
-  }
-  return ret;
-}
-
-
-/* Base64 decoding ************************************************************/
-
-/* TODO(haberman): make this streaming. */
-
-static const signed char b64table[] = {
-  -1,      -1,      -1,      -1,      -1,      -1,      -1,      -1,
-  -1,      -1,      -1,      -1,      -1,      -1,      -1,      -1,
-  -1,      -1,      -1,      -1,      -1,      -1,      -1,      -1,
-  -1,      -1,      -1,      -1,      -1,      -1,      -1,      -1,
-  -1,      -1,      -1,      -1,      -1,      -1,      -1,      -1,
-  -1,      -1,      -1,      62/*+*/, -1,      -1,      -1,      63/*/ */,
-  52/*0*/, 53/*1*/, 54/*2*/, 55/*3*/, 56/*4*/, 57/*5*/, 58/*6*/, 59/*7*/,
-  60/*8*/, 61/*9*/, -1,      -1,      -1,      -1,      -1,      -1,
-  -1,       0/*A*/,  1/*B*/,  2/*C*/,  3/*D*/,  4/*E*/,  5/*F*/,  6/*G*/,
-  07/*H*/,  8/*I*/,  9/*J*/, 10/*K*/, 11/*L*/, 12/*M*/, 13/*N*/, 14/*O*/,
-  15/*P*/, 16/*Q*/, 17/*R*/, 18/*S*/, 19/*T*/, 20/*U*/, 21/*V*/, 22/*W*/,
-  23/*X*/, 24/*Y*/, 25/*Z*/, -1,      -1,      -1,      -1,      -1,
-  -1,      26/*a*/, 27/*b*/, 28/*c*/, 29/*d*/, 30/*e*/, 31/*f*/, 32/*g*/,
-  33/*h*/, 34/*i*/, 35/*j*/, 36/*k*/, 37/*l*/, 38/*m*/, 39/*n*/, 40/*o*/,
-  41/*p*/, 42/*q*/, 43/*r*/, 44/*s*/, 45/*t*/, 46/*u*/, 47/*v*/, 48/*w*/,
-  49/*x*/, 50/*y*/, 51/*z*/, -1,      -1,      -1,      -1,      -1,
-  -1,      -1,      -1,      -1,      -1,      -1,      -1,      -1,
-  -1,      -1,      -1,      -1,      -1,      -1,      -1,      -1,
-  -1,      -1,      -1,      -1,      -1,      -1,      -1,      -1,
-  -1,      -1,      -1,      -1,      -1,      -1,      -1,      -1,
-  -1,      -1,      -1,      -1,      -1,      -1,      -1,      -1,
-  -1,      -1,      -1,      -1,      -1,      -1,      -1,      -1,
-  -1,      -1,      -1,      -1,      -1,      -1,      -1,      -1,
-  -1,      -1,      -1,      -1,      -1,      -1,      -1,      -1,
-  -1,      -1,      -1,      -1,      -1,      -1,      -1,      -1,
-  -1,      -1,      -1,      -1,      -1,      -1,      -1,      -1,
-  -1,      -1,      -1,      -1,      -1,      -1,      -1,      -1,
-  -1,      -1,      -1,      -1,      -1,      -1,      -1,      -1,
-  -1,      -1,      -1,      -1,      -1,      -1,      -1,      -1,
-  -1,      -1,      -1,      -1,      -1,      -1,      -1,      -1,
-  -1,      -1,      -1,      -1,      -1,      -1,      -1,      -1,
-  -1,      -1,      -1,      -1,      -1,      -1,      -1,      -1
-};
-
-/* Returns the table value sign-extended to 32 bits.  Knowing that the upper
- * bits will be 1 for unrecognized characters makes it easier to check for
- * this error condition later (see below). */
-int32_t b64lookup(unsigned char ch) { return b64table[ch]; }
-
-/* Returns true if the given character is not a valid base64 character or
- * padding. */
-bool nonbase64(unsigned char ch) { return b64lookup(ch) == -1 && ch != '='; }
-
-static bool base64_push(upb_json_parser *p, upb_selector_t sel, const char *ptr,
-                        size_t len) {
-  const char *limit = ptr + len;
-  for (; ptr < limit; ptr += 4) {
-    uint32_t val;
-    char output[3];
-
-    if (limit - ptr < 4) {
-      upb_status_seterrf(p->status,
-                         "Base64 input for bytes field not a multiple of 4: %s",
-                         upb_fielddef_name(p->top->f));
-      return false;
-    }
-
-    val = b64lookup(ptr[0]) << 18 |
-          b64lookup(ptr[1]) << 12 |
-          b64lookup(ptr[2]) << 6  |
-          b64lookup(ptr[3]);
-
-    /* Test the upper bit; returns true if any of the characters returned -1. */
-    if (val & 0x80000000) {
-      goto otherchar;
-    }
-
-    output[0] = val >> 16;
-    output[1] = (val >> 8) & 0xff;
-    output[2] = val & 0xff;
-    upb_sink_putstring(p->top->sink, sel, output, 3, NULL);
-  }
-  return true;
-
-otherchar:
-  if (nonbase64(ptr[0]) || nonbase64(ptr[1]) || nonbase64(ptr[2]) ||
-      nonbase64(ptr[3]) ) {
-    upb_status_seterrf(p->status,
-                       "Non-base64 characters in bytes field: %s",
-                       upb_fielddef_name(p->top->f));
-    return false;
-  } if (ptr[2] == '=') {
-    uint32_t val;
-    char output;
-
-    /* Last group contains only two input bytes, one output byte. */
-    if (ptr[0] == '=' || ptr[1] == '=' || ptr[3] != '=') {
-      goto badpadding;
-    }
-
-    val = b64lookup(ptr[0]) << 18 |
-          b64lookup(ptr[1]) << 12;
-
-    UPB_ASSERT(!(val & 0x80000000));
-    output = val >> 16;
-    upb_sink_putstring(p->top->sink, sel, &output, 1, NULL);
-    return true;
-  } else {
-    uint32_t val;
-    char output[2];
-
-    /* Last group contains only three input bytes, two output bytes. */
-    if (ptr[0] == '=' || ptr[1] == '=' || ptr[2] == '=') {
-      goto badpadding;
-    }
-
-    val = b64lookup(ptr[0]) << 18 |
-          b64lookup(ptr[1]) << 12 |
-          b64lookup(ptr[2]) << 6;
-
-    output[0] = val >> 16;
-    output[1] = (val >> 8) & 0xff;
-    upb_sink_putstring(p->top->sink, sel, output, 2, NULL);
-    return true;
-  }
-
-badpadding:
-  upb_status_seterrf(p->status,
-                     "Incorrect base64 padding for field: %s (%.*s)",
-                     upb_fielddef_name(p->top->f),
-                     4, ptr);
-  return false;
-}
-
-
-/* Accumulate buffer **********************************************************/
-
-/* Functionality for accumulating a buffer.
- *
- * Some parts of the parser need an entire value as a contiguous string.  For
- * example, to look up a member name in a hash table, or to turn a string into
- * a number, the relevant library routines need the input string to be in
- * contiguous memory, even if the value spanned two or more buffers in the
- * input.  These routines handle that.
- *
- * In the common case we can just point to the input buffer to get this
- * contiguous string and avoid any actual copy.  So we optimistically begin
- * this way.  But there are a few cases where we must instead copy into a
- * separate buffer:
- *
- *   1. The string was not contiguous in the input (it spanned buffers).
- *
- *   2. The string included escape sequences that need to be interpreted to get
- *      the true value in a contiguous buffer. */
-
-static void assert_accumulate_empty(upb_json_parser *p) {
-  UPB_ASSERT(p->accumulated == NULL);
-  UPB_ASSERT(p->accumulated_len == 0);
-}
-
-static void accumulate_clear(upb_json_parser *p) {
-  p->accumulated = NULL;
-  p->accumulated_len = 0;
-}
-
-/* Used internally by accumulate_append(). */
-static bool accumulate_realloc(upb_json_parser *p, size_t need) {
-  void *mem;
-  size_t old_size = p->accumulate_buf_size;
-  size_t new_size = UPB_MAX(old_size, 128);
-  while (new_size < need) {
-    new_size = saturating_multiply(new_size, 2);
-  }
-
-  mem = upb_arena_realloc(p->arena, p->accumulate_buf, old_size, new_size);
-  if (!mem) {
-    upb_status_seterrmsg(p->status, "Out of memory allocating buffer.");
-    return false;
-  }
-
-  p->accumulate_buf = mem;
-  p->accumulate_buf_size = new_size;
-  return true;
-}
-
-/* Logically appends the given data to the append buffer.
- * If "can_alias" is true, we will try to avoid actually copying, but the buffer
- * must be valid until the next accumulate_append() call (if any). */
-static bool accumulate_append(upb_json_parser *p, const char *buf, size_t len,
-                              bool can_alias) {
-  size_t need;
-
-  if (!p->accumulated && can_alias) {
-    p->accumulated = buf;
-    p->accumulated_len = len;
-    return true;
-  }
-
-  if (!checked_add(p->accumulated_len, len, &need)) {
-    upb_status_seterrmsg(p->status, "Integer overflow.");
-    return false;
-  }
-
-  if (need > p->accumulate_buf_size && !accumulate_realloc(p, need)) {
-    return false;
-  }
-
-  if (p->accumulated != p->accumulate_buf) {
-    if (p->accumulated_len) {
-      memcpy(p->accumulate_buf, p->accumulated, p->accumulated_len);
-    }
-    p->accumulated = p->accumulate_buf;
-  }
-
-  memcpy(p->accumulate_buf + p->accumulated_len, buf, len);
-  p->accumulated_len += len;
-  return true;
-}
-
-/* Returns a pointer to the data accumulated since the last accumulate_clear()
- * call, and writes the length to *len.  This with point either to the input
- * buffer or a temporary accumulate buffer. */
-static const char *accumulate_getptr(upb_json_parser *p, size_t *len) {
-  UPB_ASSERT(p->accumulated);
-  *len = p->accumulated_len;
-  return p->accumulated;
-}
-
-
-/* Mult-part text data ********************************************************/
-
-/* When we have text data in the input, it can often come in multiple segments.
- * For example, there may be some raw string data followed by an escape
- * sequence.  The two segments are processed with different logic.  Also buffer
- * seams in the input can cause multiple segments.
- *
- * As we see segments, there are two main cases for how we want to process them:
- *
- *  1. we want to push the captured input directly to string handlers.
- *
- *  2. we need to accumulate all the parts into a contiguous buffer for further
- *     processing (field name lookup, string->number conversion, etc). */
-
-/* This is the set of states for p->multipart_state. */
-enum {
-  /* We are not currently processing multipart data. */
-  MULTIPART_INACTIVE = 0,
-
-  /* We are processing multipart data by accumulating it into a contiguous
-   * buffer. */
-  MULTIPART_ACCUMULATE = 1,
-
-  /* We are processing multipart data by pushing each part directly to the
-   * current string handlers. */
-  MULTIPART_PUSHEAGERLY = 2
-};
-
-/* Start a multi-part text value where we accumulate the data for processing at
- * the end. */
-static void multipart_startaccum(upb_json_parser *p) {
-  assert_accumulate_empty(p);
-  UPB_ASSERT(p->multipart_state == MULTIPART_INACTIVE);
-  p->multipart_state = MULTIPART_ACCUMULATE;
-}
-
-/* Start a multi-part text value where we immediately push text data to a string
- * value with the given selector. */
-static void multipart_start(upb_json_parser *p, upb_selector_t sel) {
-  assert_accumulate_empty(p);
-  UPB_ASSERT(p->multipart_state == MULTIPART_INACTIVE);
-  p->multipart_state = MULTIPART_PUSHEAGERLY;
-  p->string_selector = sel;
-}
-
-static bool multipart_text(upb_json_parser *p, const char *buf, size_t len,
-                           bool can_alias) {
-  switch (p->multipart_state) {
-    case MULTIPART_INACTIVE:
-      upb_status_seterrmsg(
-          p->status, "Internal error: unexpected state MULTIPART_INACTIVE");
-      return false;
-
-    case MULTIPART_ACCUMULATE:
-      if (!accumulate_append(p, buf, len, can_alias)) {
-        return false;
-      }
-      break;
-
-    case MULTIPART_PUSHEAGERLY: {
-      const upb_bufhandle *handle = can_alias ? p->handle : NULL;
-      upb_sink_putstring(p->top->sink, p->string_selector, buf, len, handle);
-      break;
-    }
-  }
-
-  return true;
-}
-
-/* Note: this invalidates the accumulate buffer!  Call only after reading its
- * contents. */
-static void multipart_end(upb_json_parser *p) {
-  /* This is false sometimes. Probably a bug of some sort, but this code is
-   * intended for deletion soon. */
-  /* UPB_ASSERT(p->multipart_state != MULTIPART_INACTIVE); */
-  p->multipart_state = MULTIPART_INACTIVE;
-  accumulate_clear(p);
-}
-
-
-/* Input capture **************************************************************/
-
-/* Functionality for capturing a region of the input as text.  Gracefully
- * handles the case where a buffer seam occurs in the middle of the captured
- * region. */
-
-static void capture_begin(upb_json_parser *p, const char *ptr) {
-  UPB_ASSERT(p->multipart_state != MULTIPART_INACTIVE);
-  UPB_ASSERT(p->capture == NULL);
-  p->capture = ptr;
-}
-
-static bool capture_end(upb_json_parser *p, const char *ptr) {
-  UPB_ASSERT(p->capture);
-  if (multipart_text(p, p->capture, ptr - p->capture, true)) {
-    p->capture = NULL;
-    return true;
-  } else {
-    return false;
-  }
-}
-
-/* This is called at the end of each input buffer (ie. when we have hit a
- * buffer seam).  If we are in the middle of capturing the input, this
- * processes the unprocessed capture region. */
-static void capture_suspend(upb_json_parser *p, const char **ptr) {
-  if (!p->capture) return;
-
-  if (multipart_text(p, p->capture, *ptr - p->capture, false)) {
-    /* We use this as a signal that we were in the middle of capturing, and
-     * that capturing should resume at the beginning of the next buffer.
-     * 
-     * We can't use *ptr here, because we have no guarantee that this pointer
-     * will be valid when we resume (if the underlying memory is freed, then
-     * using the pointer at all, even to compare to NULL, is likely undefined
-     * behavior). */
-    p->capture = &suspend_capture;
-  } else {
-    /* Need to back up the pointer to the beginning of the capture, since
-     * we were not able to actually preserve it. */
-    *ptr = p->capture;
-  }
-}
-
-static void capture_resume(upb_json_parser *p, const char *ptr) {
-  if (p->capture) {
-    UPB_ASSERT(p->capture == &suspend_capture);
-    p->capture = ptr;
-  }
-}
-
-
-/* Callbacks from the parser **************************************************/
-
-/* These are the functions called directly from the parser itself.
- * We define these in the same order as their declarations in the parser. */
-
-static char escape_char(char in) {
-  switch (in) {
-    case 'r': return '\r';
-    case 't': return '\t';
-    case 'n': return '\n';
-    case 'f': return '\f';
-    case 'b': return '\b';
-    case '/': return '/';
-    case '"': return '"';
-    case '\\': return '\\';
-    default:
-      UPB_ASSERT(0);
-      return 'x';
-  }
-}
-
-static bool escape(upb_json_parser *p, const char *ptr) {
-  char ch = escape_char(*ptr);
-  return multipart_text(p, &ch, 1, false);
-}
-
-static void start_hex(upb_json_parser *p) {
-  p->digit = 0;
-}
-
-static void hexdigit(upb_json_parser *p, const char *ptr) {
-  char ch = *ptr;
-
-  p->digit <<= 4;
-
-  if (ch >= '0' && ch <= '9') {
-    p->digit += (ch - '0');
-  } else if (ch >= 'a' && ch <= 'f') {
-    p->digit += ((ch - 'a') + 10);
-  } else {
-    UPB_ASSERT(ch >= 'A' && ch <= 'F');
-    p->digit += ((ch - 'A') + 10);
-  }
-}
-
-static bool end_hex(upb_json_parser *p) {
-  uint32_t codepoint = p->digit;
-
-  /* emit the codepoint as UTF-8. */
-  char utf8[3]; /* support \u0000 -- \uFFFF -- need only three bytes. */
-  int length = 0;
-  if (codepoint <= 0x7F) {
-    utf8[0] = codepoint;
-    length = 1;
-  } else if (codepoint <= 0x07FF) {
-    utf8[1] = (codepoint & 0x3F) | 0x80;
-    codepoint >>= 6;
-    utf8[0] = (codepoint & 0x1F) | 0xC0;
-    length = 2;
-  } else /* codepoint <= 0xFFFF */ {
-    utf8[2] = (codepoint & 0x3F) | 0x80;
-    codepoint >>= 6;
-    utf8[1] = (codepoint & 0x3F) | 0x80;
-    codepoint >>= 6;
-    utf8[0] = (codepoint & 0x0F) | 0xE0;
-    length = 3;
-  }
-  /* TODO(haberman): Handle high surrogates: if codepoint is a high surrogate
-   * we have to wait for the next escape to get the full code point). */
-
-  return multipart_text(p, utf8, length, false);
-}
-
-static void start_text(upb_json_parser *p, const char *ptr) {
-  capture_begin(p, ptr);
-}
-
-static bool end_text(upb_json_parser *p, const char *ptr) {
-  return capture_end(p, ptr);
-}
-
-static bool start_number(upb_json_parser *p, const char *ptr) {
-  if (is_top_level(p)) {
-    if (is_number_wrapper_object(p)) {
-      start_wrapper_object(p);
-    } else if (is_wellknown_msg(p, UPB_WELLKNOWN_VALUE)) {
-      start_value_object(p, VALUE_NUMBERVALUE);
-    } else {
-      return false;
-    }
-  } else if (does_number_wrapper_start(p)) {
-    if (!start_subobject(p)) {
-      return false;
-    }
-    start_wrapper_object(p);
-  } else if (is_wellknown_field(p, UPB_WELLKNOWN_VALUE)) {
-    if (!start_subobject(p)) {
-      return false;
-    }
-    start_value_object(p, VALUE_NUMBERVALUE);
-  }
-
-  multipart_startaccum(p);
-  capture_begin(p, ptr);
-  return true;
-}
-
-static bool parse_number(upb_json_parser *p, bool is_quoted);
-
-static bool end_number_nontop(upb_json_parser *p, const char *ptr) {
-  if (!capture_end(p, ptr)) {
-    return false;
-  }
-
-  if (p->top->f == NULL) {
-    multipart_end(p);
-    return true;
-  }
-
-  return parse_number(p, false);
-}
-
-static bool end_number(upb_json_parser *p, const char *ptr) {
-  if (!end_number_nontop(p, ptr)) {
-    return false;
-  }
-
-  if (does_number_wrapper_end(p)) {
-    end_wrapper_object(p);
-    if (!is_top_level(p)) {
-      end_subobject(p);
-    }
-    return true;
-  }
-
-  if (is_wellknown_msg(p, UPB_WELLKNOWN_VALUE)) {
-    end_value_object(p);
-    if (!is_top_level(p)) {
-      end_subobject(p);
-    }
-    return true;
-  }
-
-  return true;
-}
-
-/* |buf| is NULL-terminated. |buf| itself will never include quotes;
- * |is_quoted| tells us whether this text originally appeared inside quotes. */
-static bool parse_number_from_buffer(upb_json_parser *p, const char *buf,
-                                     bool is_quoted) {
-  size_t len = strlen(buf);
-  const char *bufend = buf + len;
-  char *end;
-  upb_fieldtype_t type = upb_fielddef_type(p->top->f);
-  double val;
-  double dummy;
-  double inf = INFINITY;
-
-  errno = 0;
-
-  if (len == 0 || buf[0] == ' ') {
-    return false;
-  }
-
-  /* For integer types, first try parsing with integer-specific routines.
-   * If these succeed, they will be more accurate for int64/uint64 than
-   * strtod().
-   */
-  switch (type) {
-    case UPB_TYPE_ENUM:
-    case UPB_TYPE_INT32: {
-      long val = strtol(buf, &end, 0);
-      if (errno == ERANGE || end != bufend) {
-        break;
-      } else if (val > INT32_MAX || val < INT32_MIN) {
-        return false;
-      } else {
-        upb_sink_putint32(p->top->sink, parser_getsel(p), (int32_t)val);
-        return true;
-      }
-      UPB_UNREACHABLE();
-    }
-    case UPB_TYPE_UINT32: {
-      unsigned long val = strtoul(buf, &end, 0);
-      if (end != bufend) {
-        break;
-      } else if (val > UINT32_MAX || errno == ERANGE) {
-        return false;
-      } else {
-        upb_sink_putuint32(p->top->sink, parser_getsel(p), (uint32_t)val);
-        return true;
-      }
-      UPB_UNREACHABLE();
-    }
-    /* XXX: We can't handle [u]int64 properly on 32-bit machines because
-     * strto[u]ll isn't in C89. */
-    case UPB_TYPE_INT64: {
-      long val = strtol(buf, &end, 0);
-      if (errno == ERANGE || end != bufend) {
-        break;
-      } else {
-        upb_sink_putint64(p->top->sink, parser_getsel(p), val);
-        return true;
-      }
-      UPB_UNREACHABLE();
-    }
-    case UPB_TYPE_UINT64: {
-      unsigned long val = strtoul(p->accumulated, &end, 0);
-      if (end != bufend) {
-        break;
-      } else if (errno == ERANGE) {
-        return false;
-      } else {
-        upb_sink_putuint64(p->top->sink, parser_getsel(p), val);
-        return true;
-      }
-      UPB_UNREACHABLE();
-    }
-    default:
-      break;
-  }
-
-  if (type != UPB_TYPE_DOUBLE && type != UPB_TYPE_FLOAT && is_quoted) {
-    /* Quoted numbers for integer types are not allowed to be in double form. */
-    return false;
-  }
-
-  if (len == strlen("Infinity") && strcmp(buf, "Infinity") == 0) {
-    /* C89 does not have an INFINITY macro. */
-    val = inf;
-  } else if (len == strlen("-Infinity") && strcmp(buf, "-Infinity") == 0) {
-    val = -inf;
-  } else {
-    val = strtod(buf, &end);
-    if (errno == ERANGE || end != bufend) {
-      return false;
-    }
-  }
-
-  switch (type) {
-#define CASE(capitaltype, smalltype, ctype, min, max)                     \
-    case UPB_TYPE_ ## capitaltype: {                                      \
-      if (modf(val, &dummy) != 0 || val > max || val < min) {             \
-        return false;                                                     \
-      } else {                                                            \
-        upb_sink_put ## smalltype(p->top->sink, parser_getsel(p),        \
-                                  (ctype)val);                            \
-        return true;                                                      \
-      }                                                                   \
-      break;                                                              \
-    }
-    case UPB_TYPE_ENUM:
-    CASE(INT32, int32, int32_t, INT32_MIN, INT32_MAX);
-    CASE(INT64, int64, int64_t, INT64_MIN, INT64_MAX);
-    CASE(UINT32, uint32, uint32_t, 0, UINT32_MAX);
-    CASE(UINT64, uint64, uint64_t, 0, UINT64_MAX);
-#undef CASE
-
-    case UPB_TYPE_DOUBLE:
-      upb_sink_putdouble(p->top->sink, parser_getsel(p), val);
-      return true;
-    case UPB_TYPE_FLOAT:
-      if ((val > FLT_MAX || val < -FLT_MAX) && val != inf && val != -inf) {
-        return false;
-      } else {
-        upb_sink_putfloat(p->top->sink, parser_getsel(p), val);
-        return true;
-      }
-    default:
-      return false;
-  }
-}
-
-static bool parse_number(upb_json_parser *p, bool is_quoted) {
-  size_t len;
-  const char *buf;
-
-  /* strtol() and friends unfortunately do not support specifying the length of
-   * the input string, so we need to force a copy into a NULL-terminated buffer. */
-  if (!multipart_text(p, "\0", 1, false)) {
-    return false;
-  }
-
-  buf = accumulate_getptr(p, &len);
-
-  if (parse_number_from_buffer(p, buf, is_quoted)) {
-    multipart_end(p);
-    return true;
-  } else {
-    upb_status_seterrf(p->status, "error parsing number: %s", buf);
-    multipart_end(p);
-    return false;
-  }
-}
-
-static bool parser_putbool(upb_json_parser *p, bool val) {
-  bool ok;
-
-  if (p->top->f == NULL) {
-    return true;
-  }
-
-  if (upb_fielddef_type(p->top->f) != UPB_TYPE_BOOL) {
-    upb_status_seterrf(p->status,
-                       "Boolean value specified for non-bool field: %s",
-                       upb_fielddef_name(p->top->f));
-    return false;
-  }
-
-  ok = upb_sink_putbool(p->top->sink, parser_getsel(p), val);
-  UPB_ASSERT(ok);
-
-  return true;
-}
-
-static bool end_bool(upb_json_parser *p, bool val) {
-  if (is_top_level(p)) {
-    if (is_wellknown_msg(p, UPB_WELLKNOWN_BOOLVALUE)) {
-      start_wrapper_object(p);
-    } else if (is_wellknown_msg(p, UPB_WELLKNOWN_VALUE)) {
-      start_value_object(p, VALUE_BOOLVALUE);
-    } else {
-      return false;
-    }
-  } else if (is_wellknown_field(p, UPB_WELLKNOWN_BOOLVALUE)) {
-    if (!start_subobject(p)) {
-      return false;
-    }
-    start_wrapper_object(p);
-  } else if (is_wellknown_field(p, UPB_WELLKNOWN_VALUE)) {
-    if (!start_subobject(p)) {
-      return false;
-    }
-    start_value_object(p, VALUE_BOOLVALUE);
-  }
-
-  if (p->top->is_unknown_field) {
-    return true;
-  }
-
-  if (!parser_putbool(p, val)) {
-    return false;
-  }
-
-  if (is_wellknown_msg(p, UPB_WELLKNOWN_BOOLVALUE)) {
-    end_wrapper_object(p);
-    if (!is_top_level(p)) {
-      end_subobject(p);
-    }
-    return true;
-  }
-
-  if (is_wellknown_msg(p, UPB_WELLKNOWN_VALUE)) {
-    end_value_object(p);
-    if (!is_top_level(p)) {
-      end_subobject(p);
-    }
-    return true;
-  }
-
-  return true;
-}
-
-static bool end_null(upb_json_parser *p) {
-  const char *zero_ptr = "0";
-
-  if (is_top_level(p)) {
-    if (is_wellknown_msg(p, UPB_WELLKNOWN_VALUE)) {
-      start_value_object(p, VALUE_NULLVALUE);
-    } else {
-      return true;
-    }
-  } else if (is_wellknown_field(p, UPB_WELLKNOWN_VALUE)) {
-    if (!start_subobject(p)) {
-      return false;
-    }
-    start_value_object(p, VALUE_NULLVALUE);
-  } else {
-    return true;
-  }
-
-  /* Fill null_value field. */
-  multipart_startaccum(p);
-  capture_begin(p, zero_ptr);
-  capture_end(p, zero_ptr + 1);
-  parse_number(p, false);
-
-  end_value_object(p);
-  if (!is_top_level(p)) {
-    end_subobject(p);
-  }
-
-  return true;
-}
-
-static bool start_any_stringval(upb_json_parser *p) {
-  multipart_startaccum(p);
-  return true;
-}
-
-static bool start_stringval(upb_json_parser *p) {
-  if (is_top_level(p)) {
-    if (is_string_wrapper_object(p) ||
-        is_number_wrapper_object(p)) {
-      start_wrapper_object(p);
-    } else if (is_wellknown_msg(p, UPB_WELLKNOWN_FIELDMASK)) {
-      start_fieldmask_object(p);
-      return true;
-    } else if (is_wellknown_msg(p, UPB_WELLKNOWN_TIMESTAMP) ||
-               is_wellknown_msg(p, UPB_WELLKNOWN_DURATION)) {
-      start_object(p);
-    } else if (is_wellknown_msg(p, UPB_WELLKNOWN_VALUE)) {
-      start_value_object(p, VALUE_STRINGVALUE);
-    } else {
-      return false;
-    }
-  } else if (does_string_wrapper_start(p) ||
-             does_number_wrapper_start(p)) {
-    if (!start_subobject(p)) {
-      return false;
-    }
-    start_wrapper_object(p);
-  } else if (does_fieldmask_start(p)) {
-    if (!start_subobject(p)) {
-      return false;
-    }
-    start_fieldmask_object(p);
-    return true;
-  } else if (is_wellknown_field(p, UPB_WELLKNOWN_TIMESTAMP) ||
-             is_wellknown_field(p, UPB_WELLKNOWN_DURATION)) {
-    if (!start_subobject(p)) {
-      return false;
-    }
-    start_object(p);
-  } else if (is_wellknown_field(p, UPB_WELLKNOWN_VALUE)) {
-    if (!start_subobject(p)) {
-      return false;
-    }
-    start_value_object(p, VALUE_STRINGVALUE);
-  }
-
-  if (p->top->f == NULL) {
-    multipart_startaccum(p);
-    return true;
-  }
-
-  if (p->top->is_any) {
-    return start_any_stringval(p);
-  }
-
-  if (upb_fielddef_isstring(p->top->f)) {
-    upb_jsonparser_frame *inner;
-    upb_selector_t sel;
-
-    if (!check_stack(p)) return false;
-
-    /* Start a new parser frame: parser frames correspond one-to-one with
-     * handler frames, and string events occur in a sub-frame. */
-    inner = start_jsonparser_frame(p);
-    sel = getsel_for_handlertype(p, UPB_HANDLER_STARTSTR);
-    upb_sink_startstr(p->top->sink, sel, 0, &inner->sink);
-    inner->m = p->top->m;
-    inner->f = p->top->f;
-    p->top = inner;
-
-    if (upb_fielddef_type(p->top->f) == UPB_TYPE_STRING) {
-      /* For STRING fields we push data directly to the handlers as it is
-       * parsed.  We don't do this yet for BYTES fields, because our base64
-       * decoder is not streaming.
-       *
-       * TODO(haberman): make base64 decoding streaming also. */
-      multipart_start(p, getsel_for_handlertype(p, UPB_HANDLER_STRING));
-      return true;
-    } else {
-      multipart_startaccum(p);
-      return true;
-    }
-  } else if (upb_fielddef_type(p->top->f) != UPB_TYPE_BOOL &&
-             upb_fielddef_type(p->top->f) != UPB_TYPE_MESSAGE) {
-    /* No need to push a frame -- numeric values in quotes remain in the
-     * current parser frame.  These values must accmulate so we can convert
-     * them all at once at the end. */
-    multipart_startaccum(p);
-    return true;
-  } else {
-    upb_status_seterrf(p->status,
-                       "String specified for bool or submessage field: %s",
-                       upb_fielddef_name(p->top->f));
-    return false;
-  }
-}
-
-static bool end_any_stringval(upb_json_parser *p) {
-  size_t len;
-  const char *buf = accumulate_getptr(p, &len);
-
-  /* Set type_url */
-  upb_selector_t sel;
-  upb_jsonparser_frame *inner;
-  if (!check_stack(p)) return false;
-  inner = p->top + 1;
-
-  sel = getsel_for_handlertype(p, UPB_HANDLER_STARTSTR);
-  upb_sink_startstr(p->top->sink, sel, 0, &inner->sink);
-  sel = getsel_for_handlertype(p, UPB_HANDLER_STRING);
-  upb_sink_putstring(inner->sink, sel, buf, len, NULL);
-  sel = getsel_for_handlertype(p, UPB_HANDLER_ENDSTR);
-  upb_sink_endstr(inner->sink, sel);
-
-  multipart_end(p);
-
-  /* Resolve type url */
-  if (strncmp(buf, "type.googleapis.com/", 20) == 0 && len > 20) {
-    const upb_msgdef *payload_type = NULL;
-    buf += 20;
-    len -= 20;
-
-    payload_type = upb_symtab_lookupmsg2(p->symtab, buf, len);
-    if (payload_type == NULL) {
-      upb_status_seterrf(
-          p->status, "Cannot find packed type: %.*s\n", (int)len, buf);
-      return false;
-    }
-
-    json_parser_any_frame_set_payload_type(p, p->top->any_frame, payload_type);
-
-    return true;
-  } else {
-    upb_status_seterrf(
-        p->status, "Invalid type url: %.*s\n", (int)len, buf);
-    return false;
-  }
-}
-
-static bool end_stringval_nontop(upb_json_parser *p) {
-  bool ok = true;
-
-  if (is_wellknown_msg(p, UPB_WELLKNOWN_TIMESTAMP) ||
-      is_wellknown_msg(p, UPB_WELLKNOWN_DURATION)) {
-    multipart_end(p);
-    return true;
-  }
-
-  if (p->top->f == NULL) {
-    multipart_end(p);
-    return true;
-  }
-
-  if (p->top->is_any) {
-    return end_any_stringval(p);
-  }
-
-  switch (upb_fielddef_type(p->top->f)) {
-    case UPB_TYPE_BYTES:
-      if (!base64_push(p, getsel_for_handlertype(p, UPB_HANDLER_STRING),
-                       p->accumulated, p->accumulated_len)) {
-        return false;
-      }
-      /* Fall through. */
-
-    case UPB_TYPE_STRING: {
-      upb_selector_t sel = getsel_for_handlertype(p, UPB_HANDLER_ENDSTR);
-      upb_sink_endstr(p->top->sink, sel);
-      p->top--;
-      break;
-    }
-
-    case UPB_TYPE_ENUM: {
-      /* Resolve enum symbolic name to integer value. */
-      const upb_enumdef *enumdef = upb_fielddef_enumsubdef(p->top->f);
-
-      size_t len;
-      const char *buf = accumulate_getptr(p, &len);
-
-      int32_t int_val = 0;
-      ok = upb_enumdef_ntoi(enumdef, buf, len, &int_val);
-
-      if (ok) {
-        upb_selector_t sel = parser_getsel(p);
-        upb_sink_putint32(p->top->sink, sel, int_val);
-      } else {
-        if (p->ignore_json_unknown) {
-          ok = true;
-          /* TODO(teboring): Should also clean this field. */
-        } else {
-          upb_status_seterrf(p->status, "Enum value unknown: '%.*s'", len, buf);
-        }
-      }
-
-      break;
-    }
-
-    case UPB_TYPE_INT32:
-    case UPB_TYPE_INT64:
-    case UPB_TYPE_UINT32:
-    case UPB_TYPE_UINT64:
-    case UPB_TYPE_DOUBLE:
-    case UPB_TYPE_FLOAT:
-      ok = parse_number(p, true);
-      break;
-
-    default:
-      UPB_ASSERT(false);
-      upb_status_seterrmsg(p->status, "Internal error in JSON decoder");
-      ok = false;
-      break;
-  }
-
-  multipart_end(p);
-
-  return ok;
-}
-
-static bool end_stringval(upb_json_parser *p) {
-  /* FieldMask's stringvals have been ended when handling them. Only need to
-   * close FieldMask here.*/
-  if (does_fieldmask_end(p)) {
-    end_fieldmask_object(p);
-    if (!is_top_level(p)) {
-      end_subobject(p);
-    }
-    return true;
-  }
-
-  if (!end_stringval_nontop(p)) {
-    return false;
-  }
-
-  if (does_string_wrapper_end(p) ||
-      does_number_wrapper_end(p)) {
-    end_wrapper_object(p);
-    if (!is_top_level(p)) {
-      end_subobject(p);
-    }
-    return true;
-  }
-
-  if (is_wellknown_msg(p, UPB_WELLKNOWN_VALUE)) {
-    end_value_object(p);
-    if (!is_top_level(p)) {
-      end_subobject(p);
-    }
-    return true;
-  }
-
-  if (is_wellknown_msg(p, UPB_WELLKNOWN_TIMESTAMP) ||
-      is_wellknown_msg(p, UPB_WELLKNOWN_DURATION) ||
-      is_wellknown_msg(p, UPB_WELLKNOWN_FIELDMASK)) {
-    end_object(p);
-    if (!is_top_level(p)) {
-      end_subobject(p);
-    }
-    return true;
-  }
-
-  return true;
-}
-
-static void start_duration_base(upb_json_parser *p, const char *ptr) {
-  capture_begin(p, ptr);
-}
-
-static bool end_duration_base(upb_json_parser *p, const char *ptr) {
-  size_t len;
-  const char *buf;
-  char seconds_buf[14];
-  char nanos_buf[12];
-  char *end;
-  int64_t seconds = 0;
-  int32_t nanos = 0;
-  double val = 0.0;
-  const char *seconds_membername = "seconds";
-  const char *nanos_membername = "nanos";
-  size_t fraction_start;
-
-  if (!capture_end(p, ptr)) {
-    return false;
-  }
-
-  buf = accumulate_getptr(p, &len);
-
-  memset(seconds_buf, 0, 14);
-  memset(nanos_buf, 0, 12);
-
-  /* Find out base end. The maximus duration is 315576000000, which cannot be
-   * represented by double without losing precision. Thus, we need to handle
-   * fraction and base separately. */
-  for (fraction_start = 0; fraction_start < len && buf[fraction_start] != '.';
-       fraction_start++);
-
-  /* Parse base */
-  memcpy(seconds_buf, buf, fraction_start);
-  seconds = strtol(seconds_buf, &end, 10);
-  if (errno == ERANGE || end != seconds_buf + fraction_start) {
-    upb_status_seterrf(p->status, "error parsing duration: %s",
-                       seconds_buf);
-    return false;
-  }
-
-  if (seconds > 315576000000) {
-    upb_status_seterrf(p->status, "error parsing duration: "
-                                   "maximum acceptable value is "
-                                   "315576000000");
-    return false;
-  }
-
-  if (seconds < -315576000000) {
-    upb_status_seterrf(p->status, "error parsing duration: "
-                                   "minimum acceptable value is "
-                                   "-315576000000");
-    return false;
-  }
-
-  /* Parse fraction */
-  nanos_buf[0] = '0';
-  memcpy(nanos_buf + 1, buf + fraction_start, len - fraction_start);
-  val = strtod(nanos_buf, &end);
-  if (errno == ERANGE || end != nanos_buf + len - fraction_start + 1) {
-    upb_status_seterrf(p->status, "error parsing duration: %s",
-                       nanos_buf);
-    return false;
-  }
-
-  nanos = val * 1000000000;
-  if (seconds < 0) nanos = -nanos;
-
-  /* Clean up buffer */
-  multipart_end(p);
-
-  /* Set seconds */
-  start_member(p);
-  capture_begin(p, seconds_membername);
-  capture_end(p, seconds_membername + 7);
-  end_membername(p);
-  upb_sink_putint64(p->top->sink, parser_getsel(p), seconds);
-  end_member(p);
-
-  /* Set nanos */
-  start_member(p);
-  capture_begin(p, nanos_membername);
-  capture_end(p, nanos_membername + 5);
-  end_membername(p);
-  upb_sink_putint32(p->top->sink, parser_getsel(p), nanos);
-  end_member(p);
-
-  /* Continue previous arena */
-  multipart_startaccum(p);
-
-  return true;
-}
-
-static int parse_timestamp_number(upb_json_parser *p) {
-  size_t len;
-  const char *buf;
-  int val;
-
-  /* atoi() and friends unfortunately do not support specifying the length of
-   * the input string, so we need to force a copy into a NULL-terminated buffer. */
-  multipart_text(p, "\0", 1, false);
-
-  buf = accumulate_getptr(p, &len);
-  val = atoi(buf);
-  multipart_end(p);
-  multipart_startaccum(p);
-
-  return val;
-}
-
-static void start_year(upb_json_parser *p, const char *ptr) {
-  capture_begin(p, ptr);
-}
-
-static bool end_year(upb_json_parser *p, const char *ptr) {
-  if (!capture_end(p, ptr)) {
-    return false;
-  }
-  p->tm.tm_year = parse_timestamp_number(p) - 1900;
-  return true;
-}
-
-static void start_month(upb_json_parser *p, const char *ptr) {
-  capture_begin(p, ptr);
-}
-
-static bool end_month(upb_json_parser *p, const char *ptr) {
-  if (!capture_end(p, ptr)) {
-    return false;
-  }
-  p->tm.tm_mon = parse_timestamp_number(p) - 1;
-  return true;
-}
-
-static void start_day(upb_json_parser *p, const char *ptr) {
-  capture_begin(p, ptr);
-}
-
-static bool end_day(upb_json_parser *p, const char *ptr) {
-  if (!capture_end(p, ptr)) {
-    return false;
-  }
-  p->tm.tm_mday = parse_timestamp_number(p);
-  return true;
-}
-
-static void start_hour(upb_json_parser *p, const char *ptr) {
-  capture_begin(p, ptr);
-}
-
-static bool end_hour(upb_json_parser *p, const char *ptr) {
-  if (!capture_end(p, ptr)) {
-    return false;
-  }
-  p->tm.tm_hour = parse_timestamp_number(p);
-  return true;
-}
-
-static void start_minute(upb_json_parser *p, const char *ptr) {
-  capture_begin(p, ptr);
-}
-
-static bool end_minute(upb_json_parser *p, const char *ptr) {
-  if (!capture_end(p, ptr)) {
-    return false;
-  }
-  p->tm.tm_min = parse_timestamp_number(p);
-  return true;
-}
-
-static void start_second(upb_json_parser *p, const char *ptr) {
-  capture_begin(p, ptr);
-}
-
-static bool end_second(upb_json_parser *p, const char *ptr) {
-  if (!capture_end(p, ptr)) {
-    return false;
-  }
-  p->tm.tm_sec = parse_timestamp_number(p);
-  return true;
-}
-
-static void start_timestamp_base(upb_json_parser *p) {
-  memset(&p->tm, 0, sizeof(struct tm));
-}
-
-static void start_timestamp_fraction(upb_json_parser *p, const char *ptr) {
-  capture_begin(p, ptr);
-}
-
-static bool end_timestamp_fraction(upb_json_parser *p, const char *ptr) {
-  size_t len;
-  const char *buf;
-  char nanos_buf[12];
-  char *end;
-  double val = 0.0;
-  int32_t nanos;
-  const char *nanos_membername = "nanos";
-
-  memset(nanos_buf, 0, 12);
-
-  if (!capture_end(p, ptr)) {
-    return false;
-  }
-
-  buf = accumulate_getptr(p, &len);
-
-  if (len > 10) {
-    upb_status_seterrf(p->status,
-        "error parsing timestamp: at most 9-digit fraction.");
-    return false;
-  }
-
-  /* Parse nanos */
-  nanos_buf[0] = '0';
-  memcpy(nanos_buf + 1, buf, len);
-  val = strtod(nanos_buf, &end);
-
-  if (errno == ERANGE || end != nanos_buf + len + 1) {
-    upb_status_seterrf(p->status, "error parsing timestamp nanos: %s",
-                       nanos_buf);
-    return false;
-  }
-
-  nanos = val * 1000000000;
-
-  /* Clean up previous environment */
-  multipart_end(p);
-
-  /* Set nanos */
-  start_member(p);
-  capture_begin(p, nanos_membername);
-  capture_end(p, nanos_membername + 5);
-  end_membername(p);
-  upb_sink_putint32(p->top->sink, parser_getsel(p), nanos);
-  end_member(p);
-
-  /* Continue previous environment */
-  multipart_startaccum(p);
-
-  return true;
-}
-
-static void start_timestamp_zone(upb_json_parser *p, const char *ptr) {
-  capture_begin(p, ptr);
-}
-
-/* epoch_days(1970, 1, 1) == 1970-01-01 == 0. */
-static int epoch_days(int year, int month, int day) {
-  static const uint16_t month_yday[12] = {0,   31,  59,  90,  120, 151,
-                                          181, 212, 243, 273, 304, 334};
-  uint32_t year_adj = year + 4800;  /* Ensure positive year, multiple of 400. */
-  uint32_t febs = year_adj - (month <= 2 ? 1 : 0);  /* Februaries since base. */
-  uint32_t leap_days = 1 + (febs / 4) - (febs / 100) + (febs / 400);
-  uint32_t days = 365 * year_adj + leap_days + month_yday[month - 1] + day - 1;
-  return days - 2472692;  /* Adjust to Unix epoch. */
-}
-
-static int64_t upb_timegm(const struct tm *tp) {
-  int64_t ret = epoch_days(tp->tm_year + 1900, tp->tm_mon + 1, tp->tm_mday);
-  ret = (ret * 24) + tp->tm_hour;
-  ret = (ret * 60) + tp->tm_min;
-  ret = (ret * 60) + tp->tm_sec;
-  return ret;
-}
-
-static bool end_timestamp_zone(upb_json_parser *p, const char *ptr) {
-  size_t len;
-  const char *buf;
-  int hours;
-  int64_t seconds;
-  const char *seconds_membername = "seconds";
-
-  if (!capture_end(p, ptr)) {
-    return false;
-  }
-
-  buf = accumulate_getptr(p, &len);
-
-  if (buf[0] != 'Z') {
-    if (sscanf(buf + 1, "%2d:00", &hours) != 1) {
-      upb_status_seterrf(p->status, "error parsing timestamp offset");
-      return false;
-    }
-
-    if (buf[0] == '+') {
-      hours = -hours;
-    }
-
-    p->tm.tm_hour += hours;
-  }
-
-  /* Normalize tm */
-  seconds = upb_timegm(&p->tm);
-
-  /* Check timestamp boundary */
-  if (seconds < -62135596800) {
-    upb_status_seterrf(p->status, "error parsing timestamp: "
-                                   "minimum acceptable value is "
-                                   "0001-01-01T00:00:00Z");
-    return false;
-  }
-
-  /* Clean up previous environment */
-  multipart_end(p);
-
-  /* Set seconds */
-  start_member(p);
-  capture_begin(p, seconds_membername);
-  capture_end(p, seconds_membername + 7);
-  end_membername(p);
-  upb_sink_putint64(p->top->sink, parser_getsel(p), seconds);
-  end_member(p);
-
-  /* Continue previous environment */
-  multipart_startaccum(p);
-
-  return true;
-}
-
-static void start_fieldmask_path_text(upb_json_parser *p, const char *ptr) {
-  capture_begin(p, ptr);
-}
-
-static bool end_fieldmask_path_text(upb_json_parser *p, const char *ptr) {
-  return capture_end(p, ptr);
-}
-
-static bool start_fieldmask_path(upb_json_parser *p) {
-  upb_jsonparser_frame *inner;
-  upb_selector_t sel;
-
-  if (!check_stack(p)) return false;
-
-  /* Start a new parser frame: parser frames correspond one-to-one with
-   * handler frames, and string events occur in a sub-frame. */
-  inner = start_jsonparser_frame(p);
-  sel = getsel_for_handlertype(p, UPB_HANDLER_STARTSTR);
-  upb_sink_startstr(p->top->sink, sel, 0, &inner->sink);
-  inner->m = p->top->m;
-  inner->f = p->top->f;
-  p->top = inner;
-
-  multipart_startaccum(p);
-  return true;
-}
-
-static bool lower_camel_push(
-    upb_json_parser *p, upb_selector_t sel, const char *ptr, size_t len) {
-  const char *limit = ptr + len;
-  bool first = true;
-  for (;ptr < limit; ptr++) {
-    if (*ptr >= 'A' && *ptr <= 'Z' && !first) {
-      char lower = tolower(*ptr);
-      upb_sink_putstring(p->top->sink, sel, "_", 1, NULL);
-      upb_sink_putstring(p->top->sink, sel, &lower, 1, NULL);
-    } else {
-      upb_sink_putstring(p->top->sink, sel, ptr, 1, NULL);
-    }
-    first = false;
-  }
-  return true;
-}
-
-static bool end_fieldmask_path(upb_json_parser *p) {
-  upb_selector_t sel;
-
-  if (!lower_camel_push(
-           p, getsel_for_handlertype(p, UPB_HANDLER_STRING),
-           p->accumulated, p->accumulated_len)) {
-    return false;
-  }
-
-  sel = getsel_for_handlertype(p, UPB_HANDLER_ENDSTR);
-  upb_sink_endstr(p->top->sink, sel);
-  p->top--;
-
-  multipart_end(p);
-  return true;
-}
-
-static void start_member(upb_json_parser *p) {
-  UPB_ASSERT(!p->top->f);
-  multipart_startaccum(p);
-}
-
-/* Helper: invoked during parse_mapentry() to emit the mapentry message's key
- * field based on the current contents of the accumulate buffer. */
-static bool parse_mapentry_key(upb_json_parser *p) {
-
-  size_t len;
-  const char *buf = accumulate_getptr(p, &len);
-
-  /* Emit the key field. We do a bit of ad-hoc parsing here because the
-   * parser state machine has already decided that this is a string field
-   * name, and we are reinterpreting it as some arbitrary key type. In
-   * particular, integer and bool keys are quoted, so we need to parse the
-   * quoted string contents here. */
-
-  p->top->f = upb_msgdef_itof(p->top->m, UPB_MAPENTRY_KEY);
-  if (p->top->f == NULL) {
-    upb_status_seterrmsg(p->status, "mapentry message has no key");
-    return false;
-  }
-  switch (upb_fielddef_type(p->top->f)) {
-    case UPB_TYPE_INT32:
-    case UPB_TYPE_INT64:
-    case UPB_TYPE_UINT32:
-    case UPB_TYPE_UINT64:
-      /* Invoke end_number. The accum buffer has the number's text already. */
-      if (!parse_number(p, true)) {
-        return false;
-      }
-      break;
-    case UPB_TYPE_BOOL:
-      if (len == 4 && !strncmp(buf, "true", 4)) {
-        if (!parser_putbool(p, true)) {
-          return false;
-        }
-      } else if (len == 5 && !strncmp(buf, "false", 5)) {
-        if (!parser_putbool(p, false)) {
-          return false;
-        }
-      } else {
-        upb_status_seterrmsg(p->status,
-                             "Map bool key not 'true' or 'false'");
-        return false;
-      }
-      multipart_end(p);
-      break;
-    case UPB_TYPE_STRING:
-    case UPB_TYPE_BYTES: {
-      upb_sink subsink;
-      upb_selector_t sel = getsel_for_handlertype(p, UPB_HANDLER_STARTSTR);
-      upb_sink_startstr(p->top->sink, sel, len, &subsink);
-      sel = getsel_for_handlertype(p, UPB_HANDLER_STRING);
-      upb_sink_putstring(subsink, sel, buf, len, NULL);
-      sel = getsel_for_handlertype(p, UPB_HANDLER_ENDSTR);
-      upb_sink_endstr(subsink, sel);
-      multipart_end(p);
-      break;
-    }
-    default:
-      upb_status_seterrmsg(p->status, "Invalid field type for map key");
-      return false;
-  }
-
-  return true;
-}
-
-/* Helper: emit one map entry (as a submessage in the map field sequence). This
- * is invoked from end_membername(), at the end of the map entry's key string,
- * with the map key in the accumulate buffer. It parses the key from that
- * buffer, emits the handler calls to start the mapentry submessage (setting up
- * its subframe in the process), and sets up state in the subframe so that the
- * value parser (invoked next) will emit the mapentry's value field and then
- * end the mapentry message. */
-
-static bool handle_mapentry(upb_json_parser *p) {
-  const upb_fielddef *mapfield;
-  const upb_msgdef *mapentrymsg;
-  upb_jsonparser_frame *inner;
-  upb_selector_t sel;
-
-  /* Map entry: p->top->sink is the seq frame, so we need to start a frame
-   * for the mapentry itself, and then set |f| in that frame so that the map
-   * value field is parsed, and also set a flag to end the frame after the
-   * map-entry value is parsed. */
-  if (!check_stack(p)) return false;
-
-  mapfield = p->top->mapfield;
-  mapentrymsg = upb_fielddef_msgsubdef(mapfield);
-
-  inner = start_jsonparser_frame(p);
-  p->top->f = mapfield;
-  sel = getsel_for_handlertype(p, UPB_HANDLER_STARTSUBMSG);
-  upb_sink_startsubmsg(p->top->sink, sel, &inner->sink);
-  inner->m = mapentrymsg;
-  inner->mapfield = mapfield;
-
-  /* Don't set this to true *yet* -- we reuse parsing handlers below to push
-   * the key field value to the sink, and these handlers will pop the frame
-   * if they see is_mapentry (when invoked by the parser state machine, they
-   * would have just seen the map-entry value, not key). */
-  inner->is_mapentry = false;
-  p->top = inner;
-
-  /* send STARTMSG in submsg frame. */
-  upb_sink_startmsg(p->top->sink);
-
-  parse_mapentry_key(p);
-
-  /* Set up the value field to receive the map-entry value. */
-  p->top->f = upb_msgdef_itof(p->top->m, UPB_MAPENTRY_VALUE);
-  p->top->is_mapentry = true;  /* set up to pop frame after value is parsed. */
-  p->top->mapfield = mapfield;
-  if (p->top->f == NULL) {
-    upb_status_seterrmsg(p->status, "mapentry message has no value");
-    return false;
-  }
-
-  return true;
-}
-
-static bool end_membername(upb_json_parser *p) {
-  UPB_ASSERT(!p->top->f);
-
-  if (!p->top->m) {
-    p->top->is_unknown_field = true;
-    multipart_end(p);
-    return true;
-  }
-
-  if (p->top->is_any) {
-    return end_any_membername(p);
-  } else if (p->top->is_map) {
-    return handle_mapentry(p);
-  } else {
-    size_t len;
-    const char *buf = accumulate_getptr(p, &len);
-    upb_value v;
-
-    if (upb_strtable_lookup2(p->top->name_table, buf, len, &v)) {
-      p->top->f = upb_value_getconstptr(v);
-      multipart_end(p);
-
-      return true;
-    } else if (p->ignore_json_unknown) {
-      p->top->is_unknown_field = true;
-      multipart_end(p);
-      return true;
-    } else {
-      upb_status_seterrf(p->status, "No such field: %.*s\n", (int)len, buf);
-      return false;
-    }
-  }
-}
-
-static bool end_any_membername(upb_json_parser *p) {
-  size_t len;
-  const char *buf = accumulate_getptr(p, &len);
-  upb_value v;
-
-  if (len == 5 && strncmp(buf, "@type", len) == 0) {
-    upb_strtable_lookup2(p->top->name_table, "type_url", 8, &v);
-    p->top->f = upb_value_getconstptr(v);
-    multipart_end(p);
-    return true;
-  } else {
-    p->top->is_unknown_field = true;
-    multipart_end(p);
-    return true;
-  }
-}
-
-static void end_member(upb_json_parser *p) {
-  /* If we just parsed a map-entry value, end that frame too. */
-  if (p->top->is_mapentry) {
-    upb_selector_t sel;
-    bool ok;
-    const upb_fielddef *mapfield;
-
-    UPB_ASSERT(p->top > p->stack);
-    /* send ENDMSG on submsg. */
-    upb_sink_endmsg(p->top->sink, p->status);
-    mapfield = p->top->mapfield;
-
-    /* send ENDSUBMSG in repeated-field-of-mapentries frame. */
-    p->top--;
-    ok = upb_handlers_getselector(mapfield, UPB_HANDLER_ENDSUBMSG, &sel);
-    UPB_ASSUME(ok);
-    upb_sink_endsubmsg(p->top->sink, (p->top + 1)->sink, sel);
-  }
-
-  p->top->f = NULL;
-  p->top->is_unknown_field = false;
-}
-
-static void start_any_member(upb_json_parser *p, const char *ptr) {
-  start_member(p);
-  json_parser_any_frame_set_after_type_url_start_once(p->top->any_frame, ptr);
-}
-
-static void end_any_member(upb_json_parser *p, const char *ptr) {
-  json_parser_any_frame_set_before_type_url_end(p->top->any_frame, ptr);
-  end_member(p);
-}
-
-static bool start_subobject(upb_json_parser *p) {
-  if (p->top->is_unknown_field) {
-    if (!check_stack(p)) return false;
-
-    p->top = start_jsonparser_frame(p);
-    return true;
-  }
-
-  if (upb_fielddef_ismap(p->top->f)) {
-    upb_jsonparser_frame *inner;
-    upb_selector_t sel;
-
-    /* Beginning of a map. Start a new parser frame in a repeated-field
-     * context. */
-    if (!check_stack(p)) return false;
-
-    inner = start_jsonparser_frame(p);
-    sel = getsel_for_handlertype(p, UPB_HANDLER_STARTSEQ);
-    upb_sink_startseq(p->top->sink, sel, &inner->sink);
-    inner->m = upb_fielddef_msgsubdef(p->top->f);
-    inner->mapfield = p->top->f;
-    inner->is_map = true;
-    p->top = inner;
-
-    return true;
-  } else if (upb_fielddef_issubmsg(p->top->f)) {
-    upb_jsonparser_frame *inner;
-    upb_selector_t sel;
-
-    /* Beginning of a subobject. Start a new parser frame in the submsg
-     * context. */
-    if (!check_stack(p)) return false;
-
-    inner = start_jsonparser_frame(p);
-    sel = getsel_for_handlertype(p, UPB_HANDLER_STARTSUBMSG);
-    upb_sink_startsubmsg(p->top->sink, sel, &inner->sink);
-    inner->m = upb_fielddef_msgsubdef(p->top->f);
-    set_name_table(p, inner);
-    p->top = inner;
-
-    if (is_wellknown_msg(p, UPB_WELLKNOWN_ANY)) {
-      p->top->is_any = true;
-      p->top->any_frame = json_parser_any_frame_new(p);
-    } else {
-      p->top->is_any = false;
-      p->top->any_frame = NULL;
-    }
-
-    return true;
-  } else {
-    upb_status_seterrf(p->status,
-                       "Object specified for non-message/group field: %s",
-                       upb_fielddef_name(p->top->f));
-    return false;
-  }
-}
-
-static bool start_subobject_full(upb_json_parser *p) {
-  if (is_top_level(p)) {
-    if (is_wellknown_msg(p, UPB_WELLKNOWN_VALUE)) {
-      start_value_object(p, VALUE_STRUCTVALUE);
-      if (!start_subobject(p)) return false;
-      start_structvalue_object(p);
-    } else if (is_wellknown_msg(p, UPB_WELLKNOWN_STRUCT)) {
-      start_structvalue_object(p);
-    } else {
-      return true;
-    }
-  } else if (is_wellknown_field(p, UPB_WELLKNOWN_STRUCT)) {
-    if (!start_subobject(p)) return false;
-    start_structvalue_object(p);
-  } else if (is_wellknown_field(p, UPB_WELLKNOWN_VALUE)) {
-    if (!start_subobject(p)) return false;
-    start_value_object(p, VALUE_STRUCTVALUE);
-    if (!start_subobject(p)) return false;
-    start_structvalue_object(p);
-  }
-
-  return start_subobject(p);
-}
-
-static void end_subobject(upb_json_parser *p) {
-  if (is_top_level(p)) {
-    return;
-  }
-
-  if (p->top->is_map) {
-    upb_selector_t sel;
-    p->top--;
-    sel = getsel_for_handlertype(p, UPB_HANDLER_ENDSEQ);
-    upb_sink_endseq(p->top->sink, sel);
-  } else {
-    upb_selector_t sel;
-    bool is_unknown = p->top->m == NULL;
-    p->top--;
-    if (!is_unknown) {
-      sel = getsel_for_handlertype(p, UPB_HANDLER_ENDSUBMSG);
-      upb_sink_endsubmsg(p->top->sink, (p->top + 1)->sink, sel);
-    }
-  }
-}
-
-static void end_subobject_full(upb_json_parser *p) {
-  end_subobject(p);
-
-  if (is_wellknown_msg(p, UPB_WELLKNOWN_STRUCT)) {
-    end_structvalue_object(p);
-    if (!is_top_level(p)) {
-      end_subobject(p);
-    }
-  }
-
-  if (is_wellknown_msg(p, UPB_WELLKNOWN_VALUE)) {
-    end_value_object(p);
-    if (!is_top_level(p)) {
-      end_subobject(p);
-    }
-  }
-}
-
-static bool start_array(upb_json_parser *p) {
-  upb_jsonparser_frame *inner;
-  upb_selector_t sel;
-
-  if (is_top_level(p)) {
-    if (is_wellknown_msg(p, UPB_WELLKNOWN_VALUE)) {
-      start_value_object(p, VALUE_LISTVALUE);
-      if (!start_subobject(p)) return false;
-      start_listvalue_object(p);
-    } else if (is_wellknown_msg(p, UPB_WELLKNOWN_LISTVALUE)) {
-      start_listvalue_object(p);
-    } else {
-      return false;
-    }
-  } else if (is_wellknown_field(p, UPB_WELLKNOWN_LISTVALUE) &&
-             (!upb_fielddef_isseq(p->top->f) ||
-              p->top->is_repeated)) {
-    if (!start_subobject(p)) return false;
-    start_listvalue_object(p);
-  } else if (is_wellknown_field(p, UPB_WELLKNOWN_VALUE) &&
-             (!upb_fielddef_isseq(p->top->f) ||
-              p->top->is_repeated)) {
-    if (!start_subobject(p)) return false;
-    start_value_object(p, VALUE_LISTVALUE);
-    if (!start_subobject(p)) return false;
-    start_listvalue_object(p);
-  }
-
-  if (p->top->is_unknown_field) {
-    inner = start_jsonparser_frame(p);
-    inner->is_unknown_field = true;
-    p->top = inner;
-
-    return true;
-  }
-
-  if (!upb_fielddef_isseq(p->top->f)) {
-    upb_status_seterrf(p->status,
-                       "Array specified for non-repeated field: %s",
-                       upb_fielddef_name(p->top->f));
-    return false;
-  }
-
-  if (!check_stack(p)) return false;
-
-  inner = start_jsonparser_frame(p);
-  sel = getsel_for_handlertype(p, UPB_HANDLER_STARTSEQ);
-  upb_sink_startseq(p->top->sink, sel, &inner->sink);
-  inner->m = p->top->m;
-  inner->f = p->top->f;
-  inner->is_repeated = true;
-  p->top = inner;
-
-  return true;
-}
-
-static void end_array(upb_json_parser *p) {
-  upb_selector_t sel;
-
-  UPB_ASSERT(p->top > p->stack);
-
-  p->top--;
-
-  if (p->top->is_unknown_field) {
-    return;
-  }
-
-  sel = getsel_for_handlertype(p, UPB_HANDLER_ENDSEQ);
-  upb_sink_endseq(p->top->sink, sel);
-
-  if (is_wellknown_msg(p, UPB_WELLKNOWN_LISTVALUE)) {
-    end_listvalue_object(p);
-    if (!is_top_level(p)) {
-      end_subobject(p);
-    }
-  }
-
-  if (is_wellknown_msg(p, UPB_WELLKNOWN_VALUE)) {
-    end_value_object(p);
-    if (!is_top_level(p)) {
-      end_subobject(p);
-    }
-  }
-}
-
-static void start_object(upb_json_parser *p) {
-  if (!p->top->is_map && p->top->m != NULL) {
-    upb_sink_startmsg(p->top->sink);
-  }
-}
-
-static void end_object(upb_json_parser *p) {
-  if (!p->top->is_map && p->top->m != NULL) {
-    upb_sink_endmsg(p->top->sink, p->status);
-  }
-}
-
-static void start_any_object(upb_json_parser *p, const char *ptr) {
-  start_object(p);
-  p->top->any_frame->before_type_url_start = ptr;
-  p->top->any_frame->before_type_url_end = ptr;
-}
-
-static bool end_any_object(upb_json_parser *p, const char *ptr) {
-  const char *value_membername = "value";
-  bool is_well_known_packed = false;
-  const char *packed_end = ptr + 1;
-  upb_selector_t sel;
-  upb_jsonparser_frame *inner;
-
-  if (json_parser_any_frame_has_value(p->top->any_frame) &&
-      !json_parser_any_frame_has_type_url(p->top->any_frame)) {
-    upb_status_seterrmsg(p->status, "No valid type url");
-    return false;
-  }
-
-  /* Well known types data is represented as value field. */
-  if (upb_msgdef_wellknowntype(p->top->any_frame->parser->top->m) !=
-          UPB_WELLKNOWN_UNSPECIFIED) {
-    is_well_known_packed = true;
-
-    if (json_parser_any_frame_has_value_before_type_url(p->top->any_frame)) {
-      p->top->any_frame->before_type_url_start =
-          memchr(p->top->any_frame->before_type_url_start, ':',
-                 p->top->any_frame->before_type_url_end -
-                 p->top->any_frame->before_type_url_start);
-      if (p->top->any_frame->before_type_url_start == NULL) {
-        upb_status_seterrmsg(p->status, "invalid data for well known type.");
-        return false;
-      }
-      p->top->any_frame->before_type_url_start++;
-    }
-
-    if (json_parser_any_frame_has_value_after_type_url(p->top->any_frame)) {
-      p->top->any_frame->after_type_url_start =
-          memchr(p->top->any_frame->after_type_url_start, ':',
-                 (ptr + 1) -
-                 p->top->any_frame->after_type_url_start);
-      if (p->top->any_frame->after_type_url_start == NULL) {
-        upb_status_seterrmsg(p->status, "Invalid data for well known type.");
-        return false;
-      }
-      p->top->any_frame->after_type_url_start++;
-      packed_end = ptr;
-    }
-  }
-
-  if (json_parser_any_frame_has_value_before_type_url(p->top->any_frame)) {
-    if (!parse(p->top->any_frame->parser, NULL,
-               p->top->any_frame->before_type_url_start,
-               p->top->any_frame->before_type_url_end -
-               p->top->any_frame->before_type_url_start, NULL)) {
-      return false;
-    }
-  } else {
-    if (!is_well_known_packed) {
-      if (!parse(p->top->any_frame->parser, NULL, "{", 1, NULL)) {
-        return false;
-      }
-    }
-  }
-
-  if (json_parser_any_frame_has_value_before_type_url(p->top->any_frame) &&
-      json_parser_any_frame_has_value_after_type_url(p->top->any_frame)) {
-    if (!parse(p->top->any_frame->parser, NULL, ",", 1, NULL)) {
-      return false;
-    }
-  }
-
-  if (json_parser_any_frame_has_value_after_type_url(p->top->any_frame)) {
-    if (!parse(p->top->any_frame->parser, NULL,
-               p->top->any_frame->after_type_url_start,
-               packed_end - p->top->any_frame->after_type_url_start, NULL)) {
-      return false;
-    }
-  } else {
-    if (!is_well_known_packed) {
-      if (!parse(p->top->any_frame->parser, NULL, "}", 1, NULL)) {
-        return false;
-      }
-    }
-  }
-
-  if (!end(p->top->any_frame->parser, NULL)) {
-    return false;
-  }
-
-  p->top->is_any = false;
-
-  /* Set value */
-  start_member(p);
-  capture_begin(p, value_membername);
-  capture_end(p, value_membername + 5);
-  end_membername(p);
-
-  if (!check_stack(p)) return false;
-  inner = p->top + 1;
-
-  sel = getsel_for_handlertype(p, UPB_HANDLER_STARTSTR);
-  upb_sink_startstr(p->top->sink, sel, 0, &inner->sink);
-  sel = getsel_for_handlertype(p, UPB_HANDLER_STRING);
-  upb_sink_putstring(inner->sink, sel, p->top->any_frame->stringsink.ptr,
-                     p->top->any_frame->stringsink.len, NULL);
-  sel = getsel_for_handlertype(p, UPB_HANDLER_ENDSTR);
-  upb_sink_endstr(inner->sink, sel);
-
-  end_member(p);
-
-  end_object(p);
-
-  /* Deallocate any parse frame. */
-  json_parser_any_frame_free(p->top->any_frame);
-
-  return true;
-}
-
-static bool is_string_wrapper(const upb_msgdef *m) {
-  upb_wellknowntype_t type = upb_msgdef_wellknowntype(m);
-  return type == UPB_WELLKNOWN_STRINGVALUE ||
-         type == UPB_WELLKNOWN_BYTESVALUE;
-}
-
-static bool is_fieldmask(const upb_msgdef *m) {
-  upb_wellknowntype_t type = upb_msgdef_wellknowntype(m);
-  return type == UPB_WELLKNOWN_FIELDMASK;
-}
-
-static void start_fieldmask_object(upb_json_parser *p) {
-  const char *membername = "paths";
-
-  start_object(p);
-
-  /* Set up context for parsing value */
-  start_member(p);
-  capture_begin(p, membername);
-  capture_end(p, membername + 5);
-  end_membername(p);
-
-  start_array(p);
-}
-
-static void end_fieldmask_object(upb_json_parser *p) {
-  end_array(p);
-  end_member(p);
-  end_object(p);
-}
-
-static void start_wrapper_object(upb_json_parser *p) {
-  const char *membername = "value";
-
-  start_object(p);
-
-  /* Set up context for parsing value */
-  start_member(p);
-  capture_begin(p, membername);
-  capture_end(p, membername + 5);
-  end_membername(p);
-}
-
-static void end_wrapper_object(upb_json_parser *p) {
-  end_member(p);
-  end_object(p);
-}
-
-static void start_value_object(upb_json_parser *p, int value_type) {
-  const char *nullmember = "null_value";
-  const char *numbermember = "number_value";
-  const char *stringmember = "string_value";
-  const char *boolmember = "bool_value";
-  const char *structmember = "struct_value";
-  const char *listmember = "list_value";
-  const char *membername = "";
-
-  switch (value_type) {
-    case VALUE_NULLVALUE:
-      membername = nullmember;
-      break;
-    case VALUE_NUMBERVALUE:
-      membername = numbermember;
-      break;
-    case VALUE_STRINGVALUE:
-      membername = stringmember;
-      break;
-    case VALUE_BOOLVALUE:
-      membername = boolmember;
-      break;
-    case VALUE_STRUCTVALUE:
-      membername = structmember;
-      break;
-    case VALUE_LISTVALUE:
-      membername = listmember;
-      break;
-  }
-
-  start_object(p);
-
-  /* Set up context for parsing value */
-  start_member(p);
-  capture_begin(p, membername);
-  capture_end(p, membername + strlen(membername));
-  end_membername(p);
-}
-
-static void end_value_object(upb_json_parser *p) {
-  end_member(p);
-  end_object(p);
-}
-
-static void start_listvalue_object(upb_json_parser *p) {
-  const char *membername = "values";
-
-  start_object(p);
-
-  /* Set up context for parsing value */
-  start_member(p);
-  capture_begin(p, membername);
-  capture_end(p, membername + strlen(membername));
-  end_membername(p);
-}
-
-static void end_listvalue_object(upb_json_parser *p) {
-  end_member(p);
-  end_object(p);
-}
-
-static void start_structvalue_object(upb_json_parser *p) {
-  const char *membername = "fields";
-
-  start_object(p);
-
-  /* Set up context for parsing value */
-  start_member(p);
-  capture_begin(p, membername);
-  capture_end(p, membername + strlen(membername));
-  end_membername(p);
-}
-
-static void end_structvalue_object(upb_json_parser *p) {
-  end_member(p);
-  end_object(p);
-}
-
-static bool is_top_level(upb_json_parser *p) {
-  return p->top == p->stack && p->top->f == NULL && !p->top->is_unknown_field;
-}
-
-static bool is_wellknown_msg(upb_json_parser *p, upb_wellknowntype_t type) {
-  return p->top->m != NULL && upb_msgdef_wellknowntype(p->top->m) == type;
-}
-
-static bool is_wellknown_field(upb_json_parser *p, upb_wellknowntype_t type) {
-  return p->top->f != NULL &&
-         upb_fielddef_issubmsg(p->top->f) &&
-         (upb_msgdef_wellknowntype(upb_fielddef_msgsubdef(p->top->f))
-              == type);
-}
-
-static bool does_number_wrapper_start(upb_json_parser *p) {
-  return p->top->f != NULL &&
-         upb_fielddef_issubmsg(p->top->f) &&
-         upb_msgdef_isnumberwrapper(upb_fielddef_msgsubdef(p->top->f));
-}
-
-static bool does_number_wrapper_end(upb_json_parser *p) {
-  return p->top->m != NULL && upb_msgdef_isnumberwrapper(p->top->m);
-}
-
-static bool is_number_wrapper_object(upb_json_parser *p) {
-  return p->top->m != NULL && upb_msgdef_isnumberwrapper(p->top->m);
-}
-
-static bool does_string_wrapper_start(upb_json_parser *p) {
-  return p->top->f != NULL &&
-         upb_fielddef_issubmsg(p->top->f) &&
-         is_string_wrapper(upb_fielddef_msgsubdef(p->top->f));
-}
-
-static bool does_string_wrapper_end(upb_json_parser *p) {
-  return p->top->m != NULL && is_string_wrapper(p->top->m);
-}
-
-static bool is_string_wrapper_object(upb_json_parser *p) {
-  return p->top->m != NULL && is_string_wrapper(p->top->m);
-}
-
-static bool does_fieldmask_start(upb_json_parser *p) {
-  return p->top->f != NULL &&
-         upb_fielddef_issubmsg(p->top->f) &&
-         is_fieldmask(upb_fielddef_msgsubdef(p->top->f));
-}
-
-static bool does_fieldmask_end(upb_json_parser *p) {
-  return p->top->m != NULL && is_fieldmask(p->top->m);
-}
-
-#define CHECK_RETURN_TOP(x) if (!(x)) goto error
-
-
-/* The actual parser **********************************************************/
-
-/* What follows is the Ragel parser itself.  The language is specified in Ragel
- * and the actions call our C functions above.
- *
- * Ragel has an extensive set of functionality, and we use only a small part of
- * it.  There are many action types but we only use a few:
- *
- *   ">" -- transition into a machine
- *   "%" -- transition out of a machine
- *   "@" -- transition into a final state of a machine.
- *
- * "@" transitions are tricky because a machine can transition into a final
- * state repeatedly.  But in some cases we know this can't happen, for example
- * a string which is delimited by a final '"' can only transition into its
- * final state once, when the closing '"' is seen. */
-
-
-#line 2784 "upb/json/parser.rl"
-
-
-
-#line 2587 "upb/json/parser.c"
-static const char _json_actions[] = {
-       0, 1, 0, 1, 1, 1, 3, 1, 
-       4, 1, 6, 1, 7, 1, 8, 1, 
-       9, 1, 11, 1, 12, 1, 13, 1, 
-       14, 1, 15, 1, 16, 1, 17, 1, 
-       18, 1, 19, 1, 20, 1, 22, 1, 
-       23, 1, 24, 1, 35, 1, 37, 1, 
-       39, 1, 40, 1, 42, 1, 43, 1, 
-       44, 1, 46, 1, 48, 1, 49, 1, 
-       50, 1, 51, 1, 53, 1, 54, 2, 
-       4, 9, 2, 5, 6, 2, 7, 3, 
-       2, 7, 9, 2, 21, 26, 2, 25, 
-       10, 2, 27, 28, 2, 29, 30, 2, 
-       32, 34, 2, 33, 31, 2, 38, 36, 
-       2, 40, 42, 2, 45, 2, 2, 46, 
-       54, 2, 47, 36, 2, 49, 54, 2, 
-       50, 54, 2, 51, 54, 2, 52, 41, 
-       2, 53, 54, 3, 32, 34, 35, 4, 
-       21, 26, 27, 28
-};
-
-static const short _json_key_offsets[] = {
-       0, 0, 12, 13, 18, 23, 28, 29, 
-       30, 31, 32, 33, 34, 35, 36, 37, 
-       38, 43, 44, 48, 53, 58, 63, 67, 
-       71, 74, 77, 79, 83, 87, 89, 91, 
-       96, 98, 100, 109, 115, 121, 127, 133, 
-       135, 139, 142, 144, 146, 149, 150, 154, 
-       156, 158, 160, 162, 163, 165, 167, 168, 
-       170, 172, 173, 175, 177, 178, 180, 182, 
-       183, 185, 187, 191, 193, 195, 196, 197, 
-       198, 199, 201, 206, 208, 210, 212, 221, 
-       222, 222, 222, 227, 232, 237, 238, 239, 
-       240, 241, 241, 242, 243, 244, 244, 245, 
-       246, 247, 247, 252, 253, 257, 262, 267, 
-       272, 276, 276, 279, 282, 285, 288, 291, 
-       294, 294, 294, 294, 294, 294
-};
-
-static const char _json_trans_keys[] = {
-       32, 34, 45, 91, 102, 110, 116, 123, 
-       9, 13, 48, 57, 34, 32, 93, 125, 
-       9, 13, 32, 44, 93, 9, 13, 32, 
-       93, 125, 9, 13, 97, 108, 115, 101, 
-       117, 108, 108, 114, 117, 101, 32, 34, 
-       125, 9, 13, 34, 32, 58, 9, 13, 
-       32, 93, 125, 9, 13, 32, 44, 125, 
-       9, 13, 32, 44, 125, 9, 13, 32, 
-       34, 9, 13, 45, 48, 49, 57, 48, 
-       49, 57, 46, 69, 101, 48, 57, 69, 
-       101, 48, 57, 43, 45, 48, 57, 48, 
-       57, 48, 57, 46, 69, 101, 48, 57, 
-       34, 92, 34, 92, 34, 47, 92, 98, 
-       102, 110, 114, 116, 117, 48, 57, 65, 
-       70, 97, 102, 48, 57, 65, 70, 97, 
-       102, 48, 57, 65, 70, 97, 102, 48, 
-       57, 65, 70, 97, 102, 34, 92, 45, 
-       48, 49, 57, 48, 49, 57, 46, 115, 
-       48, 57, 115, 48, 57, 34, 46, 115, 
-       48, 57, 48, 57, 48, 57, 48, 57, 
-       48, 57, 45, 48, 57, 48, 57, 45, 
-       48, 57, 48, 57, 84, 48, 57, 48, 
-       57, 58, 48, 57, 48, 57, 58, 48, 
-       57, 48, 57, 43, 45, 46, 90, 48, 
-       57, 48, 57, 58, 48, 48, 34, 48, 
-       57, 43, 45, 90, 48, 57, 34, 44, 
-       34, 44, 34, 44, 34, 45, 91, 102, 
-       110, 116, 123, 48, 57, 34, 32, 93, 
-       125, 9, 13, 32, 44, 93, 9, 13, 
-       32, 93, 125, 9, 13, 97, 108, 115, 
-       101, 117, 108, 108, 114, 117, 101, 32, 
-       34, 125, 9, 13, 34, 32, 58, 9, 
-       13, 32, 93, 125, 9, 13, 32, 44, 
-       125, 9, 13, 32, 44, 125, 9, 13, 
-       32, 34, 9, 13, 32, 9, 13, 32, 
-       9, 13, 32, 9, 13, 32, 9, 13, 
-       32, 9, 13, 32, 9, 13, 0
-};
-
-static const char _json_single_lengths[] = {
-       0, 8, 1, 3, 3, 3, 1, 1, 
-       1, 1, 1, 1, 1, 1, 1, 1, 
-       3, 1, 2, 3, 3, 3, 2, 2, 
-       1, 3, 0, 2, 2, 0, 0, 3, 
-       2, 2, 9, 0, 0, 0, 0, 2, 
-       2, 1, 2, 0, 1, 1, 2, 0, 
-       0, 0, 0, 1, 0, 0, 1, 0, 
-       0, 1, 0, 0, 1, 0, 0, 1, 
-       0, 0, 4, 0, 0, 1, 1, 1, 
-       1, 0, 3, 2, 2, 2, 7, 1, 
-       0, 0, 3, 3, 3, 1, 1, 1, 
-       1, 0, 1, 1, 1, 0, 1, 1, 
-       1, 0, 3, 1, 2, 3, 3, 3, 
-       2, 0, 1, 1, 1, 1, 1, 1, 
-       0, 0, 0, 0, 0, 0
-};
-
-static const char _json_range_lengths[] = {
-       0, 2, 0, 1, 1, 1, 0, 0, 
-       0, 0, 0, 0, 0, 0, 0, 0, 
-       1, 0, 1, 1, 1, 1, 1, 1, 
-       1, 0, 1, 1, 1, 1, 1, 1, 
-       0, 0, 0, 3, 3, 3, 3, 0, 
-       1, 1, 0, 1, 1, 0, 1, 1, 
-       1, 1, 1, 0, 1, 1, 0, 1, 
-       1, 0, 1, 1, 0, 1, 1, 0, 
-       1, 1, 0, 1, 1, 0, 0, 0, 
-       0, 1, 1, 0, 0, 0, 1, 0, 
-       0, 0, 1, 1, 1, 0, 0, 0, 
-       0, 0, 0, 0, 0, 0, 0, 0, 
-       0, 0, 1, 0, 1, 1, 1, 1, 
-       1, 0, 1, 1, 1, 1, 1, 1, 
-       0, 0, 0, 0, 0, 0
-};
-
-static const short _json_index_offsets[] = {
-       0, 0, 11, 13, 18, 23, 28, 30, 
-       32, 34, 36, 38, 40, 42, 44, 46, 
-       48, 53, 55, 59, 64, 69, 74, 78, 
-       82, 85, 89, 91, 95, 99, 101, 103, 
-       108, 111, 114, 124, 128, 132, 136, 140, 
-       143, 147, 150, 153, 155, 158, 160, 164, 
-       166, 168, 170, 172, 174, 176, 178, 180, 
-       182, 184, 186, 188, 190, 192, 194, 196, 
-       198, 200, 202, 207, 209, 211, 213, 215, 
-       217, 219, 221, 226, 229, 232, 235, 244, 
-       246, 247, 248, 253, 258, 263, 265, 267, 
-       269, 271, 272, 274, 276, 278, 279, 281, 
-       283, 285, 286, 291, 293, 297, 302, 307, 
-       312, 316, 317, 320, 323, 326, 329, 332, 
-       335, 336, 337, 338, 339, 340
-};
-
-static const unsigned char _json_indicies[] = {
-       0, 2, 3, 4, 5, 6, 7, 8, 
-       0, 3, 1, 9, 1, 11, 12, 1, 
-       11, 10, 13, 14, 12, 13, 1, 14, 
-       1, 1, 14, 10, 15, 1, 16, 1, 
-       17, 1, 18, 1, 19, 1, 20, 1, 
-       21, 1, 22, 1, 23, 1, 24, 1, 
-       25, 26, 27, 25, 1, 28, 1, 29, 
-       30, 29, 1, 30, 1, 1, 30, 31, 
-       32, 33, 34, 32, 1, 35, 36, 27, 
-       35, 1, 36, 26, 36, 1, 37, 38, 
-       39, 1, 38, 39, 1, 41, 42, 42, 
-       40, 43, 1, 42, 42, 43, 40, 44, 
-       44, 45, 1, 45, 1, 45, 40, 41, 
-       42, 42, 39, 40, 47, 48, 46, 50, 
-       51, 49, 52, 52, 52, 52, 52, 52, 
-       52, 52, 53, 1, 54, 54, 54, 1, 
-       55, 55, 55, 1, 56, 56, 56, 1, 
-       57, 57, 57, 1, 59, 60, 58, 61, 
-       62, 63, 1, 64, 65, 1, 66, 67, 
-       1, 68, 1, 67, 68, 1, 69, 1, 
-       66, 67, 65, 1, 70, 1, 71, 1, 
-       72, 1, 73, 1, 74, 1, 75, 1, 
-       76, 1, 77, 1, 78, 1, 79, 1, 
-       80, 1, 81, 1, 82, 1, 83, 1, 
-       84, 1, 85, 1, 86, 1, 87, 1, 
-       88, 1, 89, 89, 90, 91, 1, 92, 
-       1, 93, 1, 94, 1, 95, 1, 96, 
-       1, 97, 1, 98, 1, 99, 99, 100, 
-       98, 1, 102, 1, 101, 104, 105, 103, 
-       1, 1, 101, 106, 107, 108, 109, 110, 
-       111, 112, 107, 1, 113, 1, 114, 115, 
-       117, 118, 1, 117, 116, 119, 120, 118, 
-       119, 1, 120, 1, 1, 120, 116, 121, 
-       1, 122, 1, 123, 1, 124, 1, 125, 
-       126, 1, 127, 1, 128, 1, 129, 130, 
-       1, 131, 1, 132, 1, 133, 134, 135, 
-       136, 134, 1, 137, 1, 138, 139, 138, 
-       1, 139, 1, 1, 139, 140, 141, 142, 
-       143, 141, 1, 144, 145, 136, 144, 1, 
-       145, 135, 145, 1, 146, 147, 147, 1, 
-       148, 148, 1, 149, 149, 1, 150, 150, 
-       1, 151, 151, 1, 152, 152, 1, 1, 
-       1, 1, 1, 1, 1, 0
-};
-
-static const char _json_trans_targs[] = {
-       1, 0, 2, 107, 3, 6, 10, 13, 
-       16, 106, 4, 3, 106, 4, 5, 7, 
-       8, 9, 108, 11, 12, 109, 14, 15, 
-       110, 16, 17, 111, 18, 18, 19, 20, 
-       21, 22, 111, 21, 22, 24, 25, 31, 
-       112, 26, 28, 27, 29, 30, 33, 113, 
-       34, 33, 113, 34, 32, 35, 36, 37, 
-       38, 39, 33, 113, 34, 41, 42, 46, 
-       42, 46, 43, 45, 44, 114, 48, 49, 
-       50, 51, 52, 53, 54, 55, 56, 57, 
-       58, 59, 60, 61, 62, 63, 64, 65, 
-       66, 67, 73, 72, 68, 69, 70, 71, 
-       72, 115, 74, 67, 72, 76, 116, 76, 
-       116, 77, 79, 81, 82, 85, 90, 94, 
-       98, 80, 117, 117, 83, 82, 80, 83, 
-       84, 86, 87, 88, 89, 117, 91, 92, 
-       93, 117, 95, 96, 97, 117, 98, 99, 
-       105, 100, 100, 101, 102, 103, 104, 105, 
-       103, 104, 117, 106, 106, 106, 106, 106, 
-       106
-};
-
-static const unsigned char _json_trans_actions[] = {
-       0, 0, 113, 107, 53, 0, 0, 0, 
-       125, 59, 45, 0, 55, 0, 0, 0, 
-       0, 0, 0, 0, 0, 0, 0, 0, 
-       0, 0, 101, 51, 47, 0, 0, 45, 
-       49, 49, 104, 0, 0, 0, 0, 0, 
-       3, 0, 0, 0, 0, 0, 5, 15, 
-       0, 0, 71, 7, 13, 0, 74, 9, 
-       9, 9, 77, 80, 11, 37, 37, 37, 
-       0, 0, 0, 39, 0, 41, 86, 0, 
-       0, 0, 17, 19, 0, 21, 23, 0, 
-       25, 27, 0, 29, 31, 0, 33, 35, 
-       0, 135, 83, 135, 0, 0, 0, 0, 
-       0, 92, 0, 89, 89, 98, 43, 0, 
-       131, 95, 113, 107, 53, 0, 0, 0, 
-       125, 59, 69, 110, 45, 0, 55, 0, 
-       0, 0, 0, 0, 0, 119, 0, 0, 
-       0, 122, 0, 0, 0, 116, 0, 101, 
-       51, 47, 0, 0, 45, 49, 49, 104, 
-       0, 0, 128, 0, 57, 63, 65, 61, 
-       67
-};
-
-static const unsigned char _json_eof_actions[] = {
-       0, 0, 0, 0, 0, 0, 0, 0, 
-       0, 0, 0, 0, 0, 0, 0, 0, 
-       0, 0, 0, 0, 0, 0, 0, 0, 
-       0, 1, 0, 1, 0, 0, 1, 1, 
-       0, 0, 0, 0, 0, 0, 0, 0, 
-       0, 0, 0, 0, 0, 0, 0, 0, 
-       0, 0, 0, 0, 0, 0, 0, 0, 
-       0, 0, 0, 0, 0, 0, 0, 0, 
-       0, 0, 0, 0, 0, 0, 0, 0, 
-       0, 0, 0, 0, 0, 0, 0, 0, 
-       0, 0, 0, 0, 0, 0, 0, 0, 
-       0, 0, 0, 0, 0, 0, 0, 0, 
-       0, 0, 0, 0, 0, 0, 0, 0, 
-       0, 0, 0, 57, 63, 65, 61, 67, 
-       0, 0, 0, 0, 0, 0
-};
-
-static const int json_start = 1;
-
-static const int json_en_number_machine = 23;
-static const int json_en_string_machine = 32;
-static const int json_en_duration_machine = 40;
-static const int json_en_timestamp_machine = 47;
-static const int json_en_fieldmask_machine = 75;
-static const int json_en_value_machine = 78;
-static const int json_en_main = 1;
-
-
-#line 2787 "upb/json/parser.rl"
-
-size_t parse(void *closure, const void *hd, const char *buf, size_t size,
-             const upb_bufhandle *handle) {
-  upb_json_parser *parser = closure;
-
-  /* Variables used by Ragel's generated code. */
-  int cs = parser->current_state;
-  int *stack = parser->parser_stack;
-  int top = parser->parser_top;
-
-  const char *p = buf;
-  const char *pe = buf + size;
-  const char *eof = &eof_ch;
-
-  parser->handle = handle;
-
-  UPB_UNUSED(hd);
-  UPB_UNUSED(handle);
-
-  capture_resume(parser, buf);
-
-  
-#line 2865 "upb/json/parser.c"
-       {
-       int _klen;
-       unsigned int _trans;
-       const char *_acts;
-       unsigned int _nacts;
-       const char *_keys;
-
-       if ( p == pe )
-               goto _test_eof;
-       if ( cs == 0 )
-               goto _out;
-_resume:
-       _keys = _json_trans_keys + _json_key_offsets[cs];
-       _trans = _json_index_offsets[cs];
-
-       _klen = _json_single_lengths[cs];
-       if ( _klen > 0 ) {
-               const char *_lower = _keys;
-               const char *_mid;
-               const char *_upper = _keys + _klen - 1;
-               while (1) {
-                       if ( _upper < _lower )
-                               break;
-
-                       _mid = _lower + ((_upper-_lower) >> 1);
-                       if ( (*p) < *_mid )
-                               _upper = _mid - 1;
-                       else if ( (*p) > *_mid )
-                               _lower = _mid + 1;
-                       else {
-                               _trans += (unsigned int)(_mid - _keys);
-                               goto _match;
-                       }
-               }
-               _keys += _klen;
-               _trans += _klen;
-       }
-
-       _klen = _json_range_lengths[cs];
-       if ( _klen > 0 ) {
-               const char *_lower = _keys;
-               const char *_mid;
-               const char *_upper = _keys + (_klen<<1) - 2;
-               while (1) {
-                       if ( _upper < _lower )
-                               break;
-
-                       _mid = _lower + (((_upper-_lower) >> 1) & ~1);
-                       if ( (*p) < _mid[0] )
-                               _upper = _mid - 2;
-                       else if ( (*p) > _mid[1] )
-                               _lower = _mid + 2;
-                       else {
-                               _trans += (unsigned int)((_mid - _keys)>>1);
-                               goto _match;
-                       }
-               }
-               _trans += _klen;
-       }
-
-_match:
-       _trans = _json_indicies[_trans];
-       cs = _json_trans_targs[_trans];
-
-       if ( _json_trans_actions[_trans] == 0 )
-               goto _again;
-
-       _acts = _json_actions + _json_trans_actions[_trans];
-       _nacts = (unsigned int) *_acts++;
-       while ( _nacts-- > 0 )
-       {
-               switch ( *_acts++ )
-               {
-       case 1:
-#line 2592 "upb/json/parser.rl"
-       { p--; {cs = stack[--top]; goto _again;} }
-       break;
-       case 2:
-#line 2594 "upb/json/parser.rl"
-       { p--; {stack[top++] = cs; cs = 23;goto _again;} }
-       break;
-       case 3:
-#line 2598 "upb/json/parser.rl"
-       { start_text(parser, p); }
-       break;
-       case 4:
-#line 2599 "upb/json/parser.rl"
-       { CHECK_RETURN_TOP(end_text(parser, p)); }
-       break;
-       case 5:
-#line 2605 "upb/json/parser.rl"
-       { start_hex(parser); }
-       break;
-       case 6:
-#line 2606 "upb/json/parser.rl"
-       { hexdigit(parser, p); }
-       break;
-       case 7:
-#line 2607 "upb/json/parser.rl"
-       { CHECK_RETURN_TOP(end_hex(parser)); }
-       break;
-       case 8:
-#line 2613 "upb/json/parser.rl"
-       { CHECK_RETURN_TOP(escape(parser, p)); }
-       break;
-       case 9:
-#line 2619 "upb/json/parser.rl"
-       { p--; {cs = stack[--top]; goto _again;} }
-       break;
-       case 10:
-#line 2624 "upb/json/parser.rl"
-       { start_year(parser, p); }
-       break;
-       case 11:
-#line 2625 "upb/json/parser.rl"
-       { CHECK_RETURN_TOP(end_year(parser, p)); }
-       break;
-       case 12:
-#line 2629 "upb/json/parser.rl"
-       { start_month(parser, p); }
-       break;
-       case 13:
-#line 2630 "upb/json/parser.rl"
-       { CHECK_RETURN_TOP(end_month(parser, p)); }
-       break;
-       case 14:
-#line 2634 "upb/json/parser.rl"
-       { start_day(parser, p); }
-       break;
-       case 15:
-#line 2635 "upb/json/parser.rl"
-       { CHECK_RETURN_TOP(end_day(parser, p)); }
-       break;
-       case 16:
-#line 2639 "upb/json/parser.rl"
-       { start_hour(parser, p); }
-       break;
-       case 17:
-#line 2640 "upb/json/parser.rl"
-       { CHECK_RETURN_TOP(end_hour(parser, p)); }
-       break;
-       case 18:
-#line 2644 "upb/json/parser.rl"
-       { start_minute(parser, p); }
-       break;
-       case 19:
-#line 2645 "upb/json/parser.rl"
-       { CHECK_RETURN_TOP(end_minute(parser, p)); }
-       break;
-       case 20:
-#line 2649 "upb/json/parser.rl"
-       { start_second(parser, p); }
-       break;
-       case 21:
-#line 2650 "upb/json/parser.rl"
-       { CHECK_RETURN_TOP(end_second(parser, p)); }
-       break;
-       case 22:
-#line 2655 "upb/json/parser.rl"
-       { start_duration_base(parser, p); }
-       break;
-       case 23:
-#line 2656 "upb/json/parser.rl"
-       { CHECK_RETURN_TOP(end_duration_base(parser, p)); }
-       break;
-       case 24:
-#line 2658 "upb/json/parser.rl"
-       { p--; {cs = stack[--top]; goto _again;} }
-       break;
-       case 25:
-#line 2663 "upb/json/parser.rl"
-       { start_timestamp_base(parser); }
-       break;
-       case 26:
-#line 2665 "upb/json/parser.rl"
-       { start_timestamp_fraction(parser, p); }
-       break;
-       case 27:
-#line 2666 "upb/json/parser.rl"
-       { CHECK_RETURN_TOP(end_timestamp_fraction(parser, p)); }
-       break;
-       case 28:
-#line 2668 "upb/json/parser.rl"
-       { start_timestamp_zone(parser, p); }
-       break;
-       case 29:
-#line 2669 "upb/json/parser.rl"
-       { CHECK_RETURN_TOP(end_timestamp_zone(parser, p)); }
-       break;
-       case 30:
-#line 2671 "upb/json/parser.rl"
-       { p--; {cs = stack[--top]; goto _again;} }
-       break;
-       case 31:
-#line 2676 "upb/json/parser.rl"
-       { start_fieldmask_path_text(parser, p); }
-       break;
-       case 32:
-#line 2677 "upb/json/parser.rl"
-       { end_fieldmask_path_text(parser, p); }
-       break;
-       case 33:
-#line 2682 "upb/json/parser.rl"
-       { start_fieldmask_path(parser); }
-       break;
-       case 34:
-#line 2683 "upb/json/parser.rl"
-       { end_fieldmask_path(parser); }
-       break;
-       case 35:
-#line 2689 "upb/json/parser.rl"
-       { p--; {cs = stack[--top]; goto _again;} }
-       break;
-       case 36:
-#line 2694 "upb/json/parser.rl"
-       {
-        if (is_wellknown_msg(parser, UPB_WELLKNOWN_TIMESTAMP)) {
-          {stack[top++] = cs; cs = 47;goto _again;}
-        } else if (is_wellknown_msg(parser, UPB_WELLKNOWN_DURATION)) {
-          {stack[top++] = cs; cs = 40;goto _again;}
-        } else if (is_wellknown_msg(parser, UPB_WELLKNOWN_FIELDMASK)) {
-          {stack[top++] = cs; cs = 75;goto _again;}
-        } else {
-          {stack[top++] = cs; cs = 32;goto _again;}
-        }
-      }
-       break;
-       case 37:
-#line 2707 "upb/json/parser.rl"
-       { p--; {stack[top++] = cs; cs = 78;goto _again;} }
-       break;
-       case 38:
-#line 2712 "upb/json/parser.rl"
-       {
-        if (is_wellknown_msg(parser, UPB_WELLKNOWN_ANY)) {
-          start_any_member(parser, p);
-        } else {
-          start_member(parser);
-        }
-      }
-       break;
-       case 39:
-#line 2719 "upb/json/parser.rl"
-       { CHECK_RETURN_TOP(end_membername(parser)); }
-       break;
-       case 40:
-#line 2722 "upb/json/parser.rl"
-       {
-        if (is_wellknown_msg(parser, UPB_WELLKNOWN_ANY)) {
-          end_any_member(parser, p);
-        } else {
-          end_member(parser);
-        }
-      }
-       break;
-       case 41:
-#line 2733 "upb/json/parser.rl"
-       {
-        if (is_wellknown_msg(parser, UPB_WELLKNOWN_ANY)) {
-          start_any_object(parser, p);
-        } else {
-          start_object(parser);
-        }
-      }
-       break;
-       case 42:
-#line 2742 "upb/json/parser.rl"
-       {
-        if (is_wellknown_msg(parser, UPB_WELLKNOWN_ANY)) {
-          CHECK_RETURN_TOP(end_any_object(parser, p));
-        } else {
-          end_object(parser);
-        }
-      }
-       break;
-       case 43:
-#line 2754 "upb/json/parser.rl"
-       { CHECK_RETURN_TOP(start_array(parser)); }
-       break;
-       case 44:
-#line 2758 "upb/json/parser.rl"
-       { end_array(parser); }
-       break;
-       case 45:
-#line 2763 "upb/json/parser.rl"
-       { CHECK_RETURN_TOP(start_number(parser, p)); }
-       break;
-       case 46:
-#line 2764 "upb/json/parser.rl"
-       { CHECK_RETURN_TOP(end_number(parser, p)); }
-       break;
-       case 47:
-#line 2766 "upb/json/parser.rl"
-       { CHECK_RETURN_TOP(start_stringval(parser)); }
-       break;
-       case 48:
-#line 2767 "upb/json/parser.rl"
-       { CHECK_RETURN_TOP(end_stringval(parser)); }
-       break;
-       case 49:
-#line 2769 "upb/json/parser.rl"
-       { CHECK_RETURN_TOP(end_bool(parser, true)); }
-       break;
-       case 50:
-#line 2771 "upb/json/parser.rl"
-       { CHECK_RETURN_TOP(end_bool(parser, false)); }
-       break;
-       case 51:
-#line 2773 "upb/json/parser.rl"
-       { CHECK_RETURN_TOP(end_null(parser)); }
-       break;
-       case 52:
-#line 2775 "upb/json/parser.rl"
-       { CHECK_RETURN_TOP(start_subobject_full(parser)); }
-       break;
-       case 53:
-#line 2776 "upb/json/parser.rl"
-       { end_subobject_full(parser); }
-       break;
-       case 54:
-#line 2781 "upb/json/parser.rl"
-       { p--; {cs = stack[--top]; goto _again;} }
-       break;
-#line 3189 "upb/json/parser.c"
-               }
-       }
-
-_again:
-       if ( cs == 0 )
-               goto _out;
-       if ( ++p != pe )
-               goto _resume;
-       _test_eof: {}
-       if ( p == eof )
-       {
-       const char *__acts = _json_actions + _json_eof_actions[cs];
-       unsigned int __nacts = (unsigned int) *__acts++;
-       while ( __nacts-- > 0 ) {
-               switch ( *__acts++ ) {
-       case 0:
-#line 2590 "upb/json/parser.rl"
-       { p--; {cs = stack[--top];      if ( p == pe )
-               goto _test_eof;
-goto _again;} }
-       break;
-       case 46:
-#line 2764 "upb/json/parser.rl"
-       { CHECK_RETURN_TOP(end_number(parser, p)); }
-       break;
-       case 49:
-#line 2769 "upb/json/parser.rl"
-       { CHECK_RETURN_TOP(end_bool(parser, true)); }
-       break;
-       case 50:
-#line 2771 "upb/json/parser.rl"
-       { CHECK_RETURN_TOP(end_bool(parser, false)); }
-       break;
-       case 51:
-#line 2773 "upb/json/parser.rl"
-       { CHECK_RETURN_TOP(end_null(parser)); }
-       break;
-       case 53:
-#line 2776 "upb/json/parser.rl"
-       { end_subobject_full(parser); }
-       break;
-#line 3231 "upb/json/parser.c"
-               }
-       }
-       }
-
-       _out: {}
-       }
-
-#line 2809 "upb/json/parser.rl"
-
-  if (p != pe) {
-    upb_status_seterrf(parser->status, "Parse error at '%.*s'\n", pe - p, p);
-  } else {
-    capture_suspend(parser, &p);
-  }
-
-error:
-  /* Save parsing state back to parser. */
-  parser->current_state = cs;
-  parser->parser_top = top;
-
-  return p - buf;
-}
-
-static bool end(void *closure, const void *hd) {
-  upb_json_parser *parser = closure;
-
-  /* Prevent compile warning on unused static constants. */
-  UPB_UNUSED(json_start);
-  UPB_UNUSED(json_en_duration_machine);
-  UPB_UNUSED(json_en_fieldmask_machine);
-  UPB_UNUSED(json_en_number_machine);
-  UPB_UNUSED(json_en_string_machine);
-  UPB_UNUSED(json_en_timestamp_machine);
-  UPB_UNUSED(json_en_value_machine);
-  UPB_UNUSED(json_en_main);
-
-  parse(parser, hd, &eof_ch, 0, NULL);
-
-  return parser->current_state >= 106;
-}
-
-static void json_parser_reset(upb_json_parser *p) {
-  int cs;
-  int top;
-
-  p->top = p->stack;
-  init_frame(p->top);
-
-  /* Emit Ragel initialization of the parser. */
-  
-#line 3282 "upb/json/parser.c"
-       {
-       cs = json_start;
-       top = 0;
-       }
-
-#line 2851 "upb/json/parser.rl"
-  p->current_state = cs;
-  p->parser_top = top;
-  accumulate_clear(p);
-  p->multipart_state = MULTIPART_INACTIVE;
-  p->capture = NULL;
-  p->accumulated = NULL;
-}
-
-static upb_json_parsermethod *parsermethod_new(upb_json_codecache *c,
-                                               const upb_msgdef *md) {
-  int i, n;
-  upb_alloc *alloc = upb_arena_alloc(c->arena);
-
-  upb_json_parsermethod *m = upb_malloc(alloc, sizeof(*m));
-
-  m->cache = c;
-
-  upb_byteshandler_init(&m->input_handler_);
-  upb_byteshandler_setstring(&m->input_handler_, parse, m);
-  upb_byteshandler_setendstr(&m->input_handler_, end, m);
-
-  upb_strtable_init2(&m->name_table, UPB_CTYPE_CONSTPTR, 4, alloc);
-
-  /* Build name_table */
-
-  n = upb_msgdef_fieldcount(md);
-  for(i = 0; i < n; i++) {
-    const upb_fielddef *f = upb_msgdef_field(md, i);
-    upb_value v = upb_value_constptr(f);
-    const char *name;
-
-    /* Add an entry for the JSON name. */
-    name = upb_fielddef_jsonname(f);
-    upb_strtable_insert3(&m->name_table, name, strlen(name), v, alloc);
-
-    if (strcmp(name, upb_fielddef_name(f)) != 0) {
-      /* Since the JSON name is different from the regular field name, add an
-       * entry for the raw name (compliant proto3 JSON parsers must accept
-       * both). */
-      const char *name = upb_fielddef_name(f);
-      upb_strtable_insert3(&m->name_table, name, strlen(name), v, alloc);
-    }
-  }
-
-  return m;
-}
-
-/* Public API *****************************************************************/
-
-upb_json_parser *upb_json_parser_create(upb_arena *arena,
-                                        const upb_json_parsermethod *method,
-                                        const upb_symtab* symtab,
-                                        upb_sink output,
-                                        upb_status *status,
-                                        bool ignore_json_unknown) {
-  upb_json_parser *p = upb_arena_malloc(arena, sizeof(upb_json_parser));
-  if (!p) return false;
-
-  p->arena = arena;
-  p->method = method;
-  p->status = status;
-  p->limit = p->stack + UPB_JSON_MAX_DEPTH;
-  p->accumulate_buf = NULL;
-  p->accumulate_buf_size = 0;
-  upb_bytessink_reset(&p->input_, &method->input_handler_, p);
-
-  json_parser_reset(p);
-  p->top->sink = output;
-  p->top->m = upb_handlers_msgdef(output.handlers);
-  if (is_wellknown_msg(p, UPB_WELLKNOWN_ANY)) {
-    p->top->is_any = true;
-    p->top->any_frame = json_parser_any_frame_new(p);
-  } else {
-    p->top->is_any = false;
-    p->top->any_frame = NULL;
-  }
-  set_name_table(p, p->top);
-  p->symtab = symtab;
-
-  p->ignore_json_unknown = ignore_json_unknown;
-
-  return p;
-}
-
-upb_bytessink upb_json_parser_input(upb_json_parser *p) {
-  return p->input_;
-}
-
-const upb_byteshandler *upb_json_parsermethod_inputhandler(
-    const upb_json_parsermethod *m) {
-  return &m->input_handler_;
-}
-
-upb_json_codecache *upb_json_codecache_new(void) {
-  upb_alloc *alloc;
-  upb_json_codecache *c;
-
-  c = upb_gmalloc(sizeof(*c));
-
-  c->arena = upb_arena_new();
-  alloc = upb_arena_alloc(c->arena);
-
-  upb_inttable_init2(&c->methods, UPB_CTYPE_CONSTPTR, alloc);
-
-  return c;
-}
-
-void upb_json_codecache_free(upb_json_codecache *c) {
-  upb_arena_free(c->arena);
-  upb_gfree(c);
-}
-
-const upb_json_parsermethod *upb_json_codecache_get(upb_json_codecache *c,
-                                                    const upb_msgdef *md) {
-  upb_json_parsermethod *m;
-  upb_value v;
-  int i, n;
-  upb_alloc *alloc = upb_arena_alloc(c->arena);
-
-  if (upb_inttable_lookupptr(&c->methods, md, &v)) {
-    return upb_value_getconstptr(v);
-  }
-
-  m = parsermethod_new(c, md);
-  v = upb_value_constptr(m);
-
-  if (!m) return NULL;
-  if (!upb_inttable_insertptr2(&c->methods, md, v, alloc)) return NULL;
-
-  /* Populate parser methods for all submessages, so the name tables will
-   * be available during parsing. */
-  n = upb_msgdef_fieldcount(md);
-  for(i = 0; i < n; i++) {
-    const upb_fielddef *f = upb_msgdef_field(md, i);
-
-    if (upb_fielddef_issubmsg(f)) {
-      const upb_msgdef *subdef = upb_fielddef_msgsubdef(f);
-      const upb_json_parsermethod *sub_method =
-          upb_json_codecache_get(c, subdef);
-
-      if (!sub_method) return NULL;
-    }
-  }
-
-  return m;
-}
index 9711925..15b59af 100644 (file)
@@ -1,3 +1,28 @@
+# Copyright (c) 2009-2021, Google LLC
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions are met:
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in the
+#       documentation and/or other materials provided with the distribution.
+#     * Neither the name of Google LLC nor the
+#       names of its contributors may be used to endorse or promote products
+#       derived from this software without specific prior written permission.
+#
+# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+# DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+# DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+# (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+# ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
 load("@rules_proto//proto:defs.bzl", "proto_library")
 load("@upb//bazel:upb_proto_library.bzl", "upb_proto_library")
 
index 98617cf..a4277c3 100644 (file)
@@ -1,3 +1,29 @@
+/*
+ * Copyright (c) 2009-2021, Google LLC
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ *     * Redistributions of source code must retain the above copyright
+ *       notice, this list of conditions and the following disclaimer.
+ *     * Redistributions in binary form must reproduce the above copyright
+ *       notice, this list of conditions and the following disclaimer in the
+ *       documentation and/or other materials provided with the distribution.
+ *     * Neither the name of Google LLC nor the
+ *       names of its contributors may be used to endorse or promote products
+ *       derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+ * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ * DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+ * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+ * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+ * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
 
 #include <time.h>
 
index c95ee88..64536f6 100644 (file)
@@ -1,10 +1,35 @@
-#!/bin/bash
+#!/bin/bash -eu
+#
+# Copyright (c) 2009-2021, Google LLC
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions are met:
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in the
+#       documentation and/or other materials provided with the distribution.
+#     * Neither the name of Google LLC nor the
+#       names of its contributors may be used to endorse or promote products
+#       derived from this software without specific prior written permission.
+#
+# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+# DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+# DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+# (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+# ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 
 set -ex
 
 # Install the latest version of Bazel.
 if [ -x "$(command -v use_bazel.sh)" ]; then
-  use_bazel.sh latest
+  use_bazel.sh 4.1.0
 fi
 
 # Verify/query CMake
index ad12fce..017c9b7 100644 (file)
@@ -1,3 +1,28 @@
+# Copyright (c) 2009-2021, Google LLC
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions are met:
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in the
+#       documentation and/or other materials provided with the distribution.
+#     * Neither the name of Google LLC nor the
+#       names of its contributors may be used to endorse or promote products
+#       derived from this software without specific prior written permission.
+#
+# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+# DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+# DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+# (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+# ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
 load(
     "//bazel:build_defs.bzl",
     "UPB_DEFAULT_COPTS",
@@ -24,12 +49,10 @@ cc_library(
         "testmain.cc",
     ],
     hdrs = [
-        "test_util.h",
         "upb_test.h",
     ],
     copts = UPB_DEFAULT_CPPOPTS,
     deps = [
-        "//:handlers",
         "//:port",
         "//:upb",
     ],
@@ -77,55 +100,34 @@ upb_proto_library(
 )
 
 proto_library(
-    name = "test_decoder_proto",
-    srcs = [
-        "pb/test_decoder.proto",
-    ],
-)
-
-upb_proto_reflection_library(
-    name = "test_decoder_upb_proto",
-    deps = [":test_decoder_proto"],
-)
-
-cc_test(
-    name = "test_decoder",
-    srcs = ["pb/test_decoder.cc"],
-    copts = UPB_DEFAULT_CPPOPTS,
-    deps = [
-        ":test_decoder_upb_proto",
-        ":upb_test",
-        "//:handlers",
-        "//:port",
-        "//:upb",
-        "//:upb_pb",
-    ],
-)
-
-proto_library(
     name = "test_cpp_proto",
     srcs = [
         "test_cpp.proto",
     ],
 )
 
-upb_proto_reflection_library(
+upb_proto_library(
     name = "test_cpp_upb_proto",
     deps = ["test_cpp_proto"],
 )
 
+upb_proto_reflection_library(
+    name = "test_cpp_upb_proto_reflection",
+    deps = ["test_cpp_proto"],
+)
+
 cc_test(
     name = "test_cpp",
     srcs = ["test_cpp.cc"],
     copts = UPB_DEFAULT_CPPOPTS,
     deps = [
         ":test_cpp_upb_proto",
+        ":test_cpp_upb_proto_reflection",
         ":upb_test",
-        "//:handlers",
+        "//:json",
         "//:port",
         "//:reflection",
         "//:upb",
-        "//:upb_pb",
     ],
 )
 
@@ -160,61 +162,6 @@ cc_binary(
     ],
 )
 
-# copybara:strip_for_google3_begin
-cc_test(
-    name = "test_encoder",
-    srcs = ["pb/test_encoder.cc"],
-    copts = UPB_DEFAULT_CPPOPTS,
-    deps = [
-        ":upb_test",
-        "//:descriptor_upb_proto",
-        "//:descriptor_upb_proto_reflection",
-        "//:upb",
-        "//:upb_pb",
-    ],
-)
-
-proto_library(
-    name = "test_json_enum_from_separate",
-    srcs = ["json/enum_from_separate_file.proto"],
-    deps = [":test_json_proto"],
-)
-
-proto_library(
-    name = "test_json_proto",
-    srcs = ["json/test.proto"],
-)
-
-upb_proto_reflection_library(
-    name = "test_json_upb_proto_reflection",
-    deps = ["test_json_proto"],
-)
-
-upb_proto_library(
-    name = "test_json_enum_from_separate_upb_proto",
-    deps = [":test_json_enum_from_separate"],
-)
-
-upb_proto_library(
-    name = "test_json_upb_proto",
-    deps = [":test_json_proto"],
-)
-
-cc_test(
-    name = "test_json",
-    srcs = [
-        "json/test_json.cc",
-    ],
-    copts = UPB_DEFAULT_CPPOPTS,
-    deps = [
-        ":test_json_upb_proto",
-        ":test_json_upb_proto_reflection",
-        ":upb_test",
-        "//:upb_json",
-    ],
-)
-# copybara:strip_end
-
 upb_proto_library(
     name = "conformance_proto_upb",
     testonly = 1,
index a065b1d..5a4f805 100644 (file)
@@ -1,3 +1,28 @@
+# Copyright (c) 2009-2021, Google LLC
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions are met:
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in the
+#       documentation and/or other materials provided with the distribution.
+#     * Neither the name of Google LLC nor the
+#       names of its contributors may be used to endorse or promote products
+#       derived from this software without specific prior written permission.
+#
+# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+# DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+# DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+# (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+# ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
 load(
     "//upb/bindings/lua:lua_proto_library.bzl",
     "lua_proto_library",
@@ -37,6 +62,7 @@ proto_library(
     name = "test_proto",
     testonly = 1,
     srcs = ["test.proto"],
+    deps = ["@com_google_protobuf//:timestamp_proto"],
 )
 
 lua_proto_library(
index 6e48cca..40f72a2 100644 (file)
@@ -1,3 +1,29 @@
+/*
+ * Copyright (c) 2009-2021, Google LLC
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ *     * Redistributions of source code must retain the above copyright
+ *       notice, this list of conditions and the following disclaimer.
+ *     * Redistributions in binary form must reproduce the above copyright
+ *       notice, this list of conditions and the following disclaimer in the
+ *       documentation and/or other materials provided with the distribution.
+ *     * Neither the name of Google LLC nor the
+ *       names of its contributors may be used to endorse or promote products
+ *       derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+ * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ * DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+ * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+ * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+ * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
 
 #include <lauxlib.h>
 #include <lua.h>
index 6b45350..4c3b64e 100644 (file)
@@ -1,6 +1,8 @@
 
 syntax = "proto2";
 
+import "google/protobuf/timestamp.proto";
+
 package upb_test;
 
 message MapTest {
@@ -26,3 +28,7 @@ message UnpackedTest {
 message TestLargeFieldNumber {
   optional int32 i32 = 456214797;
 }
+
+message TestTimestamp {
+  optional google.protobuf.Timestamp ts = 1;
+}
index e2d5345..9846897 100644 (file)
@@ -1,3 +1,31 @@
+--[[--------------------------------------------------------------------------
+
+  Copyright (c) 2009-2021, Google LLC
+  All rights reserved.
+
+  Redistribution and use in source and binary forms, with or without
+  modification, are permitted provided that the following conditions are met:
+      * Redistributions of source code must retain the above copyright
+        notice, this list of conditions and the following disclaimer.
+      * Redistributions in binary form must reproduce the above copyright
+        notice, this list of conditions and the following disclaimer in the
+        documentation and/or other materials provided with the distribution.
+      * Neither the name of Google LLC nor the
+        names of its contributors may be used to endorse or promote products
+        derived from this software without specific prior written permission.
+
+  THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+  ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+  WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+  DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+  DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+  (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+  LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+  ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+  (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+  SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+--]]--------------------------------------------------------------------------
 
 local upb = require "lupb"
 local lunit = require "lunit"
@@ -321,6 +349,16 @@ function test_msg_array()
   assert_error_match("array expected", function() msg.repeated_int32 = print end)
 end
 
+function test_array_append()
+  local arr = upb.Array(upb.TYPE_INT32)
+  for i=1,200000 do
+    arr[i] = i
+  end
+  for i=1,200000 do
+    assert_equal(i, arr[i])
+  end
+end
+
 function test_msg_submsg()
   --msg = test_messages_proto3.TestAllTypesProto3()
   msg = test_messages_proto3['TestAllTypesProto3']()
@@ -679,6 +717,15 @@ function test_descriptor_error()
   assert_nil(symtab:lookup_msg("ABC"))
 end
 
+function test_duplicate_filename_error()
+  local symtab = upb.SymbolTable()
+  local file = descriptor.FileDescriptorProto()
+  file.name = "test.proto"
+  symtab:add_file(upb.encode(file))
+  -- Second add with the same filename fails.
+  assert_error(function () symtab:add_file(upb.encode(file)) end)
+end
+
 function test_encode_skipunknown()
   -- Test that upb.ENCODE_SKIPUNKNOWN does not encode unknown fields.
   local msg = test_messages_proto3.TestAllTypesProto3{
@@ -700,6 +747,17 @@ function test_json_emit_defaults()
   local json = upb.json_encode(msg, {upb.JSONENC_EMITDEFAULTS})
 end
 
+function test_json_locale()
+  local msg = test_messages_proto3.TestAllTypesProto3()
+  msg.optional_double = 1.1
+  local original_locale = os.setlocale(nil)
+  os.setlocale("C")
+  local json = upb.json_encode(msg)
+  os.setlocale("de_DE.utf8")
+  assert_equal(json, upb.json_encode(msg))
+  os.setlocale(original_locale)  -- Restore.
+end
+
 function test_encode_depth_limit()
   local msg = test_messages_proto3.TestAllTypesProto3()
   msg.recursive_message = msg
@@ -714,6 +772,11 @@ function test_large_field_number()
   assert_equal(msg.i32, msg2.i32)
 end
 
+function test_timestamp_minutes()
+  local msg = upb.json_decode(upb_test.TestTimestamp, '{"ts": "2000-01-01T00:00:00-06:59"}')
+  assert_equal(msg.ts.seconds, 946684800 + ((6 * 60) + 59) * 60)
+end
+
 function test_gc()
   local top = test_messages_proto3.TestAllTypesProto3()
   local n = 100
index f444180..12c7f1f 100644 (file)
@@ -1,3 +1,30 @@
+/*
+ * Copyright (c) 2009-2021, Google LLC
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ *     * Redistributions of source code must retain the above copyright
+ *       notice, this list of conditions and the following disclaimer.
+ *     * Redistributions in binary form must reproduce the above copyright
+ *       notice, this list of conditions and the following disclaimer in the
+ *       documentation and/or other materials provided with the distribution.
+ *     * Neither the name of Google LLC nor the
+ *       names of its contributors may be used to endorse or promote products
+ *       derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+ * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ * DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+ * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+ * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+ * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
 /* This is a upb implementation of the upb conformance tests, see:
  *   https://github.com/google/protobuf/tree/master/conformance
  */
index 2bf1160..c8f2691 100644 (file)
@@ -1 +1,26 @@
+// Copyright (c) 2009-2021, Google LLC
+// All rights reserved.
+//
+// Redistribution and use in source and binary forms, with or without
+// modification, are permitted provided that the following conditions are met:
+//     * Redistributions of source code must retain the above copyright
+//       notice, this list of conditions and the following disclaimer.
+//     * Redistributions in binary form must reproduce the above copyright
+//       notice, this list of conditions and the following disclaimer in the
+//       documentation and/or other materials provided with the distribution.
+//     * Neither the name of Google LLC nor the
+//       names of its contributors may be used to endorse or promote products
+//       derived from this software without specific prior written permission.
+//
+// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+// WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+// DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+// DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+// (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+// LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+// ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+// SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
 // Hello World
index 966a468..55fff04 100644 (file)
@@ -1,3 +1,28 @@
+// Copyright (c) 2009-2021, Google LLC
+// All rights reserved.
+//
+// Redistribution and use in source and binary forms, with or without
+// modification, are permitted provided that the following conditions are met:
+//     * Redistributions of source code must retain the above copyright
+//       notice, this list of conditions and the following disclaimer.
+//     * Redistributions in binary form must reproduce the above copyright
+//       notice, this list of conditions and the following disclaimer in the
+//       documentation and/or other materials provided with the distribution.
+//     * Neither the name of Google LLC nor the
+//       names of its contributors may be used to endorse or promote products
+//       derived from this software without specific prior written permission.
+//
+// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+// WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+// DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+// DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+// (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+// LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+// ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+// SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
 #include <cstdint>
 
 #include "google/protobuf/descriptor.upb.h"
diff --git a/third_party/upb/tests/json/enum_from_separate_file.proto b/third_party/upb/tests/json/enum_from_separate_file.proto
deleted file mode 100644 (file)
index ceb9b42..0000000
+++ /dev/null
@@ -1,9 +0,0 @@
-syntax = "proto2";
-
-import "tests/json/test.proto";
-
-package upb.test.json;
-
-message ImportEnum {
-  optional MyEnum e = 1;
-}
diff --git a/third_party/upb/tests/json/test.proto b/third_party/upb/tests/json/test.proto
deleted file mode 100644 (file)
index 2db0388..0000000
+++ /dev/null
@@ -1,47 +0,0 @@
-syntax = "proto3";
-
-package upb.test.json;
-
-message TestMessage {
-  int32 optional_int32  = 1;
-  int64 optional_int64  = 2;
-  int32 optional_uint32  = 3;
-  int64 optional_uint64  = 4;
-  string optional_string  = 5;
-  bytes optional_bytes  = 6;
-  bool optional_bool  = 7;
-  SubMessage optional_msg  = 8;
-  MyEnum optional_enum = 9;
-
-  repeated int32 repeated_int32 = 11;
-  repeated int64 repeated_int64 = 12;
-  repeated uint32 repeated_uint32 = 13;
-  repeated uint64 repeated_uint64 = 14;
-  repeated string repeated_string = 15;
-  repeated bytes repeated_bytes = 16;
-  repeated bool repeated_bool = 17;
-  repeated SubMessage repeated_msg = 18;
-  repeated MyEnum repeated_enum = 19;
-
-  map<string, string>     map_string_string = 20;
-  map<int32,  string>     map_int32_string = 21;
-  map<bool,   string>     map_bool_string = 22;
-  map<string, int32>      map_string_int32 = 23;
-  map<string, bool>       map_string_bool = 24;
-  map<string, SubMessage> map_string_msg = 25;
-
-  oneof o {
-    int32 oneof_int32 = 26;
-    int64 oneof_int64 = 27;
-  }
-}
-
-message SubMessage {
-  int32 foo = 1;
-}
-
-enum MyEnum {
-  A = 0;
-  B = 1;
-  C = 2;
-}
diff --git a/third_party/upb/tests/json/test.proto.pb b/third_party/upb/tests/json/test.proto.pb
deleted file mode 100644 (file)
index 94b8b92..0000000
Binary files a/third_party/upb/tests/json/test.proto.pb and /dev/null differ
diff --git a/third_party/upb/tests/json/test_json.cc b/third_party/upb/tests/json/test_json.cc
deleted file mode 100644 (file)
index 18ab07f..0000000
+++ /dev/null
@@ -1,336 +0,0 @@
-/*
- *
- * A set of tests for JSON parsing and serialization.
- */
-
-#include <string>
-
-#include "tests/json/test.upb.h"  // Test that it compiles for C++.
-#include "tests/json/test.upbdefs.h"
-#include "tests/test_util.h"
-#include "tests/upb_test.h"
-#include "upb/def.hpp"
-#include "upb/handlers.h"
-#include "upb/json/parser.h"
-#include "upb/json/printer.h"
-#include "upb/port_def.inc"
-#include "upb/upb.h"
-
-// Macros for readability in test case list: allows us to give TEST("...") /
-// EXPECT("...") pairs.
-#define TEST(x)     x
-#define EXPECT_SAME NULL
-#define EXPECT(x)   x
-#define TEST_SENTINEL { NULL, NULL }
-
-struct TestCase {
-  const char* input;
-  const char* expected;
-};
-
-bool verbose = false;
-
-static TestCase kTestRoundtripMessages[] = {
-  // Test most fields here.
-  {
-    TEST("{\"optionalInt32\":-42,\"optionalString\":\"Test\\u0001Message\","
-         "\"optionalMsg\":{\"foo\":42},"
-         "\"optionalBool\":true,\"repeatedMsg\":[{\"foo\":1},"
-         "{\"foo\":2}]}"),
-    EXPECT_SAME
-  },
-  // We must also recognize raw proto names.
-  {
-    TEST("{\"optional_int32\":-42,\"optional_string\":\"Test\\u0001Message\","
-         "\"optional_msg\":{\"foo\":42},"
-         "\"optional_bool\":true,\"repeated_msg\":[{\"foo\":1},"
-         "{\"foo\":2}]}"),
-    EXPECT("{\"optionalInt32\":-42,\"optionalString\":\"Test\\u0001Message\","
-           "\"optionalMsg\":{\"foo\":42},"
-           "\"optionalBool\":true,\"repeatedMsg\":[{\"foo\":1},"
-           "{\"foo\":2}]}")
-  },
-  // Test special escapes in strings.
-  {
-    TEST("{\"repeatedString\":[\"\\b\",\"\\r\",\"\\n\",\"\\f\",\"\\t\","
-         "\"\uFFFF\"]}"),
-    EXPECT_SAME
-  },
-  // Test enum symbolic names.
-  {
-    // The common case: parse and print the symbolic name.
-    TEST("{\"optionalEnum\":\"A\"}"),
-    EXPECT_SAME
-  },
-  {
-    // Unknown enum value: will be printed as an integer.
-    TEST("{\"optionalEnum\":42}"),
-    EXPECT_SAME
-  },
-  {
-    // Known enum value: we're happy to parse an integer but we will re-emit the
-    // symbolic name.
-    TEST("{\"optionalEnum\":1}"),
-    EXPECT("{\"optionalEnum\":\"B\"}")
-  },
-  // UTF-8 tests: escapes -> literal UTF8 in output.
-  {
-    // Note double escape on \uXXXX: we want the escape to be processed by the
-    // JSON parser, not by the C++ compiler!
-    TEST("{\"optionalString\":\"\\u007F\"}"),
-    EXPECT("{\"optionalString\":\"\x7F\"}")
-  },
-  {
-    TEST("{\"optionalString\":\"\\u0080\"}"),
-    EXPECT("{\"optionalString\":\"\xC2\x80\"}")
-  },
-  {
-    TEST("{\"optionalString\":\"\\u07FF\"}"),
-    EXPECT("{\"optionalString\":\"\xDF\xBF\"}")
-  },
-  {
-    TEST("{\"optionalString\":\"\\u0800\"}"),
-    EXPECT("{\"optionalString\":\"\xE0\xA0\x80\"}")
-  },
-  {
-    TEST("{\"optionalString\":\"\\uFFFF\"}"),
-    EXPECT("{\"optionalString\":\"\xEF\xBF\xBF\"}")
-  },
-  // map-field tests
-  {
-    TEST("{\"mapStringString\":{\"a\":\"value1\",\"b\":\"value2\","
-         "\"c\":\"value3\"}}"),
-    EXPECT_SAME
-  },
-  {
-    TEST("{\"mapInt32String\":{\"1\":\"value1\",\"-1\":\"value2\","
-         "\"1234\":\"value3\"}}"),
-    EXPECT_SAME
-  },
-  {
-    TEST("{\"mapBoolString\":{\"false\":\"value1\",\"true\":\"value2\"}}"),
-    EXPECT_SAME
-  },
-  {
-    TEST("{\"mapStringInt32\":{\"asdf\":1234,\"jkl;\":-1}}"),
-    EXPECT_SAME
-  },
-  {
-    TEST("{\"mapStringBool\":{\"asdf\":true,\"jkl;\":false}}"),
-    EXPECT_SAME
-  },
-  {
-    TEST("{\"mapStringMsg\":{\"asdf\":{\"foo\":42},\"jkl;\":{\"foo\":84}}}"),
-    EXPECT_SAME
-  },
-  TEST_SENTINEL
-};
-
-static TestCase kTestRoundtripMessagesPreserve[] = {
-  // Test most fields here.
-  {
-    TEST("{\"optional_int32\":-42,\"optional_string\":\"Test\\u0001Message\","
-         "\"optional_msg\":{\"foo\":42},"
-         "\"optional_bool\":true,\"repeated_msg\":[{\"foo\":1},"
-         "{\"foo\":2}]}"),
-    EXPECT_SAME
-  },
-  TEST_SENTINEL
-};
-
-static TestCase kTestSkipUnknown[] = {
-  {
-    TEST("{\"optionalEnum\":\"UNKNOWN_ENUM_VALUE\"}"),
-    EXPECT("{}"),
-  },
-  TEST_SENTINEL
-};
-
-static TestCase kTestFailure[] = {
-  {
-    TEST("{\"optionalEnum\":\"UNKNOWN_ENUM_VALUE\"}"),
-    EXPECT("{}"),  /* Actually we expect error, this is checked later. */
-  },
-  TEST_SENTINEL
-};
-
-class StringSink {
- public:
-  StringSink() {
-    upb_byteshandler_init(&byteshandler_);
-    upb_byteshandler_setstring(&byteshandler_, &str_handler, NULL);
-    upb_bytessink_reset(&bytessink_, &byteshandler_, &s_);
-  }
-  ~StringSink() { }
-
-  upb_bytessink Sink() { return bytessink_; }
-
-  const std::string& Data() { return s_; }
-
- private:
-
-  static size_t str_handler(void* _closure, const void* hd,
-                            const char* data, size_t len,
-                            const upb_bufhandle* handle) {
-    UPB_UNUSED(hd);
-    UPB_UNUSED(handle);
-    std::string* s = static_cast<std::string*>(_closure);
-    std::string appended(data, len);
-    s->append(data, len);
-    return len;
-  }
-
-  upb_byteshandler byteshandler_;
-  upb_bytessink bytessink_;
-  std::string s_;
-};
-
-void test_json_roundtrip_message(const char* json_src,
-                                 const char* json_expected,
-                                 const upb::Handlers* serialize_handlers,
-                                 const upb::json::ParserMethodPtr parser_method,
-                                 int seam,
-                                 bool ignore_unknown) {
-  VerboseParserEnvironment env(verbose);
-  StringSink data_sink;
-  upb::json::PrinterPtr printer = upb::json::PrinterPtr::Create(
-      env.arena(), serialize_handlers, data_sink.Sink());
-  upb::json::ParserPtr parser = upb::json::ParserPtr::Create(
-      env.arena(), parser_method, NULL, printer.input(),
-      env.status(), ignore_unknown);
-  env.ResetBytesSink(parser.input());
-  env.Reset(json_src, strlen(json_src), false, false);
-
-  bool ok = env.Start() &&
-            env.ParseBuffer(seam) &&
-            env.ParseBuffer(-1) &&
-            env.End();
-
-  ASSERT(ok);
-  ASSERT(env.CheckConsistency());
-
-  if (memcmp(json_expected,
-             data_sink.Data().data(),
-             data_sink.Data().size())) {
-    fprintf(stderr,
-            "JSON parse/serialize roundtrip result differs:\n"
-            "Expected:\n%s\nParsed/Serialized:\n%s\n",
-            json_expected, data_sink.Data().c_str());
-    abort();
-  }
-}
-
-// Starts with a message in JSON format, parses and directly serializes again,
-// and compares the result.
-void test_json_roundtrip() {
-  upb::SymbolTable symtab;
-  upb::HandlerCache serialize_handlercache(
-      upb::json::PrinterPtr::NewCache(false));
-  upb::json::CodeCache parse_codecache;
-
-  upb::MessageDefPtr md(upb_test_json_TestMessage_getmsgdef(symtab.ptr()));
-  ASSERT(md);
-  const upb::Handlers* serialize_handlers = serialize_handlercache.Get(md);
-  const upb::json::ParserMethodPtr parser_method = parse_codecache.Get(md);
-  ASSERT(serialize_handlers);
-
-  for (const TestCase* test_case = kTestRoundtripMessages;
-       test_case->input != NULL; test_case++) {
-    const char *expected =
-        (test_case->expected == EXPECT_SAME) ?
-        test_case->input :
-        test_case->expected;
-
-    for (size_t i = 0; i < strlen(test_case->input); i++) {
-      test_json_roundtrip_message(test_case->input, expected,
-                                  serialize_handlers, parser_method, (int)i,
-                                  false);
-    }
-  }
-
-  // Tests ignore unknown.
-  for (const TestCase* test_case = kTestSkipUnknown;
-       test_case->input != NULL; test_case++) {
-    const char *expected =
-        (test_case->expected == EXPECT_SAME) ?
-        test_case->input :
-        test_case->expected;
-
-    for (size_t i = 0; i < strlen(test_case->input); i++) {
-      test_json_roundtrip_message(test_case->input, expected,
-                                  serialize_handlers, parser_method, (int)i,
-                                  true);
-    }
-  }
-
-  serialize_handlercache = upb::json::PrinterPtr::NewCache(true);
-  serialize_handlers = serialize_handlercache.Get(md);
-
-  for (const TestCase* test_case = kTestRoundtripMessagesPreserve;
-       test_case->input != NULL; test_case++) {
-    const char *expected =
-        (test_case->expected == EXPECT_SAME) ?
-        test_case->input :
-        test_case->expected;
-
-    for (size_t i = 0; i < strlen(test_case->input); i++) {
-      test_json_roundtrip_message(test_case->input, expected,
-                                  serialize_handlers, parser_method, (int)i,
-                                  false);
-    }
-  }
-}
-
-void test_json_parse_failure(const char* json_src,
-                             const upb::Handlers* serialize_handlers,
-                             const upb::json::ParserMethodPtr parser_method,
-                             int seam) {
-  VerboseParserEnvironment env(verbose);
-  StringSink data_sink;
-  upb::json::PrinterPtr printer = upb::json::PrinterPtr::Create(
-      env.arena(), serialize_handlers, data_sink.Sink());
-  upb::json::ParserPtr parser = upb::json::ParserPtr::Create(
-      env.arena(), parser_method, NULL, printer.input(), env.status(), false);
-  env.ResetBytesSink(parser.input());
-  env.Reset(json_src, strlen(json_src), false, true);
-
-  bool ok = env.Start() &&
-            env.ParseBuffer(seam) &&
-            env.ParseBuffer(-1) &&
-            env.End();
-
-  ASSERT(!ok);
-  ASSERT(env.CheckConsistency());
-}
-
-// Starts with a proto message in JSON format, parses and expects failre.
-void test_json_failure() {
-  upb::SymbolTable symtab;
-  upb::HandlerCache serialize_handlercache(
-      upb::json::PrinterPtr::NewCache(false));
-  upb::json::CodeCache parse_codecache;
-
-  upb::MessageDefPtr md(upb_test_json_TestMessage_getmsgdef(symtab.ptr()));
-  ASSERT(md);
-  const upb::Handlers* serialize_handlers = serialize_handlercache.Get(md);
-  const upb::json::ParserMethodPtr parser_method = parse_codecache.Get(md);
-  ASSERT(serialize_handlers);
-
-  for (const TestCase* test_case = kTestFailure;
-       test_case->input != NULL; test_case++) {
-    for (size_t i = 0; i < strlen(test_case->input); i++) {
-      test_json_parse_failure(test_case->input, serialize_handlers,
-                              parser_method, (int)i);
-    }
-  }
-}
-
-extern "C" {
-int run_tests(int argc, char *argv[]) {
-  UPB_UNUSED(argc);
-  UPB_UNUSED(argv);
-  test_json_roundtrip();
-  test_json_failure();
-  return 0;
-}
-}
diff --git a/third_party/upb/tests/pb/test_decoder.cc b/third_party/upb/tests/pb/test_decoder.cc
deleted file mode 100644 (file)
index 110dd2f..0000000
+++ /dev/null
@@ -1,1194 +0,0 @@
-/*
- *
- * An exhaustive set of tests for parsing both valid and invalid protobuf
- * input, with buffer breaks in arbitrary places.
- *
- * Tests to add:
- * - string/bytes
- * - unknown field handler called appropriately
- * - unknown fields can be inserted in random places
- * - fuzzing of valid input
- * - resource limits (max stack depth, max string len)
- * - testing of groups
- * - more throrough testing of sequences
- * - test skipping of submessages
- * - test suspending the decoder
- * - buffers that are close enough to the end of the address space that
- *   pointers overflow (this might be difficult).
- * - a few "kitchen sink" examples (one proto that uses all types, lots
- *   of submsg/sequences, etc.
- * - test different handlers at every level and whether handlers fire at
- *   the correct field path.
- * - test skips that extend past the end of current buffer (where decoder
- *   returns value greater than the size param).
- */
-
-#ifndef __STDC_FORMAT_MACROS
-#define __STDC_FORMAT_MACROS  // For PRIuS, etc.
-#endif
-
-#include <inttypes.h>
-#include <stdarg.h>
-#include <stdint.h>
-#include <stdlib.h>
-#include <string.h>
-#include <sstream>
-
-#include "tests/test_util.h"
-#include "tests/upb_test.h"
-#include "tests/pb/test_decoder.upbdefs.h"
-
-#ifdef AMALGAMATED
-#include "upb.h"
-#else  // AMALGAMATED
-#include "upb/handlers.h"
-#include "upb/pb/decoder.h"
-#include "upb/upb.h"
-#endif  // !AMALGAMATED
-
-#include "upb/port_def.inc"
-
-#undef PRINT_FAILURE
-#define PRINT_FAILURE(expr)                                           \
-  fprintf(stderr, "Assertion failed: %s:%d\n", __FILE__, __LINE__);   \
-  fprintf(stderr, "expr: %s\n", #expr);                               \
-
-#define MAX_NESTING 64
-
-#define LINE(x) x "\n"
-
-uint32_t filter_hash = 0;
-double completed;
-double total;
-double *count;
-
-enum TestMode {
-  COUNT_ONLY = 1,
-  NO_HANDLERS = 2,
-  ALL_HANDLERS = 3
-} test_mode;
-
-// Copied from decoder.c, since this is not a public interface.
-typedef struct {
-  uint8_t native_wire_type;
-  bool is_numeric;
-} upb_decoder_typeinfo;
-
-static const upb_decoder_typeinfo upb_decoder_types[] = {
-  {UPB_WIRE_TYPE_END_GROUP,   false},  // ENDGROUP
-  {UPB_WIRE_TYPE_64BIT,       true},   // DOUBLE
-  {UPB_WIRE_TYPE_32BIT,       true},   // FLOAT
-  {UPB_WIRE_TYPE_VARINT,      true},   // INT64
-  {UPB_WIRE_TYPE_VARINT,      true},   // UINT64
-  {UPB_WIRE_TYPE_VARINT,      true},   // INT32
-  {UPB_WIRE_TYPE_64BIT,       true},   // FIXED64
-  {UPB_WIRE_TYPE_32BIT,       true},   // FIXED32
-  {UPB_WIRE_TYPE_VARINT,      true},   // BOOL
-  {UPB_WIRE_TYPE_DELIMITED,   false},  // STRING
-  {UPB_WIRE_TYPE_START_GROUP, false},  // GROUP
-  {UPB_WIRE_TYPE_DELIMITED,   false},  // MESSAGE
-  {UPB_WIRE_TYPE_DELIMITED,   false},  // BYTES
-  {UPB_WIRE_TYPE_VARINT,      true},   // UINT32
-  {UPB_WIRE_TYPE_VARINT,      true},   // ENUM
-  {UPB_WIRE_TYPE_32BIT,       true},   // SFIXED32
-  {UPB_WIRE_TYPE_64BIT,       true},   // SFIXED64
-  {UPB_WIRE_TYPE_VARINT,      true},   // SINT32
-  {UPB_WIRE_TYPE_VARINT,      true},   // SINT64
-};
-
-#ifndef USE_GOOGLE
-using std::string;
-#endif
-
-void vappendf(string* str, const char *format, va_list args) {
-  va_list copy;
-  va_copy(copy, args);
-
-  int count = vsnprintf(NULL, 0, format, args);
-  if (count >= 0)
-  {
-    UPB_ASSERT(count < 32768);
-    char *buffer = new char[count + 1];
-    UPB_ASSERT(buffer);
-    count = vsnprintf(buffer, count + 1, format, copy);
-    UPB_ASSERT(count >= 0);
-    str->append(buffer, count);
-    delete [] buffer;
-  }
-  va_end(copy);
-}
-
-void appendf(string* str, const char *fmt, ...) {
-  va_list args;
-  va_start(args, fmt);
-  vappendf(str, fmt, args);
-  va_end(args);
-}
-
-void PrintBinary(const string& str) {
-  for (size_t i = 0; i < str.size(); i++) {
-    if (isprint(str[i])) {
-      fprintf(stderr, "%c", str[i]);
-    } else {
-      fprintf(stderr, "\\x%02x", (int)(uint8_t)str[i]);
-    }
-  }
-}
-
-#define UPB_PB_VARINT_MAX_LEN 10
-
-static size_t upb_vencode64(uint64_t val, char *buf) {
-  size_t i;
-  if (val == 0) { buf[0] = 0; return 1; }
-  i = 0;
-  while (val) {
-    uint8_t byte = val & 0x7fU;
-    val >>= 7;
-    if (val) byte |= 0x80U;
-    buf[i++] = byte;
-  }
-  return i;
-}
-
-static uint32_t upb_zzenc_32(int32_t n) {
-  return ((uint32_t)n << 1) ^ (n >> 31);
-}
-
-static uint64_t upb_zzenc_64(int64_t n) {
-  return ((uint64_t)n << 1) ^ (n >> 63);
-}
-
-/* Routines for building arbitrary protos *************************************/
-
-const string empty;
-
-string cat(const string& a, const string& b,
-           const string& c = empty,
-           const string& d = empty,
-           const string& e = empty,
-           const string& f = empty,
-           const string& g = empty,
-           const string& h = empty,
-           const string& i = empty,
-           const string& j = empty,
-           const string& k = empty,
-           const string& l = empty) {
-  string ret;
-  ret.reserve(a.size() + b.size() + c.size() + d.size() + e.size() + f.size() +
-              g.size() + h.size() + i.size() + j.size() + k.size() + l.size());
-  ret.append(a);
-  ret.append(b);
-  ret.append(c);
-  ret.append(d);
-  ret.append(e);
-  ret.append(f);
-  ret.append(g);
-  ret.append(h);
-  ret.append(i);
-  ret.append(j);
-  ret.append(k);
-  ret.append(l);
-  return ret;
-}
-
-template <typename T>
-string num2string(T num) {
-  std::ostringstream ss;
-  ss << num;
-  return ss.str();
-}
-
-string varint(uint64_t x) {
-  char buf[UPB_PB_VARINT_MAX_LEN];
-  size_t len = upb_vencode64(x, buf);
-  return string(buf, len);
-}
-
-// TODO: proper byte-swapping for big-endian machines.
-string fixed32(void *data) { return string(static_cast<char*>(data), 4); }
-string fixed64(void *data) { return string(static_cast<char*>(data), 8); }
-
-string delim(const string& buf) { return cat(varint(buf.size()), buf); }
-string uint32(uint32_t u32) { return fixed32(&u32); }
-string uint64(uint64_t u64) { return fixed64(&u64); }
-string flt(float f) { return fixed32(&f); }
-string dbl(double d) { return fixed64(&d); }
-string zz32(int32_t x) { return varint(upb_zzenc_32(x)); }
-string zz64(int64_t x) { return varint(upb_zzenc_64(x)); }
-
-string tag(uint32_t fieldnum, char wire_type) {
-  return varint((fieldnum << 3) | wire_type);
-}
-
-string submsg(uint32_t fn, const string& buf) {
-  return cat( tag(fn, UPB_WIRE_TYPE_DELIMITED), delim(buf) );
-}
-
-string group(uint32_t fn, const string& buf) {
-  return cat(tag(fn, UPB_WIRE_TYPE_START_GROUP), buf,
-             tag(fn, UPB_WIRE_TYPE_END_GROUP));
-}
-
-// Like delim()/submsg(), but intentionally encodes an incorrect length.
-// These help test when a delimited boundary doesn't land in the right place.
-string badlen_delim(int err, const string& buf) {
-  return cat(varint(buf.size() + err), buf);
-}
-
-string badlen_submsg(int err, uint32_t fn, const string& buf) {
-  return cat( tag(fn, UPB_WIRE_TYPE_DELIMITED), badlen_delim(err, buf) );
-}
-
-
-/* A set of handlers that covers all .proto types *****************************/
-
-// The handlers simply append to a string indicating what handlers were called.
-// This string is similar to protobuf text format but fields are referred to by
-// number instead of name and sequences are explicitly delimited.  We indent
-// using the closure depth to test that the stack of closures is properly
-// handled.
-
-int closures[MAX_NESTING];
-string output;
-
-void indentbuf(string *buf, int depth) {
-  buf->append(2 * depth, ' ');
-}
-
-#define NUMERIC_VALUE_HANDLER(member, ctype, fmt)                   \
-  bool value_##member(int* depth, const uint32_t* num, ctype val) { \
-    indentbuf(&output, *depth);                                     \
-    appendf(&output, "%" PRIu32 ":%" fmt "\n", *num, val);          \
-    return true;                                                    \
-  }
-
-NUMERIC_VALUE_HANDLER(uint32, uint32_t, PRIu32)
-NUMERIC_VALUE_HANDLER(uint64, uint64_t, PRIu64)
-NUMERIC_VALUE_HANDLER(int32,  int32_t,  PRId32)
-NUMERIC_VALUE_HANDLER(int64,  int64_t,  PRId64)
-NUMERIC_VALUE_HANDLER(float,  float,    "g")
-NUMERIC_VALUE_HANDLER(double, double,   "g")
-
-bool value_bool(int* depth, const uint32_t* num, bool val) {
-  indentbuf(&output, *depth);
-  appendf(&output, "%" PRIu32 ":%s\n", *num, val ? "true" : "false");
-  return true;
-}
-
-int* startstr(int* depth, const uint32_t* num, size_t size_hint) {
-  indentbuf(&output, *depth);
-  appendf(&output, "%" PRIu32 ":(%zu)\"", *num, size_hint);
-  return depth + 1;
-}
-
-size_t value_string(int* depth, const uint32_t* num, const char* buf,
-                    size_t n, const upb_bufhandle* handle) {
-  UPB_UNUSED(num);
-  UPB_UNUSED(depth);
-  output.append(buf, n);
-  ASSERT(handle == &global_handle);
-  return n;
-}
-
-bool endstr(int* depth, const uint32_t* num) {
-  UPB_UNUSED(num);
-  output.append("\n");
-  indentbuf(&output, *depth);
-  appendf(&output, "%" PRIu32 ":\"\n", *num);
-  return true;
-}
-
-int* startsubmsg(int* depth, const uint32_t* num) {
-  indentbuf(&output, *depth);
-  appendf(&output, "%" PRIu32 ":{\n", *num);
-  return depth + 1;
-}
-
-bool endsubmsg(int* depth, const uint32_t* num) {
-  UPB_UNUSED(num);
-  indentbuf(&output, *depth);
-  output.append("}\n");
-  return true;
-}
-
-int* startseq(int* depth, const uint32_t* num) {
-  indentbuf(&output, *depth);
-  appendf(&output, "%" PRIu32 ":[\n", *num);
-  return depth + 1;
-}
-
-bool endseq(int* depth, const uint32_t* num) {
-  UPB_UNUSED(num);
-  indentbuf(&output, *depth);
-  output.append("]\n");
-  return true;
-}
-
-bool startmsg(int* depth) {
-  indentbuf(&output, *depth);
-  output.append("<\n");
-  return true;
-}
-
-bool endmsg(int* depth, upb_status* status) {
-  UPB_UNUSED(status);
-  indentbuf(&output, *depth);
-  output.append(">\n");
-  return true;
-}
-
-void free_uint32(void *val) {
-  uint32_t *u32 = static_cast<uint32_t*>(val);
-  delete u32;
-}
-
-template<class T, bool F(int*, const uint32_t*, T)>
-void doreg(upb::HandlersPtr h, uint32_t num) {
-  upb::FieldDefPtr f = h.message_def().FindFieldByNumber(num);
-  ASSERT(f);
-  ASSERT(h.SetValueHandler<T>(f, UpbBind(F, new uint32_t(num))));
-  if (f.IsSequence()) {
-    ASSERT(h.SetStartSequenceHandler(f, UpbBind(startseq, new uint32_t(num))));
-    ASSERT(h.SetEndSequenceHandler(f, UpbBind(endseq, new uint32_t(num))));
-  }
-}
-
-// The repeated field number to correspond to the given non-repeated field
-// number.
-uint32_t rep_fn(uint32_t fn) {
-  return (UPB_MAX_FIELDNUMBER - 1000) + fn;
-}
-
-#define NOP_FIELD 40
-#define UNKNOWN_FIELD 666
-
-template <class T, bool F(int*, const uint32_t*, T)>
-void reg(upb::HandlersPtr h, upb_descriptortype_t type) {
-  // We register both a repeated and a non-repeated field for every type.
-  // For the non-repeated field we make the field number the same as the
-  // type.  For the repeated field we make it a function of the type.
-  doreg<T, F>(h, type);
-  doreg<T, F>(h, rep_fn(type));
-}
-
-void regseq(upb::HandlersPtr h, upb::FieldDefPtr f, uint32_t num) {
-  ASSERT(h.SetStartSequenceHandler(f, UpbBind(startseq, new uint32_t(num))));
-  ASSERT(h.SetEndSequenceHandler(f, UpbBind(endseq, new uint32_t(num))));
-}
-
-void reg_subm(upb::HandlersPtr h, uint32_t num) {
-  upb::FieldDefPtr f = h.message_def().FindFieldByNumber(num);
-  ASSERT(f);
-  if (f.IsSequence()) regseq(h, f, num);
-  ASSERT(
-      h.SetStartSubMessageHandler(f, UpbBind(startsubmsg, new uint32_t(num))));
-  ASSERT(h.SetEndSubMessageHandler(f, UpbBind(endsubmsg, new uint32_t(num))));
-}
-
-void reg_str(upb::HandlersPtr h, uint32_t num) {
-  upb::FieldDefPtr f = h.message_def().FindFieldByNumber(num);
-  ASSERT(f);
-  if (f.IsSequence()) regseq(h, f, num);
-  ASSERT(h.SetStartStringHandler(f, UpbBind(startstr, new uint32_t(num))));
-  ASSERT(h.SetEndStringHandler(f, UpbBind(endstr, new uint32_t(num))));
-  ASSERT(h.SetStringHandler(f, UpbBind(value_string, new uint32_t(num))));
-}
-
-struct HandlerRegisterData {
-  TestMode mode;
-};
-
-void callback(const void *closure, upb::Handlers* h_ptr) {
-  upb::HandlersPtr h(h_ptr);
-  const HandlerRegisterData* data =
-      static_cast<const HandlerRegisterData*>(closure);
-  if (data->mode == ALL_HANDLERS) {
-    h.SetStartMessageHandler(UpbMakeHandler(startmsg));
-    h.SetEndMessageHandler(UpbMakeHandler(endmsg));
-
-    // Register handlers for each type.
-    reg<double,   value_double>(h, UPB_DESCRIPTOR_TYPE_DOUBLE);
-    reg<float,    value_float> (h, UPB_DESCRIPTOR_TYPE_FLOAT);
-    reg<int64_t,  value_int64> (h, UPB_DESCRIPTOR_TYPE_INT64);
-    reg<uint64_t, value_uint64>(h, UPB_DESCRIPTOR_TYPE_UINT64);
-    reg<int32_t,  value_int32> (h, UPB_DESCRIPTOR_TYPE_INT32);
-    reg<uint64_t, value_uint64>(h, UPB_DESCRIPTOR_TYPE_FIXED64);
-    reg<uint32_t, value_uint32>(h, UPB_DESCRIPTOR_TYPE_FIXED32);
-    reg<bool,     value_bool>  (h, UPB_DESCRIPTOR_TYPE_BOOL);
-    reg<uint32_t, value_uint32>(h, UPB_DESCRIPTOR_TYPE_UINT32);
-    reg<int32_t,  value_int32> (h, UPB_DESCRIPTOR_TYPE_ENUM);
-    reg<int32_t,  value_int32> (h, UPB_DESCRIPTOR_TYPE_SFIXED32);
-    reg<int64_t,  value_int64> (h, UPB_DESCRIPTOR_TYPE_SFIXED64);
-    reg<int32_t,  value_int32> (h, UPB_DESCRIPTOR_TYPE_SINT32);
-    reg<int64_t,  value_int64> (h, UPB_DESCRIPTOR_TYPE_SINT64);
-
-    reg_str(h, UPB_DESCRIPTOR_TYPE_STRING);
-    reg_str(h, UPB_DESCRIPTOR_TYPE_BYTES);
-    reg_str(h, rep_fn(UPB_DESCRIPTOR_TYPE_STRING));
-    reg_str(h, rep_fn(UPB_DESCRIPTOR_TYPE_BYTES));
-
-    // Register submessage/group handlers that are self-recursive
-    // to this type, eg: message M { optional M m = 1; }
-    reg_subm(h, UPB_DESCRIPTOR_TYPE_MESSAGE);
-    reg_subm(h, rep_fn(UPB_DESCRIPTOR_TYPE_MESSAGE));
-
-    if (h.message_def().full_name() == std::string("DecoderTest")) {
-      reg_subm(h, UPB_DESCRIPTOR_TYPE_GROUP);
-      reg_subm(h, rep_fn(UPB_DESCRIPTOR_TYPE_GROUP));
-    }
-
-    // For NOP_FIELD we register no handlers, so we can pad a proto freely without
-    // changing the output.
-  }
-}
-
-/* Running of test cases ******************************************************/
-
-const upb::Handlers *global_handlers;
-upb::pb::DecoderMethodPtr global_method;
-
-upb::pb::DecoderPtr CreateDecoder(upb::Arena* arena,
-                                  upb::pb::DecoderMethodPtr method,
-                                  upb::Sink sink, upb::Status* status) {
-  upb::pb::DecoderPtr ret =
-      upb::pb::DecoderPtr::Create(arena, method, sink, status);
-  ret.set_max_nesting(MAX_NESTING);
-  return ret;
-}
-
-void CheckBytesParsed(upb::pb::DecoderPtr decoder, size_t ofs) {
-  // We can't have parsed more data than the decoder callback is telling us it
-  // parsed.
-  ASSERT(decoder.BytesParsed() <= ofs);
-
-  // The difference between what we've decoded and what the decoder has accepted
-  // represents the internally buffered amount.  This amount should not exceed
-  // this value which comes from decoder.int.h.
-  ASSERT(ofs <= (decoder.BytesParsed() + UPB_DECODER_MAX_RESIDUAL_BYTES));
-}
-
-static bool parse(VerboseParserEnvironment* env,
-                  upb::pb::DecoderPtr decoder, int bytes) {
-  CheckBytesParsed(decoder, env->ofs());
-  bool ret = env->ParseBuffer(bytes);
-  if (ret) {
-    CheckBytesParsed(decoder, env->ofs());
-  }
-
-  return ret;
-}
-
-void do_run_decoder(VerboseParserEnvironment* env, upb::pb::DecoderPtr decoder,
-                    const string& proto, const string* expected_output,
-                    size_t i, size_t j, bool may_skip) {
-  env->Reset(proto.c_str(), proto.size(), may_skip, expected_output == NULL);
-  decoder.Reset();
-
-  if (test_mode != COUNT_ONLY) {
-    output.clear();
-
-    if (filter_hash) {
-      fprintf(stderr, "RUNNING TEST CASE\n");
-      fprintf(stderr, "Input (len=%u): ", (unsigned)proto.size());
-      PrintBinary(proto);
-      fprintf(stderr, "\n");
-      if (expected_output) {
-        if (test_mode == ALL_HANDLERS) {
-          fprintf(stderr, "Expected output: %s\n", expected_output->c_str());
-        } else if (test_mode == NO_HANDLERS) {
-          fprintf(stderr,
-                  "No handlers are registered, BUT if they were "
-                  "the expected output would be: %s\n",
-                  expected_output->c_str());
-        }
-      } else {
-        fprintf(stderr, "Expected to FAIL\n");
-      }
-    }
-
-    bool ok = env->Start() &&
-              parse(env, decoder, (int)i) &&
-              parse(env, decoder, (int)(j - i)) &&
-              parse(env, decoder, -1) &&
-              env->End();
-
-    ASSERT(env->CheckConsistency());
-
-    if (test_mode == ALL_HANDLERS) {
-      if (expected_output) {
-        if (output != *expected_output) {
-          fprintf(stderr, "Text mismatch: '%s' vs '%s'\n",
-                  output.c_str(), expected_output->c_str());
-        }
-        ASSERT(ok);
-        ASSERT(output == *expected_output);
-      } else {
-        if (ok) {
-          fprintf(stderr, "Didn't expect ok result, but got output: '%s'\n",
-                  output.c_str());
-        }
-        ASSERT(!ok);
-      }
-    }
-  }
-  (*count)++;
-}
-
-void run_decoder(const string& proto, const string* expected_output) {
-  VerboseParserEnvironment env(filter_hash != 0);
-  upb::Sink sink(global_handlers, &closures[0]);
-  upb::pb::DecoderPtr decoder = CreateDecoder(env.arena(), global_method, sink, env.status());
-  env.ResetBytesSink(decoder.input());
-  for (size_t i = 0; i < proto.size(); i++) {
-    for (size_t j = i; j < UPB_MIN(proto.size(), i + 5); j++) {
-      do_run_decoder(&env, decoder, proto, expected_output, i, j, true);
-      if (env.SkippedWithNull()) {
-        do_run_decoder(&env, decoder, proto, expected_output, i, j, false);
-      }
-    }
-  }
-}
-
-const static string thirty_byte_nop = cat(
-    tag(NOP_FIELD, UPB_WIRE_TYPE_DELIMITED), delim(string(30, 'X')) );
-
-// Indents and wraps text as if it were a submessage with this field number
-string wrap_text(int32_t fn, const string& text) {
-  string wrapped_text = text;
-  size_t pos = 0;
-  string replace_with = "\n  ";
-  while ((pos = wrapped_text.find("\n", pos)) != string::npos &&
-         pos != wrapped_text.size() - 1) {
-    wrapped_text.replace(pos, 1, replace_with);
-    pos += replace_with.size();
-  }
-  wrapped_text = cat(
-      LINE("<"),
-      num2string(fn), LINE(":{")
-      "  ", wrapped_text,
-      LINE("  }")
-      LINE(">"));
-  return wrapped_text;
-}
-
-void assert_successful_parse(const string& proto,
-                             const char *expected_fmt, ...) {
-  string expected_text;
-  va_list args;
-  va_start(args, expected_fmt);
-  vappendf(&expected_text, expected_fmt, args);
-  va_end(args);
-  // To test both middle-of-buffer and end-of-buffer code paths,
-  // repeat once with no-op padding data at the end of buffer.
-  run_decoder(proto, &expected_text);
-  run_decoder(cat( proto, thirty_byte_nop ), &expected_text);
-
-  // Test that this also works when wrapped in a submessage or group.
-  // Indent the expected text one level and wrap it.
-  string wrapped_text1 = wrap_text(UPB_DESCRIPTOR_TYPE_MESSAGE, expected_text);
-  string wrapped_text2 = wrap_text(UPB_DESCRIPTOR_TYPE_GROUP, expected_text);
-
-  run_decoder(submsg(UPB_DESCRIPTOR_TYPE_MESSAGE, proto), &wrapped_text1);
-  run_decoder(group(UPB_DESCRIPTOR_TYPE_GROUP, proto), &wrapped_text2);
-}
-
-void assert_does_not_parse_at_eof(const string& proto) {
-  run_decoder(proto, NULL);
-
-  // Also test that we fail to parse at end-of-submessage, not just
-  // end-of-message.  But skip this if we have no handlers, because in that
-  // case we won't descend into the submessage.
-  if (test_mode != NO_HANDLERS) {
-    run_decoder(submsg(UPB_DESCRIPTOR_TYPE_MESSAGE, proto), NULL);
-    run_decoder(cat(submsg(UPB_DESCRIPTOR_TYPE_MESSAGE, proto),
-                    thirty_byte_nop), NULL);
-  }
-}
-
-void assert_does_not_parse(const string& proto) {
-  // Test that the error is caught both at end-of-buffer and middle-of-buffer.
-  assert_does_not_parse_at_eof(proto);
-  assert_does_not_parse_at_eof(cat( proto, thirty_byte_nop ));
-}
-
-
-/* The actual tests ***********************************************************/
-
-void test_premature_eof_for_type(upb_descriptortype_t type) {
-  // Incomplete values for each wire type.
-  static const string incompletes[6] = {
-    string("\x80"),     // UPB_WIRE_TYPE_VARINT
-    string("abcdefg"),  // UPB_WIRE_TYPE_64BIT
-    string("\x80"),     // UPB_WIRE_TYPE_DELIMITED (partial length)
-    string(),           // UPB_WIRE_TYPE_START_GROUP (no value required)
-    string(),           // UPB_WIRE_TYPE_END_GROUP (no value required)
-    string("abc")       // UPB_WIRE_TYPE_32BIT
-  };
-
-  uint32_t fieldnum = type;
-  uint32_t rep_fieldnum = rep_fn(type);
-  int wire_type = upb_decoder_types[type].native_wire_type;
-  const string& incomplete = incompletes[wire_type];
-
-  // EOF before a known non-repeated value.
-  assert_does_not_parse_at_eof(tag(fieldnum, wire_type));
-
-  // EOF before a known repeated value.
-  assert_does_not_parse_at_eof(tag(rep_fieldnum, wire_type));
-
-  // EOF before an unknown value.
-  assert_does_not_parse_at_eof(tag(UNKNOWN_FIELD, wire_type));
-
-  // EOF inside a known non-repeated value.
-  assert_does_not_parse_at_eof(
-      cat( tag(fieldnum, wire_type), incomplete ));
-
-  // EOF inside a known repeated value.
-  assert_does_not_parse_at_eof(
-      cat( tag(rep_fieldnum, wire_type), incomplete ));
-
-  // EOF inside an unknown value.
-  assert_does_not_parse_at_eof(
-      cat( tag(UNKNOWN_FIELD, wire_type), incomplete ));
-
-  if (wire_type == UPB_WIRE_TYPE_DELIMITED) {
-    // EOF in the middle of delimited data for known non-repeated value.
-    assert_does_not_parse_at_eof(
-        cat( tag(fieldnum, wire_type), varint(1) ));
-
-    // EOF in the middle of delimited data for known repeated value.
-    assert_does_not_parse_at_eof(
-        cat( tag(rep_fieldnum, wire_type), varint(1) ));
-
-    // EOF in the middle of delimited data for unknown value.
-    assert_does_not_parse_at_eof(
-        cat( tag(UNKNOWN_FIELD, wire_type), varint(1) ));
-
-    if (type == UPB_DESCRIPTOR_TYPE_MESSAGE) {
-      // Submessage ends in the middle of a value.
-      string incomplete_submsg =
-          cat ( tag(UPB_DESCRIPTOR_TYPE_INT32, UPB_WIRE_TYPE_VARINT),
-                incompletes[UPB_WIRE_TYPE_VARINT] );
-      assert_does_not_parse(
-          cat( tag(fieldnum, UPB_WIRE_TYPE_DELIMITED),
-               varint(incomplete_submsg.size()),
-               incomplete_submsg ));
-    }
-  } else {
-    // Packed region ends in the middle of a value.
-    assert_does_not_parse(
-        cat( tag(rep_fieldnum, UPB_WIRE_TYPE_DELIMITED),
-             varint(incomplete.size()),
-             incomplete ));
-
-    // EOF in the middle of packed region.
-    assert_does_not_parse_at_eof(
-        cat( tag(rep_fieldnum, UPB_WIRE_TYPE_DELIMITED), varint(1) ));
-  }
-}
-
-// "33" and "66" are just two random values that all numeric types can
-// represent.
-void test_valid_data_for_type(upb_descriptortype_t type,
-                              const string& enc33, const string& enc66) {
-  uint32_t fieldnum = type;
-  uint32_t rep_fieldnum = rep_fn(type);
-  int wire_type = upb_decoder_types[type].native_wire_type;
-
-  // Non-repeated
-  assert_successful_parse(
-      cat( tag(fieldnum, wire_type), enc33,
-           tag(fieldnum, wire_type), enc66 ),
-      LINE("<")
-      LINE("%u:33")
-      LINE("%u:66")
-      LINE(">"), fieldnum, fieldnum);
-
-  // Non-packed repeated.
-  assert_successful_parse(
-      cat( tag(rep_fieldnum, wire_type), enc33,
-           tag(rep_fieldnum, wire_type), enc66 ),
-      LINE("<")
-      LINE("%u:[")
-      LINE("  %u:33")
-      LINE("  %u:66")
-      LINE("]")
-      LINE(">"), rep_fieldnum, rep_fieldnum, rep_fieldnum);
-
-  // Packed repeated.
-  assert_successful_parse(
-      cat( tag(rep_fieldnum, UPB_WIRE_TYPE_DELIMITED),
-           delim(cat( enc33, enc66 )) ),
-      LINE("<")
-      LINE("%u:[")
-      LINE("  %u:33")
-      LINE("  %u:66")
-      LINE("]")
-      LINE(">"), rep_fieldnum, rep_fieldnum, rep_fieldnum);
-}
-
-void test_valid_data_for_signed_type(upb_descriptortype_t type,
-                                     const string& enc33, const string& enc66) {
-  uint32_t fieldnum = type;
-  uint32_t rep_fieldnum = rep_fn(type);
-  int wire_type = upb_decoder_types[type].native_wire_type;
-
-  // Non-repeated
-  assert_successful_parse(
-      cat( tag(fieldnum, wire_type), enc33,
-           tag(fieldnum, wire_type), enc66 ),
-      LINE("<")
-      LINE("%u:33")
-      LINE("%u:-66")
-      LINE(">"), fieldnum, fieldnum);
-
-  // Non-packed repeated.
-  assert_successful_parse(
-      cat( tag(rep_fieldnum, wire_type), enc33,
-           tag(rep_fieldnum, wire_type), enc66 ),
-      LINE("<")
-      LINE("%u:[")
-      LINE("  %u:33")
-      LINE("  %u:-66")
-      LINE("]")
-      LINE(">"), rep_fieldnum, rep_fieldnum, rep_fieldnum);
-
-  // Packed repeated.
-  assert_successful_parse(
-      cat( tag(rep_fieldnum, UPB_WIRE_TYPE_DELIMITED),
-           delim(cat( enc33, enc66 )) ),
-      LINE("<")
-      LINE("%u:[")
-      LINE("  %u:33")
-      LINE("  %u:-66")
-      LINE("]")
-      LINE(">"), rep_fieldnum, rep_fieldnum, rep_fieldnum);
-}
-
-// Test that invalid protobufs are properly detected (without crashing) and
-// have an error reported.  Field numbers match registered handlers above.
-void test_invalid() {
-  test_premature_eof_for_type(UPB_DESCRIPTOR_TYPE_DOUBLE);
-  test_premature_eof_for_type(UPB_DESCRIPTOR_TYPE_FLOAT);
-  test_premature_eof_for_type(UPB_DESCRIPTOR_TYPE_INT64);
-  test_premature_eof_for_type(UPB_DESCRIPTOR_TYPE_UINT64);
-  test_premature_eof_for_type(UPB_DESCRIPTOR_TYPE_INT32);
-  test_premature_eof_for_type(UPB_DESCRIPTOR_TYPE_FIXED64);
-  test_premature_eof_for_type(UPB_DESCRIPTOR_TYPE_FIXED32);
-  test_premature_eof_for_type(UPB_DESCRIPTOR_TYPE_BOOL);
-  test_premature_eof_for_type(UPB_DESCRIPTOR_TYPE_STRING);
-  test_premature_eof_for_type(UPB_DESCRIPTOR_TYPE_BYTES);
-  test_premature_eof_for_type(UPB_DESCRIPTOR_TYPE_UINT32);
-  test_premature_eof_for_type(UPB_DESCRIPTOR_TYPE_ENUM);
-  test_premature_eof_for_type(UPB_DESCRIPTOR_TYPE_SFIXED32);
-  test_premature_eof_for_type(UPB_DESCRIPTOR_TYPE_SFIXED64);
-  test_premature_eof_for_type(UPB_DESCRIPTOR_TYPE_SINT32);
-  test_premature_eof_for_type(UPB_DESCRIPTOR_TYPE_SINT64);
-
-  // EOF inside a tag's varint.
-  assert_does_not_parse_at_eof( string("\x80") );
-
-  // EOF inside a known group.
-  // TODO(haberman): add group to decoder test schema.
-  //assert_does_not_parse_at_eof( tag(4, UPB_WIRE_TYPE_START_GROUP) );
-
-  // EOF inside an unknown group.
-  assert_does_not_parse_at_eof( tag(UNKNOWN_FIELD, UPB_WIRE_TYPE_START_GROUP) );
-
-  // End group that we are not currently in.
-  assert_does_not_parse( tag(4, UPB_WIRE_TYPE_END_GROUP) );
-
-  // Field number is 0.
-  assert_does_not_parse(
-      cat( tag(0, UPB_WIRE_TYPE_DELIMITED), varint(0) ));
-  // The previous test alone did not catch this particular pattern which could
-  // corrupt the internal state.
-  assert_does_not_parse(
-      cat( tag(0, UPB_WIRE_TYPE_64BIT), uint64(0) ));
-
-  // Field number is too large.
-  assert_does_not_parse(
-      cat( tag(UPB_MAX_FIELDNUMBER + 1, UPB_WIRE_TYPE_DELIMITED),
-           varint(0) ));
-
-  // Known group inside a submessage has ENDGROUP tag AFTER submessage end.
-  assert_does_not_parse(
-      cat ( submsg(UPB_DESCRIPTOR_TYPE_MESSAGE,
-                   tag(UPB_DESCRIPTOR_TYPE_GROUP, UPB_WIRE_TYPE_START_GROUP)),
-            tag(UPB_DESCRIPTOR_TYPE_GROUP, UPB_WIRE_TYPE_END_GROUP)));
-
-  // Unknown string extends past enclosing submessage.
-  assert_does_not_parse(
-      cat (badlen_submsg(-1, UPB_DESCRIPTOR_TYPE_MESSAGE,
-                         submsg(12345, string("   "))),
-           submsg(UPB_DESCRIPTOR_TYPE_MESSAGE, string("     "))));
-
-  // Unknown fixed-length field extends past enclosing submessage.
-  assert_does_not_parse(
-      cat (badlen_submsg(-1, UPB_DESCRIPTOR_TYPE_MESSAGE,
-                         cat( tag(12345, UPB_WIRE_TYPE_64BIT), uint64(0))),
-           submsg(UPB_DESCRIPTOR_TYPE_MESSAGE, string("     "))));
-
-  // Test exceeding the resource limit of stack depth.
-  if (test_mode != NO_HANDLERS) {
-    string buf;
-    for (int i = 0; i <= MAX_NESTING; i++) {
-      buf.assign(submsg(UPB_DESCRIPTOR_TYPE_MESSAGE, buf));
-    }
-    assert_does_not_parse(buf);
-  }
-}
-
-void test_valid() {
-  // Empty protobuf.
-  assert_successful_parse(string(""), "<\n>\n");
-
-  // Empty protobuf where we never call PutString between
-  // StartString/EndString.
-
-  upb::Status status;
-  upb::Arena arena;
-  upb::Sink sink(global_handlers, &closures[0]);
-  upb::pb::DecoderPtr decoder =
-      CreateDecoder(&arena, global_method, sink, &status);
-  output.clear();
-  bool ok = upb::PutBuffer(std::string(), decoder.input());
-  ASSERT(ok);
-  ASSERT(status.ok());
-  if (test_mode == ALL_HANDLERS) {
-    ASSERT(output == string("<\n>\n"));
-  }
-
-  test_valid_data_for_signed_type(UPB_DESCRIPTOR_TYPE_DOUBLE,
-                                  dbl(33),
-                                  dbl(-66));
-  test_valid_data_for_signed_type(UPB_DESCRIPTOR_TYPE_FLOAT, flt(33), flt(-66));
-  test_valid_data_for_signed_type(UPB_DESCRIPTOR_TYPE_INT64,
-                                  varint(33),
-                                  varint(-66));
-  test_valid_data_for_signed_type(UPB_DESCRIPTOR_TYPE_INT32,
-                                  varint(33),
-                                  varint(-66));
-  test_valid_data_for_signed_type(UPB_DESCRIPTOR_TYPE_ENUM,
-                                  varint(33),
-                                  varint(-66));
-  test_valid_data_for_signed_type(UPB_DESCRIPTOR_TYPE_SFIXED32,
-                                  uint32(33),
-                                  uint32(-66));
-  test_valid_data_for_signed_type(UPB_DESCRIPTOR_TYPE_SFIXED64,
-                                  uint64(33),
-                                  uint64(-66));
-  test_valid_data_for_signed_type(UPB_DESCRIPTOR_TYPE_SINT32,
-                                  zz32(33),
-                                  zz32(-66));
-  test_valid_data_for_signed_type(UPB_DESCRIPTOR_TYPE_SINT64,
-                                  zz64(33),
-                                  zz64(-66));
-
-  test_valid_data_for_type(UPB_DESCRIPTOR_TYPE_UINT64, varint(33), varint(66));
-  test_valid_data_for_type(UPB_DESCRIPTOR_TYPE_UINT32, varint(33), varint(66));
-  test_valid_data_for_type(UPB_DESCRIPTOR_TYPE_FIXED64, uint64(33), uint64(66));
-  test_valid_data_for_type(UPB_DESCRIPTOR_TYPE_FIXED32, uint32(33), uint32(66));
-
-  // Unknown fields.
-  int int32_type = UPB_DESCRIPTOR_TYPE_INT32;
-  int msg_type = UPB_DESCRIPTOR_TYPE_MESSAGE;
-  assert_successful_parse(
-      cat( tag(12345, UPB_WIRE_TYPE_VARINT), varint(2345678) ),
-      "<\n>\n");
-  assert_successful_parse(
-      cat( tag(12345, UPB_WIRE_TYPE_32BIT), uint32(2345678) ),
-      "<\n>\n");
-  assert_successful_parse(
-      cat( tag(12345, UPB_WIRE_TYPE_64BIT), uint64(2345678) ),
-      "<\n>\n");
-  assert_successful_parse(
-      submsg(12345, string("                ")),
-      "<\n>\n");
-
-  // Unknown field inside a known submessage.
-  assert_successful_parse(
-      submsg(UPB_DESCRIPTOR_TYPE_MESSAGE, submsg(12345, string("   "))),
-      LINE("<")
-      LINE("%u:{")
-      LINE("  <")
-      LINE("  >")
-      LINE("  }")
-      LINE(">"), UPB_DESCRIPTOR_TYPE_MESSAGE);
-
-  assert_successful_parse(
-      cat (submsg(UPB_DESCRIPTOR_TYPE_MESSAGE, submsg(12345, string("   "))),
-           tag(UPB_DESCRIPTOR_TYPE_INT32, UPB_WIRE_TYPE_VARINT),
-           varint(5)),
-      LINE("<")
-      LINE("%u:{")
-      LINE("  <")
-      LINE("  >")
-      LINE("  }")
-      LINE("%u:5")
-      LINE(">"), UPB_DESCRIPTOR_TYPE_MESSAGE, UPB_DESCRIPTOR_TYPE_INT32);
-
-  // This triggered a previous bug in the decoder.
-  assert_successful_parse(
-      cat( tag(UPB_DESCRIPTOR_TYPE_SFIXED32, UPB_WIRE_TYPE_VARINT),
-           varint(0) ),
-      "<\n>\n");
-
-  assert_successful_parse(
-      cat(
-        submsg(UPB_DESCRIPTOR_TYPE_MESSAGE,
-          submsg(UPB_DESCRIPTOR_TYPE_MESSAGE,
-            cat( tag(int32_type, UPB_WIRE_TYPE_VARINT), varint(2345678),
-                 tag(12345, UPB_WIRE_TYPE_VARINT), varint(2345678) ))),
-        tag(int32_type, UPB_WIRE_TYPE_VARINT), varint(22222)),
-      LINE("<")
-      LINE("%u:{")
-      LINE("  <")
-      LINE("  %u:{")
-      LINE("    <")
-      LINE("    %u:2345678")
-      LINE("    >")
-      LINE("    }")
-      LINE("  >")
-      LINE("  }")
-      LINE("%u:22222")
-      LINE(">"), msg_type, msg_type, int32_type, int32_type);
-
-  assert_successful_parse(
-      cat( tag(UPB_DESCRIPTOR_TYPE_INT32, UPB_WIRE_TYPE_VARINT), varint(1),
-           tag(12345, UPB_WIRE_TYPE_VARINT), varint(2345678) ),
-      LINE("<")
-      LINE("%u:1")
-      LINE(">"), UPB_DESCRIPTOR_TYPE_INT32);
-
-  // String inside submsg.
-  uint32_t msg_fn = UPB_DESCRIPTOR_TYPE_MESSAGE;
-  assert_successful_parse(
-      submsg(msg_fn,
-             cat ( tag(UPB_DESCRIPTOR_TYPE_STRING, UPB_WIRE_TYPE_DELIMITED),
-                   delim(string("abcde"))
-                 )
-             ),
-      LINE("<")
-      LINE("%u:{")
-      LINE("  <")
-      LINE("  %u:(5)\"abcde")
-      LINE("    %u:\"")
-      LINE("  >")
-      LINE("  }")
-      LINE(">"), msg_fn, UPB_DESCRIPTOR_TYPE_STRING,
-                 UPB_DESCRIPTOR_TYPE_STRING);
-
-  // Test implicit startseq/endseq.
-  uint32_t repfl_fn = rep_fn(UPB_DESCRIPTOR_TYPE_FLOAT);
-  uint32_t repdb_fn = rep_fn(UPB_DESCRIPTOR_TYPE_DOUBLE);
-  assert_successful_parse(
-      cat( tag(repfl_fn, UPB_WIRE_TYPE_32BIT), flt(33),
-           tag(repdb_fn, UPB_WIRE_TYPE_64BIT), dbl(66) ),
-      LINE("<")
-      LINE("%u:[")
-      LINE("  %u:33")
-      LINE("]")
-      LINE("%u:[")
-      LINE("  %u:66")
-      LINE("]")
-      LINE(">"), repfl_fn, repfl_fn, repdb_fn, repdb_fn);
-
-  // Submessage tests.
-  assert_successful_parse(
-      submsg(msg_fn, submsg(msg_fn, submsg(msg_fn, string()))),
-      LINE("<")
-      LINE("%u:{")
-      LINE("  <")
-      LINE("  %u:{")
-      LINE("    <")
-      LINE("    %u:{")
-      LINE("      <")
-      LINE("      >")
-      LINE("      }")
-      LINE("    >")
-      LINE("    }")
-      LINE("  >")
-      LINE("  }")
-      LINE(">"), msg_fn, msg_fn, msg_fn);
-
-  uint32_t repm_fn = rep_fn(UPB_DESCRIPTOR_TYPE_MESSAGE);
-  assert_successful_parse(
-      submsg(repm_fn, submsg(repm_fn, string())),
-      LINE("<")
-      LINE("%u:[")
-      LINE("  %u:{")
-      LINE("    <")
-      LINE("    %u:[")
-      LINE("      %u:{")
-      LINE("        <")
-      LINE("        >")
-      LINE("        }")
-      LINE("    ]")
-      LINE("    >")
-      LINE("    }")
-      LINE("]")
-      LINE(">"), repm_fn, repm_fn, repm_fn, repm_fn);
-
-  // Test unknown group.
-  uint32_t unknown_group_fn = 12321;
-  assert_successful_parse(
-      cat( tag(unknown_group_fn, UPB_WIRE_TYPE_START_GROUP),
-           tag(unknown_group_fn, UPB_WIRE_TYPE_END_GROUP) ),
-      LINE("<")
-      LINE(">")
-  );
-
-  // Test some unknown fields inside an unknown group.
-  const string unknown_group_with_data =
-      cat(
-          tag(unknown_group_fn, UPB_WIRE_TYPE_START_GROUP),
-          tag(12345, UPB_WIRE_TYPE_VARINT), varint(2345678),
-          tag(123456789, UPB_WIRE_TYPE_32BIT), uint32(2345678),
-          tag(123477, UPB_WIRE_TYPE_64BIT), uint64(2345678),
-          tag(123, UPB_WIRE_TYPE_DELIMITED), varint(0),
-          tag(unknown_group_fn, UPB_WIRE_TYPE_END_GROUP)
-         );
-
-  // Nested unknown group with data.
-  assert_successful_parse(
-      cat(
-           tag(unknown_group_fn, UPB_WIRE_TYPE_START_GROUP),
-           unknown_group_with_data,
-           tag(unknown_group_fn, UPB_WIRE_TYPE_END_GROUP),
-           tag(UPB_DESCRIPTOR_TYPE_INT32, UPB_WIRE_TYPE_VARINT), varint(1)
-         ),
-      LINE("<")
-      LINE("%u:1")
-      LINE(">"),
-      UPB_DESCRIPTOR_TYPE_INT32
-  );
-
-  assert_successful_parse(
-      cat( tag(unknown_group_fn, UPB_WIRE_TYPE_START_GROUP),
-           tag(unknown_group_fn + 1, UPB_WIRE_TYPE_START_GROUP),
-           tag(unknown_group_fn + 1, UPB_WIRE_TYPE_END_GROUP),
-           tag(unknown_group_fn, UPB_WIRE_TYPE_END_GROUP) ),
-      LINE("<")
-      LINE(">")
-  );
-
-  // Staying within the stack limit should work properly.
-  string buf;
-  string textbuf;
-  int total = MAX_NESTING - 1;
-  for (int i = 0; i < total; i++) {
-    buf.assign(submsg(UPB_DESCRIPTOR_TYPE_MESSAGE, buf));
-    indentbuf(&textbuf, i);
-    textbuf.append("<\n");
-    indentbuf(&textbuf, i);
-    appendf(&textbuf, "%u:{\n", UPB_DESCRIPTOR_TYPE_MESSAGE);
-  }
-  indentbuf(&textbuf, total);
-  textbuf.append("<\n");
-  indentbuf(&textbuf, total);
-  textbuf.append(">\n");
-  for (int i = 0; i < total; i++) {
-    indentbuf(&textbuf, total - i - 1);
-    textbuf.append("  }\n");
-    indentbuf(&textbuf, total - i - 1);
-    textbuf.append(">\n");
-  }
-  // Have to use run_decoder directly, because we are at max nesting and can't
-  // afford the extra nesting that assert_successful_parse() will do.
-  run_decoder(buf, &textbuf);
-}
-
-void empty_callback(const void* /* closure */, upb::Handlers* /* h_ptr */) {}
-
-void test_emptyhandlers(upb::SymbolTable* symtab) {
-  // Create an empty handlers to make sure that the decoder can handle empty
-  // messages.
-  HandlerRegisterData handlerdata;
-  handlerdata.mode = test_mode;
-
-  upb::HandlerCache handler_cache(empty_callback, &handlerdata);
-  upb::pb::CodeCache pb_code_cache(&handler_cache);
-
-  upb::MessageDefPtr md = upb::MessageDefPtr(Empty_getmsgdef(symtab->ptr()));
-  global_handlers = handler_cache.Get(md);
-  global_method = pb_code_cache.Get(md);
-
-  // TODO: also test the case where a message has fields, but the fields are
-  // submessage fields and have no handlers. This also results in a decoder
-  // method with no field-handling code.
-
-  // Ensure that the method can run with empty and non-empty input.
-  string test_unknown_field_msg =
-    cat(tag(1, UPB_WIRE_TYPE_VARINT), varint(42),
-        tag(2, UPB_WIRE_TYPE_DELIMITED), delim("My test data"));
-  const struct {
-    const char* data;
-    size_t length;
-  } testdata[] = {
-    { "", 0 },
-    { test_unknown_field_msg.data(), test_unknown_field_msg.size() },
-    { NULL, 0 },
-  };
-  for (int i = 0; testdata[i].data; i++) {
-    VerboseParserEnvironment env(filter_hash != 0);
-    upb::Sink sink(global_method.dest_handlers(), &closures[0]);
-    upb::pb::DecoderPtr decoder =
-        CreateDecoder(env.arena(), global_method, sink, env.status());
-    env.ResetBytesSink(decoder.input());
-    env.Reset(testdata[i].data, testdata[i].length, true, false);
-    ASSERT(env.Start());
-    ASSERT(env.ParseBuffer(-1));
-    ASSERT(env.End());
-    ASSERT(env.CheckConsistency());
-  }
-}
-
-void run_tests() {
-  HandlerRegisterData handlerdata;
-  handlerdata.mode = test_mode;
-
-  upb::SymbolTable symtab;
-  upb::HandlerCache handler_cache(callback, &handlerdata);
-  upb::pb::CodeCache pb_code_cache(&handler_cache);
-
-  upb::MessageDefPtr md(DecoderTest_getmsgdef(symtab.ptr()));
-  global_handlers = handler_cache.Get(md);
-  global_method = pb_code_cache.Get(md);
-  completed = 0;
-
-  test_invalid();
-  test_valid();
-
-  test_emptyhandlers(&symtab);
-}
-
-extern "C" {
-
-int run_tests(int argc, char *argv[]) {
-  if (argc > 1)
-    filter_hash = (uint32_t)strtol(argv[1], NULL, 16);
-  for (int i = 0; i < MAX_NESTING; i++) {
-    closures[i] = i;
-  }
-
-  // Count tests.
-  count = &total;
-  total = 0;
-  test_mode = COUNT_ONLY;
-  run_tests();
-  count = &completed;
-
-  total *= 2;  // NO_HANDLERS, ALL_HANDLERS.
-
-  test_mode = NO_HANDLERS;
-  run_tests();
-
-  test_mode = ALL_HANDLERS;
-  run_tests();
-
-  printf("All tests passed, %d assertions.\n", num_assertions);
-  return 0;
-}
-
-}
diff --git a/third_party/upb/tests/pb/test_decoder.proto b/third_party/upb/tests/pb/test_decoder.proto
deleted file mode 100644 (file)
index e9fa6ad..0000000
+++ /dev/null
@@ -1,128 +0,0 @@
-
-syntax = "proto2";
-
-enum TestEnum {
-  FOO = 1;
-}
-
-message Empty {}
-
-message DecoderTest {
-  optional double      f_double   = 1;
-  optional float       f_float    = 2;
-  optional int64       f_int64    = 3;
-  optional uint64      f_uint64   = 4;
-  optional int32       f_int32    = 5;
-  optional fixed64     f_fixed64  = 6;
-  optional fixed32     f_fixed32  = 7;
-  optional bool        f_bool     = 8;
-  optional string      f_string   = 9;
-  optional DecoderTest f_message  = 11;
-  optional bytes       f_bytes    = 12;
-  optional uint32      f_uint32   = 13;
-  optional TestEnum    f_enum     = 14;
-  optional sfixed32    f_sfixed32 = 15;
-  optional sfixed64    f_sfixed64 = 16;
-  optional sint32      f_sint32   = 17;
-  optional sint64      f_sint64   = 18;
-
-  optional string      nop_field  = 40;
-
-  repeated double      r_double   = 536869912;
-  repeated float       r_float    = 536869913;
-  repeated int64       r_int64    = 536869914;
-  repeated uint64      r_uint64   = 536869915;
-  repeated int32       r_int32    = 536869916;
-  repeated fixed64     r_fixed64  = 536869917;
-  repeated fixed32     r_fixed32  = 536869918;
-  repeated bool        r_bool     = 536869919;
-  repeated string      r_string   = 536869920;
-  repeated DecoderTest r_message  = 536869922;
-  repeated bytes       r_bytes    = 536869923;
-  repeated uint32      r_uint32   = 536869924;
-  repeated TestEnum    r_enum     = 536869925;
-  repeated sfixed32    r_sfixed32 = 536869926;
-  repeated sfixed64    r_sfixed64 = 536869927;
-  repeated sint32      r_sint32   = 536869928;
-  repeated sint64      r_sint64   = 536869929;
-
-  optional group F_group = 10 {
-    optional double      f_double   = 1;
-    optional float       f_float    = 2;
-    optional int64       f_int64    = 3;
-    optional uint64      f_uint64   = 4;
-    optional int32       f_int32    = 5;
-    optional fixed64     f_fixed64  = 6;
-    optional fixed32     f_fixed32  = 7;
-    optional bool        f_bool     = 8;
-    optional string      f_string   = 9;
-    optional DecoderTest f_message  = 11;
-    optional bytes       f_bytes    = 12;
-    optional uint32      f_uint32   = 13;
-    optional TestEnum    f_enum     = 14;
-    optional sfixed32    f_sfixed32 = 15;
-    optional sfixed64    f_sfixed64 = 16;
-    optional sint32      f_sint32   = 17;
-    optional sint64      f_sint64   = 18;
-
-    optional string      nop_field  = 40;
-
-    repeated double      r_double   = 536869912;
-    repeated float       r_float    = 536869913;
-    repeated int64       r_int64    = 536869914;
-    repeated uint64      r_uint64   = 536869915;
-    repeated int32       r_int32    = 536869916;
-    repeated fixed64     r_fixed64  = 536869917;
-    repeated fixed32     r_fixed32  = 536869918;
-    repeated bool        r_bool     = 536869919;
-    repeated string      r_string   = 536869920;
-    repeated DecoderTest r_message  = 536869922;
-    repeated bytes       r_bytes    = 536869923;
-    repeated uint32      r_uint32   = 536869924;
-    repeated TestEnum    r_enum     = 536869925;
-    repeated sfixed32    r_sfixed32 = 536869926;
-    repeated sfixed64    r_sfixed64 = 536869927;
-    repeated sint32      r_sint32   = 536869928;
-    repeated sint64      r_sint64   = 536869929;
-  }
-
-  optional group R_group = 536869921 {
-    optional double      f_double   = 1;
-    optional float       f_float    = 2;
-    optional int64       f_int64    = 3;
-    optional uint64      f_uint64   = 4;
-    optional int32       f_int32    = 5;
-    optional fixed64     f_fixed64  = 6;
-    optional fixed32     f_fixed32  = 7;
-    optional bool        f_bool     = 8;
-    optional string      f_string   = 9;
-    optional DecoderTest f_message  = 11;
-    optional bytes       f_bytes    = 12;
-    optional uint32      f_uint32   = 13;
-    optional TestEnum    f_enum     = 14;
-    optional sfixed32    f_sfixed32 = 15;
-    optional sfixed64    f_sfixed64 = 16;
-    optional sint32      f_sint32   = 17;
-    optional sint64      f_sint64   = 18;
-
-    optional string      nop_field  = 40;
-
-    repeated double      r_double   = 536869912;
-    repeated float       r_float    = 536869913;
-    repeated int64       r_int64    = 536869914;
-    repeated uint64      r_uint64   = 536869915;
-    repeated int32       r_int32    = 536869916;
-    repeated fixed64     r_fixed64  = 536869917;
-    repeated fixed32     r_fixed32  = 536869918;
-    repeated bool        r_bool     = 536869919;
-    repeated string      r_string   = 536869920;
-    repeated DecoderTest r_message  = 536869922;
-    repeated bytes       r_bytes    = 536869923;
-    repeated uint32      r_uint32   = 536869924;
-    repeated TestEnum    r_enum     = 536869925;
-    repeated sfixed32    r_sfixed32 = 536869926;
-    repeated sfixed64    r_sfixed64 = 536869927;
-    repeated sint32      r_sint32   = 536869928;
-    repeated sint64      r_sint64   = 536869929;
-  }
-}
diff --git a/third_party/upb/tests/pb/test_encoder.cc b/third_party/upb/tests/pb/test_encoder.cc
deleted file mode 100644 (file)
index b358ef5..0000000
+++ /dev/null
@@ -1,102 +0,0 @@
-
-#include <iostream>
-
-#include "google/protobuf/descriptor.upb.h"
-#include "google/protobuf/descriptor.upbdefs.h"
-#include "tests/test_util.h"
-#include "tests/upb_test.h"
-#include "upb/pb/decoder.h"
-#include "upb/pb/encoder.h"
-#include "upb/port_def.inc"
-#include "upb/upb.hpp"
-
-template <class T>
-class FillStringHandler {
- public:
-  static void SetHandler(upb_byteshandler* handler) {
-    upb_byteshandler_setstartstr(handler, &FillStringHandler::StartString,
-                                 NULL);
-    upb_byteshandler_setstring(handler, &FillStringHandler::StringBuf, NULL);
-  }
-
- private:
-  // TODO(haberman): add UpbBind/UpbMakeHandler support to BytesHandler so these
-  // can be prettier callbacks.
-  static void* StartString(void *c, const void *hd, size_t size) {
-    UPB_UNUSED(hd);
-    UPB_UNUSED(size);
-
-    T* str = static_cast<T*>(c);
-    str->clear();
-    return c;
-  }
-
-  static size_t StringBuf(void* c, const void* hd, const char* buf, size_t n,
-                          const upb_bufhandle* h) {
-    UPB_UNUSED(hd);
-    UPB_UNUSED(h);
-
-    T* str = static_cast<T*>(c);
-    try {
-      str->append(buf, n);
-      return n;
-    } catch (const std::exception&) {
-      return 0;
-    }
-  }
-};
-
-class StringSink {
- public:
-  template <class T>
-  explicit StringSink(T* target) {
-    // TODO(haberman): we need to avoid rebuilding a new handler every time,
-    // but with class globals disallowed for google3 C++ this is tricky.
-    upb_byteshandler_init(&handler_);
-    FillStringHandler<T>::SetHandler(&handler_);
-    input_.Reset(&handler_, target);
-  }
-
-  upb::BytesSink input() { return input_; }
-
- private:
-  upb_byteshandler handler_;
-  upb::BytesSink input_;
-};
-
-void test_pb_roundtrip() {
-  std::string input(
-      google_protobuf_descriptor_proto_upbdefinit.descriptor.data,
-      google_protobuf_descriptor_proto_upbdefinit.descriptor.size);
-  std::cout << input.size() << "\n";
-  upb::SymbolTable symtab;
-  upb::HandlerCache encoder_cache(upb::pb::EncoderPtr::NewCache());
-  upb::pb::CodeCache decoder_cache(&encoder_cache);
-  upb::Arena arena;
-  upb::Status status;
-  upb::MessageDefPtr md(
-      google_protobuf_FileDescriptorProto_getmsgdef(symtab.ptr()));
-  ASSERT(md);
-  const upb::Handlers *encoder_handlers = encoder_cache.Get(md);
-  ASSERT(encoder_handlers);
-  const upb::pb::DecoderMethodPtr method = decoder_cache.Get(md);
-
-  std::string output;
-  StringSink string_sink(&output);
-  upb::pb::EncoderPtr encoder =
-      upb::pb::EncoderPtr::Create(&arena, encoder_handlers, string_sink.input());
-  upb::pb::DecoderPtr decoder =
-      upb::pb::DecoderPtr::Create(&arena, method, encoder.input(), &status);
-  bool ok = upb::PutBuffer(input, decoder.input());
-  ASSERT(ok);
-  ASSERT(input == output);
-}
-
-extern "C" {
-int run_tests(int argc, char *argv[]) {
-  UPB_UNUSED(argc);
-  UPB_UNUSED(argv);
-  test_pb_roundtrip();
-  return 0;
-}
-}
index 9d3f64a..ece707b 100644 (file)
@@ -1,5 +1,29 @@
+// Copyright (c) 2009-2021, Google LLC
+// All rights reserved.
+//
+// Redistribution and use in source and binary forms, with or without
+// modification, are permitted provided that the following conditions are met:
+//     * Redistributions of source code must retain the above copyright
+//       notice, this list of conditions and the following disclaimer.
+//     * Redistributions in binary form must reproduce the above copyright
+//       notice, this list of conditions and the following disclaimer in the
+//       documentation and/or other materials provided with the distribution.
+//     * Neither the name of Google LLC nor the
+//       names of its contributors may be used to endorse or promote products
+//       derived from this software without specific prior written permission.
+//
+// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+// WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+// DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+// DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+// (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+// LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+// ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+// SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
 /*
- *
  * Tests for C++ wrappers.
  */
 
 #include <sstream>
 
 #include "tests/test_cpp.upbdefs.h"
+#include "tests/test_cpp.upb.h"
 #include "tests/upb_test.h"
 #include "upb/def.h"
-#include "upb/handlers.h"
-#include "upb/pb/decoder.h"
-#include "upb/pb/textprinter.h"
-#include "upb/port_def.inc"
+#include "upb/def.hpp"
+#include "upb/json_decode.h"
+#include "upb/json_encode.h"
 #include "upb/upb.h"
 
-template <class T>
-void AssertInsert(T* const container, const typename T::value_type& val) {
-  bool inserted = container->insert(val).second;
-  ASSERT(inserted);
-}
-
-//
-// Tests for registering and calling handlers in all their variants.
-// This test code is very repetitive because we have to declare each
-// handler function variant separately, and they all have different
-// signatures so it does not lend itself well to templates.
-//
-// We test three handler types:
-//   StartMessage (no data params)
-//   Int32        (1 data param (int32_t))
-//   String Buf   (2 data params (const char*, size_t))
-//
-// For each handler type we test all 8 handler variants:
-//   (handler data?) x  (function/method) x (returns {void, success})
-//
-// The one notable thing we don't test at the moment is
-// StartSequence/StartString handlers: these are different from StartMessage()
-// in that they return void* for the sub-closure.  But this is exercised in
-// other tests.
-//
-
-static const int kExpectedHandlerData = 1232323;
-
-class StringBufTesterBase {
- public:
-  static constexpr int kFieldNumber = 3;
-
-  StringBufTesterBase() : seen_(false), handler_data_val_(0) {}
-
-  void CallAndVerify(upb::Sink sink, upb::FieldDefPtr f) {
-    upb_selector_t start;
-    ASSERT(upb_handlers_getselector(f.ptr(), UPB_HANDLER_STARTSTR, &start));
-    upb_selector_t str;
-    ASSERT(upb_handlers_getselector(f.ptr(), UPB_HANDLER_STRING, &str));
-
-    ASSERT(!seen_);
-    upb::Sink sub;
-    sink.StartMessage();
-    sink.StartString(start, 0, &sub);
-    size_t ret = sub.PutStringBuffer(str, &buf_, 5, &handle_);
-    ASSERT(seen_);
-    ASSERT(len_ == 5);
-    ASSERT(ret == 5);
-    ASSERT(handler_data_val_ == kExpectedHandlerData);
-  }
-
- protected:
-  bool seen_;
-  int handler_data_val_;
-  size_t len_;
-  char buf_;
-  upb_bufhandle handle_;
-};
-
-// Test 8 combinations of:
-//   (handler data?) x (buffer handle?) x (function/method)
-//
-// Then we add one test each for this variation: to prevent combinatorial
-// explosion of these tests we don't test the full 16 combinations, but
-// rely on our knowledge that the implementation processes the return wrapping
-// in a second separate and independent stage:
-//
-//   (function/method)
-
-class StringBufTesterVoidMethodNoHandlerDataNoHandle
-    : public StringBufTesterBase {
- public:
-  typedef StringBufTesterVoidMethodNoHandlerDataNoHandle ME;
-  void Register(upb::HandlersPtr h, upb::FieldDefPtr f) {
-    UPB_UNUSED(f);
-    ASSERT(h.SetStringHandler(f, UpbMakeHandler(&ME::Handler)));
-    handler_data_val_ = kExpectedHandlerData;
-  }
-
- private:
-  void Handler(const char *buf, size_t len) {
-    ASSERT(buf == &buf_);
-    seen_ = true;
-    len_ = len;
-  }
-};
-
-class StringBufTesterVoidMethodNoHandlerDataWithHandle
-    : public StringBufTesterBase {
- public:
-  typedef StringBufTesterVoidMethodNoHandlerDataWithHandle ME;
-  void Register(upb::HandlersPtr h, upb::FieldDefPtr f) {
-    UPB_UNUSED(f);
-    ASSERT(h.SetStringHandler(f, UpbMakeHandler(&ME::Handler)));
-    handler_data_val_ = kExpectedHandlerData;
-  }
-
- private:
-  void Handler(const char *buf, size_t len, const upb_bufhandle* handle) {
-    ASSERT(buf == &buf_);
-    ASSERT(handle == &handle_);
-    seen_ = true;
-    len_ = len;
-  }
-};
-
-class StringBufTesterVoidMethodWithHandlerDataNoHandle
-    : public StringBufTesterBase {
- public:
-  typedef StringBufTesterVoidMethodWithHandlerDataNoHandle ME;
-  void Register(upb::HandlersPtr h, upb::FieldDefPtr f) {
-    UPB_UNUSED(f);
-    ASSERT(h.SetStringHandler(
-        f, UpbBind(&ME::Handler, new int(kExpectedHandlerData))));
-  }
-
- private:
-  void Handler(const int* hd, const char *buf, size_t len) {
-    ASSERT(buf == &buf_);
-    handler_data_val_ = *hd;
-    seen_ = true;
-    len_ = len;
-  }
-};
-
-class StringBufTesterVoidMethodWithHandlerDataWithHandle
-    : public StringBufTesterBase {
- public:
-  typedef StringBufTesterVoidMethodWithHandlerDataWithHandle ME;
-  void Register(upb::HandlersPtr h, upb::FieldDefPtr f) {
-    UPB_UNUSED(f);
-    ASSERT(h.SetStringHandler(
-        f, UpbBind(&ME::Handler, new int(kExpectedHandlerData))));
-  }
-
- private:
-  void Handler(const int* hd, const char* buf, size_t len,
-               const upb_bufhandle* handle) {
-    ASSERT(buf == &buf_);
-    ASSERT(handle == &handle_);
-    handler_data_val_ = *hd;
-    seen_ = true;
-    len_ = len;
-  }
-};
-
-class StringBufTesterVoidFunctionNoHandlerDataNoHandle
-    : public StringBufTesterBase {
- public:
-  typedef StringBufTesterVoidFunctionNoHandlerDataNoHandle ME;
-  void Register(upb::HandlersPtr h, upb::FieldDefPtr f) {
-    UPB_UNUSED(f);
-    ASSERT(h.SetStringHandler(f, UpbMakeHandler(&ME::Handler)));
-    handler_data_val_ = kExpectedHandlerData;
-  }
-
- private:
-  static void Handler(ME* t, const char *buf, size_t len) {
-    ASSERT(buf == &t->buf_);
-    t->seen_ = true;
-    t->len_ = len;
-  }
-};
-
-class StringBufTesterVoidFunctionNoHandlerDataWithHandle
-    : public StringBufTesterBase {
- public:
-  typedef StringBufTesterVoidFunctionNoHandlerDataWithHandle ME;
-  void Register(upb::HandlersPtr h, upb::FieldDefPtr f) {
-    UPB_UNUSED(f);
-    ASSERT(h.SetStringHandler(f, UpbMakeHandler(&ME::Handler)));
-    handler_data_val_ = kExpectedHandlerData;
-  }
-
- private:
-  static void Handler(ME* t, const char* buf, size_t len,
-                      const upb_bufhandle* handle) {
-    ASSERT(buf == &t->buf_);
-    ASSERT(handle == &t->handle_);
-    t->seen_ = true;
-    t->len_ = len;
-  }
-};
-
-class StringBufTesterVoidFunctionWithHandlerDataNoHandle
-    : public StringBufTesterBase {
- public:
-  typedef StringBufTesterVoidFunctionWithHandlerDataNoHandle ME;
-  void Register(upb::HandlersPtr h, upb::FieldDefPtr f) {
-    UPB_UNUSED(f);
-    ASSERT(h.SetStringHandler(
-        f, UpbBind(&ME::Handler, new int(kExpectedHandlerData))));
-  }
-
- private:
-  static void Handler(ME* t, const int* hd, const char *buf, size_t len) {
-    ASSERT(buf == &t->buf_);
-    t->handler_data_val_ = *hd;
-    t->seen_ = true;
-    t->len_ = len;
-  }
-};
-
-class StringBufTesterVoidFunctionWithHandlerDataWithHandle
-    : public StringBufTesterBase {
- public:
-  typedef StringBufTesterVoidFunctionWithHandlerDataWithHandle ME;
-  void Register(upb::HandlersPtr h, upb::FieldDefPtr f) {
-    UPB_UNUSED(f);
-    ASSERT(h.SetStringHandler(
-        f, UpbBind(&ME::Handler, new int(kExpectedHandlerData))));
-  }
-
- private:
-  static void Handler(ME* t, const int* hd, const char* buf, size_t len,
-                      const upb_bufhandle* handle) {
-    ASSERT(buf == &t->buf_);
-    ASSERT(handle == &t->handle_);
-    t->handler_data_val_ = *hd;
-    t->seen_ = true;
-    t->len_ = len;
-  }
-};
-
-class StringBufTesterSizeTMethodNoHandlerDataNoHandle
-    : public StringBufTesterBase {
- public:
-  typedef StringBufTesterSizeTMethodNoHandlerDataNoHandle ME;
-  void Register(upb::HandlersPtr h, upb::FieldDefPtr f) {
-    UPB_UNUSED(f);
-    ASSERT(h.SetStringHandler(f, UpbMakeHandler(&ME::Handler)));
-    handler_data_val_ = kExpectedHandlerData;
-  }
-
- private:
-  size_t Handler(const char *buf, size_t len) {
-    ASSERT(buf == &buf_);
-    seen_ = true;
-    len_ = len;
-    return len;
-  }
-};
-
-class StringBufTesterBoolMethodNoHandlerDataNoHandle
-    : public StringBufTesterBase {
- public:
-  typedef StringBufTesterBoolMethodNoHandlerDataNoHandle ME;
-  void Register(upb::HandlersPtr h, upb::FieldDefPtr f) {
-    UPB_UNUSED(f);
-    ASSERT(h.SetStringHandler(f, UpbMakeHandler(&ME::Handler)));
-    handler_data_val_ = kExpectedHandlerData;
-  }
-
- private:
-  bool Handler(const char *buf, size_t len) {
-    ASSERT(buf == &buf_);
-    seen_ = true;
-    len_ = len;
-    return true;
-  }
-};
-
-class StartMsgTesterBase {
- public:
-  // We don't need the FieldDef it will create, but the test harness still
-  // requires that we provide one.
-  static constexpr int kFieldNumber = 3;
-
-  StartMsgTesterBase() : seen_(false), handler_data_val_(0) {}
-
-  void CallAndVerify(upb::Sink sink, upb::FieldDefPtr f) {
-    UPB_UNUSED(f);
-    ASSERT(!seen_);
-    sink.StartMessage();
-    ASSERT(seen_);
-    ASSERT(handler_data_val_ == kExpectedHandlerData);
-  }
-
- protected:
-  bool seen_;
-  int handler_data_val_;
-};
-
-// Test all 8 combinations of:
-//   (handler data?) x  (function/method) x (returns {void, bool})
-
-class StartMsgTesterVoidFunctionNoHandlerData : public StartMsgTesterBase {
- public:
-  typedef StartMsgTesterVoidFunctionNoHandlerData ME;
-  void Register(upb::HandlersPtr h, upb::FieldDefPtr f) {
-    UPB_UNUSED(f);
-    ASSERT(h.SetStartMessageHandler(UpbMakeHandler(&Handler)));
-    handler_data_val_ = kExpectedHandlerData;
-  }
-
- private:
-  //static void Handler(ME* t) {
-  static void Handler(ME* t) {
-    t->seen_ = true;
-  }
-};
-
-class StartMsgTesterBoolFunctionNoHandlerData : public StartMsgTesterBase {
- public:
-  typedef StartMsgTesterBoolFunctionNoHandlerData ME;
-  void Register(upb::HandlersPtr h, upb::FieldDefPtr f) {
-    UPB_UNUSED(f);
-    ASSERT(h.SetStartMessageHandler(UpbMakeHandler(&Handler)));
-    handler_data_val_ = kExpectedHandlerData;
-  }
-
- private:
-  static bool Handler(ME* t) {
-    t->seen_ = true;
-    return true;
-  }
-};
-
-class StartMsgTesterVoidMethodNoHandlerData : public StartMsgTesterBase {
- public:
-  typedef StartMsgTesterVoidMethodNoHandlerData ME;
-  void Register(upb::HandlersPtr h, upb::FieldDefPtr f) {
-    UPB_UNUSED(f);
-    ASSERT(h.SetStartMessageHandler(UpbMakeHandler(&ME::Handler)));
-    handler_data_val_ = kExpectedHandlerData;
-  }
-
- private:
-  void Handler() {
-    seen_ = true;
-  }
-};
-
-class StartMsgTesterBoolMethodNoHandlerData : public StartMsgTesterBase {
- public:
-  typedef StartMsgTesterBoolMethodNoHandlerData ME;
-  void Register(upb::HandlersPtr h, upb::FieldDefPtr f) {
-    UPB_UNUSED(f);
-    ASSERT(h.SetStartMessageHandler(UpbMakeHandler(&ME::Handler)));
-    handler_data_val_ = kExpectedHandlerData;
-  }
-
- private:
-  bool Handler() {
-    seen_ = true;
-    return true;
-  }
-};
-
-class StartMsgTesterVoidFunctionWithHandlerData : public StartMsgTesterBase {
- public:
-  typedef StartMsgTesterVoidFunctionWithHandlerData ME;
-  void Register(upb::HandlersPtr h, upb::FieldDefPtr f) {
-    UPB_UNUSED(f);
-    ASSERT(h.SetStartMessageHandler(
-        UpbBind(&Handler, new int(kExpectedHandlerData))));
-  }
-
- private:
-  static void Handler(ME* t, const int* hd) {
-    t->handler_data_val_ = *hd;
-    t->seen_ = true;
-  }
-};
-
-class StartMsgTesterBoolFunctionWithHandlerData : public StartMsgTesterBase {
- public:
-  typedef StartMsgTesterBoolFunctionWithHandlerData ME;
-  void Register(upb::HandlersPtr h, upb::FieldDefPtr f) {
-    UPB_UNUSED(f);
-    ASSERT(h.SetStartMessageHandler(
-        UpbBind(&Handler, new int(kExpectedHandlerData))));
-  }
-
- private:
-  static bool Handler(ME* t, const int* hd) {
-    t->handler_data_val_ = *hd;
-    t->seen_ = true;
-    return true;
-  }
-};
-
-class StartMsgTesterVoidMethodWithHandlerData : public StartMsgTesterBase {
- public:
-  typedef StartMsgTesterVoidMethodWithHandlerData ME;
-  void Register(upb::HandlersPtr h, upb::FieldDefPtr f) {
-    UPB_UNUSED(f);
-    ASSERT(h.SetStartMessageHandler(
-        UpbBind(&ME::Handler, new int(kExpectedHandlerData))));
-  }
-
- private:
-  void Handler(const int* hd) {
-    handler_data_val_ = *hd;
-    seen_ = true;
-  }
-};
-
-class StartMsgTesterBoolMethodWithHandlerData : public StartMsgTesterBase {
- public:
-  typedef StartMsgTesterBoolMethodWithHandlerData ME;
-  void Register(upb::HandlersPtr h, upb::FieldDefPtr f) {
-    UPB_UNUSED(f);
-    ASSERT(h.SetStartMessageHandler(
-        UpbBind(&ME::Handler, new int(kExpectedHandlerData))));
-  }
-
- private:
-  bool Handler(const int* hd) {
-    handler_data_val_ = *hd;
-    seen_ = true;
-    return true;
-  }
-};
-
-class Int32ValueTesterBase {
- public:
-  static constexpr int kFieldNumber = 1;
-
-  Int32ValueTesterBase() : seen_(false), val_(0), handler_data_val_(0) {}
-
-  void CallAndVerify(upb::Sink sink, upb::FieldDefPtr f) {
-    upb_selector_t s;
-    ASSERT(upb_handlers_getselector(f.ptr(), UPB_HANDLER_INT32, &s));
-
-    ASSERT(!seen_);
-    sink.PutInt32(s, 5);
-    ASSERT(seen_);
-    ASSERT(handler_data_val_ == kExpectedHandlerData);
-    ASSERT(val_ == 5);
-  }
-
- protected:
-  bool seen_;
-  int32_t val_;
-  int handler_data_val_;
-};
-
-// Test all 8 combinations of:
-//   (handler data?) x  (function/method) x (returns {void, bool})
-
-class ValueTesterInt32VoidFunctionNoHandlerData
-    : public Int32ValueTesterBase {
- public:
-  typedef ValueTesterInt32VoidFunctionNoHandlerData ME;
-  void Register(upb::HandlersPtr h, upb::FieldDefPtr f) {
-    ASSERT(h.SetInt32Handler(f, UpbMakeHandler(&Handler)));
-    handler_data_val_ = kExpectedHandlerData;
-  }
-
- private:
-  static void Handler(ME* t, int32_t val) {
-    t->val_ = val;
-    t->seen_ = true;
-  }
-};
-
-class ValueTesterInt32BoolFunctionNoHandlerData
-    : public Int32ValueTesterBase {
- public:
-  typedef ValueTesterInt32BoolFunctionNoHandlerData ME;
-  void Register(upb::HandlersPtr h, upb::FieldDefPtr f) {
-    ASSERT(h.SetInt32Handler(f, UpbMakeHandler(&Handler)));
-    handler_data_val_ = kExpectedHandlerData;
-  }
-
- private:
-  static bool Handler(ME* t, int32_t val) {
-    t->val_ = val;
-    t->seen_ = true;
-    return true;
-  }
-};
-
-class ValueTesterInt32VoidMethodNoHandlerData : public Int32ValueTesterBase {
- public:
-  typedef ValueTesterInt32VoidMethodNoHandlerData ME;
-  void Register(upb::HandlersPtr h, upb::FieldDefPtr f) {
-    ASSERT(h.SetInt32Handler(f, UpbMakeHandler(&ME::Handler)));
-    handler_data_val_ = kExpectedHandlerData;
-  }
-
- private:
-  void Handler(int32_t val) {
-    val_ = val;
-    seen_ = true;
-  }
-};
-
-class ValueTesterInt32BoolMethodNoHandlerData : public Int32ValueTesterBase {
- public:
-  typedef ValueTesterInt32BoolMethodNoHandlerData ME;
-  void Register(upb::HandlersPtr h, upb::FieldDefPtr f) {
-    ASSERT(h.SetInt32Handler(f, UpbMakeHandler(&ME::Handler)));
-    handler_data_val_ = kExpectedHandlerData;
-  }
-
- private:
-  bool Handler(int32_t val) {
-    val_ = val;
-    seen_ = true;
-    return true;
-  }
-};
-
-class ValueTesterInt32VoidFunctionWithHandlerData
-    : public Int32ValueTesterBase {
- public:
-  typedef ValueTesterInt32VoidFunctionWithHandlerData ME;
-  void Register(upb::HandlersPtr h, upb::FieldDefPtr f) {
-    ASSERT(h.SetInt32Handler(
-        f, UpbBind(&Handler, new int(kExpectedHandlerData))));
-  }
-
- private:
-  static void Handler(ME* t, const int* hd, int32_t val) {
-    t->val_ = val;
-    t->handler_data_val_ = *hd;
-    t->seen_ = true;
-  }
-};
-
-class ValueTesterInt32BoolFunctionWithHandlerData
-    : public Int32ValueTesterBase {
- public:
-  typedef ValueTesterInt32BoolFunctionWithHandlerData ME;
-  void Register(upb::HandlersPtr h, upb::FieldDefPtr f) {
-    ASSERT(h.SetInt32Handler(
-        f, UpbBind(&Handler, new int(kExpectedHandlerData))));
-  }
-
- private:
-  static bool Handler(ME* t, const int* hd, int32_t val) {
-    t->val_ = val;
-    t->handler_data_val_ = *hd;
-    t->seen_ = true;
-    return true;
-  }
-};
-
-class ValueTesterInt32VoidMethodWithHandlerData : public Int32ValueTesterBase {
- public:
-  typedef ValueTesterInt32VoidMethodWithHandlerData ME;
-  void Register(upb::HandlersPtr h, upb::FieldDefPtr f) {
-    ASSERT(h.SetInt32Handler(
-        f, UpbBind(&ME::Handler, new int(kExpectedHandlerData))));
-  }
-
- private:
-  void Handler(const int* hd, int32_t val) {
-    val_ = val;
-    handler_data_val_ = *hd;
-    seen_ = true;
-  }
-};
-
-class ValueTesterInt32BoolMethodWithHandlerData : public Int32ValueTesterBase {
- public:
-  typedef ValueTesterInt32BoolMethodWithHandlerData ME;
-  void Register(upb::HandlersPtr h, upb::FieldDefPtr f) {
-    ASSERT(h.SetInt32Handler(
-        f, UpbBind(&ME::Handler, new int(kExpectedHandlerData))));
-  }
-
- private:
-  bool Handler(const int* hd, int32_t val) {
-    val_ = val;
-    handler_data_val_ = *hd;
-    seen_ = true;
-    return true;
-  }
-};
-
-template <class T>
-void RegisterHandlers(const void* closure, upb::Handlers* h_ptr) {
-  T* tester = const_cast<T*>(static_cast<const T*>(closure));
-  upb::HandlersPtr h(h_ptr);
-  upb::FieldDefPtr f = h.message_def().FindFieldByNumber(T::kFieldNumber);
-  ASSERT(f);
-  tester->Register(h, f);
-}
-
-template <class T>
-void TestHandler() {
-  T tester;
-  upb::SymbolTable symtab;
-  upb::HandlerCache cache(&RegisterHandlers<T>, &tester);
-  upb::MessageDefPtr md(upb_test_TestMessage_getmsgdef(symtab.ptr()));
-  ASSERT(md);
-  upb::FieldDefPtr f = md.FindFieldByNumber(T::kFieldNumber);
-  ASSERT(f);
-
-  const upb::Handlers* h = cache.Get(md);
-
-  upb::Sink sink(h, &tester);
-  tester.CallAndVerify(sink, f);
-}
-
-class T1 {};
-class T2 {};
-
-template <class C>
-void DoNothingHandler(C* closure) {
-  UPB_UNUSED(closure);
-}
-
-template <class C>
-void DoNothingInt32Handler(C* closure, int32_t val) {
-  UPB_UNUSED(closure);
-  UPB_UNUSED(val);
-}
-
-template <class R>
-class DoNothingStartHandler {
- public:
-  // We wrap these functions inside of a class for a somewhat annoying reason.
-  // UpbMakeHandler() is a macro, so we can't say
-  //    UpbMakeHandler(DoNothingStartHandler<T1, T2>)
-  //
-  // because otherwise the preprocessor gets confused at the comma and tries to
-  // make it two macro arguments.  The usual solution doesn't work either:
-  //    UpbMakeHandler((DoNothingStartHandler<T1, T2>))
-  //
-  // If we do that the macro expands correctly, but then it tries to pass that
-  // parenthesized expression as a template parameter, ie. Type<(F)>, which
-  // isn't legal C++ (Clang will compile it but complains with
-  //    warning: address non-type template argument cannot be surrounded by
-  //    parentheses
-  //
-  // This two-level thing allows us to effectively pass two template parameters,
-  // but without any commas:
-  //    UpbMakeHandler(DoNothingStartHandler<T1>::Handler<T2>)
-  template <class C>
-  static R* Handler(C* closure) {
-    UPB_UNUSED(closure);
-    return NULL;
-  }
-
-  template <class C>
-  static R* String(C* closure, size_t size_len) {
-    UPB_UNUSED(closure);
-    UPB_UNUSED(size_len);
-    return NULL;
-  }
-};
-
-template <class C>
-void DoNothingStringBufHandler(C* closure, const char *buf, size_t len) {
-  UPB_UNUSED(closure);
-  UPB_UNUSED(buf);
-  UPB_UNUSED(len);
-}
-
-template <class C>
-void DoNothingEndMessageHandler(C* closure, upb_status *status) {
-  UPB_UNUSED(closure);
-  UPB_UNUSED(status);
-}
-
-void RegisterMismatchedTypes(const void* closure, upb::Handlers* h_ptr) {
-  upb::HandlersPtr h(h_ptr);
-  UPB_UNUSED(closure);
-
-  upb::MessageDefPtr md(h.message_def());
-  ASSERT(md);
-  upb::FieldDefPtr i32 = md.FindFieldByName("i32");
-  upb::FieldDefPtr r_i32 = md.FindFieldByName("r_i32");
-  upb::FieldDefPtr str = md.FindFieldByName("str");
-  upb::FieldDefPtr r_str = md.FindFieldByName("r_str");
-  upb::FieldDefPtr msg = md.FindFieldByName("msg");
-  upb::FieldDefPtr r_msg = md.FindFieldByName("r_msg");
-  ASSERT(i32);
-  ASSERT(r_i32);
-  ASSERT(str);
-  ASSERT(r_str);
-  ASSERT(msg);
-  ASSERT(r_msg);
-
-  // Establish T1 as the top-level closure type.
-  ASSERT(h.SetInt32Handler(i32, UpbMakeHandler(DoNothingInt32Handler<T1>)));
-
-  // Now any other attempt to set another handler with T2 as the top-level
-  // closure should fail.  But setting these same handlers with T1 as the
-  // top-level closure will succeed.
-  ASSERT(!h.SetStartMessageHandler(UpbMakeHandler(DoNothingHandler<T2>)));
-  ASSERT(h.SetStartMessageHandler(UpbMakeHandler(DoNothingHandler<T1>)));
-
-  ASSERT(
-      !h.SetEndMessageHandler(UpbMakeHandler(DoNothingEndMessageHandler<T2>)));
-  ASSERT(
-      h.SetEndMessageHandler(UpbMakeHandler(DoNothingEndMessageHandler<T1>)));
-
-  ASSERT(!h.SetStartStringHandler(
-              str, UpbMakeHandler(DoNothingStartHandler<T1>::String<T2>)));
-  ASSERT(h.SetStartStringHandler(
-              str, UpbMakeHandler(DoNothingStartHandler<T1>::String<T1>)));
-
-  ASSERT(!h.SetEndStringHandler(str, UpbMakeHandler(DoNothingHandler<T2>)));
-  ASSERT(h.SetEndStringHandler(str, UpbMakeHandler(DoNothingHandler<T1>)));
-
-  ASSERT(!h.SetStartSubMessageHandler(
-              msg, UpbMakeHandler(DoNothingStartHandler<T1>::Handler<T2>)));
-  ASSERT(h.SetStartSubMessageHandler(
-              msg, UpbMakeHandler(DoNothingStartHandler<T1>::Handler<T1>)));
-
-  ASSERT(
-      !h.SetEndSubMessageHandler(msg, UpbMakeHandler(DoNothingHandler<T2>)));
-  ASSERT(
-      h.SetEndSubMessageHandler(msg, UpbMakeHandler(DoNothingHandler<T1>)));
-
-  ASSERT(!h.SetStartSequenceHandler(
-              r_i32, UpbMakeHandler(DoNothingStartHandler<T1>::Handler<T2>)));
-  ASSERT(h.SetStartSequenceHandler(
-              r_i32, UpbMakeHandler(DoNothingStartHandler<T1>::Handler<T1>)));
-
-  ASSERT(!h.SetEndSequenceHandler(
-              r_i32, UpbMakeHandler(DoNothingHandler<T2>)));
-  ASSERT(h.SetEndSequenceHandler(
-              r_i32, UpbMakeHandler(DoNothingHandler<T1>)));
-
-  ASSERT(!h.SetStartSequenceHandler(
-              r_msg, UpbMakeHandler(DoNothingStartHandler<T1>::Handler<T2>)));
-  ASSERT(h.SetStartSequenceHandler(
-              r_msg, UpbMakeHandler(DoNothingStartHandler<T1>::Handler<T1>)));
-
-  ASSERT(!h.SetEndSequenceHandler(
-              r_msg, UpbMakeHandler(DoNothingHandler<T2>)));
-  ASSERT(h.SetEndSequenceHandler(
-              r_msg, UpbMakeHandler(DoNothingHandler<T1>)));
-
-  ASSERT(!h.SetStartSequenceHandler(
-              r_str, UpbMakeHandler(DoNothingStartHandler<T1>::Handler<T2>)));
-  ASSERT(h.SetStartSequenceHandler(
-              r_str, UpbMakeHandler(DoNothingStartHandler<T1>::Handler<T1>)));
-
-  ASSERT(!h.SetEndSequenceHandler(
-              r_str, UpbMakeHandler(DoNothingHandler<T2>)));
-  ASSERT(h.SetEndSequenceHandler(
-              r_str, UpbMakeHandler(DoNothingHandler<T1>)));
-
-  // By setting T1 as the return type for the Start* handlers we have
-  // established T1 as the type of the sequence and string frames.
-  // Setting callbacks that use T2 should fail, but T1 should succeed.
-  ASSERT(
-      !h.SetStringHandler(str, UpbMakeHandler(DoNothingStringBufHandler<T2>)));
-  ASSERT(
-      h.SetStringHandler(str, UpbMakeHandler(DoNothingStringBufHandler<T1>)));
-
-  ASSERT(!h.SetInt32Handler(r_i32, UpbMakeHandler(DoNothingInt32Handler<T2>)));
-  ASSERT(h.SetInt32Handler(r_i32, UpbMakeHandler(DoNothingInt32Handler<T1>)));
-
-  ASSERT(!h.SetStartSubMessageHandler(
-              r_msg, UpbMakeHandler(DoNothingStartHandler<T1>::Handler<T2>)));
-  ASSERT(h.SetStartSubMessageHandler(
-              r_msg, UpbMakeHandler(DoNothingStartHandler<T1>::Handler<T1>)));
-
-  ASSERT(!h.SetEndSubMessageHandler(r_msg,
-                                     UpbMakeHandler(DoNothingHandler<T2>)));
-  ASSERT(h.SetEndSubMessageHandler(r_msg,
-                                    UpbMakeHandler(DoNothingHandler<T1>)));
-
-  ASSERT(!h.SetStartStringHandler(
-              r_str, UpbMakeHandler(DoNothingStartHandler<T1>::String<T2>)));
-  ASSERT(h.SetStartStringHandler(
-              r_str, UpbMakeHandler(DoNothingStartHandler<T1>::String<T1>)));
-
-  ASSERT(
-      !h.SetEndStringHandler(r_str, UpbMakeHandler(DoNothingHandler<T2>)));
-  ASSERT(h.SetEndStringHandler(r_str, UpbMakeHandler(DoNothingHandler<T1>)));
-
-  ASSERT(!h.SetStringHandler(r_str,
-                              UpbMakeHandler(DoNothingStringBufHandler<T2>)));
-  ASSERT(h.SetStringHandler(r_str,
-                             UpbMakeHandler(DoNothingStringBufHandler<T1>)));
-}
-
-void RegisterMismatchedTypes2(const void* closure, upb::Handlers* h_ptr) {
-  upb::HandlersPtr h(h_ptr);
-  UPB_UNUSED(closure);
-
-  upb::MessageDefPtr md(h.message_def());
-  ASSERT(md);
-  upb::FieldDefPtr i32 = md.FindFieldByName("i32");
-  upb::FieldDefPtr r_i32 = md.FindFieldByName("r_i32");
-  upb::FieldDefPtr str = md.FindFieldByName("str");
-  upb::FieldDefPtr r_str = md.FindFieldByName("r_str");
-  upb::FieldDefPtr msg = md.FindFieldByName("msg");
-  upb::FieldDefPtr r_msg = md.FindFieldByName("r_msg");
-  ASSERT(i32);
-  ASSERT(r_i32);
-  ASSERT(str);
-  ASSERT(r_str);
-  ASSERT(msg);
-  ASSERT(r_msg);
-
-  // For our second test we do the same in reverse.  We directly set the type of
-  // the frame and then observe failures at registering a Start* handler that
-  // returns a different type.
-
-  // First establish the type of a sequence frame directly.
-  ASSERT(h.SetInt32Handler(r_i32, UpbMakeHandler(DoNothingInt32Handler<T1>)));
-
-  // Now setting a StartSequence callback that returns a different type should
-  // fail.
-  ASSERT(!h.SetStartSequenceHandler(
-              r_i32, UpbMakeHandler(DoNothingStartHandler<T2>::Handler<T1>)));
-  ASSERT(h.SetStartSequenceHandler(
-              r_i32, UpbMakeHandler(DoNothingStartHandler<T1>::Handler<T1>)));
-
-  // Establish a string frame directly.
-  ASSERT(h.SetStringHandler(r_str,
-                             UpbMakeHandler(DoNothingStringBufHandler<T1>)));
-
-  // Fail setting a StartString callback that returns a different type.
-  ASSERT(!h.SetStartStringHandler(
-              r_str, UpbMakeHandler(DoNothingStartHandler<T2>::String<T1>)));
-  ASSERT(h.SetStartStringHandler(
-      r_str, UpbMakeHandler(DoNothingStartHandler<T1>::String<T1>)));
-
-  // The previous established T1 as the frame for the r_str sequence.
-  ASSERT(!h.SetStartSequenceHandler(
-              r_str, UpbMakeHandler(DoNothingStartHandler<T2>::Handler<T1>)));
-  ASSERT(h.SetStartSequenceHandler(
-      r_str, UpbMakeHandler(DoNothingStartHandler<T1>::Handler<T1>)));
-}
-
-void TestMismatchedTypes() {
-  // First create a schema for our test.
-  upb::SymbolTable symtab;
-  upb::HandlerCache handler_cache(&RegisterMismatchedTypes, nullptr);
-  upb::HandlerCache handler_cache2(&RegisterMismatchedTypes2, nullptr);
-  const upb::MessageDefPtr md(upb_test_TestMessage_getmsgdef(symtab.ptr()));
-
-  // Now test the type-checking in handler registration.
-  handler_cache.Get(md);
-  handler_cache2.Get(md);
-}
-
-class IntIncrementer {
- public:
-  explicit IntIncrementer(int* x) : x_(x) { (*x_)++; }
-  ~IntIncrementer() { (*x_)--; }
-
-  static void Handler(void* closure, const IntIncrementer* incrementer,
-                      int32_t x) {
-    UPB_UNUSED(closure);
-    UPB_UNUSED(incrementer);
-    UPB_UNUSED(x);
-  }
-
- private:
-  int* x_;
-};
-
-void RegisterIncrementor(const void* closure, upb::Handlers* h_ptr) {
-  const int* x = static_cast<const int*>(closure);
-  upb::HandlersPtr h(h_ptr);
-  upb::FieldDefPtr f = h.message_def().FindFieldByName("i32");
-  h.SetInt32Handler(f, UpbBind(&IntIncrementer::Handler,
-                               new IntIncrementer(const_cast<int*>(x))));
-}
-
-void TestHandlerDataDestruction() {
-  int x = 0;
-
-  {
-    upb::SymbolTable symtab;
-    upb::HandlerCache cache(&RegisterIncrementor, &x);
-    upb::MessageDefPtr md(upb_test_TestMessage_getmsgdef(symtab.ptr()));
-    cache.Get(md);
-    ASSERT(x == 1);
-  }
-
-  ASSERT(x == 0);
-}
+// Must be last.
+#include "upb/port_def.inc"
 
 void TestIteration() {
   upb::SymbolTable symtab;
@@ -977,43 +128,32 @@ void TestInlinedArena() {
   ASSERT(n == 0);
 }
 
-extern "C" {
-
-int run_tests() {
-  TestHandler<ValueTesterInt32VoidFunctionNoHandlerData>();
-  TestHandler<ValueTesterInt32BoolFunctionNoHandlerData>();
-  TestHandler<ValueTesterInt32VoidMethodNoHandlerData>();
-  TestHandler<ValueTesterInt32BoolMethodNoHandlerData>();
-  TestHandler<ValueTesterInt32VoidFunctionWithHandlerData>();
-  TestHandler<ValueTesterInt32BoolFunctionWithHandlerData>();
-  TestHandler<ValueTesterInt32VoidMethodWithHandlerData>();
-  TestHandler<ValueTesterInt32BoolMethodWithHandlerData>();
-
-  TestHandler<StartMsgTesterVoidFunctionNoHandlerData>();
-  TestHandler<StartMsgTesterBoolFunctionNoHandlerData>();
-  TestHandler<StartMsgTesterVoidMethodNoHandlerData>();
-  TestHandler<StartMsgTesterBoolMethodNoHandlerData>();
-  TestHandler<StartMsgTesterVoidFunctionWithHandlerData>();
-  TestHandler<StartMsgTesterBoolFunctionWithHandlerData>();
-  TestHandler<StartMsgTesterVoidMethodWithHandlerData>();
-  TestHandler<StartMsgTesterBoolMethodWithHandlerData>();
+void TestDefault() {
+  upb::SymbolTable symtab;
+  upb::Arena arena;
+  upb::MessageDefPtr md(upb_test_TestMessage_getmsgdef(symtab.ptr()));
+  upb_test_TestMessage *msg = upb_test_TestMessage_new(arena.ptr());
+  size_t size = upb_json_encode(msg, md.ptr(), NULL, 0, NULL, 0, NULL);
+  ASSERT(size == 2);  // "{}"
+}
 
-  TestHandler<StringBufTesterVoidMethodNoHandlerDataNoHandle>();
-  TestHandler<StringBufTesterVoidMethodNoHandlerDataWithHandle>();
-  TestHandler<StringBufTesterVoidMethodWithHandlerDataNoHandle>();
-  TestHandler<StringBufTesterVoidMethodWithHandlerDataWithHandle>();
-  TestHandler<StringBufTesterVoidFunctionNoHandlerDataNoHandle>();
-  TestHandler<StringBufTesterVoidFunctionNoHandlerDataWithHandle>();
-  TestHandler<StringBufTesterVoidFunctionWithHandlerDataNoHandle>();
-  TestHandler<StringBufTesterVoidFunctionWithHandlerDataWithHandle>();
-  TestHandler<StringBufTesterSizeTMethodNoHandlerDataNoHandle>();
-  TestHandler<StringBufTesterBoolMethodNoHandlerDataNoHandle>();
+void TestJsonNull() {
+  upb::SymbolTable symtab;
+  upb::MessageDefPtr md(upb_test_TestMessage_getmsgdef(symtab.ptr()));
+  upb::FieldDefPtr i32_f = md.FindFieldByName("i32");
+  upb::FieldDefPtr str_f = md.FindFieldByName("str");
+  ASSERT(i32_f && str_f);
+  ASSERT(i32_f.default_value().int32_val == 5);
+  ASSERT(strcmp(str_f.default_value().str_val.data, "abc") == 0);
+  ASSERT(str_f.default_value().str_val.size == 3);
+}
 
-  TestMismatchedTypes();
+extern "C" {
 
-  TestHandlerDataDestruction();
+int run_tests() {
   TestIteration();
   TestArena();
+  TestDefault();
 
   return 0;
 }
index f890350..4992b8c 100644 (file)
@@ -3,9 +3,9 @@ syntax = "proto2";
 package upb.test;
 
 message TestMessage {
-  optional int32 i32 = 1;
+  optional int32 i32 = 1 [default = 5];
   repeated int32 r_i32 = 2;
-  optional string str = 3;
+  optional string str = 3 [default = "abc"];
   repeated string r_str = 4;
   optional TestMessage msg = 5;
   repeated TestMessage r_msg = 6;
index bd1066b..2afdefd 100644 (file)
@@ -1,3 +1,30 @@
+/*
+ * Copyright (c) 2009-2021, Google LLC
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ *     * Redistributions of source code must retain the above copyright
+ *       notice, this list of conditions and the following disclaimer.
+ *     * Redistributions in binary form must reproduce the above copyright
+ *       notice, this list of conditions and the following disclaimer in the
+ *       documentation and/or other materials provided with the distribution.
+ *     * Neither the name of Google LLC nor the
+ *       names of its contributors may be used to endorse or promote products
+ *       derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+ * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ * DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+ * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+ * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+ * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
 /* Test of generated code, with a special focus on features that are not used in
  * descriptor.proto or conformance.proto (since these get some testing from
  * upb/def.c and tests/conformance_upb.c, respectively).
@@ -410,6 +437,101 @@ void test_status_truncation(void) {
   }
 }
 
+void decrement_int(void *ptr) {
+  int* iptr = ptr;
+  (*iptr)--;
+}
+
+void test_arena_fuse(void) {
+  int i1 = 5;
+  int i2 = 5;
+  int i3 = 5;
+  int i4 = 5;
+
+  upb_arena *arena1 = upb_arena_new();
+  upb_arena *arena2 = upb_arena_new();
+
+  upb_arena_addcleanup(arena1, &i1, decrement_int);
+  upb_arena_addcleanup(arena2, &i2, decrement_int);
+
+  ASSERT(upb_arena_fuse(arena1, arena2));
+
+  upb_arena_addcleanup(arena1, &i3, decrement_int);
+  upb_arena_addcleanup(arena2, &i4, decrement_int);
+
+  upb_arena_free(arena1);
+  ASSERT(i1 == 5);
+  ASSERT(i2 == 5);
+  ASSERT(i3 == 5);
+  ASSERT(i4 == 5);
+  upb_arena_free(arena2);
+  ASSERT(i1 == 4);
+  ASSERT(i2 == 4);
+  ASSERT(i3 == 4);
+  ASSERT(i4 == 4);
+}
+
+/* Do nothing allocator for testing */
+static void *test_allocfunc(upb_alloc *alloc, void *ptr, size_t oldsize,
+                            size_t size) {
+  return upb_alloc_global.func(alloc, ptr, oldsize, size);
+}
+upb_alloc test_alloc = {&test_allocfunc};
+
+void test_arena_fuse_with_initial_block(void) {
+  char buf1[1024];
+  char buf2[1024];
+  upb_arena *arenas[] = {upb_arena_init(buf1, 1024, &upb_alloc_global),
+                         upb_arena_init(buf2, 1024, &upb_alloc_global),
+                         upb_arena_init(NULL, 0, &test_alloc),
+                         upb_arena_init(NULL, 0, &upb_alloc_global)};
+  int size = sizeof(arenas)/sizeof(arenas[0]);
+  for (int i = 0; i < size; ++i) {
+    for (int j = 0; j < size; ++j) {
+      if (i == j) {
+        ASSERT(upb_arena_fuse(arenas[i], arenas[j]));
+      } else {
+        ASSERT(!upb_arena_fuse(arenas[i], arenas[j]));
+      }
+    }
+  }
+
+  for (int i = 0; i < size; ++i) upb_arena_free(arenas[i]);
+}
+
+void test_arena_decode(void) {
+  // Tests against a bug that previously existed when passing an arena to
+  // upb_decode().
+  char large_string[1024] = {0};
+  upb_strview large_string_view = {large_string, sizeof(large_string)};
+  upb_arena *tmp = upb_arena_new();
+
+  protobuf_test_messages_proto3_TestAllTypesProto3 *msg =
+      protobuf_test_messages_proto3_TestAllTypesProto3_new(tmp);
+
+  protobuf_test_messages_proto3_TestAllTypesProto3_set_optional_bytes(
+      msg, large_string_view);
+
+  upb_strview serialized;
+  serialized.data = protobuf_test_messages_proto3_TestAllTypesProto3_serialize(
+      msg, tmp, &serialized.size);
+
+  upb_arena *arena = upb_arena_new();
+  // Parse the large payload, forcing an arena block to be allocated. This used
+  // to corrupt the cleanup list, preventing subsequent upb_arena_addcleanup()
+  // calls from working properly.
+  protobuf_test_messages_proto3_TestAllTypesProto3_parse(
+      serialized.data, serialized.size, arena);
+
+  int i1 = 5;
+  upb_arena_addcleanup(arena, &i1, decrement_int);
+  ASSERT(i1 == 5);
+  upb_arena_free(arena);
+  ASSERT(i1 == 4);
+
+  upb_arena_free(tmp);
+}
+
 int run_tests(int argc, char *argv[]) {
   test_scalars();
   test_utf8();
@@ -419,5 +541,8 @@ int run_tests(int argc, char *argv[]) {
   test_repeated();
   test_null_decode_buf();
   test_status_truncation();
+  test_arena_fuse();
+  test_arena_fuse_with_initial_block();
+  test_arena_decode();
   return 0;
 }
index 83b49f5..84ede2b 100644 (file)
@@ -1,5 +1,29 @@
+// Copyright (c) 2009-2021, Google LLC
+// All rights reserved.
+//
+// Redistribution and use in source and binary forms, with or without
+// modification, are permitted provided that the following conditions are met:
+//     * Redistributions of source code must retain the above copyright
+//       notice, this list of conditions and the following disclaimer.
+//     * Redistributions in binary form must reproduce the above copyright
+//       notice, this list of conditions and the following disclaimer in the
+//       documentation and/or other materials provided with the distribution.
+//     * Neither the name of Google LLC nor the
+//       names of its contributors may be used to endorse or promote products
+//       derived from this software without specific prior written permission.
+//
+// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+// WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+// DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+// DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+// (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+// LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+// ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+// SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
 /*
- *
  * Tests for upb_table.
  */
 
@@ -14,7 +38,8 @@
 #include <vector>
 
 #include "tests/upb_test.h"
-#include "upb/table.int.h"
+#include "upb/upb.hpp"
+#include "upb/table_internal.h"
 
 #include "upb/port_def.inc"
 
@@ -25,12 +50,10 @@ namespace upb {
 
 template <class T> upb_value MakeUpbValue(T val);
 template <class T> T GetUpbValue(upb_value val);
-template <class T> upb_ctype_t GetUpbValueType();
 
 #define FUNCS(name, type_t, enumval) \
   template<> upb_value MakeUpbValue<type_t>(type_t val) { return upb_value_ ## name(val); } \
   template<> type_t GetUpbValue<type_t>(upb_value val) { return upb_value_get ## name(val); } \
-  template<> upb_ctype_t GetUpbValueType<type_t>() { return enumval; }
 
 FUNCS(int32,    int32_t,      UPB_CTYPE_INT32)
 FUNCS(int64,    int64_t,      UPB_CTYPE_INT64)
@@ -46,13 +69,12 @@ FUNCS(fptr,     upb_func*,    UPB_CTYPE_FPTR)
 
 class IntTable {
  public:
-  IntTable(upb_ctype_t value_type) { upb_inttable_init(&table_, value_type); }
-  ~IntTable() { upb_inttable_uninit(&table_); }
+  IntTable() { upb_inttable_init(&table_, arena_.ptr()); }
 
   size_t count() { return upb_inttable_count(&table_); }
 
   bool Insert(uintptr_t key, upb_value val) {
-    return upb_inttable_insert(&table_, key, val);
+    return upb_inttable_insert(&table_, key, val, arena_.ptr());
   }
 
   bool Replace(uintptr_t key, upb_value val) {
@@ -73,11 +95,11 @@ class IntTable {
 
   std::pair<bool, upb_value> Lookup32(uint32_t key) const {
     std::pair<bool, upb_value> ret;
-    ret.first = upb_inttable_lookup32(&table_, key, &ret.second);
+    ret.first = upb_inttable_lookup(&table_, key, &ret.second);
     return ret;
   }
 
-  void Compact() { upb_inttable_compact(&table_); }
+  void Compact() { upb_inttable_compact(&table_, arena_.ptr()); }
 
   class iterator : public std::iterator<std::forward_iterator_tag,
                                         std::pair<uintptr_t, upb_value> > {
@@ -115,24 +137,25 @@ class IntTable {
     upb_inttable_iter iter_;
   };
 
+  upb::Arena arena_;
   upb_inttable table_;
 };
 
 class StrTable {
  public:
-  StrTable(upb_ctype_t value_type) { upb_strtable_init(&table_, value_type); }
-  ~StrTable() { upb_strtable_uninit(&table_); }
+  StrTable() { upb_strtable_init(&table_, 4, arena_.ptr()); }
 
   size_t count() { return upb_strtable_count(&table_); }
 
   bool Insert(const std::string& key, upb_value val) {
-    return upb_strtable_insert2(&table_, key.c_str(), key.size(), val);
+    return upb_strtable_insert(&table_, key.c_str(), key.size(), val,
+                               arena_.ptr());
   }
 
   std::pair<bool, upb_value> Remove(const std::string& key) {
     std::pair<bool, upb_value> ret;
     ret.first =
-        upb_strtable_remove2(&table_, key.c_str(), key.size(), &ret.second);
+        upb_strtable_remove(&table_, key.c_str(), key.size(), &ret.second);
     return ret;
   }
 
@@ -144,7 +167,7 @@ class StrTable {
   }
 
   void Resize(size_t size_lg2) {
-    upb_strtable_resize(&table_, size_lg2, &upb_alloc_global);
+    upb_strtable_resize(&table_, size_lg2, arena_.ptr());
   }
 
   class iterator : public std::iterator<std::forward_iterator_tag,
@@ -184,13 +207,12 @@ class StrTable {
     upb_strtable_iter iter_;
   };
 
+  upb::Arena arena_;
   upb_strtable table_;
 };
 
 template <class T> class TypedStrTable {
  public:
-  TypedStrTable() : table_(GetUpbValueType<T>()) {}
-
   size_t count() { return table_.count(); }
 
   bool Insert(const std::string &key, T val) {
@@ -260,8 +282,6 @@ template <class T> class TypedStrTable {
 
 template <class T> class TypedIntTable {
  public:
-  TypedIntTable() : table_(GetUpbValueType<T>()) {}
-
   size_t count() { return table_.count(); }
 
   bool Insert(uintptr_t key, T val) {
@@ -507,7 +527,7 @@ void test_inttable(int32_t *keys, uint16_t num_entries, const char *desc) {
     MAYBE_BREAK;
     int32_t key = keys[i & mask];
     upb_value v;
-    bool ok = upb_inttable_lookup32(&table.table_.table_, key, &v);
+    bool ok = upb_inttable_lookup(&table.table_.table_, key, &v);
     x += (uintptr_t)ok;
   }
   double total = get_usertime() - before;
@@ -521,7 +541,7 @@ void test_inttable(int32_t *keys, uint16_t num_entries, const char *desc) {
     MAYBE_BREAK;
     int32_t key = keys[rand_order[i & mask]];
     upb_value v;
-    bool ok = upb_inttable_lookup32(&table.table_.table_, key, &v);
+    bool ok = upb_inttable_lookup(&table.table_.table_, key, &v);
     x += (uintptr_t)ok;
   }
   total = get_usertime() - before;
@@ -599,12 +619,13 @@ int32_t *get_contiguous_keys(int32_t num) {
 }
 
 void test_delete() {
+  upb::Arena arena;
   upb_inttable t;
-  upb_inttable_init(&t, UPB_CTYPE_BOOL);
-  upb_inttable_insert(&t, 0, upb_value_bool(true));
-  upb_inttable_insert(&t, 2, upb_value_bool(true));
-  upb_inttable_insert(&t, 4, upb_value_bool(true));
-  upb_inttable_compact(&t);
+  upb_inttable_init(&t, arena.ptr());
+  upb_inttable_insert(&t, 0, upb_value_bool(true), arena.ptr());
+  upb_inttable_insert(&t, 2, upb_value_bool(true), arena.ptr());
+  upb_inttable_insert(&t, 4, upb_value_bool(true), arena.ptr());
+  upb_inttable_compact(&t, arena.ptr());
   upb_inttable_remove(&t, 0, NULL);
   upb_inttable_remove(&t, 2, NULL);
   upb_inttable_remove(&t, 4, NULL);
@@ -614,17 +635,15 @@ void test_delete() {
        upb_inttable_next(&iter)) {
     ASSERT(false);
   }
-
-  upb_inttable_uninit(&t);
 }
 
 void test_init() {
   for (int i = 0; i < 2048; i++) {
     /* Tests that the size calculations in init() (lg2 size for target load)
      * work for all expected sizes. */
+    upb::Arena arena;
     upb_strtable t;
-    upb_strtable_init2(&t, UPB_CTYPE_BOOL, i, &upb_alloc_global);
-    upb_strtable_uninit(&t);
+    upb_strtable_init(&t, i, arena.ptr());
   }
 }
 
diff --git a/third_party/upb/tests/test_util.h b/third_party/upb/tests/test_util.h
deleted file mode 100644 (file)
index 418a9d8..0000000
+++ /dev/null
@@ -1,230 +0,0 @@
-/*
-** Common functionality for tests.
-**/
-
-#ifndef UPB_TEST_UTIL_H_
-#define UPB_TEST_UTIL_H_
-
-#include <stdio.h>
-#include <math.h>
-#include "tests/upb_test.h"
-#include "upb/sink.h"
-
-#include "upb/port_def.inc"
-
-#ifdef __cplusplus
-
-upb_bufhandle global_handle;
-
-/* A convenience class for parser tests.  Provides some useful features:
- *
- *   - can support multiple calls to parse, to test the parser's handling
- *     of buffer seams.
- *
- *   - can output verbose output about each parse call when requested, for
- *     ease of debugging.
- *
- *   - can pass NULL for skipped regions of the input if requested.
- *
- *   - allocates and passes a separate buffer for each parsed region, to
- *     ensure that the parser is not erroneously overreading its buffer.
- */
-class VerboseParserEnvironment {
- public:
-  /* Pass verbose=true to print detailed diagnostics to stderr. */
-  VerboseParserEnvironment(bool verbose) : verbose_(verbose) {}
-
-  void Reset(const char *buf, size_t len, bool may_skip, bool expect_error) {
-    buf_ = buf;
-    len_ = len;
-    ofs_ = 0;
-    expect_error_ = expect_error;
-    end_ok_set_ = false;
-    skip_until_ = may_skip ? 0 : -1;
-    skipped_with_null_ = false;
-  }
-
-  /* The user should call a series of:
-   *
-   * Reset(buf, len, may_skip);
-   * Start()
-   * ParseBuffer(X);
-   * ParseBuffer(Y);
-   * // Repeat ParseBuffer as desired, but last call should pass -1.
-   * ParseBuffer(-1);
-   * End();
-   */
-
-
-  bool Start() {
-    if (verbose_) {
-      fprintf(stderr, "Calling start()\n");
-    }
-    return sink_.Start(len_, &subc_);
-  }
-
-  bool End() {
-    if (verbose_) {
-      fprintf(stderr, "Calling end()\n");
-    }
-    end_ok_ = sink_.End();
-    end_ok_set_ = true;
-
-    return end_ok_;
-  }
-
-  bool CheckConsistency() {
-    /* If we called end (which we should only do when previous bytes are fully
-     * accepted), then end() should return true iff there were no errors. */
-    if (end_ok_set_ && end_ok_ != status_.ok()) {
-      fprintf(stderr, "End() status and saw_error didn't match.\n");
-      return false;
-    }
-
-    if (expect_error_ && status_.ok()) {
-      fprintf(stderr, "Expected error but saw none.\n");
-      return false;
-    }
-
-    if (!status_.ok()) {
-      if (expect_error_ && verbose_) {
-        fprintf(stderr, "Encountered error, as expected: %s",
-                status_.error_message());
-      } else if (!expect_error_) {
-        fprintf(stderr, "Encountered unexpected error: %s",
-                status_.error_message());
-        return false;
-      }
-    }
-
-    return true;
-  }
-
-  bool ParseBuffer(int bytes) {
-    if (bytes < 0) {
-      bytes = (int)(len_ - ofs_);
-    }
-
-    ASSERT((size_t)bytes <= (len_ - ofs_));
-
-    /* Copy buffer into a separate, temporary buffer.
-     * This is necessary to verify that the parser is not erroneously
-     * reading outside the specified bounds. */
-    char *buf2 = NULL;
-
-    if ((int)(ofs_ + bytes) <= skip_until_) {
-      skipped_with_null_ = true;
-    } else {
-      buf2 = (char*)malloc(bytes);
-      UPB_ASSERT(buf2);
-      memcpy(buf2, buf_ + ofs_, bytes);
-    }
-
-    if (buf2 == NULL && bytes == 0) {
-      /* Decoders dont' support buf=NULL, bytes=0. */
-      return true;
-    }
-
-    if (verbose_) {
-      fprintf(stderr, "Calling parse(%u) for bytes %u-%u of the input\n",
-              (unsigned)bytes, (unsigned)ofs_, (unsigned)(ofs_ + bytes));
-    }
-
-    int parsed = (int)sink_.PutBuffer(subc_, buf2, bytes, &global_handle);
-    free(buf2);
-
-    if (verbose_) {
-      if (parsed == bytes) {
-        fprintf(stderr,
-                "parse(%u) = %u, complete byte count indicates success\n",
-                (unsigned)bytes, (unsigned)bytes);
-      } else if (parsed > bytes) {
-        fprintf(stderr,
-                "parse(%u) = %u, long byte count indicates success and skip "
-                "of the next %u bytes\n",
-                (unsigned)bytes, (unsigned)parsed, (unsigned)(parsed - bytes));
-      } else {
-        fprintf(stderr,
-                "parse(%u) = %u, short byte count indicates failure; "
-                "last %u bytes were not consumed\n",
-                (unsigned)bytes, (unsigned)parsed, (unsigned)(bytes - parsed));
-      }
-    }
-
-    if (!status_.ok()) {
-      return false;
-    }
-
-    if (parsed > bytes && skip_until_ >= 0) {
-      skip_until_ = (int)(ofs_ + parsed);
-    }
-
-    ofs_ += UPB_MIN(parsed, bytes);
-
-    return true;
-  }
-
-  void ResetBytesSink(upb::BytesSink sink) {
-    sink_ = sink;
-  }
-
-  size_t ofs() { return ofs_; }
-
-  bool SkippedWithNull() { return skipped_with_null_; }
-
-  upb::Arena* arena() { return &arena_; }
-  upb::Status* status() { return &status_; }
-
- private:
-  upb::Arena arena_;
-  upb::Status status_;
-  upb::BytesSink sink_;
-  const char* buf_;
-  size_t len_;
-  bool verbose_;
-  size_t ofs_;
-  void *subc_;
-  bool expect_error_;
-  bool end_ok_;
-  bool end_ok_set_;
-
-  /* When our parse call returns a value greater than the number of bytes
-   * we passed in, the decoder is indicating to us that the next N bytes
-   * in the stream are not needed and can be skipped.  The user is allowed
-   * to pass a NULL buffer for those N bytes.
-   *
-   * skip_until_ is initially set to 0 if we should do this NULL-buffer
-   * skipping or -1 if we should not.  If we are open to doing NULL-buffer
-   * skipping and we get an opportunity to do it, we set skip_until to the
-   * stream offset where we can skip until.  The user can then test whether
-   * this happened by testing SkippedWithNull(). */
-  int skip_until_;
-  bool skipped_with_null_;
-};
-
-#endif  /* __cplusplus */
-
-UPB_INLINE char *upb_readfile(const char *filename, size_t *len) {
-  long size;
-  char *buf;
-  FILE *f = fopen(filename, "rb");
-  if(!f) return NULL;
-  if(fseek(f, 0, SEEK_END) != 0) goto error;
-  size = ftell(f);
-  if(size < 0) goto error;
-  if(fseek(f, 0, SEEK_SET) != 0) goto error;
-  buf = (char*)malloc(size + 1);
-  if(size && fread(buf, size, 1, f) != 1) goto error;
-  fclose(f);
-  if (len) *len = size;
-  buf[size] = '\0';
-  return buf;
-
-error:
-  fclose(f);
-  return NULL;
-}
-
-#include "upb/port_undef.inc"
-
-#endif /* UPB_TEST_UTIL_H_ */
index 97dd716..3bd345e 100644 (file)
@@ -1,3 +1,27 @@
+// Copyright (c) 2009-2021, Google LLC
+// All rights reserved.
+//
+// Redistribution and use in source and binary forms, with or without
+// modification, are permitted provided that the following conditions are met:
+//     * Redistributions of source code must retain the above copyright
+//       notice, this list of conditions and the following disclaimer.
+//     * Redistributions in binary form must reproduce the above copyright
+//       notice, this list of conditions and the following disclaimer in the
+//       documentation and/or other materials provided with the distribution.
+//     * Neither the name of Google LLC nor the
+//       names of its contributors may be used to endorse or promote products
+//       derived from this software without specific prior written permission.
+//
+// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+// WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+// DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+// DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+// (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+// LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+// ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+// SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 
 #include <stdlib.h>
 #ifdef USE_GOOGLE
index d4b0688..0afb3f4 100644 (file)
@@ -1,3 +1,29 @@
+/*
+ * Copyright (c) 2009-2021, Google LLC
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ *     * Redistributions of source code must retain the above copyright
+ *       notice, this list of conditions and the following disclaimer.
+ *     * Redistributions in binary form must reproduce the above copyright
+ *       notice, this list of conditions and the following disclaimer in the
+ *       documentation and/or other materials provided with the distribution.
+ *     * Neither the name of Google LLC nor the
+ *       names of its contributors may be used to endorse or promote products
+ *       derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+ * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ * DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+ * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+ * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+ * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
 
 #ifndef UPB_TEST_H_
 #define UPB_TEST_H_
diff --git a/third_party/upb/third_party/wyhash/BUILD b/third_party/upb/third_party/wyhash/BUILD
deleted file mode 100644 (file)
index f3f3a6f..0000000
+++ /dev/null
@@ -1,17 +0,0 @@
-licenses(["unencumbered"])
-
-exports_files(["LICENSE"])
-
-cc_library(
-    name = "wyhash",
-    hdrs = ["wyhash.h"],
-    visibility = ["//:__pkg__"],
-)
-
-filegroup(
-    name = "cmake_files",
-    srcs = glob([
-        "**/*",
-    ]),
-    visibility = ["//cmake:__pkg__"],
-)
diff --git a/third_party/upb/third_party/wyhash/LICENSE b/third_party/upb/third_party/wyhash/LICENSE
deleted file mode 100644 (file)
index 471f09f..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-This is free and unencumbered software released into the public domain.
-
-Anyone is free to copy, modify, publish, use, compile, sell, or
-distribute this software, either in source code form or as a compiled
-binary, for any purpose, commercial or non-commercial, and by any
-means.
-
-In jurisdictions that recognize copyright laws, the author or authors
-of this software dedicate any and all copyright interest in the
-software to the public domain. We make this dedication for the benefit
-of the public at large and to the detriment of our heirs and
-successors. We intend this dedication to be an overt act of
-relinquishment in perpetuity of all present and future rights to this
-software under copyright law.
-
-THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-IN NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY CLAIM, DAMAGES OR
-OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
-ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
-OTHER DEALINGS IN THE SOFTWARE.
-
-For more information, please refer to <http://unlicense.org/>
-
diff --git a/third_party/upb/third_party/wyhash/wyhash.h b/third_party/upb/third_party/wyhash/wyhash.h
deleted file mode 100644 (file)
index 5658f02..0000000
+++ /dev/null
@@ -1,145 +0,0 @@
-/* Copyright 2020 çŽ‹ä¸€ Wang Yi <godspeed_china@yeah.net>
-   This is free and unencumbered software released into the public domain. http://unlicense.org/
-   See github.com/wangyi-fudan/wyhash/ LICENSE
- */
-#ifndef wyhash_final_version
-#define wyhash_final_version
-//defines that change behavior
-#ifndef WYHASH_CONDOM
-#define WYHASH_CONDOM 1 //0: read 8 bytes before and after boundaries, dangerous but fastest. 1: normal valid behavior 2: extra protection against entropy loss (probability=2^-63), aka. "blind multiplication"
-#endif
-#define WYHASH_32BIT_MUM 0     //faster on 32 bit system
-//includes
-#include <stdint.h>
-#include <string.h>
-#if defined(_MSC_VER) && defined(_M_X64)
-  #include <intrin.h>
-  #pragma intrinsic(_umul128)
-#endif
-#if defined(__GNUC__) || defined(__INTEL_COMPILER) || defined(__clang__)
-  #define _likely_(x)  __builtin_expect(x,1)
-  #define _unlikely_(x)        __builtin_expect(x,0)
-#else
-  #define _likely_(x) (x)
-  #define _unlikely_(x) (x)
-#endif
-//mum function
-static inline uint64_t _wyrot(uint64_t x) { return (x>>32)|(x<<32); }
-static inline void _wymum(uint64_t *A, uint64_t *B){
-#if(WYHASH_32BIT_MUM)
-  uint64_t hh=(*A>>32)*(*B>>32), hl=(*A>>32)*(unsigned)*B, lh=(unsigned)*A*(*B>>32), ll=(uint64_t)(unsigned)*A*(unsigned)*B;
-  #if(WYHASH_CONDOM>1)
-  *A^=_wyrot(hl)^hh; *B^=_wyrot(lh)^ll;
-  #else
-  *A=_wyrot(hl)^hh; *B=_wyrot(lh)^ll;
-  #endif
-#elif defined(__SIZEOF_INT128__)
-  __uint128_t r=*A; r*=*B; 
-  #if(WYHASH_CONDOM>1)
-  *A^=(uint64_t)r; *B^=(uint64_t)(r>>64);
-  #else
-  *A=(uint64_t)r; *B=(uint64_t)(r>>64);
-  #endif
-#elif defined(_MSC_VER) && defined(_M_X64)
-  #if(WYHASH_CONDOM>1)
-  uint64_t  a,  b;
-  a=_umul128(*A,*B,&b);
-  *A^=a;  *B^=b;
-  #else
-  *A=_umul128(*A,*B,B);
-  #endif
-#else
-  uint64_t ha=*A>>32, hb=*B>>32, la=(uint32_t)*A, lb=(uint32_t)*B, hi, lo;
-  uint64_t rh=ha*hb, rm0=ha*lb, rm1=hb*la, rl=la*lb, t=rl+(rm0<<32), c=t<rl;
-  lo=t+(rm1<<32); c+=lo<t; hi=rh+(rm0>>32)+(rm1>>32)+c;
-  #if(WYHASH_CONDOM>1)
-  *A^=lo;  *B^=hi;
-  #else
-  *A=lo;  *B=hi;
-  #endif
-#endif
-}
-static inline uint64_t _wymix(uint64_t A, uint64_t B){ _wymum(&A,&B); return A^B; }
-//read functions
-#ifndef WYHASH_LITTLE_ENDIAN
-  #if defined(_WIN32) || defined(__LITTLE_ENDIAN__) || (defined(__BYTE_ORDER__) && __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__)
-    #define WYHASH_LITTLE_ENDIAN 1
-  #elif defined(__BIG_ENDIAN__) || (defined(__BYTE_ORDER__) && __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__)
-    #define WYHASH_LITTLE_ENDIAN 0
-  #endif
-#endif
-#if (WYHASH_LITTLE_ENDIAN)
-static inline uint64_t _wyr8(const uint8_t *p) { uint64_t v; memcpy(&v, p, 8); return v;}
-static inline uint64_t _wyr4(const uint8_t *p) { unsigned v; memcpy(&v, p, 4); return v;}
-#elif defined(__GNUC__) || defined(__INTEL_COMPILER) || defined(__clang__)
-static inline uint64_t _wyr8(const uint8_t *p) { uint64_t v; memcpy(&v, p, 8); return __builtin_bswap64(v);}
-static inline uint64_t _wyr4(const uint8_t *p) { unsigned v; memcpy(&v, p, 4); return __builtin_bswap32(v);}
-#elif defined(_MSC_VER)
-static inline uint64_t _wyr8(const uint8_t *p) { uint64_t v; memcpy(&v, p, 8); return _byteswap_uint64(v);}
-static inline uint64_t _wyr4(const uint8_t *p) { unsigned v; memcpy(&v, p, 4); return _byteswap_ulong(v);}
-#endif
-static inline uint64_t _wyr3(const uint8_t *p, unsigned k) { return (((uint64_t)p[0])<<16)|(((uint64_t)p[k>>1])<<8)|p[k-1];}
-//wyhash function
-static inline uint64_t _wyfinish16(const uint8_t *p, uint64_t len, uint64_t seed, const uint64_t *secret, uint64_t i){
-#if(WYHASH_CONDOM>0)
-  uint64_t a, b;
-  if(_likely_(i<=8)){
-    if(_likely_(i>=4)){ a=_wyr4(p); b=_wyr4(p+i-4); }
-    else if (_likely_(i)){ a=_wyr3(p,i); b=0; }
-    else a=b=0;
-  } 
-  else{ a=_wyr8(p); b=_wyr8(p+i-8); }
-  return _wymix(secret[1]^len,_wymix(a^secret[1], b^seed));
-#else
-  #define oneshot_shift ((i<8)*((8-i)<<3))
-  return _wymix(secret[1]^len,_wymix((_wyr8(p)<<oneshot_shift)^secret[1],(_wyr8(p+i-8)>>oneshot_shift)^seed));
-#endif
-}
-
-static inline uint64_t _wyfinish(const uint8_t *p, uint64_t len, uint64_t seed, const uint64_t *secret, uint64_t i){
-  if(_likely_(i<=16)) return _wyfinish16(p,len,seed,secret,i);
-  return _wyfinish(p+16,len,_wymix(_wyr8(p)^secret[1],_wyr8(p+8)^seed),secret,i-16);
-}
-
-static inline uint64_t wyhash(const void *key, uint64_t len, uint64_t seed, const uint64_t *secret){
-  const uint8_t *p=(const uint8_t *)key;
-  uint64_t i=len; seed^=*secret;
-  if(_unlikely_(i>64)){
-    uint64_t see1=seed;
-    do{
-      seed=_wymix(_wyr8(p)^secret[1],_wyr8(p+8)^seed)^_wymix(_wyr8(p+16)^secret[2],_wyr8(p+24)^seed);
-      see1=_wymix(_wyr8(p+32)^secret[3],_wyr8(p+40)^see1)^_wymix(_wyr8(p+48)^secret[4],_wyr8(p+56)^see1);
-      p+=64; i-=64;
-    }while(i>64);
-    seed^=see1;
-  }
-  return _wyfinish(p,len,seed,secret,i);
-}
-//utility functions
-const uint64_t _wyp[5] = {0xa0761d6478bd642full, 0xe7037ed1a0b428dbull, 0x8ebc6af09c88c6e3ull, 0x589965cc75374cc3ull, 0x1d8e4e27c47d124full};
-static inline uint64_t wyhash64(uint64_t A, uint64_t B){  A^=_wyp[0]; B^=_wyp[1];  _wymum(&A,&B);  return _wymix(A^_wyp[0],B^_wyp[1]);}
-static inline uint64_t wyrand(uint64_t *seed){  *seed+=_wyp[0]; return _wymix(*seed,*seed^_wyp[1]);}
-static inline double wy2u01(uint64_t r){ const double _wynorm=1.0/(1ull<<52); return (r>>12)*_wynorm;}
-static inline double wy2gau(uint64_t r){ const double _wynorm=1.0/(1ull<<20); return ((r&0x1fffff)+((r>>21)&0x1fffff)+((r>>42)&0x1fffff))*_wynorm-3.0;}
-static inline uint64_t wy2u0k(uint64_t r, uint64_t k){ _wymum(&r,&k); return k; }
-
-static inline void make_secret(uint64_t seed, uint64_t *secret){
-  uint8_t c[] = {15, 23, 27, 29, 30, 39, 43, 45, 46, 51, 53, 54, 57, 58, 60, 71, 75, 77, 78, 83, 85, 86, 89, 90, 92, 99, 101, 102, 105, 106, 108, 113, 114, 116, 120, 135, 139, 141, 142, 147, 149, 150, 153, 154, 156, 163, 165, 166, 169, 170, 172, 177, 178, 180, 184, 195, 197, 198, 201, 202, 204, 209, 210, 212, 216, 225, 226, 228, 232, 240 };
-  for(size_t i=0;i<5;i++){
-    uint8_t ok;
-    do{
-      ok=1; secret[i]=0;
-      for(size_t j=0;j<64;j+=8) secret[i]|=((uint64_t)c[wyrand(&seed)%sizeof(c)])<<j;
-      if(secret[i]%2==0){ ok=0; continue; }
-      for(size_t j=0;j<i;j++)
-#if defined(__GNUC__) || defined(__INTEL_COMPILER) || defined(__clang__)
-        if(__builtin_popcountll(secret[j]^secret[i])!=32){ ok=0; break; }
-#elif defined(_MSC_VER) && defined(_M_X64)
-        if(_mm_popcnt_u64(secret[j]^secret[i])!=32){ ok=0; break; }
-#endif
-       if(!ok)continue;
-       for(uint64_t j=3;j<0x100000000ull;j+=2) if(secret[i]%j==0){ ok=0; break; }
-    }while(!ok);
-  }
-}
-#endif
index b244eff..103b11c 100755 (executable)
@@ -1,4 +1,29 @@
 #!/usr/bin/python
+#
+# Copyright (c) 2009-2021, Google LLC
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions are met:
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in the
+#       documentation and/or other materials provided with the distribution.
+#     * Neither the name of Google LLC nor the
+#       names of its contributors may be used to endorse or promote products
+#       derived from this software without specific prior written permission.
+#
+# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+# DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+# DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+# (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+# ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 
 import sys
 import re
@@ -22,15 +47,14 @@ class Amalgamator:
     self.output_c.write(open("upb/port_def.inc").read())
 
     self.output_h.write("/* Amalgamated source file */\n")
-    self.output_h.write('#include <stdint.h>')
     self.output_h.write(open("upb/port_def.inc").read())
 
   def add_include_path(self, path):
       self.include_paths.append(path)
 
   def finish(self):
-    self.output_c.write(open("upb/port_undef.inc").read())
-    self.output_h.write(open("upb/port_undef.inc").read())
+    self._add_header("upb/port_undef.inc")
+    self.add_src("upb/port_undef.inc")
 
   def _process_file(self, infile_name, outfile):
     file = None
@@ -44,7 +68,17 @@ class Amalgamator:
     if not file:
         raise RuntimeError("Couldn't open file " + infile_name)
 
-    for line in file:
+    lines = file.readlines()
+
+    has_copyright = lines[1].startswith(" * Copyright")
+    if has_copyright:
+      while not lines[0].startswith(" */"):
+        lines.pop(0)
+      lines.pop(0)
+
+    lines.insert(0, "\n/** " + infile_name + " " + ("*" * 60) +"/");
+
+    for line in lines:
       if not self._process_include(line, outfile):
         outfile.write(line)
 
index 3b794a8..546202a 100644 (file)
@@ -1,3 +1,28 @@
+# Copyright (c) 2009-2021, Google LLC
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions are met:
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in the
+#       documentation and/or other materials provided with the distribution.
+#     * Neither the name of Google LLC nor the
+#       names of its contributors may be used to endorse or promote products
+#       derived from this software without specific prior written permission.
+#
+# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+# DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+# DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+# (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+# ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
 load(
     "//bazel:build_defs.bzl",
     "UPB_DEFAULT_COPTS",
index a1e8720..54923e4 100644 (file)
@@ -1,3 +1,29 @@
+/*
+ * Copyright (c) 2009-2021, Google LLC
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ *     * Redistributions of source code must retain the above copyright
+ *       notice, this list of conditions and the following disclaimer.
+ *     * Redistributions in binary form must reproduce the above copyright
+ *       notice, this list of conditions and the following disclaimer in the
+ *       documentation and/or other materials provided with the distribution.
+ *     * Neither the name of Google LLC nor the
+ *       names of its contributors may be used to endorse or promote products
+ *       derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+ * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ * DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+ * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+ * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+ * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
 
 #include <float.h>
 #include <math.h>
index d6ac301..fa20cf7 100644 (file)
@@ -1,3 +1,28 @@
+# Copyright (c) 2009-2021, Google LLC
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions are met:
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in the
+#       documentation and/or other materials provided with the distribution.
+#     * Neither the name of Google LLC nor the
+#       names of its contributors may be used to endorse or promote products
+#       derived from this software without specific prior written permission.
+#
+# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+# DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+# DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+# (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+# ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
 load("@bazel_skylib//lib:paths.bzl", "paths")
 
 # Generic support code #########################################################
index c0c5bb9..6210e39 100644 (file)
@@ -1,6 +1,33 @@
 /*
-** lupb_msg -- Message/Array/Map objects in Lua/C that wrap upb/msg.h
-*/
+ * Copyright (c) 2009-2021, Google LLC
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ *     * Redistributions of source code must retain the above copyright
+ *       notice, this list of conditions and the following disclaimer.
+ *     * Redistributions in binary form must reproduce the above copyright
+ *       notice, this list of conditions and the following disclaimer in the
+ *       documentation and/or other materials provided with the distribution.
+ *     * Neither the name of Google LLC nor the
+ *       names of its contributors may be used to endorse or promote products
+ *       derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+ * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ * DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+ * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+ * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+ * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+/*
+ * lupb_msg -- Message/Array/Map objects in Lua/C that wrap upb/msg.h
+ */
 
 #include "upb/msg.h"
 
@@ -922,7 +949,7 @@ static int lupb_decode(lua_State *L) {
   buf = upb_arena_malloc(arena, len);
   memcpy(buf, pb, len);
 
-  ok = _upb_decode(buf, len, msg, layout, arena, UPB_DECODE_ALIAS);
+  ok = _upb_decode(buf, len, msg, layout, NULL, UPB_DECODE_ALIAS, arena);
 
   if (!ok) {
     lua_pushstring(L, "Error decoding protobuf.");
index c247c03..c9d98bb 100644 (file)
@@ -1,24 +1,51 @@
 /*
-** require("lua") -- A Lua extension for upb.
-**
-** Exposes only the core library
-** (sub-libraries are exposed in other extensions).
-**
-** 64-bit woes: Lua can only represent numbers of type lua_Number (which is
-** double unless the user specifically overrides this).  Doubles can represent
-** the entire range of 64-bit integers, but lose precision once the integers are
-** greater than 2^53.
-**
-** Lua 5.3 is adding support for integers, which will allow for 64-bit
-** integers (which can be interpreted as signed or unsigned).
-**
-** LuaJIT supports 64-bit signed and unsigned boxed representations
-** through its "cdata" mechanism, but this is not portable to regular Lua.
-**
-** Hopefully Lua 5.3 will come soon enough that we can either use Lua 5.3
-** integer support or LuaJIT 64-bit cdata for users that need the entire
-** domain of [u]int64 values.
-*/
+ * Copyright (c) 2009-2021, Google LLC
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ *     * Redistributions of source code must retain the above copyright
+ *       notice, this list of conditions and the following disclaimer.
+ *     * Redistributions in binary form must reproduce the above copyright
+ *       notice, this list of conditions and the following disclaimer in the
+ *       documentation and/or other materials provided with the distribution.
+ *     * Neither the name of Google LLC nor the
+ *       names of its contributors may be used to endorse or promote products
+ *       derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+ * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ * DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+ * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+ * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+ * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+/*
+ * require("lua") -- A Lua extension for upb.
+ *
+ * Exposes only the core library
+ * (sub-libraries are exposed in other extensions).
+ *
+ * 64-bit woes: Lua can only represent numbers of type lua_Number (which is
+ * double unless the user specifically overrides this).  Doubles can represent
+ * the entire range of 64-bit integers, but lose precision once the integers are
+ * greater than 2^53.
+ *
+ * Lua 5.3 is adding support for integers, which will allow for 64-bit
+ * integers (which can be interpreted as signed or unsigned).
+ *
+ * LuaJIT supports 64-bit signed and unsigned boxed representations
+ * through its "cdata" mechanism, but this is not portable to regular Lua.
+ *
+ * Hopefully Lua 5.3 will come soon enough that we can either use Lua 5.3
+ * integer support or LuaJIT 64-bit cdata for users that need the entire
+ * domain of [u]int64 values.
+ */
 
 #include "upb/bindings/lua/upb.h"
 
index 455752f..5976dc7 100644 (file)
@@ -1,6 +1,33 @@
 /*
-** Shared definitions for upb Lua modules.
-*/
+ * Copyright (c) 2009-2021, Google LLC
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ *     * Redistributions of source code must retain the above copyright
+ *       notice, this list of conditions and the following disclaimer.
+ *     * Redistributions in binary form must reproduce the above copyright
+ *       notice, this list of conditions and the following disclaimer in the
+ *       documentation and/or other materials provided with the distribution.
+ *     * Neither the name of Google LLC nor the
+ *       names of its contributors may be used to endorse or promote products
+ *       derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+ * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ * DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+ * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+ * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+ * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+/*
+ * Shared definitions for upb Lua modules.
+ */
 
 #ifndef UPB_LUA_UPB_H_
 #define UPB_LUA_UPB_H_
index ad6184a..e2d4cd1 100644 (file)
@@ -1,3 +1,31 @@
+--[[--------------------------------------------------------------------------
+
+  Copyright (c) 2009-2021, Google LLC
+  All rights reserved.
+
+  Redistribution and use in source and binary forms, with or without
+  modification, are permitted provided that the following conditions are met:
+      * Redistributions of source code must retain the above copyright
+        notice, this list of conditions and the following disclaimer.
+      * Redistributions in binary form must reproduce the above copyright
+        notice, this list of conditions and the following disclaimer in the
+        documentation and/or other materials provided with the distribution.
+      * Neither the name of Google LLC nor the
+        names of its contributors may be used to endorse or promote products
+        derived from this software without specific prior written permission.
+
+  THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+  ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+  WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+  DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+  DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+  (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+  LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+  ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+  (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+  SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+--]]--------------------------------------------------------------------------
 
 local upb = require("lupb")
 
index c3988f6..e2bb0dd 100644 (file)
@@ -1,3 +1,27 @@
+// Copyright (c) 2009-2021, Google LLC
+// All rights reserved.
+//
+// Redistribution and use in source and binary forms, with or without
+// modification, are permitted provided that the following conditions are met:
+//     * Redistributions of source code must retain the above copyright
+//       notice, this list of conditions and the following disclaimer.
+//     * Redistributions in binary form must reproduce the above copyright
+//       notice, this list of conditions and the following disclaimer in the
+//       documentation and/or other materials provided with the distribution.
+//     * Neither the name of Google LLC nor the
+//       names of its contributors may be used to endorse or promote products
+//       derived from this software without specific prior written permission.
+//
+// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+// WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+// DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+// DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+// (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+// LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+// ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+// SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 
 #include "absl/strings/string_view.h"
 #include "absl/strings/substitute.h"
@@ -19,7 +43,7 @@ class LuaGenerator : public protoc::CodeGenerator {
 };
 
 static std::string StripExtension(absl::string_view fname) {
-  size_t lastdot = fname.find_last_of(".");
+  size_t lastdot = fname.find_last_of('.');
   if (lastdot == std::string::npos) {
     return std::string(fname);
   }
index a5f0666..2739be8 100644 (file)
@@ -1,12 +1,38 @@
+/*
+ * Copyright (c) 2009-2021, Google LLC
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ *     * Redistributions of source code must retain the above copyright
+ *       notice, this list of conditions and the following disclaimer.
+ *     * Redistributions in binary form must reproduce the above copyright
+ *       notice, this list of conditions and the following disclaimer in the
+ *       documentation and/or other materials provided with the distribution.
+ *     * Neither the name of Google LLC nor the
+ *       names of its contributors may be used to endorse or promote products
+ *       derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+ * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ * DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+ * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+ * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+ * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
 
 #include "upb/decode.h"
 
 #include <setjmp.h>
 #include <string.h>
 
-#include "upb/decode.int.h"
+#include "upb/decode_internal.h"
 #include "upb/upb.h"
-#include "upb/upb.int.h"
+#include "upb/upb_internal.h"
 
 /* Must be last. */
 #include "upb/port_def.inc"
@@ -150,11 +176,23 @@ static const char *decode_msg(upb_decstate *d, const char *ptr, upb_msg *msg,
 
 UPB_NORETURN static void decode_err(upb_decstate *d) { UPB_LONGJMP(d->err, 1); }
 
+// We don't want to mark this NORETURN, see comment in .h.
+// Unfortunately this code to suppress the warning doesn't appear to be working.
+#ifdef __clang__
+#pragma clang diagnostic push
+#pragma clang diagnostic ignored "-Wunknown-warning-option"
+#pragma clang diagnostic ignored "-Wsuggest-attribute"
+#endif
+
 const char *fastdecode_err(upb_decstate *d) {
   longjmp(d->err, 1);
   return NULL;
 }
 
+#ifdef __clang__
+#pragma clang diagnostic pop
+#endif
+
 const uint8_t upb_utf8_offsets[] = {
     1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
     1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
@@ -261,24 +299,43 @@ static void decode_munge(int type, wireval *val) {
 }
 
 static const upb_msglayout_field *upb_find_field(const upb_msglayout *l,
-                                                 uint32_t field_number) {
+                                                 uint32_t field_number,
+                                                 int *last_field_index) {
   static upb_msglayout_field none = {0, 0, 0, 0, 0, 0};
 
-  /* Lots of optimization opportunities here. */
-  int i;
   if (l == NULL) return &none;
-  for (i = 0; i < l->field_count; i++) {
-    if (l->fields[i].number == field_number) {
-      return &l->fields[i];
+
+  size_t idx = ((size_t)field_number) - 1;  // 0 wraps to SIZE_MAX
+  if (idx < l->dense_below) {
+    goto found;
+  }
+
+  /* Resume scanning from last_field_index since fields are usually in order. */
+  int last = *last_field_index;
+  for (idx = last; idx < l->field_count; idx++) {
+    if (l->fields[idx].number == field_number) {
+      goto found;
+    }
+  }
+
+  for (idx = 0; idx < last; idx++) {
+    if (l->fields[idx].number == field_number) {
+      goto found;
     }
   }
 
   return &none; /* Unknown field. */
+
+ found:
+  UPB_ASSERT(l->fields[idx].number == field_number);
+  *last_field_index = idx;
+  return &l->fields[idx];
 }
 
-static upb_msg *decode_newsubmsg(upb_decstate *d, const upb_msglayout *layout,
+static upb_msg *decode_newsubmsg(upb_decstate *d,
+                                 upb_msglayout const *const *submsgs,
                                  const upb_msglayout_field *field) {
-  const upb_msglayout *subl = layout->submsgs[field->submsg_index];
+  const upb_msglayout *subl = submsgs[field->submsg_index];
   return _upb_msg_new_inl(subl, &d->arena);
 }
 
@@ -308,9 +365,10 @@ static const char *decode_readstr(upb_decstate *d, const char *ptr, int size,
 
 UPB_FORCEINLINE
 static const char *decode_tosubmsg(upb_decstate *d, const char *ptr,
-                                   upb_msg *submsg, const upb_msglayout *layout,
+                                   upb_msg *submsg, 
+                                   upb_msglayout const *const *submsgs,
                                    const upb_msglayout_field *field, int size) {
-  const upb_msglayout *subl = layout->submsgs[field->submsg_index];
+  const upb_msglayout *subl = submsgs[field->submsg_index];
   int saved_delta = decode_pushlimit(d, ptr, size);
   if (--d->depth < 0) decode_err(d);
   if (!decode_isdone(d, &ptr)) {
@@ -339,15 +397,17 @@ static const char *decode_group(upb_decstate *d, const char *ptr,
 
 UPB_FORCEINLINE
 static const char *decode_togroup(upb_decstate *d, const char *ptr,
-                                  upb_msg *submsg, const upb_msglayout *layout,
+                                  upb_msg *submsg,
+                                  upb_msglayout const *const *submsgs,
                                   const upb_msglayout_field *field) {
-  const upb_msglayout *subl = layout->submsgs[field->submsg_index];
+  const upb_msglayout *subl = submsgs[field->submsg_index];
   return decode_group(d, ptr, submsg, subl, field->number);
 }
 
 static const char *decode_toarray(upb_decstate *d, const char *ptr,
-                                  upb_msg *msg, const upb_msglayout *layout,
-                                  const upb_msglayout_field *field, wireval val,
+                                  upb_msg *msg,
+                                  upb_msglayout const *const *submsgs,
+                                  const upb_msglayout_field *field, wireval *val,
                                   int op) {
   upb_array **arrp = UPB_PTR_AT(msg, field->offset, void);
   upb_array *arr = *arrp;
@@ -369,27 +429,27 @@ static const char *decode_toarray(upb_decstate *d, const char *ptr,
       /* Append scalar value. */
       mem = UPB_PTR_AT(_upb_array_ptr(arr), arr->len << op, void);
       arr->len++;
-      memcpy(mem, &val, 1 << op);
+      memcpy(mem, val, 1 << op);
       return ptr;
     case OP_STRING:
-      decode_verifyutf8(d, ptr, val.size);
+      decode_verifyutf8(d, ptr, val->size);
       /* Fallthrough. */
     case OP_BYTES: {
       /* Append bytes. */
       upb_strview *str = (upb_strview*)_upb_array_ptr(arr) + arr->len;
       arr->len++;
-      return decode_readstr(d, ptr, val.size, str);
+      return decode_readstr(d, ptr, val->size, str);
     }
     case OP_SUBMSG: {
       /* Append submessage / group. */
-      upb_msg *submsg = decode_newsubmsg(d, layout, field);
+      upb_msg *submsg = decode_newsubmsg(d, submsgs, field);
       *UPB_PTR_AT(_upb_array_ptr(arr), arr->len * sizeof(void *), upb_msg *) =
           submsg;
       arr->len++;
       if (UPB_UNLIKELY(field->descriptortype == UPB_DTYPE_GROUP)) {
-        return decode_togroup(d, ptr, submsg, layout, field);
+        return decode_togroup(d, ptr, submsg, submsgs, field);
       } else {
-        return decode_tosubmsg(d, ptr, submsg, layout, field, val.size);
+        return decode_tosubmsg(d, ptr, submsg, submsgs, field, val->size);
       }
     }
     case OP_FIXPCK_LG2(2):
@@ -397,15 +457,15 @@ static const char *decode_toarray(upb_decstate *d, const char *ptr,
       /* Fixed packed. */
       int lg2 = op - OP_FIXPCK_LG2(0);
       int mask = (1 << lg2) - 1;
-      size_t count = val.size >> lg2;
-      if ((val.size & mask) != 0) {
+      size_t count = val->size >> lg2;
+      if ((val->size & mask) != 0) {
         decode_err(d); /* Length isn't a round multiple of elem size. */
       }
       decode_reserve(d, arr, count);
       mem = UPB_PTR_AT(_upb_array_ptr(arr), arr->len << lg2, void);
       arr->len += count;
-      memcpy(mem, ptr, val.size);  /* XXX: ptr boundary. */
-      return ptr + val.size;
+      memcpy(mem, ptr, val->size);  /* XXX: ptr boundary. */
+      return ptr + val->size;
     }
     case OP_VARPCK_LG2(0):
     case OP_VARPCK_LG2(2):
@@ -413,7 +473,7 @@ static const char *decode_toarray(upb_decstate *d, const char *ptr,
       /* Varint packed. */
       int lg2 = op - OP_VARPCK_LG2(0);
       int scale = 1 << lg2;
-      int saved_limit = decode_pushlimit(d, ptr, val.size);
+      int saved_limit = decode_pushlimit(d, ptr, val->size);
       char *out = UPB_PTR_AT(_upb_array_ptr(arr), arr->len << lg2, void);
       while (!decode_isdone(d, &ptr)) {
         wireval elem;
@@ -435,16 +495,15 @@ static const char *decode_toarray(upb_decstate *d, const char *ptr,
 }
 
 static const char *decode_tomap(upb_decstate *d, const char *ptr, upb_msg *msg,
-                                const upb_msglayout *layout,
-                                const upb_msglayout_field *field, wireval val) {
+                                upb_msglayout const *const *submsgs,
+                                const upb_msglayout_field *field, wireval *val) {
   upb_map **map_p = UPB_PTR_AT(msg, field->offset, upb_map *);
   upb_map *map = *map_p;
   upb_map_entry ent;
-  const upb_msglayout *entry = layout->submsgs[field->submsg_index];
+  const upb_msglayout *entry = submsgs[field->submsg_index];
 
   if (!map) {
     /* Lazily create map. */
-    const upb_msglayout *entry = layout->submsgs[field->submsg_index];
     const upb_msglayout_field *key_field = &entry->fields[0];
     const upb_msglayout_field *val_field = &entry->fields[1];
     char key_size = desctype_to_mapsize[key_field->descriptortype];
@@ -464,28 +523,28 @@ static const char *decode_tomap(upb_decstate *d, const char *ptr, upb_msg *msg,
     ent.v.val = upb_value_ptr(_upb_msg_new(entry->submsgs[0], &d->arena));
   }
 
-  ptr = decode_tosubmsg(d, ptr, &ent.k, layout, field, val.size);
+  ptr = decode_tosubmsg(d, ptr, &ent.k, submsgs, field, val->size);
   _upb_map_set(map, &ent.k, map->key_size, &ent.v, map->val_size, &d->arena);
   return ptr;
 }
 
 static const char *decode_tomsg(upb_decstate *d, const char *ptr, upb_msg *msg,
-                                const upb_msglayout *layout,
-                                const upb_msglayout_field *field, wireval val,
+                                upb_msglayout const *const *submsgs,
+                                const upb_msglayout_field *field, wireval *val,
                                 int op) {
   void *mem = UPB_PTR_AT(msg, field->offset, void);
   int type = field->descriptortype;
 
   /* Set presence if necessary. */
-  if (field->presence < 0) {
+  if (field->presence > 0) {
+    _upb_sethas_field(msg, field);
+  } else if (field->presence < 0) {
     /* Oneof case */
     uint32_t *oneof_case = _upb_oneofcase_field(msg, field);
     if (op == OP_SUBMSG && *oneof_case != field->number) {
       memset(mem, 0, sizeof(void*));
     }
     *oneof_case = field->number;
-  } else if (field->presence > 0) {
-    _upb_sethas_field(msg, field);
   }
 
   /* Store into message. */
@@ -494,29 +553,29 @@ static const char *decode_tomsg(upb_decstate *d, const char *ptr, upb_msg *msg,
       upb_msg **submsgp = mem;
       upb_msg *submsg = *submsgp;
       if (!submsg) {
-        submsg = decode_newsubmsg(d, layout, field);
+        submsg = decode_newsubmsg(d, submsgs, field);
         *submsgp = submsg;
       }
       if (UPB_UNLIKELY(type == UPB_DTYPE_GROUP)) {
-        ptr = decode_togroup(d, ptr, submsg, layout, field);
+        ptr = decode_togroup(d, ptr, submsg, submsgs, field);
       } else {
-        ptr = decode_tosubmsg(d, ptr, submsg, layout, field, val.size);
+        ptr = decode_tosubmsg(d, ptr, submsg, submsgs, field, val->size);
       }
       break;
     }
     case OP_STRING:
-      decode_verifyutf8(d, ptr, val.size);
+      decode_verifyutf8(d, ptr, val->size);
       /* Fallthrough. */
     case OP_BYTES:
-      return decode_readstr(d, ptr, val.size, mem);
+      return decode_readstr(d, ptr, val->size, mem);
     case OP_SCALAR_LG2(3):
-      memcpy(mem, &val, 8);
+      memcpy(mem, val, 8);
       break;
     case OP_SCALAR_LG2(2):
-      memcpy(mem, &val, 4);
+      memcpy(mem, val, 4);
       break;
     case OP_SCALAR_LG2(0):
-      memcpy(mem, &val, 1);
+      memcpy(mem, val, 1);
       break;
     default:
       UPB_UNREACHABLE();
@@ -542,6 +601,7 @@ static bool decode_tryfastdispatch(upb_decstate *d, const char **ptr,
 UPB_NOINLINE
 static const char *decode_msg(upb_decstate *d, const char *ptr, upb_msg *msg,
                               const upb_msglayout *layout) {
+  int last_field_index = 0;
   while (true) {
     uint32_t tag;
     const upb_msglayout_field *field;
@@ -556,7 +616,7 @@ static const char *decode_msg(upb_decstate *d, const char *ptr, upb_msg *msg,
     field_number = tag >> 3;
     wire_type = tag & 7;
 
-    field = upb_find_field(layout, field_number);
+    field = upb_find_field(layout, field_number, &last_field_index);
 
     switch (wire_type) {
       case UPB_WIRE_TYPE_VARINT:
@@ -581,7 +641,7 @@ static const char *decode_msg(upb_decstate *d, const char *ptr, upb_msg *msg,
       case UPB_WIRE_TYPE_DELIMITED: {
         int ndx = field->descriptortype;
         uint64_t size;
-        if (_upb_isrepeated(field)) ndx += 18;
+        if (_upb_getmode(field) == _UPB_MODE_ARRAY) ndx += 18;
         ptr = decode_varint64(d, ptr, &size);
         if (size >= INT32_MAX ||
             ptr - d->end + (int32_t)size > d->limit) {
@@ -605,17 +665,18 @@ static const char *decode_msg(upb_decstate *d, const char *ptr, upb_msg *msg,
 
     if (op >= 0) {
       /* Parse, using op for dispatch. */
-      switch (field->label) {
-        case UPB_LABEL_REPEATED:
-        case _UPB_LABEL_PACKED:
-          ptr = decode_toarray(d, ptr, msg, layout, field, val, op);
+      switch (_upb_getmode(field)) {
+        case _UPB_MODE_ARRAY:
+          ptr = decode_toarray(d, ptr, msg, layout->submsgs, field, &val, op);
           break;
-        case _UPB_LABEL_MAP:
-          ptr = decode_tomap(d, ptr, msg, layout, field, val);
+        case _UPB_MODE_MAP:
+          ptr = decode_tomap(d, ptr, msg, layout->submsgs, field, &val);
           break;
-        default:
-          ptr = decode_tomsg(d, ptr, msg, layout, field, val, op);
+        case _UPB_MODE_SCALAR:
+          ptr = decode_tomsg(d, ptr, msg, layout->submsgs, field, &val, op);
           break;
+        default:
+          UPB_UNREACHABLE();
       }
     } else {
     unknown:
@@ -652,8 +713,17 @@ const char *fastdecode_generic(struct upb_decstate *d, const char *ptr,
   return decode_msg(d, ptr, msg, decode_totablep(table));
 }
 
+static bool decode_top(struct upb_decstate *d, const char *buf, void *msg,
+                       const upb_msglayout *l) {
+  if (!decode_tryfastdispatch(d, &buf, msg, l)) {
+    decode_msg(d, buf, msg, l);
+  }
+  return d->end_group == DECODE_NOGROUP;
+}
+
 bool _upb_decode(const char *buf, size_t size, void *msg,
-                 const upb_msglayout *l, upb_arena *arena, int options) {
+                 const upb_msglayout *l, const upb_extreg *extreg, int options,
+                 upb_arena *arena) {
   bool ok;
   upb_decstate state;
   unsigned depth = (unsigned)options >> 16;
@@ -679,19 +749,18 @@ bool _upb_decode(const char *buf, size_t size, void *msg,
   state.end_group = DECODE_NOGROUP;
   state.arena.head = arena->head;
   state.arena.last_size = arena->last_size;
+  state.arena.cleanup_metadata = arena->cleanup_metadata;
   state.arena.parent = arena;
 
   if (UPB_UNLIKELY(UPB_SETJMP(state.err))) {
     ok = false;
   } else {
-    if (!decode_tryfastdispatch(&state, &buf, msg, l)) {
-      decode_msg(&state, buf, msg, l);
-    }
-    ok = state.end_group == DECODE_NOGROUP;
+    ok = decode_top(&state, buf, msg, l);
   }
 
   arena->head.ptr = state.arena.head.ptr;
   arena->head.end = state.arena.head.end;
+  arena->cleanup_metadata = state.arena.cleanup_metadata;
   return ok;
 }
 
index eff4b8b..2400891 100644 (file)
@@ -1,6 +1,33 @@
 /*
-** upb_decode: parsing into a upb_msg using a upb_msglayout.
-*/
+ * Copyright (c) 2009-2021, Google LLC
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ *     * Redistributions of source code must retain the above copyright
+ *       notice, this list of conditions and the following disclaimer.
+ *     * Redistributions in binary form must reproduce the above copyright
+ *       notice, this list of conditions and the following disclaimer in the
+ *       documentation and/or other materials provided with the distribution.
+ *     * Neither the name of Google LLC nor the
+ *       names of its contributors may be used to endorse or promote products
+ *       derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+ * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ * DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+ * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+ * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+ * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+/*
+ * upb_decode: parsing into a upb_msg using a upb_msglayout.
+ */
 
 #ifndef UPB_DECODE_H_
 #define UPB_DECODE_H_
@@ -23,12 +50,13 @@ enum {
 #define UPB_DECODE_MAXDEPTH(depth) ((depth) << 16)
 
 bool _upb_decode(const char *buf, size_t size, upb_msg *msg,
-                 const upb_msglayout *l, upb_arena *arena, int options);
+                 const upb_msglayout *l, const upb_extreg *extreg, int options,
+                 upb_arena *arena);
 
 UPB_INLINE
 bool upb_decode(const char *buf, size_t size, upb_msg *msg,
                 const upb_msglayout *l, upb_arena *arena) {
-  return _upb_decode(buf, size, msg, l, arena, 0);
+  return _upb_decode(buf, size, msg, l, NULL, 0, arena);
 }
 
 #ifdef __cplusplus
index f628e6d..437b647 100644 (file)
@@ -1,8 +1,35 @@
-// Fast decoder: ~3x the speed of decode.c, but x86-64 specific.
+/*
+ * Copyright (c) 2009-2021, Google LLC
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ *     * Redistributions of source code must retain the above copyright
+ *       notice, this list of conditions and the following disclaimer.
+ *     * Redistributions in binary form must reproduce the above copyright
+ *       notice, this list of conditions and the following disclaimer in the
+ *       documentation and/or other materials provided with the distribution.
+ *     * Neither the name of Google LLC nor the
+ *       names of its contributors may be used to endorse or promote products
+ *       derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+ * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ * DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+ * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+ * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+ * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+// Fast decoder: ~3x the speed of decode.c, but requires x86-64/ARM64.
 // Also the table size grows by 2x.
 //
-// Could potentially be ported to ARM64 or other 64-bit archs that pass at
-// least six arguments in registers.
+// Could potentially be ported to other 64-bit archs that pass at least six
+// arguments in registers and have 8 unused high bits in pointers.
 //
 // The overall design is to create specialized functions for every possible
 // field type (eg. oneof boolean field with a 1 byte tag) and then dispatch
@@ -10,7 +37,7 @@
 
 #include "upb/decode_fast.h"
 
-#include "upb/decode.int.h"
+#include "upb/decode_internal.h"
 
 /* Must be last. */
 #include "upb/port_def.inc"
 
 #define UPB_PARSE_ARGS d, ptr, msg, table, hasbits, data
 
-#define RETURN_GENERIC(m)  \
-  /* fprintf(stderr, m); */ \
+#define RETURN_GENERIC(m)                                                      \
+  /* Uncomment either of these for debugging purposes. */                      \
+  /* fprintf(stderr, m); */                                                    \
+  /*__builtin_trap(); */                                                       \
   return fastdecode_generic(d, ptr, msg, table, hasbits, 0);
 
 typedef enum {
@@ -37,21 +66,18 @@ typedef enum {
 } upb_card;
 
 UPB_NOINLINE
-static const char *fastdecode_isdonefallback(upb_decstate *d, const char *ptr,
-                                             upb_msg *msg, intptr_t table,
-                                             uint64_t hasbits, int overrun) {
+static const char *fastdecode_isdonefallback(UPB_PARSE_PARAMS) {
+  int overrun = data;
   ptr = decode_isdonefallback_inl(d, ptr, overrun);
   if (ptr == NULL) {
     return fastdecode_err(d);
   }
-  uint16_t tag = fastdecode_loadtag(ptr);
-  return fastdecode_tagdispatch(d, ptr, msg, table, hasbits, tag);
+  data = fastdecode_loadtag(ptr);
+  UPB_MUSTTAIL return fastdecode_tagdispatch(UPB_PARSE_ARGS);
 }
 
 UPB_FORCEINLINE
-static const char *fastdecode_dispatch(upb_decstate *d, const char *ptr,
-                                       upb_msg *msg, intptr_t table,
-                                       uint64_t hasbits) {
+static const char *fastdecode_dispatch(UPB_PARSE_PARAMS) {
   if (UPB_UNLIKELY(ptr >= d->limit_ptr)) {
     int overrun = ptr - d->end;
     if (UPB_LIKELY(overrun == d->limit)) {
@@ -59,21 +85,22 @@ static const char *fastdecode_dispatch(upb_decstate *d, const char *ptr,
       *(uint32_t*)msg |= hasbits;  // Sync hasbits.
       return ptr;
     } else {
-      return fastdecode_isdonefallback(d, ptr, msg, table, hasbits, overrun);
+      data = overrun;
+      UPB_MUSTTAIL return fastdecode_isdonefallback(UPB_PARSE_ARGS);
     }
   }
 
   // Read two bytes of tag data (for a one-byte tag, the high byte is junk).
-  uint16_t tag = fastdecode_loadtag(ptr);
-  return fastdecode_tagdispatch(d, ptr, msg, table, hasbits, tag);
+  data = fastdecode_loadtag(ptr);
+  UPB_MUSTTAIL return fastdecode_tagdispatch(UPB_PARSE_ARGS);
 }
 
 UPB_FORCEINLINE
-static bool fastdecode_checktag(uint64_t data, int tagbytes) {
+static bool fastdecode_checktag(uint16_t data, int tagbytes) {
   if (tagbytes == 1) {
     return (data & 0xff) == 0;
   } else {
-    return (data & 0xffff) == 0;
+    return data == 0;
   }
 }
 
@@ -297,6 +324,14 @@ static bool fastdecode_flippacked(uint64_t *data, int tagbytes) {
   return fastdecode_checktag(*data, tagbytes);
 }
 
+#define FASTDECODE_CHECKPACKED(tagbytes, card, func)                           \
+  if (UPB_UNLIKELY(!fastdecode_checktag(data, tagbytes))) {                    \
+    if (card == CARD_r && fastdecode_flippacked(&data, tagbytes)) {            \
+      UPB_MUSTTAIL return func(UPB_PARSE_ARGS);                                \
+    }                                                                          \
+    RETURN_GENERIC("packed check tag mismatch\n");                             \
+  }
+
 /* varint fields **************************************************************/
 
 UPB_FORCEINLINE
@@ -339,57 +374,50 @@ done:
   return ptr;
 }
 
-UPB_FORCEINLINE
-static const char *fastdecode_unpackedvarint(UPB_PARSE_PARAMS, int tagbytes,
-                                             int valbytes, upb_card card,
-                                             bool zigzag,
-                                             _upb_field_parser *packed) {
-  uint64_t val;
-  void *dst;
-  fastdecode_arr farr;
-
-  if (UPB_UNLIKELY(!fastdecode_checktag(data, tagbytes))) {
-    if (card == CARD_r && fastdecode_flippacked(&data, tagbytes)) {
-      return packed(UPB_PARSE_ARGS);
-    }
-    RETURN_GENERIC("varint field tag mismatch\n");
-  }
-
-  dst =
-      fastdecode_getfield(d, ptr, msg, &data, &hasbits, &farr, valbytes, card);
-  if (card == CARD_r) {
-    if (UPB_UNLIKELY(!dst)) {
-      RETURN_GENERIC("need array resize\n");
-    }
-  }
-
-again:
-  if (card == CARD_r) {
-    dst = fastdecode_resizearr(d, dst, &farr, valbytes);
-  }
-
-  ptr += tagbytes;
-  ptr = fastdecode_varint64(ptr, &val);
-  if (ptr == NULL) return fastdecode_err(d);
-  val = fastdecode_munge(val, valbytes, zigzag);
-  memcpy(dst, &val, valbytes);
-
-  if (card == CARD_r) {
-    fastdecode_nextret ret =
-        fastdecode_nextrepeated(d, dst, &ptr, &farr, data, tagbytes, valbytes);
-    switch (ret.next) {
-      case FD_NEXT_SAMEFIELD:
-        dst = ret.dst;
-        goto again;
-      case FD_NEXT_OTHERFIELD:
-        return fastdecode_tagdispatch(d, ptr, msg, table, hasbits, ret.tag);
-      case FD_NEXT_ATLIMIT:
-        return ptr;
-    }
-  }
-
-  return fastdecode_dispatch(d, ptr, msg, table, hasbits);
-}
+#define FASTDECODE_UNPACKEDVARINT(d, ptr, msg, table, hasbits, data, tagbytes, \
+                                  valbytes, card, zigzag, packed)              \
+  uint64_t val;                                                                \
+  void *dst;                                                                   \
+  fastdecode_arr farr;                                                         \
+                                                                               \
+  FASTDECODE_CHECKPACKED(tagbytes, card, packed);                              \
+                                                                               \
+  dst = fastdecode_getfield(d, ptr, msg, &data, &hasbits, &farr, valbytes,     \
+                            card);                                             \
+  if (card == CARD_r) {                                                        \
+    if (UPB_UNLIKELY(!dst)) {                                                  \
+      RETURN_GENERIC("need array resize\n");                                   \
+    }                                                                          \
+  }                                                                            \
+                                                                               \
+  again:                                                                       \
+  if (card == CARD_r) {                                                        \
+    dst = fastdecode_resizearr(d, dst, &farr, valbytes);                       \
+  }                                                                            \
+                                                                               \
+  ptr += tagbytes;                                                             \
+  ptr = fastdecode_varint64(ptr, &val);                                        \
+  if (ptr == NULL)                                                             \
+    return fastdecode_err(d);                                                  \
+  val = fastdecode_munge(val, valbytes, zigzag);                               \
+  memcpy(dst, &val, valbytes);                                                 \
+                                                                               \
+  if (card == CARD_r) {                                                        \
+    fastdecode_nextret ret = fastdecode_nextrepeated(                          \
+        d, dst, &ptr, &farr, data, tagbytes, valbytes);                        \
+    switch (ret.next) {                                                        \
+    case FD_NEXT_SAMEFIELD:                                                    \
+      dst = ret.dst;                                                           \
+      goto again;                                                              \
+    case FD_NEXT_OTHERFIELD:                                                   \
+      data = ret.tag;                                                          \
+      UPB_MUSTTAIL return fastdecode_tagdispatch(UPB_PARSE_ARGS);              \
+    case FD_NEXT_ATLIMIT:                                                      \
+      return ptr;                                                              \
+    }                                                                          \
+  }                                                                            \
+                                                                               \
+  UPB_MUSTTAIL return fastdecode_dispatch(UPB_PARSE_ARGS);
 
 typedef struct {
   uint8_t valbytes;
@@ -418,49 +446,36 @@ static const char *fastdecode_topackedvarint(upb_decstate *d, const char *ptr,
   return ptr;
 }
 
-UPB_FORCEINLINE
-static const char *fastdecode_packedvarint(UPB_PARSE_PARAMS, int tagbytes,
-                                           int valbytes, bool zigzag,
-                                           _upb_field_parser *unpacked) {
-  fastdecode_varintdata ctx = {valbytes, zigzag};
-
-  if (UPB_UNLIKELY(!fastdecode_checktag(data, tagbytes))) {
-    if (fastdecode_flippacked(&data, tagbytes)) {
-      return unpacked(UPB_PARSE_ARGS);
-    } else {
-      RETURN_GENERIC("varint field tag mismatch\n");
-    }
-  }
-
-  ctx.dst = fastdecode_getfield(d, ptr, msg, &data, &hasbits, &ctx.farr,
-                                valbytes, CARD_r);
-  if (UPB_UNLIKELY(!ctx.dst)) {
-    RETURN_GENERIC("need array resize\n");
-  }
-
-  ptr += tagbytes;
-  ptr = fastdecode_delimited(d, ptr, &fastdecode_topackedvarint, &ctx);
-
-  if (UPB_UNLIKELY(ptr == NULL)) {
-    return fastdecode_err(d);
-  }
-
-  return fastdecode_dispatch(d, ptr, msg, table, hasbits);
-}
-
-UPB_FORCEINLINE
-static const char *fastdecode_varint(UPB_PARSE_PARAMS, int tagbytes,
-                                     int valbytes, upb_card card, bool zigzag,
-                                     _upb_field_parser *unpacked,
-                                     _upb_field_parser *packed) {
-  if (card == CARD_p) {
-    return fastdecode_packedvarint(UPB_PARSE_ARGS, tagbytes, valbytes, zigzag,
-                                   unpacked);
-  } else {
-    return fastdecode_unpackedvarint(UPB_PARSE_ARGS, tagbytes, valbytes, card,
-                                     zigzag, packed);
+#define FASTDECODE_PACKEDVARINT(d, ptr, msg, table, hasbits, data, tagbytes,   \
+                                valbytes, zigzag, unpacked)                    \
+  fastdecode_varintdata ctx = {valbytes, zigzag};                              \
+                                                                               \
+  FASTDECODE_CHECKPACKED(tagbytes, CARD_r, unpacked);                          \
+                                                                               \
+  ctx.dst = fastdecode_getfield(d, ptr, msg, &data, &hasbits, &ctx.farr,       \
+                                valbytes, CARD_r);                             \
+  if (UPB_UNLIKELY(!ctx.dst)) {                                                \
+    RETURN_GENERIC("need array resize\n");                                     \
+  }                                                                            \
+                                                                               \
+  ptr += tagbytes;                                                             \
+  ptr = fastdecode_delimited(d, ptr, &fastdecode_topackedvarint, &ctx);        \
+                                                                               \
+  if (UPB_UNLIKELY(ptr == NULL)) {                                             \
+    return fastdecode_err(d);                                                  \
+  }                                                                            \
+                                                                               \
+  UPB_MUSTTAIL return fastdecode_dispatch(d, ptr, msg, table, hasbits, 0);
+
+#define FASTDECODE_VARINT(d, ptr, msg, table, hasbits, data, tagbytes,     \
+                          valbytes, card, zigzag, unpacked, packed)        \
+  if (card == CARD_p) {                                                    \
+    FASTDECODE_PACKEDVARINT(d, ptr, msg, table, hasbits, data, tagbytes,   \
+                            valbytes, zigzag, unpacked);                   \
+  } else {                                                                 \
+    FASTDECODE_UNPACKEDVARINT(d, ptr, msg, table, hasbits, data, tagbytes, \
+                              valbytes, card, zigzag, packed);             \
   }
-}
 
 #define z_ZZ true
 #define b_ZZ false
@@ -472,10 +487,10 @@ static const char *fastdecode_varint(UPB_PARSE_PARAMS, int tagbytes,
 #define F(card, type, valbytes, tagbytes)                                      \
   UPB_NOINLINE                                                                 \
   const char *upb_p##card##type##valbytes##_##tagbytes##bt(UPB_PARSE_PARAMS) { \
-    return fastdecode_varint(UPB_PARSE_ARGS, tagbytes, valbytes, CARD_##card,  \
-                             type##_ZZ,                                        \
-                             &upb_pr##type##valbytes##_##tagbytes##bt,         \
-                             &upb_pp##type##valbytes##_##tagbytes##bt);        \
+    FASTDECODE_VARINT(d, ptr, msg, table, hasbits, data, tagbytes, valbytes,   \
+                      CARD_##card, type##_ZZ,                                  \
+                      upb_pr##type##valbytes##_##tagbytes##bt,                 \
+                      upb_pp##type##valbytes##_##tagbytes##bt);                \
   }
 
 #define TYPES(card, tagbytes) \
@@ -503,126 +518,110 @@ TAGBYTES(p)
 #undef F
 #undef TYPES
 #undef TAGBYTES
+#undef FASTDECODE_UNPACKEDVARINT
+#undef FASTDECODE_PACKEDVARINT
+#undef FASTDECODE_VARINT
 
 
 /* fixed fields ***************************************************************/
 
-UPB_FORCEINLINE
-static const char *fastdecode_unpackedfixed(UPB_PARSE_PARAMS, int tagbytes,
-                                            int valbytes, upb_card card,
-                                            _upb_field_parser *packed) {
-  void *dst;
-  fastdecode_arr farr;
-
-  if (UPB_UNLIKELY(!fastdecode_checktag(data, tagbytes))) {
-    if (card == CARD_r && fastdecode_flippacked(&data, tagbytes)) {
-      return packed(UPB_PARSE_ARGS);
-    }
-    RETURN_GENERIC("fixed field tag mismatch\n");
+#define FASTDECODE_UNPACKEDFIXED(d, ptr, msg, table, hasbits, data, tagbytes,  \
+                                 valbytes, card, packed)                       \
+  void *dst;                                                                   \
+  fastdecode_arr farr;                                                         \
+                                                                               \
+  FASTDECODE_CHECKPACKED(tagbytes, card, packed)                               \
+                                                                               \
+  dst = fastdecode_getfield(d, ptr, msg, &data, &hasbits, &farr, valbytes,     \
+                            card);                                             \
+  if (card == CARD_r) {                                                        \
+    if (UPB_UNLIKELY(!dst)) {                                                  \
+      RETURN_GENERIC("couldn't allocate array in arena\n");                    \
+    }                                                                          \
+  }                                                                            \
+                                                                               \
+  again:                                                                       \
+  if (card == CARD_r) {                                                        \
+    dst = fastdecode_resizearr(d, dst, &farr, valbytes);                       \
+  }                                                                            \
+                                                                               \
+  ptr += tagbytes;                                                             \
+  memcpy(dst, ptr, valbytes);                                                  \
+  ptr += valbytes;                                                             \
+                                                                               \
+  if (card == CARD_r) {                                                        \
+    fastdecode_nextret ret = fastdecode_nextrepeated(                          \
+        d, dst, &ptr, &farr, data, tagbytes, valbytes);                        \
+    switch (ret.next) {                                                        \
+    case FD_NEXT_SAMEFIELD:                                                    \
+      dst = ret.dst;                                                           \
+      goto again;                                                              \
+    case FD_NEXT_OTHERFIELD:                                                   \
+      data = ret.tag;                                                          \
+      UPB_MUSTTAIL return fastdecode_tagdispatch(UPB_PARSE_ARGS);              \
+    case FD_NEXT_ATLIMIT:                                                      \
+      return ptr;                                                              \
+    }                                                                          \
+  }                                                                            \
+                                                                               \
+  UPB_MUSTTAIL return fastdecode_dispatch(UPB_PARSE_ARGS);
+
+#define FASTDECODE_PACKEDFIXED(d, ptr, msg, table, hasbits, data, tagbytes, \
+                               valbytes, unpacked)                          \
+  FASTDECODE_CHECKPACKED(tagbytes, CARD_r, unpacked)                        \
+                                                                            \
+  ptr += tagbytes;                                                          \
+  int size = (uint8_t)ptr[0];                                               \
+  ptr++;                                                                    \
+  if (size & 0x80) {                                                        \
+    ptr = fastdecode_longsize(ptr, &size);                                  \
+  }                                                                         \
+                                                                            \
+  if (UPB_UNLIKELY(fastdecode_boundscheck(ptr, size, d->limit_ptr) ||       \
+                   (size % valbytes) != 0)) {                               \
+    return fastdecode_err(d);                                               \
+  }                                                                         \
+                                                                            \
+  upb_array **arr_p = fastdecode_fieldmem(msg, data);                       \
+  upb_array *arr = *arr_p;                                                  \
+  uint8_t elem_size_lg2 = __builtin_ctz(valbytes);                          \
+  int elems = size / valbytes;                                              \
+                                                                            \
+  if (UPB_LIKELY(!arr)) {                                                   \
+    *arr_p = arr = _upb_array_new(&d->arena, elems, elem_size_lg2);         \
+    if (!arr) {                                                             \
+      return fastdecode_err(d);                                             \
+    }                                                                       \
+  } else {                                                                  \
+    _upb_array_resize(arr, elems, &d->arena);                               \
+  }                                                                         \
+                                                                            \
+  char *dst = _upb_array_ptr(arr);                                          \
+  memcpy(dst, ptr, size);                                                   \
+  arr->len = elems;                                                         \
+                                                                            \
+  ptr += size;                                                              \
+  UPB_MUSTTAIL return fastdecode_dispatch(UPB_PARSE_ARGS);
+
+#define FASTDECODE_FIXED(d, ptr, msg, table, hasbits, data, tagbytes,     \
+                         valbytes, card, unpacked, packed)                \
+  if (card == CARD_p) {                                                   \
+    FASTDECODE_PACKEDFIXED(d, ptr, msg, table, hasbits, data, tagbytes,   \
+                           valbytes, unpacked);                           \
+  } else {                                                                \
+    FASTDECODE_UNPACKEDFIXED(d, ptr, msg, table, hasbits, data, tagbytes, \
+                             valbytes, card, packed);                     \
   }
 
-  dst =
-      fastdecode_getfield(d, ptr, msg, &data, &hasbits, &farr, valbytes, card);
-  if (card == CARD_r) {
-    if (UPB_UNLIKELY(!dst)) {
-      RETURN_GENERIC("couldn't allocate array in arena\n");
-    }
-  }
-
-
-again:
-  if (card == CARD_r) {
-    dst = fastdecode_resizearr(d, dst, &farr, valbytes);
-  }
-
-  ptr += tagbytes;
-  memcpy(dst, ptr, valbytes);
-  ptr += valbytes;
-
-  if (card == CARD_r) {
-    fastdecode_nextret ret =
-        fastdecode_nextrepeated(d, dst, &ptr, &farr, data, tagbytes, valbytes);
-    switch (ret.next) {
-      case FD_NEXT_SAMEFIELD:
-        dst = ret.dst;
-        goto again;
-      case FD_NEXT_OTHERFIELD:
-        return fastdecode_tagdispatch(d, ptr, msg, table, hasbits, ret.tag);
-      case FD_NEXT_ATLIMIT:
-        return ptr;
-    }
-  }
-
-  return fastdecode_dispatch(d, ptr, msg, table, hasbits);
-}
-
-UPB_FORCEINLINE
-static const char *fastdecode_packedfixed(UPB_PARSE_PARAMS, int tagbytes,
-                                          int valbytes,
-                                          _upb_field_parser *unpacked) {
-  if (UPB_UNLIKELY(!fastdecode_checktag(data, tagbytes))) {
-    if (fastdecode_flippacked(&data, tagbytes)) {
-      return unpacked(UPB_PARSE_ARGS);
-    } else {
-      RETURN_GENERIC("varint field tag mismatch\n");
-    }
-  }
-
-  ptr += tagbytes;
-  int size = (uint8_t)ptr[0];
-  ptr++;
-  if (size & 0x80) {
-    ptr = fastdecode_longsize(ptr, &size);
-  }
-
-  if (UPB_UNLIKELY(fastdecode_boundscheck(ptr, size, d->limit_ptr)) ||
-      (size % valbytes) != 0) {
-    return fastdecode_err(d);
-  }
-
-  upb_array **arr_p = fastdecode_fieldmem(msg, data);
-  upb_array *arr = *arr_p;
-  uint8_t elem_size_lg2 = __builtin_ctz(valbytes);
-  int elems = size / valbytes;
-
-  if (UPB_LIKELY(!arr)) {
-    *arr_p = arr = _upb_array_new(&d->arena, elems, elem_size_lg2);
-    if (!arr) {
-      return fastdecode_err(d);
-    }
-  } else {
-    _upb_array_resize(arr, elems, &d->arena);
-  }
-
-  char *dst = _upb_array_ptr(arr);
-  memcpy(dst, ptr, size);
-  arr->len = elems;
-
-  return fastdecode_dispatch(d, ptr + size, msg, table, hasbits);
-}
-
-UPB_FORCEINLINE
-static const char *fastdecode_fixed(UPB_PARSE_PARAMS, int tagbytes,
-                                    int valbytes, upb_card card,
-                                    _upb_field_parser *unpacked,
-                                    _upb_field_parser *packed) {
-  if (card == CARD_p) {
-    return fastdecode_packedfixed(UPB_PARSE_ARGS, tagbytes, valbytes, unpacked);
-  } else {
-    return fastdecode_unpackedfixed(UPB_PARSE_ARGS, tagbytes, valbytes, card,
-                                    packed);
-  }
-}
-
 /* Generate all combinations:
  * {s,o,r,p} x {f4,f8} x {1bt,2bt} */
 
-#define F(card, valbytes, tagbytes)                                          \
-  UPB_NOINLINE                                                               \
-  const char *upb_p##card##f##valbytes##_##tagbytes##bt(UPB_PARSE_PARAMS) {  \
-    return fastdecode_fixed(UPB_PARSE_ARGS, tagbytes, valbytes, CARD_##card, \
-                            &upb_ppf##valbytes##_##tagbytes##bt,             \
-                            &upb_prf##valbytes##_##tagbytes##bt);            \
+#define F(card, valbytes, tagbytes)                                         \
+  UPB_NOINLINE                                                              \
+  const char *upb_p##card##f##valbytes##_##tagbytes##bt(UPB_PARSE_PARAMS) { \
+    FASTDECODE_FIXED(d, ptr, msg, table, hasbits, data, tagbytes, valbytes, \
+                     CARD_##card, upb_ppf##valbytes##_##tagbytes##bt,       \
+                     upb_prf##valbytes##_##tagbytes##bt);                   \
   }
 
 #define TYPES(card, tagbytes) \
@@ -641,6 +640,8 @@ TAGBYTES(p)
 #undef F
 #undef TYPES
 #undef TAGBYTES
+#undef FASTDECODE_UNPACKEDFIXED
+#undef FASTDECODE_PACKEDFIXED
 
 /* string fields **************************************************************/
 
@@ -652,56 +653,54 @@ typedef const char *fastdecode_copystr_func(struct upb_decstate *d,
 UPB_NOINLINE
 static const char *fastdecode_verifyutf8(upb_decstate *d, const char *ptr,
                                          upb_msg *msg, intptr_t table,
-                                         uint64_t hasbits, upb_strview *dst) {
+                                         uint64_t hasbits, uint64_t data) {
+  upb_strview *dst = (upb_strview*)data;
   if (!decode_verifyutf8_inl(dst->data, dst->size)) {
     return fastdecode_err(d);
   }
-  return fastdecode_dispatch(d, ptr, msg, table, hasbits);
+  UPB_MUSTTAIL return fastdecode_dispatch(UPB_PARSE_ARGS);
 }
 
-UPB_FORCEINLINE
-static const char *fastdecode_longstring(struct upb_decstate *d,
-                                         const char *ptr, upb_msg *msg,
-                                         intptr_t table, uint64_t hasbits,
-                                         upb_strview *dst,
-                                         bool validate_utf8) {
-  int size = (uint8_t)ptr[0];  // Could plumb through hasbits.
-  ptr++;
-  if (size & 0x80) {
-    ptr = fastdecode_longsize(ptr, &size);
+#define FASTDECODE_LONGSTRING(d, ptr, msg, table, hasbits, dst, validate_utf8) \
+  int size = (uint8_t)ptr[0]; /* Could plumb through hasbits. */               \
+  ptr++;                                                                       \
+  if (size & 0x80) {                                                           \
+    ptr = fastdecode_longsize(ptr, &size);                                     \
+  }                                                                            \
+                                                                               \
+  if (UPB_UNLIKELY(fastdecode_boundscheck(ptr, size, d->limit_ptr))) {         \
+    dst->size = 0;                                                             \
+    return fastdecode_err(d);                                                  \
+  }                                                                            \
+                                                                               \
+  if (d->alias) {                                                              \
+    dst->data = ptr;                                                           \
+    dst->size = size;                                                          \
+  } else {                                                                     \
+    char *data = upb_arena_malloc(&d->arena, size);                            \
+    if (!data) {                                                               \
+      return fastdecode_err(d);                                                \
+    }                                                                          \
+    memcpy(data, ptr, size);                                                   \
+    dst->data = data;                                                          \
+    dst->size = size;                                                          \
+  }                                                                            \
+                                                                               \
+  ptr += size;                                                                 \
+  if (validate_utf8) {                                                         \
+    data = (uint64_t)dst;                                                      \
+    UPB_MUSTTAIL return fastdecode_verifyutf8(UPB_PARSE_ARGS);                 \
+  } else {                                                                     \
+    UPB_MUSTTAIL return fastdecode_dispatch(UPB_PARSE_ARGS);                   \
   }
 
-  if (UPB_UNLIKELY(fastdecode_boundscheck(ptr, size, d->limit_ptr))) {
-    dst->size = 0;
-    return fastdecode_err(d);
-  }
-
-  if (d->alias) {
-    dst->data = ptr;
-    dst->size = size;
-  } else {
-    char *data = upb_arena_malloc(&d->arena, size);
-    if (!data) {
-      return fastdecode_err(d);
-    }
-    memcpy(data, ptr, size);
-    dst->data = data;
-    dst->size = size;
-  }
-
-  if (validate_utf8) {
-    return fastdecode_verifyutf8(d, ptr + size, msg, table, hasbits, dst);
-  } else {
-    return fastdecode_dispatch(d, ptr + size, msg, table, hasbits);
-  }
-}
-
 UPB_NOINLINE
 static const char *fastdecode_longstring_utf8(struct upb_decstate *d,
-                                         const char *ptr, upb_msg *msg,
-                                         intptr_t table, uint64_t hasbits,
-                                         upb_strview *dst) {
-  return fastdecode_longstring(d, ptr, msg, table, hasbits, dst, true);
+                                              const char *ptr, upb_msg *msg,
+                                              intptr_t table, uint64_t hasbits,
+                                              uint64_t data) {
+  upb_strview *dst = (upb_strview*)data;
+  FASTDECODE_LONGSTRING(d, ptr, msg, table, hasbits, dst, true);
 }
 
 UPB_NOINLINE
@@ -709,8 +708,9 @@ static const char *fastdecode_longstring_noutf8(struct upb_decstate *d,
                                                 const char *ptr, upb_msg *msg,
                                                 intptr_t table,
                                                 uint64_t hasbits,
-                                                upb_strview *dst) {
-  return fastdecode_longstring(d, ptr, msg, table, hasbits, dst, false);
+                                                uint64_t data) {
+  upb_strview *dst = (upb_strview*)data;
+  FASTDECODE_LONGSTRING(d, ptr, msg, table, hasbits, dst, false);
 }
 
 UPB_FORCEINLINE
@@ -723,156 +723,165 @@ static void fastdecode_docopy(upb_decstate *d, const char *ptr, uint32_t size,
   UPB_POISON_MEMORY_REGION(data + size, copy - size);
 }
 
-UPB_FORCEINLINE
-static const char *fastdecode_copystring(UPB_PARSE_PARAMS, int tagbytes,
-                                         upb_card card, bool validate_utf8) {
-  upb_strview *dst;
-  fastdecode_arr farr;
-  int64_t size;
-  size_t arena_has;
-  size_t common_has;
-  char *buf;
-
-  UPB_ASSERT(!d->alias);
-  UPB_ASSERT(fastdecode_checktag(data, tagbytes));
-
-  dst = fastdecode_getfield(d, ptr, msg, &data, &hasbits, &farr,
-                            sizeof(upb_strview), card);
-
-again:
-  if (card == CARD_r) {
-    dst = fastdecode_resizearr(d, dst, &farr, sizeof(upb_strview));
-  }
-
-  size = (uint8_t)ptr[tagbytes];
-  ptr += tagbytes + 1;
-  dst->size = size;
-
-  buf = d->arena.head.ptr;
-  arena_has = _upb_arenahas(&d->arena);
-  common_has = UPB_MIN(arena_has, (d->end - ptr) + 16);
-
-  if (UPB_LIKELY(size <= 15 - tagbytes)) {
-    if (arena_has < 16) goto longstr;
-    d->arena.head.ptr += 16;
-    memcpy(buf, ptr - tagbytes - 1, 16);
-    dst->data = buf + tagbytes + 1;
-  } else if (UPB_LIKELY(size <= 32)) {
-    if (UPB_UNLIKELY(common_has < 32)) goto longstr;
-    fastdecode_docopy(d, ptr, size, 32, buf, dst);
-  } else if (UPB_LIKELY(size <= 64)) {
-    if (UPB_UNLIKELY(common_has < 64)) goto longstr;
-    fastdecode_docopy(d, ptr, size, 64, buf, dst);
-  } else if (UPB_LIKELY(size < 128)) {
-    if (UPB_UNLIKELY(common_has < 128)) goto longstr;
-    fastdecode_docopy(d, ptr, size, 128, buf, dst);
-  } else {
-    goto longstr;
-  }
-
-  ptr += size;
-
-  if (card == CARD_r) {
-    if (validate_utf8 && !decode_verifyutf8_inl(dst->data, dst->size)) {
-      return fastdecode_err(d);
-    }
-    fastdecode_nextret ret = fastdecode_nextrepeated(
-        d, dst, &ptr, &farr, data, tagbytes, sizeof(upb_strview));
-    switch (ret.next) {
-      case FD_NEXT_SAMEFIELD:
-        dst = ret.dst;
-        goto again;
-      case FD_NEXT_OTHERFIELD:
-        return fastdecode_tagdispatch(d, ptr, msg, table, hasbits, ret.tag);
-      case FD_NEXT_ATLIMIT:
-        return ptr;
-    }
-  }
-
-  if (card != CARD_r && validate_utf8) {
-    return fastdecode_verifyutf8(d, ptr, msg, table, hasbits, dst);
-  }
-
-  return fastdecode_dispatch(d, ptr, msg, table, hasbits);
-
-longstr:
-  ptr--;
-  if (validate_utf8) {
-    return fastdecode_longstring_utf8(d, ptr, msg, table, hasbits, dst);
-  } else {
-    return fastdecode_longstring_noutf8(d, ptr, msg, table, hasbits, dst);
-  }
-}
-
-UPB_FORCEINLINE
-static const char *fastdecode_string(UPB_PARSE_PARAMS, int tagbytes,
-                                     upb_card card, _upb_field_parser *copyfunc,
-                                     bool validate_utf8) {
-  upb_strview *dst;
-  fastdecode_arr farr;
-  int64_t size;
-
-  if (UPB_UNLIKELY(!fastdecode_checktag(data, tagbytes))) {
-    RETURN_GENERIC("string field tag mismatch\n");
-  }
-
-  if (UPB_UNLIKELY(!d->alias)) {
-    return copyfunc(UPB_PARSE_ARGS);
-  }
-
-  dst = fastdecode_getfield(d, ptr, msg, &data, &hasbits, &farr,
-                            sizeof(upb_strview), card);
-
-again:
-  if (card == CARD_r) {
-    dst = fastdecode_resizearr(d, dst, &farr, sizeof(upb_strview));
+#define FASTDECODE_COPYSTRING(d, ptr, msg, table, hasbits, data, tagbytes,     \
+                              card, validate_utf8)                             \
+  upb_strview *dst;                                                            \
+  fastdecode_arr farr;                                                         \
+  int64_t size;                                                                \
+  size_t arena_has;                                                            \
+  size_t common_has;                                                           \
+  char *buf;                                                                   \
+                                                                               \
+  UPB_ASSERT(!d->alias);                                                       \
+  UPB_ASSERT(fastdecode_checktag(data, tagbytes));                             \
+                                                                               \
+  dst = fastdecode_getfield(d, ptr, msg, &data, &hasbits, &farr,               \
+                            sizeof(upb_strview), card);                        \
+                                                                               \
+  again:                                                                       \
+  if (card == CARD_r) {                                                        \
+    dst = fastdecode_resizearr(d, dst, &farr, sizeof(upb_strview));            \
+  }                                                                            \
+                                                                               \
+  size = (uint8_t)ptr[tagbytes];                                               \
+  ptr += tagbytes + 1;                                                         \
+  dst->size = size;                                                            \
+                                                                               \
+  buf = d->arena.head.ptr;                                                     \
+  arena_has = _upb_arenahas(&d->arena);                                        \
+  common_has = UPB_MIN(arena_has, (d->end - ptr) + 16);                        \
+                                                                               \
+  if (UPB_LIKELY(size <= 15 - tagbytes)) {                                     \
+    if (arena_has < 16)                                                        \
+      goto longstr;                                                            \
+    d->arena.head.ptr += 16;                                                   \
+    memcpy(buf, ptr - tagbytes - 1, 16);                                       \
+    dst->data = buf + tagbytes + 1;                                            \
+  } else if (UPB_LIKELY(size <= 32)) {                                         \
+    if (UPB_UNLIKELY(common_has < 32))                                         \
+      goto longstr;                                                            \
+    fastdecode_docopy(d, ptr, size, 32, buf, dst);                             \
+  } else if (UPB_LIKELY(size <= 64)) {                                         \
+    if (UPB_UNLIKELY(common_has < 64))                                         \
+      goto longstr;                                                            \
+    fastdecode_docopy(d, ptr, size, 64, buf, dst);                             \
+  } else if (UPB_LIKELY(size < 128)) {                                         \
+    if (UPB_UNLIKELY(common_has < 128))                                        \
+      goto longstr;                                                            \
+    fastdecode_docopy(d, ptr, size, 128, buf, dst);                            \
+  } else {                                                                     \
+    goto longstr;                                                              \
+  }                                                                            \
+                                                                               \
+  ptr += size;                                                                 \
+                                                                               \
+  if (card == CARD_r) {                                                        \
+    if (validate_utf8 && !decode_verifyutf8_inl(dst->data, dst->size)) {       \
+      return fastdecode_err(d);                                                \
+    }                                                                          \
+    fastdecode_nextret ret = fastdecode_nextrepeated(                          \
+        d, dst, &ptr, &farr, data, tagbytes, sizeof(upb_strview));             \
+    switch (ret.next) {                                                        \
+    case FD_NEXT_SAMEFIELD:                                                    \
+      dst = ret.dst;                                                           \
+      goto again;                                                              \
+    case FD_NEXT_OTHERFIELD:                                                   \
+      data = ret.tag;                                                          \
+      UPB_MUSTTAIL return fastdecode_tagdispatch(UPB_PARSE_ARGS);              \
+    case FD_NEXT_ATLIMIT:                                                      \
+      return ptr;                                                              \
+    }                                                                          \
+  }                                                                            \
+                                                                               \
+  if (card != CARD_r && validate_utf8) {                                       \
+    data = (uint64_t)dst;                                                      \
+    UPB_MUSTTAIL return fastdecode_verifyutf8(UPB_PARSE_ARGS);                 \
+  }                                                                            \
+                                                                               \
+  UPB_MUSTTAIL return fastdecode_dispatch(UPB_PARSE_ARGS);                     \
+                                                                               \
+  longstr:                                                                     \
+  ptr--;                                                                       \
+  if (validate_utf8) {                                                         \
+    UPB_MUSTTAIL return fastdecode_longstring_utf8(d, ptr, msg, table,         \
+                                                   hasbits, (uint64_t)dst);    \
+  } else {                                                                     \
+    UPB_MUSTTAIL return fastdecode_longstring_noutf8(d, ptr, msg, table,       \
+                                                     hasbits, (uint64_t)dst);  \
   }
 
-  size = (int8_t)ptr[tagbytes];
-  ptr += tagbytes + 1;
-  dst->data = ptr;
-  dst->size = size;
-
-  if (UPB_UNLIKELY(fastdecode_boundscheck(ptr, size, d->end))) {
-    ptr--;
-    if (validate_utf8) {
-      return fastdecode_longstring_utf8(d, ptr, msg, table, hasbits, dst);
-    } else {
-      return fastdecode_longstring_noutf8(d, ptr, msg, table, hasbits, dst);
-    }
-  }
-
-  ptr += size;
-
-  if (card == CARD_r) {
-    if (validate_utf8 && !decode_verifyutf8_inl(dst->data, dst->size)) {
-      return fastdecode_err(d);
-    }
-    fastdecode_nextret ret = fastdecode_nextrepeated(
-        d, dst, &ptr, &farr, data, tagbytes, sizeof(upb_strview));
-    switch (ret.next) {
-      case FD_NEXT_SAMEFIELD:
-        dst = ret.dst;
-        if (UPB_UNLIKELY(!d->alias)) {
-          // Buffer flipped and we can't alias any more. Bounce to copyfunc(),
-          // but via dispatch since we need to reload table data also.
-          fastdecode_commitarr(dst, &farr, sizeof(upb_strview));
-          return fastdecode_tagdispatch(d, ptr, msg, table, hasbits, ret.tag);
-        }
-        goto again;
-      case FD_NEXT_OTHERFIELD:
-        return fastdecode_tagdispatch(d, ptr, msg, table, hasbits, ret.tag);
-      case FD_NEXT_ATLIMIT:
-        return ptr;
-    }
-  }
-
-  if (card != CARD_r && validate_utf8) {
-    return fastdecode_verifyutf8(d, ptr, msg, table, hasbits, dst);
-  }
-
-  return fastdecode_dispatch(d, ptr, msg, table, hasbits);
-}
+#define FASTDECODE_STRING(d, ptr, msg, table, hasbits, data, tagbytes, card,   \
+                          copyfunc, validate_utf8)                             \
+  upb_strview *dst;                                                            \
+  fastdecode_arr farr;                                                         \
+  int64_t size;                                                                \
+                                                                               \
+  if (UPB_UNLIKELY(!fastdecode_checktag(data, tagbytes))) {                    \
+    RETURN_GENERIC("string field tag mismatch\n");                             \
+  }                                                                            \
+                                                                               \
+  if (UPB_UNLIKELY(!d->alias)) {                                               \
+    UPB_MUSTTAIL return copyfunc(UPB_PARSE_ARGS);                              \
+  }                                                                            \
+                                                                               \
+  dst = fastdecode_getfield(d, ptr, msg, &data, &hasbits, &farr,               \
+                            sizeof(upb_strview), card);                        \
+                                                                               \
+  again:                                                                       \
+  if (card == CARD_r) {                                                        \
+    dst = fastdecode_resizearr(d, dst, &farr, sizeof(upb_strview));            \
+  }                                                                            \
+                                                                               \
+  size = (int8_t)ptr[tagbytes];                                                \
+  ptr += tagbytes + 1;                                                         \
+  dst->data = ptr;                                                             \
+  dst->size = size;                                                            \
+                                                                               \
+  if (UPB_UNLIKELY(fastdecode_boundscheck(ptr, size, d->end))) {               \
+    ptr--;                                                                     \
+    if (validate_utf8) {                                                       \
+      return fastdecode_longstring_utf8(d, ptr, msg, table, hasbits,           \
+                                        (uint64_t)dst);                        \
+    } else {                                                                   \
+      return fastdecode_longstring_noutf8(d, ptr, msg, table, hasbits,         \
+                                          (uint64_t)dst);                      \
+    }                                                                          \
+  }                                                                            \
+                                                                               \
+  ptr += size;                                                                 \
+                                                                               \
+  if (card == CARD_r) {                                                        \
+    if (validate_utf8 && !decode_verifyutf8_inl(dst->data, dst->size)) {       \
+      return fastdecode_err(d);                                                \
+    }                                                                          \
+    fastdecode_nextret ret = fastdecode_nextrepeated(                          \
+        d, dst, &ptr, &farr, data, tagbytes, sizeof(upb_strview));             \
+    switch (ret.next) {                                                        \
+    case FD_NEXT_SAMEFIELD:                                                    \
+      dst = ret.dst;                                                           \
+      if (UPB_UNLIKELY(!d->alias)) {                                           \
+        /* Buffer flipped and we can't alias any more. Bounce to */            \
+        /* copyfunc(), but via dispatch since we need to reload table */       \
+        /* data also. */                                                       \
+        fastdecode_commitarr(dst, &farr, sizeof(upb_strview));                 \
+        data = ret.tag;                                                        \
+        UPB_MUSTTAIL return fastdecode_tagdispatch(UPB_PARSE_ARGS);            \
+      }                                                                        \
+      goto again;                                                              \
+    case FD_NEXT_OTHERFIELD:                                                   \
+      data = ret.tag;                                                          \
+      UPB_MUSTTAIL return fastdecode_tagdispatch(UPB_PARSE_ARGS);              \
+    case FD_NEXT_ATLIMIT:                                                      \
+      return ptr;                                                              \
+    }                                                                          \
+  }                                                                            \
+                                                                               \
+  if (card != CARD_r && validate_utf8) {                                       \
+    data = (uint64_t)dst;                                                      \
+    UPB_MUSTTAIL return fastdecode_verifyutf8(UPB_PARSE_ARGS);                 \
+  }                                                                            \
+                                                                               \
+  UPB_MUSTTAIL return fastdecode_dispatch(UPB_PARSE_ARGS);
 
 /* Generate all combinations:
  * {p,c} x {s,o,r} x {s, b} x {1bt,2bt} */
@@ -880,16 +889,16 @@ again:
 #define s_VALIDATE true
 #define b_VALIDATE false
 
-#define F(card, tagbytes, type)                                         \
-  UPB_NOINLINE                                                          \
-  const char *upb_c##card##type##_##tagbytes##bt(UPB_PARSE_PARAMS) {    \
-    return fastdecode_copystring(UPB_PARSE_ARGS, tagbytes, CARD_##card, \
-                                 type##_VALIDATE);                      \
-  }                                                                     \
-  const char *upb_p##card##type##_##tagbytes##bt(UPB_PARSE_PARAMS) {    \
-    return fastdecode_string(UPB_PARSE_ARGS, tagbytes, CARD_##card,     \
-                             &upb_c##card##type##_##tagbytes##bt,       \
-                             type##_VALIDATE);                          \
+#define F(card, tagbytes, type)                                        \
+  UPB_NOINLINE                                                         \
+  const char *upb_c##card##type##_##tagbytes##bt(UPB_PARSE_PARAMS) {   \
+    FASTDECODE_COPYSTRING(d, ptr, msg, table, hasbits, data, tagbytes, \
+                          CARD_##card, type##_VALIDATE);               \
+  }                                                                    \
+  const char *upb_p##card##type##_##tagbytes##bt(UPB_PARSE_PARAMS) {   \
+    FASTDECODE_STRING(d, ptr, msg, table, hasbits, data, tagbytes,     \
+                      CARD_##card, upb_c##card##type##_##tagbytes##bt, \
+                      type##_VALIDATE);                                \
   }
 
 #define UTF8(card, tagbytes) \
@@ -908,6 +917,9 @@ TAGBYTES(r)
 #undef b_VALIDATE
 #undef F
 #undef TAGBYTES
+#undef FASTDECODE_LONGSTRING
+#undef FASTDECODE_COPYSTRING
+#undef FASTDECODE_STRING
 
 /* message fields *************************************************************/
 
@@ -940,82 +952,82 @@ UPB_FORCEINLINE
 static const char *fastdecode_tosubmsg(upb_decstate *d, const char *ptr,
                                        void *ctx) {
   fastdecode_submsgdata *submsg = ctx;
-  ptr = fastdecode_dispatch(d, ptr, submsg->msg, submsg->table, 0);
+  ptr = fastdecode_dispatch(d, ptr, submsg->msg, submsg->table, 0, 0);
   UPB_ASSUME(ptr != NULL);
   return ptr;
 }
 
-UPB_FORCEINLINE
-static const char *fastdecode_submsg(UPB_PARSE_PARAMS, int tagbytes,
-                                     int msg_ceil_bytes, upb_card card) {
-
-  if (UPB_UNLIKELY(!fastdecode_checktag(data, tagbytes))) {
-    RETURN_GENERIC("submessage field tag mismatch\n");
-  }
-
-  if (--d->depth == 0) return fastdecode_err(d);
-
-  upb_msg **dst;
-  uint32_t submsg_idx = (data >> 16) & 0xff;
-  const upb_msglayout *tablep = decode_totablep(table);
-  const upb_msglayout *subtablep = tablep->submsgs[submsg_idx];
-  fastdecode_submsgdata submsg = {decode_totable(subtablep)};
-  fastdecode_arr farr;
-
-  if (subtablep->table_mask == (uint8_t)-1) {
-    RETURN_GENERIC("submessage doesn't have fast tables.");
-  }
-
-  dst = fastdecode_getfield(d, ptr, msg, &data, &hasbits, &farr,
-                            sizeof(upb_msg *), card);
-
-  if (card == CARD_s) {
-    *(uint32_t*)msg |= hasbits;
-    hasbits = 0;
-  }
-
-again:
-  if (card == CARD_r) {
-    dst = fastdecode_resizearr(d, dst, &farr, sizeof(upb_msg*));
-  }
-
-  submsg.msg = *dst;
-
-  if (card == CARD_r || UPB_LIKELY(!submsg.msg)) {
-    *dst = submsg.msg = decode_newmsg_ceil(d, subtablep, msg_ceil_bytes);
-  }
-
-  ptr += tagbytes;
-  ptr = fastdecode_delimited(d, ptr, fastdecode_tosubmsg, &submsg);
-
-  if (UPB_UNLIKELY(ptr == NULL || d->end_group != DECODE_NOGROUP)) {
-    return fastdecode_err(d);
-  }
-
-  if (card == CARD_r) {
-    fastdecode_nextret ret = fastdecode_nextrepeated(
-        d, dst, &ptr, &farr, data, tagbytes, sizeof(upb_msg *));
-    switch (ret.next) {
-      case FD_NEXT_SAMEFIELD:
-        dst = ret.dst;
-        goto again;
-      case FD_NEXT_OTHERFIELD:
-        d->depth++;
-        return fastdecode_tagdispatch(d, ptr, msg, table, hasbits, ret.tag);
-      case FD_NEXT_ATLIMIT:
-        d->depth++;
-        return ptr;
-    }
-  }
-
-  d->depth++;
-  return fastdecode_dispatch(d, ptr, msg, table, hasbits);
-}
-
-#define F(card, tagbytes, size_ceil, ceil_arg)                                 \
-  const char *upb_p##card##m_##tagbytes##bt_max##size_ceil##b(                 \
-      UPB_PARSE_PARAMS) {                                                      \
-    return fastdecode_submsg(UPB_PARSE_ARGS, tagbytes, ceil_arg, CARD_##card); \
+#define FASTDECODE_SUBMSG(d, ptr, msg, table, hasbits, data, tagbytes,    \
+                          msg_ceil_bytes, card)                           \
+                                                                          \
+  if (UPB_UNLIKELY(!fastdecode_checktag(data, tagbytes))) {               \
+    RETURN_GENERIC("submessage field tag mismatch\n");                    \
+  }                                                                       \
+                                                                          \
+  if (--d->depth == 0) return fastdecode_err(d);                          \
+                                                                          \
+  upb_msg **dst;                                                          \
+  uint32_t submsg_idx = (data >> 16) & 0xff;                              \
+  const upb_msglayout *tablep = decode_totablep(table);                   \
+  const upb_msglayout *subtablep = tablep->submsgs[submsg_idx];           \
+  fastdecode_submsgdata submsg = {decode_totable(subtablep)};             \
+  fastdecode_arr farr;                                                    \
+                                                                          \
+  if (subtablep->table_mask == (uint8_t)-1) {                             \
+    RETURN_GENERIC("submessage doesn't have fast tables.");               \
+  }                                                                       \
+                                                                          \
+  dst = fastdecode_getfield(d, ptr, msg, &data, &hasbits, &farr,          \
+                            sizeof(upb_msg *), card);                     \
+                                                                          \
+  if (card == CARD_s) {                                                   \
+    *(uint32_t *)msg |= hasbits;                                          \
+    hasbits = 0;                                                          \
+  }                                                                       \
+                                                                          \
+  again:                                                                  \
+  if (card == CARD_r) {                                                   \
+    dst = fastdecode_resizearr(d, dst, &farr, sizeof(upb_msg *));         \
+  }                                                                       \
+                                                                          \
+  submsg.msg = *dst;                                                      \
+                                                                          \
+  if (card == CARD_r || UPB_LIKELY(!submsg.msg)) {                        \
+    *dst = submsg.msg = decode_newmsg_ceil(d, subtablep, msg_ceil_bytes); \
+  }                                                                       \
+                                                                          \
+  ptr += tagbytes;                                                        \
+  ptr = fastdecode_delimited(d, ptr, fastdecode_tosubmsg, &submsg);       \
+                                                                          \
+  if (UPB_UNLIKELY(ptr == NULL || d->end_group != DECODE_NOGROUP)) {      \
+    return fastdecode_err(d);                                             \
+  }                                                                       \
+                                                                          \
+  if (card == CARD_r) {                                                   \
+    fastdecode_nextret ret = fastdecode_nextrepeated(                     \
+        d, dst, &ptr, &farr, data, tagbytes, sizeof(upb_msg *));          \
+    switch (ret.next) {                                                   \
+      case FD_NEXT_SAMEFIELD:                                             \
+        dst = ret.dst;                                                    \
+        goto again;                                                       \
+      case FD_NEXT_OTHERFIELD:                                            \
+        d->depth++;                                                       \
+        data = ret.tag;                                                   \
+        UPB_MUSTTAIL return fastdecode_tagdispatch(UPB_PARSE_ARGS);       \
+      case FD_NEXT_ATLIMIT:                                               \
+        d->depth++;                                                       \
+        return ptr;                                                       \
+    }                                                                     \
+  }                                                                       \
+                                                                          \
+  d->depth++;                                                             \
+  UPB_MUSTTAIL return fastdecode_dispatch(UPB_PARSE_ARGS);
+
+#define F(card, tagbytes, size_ceil, ceil_arg)                               \
+  const char *upb_p##card##m_##tagbytes##bt_max##size_ceil##b(               \
+      UPB_PARSE_PARAMS) {                                                    \
+    FASTDECODE_SUBMSG(d, ptr, msg, table, hasbits, data, tagbytes, ceil_arg, \
+                      CARD_##card);                                          \
   }
 
 #define SIZES(card, tagbytes) \
@@ -1036,5 +1048,6 @@ TAGBYTES(r)
 #undef TAGBYTES
 #undef SIZES
 #undef F
+#undef FASTDECODE_SUBMSG
 
 #endif  /* UPB_FASTTABLE */
index 6d56d12..a05cd80 100644 (file)
@@ -1,3 +1,30 @@
+/*
+ * Copyright (c) 2009-2021, Google LLC
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ *     * Redistributions of source code must retain the above copyright
+ *       notice, this list of conditions and the following disclaimer.
+ *     * Redistributions in binary form must reproduce the above copyright
+ *       notice, this list of conditions and the following disclaimer in the
+ *       documentation and/or other materials provided with the distribution.
+ *     * Neither the name of Google LLC nor the
+ *       names of its contributors may be used to endorse or promote products
+ *       derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+ * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ * DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+ * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+ * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+ * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
 // These are the specialized field parser functions for the fast parser.
 // Generated tables will refer to these by name.
 //
similarity index 68%
rename from third_party/upb/upb/decode.int.h
rename to third_party/upb/upb/decode_internal.h
index e286b9c..0492363 100644 (file)
@@ -1,20 +1,47 @@
 /*
-** Internal implementation details of the decoder that are shared between
-** decode.c and decode_fast.c.
-*/
+ * Copyright (c) 2009-2021, Google LLC
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ *     * Redistributions of source code must retain the above copyright
+ *       notice, this list of conditions and the following disclaimer.
+ *     * Redistributions in binary form must reproduce the above copyright
+ *       notice, this list of conditions and the following disclaimer in the
+ *       documentation and/or other materials provided with the distribution.
+ *     * Neither the name of Google LLC nor the
+ *       names of its contributors may be used to endorse or promote products
+ *       derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+ * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ * DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+ * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+ * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+ * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+/*
+ * Internal implementation details of the decoder that are shared between
+ * decode.c and decode_fast.c.
+ */
 
 #ifndef UPB_DECODE_INT_H_
 #define UPB_DECODE_INT_H_
 
 #include <setjmp.h>
 
-#include "upb/msg.h"
-#include "upb/upb.int.h"
+#include "upb/msg_internal.h"
+#include "upb/upb_internal.h"
 
 /* Must be last. */
 #include "upb/port_def.inc"
 
-#define DECODE_NOGROUP -1
+#define DECODE_NOGROUP (uint32_t)-1
 
 typedef struct upb_decstate {
   const char *end;         /* Can read up to 16 bytes slop beyond this. */
@@ -115,10 +142,11 @@ bool decode_isdone(upb_decstate *d, const char **ptr) {
   }
 }
 
+#if UPB_FASTTABLE
 UPB_INLINE
 const char *fastdecode_tagdispatch(upb_decstate *d, const char *ptr,
                                     upb_msg *msg, intptr_t table,
-                                    uint64_t hasbits, uint32_t tag) {
+                                    uint64_t hasbits, uint64_t tag) {
   const upb_msglayout *table_p = decode_totablep(table);
   uint8_t mask = table;
   uint64_t data;
@@ -126,8 +154,10 @@ const char *fastdecode_tagdispatch(upb_decstate *d, const char *ptr,
   UPB_ASSUME((idx & 7) == 0);
   idx >>= 3;
   data = table_p->fasttable[idx].field_data ^ tag;
-  return table_p->fasttable[idx].field_parser(d, ptr, msg, table, hasbits, data);
+  UPB_MUSTTAIL return table_p->fasttable[idx].field_parser(d, ptr, msg, table,
+                                                           hasbits, data);
 }
+#endif
 
 UPB_INLINE uint32_t fastdecode_loadtag(const char* ptr) {
   uint16_t tag;
index 4ba553a..641f1b4 100644 (file)
@@ -1,3 +1,29 @@
+/*
+ * Copyright (c) 2009-2021, Google LLC
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ *     * Redistributions of source code must retain the above copyright
+ *       notice, this list of conditions and the following disclaimer.
+ *     * Redistributions in binary form must reproduce the above copyright
+ *       notice, this list of conditions and the following disclaimer in the
+ *       documentation and/or other materials provided with the distribution.
+ *     * Neither the name of Google LLC nor the
+ *       names of its contributors may be used to endorse or promote products
+ *       derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+ * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ * DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+ * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+ * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+ * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
 
 #include "upb/def.h"
 
@@ -8,6 +34,9 @@
 #include <string.h>
 
 #include "google/protobuf/descriptor.upb.h"
+#include "upb/reflection.h"
+
+/* Must be last. */
 #include "upb/port_def.inc"
 
 typedef struct {
@@ -37,7 +66,6 @@ struct upb_fielddef {
   uint32_t number_;
   uint16_t index_;
   uint16_t layout_index;
-  uint32_t selector_base;  /* Used to index into a upb::Handlers table. */
   bool is_extension_;
   bool lazy_;
   bool packed_;
@@ -50,8 +78,6 @@ struct upb_msgdef {
   const upb_msglayout *layout;
   const upb_filedef *file;
   const char *full_name;
-  uint32_t selector_count;
-  uint32_t submsg_field_count;
 
   /* Tables for looking up fields by number and name. */
   upb_inttable itof;
@@ -181,30 +207,6 @@ int cmp_fields(const void *p1, const void *p2) {
   return field_rank(f1) - field_rank(f2);
 }
 
-/* A few implementation details of handlers.  We put these here to avoid
- * a def -> handlers dependency. */
-
-#define UPB_STATIC_SELECTOR_COUNT 3  /* Warning: also in upb/handlers.h. */
-
-static uint32_t upb_handlers_selectorbaseoffset(const upb_fielddef *f) {
-  return upb_fielddef_isseq(f) ? 2 : 0;
-}
-
-static uint32_t upb_handlers_selectorcount(const upb_fielddef *f) {
-  uint32_t ret = 1;
-  if (upb_fielddef_isseq(f)) ret += 2;    /* STARTSEQ/ENDSEQ */
-  if (upb_fielddef_isstring(f)) ret += 2; /* [STRING]/STARTSTR/ENDSTR */
-  if (upb_fielddef_issubmsg(f)) {
-    /* ENDSUBMSG (STARTSUBMSG is at table beginning) */
-    ret += 0;
-    if (upb_fielddef_lazy(f)) {
-      /* STARTSTR/ENDSTR/STRING (for lazy) */
-      ret += 3;
-    }
-  }
-  return ret;
-}
-
 static void upb_status_setoom(upb_status *status) {
   upb_status_seterrmsg(status, "out of memory");
 }
@@ -296,8 +298,7 @@ bool upb_enumdef_ntoi(const upb_enumdef *def, const char *name,
 
 const char *upb_enumdef_iton(const upb_enumdef *def, int32_t num) {
   upb_value v;
-  return upb_inttable_lookup32(&def->iton, num, &v) ?
-      upb_value_getcstr(v) : NULL;
+  return upb_inttable_lookup(&def->iton, num, &v) ? upb_value_getcstr(v) : NULL;
 }
 
 const char *upb_enum_iter_name(upb_enum_iter *iter) {
@@ -386,10 +387,6 @@ const char *upb_fielddef_jsonname(const upb_fielddef *f) {
   return f->json_name;
 }
 
-uint32_t upb_fielddef_selectorbase(const upb_fielddef *f) {
-  return f->selector_base;
-}
-
 const upb_filedef *upb_fielddef_file(const upb_fielddef *f) {
   return f->file;
 }
@@ -407,6 +404,23 @@ const upb_oneofdef *upb_fielddef_realcontainingoneof(const upb_fielddef *f) {
   return f->oneof;
 }
 
+upb_msgval upb_fielddef_default(const upb_fielddef *f) {
+  UPB_ASSERT(!upb_fielddef_issubmsg(f));
+  upb_msgval ret;
+  if (upb_fielddef_isstring(f)) {
+    str_t *str = f->defaultval.str;
+    if (str) {
+      ret.str_val.data = str->str;
+      ret.str_val.size = str->len;
+    } else {
+      ret.str_val.size = 0;
+    }
+  } else {
+    memcpy(&ret, &f->defaultval, 8);
+  }
+  return ret;
+}
+
 static void chkdefaulttype(const upb_fielddef *f, int ctype) {
   UPB_UNUSED(f);
   UPB_UNUSED(ctype);
@@ -535,18 +549,10 @@ upb_syntax_t upb_msgdef_syntax(const upb_msgdef *m) {
   return m->file->syntax;
 }
 
-size_t upb_msgdef_selectorcount(const upb_msgdef *m) {
-  return m->selector_count;
-}
-
-uint32_t upb_msgdef_submsgfieldcount(const upb_msgdef *m) {
-  return m->submsg_field_count;
-}
-
 const upb_fielddef *upb_msgdef_itof(const upb_msgdef *m, uint32_t i) {
   upb_value val;
-  return upb_inttable_lookup32(&m->itof, i, &val) ?
-      upb_value_getconstptr(val) : NULL;
+  return upb_inttable_lookup(&m->itof, i, &val) ? upb_value_getconstptr(val)
+                                                : NULL;
 }
 
 const upb_fielddef *upb_msgdef_ntof(const upb_msgdef *m, const char *name,
@@ -754,8 +760,8 @@ const upb_fielddef *upb_oneofdef_ntof(const upb_oneofdef *o,
 
 const upb_fielddef *upb_oneofdef_itof(const upb_oneofdef *o, uint32_t num) {
   upb_value val;
-  return upb_inttable_lookup32(&o->itof, num, &val) ?
-      upb_value_getptr(val) : NULL;
+  return upb_inttable_lookup(&o->itof, num, &val) ? upb_value_getptr(val)
+                                                  : NULL;
 }
 
 void upb_oneof_begin(upb_oneof_iter *iter, const upb_oneofdef *o) {
@@ -835,7 +841,6 @@ void upb_symtab_free(upb_symtab *s) {
 
 upb_symtab *upb_symtab_new(void) {
   upb_symtab *s = upb_gmalloc(sizeof(*s));
-  upb_alloc *alloc;
 
   if (!s) {
     return NULL;
@@ -843,10 +848,9 @@ upb_symtab *upb_symtab_new(void) {
 
   s->arena = upb_arena_new();
   s->bytes_loaded = 0;
-  alloc = upb_arena_alloc(s->arena);
 
-  if (!upb_strtable_init2(&s->syms, UPB_CTYPE_CONSTPTR, 32, alloc) ||
-      !upb_strtable_init2(&s->files, UPB_CTYPE_CONSTPTR, 4, alloc)) {
+  if (!upb_strtable_init(&s->syms, 32, s->arena) ||
+      !upb_strtable_init(&s->files, 4, s->arena)) {
     upb_arena_free(s->arena);
     upb_gfree(s);
     s = NULL;
@@ -902,14 +906,13 @@ int upb_symtab_filecount(const upb_symtab *s) {
 typedef struct {
   upb_symtab *symtab;
   upb_filedef *file;              /* File we are building. */
-  upb_arena *file_arena;          /* Allocate defs here. */
-  upb_alloc *alloc;               /* Alloc of file_arena, for tables. */
+  upb_arena *arena;               /* Allocate defs here. */
   const upb_msglayout **layouts;  /* NULL if we should build layouts. */
   upb_status *status;             /* Record errors here. */
   jmp_buf err;                    /* longjmp() on error. */
 } symtab_addctx;
 
-UPB_NORETURN UPB_NOINLINE
+UPB_NORETURN UPB_NOINLINE UPB_PRINTF(2, 3)
 static void symtab_errf(symtab_addctx *ctx, const char *fmt, ...) {
   va_list argp;
   va_start(argp, fmt);
@@ -925,7 +928,7 @@ static void symtab_oomerr(symtab_addctx *ctx) {
 }
 
 void *symtab_alloc(symtab_addctx *ctx, size_t bytes) {
-  void *ret = upb_arena_malloc(ctx->file_arena, bytes);
+  void *ret = upb_arena_malloc(ctx->arena, bytes);
   if (!ret) symtab_oomerr(ctx);
   return ret;
 }
@@ -1015,13 +1018,44 @@ static int field_number_cmp(const void *p1, const void *p2) {
   return f1->number - f2->number;
 }
 
-static void assign_layout_indices(const upb_msgdef *m, upb_msglayout_field *fields) {
+static void assign_layout_indices(const upb_msgdef *m, upb_msglayout *l,
+                                  upb_msglayout_field *fields) {
   int i;
   int n = upb_msgdef_numfields(m);
+  int dense_below = 0;
   for (i = 0; i < n; i++) {
     upb_fielddef *f = (upb_fielddef*)upb_msgdef_itof(m, fields[i].number);
     UPB_ASSERT(f);
     f->layout_index = i;
+    if (i < UINT8_MAX && fields[i].number == i + 1 &&
+        (i == 0 || fields[i-1].number == i)) {
+      dense_below = i + 1;
+    }
+  }
+  l->dense_below = dense_below;
+}
+
+static void fill_fieldlayout(upb_msglayout_field *field, const upb_fielddef *f) {
+  field->number = upb_fielddef_number(f);
+  field->descriptortype = upb_fielddef_descriptortype(f);
+
+  if (field->descriptortype == UPB_DTYPE_STRING &&
+      f->file->syntax == UPB_SYNTAX_PROTO2) {
+    /* See TableDescriptorType() in upbc/generator.cc for details and
+     * rationale. */
+    field->descriptortype = UPB_DTYPE_BYTES;
+  }
+
+  if (upb_fielddef_ismap(f)) {
+    field->mode = _UPB_MODE_MAP;
+  } else if (upb_fielddef_isseq(f)) {
+    field->mode = _UPB_MODE_ARRAY;
+  } else {
+    field->mode = _UPB_MODE_SCALAR;
+  }
+
+  if (upb_fielddef_packed(f)) {
+    field->mode |= _UPB_MODE_IS_PACKED;
   }
 }
 
@@ -1032,13 +1066,21 @@ static void make_layout(symtab_addctx *ctx, const upb_msgdef *m) {
   upb_msg_field_iter it;
   upb_msg_oneof_iter oit;
   size_t hasbit;
-  size_t submsg_count = m->submsg_field_count;
+  size_t field_count = upb_msgdef_numfields(m);
+  size_t submsg_count = 0;
   const upb_msglayout **submsgs;
   upb_msglayout_field *fields;
 
   memset(l, 0, sizeof(*l) + sizeof(_upb_fasttable_entry));
 
-  fields = symtab_alloc(ctx, upb_msgdef_numfields(m) * sizeof(*fields));
+  /* Count sub-messages. */
+  for (size_t i = 0; i < field_count; i++) {
+    if (upb_fielddef_issubmsg(&m->fields[i])) {
+      submsg_count++;
+    }
+  }
+
+  fields = symtab_alloc(ctx, field_count * sizeof(*fields));
   submsgs = symtab_alloc(ctx, submsg_count * sizeof(*submsgs));
 
   l->field_count = upb_msgdef_numfields(m);
@@ -1058,8 +1100,8 @@ static void make_layout(symtab_addctx *ctx, const upb_msgdef *m) {
     const upb_fielddef *val = upb_msgdef_itof(m, 2);
     fields[0].number = 1;
     fields[1].number = 2;
-    fields[0].label = UPB_LABEL_OPTIONAL;
-    fields[1].label = UPB_LABEL_OPTIONAL;
+    fields[0].mode = _UPB_MODE_SCALAR;
+    fields[1].mode = _UPB_MODE_SCALAR;
     fields[0].presence = 0;
     fields[1].presence = 0;
     fields[0].descriptortype = upb_fielddef_descriptortype(key);
@@ -1095,22 +1137,7 @@ static void make_layout(symtab_addctx *ctx, const upb_msgdef *m) {
     upb_fielddef* f = upb_msg_iter_field(&it);
     upb_msglayout_field *field = &fields[upb_fielddef_index(f)];
 
-    field->number = upb_fielddef_number(f);
-    field->descriptortype = upb_fielddef_descriptortype(f);
-    field->label = upb_fielddef_label(f);
-
-    if (field->descriptortype == UPB_DTYPE_STRING &&
-        f->file->syntax == UPB_SYNTAX_PROTO2) {
-      /* See TableDescriptorType() in upbc/generator.cc for details and
-       * rationale. */
-      field->descriptortype = UPB_DTYPE_BYTES;
-    }
-
-    if (upb_fielddef_ismap(f)) {
-      field->label = _UPB_LABEL_MAP;
-    } else if (upb_fielddef_packed(f)) {
-      field->label = _UPB_LABEL_PACKED;
-    }
+    fill_fieldlayout(field, f);
 
     if (upb_fielddef_issubmsg(f)) {
       const upb_msgdef *subm = upb_fielddef_msgsubdef(f);
@@ -1186,54 +1213,11 @@ static void make_layout(symtab_addctx *ctx, const upb_msgdef *m) {
 
   /* Sort fields by number. */
   qsort(fields, upb_msgdef_numfields(m), sizeof(*fields), field_number_cmp);
-  assign_layout_indices(m, fields);
-}
-
-static void assign_msg_indices(symtab_addctx *ctx, upb_msgdef *m) {
-  /* Sort fields.  upb internally relies on UPB_TYPE_MESSAGE fields having the
-   * lowest indexes, but we do not publicly guarantee this. */
-  upb_msg_field_iter j;
-  int i;
-  uint32_t selector;
-  int n = upb_msgdef_numfields(m);
-  upb_fielddef **fields;
-
-  if (n == 0) {
-    m->selector_count = UPB_STATIC_SELECTOR_COUNT;
-    m->submsg_field_count = 0;
-    return;
-  }
-
-  fields = upb_gmalloc(n * sizeof(*fields));
-
-  m->submsg_field_count = 0;
-  for(i = 0, upb_msg_field_begin(&j, m);
-      !upb_msg_field_done(&j);
-      upb_msg_field_next(&j), i++) {
-    upb_fielddef *f = upb_msg_iter_field(&j);
-    UPB_ASSERT(f->msgdef == m);
-    if (upb_fielddef_issubmsg(f)) {
-      m->submsg_field_count++;
-    }
-    fields[i] = f;
-  }
-
-  qsort(fields, n, sizeof(*fields), cmp_fields);
-
-  selector = UPB_STATIC_SELECTOR_COUNT + m->submsg_field_count;
-  for (i = 0; i < n; i++) {
-    upb_fielddef *f = fields[i];
-    f->index_ = i;
-    f->selector_base = selector + upb_handlers_selectorbaseoffset(f);
-    selector += upb_handlers_selectorcount(f);
-  }
-  m->selector_count = selector;
-
-  upb_gfree(fields);
+  assign_layout_indices(m, l, fields);
 }
 
 static char *strviewdup(symtab_addctx *ctx, upb_strview view) {
-  return upb_strdup2(view.data, view.size, ctx->alloc);
+  return upb_strdup2(view.data, view.size, ctx->arena);
 }
 
 static bool streql2(const char *a, size_t n, const char *b) {
@@ -1344,9 +1328,9 @@ static void symtab_add(symtab_addctx *ctx, const char *name, upb_value v) {
   if (upb_strtable_lookup(&ctx->symtab->syms, name, NULL)) {
     symtab_errf(ctx, "duplicate symbol '%s'", name);
   }
-  upb_alloc *alloc = upb_arena_alloc(ctx->symtab->arena);
   size_t len = strlen(name);
-  CHK_OOM(upb_strtable_insert3(&ctx->symtab->syms, name, len, v, alloc));
+  CHK_OOM(upb_strtable_insert(&ctx->symtab->syms, name, len, v,
+                              ctx->symtab->arena));
 }
 
 /* Given a symbol and the base symbol inside which it is defined, find the
@@ -1379,7 +1363,8 @@ static const void *symtab_resolve(symtab_addctx *ctx, const upb_fielddef *f,
   }
 
 notfound:
-  symtab_errf(ctx, "couldn't resolve name '%s'", sym.data);
+  symtab_errf(ctx, "couldn't resolve name '" UPB_STRVIEW_FORMAT "'",
+              UPB_STRVIEW_ARGS(sym));
 }
 
 static void create_oneofdef(
@@ -1397,10 +1382,10 @@ static void create_oneofdef(
 
   v = pack_def(o, UPB_DEFTYPE_ONEOF);
   symtab_add(ctx, o->full_name, v);
-  CHK_OOM(upb_strtable_insert3(&m->ntof, name.data, name.size, v, ctx->alloc));
+  CHK_OOM(upb_strtable_insert(&m->ntof, name.data, name.size, v, ctx->arena));
 
-  CHK_OOM(upb_inttable_init2(&o->itof, UPB_CTYPE_CONSTPTR, ctx->alloc));
-  CHK_OOM(upb_strtable_init2(&o->ntof, UPB_CTYPE_CONSTPTR, 4, ctx->alloc));
+  CHK_OOM(upb_inttable_init(&o->itof, ctx->arena));
+  CHK_OOM(upb_strtable_init(&o->ntof, 4, ctx->arena));
 }
 
 static str_t *newstr(symtab_addctx *ctx, const char *data, size_t len) {
@@ -1456,8 +1441,7 @@ static void parse_default(symtab_addctx *ctx, const char *str, size_t len,
       break;
     }
     case UPB_TYPE_INT64: {
-      /* XXX: Need to write our own strtoll, since it's not available in c89. */
-      int64_t val = strtol(str, &end, 0);
+      long long val = strtoll(str, &end, 0);
       if (val > INT64_MAX || val < INT64_MIN || errno == ERANGE || *end) {
         goto invalid;
       }
@@ -1473,8 +1457,7 @@ static void parse_default(symtab_addctx *ctx, const char *str, size_t len,
       break;
     }
     case UPB_TYPE_UINT64: {
-      /* XXX: Need to write our own strtoull, since it's not available in c89. */
-      uint64_t val = strtoul(str, &end, 0);
+      unsigned long long val = strtoull(str, &end, 0);
       if (val > UINT64_MAX || errno == ERANGE || *end) {
         goto invalid;
       }
@@ -1490,8 +1473,7 @@ static void parse_default(symtab_addctx *ctx, const char *str, size_t len,
       break;
     }
     case UPB_TYPE_FLOAT: {
-      /* XXX: Need to write our own strtof, since it's not available in c89. */
-      float val = strtod(str, &end);
+      float val = strtof(str, &end);
       if (errno == ERANGE || *end) {
         goto invalid;
       }
@@ -1523,7 +1505,7 @@ static void parse_default(symtab_addctx *ctx, const char *str, size_t len,
   return;
 
 invalid:
-  symtab_errf(ctx, "Invalid default '%.*s' for field %f", (int)len, str,
+  symtab_errf(ctx, "Invalid default '%.*s' for field %s", (int)len, str,
               upb_fielddef_fullname(f));
 }
 
@@ -1557,7 +1539,6 @@ static void set_default_default(symtab_addctx *ctx, upb_fielddef *f) {
 static void create_fielddef(
     symtab_addctx *ctx, const char *prefix, upb_msgdef *m,
     const google_protobuf_FieldDescriptorProto *field_proto) {
-  upb_alloc *alloc = ctx->alloc;
   upb_fielddef *f;
   const google_protobuf_FieldOptions *options;
   upb_strview name;
@@ -1593,7 +1574,8 @@ static void create_fielddef(
     upb_value v, field_v, json_v;
     size_t json_size;
 
-    f = (upb_fielddef*)&m->fields[m->field_count++];
+    f = (upb_fielddef*)&m->fields[m->field_count];
+    f->index_ = m->field_count++;
     f->msgdef = m;
     f->is_extension_ = false;
 
@@ -1614,12 +1596,12 @@ static void create_fielddef(
     v = upb_value_constptr(f);
     json_size = strlen(json_name);
 
-    CHK_OOM(
-        upb_strtable_insert3(&m->ntof, name.data, name.size, field_v, alloc));
-    CHK_OOM(upb_inttable_insert2(&m->itof, field_number, v, alloc));
+    CHK_OOM(upb_strtable_insert(&m->ntof, name.data, name.size, field_v,
+                                ctx->arena));
+    CHK_OOM(upb_inttable_insert(&m->itof, field_number, v, ctx->arena));
 
     if (strcmp(shortname, json_name) != 0) {
-      upb_strtable_insert3(&m->ntof, json_name, json_size, json_v, alloc);
+      upb_strtable_insert(&m->ntof, json_name, json_size, json_v, ctx->arena);
     }
 
     if (ctx->layouts) {
@@ -1682,15 +1664,16 @@ static void create_fielddef(
       symtab_errf(ctx, "oneof_index out of range (%s)", f->full_name);
     }
 
-    oneof = (upb_oneofdef*)&m->oneofs[oneof_index];
+    oneof = (upb_oneofdef *)&m->oneofs[oneof_index];
     f->oneof = oneof;
 
     oneof->field_count++;
     if (f->proto3_optional_) {
       oneof->synthetic = true;
     }
-    CHK_OOM(upb_inttable_insert2(&oneof->itof, f->number_, v, alloc));
-    CHK_OOM(upb_strtable_insert3(&oneof->ntof, name.data, name.size, v, alloc));
+    CHK_OOM(upb_inttable_insert(&oneof->itof, f->number_, v, ctx->arena));
+    CHK_OOM(
+        upb_strtable_insert(&oneof->ntof, name.data, name.size, v, ctx->arena));
   } else {
     f->oneof = NULL;
     if (f->proto3_optional_) {
@@ -1733,8 +1716,8 @@ static void create_enumdef(
   symtab_add(ctx, e->full_name, pack_def(e, UPB_DEFTYPE_ENUM));
 
   values = google_protobuf_EnumDescriptorProto_value(enum_proto, &n);
-  CHK_OOM(upb_strtable_init2(&e->ntoi, UPB_CTYPE_INT32, n, ctx->alloc));
-  CHK_OOM(upb_inttable_init2(&e->iton, UPB_CTYPE_CSTR, ctx->alloc));
+  CHK_OOM(upb_strtable_init(&e->ntoi, n, ctx->arena));
+  CHK_OOM(upb_inttable_init(&e->iton, ctx->arena));
 
   e->file = ctx->file;
   e->defaultval = 0;
@@ -1761,16 +1744,15 @@ static void create_enumdef(
     }
 
     CHK_OOM(name2)
-    CHK_OOM(
-        upb_strtable_insert3(&e->ntoi, name2, strlen(name2), v, ctx->alloc));
+    CHK_OOM(upb_strtable_insert(&e->ntoi, name2, strlen(name2), v, ctx->arena));
 
     if (!upb_inttable_lookup(&e->iton, num, NULL)) {
       upb_value v = upb_value_cstr(name2);
-      CHK_OOM(upb_inttable_insert2(&e->iton, num, v, ctx->alloc));
+      CHK_OOM(upb_inttable_insert(&e->iton, num, v, ctx->arena));
     }
   }
 
-  upb_inttable_compact2(&e->iton, ctx->alloc);
+  upb_inttable_compact(&e->iton, ctx->arena);
 }
 
 static void create_msgdef(symtab_addctx *ctx, const char *prefix,
@@ -1794,9 +1776,8 @@ static void create_msgdef(symtab_addctx *ctx, const char *prefix,
   oneofs = google_protobuf_DescriptorProto_oneof_decl(msg_proto, &n_oneof);
   fields = google_protobuf_DescriptorProto_field(msg_proto, &n_field);
 
-  CHK_OOM(upb_inttable_init2(&m->itof, UPB_CTYPE_CONSTPTR, ctx->alloc));
-  CHK_OOM(upb_strtable_init2(&m->ntof, UPB_CTYPE_CONSTPTR, n_oneof + n_field,
-                             ctx->alloc));
+  CHK_OOM(upb_inttable_init(&m->itof, ctx->arena));
+  CHK_OOM(upb_strtable_init(&m->ntof, n_oneof + n_field, ctx->arena));
 
   m->file = ctx->file;
   m->map_entry = false;
@@ -1828,10 +1809,9 @@ static void create_msgdef(symtab_addctx *ctx, const char *prefix,
     create_fielddef(ctx, m->full_name, m, fields[i]);
   }
 
-  assign_msg_indices(ctx, m);
   finalize_oneofs(ctx, m);
   assign_msg_wellknowntype(m);
-  upb_inttable_compact2(&m->itof, ctx->alloc);
+  upb_inttable_compact(&m->itof, ctx->arena);
 
   /* This message is built.  Now build nested messages and enums. */
 
@@ -1943,13 +1923,18 @@ static void build_filedef(
   const upb_strview* strs;
   size_t i, n;
 
-  count_types_in_file(file_proto, file);
+  file->symtab = ctx->symtab;
 
+  /* One pass to count and allocate. */
+  file->msg_count = 0;
+  file->enum_count = 0;
+  file->ext_count = 0;
+  count_types_in_file(file_proto, file);
   file->msgs = symtab_alloc(ctx, sizeof(*file->msgs) * file->msg_count);
   file->enums = symtab_alloc(ctx, sizeof(*file->enums) * file->enum_count);
   file->exts = symtab_alloc(ctx, sizeof(*file->exts) * file->ext_count);
 
-  /* We increment these as defs are added. */
+  /* In the second pass we increment these as defs are added. */
   file->msg_count = 0;
   file->enum_count = 0;
   file->ext_count = 0;
@@ -2060,61 +2045,61 @@ static void build_filedef(
 }
 
 static void remove_filedef(upb_symtab *s, upb_filedef *file) {
-  upb_alloc *alloc = upb_arena_alloc(s->arena);
   int i;
   for (i = 0; i < file->msg_count; i++) {
     const char *name = file->msgs[i].full_name;
-    upb_strtable_remove3(&s->syms, name, strlen(name), NULL, alloc);
+    upb_strtable_remove(&s->syms, name, strlen(name), NULL);
   }
   for (i = 0; i < file->enum_count; i++) {
     const char *name = file->enums[i].full_name;
-    upb_strtable_remove3(&s->syms, name, strlen(name), NULL, alloc);
+    upb_strtable_remove(&s->syms, name, strlen(name), NULL);
   }
   for (i = 0; i < file->ext_count; i++) {
     const char *name = file->exts[i].full_name;
-    upb_strtable_remove3(&s->syms, name, strlen(name), NULL, alloc);
+    upb_strtable_remove(&s->syms, name, strlen(name), NULL);
   }
 }
 
 static const upb_filedef *_upb_symtab_addfile(
     upb_symtab *s, const google_protobuf_FileDescriptorProto *file_proto,
     const upb_msglayout **layouts, upb_status *status) {
-  upb_arena *file_arena = upb_arena_new();
-  upb_filedef *file;
   symtab_addctx ctx;
+  upb_strview name = google_protobuf_FileDescriptorProto_name(file_proto);
 
-  if (!file_arena) return NULL;
-
-  file = upb_arena_malloc(file_arena, sizeof(*file));
-  if (!file) goto done;
+  if (upb_strtable_lookup2(&s->files, name.data, name.size, NULL)) {
+    upb_status_seterrf(status, "duplicate file name (%.*s)",
+                       UPB_STRVIEW_ARGS(name));
+    return NULL;
+  }
 
-  ctx.file = file;
   ctx.symtab = s;
-  ctx.file_arena = file_arena;
-  ctx.alloc = upb_arena_alloc(file_arena);
   ctx.layouts = layouts;
   ctx.status = status;
+  ctx.file = NULL;
+  ctx.arena = upb_arena_new();
 
-  file->msg_count = 0;
-  file->enum_count = 0;
-  file->ext_count = 0;
-  file->symtab = s;
+  if (!ctx.arena) {
+    upb_status_setoom(status);
+    return NULL;
+  }
 
   if (UPB_UNLIKELY(UPB_SETJMP(ctx.err))) {
     UPB_ASSERT(!upb_ok(status));
-    remove_filedef(s, file);
-    file = NULL;
+    if (ctx.file) {
+      remove_filedef(s, ctx.file);
+      ctx.file = NULL;
+    }
   } else {
-    build_filedef(&ctx, file, file_proto);
-    upb_strtable_insert3(&s->files, file->name, strlen(file->name),
-                         upb_value_constptr(file), ctx.alloc);
+    ctx.file = symtab_alloc(&ctx, sizeof(*ctx.file));
+    build_filedef(&ctx, ctx.file, file_proto);
+    upb_strtable_insert(&s->files, name.data, name.size,
+                        upb_value_constptr(ctx.file), ctx.arena);
     UPB_ASSERT(upb_ok(status));
-    upb_arena_fuse(s->arena, file_arena);
+    upb_arena_fuse(s->arena, ctx.arena);
   }
 
-done:
-  upb_arena_free(file_arena);
-  return file;
+  upb_arena_free(ctx.arena);
+  return ctx.file;
 }
 
 const upb_filedef *upb_symtab_addfile(
@@ -2147,7 +2132,8 @@ bool _upb_symtab_loaddefinit(upb_symtab *s, const upb_def_init *init) {
   }
 
   file = google_protobuf_FileDescriptorProto_parse_ex(
-      init->descriptor.data, init->descriptor.size, arena, UPB_DECODE_ALIAS);
+      init->descriptor.data, init->descriptor.size, NULL, UPB_DECODE_ALIAS,
+      arena);
   s->bytes_loaded += init->descriptor.size;
 
   if (!file) {
@@ -2175,4 +2161,8 @@ size_t _upb_symtab_bytesloaded(const upb_symtab *s) {
   return s->bytes_loaded;
 }
 
+upb_arena *_upb_symtab_arena(const upb_symtab *s) {
+  return s->arena;
+}
+
 #undef CHK_OOM
index 7206ec0..24dc8b3 100644 (file)
@@ -1,23 +1,51 @@
 /*
-** Defs are upb's internal representation of the constructs that can appear
-** in a .proto file:
-**
-** - upb_msgdef: describes a "message" construct.
-** - upb_fielddef: describes a message field.
-** - upb_filedef: describes a .proto file and its defs.
-** - upb_enumdef: describes an enum.
-** - upb_oneofdef: describes a oneof.
-**
-** TODO: definitions of services.
-*/
+ * Copyright (c) 2009-2021, Google LLC
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ *     * Redistributions of source code must retain the above copyright
+ *       notice, this list of conditions and the following disclaimer.
+ *     * Redistributions in binary form must reproduce the above copyright
+ *       notice, this list of conditions and the following disclaimer in the
+ *       documentation and/or other materials provided with the distribution.
+ *     * Neither the name of Google LLC nor the
+ *       names of its contributors may be used to endorse or promote products
+ *       derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+ * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ * DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+ * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+ * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+ * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+/*
+ * Defs are upb's internal representation of the constructs that can appear
+ * in a .proto file:
+ *
+ * - upb_msgdef: describes a "message" construct.
+ * - upb_fielddef: describes a message field.
+ * - upb_filedef: describes a .proto file and its defs.
+ * - upb_enumdef: describes an enum.
+ * - upb_oneofdef: describes a oneof.
+ *
+ * TODO: definitions of services.
+ */
 
 #ifndef UPB_DEF_H_
 #define UPB_DEF_H_
 
 #include "upb/upb.h"
-#include "upb/table.int.h"
+#include "upb/table_internal.h"
 #include "google/protobuf/descriptor.upb.h"
 
+/* Must be last. */
 #include "upb/port_def.inc"
 
 #ifdef __cplusplus
@@ -108,9 +136,6 @@ const upb_msgdef *upb_fielddef_msgsubdef(const upb_fielddef *f);
 const upb_enumdef *upb_fielddef_enumsubdef(const upb_fielddef *f);
 const upb_msglayout_field *upb_fielddef_layout(const upb_fielddef *f);
 
-/* Internal only. */
-uint32_t upb_fielddef_selectorbase(const upb_fielddef *f);
-
 /* upb_oneofdef ***************************************************************/
 
 typedef upb_inttable_iter upb_oneof_iter;
@@ -195,10 +220,6 @@ UPB_INLINE const upb_fielddef *upb_msgdef_ntofz(const upb_msgdef *m,
   return upb_msgdef_ntof(m, name, strlen(name));
 }
 
-/* Internal-only. */
-size_t upb_msgdef_selectorcount(const upb_msgdef *m);
-uint32_t upb_msgdef_submsgfieldcount(const upb_msgdef *m);
-
 /* Lookup of either field or oneof by name.  Returns whether either was found.
  * If the return is true, then the found def will be set, and the non-found
  * one set to NULL. */
@@ -295,6 +316,7 @@ const upb_filedef *upb_symtab_addfile(
     upb_symtab *s, const google_protobuf_FileDescriptorProto *file,
     upb_status *status);
 size_t _upb_symtab_bytesloaded(const upb_symtab *s);
+upb_arena *_upb_symtab_arena(const upb_symtab *s);
 
 /* For generated code only: loads a generated descriptor. */
 typedef struct upb_def_init {
index e32da2a..a253879 100644 (file)
@@ -1,3 +1,27 @@
+// Copyright (c) 2009-2021, Google LLC
+// All rights reserved.
+//
+// Redistribution and use in source and binary forms, with or without
+// modification, are permitted provided that the following conditions are met:
+//     * Redistributions of source code must retain the above copyright
+//       notice, this list of conditions and the following disclaimer.
+//     * Redistributions in binary form must reproduce the above copyright
+//       notice, this list of conditions and the following disclaimer in the
+//       documentation and/or other materials provided with the distribution.
+//     * Neither the name of Google LLC nor the
+//       names of its contributors may be used to endorse or promote products
+//       derived from this software without specific prior written permission.
+//
+// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+// WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+// DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+// DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+// (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+// LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+// ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+// SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 
 #ifndef UPB_DEF_HPP_
 #define UPB_DEF_HPP_
 #include <vector>
 
 #include "upb/def.h"
+#include "upb/reflection.h"
 #include "upb/upb.hpp"
 
 namespace upb {
 
+typedef upb_msgval MessageValue;
+
 class EnumDefPtr;
 class MessageDefPtr;
 class OneofDefPtr;
@@ -106,6 +133,8 @@ class FieldDefPtr {
   float default_float() const { return upb_fielddef_defaultfloat(ptr_); }
   double default_double() const { return upb_fielddef_defaultdouble(ptr_); }
 
+  MessageValue default_value() const { return upb_fielddef_default(ptr_); }
+
   // The resulting string is always NULL-terminated.  If non-NULL, the length
   // will be stored in *len.
   const char* default_string(size_t* len) const {
index f73ff09..6c5bfaf 100644 (file)
@@ -1,3 +1,30 @@
+/*
+ * Copyright (c) 2009-2021, Google LLC
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ *     * Redistributions of source code must retain the above copyright
+ *       notice, this list of conditions and the following disclaimer.
+ *     * Redistributions in binary form must reproduce the above copyright
+ *       notice, this list of conditions and the following disclaimer in the
+ *       documentation and/or other materials provided with the distribution.
+ *     * Neither the name of Google LLC nor the
+ *       names of its contributors may be used to endorse or promote products
+ *       derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+ * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ * DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+ * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+ * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+ * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
 /* We encode backwards, to avoid pre-computing lengths (one-pass encode). */
 
 #include "upb/encode.h"
@@ -5,7 +32,7 @@
 #include <setjmp.h>
 #include <string.h>
 
-#include "upb/msg.h"
+#include "upb/msg_internal.h"
 #include "upb/upb.h"
 
 /* Must be last. */
@@ -156,7 +183,7 @@ static void encode_fixedarray(upb_encstate *e, const upb_array *arr,
   }
 }
 
-static void encode_message(upb_encstate *e, const char *msg,
+static void encode_message(upb_encstate *e, const upb_msg *msg,
                            const upb_msglayout *m, size_t *size);
 
 static void encode_scalar(upb_encstate *e, const void *_field_mem,
@@ -248,10 +275,10 @@ static void encode_scalar(upb_encstate *e, const void *_field_mem,
   encode_tag(e, f->number, wire_type);
 }
 
-static void encode_array(upb_encstate *e, const char *field_mem,
+static void encode_array(upb_encstate *e, const upb_msg *msg,
                          const upb_msglayout *m, const upb_msglayout_field *f) {
-  const upb_array *arr = *(const upb_array**)field_mem;
-  bool packed = f->label == _UPB_LABEL_PACKED;
+  const upb_array *arr = *UPB_PTR_AT(msg, f->offset, upb_array*);
+  bool packed = f->mode & _UPB_MODE_IS_PACKED;
   size_t pre_len = e->limit - e->ptr;
 
   if (arr == NULL || arr->len == 0) {
@@ -367,9 +394,9 @@ static void encode_mapentry(upb_encstate *e, uint32_t number,
   encode_tag(e, number, UPB_WIRE_TYPE_DELIMITED);
 }
 
-static void encode_map(upb_encstate *e, const char *field_mem,
+static void encode_map(upb_encstate *e, const upb_msg *msg,
                        const upb_msglayout *m, const upb_msglayout_field *f) {
-  const upb_map *map = *(const upb_map**)field_mem;
+  const upb_map *map = *UPB_PTR_AT(msg, f->offset, const upb_map*);
   const upb_msglayout *layout = m->submsgs[f->submsg_index];
   UPB_ASSERT(layout->field_count == 2);
 
@@ -415,7 +442,7 @@ static void encode_scalarfield(upb_encstate *e, const char *msg,
   encode_scalar(e, msg + f->offset, m, f, skip_empty);
 }
 
-static void encode_message(upb_encstate *e, const char *msg,
+static void encode_message(upb_encstate *e, const upb_msg *msg,
                            const upb_msglayout *m, size_t *size) {
   size_t pre_len = e->limit - e->ptr;
   const upb_msglayout_field *f = &m->fields[m->field_count];
@@ -432,19 +459,25 @@ static void encode_message(upb_encstate *e, const char *msg,
 
   while (f != first) {
     f--;
-    if (_upb_isrepeated(f)) {
-      encode_array(e, msg + f->offset, m, f);
-    } else if (f->label == _UPB_LABEL_MAP) {
-      encode_map(e, msg + f->offset, m, f);
-    } else {
-      encode_scalarfield(e, msg, m, f);
+    switch (_upb_getmode(f)) {
+      case _UPB_MODE_ARRAY:
+        encode_array(e, msg, m, f);
+        break;
+      case _UPB_MODE_MAP:
+        encode_map(e, msg, m, f);
+        break;
+      case _UPB_MODE_SCALAR:
+        encode_scalarfield(e, msg, m, f);
+        break;
+      default:
+        UPB_UNREACHABLE();
     }
   }
 
   *size = (e->limit - e->ptr) - pre_len;
 }
 
-char *upb_encode_ex(const void *msg, const upb_msglayout *m, int options,
+char *upb_encode_ex(const void *msg, const upb_msglayout *l, int options,
                     upb_arena *arena, size_t *size) {
   upb_encstate e;
   unsigned depth = (unsigned)options >> 16;
@@ -462,7 +495,7 @@ char *upb_encode_ex(const void *msg, const upb_msglayout *m, int options,
     *size = 0;
     ret = NULL;
   } else {
-    encode_message(&e, msg, m, size);
+    encode_message(&e, msg, l, size);
     *size = e.limit - e.ptr;
     if (*size == 0) {
       static char ch;
index d3c1dc9..3ea2003 100644 (file)
@@ -1,6 +1,33 @@
 /*
-** upb_encode: parsing into a upb_msg using a upb_msglayout.
-*/
+ * Copyright (c) 2009-2021, Google LLC
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ *     * Redistributions of source code must retain the above copyright
+ *       notice, this list of conditions and the following disclaimer.
+ *     * Redistributions in binary form must reproduce the above copyright
+ *       notice, this list of conditions and the following disclaimer in the
+ *       documentation and/or other materials provided with the distribution.
+ *     * Neither the name of Google LLC nor the
+ *       names of its contributors may be used to endorse or promote products
+ *       derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+ * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ * DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+ * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+ * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+ * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+/*
+ * upb_encode: parsing into a upb_msg using a upb_msglayout.
+ */
 
 #ifndef UPB_ENCODE_H_
 #define UPB_ENCODE_H_
diff --git a/third_party/upb/upb/handlers-inl.h b/third_party/upb/upb/handlers-inl.h
deleted file mode 100644 (file)
index 8f8634b..0000000
+++ /dev/null
@@ -1,923 +0,0 @@
-/*
-** Inline definitions for handlers.h, which are particularly long and a bit
-** tricky.
-*/
-
-#ifndef UPB_HANDLERS_INL_H_
-#define UPB_HANDLERS_INL_H_
-
-#include <limits.h>
-#include <stddef.h>
-#include "upb/handlers.h"
-
-#include "upb/port_def.inc"
-
-#ifdef __cplusplus
-
-/* Type detection and typedefs for integer types.
- * For platforms where there are multiple 32-bit or 64-bit types, we need to be
- * able to enumerate them so we can properly create overloads for all variants.
- *
- * If any platform existed where there were three integer types with the same
- * size, this would have to become more complicated.  For example, short, int,
- * and long could all be 32-bits.  Even more diabolically, short, int, long,
- * and long long could all be 64 bits and still be standard-compliant.
- * However, few platforms are this strange, and it's unlikely that upb will be
- * used on the strangest ones. */
-
-/* Can't count on stdint.h limits like INT32_MAX, because in C++ these are
- * only defined when __STDC_LIMIT_MACROS are defined before the *first* include
- * of stdint.h.  We can't guarantee that someone else didn't include these first
- * without defining __STDC_LIMIT_MACROS. */
-#define UPB_INT32_MAX 0x7fffffffLL
-#define UPB_INT32_MIN (-UPB_INT32_MAX - 1)
-#define UPB_INT64_MAX 0x7fffffffffffffffLL
-#define UPB_INT64_MIN (-UPB_INT64_MAX - 1)
-
-#if INT_MAX == UPB_INT32_MAX && INT_MIN == UPB_INT32_MIN
-#define UPB_INT_IS_32BITS 1
-#endif
-
-#if LONG_MAX == UPB_INT32_MAX && LONG_MIN == UPB_INT32_MIN
-#define UPB_LONG_IS_32BITS 1
-#endif
-
-#if LONG_MAX == UPB_INT64_MAX && LONG_MIN == UPB_INT64_MIN
-#define UPB_LONG_IS_64BITS 1
-#endif
-
-#if LLONG_MAX == UPB_INT64_MAX && LLONG_MIN == UPB_INT64_MIN
-#define UPB_LLONG_IS_64BITS 1
-#endif
-
-/* We use macros instead of typedefs so we can undefine them later and avoid
- * leaking them outside this header file. */
-#if UPB_INT_IS_32BITS
-#define UPB_INT32_T int
-#define UPB_UINT32_T unsigned int
-
-#if UPB_LONG_IS_32BITS
-#define UPB_TWO_32BIT_TYPES 1
-#define UPB_INT32ALT_T long
-#define UPB_UINT32ALT_T unsigned long
-#endif  /* UPB_LONG_IS_32BITS */
-
-#elif UPB_LONG_IS_32BITS  /* && !UPB_INT_IS_32BITS */
-#define UPB_INT32_T long
-#define UPB_UINT32_T unsigned long
-#endif  /* UPB_INT_IS_32BITS */
-
-
-#if UPB_LONG_IS_64BITS
-#define UPB_INT64_T long
-#define UPB_UINT64_T unsigned long
-
-#if UPB_LLONG_IS_64BITS
-#define UPB_TWO_64BIT_TYPES 1
-#define UPB_INT64ALT_T long long
-#define UPB_UINT64ALT_T unsigned long long
-#endif  /* UPB_LLONG_IS_64BITS */
-
-#elif UPB_LLONG_IS_64BITS  /* && !UPB_LONG_IS_64BITS */
-#define UPB_INT64_T long long
-#define UPB_UINT64_T unsigned long long
-#endif  /* UPB_LONG_IS_64BITS */
-
-#undef UPB_INT32_MAX
-#undef UPB_INT32_MIN
-#undef UPB_INT64_MAX
-#undef UPB_INT64_MIN
-#undef UPB_INT_IS_32BITS
-#undef UPB_LONG_IS_32BITS
-#undef UPB_LONG_IS_64BITS
-#undef UPB_LLONG_IS_64BITS
-
-
-namespace upb {
-
-typedef void CleanupFunc(void *ptr);
-
-/* Template to remove "const" from "const T*" and just return "T*".
- *
- * We define a nonsense default because otherwise it will fail to instantiate as
- * a function parameter type even in cases where we don't expect any caller to
- * actually match the overload. */
-class CouldntRemoveConst {};
-template <class T> struct remove_constptr { typedef CouldntRemoveConst type; };
-template <class T> struct remove_constptr<const T *> { typedef T *type; };
-
-/* Template that we use below to remove a template specialization from
- * consideration if it matches a specific type. */
-template <class T, class U> struct disable_if_same { typedef void Type; };
-template <class T> struct disable_if_same<T, T> {};
-
-template <class T> void DeletePointer(void *p) { delete static_cast<T>(p); }
-
-template <class T1, class T2>
-struct FirstUnlessVoidOrBool {
-  typedef T1 value;
-};
-
-template <class T2>
-struct FirstUnlessVoidOrBool<void, T2> {
-  typedef T2 value;
-};
-
-template <class T2>
-struct FirstUnlessVoidOrBool<bool, T2> {
-  typedef T2 value;
-};
-
-template<class T, class U>
-struct is_same {
-  static bool value;
-};
-
-template<class T>
-struct is_same<T, T> {
-  static bool value;
-};
-
-template<class T, class U>
-bool is_same<T, U>::value = false;
-
-template<class T>
-bool is_same<T, T>::value = true;
-
-/* FuncInfo *******************************************************************/
-
-/* Info about the user's original, pre-wrapped function. */
-template <class C, class R = void>
-struct FuncInfo {
-  /* The type of the closure that the function takes (its first param). */
-  typedef C Closure;
-
-  /* The return type. */
-  typedef R Return;
-};
-
-/* Func ***********************************************************************/
-
-/* Func1, Func2, Func3: Template classes representing a function and its
- * signature.
- *
- * Since the function is a template parameter, calling the function can be
- * inlined at compile-time and does not require a function pointer at runtime.
- * These functions are not bound to a handler data so have no data or cleanup
- * handler. */
-struct UnboundFunc {
-  CleanupFunc *GetCleanup() { return nullptr; }
-  void *GetData() { return nullptr; }
-};
-
-template <class R, class P1, R F(P1), class I>
-struct Func1 : public UnboundFunc {
-  typedef R Return;
-  typedef I FuncInfo;
-  static R Call(P1 p1) { return F(p1); }
-};
-
-template <class R, class P1, class P2, R F(P1, P2), class I>
-struct Func2 : public UnboundFunc {
-  typedef R Return;
-  typedef I FuncInfo;
-  static R Call(P1 p1, P2 p2) { return F(p1, p2); }
-};
-
-template <class R, class P1, class P2, class P3, R F(P1, P2, P3), class I>
-struct Func3 : public UnboundFunc {
-  typedef R Return;
-  typedef I FuncInfo;
-  static R Call(P1 p1, P2 p2, P3 p3) { return F(p1, p2, p3); }
-};
-
-template <class R, class P1, class P2, class P3, class P4, R F(P1, P2, P3, P4),
-          class I>
-struct Func4 : public UnboundFunc {
-  typedef R Return;
-  typedef I FuncInfo;
-  static R Call(P1 p1, P2 p2, P3 p3, P4 p4) { return F(p1, p2, p3, p4); }
-};
-
-template <class R, class P1, class P2, class P3, class P4, class P5,
-          R F(P1, P2, P3, P4, P5), class I>
-struct Func5 : public UnboundFunc {
-  typedef R Return;
-  typedef I FuncInfo;
-  static R Call(P1 p1, P2 p2, P3 p3, P4 p4, P5 p5) {
-    return F(p1, p2, p3, p4, p5);
-  }
-};
-
-/* BoundFunc ******************************************************************/
-
-/* BoundFunc2, BoundFunc3: Like Func2/Func3 except also contains a value that
- * shall be bound to the function's second parameter.
- * 
- * Note that the second parameter is a const pointer, but our stored bound value
- * is non-const so we can free it when the handlers are destroyed. */
-template <class T>
-struct BoundFunc {
-  typedef typename remove_constptr<T>::type MutableP2;
-  explicit BoundFunc(MutableP2 data_) : data(data_) {}
-  CleanupFunc *GetCleanup() { return &DeletePointer<MutableP2>; }
-  MutableP2 GetData() { return data; }
-  MutableP2 data;
-};
-
-template <class R, class P1, class P2, R F(P1, P2), class I>
-struct BoundFunc2 : public BoundFunc<P2> {
-  typedef BoundFunc<P2> Base;
-  typedef I FuncInfo;
-  explicit BoundFunc2(typename Base::MutableP2 arg) : Base(arg) {}
-};
-
-template <class R, class P1, class P2, class P3, R F(P1, P2, P3), class I>
-struct BoundFunc3 : public BoundFunc<P2> {
-  typedef BoundFunc<P2> Base;
-  typedef I FuncInfo;
-  explicit BoundFunc3(typename Base::MutableP2 arg) : Base(arg) {}
-};
-
-template <class R, class P1, class P2, class P3, class P4, R F(P1, P2, P3, P4),
-          class I>
-struct BoundFunc4 : public BoundFunc<P2> {
-  typedef BoundFunc<P2> Base;
-  typedef I FuncInfo;
-  explicit BoundFunc4(typename Base::MutableP2 arg) : Base(arg) {}
-};
-
-template <class R, class P1, class P2, class P3, class P4, class P5,
-          R F(P1, P2, P3, P4, P5), class I>
-struct BoundFunc5 : public BoundFunc<P2> {
-  typedef BoundFunc<P2> Base;
-  typedef I FuncInfo;
-  explicit BoundFunc5(typename Base::MutableP2 arg) : Base(arg) {}
-};
-
-/* FuncSig ********************************************************************/
-
-/* FuncSig1, FuncSig2, FuncSig3: template classes reflecting a function
- * *signature*, but without a specific function attached.
- *
- * These classes contain member functions that can be invoked with a
- * specific function to return a Func/BoundFunc class. */
-template <class R, class P1>
-struct FuncSig1 {
-  template <R F(P1)>
-  Func1<R, P1, F, FuncInfo<P1, R> > GetFunc() {
-    return Func1<R, P1, F, FuncInfo<P1, R> >();
-  }
-};
-
-template <class R, class P1, class P2>
-struct FuncSig2 {
-  template <R F(P1, P2)>
-  Func2<R, P1, P2, F, FuncInfo<P1, R> > GetFunc() {
-    return Func2<R, P1, P2, F, FuncInfo<P1, R> >();
-  }
-
-  template <R F(P1, P2)>
-  BoundFunc2<R, P1, P2, F, FuncInfo<P1, R> > GetFunc(
-      typename remove_constptr<P2>::type param2) {
-    return BoundFunc2<R, P1, P2, F, FuncInfo<P1, R> >(param2);
-  }
-};
-
-template <class R, class P1, class P2, class P3>
-struct FuncSig3 {
-  template <R F(P1, P2, P3)>
-  Func3<R, P1, P2, P3, F, FuncInfo<P1, R> > GetFunc() {
-    return Func3<R, P1, P2, P3, F, FuncInfo<P1, R> >();
-  }
-
-  template <R F(P1, P2, P3)>
-  BoundFunc3<R, P1, P2, P3, F, FuncInfo<P1, R> > GetFunc(
-      typename remove_constptr<P2>::type param2) {
-    return BoundFunc3<R, P1, P2, P3, F, FuncInfo<P1, R> >(param2);
-  }
-};
-
-template <class R, class P1, class P2, class P3, class P4>
-struct FuncSig4 {
-  template <R F(P1, P2, P3, P4)>
-  Func4<R, P1, P2, P3, P4, F, FuncInfo<P1, R> > GetFunc() {
-    return Func4<R, P1, P2, P3, P4, F, FuncInfo<P1, R> >();
-  }
-
-  template <R F(P1, P2, P3, P4)>
-  BoundFunc4<R, P1, P2, P3, P4, F, FuncInfo<P1, R> > GetFunc(
-      typename remove_constptr<P2>::type param2) {
-    return BoundFunc4<R, P1, P2, P3, P4, F, FuncInfo<P1, R> >(param2);
-  }
-};
-
-template <class R, class P1, class P2, class P3, class P4, class P5>
-struct FuncSig5 {
-  template <R F(P1, P2, P3, P4, P5)>
-  Func5<R, P1, P2, P3, P4, P5, F, FuncInfo<P1, R> > GetFunc() {
-    return Func5<R, P1, P2, P3, P4, P5, F, FuncInfo<P1, R> >();
-  }
-
-  template <R F(P1, P2, P3, P4, P5)>
-  BoundFunc5<R, P1, P2, P3, P4, P5, F, FuncInfo<P1, R> > GetFunc(
-      typename remove_constptr<P2>::type param2) {
-    return BoundFunc5<R, P1, P2, P3, P4, P5, F, FuncInfo<P1, R> >(param2);
-  }
-};
-
-/* Overloaded template function that can construct the appropriate FuncSig*
- * class given a function pointer by deducing the template parameters. */
-template <class R, class P1>
-inline FuncSig1<R, P1> MatchFunc(R (*f)(P1)) {
-  UPB_UNUSED(f);  /* Only used for template parameter deduction. */
-  return FuncSig1<R, P1>();
-}
-
-template <class R, class P1, class P2>
-inline FuncSig2<R, P1, P2> MatchFunc(R (*f)(P1, P2)) {
-  UPB_UNUSED(f);  /* Only used for template parameter deduction. */
-  return FuncSig2<R, P1, P2>();
-}
-
-template <class R, class P1, class P2, class P3>
-inline FuncSig3<R, P1, P2, P3> MatchFunc(R (*f)(P1, P2, P3)) {
-  UPB_UNUSED(f);  /* Only used for template parameter deduction. */
-  return FuncSig3<R, P1, P2, P3>();
-}
-
-template <class R, class P1, class P2, class P3, class P4>
-inline FuncSig4<R, P1, P2, P3, P4> MatchFunc(R (*f)(P1, P2, P3, P4)) {
-  UPB_UNUSED(f);  /* Only used for template parameter deduction. */
-  return FuncSig4<R, P1, P2, P3, P4>();
-}
-
-template <class R, class P1, class P2, class P3, class P4, class P5>
-inline FuncSig5<R, P1, P2, P3, P4, P5> MatchFunc(R (*f)(P1, P2, P3, P4, P5)) {
-  UPB_UNUSED(f);  /* Only used for template parameter deduction. */
-  return FuncSig5<R, P1, P2, P3, P4, P5>();
-}
-
-/* MethodSig ******************************************************************/
-
-/* CallMethod*: a function template that calls a given method. */
-template <class R, class C, R (C::*F)()>
-R CallMethod0(C *obj) {
-  return ((*obj).*F)();
-}
-
-template <class R, class C, class P1, R (C::*F)(P1)>
-R CallMethod1(C *obj, P1 arg1) {
-  return ((*obj).*F)(arg1);
-}
-
-template <class R, class C, class P1, class P2, R (C::*F)(P1, P2)>
-R CallMethod2(C *obj, P1 arg1, P2 arg2) {
-  return ((*obj).*F)(arg1, arg2);
-}
-
-template <class R, class C, class P1, class P2, class P3, R (C::*F)(P1, P2, P3)>
-R CallMethod3(C *obj, P1 arg1, P2 arg2, P3 arg3) {
-  return ((*obj).*F)(arg1, arg2, arg3);
-}
-
-template <class R, class C, class P1, class P2, class P3, class P4,
-          R (C::*F)(P1, P2, P3, P4)>
-R CallMethod4(C *obj, P1 arg1, P2 arg2, P3 arg3, P4 arg4) {
-  return ((*obj).*F)(arg1, arg2, arg3, arg4);
-}
-
-/* MethodSig: like FuncSig, but for member functions.
- *
- * GetFunc() returns a normal FuncN object, so after calling GetFunc() no
- * more logic is required to special-case methods. */
-template <class R, class C>
-struct MethodSig0 {
-  template <R (C::*F)()>
-  Func1<R, C *, CallMethod0<R, C, F>, FuncInfo<C *, R> > GetFunc() {
-    return Func1<R, C *, CallMethod0<R, C, F>, FuncInfo<C *, R> >();
-  }
-};
-
-template <class R, class C, class P1>
-struct MethodSig1 {
-  template <R (C::*F)(P1)>
-  Func2<R, C *, P1, CallMethod1<R, C, P1, F>, FuncInfo<C *, R> > GetFunc() {
-    return Func2<R, C *, P1, CallMethod1<R, C, P1, F>, FuncInfo<C *, R> >();
-  }
-
-  template <R (C::*F)(P1)>
-  BoundFunc2<R, C *, P1, CallMethod1<R, C, P1, F>, FuncInfo<C *, R> > GetFunc(
-      typename remove_constptr<P1>::type param1) {
-    return BoundFunc2<R, C *, P1, CallMethod1<R, C, P1, F>, FuncInfo<C *, R> >(
-        param1);
-  }
-};
-
-template <class R, class C, class P1, class P2>
-struct MethodSig2 {
-  template <R (C::*F)(P1, P2)>
-  Func3<R, C *, P1, P2, CallMethod2<R, C, P1, P2, F>, FuncInfo<C *, R> >
-  GetFunc() {
-    return Func3<R, C *, P1, P2, CallMethod2<R, C, P1, P2, F>,
-                 FuncInfo<C *, R> >();
-  }
-
-  template <R (C::*F)(P1, P2)>
-  BoundFunc3<R, C *, P1, P2, CallMethod2<R, C, P1, P2, F>, FuncInfo<C *, R> >
-  GetFunc(typename remove_constptr<P1>::type param1) {
-    return BoundFunc3<R, C *, P1, P2, CallMethod2<R, C, P1, P2, F>,
-                      FuncInfo<C *, R> >(param1);
-  }
-};
-
-template <class R, class C, class P1, class P2, class P3>
-struct MethodSig3 {
-  template <R (C::*F)(P1, P2, P3)>
-  Func4<R, C *, P1, P2, P3, CallMethod3<R, C, P1, P2, P3, F>, FuncInfo<C *, R> >
-  GetFunc() {
-    return Func4<R, C *, P1, P2, P3, CallMethod3<R, C, P1, P2, P3, F>,
-                 FuncInfo<C *, R> >();
-  }
-
-  template <R (C::*F)(P1, P2, P3)>
-  BoundFunc4<R, C *, P1, P2, P3, CallMethod3<R, C, P1, P2, P3, F>,
-             FuncInfo<C *, R> >
-  GetFunc(typename remove_constptr<P1>::type param1) {
-    return BoundFunc4<R, C *, P1, P2, P3, CallMethod3<R, C, P1, P2, P3, F>,
-                      FuncInfo<C *, R> >(param1);
-  }
-};
-
-template <class R, class C, class P1, class P2, class P3, class P4>
-struct MethodSig4 {
-  template <R (C::*F)(P1, P2, P3, P4)>
-  Func5<R, C *, P1, P2, P3, P4, CallMethod4<R, C, P1, P2, P3, P4, F>,
-        FuncInfo<C *, R> >
-  GetFunc() {
-    return Func5<R, C *, P1, P2, P3, P4, CallMethod4<R, C, P1, P2, P3, P4, F>,
-                 FuncInfo<C *, R> >();
-  }
-
-  template <R (C::*F)(P1, P2, P3, P4)>
-  BoundFunc5<R, C *, P1, P2, P3, P4, CallMethod4<R, C, P1, P2, P3, P4, F>,
-             FuncInfo<C *, R> >
-  GetFunc(typename remove_constptr<P1>::type param1) {
-    return BoundFunc5<R, C *, P1, P2, P3, P4,
-                      CallMethod4<R, C, P1, P2, P3, P4, F>, FuncInfo<C *, R> >(
-        param1);
-  }
-};
-
-template <class R, class C>
-inline MethodSig0<R, C> MatchFunc(R (C::*f)()) {
-  UPB_UNUSED(f);  /* Only used for template parameter deduction. */
-  return MethodSig0<R, C>();
-}
-
-template <class R, class C, class P1>
-inline MethodSig1<R, C, P1> MatchFunc(R (C::*f)(P1)) {
-  UPB_UNUSED(f);  /* Only used for template parameter deduction. */
-  return MethodSig1<R, C, P1>();
-}
-
-template <class R, class C, class P1, class P2>
-inline MethodSig2<R, C, P1, P2> MatchFunc(R (C::*f)(P1, P2)) {
-  UPB_UNUSED(f);  /* Only used for template parameter deduction. */
-  return MethodSig2<R, C, P1, P2>();
-}
-
-template <class R, class C, class P1, class P2, class P3>
-inline MethodSig3<R, C, P1, P2, P3> MatchFunc(R (C::*f)(P1, P2, P3)) {
-  UPB_UNUSED(f);  /* Only used for template parameter deduction. */
-  return MethodSig3<R, C, P1, P2, P3>();
-}
-
-template <class R, class C, class P1, class P2, class P3, class P4>
-inline MethodSig4<R, C, P1, P2, P3, P4> MatchFunc(R (C::*f)(P1, P2, P3, P4)) {
-  UPB_UNUSED(f);  /* Only used for template parameter deduction. */
-  return MethodSig4<R, C, P1, P2, P3, P4>();
-}
-
-/* MaybeWrapReturn ************************************************************/
-
-/* Template class that attempts to wrap the return value of the function so it
- * matches the expected type.  There are two main adjustments it may make:
- *
- *   1. If the function returns void, make it return the expected type and with
- *      a value that always indicates success.
- *   2. If the function returns bool, make it return the expected type with a
- *      value that indicates success or failure.
- *
- * The "expected type" for return is:
- *   1. void* for start handlers.  If the closure parameter has a different type
- *      we will cast it to void* for the return in the success case.
- *   2. size_t for string buffer handlers.
- *   3. bool for everything else. */
-
-/* Template parameters are FuncN type and desired return type. */
-template <class F, class R, class Enable = void>
-struct MaybeWrapReturn;
-
-/* If the return type matches, return the given function unwrapped. */
-template <class F>
-struct MaybeWrapReturn<F, typename F::Return> {
-  typedef F Func;
-};
-
-/* Function wrapper that munges the return value from void to (bool)true. */
-template <class P1, class P2, void F(P1, P2)>
-bool ReturnTrue2(P1 p1, P2 p2) {
-  F(p1, p2);
-  return true;
-}
-
-template <class P1, class P2, class P3, void F(P1, P2, P3)>
-bool ReturnTrue3(P1 p1, P2 p2, P3 p3) {
-  F(p1, p2, p3);
-  return true;
-}
-
-/* Function wrapper that munges the return value from void to (void*)arg1  */
-template <class P1, class P2, void F(P1, P2)>
-void *ReturnClosure2(P1 p1, P2 p2) {
-  F(p1, p2);
-  return p1;
-}
-
-template <class P1, class P2, class P3, void F(P1, P2, P3)>
-void *ReturnClosure3(P1 p1, P2 p2, P3 p3) {
-  F(p1, p2, p3);
-  return p1;
-}
-
-/* Function wrapper that munges the return value from R to void*. */
-template <class R, class P1, class P2, R F(P1, P2)>
-void *CastReturnToVoidPtr2(P1 p1, P2 p2) {
-  return F(p1, p2);
-}
-
-template <class R, class P1, class P2, class P3, R F(P1, P2, P3)>
-void *CastReturnToVoidPtr3(P1 p1, P2 p2, P3 p3) {
-  return F(p1, p2, p3);
-}
-
-/* Function wrapper that munges the return value from bool to void*. */
-template <class P1, class P2, bool F(P1, P2)>
-void *ReturnClosureOrBreak2(P1 p1, P2 p2) {
-  return F(p1, p2) ? p1 : UPB_BREAK;
-}
-
-template <class P1, class P2, class P3, bool F(P1, P2, P3)>
-void *ReturnClosureOrBreak3(P1 p1, P2 p2, P3 p3) {
-  return F(p1, p2, p3) ? p1 : UPB_BREAK;
-}
-
-/* For the string callback, which takes five params, returns the size param. */
-template <class P1, class P2,
-          void F(P1, P2, const char *, size_t, const upb_bufhandle *)>
-size_t ReturnStringLen(P1 p1, P2 p2, const char *p3, size_t p4,
-                       const upb_bufhandle *p5) {
-  F(p1, p2, p3, p4, p5);
-  return p4;
-}
-
-/* For the string callback, which takes five params, returns the size param or
- * zero. */
-template <class P1, class P2,
-          bool F(P1, P2, const char *, size_t, const upb_bufhandle *)>
-size_t ReturnNOr0(P1 p1, P2 p2, const char *p3, size_t p4,
-                  const upb_bufhandle *p5) {
-  return F(p1, p2, p3, p4, p5) ? p4 : 0;
-}
-
-/* If we have a function returning void but want a function returning bool, wrap
- * it in a function that returns true. */
-template <class P1, class P2, void F(P1, P2), class I>
-struct MaybeWrapReturn<Func2<void, P1, P2, F, I>, bool> {
-  typedef Func2<bool, P1, P2, ReturnTrue2<P1, P2, F>, I> Func;
-};
-
-template <class P1, class P2, class P3, void F(P1, P2, P3), class I>
-struct MaybeWrapReturn<Func3<void, P1, P2, P3, F, I>, bool> {
-  typedef Func3<bool, P1, P2, P3, ReturnTrue3<P1, P2, P3, F>, I> Func;
-};
-
-/* If our function returns void but we want one returning void*, wrap it in a
- * function that returns the first argument. */
-template <class P1, class P2, void F(P1, P2), class I>
-struct MaybeWrapReturn<Func2<void, P1, P2, F, I>, void *> {
-  typedef Func2<void *, P1, P2, ReturnClosure2<P1, P2, F>, I> Func;
-};
-
-template <class P1, class P2, class P3, void F(P1, P2, P3), class I>
-struct MaybeWrapReturn<Func3<void, P1, P2, P3, F, I>, void *> {
-  typedef Func3<void *, P1, P2, P3, ReturnClosure3<P1, P2, P3, F>, I> Func;
-};
-
-/* If our function returns R* but we want one returning void*, wrap it in a
- * function that casts to void*. */
-template <class R, class P1, class P2, R *F(P1, P2), class I>
-struct MaybeWrapReturn<Func2<R *, P1, P2, F, I>, void *,
-                       typename disable_if_same<R *, void *>::Type> {
-  typedef Func2<void *, P1, P2, CastReturnToVoidPtr2<R *, P1, P2, F>, I> Func;
-};
-
-template <class R, class P1, class P2, class P3, R *F(P1, P2, P3), class I>
-struct MaybeWrapReturn<Func3<R *, P1, P2, P3, F, I>, void *,
-                       typename disable_if_same<R *, void *>::Type> {
-  typedef Func3<void *, P1, P2, P3, CastReturnToVoidPtr3<R *, P1, P2, P3, F>, I>
-      Func;
-};
-
-/* If our function returns bool but we want one returning void*, wrap it in a
- * function that returns either the first param or UPB_BREAK. */
-template <class P1, class P2, bool F(P1, P2), class I>
-struct MaybeWrapReturn<Func2<bool, P1, P2, F, I>, void *> {
-  typedef Func2<void *, P1, P2, ReturnClosureOrBreak2<P1, P2, F>, I> Func;
-};
-
-template <class P1, class P2, class P3, bool F(P1, P2, P3), class I>
-struct MaybeWrapReturn<Func3<bool, P1, P2, P3, F, I>, void *> {
-  typedef Func3<void *, P1, P2, P3, ReturnClosureOrBreak3<P1, P2, P3, F>, I>
-      Func;
-};
-
-/* If our function returns void but we want one returning size_t, wrap it in a
- * function that returns the size argument. */
-template <class P1, class P2,
-          void F(P1, P2, const char *, size_t, const upb_bufhandle *), class I>
-struct MaybeWrapReturn<
-    Func5<void, P1, P2, const char *, size_t, const upb_bufhandle *, F, I>,
-          size_t> {
-  typedef Func5<size_t, P1, P2, const char *, size_t, const upb_bufhandle *,
-                ReturnStringLen<P1, P2, F>, I> Func;
-};
-
-/* If our function returns bool but we want one returning size_t, wrap it in a
- * function that returns either 0 or the buf size. */
-template <class P1, class P2,
-          bool F(P1, P2, const char *, size_t, const upb_bufhandle *), class I>
-struct MaybeWrapReturn<
-    Func5<bool, P1, P2, const char *, size_t, const upb_bufhandle *, F, I>,
-    size_t> {
-  typedef Func5<size_t, P1, P2, const char *, size_t, const upb_bufhandle *,
-                ReturnNOr0<P1, P2, F>, I> Func;
-};
-
-/* ConvertParams **************************************************************/
-
-/* Template class that converts the function parameters if necessary, and
- * ignores the HandlerData parameter if appropriate.
- *
- * Template parameter is the are FuncN function type. */
-template <class F, class T>
-struct ConvertParams;
-
-/* Function that discards the handler data parameter. */
-template <class R, class P1, R F(P1)>
-R IgnoreHandlerData2(void *p1, const void *hd) {
-  UPB_UNUSED(hd);
-  return F(static_cast<P1>(p1));
-}
-
-template <class R, class P1, class P2Wrapper, class P2Wrapped,
-          R F(P1, P2Wrapped)>
-R IgnoreHandlerData3(void *p1, const void *hd, P2Wrapper p2) {
-  UPB_UNUSED(hd);
-  return F(static_cast<P1>(p1), p2);
-}
-
-template <class R, class P1, class P2, class P3, R F(P1, P2, P3)>
-R IgnoreHandlerData4(void *p1, const void *hd, P2 p2, P3 p3) {
-  UPB_UNUSED(hd);
-  return F(static_cast<P1>(p1), p2, p3);
-}
-
-template <class R, class P1, class P2, class P3, class P4, R F(P1, P2, P3, P4)>
-R IgnoreHandlerData5(void *p1, const void *hd, P2 p2, P3 p3, P4 p4) {
-  UPB_UNUSED(hd);
-  return F(static_cast<P1>(p1), p2, p3, p4);
-}
-
-template <class R, class P1, R F(P1, const char*, size_t)>
-R IgnoreHandlerDataIgnoreHandle(void *p1, const void *hd, const char *p2,
-                                size_t p3, const upb_bufhandle *handle) {
-  UPB_UNUSED(hd);
-  UPB_UNUSED(handle);
-  return F(static_cast<P1>(p1), p2, p3);
-}
-
-/* Function that casts the handler data parameter. */
-template <class R, class P1, class P2, R F(P1, P2)>
-R CastHandlerData2(void *c, const void *hd) {
-  return F(static_cast<P1>(c), static_cast<P2>(hd));
-}
-
-template <class R, class P1, class P2, class P3Wrapper, class P3Wrapped,
-          R F(P1, P2, P3Wrapped)>
-R CastHandlerData3(void *c, const void *hd, P3Wrapper p3) {
-  return F(static_cast<P1>(c), static_cast<P2>(hd), p3);
-}
-
-template <class R, class P1, class P2, class P3, class P4, class P5,
-          R F(P1, P2, P3, P4, P5)>
-R CastHandlerData5(void *c, const void *hd, P3 p3, P4 p4, P5 p5) {
-  return F(static_cast<P1>(c), static_cast<P2>(hd), p3, p4, p5);
-}
-
-template <class R, class P1, class P2, R F(P1, P2, const char *, size_t)>
-R CastHandlerDataIgnoreHandle(void *c, const void *hd, const char *p3,
-                              size_t p4, const upb_bufhandle *handle) {
-  UPB_UNUSED(handle);
-  return F(static_cast<P1>(c), static_cast<P2>(hd), p3, p4);
-}
-
-/* For unbound functions, ignore the handler data. */
-template <class R, class P1, R F(P1), class I, class T>
-struct ConvertParams<Func1<R, P1, F, I>, T> {
-  typedef Func2<R, void *, const void *, IgnoreHandlerData2<R, P1, F>, I> Func;
-};
-
-template <class R, class P1, class P2, R F(P1, P2), class I,
-          class R2, class P1_2, class P2_2, class P3_2>
-struct ConvertParams<Func2<R, P1, P2, F, I>,
-                     R2 (*)(P1_2, P2_2, P3_2)> {
-  typedef Func3<R, void *, const void *, P3_2,
-                IgnoreHandlerData3<R, P1, P3_2, P2, F>, I> Func;
-};
-
-/* For StringBuffer only; this ignores both the handler data and the
- * upb_bufhandle. */
-template <class R, class P1, R F(P1, const char *, size_t), class I, class T>
-struct ConvertParams<Func3<R, P1, const char *, size_t, F, I>, T> {
-  typedef Func5<R, void *, const void *, const char *, size_t,
-                const upb_bufhandle *, IgnoreHandlerDataIgnoreHandle<R, P1, F>,
-                I> Func;
-};
-
-template <class R, class P1, class P2, class P3, class P4, R F(P1, P2, P3, P4),
-          class I, class T>
-struct ConvertParams<Func4<R, P1, P2, P3, P4, F, I>, T> {
-  typedef Func5<R, void *, const void *, P2, P3, P4,
-                IgnoreHandlerData5<R, P1, P2, P3, P4, F>, I> Func;
-};
-
-/* For bound functions, cast the handler data. */
-template <class R, class P1, class P2, R F(P1, P2), class I, class T>
-struct ConvertParams<BoundFunc2<R, P1, P2, F, I>, T> {
-  typedef Func2<R, void *, const void *, CastHandlerData2<R, P1, P2, F>, I>
-      Func;
-};
-
-template <class R, class P1, class P2, class P3, R F(P1, P2, P3), class I,
-          class R2, class P1_2, class P2_2, class P3_2>
-struct ConvertParams<BoundFunc3<R, P1, P2, P3, F, I>,
-                     R2 (*)(P1_2, P2_2, P3_2)> {
-  typedef Func3<R, void *, const void *, P3_2,
-                CastHandlerData3<R, P1, P2, P3_2, P3, F>, I> Func;
-};
-
-/* For StringBuffer only; this ignores the upb_bufhandle. */
-template <class R, class P1, class P2, R F(P1, P2, const char *, size_t),
-          class I, class T>
-struct ConvertParams<BoundFunc4<R, P1, P2, const char *, size_t, F, I>, T> {
-  typedef Func5<R, void *, const void *, const char *, size_t,
-                const upb_bufhandle *,
-                CastHandlerDataIgnoreHandle<R, P1, P2, F>, I>
-      Func;
-};
-
-template <class R, class P1, class P2, class P3, class P4, class P5,
-          R F(P1, P2, P3, P4, P5), class I, class T>
-struct ConvertParams<BoundFunc5<R, P1, P2, P3, P4, P5, F, I>, T> {
-  typedef Func5<R, void *, const void *, P3, P4, P5,
-                CastHandlerData5<R, P1, P2, P3, P4, P5, F>, I> Func;
-};
-
-/* utype/ltype are upper/lower-case, ctype is canonical C type, vtype is
- * variant C type. */
-#define TYPE_METHODS(utype, ltype, ctype, vtype)                      \
-  template <>                                                         \
-  struct CanonicalType<vtype> {                                       \
-    typedef ctype Type;                                               \
-  };                                                                  \
-  template <>                                                         \
-  inline bool HandlersPtr::SetValueHandler<vtype>(                    \
-      FieldDefPtr f, const HandlersPtr::utype##Handler &handler) {    \
-    handler.AddCleanup(ptr());                                        \
-    return upb_handlers_set##ltype(ptr(), f.ptr(), handler.handler(), \
-                                   &handler.attr());                  \
-  }
-
-TYPE_METHODS(Double, double, double,   double)
-TYPE_METHODS(Float,  float,  float,    float)
-TYPE_METHODS(UInt64, uint64, uint64_t, UPB_UINT64_T)
-TYPE_METHODS(UInt32, uint32, uint32_t, UPB_UINT32_T)
-TYPE_METHODS(Int64,  int64,  int64_t,  UPB_INT64_T)
-TYPE_METHODS(Int32,  int32,  int32_t,  UPB_INT32_T)
-TYPE_METHODS(Bool,   bool,   bool,     bool)
-
-#ifdef UPB_TWO_32BIT_TYPES
-TYPE_METHODS(Int32,  int32,  int32_t,  UPB_INT32ALT_T)
-TYPE_METHODS(UInt32, uint32, uint32_t, UPB_UINT32ALT_T)
-#endif
-
-#ifdef UPB_TWO_64BIT_TYPES
-TYPE_METHODS(Int64,  int64,  int64_t,  UPB_INT64ALT_T)
-TYPE_METHODS(UInt64, uint64, uint64_t, UPB_UINT64ALT_T)
-#endif
-#undef TYPE_METHODS
-
-template <> struct CanonicalType<Status*> {
-  typedef Status* Type;
-};
-
-template <class F> struct ReturnOf;
-
-template <class R, class P1, class P2>
-struct ReturnOf<R (*)(P1, P2)> {
-  typedef R Return;
-};
-
-template <class R, class P1, class P2, class P3>
-struct ReturnOf<R (*)(P1, P2, P3)> {
-  typedef R Return;
-};
-
-template <class R, class P1, class P2, class P3, class P4>
-struct ReturnOf<R (*)(P1, P2, P3, P4)> {
-  typedef R Return;
-};
-
-template <class R, class P1, class P2, class P3, class P4, class P5>
-struct ReturnOf<R (*)(P1, P2, P3, P4, P5)> {
-  typedef R Return;
-};
-
-
-template <class T>
-template <class F>
-inline Handler<T>::Handler(F func)
-    : registered_(false),
-      cleanup_data_(func.GetData()),
-      cleanup_func_(func.GetCleanup()) {
-  attr_.handler_data = func.GetData();
-  typedef typename ReturnOf<T>::Return Return;
-  typedef typename ConvertParams<F, T>::Func ConvertedParamsFunc;
-  typedef typename MaybeWrapReturn<ConvertedParamsFunc, Return>::Func
-      ReturnWrappedFunc;
-  handler_ = ReturnWrappedFunc().Call;
-
-  /* Set attributes based on what templates can statically tell us about the
-   * user's function. */
-
-  /* If the original function returns void, then we know that we wrapped it to
-   * always return ok. */
-  bool always_ok = is_same<typename F::FuncInfo::Return, void>::value;
-  attr_.alwaysok = always_ok;
-
-  /* Closure parameter and return type. */
-  attr_.closure_type = UniquePtrForType<typename F::FuncInfo::Closure>();
-
-  /* We use the closure type (from the first parameter) if the return type is
-   * void or bool, since these are the two cases we wrap to return the closure's
-   * type anyway.
-   *
-   * This is all nonsense for non START* handlers, but it doesn't matter because
-   * in that case the value will be ignored. */
-  typedef typename FirstUnlessVoidOrBool<typename F::FuncInfo::Return,
-                                         typename F::FuncInfo::Closure>::value
-      EffectiveReturn;
-  attr_.return_closure_type = UniquePtrForType<EffectiveReturn>();
-}
-
-template <class T>
-inline void Handler<T>::AddCleanup(upb_handlers* h) const {
-  UPB_ASSERT(!registered_);
-  registered_ = true;
-  if (cleanup_func_) {
-    bool ok = upb_handlers_addcleanup(h, cleanup_data_, cleanup_func_);
-    UPB_ASSERT(ok);
-  }
-}
-
-}  /* namespace upb */
-
-#endif  /* __cplusplus */
-
-
-#undef UPB_TWO_32BIT_TYPES
-#undef UPB_TWO_64BIT_TYPES
-#undef UPB_INT32_T
-#undef UPB_UINT32_T
-#undef UPB_INT32ALT_T
-#undef UPB_UINT32ALT_T
-#undef UPB_INT64_T
-#undef UPB_UINT64_T
-#undef UPB_INT64ALT_T
-#undef UPB_UINT64ALT_T
-
-#include "upb/port_undef.inc"
-
-#endif  /* UPB_HANDLERS_INL_H_ */
diff --git a/third_party/upb/upb/handlers.c b/third_party/upb/upb/handlers.c
deleted file mode 100644 (file)
index 4168a4f..0000000
+++ /dev/null
@@ -1,545 +0,0 @@
-/*
-** TODO(haberman): it's unclear whether a lot of the consistency checks should
-** UPB_ASSERT() or return false.
-*/
-
-#include "upb/handlers.h"
-
-#include <string.h>
-
-#include "upb/sink.h"
-
-#include "upb/port_def.inc"
-
-struct upb_handlers {
-  upb_handlercache *cache;
-  const upb_msgdef *msg;
-  const upb_handlers **sub;
-  const void *top_closure_type;
-  upb_handlers_tabent table[1];  /* Dynamically-sized field handler array. */
-};
-
-static void *upb_calloc(upb_arena *arena, size_t size) {
-  void *mem = upb_malloc(upb_arena_alloc(arena), size);
-  if (mem) {
-    memset(mem, 0, size);
-  }
-  return mem;
-}
-
-/* Defined for the sole purpose of having a unique pointer value for
- * UPB_NO_CLOSURE. */
-char _upb_noclosure;
-
-/* Given a selector for a STARTSUBMSG handler, resolves to a pointer to the
- * subhandlers for this submessage field. */
-#define SUBH(h, selector) (h->sub[selector])
-
-/* The selector for a submessage field is the field index. */
-#define SUBH_F(h, f) SUBH(h, upb_fielddef_index(f))
-
-static int32_t trygetsel(upb_handlers *h, const upb_fielddef *f,
-                         upb_handlertype_t type) {
-  upb_selector_t sel;
-  bool ok;
-
-  ok = upb_handlers_getselector(f, type, &sel);
-
-  UPB_ASSERT(upb_handlers_msgdef(h) == upb_fielddef_containingtype(f));
-  UPB_ASSERT(ok);
-
-  return sel;
-}
-
-static upb_selector_t handlers_getsel(upb_handlers *h, const upb_fielddef *f,
-                             upb_handlertype_t type) {
-  int32_t sel = trygetsel(h, f, type);
-  UPB_ASSERT(sel >= 0);
-  return sel;
-}
-
-static const void **returntype(upb_handlers *h, const upb_fielddef *f,
-                               upb_handlertype_t type) {
-  return &h->table[handlers_getsel(h, f, type)].attr.return_closure_type;
-}
-
-static bool doset(upb_handlers *h, int32_t sel, const upb_fielddef *f,
-                  upb_handlertype_t type, upb_func *func,
-                  const upb_handlerattr *attr) {
-  upb_handlerattr set_attr = UPB_HANDLERATTR_INIT;
-  const void *closure_type;
-  const void **context_closure_type;
-
-  UPB_ASSERT(!h->table[sel].func);
-
-  if (attr) {
-    set_attr = *attr;
-  }
-
-  /* Check that the given closure type matches the closure type that has been
-   * established for this context (if any). */
-  closure_type = set_attr.closure_type;
-
-  if (type == UPB_HANDLER_STRING) {
-    context_closure_type = returntype(h, f, UPB_HANDLER_STARTSTR);
-  } else if (f && upb_fielddef_isseq(f) &&
-             type != UPB_HANDLER_STARTSEQ &&
-             type != UPB_HANDLER_ENDSEQ) {
-    context_closure_type = returntype(h, f, UPB_HANDLER_STARTSEQ);
-  } else {
-    context_closure_type = &h->top_closure_type;
-  }
-
-  if (closure_type && *context_closure_type &&
-      closure_type != *context_closure_type) {
-    return false;
-  }
-
-  if (closure_type)
-    *context_closure_type = closure_type;
-
-  /* If this is a STARTSEQ or STARTSTR handler, check that the returned pointer
-   * matches any pre-existing expectations about what type is expected. */
-  if (type == UPB_HANDLER_STARTSEQ || type == UPB_HANDLER_STARTSTR) {
-    const void *return_type = set_attr.return_closure_type;
-    const void *table_return_type = h->table[sel].attr.return_closure_type;
-    if (return_type && table_return_type && return_type != table_return_type) {
-      return false;
-    }
-
-    if (table_return_type && !return_type) {
-      set_attr.return_closure_type = table_return_type;
-    }
-  }
-
-  h->table[sel].func = (upb_func*)func;
-  h->table[sel].attr = set_attr;
-  return true;
-}
-
-/* Returns the effective closure type for this handler (which will propagate
- * from outer frames if this frame has no START* handler).  Not implemented for
- * UPB_HANDLER_STRING at the moment since this is not needed.  Returns NULL is
- * the effective closure type is unspecified (either no handler was registered
- * to specify it or the handler that was registered did not specify the closure
- * type). */
-const void *effective_closure_type(upb_handlers *h, const upb_fielddef *f,
-                                   upb_handlertype_t type) {
-  const void *ret;
-  upb_selector_t sel;
-
-  UPB_ASSERT(type != UPB_HANDLER_STRING);
-  ret = h->top_closure_type;
-
-  if (upb_fielddef_isseq(f) &&
-      type != UPB_HANDLER_STARTSEQ &&
-      type != UPB_HANDLER_ENDSEQ &&
-      h->table[sel = handlers_getsel(h, f, UPB_HANDLER_STARTSEQ)].func) {
-    ret = h->table[sel].attr.return_closure_type;
-  }
-
-  if (type == UPB_HANDLER_STRING &&
-      h->table[sel = handlers_getsel(h, f, UPB_HANDLER_STARTSTR)].func) {
-    ret = h->table[sel].attr.return_closure_type;
-  }
-
-  /* The effective type of the submessage; not used yet.
-   * if (type == SUBMESSAGE &&
-   *     h->table[sel = handlers_getsel(h, f, UPB_HANDLER_STARTSUBMSG)].func) {
-   *   ret = h->table[sel].attr.return_closure_type;
-   * } */
-
-  return ret;
-}
-
-static upb_handlers *upb_handlers_new(const upb_msgdef *md,
-                                      upb_handlercache *cache,
-                                      upb_arena *arena) {
-  int extra;
-  upb_handlers *h;
-
-  extra =
-      (int)(sizeof(upb_handlers_tabent) * (upb_msgdef_selectorcount(md) - 1));
-  h = upb_calloc(arena, sizeof(*h) + extra);
-  if (!h) return NULL;
-
-  h->cache = cache;
-  h->msg = md;
-
-  if (upb_msgdef_submsgfieldcount(md) > 0) {
-    size_t bytes = upb_msgdef_submsgfieldcount(md) * sizeof(*h->sub);
-    h->sub = upb_calloc(arena, bytes);
-    if (!h->sub) return NULL;
-  } else {
-    h->sub = 0;
-  }
-
-  /* calloc() above initialized all handlers to NULL. */
-  return h;
-}
-
-/* Public interface ***********************************************************/
-
-#define SETTER(name, handlerctype, handlertype)                       \
-  bool upb_handlers_set##name(upb_handlers *h, const upb_fielddef *f, \
-                              handlerctype func,                      \
-                              const upb_handlerattr *attr) {          \
-    int32_t sel = trygetsel(h, f, handlertype);                       \
-    return doset(h, sel, f, handlertype, (upb_func *)func, attr);     \
-  }
-
-SETTER(int32,       upb_int32_handlerfunc*,       UPB_HANDLER_INT32)
-SETTER(int64,       upb_int64_handlerfunc*,       UPB_HANDLER_INT64)
-SETTER(uint32,      upb_uint32_handlerfunc*,      UPB_HANDLER_UINT32)
-SETTER(uint64,      upb_uint64_handlerfunc*,      UPB_HANDLER_UINT64)
-SETTER(float,       upb_float_handlerfunc*,       UPB_HANDLER_FLOAT)
-SETTER(double,      upb_double_handlerfunc*,      UPB_HANDLER_DOUBLE)
-SETTER(bool,        upb_bool_handlerfunc*,        UPB_HANDLER_BOOL)
-SETTER(startstr,    upb_startstr_handlerfunc*,    UPB_HANDLER_STARTSTR)
-SETTER(string,      upb_string_handlerfunc*,      UPB_HANDLER_STRING)
-SETTER(endstr,      upb_endfield_handlerfunc*,    UPB_HANDLER_ENDSTR)
-SETTER(startseq,    upb_startfield_handlerfunc*,  UPB_HANDLER_STARTSEQ)
-SETTER(startsubmsg, upb_startfield_handlerfunc*,  UPB_HANDLER_STARTSUBMSG)
-SETTER(endsubmsg,   upb_endfield_handlerfunc*,    UPB_HANDLER_ENDSUBMSG)
-SETTER(endseq,      upb_endfield_handlerfunc*,    UPB_HANDLER_ENDSEQ)
-
-#undef SETTER
-
-bool upb_handlers_setunknown(upb_handlers *h, upb_unknown_handlerfunc *func,
-                             const upb_handlerattr *attr) {
-  return doset(h, UPB_UNKNOWN_SELECTOR, NULL, UPB_HANDLER_INT32,
-               (upb_func *)func, attr);
-}
-
-bool upb_handlers_setstartmsg(upb_handlers *h, upb_startmsg_handlerfunc *func,
-                              const upb_handlerattr *attr) {
-  return doset(h, UPB_STARTMSG_SELECTOR, NULL, UPB_HANDLER_INT32,
-               (upb_func *)func, attr);
-}
-
-bool upb_handlers_setendmsg(upb_handlers *h, upb_endmsg_handlerfunc *func,
-                            const upb_handlerattr *attr) {
-  return doset(h, UPB_ENDMSG_SELECTOR, NULL, UPB_HANDLER_INT32,
-               (upb_func *)func, attr);
-}
-
-bool upb_handlers_setsubhandlers(upb_handlers *h, const upb_fielddef *f,
-                                 const upb_handlers *sub) {
-  UPB_ASSERT(sub);
-  UPB_ASSERT(upb_fielddef_issubmsg(f));
-  if (SUBH_F(h, f)) return false;  /* Can't reset. */
-  if (upb_handlers_msgdef(sub) != upb_fielddef_msgsubdef(f)) {
-    return false;
-  }
-  SUBH_F(h, f) = sub;
-  return true;
-}
-
-const upb_handlers *upb_handlers_getsubhandlers(const upb_handlers *h,
-                                                const upb_fielddef *f) {
-  UPB_ASSERT(upb_fielddef_issubmsg(f));
-  return SUBH_F(h, f);
-}
-
-upb_func *upb_handlers_gethandler(const upb_handlers *h, upb_selector_t s,
-                                  const void **handler_data) {
-  upb_func *ret = (upb_func *)h->table[s].func;
-  if (ret && handler_data) {
-    *handler_data = h->table[s].attr.handler_data;
-  }
-  return ret;
-}
-
-bool upb_handlers_getattr(const upb_handlers *h, upb_selector_t sel,
-                          upb_handlerattr *attr) {
-  if (!upb_handlers_gethandler(h, sel, NULL))
-    return false;
-  *attr = h->table[sel].attr;
-  return true;
-}
-
-const upb_handlers *upb_handlers_getsubhandlers_sel(const upb_handlers *h,
-                                                    upb_selector_t sel) {
-  /* STARTSUBMSG selector in sel is the field's selector base. */
-  return SUBH(h, sel - UPB_STATIC_SELECTOR_COUNT);
-}
-
-const upb_msgdef *upb_handlers_msgdef(const upb_handlers *h) { return h->msg; }
-
-bool upb_handlers_addcleanup(upb_handlers *h, void *p, upb_handlerfree *func) {
-  return upb_handlercache_addcleanup(h->cache, p, func);
-}
-
-upb_handlertype_t upb_handlers_getprimitivehandlertype(const upb_fielddef *f) {
-  switch (upb_fielddef_type(f)) {
-    case UPB_TYPE_INT32:
-    case UPB_TYPE_ENUM: return UPB_HANDLER_INT32;
-    case UPB_TYPE_INT64: return UPB_HANDLER_INT64;
-    case UPB_TYPE_UINT32: return UPB_HANDLER_UINT32;
-    case UPB_TYPE_UINT64: return UPB_HANDLER_UINT64;
-    case UPB_TYPE_FLOAT: return UPB_HANDLER_FLOAT;
-    case UPB_TYPE_DOUBLE: return UPB_HANDLER_DOUBLE;
-    case UPB_TYPE_BOOL: return UPB_HANDLER_BOOL;
-    default: UPB_ASSERT(false); return -1;  /* Invalid input. */
-  }
-}
-
-bool upb_handlers_getselector(const upb_fielddef *f, upb_handlertype_t type,
-                              upb_selector_t *s) {
-  uint32_t selector_base = upb_fielddef_selectorbase(f);
-  switch (type) {
-    case UPB_HANDLER_INT32:
-    case UPB_HANDLER_INT64:
-    case UPB_HANDLER_UINT32:
-    case UPB_HANDLER_UINT64:
-    case UPB_HANDLER_FLOAT:
-    case UPB_HANDLER_DOUBLE:
-    case UPB_HANDLER_BOOL:
-      if (!upb_fielddef_isprimitive(f) ||
-          upb_handlers_getprimitivehandlertype(f) != type)
-        return false;
-      *s = selector_base;
-      break;
-    case UPB_HANDLER_STRING:
-      if (upb_fielddef_isstring(f)) {
-        *s = selector_base;
-      } else if (upb_fielddef_lazy(f)) {
-        *s = selector_base + 3;
-      } else {
-        return false;
-      }
-      break;
-    case UPB_HANDLER_STARTSTR:
-      if (upb_fielddef_isstring(f) || upb_fielddef_lazy(f)) {
-        *s = selector_base + 1;
-      } else {
-        return false;
-      }
-      break;
-    case UPB_HANDLER_ENDSTR:
-      if (upb_fielddef_isstring(f) || upb_fielddef_lazy(f)) {
-        *s = selector_base + 2;
-      } else {
-        return false;
-      }
-      break;
-    case UPB_HANDLER_STARTSEQ:
-      if (!upb_fielddef_isseq(f)) return false;
-      *s = selector_base - 2;
-      break;
-    case UPB_HANDLER_ENDSEQ:
-      if (!upb_fielddef_isseq(f)) return false;
-      *s = selector_base - 1;
-      break;
-    case UPB_HANDLER_STARTSUBMSG:
-      if (!upb_fielddef_issubmsg(f)) return false;
-      /* Selectors for STARTSUBMSG are at the beginning of the table so that the
-       * selector can also be used as an index into the "sub" array of
-       * subhandlers.  The indexes for the two into these two tables are the
-       * same, except that in the handler table the static selectors come first. */
-      *s = upb_fielddef_index(f) + UPB_STATIC_SELECTOR_COUNT;
-      break;
-    case UPB_HANDLER_ENDSUBMSG:
-      if (!upb_fielddef_issubmsg(f)) return false;
-      *s = selector_base;
-      break;
-  }
-  UPB_ASSERT((size_t)*s < upb_msgdef_selectorcount(upb_fielddef_containingtype(f)));
-  return true;
-}
-
-/* upb_handlercache ***********************************************************/
-
-struct upb_handlercache {
-  upb_arena *arena;
-  upb_inttable tab;  /* maps upb_msgdef* -> upb_handlers*. */
-  upb_handlers_callback *callback;
-  const void *closure;
-};
-
-const upb_handlers *upb_handlercache_get(upb_handlercache *c,
-                                         const upb_msgdef *md) {
-  int i, n;
-  upb_value v;
-  upb_handlers *h;
-
-  if (upb_inttable_lookupptr(&c->tab, md, &v)) {
-    return upb_value_getptr(v);
-  }
-
-  h = upb_handlers_new(md, c, c->arena);
-  v = upb_value_ptr(h);
-
-  if (!h) return NULL;
-  if (!upb_inttable_insertptr(&c->tab, md, v)) return NULL;
-
-  c->callback(c->closure, h);
-
-  /* For each submessage field, get or create a handlers object and set it as
-   * the subhandlers. */
-  n = upb_msgdef_fieldcount(md);
-  for (i = 0; i < n; i++) {
-    const upb_fielddef *f = upb_msgdef_field(md, i);
-
-    if (upb_fielddef_issubmsg(f)) {
-      const upb_msgdef *subdef = upb_fielddef_msgsubdef(f);
-      const upb_handlers *sub_mh = upb_handlercache_get(c, subdef);
-
-      if (!sub_mh) return NULL;
-
-      upb_handlers_setsubhandlers(h, f, sub_mh);
-    }
-  }
-
-  return h;
-}
-
-
-upb_handlercache *upb_handlercache_new(upb_handlers_callback *callback,
-                                       const void *closure) {
-  upb_handlercache *cache = upb_gmalloc(sizeof(*cache));
-
-  if (!cache) return NULL;
-
-  cache->arena = upb_arena_new();
-
-  cache->callback = callback;
-  cache->closure = closure;
-
-  if (!upb_inttable_init(&cache->tab, UPB_CTYPE_PTR)) goto oom;
-
-  return cache;
-
-oom:
-  upb_gfree(cache);
-  return NULL;
-}
-
-void upb_handlercache_free(upb_handlercache *cache) {
-  upb_inttable_uninit(&cache->tab);
-  upb_arena_free(cache->arena);
-  upb_gfree(cache);
-}
-
-bool upb_handlercache_addcleanup(upb_handlercache *c, void *p,
-                                 upb_handlerfree *func) {
-  return upb_arena_addcleanup(c->arena, p, func);
-}
-
-/* upb_byteshandler ***********************************************************/
-
-bool upb_byteshandler_setstartstr(upb_byteshandler *h,
-                                  upb_startstr_handlerfunc *func, void *d) {
-  h->table[UPB_STARTSTR_SELECTOR].func = (upb_func*)func;
-  h->table[UPB_STARTSTR_SELECTOR].attr.handler_data = d;
-  return true;
-}
-
-bool upb_byteshandler_setstring(upb_byteshandler *h,
-                                upb_string_handlerfunc *func, void *d) {
-  h->table[UPB_STRING_SELECTOR].func = (upb_func*)func;
-  h->table[UPB_STRING_SELECTOR].attr.handler_data = d;
-  return true;
-}
-
-bool upb_byteshandler_setendstr(upb_byteshandler *h,
-                                upb_endfield_handlerfunc *func, void *d) {
-  h->table[UPB_ENDSTR_SELECTOR].func = (upb_func*)func;
-  h->table[UPB_ENDSTR_SELECTOR].attr.handler_data = d;
-  return true;
-}
-
-/** Handlers for upb_msg ******************************************************/
-
-typedef struct {
-  size_t offset;
-  int32_t hasbit;
-} upb_msg_handlerdata;
-
-/* Fallback implementation if the handler is not specialized by the producer. */
-#define MSG_WRITER(type, ctype)                                               \
-  bool upb_msg_set ## type (void *c, const void *hd, ctype val) {             \
-    uint8_t *m = c;                                                           \
-    const upb_msg_handlerdata *d = hd;                                        \
-    if (d->hasbit > 0)                                                        \
-      *(uint8_t*)&m[d->hasbit / 8] |= 1 << (d->hasbit % 8);                   \
-    *(ctype*)&m[d->offset] = val;                                             \
-    return true;                                                              \
-  }                                                                           \
-
-MSG_WRITER(double, double)
-MSG_WRITER(float,  float)
-MSG_WRITER(int32,  int32_t)
-MSG_WRITER(int64,  int64_t)
-MSG_WRITER(uint32, uint32_t)
-MSG_WRITER(uint64, uint64_t)
-MSG_WRITER(bool,   bool)
-
-bool upb_msg_setscalarhandler(upb_handlers *h, const upb_fielddef *f,
-                              size_t offset, int32_t hasbit) {
-  upb_handlerattr attr = UPB_HANDLERATTR_INIT;
-  bool ok;
-
-  upb_msg_handlerdata *d = upb_gmalloc(sizeof(*d));
-  if (!d) return false;
-  d->offset = offset;
-  d->hasbit = hasbit;
-
-  attr.handler_data = d;
-  attr.alwaysok = true;
-  upb_handlers_addcleanup(h, d, upb_gfree);
-
-#define TYPE(u, l) \
-  case UPB_TYPE_##u: \
-    ok = upb_handlers_set##l(h, f, upb_msg_set##l, &attr); break;
-
-  ok = false;
-
-  switch (upb_fielddef_type(f)) {
-    TYPE(INT64,  int64);
-    TYPE(INT32,  int32);
-    TYPE(ENUM,   int32);
-    TYPE(UINT64, uint64);
-    TYPE(UINT32, uint32);
-    TYPE(DOUBLE, double);
-    TYPE(FLOAT,  float);
-    TYPE(BOOL,   bool);
-    default: UPB_ASSERT(false); break;
-  }
-#undef TYPE
-
-  return ok;
-}
-
-bool upb_msg_getscalarhandlerdata(const upb_handlers *h,
-                                  upb_selector_t s,
-                                  upb_fieldtype_t *type,
-                                  size_t *offset,
-                                  int32_t *hasbit) {
-  const upb_msg_handlerdata *d;
-  const void *p;
-  upb_func *f = upb_handlers_gethandler(h, s, &p);
-
-  if ((upb_int64_handlerfunc*)f == upb_msg_setint64) {
-    *type = UPB_TYPE_INT64;
-  } else if ((upb_int32_handlerfunc*)f == upb_msg_setint32) {
-    *type = UPB_TYPE_INT32;
-  } else if ((upb_uint64_handlerfunc*)f == upb_msg_setuint64) {
-    *type = UPB_TYPE_UINT64;
-  } else if ((upb_uint32_handlerfunc*)f == upb_msg_setuint32) {
-    *type = UPB_TYPE_UINT32;
-  } else if ((upb_double_handlerfunc*)f == upb_msg_setdouble) {
-    *type = UPB_TYPE_DOUBLE;
-  } else if ((upb_float_handlerfunc*)f == upb_msg_setfloat) {
-    *type = UPB_TYPE_FLOAT;
-  } else if ((upb_bool_handlerfunc*)f == upb_msg_setbool) {
-    *type = UPB_TYPE_BOOL;
-  } else {
-    return false;
-  }
-
-  d = p;
-  *offset = d->offset;
-  *hasbit = d->hasbit;
-  return true;
-}
diff --git a/third_party/upb/upb/handlers.h b/third_party/upb/upb/handlers.h
deleted file mode 100644 (file)
index 53904b6..0000000
+++ /dev/null
@@ -1,735 +0,0 @@
-/*
-** upb::Handlers (upb_handlers)
-**
-** A upb_handlers is like a virtual table for a upb_msgdef.  Each field of the
-** message can have associated functions that will be called when we are
-** parsing or visiting a stream of data.  This is similar to how handlers work
-** in SAX (the Simple API for XML).
-**
-** The handlers have no idea where the data is coming from, so a single set of
-** handlers could be used with two completely different data sources (for
-** example, a parser and a visitor over in-memory objects).  This decoupling is
-** the most important feature of upb, because it allows parsers and serializers
-** to be highly reusable.
-**
-** This is a mixed C/C++ interface that offers a full API to both languages.
-** See the top-level README for more information.
-*/
-
-#ifndef UPB_HANDLERS_H
-#define UPB_HANDLERS_H
-
-#include "upb/def.h"
-#include "upb/table.int.h"
-
-#include "upb/port_def.inc"
-
-#ifdef __cplusplus
-#include "upb/def.hpp"
-namespace upb {
-class HandlersPtr;
-class HandlerCache;
-template <class T> class Handler;
-template <class T> struct CanonicalType;
-}  /* namespace upb */
-#endif
-
-
-/* The maximum depth that the handler graph can have.  This is a resource limit
- * for the C stack since we sometimes need to recursively traverse the graph.
- * Cycles are ok; the traversal will stop when it detects a cycle, but we must
- * hit the cycle before the maximum depth is reached.
- *
- * If having a single static limit is too inflexible, we can add another variant
- * of Handlers::Freeze that allows specifying this as a parameter. */
-#define UPB_MAX_HANDLER_DEPTH 64
-
-/* All the different types of handlers that can be registered.
- * Only needed for the advanced functions in upb::Handlers. */
-typedef enum {
-  UPB_HANDLER_INT32,
-  UPB_HANDLER_INT64,
-  UPB_HANDLER_UINT32,
-  UPB_HANDLER_UINT64,
-  UPB_HANDLER_FLOAT,
-  UPB_HANDLER_DOUBLE,
-  UPB_HANDLER_BOOL,
-  UPB_HANDLER_STARTSTR,
-  UPB_HANDLER_STRING,
-  UPB_HANDLER_ENDSTR,
-  UPB_HANDLER_STARTSUBMSG,
-  UPB_HANDLER_ENDSUBMSG,
-  UPB_HANDLER_STARTSEQ,
-  UPB_HANDLER_ENDSEQ
-} upb_handlertype_t;
-
-#define UPB_HANDLER_MAX (UPB_HANDLER_ENDSEQ+1)
-
-#define UPB_BREAK NULL
-
-/* A convenient definition for when no closure is needed. */
-extern char _upb_noclosure;
-#define UPB_NO_CLOSURE &_upb_noclosure
-
-/* A selector refers to a specific field handler in the Handlers object
- * (for example: the STARTSUBMSG handler for field "field15"). */
-typedef int32_t upb_selector_t;
-
-/* Static selectors for upb::Handlers. */
-#define UPB_STARTMSG_SELECTOR 0
-#define UPB_ENDMSG_SELECTOR 1
-#define UPB_UNKNOWN_SELECTOR 2
-#define UPB_STATIC_SELECTOR_COUNT 3  /* Warning: also in upb/def.c. */
-
-/* Static selectors for upb::BytesHandler. */
-#define UPB_STARTSTR_SELECTOR 0
-#define UPB_STRING_SELECTOR 1
-#define UPB_ENDSTR_SELECTOR 2
-
-#ifdef __cplusplus
-template<class T> const void *UniquePtrForType() {
-  static const char ch = 0;
-  return &ch;
-}
-#endif
-
-/* upb_handlers ************************************************************/
-
-/* Handler attributes, to be registered with the handler itself. */
-typedef struct {
-  const void *handler_data;
-  const void *closure_type;
-  const void *return_closure_type;
-  bool alwaysok;
-} upb_handlerattr;
-
-#define UPB_HANDLERATTR_INIT {NULL, NULL, NULL, false}
-
-/* Bufhandle, data passed along with a buffer to indicate its provenance. */
-struct upb_bufhandle {
-  /* The beginning of the buffer.  This may be different than the pointer
-   * passed to a StringBuf handler because the handler may receive data
-   * that is from the middle or end of a larger buffer. */
-  const char *buf;
-
-  /* The offset within the attached object where this buffer begins.  Only
-   * meaningful if there is an attached object. */
-  size_t objofs;
-
-  /* The attached object (if any) and a pointer representing its type. */
-  const void *obj;
-  const void *objtype;
-
-#ifdef __cplusplus
-  template <class T>
-  void SetAttachedObject(const T* _obj) {
-    obj = _obj;
-    objtype = UniquePtrForType<T>();
-  }
-
-  template <class T>
-  const T *GetAttachedObject() const {
-    return objtype == UniquePtrForType<T>() ? static_cast<const T *>(obj)
-                                            : NULL;
-  }
-#endif
-};
-
-typedef struct upb_bufhandle upb_bufhandle;
-
-#define UPB_BUFHANDLE_INIT {NULL, 0, NULL, NULL}
-
-/* Handler function typedefs. */
-typedef void upb_handlerfree(void *d);
-typedef bool upb_unknown_handlerfunc(void *c, const void *hd, const char *buf,
-                                     size_t n);
-typedef bool upb_startmsg_handlerfunc(void *c, const void*);
-typedef bool upb_endmsg_handlerfunc(void *c, const void *, upb_status *status);
-typedef void* upb_startfield_handlerfunc(void *c, const void *hd);
-typedef bool upb_endfield_handlerfunc(void *c, const void *hd);
-typedef bool upb_int32_handlerfunc(void *c, const void *hd, int32_t val);
-typedef bool upb_int64_handlerfunc(void *c, const void *hd, int64_t val);
-typedef bool upb_uint32_handlerfunc(void *c, const void *hd, uint32_t val);
-typedef bool upb_uint64_handlerfunc(void *c, const void *hd, uint64_t val);
-typedef bool upb_float_handlerfunc(void *c, const void *hd, float val);
-typedef bool upb_double_handlerfunc(void *c, const void *hd, double val);
-typedef bool upb_bool_handlerfunc(void *c, const void *hd, bool val);
-typedef void *upb_startstr_handlerfunc(void *c, const void *hd,
-                                       size_t size_hint);
-typedef size_t upb_string_handlerfunc(void *c, const void *hd, const char *buf,
-                                      size_t n, const upb_bufhandle* handle);
-
-struct upb_handlers;
-typedef struct upb_handlers upb_handlers;
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-/* Mutating accessors. */
-const upb_status *upb_handlers_status(upb_handlers *h);
-void upb_handlers_clearerr(upb_handlers *h);
-const upb_msgdef *upb_handlers_msgdef(const upb_handlers *h);
-bool upb_handlers_addcleanup(upb_handlers *h, void *p, upb_handlerfree *hfree);
-bool upb_handlers_setunknown(upb_handlers *h, upb_unknown_handlerfunc *func,
-                             const upb_handlerattr *attr);
-bool upb_handlers_setstartmsg(upb_handlers *h, upb_startmsg_handlerfunc *func,
-                              const upb_handlerattr *attr);
-bool upb_handlers_setendmsg(upb_handlers *h, upb_endmsg_handlerfunc *func,
-                            const upb_handlerattr *attr);
-bool upb_handlers_setint32(upb_handlers *h, const upb_fielddef *f,
-                           upb_int32_handlerfunc *func,
-                           const upb_handlerattr *attr);
-bool upb_handlers_setint64(upb_handlers *h, const upb_fielddef *f,
-                           upb_int64_handlerfunc *func,
-                           const upb_handlerattr *attr);
-bool upb_handlers_setuint32(upb_handlers *h, const upb_fielddef *f,
-                            upb_uint32_handlerfunc *func,
-                            const upb_handlerattr *attr);
-bool upb_handlers_setuint64(upb_handlers *h, const upb_fielddef *f,
-                            upb_uint64_handlerfunc *func,
-                            const upb_handlerattr *attr);
-bool upb_handlers_setfloat(upb_handlers *h, const upb_fielddef *f,
-                           upb_float_handlerfunc *func,
-                           const upb_handlerattr *attr);
-bool upb_handlers_setdouble(upb_handlers *h, const upb_fielddef *f,
-                            upb_double_handlerfunc *func,
-                            const upb_handlerattr *attr);
-bool upb_handlers_setbool(upb_handlers *h, const upb_fielddef *f,
-                          upb_bool_handlerfunc *func,
-                          const upb_handlerattr *attr);
-bool upb_handlers_setstartstr(upb_handlers *h, const upb_fielddef *f,
-                              upb_startstr_handlerfunc *func,
-                              const upb_handlerattr *attr);
-bool upb_handlers_setstring(upb_handlers *h, const upb_fielddef *f,
-                            upb_string_handlerfunc *func,
-                            const upb_handlerattr *attr);
-bool upb_handlers_setendstr(upb_handlers *h, const upb_fielddef *f,
-                            upb_endfield_handlerfunc *func,
-                            const upb_handlerattr *attr);
-bool upb_handlers_setstartseq(upb_handlers *h, const upb_fielddef *f,
-                              upb_startfield_handlerfunc *func,
-                              const upb_handlerattr *attr);
-bool upb_handlers_setstartsubmsg(upb_handlers *h, const upb_fielddef *f,
-                                 upb_startfield_handlerfunc *func,
-                                 const upb_handlerattr *attr);
-bool upb_handlers_setendsubmsg(upb_handlers *h, const upb_fielddef *f,
-                               upb_endfield_handlerfunc *func,
-                               const upb_handlerattr *attr);
-bool upb_handlers_setendseq(upb_handlers *h, const upb_fielddef *f,
-                            upb_endfield_handlerfunc *func,
-                            const upb_handlerattr *attr);
-
-/* Read-only accessors. */
-const upb_handlers *upb_handlers_getsubhandlers(const upb_handlers *h,
-                                                const upb_fielddef *f);
-const upb_handlers *upb_handlers_getsubhandlers_sel(const upb_handlers *h,
-                                                    upb_selector_t sel);
-upb_func *upb_handlers_gethandler(const upb_handlers *h, upb_selector_t s,
-                                  const void **handler_data);
-bool upb_handlers_getattr(const upb_handlers *h, upb_selector_t s,
-                          upb_handlerattr *attr);
-
-/* "Static" methods */
-upb_handlertype_t upb_handlers_getprimitivehandlertype(const upb_fielddef *f);
-bool upb_handlers_getselector(const upb_fielddef *f, upb_handlertype_t type,
-                              upb_selector_t *s);
-UPB_INLINE upb_selector_t upb_handlers_getendselector(upb_selector_t start) {
-  return start + 1;
-}
-
-#ifdef __cplusplus
-}  /* extern "C" */
-
-namespace upb {
-typedef upb_handlers Handlers;
-}
-
-/* Convenience macros for creating a Handler object that is wrapped with a
- * type-safe wrapper function that converts the "void*" parameters/returns
- * of the underlying C API into nice C++ function.
- *
- * Sample usage:
- *   void OnValue1(MyClosure* c, const MyHandlerData* d, int32_t val) {
- *     // do stuff ...
- *   }
- *
- *   // Handler that doesn't need any data bound to it.
- *   void OnValue2(MyClosure* c, int32_t val) {
- *     // do stuff ...
- *   }
- *
- *   // Handler that returns bool so it can return failure if necessary.
- *   bool OnValue3(MyClosure* c, int32_t val) {
- *     // do stuff ...
- *     return ok;
- *   }
- *
- *   // Member function handler.
- *   class MyClosure {
- *    public:
- *     void OnValue(int32_t val) {
- *       // do stuff ...
- *     }
- *   };
- *
- *   // Takes ownership of the MyHandlerData.
- *   handlers->SetInt32Handler(f1, UpbBind(OnValue1, new MyHandlerData(...)));
- *   handlers->SetInt32Handler(f2, UpbMakeHandler(OnValue2));
- *   handlers->SetInt32Handler(f1, UpbMakeHandler(OnValue3));
- *   handlers->SetInt32Handler(f2, UpbMakeHandler(&MyClosure::OnValue));
- */
-
-/* In C++11, the "template" disambiguator can appear even outside templates,
- * so all calls can safely use this pair of macros. */
-
-#define UpbMakeHandler(f) upb::MatchFunc(f).template GetFunc<f>()
-
-/* We have to be careful to only evaluate "d" once. */
-#define UpbBind(f, d) upb::MatchFunc(f).template GetFunc<f>((d))
-
-/* Handler: a struct that contains the (handler, data, deleter) tuple that is
- * used to register all handlers.  Users can Make() these directly but it's
- * more convenient to use the UpbMakeHandler/UpbBind macros above. */
-template <class T> class upb::Handler {
- public:
-  /* The underlying, handler function signature that upb uses internally. */
-  typedef T FuncPtr;
-
-  /* Intentionally implicit. */
-  template <class F> Handler(F func);
-  ~Handler() { UPB_ASSERT(registered_); }
-
-  void AddCleanup(upb_handlers* h) const;
-  FuncPtr handler() const { return handler_; }
-  const upb_handlerattr& attr() const { return attr_; }
-
- private:
-  Handler(const Handler&) = delete;
-  Handler& operator=(const Handler&) = delete;
-
-  FuncPtr handler_;
-  mutable upb_handlerattr attr_;
-  mutable bool registered_;
-  void *cleanup_data_;
-  upb_handlerfree *cleanup_func_;
-};
-
-/* A upb::Handlers object represents the set of handlers associated with a
- * message in the graph of messages.  You can think of it as a big virtual
- * table with functions corresponding to all the events that can fire while
- * parsing or visiting a message of a specific type.
- *
- * Any handlers that are not set behave as if they had successfully consumed
- * the value.  Any unset Start* handlers will propagate their closure to the
- * inner frame.
- *
- * The easiest way to create the *Handler objects needed by the Set* methods is
- * with the UpbBind() and UpbMakeHandler() macros; see below. */
-class upb::HandlersPtr {
- public:
-  HandlersPtr(upb_handlers* ptr) : ptr_(ptr) {}
-
-  upb_handlers* ptr() const { return ptr_; }
-
-  typedef upb_selector_t Selector;
-  typedef upb_handlertype_t Type;
-
-  typedef Handler<void *(*)(void *, const void *)> StartFieldHandler;
-  typedef Handler<bool (*)(void *, const void *)> EndFieldHandler;
-  typedef Handler<bool (*)(void *, const void *)> StartMessageHandler;
-  typedef Handler<bool (*)(void *, const void *, upb_status *)>
-      EndMessageHandler;
-  typedef Handler<void *(*)(void *, const void *, size_t)> StartStringHandler;
-  typedef Handler<size_t (*)(void *, const void *, const char *, size_t,
-                             const upb_bufhandle *)>
-      StringHandler;
-
-  template <class T> struct ValueHandler {
-    typedef Handler<bool(*)(void *, const void *, T)> H;
-  };
-
-  typedef ValueHandler<int32_t>::H     Int32Handler;
-  typedef ValueHandler<int64_t>::H     Int64Handler;
-  typedef ValueHandler<uint32_t>::H    UInt32Handler;
-  typedef ValueHandler<uint64_t>::H    UInt64Handler;
-  typedef ValueHandler<float>::H       FloatHandler;
-  typedef ValueHandler<double>::H      DoubleHandler;
-  typedef ValueHandler<bool>::H        BoolHandler;
-
-  /* Any function pointer can be converted to this and converted back to its
-   * correct type. */
-  typedef void GenericFunction();
-
-  typedef void HandlersCallback(const void *closure, upb_handlers *h);
-
-  /* Returns the msgdef associated with this handlers object. */
-  MessageDefPtr message_def() const {
-    return MessageDefPtr(upb_handlers_msgdef(ptr()));
-  }
-
-  /* Adds the given pointer and function to the list of cleanup functions that
-   * will be run when these handlers are freed.  If this pointer has previously
-   * been registered, the function returns false and does nothing. */
-  bool AddCleanup(void *ptr, upb_handlerfree *cleanup) {
-    return upb_handlers_addcleanup(ptr_, ptr, cleanup);
-  }
-
-  /* Sets the startmsg handler for the message, which is defined as follows:
-   *
-   *   bool startmsg(MyType* closure) {
-   *     // Called when the message begins.  Returns true if processing should
-   *     // continue.
-   *     return true;
-   *   }
-   */
-  bool SetStartMessageHandler(const StartMessageHandler &h) {
-    h.AddCleanup(ptr());
-    return upb_handlers_setstartmsg(ptr(), h.handler(), &h.attr());
-  }
-
-  /* Sets the endmsg handler for the message, which is defined as follows:
-   *
-   *   bool endmsg(MyType* closure, upb_status *status) {
-   *     // Called when processing of this message ends, whether in success or
-   *     // failure.  "status" indicates the final status of processing, and
-   *     // can also be modified in-place to update the final status.
-   *   }
-   */
-  bool SetEndMessageHandler(const EndMessageHandler& h) {
-    h.AddCleanup(ptr());
-    return upb_handlers_setendmsg(ptr(), h.handler(), &h.attr());
-  }
-
-  /* Sets the value handler for the given field, which is defined as follows
-   * (this is for an int32 field; other field types will pass their native
-   * C/C++ type for "val"):
-   *
-   *   bool OnValue(MyClosure* c, const MyHandlerData* d, int32_t val) {
-   *     // Called when the field's value is encountered.  "d" contains
-   *     // whatever data was bound to this field when it was registered.
-   *     // Returns true if processing should continue.
-   *     return true;
-   *   }
-   *
-   *   handers->SetInt32Handler(f, UpbBind(OnValue, new MyHandlerData(...)));
-   *
-   * The value type must exactly match f->type().
-   * For example, a handler that takes an int32_t parameter may only be used for
-   * fields of type UPB_TYPE_INT32 and UPB_TYPE_ENUM.
-   *
-   * Returns false if the handler failed to register; in this case the cleanup
-   * handler (if any) will be called immediately.
-   */
-  bool SetInt32Handler(FieldDefPtr f, const Int32Handler &h) {
-    h.AddCleanup(ptr());
-    return upb_handlers_setint32(ptr(), f.ptr(), h.handler(), &h.attr());
-  }
-
-  bool SetInt64Handler (FieldDefPtr f,  const Int64Handler& h) {
-    h.AddCleanup(ptr());
-    return upb_handlers_setint64(ptr(), f.ptr(), h.handler(), &h.attr());
-  }
-
-  bool SetUInt32Handler(FieldDefPtr f, const UInt32Handler& h) {
-    h.AddCleanup(ptr());
-    return upb_handlers_setuint32(ptr(), f.ptr(), h.handler(), &h.attr());
-  }
-
-  bool SetUInt64Handler(FieldDefPtr f, const UInt64Handler& h) {
-    h.AddCleanup(ptr());
-    return upb_handlers_setuint64(ptr(), f.ptr(), h.handler(), &h.attr());
-  }
-
-  bool SetFloatHandler (FieldDefPtr f,  const FloatHandler& h) {
-    h.AddCleanup(ptr());
-    return upb_handlers_setfloat(ptr(), f.ptr(), h.handler(), &h.attr());
-  }
-
-  bool SetDoubleHandler(FieldDefPtr f, const DoubleHandler& h) {
-    h.AddCleanup(ptr());
-    return upb_handlers_setdouble(ptr(), f.ptr(), h.handler(), &h.attr());
-  }
-
-  bool SetBoolHandler(FieldDefPtr f, const BoolHandler &h) {
-    h.AddCleanup(ptr());
-    return upb_handlers_setbool(ptr(), f.ptr(), h.handler(), &h.attr());
-  }
-
-  /* Like the previous, but templated on the type on the value (ie. int32).
-   * This is mostly useful to call from other templates.  To call this you must
-   * specify the template parameter explicitly, ie:
-   *   h->SetValueHandler<T>(f, UpbBind(MyHandler<T>, MyData)); */
-  template <class T>
-  bool SetValueHandler(
-      FieldDefPtr f,
-      const typename ValueHandler<typename CanonicalType<T>::Type>::H &handler);
-
-  /* Sets handlers for a string field, which are defined as follows:
-   *
-   *   MySubClosure* startstr(MyClosure* c, const MyHandlerData* d,
-   *                          size_t size_hint) {
-   *     // Called when a string value begins.  The return value indicates the
-   *     // closure for the string.  "size_hint" indicates the size of the
-   *     // string if it is known, however if the string is length-delimited
-   *     // and the end-of-string is not available size_hint will be zero.
-   *     // This case is indistinguishable from the case where the size is
-   *     // known to be zero.
-   *     //
-   *     // TODO(haberman): is it important to distinguish these cases?
-   *     // If we had ssize_t as a type we could make -1 "unknown", but
-   *     // ssize_t is POSIX (not ANSI) and therefore less portable.
-   *     // In practice I suspect it won't be important to distinguish.
-   *     return closure;
-   *   }
-   *
-   *   size_t str(MyClosure* closure, const MyHandlerData* d,
-   *              const char *str, size_t len) {
-   *     // Called for each buffer of string data; the multiple physical buffers
-   *     // are all part of the same logical string.  The return value indicates
-   *     // how many bytes were consumed.  If this number is less than "len",
-   *     // this will also indicate that processing should be halted for now,
-   *     // like returning false or UPB_BREAK from any other callback.  If
-   *     // number is greater than "len", the excess bytes will be skipped over
-   *     // and not passed to the callback.
-   *     return len;
-   *   }
-   *
-   *   bool endstr(MyClosure* c, const MyHandlerData* d) {
-   *     // Called when a string value ends.  Return value indicates whether
-   *     // processing should continue.
-   *     return true;
-   *   }
-   */
-  bool SetStartStringHandler(FieldDefPtr f, const StartStringHandler &h) {
-    h.AddCleanup(ptr());
-    return upb_handlers_setstartstr(ptr(), f.ptr(), h.handler(), &h.attr());
-  }
-
-  bool SetStringHandler(FieldDefPtr f, const StringHandler& h) {
-    h.AddCleanup(ptr());
-    return upb_handlers_setstring(ptr(), f.ptr(), h.handler(), &h.attr());
-  }
-
-  bool SetEndStringHandler(FieldDefPtr f, const EndFieldHandler& h) {
-    h.AddCleanup(ptr());
-    return upb_handlers_setendstr(ptr(), f.ptr(), h.handler(), &h.attr());
-  }
-
-  /* Sets the startseq handler, which is defined as follows:
-   *
-   *   MySubClosure *startseq(MyClosure* c, const MyHandlerData* d) {
-   *     // Called when a sequence (repeated field) begins.  The returned
-   *     // pointer indicates the closure for the sequence (or UPB_BREAK
-   *     // to interrupt processing).
-   *     return closure;
-   *   }
-   *
-   *   h->SetStartSequenceHandler(f, UpbBind(startseq, new MyHandlerData(...)));
-   *
-   * Returns "false" if "f" does not belong to this message or is not a
-   * repeated field.
-   */
-  bool SetStartSequenceHandler(FieldDefPtr f, const StartFieldHandler &h) {
-    h.AddCleanup(ptr());
-    return upb_handlers_setstartseq(ptr(), f.ptr(), h.handler(), &h.attr());
-  }
-
-  /* Sets the startsubmsg handler for the given field, which is defined as
-   * follows:
-   *
-   *   MySubClosure* startsubmsg(MyClosure* c, const MyHandlerData* d) {
-   *     // Called when a submessage begins.  The returned pointer indicates the
-   *     // closure for the sequence (or UPB_BREAK to interrupt processing).
-   *     return closure;
-   *   }
-   *
-   *   h->SetStartSubMessageHandler(f, UpbBind(startsubmsg,
-   *                                           new MyHandlerData(...)));
-   *
-   * Returns "false" if "f" does not belong to this message or is not a
-   * submessage/group field.
-   */
-  bool SetStartSubMessageHandler(FieldDefPtr f, const StartFieldHandler& h) {
-    h.AddCleanup(ptr());
-    return upb_handlers_setstartsubmsg(ptr(), f.ptr(), h.handler(), &h.attr());
-  }
-
-  /* Sets the endsubmsg handler for the given field, which is defined as
-   * follows:
-   *
-   *   bool endsubmsg(MyClosure* c, const MyHandlerData* d) {
-   *     // Called when a submessage ends.  Returns true to continue processing.
-   *     return true;
-   *   }
-   *
-   * Returns "false" if "f" does not belong to this message or is not a
-   * submessage/group field.
-   */
-  bool SetEndSubMessageHandler(FieldDefPtr f, const EndFieldHandler &h) {
-    h.AddCleanup(ptr());
-    return upb_handlers_setendsubmsg(ptr(), f.ptr(), h.handler(), &h.attr());
-  }
-
-  /* Starts the endsubseq handler for the given field, which is defined as
-   * follows:
-   *
-   *   bool endseq(MyClosure* c, const MyHandlerData* d) {
-   *     // Called when a sequence ends.  Returns true continue processing.
-   *     return true;
-   *   }
-   *
-   * Returns "false" if "f" does not belong to this message or is not a
-   * repeated field.
-   */
-  bool SetEndSequenceHandler(FieldDefPtr f, const EndFieldHandler &h) {
-    h.AddCleanup(ptr());
-    return upb_handlers_setendseq(ptr(), f.ptr(), h.handler(), &h.attr());
-  }
-
- private:
-  upb_handlers* ptr_;
-};
-
-#endif  /* __cplusplus */
-
-/* upb_handlercache ***********************************************************/
-
-/* A upb_handlercache lazily builds and caches upb_handlers.  You pass it a
- * function (with optional closure) that can build handlers for a given
- * message on-demand, and the cache maintains a map of msgdef->handlers. */
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-struct upb_handlercache;
-typedef struct upb_handlercache upb_handlercache;
-
-typedef void upb_handlers_callback(const void *closure, upb_handlers *h);
-
-upb_handlercache *upb_handlercache_new(upb_handlers_callback *callback,
-                                       const void *closure);
-void upb_handlercache_free(upb_handlercache *cache);
-const upb_handlers *upb_handlercache_get(upb_handlercache *cache,
-                                         const upb_msgdef *md);
-bool upb_handlercache_addcleanup(upb_handlercache *h, void *p,
-                                 upb_handlerfree *hfree);
-
-#ifdef __cplusplus
-}  /* extern "C" */
-
-class upb::HandlerCache {
- public:
-  HandlerCache(upb_handlers_callback *callback, const void *closure)
-      : ptr_(upb_handlercache_new(callback, closure), upb_handlercache_free) {}
-  HandlerCache(HandlerCache&&) = default;
-  HandlerCache& operator=(HandlerCache&&) = default;
-  HandlerCache(upb_handlercache* c) : ptr_(c, upb_handlercache_free) {}
-
-  upb_handlercache* ptr() { return ptr_.get(); }
-
-  const upb_handlers *Get(MessageDefPtr md) {
-    return upb_handlercache_get(ptr_.get(), md.ptr());
-  }
-
- private:
-  std::unique_ptr<upb_handlercache, decltype(&upb_handlercache_free)> ptr_;
-};
-
-#endif  /* __cplusplus */
-
-/* upb_byteshandler ***********************************************************/
-
-typedef struct {
-  upb_func *func;
-
-  /* It is wasteful to include the entire attributes here:
-   *
-   * * Some of the information is redundant (like storing the closure type
-   *   separately for each handler that must match).
-   * * Some of the info is only needed prior to freeze() (like closure types).
-   * * alignment padding wastes a lot of space for alwaysok_.
-   *
-   * If/when the size and locality of handlers is an issue, we can optimize this
-   * not to store the entire attr like this.  We do not expose the table's
-   * layout to allow this optimization in the future. */
-  upb_handlerattr attr;
-} upb_handlers_tabent;
-
-#define UPB_TABENT_INIT {NULL, UPB_HANDLERATTR_INIT}
-
-typedef struct {
-  upb_handlers_tabent table[3];
-} upb_byteshandler;
-
-#define UPB_BYTESHANDLER_INIT                             \
-  {                                                       \
-    { UPB_TABENT_INIT, UPB_TABENT_INIT, UPB_TABENT_INIT } \
-  }
-
-UPB_INLINE void upb_byteshandler_init(upb_byteshandler *handler) {
-  upb_byteshandler init = UPB_BYTESHANDLER_INIT;
-  *handler = init;
-}
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-/* Caller must ensure that "d" outlives the handlers. */
-bool upb_byteshandler_setstartstr(upb_byteshandler *h,
-                                  upb_startstr_handlerfunc *func, void *d);
-bool upb_byteshandler_setstring(upb_byteshandler *h,
-                                upb_string_handlerfunc *func, void *d);
-bool upb_byteshandler_setendstr(upb_byteshandler *h,
-                                upb_endfield_handlerfunc *func, void *d);
-
-#ifdef __cplusplus
-}  /* extern "C" */
-
-namespace upb {
-typedef upb_byteshandler BytesHandler;
-}
-#endif
-
-/** Message handlers ******************************************************************/
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-/* These are the handlers used internally by upb_msgfactory_getmergehandlers().
- * They write scalar data to a known offset from the message pointer.
- *
- * These would be trivial for anyone to implement themselves, but it's better
- * to use these because some JITs will recognize and specialize these instead
- * of actually calling the function. */
-
-/* Sets a handler for the given primitive field that will write the data at the
- * given offset.  If hasbit > 0, also sets a hasbit at the given bit offset
- * (addressing each byte low to high). */
-bool upb_msg_setscalarhandler(upb_handlers *h,
-                              const upb_fielddef *f,
-                              size_t offset,
-                              int32_t hasbit);
-
-/* If the given handler is a msghandlers_primitive field, returns true and sets
- * *type, *offset and *hasbit.  Otherwise returns false. */
-bool upb_msg_getscalarhandlerdata(const upb_handlers *h,
-                                  upb_selector_t s,
-                                  upb_fieldtype_t *type,
-                                  size_t *offset,
-                                  int32_t *hasbit);
-
-
-
-#ifdef __cplusplus
-}  /* extern "C" */
-#endif
-
-#include "upb/port_undef.inc"
-
-#include "upb/handlers-inl.h"
-
-#endif  /* UPB_HANDLERS_H */
diff --git a/third_party/upb/upb/json/parser.h b/third_party/upb/upb/json/parser.h
deleted file mode 100644 (file)
index d323c52..0000000
+++ /dev/null
@@ -1,140 +0,0 @@
-/*
-** upb::json::Parser (upb_json_parser)
-**
-** Parses JSON according to a specific schema.
-** Support for parsing arbitrary JSON (schema-less) will be added later.
-*/
-
-#ifndef UPB_JSON_PARSER_H_
-#define UPB_JSON_PARSER_H_
-
-#include "upb/sink.h"
-
-#ifdef __cplusplus
-namespace upb {
-namespace json {
-class CodeCache;
-class ParserPtr;
-class ParserMethodPtr;
-}  /* namespace json */
-}  /* namespace upb */
-#endif
-
-/* upb_json_parsermethod ******************************************************/
-
-struct upb_json_parsermethod;
-typedef struct upb_json_parsermethod upb_json_parsermethod;
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-const upb_byteshandler* upb_json_parsermethod_inputhandler(
-    const upb_json_parsermethod* m);
-
-#ifdef __cplusplus
-}  /* extern "C" */
-
-class upb::json::ParserMethodPtr {
- public:
-  ParserMethodPtr() : ptr_(nullptr) {}
-  ParserMethodPtr(const upb_json_parsermethod* ptr) : ptr_(ptr) {}
-
-  const upb_json_parsermethod* ptr() const { return ptr_; }
-
-  const BytesHandler* input_handler() const {
-    return upb_json_parsermethod_inputhandler(ptr());
-  }
-
- private:
-  const upb_json_parsermethod* ptr_;
-};
-
-#endif  /* __cplusplus */
-
-/* upb_json_parser ************************************************************/
-
-/* Preallocation hint: parser won't allocate more bytes than this when first
- * constructed.  This hint may be an overestimate for some build configurations.
- * But if the parser library is upgraded without recompiling the application,
- * it may be an underestimate. */
-#define UPB_JSON_PARSER_SIZE 5712
-
-struct upb_json_parser;
-typedef struct upb_json_parser upb_json_parser;
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-upb_json_parser* upb_json_parser_create(upb_arena* a,
-                                        const upb_json_parsermethod* m,
-                                        const upb_symtab* symtab,
-                                        upb_sink output,
-                                        upb_status *status,
-                                        bool ignore_json_unknown);
-upb_bytessink upb_json_parser_input(upb_json_parser* p);
-
-#ifdef __cplusplus
-}  /* extern "C" */
-
-/* Parses an incoming BytesStream, pushing the results to the destination
- * sink. */
-class upb::json::ParserPtr {
- public:
-  ParserPtr(upb_json_parser* ptr) : ptr_(ptr) {}
-
-  static ParserPtr Create(Arena* arena, ParserMethodPtr method,
-                          SymbolTable* symtab, Sink output, Status* status,
-                          bool ignore_json_unknown) {
-    upb_symtab* symtab_ptr = symtab ? symtab->ptr() : nullptr;
-    return ParserPtr(upb_json_parser_create(
-        arena->ptr(), method.ptr(), symtab_ptr, output.sink(), status->ptr(),
-        ignore_json_unknown));
-  }
-
-  BytesSink input() { return upb_json_parser_input(ptr_); }
-
- private:
-  upb_json_parser* ptr_;
-};
-
-#endif  /* __cplusplus */
-
-/* upb_json_codecache *********************************************************/
-
-/* Lazily builds and caches decoder methods that will push data to the given
- * handlers.  The upb_symtab object(s) must outlive this object. */
-
-struct upb_json_codecache;
-typedef struct upb_json_codecache upb_json_codecache;
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-upb_json_codecache *upb_json_codecache_new(void);
-void upb_json_codecache_free(upb_json_codecache *cache);
-const upb_json_parsermethod* upb_json_codecache_get(upb_json_codecache* cache,
-                                                    const upb_msgdef* md);
-
-#ifdef __cplusplus
-}  /* extern "C" */
-
-class upb::json::CodeCache {
- public:
-  CodeCache() : ptr_(upb_json_codecache_new(), upb_json_codecache_free) {}
-
-  /* Returns a DecoderMethod that can push data to the given handlers.
-   * If a suitable method already exists, it will be returned from the cache. */
-  ParserMethodPtr Get(MessageDefPtr md) {
-    return upb_json_codecache_get(ptr_.get(), md.ptr());
-  }
-
- private:
-  std::unique_ptr<upb_json_codecache, decltype(&upb_json_codecache_free)> ptr_;
-};
-
-#endif
-
-#endif  /* UPB_JSON_PARSER_H_ */
diff --git a/third_party/upb/upb/json/parser.rl b/third_party/upb/upb/json/parser.rl
deleted file mode 100644 (file)
index a7d75ff..0000000
+++ /dev/null
@@ -1,2996 +0,0 @@
-/*
-** upb::json::Parser (upb_json_parser)
-**
-** A parser that uses the Ragel State Machine Compiler to generate
-** the finite automata.
-**
-** Ragel only natively handles regular languages, but we can manually
-** program it a bit to handle context-free languages like JSON, by using
-** the "fcall" and "fret" constructs.
-**
-** This parser can handle the basics, but needs several things to be fleshed
-** out:
-**
-** - handling of unicode escape sequences (including high surrogate pairs).
-** - properly check and report errors for unknown fields, stack overflow,
-**   improper array nesting (or lack of nesting).
-** - handling of base64 sequences with padding characters.
-** - handling of push-back (non-success returns from sink functions).
-** - handling of keys/escape-sequences/etc that span input buffers.
-*/
-
-#include <ctype.h>
-#include <errno.h>
-#include <float.h>
-#include <math.h>
-#include <stdint.h>
-#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
-
-#include <time.h>
-
-#include "upb/json/parser.h"
-#include "upb/pb/encoder.h"
-
-#include "upb/port_def.inc"
-
-#define UPB_JSON_MAX_DEPTH 64
-
-/* Type of value message */
-enum {
-  VALUE_NULLVALUE   = 0,
-  VALUE_NUMBERVALUE = 1,
-  VALUE_STRINGVALUE = 2,
-  VALUE_BOOLVALUE   = 3,
-  VALUE_STRUCTVALUE = 4,
-  VALUE_LISTVALUE   = 5
-};
-
-/* Forward declare */
-static bool is_top_level(upb_json_parser *p);
-static bool is_wellknown_msg(upb_json_parser *p, upb_wellknowntype_t type);
-static bool is_wellknown_field(upb_json_parser *p, upb_wellknowntype_t type);
-
-static bool is_number_wrapper_object(upb_json_parser *p);
-static bool does_number_wrapper_start(upb_json_parser *p);
-static bool does_number_wrapper_end(upb_json_parser *p);
-
-static bool is_string_wrapper_object(upb_json_parser *p);
-static bool does_string_wrapper_start(upb_json_parser *p);
-static bool does_string_wrapper_end(upb_json_parser *p);
-
-static bool does_fieldmask_start(upb_json_parser *p);
-static bool does_fieldmask_end(upb_json_parser *p);
-static void start_fieldmask_object(upb_json_parser *p);
-static void end_fieldmask_object(upb_json_parser *p);
-
-static void start_wrapper_object(upb_json_parser *p);
-static void end_wrapper_object(upb_json_parser *p);
-
-static void start_value_object(upb_json_parser *p, int value_type);
-static void end_value_object(upb_json_parser *p);
-
-static void start_listvalue_object(upb_json_parser *p);
-static void end_listvalue_object(upb_json_parser *p);
-
-static void start_structvalue_object(upb_json_parser *p);
-static void end_structvalue_object(upb_json_parser *p);
-
-static void start_object(upb_json_parser *p);
-static void end_object(upb_json_parser *p);
-
-static void start_any_object(upb_json_parser *p, const char *ptr);
-static bool end_any_object(upb_json_parser *p, const char *ptr);
-
-static bool start_subobject(upb_json_parser *p);
-static void end_subobject(upb_json_parser *p);
-
-static void start_member(upb_json_parser *p);
-static void end_member(upb_json_parser *p);
-static bool end_membername(upb_json_parser *p);
-
-static void start_any_member(upb_json_parser *p, const char *ptr);
-static void end_any_member(upb_json_parser *p, const char *ptr);
-static bool end_any_membername(upb_json_parser *p);
-
-size_t parse(void *closure, const void *hd, const char *buf, size_t size,
-             const upb_bufhandle *handle);
-static bool end(void *closure, const void *hd);
-
-static const char eof_ch = 'e';
-
-/* stringsink */
-typedef struct {
-  upb_byteshandler handler;
-  upb_bytessink sink;
-  char *ptr;
-  size_t len, size;
-} upb_stringsink;
-
-
-static void *stringsink_start(void *_sink, const void *hd, size_t size_hint) {
-  upb_stringsink *sink = _sink;
-  sink->len = 0;
-  UPB_UNUSED(hd);
-  UPB_UNUSED(size_hint);
-  return sink;
-}
-
-static size_t stringsink_string(void *_sink, const void *hd, const char *ptr,
-                                size_t len, const upb_bufhandle *handle) {
-  upb_stringsink *sink = _sink;
-  size_t new_size = sink->size;
-
-  UPB_UNUSED(hd);
-  UPB_UNUSED(handle);
-
-  while (sink->len + len > new_size) {
-    new_size *= 2;
-  }
-
-  if (new_size != sink->size) {
-    sink->ptr = realloc(sink->ptr, new_size);
-    sink->size = new_size;
-  }
-
-  memcpy(sink->ptr + sink->len, ptr, len);
-  sink->len += len;
-
-  return len;
-}
-
-void upb_stringsink_init(upb_stringsink *sink) {
-  upb_byteshandler_init(&sink->handler);
-  upb_byteshandler_setstartstr(&sink->handler, stringsink_start, NULL);
-  upb_byteshandler_setstring(&sink->handler, stringsink_string, NULL);
-
-  upb_bytessink_reset(&sink->sink, &sink->handler, sink);
-
-  sink->size = 32;
-  sink->ptr = malloc(sink->size);
-  sink->len = 0;
-}
-
-void upb_stringsink_uninit(upb_stringsink *sink) { free(sink->ptr); }
-
-typedef struct {
-  /* For encoding Any value field in binary format. */
-  upb_handlercache *encoder_handlercache;
-  upb_stringsink stringsink;
-
-  /* For decoding Any value field in json format. */
-  upb_json_codecache *parser_codecache;
-  upb_sink sink;
-  upb_json_parser *parser;
-
-  /* Mark the range of uninterpreted values in json input before type url. */
-  const char *before_type_url_start;
-  const char *before_type_url_end;
-
-  /* Mark the range of uninterpreted values in json input after type url. */
-  const char *after_type_url_start;
-} upb_jsonparser_any_frame;
-
-typedef struct {
-  upb_sink sink;
-
-  /* The current message in which we're parsing, and the field whose value we're
-   * expecting next. */
-  const upb_msgdef *m;
-  const upb_fielddef *f;
-
-  /* The table mapping json name to fielddef for this message. */
-  const upb_strtable *name_table;
-
-  /* We are in a repeated-field context. We need this flag to decide whether to
-   * handle the array as a normal repeated field or a
-   * google.protobuf.ListValue/google.protobuf.Value. */
-  bool is_repeated;
-
-  /* We are in a repeated-field context, ready to emit mapentries as
-   * submessages. This flag alters the start-of-object (open-brace) behavior to
-   * begin a sequence of mapentry messages rather than a single submessage. */
-  bool is_map;
-
-  /* We are in a map-entry message context. This flag is set when parsing the
-   * value field of a single map entry and indicates to all value-field parsers
-   * (subobjects, strings, numbers, and bools) that the map-entry submessage
-   * should end as soon as the value is parsed. */
-  bool is_mapentry;
-
-  /* If |is_map| or |is_mapentry| is true, |mapfield| refers to the parent
-   * message's map field that we're currently parsing. This differs from |f|
-   * because |f| is the field in the *current* message (i.e., the map-entry
-   * message itself), not the parent's field that leads to this map. */
-  const upb_fielddef *mapfield;
-
-  /* We are in an Any message context. This flag is set when parsing the Any
-   * message and indicates to all field parsers (subobjects, strings, numbers,
-   * and bools) that the parsed field should be serialized as binary data or
-   * cached (type url not found yet). */
-  bool is_any;
-
-  /* The type of packed message in Any. */
-  upb_jsonparser_any_frame *any_frame;
-
-  /* True if the field to be parsed is unknown. */
-  bool is_unknown_field;
-} upb_jsonparser_frame;
-
-static void init_frame(upb_jsonparser_frame* frame) {
-  frame->m = NULL;
-  frame->f = NULL;
-  frame->name_table = NULL;
-  frame->is_repeated = false;
-  frame->is_map = false;
-  frame->is_mapentry = false;
-  frame->mapfield = NULL;
-  frame->is_any = false;
-  frame->any_frame = NULL;
-  frame->is_unknown_field = false;
-}
-
-struct upb_json_parser {
-  upb_arena *arena;
-  const upb_json_parsermethod *method;
-  upb_bytessink input_;
-
-  /* Stack to track the JSON scopes we are in. */
-  upb_jsonparser_frame stack[UPB_JSON_MAX_DEPTH];
-  upb_jsonparser_frame *top;
-  upb_jsonparser_frame *limit;
-
-  upb_status *status;
-
-  /* Ragel's internal parsing stack for the parsing state machine. */
-  int current_state;
-  int parser_stack[UPB_JSON_MAX_DEPTH];
-  int parser_top;
-
-  /* The handle for the current buffer. */
-  const upb_bufhandle *handle;
-
-  /* Accumulate buffer.  See details in parser.rl. */
-  const char *accumulated;
-  size_t accumulated_len;
-  char *accumulate_buf;
-  size_t accumulate_buf_size;
-
-  /* Multi-part text data.  See details in parser.rl. */
-  int multipart_state;
-  upb_selector_t string_selector;
-
-  /* Input capture.  See details in parser.rl. */
-  const char *capture;
-
-  /* Intermediate result of parsing a unicode escape sequence. */
-  uint32_t digit;
-
-  /* For resolve type url in Any. */
-  const upb_symtab *symtab;
-
-  /* Whether to proceed if unknown field is met. */
-  bool ignore_json_unknown;
-
-  /* Cache for parsing timestamp due to base and zone are handled in different
-   * handlers. */
-  struct tm tm;
-};
-
-static upb_jsonparser_frame* start_jsonparser_frame(upb_json_parser *p) {
-  upb_jsonparser_frame *inner;
-  inner = p->top + 1;
-  init_frame(inner);
-  return inner;
-}
-
-struct upb_json_codecache {
-  upb_arena *arena;
-  upb_inttable methods;   /* upb_msgdef* -> upb_json_parsermethod* */
-};
-
-struct upb_json_parsermethod {
-  const upb_json_codecache *cache;
-  upb_byteshandler input_handler_;
-
-  /* Maps json_name -> fielddef */
-  upb_strtable name_table;
-};
-
-#define PARSER_CHECK_RETURN(x) if (!(x)) return false
-
-static upb_jsonparser_any_frame *json_parser_any_frame_new(
-    upb_json_parser *p) {
-  upb_jsonparser_any_frame *frame;
-
-  frame = upb_arena_malloc(p->arena, sizeof(upb_jsonparser_any_frame));
-
-  frame->encoder_handlercache = upb_pb_encoder_newcache();
-  frame->parser_codecache = upb_json_codecache_new();
-  frame->parser = NULL;
-  frame->before_type_url_start = NULL;
-  frame->before_type_url_end = NULL;
-  frame->after_type_url_start = NULL;
-
-  upb_stringsink_init(&frame->stringsink);
-
-  return frame;
-}
-
-static void json_parser_any_frame_set_payload_type(
-    upb_json_parser *p,
-    upb_jsonparser_any_frame *frame,
-    const upb_msgdef *payload_type) {
-  const upb_handlers *h;
-  const upb_json_parsermethod *parser_method;
-  upb_pb_encoder *encoder;
-
-  /* Initialize encoder. */
-  h = upb_handlercache_get(frame->encoder_handlercache, payload_type);
-  encoder = upb_pb_encoder_create(p->arena, h, frame->stringsink.sink);
-
-  /* Initialize parser. */
-  parser_method = upb_json_codecache_get(frame->parser_codecache, payload_type);
-  upb_sink_reset(&frame->sink, h, encoder);
-  frame->parser =
-      upb_json_parser_create(p->arena, parser_method, p->symtab, frame->sink,
-                             p->status, p->ignore_json_unknown);
-}
-
-static void json_parser_any_frame_free(upb_jsonparser_any_frame *frame) {
-  upb_handlercache_free(frame->encoder_handlercache);
-  upb_json_codecache_free(frame->parser_codecache);
-  upb_stringsink_uninit(&frame->stringsink);
-}
-
-static bool json_parser_any_frame_has_type_url(
-  upb_jsonparser_any_frame *frame) {
-  return frame->parser != NULL;
-}
-
-static bool json_parser_any_frame_has_value_before_type_url(
-  upb_jsonparser_any_frame *frame) {
-  return frame->before_type_url_start != frame->before_type_url_end;
-}
-
-static bool json_parser_any_frame_has_value_after_type_url(
-  upb_jsonparser_any_frame *frame) {
-  return frame->after_type_url_start != NULL;
-}
-
-static bool json_parser_any_frame_has_value(
-  upb_jsonparser_any_frame *frame) {
-  return json_parser_any_frame_has_value_before_type_url(frame) ||
-         json_parser_any_frame_has_value_after_type_url(frame);
-}
-
-static void json_parser_any_frame_set_before_type_url_end(
-    upb_jsonparser_any_frame *frame,
-    const char *ptr) {
-  if (frame->parser == NULL) {
-    frame->before_type_url_end = ptr;
-  }
-}
-
-static void json_parser_any_frame_set_after_type_url_start_once(
-    upb_jsonparser_any_frame *frame,
-    const char *ptr) {
-  if (json_parser_any_frame_has_type_url(frame) &&
-      frame->after_type_url_start == NULL) {
-    frame->after_type_url_start = ptr;
-  }
-}
-
-/* Used to signal that a capture has been suspended. */
-static char suspend_capture;
-
-static upb_selector_t getsel_for_handlertype(upb_json_parser *p,
-                                             upb_handlertype_t type) {
-  upb_selector_t sel;
-  bool ok = upb_handlers_getselector(p->top->f, type, &sel);
-  UPB_ASSUME(ok);
-  return sel;
-}
-
-static upb_selector_t parser_getsel(upb_json_parser *p) {
-  return getsel_for_handlertype(
-      p, upb_handlers_getprimitivehandlertype(p->top->f));
-}
-
-static bool check_stack(upb_json_parser *p) {
-  if ((p->top + 1) == p->limit) {
-    upb_status_seterrmsg(p->status, "Nesting too deep");
-    return false;
-  }
-
-  return true;
-}
-
-static void set_name_table(upb_json_parser *p, upb_jsonparser_frame *frame) {
-  upb_value v;
-  const upb_json_codecache *cache = p->method->cache;
-  bool ok;
-  const upb_json_parsermethod *method;
-
-  ok = upb_inttable_lookupptr(&cache->methods, frame->m, &v);
-  UPB_ASSUME(ok);
-  method = upb_value_getconstptr(v);
-
-  frame->name_table = &method->name_table;
-}
-
-/* There are GCC/Clang built-ins for overflow checking which we could start
- * using if there was any performance benefit to it. */
-
-static bool checked_add(size_t a, size_t b, size_t *c) {
-  if (SIZE_MAX - a < b) return false;
-  *c = a + b;
-  return true;
-}
-
-static size_t saturating_multiply(size_t a, size_t b) {
-  /* size_t is unsigned, so this is defined behavior even on overflow. */
-  size_t ret = a * b;
-  if (b != 0 && ret / b != a) {
-    ret = SIZE_MAX;
-  }
-  return ret;
-}
-
-
-/* Base64 decoding ************************************************************/
-
-/* TODO(haberman): make this streaming. */
-
-static const signed char b64table[] = {
-  -1,      -1,      -1,      -1,      -1,      -1,      -1,      -1,
-  -1,      -1,      -1,      -1,      -1,      -1,      -1,      -1,
-  -1,      -1,      -1,      -1,      -1,      -1,      -1,      -1,
-  -1,      -1,      -1,      -1,      -1,      -1,      -1,      -1,
-  -1,      -1,      -1,      -1,      -1,      -1,      -1,      -1,
-  -1,      -1,      -1,      62/*+*/, -1,      -1,      -1,      63/*/ */,
-  52/*0*/, 53/*1*/, 54/*2*/, 55/*3*/, 56/*4*/, 57/*5*/, 58/*6*/, 59/*7*/,
-  60/*8*/, 61/*9*/, -1,      -1,      -1,      -1,      -1,      -1,
-  -1,       0/*A*/,  1/*B*/,  2/*C*/,  3/*D*/,  4/*E*/,  5/*F*/,  6/*G*/,
-  07/*H*/,  8/*I*/,  9/*J*/, 10/*K*/, 11/*L*/, 12/*M*/, 13/*N*/, 14/*O*/,
-  15/*P*/, 16/*Q*/, 17/*R*/, 18/*S*/, 19/*T*/, 20/*U*/, 21/*V*/, 22/*W*/,
-  23/*X*/, 24/*Y*/, 25/*Z*/, -1,      -1,      -1,      -1,      -1,
-  -1,      26/*a*/, 27/*b*/, 28/*c*/, 29/*d*/, 30/*e*/, 31/*f*/, 32/*g*/,
-  33/*h*/, 34/*i*/, 35/*j*/, 36/*k*/, 37/*l*/, 38/*m*/, 39/*n*/, 40/*o*/,
-  41/*p*/, 42/*q*/, 43/*r*/, 44/*s*/, 45/*t*/, 46/*u*/, 47/*v*/, 48/*w*/,
-  49/*x*/, 50/*y*/, 51/*z*/, -1,      -1,      -1,      -1,      -1,
-  -1,      -1,      -1,      -1,      -1,      -1,      -1,      -1,
-  -1,      -1,      -1,      -1,      -1,      -1,      -1,      -1,
-  -1,      -1,      -1,      -1,      -1,      -1,      -1,      -1,
-  -1,      -1,      -1,      -1,      -1,      -1,      -1,      -1,
-  -1,      -1,      -1,      -1,      -1,      -1,      -1,      -1,
-  -1,      -1,      -1,      -1,      -1,      -1,      -1,      -1,
-  -1,      -1,      -1,      -1,      -1,      -1,      -1,      -1,
-  -1,      -1,      -1,      -1,      -1,      -1,      -1,      -1,
-  -1,      -1,      -1,      -1,      -1,      -1,      -1,      -1,
-  -1,      -1,      -1,      -1,      -1,      -1,      -1,      -1,
-  -1,      -1,      -1,      -1,      -1,      -1,      -1,      -1,
-  -1,      -1,      -1,      -1,      -1,      -1,      -1,      -1,
-  -1,      -1,      -1,      -1,      -1,      -1,      -1,      -1,
-  -1,      -1,      -1,      -1,      -1,      -1,      -1,      -1,
-  -1,      -1,      -1,      -1,      -1,      -1,      -1,      -1,
-  -1,      -1,      -1,      -1,      -1,      -1,      -1,      -1
-};
-
-/* Returns the table value sign-extended to 32 bits.  Knowing that the upper
- * bits will be 1 for unrecognized characters makes it easier to check for
- * this error condition later (see below). */
-int32_t b64lookup(unsigned char ch) { return b64table[ch]; }
-
-/* Returns true if the given character is not a valid base64 character or
- * padding. */
-bool nonbase64(unsigned char ch) { return b64lookup(ch) == -1 && ch != '='; }
-
-static bool base64_push(upb_json_parser *p, upb_selector_t sel, const char *ptr,
-                        size_t len) {
-  const char *limit = ptr + len;
-  for (; ptr < limit; ptr += 4) {
-    uint32_t val;
-    char output[3];
-
-    if (limit - ptr < 4) {
-      upb_status_seterrf(p->status,
-                         "Base64 input for bytes field not a multiple of 4: %s",
-                         upb_fielddef_name(p->top->f));
-      return false;
-    }
-
-    val = b64lookup(ptr[0]) << 18 |
-          b64lookup(ptr[1]) << 12 |
-          b64lookup(ptr[2]) << 6  |
-          b64lookup(ptr[3]);
-
-    /* Test the upper bit; returns true if any of the characters returned -1. */
-    if (val & 0x80000000) {
-      goto otherchar;
-    }
-
-    output[0] = val >> 16;
-    output[1] = (val >> 8) & 0xff;
-    output[2] = val & 0xff;
-    upb_sink_putstring(p->top->sink, sel, output, 3, NULL);
-  }
-  return true;
-
-otherchar:
-  if (nonbase64(ptr[0]) || nonbase64(ptr[1]) || nonbase64(ptr[2]) ||
-      nonbase64(ptr[3]) ) {
-    upb_status_seterrf(p->status,
-                       "Non-base64 characters in bytes field: %s",
-                       upb_fielddef_name(p->top->f));
-    return false;
-  } if (ptr[2] == '=') {
-    uint32_t val;
-    char output;
-
-    /* Last group contains only two input bytes, one output byte. */
-    if (ptr[0] == '=' || ptr[1] == '=' || ptr[3] != '=') {
-      goto badpadding;
-    }
-
-    val = b64lookup(ptr[0]) << 18 |
-          b64lookup(ptr[1]) << 12;
-
-    UPB_ASSERT(!(val & 0x80000000));
-    output = val >> 16;
-    upb_sink_putstring(p->top->sink, sel, &output, 1, NULL);
-    return true;
-  } else {
-    uint32_t val;
-    char output[2];
-
-    /* Last group contains only three input bytes, two output bytes. */
-    if (ptr[0] == '=' || ptr[1] == '=' || ptr[2] == '=') {
-      goto badpadding;
-    }
-
-    val = b64lookup(ptr[0]) << 18 |
-          b64lookup(ptr[1]) << 12 |
-          b64lookup(ptr[2]) << 6;
-
-    output[0] = val >> 16;
-    output[1] = (val >> 8) & 0xff;
-    upb_sink_putstring(p->top->sink, sel, output, 2, NULL);
-    return true;
-  }
-
-badpadding:
-  upb_status_seterrf(p->status,
-                     "Incorrect base64 padding for field: %s (%.*s)",
-                     upb_fielddef_name(p->top->f),
-                     4, ptr);
-  return false;
-}
-
-
-/* Accumulate buffer **********************************************************/
-
-/* Functionality for accumulating a buffer.
- *
- * Some parts of the parser need an entire value as a contiguous string.  For
- * example, to look up a member name in a hash table, or to turn a string into
- * a number, the relevant library routines need the input string to be in
- * contiguous memory, even if the value spanned two or more buffers in the
- * input.  These routines handle that.
- *
- * In the common case we can just point to the input buffer to get this
- * contiguous string and avoid any actual copy.  So we optimistically begin
- * this way.  But there are a few cases where we must instead copy into a
- * separate buffer:
- *
- *   1. The string was not contiguous in the input (it spanned buffers).
- *
- *   2. The string included escape sequences that need to be interpreted to get
- *      the true value in a contiguous buffer. */
-
-static void assert_accumulate_empty(upb_json_parser *p) {
-  UPB_ASSERT(p->accumulated == NULL);
-  UPB_ASSERT(p->accumulated_len == 0);
-}
-
-static void accumulate_clear(upb_json_parser *p) {
-  p->accumulated = NULL;
-  p->accumulated_len = 0;
-}
-
-/* Used internally by accumulate_append(). */
-static bool accumulate_realloc(upb_json_parser *p, size_t need) {
-  void *mem;
-  size_t old_size = p->accumulate_buf_size;
-  size_t new_size = UPB_MAX(old_size, 128);
-  while (new_size < need) {
-    new_size = saturating_multiply(new_size, 2);
-  }
-
-  mem = upb_arena_realloc(p->arena, p->accumulate_buf, old_size, new_size);
-  if (!mem) {
-    upb_status_seterrmsg(p->status, "Out of memory allocating buffer.");
-    return false;
-  }
-
-  p->accumulate_buf = mem;
-  p->accumulate_buf_size = new_size;
-  return true;
-}
-
-/* Logically appends the given data to the append buffer.
- * If "can_alias" is true, we will try to avoid actually copying, but the buffer
- * must be valid until the next accumulate_append() call (if any). */
-static bool accumulate_append(upb_json_parser *p, const char *buf, size_t len,
-                              bool can_alias) {
-  size_t need;
-
-  if (!p->accumulated && can_alias) {
-    p->accumulated = buf;
-    p->accumulated_len = len;
-    return true;
-  }
-
-  if (!checked_add(p->accumulated_len, len, &need)) {
-    upb_status_seterrmsg(p->status, "Integer overflow.");
-    return false;
-  }
-
-  if (need > p->accumulate_buf_size && !accumulate_realloc(p, need)) {
-    return false;
-  }
-
-  if (p->accumulated != p->accumulate_buf) {
-    if (p->accumulated_len) {
-      memcpy(p->accumulate_buf, p->accumulated, p->accumulated_len);
-    }
-    p->accumulated = p->accumulate_buf;
-  }
-
-  memcpy(p->accumulate_buf + p->accumulated_len, buf, len);
-  p->accumulated_len += len;
-  return true;
-}
-
-/* Returns a pointer to the data accumulated since the last accumulate_clear()
- * call, and writes the length to *len.  This with point either to the input
- * buffer or a temporary accumulate buffer. */
-static const char *accumulate_getptr(upb_json_parser *p, size_t *len) {
-  UPB_ASSERT(p->accumulated);
-  *len = p->accumulated_len;
-  return p->accumulated;
-}
-
-
-/* Mult-part text data ********************************************************/
-
-/* When we have text data in the input, it can often come in multiple segments.
- * For example, there may be some raw string data followed by an escape
- * sequence.  The two segments are processed with different logic.  Also buffer
- * seams in the input can cause multiple segments.
- *
- * As we see segments, there are two main cases for how we want to process them:
- *
- *  1. we want to push the captured input directly to string handlers.
- *
- *  2. we need to accumulate all the parts into a contiguous buffer for further
- *     processing (field name lookup, string->number conversion, etc). */
-
-/* This is the set of states for p->multipart_state. */
-enum {
-  /* We are not currently processing multipart data. */
-  MULTIPART_INACTIVE = 0,
-
-  /* We are processing multipart data by accumulating it into a contiguous
-   * buffer. */
-  MULTIPART_ACCUMULATE = 1,
-
-  /* We are processing multipart data by pushing each part directly to the
-   * current string handlers. */
-  MULTIPART_PUSHEAGERLY = 2
-};
-
-/* Start a multi-part text value where we accumulate the data for processing at
- * the end. */
-static void multipart_startaccum(upb_json_parser *p) {
-  assert_accumulate_empty(p);
-  UPB_ASSERT(p->multipart_state == MULTIPART_INACTIVE);
-  p->multipart_state = MULTIPART_ACCUMULATE;
-}
-
-/* Start a multi-part text value where we immediately push text data to a string
- * value with the given selector. */
-static void multipart_start(upb_json_parser *p, upb_selector_t sel) {
-  assert_accumulate_empty(p);
-  UPB_ASSERT(p->multipart_state == MULTIPART_INACTIVE);
-  p->multipart_state = MULTIPART_PUSHEAGERLY;
-  p->string_selector = sel;
-}
-
-static bool multipart_text(upb_json_parser *p, const char *buf, size_t len,
-                           bool can_alias) {
-  switch (p->multipart_state) {
-    case MULTIPART_INACTIVE:
-      upb_status_seterrmsg(
-          p->status, "Internal error: unexpected state MULTIPART_INACTIVE");
-      return false;
-
-    case MULTIPART_ACCUMULATE:
-      if (!accumulate_append(p, buf, len, can_alias)) {
-        return false;
-      }
-      break;
-
-    case MULTIPART_PUSHEAGERLY: {
-      const upb_bufhandle *handle = can_alias ? p->handle : NULL;
-      upb_sink_putstring(p->top->sink, p->string_selector, buf, len, handle);
-      break;
-    }
-  }
-
-  return true;
-}
-
-/* Note: this invalidates the accumulate buffer!  Call only after reading its
- * contents. */
-static void multipart_end(upb_json_parser *p) {
-  /* This is false sometimes. Probably a bug of some sort, but this code is
-   * intended for deletion soon. */
-  /* UPB_ASSERT(p->multipart_state != MULTIPART_INACTIVE); */
-  p->multipart_state = MULTIPART_INACTIVE;
-  accumulate_clear(p);
-}
-
-
-/* Input capture **************************************************************/
-
-/* Functionality for capturing a region of the input as text.  Gracefully
- * handles the case where a buffer seam occurs in the middle of the captured
- * region. */
-
-static void capture_begin(upb_json_parser *p, const char *ptr) {
-  UPB_ASSERT(p->multipart_state != MULTIPART_INACTIVE);
-  UPB_ASSERT(p->capture == NULL);
-  p->capture = ptr;
-}
-
-static bool capture_end(upb_json_parser *p, const char *ptr) {
-  UPB_ASSERT(p->capture);
-  if (multipart_text(p, p->capture, ptr - p->capture, true)) {
-    p->capture = NULL;
-    return true;
-  } else {
-    return false;
-  }
-}
-
-/* This is called at the end of each input buffer (ie. when we have hit a
- * buffer seam).  If we are in the middle of capturing the input, this
- * processes the unprocessed capture region. */
-static void capture_suspend(upb_json_parser *p, const char **ptr) {
-  if (!p->capture) return;
-
-  if (multipart_text(p, p->capture, *ptr - p->capture, false)) {
-    /* We use this as a signal that we were in the middle of capturing, and
-     * that capturing should resume at the beginning of the next buffer.
-     * 
-     * We can't use *ptr here, because we have no guarantee that this pointer
-     * will be valid when we resume (if the underlying memory is freed, then
-     * using the pointer at all, even to compare to NULL, is likely undefined
-     * behavior). */
-    p->capture = &suspend_capture;
-  } else {
-    /* Need to back up the pointer to the beginning of the capture, since
-     * we were not able to actually preserve it. */
-    *ptr = p->capture;
-  }
-}
-
-static void capture_resume(upb_json_parser *p, const char *ptr) {
-  if (p->capture) {
-    UPB_ASSERT(p->capture == &suspend_capture);
-    p->capture = ptr;
-  }
-}
-
-
-/* Callbacks from the parser **************************************************/
-
-/* These are the functions called directly from the parser itself.
- * We define these in the same order as their declarations in the parser. */
-
-static char escape_char(char in) {
-  switch (in) {
-    case 'r': return '\r';
-    case 't': return '\t';
-    case 'n': return '\n';
-    case 'f': return '\f';
-    case 'b': return '\b';
-    case '/': return '/';
-    case '"': return '"';
-    case '\\': return '\\';
-    default:
-      UPB_ASSERT(0);
-      return 'x';
-  }
-}
-
-static bool escape(upb_json_parser *p, const char *ptr) {
-  char ch = escape_char(*ptr);
-  return multipart_text(p, &ch, 1, false);
-}
-
-static void start_hex(upb_json_parser *p) {
-  p->digit = 0;
-}
-
-static void hexdigit(upb_json_parser *p, const char *ptr) {
-  char ch = *ptr;
-
-  p->digit <<= 4;
-
-  if (ch >= '0' && ch <= '9') {
-    p->digit += (ch - '0');
-  } else if (ch >= 'a' && ch <= 'f') {
-    p->digit += ((ch - 'a') + 10);
-  } else {
-    UPB_ASSERT(ch >= 'A' && ch <= 'F');
-    p->digit += ((ch - 'A') + 10);
-  }
-}
-
-static bool end_hex(upb_json_parser *p) {
-  uint32_t codepoint = p->digit;
-
-  /* emit the codepoint as UTF-8. */
-  char utf8[3]; /* support \u0000 -- \uFFFF -- need only three bytes. */
-  int length = 0;
-  if (codepoint <= 0x7F) {
-    utf8[0] = codepoint;
-    length = 1;
-  } else if (codepoint <= 0x07FF) {
-    utf8[1] = (codepoint & 0x3F) | 0x80;
-    codepoint >>= 6;
-    utf8[0] = (codepoint & 0x1F) | 0xC0;
-    length = 2;
-  } else /* codepoint <= 0xFFFF */ {
-    utf8[2] = (codepoint & 0x3F) | 0x80;
-    codepoint >>= 6;
-    utf8[1] = (codepoint & 0x3F) | 0x80;
-    codepoint >>= 6;
-    utf8[0] = (codepoint & 0x0F) | 0xE0;
-    length = 3;
-  }
-  /* TODO(haberman): Handle high surrogates: if codepoint is a high surrogate
-   * we have to wait for the next escape to get the full code point). */
-
-  return multipart_text(p, utf8, length, false);
-}
-
-static void start_text(upb_json_parser *p, const char *ptr) {
-  capture_begin(p, ptr);
-}
-
-static bool end_text(upb_json_parser *p, const char *ptr) {
-  return capture_end(p, ptr);
-}
-
-static bool start_number(upb_json_parser *p, const char *ptr) {
-  if (is_top_level(p)) {
-    if (is_number_wrapper_object(p)) {
-      start_wrapper_object(p);
-    } else if (is_wellknown_msg(p, UPB_WELLKNOWN_VALUE)) {
-      start_value_object(p, VALUE_NUMBERVALUE);
-    } else {
-      return false;
-    }
-  } else if (does_number_wrapper_start(p)) {
-    if (!start_subobject(p)) {
-      return false;
-    }
-    start_wrapper_object(p);
-  } else if (is_wellknown_field(p, UPB_WELLKNOWN_VALUE)) {
-    if (!start_subobject(p)) {
-      return false;
-    }
-    start_value_object(p, VALUE_NUMBERVALUE);
-  }
-
-  multipart_startaccum(p);
-  capture_begin(p, ptr);
-  return true;
-}
-
-static bool parse_number(upb_json_parser *p, bool is_quoted);
-
-static bool end_number_nontop(upb_json_parser *p, const char *ptr) {
-  if (!capture_end(p, ptr)) {
-    return false;
-  }
-
-  if (p->top->f == NULL) {
-    multipart_end(p);
-    return true;
-  }
-
-  return parse_number(p, false);
-}
-
-static bool end_number(upb_json_parser *p, const char *ptr) {
-  if (!end_number_nontop(p, ptr)) {
-    return false;
-  }
-
-  if (does_number_wrapper_end(p)) {
-    end_wrapper_object(p);
-    if (!is_top_level(p)) {
-      end_subobject(p);
-    }
-    return true;
-  }
-
-  if (is_wellknown_msg(p, UPB_WELLKNOWN_VALUE)) {
-    end_value_object(p);
-    if (!is_top_level(p)) {
-      end_subobject(p);
-    }
-    return true;
-  }
-
-  return true;
-}
-
-/* |buf| is NULL-terminated. |buf| itself will never include quotes;
- * |is_quoted| tells us whether this text originally appeared inside quotes. */
-static bool parse_number_from_buffer(upb_json_parser *p, const char *buf,
-                                     bool is_quoted) {
-  size_t len = strlen(buf);
-  const char *bufend = buf + len;
-  char *end;
-  upb_fieldtype_t type = upb_fielddef_type(p->top->f);
-  double val;
-  double dummy;
-  double inf = INFINITY;
-
-  errno = 0;
-
-  if (len == 0 || buf[0] == ' ') {
-    return false;
-  }
-
-  /* For integer types, first try parsing with integer-specific routines.
-   * If these succeed, they will be more accurate for int64/uint64 than
-   * strtod().
-   */
-  switch (type) {
-    case UPB_TYPE_ENUM:
-    case UPB_TYPE_INT32: {
-      long val = strtol(buf, &end, 0);
-      if (errno == ERANGE || end != bufend) {
-        break;
-      } else if (val > INT32_MAX || val < INT32_MIN) {
-        return false;
-      } else {
-        upb_sink_putint32(p->top->sink, parser_getsel(p), (int32_t)val);
-        return true;
-      }
-      UPB_UNREACHABLE();
-    }
-    case UPB_TYPE_UINT32: {
-      unsigned long val = strtoul(buf, &end, 0);
-      if (end != bufend) {
-        break;
-      } else if (val > UINT32_MAX || errno == ERANGE) {
-        return false;
-      } else {
-        upb_sink_putuint32(p->top->sink, parser_getsel(p), (uint32_t)val);
-        return true;
-      }
-      UPB_UNREACHABLE();
-    }
-    /* XXX: We can't handle [u]int64 properly on 32-bit machines because
-     * strto[u]ll isn't in C89. */
-    case UPB_TYPE_INT64: {
-      long val = strtol(buf, &end, 0);
-      if (errno == ERANGE || end != bufend) {
-        break;
-      } else {
-        upb_sink_putint64(p->top->sink, parser_getsel(p), val);
-        return true;
-      }
-      UPB_UNREACHABLE();
-    }
-    case UPB_TYPE_UINT64: {
-      unsigned long val = strtoul(p->accumulated, &end, 0);
-      if (end != bufend) {
-        break;
-      } else if (errno == ERANGE) {
-        return false;
-      } else {
-        upb_sink_putuint64(p->top->sink, parser_getsel(p), val);
-        return true;
-      }
-      UPB_UNREACHABLE();
-    }
-    default:
-      break;
-  }
-
-  if (type != UPB_TYPE_DOUBLE && type != UPB_TYPE_FLOAT && is_quoted) {
-    /* Quoted numbers for integer types are not allowed to be in double form. */
-    return false;
-  }
-
-  if (len == strlen("Infinity") && strcmp(buf, "Infinity") == 0) {
-    /* C89 does not have an INFINITY macro. */
-    val = inf;
-  } else if (len == strlen("-Infinity") && strcmp(buf, "-Infinity") == 0) {
-    val = -inf;
-  } else {
-    val = strtod(buf, &end);
-    if (errno == ERANGE || end != bufend) {
-      return false;
-    }
-  }
-
-  switch (type) {
-#define CASE(capitaltype, smalltype, ctype, min, max)                     \
-    case UPB_TYPE_ ## capitaltype: {                                      \
-      if (modf(val, &dummy) != 0 || val > max || val < min) {             \
-        return false;                                                     \
-      } else {                                                            \
-        upb_sink_put ## smalltype(p->top->sink, parser_getsel(p),        \
-                                  (ctype)val);                            \
-        return true;                                                      \
-      }                                                                   \
-      break;                                                              \
-    }
-    case UPB_TYPE_ENUM:
-    CASE(INT32, int32, int32_t, INT32_MIN, INT32_MAX);
-    CASE(INT64, int64, int64_t, INT64_MIN, INT64_MAX);
-    CASE(UINT32, uint32, uint32_t, 0, UINT32_MAX);
-    CASE(UINT64, uint64, uint64_t, 0, UINT64_MAX);
-#undef CASE
-
-    case UPB_TYPE_DOUBLE:
-      upb_sink_putdouble(p->top->sink, parser_getsel(p), val);
-      return true;
-    case UPB_TYPE_FLOAT:
-      if ((val > FLT_MAX || val < -FLT_MAX) && val != inf && val != -inf) {
-        return false;
-      } else {
-        upb_sink_putfloat(p->top->sink, parser_getsel(p), val);
-        return true;
-      }
-    default:
-      return false;
-  }
-}
-
-static bool parse_number(upb_json_parser *p, bool is_quoted) {
-  size_t len;
-  const char *buf;
-
-  /* strtol() and friends unfortunately do not support specifying the length of
-   * the input string, so we need to force a copy into a NULL-terminated buffer. */
-  if (!multipart_text(p, "\0", 1, false)) {
-    return false;
-  }
-
-  buf = accumulate_getptr(p, &len);
-
-  if (parse_number_from_buffer(p, buf, is_quoted)) {
-    multipart_end(p);
-    return true;
-  } else {
-    upb_status_seterrf(p->status, "error parsing number: %s", buf);
-    multipart_end(p);
-    return false;
-  }
-}
-
-static bool parser_putbool(upb_json_parser *p, bool val) {
-  bool ok;
-
-  if (p->top->f == NULL) {
-    return true;
-  }
-
-  if (upb_fielddef_type(p->top->f) != UPB_TYPE_BOOL) {
-    upb_status_seterrf(p->status,
-                       "Boolean value specified for non-bool field: %s",
-                       upb_fielddef_name(p->top->f));
-    return false;
-  }
-
-  ok = upb_sink_putbool(p->top->sink, parser_getsel(p), val);
-  UPB_ASSERT(ok);
-
-  return true;
-}
-
-static bool end_bool(upb_json_parser *p, bool val) {
-  if (is_top_level(p)) {
-    if (is_wellknown_msg(p, UPB_WELLKNOWN_BOOLVALUE)) {
-      start_wrapper_object(p);
-    } else if (is_wellknown_msg(p, UPB_WELLKNOWN_VALUE)) {
-      start_value_object(p, VALUE_BOOLVALUE);
-    } else {
-      return false;
-    }
-  } else if (is_wellknown_field(p, UPB_WELLKNOWN_BOOLVALUE)) {
-    if (!start_subobject(p)) {
-      return false;
-    }
-    start_wrapper_object(p);
-  } else if (is_wellknown_field(p, UPB_WELLKNOWN_VALUE)) {
-    if (!start_subobject(p)) {
-      return false;
-    }
-    start_value_object(p, VALUE_BOOLVALUE);
-  }
-
-  if (p->top->is_unknown_field) {
-    return true;
-  }
-
-  if (!parser_putbool(p, val)) {
-    return false;
-  }
-
-  if (is_wellknown_msg(p, UPB_WELLKNOWN_BOOLVALUE)) {
-    end_wrapper_object(p);
-    if (!is_top_level(p)) {
-      end_subobject(p);
-    }
-    return true;
-  }
-
-  if (is_wellknown_msg(p, UPB_WELLKNOWN_VALUE)) {
-    end_value_object(p);
-    if (!is_top_level(p)) {
-      end_subobject(p);
-    }
-    return true;
-  }
-
-  return true;
-}
-
-static bool end_null(upb_json_parser *p) {
-  const char *zero_ptr = "0";
-
-  if (is_top_level(p)) {
-    if (is_wellknown_msg(p, UPB_WELLKNOWN_VALUE)) {
-      start_value_object(p, VALUE_NULLVALUE);
-    } else {
-      return true;
-    }
-  } else if (is_wellknown_field(p, UPB_WELLKNOWN_VALUE)) {
-    if (!start_subobject(p)) {
-      return false;
-    }
-    start_value_object(p, VALUE_NULLVALUE);
-  } else {
-    return true;
-  }
-
-  /* Fill null_value field. */
-  multipart_startaccum(p);
-  capture_begin(p, zero_ptr);
-  capture_end(p, zero_ptr + 1);
-  parse_number(p, false);
-
-  end_value_object(p);
-  if (!is_top_level(p)) {
-    end_subobject(p);
-  }
-
-  return true;
-}
-
-static bool start_any_stringval(upb_json_parser *p) {
-  multipart_startaccum(p);
-  return true;
-}
-
-static bool start_stringval(upb_json_parser *p) {
-  if (is_top_level(p)) {
-    if (is_string_wrapper_object(p) ||
-        is_number_wrapper_object(p)) {
-      start_wrapper_object(p);
-    } else if (is_wellknown_msg(p, UPB_WELLKNOWN_FIELDMASK)) {
-      start_fieldmask_object(p);
-      return true;
-    } else if (is_wellknown_msg(p, UPB_WELLKNOWN_TIMESTAMP) ||
-               is_wellknown_msg(p, UPB_WELLKNOWN_DURATION)) {
-      start_object(p);
-    } else if (is_wellknown_msg(p, UPB_WELLKNOWN_VALUE)) {
-      start_value_object(p, VALUE_STRINGVALUE);
-    } else {
-      return false;
-    }
-  } else if (does_string_wrapper_start(p) ||
-             does_number_wrapper_start(p)) {
-    if (!start_subobject(p)) {
-      return false;
-    }
-    start_wrapper_object(p);
-  } else if (does_fieldmask_start(p)) {
-    if (!start_subobject(p)) {
-      return false;
-    }
-    start_fieldmask_object(p);
-    return true;
-  } else if (is_wellknown_field(p, UPB_WELLKNOWN_TIMESTAMP) ||
-             is_wellknown_field(p, UPB_WELLKNOWN_DURATION)) {
-    if (!start_subobject(p)) {
-      return false;
-    }
-    start_object(p);
-  } else if (is_wellknown_field(p, UPB_WELLKNOWN_VALUE)) {
-    if (!start_subobject(p)) {
-      return false;
-    }
-    start_value_object(p, VALUE_STRINGVALUE);
-  }
-
-  if (p->top->f == NULL) {
-    multipart_startaccum(p);
-    return true;
-  }
-
-  if (p->top->is_any) {
-    return start_any_stringval(p);
-  }
-
-  if (upb_fielddef_isstring(p->top->f)) {
-    upb_jsonparser_frame *inner;
-    upb_selector_t sel;
-
-    if (!check_stack(p)) return false;
-
-    /* Start a new parser frame: parser frames correspond one-to-one with
-     * handler frames, and string events occur in a sub-frame. */
-    inner = start_jsonparser_frame(p);
-    sel = getsel_for_handlertype(p, UPB_HANDLER_STARTSTR);
-    upb_sink_startstr(p->top->sink, sel, 0, &inner->sink);
-    inner->m = p->top->m;
-    inner->f = p->top->f;
-    p->top = inner;
-
-    if (upb_fielddef_type(p->top->f) == UPB_TYPE_STRING) {
-      /* For STRING fields we push data directly to the handlers as it is
-       * parsed.  We don't do this yet for BYTES fields, because our base64
-       * decoder is not streaming.
-       *
-       * TODO(haberman): make base64 decoding streaming also. */
-      multipart_start(p, getsel_for_handlertype(p, UPB_HANDLER_STRING));
-      return true;
-    } else {
-      multipart_startaccum(p);
-      return true;
-    }
-  } else if (upb_fielddef_type(p->top->f) != UPB_TYPE_BOOL &&
-             upb_fielddef_type(p->top->f) != UPB_TYPE_MESSAGE) {
-    /* No need to push a frame -- numeric values in quotes remain in the
-     * current parser frame.  These values must accmulate so we can convert
-     * them all at once at the end. */
-    multipart_startaccum(p);
-    return true;
-  } else {
-    upb_status_seterrf(p->status,
-                       "String specified for bool or submessage field: %s",
-                       upb_fielddef_name(p->top->f));
-    return false;
-  }
-}
-
-static bool end_any_stringval(upb_json_parser *p) {
-  size_t len;
-  const char *buf = accumulate_getptr(p, &len);
-
-  /* Set type_url */
-  upb_selector_t sel;
-  upb_jsonparser_frame *inner;
-  if (!check_stack(p)) return false;
-  inner = p->top + 1;
-
-  sel = getsel_for_handlertype(p, UPB_HANDLER_STARTSTR);
-  upb_sink_startstr(p->top->sink, sel, 0, &inner->sink);
-  sel = getsel_for_handlertype(p, UPB_HANDLER_STRING);
-  upb_sink_putstring(inner->sink, sel, buf, len, NULL);
-  sel = getsel_for_handlertype(p, UPB_HANDLER_ENDSTR);
-  upb_sink_endstr(inner->sink, sel);
-
-  multipart_end(p);
-
-  /* Resolve type url */
-  if (strncmp(buf, "type.googleapis.com/", 20) == 0 && len > 20) {
-    const upb_msgdef *payload_type = NULL;
-    buf += 20;
-    len -= 20;
-
-    payload_type = upb_symtab_lookupmsg2(p->symtab, buf, len);
-    if (payload_type == NULL) {
-      upb_status_seterrf(
-          p->status, "Cannot find packed type: %.*s\n", (int)len, buf);
-      return false;
-    }
-
-    json_parser_any_frame_set_payload_type(p, p->top->any_frame, payload_type);
-
-    return true;
-  } else {
-    upb_status_seterrf(
-        p->status, "Invalid type url: %.*s\n", (int)len, buf);
-    return false;
-  }
-}
-
-static bool end_stringval_nontop(upb_json_parser *p) {
-  bool ok = true;
-
-  if (is_wellknown_msg(p, UPB_WELLKNOWN_TIMESTAMP) ||
-      is_wellknown_msg(p, UPB_WELLKNOWN_DURATION)) {
-    multipart_end(p);
-    return true;
-  }
-
-  if (p->top->f == NULL) {
-    multipart_end(p);
-    return true;
-  }
-
-  if (p->top->is_any) {
-    return end_any_stringval(p);
-  }
-
-  switch (upb_fielddef_type(p->top->f)) {
-    case UPB_TYPE_BYTES:
-      if (!base64_push(p, getsel_for_handlertype(p, UPB_HANDLER_STRING),
-                       p->accumulated, p->accumulated_len)) {
-        return false;
-      }
-      /* Fall through. */
-
-    case UPB_TYPE_STRING: {
-      upb_selector_t sel = getsel_for_handlertype(p, UPB_HANDLER_ENDSTR);
-      upb_sink_endstr(p->top->sink, sel);
-      p->top--;
-      break;
-    }
-
-    case UPB_TYPE_ENUM: {
-      /* Resolve enum symbolic name to integer value. */
-      const upb_enumdef *enumdef = upb_fielddef_enumsubdef(p->top->f);
-
-      size_t len;
-      const char *buf = accumulate_getptr(p, &len);
-
-      int32_t int_val = 0;
-      ok = upb_enumdef_ntoi(enumdef, buf, len, &int_val);
-
-      if (ok) {
-        upb_selector_t sel = parser_getsel(p);
-        upb_sink_putint32(p->top->sink, sel, int_val);
-      } else {
-        if (p->ignore_json_unknown) {
-          ok = true;
-          /* TODO(teboring): Should also clean this field. */
-        } else {
-          upb_status_seterrf(p->status, "Enum value unknown: '%.*s'", len, buf);
-        }
-      }
-
-      break;
-    }
-
-    case UPB_TYPE_INT32:
-    case UPB_TYPE_INT64:
-    case UPB_TYPE_UINT32:
-    case UPB_TYPE_UINT64:
-    case UPB_TYPE_DOUBLE:
-    case UPB_TYPE_FLOAT:
-      ok = parse_number(p, true);
-      break;
-
-    default:
-      UPB_ASSERT(false);
-      upb_status_seterrmsg(p->status, "Internal error in JSON decoder");
-      ok = false;
-      break;
-  }
-
-  multipart_end(p);
-
-  return ok;
-}
-
-static bool end_stringval(upb_json_parser *p) {
-  /* FieldMask's stringvals have been ended when handling them. Only need to
-   * close FieldMask here.*/
-  if (does_fieldmask_end(p)) {
-    end_fieldmask_object(p);
-    if (!is_top_level(p)) {
-      end_subobject(p);
-    }
-    return true;
-  }
-
-  if (!end_stringval_nontop(p)) {
-    return false;
-  }
-
-  if (does_string_wrapper_end(p) ||
-      does_number_wrapper_end(p)) {
-    end_wrapper_object(p);
-    if (!is_top_level(p)) {
-      end_subobject(p);
-    }
-    return true;
-  }
-
-  if (is_wellknown_msg(p, UPB_WELLKNOWN_VALUE)) {
-    end_value_object(p);
-    if (!is_top_level(p)) {
-      end_subobject(p);
-    }
-    return true;
-  }
-
-  if (is_wellknown_msg(p, UPB_WELLKNOWN_TIMESTAMP) ||
-      is_wellknown_msg(p, UPB_WELLKNOWN_DURATION) ||
-      is_wellknown_msg(p, UPB_WELLKNOWN_FIELDMASK)) {
-    end_object(p);
-    if (!is_top_level(p)) {
-      end_subobject(p);
-    }
-    return true;
-  }
-
-  return true;
-}
-
-static void start_duration_base(upb_json_parser *p, const char *ptr) {
-  capture_begin(p, ptr);
-}
-
-static bool end_duration_base(upb_json_parser *p, const char *ptr) {
-  size_t len;
-  const char *buf;
-  char seconds_buf[14];
-  char nanos_buf[12];
-  char *end;
-  int64_t seconds = 0;
-  int32_t nanos = 0;
-  double val = 0.0;
-  const char *seconds_membername = "seconds";
-  const char *nanos_membername = "nanos";
-  size_t fraction_start;
-
-  if (!capture_end(p, ptr)) {
-    return false;
-  }
-
-  buf = accumulate_getptr(p, &len);
-
-  memset(seconds_buf, 0, 14);
-  memset(nanos_buf, 0, 12);
-
-  /* Find out base end. The maximus duration is 315576000000, which cannot be
-   * represented by double without losing precision. Thus, we need to handle
-   * fraction and base separately. */
-  for (fraction_start = 0; fraction_start < len && buf[fraction_start] != '.';
-       fraction_start++);
-
-  /* Parse base */
-  memcpy(seconds_buf, buf, fraction_start);
-  seconds = strtol(seconds_buf, &end, 10);
-  if (errno == ERANGE || end != seconds_buf + fraction_start) {
-    upb_status_seterrf(p->status, "error parsing duration: %s",
-                       seconds_buf);
-    return false;
-  }
-
-  if (seconds > 315576000000) {
-    upb_status_seterrf(p->status, "error parsing duration: "
-                                   "maximum acceptable value is "
-                                   "315576000000");
-    return false;
-  }
-
-  if (seconds < -315576000000) {
-    upb_status_seterrf(p->status, "error parsing duration: "
-                                   "minimum acceptable value is "
-                                   "-315576000000");
-    return false;
-  }
-
-  /* Parse fraction */
-  nanos_buf[0] = '0';
-  memcpy(nanos_buf + 1, buf + fraction_start, len - fraction_start);
-  val = strtod(nanos_buf, &end);
-  if (errno == ERANGE || end != nanos_buf + len - fraction_start + 1) {
-    upb_status_seterrf(p->status, "error parsing duration: %s",
-                       nanos_buf);
-    return false;
-  }
-
-  nanos = val * 1000000000;
-  if (seconds < 0) nanos = -nanos;
-
-  /* Clean up buffer */
-  multipart_end(p);
-
-  /* Set seconds */
-  start_member(p);
-  capture_begin(p, seconds_membername);
-  capture_end(p, seconds_membername + 7);
-  end_membername(p);
-  upb_sink_putint64(p->top->sink, parser_getsel(p), seconds);
-  end_member(p);
-
-  /* Set nanos */
-  start_member(p);
-  capture_begin(p, nanos_membername);
-  capture_end(p, nanos_membername + 5);
-  end_membername(p);
-  upb_sink_putint32(p->top->sink, parser_getsel(p), nanos);
-  end_member(p);
-
-  /* Continue previous arena */
-  multipart_startaccum(p);
-
-  return true;
-}
-
-static int parse_timestamp_number(upb_json_parser *p) {
-  size_t len;
-  const char *buf;
-  int val;
-
-  /* atoi() and friends unfortunately do not support specifying the length of
-   * the input string, so we need to force a copy into a NULL-terminated buffer. */
-  multipart_text(p, "\0", 1, false);
-
-  buf = accumulate_getptr(p, &len);
-  val = atoi(buf);
-  multipart_end(p);
-  multipart_startaccum(p);
-
-  return val;
-}
-
-static void start_year(upb_json_parser *p, const char *ptr) {
-  capture_begin(p, ptr);
-}
-
-static bool end_year(upb_json_parser *p, const char *ptr) {
-  if (!capture_end(p, ptr)) {
-    return false;
-  }
-  p->tm.tm_year = parse_timestamp_number(p) - 1900;
-  return true;
-}
-
-static void start_month(upb_json_parser *p, const char *ptr) {
-  capture_begin(p, ptr);
-}
-
-static bool end_month(upb_json_parser *p, const char *ptr) {
-  if (!capture_end(p, ptr)) {
-    return false;
-  }
-  p->tm.tm_mon = parse_timestamp_number(p) - 1;
-  return true;
-}
-
-static void start_day(upb_json_parser *p, const char *ptr) {
-  capture_begin(p, ptr);
-}
-
-static bool end_day(upb_json_parser *p, const char *ptr) {
-  if (!capture_end(p, ptr)) {
-    return false;
-  }
-  p->tm.tm_mday = parse_timestamp_number(p);
-  return true;
-}
-
-static void start_hour(upb_json_parser *p, const char *ptr) {
-  capture_begin(p, ptr);
-}
-
-static bool end_hour(upb_json_parser *p, const char *ptr) {
-  if (!capture_end(p, ptr)) {
-    return false;
-  }
-  p->tm.tm_hour = parse_timestamp_number(p);
-  return true;
-}
-
-static void start_minute(upb_json_parser *p, const char *ptr) {
-  capture_begin(p, ptr);
-}
-
-static bool end_minute(upb_json_parser *p, const char *ptr) {
-  if (!capture_end(p, ptr)) {
-    return false;
-  }
-  p->tm.tm_min = parse_timestamp_number(p);
-  return true;
-}
-
-static void start_second(upb_json_parser *p, const char *ptr) {
-  capture_begin(p, ptr);
-}
-
-static bool end_second(upb_json_parser *p, const char *ptr) {
-  if (!capture_end(p, ptr)) {
-    return false;
-  }
-  p->tm.tm_sec = parse_timestamp_number(p);
-  return true;
-}
-
-static void start_timestamp_base(upb_json_parser *p) {
-  memset(&p->tm, 0, sizeof(struct tm));
-}
-
-static void start_timestamp_fraction(upb_json_parser *p, const char *ptr) {
-  capture_begin(p, ptr);
-}
-
-static bool end_timestamp_fraction(upb_json_parser *p, const char *ptr) {
-  size_t len;
-  const char *buf;
-  char nanos_buf[12];
-  char *end;
-  double val = 0.0;
-  int32_t nanos;
-  const char *nanos_membername = "nanos";
-
-  memset(nanos_buf, 0, 12);
-
-  if (!capture_end(p, ptr)) {
-    return false;
-  }
-
-  buf = accumulate_getptr(p, &len);
-
-  if (len > 10) {
-    upb_status_seterrf(p->status,
-        "error parsing timestamp: at most 9-digit fraction.");
-    return false;
-  }
-
-  /* Parse nanos */
-  nanos_buf[0] = '0';
-  memcpy(nanos_buf + 1, buf, len);
-  val = strtod(nanos_buf, &end);
-
-  if (errno == ERANGE || end != nanos_buf + len + 1) {
-    upb_status_seterrf(p->status, "error parsing timestamp nanos: %s",
-                       nanos_buf);
-    return false;
-  }
-
-  nanos = val * 1000000000;
-
-  /* Clean up previous environment */
-  multipart_end(p);
-
-  /* Set nanos */
-  start_member(p);
-  capture_begin(p, nanos_membername);
-  capture_end(p, nanos_membername + 5);
-  end_membername(p);
-  upb_sink_putint32(p->top->sink, parser_getsel(p), nanos);
-  end_member(p);
-
-  /* Continue previous environment */
-  multipart_startaccum(p);
-
-  return true;
-}
-
-static void start_timestamp_zone(upb_json_parser *p, const char *ptr) {
-  capture_begin(p, ptr);
-}
-
-/* epoch_days(1970, 1, 1) == 1970-01-01 == 0. */
-static int epoch_days(int year, int month, int day) {
-  static const uint16_t month_yday[12] = {0,   31,  59,  90,  120, 151,
-                                          181, 212, 243, 273, 304, 334};
-  uint32_t year_adj = year + 4800;  /* Ensure positive year, multiple of 400. */
-  uint32_t febs = year_adj - (month <= 2 ? 1 : 0);  /* Februaries since base. */
-  uint32_t leap_days = 1 + (febs / 4) - (febs / 100) + (febs / 400);
-  uint32_t days = 365 * year_adj + leap_days + month_yday[month - 1] + day - 1;
-  return days - 2472692;  /* Adjust to Unix epoch. */
-}
-
-static int64_t upb_timegm(const struct tm *tp) {
-  int64_t ret = epoch_days(tp->tm_year + 1900, tp->tm_mon + 1, tp->tm_mday);
-  ret = (ret * 24) + tp->tm_hour;
-  ret = (ret * 60) + tp->tm_min;
-  ret = (ret * 60) + tp->tm_sec;
-  return ret;
-}
-
-static bool end_timestamp_zone(upb_json_parser *p, const char *ptr) {
-  size_t len;
-  const char *buf;
-  int hours;
-  int64_t seconds;
-  const char *seconds_membername = "seconds";
-
-  if (!capture_end(p, ptr)) {
-    return false;
-  }
-
-  buf = accumulate_getptr(p, &len);
-
-  if (buf[0] != 'Z') {
-    if (sscanf(buf + 1, "%2d:00", &hours) != 1) {
-      upb_status_seterrf(p->status, "error parsing timestamp offset");
-      return false;
-    }
-
-    if (buf[0] == '+') {
-      hours = -hours;
-    }
-
-    p->tm.tm_hour += hours;
-  }
-
-  /* Normalize tm */
-  seconds = upb_timegm(&p->tm);
-
-  /* Check timestamp boundary */
-  if (seconds < -62135596800) {
-    upb_status_seterrf(p->status, "error parsing timestamp: "
-                                   "minimum acceptable value is "
-                                   "0001-01-01T00:00:00Z");
-    return false;
-  }
-
-  /* Clean up previous environment */
-  multipart_end(p);
-
-  /* Set seconds */
-  start_member(p);
-  capture_begin(p, seconds_membername);
-  capture_end(p, seconds_membername + 7);
-  end_membername(p);
-  upb_sink_putint64(p->top->sink, parser_getsel(p), seconds);
-  end_member(p);
-
-  /* Continue previous environment */
-  multipart_startaccum(p);
-
-  return true;
-}
-
-static void start_fieldmask_path_text(upb_json_parser *p, const char *ptr) {
-  capture_begin(p, ptr);
-}
-
-static bool end_fieldmask_path_text(upb_json_parser *p, const char *ptr) {
-  return capture_end(p, ptr);
-}
-
-static bool start_fieldmask_path(upb_json_parser *p) {
-  upb_jsonparser_frame *inner;
-  upb_selector_t sel;
-
-  if (!check_stack(p)) return false;
-
-  /* Start a new parser frame: parser frames correspond one-to-one with
-   * handler frames, and string events occur in a sub-frame. */
-  inner = start_jsonparser_frame(p);
-  sel = getsel_for_handlertype(p, UPB_HANDLER_STARTSTR);
-  upb_sink_startstr(p->top->sink, sel, 0, &inner->sink);
-  inner->m = p->top->m;
-  inner->f = p->top->f;
-  p->top = inner;
-
-  multipart_startaccum(p);
-  return true;
-}
-
-static bool lower_camel_push(
-    upb_json_parser *p, upb_selector_t sel, const char *ptr, size_t len) {
-  const char *limit = ptr + len;
-  bool first = true;
-  for (;ptr < limit; ptr++) {
-    if (*ptr >= 'A' && *ptr <= 'Z' && !first) {
-      char lower = tolower(*ptr);
-      upb_sink_putstring(p->top->sink, sel, "_", 1, NULL);
-      upb_sink_putstring(p->top->sink, sel, &lower, 1, NULL);
-    } else {
-      upb_sink_putstring(p->top->sink, sel, ptr, 1, NULL);
-    }
-    first = false;
-  }
-  return true;
-}
-
-static bool end_fieldmask_path(upb_json_parser *p) {
-  upb_selector_t sel;
-
-  if (!lower_camel_push(
-           p, getsel_for_handlertype(p, UPB_HANDLER_STRING),
-           p->accumulated, p->accumulated_len)) {
-    return false;
-  }
-
-  sel = getsel_for_handlertype(p, UPB_HANDLER_ENDSTR);
-  upb_sink_endstr(p->top->sink, sel);
-  p->top--;
-
-  multipart_end(p);
-  return true;
-}
-
-static void start_member(upb_json_parser *p) {
-  UPB_ASSERT(!p->top->f);
-  multipart_startaccum(p);
-}
-
-/* Helper: invoked during parse_mapentry() to emit the mapentry message's key
- * field based on the current contents of the accumulate buffer. */
-static bool parse_mapentry_key(upb_json_parser *p) {
-
-  size_t len;
-  const char *buf = accumulate_getptr(p, &len);
-
-  /* Emit the key field. We do a bit of ad-hoc parsing here because the
-   * parser state machine has already decided that this is a string field
-   * name, and we are reinterpreting it as some arbitrary key type. In
-   * particular, integer and bool keys are quoted, so we need to parse the
-   * quoted string contents here. */
-
-  p->top->f = upb_msgdef_itof(p->top->m, UPB_MAPENTRY_KEY);
-  if (p->top->f == NULL) {
-    upb_status_seterrmsg(p->status, "mapentry message has no key");
-    return false;
-  }
-  switch (upb_fielddef_type(p->top->f)) {
-    case UPB_TYPE_INT32:
-    case UPB_TYPE_INT64:
-    case UPB_TYPE_UINT32:
-    case UPB_TYPE_UINT64:
-      /* Invoke end_number. The accum buffer has the number's text already. */
-      if (!parse_number(p, true)) {
-        return false;
-      }
-      break;
-    case UPB_TYPE_BOOL:
-      if (len == 4 && !strncmp(buf, "true", 4)) {
-        if (!parser_putbool(p, true)) {
-          return false;
-        }
-      } else if (len == 5 && !strncmp(buf, "false", 5)) {
-        if (!parser_putbool(p, false)) {
-          return false;
-        }
-      } else {
-        upb_status_seterrmsg(p->status,
-                             "Map bool key not 'true' or 'false'");
-        return false;
-      }
-      multipart_end(p);
-      break;
-    case UPB_TYPE_STRING:
-    case UPB_TYPE_BYTES: {
-      upb_sink subsink;
-      upb_selector_t sel = getsel_for_handlertype(p, UPB_HANDLER_STARTSTR);
-      upb_sink_startstr(p->top->sink, sel, len, &subsink);
-      sel = getsel_for_handlertype(p, UPB_HANDLER_STRING);
-      upb_sink_putstring(subsink, sel, buf, len, NULL);
-      sel = getsel_for_handlertype(p, UPB_HANDLER_ENDSTR);
-      upb_sink_endstr(subsink, sel);
-      multipart_end(p);
-      break;
-    }
-    default:
-      upb_status_seterrmsg(p->status, "Invalid field type for map key");
-      return false;
-  }
-
-  return true;
-}
-
-/* Helper: emit one map entry (as a submessage in the map field sequence). This
- * is invoked from end_membername(), at the end of the map entry's key string,
- * with the map key in the accumulate buffer. It parses the key from that
- * buffer, emits the handler calls to start the mapentry submessage (setting up
- * its subframe in the process), and sets up state in the subframe so that the
- * value parser (invoked next) will emit the mapentry's value field and then
- * end the mapentry message. */
-
-static bool handle_mapentry(upb_json_parser *p) {
-  const upb_fielddef *mapfield;
-  const upb_msgdef *mapentrymsg;
-  upb_jsonparser_frame *inner;
-  upb_selector_t sel;
-
-  /* Map entry: p->top->sink is the seq frame, so we need to start a frame
-   * for the mapentry itself, and then set |f| in that frame so that the map
-   * value field is parsed, and also set a flag to end the frame after the
-   * map-entry value is parsed. */
-  if (!check_stack(p)) return false;
-
-  mapfield = p->top->mapfield;
-  mapentrymsg = upb_fielddef_msgsubdef(mapfield);
-
-  inner = start_jsonparser_frame(p);
-  p->top->f = mapfield;
-  sel = getsel_for_handlertype(p, UPB_HANDLER_STARTSUBMSG);
-  upb_sink_startsubmsg(p->top->sink, sel, &inner->sink);
-  inner->m = mapentrymsg;
-  inner->mapfield = mapfield;
-
-  /* Don't set this to true *yet* -- we reuse parsing handlers below to push
-   * the key field value to the sink, and these handlers will pop the frame
-   * if they see is_mapentry (when invoked by the parser state machine, they
-   * would have just seen the map-entry value, not key). */
-  inner->is_mapentry = false;
-  p->top = inner;
-
-  /* send STARTMSG in submsg frame. */
-  upb_sink_startmsg(p->top->sink);
-
-  parse_mapentry_key(p);
-
-  /* Set up the value field to receive the map-entry value. */
-  p->top->f = upb_msgdef_itof(p->top->m, UPB_MAPENTRY_VALUE);
-  p->top->is_mapentry = true;  /* set up to pop frame after value is parsed. */
-  p->top->mapfield = mapfield;
-  if (p->top->f == NULL) {
-    upb_status_seterrmsg(p->status, "mapentry message has no value");
-    return false;
-  }
-
-  return true;
-}
-
-static bool end_membername(upb_json_parser *p) {
-  UPB_ASSERT(!p->top->f);
-
-  if (!p->top->m) {
-    p->top->is_unknown_field = true;
-    multipart_end(p);
-    return true;
-  }
-
-  if (p->top->is_any) {
-    return end_any_membername(p);
-  } else if (p->top->is_map) {
-    return handle_mapentry(p);
-  } else {
-    size_t len;
-    const char *buf = accumulate_getptr(p, &len);
-    upb_value v;
-
-    if (upb_strtable_lookup2(p->top->name_table, buf, len, &v)) {
-      p->top->f = upb_value_getconstptr(v);
-      multipart_end(p);
-
-      return true;
-    } else if (p->ignore_json_unknown) {
-      p->top->is_unknown_field = true;
-      multipart_end(p);
-      return true;
-    } else {
-      upb_status_seterrf(p->status, "No such field: %.*s\n", (int)len, buf);
-      return false;
-    }
-  }
-}
-
-static bool end_any_membername(upb_json_parser *p) {
-  size_t len;
-  const char *buf = accumulate_getptr(p, &len);
-  upb_value v;
-
-  if (len == 5 && strncmp(buf, "@type", len) == 0) {
-    upb_strtable_lookup2(p->top->name_table, "type_url", 8, &v);
-    p->top->f = upb_value_getconstptr(v);
-    multipart_end(p);
-    return true;
-  } else {
-    p->top->is_unknown_field = true;
-    multipart_end(p);
-    return true;
-  }
-}
-
-static void end_member(upb_json_parser *p) {
-  /* If we just parsed a map-entry value, end that frame too. */
-  if (p->top->is_mapentry) {
-    upb_selector_t sel;
-    bool ok;
-    const upb_fielddef *mapfield;
-
-    UPB_ASSERT(p->top > p->stack);
-    /* send ENDMSG on submsg. */
-    upb_sink_endmsg(p->top->sink, p->status);
-    mapfield = p->top->mapfield;
-
-    /* send ENDSUBMSG in repeated-field-of-mapentries frame. */
-    p->top--;
-    ok = upb_handlers_getselector(mapfield, UPB_HANDLER_ENDSUBMSG, &sel);
-    UPB_ASSUME(ok);
-    upb_sink_endsubmsg(p->top->sink, (p->top + 1)->sink, sel);
-  }
-
-  p->top->f = NULL;
-  p->top->is_unknown_field = false;
-}
-
-static void start_any_member(upb_json_parser *p, const char *ptr) {
-  start_member(p);
-  json_parser_any_frame_set_after_type_url_start_once(p->top->any_frame, ptr);
-}
-
-static void end_any_member(upb_json_parser *p, const char *ptr) {
-  json_parser_any_frame_set_before_type_url_end(p->top->any_frame, ptr);
-  end_member(p);
-}
-
-static bool start_subobject(upb_json_parser *p) {
-  if (p->top->is_unknown_field) {
-    if (!check_stack(p)) return false;
-
-    p->top = start_jsonparser_frame(p);
-    return true;
-  }
-
-  if (upb_fielddef_ismap(p->top->f)) {
-    upb_jsonparser_frame *inner;
-    upb_selector_t sel;
-
-    /* Beginning of a map. Start a new parser frame in a repeated-field
-     * context. */
-    if (!check_stack(p)) return false;
-
-    inner = start_jsonparser_frame(p);
-    sel = getsel_for_handlertype(p, UPB_HANDLER_STARTSEQ);
-    upb_sink_startseq(p->top->sink, sel, &inner->sink);
-    inner->m = upb_fielddef_msgsubdef(p->top->f);
-    inner->mapfield = p->top->f;
-    inner->is_map = true;
-    p->top = inner;
-
-    return true;
-  } else if (upb_fielddef_issubmsg(p->top->f)) {
-    upb_jsonparser_frame *inner;
-    upb_selector_t sel;
-
-    /* Beginning of a subobject. Start a new parser frame in the submsg
-     * context. */
-    if (!check_stack(p)) return false;
-
-    inner = start_jsonparser_frame(p);
-    sel = getsel_for_handlertype(p, UPB_HANDLER_STARTSUBMSG);
-    upb_sink_startsubmsg(p->top->sink, sel, &inner->sink);
-    inner->m = upb_fielddef_msgsubdef(p->top->f);
-    set_name_table(p, inner);
-    p->top = inner;
-
-    if (is_wellknown_msg(p, UPB_WELLKNOWN_ANY)) {
-      p->top->is_any = true;
-      p->top->any_frame = json_parser_any_frame_new(p);
-    } else {
-      p->top->is_any = false;
-      p->top->any_frame = NULL;
-    }
-
-    return true;
-  } else {
-    upb_status_seterrf(p->status,
-                       "Object specified for non-message/group field: %s",
-                       upb_fielddef_name(p->top->f));
-    return false;
-  }
-}
-
-static bool start_subobject_full(upb_json_parser *p) {
-  if (is_top_level(p)) {
-    if (is_wellknown_msg(p, UPB_WELLKNOWN_VALUE)) {
-      start_value_object(p, VALUE_STRUCTVALUE);
-      if (!start_subobject(p)) return false;
-      start_structvalue_object(p);
-    } else if (is_wellknown_msg(p, UPB_WELLKNOWN_STRUCT)) {
-      start_structvalue_object(p);
-    } else {
-      return true;
-    }
-  } else if (is_wellknown_field(p, UPB_WELLKNOWN_STRUCT)) {
-    if (!start_subobject(p)) return false;
-    start_structvalue_object(p);
-  } else if (is_wellknown_field(p, UPB_WELLKNOWN_VALUE)) {
-    if (!start_subobject(p)) return false;
-    start_value_object(p, VALUE_STRUCTVALUE);
-    if (!start_subobject(p)) return false;
-    start_structvalue_object(p);
-  }
-
-  return start_subobject(p);
-}
-
-static void end_subobject(upb_json_parser *p) {
-  if (is_top_level(p)) {
-    return;
-  }
-
-  if (p->top->is_map) {
-    upb_selector_t sel;
-    p->top--;
-    sel = getsel_for_handlertype(p, UPB_HANDLER_ENDSEQ);
-    upb_sink_endseq(p->top->sink, sel);
-  } else {
-    upb_selector_t sel;
-    bool is_unknown = p->top->m == NULL;
-    p->top--;
-    if (!is_unknown) {
-      sel = getsel_for_handlertype(p, UPB_HANDLER_ENDSUBMSG);
-      upb_sink_endsubmsg(p->top->sink, (p->top + 1)->sink, sel);
-    }
-  }
-}
-
-static void end_subobject_full(upb_json_parser *p) {
-  end_subobject(p);
-
-  if (is_wellknown_msg(p, UPB_WELLKNOWN_STRUCT)) {
-    end_structvalue_object(p);
-    if (!is_top_level(p)) {
-      end_subobject(p);
-    }
-  }
-
-  if (is_wellknown_msg(p, UPB_WELLKNOWN_VALUE)) {
-    end_value_object(p);
-    if (!is_top_level(p)) {
-      end_subobject(p);
-    }
-  }
-}
-
-static bool start_array(upb_json_parser *p) {
-  upb_jsonparser_frame *inner;
-  upb_selector_t sel;
-
-  if (is_top_level(p)) {
-    if (is_wellknown_msg(p, UPB_WELLKNOWN_VALUE)) {
-      start_value_object(p, VALUE_LISTVALUE);
-      if (!start_subobject(p)) return false;
-      start_listvalue_object(p);
-    } else if (is_wellknown_msg(p, UPB_WELLKNOWN_LISTVALUE)) {
-      start_listvalue_object(p);
-    } else {
-      return false;
-    }
-  } else if (is_wellknown_field(p, UPB_WELLKNOWN_LISTVALUE) &&
-             (!upb_fielddef_isseq(p->top->f) ||
-              p->top->is_repeated)) {
-    if (!start_subobject(p)) return false;
-    start_listvalue_object(p);
-  } else if (is_wellknown_field(p, UPB_WELLKNOWN_VALUE) &&
-             (!upb_fielddef_isseq(p->top->f) ||
-              p->top->is_repeated)) {
-    if (!start_subobject(p)) return false;
-    start_value_object(p, VALUE_LISTVALUE);
-    if (!start_subobject(p)) return false;
-    start_listvalue_object(p);
-  }
-
-  if (p->top->is_unknown_field) {
-    inner = start_jsonparser_frame(p);
-    inner->is_unknown_field = true;
-    p->top = inner;
-
-    return true;
-  }
-
-  if (!upb_fielddef_isseq(p->top->f)) {
-    upb_status_seterrf(p->status,
-                       "Array specified for non-repeated field: %s",
-                       upb_fielddef_name(p->top->f));
-    return false;
-  }
-
-  if (!check_stack(p)) return false;
-
-  inner = start_jsonparser_frame(p);
-  sel = getsel_for_handlertype(p, UPB_HANDLER_STARTSEQ);
-  upb_sink_startseq(p->top->sink, sel, &inner->sink);
-  inner->m = p->top->m;
-  inner->f = p->top->f;
-  inner->is_repeated = true;
-  p->top = inner;
-
-  return true;
-}
-
-static void end_array(upb_json_parser *p) {
-  upb_selector_t sel;
-
-  UPB_ASSERT(p->top > p->stack);
-
-  p->top--;
-
-  if (p->top->is_unknown_field) {
-    return;
-  }
-
-  sel = getsel_for_handlertype(p, UPB_HANDLER_ENDSEQ);
-  upb_sink_endseq(p->top->sink, sel);
-
-  if (is_wellknown_msg(p, UPB_WELLKNOWN_LISTVALUE)) {
-    end_listvalue_object(p);
-    if (!is_top_level(p)) {
-      end_subobject(p);
-    }
-  }
-
-  if (is_wellknown_msg(p, UPB_WELLKNOWN_VALUE)) {
-    end_value_object(p);
-    if (!is_top_level(p)) {
-      end_subobject(p);
-    }
-  }
-}
-
-static void start_object(upb_json_parser *p) {
-  if (!p->top->is_map && p->top->m != NULL) {
-    upb_sink_startmsg(p->top->sink);
-  }
-}
-
-static void end_object(upb_json_parser *p) {
-  if (!p->top->is_map && p->top->m != NULL) {
-    upb_sink_endmsg(p->top->sink, p->status);
-  }
-}
-
-static void start_any_object(upb_json_parser *p, const char *ptr) {
-  start_object(p);
-  p->top->any_frame->before_type_url_start = ptr;
-  p->top->any_frame->before_type_url_end = ptr;
-}
-
-static bool end_any_object(upb_json_parser *p, const char *ptr) {
-  const char *value_membername = "value";
-  bool is_well_known_packed = false;
-  const char *packed_end = ptr + 1;
-  upb_selector_t sel;
-  upb_jsonparser_frame *inner;
-
-  if (json_parser_any_frame_has_value(p->top->any_frame) &&
-      !json_parser_any_frame_has_type_url(p->top->any_frame)) {
-    upb_status_seterrmsg(p->status, "No valid type url");
-    return false;
-  }
-
-  /* Well known types data is represented as value field. */
-  if (upb_msgdef_wellknowntype(p->top->any_frame->parser->top->m) !=
-          UPB_WELLKNOWN_UNSPECIFIED) {
-    is_well_known_packed = true;
-
-    if (json_parser_any_frame_has_value_before_type_url(p->top->any_frame)) {
-      p->top->any_frame->before_type_url_start =
-          memchr(p->top->any_frame->before_type_url_start, ':',
-                 p->top->any_frame->before_type_url_end -
-                 p->top->any_frame->before_type_url_start);
-      if (p->top->any_frame->before_type_url_start == NULL) {
-        upb_status_seterrmsg(p->status, "invalid data for well known type.");
-        return false;
-      }
-      p->top->any_frame->before_type_url_start++;
-    }
-
-    if (json_parser_any_frame_has_value_after_type_url(p->top->any_frame)) {
-      p->top->any_frame->after_type_url_start =
-          memchr(p->top->any_frame->after_type_url_start, ':',
-                 (ptr + 1) -
-                 p->top->any_frame->after_type_url_start);
-      if (p->top->any_frame->after_type_url_start == NULL) {
-        upb_status_seterrmsg(p->status, "Invalid data for well known type.");
-        return false;
-      }
-      p->top->any_frame->after_type_url_start++;
-      packed_end = ptr;
-    }
-  }
-
-  if (json_parser_any_frame_has_value_before_type_url(p->top->any_frame)) {
-    if (!parse(p->top->any_frame->parser, NULL,
-               p->top->any_frame->before_type_url_start,
-               p->top->any_frame->before_type_url_end -
-               p->top->any_frame->before_type_url_start, NULL)) {
-      return false;
-    }
-  } else {
-    if (!is_well_known_packed) {
-      if (!parse(p->top->any_frame->parser, NULL, "{", 1, NULL)) {
-        return false;
-      }
-    }
-  }
-
-  if (json_parser_any_frame_has_value_before_type_url(p->top->any_frame) &&
-      json_parser_any_frame_has_value_after_type_url(p->top->any_frame)) {
-    if (!parse(p->top->any_frame->parser, NULL, ",", 1, NULL)) {
-      return false;
-    }
-  }
-
-  if (json_parser_any_frame_has_value_after_type_url(p->top->any_frame)) {
-    if (!parse(p->top->any_frame->parser, NULL,
-               p->top->any_frame->after_type_url_start,
-               packed_end - p->top->any_frame->after_type_url_start, NULL)) {
-      return false;
-    }
-  } else {
-    if (!is_well_known_packed) {
-      if (!parse(p->top->any_frame->parser, NULL, "}", 1, NULL)) {
-        return false;
-      }
-    }
-  }
-
-  if (!end(p->top->any_frame->parser, NULL)) {
-    return false;
-  }
-
-  p->top->is_any = false;
-
-  /* Set value */
-  start_member(p);
-  capture_begin(p, value_membername);
-  capture_end(p, value_membername + 5);
-  end_membername(p);
-
-  if (!check_stack(p)) return false;
-  inner = p->top + 1;
-
-  sel = getsel_for_handlertype(p, UPB_HANDLER_STARTSTR);
-  upb_sink_startstr(p->top->sink, sel, 0, &inner->sink);
-  sel = getsel_for_handlertype(p, UPB_HANDLER_STRING);
-  upb_sink_putstring(inner->sink, sel, p->top->any_frame->stringsink.ptr,
-                     p->top->any_frame->stringsink.len, NULL);
-  sel = getsel_for_handlertype(p, UPB_HANDLER_ENDSTR);
-  upb_sink_endstr(inner->sink, sel);
-
-  end_member(p);
-
-  end_object(p);
-
-  /* Deallocate any parse frame. */
-  json_parser_any_frame_free(p->top->any_frame);
-
-  return true;
-}
-
-static bool is_string_wrapper(const upb_msgdef *m) {
-  upb_wellknowntype_t type = upb_msgdef_wellknowntype(m);
-  return type == UPB_WELLKNOWN_STRINGVALUE ||
-         type == UPB_WELLKNOWN_BYTESVALUE;
-}
-
-static bool is_fieldmask(const upb_msgdef *m) {
-  upb_wellknowntype_t type = upb_msgdef_wellknowntype(m);
-  return type == UPB_WELLKNOWN_FIELDMASK;
-}
-
-static void start_fieldmask_object(upb_json_parser *p) {
-  const char *membername = "paths";
-
-  start_object(p);
-
-  /* Set up context for parsing value */
-  start_member(p);
-  capture_begin(p, membername);
-  capture_end(p, membername + 5);
-  end_membername(p);
-
-  start_array(p);
-}
-
-static void end_fieldmask_object(upb_json_parser *p) {
-  end_array(p);
-  end_member(p);
-  end_object(p);
-}
-
-static void start_wrapper_object(upb_json_parser *p) {
-  const char *membername = "value";
-
-  start_object(p);
-
-  /* Set up context for parsing value */
-  start_member(p);
-  capture_begin(p, membername);
-  capture_end(p, membername + 5);
-  end_membername(p);
-}
-
-static void end_wrapper_object(upb_json_parser *p) {
-  end_member(p);
-  end_object(p);
-}
-
-static void start_value_object(upb_json_parser *p, int value_type) {
-  const char *nullmember = "null_value";
-  const char *numbermember = "number_value";
-  const char *stringmember = "string_value";
-  const char *boolmember = "bool_value";
-  const char *structmember = "struct_value";
-  const char *listmember = "list_value";
-  const char *membername = "";
-
-  switch (value_type) {
-    case VALUE_NULLVALUE:
-      membername = nullmember;
-      break;
-    case VALUE_NUMBERVALUE:
-      membername = numbermember;
-      break;
-    case VALUE_STRINGVALUE:
-      membername = stringmember;
-      break;
-    case VALUE_BOOLVALUE:
-      membername = boolmember;
-      break;
-    case VALUE_STRUCTVALUE:
-      membername = structmember;
-      break;
-    case VALUE_LISTVALUE:
-      membername = listmember;
-      break;
-  }
-
-  start_object(p);
-
-  /* Set up context for parsing value */
-  start_member(p);
-  capture_begin(p, membername);
-  capture_end(p, membername + strlen(membername));
-  end_membername(p);
-}
-
-static void end_value_object(upb_json_parser *p) {
-  end_member(p);
-  end_object(p);
-}
-
-static void start_listvalue_object(upb_json_parser *p) {
-  const char *membername = "values";
-
-  start_object(p);
-
-  /* Set up context for parsing value */
-  start_member(p);
-  capture_begin(p, membername);
-  capture_end(p, membername + strlen(membername));
-  end_membername(p);
-}
-
-static void end_listvalue_object(upb_json_parser *p) {
-  end_member(p);
-  end_object(p);
-}
-
-static void start_structvalue_object(upb_json_parser *p) {
-  const char *membername = "fields";
-
-  start_object(p);
-
-  /* Set up context for parsing value */
-  start_member(p);
-  capture_begin(p, membername);
-  capture_end(p, membername + strlen(membername));
-  end_membername(p);
-}
-
-static void end_structvalue_object(upb_json_parser *p) {
-  end_member(p);
-  end_object(p);
-}
-
-static bool is_top_level(upb_json_parser *p) {
-  return p->top == p->stack && p->top->f == NULL && !p->top->is_unknown_field;
-}
-
-static bool is_wellknown_msg(upb_json_parser *p, upb_wellknowntype_t type) {
-  return p->top->m != NULL && upb_msgdef_wellknowntype(p->top->m) == type;
-}
-
-static bool is_wellknown_field(upb_json_parser *p, upb_wellknowntype_t type) {
-  return p->top->f != NULL &&
-         upb_fielddef_issubmsg(p->top->f) &&
-         (upb_msgdef_wellknowntype(upb_fielddef_msgsubdef(p->top->f))
-              == type);
-}
-
-static bool does_number_wrapper_start(upb_json_parser *p) {
-  return p->top->f != NULL &&
-         upb_fielddef_issubmsg(p->top->f) &&
-         upb_msgdef_isnumberwrapper(upb_fielddef_msgsubdef(p->top->f));
-}
-
-static bool does_number_wrapper_end(upb_json_parser *p) {
-  return p->top->m != NULL && upb_msgdef_isnumberwrapper(p->top->m);
-}
-
-static bool is_number_wrapper_object(upb_json_parser *p) {
-  return p->top->m != NULL && upb_msgdef_isnumberwrapper(p->top->m);
-}
-
-static bool does_string_wrapper_start(upb_json_parser *p) {
-  return p->top->f != NULL &&
-         upb_fielddef_issubmsg(p->top->f) &&
-         is_string_wrapper(upb_fielddef_msgsubdef(p->top->f));
-}
-
-static bool does_string_wrapper_end(upb_json_parser *p) {
-  return p->top->m != NULL && is_string_wrapper(p->top->m);
-}
-
-static bool is_string_wrapper_object(upb_json_parser *p) {
-  return p->top->m != NULL && is_string_wrapper(p->top->m);
-}
-
-static bool does_fieldmask_start(upb_json_parser *p) {
-  return p->top->f != NULL &&
-         upb_fielddef_issubmsg(p->top->f) &&
-         is_fieldmask(upb_fielddef_msgsubdef(p->top->f));
-}
-
-static bool does_fieldmask_end(upb_json_parser *p) {
-  return p->top->m != NULL && is_fieldmask(p->top->m);
-}
-
-#define CHECK_RETURN_TOP(x) if (!(x)) goto error
-
-
-/* The actual parser **********************************************************/
-
-/* What follows is the Ragel parser itself.  The language is specified in Ragel
- * and the actions call our C functions above.
- *
- * Ragel has an extensive set of functionality, and we use only a small part of
- * it.  There are many action types but we only use a few:
- *
- *   ">" -- transition into a machine
- *   "%" -- transition out of a machine
- *   "@" -- transition into a final state of a machine.
- *
- * "@" transitions are tricky because a machine can transition into a final
- * state repeatedly.  But in some cases we know this can't happen, for example
- * a string which is delimited by a final '"' can only transition into its
- * final state once, when the closing '"' is seen. */
-
-%%{
-  machine json;
-
-  ws = space*;
-
-  integer  = "0" | /[1-9]/ /[0-9]/*;
-  decimal  = "." /[0-9]/+;
-  exponent = /[eE]/ /[+\-]/? /[0-9]/+;
-
-  number_machine :=
-    ("-"? integer decimal? exponent?)
-      %/{ fhold; fret; }
-    <: any
-      >{ fhold; fret; }
-    ;
-  number  = /[0-9\-]/ >{ fhold; fcall number_machine; };
-
-  text =
-    /[^\\"]/+
-      >{ start_text(parser, p); }
-      %{ CHECK_RETURN_TOP(end_text(parser, p)); }
-    ;
-
-  unicode_char =
-    "\\u"
-    /[0-9A-Fa-f]/{4}
-      >{ start_hex(parser); }
-      ${ hexdigit(parser, p); }
-      %{ CHECK_RETURN_TOP(end_hex(parser)); }
-    ;
-
-  escape_char  =
-    "\\"
-    /[rtbfn"\/\\]/
-      >{ CHECK_RETURN_TOP(escape(parser, p)); }
-    ;
-
-  string_machine :=
-    (text | unicode_char | escape_char)**
-    '"'
-      @{ fhold; fret; }
-    ;
-
-  year = 
-    (digit digit digit digit)
-      >{ start_year(parser, p); }
-      %{ CHECK_RETURN_TOP(end_year(parser, p)); }
-    ;
-  month =
-    (digit digit)
-      >{ start_month(parser, p); }
-      %{ CHECK_RETURN_TOP(end_month(parser, p)); }
-    ;
-  day =
-    (digit digit)
-      >{ start_day(parser, p); }
-      %{ CHECK_RETURN_TOP(end_day(parser, p)); }
-    ;
-  hour =
-    (digit digit)
-      >{ start_hour(parser, p); }
-      %{ CHECK_RETURN_TOP(end_hour(parser, p)); }
-    ;
-  minute =
-    (digit digit)
-      >{ start_minute(parser, p); }
-      %{ CHECK_RETURN_TOP(end_minute(parser, p)); }
-    ;
-  second =
-    (digit digit)
-      >{ start_second(parser, p); }
-      %{ CHECK_RETURN_TOP(end_second(parser, p)); }
-    ;
-
-  duration_machine :=
-    ("-"? integer decimal?)
-      >{ start_duration_base(parser, p); }
-      %{ CHECK_RETURN_TOP(end_duration_base(parser, p)); }
-    's"'
-      @{ fhold; fret; }
-    ;
-
-  timestamp_machine :=
-    (year "-" month "-" day "T" hour ":" minute ":" second)
-      >{ start_timestamp_base(parser); }
-    ("." digit+)?
-      >{ start_timestamp_fraction(parser, p); }
-      %{ CHECK_RETURN_TOP(end_timestamp_fraction(parser, p)); }
-    ([+\-] digit digit ":00" | "Z")
-      >{ start_timestamp_zone(parser, p); }
-      %{ CHECK_RETURN_TOP(end_timestamp_zone(parser, p)); }
-    '"'
-      @{ fhold; fret; }
-    ;
-
-  fieldmask_path_text =
-    /[^",]/+
-      >{ start_fieldmask_path_text(parser, p); }
-      %{ end_fieldmask_path_text(parser, p); }
-    ;
-
-  fieldmask_path =
-    fieldmask_path_text
-      >{ start_fieldmask_path(parser); }
-      %{ end_fieldmask_path(parser); }
-    ;
-
-  fieldmask_machine :=
-    (fieldmask_path ("," fieldmask_path)*)?
-    '"'
-      @{ fhold; fret; }
-    ;
-
-  string =
-    '"'
-      @{
-        if (is_wellknown_msg(parser, UPB_WELLKNOWN_TIMESTAMP)) {
-          fcall timestamp_machine;
-        } else if (is_wellknown_msg(parser, UPB_WELLKNOWN_DURATION)) {
-          fcall duration_machine;
-        } else if (is_wellknown_msg(parser, UPB_WELLKNOWN_FIELDMASK)) {
-          fcall fieldmask_machine;
-        } else {
-          fcall string_machine;
-        }
-      }
-    '"';
-
-  value2 = ^(space | "]" | "}") >{ fhold; fcall value_machine; } ;
-
-  member =
-    ws
-    string
-      >{
-        if (is_wellknown_msg(parser, UPB_WELLKNOWN_ANY)) {
-          start_any_member(parser, p);
-        } else {
-          start_member(parser);
-        }
-      }
-      @{ CHECK_RETURN_TOP(end_membername(parser)); }
-    ws ":" ws
-    value2
-      %{
-        if (is_wellknown_msg(parser, UPB_WELLKNOWN_ANY)) {
-          end_any_member(parser, p);
-        } else {
-          end_member(parser);
-        }
-      }
-    ws;
-
-  object =
-    ("{" ws)
-      >{
-        if (is_wellknown_msg(parser, UPB_WELLKNOWN_ANY)) {
-          start_any_object(parser, p);
-        } else {
-          start_object(parser);
-        }
-      }
-    (member ("," member)*)?
-    "}"
-      >{
-        if (is_wellknown_msg(parser, UPB_WELLKNOWN_ANY)) {
-          CHECK_RETURN_TOP(end_any_object(parser, p));
-        } else {
-          end_object(parser);
-        }
-      }
-    ;
-
-  element = ws value2 ws;
-  array   =
-    "["
-      >{ CHECK_RETURN_TOP(start_array(parser)); }
-    ws
-    (element ("," element)*)?
-    "]"
-      >{ end_array(parser); }
-    ;
-
-  value =
-    number
-      >{ CHECK_RETURN_TOP(start_number(parser, p)); }
-      %{ CHECK_RETURN_TOP(end_number(parser, p)); }
-    | string
-      >{ CHECK_RETURN_TOP(start_stringval(parser)); }
-      @{ CHECK_RETURN_TOP(end_stringval(parser)); }
-    | "true"
-      %{ CHECK_RETURN_TOP(end_bool(parser, true)); }
-    | "false"
-      %{ CHECK_RETURN_TOP(end_bool(parser, false)); }
-    | "null"
-      %{ CHECK_RETURN_TOP(end_null(parser)); }
-    | object
-      >{ CHECK_RETURN_TOP(start_subobject_full(parser)); }
-      %{ end_subobject_full(parser); }
-    | array;
-
-  value_machine :=
-    value
-    <: any >{ fhold; fret; } ;
-
-  main := ws value ws;
-}%%
-
-%% write data noerror nofinal;
-
-size_t parse(void *closure, const void *hd, const char *buf, size_t size,
-             const upb_bufhandle *handle) {
-  upb_json_parser *parser = closure;
-
-  /* Variables used by Ragel's generated code. */
-  int cs = parser->current_state;
-  int *stack = parser->parser_stack;
-  int top = parser->parser_top;
-
-  const char *p = buf;
-  const char *pe = buf + size;
-  const char *eof = &eof_ch;
-
-  parser->handle = handle;
-
-  UPB_UNUSED(hd);
-  UPB_UNUSED(handle);
-
-  capture_resume(parser, buf);
-
-  %% write exec;
-
-  if (p != pe) {
-    upb_status_seterrf(parser->status, "Parse error at '%.*s'\n", pe - p, p);
-  } else {
-    capture_suspend(parser, &p);
-  }
-
-error:
-  /* Save parsing state back to parser. */
-  parser->current_state = cs;
-  parser->parser_top = top;
-
-  return p - buf;
-}
-
-static bool end(void *closure, const void *hd) {
-  upb_json_parser *parser = closure;
-
-  /* Prevent compile warning on unused static constants. */
-  UPB_UNUSED(json_start);
-  UPB_UNUSED(json_en_duration_machine);
-  UPB_UNUSED(json_en_fieldmask_machine);
-  UPB_UNUSED(json_en_number_machine);
-  UPB_UNUSED(json_en_string_machine);
-  UPB_UNUSED(json_en_timestamp_machine);
-  UPB_UNUSED(json_en_value_machine);
-  UPB_UNUSED(json_en_main);
-
-  parse(parser, hd, &eof_ch, 0, NULL);
-
-  return parser->current_state >= %%{ write first_final; }%%;
-}
-
-static void json_parser_reset(upb_json_parser *p) {
-  int cs;
-  int top;
-
-  p->top = p->stack;
-  init_frame(p->top);
-
-  /* Emit Ragel initialization of the parser. */
-  %% write init;
-  p->current_state = cs;
-  p->parser_top = top;
-  accumulate_clear(p);
-  p->multipart_state = MULTIPART_INACTIVE;
-  p->capture = NULL;
-  p->accumulated = NULL;
-}
-
-static upb_json_parsermethod *parsermethod_new(upb_json_codecache *c,
-                                               const upb_msgdef *md) {
-  int i, n;
-  upb_alloc *alloc = upb_arena_alloc(c->arena);
-
-  upb_json_parsermethod *m = upb_malloc(alloc, sizeof(*m));
-
-  m->cache = c;
-
-  upb_byteshandler_init(&m->input_handler_);
-  upb_byteshandler_setstring(&m->input_handler_, parse, m);
-  upb_byteshandler_setendstr(&m->input_handler_, end, m);
-
-  upb_strtable_init2(&m->name_table, UPB_CTYPE_CONSTPTR, 4, alloc);
-
-  /* Build name_table */
-
-  n = upb_msgdef_fieldcount(md);
-  for(i = 0; i < n; i++) {
-    const upb_fielddef *f = upb_msgdef_field(md, i);
-    upb_value v = upb_value_constptr(f);
-    const char *name;
-
-    /* Add an entry for the JSON name. */
-    name = upb_fielddef_jsonname(f);
-    upb_strtable_insert3(&m->name_table, name, strlen(name), v, alloc);
-
-    if (strcmp(name, upb_fielddef_name(f)) != 0) {
-      /* Since the JSON name is different from the regular field name, add an
-       * entry for the raw name (compliant proto3 JSON parsers must accept
-       * both). */
-      const char *name = upb_fielddef_name(f);
-      upb_strtable_insert3(&m->name_table, name, strlen(name), v, alloc);
-    }
-  }
-
-  return m;
-}
-
-/* Public API *****************************************************************/
-
-upb_json_parser *upb_json_parser_create(upb_arena *arena,
-                                        const upb_json_parsermethod *method,
-                                        const upb_symtab* symtab,
-                                        upb_sink output,
-                                        upb_status *status,
-                                        bool ignore_json_unknown) {
-  upb_json_parser *p = upb_arena_malloc(arena, sizeof(upb_json_parser));
-  if (!p) return false;
-
-  p->arena = arena;
-  p->method = method;
-  p->status = status;
-  p->limit = p->stack + UPB_JSON_MAX_DEPTH;
-  p->accumulate_buf = NULL;
-  p->accumulate_buf_size = 0;
-  upb_bytessink_reset(&p->input_, &method->input_handler_, p);
-
-  json_parser_reset(p);
-  p->top->sink = output;
-  p->top->m = upb_handlers_msgdef(output.handlers);
-  if (is_wellknown_msg(p, UPB_WELLKNOWN_ANY)) {
-    p->top->is_any = true;
-    p->top->any_frame = json_parser_any_frame_new(p);
-  } else {
-    p->top->is_any = false;
-    p->top->any_frame = NULL;
-  }
-  set_name_table(p, p->top);
-  p->symtab = symtab;
-
-  p->ignore_json_unknown = ignore_json_unknown;
-
-  return p;
-}
-
-upb_bytessink upb_json_parser_input(upb_json_parser *p) {
-  return p->input_;
-}
-
-const upb_byteshandler *upb_json_parsermethod_inputhandler(
-    const upb_json_parsermethod *m) {
-  return &m->input_handler_;
-}
-
-upb_json_codecache *upb_json_codecache_new(void) {
-  upb_alloc *alloc;
-  upb_json_codecache *c;
-
-  c = upb_gmalloc(sizeof(*c));
-
-  c->arena = upb_arena_new();
-  alloc = upb_arena_alloc(c->arena);
-
-  upb_inttable_init2(&c->methods, UPB_CTYPE_CONSTPTR, alloc);
-
-  return c;
-}
-
-void upb_json_codecache_free(upb_json_codecache *c) {
-  upb_arena_free(c->arena);
-  upb_gfree(c);
-}
-
-const upb_json_parsermethod *upb_json_codecache_get(upb_json_codecache *c,
-                                                    const upb_msgdef *md) {
-  upb_json_parsermethod *m;
-  upb_value v;
-  int i, n;
-  upb_alloc *alloc = upb_arena_alloc(c->arena);
-
-  if (upb_inttable_lookupptr(&c->methods, md, &v)) {
-    return upb_value_getconstptr(v);
-  }
-
-  m = parsermethod_new(c, md);
-  v = upb_value_constptr(m);
-
-  if (!m) return NULL;
-  if (!upb_inttable_insertptr2(&c->methods, md, v, alloc)) return NULL;
-
-  /* Populate parser methods for all submessages, so the name tables will
-   * be available during parsing. */
-  n = upb_msgdef_fieldcount(md);
-  for(i = 0; i < n; i++) {
-    const upb_fielddef *f = upb_msgdef_field(md, i);
-
-    if (upb_fielddef_issubmsg(f)) {
-      const upb_msgdef *subdef = upb_fielddef_msgsubdef(f);
-      const upb_json_parsermethod *sub_method =
-          upb_json_codecache_get(c, subdef);
-
-      if (!sub_method) return NULL;
-    }
-  }
-
-  return m;
-}
diff --git a/third_party/upb/upb/json/printer.c b/third_party/upb/upb/json/printer.c
deleted file mode 100644 (file)
index 2f0c8fb..0000000
+++ /dev/null
@@ -1,1396 +0,0 @@
-/*
-** This currently uses snprintf() to format primitives, and could be optimized
-** further.
-*/
-
-#include "upb/json/printer.h"
-
-#include <ctype.h>
-#include <inttypes.h>
-#include <math.h>
-#include <stdint.h>
-#include <stdio.h>
-#include <string.h>
-#include <time.h>
-
-#include "upb/port_def.inc"
-
-struct upb_json_printer {
-  upb_sink input_;
-  /* BytesSink closure. */
-  void *subc_;
-  upb_bytessink output_;
-
-  /* We track the depth so that we know when to emit startstr/endstr on the
-   * output. */
-  int depth_;
-
-  /* Have we emitted the first element? This state is necessary to emit commas
-   * without leaving a trailing comma in arrays/maps. We keep this state per
-   * frame depth.
-   *
-   * Why max_depth * 2? UPB_MAX_HANDLER_DEPTH counts depth as nested messages.
-   * We count frames (contexts in which we separate elements by commas) as both
-   * repeated fields and messages (maps), and the worst case is a
-   * message->repeated field->submessage->repeated field->... nesting. */
-  bool first_elem_[UPB_MAX_HANDLER_DEPTH * 2];
-
-  /* To print timestamp, printer needs to cache its seconds and nanos values
-   * and convert them when ending timestamp message. See comments of
-   * printer_sethandlers_timestamp for more detail. */
-  int64_t seconds;
-  int32_t nanos;
-};
-
-/* StringPiece; a pointer plus a length. */
-typedef struct {
-  char *ptr;
-  size_t len;
-} strpc;
-
-void freestrpc(void *ptr) {
-  strpc *pc = ptr;
-  upb_gfree(pc->ptr);
-  upb_gfree(pc);
-}
-
-typedef struct {
-  bool preserve_fieldnames;
-} upb_json_printercache;
-
-/* Convert fielddef name to JSON name and return as a string piece. */
-strpc *newstrpc(upb_handlers *h, const upb_fielddef *f,
-                bool preserve_fieldnames) {
-  /* TODO(haberman): handle malloc failure. */
-  strpc *ret = upb_gmalloc(sizeof(*ret));
-  if (preserve_fieldnames) {
-    ret->ptr = upb_gstrdup(upb_fielddef_name(f));
-    ret->len = strlen(ret->ptr);
-  } else {
-    ret->ptr = upb_gstrdup(upb_fielddef_jsonname(f));
-    ret->len = strlen(ret->ptr);
-  }
-
-  upb_handlers_addcleanup(h, ret, freestrpc);
-  return ret;
-}
-
-/* Convert a null-terminated const char* to a string piece. */
-strpc *newstrpc_str(upb_handlers *h, const char * str) {
-  strpc * ret = upb_gmalloc(sizeof(*ret));
-  ret->ptr = upb_gstrdup(str);
-  ret->len = strlen(str);
-  upb_handlers_addcleanup(h, ret, freestrpc);
-  return ret;
-}
-
-/* ------------ JSON string printing: values, maps, arrays ------------------ */
-
-static void print_data(
-    upb_json_printer *p, const char *buf, size_t len) {
-  /* TODO: Will need to change if we support pushback from the sink. */
-  size_t n = upb_bytessink_putbuf(p->output_, p->subc_, buf, len, NULL);
-  UPB_ASSERT(n == len);
-}
-
-static void print_comma(upb_json_printer *p) {
-  if (!p->first_elem_[p->depth_]) {
-    print_data(p, ",", 1);
-  }
-  p->first_elem_[p->depth_] = false;
-}
-
-/* Helpers that print properly formatted elements to the JSON output stream. */
-
-/* Used for escaping control chars in strings. */
-static const char kControlCharLimit = 0x20;
-
-UPB_INLINE bool is_json_escaped(char c) {
-  /* See RFC 4627. */
-  unsigned char uc = (unsigned char)c;
-  return uc < kControlCharLimit || uc == '"' || uc == '\\';
-}
-
-UPB_INLINE const char* json_nice_escape(char c) {
-  switch (c) {
-    case '"':  return "\\\"";
-    case '\\': return "\\\\";
-    case '\b': return "\\b";
-    case '\f': return "\\f";
-    case '\n': return "\\n";
-    case '\r': return "\\r";
-    case '\t': return "\\t";
-    default:   return NULL;
-  }
-}
-
-/* Write a properly escaped string chunk. The surrounding quotes are *not*
- * printed; this is so that the caller has the option of emitting the string
- * content in chunks. */
-static void putstring(upb_json_printer *p, const char *buf, size_t len) {
-  const char* unescaped_run = NULL;
-  unsigned int i;
-  for (i = 0; i < len; i++) {
-    char c = buf[i];
-    /* Handle escaping. */
-    if (is_json_escaped(c)) {
-      /* Use a "nice" escape, like \n, if one exists for this character. */
-      const char* escape = json_nice_escape(c);
-      /* If we don't have a specific 'nice' escape code, use a \uXXXX-style
-       * escape. */
-      char escape_buf[8];
-      if (!escape) {
-        unsigned char byte = (unsigned char)c;
-        snprintf(escape_buf, sizeof(escape_buf), "\\u%04x", (int)byte);
-        escape = escape_buf;
-      }
-
-      /* N.B. that we assume that the input encoding is equal to the output
-       * encoding (both UTF-8 for  now), so for chars >= 0x20 and != \, ", we
-       * can simply pass the bytes through. */
-
-      /* If there's a current run of unescaped chars, print that run first. */
-      if (unescaped_run) {
-        print_data(p, unescaped_run, &buf[i] - unescaped_run);
-        unescaped_run = NULL;
-      }
-      /* Then print the escape code. */
-      print_data(p, escape, strlen(escape));
-    } else {
-      /* Add to the current unescaped run of characters. */
-      if (unescaped_run == NULL) {
-        unescaped_run = &buf[i];
-      }
-    }
-  }
-
-  /* If the string ended in a run of unescaped characters, print that last run. */
-  if (unescaped_run) {
-    print_data(p, unescaped_run, &buf[len] - unescaped_run);
-  }
-}
-
-#define CHKLENGTH(x) if (!(x)) return -1;
-
-/* Helpers that format floating point values according to our custom formats.
- * Right now we use %.8g and %.17g for float/double, respectively, to match
- * proto2::util::JsonFormat's defaults.  May want to change this later. */
-
-const char neginf[] = "\"-Infinity\"";
-const char inf[] = "\"Infinity\"";
-
-static size_t fmt_double(double val, char* buf, size_t length) {
-  if (val == INFINITY) {
-    CHKLENGTH(length >= strlen(inf));
-    strcpy(buf, inf);
-    return strlen(inf);
-  } else if (val == -INFINITY) {
-    CHKLENGTH(length >= strlen(neginf));
-    strcpy(buf, neginf);
-    return strlen(neginf);
-  } else {
-    size_t n = snprintf(buf, length, "%.17g", val);
-    CHKLENGTH(n > 0 && n < length);
-    return n;
-  }
-}
-
-static size_t fmt_float(float val, char* buf, size_t length) {
-  size_t n = snprintf(buf, length, "%.8g", val);
-  CHKLENGTH(n > 0 && n < length);
-  return n;
-}
-
-static size_t fmt_bool(bool val, char* buf, size_t length) {
-  size_t n = snprintf(buf, length, "%s", (val ? "true" : "false"));
-  CHKLENGTH(n > 0 && n < length);
-  return n;
-}
-
-static size_t fmt_int64_as_number(int64_t val, char* buf, size_t length) {
-  size_t n = snprintf(buf, length, "%" PRId64, val);
-  CHKLENGTH(n > 0 && n < length);
-  return n;
-}
-
-static size_t fmt_uint64_as_number(uint64_t val, char* buf, size_t length) {
-  size_t n = snprintf(buf, length, "%" PRIu64, val);
-  CHKLENGTH(n > 0 && n < length);
-  return n;
-}
-
-static size_t fmt_int64_as_string(int64_t val, char* buf, size_t length) {
-  size_t n = snprintf(buf, length, "\"%" PRId64 "\"", val);
-  CHKLENGTH(n > 0 && n < length);
-  return n;
-}
-
-static size_t fmt_uint64_as_string(uint64_t val, char* buf, size_t length) {
-  size_t n = snprintf(buf, length, "\"%" PRIu64 "\"", val);
-  CHKLENGTH(n > 0 && n < length);
-  return n;
-}
-
-/* Print a map key given a field name. Called by scalar field handlers and by
- * startseq for repeated fields. */
-static bool putkey(void *closure, const void *handler_data) {
-  upb_json_printer *p = closure;
-  const strpc *key = handler_data;
-  print_comma(p);
-  print_data(p, "\"", 1);
-  putstring(p, key->ptr, key->len);
-  print_data(p, "\":", 2);
-  return true;
-}
-
-#define CHKFMT(val) if ((val) == (size_t)-1) return false;
-#define CHK(val)    if (!(val)) return false;
-
-#define TYPE_HANDLERS(type, fmt_func)                                        \
-  static bool put##type(void *closure, const void *handler_data, type val) { \
-    upb_json_printer *p = closure;                                           \
-    char data[64];                                                           \
-    size_t length = fmt_func(val, data, sizeof(data));                       \
-    UPB_UNUSED(handler_data);                                                \
-    CHKFMT(length);                                                          \
-    print_data(p, data, length);                                             \
-    return true;                                                             \
-  }                                                                          \
-  static bool scalar_##type(void *closure, const void *handler_data,         \
-                            type val) {                                      \
-    CHK(putkey(closure, handler_data));                                      \
-    CHK(put##type(closure, handler_data, val));                              \
-    return true;                                                             \
-  }                                                                          \
-  static bool repeated_##type(void *closure, const void *handler_data,       \
-                              type val) {                                    \
-    upb_json_printer *p = closure;                                           \
-    print_comma(p);                                                          \
-    CHK(put##type(closure, handler_data, val));                              \
-    return true;                                                             \
-  }
-
-#define TYPE_HANDLERS_MAPKEY(type, fmt_func)                                 \
-  static bool putmapkey_##type(void *closure, const void *handler_data,      \
-                            type val) {                                      \
-    upb_json_printer *p = closure;                                           \
-    char data[64];                                                           \
-    size_t length = fmt_func(val, data, sizeof(data));                       \
-    UPB_UNUSED(handler_data);                                                \
-    print_data(p, "\"", 1);                                                  \
-    print_data(p, data, length);                                             \
-    print_data(p, "\":", 2);                                                 \
-    return true;                                                             \
-  }
-
-TYPE_HANDLERS(double,   fmt_double)
-TYPE_HANDLERS(float,    fmt_float)
-TYPE_HANDLERS(bool,     fmt_bool)
-TYPE_HANDLERS(int32_t,  fmt_int64_as_number)
-TYPE_HANDLERS(uint32_t, fmt_int64_as_number)
-TYPE_HANDLERS(int64_t,  fmt_int64_as_string)
-TYPE_HANDLERS(uint64_t, fmt_uint64_as_string)
-
-/* double and float are not allowed to be map keys. */
-TYPE_HANDLERS_MAPKEY(bool,     fmt_bool)
-TYPE_HANDLERS_MAPKEY(int32_t,  fmt_int64_as_number)
-TYPE_HANDLERS_MAPKEY(uint32_t, fmt_int64_as_number)
-TYPE_HANDLERS_MAPKEY(int64_t,  fmt_int64_as_number)
-TYPE_HANDLERS_MAPKEY(uint64_t, fmt_uint64_as_number)
-
-#undef TYPE_HANDLERS
-#undef TYPE_HANDLERS_MAPKEY
-
-typedef struct {
-  void *keyname;
-  const upb_enumdef *enumdef;
-} EnumHandlerData;
-
-static bool scalar_enum(void *closure, const void *handler_data,
-                        int32_t val) {
-  const EnumHandlerData *hd = handler_data;
-  upb_json_printer *p = closure;
-  const char *symbolic_name;
-
-  CHK(putkey(closure, hd->keyname));
-
-  symbolic_name = upb_enumdef_iton(hd->enumdef, val);
-  if (symbolic_name) {
-    print_data(p, "\"", 1);
-    putstring(p, symbolic_name, strlen(symbolic_name));
-    print_data(p, "\"", 1);
-  } else {
-    putint32_t(closure, NULL, val);
-  }
-
-  return true;
-}
-
-static void print_enum_symbolic_name(upb_json_printer *p,
-                                     const upb_enumdef *def,
-                                     int32_t val) {
-  const char *symbolic_name = upb_enumdef_iton(def, val);
-  if (symbolic_name) {
-    print_data(p, "\"", 1);
-    putstring(p, symbolic_name, strlen(symbolic_name));
-    print_data(p, "\"", 1);
-  } else {
-    putint32_t(p, NULL, val);
-  }
-}
-
-static bool repeated_enum(void *closure, const void *handler_data,
-                          int32_t val) {
-  const EnumHandlerData *hd = handler_data;
-  upb_json_printer *p = closure;
-  print_comma(p);
-
-  print_enum_symbolic_name(p, hd->enumdef, val);
-
-  return true;
-}
-
-static bool mapvalue_enum(void *closure, const void *handler_data,
-                          int32_t val) {
-  const EnumHandlerData *hd = handler_data;
-  upb_json_printer *p = closure;
-
-  print_enum_symbolic_name(p, hd->enumdef, val);
-
-  return true;
-}
-
-static void *scalar_startsubmsg(void *closure, const void *handler_data) {
-  return putkey(closure, handler_data) ? closure : UPB_BREAK;
-}
-
-static void *repeated_startsubmsg(void *closure, const void *handler_data) {
-  upb_json_printer *p = closure;
-  UPB_UNUSED(handler_data);
-  print_comma(p);
-  return closure;
-}
-
-static void start_frame(upb_json_printer *p) {
-  p->depth_++;
-  p->first_elem_[p->depth_] = true;
-  print_data(p, "{", 1);
-}
-
-static void end_frame(upb_json_printer *p) {
-  print_data(p, "}", 1);
-  p->depth_--;
-}
-
-static bool printer_startmsg(void *closure, const void *handler_data) {
-  upb_json_printer *p = closure;
-  UPB_UNUSED(handler_data);
-  if (p->depth_ == 0) {
-    upb_bytessink_start(p->output_, 0, &p->subc_);
-  }
-  start_frame(p);
-  return true;
-}
-
-static bool printer_endmsg(void *closure, const void *handler_data, upb_status *s) {
-  upb_json_printer *p = closure;
-  UPB_UNUSED(handler_data);
-  UPB_UNUSED(s);
-  end_frame(p);
-  if (p->depth_ == 0) {
-    upb_bytessink_end(p->output_);
-  }
-  return true;
-}
-
-static void *startseq(void *closure, const void *handler_data) {
-  upb_json_printer *p = closure;
-  CHK(putkey(closure, handler_data));
-  p->depth_++;
-  p->first_elem_[p->depth_] = true;
-  print_data(p, "[", 1);
-  return closure;
-}
-
-static bool endseq(void *closure, const void *handler_data) {
-  upb_json_printer *p = closure;
-  UPB_UNUSED(handler_data);
-  print_data(p, "]", 1);
-  p->depth_--;
-  return true;
-}
-
-static void *startmap(void *closure, const void *handler_data) {
-  upb_json_printer *p = closure;
-  CHK(putkey(closure, handler_data));
-  p->depth_++;
-  p->first_elem_[p->depth_] = true;
-  print_data(p, "{", 1);
-  return closure;
-}
-
-static bool endmap(void *closure, const void *handler_data) {
-  upb_json_printer *p = closure;
-  UPB_UNUSED(handler_data);
-  print_data(p, "}", 1);
-  p->depth_--;
-  return true;
-}
-
-static size_t putstr(void *closure, const void *handler_data, const char *str,
-                     size_t len, const upb_bufhandle *handle) {
-  upb_json_printer *p = closure;
-  UPB_UNUSED(handler_data);
-  UPB_UNUSED(handle);
-  putstring(p, str, len);
-  return len;
-}
-
-/* This has to Base64 encode the bytes, because JSON has no "bytes" type. */
-static size_t putbytes(void *closure, const void *handler_data, const char *str,
-                       size_t len, const upb_bufhandle *handle) {
-  upb_json_printer *p = closure;
-
-  /* This is the regular base64, not the "web-safe" version. */
-  static const char base64[] =
-      "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";
-
-  /* Base64-encode. */
-  char data[16000];
-  const char *limit = data + sizeof(data);
-  const unsigned char *from = (const unsigned char*)str;
-  char *to = data;
-  size_t remaining = len;
-  size_t bytes;
-
-  UPB_UNUSED(handler_data);
-  UPB_UNUSED(handle);
-
-  print_data(p, "\"", 1);
-
-  while (remaining > 2) {
-    if (limit - to < 4) {
-      bytes = to - data;
-      putstring(p, data, bytes);
-      to = data;
-    }
-
-    to[0] = base64[from[0] >> 2];
-    to[1] = base64[((from[0] & 0x3) << 4) | (from[1] >> 4)];
-    to[2] = base64[((from[1] & 0xf) << 2) | (from[2] >> 6)];
-    to[3] = base64[from[2] & 0x3f];
-
-    remaining -= 3;
-    to += 4;
-    from += 3;
-  }
-
-  switch (remaining) {
-    case 2:
-      to[0] = base64[from[0] >> 2];
-      to[1] = base64[((from[0] & 0x3) << 4) | (from[1] >> 4)];
-      to[2] = base64[(from[1] & 0xf) << 2];
-      to[3] = '=';
-      to += 4;
-      from += 2;
-      break;
-    case 1:
-      to[0] = base64[from[0] >> 2];
-      to[1] = base64[((from[0] & 0x3) << 4)];
-      to[2] = '=';
-      to[3] = '=';
-      to += 4;
-      from += 1;
-      break;
-  }
-
-  bytes = to - data;
-  putstring(p, data, bytes);
-  print_data(p, "\"", 1);
-  return len;
-}
-
-static void *scalar_startstr(void *closure, const void *handler_data,
-                             size_t size_hint) {
-  upb_json_printer *p = closure;
-  UPB_UNUSED(handler_data);
-  UPB_UNUSED(size_hint);
-  CHK(putkey(closure, handler_data));
-  print_data(p, "\"", 1);
-  return p;
-}
-
-static size_t scalar_str(void *closure, const void *handler_data,
-                         const char *str, size_t len,
-                         const upb_bufhandle *handle) {
-  CHK(putstr(closure, handler_data, str, len, handle));
-  return len;
-}
-
-static bool scalar_endstr(void *closure, const void *handler_data) {
-  upb_json_printer *p = closure;
-  UPB_UNUSED(handler_data);
-  print_data(p, "\"", 1);
-  return true;
-}
-
-static void *repeated_startstr(void *closure, const void *handler_data,
-                               size_t size_hint) {
-  upb_json_printer *p = closure;
-  UPB_UNUSED(handler_data);
-  UPB_UNUSED(size_hint);
-  print_comma(p);
-  print_data(p, "\"", 1);
-  return p;
-}
-
-static size_t repeated_str(void *closure, const void *handler_data,
-                           const char *str, size_t len,
-                           const upb_bufhandle *handle) {
-  CHK(putstr(closure, handler_data, str, len, handle));
-  return len;
-}
-
-static bool repeated_endstr(void *closure, const void *handler_data) {
-  upb_json_printer *p = closure;
-  UPB_UNUSED(handler_data);
-  print_data(p, "\"", 1);
-  return true;
-}
-
-static void *mapkeyval_startstr(void *closure, const void *handler_data,
-                                size_t size_hint) {
-  upb_json_printer *p = closure;
-  UPB_UNUSED(handler_data);
-  UPB_UNUSED(size_hint);
-  print_data(p, "\"", 1);
-  return p;
-}
-
-static size_t mapkey_str(void *closure, const void *handler_data,
-                         const char *str, size_t len,
-                         const upb_bufhandle *handle) {
-  CHK(putstr(closure, handler_data, str, len, handle));
-  return len;
-}
-
-static bool mapkey_endstr(void *closure, const void *handler_data) {
-  upb_json_printer *p = closure;
-  UPB_UNUSED(handler_data);
-  print_data(p, "\":", 2);
-  return true;
-}
-
-static bool mapvalue_endstr(void *closure, const void *handler_data) {
-  upb_json_printer *p = closure;
-  UPB_UNUSED(handler_data);
-  print_data(p, "\"", 1);
-  return true;
-}
-
-static size_t scalar_bytes(void *closure, const void *handler_data,
-                           const char *str, size_t len,
-                           const upb_bufhandle *handle) {
-  CHK(putkey(closure, handler_data));
-  CHK(putbytes(closure, handler_data, str, len, handle));
-  return len;
-}
-
-static size_t repeated_bytes(void *closure, const void *handler_data,
-                             const char *str, size_t len,
-                             const upb_bufhandle *handle) {
-  upb_json_printer *p = closure;
-  print_comma(p);
-  CHK(putbytes(closure, handler_data, str, len, handle));
-  return len;
-}
-
-static size_t mapkey_bytes(void *closure, const void *handler_data,
-                           const char *str, size_t len,
-                           const upb_bufhandle *handle) {
-  upb_json_printer *p = closure;
-  CHK(putbytes(closure, handler_data, str, len, handle));
-  print_data(p, ":", 1);
-  return len;
-}
-
-static void set_enum_hd(upb_handlers *h,
-                        const upb_fielddef *f,
-                        bool preserve_fieldnames,
-                        upb_handlerattr *attr) {
-  EnumHandlerData *hd = upb_gmalloc(sizeof(EnumHandlerData));
-  hd->enumdef = upb_fielddef_enumsubdef(f);
-  hd->keyname = newstrpc(h, f, preserve_fieldnames);
-  upb_handlers_addcleanup(h, hd, upb_gfree);
-  attr->handler_data = hd;
-}
-
-/* Set up handlers for a mapentry submessage (i.e., an individual key/value pair
- * in a map).
- *
- * TODO: Handle missing key, missing value, out-of-order key/value, or repeated
- * key or value cases properly. The right way to do this is to allocate a
- * temporary structure at the start of a mapentry submessage, store key and
- * value data in it as key and value handlers are called, and then print the
- * key/value pair once at the end of the submessage. If we don't do this, we
- * should at least detect the case and throw an error. However, so far all of
- * our sources that emit mapentry messages do so canonically (with one key
- * field, and then one value field), so this is not a pressing concern at the
- * moment. */
-void printer_sethandlers_mapentry(const void *closure, bool preserve_fieldnames,
-                                  upb_handlers *h) {
-  const upb_msgdef *md = upb_handlers_msgdef(h);
-
-  /* A mapentry message is printed simply as '"key": value'. Rather than
-   * special-case key and value for every type below, we just handle both
-   * fields explicitly here. */
-  const upb_fielddef* key_field = upb_msgdef_itof(md, UPB_MAPENTRY_KEY);
-  const upb_fielddef* value_field = upb_msgdef_itof(md, UPB_MAPENTRY_VALUE);
-
-  upb_handlerattr empty_attr = UPB_HANDLERATTR_INIT;
-
-  UPB_UNUSED(closure);
-
-  switch (upb_fielddef_type(key_field)) {
-    case UPB_TYPE_INT32:
-      upb_handlers_setint32(h, key_field, putmapkey_int32_t, &empty_attr);
-      break;
-    case UPB_TYPE_INT64:
-      upb_handlers_setint64(h, key_field, putmapkey_int64_t, &empty_attr);
-      break;
-    case UPB_TYPE_UINT32:
-      upb_handlers_setuint32(h, key_field, putmapkey_uint32_t, &empty_attr);
-      break;
-    case UPB_TYPE_UINT64:
-      upb_handlers_setuint64(h, key_field, putmapkey_uint64_t, &empty_attr);
-      break;
-    case UPB_TYPE_BOOL:
-      upb_handlers_setbool(h, key_field, putmapkey_bool, &empty_attr);
-      break;
-    case UPB_TYPE_STRING:
-      upb_handlers_setstartstr(h, key_field, mapkeyval_startstr, &empty_attr);
-      upb_handlers_setstring(h, key_field, mapkey_str, &empty_attr);
-      upb_handlers_setendstr(h, key_field, mapkey_endstr, &empty_attr);
-      break;
-    case UPB_TYPE_BYTES:
-      upb_handlers_setstring(h, key_field, mapkey_bytes, &empty_attr);
-      break;
-    default:
-      UPB_ASSERT(false);
-      break;
-  }
-
-  switch (upb_fielddef_type(value_field)) {
-    case UPB_TYPE_INT32:
-      upb_handlers_setint32(h, value_field, putint32_t, &empty_attr);
-      break;
-    case UPB_TYPE_INT64:
-      upb_handlers_setint64(h, value_field, putint64_t, &empty_attr);
-      break;
-    case UPB_TYPE_UINT32:
-      upb_handlers_setuint32(h, value_field, putuint32_t, &empty_attr);
-      break;
-    case UPB_TYPE_UINT64:
-      upb_handlers_setuint64(h, value_field, putuint64_t, &empty_attr);
-      break;
-    case UPB_TYPE_BOOL:
-      upb_handlers_setbool(h, value_field, putbool, &empty_attr);
-      break;
-    case UPB_TYPE_FLOAT:
-      upb_handlers_setfloat(h, value_field, putfloat, &empty_attr);
-      break;
-    case UPB_TYPE_DOUBLE:
-      upb_handlers_setdouble(h, value_field, putdouble, &empty_attr);
-      break;
-    case UPB_TYPE_STRING:
-      upb_handlers_setstartstr(h, value_field, mapkeyval_startstr, &empty_attr);
-      upb_handlers_setstring(h, value_field, putstr, &empty_attr);
-      upb_handlers_setendstr(h, value_field, mapvalue_endstr, &empty_attr);
-      break;
-    case UPB_TYPE_BYTES:
-      upb_handlers_setstring(h, value_field, putbytes, &empty_attr);
-      break;
-    case UPB_TYPE_ENUM: {
-      upb_handlerattr enum_attr = UPB_HANDLERATTR_INIT;
-      set_enum_hd(h, value_field, preserve_fieldnames, &enum_attr);
-      upb_handlers_setint32(h, value_field, mapvalue_enum, &enum_attr);
-      break;
-    }
-    case UPB_TYPE_MESSAGE:
-      /* No handler necessary -- the submsg handlers will print the message
-       * as appropriate. */
-      break;
-  }
-}
-
-static bool putseconds(void *closure, const void *handler_data,
-                       int64_t seconds) {
-  upb_json_printer *p = closure;
-  p->seconds = seconds;
-  UPB_UNUSED(handler_data);
-  return true;
-}
-
-static bool putnanos(void *closure, const void *handler_data,
-                     int32_t nanos) {
-  upb_json_printer *p = closure;
-  p->nanos = nanos;
-  UPB_UNUSED(handler_data);
-  return true;
-}
-
-static void *scalar_startstr_nokey(void *closure, const void *handler_data,
-                                   size_t size_hint) {
-  upb_json_printer *p = closure;
-  UPB_UNUSED(handler_data);
-  UPB_UNUSED(size_hint);
-  print_data(p, "\"", 1);
-  return p;
-}
-
-static size_t putstr_nokey(void *closure, const void *handler_data,
-                           const char *str, size_t len,
-                           const upb_bufhandle *handle) {
-  upb_json_printer *p = closure;
-  UPB_UNUSED(handler_data);
-  UPB_UNUSED(handle);
-  print_data(p, "\"", 1);
-  putstring(p, str, len);
-  print_data(p, "\"", 1);
-  return len + 2;
-}
-
-static void *startseq_nokey(void *closure, const void *handler_data) {
-  upb_json_printer *p = closure;
-  UPB_UNUSED(handler_data);
-  p->depth_++;
-  p->first_elem_[p->depth_] = true;
-  print_data(p, "[", 1);
-  return closure;
-}
-
-static void *startseq_fieldmask(void *closure, const void *handler_data) {
-  upb_json_printer *p = closure;
-  UPB_UNUSED(handler_data);
-  p->depth_++;
-  p->first_elem_[p->depth_] = true;
-  return closure;
-}
-
-static bool endseq_fieldmask(void *closure, const void *handler_data) {
-  upb_json_printer *p = closure;
-  UPB_UNUSED(handler_data);
-  p->depth_--;
-  return true;
-}
-
-static void *repeated_startstr_fieldmask(
-    void *closure, const void *handler_data,
-    size_t size_hint) {
-  upb_json_printer *p = closure;
-  UPB_UNUSED(handler_data);
-  UPB_UNUSED(size_hint);
-  print_comma(p);
-  return p;
-}
-
-static size_t repeated_str_fieldmask(
-    void *closure, const void *handler_data,
-    const char *str, size_t len,
-    const upb_bufhandle *handle) {
-  const char* limit = str + len;
-  bool upper = false;
-  size_t result_len = 0;
-  for (; str < limit; str++) {
-    if (*str == '_') {
-      upper = true;
-      continue;
-    }
-    if (upper && *str >= 'a' && *str <= 'z') {
-      char upper_char = toupper(*str);
-      CHK(putstr(closure, handler_data, &upper_char, 1, handle));
-    } else {
-      CHK(putstr(closure, handler_data, str, 1, handle));
-    }
-    upper = false;
-    result_len++;
-  }
-  return result_len;
-}
-
-static void *startmap_nokey(void *closure, const void *handler_data) {
-  upb_json_printer *p = closure;
-  UPB_UNUSED(handler_data);
-  p->depth_++;
-  p->first_elem_[p->depth_] = true;
-  print_data(p, "{", 1);
-  return closure;
-}
-
-static bool putnull(void *closure, const void *handler_data,
-                    int32_t null) {
-  upb_json_printer *p = closure;
-  print_data(p, "null", 4);
-  UPB_UNUSED(handler_data);
-  UPB_UNUSED(null);
-  return true;
-}
-
-static bool printer_startdurationmsg(void *closure, const void *handler_data) {
-  upb_json_printer *p = closure;
-  UPB_UNUSED(handler_data);
-  if (p->depth_ == 0) {
-    upb_bytessink_start(p->output_, 0, &p->subc_);
-  }
-  return true;
-}
-
-#define UPB_DURATION_MAX_JSON_LEN 23
-#define UPB_DURATION_MAX_NANO_LEN 9
-
-static bool printer_enddurationmsg(void *closure, const void *handler_data,
-                                   upb_status *s) {
-  upb_json_printer *p = closure;
-  char buffer[UPB_DURATION_MAX_JSON_LEN];
-  size_t base_len;
-  size_t curr;
-  size_t i;
-
-  memset(buffer, 0, UPB_DURATION_MAX_JSON_LEN);
-
-  if (p->seconds < -315576000000) {
-    upb_status_seterrf(s, "error parsing duration: "
-                          "minimum acceptable value is "
-                          "-315576000000");
-    return false;
-  }
-
-  if (p->seconds > 315576000000) {
-    upb_status_seterrf(s, "error serializing duration: "
-                          "maximum acceptable value is "
-                          "315576000000");
-    return false;
-  }
-
-  snprintf(buffer, sizeof(buffer), "%ld", (long)p->seconds);
-  base_len = strlen(buffer);
-
-  if (p->nanos != 0) {
-    char nanos_buffer[UPB_DURATION_MAX_NANO_LEN + 3];
-    snprintf(nanos_buffer, sizeof(nanos_buffer), "%.9f",
-                  p->nanos / 1000000000.0);
-    /* Remove trailing 0. */
-    for (i = UPB_DURATION_MAX_NANO_LEN + 2;
-         nanos_buffer[i] == '0'; i--) {
-      nanos_buffer[i] = 0;
-    }
-    strcpy(buffer + base_len, nanos_buffer + 1);
-  }
-
-  curr = strlen(buffer);
-  strcpy(buffer + curr, "s");
-
-  p->seconds = 0;
-  p->nanos = 0;
-
-  print_data(p, "\"", 1);
-  print_data(p, buffer, strlen(buffer));
-  print_data(p, "\"", 1);
-
-  if (p->depth_ == 0) {
-    upb_bytessink_end(p->output_);
-  }
-
-  UPB_UNUSED(handler_data);
-  return true;
-}
-
-static bool printer_starttimestampmsg(void *closure, const void *handler_data) {
-  upb_json_printer *p = closure;
-  UPB_UNUSED(handler_data);
-  if (p->depth_ == 0) {
-    upb_bytessink_start(p->output_, 0, &p->subc_);
-  }
-  return true;
-}
-
-#define UPB_TIMESTAMP_MAX_JSON_LEN 31
-#define UPB_TIMESTAMP_BEFORE_NANO_LEN 19
-#define UPB_TIMESTAMP_MAX_NANO_LEN 9
-
-static bool printer_endtimestampmsg(void *closure, const void *handler_data,
-                                    upb_status *s) {
-  upb_json_printer *p = closure;
-  char buffer[UPB_TIMESTAMP_MAX_JSON_LEN];
-  time_t time = p->seconds;
-  size_t curr;
-  size_t i;
-  size_t year_length =
-      strftime(buffer, UPB_TIMESTAMP_MAX_JSON_LEN, "%Y", gmtime(&time));
-
-  if (p->seconds < -62135596800) {
-    upb_status_seterrf(s, "error parsing timestamp: "
-                          "minimum acceptable value is "
-                          "0001-01-01T00:00:00Z");
-    return false;
-  }
-
-  if (p->seconds > 253402300799) {
-    upb_status_seterrf(s, "error parsing timestamp: "
-                          "maximum acceptable value is "
-                          "9999-12-31T23:59:59Z");
-    return false;
-  }
-
-  /* strftime doesn't guarantee 4 digits for year. Prepend 0 by ourselves. */
-  for (i = 0; i < 4 - year_length; i++) {
-    buffer[i] = '0';
-  }
-
-  strftime(buffer + (4 - year_length), UPB_TIMESTAMP_MAX_JSON_LEN,
-           "%Y-%m-%dT%H:%M:%S", gmtime(&time));
-  if (p->nanos != 0) {
-    char nanos_buffer[UPB_TIMESTAMP_MAX_NANO_LEN + 3];
-    snprintf(nanos_buffer, sizeof(nanos_buffer), "%.9f",
-             p->nanos / 1000000000.0);
-    /* Remove trailing 0. */
-    for (i = UPB_TIMESTAMP_MAX_NANO_LEN + 2;
-         nanos_buffer[i] == '0'; i--) {
-      nanos_buffer[i] = 0;
-    }
-    strcpy(buffer + UPB_TIMESTAMP_BEFORE_NANO_LEN, nanos_buffer + 1);
-  }
-
-  curr = strlen(buffer);
-  strcpy(buffer + curr, "Z");
-
-  p->seconds = 0;
-  p->nanos = 0;
-
-  print_data(p, "\"", 1);
-  print_data(p, buffer, strlen(buffer));
-  print_data(p, "\"", 1);
-
-  if (p->depth_ == 0) {
-    upb_bytessink_end(p->output_);
-  }
-
-  UPB_UNUSED(handler_data);
-  UPB_UNUSED(s);
-  return true;
-}
-
-static bool printer_startmsg_noframe(void *closure, const void *handler_data) {
-  upb_json_printer *p = closure;
-  UPB_UNUSED(handler_data);
-  if (p->depth_ == 0) {
-    upb_bytessink_start(p->output_, 0, &p->subc_);
-  }
-  return true;
-}
-
-static bool printer_endmsg_noframe(
-    void *closure, const void *handler_data, upb_status *s) {
-  upb_json_printer *p = closure;
-  UPB_UNUSED(handler_data);
-  UPB_UNUSED(s);
-  if (p->depth_ == 0) {
-    upb_bytessink_end(p->output_);
-  }
-  return true;
-}
-
-static bool printer_startmsg_fieldmask(
-    void *closure, const void *handler_data) {
-  upb_json_printer *p = closure;
-  UPB_UNUSED(handler_data);
-  if (p->depth_ == 0) {
-    upb_bytessink_start(p->output_, 0, &p->subc_);
-  }
-  print_data(p, "\"", 1);
-  return true;
-}
-
-static bool printer_endmsg_fieldmask(
-    void *closure, const void *handler_data, upb_status *s) {
-  upb_json_printer *p = closure;
-  UPB_UNUSED(handler_data);
-  UPB_UNUSED(s);
-  print_data(p, "\"", 1);
-  if (p->depth_ == 0) {
-    upb_bytessink_end(p->output_);
-  }
-  return true;
-}
-
-static void *scalar_startstr_onlykey(
-    void *closure, const void *handler_data, size_t size_hint) {
-  upb_json_printer *p = closure;
-  UPB_UNUSED(size_hint);
-  CHK(putkey(closure, handler_data));
-  return p;
-}
-
-/* Set up handlers for an Any submessage. */
-void printer_sethandlers_any(const void *closure, upb_handlers *h) {
-  const upb_msgdef *md = upb_handlers_msgdef(h);
-
-  const upb_fielddef* type_field = upb_msgdef_itof(md, UPB_ANY_TYPE);
-  const upb_fielddef* value_field = upb_msgdef_itof(md, UPB_ANY_VALUE);
-
-  upb_handlerattr empty_attr = UPB_HANDLERATTR_INIT;
-
-  /* type_url's json name is "@type" */
-  upb_handlerattr type_name_attr = UPB_HANDLERATTR_INIT;
-  upb_handlerattr value_name_attr = UPB_HANDLERATTR_INIT;
-  strpc *type_url_json_name = newstrpc_str(h, "@type");
-  strpc *value_json_name = newstrpc_str(h, "value");
-
-  type_name_attr.handler_data = type_url_json_name;
-  value_name_attr.handler_data = value_json_name;
-
-  /* Set up handlers. */
-  upb_handlers_setstartmsg(h, printer_startmsg, &empty_attr);
-  upb_handlers_setendmsg(h, printer_endmsg, &empty_attr);
-
-  upb_handlers_setstartstr(h, type_field, scalar_startstr, &type_name_attr);
-  upb_handlers_setstring(h, type_field, scalar_str, &empty_attr);
-  upb_handlers_setendstr(h, type_field, scalar_endstr, &empty_attr);
-
-  /* This is not the full and correct JSON encoding for the Any value field. It
-   * requires further processing by the wrapper code based on the type URL.
-   */
-  upb_handlers_setstartstr(h, value_field, scalar_startstr_onlykey,
-                           &value_name_attr);
-
-  UPB_UNUSED(closure);
-}
-
-/* Set up handlers for a fieldmask submessage. */
-void printer_sethandlers_fieldmask(const void *closure, upb_handlers *h) {
-  const upb_msgdef *md = upb_handlers_msgdef(h);
-  const upb_fielddef* f = upb_msgdef_itof(md, 1);
-
-  upb_handlerattr empty_attr = UPB_HANDLERATTR_INIT;
-
-  upb_handlers_setstartseq(h, f, startseq_fieldmask, &empty_attr);
-  upb_handlers_setendseq(h, f, endseq_fieldmask, &empty_attr);
-
-  upb_handlers_setstartmsg(h, printer_startmsg_fieldmask, &empty_attr);
-  upb_handlers_setendmsg(h, printer_endmsg_fieldmask, &empty_attr);
-
-  upb_handlers_setstartstr(h, f, repeated_startstr_fieldmask, &empty_attr);
-  upb_handlers_setstring(h, f, repeated_str_fieldmask, &empty_attr);
-
-  UPB_UNUSED(closure);
-}
-
-/* Set up handlers for a duration submessage. */
-void printer_sethandlers_duration(const void *closure, upb_handlers *h) {
-  const upb_msgdef *md = upb_handlers_msgdef(h);
-
-  const upb_fielddef* seconds_field =
-      upb_msgdef_itof(md, UPB_DURATION_SECONDS);
-  const upb_fielddef* nanos_field =
-      upb_msgdef_itof(md, UPB_DURATION_NANOS);
-
-  upb_handlerattr empty_attr = UPB_HANDLERATTR_INIT;
-
-  upb_handlers_setstartmsg(h, printer_startdurationmsg, &empty_attr);
-  upb_handlers_setint64(h, seconds_field, putseconds, &empty_attr);
-  upb_handlers_setint32(h, nanos_field, putnanos, &empty_attr);
-  upb_handlers_setendmsg(h, printer_enddurationmsg, &empty_attr);
-
-  UPB_UNUSED(closure);
-}
-
-/* Set up handlers for a timestamp submessage. Instead of printing fields
- * separately, the json representation of timestamp follows RFC 3339 */
-void printer_sethandlers_timestamp(const void *closure, upb_handlers *h) {
-  const upb_msgdef *md = upb_handlers_msgdef(h);
-
-  const upb_fielddef* seconds_field =
-      upb_msgdef_itof(md, UPB_TIMESTAMP_SECONDS);
-  const upb_fielddef* nanos_field =
-      upb_msgdef_itof(md, UPB_TIMESTAMP_NANOS);
-
-  upb_handlerattr empty_attr = UPB_HANDLERATTR_INIT;
-
-  upb_handlers_setstartmsg(h, printer_starttimestampmsg, &empty_attr);
-  upb_handlers_setint64(h, seconds_field, putseconds, &empty_attr);
-  upb_handlers_setint32(h, nanos_field, putnanos, &empty_attr);
-  upb_handlers_setendmsg(h, printer_endtimestampmsg, &empty_attr);
-
-  UPB_UNUSED(closure);
-}
-
-void printer_sethandlers_value(const void *closure, upb_handlers *h) {
-  const upb_msgdef *md = upb_handlers_msgdef(h);
-  int i, n;
-
-  upb_handlerattr empty_attr = UPB_HANDLERATTR_INIT;
-
-  upb_handlers_setstartmsg(h, printer_startmsg_noframe, &empty_attr);
-  upb_handlers_setendmsg(h, printer_endmsg_noframe, &empty_attr);
-
-  n = upb_msgdef_fieldcount(md);
-  for (i = 0; i < n; i++) {
-    const upb_fielddef *f = upb_msgdef_field(md, i);
-
-    switch (upb_fielddef_type(f)) {
-      case UPB_TYPE_ENUM:
-        upb_handlers_setint32(h, f, putnull, &empty_attr);
-        break;
-      case UPB_TYPE_DOUBLE:
-        upb_handlers_setdouble(h, f, putdouble, &empty_attr);
-        break;
-      case UPB_TYPE_STRING:
-        upb_handlers_setstartstr(h, f, scalar_startstr_nokey, &empty_attr);
-        upb_handlers_setstring(h, f, scalar_str, &empty_attr);
-        upb_handlers_setendstr(h, f, scalar_endstr, &empty_attr);
-        break;
-      case UPB_TYPE_BOOL:
-        upb_handlers_setbool(h, f, putbool, &empty_attr);
-        break;
-      case UPB_TYPE_MESSAGE:
-        break;
-      default:
-        UPB_ASSERT(false);
-        break;
-    }
-  }
-
-  UPB_UNUSED(closure);
-}
-
-#define WRAPPER_SETHANDLERS(wrapper, type, putmethod)                      \
-void printer_sethandlers_##wrapper(const void *closure, upb_handlers *h) { \
-  const upb_msgdef *md = upb_handlers_msgdef(h);                           \
-  const upb_fielddef* f = upb_msgdef_itof(md, 1);                          \
-  upb_handlerattr empty_attr = UPB_HANDLERATTR_INIT;                \
-  upb_handlers_setstartmsg(h, printer_startmsg_noframe, &empty_attr);      \
-  upb_handlers_setendmsg(h, printer_endmsg_noframe, &empty_attr);          \
-  upb_handlers_set##type(h, f, putmethod, &empty_attr);                    \
-  UPB_UNUSED(closure);                                                     \
-}
-
-WRAPPER_SETHANDLERS(doublevalue, double, putdouble)
-WRAPPER_SETHANDLERS(floatvalue,  float,  putfloat)
-WRAPPER_SETHANDLERS(int64value,  int64,  putint64_t)
-WRAPPER_SETHANDLERS(uint64value, uint64, putuint64_t)
-WRAPPER_SETHANDLERS(int32value,  int32,  putint32_t)
-WRAPPER_SETHANDLERS(uint32value, uint32, putuint32_t)
-WRAPPER_SETHANDLERS(boolvalue,   bool,   putbool)
-WRAPPER_SETHANDLERS(stringvalue, string, putstr_nokey)
-WRAPPER_SETHANDLERS(bytesvalue,  string, putbytes)
-
-#undef WRAPPER_SETHANDLERS
-
-void printer_sethandlers_listvalue(const void *closure, upb_handlers *h) {
-  const upb_msgdef *md = upb_handlers_msgdef(h);
-  const upb_fielddef* f = upb_msgdef_itof(md, 1);
-
-  upb_handlerattr empty_attr = UPB_HANDLERATTR_INIT;
-
-  upb_handlers_setstartseq(h, f, startseq_nokey, &empty_attr);
-  upb_handlers_setendseq(h, f, endseq, &empty_attr);
-
-  upb_handlers_setstartmsg(h, printer_startmsg_noframe, &empty_attr);
-  upb_handlers_setendmsg(h, printer_endmsg_noframe, &empty_attr);
-
-  upb_handlers_setstartsubmsg(h, f, repeated_startsubmsg, &empty_attr);
-
-  UPB_UNUSED(closure);
-}
-
-void printer_sethandlers_structvalue(const void *closure, upb_handlers *h) {
-  const upb_msgdef *md = upb_handlers_msgdef(h);
-  const upb_fielddef* f = upb_msgdef_itof(md, 1);
-
-  upb_handlerattr empty_attr = UPB_HANDLERATTR_INIT;
-
-  upb_handlers_setstartseq(h, f, startmap_nokey, &empty_attr);
-  upb_handlers_setendseq(h, f, endmap, &empty_attr);
-
-  upb_handlers_setstartmsg(h, printer_startmsg_noframe, &empty_attr);
-  upb_handlers_setendmsg(h, printer_endmsg_noframe, &empty_attr);
-
-  upb_handlers_setstartsubmsg(h, f, repeated_startsubmsg, &empty_attr);
-
-  UPB_UNUSED(closure);
-}
-
-void printer_sethandlers(const void *closure, upb_handlers *h) {
-  const upb_msgdef *md = upb_handlers_msgdef(h);
-  bool is_mapentry = upb_msgdef_mapentry(md);
-  upb_handlerattr empty_attr = UPB_HANDLERATTR_INIT;
-  int i, n;
-  const upb_json_printercache *cache = closure;
-  const bool preserve_fieldnames = cache->preserve_fieldnames;
-
-  if (is_mapentry) {
-    /* mapentry messages are sufficiently different that we handle them
-     * separately. */
-    printer_sethandlers_mapentry(closure, preserve_fieldnames, h);
-    return;
-  }
-
-  switch (upb_msgdef_wellknowntype(md)) {
-    case UPB_WELLKNOWN_UNSPECIFIED:
-      break;
-    case UPB_WELLKNOWN_ANY:
-      printer_sethandlers_any(closure, h);
-      return;
-    case UPB_WELLKNOWN_FIELDMASK:
-      printer_sethandlers_fieldmask(closure, h);
-      return;
-    case UPB_WELLKNOWN_DURATION:
-      printer_sethandlers_duration(closure, h);
-      return;
-    case UPB_WELLKNOWN_TIMESTAMP:
-      printer_sethandlers_timestamp(closure, h);
-      return;
-    case UPB_WELLKNOWN_VALUE:
-      printer_sethandlers_value(closure, h);
-      return;
-    case UPB_WELLKNOWN_LISTVALUE:
-      printer_sethandlers_listvalue(closure, h);
-      return;
-    case UPB_WELLKNOWN_STRUCT:
-      printer_sethandlers_structvalue(closure, h);
-      return;
-#define WRAPPER(wellknowntype, name)        \
-  case wellknowntype:                       \
-    printer_sethandlers_##name(closure, h); \
-    return;                                 \
-
-    WRAPPER(UPB_WELLKNOWN_DOUBLEVALUE, doublevalue);
-    WRAPPER(UPB_WELLKNOWN_FLOATVALUE, floatvalue);
-    WRAPPER(UPB_WELLKNOWN_INT64VALUE, int64value);
-    WRAPPER(UPB_WELLKNOWN_UINT64VALUE, uint64value);
-    WRAPPER(UPB_WELLKNOWN_INT32VALUE, int32value);
-    WRAPPER(UPB_WELLKNOWN_UINT32VALUE, uint32value);
-    WRAPPER(UPB_WELLKNOWN_BOOLVALUE, boolvalue);
-    WRAPPER(UPB_WELLKNOWN_STRINGVALUE, stringvalue);
-    WRAPPER(UPB_WELLKNOWN_BYTESVALUE, bytesvalue);
-
-#undef WRAPPER
-  }
-
-  upb_handlers_setstartmsg(h, printer_startmsg, &empty_attr);
-  upb_handlers_setendmsg(h, printer_endmsg, &empty_attr);
-
-#define TYPE(type, name, ctype)                                               \
-  case type:                                                                  \
-    if (upb_fielddef_isseq(f)) {                                              \
-      upb_handlers_set##name(h, f, repeated_##ctype, &empty_attr);            \
-    } else {                                                                  \
-      upb_handlers_set##name(h, f, scalar_##ctype, &name_attr);               \
-    }                                                                         \
-    break;
-
-  n = upb_msgdef_fieldcount(md);
-  for (i = 0; i < n; i++) {
-    const upb_fielddef *f = upb_msgdef_field(md, i);
-
-    upb_handlerattr name_attr = UPB_HANDLERATTR_INIT;
-    name_attr.handler_data = newstrpc(h, f, preserve_fieldnames);
-
-    if (upb_fielddef_ismap(f)) {
-      upb_handlers_setstartseq(h, f, startmap, &name_attr);
-      upb_handlers_setendseq(h, f, endmap, &name_attr);
-    } else if (upb_fielddef_isseq(f)) {
-      upb_handlers_setstartseq(h, f, startseq, &name_attr);
-      upb_handlers_setendseq(h, f, endseq, &empty_attr);
-    }
-
-    switch (upb_fielddef_type(f)) {
-      TYPE(UPB_TYPE_FLOAT,  float,  float);
-      TYPE(UPB_TYPE_DOUBLE, double, double);
-      TYPE(UPB_TYPE_BOOL,   bool,   bool);
-      TYPE(UPB_TYPE_INT32,  int32,  int32_t);
-      TYPE(UPB_TYPE_UINT32, uint32, uint32_t);
-      TYPE(UPB_TYPE_INT64,  int64,  int64_t);
-      TYPE(UPB_TYPE_UINT64, uint64, uint64_t);
-      case UPB_TYPE_ENUM: {
-        /* For now, we always emit symbolic names for enums. We may want an
-         * option later to control this behavior, but we will wait for a real
-         * need first. */
-        upb_handlerattr enum_attr = UPB_HANDLERATTR_INIT;
-        set_enum_hd(h, f, preserve_fieldnames, &enum_attr);
-
-        if (upb_fielddef_isseq(f)) {
-          upb_handlers_setint32(h, f, repeated_enum, &enum_attr);
-        } else {
-          upb_handlers_setint32(h, f, scalar_enum, &enum_attr);
-        }
-
-        break;
-      }
-      case UPB_TYPE_STRING:
-        if (upb_fielddef_isseq(f)) {
-          upb_handlers_setstartstr(h, f, repeated_startstr, &empty_attr);
-          upb_handlers_setstring(h, f, repeated_str, &empty_attr);
-          upb_handlers_setendstr(h, f, repeated_endstr, &empty_attr);
-        } else {
-          upb_handlers_setstartstr(h, f, scalar_startstr, &name_attr);
-          upb_handlers_setstring(h, f, scalar_str, &empty_attr);
-          upb_handlers_setendstr(h, f, scalar_endstr, &empty_attr);
-        }
-        break;
-      case UPB_TYPE_BYTES:
-        /* XXX: this doesn't support strings that span buffers yet. The base64
-         * encoder will need to be made resumable for this to work properly. */
-        if (upb_fielddef_isseq(f)) {
-          upb_handlers_setstring(h, f, repeated_bytes, &empty_attr);
-        } else {
-          upb_handlers_setstring(h, f, scalar_bytes, &name_attr);
-        }
-        break;
-      case UPB_TYPE_MESSAGE:
-        if (upb_fielddef_isseq(f)) {
-          upb_handlers_setstartsubmsg(h, f, repeated_startsubmsg, &name_attr);
-        } else {
-          upb_handlers_setstartsubmsg(h, f, scalar_startsubmsg, &name_attr);
-        }
-        break;
-    }
-  }
-
-#undef TYPE
-}
-
-static void json_printer_reset(upb_json_printer *p) {
-  p->depth_ = 0;
-}
-
-
-/* Public API *****************************************************************/
-
-upb_json_printer *upb_json_printer_create(upb_arena *a, const upb_handlers *h,
-                                          upb_bytessink output) {
-  upb_json_printer *p = upb_arena_malloc(a, sizeof(upb_json_printer));
-  if (!p) return NULL;
-
-  p->output_ = output;
-  json_printer_reset(p);
-  upb_sink_reset(&p->input_, h, p);
-  p->seconds = 0;
-  p->nanos = 0;
-
-  return p;
-}
-
-upb_sink upb_json_printer_input(upb_json_printer *p) {
-  return p->input_;
-}
-
-upb_handlercache *upb_json_printer_newcache(bool preserve_proto_fieldnames) {
-  upb_json_printercache *cache = upb_gmalloc(sizeof(*cache));
-  upb_handlercache *ret = upb_handlercache_new(printer_sethandlers, cache);
-
-  cache->preserve_fieldnames = preserve_proto_fieldnames;
-  upb_handlercache_addcleanup(ret, cache, upb_gfree);
-
-  return ret;
-}
diff --git a/third_party/upb/upb/json/printer.h b/third_party/upb/upb/json/printer.h
deleted file mode 100644 (file)
index 85b9b12..0000000
+++ /dev/null
@@ -1,72 +0,0 @@
-/*
-** upb::json::Printer
-**
-** Handlers that emit JSON according to a specific protobuf schema.
-*/
-
-#ifndef UPB_JSON_TYPED_PRINTER_H_
-#define UPB_JSON_TYPED_PRINTER_H_
-
-#include "upb/sink.h"
-
-#ifdef __cplusplus
-namespace upb {
-namespace json {
-class PrinterPtr;
-}  /* namespace json */
-}  /* namespace upb */
-#endif
-
-/* upb_json_printer ***********************************************************/
-
-#define UPB_JSON_PRINTER_SIZE 192
-
-struct upb_json_printer;
-typedef struct upb_json_printer upb_json_printer;
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-/* Native C API. */
-upb_json_printer *upb_json_printer_create(upb_arena *a, const upb_handlers *h,
-                                          upb_bytessink output);
-upb_sink upb_json_printer_input(upb_json_printer *p);
-const upb_handlers *upb_json_printer_newhandlers(const upb_msgdef *md,
-                                                 bool preserve_fieldnames,
-                                                 const void *owner);
-
-/* Lazily builds and caches handlers that will push encoded data to a bytessink.
- * Any msgdef objects used with this object must outlive it. */
-upb_handlercache *upb_json_printer_newcache(bool preserve_proto_fieldnames);
-
-#ifdef __cplusplus
-}  /* extern "C" */
-
-/* Prints an incoming stream of data to a BytesSink in JSON format. */
-class upb::json::PrinterPtr {
- public:
-  PrinterPtr(upb_json_printer* ptr) : ptr_(ptr) {}
-
-  static PrinterPtr Create(Arena *arena, const upb::Handlers *handlers,
-                           BytesSink output) {
-    return PrinterPtr(
-        upb_json_printer_create(arena->ptr(), handlers, output.sink()));
-  }
-
-  /* The input to the printer. */
-  Sink input() { return upb_json_printer_input(ptr_); }
-
-  static const size_t kSize = UPB_JSON_PRINTER_SIZE;
-
-  static HandlerCache NewCache(bool preserve_proto_fieldnames) {
-    return upb_json_printer_newcache(preserve_proto_fieldnames);
-  }
-
- private:
-  upb_json_printer* ptr_;
-};
-
-#endif  /* __cplusplus */
-
-#endif  /* UPB_JSON_TYPED_PRINTER_H_ */
index bb33744..b574a17 100644 (file)
@@ -1,3 +1,29 @@
+/*
+ * Copyright (c) 2009-2021, Google LLC
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ *     * Redistributions of source code must retain the above copyright
+ *       notice, this list of conditions and the following disclaimer.
+ *     * Redistributions in binary form must reproduce the above copyright
+ *       notice, this list of conditions and the following disclaimer in the
+ *       documentation and/or other materials provided with the distribution.
+ *     * Neither the name of Google LLC nor the
+ *       names of its contributors may be used to endorse or promote products
+ *       derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+ * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ * DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+ * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+ * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+ * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
 
 #include "upb/json_decode.h"
 
@@ -62,6 +88,7 @@ UPB_NORETURN static void jsondec_err(jsondec *d, const char *msg) {
   UPB_LONGJMP(d->err, 1);
 }
 
+UPB_PRINTF(2, 3)
 UPB_NORETURN static void jsondec_errf(jsondec *d, const char *fmt, ...) {
   va_list argp;
   upb_status_seterrf(d->status, "Error parsing JSON @%d:%d: ", d->line,
@@ -678,7 +705,7 @@ static upb_msgval jsondec_int(jsondec *d, const upb_fielddef *f) {
       }
       val.int64_val = dbl;  /* must be guarded, overflow here is UB */
       if (val.int64_val != dbl) {
-        jsondec_errf(d, "JSON number was not integral (%d != %" PRId64 ")", dbl,
+        jsondec_errf(d, "JSON number was not integral (%f != %" PRId64 ")", dbl,
                      val.int64_val);
       }
       break;
@@ -704,7 +731,7 @@ static upb_msgval jsondec_int(jsondec *d, const upb_fielddef *f) {
 
 /* Parse UINT32 or UINT64 value. */
 static upb_msgval jsondec_uint(jsondec *d, const upb_fielddef *f) {
-  upb_msgval val;
+  upb_msgval val = {0};
 
   switch (jsondec_peek(d)) {
     case JD_NUMBER: {
@@ -714,7 +741,7 @@ static upb_msgval jsondec_uint(jsondec *d, const upb_fielddef *f) {
       }
       val.uint64_val = dbl;  /* must be guarded, overflow here is UB */
       if (val.uint64_val != dbl) {
-        jsondec_errf(d, "JSON number was not integral (%d != %" PRIu64 ")", dbl,
+        jsondec_errf(d, "JSON number was not integral (%f != %" PRIu64 ")", dbl,
                      val.uint64_val);
       }
       break;
@@ -741,7 +768,7 @@ static upb_msgval jsondec_uint(jsondec *d, const upb_fielddef *f) {
 /* Parse DOUBLE or FLOAT value. */
 static upb_msgval jsondec_double(jsondec *d, const upb_fielddef *f) {
   upb_strview str;
-  upb_msgval val;
+  upb_msgval val = {0};
 
   switch (jsondec_peek(d)) {
     case JD_NUMBER:
@@ -905,24 +932,24 @@ static void jsondec_field(jsondec *d, upb_msg *msg, const upb_msgdef *m) {
 
   if (!f) {
     if ((d->options & UPB_JSONDEC_IGNOREUNKNOWN) == 0) {
-      jsondec_errf(d, "Unknown field: '" UPB_STRVIEW_FORMAT "'",
+      jsondec_errf(d, "No such field: " UPB_STRVIEW_FORMAT,
                    UPB_STRVIEW_ARGS(name));
     }
     jsondec_skipval(d);
     return;
   }
 
-  if (upb_fielddef_realcontainingoneof(f) &&
-      upb_msg_whichoneof(msg, upb_fielddef_containingoneof(f))) {
-    jsondec_err(d, "More than one field for this oneof.");
-  }
-
   if (jsondec_peek(d) == JD_NULL && !jsondec_isvalue(f)) {
     /* JSON "null" indicates a default value, so no need to set anything. */
     jsondec_null(d);
     return;
   }
 
+  if (upb_fielddef_realcontainingoneof(f) &&
+      upb_msg_whichoneof(msg, upb_fielddef_containingoneof(f))) {
+    jsondec_err(d, "More than one field for this oneof.");
+  }
+
   preserved = d->debug_field;
   d->debug_field = f;
 
@@ -1058,7 +1085,8 @@ static void jsondec_timestamp(jsondec *d, upb_msg *msg, const upb_msgdef *m) {
 
   {
     /* [+-]08:00 or Z */
-    int ofs = 0;
+    int ofs_hour = 0;
+    int ofs_min = 0;
     bool neg = false;
 
     if (ptr == end) goto malformed;
@@ -1069,9 +1097,10 @@ static void jsondec_timestamp(jsondec *d, upb_msg *msg, const upb_msgdef *m) {
         /* fallthrough */
       case '+':
         if ((end - ptr) != 5) goto malformed;
-        ofs = jsondec_tsdigits(d, &ptr, 2, ":00");
-        ofs *= 60 * 60;
-        seconds.int64_val += (neg ? ofs : -ofs);
+        ofs_hour = jsondec_tsdigits(d, &ptr, 2, ":");
+        ofs_min = jsondec_tsdigits(d, &ptr, 2, NULL);
+        ofs_min = ((ofs_hour * 60) + ofs_min) * 60;
+        seconds.int64_val += (neg ? ofs_min : -ofs_min);
         break;
       case 'Z':
         if (ptr != end) goto malformed;
@@ -1424,6 +1453,9 @@ bool upb_json_decode(const char *buf, size_t size, upb_msg *msg,
                      const upb_msgdef *m, const upb_symtab *any_pool,
                      int options, upb_arena *arena, upb_status *status) {
   jsondec d;
+
+  if (size == 0) return true;
+
   d.ptr = buf;
   d.end = buf + size;
   d.arena = arena;
index a0ba1ee..9ace310 100644 (file)
@@ -1,3 +1,29 @@
+/*
+ * Copyright (c) 2009-2021, Google LLC
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ *     * Redistributions of source code must retain the above copyright
+ *       notice, this list of conditions and the following disclaimer.
+ *     * Redistributions in binary form must reproduce the above copyright
+ *       notice, this list of conditions and the following disclaimer in the
+ *       documentation and/or other materials provided with the distribution.
+ *     * Neither the name of Google LLC nor the
+ *       names of its contributors may be used to endorse or promote products
+ *       derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+ * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ * DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+ * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+ * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+ * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
 
 #ifndef UPB_JSONDECODE_H_
 #define UPB_JSONDECODE_H_
index 9217c65..31725cf 100644 (file)
@@ -1,3 +1,29 @@
+/*
+ * Copyright (c) 2009-2021, Google LLC
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ *     * Redistributions of source code must retain the above copyright
+ *       notice, this list of conditions and the following disclaimer.
+ *     * Redistributions in binary form must reproduce the above copyright
+ *       notice, this list of conditions and the following disclaimer in the
+ *       documentation and/or other materials provided with the distribution.
+ *     * Neither the name of Google LLC nor the
+ *       names of its contributors may be used to endorse or promote products
+ *       derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+ * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ * DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+ * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+ * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+ * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
 
 #include "upb/json_encode.h"
 
@@ -32,7 +58,7 @@ static void jsonenc_scalar(jsonenc *e, upb_msgval val, const upb_fielddef *f);
 static void jsonenc_msgfield(jsonenc *e, const upb_msg *msg,
                              const upb_msgdef *m);
 static void jsonenc_msgfields(jsonenc *e, const upb_msg *msg,
-                              const upb_msgdef *m);
+                              const upb_msgdef *m, bool first);
 static void jsonenc_value(jsonenc *e, const upb_msg *msg, const upb_msgdef *m);
 
 UPB_NORETURN static void jsonenc_err(jsonenc *e, const char *msg) {
@@ -40,6 +66,7 @@ UPB_NORETURN static void jsonenc_err(jsonenc *e, const char *msg) {
   longjmp(e->err, 1);
 }
 
+UPB_PRINTF(2, 3)
 UPB_NORETURN static void jsonenc_errf(jsonenc *e, const char *fmt, ...) {
   va_list argp;
   va_start(argp, fmt);
@@ -62,8 +89,10 @@ static void jsonenc_putbytes(jsonenc *e, const void *data, size_t len) {
     memcpy(e->ptr, data, len);
     e->ptr += len;
   } else {
-    if (have) memcpy(e->ptr, data, have);
-    e->ptr += have;
+    if (have) {
+      memcpy(e->ptr, data, have);
+      e->ptr += have;
+    }
     e->overflow += (len - have);
   }
 }
@@ -72,6 +101,7 @@ static void jsonenc_putstr(jsonenc *e, const char *str) {
   jsonenc_putbytes(e, str, strlen(str));
 }
 
+UPB_PRINTF(2, 3)
 static void jsonenc_printf(jsonenc *e, const char *fmt, ...) {
   size_t n;
   size_t have = e->end - e->ptr;
@@ -84,7 +114,7 @@ static void jsonenc_printf(jsonenc *e, const char *fmt, ...) {
   if (UPB_LIKELY(have > n)) {
     e->ptr += n;
   } else {
-    e->ptr += have;
+    e->ptr = UPB_PTRADD(e->ptr, have);
     e->overflow += (n - have);
   }
 }
@@ -102,7 +132,7 @@ static void jsonenc_nanos(jsonenc *e, int32_t nanos) {
     digits -= 3;
   }
 
-  jsonenc_printf(e, ".%0.*" PRId32, digits, nanos);
+  jsonenc_printf(e, ".%.*" PRId32, digits, nanos);
 }
 
 static void jsonenc_timestamp(jsonenc *e, const upb_msg *msg,
@@ -188,7 +218,7 @@ static void jsonenc_bytes(jsonenc *e, upb_strview str) {
   static const char base64[] =
       "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";
   const unsigned char *ptr = (unsigned char*)str.data;
-  const unsigned char *end = ptr + str.size;
+  const unsigned char *end = UPB_PTRADD(ptr, str.size);
   char buf[4];
 
   jsonenc_putstr(e, "\"");
@@ -224,7 +254,7 @@ static void jsonenc_bytes(jsonenc *e, upb_strview str) {
 
 static void jsonenc_stringbody(jsonenc *e, upb_strview str) {
   const char *ptr = str.data;
-  const char *end = ptr + str.size;
+  const char *end = UPB_PTRADD(ptr, str.size);
 
   while (ptr < end) {
     switch (*ptr) {
@@ -277,7 +307,17 @@ static void jsonenc_double(jsonenc *e, const char *fmt, double val) {
   } else if (val != val) {
     jsonenc_putstr(e, "\"NaN\"");
   } else {
+    char *p = e->ptr;
     jsonenc_printf(e, fmt, val);
+
+    /* printf() is dependent on locales; sadly there is no easy and portable way
+     * to avoid this. This little post-processing step will translate 1,2 -> 1.2
+     * since JSON needs the latter. Arguably a hack, but it is simple and the
+     * alternatives are far more complicated, platform-dependent, and/or larger
+     * in code size. */
+    for (char *end = e->ptr; p < end; p++) {
+      if (*p == ',') *p = '.';
+    }
   }
 }
 
@@ -340,14 +380,13 @@ static void jsonenc_any(jsonenc *e, const upb_msg *msg, const upb_msgdef *m) {
 
   jsonenc_putstr(e, "{\"@type\":");
   jsonenc_string(e, type_url);
-  jsonenc_putstr(e, ",");
 
   if (upb_msgdef_wellknowntype(any_m) == UPB_WELLKNOWN_UNSPECIFIED) {
     /* Regular messages: {"@type": "...","foo": 1, "bar": 2} */
-    jsonenc_msgfields(e, any, any_m);
+    jsonenc_msgfields(e, any, any_m, false);
   } else {
     /* Well-known type: {"@type": "...","value": <well-known encoding>} */
-    jsonenc_putstr(e, "\"value\":");
+    jsonenc_putstr(e, ",\"value\":");
     jsonenc_msgfield(e, any, any_m);
   }
 
@@ -650,10 +689,9 @@ static void jsonenc_fieldval(jsonenc *e, const upb_fielddef *f,
 }
 
 static void jsonenc_msgfields(jsonenc *e, const upb_msg *msg,
-                              const upb_msgdef *m) {
+                              const upb_msgdef *m, bool first) {
   upb_msgval val;
   const upb_fielddef *f;
-  bool first = true;
 
   if (e->options & UPB_JSONENC_EMITDEFAULTS) {
     /* Iterate over all fields. */
@@ -676,7 +714,7 @@ static void jsonenc_msgfields(jsonenc *e, const upb_msg *msg,
 
 static void jsonenc_msg(jsonenc *e, const upb_msg *msg, const upb_msgdef *m) {
   jsonenc_putstr(e, "{");
-  jsonenc_msgfields(e, msg, m);
+  jsonenc_msgfields(e, msg, m, true);
   jsonenc_putstr(e, "}");
 }
 
@@ -698,7 +736,7 @@ size_t upb_json_encode(const upb_msg *msg, const upb_msgdef *m,
 
   e.buf = buf;
   e.ptr = buf;
-  e.end = buf + size;
+  e.end = UPB_PTRADD(buf, size);
   e.overflow = 0;
   e.options = options;
   e.ext_pool = ext_pool;
index 0ad4163..1065af7 100644 (file)
@@ -1,3 +1,29 @@
+/*
+ * Copyright (c) 2009-2021, Google LLC
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ *     * Redistributions of source code must retain the above copyright
+ *       notice, this list of conditions and the following disclaimer.
+ *     * Redistributions in binary form must reproduce the above copyright
+ *       notice, this list of conditions and the following disclaimer in the
+ *       documentation and/or other materials provided with the distribution.
+ *     * Neither the name of Google LLC nor the
+ *       names of its contributors may be used to endorse or promote products
+ *       derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+ * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ * DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+ * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+ * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+ * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
 
 #ifndef UPB_JSONENCODE_H_
 #define UPB_JSONENCODE_H_
index 876a06d..ad2d547 100644 (file)
@@ -1,13 +1,39 @@
+/*
+ * Copyright (c) 2009-2021, Google LLC
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ *     * Redistributions of source code must retain the above copyright
+ *       notice, this list of conditions and the following disclaimer.
+ *     * Redistributions in binary form must reproduce the above copyright
+ *       notice, this list of conditions and the following disclaimer in the
+ *       documentation and/or other materials provided with the distribution.
+ *     * Neither the name of Google LLC nor the
+ *       names of its contributors may be used to endorse or promote products
+ *       derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+ * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ * DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+ * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+ * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+ * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
 
 #include "upb/msg.h"
 
-#include "upb/table.int.h"
-
+#include "upb/msg_internal.h"
 #include "upb/port_def.inc"
+#include "upb/table_internal.h"
 
 /** upb_msg *******************************************************************/
 
-static const size_t overhead = sizeof(upb_msg_internal);
+static const size_t overhead = sizeof(upb_msg_internaldata);
 
 static const upb_msg_internal *upb_msg_getinternal_const(const upb_msg *msg) {
   ptrdiff_t size = sizeof(upb_msg_internal);
@@ -23,49 +49,107 @@ void _upb_msg_clear(upb_msg *msg, const upb_msglayout *l) {
   memset(mem, 0, upb_msg_sizeof(l));
 }
 
+static bool realloc_internal(upb_msg *msg, size_t need, upb_arena *arena) {
+  upb_msg_internal *in = upb_msg_getinternal(msg);
+  if (!in->internal) {
+    /* No internal data, allocate from scratch. */
+    size_t size = UPB_MAX(128, _upb_lg2ceilsize(need + overhead));
+    upb_msg_internaldata *internal = upb_arena_malloc(arena, size);
+    if (!internal) return false;
+    internal->size = size;
+    internal->unknown_end = overhead;
+    internal->ext_begin = size;
+    in->internal = internal;
+  } else if (in->internal->ext_begin - in->internal->unknown_end < need) {
+    /* Internal data is too small, reallocate. */
+    size_t new_size = _upb_lg2ceilsize(in->internal->size + need);
+    size_t ext_bytes = in->internal->size - in->internal->ext_begin;
+    size_t new_ext_begin = new_size - ext_bytes;
+    upb_msg_internaldata *internal =
+        upb_arena_realloc(arena, in->internal, in->internal->size, new_size);
+    if (!internal) return false;
+    if (ext_bytes) {
+      /* Need to move extension data to the end. */
+      char *ptr = (char*)internal;
+      memmove(ptr + new_ext_begin, ptr + internal->ext_begin, ext_bytes);
+    }
+    internal->ext_begin = new_ext_begin;
+    internal->size = new_size;
+    in->internal = internal;
+  }
+  UPB_ASSERT(in->internal->ext_begin - in->internal->unknown_end >= need);
+  return true;
+}
+
 bool _upb_msg_addunknown(upb_msg *msg, const char *data, size_t len,
                          upb_arena *arena) {
-
+  if (!realloc_internal(msg, len, arena)) return false;
   upb_msg_internal *in = upb_msg_getinternal(msg);
-  if (!in->unknown) {
-    size_t size = 128;
-    while (size < len) size *= 2;
-    in->unknown = upb_arena_malloc(arena, size + overhead);
-    if (!in->unknown) return false;
-    in->unknown->size = size;
-    in->unknown->len = 0;
-  } else if (in->unknown->size - in->unknown->len < len) {
-    size_t need = in->unknown->len + len;
-    size_t size = in->unknown->size;
-    while (size < need)  size *= 2;
-    in->unknown = upb_arena_realloc(
-        arena, in->unknown, in->unknown->size + overhead, size + overhead);
-    if (!in->unknown) return false;
-    in->unknown->size = size;
-  }
-  memcpy(UPB_PTR_AT(in->unknown + 1, in->unknown->len, char), data, len);
-  in->unknown->len += len;
+  memcpy(UPB_PTR_AT(in->internal, in->internal->unknown_end, char), data, len);
+  in->internal->unknown_end += len;
   return true;
 }
 
 void _upb_msg_discardunknown_shallow(upb_msg *msg) {
   upb_msg_internal *in = upb_msg_getinternal(msg);
-  if (in->unknown) {
-    in->unknown->len = 0;
+  if (in->internal) {
+    in->internal->unknown_end = overhead;
   }
 }
 
 const char *upb_msg_getunknown(const upb_msg *msg, size_t *len) {
   const upb_msg_internal *in = upb_msg_getinternal_const(msg);
-  if (in->unknown) {
-    *len = in->unknown->len;
-    return (char*)(in->unknown + 1);
+  if (in->internal) {
+    *len = in->internal->unknown_end - overhead;
+    return (char*)(in->internal + 1);
   } else {
     *len = 0;
     return NULL;
   }
 }
 
+const upb_msg_ext *_upb_msg_getexts(const upb_msg *msg, size_t *count) {
+  const upb_msg_internal *in = upb_msg_getinternal_const(msg);
+  if (in->internal) {
+    *count =
+        (in->internal->size - in->internal->ext_begin) / sizeof(upb_msg_ext);
+    return UPB_PTR_AT(in->internal, in->internal->ext_begin, void);
+  } else {
+    *count = 0;
+    return NULL;
+  }
+}
+
+const upb_msg_ext *_upb_msg_getext(const upb_msg *msg,
+                                   const upb_msglayout_ext *e) {
+  size_t n;
+  const upb_msg_ext *ext = _upb_msg_getexts(msg, &n);
+
+  /* For now we use linear search exclusively to find extensions. If this
+   * becomes an issue due to messages with lots of extensions, we can introduce
+   * a table of some sort. */
+  for (size_t i = 0; i < n; i++) {
+    if (ext[i].ext == e) {
+      return &ext[i];
+    }
+  }
+
+  return NULL;
+}
+
+upb_msg_ext *_upb_msg_getorcreateext(upb_msg *msg, const upb_msglayout_ext *e,
+                                     upb_arena *arena) {
+  upb_msg_ext *ext = (upb_msg_ext*)_upb_msg_getext(msg, e);
+  if (ext) return ext;
+  if (!realloc_internal(msg, sizeof(upb_msg_ext), arena)) return NULL;
+  upb_msg_internal *in = upb_msg_getinternal(msg);
+  in->internal->ext_begin -= sizeof(upb_msg_ext);
+  ext = UPB_PTR_AT(in->internal, in->internal->ext_begin, void);
+  memset(ext, 0, sizeof(upb_msg_ext));
+  ext->ext = e;
+  return ext;
+}
+
 /** upb_array *****************************************************************/
 
 bool _upb_array_realloc(upb_array *arr, size_t min_size, upb_arena *arena) {
@@ -133,7 +217,7 @@ upb_map *_upb_map_new(upb_arena *a, size_t key_size, size_t value_size) {
     return NULL;
   }
 
-  upb_strtable_init2(&map->table, UPB_CTYPE_INT32, 4, upb_arena_alloc(a));
+  upb_strtable_init(&map->table, 4, a);
   map->key_size = key_size;
   map->val_size = value_size;
 
@@ -254,3 +338,60 @@ bool _upb_mapsorter_pushmap(_upb_mapsorter *s, upb_descriptortype_t key_type,
   qsort(&s->entries[sorted->start], map_size, sizeof(*s->entries), compar);
   return true;
 }
+
+/** upb_extreg ****************************************************************/
+
+struct upb_extreg {
+  upb_arena *arena;
+  upb_strtable exts;  /* Key is upb_msglayout* concatenated with fieldnum. */
+};
+
+#define EXTREG_KEY_SIZE (sizeof(upb_msglayout*) + sizeof(uint32_t))
+
+static void extreg_key(char *buf, const upb_msglayout *l, uint32_t fieldnum) {
+  memcpy(buf, &l, sizeof(l));
+  memcpy(buf + sizeof(l), &fieldnum, sizeof(fieldnum));
+}
+
+upb_extreg *upb_extreg_new(upb_arena *arena) {
+  upb_extreg *r = upb_arena_malloc(arena, sizeof(*r));
+  if (!r) return NULL;
+  r->arena = arena;
+  if (!upb_strtable_init(&r->exts, 8, arena)) return NULL;
+  return r;
+}
+
+bool _upb_extreg_add(upb_extreg *r, const upb_msglayout_ext *e, size_t count) {
+  char buf[EXTREG_KEY_SIZE];
+  const upb_msglayout_ext *start = e;
+  const upb_msglayout_ext *end = e + count;
+  for (; e < end; e++) {
+    extreg_key(buf, e->extendee, e->field.number);
+    if (!upb_strtable_insert(&r->exts, buf, EXTREG_KEY_SIZE,
+                             upb_value_constptr(e), r->arena)) {
+      goto failure;
+    }
+  }
+  return true;
+
+failure:
+  /* Back out the entries previously added. */
+  for (end = e, e = start; e < end; e++) {
+    extreg_key(buf, e->extendee, e->field.number);
+    upb_strtable_remove(&r->exts, buf, EXTREG_KEY_SIZE, NULL);
+  }
+  return false;
+}
+
+const upb_msglayout_field *_upb_extreg_get(const upb_extreg *r,
+                                           const upb_msglayout *l,
+                                           uint32_t num) {
+  char buf[EXTREG_KEY_SIZE];
+  upb_value v;
+  extreg_key(buf, l, num);
+  if (upb_strtable_lookup2(&r->exts, buf, EXTREG_KEY_SIZE, &v)) {
+    return upb_value_getconstptr(v);
+  } else {
+    return NULL;
+  }
+}
index 9b4557a..497bd82 100644 (file)
 /*
-** Our memory representation for parsing tables and messages themselves.
-** Functions in this file are used by generated code and possibly reflection.
-**
-** The definitions in this file are internal to upb.
-**/
+ * Copyright (c) 2009-2021, Google LLC
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ *     * Redistributions of source code must retain the above copyright
+ *       notice, this list of conditions and the following disclaimer.
+ *     * Redistributions in binary form must reproduce the above copyright
+ *       notice, this list of conditions and the following disclaimer in the
+ *       documentation and/or other materials provided with the distribution.
+ *     * Neither the name of Google LLC nor the
+ *       names of its contributors may be used to endorse or promote products
+ *       derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+ * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ * DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+ * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+ * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+ * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+/*
+ * Public APIs for message operations that do not require descriptors.
+ * These functions can be used even in build that does not want to depend on
+ * reflection or descriptors.
+ *
+ * Descriptor-based reflection functionality lives in reflection.h.
+ */
 
 #ifndef UPB_MSG_H_
 #define UPB_MSG_H_
 
-#include <stdint.h>
-#include <stdlib.h>
-#include <string.h>
+#include <stddef.h>
 
-#include "upb/table.int.h"
 #include "upb/upb.h"
 
-/* Must be last. */
-#include "upb/port_def.inc"
-
 #ifdef __cplusplus
 extern "C" {
 #endif
 
-#define PTR_AT(msg, ofs, type) (type*)((const char*)msg + ofs)
-
 typedef void upb_msg;
 
-/** upb_msglayout *************************************************************/
-
-/* upb_msglayout represents the memory layout of a given upb_msgdef.  The
- * members are public so generated code can initialize them, but users MUST NOT
- * read or write any of its members. */
-
-/* These aren't real labels according to descriptor.proto, but in the table we
- * use these for map/packed fields instead of UPB_LABEL_REPEATED. */
-enum {
-  _UPB_LABEL_MAP = 4,
-  _UPB_LABEL_PACKED = 7  /* Low 3 bits are common with UPB_LABEL_REPEATED. */
-};
-
-typedef struct {
-  uint32_t number;
-  uint16_t offset;
-  int16_t presence;       /* If >0, hasbit_index.  If <0, ~oneof_index. */
-  uint16_t submsg_index;  /* undefined if descriptortype != MESSAGE or GROUP. */
-  uint8_t descriptortype;
-  uint8_t label;          /* google.protobuf.Label or _UPB_LABEL_* above. */
-} upb_msglayout_field;
-
-struct upb_decstate;
+/* For users these are opaque. They can be obtained from upb_msgdef_layout()
+ * but users cannot access any of the members. */
 struct upb_msglayout;
-
-typedef const char *_upb_field_parser(struct upb_decstate *d, const char *ptr,
-                                      upb_msg *msg, intptr_t table,
-                                      uint64_t hasbits, uint64_t data);
-
-typedef struct {
-  uint64_t field_data;
-  _upb_field_parser *field_parser;
-} _upb_fasttable_entry;
-
-typedef struct upb_msglayout {
-  const struct upb_msglayout *const* submsgs;
-  const upb_msglayout_field *fields;
-  /* Must be aligned to sizeof(void*).  Doesn't include internal members like
-   * unknown fields, extension dict, pointer to msglayout, etc. */
-  uint16_t size;
-  uint16_t field_count;
-  bool extendable;
-  uint8_t table_mask;
-  /* To constant-initialize the tables of variable length, we need a flexible
-   * array member, and we need to compile in C99 mode. */
-  _upb_fasttable_entry fasttable[];
-} upb_msglayout;
-
-/** upb_msg *******************************************************************/
-
-/* Internal members of a upb_msg.  We can change this without breaking binary
- * compatibility.  We put these before the user's data.  The user's upb_msg*
- * points after the upb_msg_internal. */
-
-typedef struct {
-  uint32_t len;
-  uint32_t size;
-  /* Data follows. */
-} upb_msg_unknowndata;
-
-/* Used when a message is not extendable. */
-typedef struct {
-  upb_msg_unknowndata *unknown;
-} upb_msg_internal;
-
-/* Maps upb_fieldtype_t -> memory size. */
-extern char _upb_fieldtype_to_size[12];
-
-UPB_INLINE size_t upb_msg_sizeof(const upb_msglayout *l) {
-  return l->size + sizeof(upb_msg_internal);
-}
-
-UPB_INLINE upb_msg *_upb_msg_new_inl(const upb_msglayout *l, upb_arena *a) {
-  size_t size = upb_msg_sizeof(l);
-  void *mem = upb_arena_malloc(a, size);
-  upb_msg *msg;
-  if (UPB_UNLIKELY(!mem)) return NULL;
-  msg = UPB_PTR_AT(mem, sizeof(upb_msg_internal), upb_msg);
-  memset(mem, 0, size);
-  return msg;
-}
-
-/* Creates a new messages with the given layout on the given arena. */
-upb_msg *_upb_msg_new(const upb_msglayout *l, upb_arena *a);
-
-UPB_INLINE upb_msg_internal *upb_msg_getinternal(upb_msg *msg) {
-  ptrdiff_t size = sizeof(upb_msg_internal);
-  return (upb_msg_internal*)((char*)msg - size);
-}
-
-/* Clears the given message. */
-void _upb_msg_clear(upb_msg *msg, const upb_msglayout *l);
-
-/* Discards the unknown fields for this message only. */
-void _upb_msg_discardunknown_shallow(upb_msg *msg);
+typedef struct upb_msglayout upb_msglayout;
 
 /* Adds unknown data (serialized protobuf data) to the given message.  The data
  * is copied into the message instance. */
-bool _upb_msg_addunknown(upb_msg *msg, const char *data, size_t len,
-                         upb_arena *arena);
+void upb_msg_addunknown(upb_msg *msg, const char *data, size_t len,
+                        upb_arena *arena);
 
 /* Returns a reference to the message's unknown data. */
 const char *upb_msg_getunknown(const upb_msg *msg, size_t *len);
 
-/** Hasbit access *************************************************************/
-
-UPB_INLINE bool _upb_hasbit(const upb_msg *msg, size_t idx) {
-  return (*PTR_AT(msg, idx / 8, const char) & (1 << (idx % 8))) != 0;
-}
-
-UPB_INLINE void _upb_sethas(const upb_msg *msg, size_t idx) {
-  (*PTR_AT(msg, idx / 8, char)) |= (char)(1 << (idx % 8));
-}
-
-UPB_INLINE void _upb_clearhas(const upb_msg *msg, size_t idx) {
-  (*PTR_AT(msg, idx / 8, char)) &= (char)(~(1 << (idx % 8)));
-}
-
-UPB_INLINE size_t _upb_msg_hasidx(const upb_msglayout_field *f) {
-  UPB_ASSERT(f->presence > 0);
-  return f->presence;
-}
-
-UPB_INLINE bool _upb_hasbit_field(const upb_msg *msg,
-                                  const upb_msglayout_field *f) {
-  return _upb_hasbit(msg, _upb_msg_hasidx(f));
-}
-
-UPB_INLINE void _upb_sethas_field(const upb_msg *msg,
-                                  const upb_msglayout_field *f) {
-  _upb_sethas(msg, _upb_msg_hasidx(f));
-}
-
-UPB_INLINE void _upb_clearhas_field(const upb_msg *msg,
-                                    const upb_msglayout_field *f) {
-  _upb_clearhas(msg, _upb_msg_hasidx(f));
-}
-
-/** Oneof case access *********************************************************/
-
-UPB_INLINE uint32_t *_upb_oneofcase(upb_msg *msg, size_t case_ofs) {
-  return PTR_AT(msg, case_ofs, uint32_t);
-}
-
-UPB_INLINE uint32_t _upb_getoneofcase(const void *msg, size_t case_ofs) {
-  return *PTR_AT(msg, case_ofs, uint32_t);
-}
-
-UPB_INLINE size_t _upb_oneofcase_ofs(const upb_msglayout_field *f) {
-  UPB_ASSERT(f->presence < 0);
-  return ~(ptrdiff_t)f->presence;
-}
-
-UPB_INLINE uint32_t *_upb_oneofcase_field(upb_msg *msg,
-                                          const upb_msglayout_field *f) {
-  return _upb_oneofcase(msg, _upb_oneofcase_ofs(f));
-}
-
-UPB_INLINE uint32_t _upb_getoneofcase_field(const upb_msg *msg,
-                                            const upb_msglayout_field *f) {
-  return _upb_getoneofcase(msg, _upb_oneofcase_ofs(f));
-}
-
-UPB_INLINE bool _upb_has_submsg_nohasbit(const upb_msg *msg, size_t ofs) {
-  return *PTR_AT(msg, ofs, const upb_msg*) != NULL;
-}
-
-UPB_INLINE bool _upb_isrepeated(const upb_msglayout_field *field) {
-  return (field->label & 3) == UPB_LABEL_REPEATED;
-}
-
-UPB_INLINE bool _upb_repeated_or_map(const upb_msglayout_field *field) {
-  return field->label >= UPB_LABEL_REPEATED;
-}
-
-/** upb_array *****************************************************************/
-
-/* Our internal representation for repeated fields.  */
-typedef struct {
-  uintptr_t data;   /* Tagged ptr: low 3 bits of ptr are lg2(elem size). */
-  size_t len;   /* Measured in elements. */
-  size_t size;  /* Measured in elements. */
-  uint64_t junk;
-} upb_array;
-
-UPB_INLINE const void *_upb_array_constptr(const upb_array *arr) {
-  UPB_ASSERT((arr->data & 7) <= 4);
-  return (void*)(arr->data & ~(uintptr_t)7);
-}
-
-UPB_INLINE uintptr_t _upb_array_tagptr(void* ptr, int elem_size_lg2) {
-  UPB_ASSERT(elem_size_lg2 <= 4);
-  return (uintptr_t)ptr | elem_size_lg2;
-}
-
-UPB_INLINE void *_upb_array_ptr(upb_array *arr) {
-  return (void*)_upb_array_constptr(arr);
-}
-
-UPB_INLINE uintptr_t _upb_tag_arrptr(void* ptr, int elem_size_lg2) {
-  UPB_ASSERT(elem_size_lg2 <= 4);
-  UPB_ASSERT(((uintptr_t)ptr & 7) == 0);
-  return (uintptr_t)ptr | (unsigned)elem_size_lg2;
-}
-
-UPB_INLINE upb_array *_upb_array_new(upb_arena *a, size_t init_size,
-                                     int elem_size_lg2) {
-  const size_t arr_size = UPB_ALIGN_UP(sizeof(upb_array), 8);
-  const size_t bytes = sizeof(upb_array) + (init_size << elem_size_lg2);
-  upb_array *arr = (upb_array*)upb_arena_malloc(a, bytes);
-  if (!arr) return NULL;
-  arr->data = _upb_tag_arrptr(UPB_PTR_AT(arr, arr_size, void), elem_size_lg2);
-  arr->len = 0;
-  arr->size = init_size;
-  return arr;
-}
+/** upb_extreg *******************************************************************/
 
-/* Resizes the capacity of the array to be at least min_size. */
-bool _upb_array_realloc(upb_array *arr, size_t min_size, upb_arena *arena);
-
-/* Fallback functions for when the accessors require a resize. */
-void *_upb_array_resize_fallback(upb_array **arr_ptr, size_t size,
-                                 int elem_size_lg2, upb_arena *arena);
-bool _upb_array_append_fallback(upb_array **arr_ptr, const void *value,
-                                int elem_size_lg2, upb_arena *arena);
-
-UPB_INLINE bool _upb_array_reserve(upb_array *arr, size_t size,
-                                   upb_arena *arena) {
-  if (arr->size < size) return _upb_array_realloc(arr, size, arena);
-  return true;
-}
-
-UPB_INLINE bool _upb_array_resize(upb_array *arr, size_t size,
-                                  upb_arena *arena) {
-  if (!_upb_array_reserve(arr, size, arena)) return false;
-  arr->len = size;
-  return true;
-}
-
-UPB_INLINE const void *_upb_array_accessor(const void *msg, size_t ofs,
-                                           size_t *size) {
-  const upb_array *arr = *PTR_AT(msg, ofs, const upb_array*);
-  if (arr) {
-    if (size) *size = arr->len;
-    return _upb_array_constptr(arr);
-  } else {
-    if (size) *size = 0;
-    return NULL;
-  }
-}
-
-UPB_INLINE void *_upb_array_mutable_accessor(void *msg, size_t ofs,
-                                             size_t *size) {
-  upb_array *arr = *PTR_AT(msg, ofs, upb_array*);
-  if (arr) {
-    if (size) *size = arr->len;
-    return _upb_array_ptr(arr);
-  } else {
-    if (size) *size = 0;
-    return NULL;
-  }
-}
-
-UPB_INLINE void *_upb_array_resize_accessor2(void *msg, size_t ofs, size_t size,
-                                             int elem_size_lg2,
-                                             upb_arena *arena) {
-  upb_array **arr_ptr = PTR_AT(msg, ofs, upb_array *);
-  upb_array *arr = *arr_ptr;
-  if (!arr || arr->size < size) {
-    return _upb_array_resize_fallback(arr_ptr, size, elem_size_lg2, arena);
-  }
-  arr->len = size;
-  return _upb_array_ptr(arr);
-}
-
-UPB_INLINE bool _upb_array_append_accessor2(void *msg, size_t ofs,
-                                            int elem_size_lg2,
-                                            const void *value,
-                                            upb_arena *arena) {
-  upb_array **arr_ptr = PTR_AT(msg, ofs, upb_array *);
-  size_t elem_size = 1 << elem_size_lg2;
-  upb_array *arr = *arr_ptr;
-  void *ptr;
-  if (!arr || arr->len == arr->size) {
-    return _upb_array_append_fallback(arr_ptr, value, elem_size_lg2, arena);
-  }
-  ptr = _upb_array_ptr(arr);
-  memcpy(PTR_AT(ptr, arr->len * elem_size, char), value, elem_size);
-  arr->len++;
-  return true;
-}
-
-/* Used by old generated code, remove once all code has been regenerated. */
-UPB_INLINE int _upb_sizelg2(upb_fieldtype_t type) {
-  switch (type) {
-    case UPB_TYPE_BOOL:
-      return 0;
-    case UPB_TYPE_FLOAT:
-    case UPB_TYPE_INT32:
-    case UPB_TYPE_UINT32:
-    case UPB_TYPE_ENUM:
-      return 2;
-    case UPB_TYPE_MESSAGE:
-      return UPB_SIZE(2, 3);
-    case UPB_TYPE_DOUBLE:
-    case UPB_TYPE_INT64:
-    case UPB_TYPE_UINT64:
-      return 3;
-    case UPB_TYPE_STRING:
-    case UPB_TYPE_BYTES:
-      return UPB_SIZE(3, 4);
-  }
-  UPB_UNREACHABLE();
-}
-UPB_INLINE void *_upb_array_resize_accessor(void *msg, size_t ofs, size_t size,
-                                             upb_fieldtype_t type,
-                                             upb_arena *arena) {
-  return _upb_array_resize_accessor2(msg, ofs, size, _upb_sizelg2(type), arena);
-}
-UPB_INLINE bool _upb_array_append_accessor(void *msg, size_t ofs,
-                                            size_t elem_size, upb_fieldtype_t type,
-                                            const void *value,
-                                            upb_arena *arena) {
-  (void)elem_size;
-  return _upb_array_append_accessor2(msg, ofs, _upb_sizelg2(type), value,
-                                     arena);
-}
-
-/** upb_map *******************************************************************/
-
-/* Right now we use strmaps for everything.  We'll likely want to use
- * integer-specific maps for integer-keyed maps.*/
-typedef struct {
-  /* Size of key and val, based on the map type.  Strings are represented as '0'
-   * because they must be handled specially. */
-  char key_size;
-  char val_size;
-
-  upb_strtable table;
-} upb_map;
-
-/* Map entries aren't actually stored, they are only used during parsing.  For
- * parsing, it helps a lot if all map entry messages have the same layout.
- * The compiler and def.c must ensure that all map entries have this layout. */
-typedef struct {
-  upb_msg_internal internal;
-  union {
-    upb_strview str;  /* For str/bytes. */
-    upb_value val;    /* For all other types. */
-  } k;
-  union {
-    upb_strview str;  /* For str/bytes. */
-    upb_value val;    /* For all other types. */
-  } v;
-} upb_map_entry;
-
-/* Creates a new map on the given arena with this key/value type. */
-upb_map *_upb_map_new(upb_arena *a, size_t key_size, size_t value_size);
-
-/* Converting between internal table representation and user values.
+/* Extension registry: a dynamic data structure that stores a map of:
+ *   (upb_msglayout, number) -> extension info
+ *
+ * upb_decode() uses upb_extreg to look up extensions while parsing binary
+ * format.
+ *
+ * upb_extreg is part of the mini-table (msglayout) family of objects. Like all
+ * mini-table objects, it is suitable for reflection-less builds that do not
+ * want to expose names into the binary.
  *
- * _upb_map_tokey() and _upb_map_fromkey() are inverses.
- * _upb_map_tovalue() and _upb_map_fromvalue() are inverses.
+ * Unlike most mini-table types, upb_extreg requires dynamic memory allocation
+ * and dynamic initialization:
+ * * If reflection is being used, then upb_symtab will construct an appropriate
+ *   upb_extreg automatically.
+ * * For a mini-table only build, the user must manually construct the
+ *   upb_extreg and populate it with all of the extensions the user cares about.
+ * * A third alternative is to manually unpack relevant extensions after the
+ *   main parse is complete, similar to how Any works. This is perhaps the
+ *   nicest solution from the perspective of reducing dependencies, avoiding
+ *   dynamic memory allocation, and avoiding the need to parse uninteresting
+ *   extensions.  The downsides are:
+ *     (1) parse errors are not caught during the main parse
+ *     (2) the CPU hit of parsing comes during access, which could cause an
+ *         undesirable stutter in application performance.
  *
- * These functions account for the fact that strings are treated differently
- * from other types when stored in a map.
+ * Users cannot directly get or put into this map. Users can only add the
+ * extensions from a generated module and pass the extension registry to the
+ * binary decoder.
+ *
+ * A upb_symtab provides a upb_extreg, so any users who use reflection do not
+ * need to populate a upb_extreg directly.
  */
 
-UPB_INLINE upb_strview _upb_map_tokey(const void *key, size_t size) {
-  if (size == UPB_MAPTYPE_STRING) {
-    return *(upb_strview*)key;
-  } else {
-    return upb_strview_make((const char*)key, size);
-  }
-}
-
-UPB_INLINE void _upb_map_fromkey(upb_strview key, void* out, size_t size) {
-  if (size == UPB_MAPTYPE_STRING) {
-    memcpy(out, &key, sizeof(key));
-  } else {
-    memcpy(out, key.data, size);
-  }
-}
-
-UPB_INLINE bool _upb_map_tovalue(const void *val, size_t size, upb_value *msgval,
-                                 upb_arena *a) {
-  if (size == UPB_MAPTYPE_STRING) {
-    upb_strview *strp = (upb_strview*)upb_arena_malloc(a, sizeof(*strp));
-    if (!strp) return false;
-    *strp = *(upb_strview*)val;
-    *msgval = upb_value_ptr(strp);
-  } else {
-    memcpy(msgval, val, size);
-  }
-  return true;
-}
-
-UPB_INLINE void _upb_map_fromvalue(upb_value val, void* out, size_t size) {
-  if (size == UPB_MAPTYPE_STRING) {
-    const upb_strview *strp = (const upb_strview*)upb_value_getptr(val);
-    memcpy(out, strp, sizeof(upb_strview));
-  } else {
-    memcpy(out, &val, size);
-  }
-}
-
-/* Map operations, shared by reflection and generated code. */
-
-UPB_INLINE size_t _upb_map_size(const upb_map *map) {
-  return map->table.t.count;
-}
-
-UPB_INLINE bool _upb_map_get(const upb_map *map, const void *key,
-                             size_t key_size, void *val, size_t val_size) {
-  upb_value tabval;
-  upb_strview k = _upb_map_tokey(key, key_size);
-  bool ret = upb_strtable_lookup2(&map->table, k.data, k.size, &tabval);
-  if (ret && val) {
-    _upb_map_fromvalue(tabval, val, val_size);
-  }
-  return ret;
-}
-
-UPB_INLINE void* _upb_map_next(const upb_map *map, size_t *iter) {
-  upb_strtable_iter it;
-  it.t = &map->table;
-  it.index = *iter;
-  upb_strtable_next(&it);
-  *iter = it.index;
-  if (upb_strtable_done(&it)) return NULL;
-  return (void*)str_tabent(&it);
-}
-
-UPB_INLINE bool _upb_map_set(upb_map *map, const void *key, size_t key_size,
-                             void *val, size_t val_size, upb_arena *arena) {
-  upb_strview strkey = _upb_map_tokey(key, key_size);
-  upb_value tabval = {0};
-  if (!_upb_map_tovalue(val, val_size, &tabval, arena)) return false;
-  upb_alloc *a = upb_arena_alloc(arena);
+struct upb_extreg;
+typedef struct upb_extreg upb_extreg;
 
-  /* TODO(haberman): add overwrite operation to minimize number of lookups. */
-  upb_strtable_remove3(&map->table, strkey.data, strkey.size, NULL, a);
-  return upb_strtable_insert3(&map->table, strkey.data, strkey.size, tabval, a);
-}
-
-UPB_INLINE bool _upb_map_delete(upb_map *map, const void *key, size_t key_size) {
-  upb_strview k = _upb_map_tokey(key, key_size);
-  return upb_strtable_remove3(&map->table, k.data, k.size, NULL, NULL);
-}
-
-UPB_INLINE void _upb_map_clear(upb_map *map) {
-  upb_strtable_clear(&map->table);
-}
-
-/* Message map operations, these get the map from the message first. */
-
-UPB_INLINE size_t _upb_msg_map_size(const upb_msg *msg, size_t ofs) {
-  upb_map *map = *UPB_PTR_AT(msg, ofs, upb_map *);
-  return map ? _upb_map_size(map) : 0;
-}
-
-UPB_INLINE bool _upb_msg_map_get(const upb_msg *msg, size_t ofs,
-                                 const void *key, size_t key_size, void *val,
-                                 size_t val_size) {
-  upb_map *map = *UPB_PTR_AT(msg, ofs, upb_map *);
-  if (!map) return false;
-  return _upb_map_get(map, key, key_size, val, val_size);
-}
-
-UPB_INLINE void *_upb_msg_map_next(const upb_msg *msg, size_t ofs,
-                                   size_t *iter) {
-  upb_map *map = *UPB_PTR_AT(msg, ofs, upb_map *);
-  if (!map) return NULL;
-  return _upb_map_next(map, iter);
-}
-
-UPB_INLINE bool _upb_msg_map_set(upb_msg *msg, size_t ofs, const void *key,
-                                 size_t key_size, void *val, size_t val_size,
-                                 upb_arena *arena) {
-  upb_map **map = PTR_AT(msg, ofs, upb_map *);
-  if (!*map) {
-    *map = _upb_map_new(arena, key_size, val_size);
-  }
-  return _upb_map_set(*map, key, key_size, val, val_size, arena);
-}
-
-UPB_INLINE bool _upb_msg_map_delete(upb_msg *msg, size_t ofs, const void *key,
-                                    size_t key_size) {
-  upb_map *map = *UPB_PTR_AT(msg, ofs, upb_map *);
-  if (!map) return false;
-  return _upb_map_delete(map, key, key_size);
-}
-
-UPB_INLINE void _upb_msg_map_clear(upb_msg *msg, size_t ofs) {
-  upb_map *map = *UPB_PTR_AT(msg, ofs, upb_map *);
-  if (!map) return;
-  _upb_map_clear(map);
-}
-
-/* Accessing map key/value from a pointer, used by generated code only. */
-
-UPB_INLINE void _upb_msg_map_key(const void* msg, void* key, size_t size) {
-  const upb_tabent *ent = (const upb_tabent*)msg;
-  uint32_t u32len;
-  upb_strview k;
-  k.data = upb_tabstr(ent->key, &u32len);
-  k.size = u32len;
-  _upb_map_fromkey(k, key, size);
-}
-
-UPB_INLINE void _upb_msg_map_value(const void* msg, void* val, size_t size) {
-  const upb_tabent *ent = (const upb_tabent*)msg;
-  upb_value v;
-  _upb_value_setval(&v, ent->val.val);
-  _upb_map_fromvalue(v, val, size);
-}
-
-UPB_INLINE void _upb_msg_map_set_value(void* msg, const void* val, size_t size) {
-  upb_tabent *ent = (upb_tabent*)msg;
-  /* This is like _upb_map_tovalue() except the entry already exists so we can
-   * reuse the allocated upb_strview for string fields. */
-  if (size == UPB_MAPTYPE_STRING) {
-    upb_strview *strp = (upb_strview*)(uintptr_t)ent->val.val;
-    memcpy(strp, val, sizeof(*strp));
-  } else {
-    memcpy(&ent->val.val, val, size);
-  }
-}
-
-/** _upb_mapsorter *************************************************************/
-
-/* _upb_mapsorter sorts maps and provides ordered iteration over the entries.
- * Since maps can be recursive (map values can be messages which contain other maps).
- * _upb_mapsorter can contain a stack of maps. */
-
-typedef struct {
-  upb_tabent const**entries;
-  int size;
-  int cap;
-} _upb_mapsorter;
-
-typedef struct {
-  int start;
-  int pos;
-  int end;
-} _upb_sortedmap;
-
-UPB_INLINE void _upb_mapsorter_init(_upb_mapsorter *s) {
-  s->entries = NULL;
-  s->size = 0;
-  s->cap = 0;
-}
-
-UPB_INLINE void _upb_mapsorter_destroy(_upb_mapsorter *s) {
-  if (s->entries) free(s->entries);
-}
-
-bool _upb_mapsorter_pushmap(_upb_mapsorter *s, upb_descriptortype_t key_type,
-                            const upb_map *map, _upb_sortedmap *sorted);
-
-UPB_INLINE void _upb_mapsorter_popmap(_upb_mapsorter *s, _upb_sortedmap *sorted) {
-  s->size = sorted->start;
-}
-
-UPB_INLINE bool _upb_sortedmap_next(_upb_mapsorter *s, const upb_map *map,
-                                    _upb_sortedmap *sorted,
-                                    upb_map_entry *ent) {
-  if (sorted->pos == sorted->end) return false;
-  const upb_tabent *tabent = s->entries[sorted->pos++];
-  upb_strview key = upb_tabstrview(tabent->key);
-  _upb_map_fromkey(key, &ent->k, map->key_size);
-  upb_value val = {tabent->val.val};
-  _upb_map_fromvalue(val, &ent->v, map->val_size);
-  return true;
-}
-
-#undef PTR_AT
+/* Creates a upb_extreg in the given arena.  The arena must outlive any use of
+ * the extreg. */
+upb_extreg *upb_extreg_new(upb_arena *arena);
 
 #ifdef __cplusplus
 }  /* extern "C" */
 #endif
 
-#include "upb/port_undef.inc"
-
-#endif /* UPB_MSG_H_ */
+#endif /* UPB_MSG_INT_H_ */
diff --git a/third_party/upb/upb/msg_internal.h b/third_party/upb/upb/msg_internal.h
new file mode 100644 (file)
index 0000000..2451700
--- /dev/null
@@ -0,0 +1,687 @@
+/*
+** Our memory representation for parsing tables and messages themselves.
+** Functions in this file are used by generated code and possibly reflection.
+**
+** The definitions in this file are internal to upb.
+**/
+
+#ifndef UPB_MSG_INT_H_
+#define UPB_MSG_INT_H_
+
+#include <stdint.h>
+#include <stdlib.h>
+#include <string.h>
+
+#include "upb/msg.h"
+#include "upb/table_internal.h"
+#include "upb/upb.h"
+
+/* Must be last. */
+#include "upb/port_def.inc"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+/** upb_msglayout *************************************************************/
+
+/* upb_msglayout represents the memory layout of a given upb_msgdef.  The
+ * members are public so generated code can initialize them, but users MUST NOT
+ * read or write any of its members. */
+
+/* These aren't real labels according to descriptor.proto, but in the table we
+ * use these for map/packed fields instead of UPB_LABEL_REPEATED. */
+enum {
+  _UPB_LABEL_MAP = 4,
+  _UPB_LABEL_PACKED = 7  /* Low 3 bits are common with UPB_LABEL_REPEATED. */
+};
+
+typedef struct {
+  uint32_t number;
+  uint16_t offset;
+  int16_t presence;       /* If >0, hasbit_index.  If <0, ~oneof_index. */
+  uint16_t submsg_index;  /* undefined if descriptortype != MESSAGE or GROUP. */
+  uint8_t descriptortype;
+  int8_t mode;            /* upb_fieldmode, with flags from upb_labelflags */
+} upb_msglayout_field;
+
+typedef enum {
+  _UPB_MODE_MAP = 0,
+  _UPB_MODE_ARRAY = 1,
+  _UPB_MODE_SCALAR = 2,
+} upb_fieldmode;
+
+/* Extra flags on the mode field. */
+enum upb_labelflags {
+  _UPB_MODE_IS_PACKED = 4,
+};
+
+UPB_INLINE upb_fieldmode _upb_getmode(const upb_msglayout_field *field) {
+  return (upb_fieldmode)(field->mode & 3);
+}
+
+UPB_INLINE bool _upb_repeated_or_map(const upb_msglayout_field *field) {
+  /* This works because upb_fieldmode has no value 3. */
+  return !(field->mode & _UPB_MODE_SCALAR);
+}
+
+UPB_INLINE bool _upb_issubmsg(const upb_msglayout_field *field) {
+  return field->descriptortype == UPB_DTYPE_MESSAGE ||
+         field->descriptortype == UPB_DTYPE_GROUP;
+}
+
+struct upb_decstate;
+struct upb_msglayout;
+
+typedef const char *_upb_field_parser(struct upb_decstate *d, const char *ptr,
+                                      upb_msg *msg, intptr_t table,
+                                      uint64_t hasbits, uint64_t data);
+
+typedef struct {
+  uint64_t field_data;
+  _upb_field_parser *field_parser;
+} _upb_fasttable_entry;
+
+struct upb_msglayout {
+  const struct upb_msglayout *const* submsgs;
+  const upb_msglayout_field *fields;
+  /* Must be aligned to sizeof(void*).  Doesn't include internal members like
+   * unknown fields, extension dict, pointer to msglayout, etc. */
+  uint16_t size;
+  uint16_t field_count;
+  bool extendable;
+  uint8_t dense_below;
+  uint8_t table_mask;
+  /* To constant-initialize the tables of variable length, we need a flexible
+   * array member, and we need to compile in C99 mode. */
+  _upb_fasttable_entry fasttable[];
+};
+
+typedef struct {
+  upb_msglayout_field field;
+  const upb_msglayout *extendee;
+  const upb_msglayout *submsg;   /* NULL for non-submessage fields. */
+} upb_msglayout_ext;
+
+/** upb_extreg ****************************************************************/
+
+/* Adds the given extension info for message type |l| and field number |num|
+ * into the registry. Returns false if this message type and field number were
+ * already in the map, or if memory allocation fails. */
+bool _upb_extreg_add(upb_extreg *r, const upb_msglayout_ext *e, size_t count);
+
+/* Looks up the extension (if any) defined for message type |l| and field
+ * number |num|.  If an extension was found, copies the field info into |*ext|
+ * and returns true. Otherwise returns false. */
+const upb_msglayout_field *_upb_extreg_get(const upb_extreg *r,
+                                           const upb_msglayout *l,
+                                           uint32_t num);
+
+/** upb_msg *******************************************************************/
+
+/* Internal members of a upb_msg that track unknown fields and/or extensions.
+ * We can change this without breaking binary compatibility.  We put these
+ * before the user's data.  The user's upb_msg* points after the
+ * upb_msg_internal. */
+
+typedef struct {
+  /* Total size of this structure, including the data that follows.
+   * Must be aligned to 8, which is alignof(upb_msg_ext) */
+  uint32_t size;
+
+  /* Offsets relative to the beginning of this structure.
+   *
+   * Unknown data grows forward from the beginning to unknown_end.
+   * Extension data grows backward from size to ext_begin.
+   * When the two meet, we're out of data and have to realloc.
+   *
+   * If we imagine that the final member of this struct is:
+   *   char data[size - overhead];  // overhead = sizeof(upb_msg_internaldata)
+   * 
+   * Then we have:
+   *   unknown data: data[0 .. (unknown_end - overhead)]
+   *   extensions data: data[(ext_begin - overhead) .. (size - overhead)] */
+  uint32_t unknown_end;
+  uint32_t ext_begin;
+  /* Data follows, as if there were an array:
+   *   char data[size - sizeof(upb_msg_internaldata)]; */
+} upb_msg_internaldata;
+
+typedef struct {
+  upb_msg_internaldata *internal;
+} upb_msg_internal;
+
+/* Maps upb_fieldtype_t -> memory size. */
+extern char _upb_fieldtype_to_size[12];
+
+UPB_INLINE size_t upb_msg_sizeof(const upb_msglayout *l) {
+  return l->size + sizeof(upb_msg_internal);
+}
+
+UPB_INLINE upb_msg *_upb_msg_new_inl(const upb_msglayout *l, upb_arena *a) {
+  size_t size = upb_msg_sizeof(l);
+  void *mem = upb_arena_malloc(a, size);
+  upb_msg *msg;
+  if (UPB_UNLIKELY(!mem)) return NULL;
+  msg = UPB_PTR_AT(mem, sizeof(upb_msg_internal), upb_msg);
+  memset(mem, 0, size);
+  return msg;
+}
+
+/* Creates a new messages with the given layout on the given arena. */
+upb_msg *_upb_msg_new(const upb_msglayout *l, upb_arena *a);
+
+UPB_INLINE upb_msg_internal *upb_msg_getinternal(upb_msg *msg) {
+  ptrdiff_t size = sizeof(upb_msg_internal);
+  return (upb_msg_internal*)((char*)msg - size);
+}
+
+/* Clears the given message. */
+void _upb_msg_clear(upb_msg *msg, const upb_msglayout *l);
+
+/* Discards the unknown fields for this message only. */
+void _upb_msg_discardunknown_shallow(upb_msg *msg);
+
+/* Adds unknown data (serialized protobuf data) to the given message.  The data
+ * is copied into the message instance. */
+bool _upb_msg_addunknown(upb_msg *msg, const char *data, size_t len,
+                         upb_arena *arena);
+
+/** upb_msg_ext ***************************************************************/
+
+/* The internal representation of an extension is self-describing: it contains
+ * enough information that we can serialize it to binary format without needing
+ * to look it up in a registry. */
+typedef struct {
+  const upb_msglayout_ext *ext;
+  union {
+    upb_strview str;
+    void *ptr;
+    double dbl;
+    char scalar_data[8];
+  } data;
+} upb_msg_ext;
+
+/* Adds the given extension data to the given message. The returned extension will
+ * have its "ext" member initialized according to |ext|. */
+upb_msg_ext *_upb_msg_getorcreateext(upb_msg *msg, const upb_msglayout_ext *ext,
+                                     upb_arena *arena);
+
+/* Returns an array of extensions for this message. Note: the array is
+ * ordered in reverse relative to the order of creation. */
+const upb_msg_ext *_upb_msg_getexts(const upb_msg *msg, size_t *count);
+
+/* Returns an extension for the given field number, or NULL if no extension
+ * exists for this field number. */
+const upb_msg_ext *_upb_msg_getext(const upb_msg *msg,
+                                   const upb_msglayout_ext *ext);
+
+/** Hasbit access *************************************************************/
+
+UPB_INLINE bool _upb_hasbit(const upb_msg *msg, size_t idx) {
+  return (*UPB_PTR_AT(msg, idx / 8, const char) & (1 << (idx % 8))) != 0;
+}
+
+UPB_INLINE void _upb_sethas(const upb_msg *msg, size_t idx) {
+  (*UPB_PTR_AT(msg, idx / 8, char)) |= (char)(1 << (idx % 8));
+}
+
+UPB_INLINE void _upb_clearhas(const upb_msg *msg, size_t idx) {
+  (*UPB_PTR_AT(msg, idx / 8, char)) &= (char)(~(1 << (idx % 8)));
+}
+
+UPB_INLINE size_t _upb_msg_hasidx(const upb_msglayout_field *f) {
+  UPB_ASSERT(f->presence > 0);
+  return f->presence;
+}
+
+UPB_INLINE bool _upb_hasbit_field(const upb_msg *msg,
+                                  const upb_msglayout_field *f) {
+  return _upb_hasbit(msg, _upb_msg_hasidx(f));
+}
+
+UPB_INLINE void _upb_sethas_field(const upb_msg *msg,
+                                  const upb_msglayout_field *f) {
+  _upb_sethas(msg, _upb_msg_hasidx(f));
+}
+
+UPB_INLINE void _upb_clearhas_field(const upb_msg *msg,
+                                    const upb_msglayout_field *f) {
+  _upb_clearhas(msg, _upb_msg_hasidx(f));
+}
+
+/** Oneof case access *********************************************************/
+
+UPB_INLINE uint32_t *_upb_oneofcase(upb_msg *msg, size_t case_ofs) {
+  return UPB_PTR_AT(msg, case_ofs, uint32_t);
+}
+
+UPB_INLINE uint32_t _upb_getoneofcase(const void *msg, size_t case_ofs) {
+  return *UPB_PTR_AT(msg, case_ofs, uint32_t);
+}
+
+UPB_INLINE size_t _upb_oneofcase_ofs(const upb_msglayout_field *f) {
+  UPB_ASSERT(f->presence < 0);
+  return ~(ptrdiff_t)f->presence;
+}
+
+UPB_INLINE uint32_t *_upb_oneofcase_field(upb_msg *msg,
+                                          const upb_msglayout_field *f) {
+  return _upb_oneofcase(msg, _upb_oneofcase_ofs(f));
+}
+
+UPB_INLINE uint32_t _upb_getoneofcase_field(const upb_msg *msg,
+                                            const upb_msglayout_field *f) {
+  return _upb_getoneofcase(msg, _upb_oneofcase_ofs(f));
+}
+
+UPB_INLINE bool _upb_has_submsg_nohasbit(const upb_msg *msg, size_t ofs) {
+  return *UPB_PTR_AT(msg, ofs, const upb_msg*) != NULL;
+}
+
+/** upb_array *****************************************************************/
+
+/* Our internal representation for repeated fields.  */
+typedef struct {
+  uintptr_t data;   /* Tagged ptr: low 3 bits of ptr are lg2(elem size). */
+  size_t len;   /* Measured in elements. */
+  size_t size;  /* Measured in elements. */
+  uint64_t junk;
+} upb_array;
+
+UPB_INLINE const void *_upb_array_constptr(const upb_array *arr) {
+  UPB_ASSERT((arr->data & 7) <= 4);
+  return (void*)(arr->data & ~(uintptr_t)7);
+}
+
+UPB_INLINE uintptr_t _upb_array_tagptr(void* ptr, int elem_size_lg2) {
+  UPB_ASSERT(elem_size_lg2 <= 4);
+  return (uintptr_t)ptr | elem_size_lg2;
+}
+
+UPB_INLINE void *_upb_array_ptr(upb_array *arr) {
+  return (void*)_upb_array_constptr(arr);
+}
+
+UPB_INLINE uintptr_t _upb_tag_arrptr(void* ptr, int elem_size_lg2) {
+  UPB_ASSERT(elem_size_lg2 <= 4);
+  UPB_ASSERT(((uintptr_t)ptr & 7) == 0);
+  return (uintptr_t)ptr | (unsigned)elem_size_lg2;
+}
+
+UPB_INLINE upb_array *_upb_array_new(upb_arena *a, size_t init_size,
+                                     int elem_size_lg2) {
+  const size_t arr_size = UPB_ALIGN_UP(sizeof(upb_array), 8);
+  const size_t bytes = sizeof(upb_array) + (init_size << elem_size_lg2);
+  upb_array *arr = (upb_array*)upb_arena_malloc(a, bytes);
+  if (!arr) return NULL;
+  arr->data = _upb_tag_arrptr(UPB_PTR_AT(arr, arr_size, void), elem_size_lg2);
+  arr->len = 0;
+  arr->size = init_size;
+  return arr;
+}
+
+/* Resizes the capacity of the array to be at least min_size. */
+bool _upb_array_realloc(upb_array *arr, size_t min_size, upb_arena *arena);
+
+/* Fallback functions for when the accessors require a resize. */
+void *_upb_array_resize_fallback(upb_array **arr_ptr, size_t size,
+                                 int elem_size_lg2, upb_arena *arena);
+bool _upb_array_append_fallback(upb_array **arr_ptr, const void *value,
+                                int elem_size_lg2, upb_arena *arena);
+
+UPB_INLINE bool _upb_array_reserve(upb_array *arr, size_t size,
+                                   upb_arena *arena) {
+  if (arr->size < size) return _upb_array_realloc(arr, size, arena);
+  return true;
+}
+
+UPB_INLINE bool _upb_array_resize(upb_array *arr, size_t size,
+                                  upb_arena *arena) {
+  if (!_upb_array_reserve(arr, size, arena)) return false;
+  arr->len = size;
+  return true;
+}
+
+UPB_INLINE const void *_upb_array_accessor(const void *msg, size_t ofs,
+                                           size_t *size) {
+  const upb_array *arr = *UPB_PTR_AT(msg, ofs, const upb_array*);
+  if (arr) {
+    if (size) *size = arr->len;
+    return _upb_array_constptr(arr);
+  } else {
+    if (size) *size = 0;
+    return NULL;
+  }
+}
+
+UPB_INLINE void *_upb_array_mutable_accessor(void *msg, size_t ofs,
+                                             size_t *size) {
+  upb_array *arr = *UPB_PTR_AT(msg, ofs, upb_array*);
+  if (arr) {
+    if (size) *size = arr->len;
+    return _upb_array_ptr(arr);
+  } else {
+    if (size) *size = 0;
+    return NULL;
+  }
+}
+
+UPB_INLINE void *_upb_array_resize_accessor2(void *msg, size_t ofs, size_t size,
+                                             int elem_size_lg2,
+                                             upb_arena *arena) {
+  upb_array **arr_ptr = UPB_PTR_AT(msg, ofs, upb_array *);
+  upb_array *arr = *arr_ptr;
+  if (!arr || arr->size < size) {
+    return _upb_array_resize_fallback(arr_ptr, size, elem_size_lg2, arena);
+  }
+  arr->len = size;
+  return _upb_array_ptr(arr);
+}
+
+UPB_INLINE bool _upb_array_append_accessor2(void *msg, size_t ofs,
+                                            int elem_size_lg2,
+                                            const void *value,
+                                            upb_arena *arena) {
+  upb_array **arr_ptr = UPB_PTR_AT(msg, ofs, upb_array *);
+  size_t elem_size = 1 << elem_size_lg2;
+  upb_array *arr = *arr_ptr;
+  void *ptr;
+  if (!arr || arr->len == arr->size) {
+    return _upb_array_append_fallback(arr_ptr, value, elem_size_lg2, arena);
+  }
+  ptr = _upb_array_ptr(arr);
+  memcpy(UPB_PTR_AT(ptr, arr->len * elem_size, char), value, elem_size);
+  arr->len++;
+  return true;
+}
+
+/* Used by old generated code, remove once all code has been regenerated. */
+UPB_INLINE int _upb_sizelg2(upb_fieldtype_t type) {
+  switch (type) {
+    case UPB_TYPE_BOOL:
+      return 0;
+    case UPB_TYPE_FLOAT:
+    case UPB_TYPE_INT32:
+    case UPB_TYPE_UINT32:
+    case UPB_TYPE_ENUM:
+      return 2;
+    case UPB_TYPE_MESSAGE:
+      return UPB_SIZE(2, 3);
+    case UPB_TYPE_DOUBLE:
+    case UPB_TYPE_INT64:
+    case UPB_TYPE_UINT64:
+      return 3;
+    case UPB_TYPE_STRING:
+    case UPB_TYPE_BYTES:
+      return UPB_SIZE(3, 4);
+  }
+  UPB_UNREACHABLE();
+}
+UPB_INLINE void *_upb_array_resize_accessor(void *msg, size_t ofs, size_t size,
+                                             upb_fieldtype_t type,
+                                             upb_arena *arena) {
+  return _upb_array_resize_accessor2(msg, ofs, size, _upb_sizelg2(type), arena);
+}
+UPB_INLINE bool _upb_array_append_accessor(void *msg, size_t ofs,
+                                            size_t elem_size, upb_fieldtype_t type,
+                                            const void *value,
+                                            upb_arena *arena) {
+  (void)elem_size;
+  return _upb_array_append_accessor2(msg, ofs, _upb_sizelg2(type), value,
+                                     arena);
+}
+
+/** upb_map *******************************************************************/
+
+/* Right now we use strmaps for everything.  We'll likely want to use
+ * integer-specific maps for integer-keyed maps.*/
+typedef struct {
+  /* Size of key and val, based on the map type.  Strings are represented as '0'
+   * because they must be handled specially. */
+  char key_size;
+  char val_size;
+
+  upb_strtable table;
+} upb_map;
+
+/* Map entries aren't actually stored, they are only used during parsing.  For
+ * parsing, it helps a lot if all map entry messages have the same layout.
+ * The compiler and def.c must ensure that all map entries have this layout. */
+typedef struct {
+  upb_msg_internal internal;
+  union {
+    upb_strview str;  /* For str/bytes. */
+    upb_value val;    /* For all other types. */
+  } k;
+  union {
+    upb_strview str;  /* For str/bytes. */
+    upb_value val;    /* For all other types. */
+  } v;
+} upb_map_entry;
+
+/* Creates a new map on the given arena with this key/value type. */
+upb_map *_upb_map_new(upb_arena *a, size_t key_size, size_t value_size);
+
+/* Converting between internal table representation and user values.
+ *
+ * _upb_map_tokey() and _upb_map_fromkey() are inverses.
+ * _upb_map_tovalue() and _upb_map_fromvalue() are inverses.
+ *
+ * These functions account for the fact that strings are treated differently
+ * from other types when stored in a map.
+ */
+
+UPB_INLINE upb_strview _upb_map_tokey(const void *key, size_t size) {
+  if (size == UPB_MAPTYPE_STRING) {
+    return *(upb_strview*)key;
+  } else {
+    return upb_strview_make((const char*)key, size);
+  }
+}
+
+UPB_INLINE void _upb_map_fromkey(upb_strview key, void* out, size_t size) {
+  if (size == UPB_MAPTYPE_STRING) {
+    memcpy(out, &key, sizeof(key));
+  } else {
+    memcpy(out, key.data, size);
+  }
+}
+
+UPB_INLINE bool _upb_map_tovalue(const void *val, size_t size, upb_value *msgval,
+                                 upb_arena *a) {
+  if (size == UPB_MAPTYPE_STRING) {
+    upb_strview *strp = (upb_strview*)upb_arena_malloc(a, sizeof(*strp));
+    if (!strp) return false;
+    *strp = *(upb_strview*)val;
+    *msgval = upb_value_ptr(strp);
+  } else {
+    memcpy(msgval, val, size);
+  }
+  return true;
+}
+
+UPB_INLINE void _upb_map_fromvalue(upb_value val, void* out, size_t size) {
+  if (size == UPB_MAPTYPE_STRING) {
+    const upb_strview *strp = (const upb_strview*)upb_value_getptr(val);
+    memcpy(out, strp, sizeof(upb_strview));
+  } else {
+    memcpy(out, &val, size);
+  }
+}
+
+/* Map operations, shared by reflection and generated code. */
+
+UPB_INLINE size_t _upb_map_size(const upb_map *map) {
+  return map->table.t.count;
+}
+
+UPB_INLINE bool _upb_map_get(const upb_map *map, const void *key,
+                             size_t key_size, void *val, size_t val_size) {
+  upb_value tabval;
+  upb_strview k = _upb_map_tokey(key, key_size);
+  bool ret = upb_strtable_lookup2(&map->table, k.data, k.size, &tabval);
+  if (ret && val) {
+    _upb_map_fromvalue(tabval, val, val_size);
+  }
+  return ret;
+}
+
+UPB_INLINE void* _upb_map_next(const upb_map *map, size_t *iter) {
+  upb_strtable_iter it;
+  it.t = &map->table;
+  it.index = *iter;
+  upb_strtable_next(&it);
+  *iter = it.index;
+  if (upb_strtable_done(&it)) return NULL;
+  return (void*)str_tabent(&it);
+}
+
+UPB_INLINE bool _upb_map_set(upb_map *map, const void *key, size_t key_size,
+                             void *val, size_t val_size, upb_arena *a) {
+  upb_strview strkey = _upb_map_tokey(key, key_size);
+  upb_value tabval = {0};
+  if (!_upb_map_tovalue(val, val_size, &tabval, a)) return false;
+
+  /* TODO(haberman): add overwrite operation to minimize number of lookups. */
+  upb_strtable_remove(&map->table, strkey.data, strkey.size, NULL);
+  return upb_strtable_insert(&map->table, strkey.data, strkey.size, tabval, a);
+}
+
+UPB_INLINE bool _upb_map_delete(upb_map *map, const void *key, size_t key_size) {
+  upb_strview k = _upb_map_tokey(key, key_size);
+  return upb_strtable_remove(&map->table, k.data, k.size, NULL);
+}
+
+UPB_INLINE void _upb_map_clear(upb_map *map) {
+  upb_strtable_clear(&map->table);
+}
+
+/* Message map operations, these get the map from the message first. */
+
+UPB_INLINE size_t _upb_msg_map_size(const upb_msg *msg, size_t ofs) {
+  upb_map *map = *UPB_PTR_AT(msg, ofs, upb_map *);
+  return map ? _upb_map_size(map) : 0;
+}
+
+UPB_INLINE bool _upb_msg_map_get(const upb_msg *msg, size_t ofs,
+                                 const void *key, size_t key_size, void *val,
+                                 size_t val_size) {
+  upb_map *map = *UPB_PTR_AT(msg, ofs, upb_map *);
+  if (!map) return false;
+  return _upb_map_get(map, key, key_size, val, val_size);
+}
+
+UPB_INLINE void *_upb_msg_map_next(const upb_msg *msg, size_t ofs,
+                                   size_t *iter) {
+  upb_map *map = *UPB_PTR_AT(msg, ofs, upb_map *);
+  if (!map) return NULL;
+  return _upb_map_next(map, iter);
+}
+
+UPB_INLINE bool _upb_msg_map_set(upb_msg *msg, size_t ofs, const void *key,
+                                 size_t key_size, void *val, size_t val_size,
+                                 upb_arena *arena) {
+  upb_map **map = UPB_PTR_AT(msg, ofs, upb_map *);
+  if (!*map) {
+    *map = _upb_map_new(arena, key_size, val_size);
+  }
+  return _upb_map_set(*map, key, key_size, val, val_size, arena);
+}
+
+UPB_INLINE bool _upb_msg_map_delete(upb_msg *msg, size_t ofs, const void *key,
+                                    size_t key_size) {
+  upb_map *map = *UPB_PTR_AT(msg, ofs, upb_map *);
+  if (!map) return false;
+  return _upb_map_delete(map, key, key_size);
+}
+
+UPB_INLINE void _upb_msg_map_clear(upb_msg *msg, size_t ofs) {
+  upb_map *map = *UPB_PTR_AT(msg, ofs, upb_map *);
+  if (!map) return;
+  _upb_map_clear(map);
+}
+
+/* Accessing map key/value from a pointer, used by generated code only. */
+
+UPB_INLINE void _upb_msg_map_key(const void* msg, void* key, size_t size) {
+  const upb_tabent *ent = (const upb_tabent*)msg;
+  uint32_t u32len;
+  upb_strview k;
+  k.data = upb_tabstr(ent->key, &u32len);
+  k.size = u32len;
+  _upb_map_fromkey(k, key, size);
+}
+
+UPB_INLINE void _upb_msg_map_value(const void* msg, void* val, size_t size) {
+  const upb_tabent *ent = (const upb_tabent*)msg;
+  upb_value v = {ent->val.val};
+  _upb_map_fromvalue(v, val, size);
+}
+
+UPB_INLINE void _upb_msg_map_set_value(void* msg, const void* val, size_t size) {
+  upb_tabent *ent = (upb_tabent*)msg;
+  /* This is like _upb_map_tovalue() except the entry already exists so we can
+   * reuse the allocated upb_strview for string fields. */
+  if (size == UPB_MAPTYPE_STRING) {
+    upb_strview *strp = (upb_strview*)(uintptr_t)ent->val.val;
+    memcpy(strp, val, sizeof(*strp));
+  } else {
+    memcpy(&ent->val.val, val, size);
+  }
+}
+
+/** _upb_mapsorter *************************************************************/
+
+/* _upb_mapsorter sorts maps and provides ordered iteration over the entries.
+ * Since maps can be recursive (map values can be messages which contain other maps).
+ * _upb_mapsorter can contain a stack of maps. */
+
+typedef struct {
+  upb_tabent const**entries;
+  int size;
+  int cap;
+} _upb_mapsorter;
+
+typedef struct {
+  int start;
+  int pos;
+  int end;
+} _upb_sortedmap;
+
+UPB_INLINE void _upb_mapsorter_init(_upb_mapsorter *s) {
+  s->entries = NULL;
+  s->size = 0;
+  s->cap = 0;
+}
+
+UPB_INLINE void _upb_mapsorter_destroy(_upb_mapsorter *s) {
+  if (s->entries) free(s->entries);
+}
+
+bool _upb_mapsorter_pushmap(_upb_mapsorter *s, upb_descriptortype_t key_type,
+                            const upb_map *map, _upb_sortedmap *sorted);
+
+UPB_INLINE void _upb_mapsorter_popmap(_upb_mapsorter *s, _upb_sortedmap *sorted) {
+  s->size = sorted->start;
+}
+
+UPB_INLINE bool _upb_sortedmap_next(_upb_mapsorter *s, const upb_map *map,
+                                    _upb_sortedmap *sorted,
+                                    upb_map_entry *ent) {
+  if (sorted->pos == sorted->end) return false;
+  const upb_tabent *tabent = s->entries[sorted->pos++];
+  upb_strview key = upb_tabstrview(tabent->key);
+  _upb_map_fromkey(key, &ent->k, map->key_size);
+  upb_value val = {tabent->val.val};
+  _upb_map_fromvalue(val, &ent->v, map->val_size);
+  return true;
+}
+
+#ifdef __cplusplus
+}  /* extern "C" */
+#endif
+
+#include "upb/port_undef.inc"
+
+#endif /* UPB_MSG_INT_H_ */
diff --git a/third_party/upb/upb/pb/compile_decoder.c b/third_party/upb/upb/pb/compile_decoder.c
deleted file mode 100644 (file)
index 3c73f1a..0000000
+++ /dev/null
@@ -1,919 +0,0 @@
-/*
-** protobuf decoder bytecode compiler
-**
-** Code to compile a upb::Handlers into bytecode for decoding a protobuf
-** according to that specific schema and destination handlers.
-**
-** Bytecode definition is in decoder.int.h.
-*/
-
-#include <stdarg.h>
-#include "upb/pb/decoder.int.h"
-#include "upb/pb/varint.int.h"
-
-#ifdef UPB_DUMP_BYTECODE
-#include <stdio.h>
-#endif
-
-#include "upb/port_def.inc"
-
-#define MAXLABEL 5
-#define EMPTYLABEL -1
-
-/* upb_pbdecodermethod ********************************************************/
-
-static void freemethod(upb_pbdecodermethod *method) {
-  upb_inttable_uninit(&method->dispatch);
-  upb_gfree(method);
-}
-
-static upb_pbdecodermethod *newmethod(const upb_handlers *dest_handlers,
-                                      mgroup *group) {
-  upb_pbdecodermethod *ret = upb_gmalloc(sizeof(*ret));
-  upb_byteshandler_init(&ret->input_handler_);
-
-  ret->group = group;
-  ret->dest_handlers_ = dest_handlers;
-  upb_inttable_init(&ret->dispatch, UPB_CTYPE_UINT64);
-
-  return ret;
-}
-
-const upb_handlers *upb_pbdecodermethod_desthandlers(
-    const upb_pbdecodermethod *m) {
-  return m->dest_handlers_;
-}
-
-const upb_byteshandler *upb_pbdecodermethod_inputhandler(
-    const upb_pbdecodermethod *m) {
-  return &m->input_handler_;
-}
-
-bool upb_pbdecodermethod_isnative(const upb_pbdecodermethod *m) {
-  return m->is_native_;
-}
-
-
-/* mgroup *********************************************************************/
-
-static void freegroup(mgroup *g) {
-  upb_inttable_iter i;
-
-  upb_inttable_begin(&i, &g->methods);
-  for(; !upb_inttable_done(&i); upb_inttable_next(&i)) {
-    freemethod(upb_value_getptr(upb_inttable_iter_value(&i)));
-  }
-
-  upb_inttable_uninit(&g->methods);
-  upb_gfree(g->bytecode);
-  upb_gfree(g);
-}
-
-mgroup *newgroup(void) {
-  mgroup *g = upb_gmalloc(sizeof(*g));
-  upb_inttable_init(&g->methods, UPB_CTYPE_PTR);
-  g->bytecode = NULL;
-  g->bytecode_end = NULL;
-  return g;
-}
-
-
-/* bytecode compiler **********************************************************/
-
-/* Data used only at compilation time. */
-typedef struct {
-  mgroup *group;
-
-  uint32_t *pc;
-  int fwd_labels[MAXLABEL];
-  int back_labels[MAXLABEL];
-
-  /* For fields marked "lazy", parse them lazily or eagerly? */
-  bool lazy;
-} compiler;
-
-static compiler *newcompiler(mgroup *group, bool lazy) {
-  compiler *ret = upb_gmalloc(sizeof(*ret));
-  int i;
-
-  ret->group = group;
-  ret->lazy = lazy;
-  for (i = 0; i < MAXLABEL; i++) {
-    ret->fwd_labels[i] = EMPTYLABEL;
-    ret->back_labels[i] = EMPTYLABEL;
-  }
-  return ret;
-}
-
-static void freecompiler(compiler *c) {
-  upb_gfree(c);
-}
-
-const size_t ptr_words = sizeof(void*) / sizeof(uint32_t);
-
-/* How many words an instruction is. */
-static int instruction_len(uint32_t instr) {
-  switch (getop(instr)) {
-    case OP_SETDISPATCH: return 1 + ptr_words;
-    case OP_TAGN: return 3;
-    case OP_SETBIGGROUPNUM: return 2;
-    default: return 1;
-  }
-}
-
-bool op_has_longofs(int32_t instruction) {
-  switch (getop(instruction)) {
-    case OP_CALL:
-    case OP_BRANCH:
-    case OP_CHECKDELIM:
-      return true;
-    /* The "tag" instructions only have 8 bytes available for the jump target,
-     * but that is ok because these opcodes only require short jumps. */
-    case OP_TAG1:
-    case OP_TAG2:
-    case OP_TAGN:
-      return false;
-    default:
-      UPB_ASSERT(false);
-      return false;
-  }
-}
-
-static int32_t getofs(uint32_t instruction) {
-  if (op_has_longofs(instruction)) {
-    return (int32_t)instruction >> 8;
-  } else {
-    return (int8_t)(instruction >> 8);
-  }
-}
-
-static void setofs(uint32_t *instruction, int32_t ofs) {
-  if (op_has_longofs(*instruction)) {
-    *instruction = getop(*instruction) | (uint32_t)ofs << 8;
-  } else {
-    *instruction = (*instruction & ~0xff00) | ((ofs & 0xff) << 8);
-  }
-  UPB_ASSERT(getofs(*instruction) == ofs);  /* Would fail in cases of overflow. */
-}
-
-static uint32_t pcofs(compiler *c) {
-  return (uint32_t)(c->pc - c->group->bytecode);
-}
-
-/* Defines a local label at the current PC location.  All previous forward
- * references are updated to point to this location.  The location is noted
- * for any future backward references. */
-static void label(compiler *c, unsigned int label) {
-  int val;
-  uint32_t *codep;
-
-  UPB_ASSERT(label < MAXLABEL);
-  val = c->fwd_labels[label];
-  codep = (val == EMPTYLABEL) ? NULL : c->group->bytecode + val;
-  while (codep) {
-    int ofs = getofs(*codep);
-    setofs(codep, (int32_t)(c->pc - codep - instruction_len(*codep)));
-    codep = ofs ? codep + ofs : NULL;
-  }
-  c->fwd_labels[label] = EMPTYLABEL;
-  c->back_labels[label] = pcofs(c);
-}
-
-/* Creates a reference to a numbered label; either a forward reference
- * (positive arg) or backward reference (negative arg).  For forward references
- * the value returned now is actually a "next" pointer into a linked list of all
- * instructions that use this label and will be patched later when the label is
- * defined with label().
- *
- * The returned value is the offset that should be written into the instruction.
- */
-static int32_t labelref(compiler *c, int label) {
-  UPB_ASSERT(label < MAXLABEL);
-  if (label == LABEL_DISPATCH) {
-    /* No resolving required. */
-    return 0;
-  } else if (label < 0) {
-    /* Backward local label.  Relative to the next instruction. */
-    uint32_t from = (uint32_t)((c->pc + 1) - c->group->bytecode);
-    return c->back_labels[-label] - from;
-  } else {
-    /* Forward local label: prepend to (possibly-empty) linked list. */
-    int *lptr = &c->fwd_labels[label];
-    int32_t ret = (*lptr == EMPTYLABEL) ? 0 : *lptr - pcofs(c);
-    *lptr = pcofs(c);
-    return ret;
-  }
-}
-
-static void put32(compiler *c, uint32_t v) {
-  mgroup *g = c->group;
-  if (c->pc == g->bytecode_end) {
-    int ofs = pcofs(c);
-    size_t oldsize = g->bytecode_end - g->bytecode;
-    size_t newsize = UPB_MAX(oldsize * 2, 64);
-    /* TODO(haberman): handle OOM. */
-    g->bytecode = upb_grealloc(g->bytecode, oldsize * sizeof(uint32_t),
-                                            newsize * sizeof(uint32_t));
-    g->bytecode_end = g->bytecode + newsize;
-    c->pc = g->bytecode + ofs;
-  }
-  *c->pc++ = v;
-}
-
-static void putop(compiler *c, int op, ...) {
-  va_list ap;
-  va_start(ap, op);
-
-  switch (op) {
-    case OP_SETDISPATCH: {
-      uintptr_t ptr = (uintptr_t)va_arg(ap, void*);
-      put32(c, OP_SETDISPATCH);
-      put32(c, (uint32_t)ptr);
-      if (sizeof(uintptr_t) > sizeof(uint32_t))
-        put32(c, (uint64_t)ptr >> 32);
-      break;
-    }
-    case OP_STARTMSG:
-    case OP_ENDMSG:
-    case OP_PUSHLENDELIM:
-    case OP_POP:
-    case OP_SETDELIM:
-    case OP_HALT:
-    case OP_RET:
-    case OP_DISPATCH:
-      put32(c, op);
-      break;
-    case OP_PARSE_DOUBLE:
-    case OP_PARSE_FLOAT:
-    case OP_PARSE_INT64:
-    case OP_PARSE_UINT64:
-    case OP_PARSE_INT32:
-    case OP_PARSE_FIXED64:
-    case OP_PARSE_FIXED32:
-    case OP_PARSE_BOOL:
-    case OP_PARSE_UINT32:
-    case OP_PARSE_SFIXED32:
-    case OP_PARSE_SFIXED64:
-    case OP_PARSE_SINT32:
-    case OP_PARSE_SINT64:
-    case OP_STARTSEQ:
-    case OP_ENDSEQ:
-    case OP_STARTSUBMSG:
-    case OP_ENDSUBMSG:
-    case OP_STARTSTR:
-    case OP_STRING:
-    case OP_ENDSTR:
-    case OP_PUSHTAGDELIM:
-      put32(c, op | va_arg(ap, upb_selector_t) << 8);
-      break;
-    case OP_SETBIGGROUPNUM:
-      put32(c, op);
-      put32(c, va_arg(ap, int));
-      break;
-    case OP_CALL: {
-      const upb_pbdecodermethod *method = va_arg(ap, upb_pbdecodermethod *);
-      put32(c, op | (method->code_base.ofs - (pcofs(c) + 1)) << 8);
-      break;
-    }
-    case OP_CHECKDELIM:
-    case OP_BRANCH: {
-      uint32_t instruction = op;
-      int label = va_arg(ap, int);
-      setofs(&instruction, labelref(c, label));
-      put32(c, instruction);
-      break;
-    }
-    case OP_TAG1:
-    case OP_TAG2: {
-      int label = va_arg(ap, int);
-      uint64_t tag = va_arg(ap, uint64_t);
-      uint32_t instruction = (uint32_t)(op | (tag << 16));
-      UPB_ASSERT(tag <= 0xffff);
-      setofs(&instruction, labelref(c, label));
-      put32(c, instruction);
-      break;
-    }
-    case OP_TAGN: {
-      int label = va_arg(ap, int);
-      uint64_t tag = va_arg(ap, uint64_t);
-      uint32_t instruction = op | (upb_value_size(tag) << 16);
-      setofs(&instruction, labelref(c, label));
-      put32(c, instruction);
-      put32(c, (uint32_t)tag);
-      put32(c, tag >> 32);
-      break;
-    }
-  }
-
-  va_end(ap);
-}
-
-#if defined(UPB_DUMP_BYTECODE)
-
-const char *upb_pbdecoder_getopname(unsigned int op) {
-#define QUOTE(x) #x
-#define EXPAND_AND_QUOTE(x) QUOTE(x)
-#define OPNAME(x) OP_##x
-#define OP(x) case OPNAME(x): return EXPAND_AND_QUOTE(OPNAME(x));
-#define T(x) OP(PARSE_##x)
-  /* Keep in sync with list in decoder.int.h. */
-  switch ((opcode)op) {
-    T(DOUBLE) T(FLOAT) T(INT64) T(UINT64) T(INT32) T(FIXED64) T(FIXED32)
-    T(BOOL) T(UINT32) T(SFIXED32) T(SFIXED64) T(SINT32) T(SINT64)
-    OP(STARTMSG) OP(ENDMSG) OP(STARTSEQ) OP(ENDSEQ) OP(STARTSUBMSG)
-    OP(ENDSUBMSG) OP(STARTSTR) OP(STRING) OP(ENDSTR) OP(CALL) OP(RET)
-    OP(PUSHLENDELIM) OP(PUSHTAGDELIM) OP(SETDELIM) OP(CHECKDELIM)
-    OP(BRANCH) OP(TAG1) OP(TAG2) OP(TAGN) OP(SETDISPATCH) OP(POP)
-    OP(SETBIGGROUPNUM) OP(DISPATCH) OP(HALT)
-  }
-  return "<unknown op>";
-#undef OP
-#undef T
-}
-
-#endif
-
-#ifdef UPB_DUMP_BYTECODE
-
-static void dumpbc(uint32_t *p, uint32_t *end, FILE *f) {
-
-  uint32_t *begin = p;
-
-  while (p < end) {
-    fprintf(f, "%p  %8tx", p, p - begin);
-    uint32_t instr = *p++;
-    uint8_t op = getop(instr);
-    fprintf(f, " %s", upb_pbdecoder_getopname(op));
-    switch ((opcode)op) {
-      case OP_SETDISPATCH: {
-        const upb_inttable *dispatch;
-        memcpy(&dispatch, p, sizeof(void*));
-        p += ptr_words;
-        const upb_pbdecodermethod *method =
-            (void *)((char *)dispatch -
-                     offsetof(upb_pbdecodermethod, dispatch));
-        fprintf(f, " %s", upb_msgdef_fullname(
-                              upb_handlers_msgdef(method->dest_handlers_)));
-        break;
-      }
-      case OP_DISPATCH:
-      case OP_STARTMSG:
-      case OP_ENDMSG:
-      case OP_PUSHLENDELIM:
-      case OP_POP:
-      case OP_SETDELIM:
-      case OP_HALT:
-      case OP_RET:
-        break;
-      case OP_PARSE_DOUBLE:
-      case OP_PARSE_FLOAT:
-      case OP_PARSE_INT64:
-      case OP_PARSE_UINT64:
-      case OP_PARSE_INT32:
-      case OP_PARSE_FIXED64:
-      case OP_PARSE_FIXED32:
-      case OP_PARSE_BOOL:
-      case OP_PARSE_UINT32:
-      case OP_PARSE_SFIXED32:
-      case OP_PARSE_SFIXED64:
-      case OP_PARSE_SINT32:
-      case OP_PARSE_SINT64:
-      case OP_STARTSEQ:
-      case OP_ENDSEQ:
-      case OP_STARTSUBMSG:
-      case OP_ENDSUBMSG:
-      case OP_STARTSTR:
-      case OP_STRING:
-      case OP_ENDSTR:
-      case OP_PUSHTAGDELIM:
-        fprintf(f, " %d", instr >> 8);
-        break;
-      case OP_SETBIGGROUPNUM:
-        fprintf(f, " %d", *p++);
-        break;
-      case OP_CHECKDELIM:
-      case OP_CALL:
-      case OP_BRANCH:
-        fprintf(f, " =>0x%tx", p + getofs(instr) - begin);
-        break;
-      case OP_TAG1:
-      case OP_TAG2: {
-        fprintf(f, " tag:0x%x", instr >> 16);
-        if (getofs(instr)) {
-          fprintf(f, " =>0x%tx", p + getofs(instr) - begin);
-        }
-        break;
-      }
-      case OP_TAGN: {
-        uint64_t tag = *p++;
-        tag |= (uint64_t)*p++ << 32;
-        fprintf(f, " tag:0x%llx", (long long)tag);
-        fprintf(f, " n:%d", instr >> 16);
-        if (getofs(instr)) {
-          fprintf(f, " =>0x%tx", p + getofs(instr) - begin);
-        }
-        break;
-      }
-    }
-    fputs("\n", f);
-  }
-}
-
-#endif
-
-static uint64_t get_encoded_tag(const upb_fielddef *f, int wire_type) {
-  uint32_t tag = (upb_fielddef_number(f) << 3) | wire_type;
-  uint64_t encoded_tag = upb_vencode32(tag);
-  /* No tag should be greater than 5 bytes. */
-  UPB_ASSERT(encoded_tag <= 0xffffffffff);
-  return encoded_tag;
-}
-
-static void putchecktag(compiler *c, const upb_fielddef *f,
-                        int wire_type, int dest) {
-  uint64_t tag = get_encoded_tag(f, wire_type);
-  switch (upb_value_size(tag)) {
-    case 1:
-      putop(c, OP_TAG1, dest, tag);
-      break;
-    case 2:
-      putop(c, OP_TAG2, dest, tag);
-      break;
-    default:
-      putop(c, OP_TAGN, dest, tag);
-      break;
-  }
-}
-
-static upb_selector_t getsel(const upb_fielddef *f, upb_handlertype_t type) {
-  upb_selector_t selector;
-  bool ok = upb_handlers_getselector(f, type, &selector);
-  UPB_ASSERT(ok);
-  return selector;
-}
-
-/* Takes an existing, primary dispatch table entry and repacks it with a
- * different alternate wire type.  Called when we are inserting a secondary
- * dispatch table entry for an alternate wire type. */
-static uint64_t repack(uint64_t dispatch, int new_wt2) {
-  uint64_t ofs;
-  uint8_t wt1;
-  uint8_t old_wt2;
-  upb_pbdecoder_unpackdispatch(dispatch, &ofs, &wt1, &old_wt2);
-  UPB_ASSERT(old_wt2 == NO_WIRE_TYPE);  /* wt2 should not be set yet. */
-  return upb_pbdecoder_packdispatch(ofs, wt1, new_wt2);
-}
-
-/* Marks the current bytecode position as the dispatch target for this message,
- * field, and wire type. */
-static void dispatchtarget(compiler *c, upb_pbdecodermethod *method,
-                           const upb_fielddef *f, int wire_type) {
-  /* Offset is relative to msg base. */
-  uint64_t ofs = pcofs(c) - method->code_base.ofs;
-  uint32_t fn = upb_fielddef_number(f);
-  upb_inttable *d = &method->dispatch;
-  upb_value v;
-  if (upb_inttable_remove(d, fn, &v)) {
-    /* TODO: prioritize based on packed setting in .proto file. */
-    uint64_t repacked = repack(upb_value_getuint64(v), wire_type);
-    upb_inttable_insert(d, fn, upb_value_uint64(repacked));
-    upb_inttable_insert(d, fn + UPB_MAX_FIELDNUMBER, upb_value_uint64(ofs));
-  } else {
-    uint64_t val = upb_pbdecoder_packdispatch(ofs, wire_type, NO_WIRE_TYPE);
-    upb_inttable_insert(d, fn, upb_value_uint64(val));
-  }
-}
-
-static void putpush(compiler *c, const upb_fielddef *f) {
-  if (upb_fielddef_descriptortype(f) == UPB_DESCRIPTOR_TYPE_MESSAGE) {
-    putop(c, OP_PUSHLENDELIM);
-  } else {
-    uint32_t fn = upb_fielddef_number(f);
-    if (fn >= 1 << 24) {
-      putop(c, OP_PUSHTAGDELIM, 0);
-      putop(c, OP_SETBIGGROUPNUM, fn);
-    } else {
-      putop(c, OP_PUSHTAGDELIM, fn);
-    }
-  }
-}
-
-static upb_pbdecodermethod *find_submethod(const compiler *c,
-                                           const upb_pbdecodermethod *method,
-                                           const upb_fielddef *f) {
-  const upb_handlers *sub =
-      upb_handlers_getsubhandlers(method->dest_handlers_, f);
-  upb_value v;
-  return upb_inttable_lookupptr(&c->group->methods, sub, &v)
-             ? upb_value_getptr(v)
-             : NULL;
-}
-
-static void putsel(compiler *c, opcode op, upb_selector_t sel,
-                   const upb_handlers *h) {
-  if (upb_handlers_gethandler(h, sel, NULL)) {
-    putop(c, op, sel);
-  }
-}
-
-/* Puts an opcode to call a callback, but only if a callback actually exists for
- * this field and handler type. */
-static void maybeput(compiler *c, opcode op, const upb_handlers *h,
-                     const upb_fielddef *f, upb_handlertype_t type) {
-  putsel(c, op, getsel(f, type), h);
-}
-
-static bool haslazyhandlers(const upb_handlers *h, const upb_fielddef *f) {
-  if (!upb_fielddef_lazy(f))
-    return false;
-
-  return upb_handlers_gethandler(h, getsel(f, UPB_HANDLER_STARTSTR), NULL) ||
-         upb_handlers_gethandler(h, getsel(f, UPB_HANDLER_STRING), NULL) ||
-         upb_handlers_gethandler(h, getsel(f, UPB_HANDLER_ENDSTR), NULL);
-}
-
-
-/* bytecode compiler code generation ******************************************/
-
-/* Symbolic names for our local labels. */
-#define LABEL_LOOPSTART 1  /* Top of a repeated field loop. */
-#define LABEL_LOOPBREAK 2  /* To jump out of a repeated loop */
-#define LABEL_FIELD     3  /* Jump backward to find the most recent field. */
-#define LABEL_ENDMSG    4  /* To reach the OP_ENDMSG instr for this msg. */
-
-/* Generates bytecode to parse a single non-lazy message field. */
-static void generate_msgfield(compiler *c, const upb_fielddef *f,
-                              upb_pbdecodermethod *method) {
-  const upb_handlers *h = upb_pbdecodermethod_desthandlers(method);
-  const upb_pbdecodermethod *sub_m = find_submethod(c, method, f);
-  int wire_type;
-
-  if (!sub_m) {
-    /* Don't emit any code for this field at all; it will be parsed as an
-     * unknown field.
-     *
-     * TODO(haberman): we should change this to parse it as a string field
-     * instead.  It will probably be faster, but more importantly, once we
-     * start vending unknown fields, a field shouldn't be treated as unknown
-     * just because it doesn't have subhandlers registered. */
-    return;
-  }
-
-  label(c, LABEL_FIELD);
-
-  wire_type =
-      (upb_fielddef_descriptortype(f) == UPB_DESCRIPTOR_TYPE_MESSAGE)
-          ? UPB_WIRE_TYPE_DELIMITED
-          : UPB_WIRE_TYPE_START_GROUP;
-
-  if (upb_fielddef_isseq(f)) {
-    putop(c, OP_CHECKDELIM, LABEL_ENDMSG);
-    putchecktag(c, f, wire_type, LABEL_DISPATCH);
-   dispatchtarget(c, method, f, wire_type);
-    putop(c, OP_PUSHTAGDELIM, 0);
-    putop(c, OP_STARTSEQ, getsel(f, UPB_HANDLER_STARTSEQ));
-   label(c, LABEL_LOOPSTART);
-    putpush(c, f);
-    putop(c, OP_STARTSUBMSG, getsel(f, UPB_HANDLER_STARTSUBMSG));
-    putop(c, OP_CALL, sub_m);
-    putop(c, OP_POP);
-    maybeput(c, OP_ENDSUBMSG, h, f, UPB_HANDLER_ENDSUBMSG);
-    if (wire_type == UPB_WIRE_TYPE_DELIMITED) {
-      putop(c, OP_SETDELIM);
-    }
-    putop(c, OP_CHECKDELIM, LABEL_LOOPBREAK);
-    putchecktag(c, f, wire_type, LABEL_LOOPBREAK);
-    putop(c, OP_BRANCH, -LABEL_LOOPSTART);
-   label(c, LABEL_LOOPBREAK);
-    putop(c, OP_POP);
-    maybeput(c, OP_ENDSEQ, h, f, UPB_HANDLER_ENDSEQ);
-  } else {
-    putop(c, OP_CHECKDELIM, LABEL_ENDMSG);
-    putchecktag(c, f, wire_type, LABEL_DISPATCH);
-   dispatchtarget(c, method, f, wire_type);
-    putpush(c, f);
-    putop(c, OP_STARTSUBMSG, getsel(f, UPB_HANDLER_STARTSUBMSG));
-    putop(c, OP_CALL, sub_m);
-    putop(c, OP_POP);
-    maybeput(c, OP_ENDSUBMSG, h, f, UPB_HANDLER_ENDSUBMSG);
-    if (wire_type == UPB_WIRE_TYPE_DELIMITED) {
-      putop(c, OP_SETDELIM);
-    }
-  }
-}
-
-/* Generates bytecode to parse a single string or lazy submessage field. */
-static void generate_delimfield(compiler *c, const upb_fielddef *f,
-                                upb_pbdecodermethod *method) {
-  const upb_handlers *h = upb_pbdecodermethod_desthandlers(method);
-
-  label(c, LABEL_FIELD);
-  if (upb_fielddef_isseq(f)) {
-    putop(c, OP_CHECKDELIM, LABEL_ENDMSG);
-    putchecktag(c, f, UPB_WIRE_TYPE_DELIMITED, LABEL_DISPATCH);
-   dispatchtarget(c, method, f, UPB_WIRE_TYPE_DELIMITED);
-    putop(c, OP_PUSHTAGDELIM, 0);
-    putop(c, OP_STARTSEQ, getsel(f, UPB_HANDLER_STARTSEQ));
-   label(c, LABEL_LOOPSTART);
-    putop(c, OP_PUSHLENDELIM);
-    putop(c, OP_STARTSTR, getsel(f, UPB_HANDLER_STARTSTR));
-    /* Need to emit even if no handler to skip past the string. */
-    putop(c, OP_STRING, getsel(f, UPB_HANDLER_STRING));
-    maybeput(c, OP_ENDSTR, h, f, UPB_HANDLER_ENDSTR);
-    putop(c, OP_POP);
-    putop(c, OP_SETDELIM);
-    putop(c, OP_CHECKDELIM, LABEL_LOOPBREAK);
-    putchecktag(c, f, UPB_WIRE_TYPE_DELIMITED, LABEL_LOOPBREAK);
-    putop(c, OP_BRANCH, -LABEL_LOOPSTART);
-   label(c, LABEL_LOOPBREAK);
-    putop(c, OP_POP);
-    maybeput(c, OP_ENDSEQ, h, f, UPB_HANDLER_ENDSEQ);
-  } else {
-    putop(c, OP_CHECKDELIM, LABEL_ENDMSG);
-    putchecktag(c, f, UPB_WIRE_TYPE_DELIMITED, LABEL_DISPATCH);
-   dispatchtarget(c, method, f, UPB_WIRE_TYPE_DELIMITED);
-    putop(c, OP_PUSHLENDELIM);
-    putop(c, OP_STARTSTR, getsel(f, UPB_HANDLER_STARTSTR));
-    putop(c, OP_STRING, getsel(f, UPB_HANDLER_STRING));
-    maybeput(c, OP_ENDSTR, h, f, UPB_HANDLER_ENDSTR);
-    putop(c, OP_POP);
-    putop(c, OP_SETDELIM);
-  }
-}
-
-/* Generates bytecode to parse a single primitive field. */
-static void generate_primitivefield(compiler *c, const upb_fielddef *f,
-                                    upb_pbdecodermethod *method) {
-  const upb_handlers *h = upb_pbdecodermethod_desthandlers(method);
-  upb_descriptortype_t descriptor_type = upb_fielddef_descriptortype(f);
-  opcode parse_type;
-  upb_selector_t sel;
-  int wire_type;
-
-  label(c, LABEL_FIELD);
-
-  /* From a decoding perspective, ENUM is the same as INT32. */
-  if (descriptor_type == UPB_DESCRIPTOR_TYPE_ENUM)
-    descriptor_type = UPB_DESCRIPTOR_TYPE_INT32;
-
-  parse_type = (opcode)descriptor_type;
-
-  /* TODO(haberman): generate packed or non-packed first depending on "packed"
-   * setting in the fielddef.  This will favor (in speed) whichever was
-   * specified. */
-
-  UPB_ASSERT((int)parse_type >= 0 && parse_type <= OP_MAX);
-  sel = getsel(f, upb_handlers_getprimitivehandlertype(f));
-  wire_type = upb_pb_native_wire_types[upb_fielddef_descriptortype(f)];
-  if (upb_fielddef_isseq(f)) {
-    putop(c, OP_CHECKDELIM, LABEL_ENDMSG);
-    putchecktag(c, f, UPB_WIRE_TYPE_DELIMITED, LABEL_DISPATCH);
-   dispatchtarget(c, method, f, UPB_WIRE_TYPE_DELIMITED);
-    putop(c, OP_PUSHLENDELIM);
-    putop(c, OP_STARTSEQ, getsel(f, UPB_HANDLER_STARTSEQ));  /* Packed */
-   label(c, LABEL_LOOPSTART);
-    putop(c, parse_type, sel);
-    putop(c, OP_CHECKDELIM, LABEL_LOOPBREAK);
-    putop(c, OP_BRANCH, -LABEL_LOOPSTART);
-   dispatchtarget(c, method, f, wire_type);
-    putop(c, OP_PUSHTAGDELIM, 0);
-    putop(c, OP_STARTSEQ, getsel(f, UPB_HANDLER_STARTSEQ));  /* Non-packed */
-   label(c, LABEL_LOOPSTART);
-    putop(c, parse_type, sel);
-    putop(c, OP_CHECKDELIM, LABEL_LOOPBREAK);
-    putchecktag(c, f, wire_type, LABEL_LOOPBREAK);
-    putop(c, OP_BRANCH, -LABEL_LOOPSTART);
-   label(c, LABEL_LOOPBREAK);
-    putop(c, OP_POP);  /* Packed and non-packed join. */
-    maybeput(c, OP_ENDSEQ, h, f, UPB_HANDLER_ENDSEQ);
-    putop(c, OP_SETDELIM);  /* Could remove for non-packed by dup ENDSEQ. */
-  } else {
-    putop(c, OP_CHECKDELIM, LABEL_ENDMSG);
-    putchecktag(c, f, wire_type, LABEL_DISPATCH);
-   dispatchtarget(c, method, f, wire_type);
-    putop(c, parse_type, sel);
-  }
-}
-
-/* Adds bytecode for parsing the given message to the given decoderplan,
- * while adding all dispatch targets to this message's dispatch table. */
-static void compile_method(compiler *c, upb_pbdecodermethod *method) {
-  const upb_handlers *h;
-  const upb_msgdef *md;
-  uint32_t* start_pc;
-  int i, n;
-  upb_value val;
-
-  UPB_ASSERT(method);
-
-  /* Clear all entries in the dispatch table. */
-  upb_inttable_uninit(&method->dispatch);
-  upb_inttable_init(&method->dispatch, UPB_CTYPE_UINT64);
-
-  h = upb_pbdecodermethod_desthandlers(method);
-  md = upb_handlers_msgdef(h);
-
- method->code_base.ofs = pcofs(c);
-  putop(c, OP_SETDISPATCH, &method->dispatch);
-  putsel(c, OP_STARTMSG, UPB_STARTMSG_SELECTOR, h);
- label(c, LABEL_FIELD);
-  start_pc = c->pc;
-  n = upb_msgdef_fieldcount(md);
-  for(i = 0; i < n; i++) {
-    const upb_fielddef *f = upb_msgdef_field(md, i);
-    upb_fieldtype_t type = upb_fielddef_type(f);
-
-    if (type == UPB_TYPE_MESSAGE && !(haslazyhandlers(h, f) && c->lazy)) {
-      generate_msgfield(c, f, method);
-    } else if (type == UPB_TYPE_STRING || type == UPB_TYPE_BYTES ||
-               type == UPB_TYPE_MESSAGE) {
-      generate_delimfield(c, f, method);
-    } else {
-      generate_primitivefield(c, f, method);
-    }
-  }
-
-  /* If there were no fields, or if no handlers were defined, we need to
-   * generate a non-empty loop body so that we can at least dispatch for unknown
-   * fields and check for the end of the message. */
-  if (c->pc == start_pc) {
-    /* Check for end-of-message. */
-    putop(c, OP_CHECKDELIM, LABEL_ENDMSG);
-    /* Unconditionally dispatch. */
-    putop(c, OP_DISPATCH, 0);
-  }
-
-  /* For now we just loop back to the last field of the message (or if none,
-   * the DISPATCH opcode for the message). */
-  putop(c, OP_BRANCH, -LABEL_FIELD);
-
-  /* Insert both a label and a dispatch table entry for this end-of-msg. */
- label(c, LABEL_ENDMSG);
-  val = upb_value_uint64(pcofs(c) - method->code_base.ofs);
-  upb_inttable_insert(&method->dispatch, DISPATCH_ENDMSG, val);
-
-  putsel(c, OP_ENDMSG, UPB_ENDMSG_SELECTOR, h);
-  putop(c, OP_RET);
-
-  upb_inttable_compact(&method->dispatch);
-}
-
-/* Populate "methods" with new upb_pbdecodermethod objects reachable from "h".
- * Returns the method for these handlers.
- *
- * Generates a new method for every destination handlers reachable from "h". */
-static void find_methods(compiler *c, const upb_handlers *h) {
-  upb_value v;
-  int i, n;
-  const upb_msgdef *md;
-  upb_pbdecodermethod *method;
-
-  if (upb_inttable_lookupptr(&c->group->methods, h, &v))
-    return;
-
-  method = newmethod(h, c->group);
-  upb_inttable_insertptr(&c->group->methods, h, upb_value_ptr(method));
-
-  /* Find submethods. */
-  md = upb_handlers_msgdef(h);
-  n = upb_msgdef_fieldcount(md);
-  for (i = 0; i < n; i++) {
-    const upb_fielddef *f = upb_msgdef_field(md, i);
-    const upb_handlers *sub_h;
-    if (upb_fielddef_type(f) == UPB_TYPE_MESSAGE &&
-        (sub_h = upb_handlers_getsubhandlers(h, f)) != NULL) {
-      /* We only generate a decoder method for submessages with handlers.
-       * Others will be parsed as unknown fields. */
-      find_methods(c, sub_h);
-    }
-  }
-}
-
-/* (Re-)compile bytecode for all messages in "msgs."
- * Overwrites any existing bytecode in "c". */
-static void compile_methods(compiler *c) {
-  upb_inttable_iter i;
-
-  /* Start over at the beginning of the bytecode. */
-  c->pc = c->group->bytecode;
-
-  upb_inttable_begin(&i, &c->group->methods);
-  for(; !upb_inttable_done(&i); upb_inttable_next(&i)) {
-    upb_pbdecodermethod *method = upb_value_getptr(upb_inttable_iter_value(&i));
-    compile_method(c, method);
-  }
-}
-
-static void set_bytecode_handlers(mgroup *g) {
-  upb_inttable_iter i;
-  upb_inttable_begin(&i, &g->methods);
-  for(; !upb_inttable_done(&i); upb_inttable_next(&i)) {
-    upb_pbdecodermethod *m = upb_value_getptr(upb_inttable_iter_value(&i));
-    upb_byteshandler *h = &m->input_handler_;
-
-    m->code_base.ptr = g->bytecode + m->code_base.ofs;
-
-    upb_byteshandler_setstartstr(h, upb_pbdecoder_startbc, m->code_base.ptr);
-    upb_byteshandler_setstring(h, upb_pbdecoder_decode, g);
-    upb_byteshandler_setendstr(h, upb_pbdecoder_end, m);
-  }
-}
-
-
-/* TODO(haberman): allow this to be constructed for an arbitrary set of dest
- * handlers and other mgroups (but verify we have a transitive closure). */
-const mgroup *mgroup_new(const upb_handlers *dest, bool lazy) {
-  mgroup *g;
-  compiler *c;
-
-  g = newgroup();
-  c = newcompiler(g, lazy);
-  find_methods(c, dest);
-
-  /* We compile in two passes:
-   * 1. all messages are assigned relative offsets from the beginning of the
-   *    bytecode (saved in method->code_base).
-   * 2. forwards OP_CALL instructions can be correctly linked since message
-   *    offsets have been previously assigned.
-   *
-   * Could avoid the second pass by linking OP_CALL instructions somehow. */
-  compile_methods(c);
-  compile_methods(c);
-  g->bytecode_end = c->pc;
-  freecompiler(c);
-
-#ifdef UPB_DUMP_BYTECODE
-  {
-    FILE *f = fopen("/tmp/upb-bytecode", "w");
-    UPB_ASSERT(f);
-    dumpbc(g->bytecode, g->bytecode_end, stderr);
-    dumpbc(g->bytecode, g->bytecode_end, f);
-    fclose(f);
-
-    f = fopen("/tmp/upb-bytecode.bin", "wb");
-    UPB_ASSERT(f);
-    fwrite(g->bytecode, 1, g->bytecode_end - g->bytecode, f);
-    fclose(f);
-  }
-#endif
-
-  set_bytecode_handlers(g);
-  return g;
-}
-
-
-/* upb_pbcodecache ************************************************************/
-
-upb_pbcodecache *upb_pbcodecache_new(upb_handlercache *dest) {
-  upb_pbcodecache *c = upb_gmalloc(sizeof(*c));
-
-  if (!c) return NULL;
-
-  c->dest = dest;
-  c->lazy = false;
-
-  c->arena = upb_arena_new();
-  if (!upb_inttable_init(&c->groups, UPB_CTYPE_CONSTPTR)) return NULL;
-
-  return c;
-}
-
-void upb_pbcodecache_free(upb_pbcodecache *c) {
-  upb_inttable_iter i;
-
-  upb_inttable_begin(&i, &c->groups);
-  for(; !upb_inttable_done(&i); upb_inttable_next(&i)) {
-    upb_value val = upb_inttable_iter_value(&i);
-    freegroup((void*)upb_value_getconstptr(val));
-  }
-
-  upb_inttable_uninit(&c->groups);
-  upb_arena_free(c->arena);
-  upb_gfree(c);
-}
-
-void upb_pbdecodermethodopts_setlazy(upb_pbcodecache *c, bool lazy) {
-  UPB_ASSERT(upb_inttable_count(&c->groups) == 0);
-  c->lazy = lazy;
-}
-
-const upb_pbdecodermethod *upb_pbcodecache_get(upb_pbcodecache *c,
-                                               const upb_msgdef *md) {
-  upb_value v;
-  bool ok;
-  const upb_handlers *h;
-  const mgroup *g;
-
-  h = upb_handlercache_get(c->dest, md);
-  if (upb_inttable_lookupptr(&c->groups, md, &v)) {
-    g = upb_value_getconstptr(v);
-  } else {
-    g = mgroup_new(h, c->lazy);
-    ok = upb_inttable_insertptr(&c->groups, md, upb_value_constptr(g));
-    UPB_ASSUME(ok);
-  }
-
-  ok = upb_inttable_lookupptr(&g->methods, h, &v);
-  UPB_ASSUME(ok);
-  return upb_value_getptr(v);
-}
diff --git a/third_party/upb/upb/pb/decoder.c b/third_party/upb/upb/pb/decoder.c
deleted file mode 100644 (file)
index 4f40eed..0000000
+++ /dev/null
@@ -1,1047 +0,0 @@
-/*
-** upb::Decoder (Bytecode Decoder VM)
-**
-** Bytecode must previously have been generated using the bytecode compiler in
-** compile_decoder.c.  This decoder then walks through the bytecode op-by-op to
-** parse the input.
-**
-** Decoding is fully resumable; we just keep a pointer to the current bytecode
-** instruction and resume from there.  A fair amount of the logic here is to
-** handle the fact that values can span buffer seams and we have to be able to
-** be capable of suspending/resuming from any byte in the stream.  This
-** sometimes requires keeping a few trailing bytes from the last buffer around
-** in the "residual" buffer.
-*/
-
-#include <inttypes.h>
-#include <stddef.h>
-#include "upb/pb/decoder.int.h"
-#include "upb/pb/varint.int.h"
-
-#ifdef UPB_DUMP_BYTECODE
-#include <stdio.h>
-#endif
-
-#include "upb/port_def.inc"
-
-#define CHECK_SUSPEND(x) if (!(x)) return upb_pbdecoder_suspend(d);
-
-/* Error messages that are shared between the bytecode and JIT decoders. */
-const char *kPbDecoderStackOverflow = "Nesting too deep.";
-const char *kPbDecoderSubmessageTooLong =
-    "Submessage end extends past enclosing submessage.";
-
-/* Error messages shared within this file. */
-static const char *kUnterminatedVarint = "Unterminated varint.";
-
-/* upb_pbdecoder **************************************************************/
-
-static opcode halt = OP_HALT;
-
-/* A dummy character we can point to when the user passes us a NULL buffer.
- * We need this because in C (NULL + 0) and (NULL - NULL) are undefined
- * behavior, which would invalidate functions like curbufleft(). */
-static const char dummy_char;
-
-/* Whether an op consumes any of the input buffer. */
-static bool consumes_input(opcode op) {
-  switch (op) {
-    case OP_SETDISPATCH:
-    case OP_STARTMSG:
-    case OP_ENDMSG:
-    case OP_STARTSEQ:
-    case OP_ENDSEQ:
-    case OP_STARTSUBMSG:
-    case OP_ENDSUBMSG:
-    case OP_STARTSTR:
-    case OP_ENDSTR:
-    case OP_PUSHTAGDELIM:
-    case OP_POP:
-    case OP_SETDELIM:
-    case OP_SETBIGGROUPNUM:
-    case OP_CHECKDELIM:
-    case OP_CALL:
-    case OP_RET:
-    case OP_BRANCH:
-      return false;
-    default:
-      return true;
-  }
-}
-
-static size_t stacksize(upb_pbdecoder *d, size_t entries) {
-  UPB_UNUSED(d);
-  return entries * sizeof(upb_pbdecoder_frame);
-}
-
-static size_t callstacksize(upb_pbdecoder *d, size_t entries) {
-  UPB_UNUSED(d);
-
-  return entries * sizeof(uint32_t*);
-}
-
-
-static bool in_residual_buf(const upb_pbdecoder *d, const char *p);
-
-/* It's unfortunate that we have to micro-manage the compiler with
- * UPB_FORCEINLINE and UPB_NOINLINE, especially since this tuning is necessarily
- * specific to one hardware configuration.  But empirically on a Core i7,
- * performance increases 30-50% with these annotations.  Every instance where
- * these appear, gcc 4.2.1 made the wrong decision and degraded performance in
- * benchmarks. */
-
-static void seterr(upb_pbdecoder *d, const char *msg) {
-  upb_status_seterrmsg(d->status, msg);
-}
-
-void upb_pbdecoder_seterr(upb_pbdecoder *d, const char *msg) {
-  seterr(d, msg);
-}
-
-
-/* Buffering ******************************************************************/
-
-/* We operate on one buffer at a time, which is either the user's buffer passed
- * to our "decode" callback or some residual bytes from the previous buffer. */
-
-/* How many bytes can be safely read from d->ptr without reading past end-of-buf
- * or past the current delimited end. */
-static size_t curbufleft(const upb_pbdecoder *d) {
-  UPB_ASSERT(d->data_end >= d->ptr);
-  return d->data_end - d->ptr;
-}
-
-/* How many bytes are available before end-of-buffer. */
-static size_t bufleft(const upb_pbdecoder *d) {
-  return d->end - d->ptr;
-}
-
-/* Overall stream offset of d->ptr. */
-uint64_t offset(const upb_pbdecoder *d) {
-  return d->bufstart_ofs + (d->ptr - d->buf);
-}
-
-/* How many bytes are available before the end of this delimited region. */
-size_t delim_remaining(const upb_pbdecoder *d) {
-  return d->top->end_ofs - offset(d);
-}
-
-/* Advances d->ptr. */
-static void advance(upb_pbdecoder *d, size_t len) {
-  UPB_ASSERT(curbufleft(d) >= len);
-  d->ptr += len;
-}
-
-static bool in_buf(const char *p, const char *buf, const char *end) {
-  return p >= buf && p <= end;
-}
-
-static bool in_residual_buf(const upb_pbdecoder *d, const char *p) {
-  return in_buf(p, d->residual, d->residual_end);
-}
-
-/* Calculates the delim_end value, which is affected by both the current buffer
- * and the parsing stack, so must be called whenever either is updated. */
-static void set_delim_end(upb_pbdecoder *d) {
-  size_t delim_ofs = d->top->end_ofs - d->bufstart_ofs;
-  if (delim_ofs <= (size_t)(d->end - d->buf)) {
-    d->delim_end = d->buf + delim_ofs;
-    d->data_end = d->delim_end;
-  } else {
-    d->data_end = d->end;
-    d->delim_end = NULL;
-  }
-}
-
-static void switchtobuf(upb_pbdecoder *d, const char *buf, const char *end) {
-  d->ptr = buf;
-  d->buf = buf;
-  d->end = end;
-  set_delim_end(d);
-}
-
-static void advancetobuf(upb_pbdecoder *d, const char *buf, size_t len) {
-  UPB_ASSERT(curbufleft(d) == 0);
-  d->bufstart_ofs += (d->end - d->buf);
-  switchtobuf(d, buf, buf + len);
-}
-
-static void checkpoint(upb_pbdecoder *d) {
-  /* The assertion here is in the interests of efficiency, not correctness.
-   * We are trying to ensure that we don't checkpoint() more often than
-   * necessary. */
-  UPB_ASSERT(d->checkpoint != d->ptr);
-  d->checkpoint = d->ptr;
-}
-
-/* Skips "bytes" bytes in the stream, which may be more than available.  If we
- * skip more bytes than are available, we return a long read count to the caller
- * indicating how many bytes can be skipped over before passing actual data
- * again.  Skipped bytes can pass a NULL buffer and the decoder guarantees they
- * won't actually be read.
- */
-static int32_t skip(upb_pbdecoder *d, size_t bytes) {
-  UPB_ASSERT(!in_residual_buf(d, d->ptr) || d->size_param == 0);
-  UPB_ASSERT(d->skip == 0);
-  if (bytes > delim_remaining(d)) {
-    seterr(d, "Skipped value extended beyond enclosing submessage.");
-    return (int32_t)upb_pbdecoder_suspend(d);
-  } else if (bufleft(d) >= bytes) {
-    /* Skipped data is all in current buffer, and more is still available. */
-    advance(d, bytes);
-    d->skip = 0;
-    return DECODE_OK;
-  } else {
-    /* Skipped data extends beyond currently available buffers. */
-    d->pc = d->last;
-    d->skip = bytes - curbufleft(d);
-    d->bufstart_ofs += (d->end - d->buf);
-    d->residual_end = d->residual;
-    switchtobuf(d, d->residual, d->residual_end);
-    return (int32_t)(d->size_param + d->skip);
-  }
-}
-
-
-/* Resumes the decoder from an initial state or from a previous suspend. */
-int32_t upb_pbdecoder_resume(upb_pbdecoder *d, void *p, const char *buf,
-                             size_t size, const upb_bufhandle *handle) {
-  UPB_UNUSED(p);  /* Useless; just for the benefit of the JIT. */
-
-  /* d->skip and d->residual_end could probably elegantly be represented
-   * as a single variable, to more easily represent this invariant. */
-  UPB_ASSERT(!(d->skip && d->residual_end > d->residual));
-
-  /* We need to remember the original size_param, so that the value we return
-   * is relative to it, even if we do some skipping first. */
-  d->size_param = size;
-  d->handle = handle;
-
-  /* Have to handle this case specially (ie. not with skip()) because the user
-   * is allowed to pass a NULL buffer here, which won't allow us to safely
-   * calculate a d->end or use our normal functions like curbufleft(). */
-  if (d->skip && d->skip >= size) {
-    d->skip -= size;
-    d->bufstart_ofs += size;
-    buf = &dummy_char;
-    size = 0;
-
-    /* We can't just return now, because we might need to execute some ops
-     * like CHECKDELIM, which could call some callbacks and pop the stack. */
-  }
-
-  /* We need to pretend that this was the actual buffer param, since some of the
-   * calculations assume that d->ptr/d->buf is relative to this. */
-  d->buf_param = buf;
-
-  if (!buf) {
-    /* NULL buf is ok if its entire span is covered by the "skip" above, but
-     * by this point we know that "skip" doesn't cover the buffer. */
-    seterr(d, "Passed NULL buffer over non-skippable region.");
-    return (int32_t)upb_pbdecoder_suspend(d);
-  }
-
-  if (d->residual_end > d->residual) {
-    /* We have residual bytes from the last buffer. */
-    UPB_ASSERT(d->ptr == d->residual);
-  } else {
-    switchtobuf(d, buf, buf + size);
-  }
-
-  d->checkpoint = d->ptr;
-
-  /* Handle skips that don't cover the whole buffer (as above). */
-  if (d->skip) {
-    size_t skip_bytes = d->skip;
-    d->skip = 0;
-    CHECK_RETURN(skip(d, skip_bytes));
-    checkpoint(d);
-  }
-
-  /* If we're inside an unknown group, continue to parse unknown values. */
-  if (d->top->groupnum < 0) {
-    CHECK_RETURN(upb_pbdecoder_skipunknown(d, -1, 0));
-    checkpoint(d);
-  }
-
-  return DECODE_OK;
-}
-
-/* Suspends the decoder at the last checkpoint, without saving any residual
- * bytes.  If there are any unconsumed bytes, returns a short byte count. */
-size_t upb_pbdecoder_suspend(upb_pbdecoder *d) {
-  d->pc = d->last;
-  if (d->checkpoint == d->residual) {
-    /* Checkpoint was in residual buf; no user bytes were consumed. */
-    d->ptr = d->residual;
-    return 0;
-  } else {
-    size_t ret = d->size_param - (d->end - d->checkpoint);
-    UPB_ASSERT(!in_residual_buf(d, d->checkpoint));
-    UPB_ASSERT(d->buf == d->buf_param || d->buf == &dummy_char);
-
-    d->bufstart_ofs += (d->checkpoint - d->buf);
-    d->residual_end = d->residual;
-    switchtobuf(d, d->residual, d->residual_end);
-    return ret;
-  }
-}
-
-/* Suspends the decoder at the last checkpoint, and saves any unconsumed
- * bytes in our residual buffer.  This is necessary if we need more user
- * bytes to form a complete value, which might not be contiguous in the
- * user's buffers.  Always consumes all user bytes. */
-static size_t suspend_save(upb_pbdecoder *d) {
-  /* We hit end-of-buffer before we could parse a full value.
-   * Save any unconsumed bytes (if any) to the residual buffer. */
-  d->pc = d->last;
-
-  if (d->checkpoint == d->residual) {
-    /* Checkpoint was in residual buf; append user byte(s) to residual buf. */
-    UPB_ASSERT((d->residual_end - d->residual) + d->size_param <=
-           sizeof(d->residual));
-    if (!in_residual_buf(d, d->ptr)) {
-      d->bufstart_ofs -= (d->residual_end - d->residual);
-    }
-    memcpy(d->residual_end, d->buf_param, d->size_param);
-    d->residual_end += d->size_param;
-  } else {
-    /* Checkpoint was in user buf; old residual bytes not needed. */
-    size_t save;
-    UPB_ASSERT(!in_residual_buf(d, d->checkpoint));
-
-    d->ptr = d->checkpoint;
-    save = curbufleft(d);
-    UPB_ASSERT(save <= sizeof(d->residual));
-    memcpy(d->residual, d->ptr, save);
-    d->residual_end = d->residual + save;
-    d->bufstart_ofs = offset(d);
-  }
-
-  switchtobuf(d, d->residual, d->residual_end);
-  return d->size_param;
-}
-
-/* Copies the next "bytes" bytes into "buf" and advances the stream.
- * Requires that this many bytes are available in the current buffer. */
-UPB_FORCEINLINE static void consumebytes(upb_pbdecoder *d, void *buf,
-                                         size_t bytes) {
-  UPB_ASSERT(bytes <= curbufleft(d));
-  memcpy(buf, d->ptr, bytes);
-  advance(d, bytes);
-}
-
-/* Slow path for getting the next "bytes" bytes, regardless of whether they are
- * available in the current buffer or not.  Returns a status code as described
- * in decoder.int.h. */
-UPB_NOINLINE static int32_t getbytes_slow(upb_pbdecoder *d, void *buf,
-                                          size_t bytes) {
-  const size_t avail = curbufleft(d);
-  consumebytes(d, buf, avail);
-  bytes -= avail;
-  UPB_ASSERT(bytes > 0);
-  if (in_residual_buf(d, d->ptr)) {
-    advancetobuf(d, d->buf_param, d->size_param);
-  }
-  if (curbufleft(d) >= bytes) {
-    consumebytes(d, (char *)buf + avail, bytes);
-    return DECODE_OK;
-  } else if (d->data_end == d->delim_end) {
-    seterr(d, "Submessage ended in the middle of a value or group");
-    return (int32_t)upb_pbdecoder_suspend(d);
-  } else {
-    return (int32_t)suspend_save(d);
-  }
-}
-
-/* Gets the next "bytes" bytes, regardless of whether they are available in the
- * current buffer or not.  Returns a status code as described in decoder.int.h.
- */
-UPB_FORCEINLINE static int32_t getbytes(upb_pbdecoder *d, void *buf,
-                                        size_t bytes) {
-  if (curbufleft(d) >= bytes) {
-    /* Buffer has enough data to satisfy. */
-    consumebytes(d, buf, bytes);
-    return DECODE_OK;
-  } else {
-    return getbytes_slow(d, buf, bytes);
-  }
-}
-
-UPB_NOINLINE static size_t peekbytes_slow(upb_pbdecoder *d, void *buf,
-                                          size_t bytes) {
-  size_t ret = curbufleft(d);
-  memcpy(buf, d->ptr, ret);
-  if (in_residual_buf(d, d->ptr)) {
-    size_t copy = UPB_MIN(bytes - ret, d->size_param);
-    memcpy((char *)buf + ret, d->buf_param, copy);
-    ret += copy;
-  }
-  return ret;
-}
-
-UPB_FORCEINLINE static size_t peekbytes(upb_pbdecoder *d, void *buf,
-                                        size_t bytes) {
-  if (curbufleft(d) >= bytes) {
-    memcpy(buf, d->ptr, bytes);
-    return bytes;
-  } else {
-    return peekbytes_slow(d, buf, bytes);
-  }
-}
-
-
-/* Decoding of wire types *****************************************************/
-
-/* Slow path for decoding a varint from the current buffer position.
- * Returns a status code as described in decoder.int.h. */
-UPB_NOINLINE int32_t upb_pbdecoder_decode_varint_slow(upb_pbdecoder *d,
-                                                      uint64_t *u64) {
-  uint8_t byte = 0x80;
-  int bitpos;
-  *u64 = 0;
-  for(bitpos = 0; bitpos < 70 && (byte & 0x80); bitpos += 7) {
-    CHECK_RETURN(getbytes(d, &byte, 1));
-    *u64 |= (uint64_t)(byte & 0x7F) << bitpos;
-  }
-  if(bitpos == 70 && (byte & 0x80)) {
-    seterr(d, kUnterminatedVarint);
-    return (int32_t)upb_pbdecoder_suspend(d);
-  }
-  return DECODE_OK;
-}
-
-/* Decodes a varint from the current buffer position.
- * Returns a status code as described in decoder.int.h. */
-UPB_FORCEINLINE static int32_t decode_varint(upb_pbdecoder *d, uint64_t *u64) {
-  if (curbufleft(d) > 0 && !(*d->ptr & 0x80)) {
-    *u64 = *d->ptr;
-    advance(d, 1);
-    return DECODE_OK;
-  } else if (curbufleft(d) >= 10) {
-    /* Fast case. */
-    upb_decoderet r = upb_vdecode_fast(d->ptr);
-    if (r.p == NULL) {
-      seterr(d, kUnterminatedVarint);
-      return (int32_t)upb_pbdecoder_suspend(d);
-    }
-    advance(d, r.p - d->ptr);
-    *u64 = r.val;
-    return DECODE_OK;
-  } else {
-    /* Slow case -- varint spans buffer seam. */
-    return upb_pbdecoder_decode_varint_slow(d, u64);
-  }
-}
-
-/* Decodes a 32-bit varint from the current buffer position.
- * Returns a status code as described in decoder.int.h. */
-UPB_FORCEINLINE static int32_t decode_v32(upb_pbdecoder *d, uint32_t *u32) {
-  uint64_t u64;
-  int32_t ret = decode_varint(d, &u64);
-  if (ret >= 0) return ret;
-  if (u64 > UINT32_MAX) {
-    seterr(d, "Unterminated 32-bit varint");
-    /* TODO(haberman) guarantee that this function return is >= 0 somehow,
-     * so we know this path will always be treated as error by our caller.
-     * Right now the size_t -> int32_t can overflow and produce negative values.
-     */
-    *u32 = 0;
-    return (int32_t)upb_pbdecoder_suspend(d);
-  }
-  *u32 = (uint32_t)u64;
-  return DECODE_OK;
-}
-
-/* Decodes a fixed32 from the current buffer position.
- * Returns a status code as described in decoder.int.h.
- * TODO: proper byte swapping for big-endian machines. */
-UPB_FORCEINLINE static int32_t decode_fixed32(upb_pbdecoder *d, uint32_t *u32) {
-  return getbytes(d, u32, 4);
-}
-
-/* Decodes a fixed64 from the current buffer position.
- * Returns a status code as described in decoder.int.h.
- * TODO: proper byte swapping for big-endian machines. */
-UPB_FORCEINLINE static int32_t decode_fixed64(upb_pbdecoder *d, uint64_t *u64) {
-  return getbytes(d, u64, 8);
-}
-
-/* Non-static versions of the above functions.
- * These are called by the JIT for fallback paths. */
-int32_t upb_pbdecoder_decode_f32(upb_pbdecoder *d, uint32_t *u32) {
-  return decode_fixed32(d, u32);
-}
-
-int32_t upb_pbdecoder_decode_f64(upb_pbdecoder *d, uint64_t *u64) {
-  return decode_fixed64(d, u64);
-}
-
-static double as_double(uint64_t n) { double d; memcpy(&d, &n, 8); return d; }
-static float  as_float(uint32_t n)  { float  f; memcpy(&f, &n, 4); return f; }
-
-/* Pushes a frame onto the decoder stack. */
-static bool decoder_push(upb_pbdecoder *d, uint64_t end) {
-  upb_pbdecoder_frame *fr = d->top;
-
-  if (end > fr->end_ofs) {
-    seterr(d, kPbDecoderSubmessageTooLong);
-    return false;
-  } else if (fr == d->limit) {
-    seterr(d, kPbDecoderStackOverflow);
-    return false;
-  }
-
-  fr++;
-  fr->end_ofs = end;
-  fr->dispatch = NULL;
-  fr->groupnum = 0;
-  d->top = fr;
-  return true;
-}
-
-static bool pushtagdelim(upb_pbdecoder *d, uint32_t arg) {
-  /* While we expect to see an "end" tag (either ENDGROUP or a non-sequence
-   * field number) prior to hitting any enclosing submessage end, pushing our
-   * existing delim end prevents us from continuing to parse values from a
-   * corrupt proto that doesn't give us an END tag in time. */
-  if (!decoder_push(d, d->top->end_ofs))
-    return false;
-  d->top->groupnum = arg;
-  return true;
-}
-
-/* Pops a frame from the decoder stack. */
-static void decoder_pop(upb_pbdecoder *d) { d->top--; }
-
-UPB_NOINLINE int32_t upb_pbdecoder_checktag_slow(upb_pbdecoder *d,
-                                                 uint64_t expected) {
-  uint64_t data = 0;
-  size_t bytes = upb_value_size(expected);
-  size_t read = peekbytes(d, &data, bytes);
-  if (read == bytes && data == expected) {
-    /* Advance past matched bytes. */
-    int32_t ok = getbytes(d, &data, read);
-    UPB_ASSERT(ok < 0);
-    return DECODE_OK;
-  } else if (read < bytes && memcmp(&data, &expected, read) == 0) {
-    return (int32_t)suspend_save(d);
-  } else {
-    return DECODE_MISMATCH;
-  }
-}
-
-int32_t upb_pbdecoder_skipunknown(upb_pbdecoder *d, int32_t fieldnum,
-                                  uint8_t wire_type) {
-  if (fieldnum >= 0)
-    goto have_tag;
-
-  while (true) {
-    uint32_t tag;
-    CHECK_RETURN(decode_v32(d, &tag));
-    wire_type = tag & 0x7;
-    fieldnum = tag >> 3;
-
-have_tag:
-    if (fieldnum == 0) {
-      seterr(d, "Saw invalid field number (0)");
-      return (int32_t)upb_pbdecoder_suspend(d);
-    }
-
-    switch (wire_type) {
-      case UPB_WIRE_TYPE_32BIT:
-        CHECK_RETURN(skip(d, 4));
-        break;
-      case UPB_WIRE_TYPE_64BIT:
-        CHECK_RETURN(skip(d, 8));
-        break;
-      case UPB_WIRE_TYPE_VARINT: {
-        uint64_t u64;
-        CHECK_RETURN(decode_varint(d, &u64));
-        break;
-      }
-      case UPB_WIRE_TYPE_DELIMITED: {
-        uint32_t len;
-        CHECK_RETURN(decode_v32(d, &len));
-        CHECK_RETURN(skip(d, len));
-        break;
-      }
-      case UPB_WIRE_TYPE_START_GROUP:
-        if (!pushtagdelim(d, -fieldnum)) {
-          return (int32_t)upb_pbdecoder_suspend(d);
-        }
-        break;
-      case UPB_WIRE_TYPE_END_GROUP:
-        if (fieldnum == -d->top->groupnum) {
-          decoder_pop(d);
-        } else if (fieldnum == d->top->groupnum) {
-          return DECODE_ENDGROUP;
-        } else {
-          seterr(d, "Unmatched ENDGROUP tag.");
-          return (int32_t)upb_pbdecoder_suspend(d);
-        }
-        break;
-      default:
-        seterr(d, "Invalid wire type");
-        return (int32_t)upb_pbdecoder_suspend(d);
-    }
-
-    if (d->top->groupnum >= 0) {
-      /* TODO: More code needed for handling unknown groups. */
-      upb_sink_putunknown(d->top->sink, d->checkpoint, d->ptr - d->checkpoint);
-      return DECODE_OK;
-    }
-
-    /* Unknown group -- continue looping over unknown fields. */
-    checkpoint(d);
-  }
-}
-
-static void goto_endmsg(upb_pbdecoder *d) {
-  upb_value v;
-  bool found = upb_inttable_lookup32(d->top->dispatch, DISPATCH_ENDMSG, &v);
-  UPB_ASSERT(found);
-  d->pc = d->top->base + upb_value_getuint64(v);
-}
-
-/* Parses a tag and jumps to the corresponding bytecode instruction for this
- * field.
- *
- * If the tag is unknown (or the wire type doesn't match), parses the field as
- * unknown.  If the tag is a valid ENDGROUP tag, jumps to the bytecode
- * instruction for the end of message. */
-static int32_t dispatch(upb_pbdecoder *d) {
-  upb_inttable *dispatch = d->top->dispatch;
-  uint32_t tag;
-  uint8_t wire_type;
-  uint32_t fieldnum;
-  upb_value val;
-  int32_t retval;
-
-  /* Decode tag. */
-  CHECK_RETURN(decode_v32(d, &tag));
-  wire_type = tag & 0x7;
-  fieldnum = tag >> 3;
-
-  /* Lookup tag.  Because of packed/non-packed compatibility, we have to
-   * check the wire type against two possibilities. */
-  if (fieldnum != DISPATCH_ENDMSG &&
-      upb_inttable_lookup32(dispatch, fieldnum, &val)) {
-    uint64_t v = upb_value_getuint64(val);
-    if (wire_type == (v & 0xff)) {
-      d->pc = d->top->base + (v >> 16);
-      return DECODE_OK;
-    } else if (wire_type == ((v >> 8) & 0xff)) {
-      bool found =
-          upb_inttable_lookup(dispatch, fieldnum + UPB_MAX_FIELDNUMBER, &val);
-      UPB_ASSERT(found);
-      d->pc = d->top->base + upb_value_getuint64(val);
-      return DECODE_OK;
-    }
-  }
-
-  /* We have some unknown fields (or ENDGROUP) to parse.  The DISPATCH or TAG
-   * bytecode that triggered this is preceded by a CHECKDELIM bytecode which
-   * we need to back up to, so that when we're done skipping unknown data we
-   * can re-check the delimited end. */
-  d->last--;  /* Necessary if we get suspended */
-  d->pc = d->last;
-  UPB_ASSERT(getop(*d->last) == OP_CHECKDELIM);
-
-  /* Unknown field or ENDGROUP. */
-  retval = upb_pbdecoder_skipunknown(d, fieldnum, wire_type);
-
-  CHECK_RETURN(retval);
-
-  if (retval == DECODE_ENDGROUP) {
-    goto_endmsg(d);
-    return DECODE_OK;
-  }
-
-  return DECODE_OK;
-}
-
-/* Callers know that the stack is more than one deep because the opcodes that
- * call this only occur after PUSH operations. */
-upb_pbdecoder_frame *outer_frame(upb_pbdecoder *d) {
-  UPB_ASSERT(d->top != d->stack);
-  return d->top - 1;
-}
-
-
-/* The main decoding loop *****************************************************/
-
-/* The main decoder VM function.  Uses traditional bytecode dispatch loop with a
- * switch() statement. */
-size_t run_decoder_vm(upb_pbdecoder *d, const mgroup *group,
-                      const upb_bufhandle* handle) {
-
-#define VMCASE(op, code) \
-  case op: { code; if (consumes_input(op)) checkpoint(d); break; }
-#define PRIMITIVE_OP(type, wt, name, convfunc, ctype) \
-  VMCASE(OP_PARSE_ ## type, { \
-    ctype val; \
-    CHECK_RETURN(decode_ ## wt(d, &val)); \
-    upb_sink_put ## name(d->top->sink, arg, (convfunc)(val)); \
-  })
-
-  while(1) {
-    int32_t instruction;
-    opcode op;
-    uint32_t arg;
-    int32_t longofs;
-
-    d->last = d->pc;
-    instruction = *d->pc++;
-    op = getop(instruction);
-    arg = instruction >> 8;
-    longofs = arg;
-    UPB_ASSERT(d->ptr != d->residual_end);
-    UPB_UNUSED(group);
-#ifdef UPB_DUMP_BYTECODE
-    fprintf(stderr, "s_ofs=%d buf_ofs=%d data_rem=%d buf_rem=%d delim_rem=%d "
-                    "%x %s (%d)\n",
-            (int)offset(d),
-            (int)(d->ptr - d->buf),
-            (int)(d->data_end - d->ptr),
-            (int)(d->end - d->ptr),
-            (int)((d->top->end_ofs - d->bufstart_ofs) - (d->ptr - d->buf)),
-            (int)(d->pc - 1 - group->bytecode),
-            upb_pbdecoder_getopname(op),
-            arg);
-#endif
-    switch (op) {
-      /* Technically, we are losing data if we see a 32-bit varint that is not
-       * properly sign-extended.  We could detect this and error about the data
-       * loss, but proto2 does not do this, so we pass. */
-      PRIMITIVE_OP(INT32,    varint,  int32,  int32_t,      uint64_t)
-      PRIMITIVE_OP(INT64,    varint,  int64,  int64_t,      uint64_t)
-      PRIMITIVE_OP(UINT32,   varint,  uint32, uint32_t,     uint64_t)
-      PRIMITIVE_OP(UINT64,   varint,  uint64, uint64_t,     uint64_t)
-      PRIMITIVE_OP(FIXED32,  fixed32, uint32, uint32_t,     uint32_t)
-      PRIMITIVE_OP(FIXED64,  fixed64, uint64, uint64_t,     uint64_t)
-      PRIMITIVE_OP(SFIXED32, fixed32, int32,  int32_t,      uint32_t)
-      PRIMITIVE_OP(SFIXED64, fixed64, int64,  int64_t,      uint64_t)
-      PRIMITIVE_OP(BOOL,     varint,  bool,   bool,         uint64_t)
-      PRIMITIVE_OP(DOUBLE,   fixed64, double, as_double,    uint64_t)
-      PRIMITIVE_OP(FLOAT,    fixed32, float,  as_float,     uint32_t)
-      PRIMITIVE_OP(SINT32,   varint,  int32,  upb_zzdec_32, uint64_t)
-      PRIMITIVE_OP(SINT64,   varint,  int64,  upb_zzdec_64, uint64_t)
-
-      VMCASE(OP_SETDISPATCH,
-        d->top->base = d->pc - 1;
-        memcpy(&d->top->dispatch, d->pc, sizeof(void*));
-        d->pc += sizeof(void*) / sizeof(uint32_t);
-      )
-      VMCASE(OP_STARTMSG,
-        CHECK_SUSPEND(upb_sink_startmsg(d->top->sink));
-      )
-      VMCASE(OP_ENDMSG,
-        CHECK_SUSPEND(upb_sink_endmsg(d->top->sink, d->status));
-      )
-      VMCASE(OP_STARTSEQ,
-        upb_pbdecoder_frame *outer = outer_frame(d);
-        CHECK_SUSPEND(upb_sink_startseq(outer->sink, arg, &d->top->sink));
-      )
-      VMCASE(OP_ENDSEQ,
-        CHECK_SUSPEND(upb_sink_endseq(d->top->sink, arg));
-      )
-      VMCASE(OP_STARTSUBMSG,
-        upb_pbdecoder_frame *outer = outer_frame(d);
-        CHECK_SUSPEND(upb_sink_startsubmsg(outer->sink, arg, &d->top->sink));
-      )
-      VMCASE(OP_ENDSUBMSG,
-        upb_sink subsink = (d->top + 1)->sink;
-        CHECK_SUSPEND(upb_sink_endsubmsg(d->top->sink, subsink, arg));
-      )
-      VMCASE(OP_STARTSTR,
-        uint32_t len = (uint32_t)delim_remaining(d);
-        upb_pbdecoder_frame *outer = outer_frame(d);
-        CHECK_SUSPEND(upb_sink_startstr(outer->sink, arg, len, &d->top->sink));
-        if (len == 0) {
-          d->pc++;  /* Skip OP_STRING. */
-        }
-      )
-      VMCASE(OP_STRING,
-        uint32_t len = (uint32_t)curbufleft(d);
-        size_t n = upb_sink_putstring(d->top->sink, arg, d->ptr, len, handle);
-        if (n > len) {
-          if (n > delim_remaining(d)) {
-            seterr(d, "Tried to skip past end of string.");
-            return upb_pbdecoder_suspend(d);
-          } else {
-            int32_t ret = skip(d, n);
-            /* This shouldn't return DECODE_OK, because n > len. */
-            UPB_ASSERT(ret >= 0);
-            return ret;
-          }
-        }
-        advance(d, n);
-        if (n < len || d->delim_end == NULL) {
-          /* We aren't finished with this string yet. */
-          d->pc--;  /* Repeat OP_STRING. */
-          if (n > 0) checkpoint(d);
-          return upb_pbdecoder_suspend(d);
-        }
-      )
-      VMCASE(OP_ENDSTR,
-        CHECK_SUSPEND(upb_sink_endstr(d->top->sink, arg));
-      )
-      VMCASE(OP_PUSHTAGDELIM,
-        CHECK_SUSPEND(pushtagdelim(d, arg));
-      )
-      VMCASE(OP_SETBIGGROUPNUM,
-        d->top->groupnum = *d->pc++;
-      )
-      VMCASE(OP_POP,
-        UPB_ASSERT(d->top > d->stack);
-        decoder_pop(d);
-      )
-      VMCASE(OP_PUSHLENDELIM,
-        uint32_t len;
-        CHECK_RETURN(decode_v32(d, &len));
-        CHECK_SUSPEND(decoder_push(d, offset(d) + len));
-        set_delim_end(d);
-      )
-      VMCASE(OP_SETDELIM,
-        set_delim_end(d);
-      )
-      VMCASE(OP_CHECKDELIM,
-        /* We are guaranteed of this assert because we never allow ourselves to
-         * consume bytes beyond data_end, which covers delim_end when non-NULL.
-         */
-        UPB_ASSERT(!(d->delim_end && d->ptr > d->delim_end));
-        if (d->ptr == d->delim_end)
-          d->pc += longofs;
-      )
-      VMCASE(OP_CALL,
-        d->callstack[d->call_len++] = d->pc;
-        d->pc += longofs;
-      )
-      VMCASE(OP_RET,
-        UPB_ASSERT(d->call_len > 0);
-        d->pc = d->callstack[--d->call_len];
-      )
-      VMCASE(OP_BRANCH,
-        d->pc += longofs;
-      )
-      VMCASE(OP_TAG1,
-        uint8_t expected;
-        CHECK_SUSPEND(curbufleft(d) > 0);
-        expected = (arg >> 8) & 0xff;
-        if (*d->ptr == expected) {
-          advance(d, 1);
-        } else {
-          int8_t shortofs;
-         badtag:
-          shortofs = arg;
-          if (shortofs == LABEL_DISPATCH) {
-            CHECK_RETURN(dispatch(d));
-          } else {
-            d->pc += shortofs;
-            break; /* Avoid checkpoint(). */
-          }
-        }
-      )
-      VMCASE(OP_TAG2,
-        uint16_t expected;
-        CHECK_SUSPEND(curbufleft(d) > 0);
-        expected = (arg >> 8) & 0xffff;
-        if (curbufleft(d) >= 2) {
-          uint16_t actual;
-          memcpy(&actual, d->ptr, 2);
-          if (expected == actual) {
-            advance(d, 2);
-          } else {
-            goto badtag;
-          }
-        } else {
-          int32_t result = upb_pbdecoder_checktag_slow(d, expected);
-          if (result == DECODE_MISMATCH) goto badtag;
-          if (result >= 0) return result;
-        }
-      )
-      VMCASE(OP_TAGN, {
-        uint64_t expected;
-        int32_t result;
-        memcpy(&expected, d->pc, 8);
-        d->pc += 2;
-        result = upb_pbdecoder_checktag_slow(d, expected);
-        if (result == DECODE_MISMATCH) goto badtag;
-        if (result >= 0) return result;
-      })
-      VMCASE(OP_DISPATCH, {
-        CHECK_RETURN(dispatch(d));
-      })
-      VMCASE(OP_HALT, {
-        return d->size_param;
-      })
-    }
-  }
-}
-
-
-/* BytesHandler handlers ******************************************************/
-
-void *upb_pbdecoder_startbc(void *closure, const void *pc, size_t size_hint) {
-  upb_pbdecoder *d = closure;
-  UPB_UNUSED(size_hint);
-  d->top->end_ofs = UINT64_MAX;
-  d->bufstart_ofs = 0;
-  d->call_len = 1;
-  d->callstack[0] = &halt;
-  d->pc = pc;
-  d->skip = 0;
-  return d;
-}
-
-bool upb_pbdecoder_end(void *closure, const void *handler_data) {
-  upb_pbdecoder *d = closure;
-  const upb_pbdecodermethod *method = handler_data;
-  uint64_t end;
-  char dummy;
-
-  if (d->residual_end > d->residual) {
-    seterr(d, "Unexpected EOF: decoder still has buffered unparsed data");
-    return false;
-  }
-
-  if (d->skip) {
-    seterr(d, "Unexpected EOF inside skipped data");
-    return false;
-  }
-
-  if (d->top->end_ofs != UINT64_MAX) {
-    seterr(d, "Unexpected EOF inside delimited string");
-    return false;
-  }
-
-  /* The user's end() call indicates that the message ends here. */
-  end = offset(d);
-  d->top->end_ofs = end;
-
-  {
-    const uint32_t *p = d->pc;
-    d->stack->end_ofs = end;
-    /* Check the previous bytecode, but guard against beginning. */
-    if (p != method->code_base.ptr) p--;
-    if (getop(*p) == OP_CHECKDELIM) {
-      /* Rewind from OP_TAG* to OP_CHECKDELIM. */
-      UPB_ASSERT(getop(*d->pc) == OP_TAG1 ||
-             getop(*d->pc) == OP_TAG2 ||
-             getop(*d->pc) == OP_TAGN ||
-             getop(*d->pc) == OP_DISPATCH);
-      d->pc = p;
-    }
-    upb_pbdecoder_decode(closure, handler_data, &dummy, 0, NULL);
-  }
-
-  if (d->call_len != 0) {
-    seterr(d, "Unexpected EOF inside submessage or group");
-    return false;
-  }
-
-  return true;
-}
-
-size_t upb_pbdecoder_decode(void *decoder, const void *group, const char *buf,
-                            size_t size, const upb_bufhandle *handle) {
-  int32_t result = upb_pbdecoder_resume(decoder, NULL, buf, size, handle);
-
-  if (result == DECODE_ENDGROUP) goto_endmsg(decoder);
-  CHECK_RETURN(result);
-
-  return run_decoder_vm(decoder, group, handle);
-}
-
-
-/* Public API *****************************************************************/
-
-void upb_pbdecoder_reset(upb_pbdecoder *d) {
-  d->top = d->stack;
-  d->top->groupnum = 0;
-  d->ptr = d->residual;
-  d->buf = d->residual;
-  d->end = d->residual;
-  d->residual_end = d->residual;
-}
-
-upb_pbdecoder *upb_pbdecoder_create(upb_arena *a, const upb_pbdecodermethod *m,
-                                    upb_sink sink, upb_status *status) {
-  const size_t default_max_nesting = 64;
-
-  upb_pbdecoder *d = upb_arena_malloc(a, sizeof(upb_pbdecoder));
-  if (!d) return NULL;
-
-  d->method_ = m;
-  d->callstack = upb_arena_malloc(a, callstacksize(d, default_max_nesting));
-  d->stack = upb_arena_malloc(a, stacksize(d, default_max_nesting));
-  if (!d->stack || !d->callstack) {
-    return NULL;
-  }
-
-  d->arena = a;
-  d->limit = d->stack + default_max_nesting - 1;
-  d->stack_size = default_max_nesting;
-  d->status = status;
-
-  upb_pbdecoder_reset(d);
-  upb_bytessink_reset(&d->input_, &m->input_handler_, d);
-
-  if (d->method_->dest_handlers_) {
-    if (sink.handlers != d->method_->dest_handlers_)
-      return NULL;
-  }
-  d->top->sink = sink;
-
-  return d;
-}
-
-uint64_t upb_pbdecoder_bytesparsed(const upb_pbdecoder *d) {
-  return offset(d);
-}
-
-const upb_pbdecodermethod *upb_pbdecoder_method(const upb_pbdecoder *d) {
-  return d->method_;
-}
-
-upb_bytessink upb_pbdecoder_input(upb_pbdecoder *d) {
-  return d->input_;
-}
-
-size_t upb_pbdecoder_maxnesting(const upb_pbdecoder *d) {
-  return d->stack_size;
-}
-
-bool upb_pbdecoder_setmaxnesting(upb_pbdecoder *d, size_t max) {
-  UPB_ASSERT(d->top >= d->stack);
-
-  if (max < (size_t)(d->top - d->stack)) {
-    /* Can't set a limit smaller than what we are currently at. */
-    return false;
-  }
-
-  if (max > d->stack_size) {
-    /* Need to reallocate stack and callstack to accommodate. */
-    size_t old_size = stacksize(d, d->stack_size);
-    size_t new_size = stacksize(d, max);
-    void *p = upb_arena_realloc(d->arena, d->stack, old_size, new_size);
-    if (!p) {
-      return false;
-    }
-    d->stack = p;
-
-    old_size = callstacksize(d, d->stack_size);
-    new_size = callstacksize(d, max);
-    p = upb_arena_realloc(d->arena, d->callstack, old_size, new_size);
-    if (!p) {
-      return false;
-    }
-    d->callstack = p;
-
-    d->stack_size = max;
-  }
-
-  d->limit = d->stack + max - 1;
-  return true;
-}
diff --git a/third_party/upb/upb/pb/decoder.h b/third_party/upb/upb/pb/decoder.h
deleted file mode 100644 (file)
index 8c4d8bf..0000000
+++ /dev/null
@@ -1,242 +0,0 @@
-/*
-** upb::pb::Decoder
-**
-** A high performance, streaming, resumable decoder for the binary protobuf
-** format.
-**
-** This interface works the same regardless of what decoder backend is being
-** used.  A client of this class does not need to know whether decoding is using
-** a JITted decoder (DynASM, LLVM, etc) or an interpreted decoder.  By default,
-** it will always use the fastest available decoder.  However, you can call
-** set_allow_jit(false) to disable any JIT decoder that might be available.
-** This is primarily useful for testing purposes.
-*/
-
-#ifndef UPB_DECODER_H_
-#define UPB_DECODER_H_
-
-#include "upb/sink.h"
-
-#ifdef __cplusplus
-namespace upb {
-namespace pb {
-class CodeCache;
-class DecoderPtr;
-class DecoderMethodPtr;
-class DecoderMethodOptions;
-}  /* namespace pb */
-}  /* namespace upb */
-#endif
-
-/* The maximum number of bytes we are required to buffer internally between
- * calls to the decoder.  The value is 14: a 5 byte unknown tag plus ten-byte
- * varint, less one because we are buffering an incomplete value.
- *
- * Should only be used by unit tests. */
-#define UPB_DECODER_MAX_RESIDUAL_BYTES 14
-
-/* upb_pbdecodermethod ********************************************************/
-
-struct upb_pbdecodermethod;
-typedef struct upb_pbdecodermethod upb_pbdecodermethod;
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-const upb_handlers *upb_pbdecodermethod_desthandlers(
-    const upb_pbdecodermethod *m);
-const upb_byteshandler *upb_pbdecodermethod_inputhandler(
-    const upb_pbdecodermethod *m);
-bool upb_pbdecodermethod_isnative(const upb_pbdecodermethod *m);
-
-#ifdef __cplusplus
-}  /* extern "C" */
-
-/* Represents the code to parse a protobuf according to a destination
- * Handlers. */
-class upb::pb::DecoderMethodPtr {
- public:
-  DecoderMethodPtr() : ptr_(nullptr) {}
-  DecoderMethodPtr(const upb_pbdecodermethod* ptr) : ptr_(ptr) {}
-
-  const upb_pbdecodermethod* ptr() { return ptr_; }
-
-  /* The destination handlers that are statically bound to this method.
-   * This method is only capable of outputting to a sink that uses these
-   * handlers. */
-  const Handlers *dest_handlers() const {
-    return upb_pbdecodermethod_desthandlers(ptr_);
-  }
-
-  /* The input handlers for this decoder method. */
-  const BytesHandler* input_handler() const {
-    return upb_pbdecodermethod_inputhandler(ptr_);
-  }
-
-  /* Whether this method is native. */
-  bool is_native() const {
-    return upb_pbdecodermethod_isnative(ptr_);
-  }
-
- private:
-  const upb_pbdecodermethod* ptr_;
-};
-
-#endif
-
-/* upb_pbdecoder **************************************************************/
-
-/* Preallocation hint: decoder won't allocate more bytes than this when first
- * constructed.  This hint may be an overestimate for some build configurations.
- * But if the decoder library is upgraded without recompiling the application,
- * it may be an underestimate. */
-#define UPB_PB_DECODER_SIZE 4416
-
-struct upb_pbdecoder;
-typedef struct upb_pbdecoder upb_pbdecoder;
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-upb_pbdecoder *upb_pbdecoder_create(upb_arena *arena,
-                                    const upb_pbdecodermethod *method,
-                                    upb_sink output, upb_status *status);
-const upb_pbdecodermethod *upb_pbdecoder_method(const upb_pbdecoder *d);
-upb_bytessink upb_pbdecoder_input(upb_pbdecoder *d);
-uint64_t upb_pbdecoder_bytesparsed(const upb_pbdecoder *d);
-size_t upb_pbdecoder_maxnesting(const upb_pbdecoder *d);
-bool upb_pbdecoder_setmaxnesting(upb_pbdecoder *d, size_t max);
-void upb_pbdecoder_reset(upb_pbdecoder *d);
-
-#ifdef __cplusplus
-}  /* extern "C" */
-
-/* A Decoder receives binary protobuf data on its input sink and pushes the
- * decoded data to its output sink. */
-class upb::pb::DecoderPtr {
- public:
-  DecoderPtr() : ptr_(nullptr) {}
-  DecoderPtr(upb_pbdecoder* ptr) : ptr_(ptr) {}
-
-  upb_pbdecoder* ptr() { return ptr_; }
-
-  /* Constructs a decoder instance for the given method, which must outlive this
-   * decoder.  Any errors during parsing will be set on the given status, which
-   * must also outlive this decoder.
-   *
-   * The sink must match the given method. */
-  static DecoderPtr Create(Arena *arena, DecoderMethodPtr method,
-                           upb::Sink output, Status *status) {
-    return DecoderPtr(upb_pbdecoder_create(arena->ptr(), method.ptr(),
-                                           output.sink(), status->ptr()));
-  }
-
-  /* Returns the DecoderMethod this decoder is parsing from. */
-  const DecoderMethodPtr method() const {
-    return DecoderMethodPtr(upb_pbdecoder_method(ptr_));
-  }
-
-  /* The sink on which this decoder receives input. */
-  BytesSink input() { return BytesSink(upb_pbdecoder_input(ptr())); }
-
-  /* Returns number of bytes successfully parsed.
-   *
-   * This can be useful for determining the stream position where an error
-   * occurred.
-   *
-   * This value may not be up-to-date when called from inside a parsing
-   * callback. */
-  uint64_t BytesParsed() { return upb_pbdecoder_bytesparsed(ptr()); }
-
-  /* Gets/sets the parsing nexting limit.  If the total number of nested
-   * submessages and repeated fields hits this limit, parsing will fail.  This
-   * is a resource limit that controls the amount of memory used by the parsing
-   * stack.
-   *
-   * Setting the limit will fail if the parser is currently suspended at a depth
-   * greater than this, or if memory allocation of the stack fails. */
-  size_t max_nesting() { return upb_pbdecoder_maxnesting(ptr()); }
-  bool set_max_nesting(size_t max) {
-    return upb_pbdecoder_setmaxnesting(ptr(), max);
-  }
-
-  void Reset() { upb_pbdecoder_reset(ptr()); }
-
-  static const size_t kSize = UPB_PB_DECODER_SIZE;
-
- private:
-  upb_pbdecoder *ptr_;
-};
-
-#endif  /* __cplusplus */
-
-/* upb_pbcodecache ************************************************************/
-
-/* Lazily builds and caches decoder methods that will push data to the given
- * handlers.  The destination handlercache must outlive this object. */
-
-struct upb_pbcodecache;
-typedef struct upb_pbcodecache upb_pbcodecache;
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-upb_pbcodecache *upb_pbcodecache_new(upb_handlercache *dest);
-void upb_pbcodecache_free(upb_pbcodecache *c);
-bool upb_pbcodecache_allowjit(const upb_pbcodecache *c);
-void upb_pbcodecache_setallowjit(upb_pbcodecache *c, bool allow);
-void upb_pbcodecache_setlazy(upb_pbcodecache *c, bool lazy);
-const upb_pbdecodermethod *upb_pbcodecache_get(upb_pbcodecache *c,
-                                               const upb_msgdef *md);
-
-#ifdef __cplusplus
-}  /* extern "C" */
-
-/* A class for caching protobuf processing code, whether bytecode for the
- * interpreted decoder or machine code for the JIT.
- *
- * This class is not thread-safe. */
-class upb::pb::CodeCache {
- public:
-  CodeCache(upb::HandlerCache *dest)
-      : ptr_(upb_pbcodecache_new(dest->ptr()), upb_pbcodecache_free) {}
-  CodeCache(CodeCache&&) = default;
-  CodeCache& operator=(CodeCache&&) = default;
-
-  upb_pbcodecache* ptr() { return ptr_.get(); }
-  const upb_pbcodecache* ptr() const { return ptr_.get(); }
-
-  /* Whether the cache is allowed to generate machine code.  Defaults to true.
-   * There is no real reason to turn it off except for testing or if you are
-   * having a specific problem with the JIT.
-   *
-   * Note that allow_jit = true does not *guarantee* that the code will be JIT
-   * compiled.  If this platform is not supported or the JIT was not compiled
-   * in, the code may still be interpreted. */
-  bool allow_jit() const { return upb_pbcodecache_allowjit(ptr()); }
-
-  /* This may only be called when the object is first constructed, and prior to
-   * any code generation. */
-  void set_allow_jit(bool allow) { upb_pbcodecache_setallowjit(ptr(), allow); }
-
-  /* Should the decoder push submessages to lazy handlers for fields that have
-   * them?  The caller should set this iff the lazy handlers expect data that is
-   * in protobuf binary format and the caller wishes to lazy parse it. */
-  void set_lazy(bool lazy) { upb_pbcodecache_setlazy(ptr(), lazy); }
-
-  /* Returns a DecoderMethod that can push data to the given handlers.
-   * If a suitable method already exists, it will be returned from the cache. */
-  const DecoderMethodPtr Get(MessageDefPtr md) {
-    return DecoderMethodPtr(upb_pbcodecache_get(ptr(), md.ptr()));
-  }
-
- private:
-  std::unique_ptr<upb_pbcodecache, decltype(&upb_pbcodecache_free)> ptr_;
-};
-
-#endif  /* __cplusplus */
-
-#endif  /* UPB_DECODER_H_ */
diff --git a/third_party/upb/upb/pb/decoder.int.h b/third_party/upb/upb/pb/decoder.int.h
deleted file mode 100644 (file)
index 9d5f583..0000000
+++ /dev/null
@@ -1,288 +0,0 @@
-/*
-** Internal-only definitions for the decoder.
-*/
-
-#ifndef UPB_DECODER_INT_H_
-#define UPB_DECODER_INT_H_
-
-#include "upb/def.h"
-#include "upb/handlers.h"
-#include "upb/pb/decoder.h"
-#include "upb/sink.h"
-#include "upb/table.int.h"
-
-#include "upb/port_def.inc"
-
-/* Opcode definitions.  The canonical meaning of each opcode is its
- * implementation in the interpreter (the JIT is written to match this).
- *
- * All instructions have the opcode in the low byte.
- * Instruction format for most instructions is:
- *
- * +-------------------+--------+
- * |     arg (24)      | op (8) |
- * +-------------------+--------+
- *
- * Exceptions are indicated below.  A few opcodes are multi-word. */
-typedef enum {
-  /* Opcodes 1-8, 13, 15-18 parse their respective descriptor types.
-   * Arg for all of these is the upb selector for this field. */
-#define T(type) OP_PARSE_ ## type = UPB_DESCRIPTOR_TYPE_ ## type
-  T(DOUBLE), T(FLOAT), T(INT64), T(UINT64), T(INT32), T(FIXED64), T(FIXED32),
-  T(BOOL), T(UINT32), T(SFIXED32), T(SFIXED64), T(SINT32), T(SINT64),
-#undef T
-  OP_STARTMSG       = 9,   /* No arg. */
-  OP_ENDMSG         = 10,  /* No arg. */
-  OP_STARTSEQ       = 11,
-  OP_ENDSEQ         = 12,
-  OP_STARTSUBMSG    = 14,
-  OP_ENDSUBMSG      = 19,
-  OP_STARTSTR       = 20,
-  OP_STRING         = 21,
-  OP_ENDSTR         = 22,
-
-  OP_PUSHTAGDELIM   = 23,  /* No arg. */
-  OP_PUSHLENDELIM   = 24,  /* No arg. */
-  OP_POP            = 25,  /* No arg. */
-  OP_SETDELIM       = 26,  /* No arg. */
-  OP_SETBIGGROUPNUM = 27,  /* two words:
-                            *   | unused (24)     | opc (8) |
-                            *   |        groupnum (32)      | */
-  OP_CHECKDELIM     = 28,
-  OP_CALL           = 29,
-  OP_RET            = 30,
-  OP_BRANCH         = 31,
-
-  /* Different opcodes depending on how many bytes expected. */
-  OP_TAG1           = 32,  /* | match tag (16) | jump target (8) | opc (8) | */
-  OP_TAG2           = 33,  /* | match tag (16) | jump target (8) | opc (8) | */
-  OP_TAGN           = 34,  /* three words: */
-                           /*   | unused (16) | jump target(8) | opc (8) | */
-                           /*   |           match tag 1 (32)             | */
-                           /*   |           match tag 2 (32)             | */
-
-  OP_SETDISPATCH    = 35,  /* N words: */
-                           /*   | unused (24)         | opc | */
-                           /*   | upb_inttable* (32 or 64)  | */
-
-  OP_DISPATCH       = 36,  /* No arg. */
-
-  OP_HALT           = 37   /* No arg. */
-} opcode;
-
-#define OP_MAX OP_HALT
-
-UPB_INLINE opcode getop(uint32_t instr) { return (opcode)(instr & 0xff); }
-
-struct upb_pbcodecache {
-  upb_arena *arena;
-  upb_handlercache *dest;
-  bool allow_jit;
-  bool lazy;
-
-  /* Map of upb_msgdef -> mgroup. */
-  upb_inttable groups;
-};
-
-/* Method group; represents a set of decoder methods that had their code
- * emitted together.  Immutable once created.  */
-typedef struct {
-  /* Maps upb_msgdef/upb_handlers -> upb_pbdecodermethod.  Owned by us.
-   *
-   * Ideally this would be on pbcodecache (if we were actually caching code).
-   * Right now we don't actually cache anything, which is wasteful. */
-  upb_inttable methods;
-
-  /* The bytecode for our methods, if any exists.  Owned by us. */
-  uint32_t *bytecode;
-  uint32_t *bytecode_end;
-} mgroup;
-
-/* The maximum that any submessages can be nested.  Matches proto2's limit.
- * This specifies the size of the decoder's statically-sized array and therefore
- * setting it high will cause the upb::pb::Decoder object to be larger.
- *
- * If necessary we can add a runtime-settable property to Decoder that allow
- * this to be larger than the compile-time setting, but this would add
- * complexity, particularly since we would have to decide how/if to give users
- * the ability to set a custom memory allocation function. */
-#define UPB_DECODER_MAX_NESTING 64
-
-/* Internal-only struct used by the decoder. */
-typedef struct {
-  /* Space optimization note: we store two pointers here that the JIT
-   * doesn't need at all; the upb_handlers* inside the sink and
-   * the dispatch table pointer.  We can optimze so that the JIT uses
-   * smaller stack frames than the interpreter.  The only thing we need
-   * to guarantee is that the fallback routines can find end_ofs. */
-  upb_sink sink;
-
-  /* The absolute stream offset of the end-of-frame delimiter.
-   * Non-delimited frames (groups and non-packed repeated fields) reuse the
-   * delimiter of their parent, even though the frame may not end there.
-   *
-   * NOTE: the JIT stores a slightly different value here for non-top frames.
-   * It stores the value relative to the end of the enclosed message.  But the
-   * top frame is still stored the same way, which is important for ensuring
-   * that calls from the JIT into C work correctly. */
-  uint64_t end_ofs;
-  const uint32_t *base;
-
-  /* 0 indicates a length-delimited field.
-   * A positive number indicates a known group.
-   * A negative number indicates an unknown group. */
-  int32_t groupnum;
-  upb_inttable *dispatch;  /* Not used by the JIT. */
-} upb_pbdecoder_frame;
-
-struct upb_pbdecodermethod {
-  /* While compiling, the base is relative in "ofs", after compiling it is
-   * absolute in "ptr". */
-  union {
-    uint32_t ofs;     /* PC offset of method. */
-    void *ptr;        /* Pointer to bytecode or machine code for this method. */
-  } code_base;
-
-  /* The decoder method group to which this method belongs. */
-  const mgroup *group;
-
-  /* Whether this method is native code or bytecode. */
-  bool is_native_;
-
-  /* The handler one calls to invoke this method. */
-  upb_byteshandler input_handler_;
-
-  /* The destination handlers this method is bound to.  We own a ref. */
-  const upb_handlers *dest_handlers_;
-
-  /* Dispatch table -- used by both bytecode decoder and JIT when encountering a
-   * field number that wasn't the one we were expecting to see.  See
-   * decoder.int.h for the layout of this table. */
-  upb_inttable dispatch;
-};
-
-struct upb_pbdecoder {
-  upb_arena *arena;
-
-  /* Our input sink. */
-  upb_bytessink input_;
-
-  /* The decoder method we are parsing with (owned). */
-  const upb_pbdecodermethod *method_;
-
-  size_t call_len;
-  const uint32_t *pc, *last;
-
-  /* Current input buffer and its stream offset. */
-  const char *buf, *ptr, *end, *checkpoint;
-
-  /* End of the delimited region, relative to ptr, NULL if not in this buf. */
-  const char *delim_end;
-
-  /* End of the delimited region, relative to ptr, end if not in this buf. */
-  const char *data_end;
-
-  /* Overall stream offset of "buf." */
-  uint64_t bufstart_ofs;
-
-  /* Buffer for residual bytes not parsed from the previous buffer. */
-  char residual[UPB_DECODER_MAX_RESIDUAL_BYTES];
-  char *residual_end;
-
-  /* Bytes of data that should be discarded from the input beore we start
-   * parsing again.  We set this when we internally determine that we can
-   * safely skip the next N bytes, but this region extends past the current
-   * user buffer. */
-  size_t skip;
-
-  /* Stores the user buffer passed to our decode function. */
-  const char *buf_param;
-  size_t size_param;
-  const upb_bufhandle *handle;
-
-  /* Our internal stack. */
-  upb_pbdecoder_frame *stack, *top, *limit;
-  const uint32_t **callstack;
-  size_t stack_size;
-
-  upb_status *status;
-};
-
-/* Decoder entry points; used as handlers. */
-void *upb_pbdecoder_startbc(void *closure, const void *pc, size_t size_hint);
-size_t upb_pbdecoder_decode(void *closure, const void *hd, const char *buf,
-                            size_t size, const upb_bufhandle *handle);
-bool upb_pbdecoder_end(void *closure, const void *handler_data);
-
-/* Decoder-internal functions that the JIT calls to handle fallback paths. */
-int32_t upb_pbdecoder_resume(upb_pbdecoder *d, void *p, const char *buf,
-                             size_t size, const upb_bufhandle *handle);
-size_t upb_pbdecoder_suspend(upb_pbdecoder *d);
-int32_t upb_pbdecoder_skipunknown(upb_pbdecoder *d, int32_t fieldnum,
-                                  uint8_t wire_type);
-int32_t upb_pbdecoder_checktag_slow(upb_pbdecoder *d, uint64_t expected);
-int32_t upb_pbdecoder_decode_varint_slow(upb_pbdecoder *d, uint64_t *u64);
-int32_t upb_pbdecoder_decode_f32(upb_pbdecoder *d, uint32_t *u32);
-int32_t upb_pbdecoder_decode_f64(upb_pbdecoder *d, uint64_t *u64);
-void upb_pbdecoder_seterr(upb_pbdecoder *d, const char *msg);
-
-/* Error messages that are shared between the bytecode and JIT decoders. */
-extern const char *kPbDecoderStackOverflow;
-extern const char *kPbDecoderSubmessageTooLong;
-
-/* Access to decoderplan members needed by the decoder. */
-const char *upb_pbdecoder_getopname(unsigned int op);
-
-/* A special label that means "do field dispatch for this message and branch to
- * wherever that takes you." */
-#define LABEL_DISPATCH 0
-
-/* A special slot in the dispatch table that stores the epilogue (ENDMSG and/or
- * RET) for branching to when we find an appropriate ENDGROUP tag. */
-#define DISPATCH_ENDMSG 0
-
-/* It's important to use this invalid wire type instead of 0 (which is a valid
- * wire type). */
-#define NO_WIRE_TYPE 0xff
-
-/* The dispatch table layout is:
- *   [field number] -> [ 48-bit offset ][ 8-bit wt2 ][ 8-bit wt1 ]
- *
- * If wt1 matches, jump to the 48-bit offset.  If wt2 matches, lookup
- * (UPB_MAX_FIELDNUMBER + fieldnum) and jump there.
- *
- * We need two wire types because of packed/non-packed compatibility.  A
- * primitive repeated field can use either wire type and be valid.  While we
- * could key the table on fieldnum+wiretype, the table would be 8x sparser.
- *
- * Storing two wire types in the primary value allows us to quickly rule out
- * the second wire type without needing to do a separate lookup (this case is
- * less common than an unknown field). */
-UPB_INLINE uint64_t upb_pbdecoder_packdispatch(uint64_t ofs, uint8_t wt1,
-                                               uint8_t wt2) {
-  return (ofs << 16) | (wt2 << 8) | wt1;
-}
-
-UPB_INLINE void upb_pbdecoder_unpackdispatch(uint64_t dispatch, uint64_t *ofs,
-                                             uint8_t *wt1, uint8_t *wt2) {
-  *wt1 = (uint8_t)dispatch;
-  *wt2 = (uint8_t)(dispatch >> 8);
-  *ofs = dispatch >> 16;
-}
-
-/* All of the functions in decoder.c that return int32_t return values according
- * to the following scheme:
- *   1. negative values indicate a return code from the following list.
- *   2. positive values indicate that error or end of buffer was hit, and
- *      that the decode function should immediately return the given value
- *      (the decoder state has already been suspended and is ready to be
- *      resumed). */
-#define DECODE_OK -1
-#define DECODE_MISMATCH -2  /* Used only from checktag_slow(). */
-#define DECODE_ENDGROUP -3  /* Used only from checkunknown(). */
-
-#define CHECK_RETURN(x) { int32_t ret = x; if (ret >= 0) return ret; }
-
-#include "upb/port_undef.inc"
-
-#endif  /* UPB_DECODER_INT_H_ */
diff --git a/third_party/upb/upb/pb/encoder.c b/third_party/upb/upb/pb/encoder.c
deleted file mode 100644 (file)
index 0c47b0d..0000000
+++ /dev/null
@@ -1,563 +0,0 @@
-/*
-** upb::Encoder
-**
-** Since we are implementing pure handlers (ie. without any out-of-band access
-** to pre-computed lengths), we have to buffer all submessages before we can
-** emit even their first byte.
-**
-** Not knowing the size of submessages also means we can't write a perfect
-** zero-copy implementation, even with buffering.  Lengths are stored as
-** varints, which means that we don't know how many bytes to reserve for the
-** length until we know what the length is.
-**
-** This leaves us with three main choices:
-**
-** 1. buffer all submessage data in a temporary buffer, then copy it exactly
-**    once into the output buffer.
-**
-** 2. attempt to buffer data directly into the output buffer, estimating how
-**    many bytes each length will take.  When our guesses are wrong, use
-**    memmove() to grow or shrink the allotted space.
-**
-** 3. buffer directly into the output buffer, allocating a max length
-**    ahead-of-time for each submessage length.  If we overallocated, we waste
-**    space, but no memcpy() or memmove() is required.  This approach requires
-**    defining a maximum size for submessages and rejecting submessages that
-**    exceed that size.
-**
-** (2) and (3) have the potential to have better performance, but they are more
-** complicated and subtle to implement:
-**
-**   (3) requires making an arbitrary choice of the maximum message size; it
-**       wastes space when submessages are shorter than this and fails
-**       completely when they are longer.  This makes it more finicky and
-**       requires configuration based on the input.  It also makes it impossible
-**       to perfectly match the output of reference encoders that always use the
-**       optimal amount of space for each length.
-**
-**   (2) requires guessing the the size upfront, and if multiple lengths are
-**       guessed wrong the minimum required number of memmove() operations may
-**       be complicated to compute correctly.  Implemented properly, it may have
-**       a useful amortized or average cost, but more investigation is required
-**       to determine this and what the optimal algorithm is to achieve it.
-**
-**   (1) makes you always pay for exactly one copy, but its implementation is
-**       the simplest and its performance is predictable.
-**
-** So for now, we implement (1) only.  If we wish to optimize later, we should
-** be able to do it without affecting users.
-**
-** The strategy is to buffer the segments of data that do *not* depend on
-** unknown lengths in one buffer, and keep a separate buffer of segment pointers
-** and lengths.  When the top-level submessage ends, we can go beginning to end,
-** alternating the writing of lengths with memcpy() of the rest of the data.
-** At the top level though, no buffering is required.
-*/
-
-#include "upb/pb/encoder.h"
-#include "upb/pb/varint.int.h"
-
-#include "upb/port_def.inc"
-
-/* The output buffer is divided into segments; a segment is a string of data
- * that is "ready to go" -- it does not need any varint lengths inserted into
- * the middle.  The seams between segments are where varints will be inserted
- * once they are known.
- *
- * We also use the concept of a "run", which is a range of encoded bytes that
- * occur at a single submessage level.  Every segment contains one or more runs.
- *
- * A segment can span messages.  Consider:
- *
- *                  .--Submessage lengths---------.
- *                  |       |                     |
- *                  |       V                     V
- *                  V      | |---------------    | |-----------------
- * Submessages:    | |-----------------------------------------------
- * Top-level msg: ------------------------------------------------------------
- *
- * Segments:          -----   -------------------   -----------------
- * Runs:              *----   *--------------*---   *----------------
- * (* marks the start)
- *
- * Note that the top-level menssage is not in any segment because it does not
- * have any length preceding it.
- *
- * A segment is only interrupted when another length needs to be inserted.  So
- * observe how the second segment spans both the inner submessage and part of
- * the next enclosing message. */
-typedef struct {
-  uint32_t msglen;  /* The length to varint-encode before this segment. */
-  uint32_t seglen;  /* Length of the segment. */
-} upb_pb_encoder_segment;
-
-struct upb_pb_encoder {
-  upb_arena *arena;
-
-  /* Our input and output. */
-  upb_sink input_;
-  upb_bytessink output_;
-
-  /* The "subclosure" -- used as the inner closure as part of the bytessink
-   * protocol. */
-  void *subc;
-
-  /* The output buffer and limit, and our current write position.  "buf"
-   * initially points to "initbuf", but is dynamically allocated if we need to
-   * grow beyond the initial size. */
-  char *buf, *ptr, *limit;
-
-  /* The beginning of the current run, or undefined if we are at the top
-   * level. */
-  char *runbegin;
-
-  /* The list of segments we are accumulating. */
-  upb_pb_encoder_segment *segbuf, *segptr, *seglimit;
-
-  /* The stack of enclosing submessages.  Each entry in the stack points to the
-   * segment where this submessage's length is being accumulated. */
-  int *stack, *top, *stacklimit;
-
-  /* Depth of startmsg/endmsg calls. */
-  int depth;
-};
-
-/* low-level buffering ********************************************************/
-
-/* Low-level functions for interacting with the output buffer. */
-
-/* TODO(haberman): handle pushback */
-static void putbuf(upb_pb_encoder *e, const char *buf, size_t len) {
-  size_t n = upb_bytessink_putbuf(e->output_, e->subc, buf, len, NULL);
-  UPB_ASSERT(n == len);
-}
-
-static upb_pb_encoder_segment *top(upb_pb_encoder *e) {
-  return &e->segbuf[*e->top];
-}
-
-/* Call to ensure that at least "bytes" bytes are available for writing at
- * e->ptr.  Returns false if the bytes could not be allocated. */
-static bool reserve(upb_pb_encoder *e, size_t bytes) {
-  if ((size_t)(e->limit - e->ptr) < bytes) {
-    /* Grow buffer. */
-    char *new_buf;
-    size_t needed = bytes + (e->ptr - e->buf);
-    size_t old_size = e->limit - e->buf;
-
-    size_t new_size = old_size;
-
-    while (new_size < needed) {
-      new_size *= 2;
-    }
-
-    new_buf = upb_arena_realloc(e->arena, e->buf, old_size, new_size);
-
-    if (new_buf == NULL) {
-      return false;
-    }
-
-    e->ptr = new_buf + (e->ptr - e->buf);
-    e->runbegin = new_buf + (e->runbegin - e->buf);
-    e->limit = new_buf + new_size;
-    e->buf = new_buf;
-  }
-
-  return true;
-}
-
-/* Call when "bytes" bytes have been writte at e->ptr.  The caller *must* have
- * previously called reserve() with at least this many bytes. */
-static void encoder_advance(upb_pb_encoder *e, size_t bytes) {
-  UPB_ASSERT((size_t)(e->limit - e->ptr) >= bytes);
-  e->ptr += bytes;
-}
-
-/* Call when all of the bytes for a handler have been written.  Flushes the
- * bytes if possible and necessary, returning false if this failed. */
-static bool commit(upb_pb_encoder *e) {
-  if (!e->top) {
-    /* We aren't inside a delimited region.  Flush our accumulated bytes to
-     * the output.
-     *
-     * TODO(haberman): in the future we may want to delay flushing for
-     * efficiency reasons. */
-    putbuf(e, e->buf, e->ptr - e->buf);
-    e->ptr = e->buf;
-  }
-
-  return true;
-}
-
-/* Writes the given bytes to the buffer, handling reserve/advance. */
-static bool encode_bytesval(upb_pb_encoder *e, const void *data, size_t len) {
-  if (!reserve(e, len)) {
-    return false;
-  }
-
-  memcpy(e->ptr, data, len);
-  encoder_advance(e, len);
-  return true;
-}
-
-/* Finish the current run by adding the run totals to the segment and message
- * length. */
-static void accumulate(upb_pb_encoder *e) {
-  size_t run_len;
-  UPB_ASSERT(e->ptr >= e->runbegin);
-  run_len = e->ptr - e->runbegin;
-  e->segptr->seglen += run_len;
-  top(e)->msglen += run_len;
-  e->runbegin = e->ptr;
-}
-
-/* Call to indicate the start of delimited region for which the full length is
- * not yet known.  All data will be buffered until the length is known.
- * Delimited regions may be nested; their lengths will all be tracked properly. */
-static bool start_delim(upb_pb_encoder *e) {
-  if (e->top) {
-    /* We are already buffering, advance to the next segment and push it on the
-     * stack. */
-    accumulate(e);
-
-    if (++e->top == e->stacklimit) {
-      /* TODO(haberman): grow stack? */
-      return false;
-    }
-
-    if (++e->segptr == e->seglimit) {
-      /* Grow segment buffer. */
-      size_t old_size =
-          (e->seglimit - e->segbuf) * sizeof(upb_pb_encoder_segment);
-      size_t new_size = old_size * 2;
-      upb_pb_encoder_segment *new_buf =
-          upb_arena_realloc(e->arena, e->segbuf, old_size, new_size);
-
-      if (new_buf == NULL) {
-        return false;
-      }
-
-      e->segptr = new_buf + (e->segptr - e->segbuf);
-      e->seglimit = new_buf + (new_size / sizeof(upb_pb_encoder_segment));
-      e->segbuf = new_buf;
-    }
-  } else {
-    /* We were previously at the top level, start buffering. */
-    e->segptr = e->segbuf;
-    e->top = e->stack;
-    e->runbegin = e->ptr;
-  }
-
-  *e->top = (int)(e->segptr - e->segbuf);
-  e->segptr->seglen = 0;
-  e->segptr->msglen = 0;
-
-  return true;
-}
-
-/* Call to indicate the end of a delimited region.  We now know the length of
- * the delimited region.  If we are not nested inside any other delimited
- * regions, we can now emit all of the buffered data we accumulated. */
-static bool end_delim(upb_pb_encoder *e) {
-  size_t msglen;
-  accumulate(e);
-  msglen = top(e)->msglen;
-
-  if (e->top == e->stack) {
-    /* All lengths are now available, emit all buffered data. */
-    char buf[UPB_PB_VARINT_MAX_LEN];
-    upb_pb_encoder_segment *s;
-    const char *ptr = e->buf;
-    for (s = e->segbuf; s <= e->segptr; s++) {
-      size_t lenbytes = upb_vencode64(s->msglen, buf);
-      putbuf(e, buf, lenbytes);
-      putbuf(e, ptr, s->seglen);
-      ptr += s->seglen;
-    }
-
-    e->ptr = e->buf;
-    e->top = NULL;
-  } else {
-    /* Need to keep buffering; propagate length info into enclosing
-     * submessages. */
-    --e->top;
-    top(e)->msglen += msglen + upb_varint_size(msglen);
-  }
-
-  return true;
-}
-
-
-/* tag_t **********************************************************************/
-
-/* A precomputed (pre-encoded) tag and length. */
-
-typedef struct {
-  uint8_t bytes;
-  char tag[7];
-} tag_t;
-
-/* Allocates a new tag for this field, and sets it in these handlerattr. */
-static void new_tag(upb_handlers *h, const upb_fielddef *f, upb_wiretype_t wt,
-                    upb_handlerattr *attr) {
-  uint32_t n = upb_fielddef_number(f);
-
-  tag_t *tag = upb_gmalloc(sizeof(tag_t));
-  tag->bytes = upb_vencode64((n << 3) | wt, tag->tag);
-
-  attr->handler_data = tag;
-  upb_handlers_addcleanup(h, tag, upb_gfree);
-}
-
-static bool encode_tagval(upb_pb_encoder *e, const tag_t *tag) {
-  return encode_bytesval(e, tag->tag, tag->bytes);
-}
-
-
-/* encoding of wire types *****************************************************/
-
-static bool doencode_fixed64(upb_pb_encoder *e, uint64_t val) {
-  /* TODO(haberman): byte-swap for big endian. */
-  return encode_bytesval(e, &val, sizeof(uint64_t));
-}
-
-static bool doencode_fixed32(upb_pb_encoder *e, uint32_t val) {
-  /* TODO(haberman): byte-swap for big endian. */
-  return encode_bytesval(e, &val, sizeof(uint32_t));
-}
-
-static bool doencode_varint(upb_pb_encoder *e, uint64_t val) {
-  if (!reserve(e, UPB_PB_VARINT_MAX_LEN)) {
-    return false;
-  }
-
-  encoder_advance(e, upb_vencode64(val, e->ptr));
-  return true;
-}
-
-static uint64_t dbl2uint64(double d) {
-  uint64_t ret;
-  memcpy(&ret, &d, sizeof(uint64_t));
-  return ret;
-}
-
-static uint32_t flt2uint32(float d) {
-  uint32_t ret;
-  memcpy(&ret, &d, sizeof(uint32_t));
-  return ret;
-}
-
-
-/* encoding of proto types ****************************************************/
-
-static bool startmsg(void *c, const void *hd) {
-  upb_pb_encoder *e = c;
-  UPB_UNUSED(hd);
-  if (e->depth++ == 0) {
-    upb_bytessink_start(e->output_, 0, &e->subc);
-  }
-  return true;
-}
-
-static bool endmsg(void *c, const void *hd, upb_status *status) {
-  upb_pb_encoder *e = c;
-  UPB_UNUSED(hd);
-  UPB_UNUSED(status);
-  if (--e->depth == 0) {
-    upb_bytessink_end(e->output_);
-  }
-  return true;
-}
-
-static void *encode_startdelimfield(void *c, const void *hd) {
-  bool ok = encode_tagval(c, hd) && commit(c) && start_delim(c);
-  return ok ? c : UPB_BREAK;
-}
-
-static bool encode_unknown(void *c, const void *hd, const char *buf,
-                           size_t len) {
-  UPB_UNUSED(hd);
-  return encode_bytesval(c, buf, len) && commit(c);
-}
-
-static bool encode_enddelimfield(void *c, const void *hd) {
-  UPB_UNUSED(hd);
-  return end_delim(c);
-}
-
-static void *encode_startgroup(void *c, const void *hd) {
-  return (encode_tagval(c, hd) && commit(c)) ? c : UPB_BREAK;
-}
-
-static bool encode_endgroup(void *c, const void *hd) {
-  return encode_tagval(c, hd) && commit(c);
-}
-
-static void *encode_startstr(void *c, const void *hd, size_t size_hint) {
-  UPB_UNUSED(size_hint);
-  return encode_startdelimfield(c, hd);
-}
-
-static size_t encode_strbuf(void *c, const void *hd, const char *buf,
-                            size_t len, const upb_bufhandle *h) {
-  UPB_UNUSED(hd);
-  UPB_UNUSED(h);
-  return encode_bytesval(c, buf, len) ? len : 0;
-}
-
-#define T(type, ctype, convert, encode)                                    \
-  static bool encode_scalar_##type(void *e, const void *hd, ctype val) {   \
-    return encode_tagval(e, hd) && encode(e, (convert)(val)) && commit(e); \
-  }                                                                        \
-  static bool encode_packed_##type(void *e, const void *hd, ctype val) {   \
-    UPB_UNUSED(hd);                                                        \
-    return encode(e, (convert)(val));                                      \
-  }
-
-T(double,   double,   dbl2uint64,   doencode_fixed64)
-T(float,    float,    flt2uint32,   doencode_fixed32)
-T(int64,    int64_t,  uint64_t,     doencode_varint)
-T(int32,    int32_t,  int64_t,      doencode_varint)
-T(fixed64,  uint64_t, uint64_t,     doencode_fixed64)
-T(fixed32,  uint32_t, uint32_t,     doencode_fixed32)
-T(bool,     bool,     bool,         doencode_varint)
-T(uint32,   uint32_t, uint32_t,     doencode_varint)
-T(uint64,   uint64_t, uint64_t,     doencode_varint)
-T(enum,     int32_t,  uint32_t,     doencode_varint)
-T(sfixed32, int32_t,  uint32_t,     doencode_fixed32)
-T(sfixed64, int64_t,  uint64_t,     doencode_fixed64)
-T(sint32,   int32_t,  upb_zzenc_32, doencode_varint)
-T(sint64,   int64_t,  upb_zzenc_64, doencode_varint)
-
-#undef T
-
-
-/* code to build the handlers *************************************************/
-
-#include <stdio.h>
-static void newhandlers_callback(const void *closure, upb_handlers *h) {
-  const upb_msgdef *m;
-  int i, n;
-
-  UPB_UNUSED(closure);
-
-  upb_handlers_setstartmsg(h, startmsg, NULL);
-  upb_handlers_setendmsg(h, endmsg, NULL);
-  upb_handlers_setunknown(h, encode_unknown, NULL);
-
-  m = upb_handlers_msgdef(h);
-  n = upb_msgdef_fieldcount(m);
-  for(i = 0; i < n; i++) {
-    const upb_fielddef *f = upb_msgdef_field(m, i);
-    bool packed = upb_fielddef_isseq(f) && upb_fielddef_isprimitive(f) &&
-                  upb_fielddef_packed(f);
-    upb_handlerattr attr = UPB_HANDLERATTR_INIT;
-    upb_wiretype_t wt =
-        packed ? UPB_WIRE_TYPE_DELIMITED
-               : upb_pb_native_wire_types[upb_fielddef_descriptortype(f)];
-
-    /* Pre-encode the tag for this field. */
-    new_tag(h, f, wt, &attr);
-
-    if (packed) {
-      upb_handlers_setstartseq(h, f, encode_startdelimfield, &attr);
-      upb_handlers_setendseq(h, f, encode_enddelimfield, &attr);
-    }
-
-#define T(upper, lower, upbtype)                                     \
-  case UPB_DESCRIPTOR_TYPE_##upper:                                  \
-    if (packed) {                                                    \
-      upb_handlers_set##upbtype(h, f, encode_packed_##lower, &attr); \
-    } else {                                                         \
-      upb_handlers_set##upbtype(h, f, encode_scalar_##lower, &attr); \
-    }                                                                \
-    break;
-
-    switch (upb_fielddef_descriptortype(f)) {
-      T(DOUBLE,   double,   double);
-      T(FLOAT,    float,    float);
-      T(INT64,    int64,    int64);
-      T(INT32,    int32,    int32);
-      T(FIXED64,  fixed64,  uint64);
-      T(FIXED32,  fixed32,  uint32);
-      T(BOOL,     bool,     bool);
-      T(UINT32,   uint32,   uint32);
-      T(UINT64,   uint64,   uint64);
-      T(ENUM,     enum,     int32);
-      T(SFIXED32, sfixed32, int32);
-      T(SFIXED64, sfixed64, int64);
-      T(SINT32,   sint32,   int32);
-      T(SINT64,   sint64,   int64);
-      case UPB_DESCRIPTOR_TYPE_STRING:
-      case UPB_DESCRIPTOR_TYPE_BYTES:
-        upb_handlers_setstartstr(h, f, encode_startstr, &attr);
-        upb_handlers_setendstr(h, f, encode_enddelimfield, &attr);
-        upb_handlers_setstring(h, f, encode_strbuf, &attr);
-        break;
-      case UPB_DESCRIPTOR_TYPE_MESSAGE:
-        upb_handlers_setstartsubmsg(h, f, encode_startdelimfield, &attr);
-        upb_handlers_setendsubmsg(h, f, encode_enddelimfield, &attr);
-        break;
-      case UPB_DESCRIPTOR_TYPE_GROUP: {
-        /* Endgroup takes a different tag (wire_type = END_GROUP). */
-        upb_handlerattr attr2 = UPB_HANDLERATTR_INIT;
-        new_tag(h, f, UPB_WIRE_TYPE_END_GROUP, &attr2);
-
-        upb_handlers_setstartsubmsg(h, f, encode_startgroup, &attr);
-        upb_handlers_setendsubmsg(h, f, encode_endgroup, &attr2);
-
-        break;
-      }
-    }
-
-#undef T
-  }
-}
-
-void upb_pb_encoder_reset(upb_pb_encoder *e) {
-  e->segptr = NULL;
-  e->top = NULL;
-  e->depth = 0;
-}
-
-
-/* public API *****************************************************************/
-
-upb_handlercache *upb_pb_encoder_newcache(void) {
-  return upb_handlercache_new(newhandlers_callback, NULL);
-}
-
-upb_pb_encoder *upb_pb_encoder_create(upb_arena *arena, const upb_handlers *h,
-                                      upb_bytessink output) {
-  const size_t initial_bufsize = 256;
-  const size_t initial_segbufsize = 16;
-  /* TODO(haberman): make this configurable. */
-  const size_t stack_size = 64;
-
-  upb_pb_encoder *e = upb_arena_malloc(arena, sizeof(upb_pb_encoder));
-  if (!e) return NULL;
-
-  e->buf = upb_arena_malloc(arena, initial_bufsize);
-  e->segbuf = upb_arena_malloc(arena, initial_segbufsize * sizeof(*e->segbuf));
-  e->stack = upb_arena_malloc(arena, stack_size * sizeof(*e->stack));
-
-  if (!e->buf || !e->segbuf || !e->stack) {
-    return NULL;
-  }
-
-  e->limit = e->buf + initial_bufsize;
-  e->seglimit = e->segbuf + initial_segbufsize;
-  e->stacklimit = e->stack + stack_size;
-
-  upb_pb_encoder_reset(e);
-  upb_sink_reset(&e->input_, h, e);
-
-  e->arena = arena;
-  e->output_ = output;
-  e->subc = output.closure;
-  e->ptr = e->buf;
-
-  return e;
-}
-
-upb_sink upb_pb_encoder_input(upb_pb_encoder *e) { return e->input_; }
diff --git a/third_party/upb/upb/pb/encoder.h b/third_party/upb/upb/pb/encoder.h
deleted file mode 100644 (file)
index f125b37..0000000
+++ /dev/null
@@ -1,83 +0,0 @@
-/*
-** upb::pb::Encoder (upb_pb_encoder)
-**
-** Implements a set of upb_handlers that write protobuf data to the binary wire
-** format.
-**
-** This encoder implementation does not have any access to any out-of-band or
-** precomputed lengths for submessages, so it must buffer submessages internally
-** before it can emit the first byte.
-*/
-
-#ifndef UPB_ENCODER_H_
-#define UPB_ENCODER_H_
-
-#include "upb/sink.h"
-
-#ifdef __cplusplus
-namespace upb {
-namespace pb {
-class EncoderPtr;
-}  /* namespace pb */
-}  /* namespace upb */
-#endif
-
-#define UPB_PBENCODER_MAX_NESTING 100
-
-/* upb_pb_encoder *************************************************************/
-
-/* Preallocation hint: decoder won't allocate more bytes than this when first
- * constructed.  This hint may be an overestimate for some build configurations.
- * But if the decoder library is upgraded without recompiling the application,
- * it may be an underestimate. */
-#define UPB_PB_ENCODER_SIZE 784
-
-struct upb_pb_encoder;
-typedef struct upb_pb_encoder upb_pb_encoder;
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-upb_sink upb_pb_encoder_input(upb_pb_encoder *p);
-upb_pb_encoder* upb_pb_encoder_create(upb_arena* a, const upb_handlers* h,
-                                      upb_bytessink output);
-
-/* Lazily builds and caches handlers that will push encoded data to a bytessink.
- * Any msgdef objects used with this object must outlive it. */
-upb_handlercache *upb_pb_encoder_newcache(void);
-
-#ifdef __cplusplus
-}  /* extern "C" { */
-
-class upb::pb::EncoderPtr {
- public:
-  EncoderPtr(upb_pb_encoder* ptr) : ptr_(ptr) {}
-
-  upb_pb_encoder* ptr() { return ptr_; }
-
-  /* Creates a new encoder in the given environment.  The Handlers must have
-   * come from NewHandlers() below. */
-  static EncoderPtr Create(Arena* arena, const Handlers* handlers,
-                           BytesSink output) {
-    return EncoderPtr(
-        upb_pb_encoder_create(arena->ptr(), handlers, output.sink()));
-  }
-
-  /* The input to the encoder. */
-  upb::Sink input() { return upb_pb_encoder_input(ptr()); }
-
-  /* Creates a new set of handlers for this MessageDef. */
-  static HandlerCache NewCache() {
-    return HandlerCache(upb_pb_encoder_newcache());
-  }
-
-  static const size_t kSize = UPB_PB_ENCODER_SIZE;
-
- private:
-  upb_pb_encoder* ptr_;
-};
-
-#endif  /* __cplusplus */
-
-#endif  /* UPB_ENCODER_H_ */
diff --git a/third_party/upb/upb/pb/make-gdb-script.rb b/third_party/upb/upb/pb/make-gdb-script.rb
deleted file mode 100755 (executable)
index 3895597..0000000
+++ /dev/null
@@ -1,36 +0,0 @@
-#!/usr/bin/ruby
-
-puts "set width 0
-set height 0
-set verbose off\n\n"
-
-IO.popen("nm -S /tmp/upb-jit-code.so").each_line { |line|
-  # Input lines look like this:
-  #   000000000000575a T X.0x10.OP_CHECKDELIM
-  #
-  # For each one we want to emit a command that looks like:
-  #   b X.0x10.OP_CHECKDELIM
-  #   commands
-  #     silent
-  #     printf "buf_ofs=%d data_rem=%d delim_rem=%d X.0x10.OP_CHECKDELIM\n", $rbx - (long)((upb_pbdecoder*)($r15))->buf, $r12 - $rbx, $rbp - $rbx
-  #     continue
-  #   end
-
-  parts = line.split
-  next if parts[1] != "T"
-  sym = parts[2]
-  next if sym !~ /X\./;
-  if sym =~ /OP_/ then
-    printcmd = "printf \"buf_ofs=%d data_rem=%d delim_rem=%d #{sym}\\n\", $rbx - (long)((upb_pbdecoder*)($r15))->buf, $r12 - $rbx, $rbp - $rbx"
-  elsif sym =~ /enterjit/ then
-    printcmd = "printf \"#{sym} bytes=%d\\n\", $rcx"
-  else
-    printcmd = "printf \"#{sym}\\n\""
-  end
-  puts "b #{sym}
-commands
-  silent
-  #{printcmd}
-  continue
-end\n\n"
-}
diff --git a/third_party/upb/upb/pb/textprinter.c b/third_party/upb/upb/pb/textprinter.c
deleted file mode 100644 (file)
index 1331268..0000000
+++ /dev/null
@@ -1,339 +0,0 @@
-/*
- * upb::pb::TextPrinter
- *
- * OPT: This is not optimized at all.  It uses printf() which parses the format
- * string every time, and it allocates memory for every put.
- */
-
-#include "upb/pb/textprinter.h"
-
-#include <ctype.h>
-#include <float.h>
-#include <inttypes.h>
-#include <stdarg.h>
-#include <stdio.h>
-#include <string.h>
-
-#include "upb/sink.h"
-
-#include "upb/port_def.inc"
-
-struct upb_textprinter {
-  upb_sink input_;
-  upb_bytessink output_;
-  int indent_depth_;
-  bool single_line_;
-  void *subc;
-};
-
-#define CHECK(x) if ((x) < 0) goto err;
-
-static const char *shortname(const char *longname) {
-  const char *last = strrchr(longname, '.');
-  return last ? last + 1 : longname;
-}
-
-static int indent(upb_textprinter *p) {
-  int i;
-  if (!p->single_line_)
-    for (i = 0; i < p->indent_depth_; i++)
-      upb_bytessink_putbuf(p->output_, p->subc, "  ", 2, NULL);
-  return 0;
-}
-
-static int endfield(upb_textprinter *p) {
-  const char ch = (p->single_line_ ? ' ' : '\n');
-  upb_bytessink_putbuf(p->output_, p->subc, &ch, 1, NULL);
-  return 0;
-}
-
-static int putescaped(upb_textprinter *p, const char *buf, size_t len,
-                      bool preserve_utf8) {
-  /* Based on CEscapeInternal() from Google's protobuf release. */
-  char dstbuf[4096], *dst = dstbuf, *dstend = dstbuf + sizeof(dstbuf);
-  const char *end = buf + len;
-
-  /* I think hex is prettier and more useful, but proto2 uses octal; should
-   * investigate whether it can parse hex also. */
-  const bool use_hex = false;
-  bool last_hex_escape = false; /* true if last output char was \xNN */
-
-  for (; buf < end; buf++) {
-    bool is_hex_escape;
-
-    if (dstend - dst < 4) {
-      upb_bytessink_putbuf(p->output_, p->subc, dstbuf, dst - dstbuf, NULL);
-      dst = dstbuf;
-    }
-
-    is_hex_escape = false;
-    switch (*buf) {
-      case '\n': *(dst++) = '\\'; *(dst++) = 'n';  break;
-      case '\r': *(dst++) = '\\'; *(dst++) = 'r';  break;
-      case '\t': *(dst++) = '\\'; *(dst++) = 't';  break;
-      case '\"': *(dst++) = '\\'; *(dst++) = '\"'; break;
-      case '\'': *(dst++) = '\\'; *(dst++) = '\''; break;
-      case '\\': *(dst++) = '\\'; *(dst++) = '\\'; break;
-      default:
-        /* Note that if we emit \xNN and the buf character after that is a hex
-         * digit then that digit must be escaped too to prevent it being
-         * interpreted as part of the character code by C. */
-        if ((!preserve_utf8 || (uint8_t)*buf < 0x80) &&
-            (!isprint(*buf) || (last_hex_escape && isxdigit(*buf)))) {
-          sprintf(dst, (use_hex ? "\\x%02x" : "\\%03o"), (uint8_t)*buf);
-          is_hex_escape = use_hex;
-          dst += 4;
-        } else {
-          *(dst++) = *buf; break;
-        }
-    }
-    last_hex_escape = is_hex_escape;
-  }
-  /* Flush remaining data. */
-  upb_bytessink_putbuf(p->output_, p->subc, dstbuf, dst - dstbuf, NULL);
-  return 0;
-}
-
-bool putf(upb_textprinter *p, const char *fmt, ...) {
-  va_list args;
-  va_list args_copy;
-  char *str;
-  int written;
-  int len;
-  bool ok;
-
-  va_start(args, fmt);
-
-  /* Run once to get the length of the string. */
-  va_copy(args_copy, args);
-  len = vsnprintf(NULL, 0, fmt, args_copy);
-  va_end(args_copy);
-
-  /* + 1 for NULL terminator (vsprintf() requires it even if we don't). */
-  str = upb_gmalloc(len + 1);
-  if (!str) return false;
-  written = vsprintf(str, fmt, args);
-  va_end(args);
-  UPB_ASSERT(written == len);
-
-  ok = upb_bytessink_putbuf(p->output_, p->subc, str, len, NULL);
-  upb_gfree(str);
-  return ok;
-}
-
-
-/* handlers *******************************************************************/
-
-static bool textprinter_startmsg(void *c, const void *hd) {
-  upb_textprinter *p = c;
-  UPB_UNUSED(hd);
-  if (p->indent_depth_ == 0) {
-    upb_bytessink_start(p->output_, 0, &p->subc);
-  }
-  return true;
-}
-
-static bool textprinter_endmsg(void *c, const void *hd, upb_status *s) {
-  upb_textprinter *p = c;
-  UPB_UNUSED(hd);
-  UPB_UNUSED(s);
-  if (p->indent_depth_ == 0) {
-    upb_bytessink_end(p->output_);
-  }
-  return true;
-}
-
-#define TYPE(name, ctype, fmt) \
-  static bool textprinter_put ## name(void *closure, const void *handler_data, \
-                                      ctype val) {                             \
-    upb_textprinter *p = closure;                                              \
-    const upb_fielddef *f = handler_data;                                      \
-    CHECK(indent(p));                                                          \
-    putf(p, "%s: " fmt, upb_fielddef_name(f), val);                            \
-    CHECK(endfield(p));                                                        \
-    return true;                                                               \
-  err:                                                                         \
-    return false;                                                              \
-}
-
-static bool textprinter_putbool(void *closure, const void *handler_data,
-                                bool val) {
-  upb_textprinter *p = closure;
-  const upb_fielddef *f = handler_data;
-  CHECK(indent(p));
-  putf(p, "%s: %s", upb_fielddef_name(f), val ? "true" : "false");
-  CHECK(endfield(p));
-  return true;
-err:
-  return false;
-}
-
-#define STRINGIFY_HELPER(x) #x
-#define STRINGIFY_MACROVAL(x) STRINGIFY_HELPER(x)
-
-TYPE(int32,  int32_t,  "%" PRId32)
-TYPE(int64,  int64_t,  "%" PRId64)
-TYPE(uint32, uint32_t, "%" PRIu32)
-TYPE(uint64, uint64_t, "%" PRIu64)
-TYPE(float,  float,    "%." STRINGIFY_MACROVAL(FLT_DIG) "g")
-TYPE(double, double,   "%." STRINGIFY_MACROVAL(DBL_DIG) "g")
-
-#undef TYPE
-
-/* Output a symbolic value from the enum if found, else just print as int32. */
-static bool textprinter_putenum(void *closure, const void *handler_data,
-                                int32_t val) {
-  upb_textprinter *p = closure;
-  const upb_fielddef *f = handler_data;
-  const upb_enumdef *enum_def = upb_fielddef_enumsubdef(f);
-  const char *label = upb_enumdef_iton(enum_def, val);
-  if (label) {
-    indent(p);
-    putf(p, "%s: %s", upb_fielddef_name(f), label);
-    endfield(p);
-  } else {
-    if (!textprinter_putint32(closure, handler_data, val))
-      return false;
-  }
-  return true;
-}
-
-static void *textprinter_startstr(void *closure, const void *handler_data,
-                      size_t size_hint) {
-  upb_textprinter *p = closure;
-  const upb_fielddef *f = handler_data;
-  UPB_UNUSED(size_hint);
-  indent(p);
-  putf(p, "%s: \"", upb_fielddef_name(f));
-  return p;
-}
-
-static bool textprinter_endstr(void *closure, const void *handler_data) {
-  upb_textprinter *p = closure;
-  UPB_UNUSED(handler_data);
-  putf(p, "\"");
-  endfield(p);
-  return true;
-}
-
-static size_t textprinter_putstr(void *closure, const void *hd, const char *buf,
-                                 size_t len, const upb_bufhandle *handle) {
-  upb_textprinter *p = closure;
-  const upb_fielddef *f = hd;
-  UPB_UNUSED(handle);
-  CHECK(putescaped(p, buf, len, upb_fielddef_type(f) == UPB_TYPE_STRING));
-  return len;
-err:
-  return 0;
-}
-
-static void *textprinter_startsubmsg(void *closure, const void *handler_data) {
-  upb_textprinter *p = closure;
-  const char *name = handler_data;
-  CHECK(indent(p));
-  putf(p, "%s {%c", name, p->single_line_ ? ' ' : '\n');
-  p->indent_depth_++;
-  return p;
-err:
-  return UPB_BREAK;
-}
-
-static bool textprinter_endsubmsg(void *closure, const void *handler_data) {
-  upb_textprinter *p = closure;
-  UPB_UNUSED(handler_data);
-  p->indent_depth_--;
-  CHECK(indent(p));
-  upb_bytessink_putbuf(p->output_, p->subc, "}", 1, NULL);
-  CHECK(endfield(p));
-  return true;
-err:
-  return false;
-}
-
-static void onmreg(const void *c, upb_handlers *h) {
-  const upb_msgdef *m = upb_handlers_msgdef(h);
-  int i, n;
-  UPB_UNUSED(c);
-
-  upb_handlers_setstartmsg(h, textprinter_startmsg, NULL);
-  upb_handlers_setendmsg(h, textprinter_endmsg, NULL);
-
-  n = upb_msgdef_fieldcount(m);
-  for(i = 0; i < n; i++) {
-    const upb_fielddef *f = upb_msgdef_field(m, i);
-    upb_handlerattr attr = UPB_HANDLERATTR_INIT;
-    attr.handler_data = f;
-    switch (upb_fielddef_type(f)) {
-      case UPB_TYPE_INT32:
-        upb_handlers_setint32(h, f, textprinter_putint32, &attr);
-        break;
-      case UPB_TYPE_INT64:
-        upb_handlers_setint64(h, f, textprinter_putint64, &attr);
-        break;
-      case UPB_TYPE_UINT32:
-        upb_handlers_setuint32(h, f, textprinter_putuint32, &attr);
-        break;
-      case UPB_TYPE_UINT64:
-        upb_handlers_setuint64(h, f, textprinter_putuint64, &attr);
-        break;
-      case UPB_TYPE_FLOAT:
-        upb_handlers_setfloat(h, f, textprinter_putfloat, &attr);
-        break;
-      case UPB_TYPE_DOUBLE:
-        upb_handlers_setdouble(h, f, textprinter_putdouble, &attr);
-        break;
-      case UPB_TYPE_BOOL:
-        upb_handlers_setbool(h, f, textprinter_putbool, &attr);
-        break;
-      case UPB_TYPE_STRING:
-      case UPB_TYPE_BYTES:
-        upb_handlers_setstartstr(h, f, textprinter_startstr, &attr);
-        upb_handlers_setstring(h, f, textprinter_putstr, &attr);
-        upb_handlers_setendstr(h, f, textprinter_endstr, &attr);
-        break;
-      case UPB_TYPE_MESSAGE: {
-        const char *name =
-            upb_fielddef_descriptortype(f) == UPB_DESCRIPTOR_TYPE_GROUP
-                ? shortname(upb_msgdef_fullname(upb_fielddef_msgsubdef(f)))
-                : upb_fielddef_name(f);
-        attr.handler_data = name;
-        upb_handlers_setstartsubmsg(h, f, textprinter_startsubmsg, &attr);
-        upb_handlers_setendsubmsg(h, f, textprinter_endsubmsg, &attr);
-        break;
-      }
-      case UPB_TYPE_ENUM:
-        upb_handlers_setint32(h, f, textprinter_putenum, &attr);
-        break;
-    }
-  }
-}
-
-static void textprinter_reset(upb_textprinter *p, bool single_line) {
-  p->single_line_ = single_line;
-  p->indent_depth_ = 0;
-}
-
-
-/* Public API *****************************************************************/
-
-upb_textprinter *upb_textprinter_create(upb_arena *arena, const upb_handlers *h,
-                                        upb_bytessink output) {
-  upb_textprinter *p = upb_arena_malloc(arena, sizeof(upb_textprinter));
-  if (!p) return NULL;
-
-  p->output_ = output;
-  upb_sink_reset(&p->input_, h, p);
-  textprinter_reset(p, false);
-
-  return p;
-}
-
-upb_handlercache *upb_textprinter_newcache(void) {
-  return upb_handlercache_new(&onmreg, NULL);
-}
-
-upb_sink upb_textprinter_input(upb_textprinter *p) { return p->input_; }
-
-void upb_textprinter_setsingleline(upb_textprinter *p, bool single_line) {
-  p->single_line_ = single_line;
-}
diff --git a/third_party/upb/upb/pb/textprinter.h b/third_party/upb/upb/pb/textprinter.h
deleted file mode 100644 (file)
index 7e20d75..0000000
+++ /dev/null
@@ -1,69 +0,0 @@
-/*
-** upb::pb::TextPrinter (upb_textprinter)
-**
-** Handlers for writing to protobuf text format.
-*/
-
-#ifndef UPB_TEXT_H_
-#define UPB_TEXT_H_
-
-#include "upb/sink.h"
-
-#ifdef __cplusplus
-namespace upb {
-namespace pb {
-class TextPrinterPtr;
-}  /* namespace pb */
-}  /* namespace upb */
-#endif
-
-/* upb_textprinter ************************************************************/
-
-struct upb_textprinter;
-typedef struct upb_textprinter upb_textprinter;
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-/* C API. */
-upb_textprinter *upb_textprinter_create(upb_arena *arena, const upb_handlers *h,
-                                        upb_bytessink output);
-void upb_textprinter_setsingleline(upb_textprinter *p, bool single_line);
-upb_sink upb_textprinter_input(upb_textprinter *p);
-upb_handlercache *upb_textprinter_newcache(void);
-
-#ifdef __cplusplus
-}  /* extern "C" */
-
-class upb::pb::TextPrinterPtr {
- public:
-  TextPrinterPtr(upb_textprinter* ptr) : ptr_(ptr) {}
-
-  /* The given handlers must have come from NewHandlers().  It must outlive the
-   * TextPrinter. */
-  static TextPrinterPtr Create(Arena *arena, upb::HandlersPtr *handlers,
-                               BytesSink output) {
-    return TextPrinterPtr(
-        upb_textprinter_create(arena->ptr(), handlers->ptr(), output.sink()));
-  }
-
-  void SetSingleLineMode(bool single_line) {
-    upb_textprinter_setsingleline(ptr_, single_line);
-  }
-
-  Sink input() { return upb_textprinter_input(ptr_); }
-
-  /* If handler caching becomes a requirement we can add a code cache as in
-   * decoder.h */
-  static HandlerCache NewCache() {
-    return HandlerCache(upb_textprinter_newcache());
-  }
-
- private:
-  upb_textprinter* ptr_;
-};
-
-#endif
-
-#endif  /* UPB_TEXT_H_ */
diff --git a/third_party/upb/upb/pb/varint.c b/third_party/upb/upb/pb/varint.c
deleted file mode 100644 (file)
index 90f58a1..0000000
+++ /dev/null
@@ -1,74 +0,0 @@
-
-#include "upb/pb/varint.int.h"
-
-/* Index is descriptor type. */
-const uint8_t upb_pb_native_wire_types[] = {
-  UPB_WIRE_TYPE_END_GROUP,     /* ENDGROUP */
-  UPB_WIRE_TYPE_64BIT,         /* DOUBLE */
-  UPB_WIRE_TYPE_32BIT,         /* FLOAT */
-  UPB_WIRE_TYPE_VARINT,        /* INT64 */
-  UPB_WIRE_TYPE_VARINT,        /* UINT64 */
-  UPB_WIRE_TYPE_VARINT,        /* INT32 */
-  UPB_WIRE_TYPE_64BIT,         /* FIXED64 */
-  UPB_WIRE_TYPE_32BIT,         /* FIXED32 */
-  UPB_WIRE_TYPE_VARINT,        /* BOOL */
-  UPB_WIRE_TYPE_DELIMITED,     /* STRING */
-  UPB_WIRE_TYPE_START_GROUP,   /* GROUP */
-  UPB_WIRE_TYPE_DELIMITED,     /* MESSAGE */
-  UPB_WIRE_TYPE_DELIMITED,     /* BYTES */
-  UPB_WIRE_TYPE_VARINT,        /* UINT32 */
-  UPB_WIRE_TYPE_VARINT,        /* ENUM */
-  UPB_WIRE_TYPE_32BIT,         /* SFIXED32 */
-  UPB_WIRE_TYPE_64BIT,         /* SFIXED64 */
-  UPB_WIRE_TYPE_VARINT,        /* SINT32 */
-  UPB_WIRE_TYPE_VARINT,        /* SINT64 */
-};
-
-/* A basic branch-based decoder, uses 32-bit values to get good performance
- * on 32-bit architectures (but performs well on 64-bits also).
- * This scheme comes from the original Google Protobuf implementation
- * (proto2). */
-upb_decoderet upb_vdecode_max8_branch32(upb_decoderet r) {
-  upb_decoderet err = {NULL, 0};
-  const char *p = r.p;
-  uint32_t low = (uint32_t)r.val;
-  uint32_t high = 0;
-  uint32_t b;
-  b = *(p++); low  |= (b & 0x7fU) << 14; if (!(b & 0x80)) goto done;
-  b = *(p++); low  |= (b & 0x7fU) << 21; if (!(b & 0x80)) goto done;
-  b = *(p++); low  |= (b & 0x7fU) << 28;
-              high  = (b & 0x7fU) >>  4; if (!(b & 0x80)) goto done;
-  b = *(p++); high |= (b & 0x7fU) <<  3; if (!(b & 0x80)) goto done;
-  b = *(p++); high |= (b & 0x7fU) << 10; if (!(b & 0x80)) goto done;
-  b = *(p++); high |= (b & 0x7fU) << 17; if (!(b & 0x80)) goto done;
-  b = *(p++); high |= (b & 0x7fU) << 24; if (!(b & 0x80)) goto done;
-  b = *(p++); high |= (b & 0x7fU) << 31; if (!(b & 0x80)) goto done;
-  return err;
-
-done:
-  r.val = ((uint64_t)high << 32) | low;
-  r.p = p;
-  return r;
-}
-
-/* Like the previous, but uses 64-bit values. */
-upb_decoderet upb_vdecode_max8_branch64(upb_decoderet r) {
-  const char *p = r.p;
-  uint64_t val = r.val;
-  uint64_t b;
-  upb_decoderet err = {NULL, 0};
-  b = *(p++); val |= (b & 0x7fU) << 14; if (!(b & 0x80)) goto done;
-  b = *(p++); val |= (b & 0x7fU) << 21; if (!(b & 0x80)) goto done;
-  b = *(p++); val |= (b & 0x7fU) << 28; if (!(b & 0x80)) goto done;
-  b = *(p++); val |= (b & 0x7fU) << 35; if (!(b & 0x80)) goto done;
-  b = *(p++); val |= (b & 0x7fU) << 42; if (!(b & 0x80)) goto done;
-  b = *(p++); val |= (b & 0x7fU) << 49; if (!(b & 0x80)) goto done;
-  b = *(p++); val |= (b & 0x7fU) << 56; if (!(b & 0x80)) goto done;
-  b = *(p++); val |= (b & 0x7fU) << 63; if (!(b & 0x80)) goto done;
-  return err;
-
-done:
-  r.val = val;
-  r.p = p;
-  return r;
-}
diff --git a/third_party/upb/upb/pb/varint.int.h b/third_party/upb/upb/pb/varint.int.h
deleted file mode 100644 (file)
index 9b98a81..0000000
+++ /dev/null
@@ -1,164 +0,0 @@
-/*
-** A number of routines for varint manipulation (we keep them all around to
-** have multiple approaches available for benchmarking).
-*/
-
-#ifndef UPB_VARINT_DECODER_H_
-#define UPB_VARINT_DECODER_H_
-
-#include <assert.h>
-#include <stdint.h>
-#include <string.h>
-#include "upb/upb.h"
-
-#include "upb/port_def.inc"
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-#define UPB_MAX_WIRE_TYPE 5
-
-/* The maximum number of bytes that it takes to encode a 64-bit varint. */
-#define UPB_PB_VARINT_MAX_LEN 10
-
-/* Array of the "native" (ie. non-packed-repeated) wire type for the given a
- * descriptor type (upb_descriptortype_t). */
-extern const uint8_t upb_pb_native_wire_types[];
-
-UPB_INLINE uint64_t byteswap64(uint64_t val) {
-  uint64_t byte = 0xff;
-  return (val & (byte << 56) >> 56)
-    | (val & (byte << 48) >> 40)
-    | (val & (byte << 40) >> 24)
-    | (val & (byte << 32) >> 8)
-    | (val & (byte << 24) << 8)
-    | (val & (byte << 16) << 24)
-    | (val & (byte <<  8) << 40)
-    | (val & (byte <<  0) << 56);
-}
-
-/* Zig-zag encoding/decoding **************************************************/
-
-UPB_INLINE int32_t upb_zzdec_32(uint64_t _n) {
-  uint32_t n = (uint32_t)_n;
-  return (n >> 1) ^ -(int32_t)(n & 1);
-}
-UPB_INLINE int64_t upb_zzdec_64(uint64_t n) {
-  return (n >> 1) ^ -(int64_t)(n & 1);
-}
-UPB_INLINE uint32_t upb_zzenc_32(int32_t n) {
-  return ((uint32_t)n << 1) ^ (n >> 31);
-}
-UPB_INLINE uint64_t upb_zzenc_64(int64_t n) {
-  return ((uint64_t)n << 1) ^ (n >> 63);
-}
-
-/* Decoding *******************************************************************/
-
-/* All decoding functions return this struct by value. */
-typedef struct {
-  const char *p;  /* NULL if the varint was unterminated. */
-  uint64_t val;
-} upb_decoderet;
-
-UPB_INLINE upb_decoderet upb_decoderet_make(const char *p, uint64_t val) {
-  upb_decoderet ret;
-  ret.p = p;
-  ret.val = val;
-  return ret;
-}
-
-upb_decoderet upb_vdecode_max8_branch32(upb_decoderet r);
-upb_decoderet upb_vdecode_max8_branch64(upb_decoderet r);
-
-/* Template for a function that checks the first two bytes with branching
- * and dispatches 2-10 bytes with a separate function.  Note that this may read
- * up to 10 bytes, so it must not be used unless there are at least ten bytes
- * left in the buffer! */
-#define UPB_VARINT_DECODER_CHECK2(name, decode_max8_function)                  \
-UPB_INLINE upb_decoderet upb_vdecode_check2_ ## name(const char *_p) {         \
-  uint8_t *p = (uint8_t*)_p;                                                   \
-  upb_decoderet r;                                                             \
-  if ((*p & 0x80) == 0) {                                                      \
-  /* Common case: one-byte varint. */                                          \
-    return upb_decoderet_make(_p + 1, *p & 0x7fU);                             \
-  }                                                                            \
-  r = upb_decoderet_make(_p + 2, (*p & 0x7fU) | ((*(p + 1) & 0x7fU) << 7));    \
-  if ((*(p + 1) & 0x80) == 0) {                                                \
-    /* Two-byte varint. */                                                     \
-    return r;                                                                  \
-  }                                                                            \
-  /* Longer varint, fallback to out-of-line function. */                       \
-  return decode_max8_function(r);                                              \
-}
-
-UPB_VARINT_DECODER_CHECK2(branch32, upb_vdecode_max8_branch32)
-UPB_VARINT_DECODER_CHECK2(branch64, upb_vdecode_max8_branch64)
-#undef UPB_VARINT_DECODER_CHECK2
-
-/* Our canonical functions for decoding varints, based on the currently
- * favored best-performing implementations. */
-UPB_INLINE upb_decoderet upb_vdecode_fast(const char *p) {
-  if (sizeof(long) == 8)
-    return upb_vdecode_check2_branch64(p);
-  else
-    return upb_vdecode_check2_branch32(p);
-}
-
-
-/* Encoding *******************************************************************/
-
-UPB_INLINE int upb_value_size(uint64_t val) {
-#ifdef __GNUC__
-  /* 0-based, undef if val == 0. */
-  int high_bit = val ? 63 - __builtin_clzll(val) : 0;
-#else
-  int high_bit = 0;
-  uint64_t tmp = val;
-  while(tmp >>= 1) high_bit++;
-#endif
-  return val == 0 ? 1 : high_bit / 8 + 1;
-}
-
-/* Encodes a 64-bit varint into buf (which must be >=UPB_PB_VARINT_MAX_LEN
- * bytes long), returning how many bytes were used.
- *
- * TODO: benchmark and optimize if necessary. */
-UPB_INLINE size_t upb_vencode64(uint64_t val, char *buf) {
-  size_t i;
-  if (val == 0) { buf[0] = 0; return 1; }
-  i = 0;
-  while (val) {
-    uint8_t byte = val & 0x7fU;
-    val >>= 7;
-    if (val) byte |= 0x80U;
-    buf[i++] = byte;
-  }
-  return i;
-}
-
-UPB_INLINE size_t upb_varint_size(uint64_t val) {
-  char buf[UPB_PB_VARINT_MAX_LEN];
-  return upb_vencode64(val, buf);
-}
-
-/* Encodes a 32-bit varint, *not* sign-extended. */
-UPB_INLINE uint64_t upb_vencode32(uint32_t val) {
-  char buf[UPB_PB_VARINT_MAX_LEN];
-  size_t bytes = upb_vencode64(val, buf);
-  uint64_t ret = 0;
-  UPB_ASSERT(bytes <= 5);
-  memcpy(&ret, buf, bytes);
-  ret = _upb_be_swap64(ret);
-  UPB_ASSERT(ret <= 0xffffffffffU);
-  return ret;
-}
-
-#ifdef __cplusplus
-}  /* extern "C" */
-#endif
-
-#include "upb/port_undef.inc"
-
-#endif  /* UPB_VARINT_DECODER_H_ */
index 2cd1bb6..75d416d 100644 (file)
@@ -1,25 +1,52 @@
 /*
-* This is where we define macros used across upb.
-*
-* All of these macros are undef'd in port_undef.inc to avoid leaking them to
-* users.
-*
-* The correct usage is:
-*
-*   #include "upb/foobar.h"
-*   #include "upb/baz.h"
-*
-*   // MUST be last included header.
-*   #include "upb/port_def.inc"
-*
-*   // Code for this file.
-*   // <...>
-*
-*   // Can be omitted for .c files, required for .h.
-*   #include "upb/port_undef.inc"
-*
-* This file is private and must not be included by users!
-*/
+ * Copyright (c) 2009-2021, Google LLC
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ *     * Redistributions of source code must retain the above copyright
+ *       notice, this list of conditions and the following disclaimer.
+ *     * Redistributions in binary form must reproduce the above copyright
+ *       notice, this list of conditions and the following disclaimer in the
+ *       documentation and/or other materials provided with the distribution.
+ *     * Neither the name of Google LLC nor the
+ *       names of its contributors may be used to endorse or promote products
+ *       derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+ * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ * DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+ * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+ * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+ * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+/*
+ * This is where we define macros used across upb.
+ *
+ * All of these macros are undef'd in port_undef.inc to avoid leaking them to
+ * users.
+ *
+ * The correct usage is:
+ *
+ *   #include "upb/foobar.h"
+ *   #include "upb/baz.h"
+ *
+ *   // MUST be last included header.
+ *   #include "upb/port_def.inc"
+ *
+ *   // Code for this file.
+ *   // <...>
+ *
+ *   // Can be omitted for .c files, required for .h.
+ *   #include "upb/port_undef.inc"
+ *
+ * This file is private and must not be included by users!
+ */
 
 #if !((defined(__STDC_VERSION__) && __STDC_VERSION__ >= 199901L) || \
       (defined(__cplusplus) && __cplusplus >= 201103L) ||           \
 #define UPB_FORCEINLINE __inline__ __attribute__((always_inline))
 #define UPB_NOINLINE __attribute__((noinline))
 #define UPB_NORETURN __attribute__((__noreturn__))
+#define UPB_PRINTF(str, first_vararg) __attribute__((format (printf, str, first_vararg)))
 #elif defined(_MSC_VER)
 #define UPB_NOINLINE
 #define UPB_FORCEINLINE
 #define UPB_NORETURN __declspec(noreturn)
+#define UPB_PRINTF(str, first_vararg)
 #else  /* !defined(__GNUC__) */
 #define UPB_FORCEINLINE
 #define UPB_NOINLINE
 #define UPB_NORETURN
+#define UPB_PRINTF(str, first_vararg)
 #endif
 
 #define UPB_MAX(x, y) ((x) > (y) ? (x) : (y))
 #define UPB_LONGJMP(buf, val) longjmp(buf, val)
 #endif
 
+/* UPB_PTRADD(ptr, ofs): add pointer while avoiding "NULL + 0" UB */
+#define UPB_PTRADD(ptr, ofs) ((ofs) ? (ptr) + (ofs) : (ptr))
+
 /* Configure whether fasttable is switched on or not. *************************/
 
-#if defined(__x86_64__) && defined(__GNUC__)
+#ifdef __has_attribute
+#define UPB_HAS_ATTRIBUTE(x) __has_attribute(x)
+#else
+#define UPB_HAS_ATTRIBUTE(x) 0
+#endif
+
+#if UPB_HAS_ATTRIBUTE(musttail)
+#define UPB_MUSTTAIL __attribute__((musttail))
+#else
+#define UPB_MUSTTAIL
+#endif
+
+#undef UPB_HAS_ATTRIBUTE
+
+/* This check is not fully robust: it does not require that we have "musttail"
+ * support available. We need tail calls to avoid consuming arbitrary amounts
+ * of stack space.
+ *
+ * GCC/Clang can mostly be trusted to generate tail calls as long as
+ * optimization is enabled, but, debug builds will not generate tail calls
+ * unless "musttail" is available.
+ *
+ * We should probably either:
+ *   1. require that the compiler supports musttail.
+ *   2. add some fallback code for when musttail isn't available (ie. return
+ *      instead of tail calling). This is safe and portable, but this comes at
+ *      a CPU cost.
+ */
+#if (defined(__x86_64__) || defined(__aarch64__)) && defined(__GNUC__)
 #define UPB_FASTTABLE_SUPPORTED 1
 #else
 #define UPB_FASTTABLE_SUPPORTED 0
  * for example for testing or benchmarking. */
 #if defined(UPB_ENABLE_FASTTABLE)
 #if !UPB_FASTTABLE_SUPPORTED
-#error fasttable is x86-64 + Clang/GCC only
+#error fasttable is x86-64/ARM64 only and requires GCC or Clang.
 #endif
 #define UPB_FASTTABLE 1
 /* Define UPB_TRY_ENABLE_FASTTABLE to use fasttable if possible.
@@ -189,4 +250,4 @@ void __asan_unpoison_memory_region(void const volatile *addr, size_t size);
   ((void)(addr), (void)(size))
 #define UPB_UNPOISON_MEMORY_REGION(addr, size) \
   ((void)(addr), (void)(size))
-#endif 
+#endif
index b7be52c..70956df 100644 (file)
@@ -1,24 +1,61 @@
+/*
+ * Copyright (c) 2009-2021, Google LLC
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ *     * Redistributions of source code must retain the above copyright
+ *       notice, this list of conditions and the following disclaimer.
+ *     * Redistributions in binary form must reproduce the above copyright
+ *       notice, this list of conditions and the following disclaimer in the
+ *       documentation and/or other materials provided with the distribution.
+ *     * Neither the name of Google LLC nor the
+ *       names of its contributors may be used to endorse or promote products
+ *       derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+ * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ * DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+ * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+ * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+ * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
 /* See port_def.inc.  This should #undef all macros #defined there. */
 
-#undef UPB_MAPTYPE_STRING
 #undef UPB_SIZE
 #undef UPB_PTR_AT
 #undef UPB_READ_ONEOF
 #undef UPB_WRITE_ONEOF
+#undef UPB_MAPTYPE_STRING
 #undef UPB_INLINE
 #undef UPB_ALIGN_UP
 #undef UPB_ALIGN_DOWN
 #undef UPB_ALIGN_MALLOC
 #undef UPB_ALIGN_OF
+#undef UPB_LIKELY
+#undef UPB_UNLIKELY
 #undef UPB_FORCEINLINE
 #undef UPB_NOINLINE
 #undef UPB_NORETURN
+#undef UPB_PRINTF
 #undef UPB_MAX
 #undef UPB_MIN
 #undef UPB_UNUSED
 #undef UPB_ASSUME
 #undef UPB_ASSERT
 #undef UPB_UNREACHABLE
+#undef UPB_SETJMP
+#undef UPB_LONGJMP
+#undef UPB_PTRADD
+#undef UPB_MUSTTAIL
+#undef UPB_FASTTABLE_SUPPORTED
+#undef UPB_FASTTABLE
+#undef UPB_FASTTABLE_INIT
 #undef UPB_POISON_MEMORY_REGION
 #undef UPB_UNPOISON_MEMORY_REGION
 #undef UPB_ASAN
index a233d96..b562190 100644 (file)
@@ -1,8 +1,34 @@
+/*
+ * Copyright (c) 2009-2021, Google LLC
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ *     * Redistributions of source code must retain the above copyright
+ *       notice, this list of conditions and the following disclaimer.
+ *     * Redistributions in binary form must reproduce the above copyright
+ *       notice, this list of conditions and the following disclaimer in the
+ *       documentation and/or other materials provided with the distribution.
+ *     * Neither the name of Google LLC nor the
+ *       names of its contributors may be used to endorse or promote products
+ *       derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+ * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ * DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+ * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+ * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+ * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
 
 #include "upb/reflection.h"
 
 #include <string.h>
-#include "upb/table.int.h"
+#include "upb/table_internal.h"
 #include "upb/msg.h"
 
 #include "upb/port_def.inc"
@@ -113,40 +139,7 @@ upb_msgval upb_msg_get(const upb_msg *msg, const upb_fielddef *f) {
   if (!upb_fielddef_haspresence(f) || upb_msg_has(msg, f)) {
     return _upb_msg_getraw(msg, f);
   } else {
-    /* TODO(haberman): change upb_fielddef to not require this switch(). */
-    upb_msgval val = {0};
-    switch (upb_fielddef_type(f)) {
-      case UPB_TYPE_INT32:
-      case UPB_TYPE_ENUM:
-        val.int32_val = upb_fielddef_defaultint32(f);
-        break;
-      case UPB_TYPE_INT64:
-        val.int64_val = upb_fielddef_defaultint64(f);
-        break;
-      case UPB_TYPE_UINT32:
-        val.uint32_val = upb_fielddef_defaultuint32(f);
-        break;
-      case UPB_TYPE_UINT64:
-        val.uint64_val = upb_fielddef_defaultuint64(f);
-        break;
-      case UPB_TYPE_FLOAT:
-        val.float_val = upb_fielddef_defaultfloat(f);
-        break;
-      case UPB_TYPE_DOUBLE:
-        val.double_val = upb_fielddef_defaultdouble(f);
-        break;
-      case UPB_TYPE_BOOL:
-        val.bool_val = upb_fielddef_defaultbool(f);
-        break;
-      case UPB_TYPE_STRING:
-      case UPB_TYPE_BYTES:
-        val.str_val.data = upb_fielddef_defaultstr(f, &val.str_val.size);
-        break;
-      case UPB_TYPE_MESSAGE:
-        val.msg_val = NULL;
-        break;
-    }
-    return val;
+    return upb_fielddef_default(f);
   }
 }
 
@@ -333,10 +326,9 @@ void upb_array_set(upb_array *arr, size_t i, upb_msgval val) {
 }
 
 bool upb_array_append(upb_array *arr, upb_msgval val, upb_arena *arena) {
-  if (!_upb_array_realloc(arr, arr->len + 1, arena)) {
+  if (!upb_array_resize(arr, arr->len + 1, arena)) {
     return false;
   }
-  arr->len++;
   upb_array_set(arr, arr->len - 1, val);
   return true;
 }
index 0133630..f0eb0d4 100644 (file)
@@ -1,3 +1,29 @@
+/*
+ * Copyright (c) 2009-2021, Google LLC
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ *     * Redistributions of source code must retain the above copyright
+ *       notice, this list of conditions and the following disclaimer.
+ *     * Redistributions in binary form must reproduce the above copyright
+ *       notice, this list of conditions and the following disclaimer in the
+ *       documentation and/or other materials provided with the distribution.
+ *     * Neither the name of Google LLC nor the
+ *       names of its contributors may be used to endorse or promote products
+ *       derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+ * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ * DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+ * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+ * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+ * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
 
 #ifndef UPB_REFLECTION_H_
 #define UPB_REFLECTION_H_
@@ -8,6 +34,10 @@
 
 #include "upb/port_def.inc"
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 typedef union {
   bool bool_val;
   float float_val;
@@ -28,6 +58,8 @@ typedef union {
   upb_array* array;
 } upb_mutmsgval;
 
+upb_msgval upb_fielddef_default(const upb_fielddef *f);
+
 /** upb_msg *******************************************************************/
 
 /* Creates a new message of the given type in the given arena. */
@@ -78,17 +110,9 @@ bool upb_msg_next(const upb_msg *msg, const upb_msgdef *m,
                   const upb_symtab *ext_pool, const upb_fielddef **f,
                   upb_msgval *val, size_t *iter);
 
-/* Adds unknown data (serialized protobuf data) to the given message.  The data
- * is copied into the message instance. */
-void upb_msg_addunknown(upb_msg *msg, const char *data, size_t len,
-                        upb_arena *arena);
-
 /* Clears all unknown field data from this message and all submessages. */
 bool upb_msg_discardunknown(upb_msg *msg, const upb_msgdef *m, int maxdepth);
 
-/* Returns a reference to the message's unknown data. */
-const char *upb_msg_getunknown(const upb_msg *msg, size_t *len);
-
 /** upb_array *****************************************************************/
 
 /* Creates a new array on the given arena that holds elements of this type. */
@@ -163,6 +187,10 @@ upb_msgval upb_mapiter_value(const upb_map *map, size_t iter);
  * iterator must not have been initialized const. */
 void upb_mapiter_setvalue(upb_map *map, size_t iter, upb_msgval value);
 
+#ifdef __cplusplus
+}  /* extern "C" */
+#endif
+
 #include "upb/port_undef.inc"
 
 #endif /* UPB_REFLECTION_H_ */
diff --git a/third_party/upb/upb/reflection.hpp b/third_party/upb/upb/reflection.hpp
new file mode 100644 (file)
index 0000000..e144ee3
--- /dev/null
@@ -0,0 +1,37 @@
+// Copyright (c) 2009-2021, Google LLC
+// All rights reserved.
+//
+// Redistribution and use in source and binary forms, with or without
+// modification, are permitted provided that the following conditions are met:
+//     * Redistributions of source code must retain the above copyright
+//       notice, this list of conditions and the following disclaimer.
+//     * Redistributions in binary form must reproduce the above copyright
+//       notice, this list of conditions and the following disclaimer in the
+//       documentation and/or other materials provided with the distribution.
+//     * Neither the name of Google LLC nor the
+//       names of its contributors may be used to endorse or promote products
+//       derived from this software without specific prior written permission.
+//
+// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+// WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+// DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+// DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+// (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+// LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+// ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+// SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+#ifndef UPB_REFLECTION_HPP_
+#define UPB_REFLECTION_HPP_
+
+#include "upb/reflection.h"
+
+namespace upb {
+
+typedef upb_msgval MessageValue;
+
+}  // namespace upb
+
+#endif  // UPB_REFLECTION_HPP_
diff --git a/third_party/upb/upb/sink.c b/third_party/upb/upb/sink.c
deleted file mode 100644 (file)
index d55d258..0000000
+++ /dev/null
@@ -1,17 +0,0 @@
-
-#include "upb/sink.h"
-
-bool upb_bufsrc_putbuf(const char *buf, size_t len, upb_bytessink sink) {
-  void *subc;
-  bool ret;
-  upb_bufhandle handle = UPB_BUFHANDLE_INIT;
-  handle.buf = buf;
-  ret = upb_bytessink_start(sink, len, &subc);
-  if (ret && len != 0) {
-    ret = (upb_bytessink_putbuf(sink, subc, buf, len, &handle) >= len);
-  }
-  if (ret) {
-    ret = upb_bytessink_end(sink);
-  }
-  return ret;
-}
diff --git a/third_party/upb/upb/sink.h b/third_party/upb/upb/sink.h
deleted file mode 100644 (file)
index 871a8f5..0000000
+++ /dev/null
@@ -1,517 +0,0 @@
-/*
-** upb::Sink (upb_sink)
-** upb::BytesSink (upb_bytessink)
-**
-** A upb_sink is an object that binds a upb_handlers object to some runtime
-** state.  It is the object that can actually receive data via the upb_handlers
-** interface.
-**
-** Unlike upb_def and upb_handlers, upb_sink is never frozen, immutable, or
-** thread-safe.  You can create as many of them as you want, but each one may
-** only be used in a single thread at a time.
-**
-** If we compare with class-based OOP, a you can think of a upb_def as an
-** abstract base class, a upb_handlers as a concrete derived class, and a
-** upb_sink as an object (class instance).
-*/
-
-#ifndef UPB_SINK_H
-#define UPB_SINK_H
-
-#include "upb/handlers.h"
-
-#include "upb/port_def.inc"
-
-#ifdef __cplusplus
-namespace upb {
-class BytesSink;
-class Sink;
-}
-#endif
-
-/* upb_sink *******************************************************************/
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-typedef struct {
-  const upb_handlers *handlers;
-  void *closure;
-} upb_sink;
-
-#define PUTVAL(type, ctype)                                           \
-  UPB_INLINE bool upb_sink_put##type(upb_sink s, upb_selector_t sel,  \
-                                     ctype val) {                     \
-    typedef upb_##type##_handlerfunc functype;                        \
-    functype *func;                                                   \
-    const void *hd;                                                   \
-    if (!s.handlers) return true;                                     \
-    func = (functype *)upb_handlers_gethandler(s.handlers, sel, &hd); \
-    if (!func) return true;                                           \
-    return func(s.closure, hd, val);                                  \
-  }
-
-PUTVAL(int32,  int32_t)
-PUTVAL(int64,  int64_t)
-PUTVAL(uint32, uint32_t)
-PUTVAL(uint64, uint64_t)
-PUTVAL(float,  float)
-PUTVAL(double, double)
-PUTVAL(bool,   bool)
-#undef PUTVAL
-
-UPB_INLINE void upb_sink_reset(upb_sink *s, const upb_handlers *h, void *c) {
-  s->handlers = h;
-  s->closure = c;
-}
-
-UPB_INLINE size_t upb_sink_putstring(upb_sink s, upb_selector_t sel,
-                                     const char *buf, size_t n,
-                                     const upb_bufhandle *handle) {
-  typedef upb_string_handlerfunc func;
-  func *handler;
-  const void *hd;
-  if (!s.handlers) return n;
-  handler = (func *)upb_handlers_gethandler(s.handlers, sel, &hd);
-
-  if (!handler) return n;
-  return handler(s.closure, hd, buf, n, handle);
-}
-
-UPB_INLINE bool upb_sink_putunknown(upb_sink s, const char *buf, size_t n) {
-  typedef upb_unknown_handlerfunc func;
-  func *handler;
-  const void *hd;
-  if (!s.handlers) return true;
-  handler =
-      (func *)upb_handlers_gethandler(s.handlers, UPB_UNKNOWN_SELECTOR, &hd);
-
-  if (!handler) return n;
-  return handler(s.closure, hd, buf, n);
-}
-
-UPB_INLINE bool upb_sink_startmsg(upb_sink s) {
-  typedef upb_startmsg_handlerfunc func;
-  func *startmsg;
-  const void *hd;
-  if (!s.handlers) return true;
-  startmsg =
-      (func *)upb_handlers_gethandler(s.handlers, UPB_STARTMSG_SELECTOR, &hd);
-
-  if (!startmsg) return true;
-  return startmsg(s.closure, hd);
-}
-
-UPB_INLINE bool upb_sink_endmsg(upb_sink s, upb_status *status) {
-  typedef upb_endmsg_handlerfunc func;
-  func *endmsg;
-  const void *hd;
-  if (!s.handlers) return true;
-  endmsg =
-      (func *)upb_handlers_gethandler(s.handlers, UPB_ENDMSG_SELECTOR, &hd);
-
-  if (!endmsg) return true;
-  return endmsg(s.closure, hd, status);
-}
-
-UPB_INLINE bool upb_sink_startseq(upb_sink s, upb_selector_t sel,
-                                  upb_sink *sub) {
-  typedef upb_startfield_handlerfunc func;
-  func *startseq;
-  const void *hd;
-  sub->closure = s.closure;
-  sub->handlers = s.handlers;
-  if (!s.handlers) return true;
-  startseq = (func*)upb_handlers_gethandler(s.handlers, sel, &hd);
-
-  if (!startseq) return true;
-  sub->closure = startseq(s.closure, hd);
-  return sub->closure ? true : false;
-}
-
-UPB_INLINE bool upb_sink_endseq(upb_sink s, upb_selector_t sel) {
-  typedef upb_endfield_handlerfunc func;
-  func *endseq;
-  const void *hd;
-  if (!s.handlers) return true;
-  endseq = (func*)upb_handlers_gethandler(s.handlers, sel, &hd);
-
-  if (!endseq) return true;
-  return endseq(s.closure, hd);
-}
-
-UPB_INLINE bool upb_sink_startstr(upb_sink s, upb_selector_t sel,
-                                  size_t size_hint, upb_sink *sub) {
-  typedef upb_startstr_handlerfunc func;
-  func *startstr;
-  const void *hd;
-  sub->closure = s.closure;
-  sub->handlers = s.handlers;
-  if (!s.handlers) return true;
-  startstr = (func*)upb_handlers_gethandler(s.handlers, sel, &hd);
-
-  if (!startstr) return true;
-  sub->closure = startstr(s.closure, hd, size_hint);
-  return sub->closure ? true : false;
-}
-
-UPB_INLINE bool upb_sink_endstr(upb_sink s, upb_selector_t sel) {
-  typedef upb_endfield_handlerfunc func;
-  func *endstr;
-  const void *hd;
-  if (!s.handlers) return true;
-  endstr = (func*)upb_handlers_gethandler(s.handlers, sel, &hd);
-
-  if (!endstr) return true;
-  return endstr(s.closure, hd);
-}
-
-UPB_INLINE bool upb_sink_startsubmsg(upb_sink s, upb_selector_t sel,
-                                     upb_sink *sub) {
-  typedef upb_startfield_handlerfunc func;
-  func *startsubmsg;
-  const void *hd;
-  sub->closure = s.closure;
-  if (!s.handlers) {
-    sub->handlers = NULL;
-    return true;
-  }
-  sub->handlers = upb_handlers_getsubhandlers_sel(s.handlers, sel);
-  startsubmsg = (func*)upb_handlers_gethandler(s.handlers, sel, &hd);
-
-  if (!startsubmsg) return true;
-  sub->closure = startsubmsg(s.closure, hd);
-  return sub->closure ? true : false;
-}
-
-UPB_INLINE bool upb_sink_endsubmsg(upb_sink s, upb_sink sub,
-                                   upb_selector_t sel) {
-  typedef upb_endfield_handlerfunc func;
-  func *endsubmsg;
-  const void *hd;
-  if (!s.handlers) return true;
-  endsubmsg = (func*)upb_handlers_gethandler(s.handlers, sel, &hd);
-
-  if (!endsubmsg) return true;
-  return endsubmsg(sub.closure, hd);
-}
-
-#ifdef __cplusplus
-}  /* extern "C" */
-
-/* A upb::Sink is an object that binds a upb::Handlers object to some runtime
- * state.  It represents an endpoint to which data can be sent.
- *
- * TODO(haberman): right now all of these functions take selectors.  Should they
- * take selectorbase instead?
- *
- * ie. instead of calling:
- *   sink->StartString(FOO_FIELD_START_STRING, ...)
- * a selector base would let you say:
- *   sink->StartString(FOO_FIELD, ...)
- *
- * This would make call sites a little nicer and require emitting fewer selector
- * definitions in .h files.
- *
- * But the current scheme has the benefit that you can retrieve a function
- * pointer for any handler with handlers->GetHandler(selector), without having
- * to have a separate GetHandler() function for each handler type.  The JIT
- * compiler uses this.  To accommodate we'd have to expose a separate
- * GetHandler() for every handler type.
- *
- * Also to ponder: selectors right now are independent of a specific Handlers
- * instance.  In other words, they allocate a number to every possible handler
- * that *could* be registered, without knowing anything about what handlers
- * *are* registered.  That means that using selectors as table offsets prohibits
- * us from compacting the handler table at Freeze() time.  If the table is very
- * sparse, this could be wasteful.
- *
- * Having another selector-like thing that is specific to a Handlers instance
- * would allow this compacting, but then it would be impossible to write code
- * ahead-of-time that can be bound to any Handlers instance at runtime.  For
- * example, a .proto file parser written as straight C will not know what
- * Handlers it will be bound to, so when it calls sink->StartString() what
- * selector will it pass?  It needs a selector like we have today, that is
- * independent of any particular upb::Handlers.
- *
- * Is there a way then to allow Handlers table compaction? */
-class upb::Sink {
- public:
-  /* Constructor with no initialization; must be Reset() before use. */
-  Sink() {}
-
-  Sink(const Sink&) = default;
-  Sink& operator=(const Sink&) = default;
-
-  Sink(const upb_sink& sink) : sink_(sink) {}
-  Sink &operator=(const upb_sink &sink) {
-    sink_ = sink;
-    return *this;
-  }
-
-  upb_sink sink() { return sink_; }
-
-  /* Constructs a new sink for the given frozen handlers and closure.
-   *
-   * TODO: once the Handlers know the expected closure type, verify that T
-   * matches it. */
-  template <class T> Sink(const upb_handlers* handlers, T* closure) {
-    Reset(handlers, closure);
-  }
-
-  upb_sink* ptr() { return &sink_; }
-
-  /* Resets the value of the sink. */
-  template <class T> void Reset(const upb_handlers* handlers, T* closure) {
-    upb_sink_reset(&sink_, handlers, closure);
-  }
-
-  /* Returns the top-level object that is bound to this sink.
-   *
-   * TODO: once the Handlers know the expected closure type, verify that T
-   * matches it. */
-  template <class T> T* GetObject() const {
-    return static_cast<T*>(sink_.closure);
-  }
-
-  /* Functions for pushing data into the sink.
-   *
-   * These return false if processing should stop (either due to error or just
-   * to suspend).
-   *
-   * These may not be called from within one of the same sink's handlers (in
-   * other words, handlers are not re-entrant). */
-
-  /* Should be called at the start and end of every message; both the top-level
-   * message and submessages.  This means that submessages should use the
-   * following sequence:
-   *   sink->StartSubMessage(startsubmsg_selector);
-   *   sink->StartMessage();
-   *   // ...
-   *   sink->EndMessage(&status);
-   *   sink->EndSubMessage(endsubmsg_selector); */
-  bool StartMessage() { return upb_sink_startmsg(sink_); }
-  bool EndMessage(upb_status *status) {
-    return upb_sink_endmsg(sink_, status);
-  }
-
-  /* Putting of individual values.  These work for both repeated and
-   * non-repeated fields, but for repeated fields you must wrap them in
-   * calls to StartSequence()/EndSequence(). */
-  bool PutInt32(HandlersPtr::Selector s, int32_t val) {
-    return upb_sink_putint32(sink_, s, val);
-  }
-
-  bool PutInt64(HandlersPtr::Selector s, int64_t val) {
-    return upb_sink_putint64(sink_, s, val);
-  }
-
-  bool PutUInt32(HandlersPtr::Selector s, uint32_t val) {
-    return upb_sink_putuint32(sink_, s, val);
-  }
-
-  bool PutUInt64(HandlersPtr::Selector s, uint64_t val) {
-    return upb_sink_putuint64(sink_, s, val);
-  }
-
-  bool PutFloat(HandlersPtr::Selector s, float val) {
-    return upb_sink_putfloat(sink_, s, val);
-  }
-
-  bool PutDouble(HandlersPtr::Selector s, double val) {
-    return upb_sink_putdouble(sink_, s, val);
-  }
-
-  bool PutBool(HandlersPtr::Selector s, bool val) {
-    return upb_sink_putbool(sink_, s, val);
-  }
-
-  /* Putting of string/bytes values.  Each string can consist of zero or more
-   * non-contiguous buffers of data.
-   *
-   * For StartString(), the function will write a sink for the string to "sub."
-   * The sub-sink must be used for any/all PutStringBuffer() calls. */
-  bool StartString(HandlersPtr::Selector s, size_t size_hint, Sink* sub) {
-    upb_sink sub_c;
-    bool ret = upb_sink_startstr(sink_, s, size_hint, &sub_c);
-    *sub = sub_c;
-    return ret;
-  }
-
-  size_t PutStringBuffer(HandlersPtr::Selector s, const char *buf, size_t len,
-                         const upb_bufhandle *handle) {
-    return upb_sink_putstring(sink_, s, buf, len, handle);
-  }
-
-  bool EndString(HandlersPtr::Selector s) {
-    return upb_sink_endstr(sink_, s);
-  }
-
-  /* For submessage fields.
-   *
-   * For StartSubMessage(), the function will write a sink for the string to
-   * "sub." The sub-sink must be used for any/all handlers called within the
-   * submessage. */
-  bool StartSubMessage(HandlersPtr::Selector s, Sink* sub) {
-    upb_sink sub_c;
-    bool ret = upb_sink_startsubmsg(sink_, s, &sub_c);
-    *sub = sub_c;
-    return ret;
-  }
-
-  bool EndSubMessage(HandlersPtr::Selector s, Sink sub) {
-    return upb_sink_endsubmsg(sink_, sub.sink_, s);
-  }
-
-  /* For repeated fields of any type, the sequence of values must be wrapped in
-   * these calls.
-   *
-   * For StartSequence(), the function will write a sink for the string to
-   * "sub." The sub-sink must be used for any/all handlers called within the
-   * sequence. */
-  bool StartSequence(HandlersPtr::Selector s, Sink* sub) {
-    upb_sink sub_c;
-    bool ret = upb_sink_startseq(sink_, s, &sub_c);
-    *sub = sub_c;
-    return ret;
-  }
-
-  bool EndSequence(HandlersPtr::Selector s) {
-    return upb_sink_endseq(sink_, s);
-  }
-
-  /* Copy and assign specifically allowed.
-   * We don't even bother making these members private because so many
-   * functions need them and this is mainly just a dumb data container anyway.
-   */
-
- private:
-  upb_sink sink_;
-};
-
-#endif  /* __cplusplus */
-
-/* upb_bytessink **************************************************************/
-
-typedef struct {
-  const upb_byteshandler *handler;
-  void *closure;
-} upb_bytessink ;
-
-UPB_INLINE void upb_bytessink_reset(upb_bytessink* s, const upb_byteshandler *h,
-                                    void *closure) {
-  s->handler = h;
-  s->closure = closure;
-}
-
-UPB_INLINE bool upb_bytessink_start(upb_bytessink s, size_t size_hint,
-                                    void **subc) {
-  typedef upb_startstr_handlerfunc func;
-  func *start;
-  *subc = s.closure;
-  if (!s.handler) return true;
-  start = (func *)s.handler->table[UPB_STARTSTR_SELECTOR].func;
-
-  if (!start) return true;
-  *subc = start(s.closure,
-                s.handler->table[UPB_STARTSTR_SELECTOR].attr.handler_data,
-                size_hint);
-  return *subc != NULL;
-}
-
-UPB_INLINE size_t upb_bytessink_putbuf(upb_bytessink s, void *subc,
-                                       const char *buf, size_t size,
-                                       const upb_bufhandle* handle) {
-  typedef upb_string_handlerfunc func;
-  func *putbuf;
-  if (!s.handler) return true;
-  putbuf = (func *)s.handler->table[UPB_STRING_SELECTOR].func;
-
-  if (!putbuf) return true;
-  return putbuf(subc, s.handler->table[UPB_STRING_SELECTOR].attr.handler_data,
-                buf, size, handle);
-}
-
-UPB_INLINE bool upb_bytessink_end(upb_bytessink s) {
-  typedef upb_endfield_handlerfunc func;
-  func *end;
-  if (!s.handler) return true;
-  end = (func *)s.handler->table[UPB_ENDSTR_SELECTOR].func;
-
-  if (!end) return true;
-  return end(s.closure,
-             s.handler->table[UPB_ENDSTR_SELECTOR].attr.handler_data);
-}
-
-#ifdef __cplusplus
-
-class upb::BytesSink {
- public:
-  BytesSink() {}
-
-  BytesSink(const BytesSink&) = default;
-  BytesSink& operator=(const BytesSink&) = default;
-
-  BytesSink(const upb_bytessink& sink) : sink_(sink) {}
-  BytesSink &operator=(const upb_bytessink &sink) {
-    sink_ = sink;
-    return *this;
-  }
-
-  upb_bytessink sink() { return sink_; }
-
-  /* Constructs a new sink for the given frozen handlers and closure.
-   *
-   * TODO(haberman): once the Handlers know the expected closure type, verify
-   * that T matches it. */
-  template <class T> BytesSink(const upb_byteshandler* handler, T* closure) {
-    upb_bytessink_reset(sink_, handler, closure);
-  }
-
-  /* Resets the value of the sink. */
-  template <class T> void Reset(const upb_byteshandler* handler, T* closure) {
-    upb_bytessink_reset(&sink_, handler, closure);
-  }
-
-  bool Start(size_t size_hint, void **subc) {
-    return upb_bytessink_start(sink_, size_hint, subc);
-  }
-
-  size_t PutBuffer(void *subc, const char *buf, size_t len,
-                   const upb_bufhandle *handle) {
-    return upb_bytessink_putbuf(sink_, subc, buf, len, handle);
-  }
-
-  bool End() {
-    return upb_bytessink_end(sink_);
-  }
-
- private:
-  upb_bytessink sink_;
-};
-
-#endif  /* __cplusplus */
-
-/* upb_bufsrc *****************************************************************/
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-bool upb_bufsrc_putbuf(const char *buf, size_t len, upb_bytessink sink);
-
-#ifdef __cplusplus
-}  /* extern "C" */
-
-namespace upb {
-template <class T> bool PutBuffer(const T& str, BytesSink sink) {
-  return upb_bufsrc_putbuf(str.data(), str.size(), sink.sink());
-}
-}
-
-#endif  /* __cplusplus */
-
-#include "upb/port_undef.inc"
-
-#endif
index 8837047..21e42ac 100644 (file)
@@ -1,13 +1,39 @@
 /*
-** upb_table Implementation
-**
-** Implementation is heavily inspired by Lua's ltable.c.
-*/
+ * Copyright (c) 2009-2021, Google LLC
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ *     * Redistributions of source code must retain the above copyright
+ *       notice, this list of conditions and the following disclaimer.
+ *     * Redistributions in binary form must reproduce the above copyright
+ *       notice, this list of conditions and the following disclaimer in the
+ *       documentation and/or other materials provided with the distribution.
+ *     * Neither the name of Google LLC nor the
+ *       names of its contributors may be used to endorse or promote products
+ *       derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+ * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ * DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+ * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+ * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+ * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+/*
+ * upb_table Implementation
+ *
+ * Implementation is heavily inspired by Lua's ltable.c.
+ */
 
 #include <string.h>
 
-#include "third_party/wyhash/wyhash.h"
-#include "upb/table.int.h"
+#include "upb/table_internal.h"
 
 /* Must be last. */
 #include "upb/port_def.inc"
@@ -25,9 +51,15 @@ static const double MAX_LOAD = 0.85;
  * cache effects).  The lower this is, the more memory we'll use. */
 static const double MIN_DENSITY = 0.1;
 
-bool is_pow2(uint64_t v) { return v == 0 || (v & (v - 1)) == 0; }
+static bool is_pow2(uint64_t v) { return v == 0 || (v & (v - 1)) == 0; }
+
+static upb_value _upb_value_val(uint64_t val) {
+  upb_value ret;
+  _upb_value_setval(&ret, val);
+  return ret;
+}
 
-int log2ceil(uint64_t v) {
+static int log2ceil(uint64_t v) {
   int ret = 0;
   bool pow2 = is_pow2(v);
   while (v >>= 1) ret++;
@@ -35,11 +67,7 @@ int log2ceil(uint64_t v) {
   return UPB_MIN(UPB_MAXARRSIZE, ret);
 }
 
-char *upb_strdup(const char *s, upb_alloc *a) {
-  return upb_strdup2(s, strlen(s), a);
-}
-
-char *upb_strdup2(const char *s, size_t len, upb_alloc *a) {
+char *upb_strdup2(const char *s, size_t len, upb_arena *a) {
   size_t n;
   char *p;
 
@@ -48,7 +76,7 @@ char *upb_strdup2(const char *s, size_t len, upb_alloc *a) {
   /* Always null-terminate, even if binary data; but don't rely on the input to
    * have a null-terminating byte since it may be a raw binary buffer. */
   n = len + 1;
-  p = upb_malloc(a, n);
+  p = upb_arena_malloc(a, n);
   if (p) {
     memcpy(p, s, len);
     p[len] = 0;
@@ -83,16 +111,24 @@ typedef bool eqlfunc_t(upb_tabkey k1, lookupkey_t k2);
 
 /* Base table (shared code) ***************************************************/
 
-/* For when we need to cast away const. */
-static upb_tabent *mutable_entries(upb_table *t) {
-  return (upb_tabent*)t->entries;
+static uint32_t upb_inthash(uintptr_t key) {
+  return (uint32_t)key;
+}
+
+static const upb_tabent *upb_getentry(const upb_table *t, uint32_t hash) {
+  return t->entries + (hash & t->mask);
 }
 
+static bool upb_arrhas(upb_tabval key) {
+  return key.val != (uint64_t)-1;
+}
+
+
 static bool isfull(upb_table *t) {
   return t->count == t->max_count;
 }
 
-static bool init(upb_table *t, uint8_t size_lg2, upb_alloc *a) {
+static bool init(upb_table *t, uint8_t size_lg2, upb_arena *a) {
   size_t bytes;
 
   t->count = 0;
@@ -101,21 +137,17 @@ static bool init(upb_table *t, uint8_t size_lg2, upb_alloc *a) {
   t->max_count = upb_table_size(t) * MAX_LOAD;
   bytes = upb_table_size(t) * sizeof(upb_tabent);
   if (bytes > 0) {
-    t->entries = upb_malloc(a, bytes);
+    t->entries = upb_arena_malloc(a, bytes);
     if (!t->entries) return false;
-    memset(mutable_entries(t), 0, bytes);
+    memset(t->entries, 0, bytes);
   } else {
     t->entries = NULL;
   }
   return true;
 }
 
-static void uninit(upb_table *t, upb_alloc *a) {
-  upb_free(a, mutable_entries(t));
-}
-
 static upb_tabent *emptyent(upb_table *t, upb_tabent *e) {
-  upb_tabent *begin = mutable_entries(t);
+  upb_tabent *begin = t->entries;
   upb_tabent *end = begin + upb_table_size(t);
   for (e = e + 1; e < end; e++) {
     if (upb_tabent_isempty(e)) return e;
@@ -265,9 +297,9 @@ static size_t begin(const upb_table *t) {
 
 /* A simple "subclass" of upb_table that only adds a hash function for strings. */
 
-static upb_tabkey strcopy(lookupkey_t k2, upb_alloc *a) {
+static upb_tabkey strcopy(lookupkey_t k2, upb_arena *a) {
   uint32_t len = (uint32_t) k2.str.len;
-  char *str = upb_malloc(a, k2.str.len + sizeof(uint32_t) + 1);
+  char *str = upb_arena_malloc(a, k2.str.len + sizeof(uint32_t) + 1);
   if (str == NULL) return 0;
   memcpy(str, &len, sizeof(uint32_t));
   if (k2.str.len) memcpy(str + sizeof(uint32_t), k2.str.str, k2.str.len);
@@ -275,8 +307,143 @@ static upb_tabkey strcopy(lookupkey_t k2, upb_alloc *a) {
   return (uintptr_t)str;
 }
 
+/* Adapted from ABSL's wyhash. */
+
+static uint64_t UnalignedLoad64(const void *p) {
+  uint64_t val;
+  memcpy(&val, p, 8);
+  return val;
+}
+
+static uint32_t UnalignedLoad32(const void *p) {
+  uint32_t val;
+  memcpy(&val, p, 4);
+  return val;
+}
+
+#if defined(_MSC_VER) && defined(_M_X64)
+#include <intrin.h>
+#endif
+
+/* Computes a * b, returning the low 64 bits of the result and storing the high
+ * 64 bits in |*high|. */
+static uint64_t upb_umul128(uint64_t v0, uint64_t v1, uint64_t* out_high) {
+#ifdef __SIZEOF_INT128__
+  __uint128_t p = v0;
+  p *= v1;
+  *out_high = (uint64_t)(p >> 64);
+  return (uint64_t)p;
+#elif defined(_MSC_VER) && defined(_M_X64)
+  return _umul128(v0, v1, out_high);
+#else
+  uint64_t a32 = v0 >> 32;
+  uint64_t a00 = v0 & 0xffffffff;
+  uint64_t b32 = v1 >> 32;
+  uint64_t b00 = v1 & 0xffffffff;
+  uint64_t high = a32 * b32;
+  uint64_t low = a00 * b00;
+  uint64_t mid1 = a32 * b00;
+  uint64_t mid2 = a00 * b32;
+  low += (mid1 << 32) + (mid2 << 32);
+  // Omit carry bit, for mixing we do not care about exact numerical precision.
+  high += (mid1 >> 32) + (mid2 >> 32);
+  *out_high = high;
+  return low;
+#endif
+}
+
+static uint64_t WyhashMix(uint64_t v0, uint64_t v1) {
+  uint64_t high;
+  uint64_t low = upb_umul128(v0, v1, &high);
+  return low ^ high;
+}
+
+static uint64_t Wyhash(const void *data, size_t len, uint64_t seed,
+                       const uint64_t salt[]) {
+  const uint8_t* ptr = (const uint8_t*)data;
+  uint64_t starting_length = (uint64_t)len;
+  uint64_t current_state = seed ^ salt[0];
+
+  if (len > 64) {
+    // If we have more than 64 bytes, we're going to handle chunks of 64
+    // bytes at a time. We're going to build up two separate hash states
+    // which we will then hash together.
+    uint64_t duplicated_state = current_state;
+
+    do {
+      uint64_t a = UnalignedLoad64(ptr);
+      uint64_t b = UnalignedLoad64(ptr + 8);
+      uint64_t c = UnalignedLoad64(ptr + 16);
+      uint64_t d = UnalignedLoad64(ptr + 24);
+      uint64_t e = UnalignedLoad64(ptr + 32);
+      uint64_t f = UnalignedLoad64(ptr + 40);
+      uint64_t g = UnalignedLoad64(ptr + 48);
+      uint64_t h = UnalignedLoad64(ptr + 56);
+
+      uint64_t cs0 = WyhashMix(a ^ salt[1], b ^ current_state);
+      uint64_t cs1 = WyhashMix(c ^ salt[2], d ^ current_state);
+      current_state = (cs0 ^ cs1);
+
+      uint64_t ds0 = WyhashMix(e ^ salt[3], f ^ duplicated_state);
+      uint64_t ds1 = WyhashMix(g ^ salt[4], h ^ duplicated_state);
+      duplicated_state = (ds0 ^ ds1);
+
+      ptr += 64;
+      len -= 64;
+    } while (len > 64);
+
+    current_state = current_state ^ duplicated_state;
+  }
+
+  // We now have a data `ptr` with at most 64 bytes and the current state
+  // of the hashing state machine stored in current_state.
+  while (len > 16) {
+    uint64_t a = UnalignedLoad64(ptr);
+    uint64_t b = UnalignedLoad64(ptr + 8);
+
+    current_state = WyhashMix(a ^ salt[1], b ^ current_state);
+
+    ptr += 16;
+    len -= 16;
+  }
+
+  // We now have a data `ptr` with at most 16 bytes.
+  uint64_t a = 0;
+  uint64_t b = 0;
+  if (len > 8) {
+    // When we have at least 9 and at most 16 bytes, set A to the first 64
+    // bits of the input and B to the last 64 bits of the input. Yes, they will
+    // overlap in the middle if we are working with less than the full 16
+    // bytes.
+    a = UnalignedLoad64(ptr);
+    b = UnalignedLoad64(ptr + len - 8);
+  } else if (len > 3) {
+    // If we have at least 4 and at most 8 bytes, set A to the first 32
+    // bits and B to the last 32 bits.
+    a = UnalignedLoad32(ptr);
+    b = UnalignedLoad32(ptr + len - 4);
+  } else if (len > 0) {
+    // If we have at least 1 and at most 3 bytes, read all of the provided
+    // bits into A, with some adjustments.
+    a = ((ptr[0] << 16) | (ptr[len >> 1] << 8) | ptr[len - 1]);
+    b = 0;
+  } else {
+    a = 0;
+    b = 0;
+  }
+
+  uint64_t w = WyhashMix(a ^ salt[1], b ^ current_state);
+  uint64_t z = salt[1] ^ starting_length;
+  return WyhashMix(w, z);
+}
+
+const uint64_t kWyhashSalt[5] = {
+    0x243F6A8885A308D3ULL, 0x13198A2E03707344ULL, 0xA4093822299F31D0ULL,
+    0x082EFA98EC4E6C89ULL, 0x452821E638D01377ULL,
+};
+
 static uint32_t table_hash(const char *p, size_t n) {
-  return wyhash(p, n, 0, _wyp);
+  return Wyhash(p, n, 0, kWyhashSalt);
 }
 
 static uint32_t strhash(upb_tabkey key) {
@@ -291,9 +458,7 @@ static bool streql(upb_tabkey k1, lookupkey_t k2) {
   return len == k2.str.len && (len == 0 || memcmp(str, k2.str.str, len) == 0);
 }
 
-bool upb_strtable_init2(upb_strtable *t, upb_ctype_t ctype,
-                        size_t expected_size, upb_alloc *a) {
-  UPB_UNUSED(ctype);  /* TODO(haberman): rm */
+bool upb_strtable_init(upb_strtable *t, size_t expected_size, upb_arena *a) {
   // Multiply by approximate reciprocal of MAX_LOAD (0.85), with pow2 denominator.
   size_t need_entries = (expected_size + 1) * 1204 / 1024;
   UPB_ASSERT(need_entries >= expected_size * 0.85);
@@ -307,14 +472,7 @@ void upb_strtable_clear(upb_strtable *t) {
   memset((char*)t->t.entries, 0, bytes);
 }
 
-void upb_strtable_uninit2(upb_strtable *t, upb_alloc *a) {
-  size_t i;
-  for (i = 0; i < upb_table_size(&t->t); i++)
-    upb_free(a, (void*)t->t.entries[i].key);
-  uninit(&t->t, a);
-}
-
-bool upb_strtable_resize(upb_strtable *t, size_t size_lg2, upb_alloc *a) {
+bool upb_strtable_resize(upb_strtable *t, size_t size_lg2, upb_arena *a) {
   upb_strtable new_table;
   upb_strtable_iter i;
 
@@ -323,17 +481,15 @@ bool upb_strtable_resize(upb_strtable *t, size_t size_lg2, upb_alloc *a) {
   upb_strtable_begin(&i, t);
   for ( ; !upb_strtable_done(&i); upb_strtable_next(&i)) {
     upb_strview key = upb_strtable_iter_key(&i);
-    upb_strtable_insert3(
-        &new_table, key.data, key.size,
-        upb_strtable_iter_value(&i), a);
+    upb_strtable_insert(&new_table, key.data, key.size,
+                        upb_strtable_iter_value(&i), a);
   }
-  upb_strtable_uninit2(t, a);
   *t = new_table;
   return true;
 }
 
-bool upb_strtable_insert3(upb_strtable *t, const char *k, size_t len,
-                          upb_value v, upb_alloc *a) {
+bool upb_strtable_insert(upb_strtable *t, const char *k, size_t len,
+                         upb_value v, upb_arena *a) {
   lookupkey_t key;
   upb_tabkey tabkey;
   uint32_t hash;
@@ -360,19 +516,11 @@ bool upb_strtable_lookup2(const upb_strtable *t, const char *key, size_t len,
   return lookup(&t->t, strkey2(key, len), v, hash, &streql);
 }
 
-bool upb_strtable_remove3(upb_strtable *t, const char *key, size_t len,
-                         upb_value *val, upb_alloc *alloc) {
+bool upb_strtable_remove(upb_strtable *t, const char *key, size_t len,
+                         upb_value *val) {
   uint32_t hash = table_hash(key, len);
   upb_tabkey tabkey;
-  if (rm(&t->t, strkey2(key, len), val, &tabkey, hash, &streql)) {
-    if (alloc) {
-      /* Arena-based allocs don't need to free and won't pass this. */
-      upb_free(alloc, (void*)tabkey);
-    }
-    return true;
-  } else {
-    return false;
-  }
+  return rm(&t->t, strkey2(key, len), val, &tabkey, hash, &streql);
 }
 
 /* Iteration */
@@ -470,7 +618,7 @@ static void check(upb_inttable *t) {
 }
 
 bool upb_inttable_sizedinit(upb_inttable *t, size_t asize, int hsize_lg2,
-                            upb_alloc *a) {
+                            upb_arena *a) {
   size_t array_bytes;
 
   if (!init(&t->t, hsize_lg2, a)) return false;
@@ -479,9 +627,8 @@ bool upb_inttable_sizedinit(upb_inttable *t, size_t asize, int hsize_lg2,
   t->array_size = UPB_MAX(1, asize);
   t->array_count = 0;
   array_bytes = t->array_size * sizeof(upb_value);
-  t->array = upb_malloc(a, array_bytes);
+  t->array = upb_arena_malloc(a, array_bytes);
   if (!t->array) {
-    uninit(&t->t, a);
     return false;
   }
   memset(mutable_array(t), 0xff, array_bytes);
@@ -489,18 +636,12 @@ bool upb_inttable_sizedinit(upb_inttable *t, size_t asize, int hsize_lg2,
   return true;
 }
 
-bool upb_inttable_init2(upb_inttable *t, upb_ctype_t ctype, upb_alloc *a) {
-  UPB_UNUSED(ctype);  /* TODO(haberman): rm */
+bool upb_inttable_init(upb_inttable *t, upb_arena *a) {
   return upb_inttable_sizedinit(t, 0, 4, a);
 }
 
-void upb_inttable_uninit2(upb_inttable *t, upb_alloc *a) {
-  uninit(&t->t, a);
-  upb_free(a, mutable_array(t));
-}
-
-bool upb_inttable_insert2(upb_inttable *t, uintptr_t key, upb_value val,
-                          upb_alloc *a) {
+bool upb_inttable_insert(upb_inttable *t, uintptr_t key, upb_value val,
+                         upb_arena *a) {
   upb_tabval tabval;
   tabval.val = val.val;
   UPB_ASSERT(upb_arrhas(tabval));  /* This will reject (uint64_t)-1.  Fix this. */
@@ -531,7 +672,6 @@ bool upb_inttable_insert2(upb_inttable *t, uintptr_t key, upb_value val,
 
       UPB_ASSERT(t->t.count == new_table.count);
 
-      uninit(&t->t, a);
       t->t = new_table;
     }
     insert(&t->t, intkey(key), key, val, upb_inthash(key), &inthash, &inteql);
@@ -575,21 +715,7 @@ bool upb_inttable_remove(upb_inttable *t, uintptr_t key, upb_value *val) {
   return success;
 }
 
-bool upb_inttable_insertptr2(upb_inttable *t, const void *key, upb_value val,
-                             upb_alloc *a) {
-  return upb_inttable_insert2(t, (uintptr_t)key, val, a);
-}
-
-bool upb_inttable_lookupptr(const upb_inttable *t, const void *key,
-                            upb_value *v) {
-  return upb_inttable_lookup(t, (uintptr_t)key, v);
-}
-
-bool upb_inttable_removeptr(upb_inttable *t, const void *key, upb_value *val) {
-  return upb_inttable_remove(t, (uintptr_t)key, val);
-}
-
-void upb_inttable_compact2(upb_inttable *t, upb_alloc *a) {
+void upb_inttable_compact(upb_inttable *t, upb_arena *a) {
   /* A power-of-two histogram of the table keys. */
   size_t counts[UPB_MAXARRSIZE + 1] = {0};
 
@@ -637,12 +763,11 @@ void upb_inttable_compact2(upb_inttable *t, upb_alloc *a) {
     upb_inttable_begin(&i, t);
     for (; !upb_inttable_done(&i); upb_inttable_next(&i)) {
       uintptr_t k = upb_inttable_iter_key(&i);
-      upb_inttable_insert2(&new_t, k, upb_inttable_iter_value(&i), a);
+      upb_inttable_insert(&new_t, k, upb_inttable_iter_value(&i), a);
     }
     UPB_ASSERT(new_t.array_size == arr_size);
     UPB_ASSERT(new_t.t.size_lg2 == hashsize_lg2);
   }
-  upb_inttable_uninit2(t, a);
   *t = new_t;
 }
 
similarity index 60%
rename from third_party/upb/upb/table.int.h
rename to third_party/upb/upb/table_internal.h
index 49caac4..1313686 100644 (file)
@@ -1,21 +1,48 @@
 /*
-** upb_table
-**
-** This header is INTERNAL-ONLY!  Its interfaces are not public or stable!
-** This file defines very fast int->upb_value (inttable) and string->upb_value
-** (strtable) hash tables.
-**
-** The table uses chained scatter with Brent's variation (inspired by the Lua
-** implementation of hash tables).  The hash function for strings is Austin
-** Appleby's "MurmurHash."
-**
-** The inttable uses uintptr_t as its key, which guarantees it can be used to
-** store pointers or integers of at least 32 bits (upb isn't really useful on
-** systems where sizeof(void*) < 4).
-**
-** The table must be homogeneous (all values of the same type).  In debug
-** mode, we check this on insert and lookup.
-*/
+ * Copyright (c) 2009-2021, Google LLC
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ *     * Redistributions of source code must retain the above copyright
+ *       notice, this list of conditions and the following disclaimer.
+ *     * Redistributions in binary form must reproduce the above copyright
+ *       notice, this list of conditions and the following disclaimer in the
+ *       documentation and/or other materials provided with the distribution.
+ *     * Neither the name of Google LLC nor the
+ *       names of its contributors may be used to endorse or promote products
+ *       derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+ * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ * DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+ * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+ * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+ * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+/*
+ * upb_table
+ *
+ * This header is INTERNAL-ONLY!  Its interfaces are not public or stable!
+ * This file defines very fast int->upb_value (inttable) and string->upb_value
+ * (strtable) hash tables.
+ *
+ * The table uses chained scatter with Brent's variation (inspired by the Lua
+ * implementation of hash tables).  The hash function for strings is Austin
+ * Appleby's "MurmurHash."
+ *
+ * The inttable uses uintptr_t as its key, which guarantees it can be used to
+ * store pointers or integers of at least 32 bits (upb isn't really useful on
+ * systems where sizeof(void*) < 4).
+ *
+ * The table must be homogeneous (all values of the same type).  In debug
+ * mode, we check this on insert and lookup.
+ */
 
 #ifndef UPB_TABLE_H_
 #define UPB_TABLE_H_
@@ -33,47 +60,18 @@ extern "C" {
 
 /* upb_value ******************************************************************/
 
-/* A tagged union (stored untagged inside the table) so that we can check that
- * clients calling table accessors are correctly typed without having to have
- * an explosion of accessors. */
-typedef enum {
-  UPB_CTYPE_INT32    = 1,
-  UPB_CTYPE_INT64    = 2,
-  UPB_CTYPE_UINT32   = 3,
-  UPB_CTYPE_UINT64   = 4,
-  UPB_CTYPE_BOOL     = 5,
-  UPB_CTYPE_CSTR     = 6,
-  UPB_CTYPE_PTR      = 7,
-  UPB_CTYPE_CONSTPTR = 8,
-  UPB_CTYPE_FPTR     = 9,
-  UPB_CTYPE_FLOAT    = 10,
-  UPB_CTYPE_DOUBLE   = 11
-} upb_ctype_t;
-
 typedef struct {
   uint64_t val;
 } upb_value;
 
-/* Like strdup(), which isn't always available since it's not ANSI C. */
-char *upb_strdup(const char *s, upb_alloc *a);
 /* Variant that works with a length-delimited rather than NULL-delimited string,
  * as supported by strtable. */
-char *upb_strdup2(const char *s, size_t len, upb_alloc *a);
-
-UPB_INLINE char *upb_gstrdup(const char *s) {
-  return upb_strdup(s, &upb_alloc_global);
-}
+char *upb_strdup2(const char *s, size_t len, upb_arena *a);
 
 UPB_INLINE void _upb_value_setval(upb_value *v, uint64_t val) {
   v->val = val;
 }
 
-UPB_INLINE upb_value _upb_value_val(uint64_t val) {
-  upb_value ret;
-  _upb_value_setval(&ret, val);
-  return ret;
-}
-
 /* For each value ctype, define the following set of functions:
  *
  * // Get/set an int32 from a upb_value.
@@ -181,14 +179,7 @@ typedef struct {
   uint32_t mask;         /* Mask to turn hash value -> bucket. */
   uint32_t max_count;    /* Max count before we hit our load limit. */
   uint8_t size_lg2;      /* Size of the hashtable part is 2^size_lg2 entries. */
-
-  /* Hash table entries.
-   * Making this const isn't entirely accurate; what we really want is for it to
-   * have the same const-ness as the table it's inside.  But there's no way to
-   * declare that in C.  So we have to make it const so that we can statically
-   * initialize const hash tables.  Then we cast away const when we have to.
-   */
-  const upb_tabent *entries;
+  upb_tabent *entries;
 } upb_table;
 
 typedef struct {
@@ -202,8 +193,6 @@ typedef struct {
   size_t array_count;       /* Array part number of elements. */
 } upb_inttable;
 
-#define UPB_ARRAY_EMPTYENT -1
-
 UPB_INLINE size_t upb_table_size(const upb_table *t) {
   if (t->size_lg2 == 0)
     return 0;
@@ -216,48 +205,10 @@ UPB_INLINE bool upb_tabent_isempty(const upb_tabent *e) {
   return e->key == 0;
 }
 
-/* Used by some of the unit tests for generic hashing functionality. */
-uint32_t upb_murmur_hash2(const void * key, size_t len, uint32_t seed);
-
-UPB_INLINE uintptr_t upb_intkey(uintptr_t key) {
-  return key;
-}
-
-UPB_INLINE uint32_t upb_inthash(uintptr_t key) {
-  return (uint32_t)key;
-}
-
-static const upb_tabent *upb_getentry(const upb_table *t, uint32_t hash) {
-  return t->entries + (hash & t->mask);
-}
-
-UPB_INLINE bool upb_arrhas(upb_tabval key) {
-  return key.val != (uint64_t)-1;
-}
-
 /* Initialize and uninitialize a table, respectively.  If memory allocation
  * failed, false is returned that the table is uninitialized. */
-bool upb_inttable_init2(upb_inttable *table, upb_ctype_t ctype, upb_alloc *a);
-bool upb_strtable_init2(upb_strtable *table, upb_ctype_t ctype,
-                        size_t expected_size, upb_alloc *a);
-void upb_inttable_uninit2(upb_inttable *table, upb_alloc *a);
-void upb_strtable_uninit2(upb_strtable *table, upb_alloc *a);
-
-UPB_INLINE bool upb_inttable_init(upb_inttable *table, upb_ctype_t ctype) {
-  return upb_inttable_init2(table, ctype, &upb_alloc_global);
-}
-
-UPB_INLINE bool upb_strtable_init(upb_strtable *table, upb_ctype_t ctype) {
-  return upb_strtable_init2(table, ctype, 4, &upb_alloc_global);
-}
-
-UPB_INLINE void upb_inttable_uninit(upb_inttable *table) {
-  upb_inttable_uninit2(table, &upb_alloc_global);
-}
-
-UPB_INLINE void upb_strtable_uninit(upb_strtable *table) {
-  upb_strtable_uninit2(table, &upb_alloc_global);
-}
+bool upb_inttable_init(upb_inttable *table, upb_arena *a);
+bool upb_strtable_init(upb_strtable *table, size_t expected_size, upb_arena *a);
 
 /* Returns the number of values in the table. */
 size_t upb_inttable_count(const upb_inttable *t);
@@ -265,12 +216,6 @@ UPB_INLINE size_t upb_strtable_count(const upb_strtable *t) {
   return t->t.count;
 }
 
-void upb_inttable_packedsize(const upb_inttable *t, size_t *size);
-void upb_strtable_packedsize(const upb_strtable *t, size_t *size);
-upb_inttable *upb_inttable_pack(const upb_inttable *t, void *p, size_t *ofs,
-                                size_t size);
-upb_strtable *upb_strtable_pack(const upb_strtable *t, void *p, size_t *ofs,
-                                size_t size);
 void upb_strtable_clear(upb_strtable *t);
 
 /* Inserts the given key into the hashtable with the given value.  The key must
@@ -280,26 +225,10 @@ void upb_strtable_clear(upb_strtable *t);
  *
  * If a table resize was required but memory allocation failed, false is
  * returned and the table is unchanged. */
-bool upb_inttable_insert2(upb_inttable *t, uintptr_t key, upb_value val,
-                          upb_alloc *a);
-bool upb_strtable_insert3(upb_strtable *t, const char *key, size_t len,
-                          upb_value val, upb_alloc *a);
-
-UPB_INLINE bool upb_inttable_insert(upb_inttable *t, uintptr_t key,
-                                    upb_value val) {
-  return upb_inttable_insert2(t, key, val, &upb_alloc_global);
-}
-
-UPB_INLINE bool upb_strtable_insert2(upb_strtable *t, const char *key,
-                                     size_t len, upb_value val) {
-  return upb_strtable_insert3(t, key, len, val, &upb_alloc_global);
-}
-
-/* For NULL-terminated strings. */
-UPB_INLINE bool upb_strtable_insert(upb_strtable *t, const char *key,
-                                    upb_value val) {
-  return upb_strtable_insert2(t, key, strlen(key), val);
-}
+bool upb_inttable_insert(upb_inttable *t, uintptr_t key, upb_value val,
+                         upb_arena *a);
+bool upb_strtable_insert(upb_strtable *t, const char *key, size_t len,
+                         upb_value val, upb_arena *a);
 
 /* Looks up key in this table, returning "true" if the key was found.
  * If v is non-NULL, copies the value for this key into *v. */
@@ -316,74 +245,21 @@ UPB_INLINE bool upb_strtable_lookup(const upb_strtable *t, const char *key,
 /* Removes an item from the table.  Returns true if the remove was successful,
  * and stores the removed item in *val if non-NULL. */
 bool upb_inttable_remove(upb_inttable *t, uintptr_t key, upb_value *val);
-bool upb_strtable_remove3(upb_strtable *t, const char *key, size_t len,
-                          upb_value *val, upb_alloc *alloc);
-
-UPB_INLINE bool upb_strtable_remove2(upb_strtable *t, const char *key,
-                                     size_t len, upb_value *val) {
-  return upb_strtable_remove3(t, key, len, val, &upb_alloc_global);
-}
-
-/* For NULL-terminated strings. */
-UPB_INLINE bool upb_strtable_remove(upb_strtable *t, const char *key,
-                                    upb_value *v) {
-  return upb_strtable_remove2(t, key, strlen(key), v);
-}
+bool upb_strtable_remove(upb_strtable *t, const char *key, size_t len,
+                          upb_value *val);
 
 /* Updates an existing entry in an inttable.  If the entry does not exist,
  * returns false and does nothing.  Unlike insert/remove, this does not
  * invalidate iterators. */
 bool upb_inttable_replace(upb_inttable *t, uintptr_t key, upb_value val);
 
-/* Convenience routines for inttables with pointer keys. */
-bool upb_inttable_insertptr2(upb_inttable *t, const void *key, upb_value val,
-                             upb_alloc *a);
-bool upb_inttable_removeptr(upb_inttable *t, const void *key, upb_value *val);
-bool upb_inttable_lookupptr(
-    const upb_inttable *t, const void *key, upb_value *val);
-
-UPB_INLINE bool upb_inttable_insertptr(upb_inttable *t, const void *key,
-                                       upb_value val) {
-  return upb_inttable_insertptr2(t, key, val, &upb_alloc_global);
-}
-
 /* Optimizes the table for the current set of entries, for both memory use and
  * lookup time.  Client should call this after all entries have been inserted;
  * inserting more entries is legal, but will likely require a table resize. */
-void upb_inttable_compact2(upb_inttable *t, upb_alloc *a);
-
-UPB_INLINE void upb_inttable_compact(upb_inttable *t) {
-  upb_inttable_compact2(t, &upb_alloc_global);
-}
-
-/* A special-case inlinable version of the lookup routine for 32-bit
- * integers. */
-UPB_INLINE bool upb_inttable_lookup32(const upb_inttable *t, uint32_t key,
-                                      upb_value *v) {
-  *v = upb_value_int32(0);  /* Silence compiler warnings. */
-  if (key < t->array_size) {
-    upb_tabval arrval = t->array[key];
-    if (upb_arrhas(arrval)) {
-      _upb_value_setval(v, arrval.val);
-      return true;
-    } else {
-      return false;
-    }
-  } else {
-    const upb_tabent *e;
-    if (t->t.entries == NULL) return false;
-    for (e = upb_getentry(&t->t, upb_inthash(key)); true; e = e->next) {
-      if ((uint32_t)e->key == key) {
-        _upb_value_setval(v, e->val.val);
-        return true;
-      }
-      if (e->next == NULL) return false;
-    }
-  }
-}
+void upb_inttable_compact(upb_inttable *t, upb_arena *a);
 
 /* Exposed for testing only. */
-bool upb_strtable_resize(upb_strtable *t, size_t size_lg2, upb_alloc *a);
+bool upb_strtable_resize(upb_strtable *t, size_t size_lg2, upb_arena *a);
 
 /* Iterators ******************************************************************/
 
index 028cc29..6ea2527 100644 (file)
@@ -1,3 +1,29 @@
+/*
+ * Copyright (c) 2009-2021, Google LLC
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ *     * Redistributions of source code must retain the above copyright
+ *       notice, this list of conditions and the following disclaimer.
+ *     * Redistributions in binary form must reproduce the above copyright
+ *       notice, this list of conditions and the following disclaimer in the
+ *       documentation and/or other materials provided with the distribution.
+ *     * Neither the name of Google LLC nor the
+ *       names of its contributors may be used to endorse or promote products
+ *       derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+ * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ * DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+ * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+ * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+ * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
 
 #include "upb/text_encode.h"
 
@@ -28,8 +54,10 @@ static void txtenc_putbytes(txtenc *e, const void *data, size_t len) {
     memcpy(e->ptr, data, len);
     e->ptr += len;
   } else {
-    if (have) memcpy(e->ptr, data, have);
-    e->ptr += have;
+    if (have) {
+      memcpy(e->ptr, data, have);
+      e->ptr += have;
+    }
     e->overflow += (len - have);
   }
 }
@@ -50,7 +78,7 @@ static void txtenc_printf(txtenc *e, const char *fmt, ...) {
   if (UPB_LIKELY(have > n)) {
     e->ptr += n;
   } else {
-    e->ptr += have;
+    e->ptr = UPB_PTRADD(e->ptr, have);
     e->overflow += (n - have);
   }
 }
@@ -408,7 +436,7 @@ size_t upb_text_encode(const upb_msg *msg, const upb_msgdef *m,
 
   e.buf = buf;
   e.ptr = buf;
-  e.end = buf + size;
+  e.end = UPB_PTRADD(buf, size);
   e.overflow = 0;
   e.indent_depth = 0;
   e.options = options;
index 4ad3d1c..9456082 100644 (file)
@@ -1,3 +1,29 @@
+/*
+ * Copyright (c) 2009-2021, Google LLC
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ *     * Redistributions of source code must retain the above copyright
+ *       notice, this list of conditions and the following disclaimer.
+ *     * Redistributions in binary form must reproduce the above copyright
+ *       notice, this list of conditions and the following disclaimer in the
+ *       documentation and/or other materials provided with the distribution.
+ *     * Neither the name of Google LLC nor the
+ *       names of its contributors may be used to endorse or promote products
+ *       derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+ * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ * DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+ * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+ * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+ * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
 
 #ifndef UPB_TEXTENCODE_H_
 #define UPB_TEXTENCODE_H_
index a126569..fd0290b 100644 (file)
@@ -1,5 +1,31 @@
-
-#include "upb/upb.int.h"
+/*
+ * Copyright (c) 2009-2021, Google LLC
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ *     * Redistributions of source code must retain the above copyright
+ *       notice, this list of conditions and the following disclaimer.
+ *     * Redistributions in binary form must reproduce the above copyright
+ *       notice, this list of conditions and the following disclaimer in the
+ *       documentation and/or other materials provided with the distribution.
+ *     * Neither the name of Google LLC nor the
+ *       names of its contributors may be used to endorse or promote products
+ *       derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+ * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ * DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+ * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+ * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+ * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#include "upb/upb_internal.h"
 
 #include <errno.h>
 #include <stdarg.h>
@@ -67,6 +93,19 @@ static void *upb_global_allocfunc(upb_alloc *alloc, void *ptr, size_t oldsize,
   }
 }
 
+static uint32_t *upb_cleanup_pointer(uintptr_t cleanup_metadata) {
+  return (uint32_t *)(cleanup_metadata & ~0x1);
+}
+
+static bool upb_cleanup_has_initial_block(uintptr_t cleanup_metadata) {
+  return cleanup_metadata & 0x1;
+}
+
+static uintptr_t upb_cleanup_metadata(uint32_t *cleanup,
+                                      bool has_initial_block) {
+  return (uintptr_t)cleanup | has_initial_block;
+}
+
 upb_alloc upb_alloc_global = {&upb_global_allocfunc};
 
 /* upb_arena ******************************************************************/
@@ -112,7 +151,8 @@ static void upb_arena_addblock(upb_arena *a, upb_arena *root, void *ptr,
 
   a->head.ptr = UPB_PTR_AT(block, memblock_reserve, char);
   a->head.end = UPB_PTR_AT(block, size, char);
-  a->cleanups = &block->cleanups;
+  a->cleanup_metadata = upb_cleanup_metadata(
+      &block->cleanups, upb_cleanup_has_initial_block(a->cleanup_metadata));
 
   UPB_POISON_MEMORY_REGION(a->head.ptr, a->head.end - a->head.ptr);
 }
@@ -160,6 +200,7 @@ upb_arena *arena_initslow(void *mem, size_t n, upb_alloc *alloc) {
   a->refcount = 1;
   a->freelist = NULL;
   a->freelist_tail = NULL;
+  a->cleanup_metadata = upb_cleanup_metadata(NULL, false);
 
   upb_arena_addblock(a, a, mem, n);
 
@@ -187,7 +228,7 @@ upb_arena *upb_arena_init(void *mem, size_t n, upb_alloc *alloc) {
   a->head.ptr = mem;
   a->head.end = UPB_PTR_AT(mem, n - sizeof(*a), char);
   a->freelist = NULL;
-  a->cleanups = NULL;
+  a->cleanup_metadata = upb_cleanup_metadata(NULL, true);
 
   return a;
 }
@@ -222,15 +263,17 @@ void upb_arena_free(upb_arena *a) {
 
 bool upb_arena_addcleanup(upb_arena *a, void *ud, upb_cleanup_func *func) {
   cleanup_ent *ent;
+  uint32_t* cleanups = upb_cleanup_pointer(a->cleanup_metadata);
 
-  if (!a->cleanups || _upb_arenahas(a) < sizeof(cleanup_ent)) {
+  if (!cleanups || _upb_arenahas(a) < sizeof(cleanup_ent)) {
     if (!upb_arena_allocblock(a, 128)) return false;  /* Out of memory. */
     UPB_ASSERT(_upb_arenahas(a) >= sizeof(cleanup_ent));
+    cleanups = upb_cleanup_pointer(a->cleanup_metadata);
   }
 
   a->head.end -= sizeof(cleanup_ent);
   ent = (cleanup_ent*)a->head.end;
-  (*a->cleanups)++;
+  (*cleanups)++;
   UPB_UNPOISON_MEMORY_REGION(ent, sizeof(cleanup_ent));
 
   ent->cleanup = func;
@@ -239,11 +282,18 @@ bool upb_arena_addcleanup(upb_arena *a, void *ud, upb_cleanup_func *func) {
   return true;
 }
 
-void upb_arena_fuse(upb_arena *a1, upb_arena *a2) {
+bool upb_arena_fuse(upb_arena *a1, upb_arena *a2) {
   upb_arena *r1 = arena_findroot(a1);
   upb_arena *r2 = arena_findroot(a2);
 
-  if (r1 == r2) return;  /* Already fused. */
+  if (r1 == r2) return true;  /* Already fused. */
+
+  /* Do not fuse initial blocks since we cannot lifetime extend them. */
+  if (upb_cleanup_has_initial_block(r1->cleanup_metadata)) return false;
+  if (upb_cleanup_has_initial_block(r2->cleanup_metadata)) return false;
+
+  /* Only allow fuse with a common allocator */
+  if (r1->block_alloc != r2->block_alloc) return false;
 
   /* We want to join the smaller tree to the larger tree.
    * So swap first if they are backwards. */
@@ -261,4 +311,5 @@ void upb_arena_fuse(upb_arena *a1, upb_arena *a2) {
     r1->freelist = r2->freelist;
   }
   r2->parent = r1;
+  return true;
 }
index 11c0e4d..bc0edf9 100644 (file)
@@ -1,6 +1,33 @@
 /*
-** This file contains shared definitions that are widely used across upb.
-*/
+ * Copyright (c) 2009-2021, Google LLC
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ *     * Redistributions of source code must retain the above copyright
+ *       notice, this list of conditions and the following disclaimer.
+ *     * Redistributions in binary form must reproduce the above copyright
+ *       notice, this list of conditions and the following disclaimer in the
+ *       documentation and/or other materials provided with the distribution.
+ *     * Neither the name of Google LLC nor the
+ *       names of its contributors may be used to endorse or promote products
+ *       derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+ * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ * DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+ * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+ * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+ * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+/*
+ * This file contains shared definitions that are widely used across upb.
+ */
 
 #ifndef UPB_H_
 #define UPB_H_
@@ -33,9 +60,12 @@ bool upb_ok(const upb_status *status);
 /* These are no-op if |status| is NULL. */
 void upb_status_clear(upb_status *status);
 void upb_status_seterrmsg(upb_status *status, const char *msg);
-void upb_status_seterrf(upb_status *status, const char *fmt, ...);
-void upb_status_vseterrf(upb_status *status, const char *fmt, va_list args);
-void upb_status_vappenderrf(upb_status *status, const char *fmt, va_list args);
+void upb_status_seterrf(upb_status *status, const char *fmt, ...)
+    UPB_PRINTF(2, 3);
+void upb_status_vseterrf(upb_status *status, const char *fmt, va_list args)
+    UPB_PRINTF(2, 0);
+void upb_status_vappenderrf(upb_status *status, const char *fmt, va_list args)
+    UPB_PRINTF(2, 0);
 
 /** upb_strview ************************************************************/
 
@@ -156,7 +186,7 @@ typedef struct {
 upb_arena *upb_arena_init(void *mem, size_t n, upb_alloc *alloc);
 void upb_arena_free(upb_arena *a);
 bool upb_arena_addcleanup(upb_arena *a, void *ud, upb_cleanup_func *func);
-void upb_arena_fuse(upb_arena *a, upb_arena *b);
+bool upb_arena_fuse(upb_arena *a, upb_arena *b);
 void *_upb_arena_slowmalloc(upb_arena *a, size_t size);
 
 UPB_INLINE upb_alloc *upb_arena_alloc(upb_arena *a) { return (upb_alloc*)a; }
index b7b9976..3610537 100644 (file)
@@ -1,3 +1,27 @@
+// Copyright (c) 2009-2021, Google LLC
+// All rights reserved.
+//
+// Redistribution and use in source and binary forms, with or without
+// modification, are permitted provided that the following conditions are met:
+//     * Redistributions of source code must retain the above copyright
+//       notice, this list of conditions and the following disclaimer.
+//     * Redistributions in binary form must reproduce the above copyright
+//       notice, this list of conditions and the following disclaimer in the
+//       documentation and/or other materials provided with the distribution.
+//     * Neither the name of Google LLC nor the
+//       names of its contributors may be used to endorse or promote products
+//       derived from this software without specific prior written permission.
+//
+// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+// WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+// DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+// DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+// (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+// LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+// ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+// SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 
 #ifndef UPB_HPP_
 #define UPB_HPP_
diff --git a/third_party/upb/upb/upb.int.h b/third_party/upb/upb/upb.int.h
deleted file mode 100644 (file)
index b857560..0000000
+++ /dev/null
@@ -1,29 +0,0 @@
-
-#ifndef UPB_INT_H_
-#define UPB_INT_H_
-
-#include "upb/upb.h"
-
-struct mem_block;
-typedef struct mem_block mem_block;
-
-struct upb_arena {
-  _upb_arena_head head;
-  uint32_t *cleanups;
-
-  /* Allocator to allocate arena blocks.  We are responsible for freeing these
-   * when we are destroyed. */
-  upb_alloc *block_alloc;
-  uint32_t last_size;
-
-  /* When multiple arenas are fused together, each arena points to a parent
-   * arena (root points to itself). The root tracks how many live arenas
-   * reference it. */
-  uint32_t refcount;  /* Only used when a->parent == a */
-  struct upb_arena *parent;
-
-  /* Linked list of blocks to free/cleanup. */
-  mem_block *freelist, *freelist_tail;
-};
-
-#endif  /* UPB_INT_H_ */
diff --git a/third_party/upb/upb/upb_internal.h b/third_party/upb/upb/upb_internal.h
new file mode 100644 (file)
index 0000000..ae50678
--- /dev/null
@@ -0,0 +1,58 @@
+/*
+ * Copyright (c) 2009-2021, Google LLC
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ *     * Redistributions of source code must retain the above copyright
+ *       notice, this list of conditions and the following disclaimer.
+ *     * Redistributions in binary form must reproduce the above copyright
+ *       notice, this list of conditions and the following disclaimer in the
+ *       documentation and/or other materials provided with the distribution.
+ *     * Neither the name of Google LLC nor the
+ *       names of its contributors may be used to endorse or promote products
+ *       derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+ * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ * DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+ * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+ * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+ * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#ifndef UPB_INT_H_
+#define UPB_INT_H_
+
+#include "upb/upb.h"
+
+struct mem_block;
+typedef struct mem_block mem_block;
+
+struct upb_arena {
+  _upb_arena_head head;
+  /* Stores cleanup metadata for this arena.
+   * - a pointer to the current cleanup counter.
+   * - a boolean indicating if there is an unowned initial block.  */
+  uintptr_t cleanup_metadata;
+
+  /* Allocator to allocate arena blocks.  We are responsible for freeing these
+   * when we are destroyed. */
+  upb_alloc *block_alloc;
+  uint32_t last_size;
+
+  /* When multiple arenas are fused together, each arena points to a parent
+   * arena (root points to itself). The root tracks how many live arenas
+   * reference it. */
+  uint32_t refcount;  /* Only used when a->parent == a */
+  struct upb_arena *parent;
+
+  /* Linked list of blocks to free/cleanup. */
+  mem_block *freelist, *freelist_tail;
+};
+
+#endif  /* UPB_INT_H_ */
index 3b7d69b..29bb398 100644 (file)
@@ -1,3 +1,28 @@
+# Copyright (c) 2009-2021, Google LLC
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions are met:
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in the
+#       documentation and/or other materials provided with the distribution.
+#     * Neither the name of Google LLC nor the
+#       names of its contributors may be used to endorse or promote products
+#       derived from this software without specific prior written permission.
+#
+# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+# DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+# DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+# (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+# ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
 load(
     "//bazel:build_defs.bzl",
     "UPB_DEFAULT_CPPOPTS",
index c1b30a3..d2df929 100644 (file)
@@ -1,3 +1,27 @@
+// Copyright (c) 2009-2021, Google LLC
+// All rights reserved.
+//
+// Redistribution and use in source and binary forms, with or without
+// modification, are permitted provided that the following conditions are met:
+//     * Redistributions of source code must retain the above copyright
+//       notice, this list of conditions and the following disclaimer.
+//     * Redistributions in binary form must reproduce the above copyright
+//       notice, this list of conditions and the following disclaimer in the
+//       documentation and/or other materials provided with the distribution.
+//     * Neither the name of Google LLC nor the
+//       names of its contributors may be used to endorse or promote products
+//       derived from this software without specific prior written permission.
+//
+// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+// WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+// DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+// DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+// (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+// LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+// ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+// SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 
 #include "absl/strings/str_replace.h"
 #include "upbc/common.h"
@@ -18,7 +42,7 @@ void AddMessages(const protobuf::Descriptor* message,
 }  // namespace
 
 std::string StripExtension(absl::string_view fname) {
-  size_t lastdot = fname.find_last_of(".");
+  size_t lastdot = fname.find_last_of('.');
   if (lastdot == std::string::npos) {
     return std::string(fname);
   }
index 5825786..1867ae0 100644 (file)
@@ -1,3 +1,29 @@
+/*
+ * Copyright (c) 2009-2021, Google LLC
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ *     * Redistributions of source code must retain the above copyright
+ *       notice, this list of conditions and the following disclaimer.
+ *     * Redistributions in binary form must reproduce the above copyright
+ *       notice, this list of conditions and the following disclaimer in the
+ *       documentation and/or other materials provided with the distribution.
+ *     * Neither the name of Google LLC nor the
+ *       names of its contributors may be used to endorse or promote products
+ *       derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+ * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ * DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+ * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+ * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+ * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
 
 #ifndef UPBC_COMMON_H
 #define UPBC_COMMON_H
index 3d35448..1c5cd0b 100644 (file)
@@ -1,3 +1,27 @@
+// Copyright (c) 2009-2021, Google LLC
+// All rights reserved.
+//
+// Redistribution and use in source and binary forms, with or without
+// modification, are permitted provided that the following conditions are met:
+//     * Redistributions of source code must retain the above copyright
+//       notice, this list of conditions and the following disclaimer.
+//     * Redistributions in binary form must reproduce the above copyright
+//       notice, this list of conditions and the following disclaimer in the
+//       documentation and/or other materials provided with the distribution.
+//     * Neither the name of Google LLC nor the
+//       names of its contributors may be used to endorse or promote products
+//       derived from this software without specific prior written permission.
+//
+// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+// WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+// DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+// DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+// (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+// LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+// ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+// SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 
 #include "upbc/message_layout.h"
 #include "google/protobuf/descriptor.pb.h"
index f257a96..e4e5d74 100644 (file)
@@ -1,3 +1,29 @@
+/*
+ * Copyright (c) 2009-2021, Google LLC
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ *     * Redistributions of source code must retain the above copyright
+ *       notice, this list of conditions and the following disclaimer.
+ *     * Redistributions in binary form must reproduce the above copyright
+ *       notice, this list of conditions and the following disclaimer in the
+ *       documentation and/or other materials provided with the distribution.
+ *     * Neither the name of Google LLC nor the
+ *       names of its contributors may be used to endorse or promote products
+ *       derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+ * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ * DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+ * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+ * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+ * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
 
 #ifndef UPBC_MESSAGE_LAYOUT_H
 #define UPBC_MESSAGE_LAYOUT_H
index e099ad4..a68a691 100644 (file)
@@ -1,3 +1,27 @@
+// Copyright (c) 2009-2021, Google LLC
+// All rights reserved.
+//
+// Redistribution and use in source and binary forms, with or without
+// modification, are permitted provided that the following conditions are met:
+//     * Redistributions of source code must retain the above copyright
+//       notice, this list of conditions and the following disclaimer.
+//     * Redistributions in binary form must reproduce the above copyright
+//       notice, this list of conditions and the following disclaimer in the
+//       documentation and/or other materials provided with the distribution.
+//     * Neither the name of Google LLC nor the
+//       names of its contributors may be used to endorse or promote products
+//       derived from this software without specific prior written permission.
+//
+// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+// WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+// DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+// DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+// (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+// LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+// ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+// SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 
 #include <memory>
 
@@ -219,7 +243,7 @@ void GenerateMessageInHeader(const protobuf::Descriptor* message, Output& output
   MessageLayout layout(message);
 
   output("/* $0 */\n\n", message->full_name());
-  std::string msgname = ToCIdent(message->full_name());
+  std::string msg_name = ToCIdent(message->full_name());
 
   if (!message->options().map_entry()) {
     output(
@@ -229,13 +253,19 @@ void GenerateMessageInHeader(const protobuf::Descriptor* message, Output& output
         "UPB_INLINE $0 *$0_parse(const char *buf, size_t size,\n"
         "                        upb_arena *arena) {\n"
         "  $0 *ret = $0_new(arena);\n"
-        "  return (ret && upb_decode(buf, size, ret, &$1, arena)) ? ret : NULL;\n"
+        "  if (!ret) return NULL;\n"
+        "  if (!upb_decode(buf, size, ret, &$1, arena)) return NULL;\n"
+        "  return ret;\n"
         "}\n"
         "UPB_INLINE $0 *$0_parse_ex(const char *buf, size_t size,\n"
-        "                           upb_arena *arena, int options) {\n"
+        "                           const upb_extreg *extreg, int options,\n"
+        "                           upb_arena *arena) {\n"
         "  $0 *ret = $0_new(arena);\n"
-        "  return (ret && _upb_decode(buf, size, ret, &$1, arena, options))\n"
-        "      ? ret : NULL;\n"
+        "  if (!ret) return NULL;\n"
+        "  if (!_upb_decode(buf, size, ret, &$1, extreg, options, arena)) {\n"
+        "    return NULL;\n"
+        "  }\n"
+        "  return ret;\n"
         "}\n"
         "UPB_INLINE char *$0_serialize(const $0 *msg, upb_arena *arena, size_t "
         "*len) {\n"
@@ -261,7 +291,7 @@ void GenerateMessageInHeader(const protobuf::Descriptor* message, Output& output
         "UPB_INLINE $0_oneofcases $1_$2_case(const $1* msg) { "
         "return ($0_oneofcases)*UPB_PTR_AT(msg, $3, int32_t); }\n"
         "\n",
-        fullname, msgname, oneof->name(),
+        fullname, msg_name, oneof->name(),
         GetSizeInit(layout.GetOneofCaseOffset(oneof)));
   }
 
@@ -273,12 +303,12 @@ void GenerateMessageInHeader(const protobuf::Descriptor* message, Output& output
       output(
           "UPB_INLINE bool $0_has_$1(const $0 *msg) { "
           "return _upb_hasbit(msg, $2); }\n",
-          msgname, field->name(), layout.GetHasbitIndex(field));
+          msg_name, field->name(), layout.GetHasbitIndex(field));
     } else if (field->real_containing_oneof()) {
       output(
           "UPB_INLINE bool $0_has_$1(const $0 *msg) { "
           "return _upb_getoneofcase(msg, $2) == $3; }\n",
-          msgname, field->name(),
+          msg_name, field->name(),
           GetSizeInit(
               layout.GetOneofCaseOffset(field->real_containing_oneof())),
           field->number());
@@ -286,7 +316,7 @@ void GenerateMessageInHeader(const protobuf::Descriptor* message, Output& output
       output(
           "UPB_INLINE bool $0_has_$1(const $0 *msg) { "
           "return _upb_has_submsg_nohasbit(msg, $2); }\n",
-          msgname, field->name(), GetSizeInit(layout.GetFieldOffset(field)));
+          msg_name, field->name(), GetSizeInit(layout.GetFieldOffset(field)));
     }
 
     // Generate getter.
@@ -297,11 +327,11 @@ void GenerateMessageInHeader(const protobuf::Descriptor* message, Output& output
       output(
           "UPB_INLINE size_t $0_$1_size(const $0 *msg) {"
           "return _upb_msg_map_size(msg, $2); }\n",
-          msgname, field->name(), GetSizeInit(layout.GetFieldOffset(field)));
+          msg_name, field->name(), GetSizeInit(layout.GetFieldOffset(field)));
       output(
           "UPB_INLINE bool $0_$1_get(const $0 *msg, $2 key, $3 *val) { "
           "return _upb_msg_map_get(msg, $4, &key, $5, val, $6); }\n",
-          msgname, field->name(), CType(key), CType(val),
+          msg_name, field->name(), CType(key), CType(val),
           GetSizeInit(layout.GetFieldOffset(field)),
           key->cpp_type() == protobuf::FieldDescriptor::CPPTYPE_STRING
               ? "0"
@@ -312,7 +342,7 @@ void GenerateMessageInHeader(const protobuf::Descriptor* message, Output& output
       output(
           "UPB_INLINE $0 $1_$2_next(const $1 *msg, size_t* iter) { "
           "return ($0)_upb_msg_map_next(msg, $3, iter); }\n",
-          CTypeConst(field), msgname, field->name(),
+          CTypeConst(field), msg_name, field->name(),
           GetSizeInit(layout.GetFieldOffset(field)));
     } else if (message->options().map_entry()) {
       output(
@@ -321,7 +351,7 @@ void GenerateMessageInHeader(const protobuf::Descriptor* message, Output& output
           "  _upb_msg_map_$2(msg, &ret, $4);\n"
           "  return ret;\n"
           "}\n",
-          CTypeConst(field), msgname, field->name(), CType(field),
+          CTypeConst(field), msg_name, field->name(), CType(field),
           field->cpp_type() == protobuf::FieldDescriptor::CPPTYPE_STRING
               ? "0"
               : "sizeof(ret)");
@@ -329,13 +359,13 @@ void GenerateMessageInHeader(const protobuf::Descriptor* message, Output& output
       output(
           "UPB_INLINE $0 const* $1_$2(const $1 *msg, size_t *len) { "
           "return ($0 const*)_upb_array_accessor(msg, $3, len); }\n",
-          CTypeConst(field), msgname, field->name(),
+          CTypeConst(field), msg_name, field->name(),
           GetSizeInit(layout.GetFieldOffset(field)));
     } else if (field->real_containing_oneof()) {
       output(
           "UPB_INLINE $0 $1_$2(const $1 *msg) { "
           "return UPB_READ_ONEOF(msg, $0, $3, $4, $5, $6); }\n",
-          CTypeConst(field), msgname, field->name(),
+          CTypeConst(field), msg_name, field->name(),
           GetSizeInit(layout.GetFieldOffset(field)),
           GetSizeInit(layout.GetOneofCaseOffset(field->real_containing_oneof())),
           field->number(), FieldDefault(field));
@@ -343,7 +373,7 @@ void GenerateMessageInHeader(const protobuf::Descriptor* message, Output& output
       output(
           "UPB_INLINE $0 $1_$2(const $1 *msg) { "
           "return *UPB_PTR_AT(msg, $3, $0); }\n",
-          CTypeConst(field), msgname, field->name(),
+          CTypeConst(field), msg_name, field->name(),
           GetSizeInit(layout.GetFieldOffset(field)));
     }
   }
@@ -360,12 +390,12 @@ void GenerateMessageInHeader(const protobuf::Descriptor* message, Output& output
       const protobuf::FieldDescriptor* val = entry->FindFieldByNumber(2);
       output(
           "UPB_INLINE void $0_$1_clear($0 *msg) { _upb_msg_map_clear(msg, $2); }\n",
-          msgname, field->name(),
+          msg_name, field->name(),
           GetSizeInit(layout.GetFieldOffset(field)));
       output(
           "UPB_INLINE bool $0_$1_set($0 *msg, $2 key, $3 val, upb_arena *a) { "
           "return _upb_msg_map_set(msg, $4, &key, $5, &val, $6, a); }\n",
-          msgname, field->name(), CType(key), CType(val),
+          msg_name, field->name(), CType(key), CType(val),
           GetSizeInit(layout.GetFieldOffset(field)),
           key->cpp_type() == protobuf::FieldDescriptor::CPPTYPE_STRING
               ? "0"
@@ -376,7 +406,7 @@ void GenerateMessageInHeader(const protobuf::Descriptor* message, Output& output
       output(
           "UPB_INLINE bool $0_$1_delete($0 *msg, $2 key) { "
           "return _upb_msg_map_delete(msg, $3, &key, $4); }\n",
-          msgname, field->name(), CType(key),
+          msg_name, field->name(), CType(key),
           GetSizeInit(layout.GetFieldOffset(field)),
           key->cpp_type() == protobuf::FieldDescriptor::CPPTYPE_STRING
               ? "0"
@@ -384,21 +414,21 @@ void GenerateMessageInHeader(const protobuf::Descriptor* message, Output& output
       output(
           "UPB_INLINE $0 $1_$2_nextmutable($1 *msg, size_t* iter) { "
           "return ($0)_upb_msg_map_next(msg, $3, iter); }\n",
-          CType(field), msgname, field->name(),
+          CType(field), msg_name, field->name(),
           GetSizeInit(layout.GetFieldOffset(field)));
     } else if (field->is_repeated()) {
       output(
           "UPB_INLINE $0* $1_mutable_$2($1 *msg, size_t *len) {\n"
           "  return ($0*)_upb_array_mutable_accessor(msg, $3, len);\n"
           "}\n",
-          CType(field), msgname, field->name(),
+          CType(field), msg_name, field->name(),
           GetSizeInit(layout.GetFieldOffset(field)));
       output(
           "UPB_INLINE $0* $1_resize_$2($1 *msg, size_t len, "
           "upb_arena *arena) {\n"
           "  return ($0*)_upb_array_resize_accessor2(msg, $3, len, $4, arena);\n"
           "}\n",
-          CType(field), msgname, field->name(),
+          CType(field), msg_name, field->name(),
           GetSizeInit(layout.GetFieldOffset(field)),
           SizeLg2(field));
       if (field->cpp_type() == protobuf::FieldDescriptor::CPPTYPE_MESSAGE) {
@@ -410,7 +440,7 @@ void GenerateMessageInHeader(const protobuf::Descriptor* message, Output& output
             "  if (!ok) return NULL;\n"
             "  return sub;\n"
             "}\n",
-            MessageName(field->message_type()), msgname, field->name(),
+            MessageName(field->message_type()), msg_name, field->name(),
             MessageInit(field->message_type()),
             GetSizeInit(layout.GetFieldOffset(field)),
             SizeLg2(field));
@@ -420,7 +450,7 @@ void GenerateMessageInHeader(const protobuf::Descriptor* message, Output& output
             "  return _upb_array_append_accessor2(msg, $3, $4, &val,\n"
             "      arena);\n"
             "}\n",
-            CType(field), msgname, field->name(),
+            CType(field), msg_name, field->name(),
             GetSizeInit(layout.GetFieldOffset(field)),
             SizeLg2(field));
       }
@@ -433,7 +463,7 @@ void GenerateMessageInHeader(const protobuf::Descriptor* message, Output& output
 
       // The common function signature for all setters.  Varying implementations
       // follow.
-      output("UPB_INLINE void $0_set_$1($0 *msg, $2 value) {\n", msgname,
+      output("UPB_INLINE void $0_set_$1($0 *msg, $2 value) {\n", msg_name,
              field->name(), CType(field));
 
       if (message->options().map_entry()) {
@@ -473,7 +503,7 @@ void GenerateMessageInHeader(const protobuf::Descriptor* message, Output& output
             "  }\n"
             "  return sub;\n"
             "}\n",
-            MessageName(field->message_type()), msgname, field->name(),
+            MessageName(field->message_type()), msg_name, field->name(),
             MessageInit(field->message_type()));
       }
     }
@@ -487,7 +517,7 @@ void WriteHeader(const protobuf::FileDescriptor* file, Output& output) {
   output(
       "#ifndef $0_UPB_H_\n"
       "#define $0_UPB_H_\n\n"
-      "#include \"upb/msg.h\"\n"
+      "#include \"upb/msg_internal.h\"\n"
       "#include \"upb/decode.h\"\n"
       "#include \"upb/decode_fast.h\"\n"
       "#include \"upb/encode.h\"\n\n",
@@ -512,7 +542,7 @@ void WriteHeader(const protobuf::FileDescriptor* file, Output& output) {
       "#endif\n"
       "\n");
 
-  std::vector<const protobuf::Descriptor*> this_file_messages =
+  const std::vector<const protobuf::Descriptor*> this_file_messages =
       SortedMessages(file);
 
   // Forward-declare types defined in this file.
@@ -530,7 +560,7 @@ void WriteHeader(const protobuf::FileDescriptor* file, Output& output) {
   // Order by full name for consistent ordering.
   std::map<std::string, const protobuf::Descriptor*> forward_messages;
 
-  for (auto message : SortedMessages(file)) {
+  for (auto* message : this_file_messages) {
     for (int i = 0; i < message->field_count(); i++) {
       const protobuf::FieldDescriptor* field = message->field(i);
       if (field->cpp_type() == protobuf::FieldDescriptor::CPPTYPE_MESSAGE &&
@@ -819,130 +849,166 @@ std::vector<TableEntry> FastDecodeTable(const protobuf::Descriptor* message,
   return table;
 }
 
-void WriteSource(const protobuf::FileDescriptor* file, Output& output,
-                 bool fasttable_enabled) {
-  EmitFileWarning(file, output);
+void WriteField(const protobuf::FieldDescriptor* field,
+                absl::string_view offset, absl::string_view presence,
+                int submsg_index, Output& output) {
+  std::string mode;
+  if (field->is_map()) {
+    mode = "_UPB_MODE_MAP";
+  } else if (field->is_repeated()) {
+    mode = "_UPB_MODE_ARRAY";
+  } else {
+    mode = "_UPB_MODE_SCALAR";
+  }
 
-  output(
-      "#include <stddef.h>\n"
-      "#include \"upb/msg.h\"\n"
-      "#include \"$0\"\n",
-      HeaderFilename(file->name()));
+  if (field->is_packed()) {
+    absl::StrAppend(&mode, " | _UPB_MODE_IS_PACKED");
+  }
 
-  for (int i = 0; i < file->dependency_count(); i++) {
-    output("#include \"$0\"\n", HeaderFilename(file->dependency(i)->name()));
+  output("{$0, $1, $2, $3, $4, $5}", field->number(), offset, presence,
+         submsg_index, TableDescriptorType(field), mode);
+}
+
+// Writes a single field into a .upb.c source file.
+void WriteMessageField(const protobuf::FieldDescriptor* field,
+                       const MessageLayout& layout, int submsg_index,
+                       Output& output) {
+  std::string presence = "0";
+
+  if (MessageLayout::HasHasbit(field)) {
+    int index = layout.GetHasbitIndex(field);
+    assert(index != 0);
+    presence = absl::StrCat(index);
+  } else if (field->real_containing_oneof()) {
+    MessageLayout::Size case_offset =
+        layout.GetOneofCaseOffset(field->real_containing_oneof());
+
+    // We encode as negative to distinguish from hasbits.
+    case_offset.size32 = ~case_offset.size32;
+    case_offset.size64 = ~case_offset.size64;
+    assert(case_offset.size32 < 0);
+    assert(case_offset.size64 < 0);
+    presence = GetSizeInit(case_offset);
   }
 
-  output(
-      "\n"
-      "#include \"upb/port_def.inc\"\n"
-      "\n");
+  output("  ");
+  WriteField(field, GetSizeInit(layout.GetFieldOffset(field)), presence,
+             submsg_index, output);
+  output(",\n");
+}
 
+// Writes a single message into a .upb.c source file.
+void WriteMessage(const protobuf::Descriptor* message, Output& output,
+                  bool fasttable_enabled) {
+  std::string msg_name = ToCIdent(message->full_name());
+  std::string fields_array_ref = "NULL";
+  std::string submsgs_array_ref = "NULL";
+  uint8_t dense_below = 0;
+  const int dense_below_max = std::numeric_limits<decltype(dense_below)>::max();
+  MessageLayout layout(message);
+  SubmsgArray submsg_array(message);
+
+  if (!submsg_array.submsgs().empty()) {
+    // TODO(haberman): could save a little bit of space by only generating a
+    // "submsgs" array for every strongly-connected component.
+    std::string submsgs_array_name = msg_name + "_submsgs";
+    submsgs_array_ref = "&" + submsgs_array_name + "[0]";
+    output("static const upb_msglayout *const $0[$1] = {\n",
+           submsgs_array_name, submsg_array.submsgs().size());
+
+    for (auto submsg : submsg_array.submsgs()) {
+      output("  &$0,\n", MessageInit(submsg));
+    }
 
-  for (auto message : SortedMessages(file)) {
-    std::string msgname = ToCIdent(message->full_name());
-    std::string fields_array_ref = "NULL";
-    std::string submsgs_array_ref = "NULL";
-    MessageLayout layout(message);
-    SubmsgArray submsg_array(message);
+    output("};\n\n");
+  }
 
-    if (!submsg_array.submsgs().empty()) {
-      // TODO(haberman): could save a little bit of space by only generating a
-      // "submsgs" array for every strongly-connected component.
-      std::string submsgs_array_name = msgname + "_submsgs";
-      submsgs_array_ref = "&" + submsgs_array_name + "[0]";
-      output("static const upb_msglayout *const $0[$1] = {\n",
-             submsgs_array_name, submsg_array.submsgs().size());
+  std::vector<const protobuf::FieldDescriptor*> field_number_order =
+      FieldNumberOrder(message);
+  if (!field_number_order.empty()) {
+    std::string fields_array_name = msg_name + "__fields";
+    fields_array_ref = "&" + fields_array_name + "[0]";
+    output("static const upb_msglayout_field $0[$1] = {\n",
+           fields_array_name, field_number_order.size());
+    for (int i = 0; i < static_cast<int>(field_number_order.size()); i++) {
+      auto field = field_number_order[i];
+      int submsg_index = 0;
+
+      if (i < dense_below_max && field->number() == i + 1 &&
+          (i == 0 || field_number_order[i - 1]->number() == i)) {
+        dense_below = i + 1;
+      }
 
-      for (auto submsg : submsg_array.submsgs()) {
-        output("  &$0,\n", MessageInit(submsg));
+      if (field->cpp_type() == protobuf::FieldDescriptor::CPPTYPE_MESSAGE) {
+        submsg_index = submsg_array.GetIndex(field);
       }
 
-      output("};\n\n");
+      WriteMessageField(field, layout, submsg_index, output);
     }
+    output("};\n\n");
+  }
 
-    std::vector<const protobuf::FieldDescriptor*> field_number_order =
-        FieldNumberOrder(message);
-    if (!field_number_order.empty()) {
-      std::string fields_array_name = msgname + "__fields";
-      fields_array_ref = "&" + fields_array_name + "[0]";
-      output("static const upb_msglayout_field $0[$1] = {\n",
-             fields_array_name, field_number_order.size());
-      for (auto field : field_number_order) {
-        int submsg_index = 0;
-        std::string presence = "0";
-
-        if (field->cpp_type() == protobuf::FieldDescriptor::CPPTYPE_MESSAGE) {
-          submsg_index = submsg_array.GetIndex(field);
-        }
+  std::vector<TableEntry> table;
+  uint8_t table_mask = -1;
 
-        if (MessageLayout::HasHasbit(field)) {
-          int index = layout.GetHasbitIndex(field);
-          assert(index != 0);
-          presence = absl::StrCat(index);
-        } else if (field->real_containing_oneof()) {
-          MessageLayout::Size case_offset =
-              layout.GetOneofCaseOffset(field->real_containing_oneof());
-
-          // We encode as negative to distinguish from hasbits.
-          case_offset.size32 = ~case_offset.size32;
-          case_offset.size64 = ~case_offset.size64;
-          assert(case_offset.size32 < 0);
-          assert(case_offset.size64 < 0);
-          presence = GetSizeInit(case_offset);
-        }
+  if (fasttable_enabled) {
+    table = FastDecodeTable(message, layout);
+  }
 
-        std::string label;
-        if (field->is_map()) {
-          label = "_UPB_LABEL_MAP";
-        } else if (field->is_packed()) {
-          label = "_UPB_LABEL_PACKED";
-        } else {
-          label = absl::StrCat(field->label());
-        }
+  if (table.size() > 1) {
+    assert((table.size() & (table.size() - 1)) == 0);
+    table_mask = (table.size() - 1) << 3;
+  }
 
-        output("  {$0, $1, $2, $3, $4, $5},\n",
-               field->number(),
-               GetSizeInit(layout.GetFieldOffset(field)),
-               presence,
-               submsg_index,
-               TableDescriptorType(field),
-               label);
-      }
-      output("};\n\n");
+  output("const upb_msglayout $0 = {\n", MessageInit(message));
+  output("  $0,\n", submsgs_array_ref);
+  output("  $0,\n", fields_array_ref);
+  output("  $0, $1, $2, $3, $4,\n", GetSizeInit(layout.message_size()),
+         field_number_order.size(),
+         "false",  // TODO: extendable
+         dense_below,
+         table_mask
+  );
+  if (!table.empty()) {
+    output("  UPB_FASTTABLE_INIT({\n");
+    for (const auto& ent : table) {
+      output("    {0x$1, &$0},\n", ent.first,
+             absl::StrCat(absl::Hex(ent.second, absl::kZeroPad16)));
     }
+    output("  }),\n");
+  }
+  output("};\n\n");
+}
 
-    std::vector<TableEntry> table;
-    uint8_t table_mask = -1;
+void WriteMessages(const protobuf::FileDescriptor* file, Output& output,
+                   bool fasttable_enabled) {
+  for (auto* message : SortedMessages(file)) {
+    WriteMessage(message, output, fasttable_enabled);
+  }
+}
 
-    if (fasttable_enabled) {
-      table = FastDecodeTable(message, layout);
-    }
+// Writes a .upb.c source file.
+void WriteSource(const protobuf::FileDescriptor* file, Output& output,
+                 bool fasttable_enabled) {
+  EmitFileWarning(file, output);
 
-    if (table.size() > 1) {
-      assert((table.size() & (table.size() - 1)) == 0);
-      table_mask = (table.size() - 1) << 3;
-    }
+  output(
+      "#include <stddef.h>\n"
+      "#include \"upb/msg_internal.h\"\n"
+      "#include \"$0\"\n",
+      HeaderFilename(file->name()));
 
-    output("const upb_msglayout $0 = {\n", MessageInit(message));
-    output("  $0,\n", submsgs_array_ref);
-    output("  $0,\n", fields_array_ref);
-    output("  $0, $1, $2, $3,\n", GetSizeInit(layout.message_size()),
-           field_number_order.size(),
-           "false",  // TODO: extendable
-           table_mask
-    );
-    if (!table.empty()) {
-      output("  UPB_FASTTABLE_INIT({\n");
-      for (const auto& ent : table) {
-        output("    {0x$1, &$0},\n", ent.first,
-               absl::StrCat(absl::Hex(ent.second, absl::kZeroPad16)));
-      }
-      output("  }),\n");
-    }
-    output("};\n\n");
+  for (int i = 0; i < file->dependency_count(); i++) {
+    output("#include \"$0\"\n", HeaderFilename(file->dependency(i)->name()));
   }
 
+  output(
+      "\n"
+      "#include \"upb/port_def.inc\"\n"
+      "\n");
+
+  WriteMessages(file, output, fasttable_enabled);
+
   output("#include \"upb/port_undef.inc\"\n");
   output("\n");
 }
index f51ae07..4ec4163 100644 (file)
@@ -1,3 +1,27 @@
+// Copyright (c) 2009-2021, Google LLC
+// All rights reserved.
+//
+// Redistribution and use in source and binary forms, with or without
+// modification, are permitted provided that the following conditions are met:
+//     * Redistributions of source code must retain the above copyright
+//       notice, this list of conditions and the following disclaimer.
+//     * Redistributions in binary form must reproduce the above copyright
+//       notice, this list of conditions and the following disclaimer in the
+//       documentation and/or other materials provided with the distribution.
+//     * Neither the name of Google LLC nor the
+//       names of its contributors may be used to endorse or promote products
+//       derived from this software without specific prior written permission.
+//
+// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+// WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+// DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY
+// DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+// (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+// LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+// ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+// SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 
 #include <memory>
 
index fa20595..4f0fe3a 100644 (file)
@@ -25,24 +25,3 @@ ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
 (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
 SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 
-----------------------------------------------------
-
-xxhsum command line interface
-Copyright (c) 2013-2020 Yann Collet
-All rights reserved.
-
-GPL v2 License
-
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2 of the License, or
-(at your option) any later version.
-
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-GNU General Public License for more details.
-
-You should have received a copy of the GNU General Public License along
-with this program; if not, write to the Free Software Foundation, Inc.,
-51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
index f691a22..331c11b 100644 (file)
@@ -40,7 +40,6 @@ def mako_plugin(dictionary):
                     tests.append({
                         'name': new_target['name'],
                         'args': [fn],
-                        'exclude_iomgrs': ['uv'],
                         'exclude_configs': ['tsan'],
                         'uses_polling': False,
                         'platforms': ['mac', 'linux'],
diff --git a/tools/codegen/core/gen_legal_metadata_characters.cc b/tools/codegen/core/gen_legal_metadata_characters.cc
deleted file mode 100644 (file)
index fbabd24..0000000
+++ /dev/null
@@ -1,66 +0,0 @@
-/*
- *
- * Copyright 2015 gRPC authors.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- *
- */
-
-/* generates constant table for metadata.cc */
-
-#include <stdio.h>
-#include <string.h>
-
-static unsigned char legal_bits[256 / 8];
-
-static void legal(int x) {
-  int byte = x / 8;
-  int bit = x % 8;
-  /* NB: the following integer arithmetic operation needs to be in its
-   * expanded form due to the "integral promotion" performed (see section
-   * 3.2.1.1 of the C89 draft standard). A cast to the smaller container type
-   * is then required to avoid the compiler warning */
-  legal_bits[byte] =
-      (unsigned char)((legal_bits[byte] | (unsigned char)(1 << bit)));
-}
-
-static void dump(void) {
-  int i;
-
-  printf("static const uint8_t legal_header_bits[256/8] = ");
-  for (i = 0; i < 256 / 8; i++)
-    printf("%c 0x%02x", i ? ',' : '{', legal_bits[i]);
-  printf(" };\n");
-}
-
-static void clear(void) { memset(legal_bits, 0, sizeof(legal_bits)); }
-
-int main(void) {
-  int i;
-
-  clear();
-  for (i = 'a'; i <= 'z'; i++) legal(i);
-  for (i = '0'; i <= '9'; i++) legal(i);
-  legal('-');
-  legal('_');
-  legal('.');
-  dump();
-
-  clear();
-  for (i = 32; i <= 126; i++) {
-    legal(i);
-  }
-  dump();
-
-  return 0;
-}
diff --git a/tools/codegen/core/gen_percent_encoding_tables.cc b/tools/codegen/core/gen_percent_encoding_tables.cc
deleted file mode 100644 (file)
index a99024e..0000000
+++ /dev/null
@@ -1,69 +0,0 @@
-/*
- *
- * Copyright 2015 gRPC authors.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- *
- */
-
-/* generates constant table for metadata.cc */
-
-#include <stdio.h>
-#include <string.h>
-
-static unsigned char legal_bits[256 / 8];
-
-static void legal(int x) {
-  int byte = x / 8;
-  int bit = x % 8;
-  /* NB: the following integer arithmetic operation needs to be in its
-   * expanded form due to the "integral promotion" performed (see section
-   * 3.2.1.1 of the C89 draft standard). A cast to the smaller container type
-   * is then required to avoid the compiler warning */
-  legal_bits[byte] =
-      (unsigned char)((legal_bits[byte] | (unsigned char)(1 << bit)));
-}
-
-static void dump(const char *name) {
-  int i;
-
-  printf("const uint8_t %s[256/8] = ", name);
-  for (i = 0; i < 256 / 8; i++)
-    printf("%c 0x%02x", i ? ',' : '{', legal_bits[i]);
-  printf(" };\n");
-}
-
-static void clear(void) { memset(legal_bits, 0, sizeof(legal_bits)); }
-
-int main(void) {
-  int i;
-
-  clear();
-  for (i = 'a'; i <= 'z'; i++) legal(i);
-  for (i = 'A'; i <= 'Z'; i++) legal(i);
-  for (i = '0'; i <= '9'; i++) legal(i);
-  legal('-');
-  legal('_');
-  legal('.');
-  legal('~');
-  dump("grpc_url_percent_encoding_unreserved_bytes");
-
-  clear();
-  for (i = 32; i <= 126; i++) {
-    if (i == '%') continue;
-    legal(i);
-  }
-  dump("grpc_compatible_percent_encoding_unreserved_bytes");
-
-  return 0;
-}
diff --git a/tools/codegen/core/gen_switch.py b/tools/codegen/core/gen_switch.py
new file mode 100755 (executable)
index 0000000..6667959
--- /dev/null
@@ -0,0 +1,75 @@
+#!/usr/bin/env python3
+
+# Copyright 2021 gRPC authors.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+import sys
+
+
+# utility: print a big comment block into a set of files
+def put_banner(files, banner):
+    for f in files:
+        print('/*', file=f)
+        for line in banner:
+            print(' * %s' % line, file=f)
+        print(' */', file=f)
+        print('', file=f)
+
+
+with open('src/core/lib/promise/detail/switch.h', 'w') as H:
+    # copy-paste copyright notice from this file
+    with open(sys.argv[0]) as my_source:
+        copyright = []
+        for line in my_source:
+            if line[0] != '#':
+                break
+        for line in my_source:
+            if line[0] == '#':
+                copyright.append(line)
+                break
+        for line in my_source:
+            if line[0] != '#':
+                break
+            copyright.append(line)
+        put_banner([H], [line[2:].rstrip() for line in copyright])
+
+    put_banner([H], ["Automatically generated by %s" % sys.argv[0]])
+
+    print("#ifndef GRPC_CORE_LIB_PROMISE_DETAIL_SWITCH_H", file=H)
+    print("#define GRPC_CORE_LIB_PROMISE_DETAIL_SWITCH_H", file=H)
+    print('', file=H)
+    print('#include <grpc/impl/codegen/port_platform.h>', file=H)
+    print('', file=H)
+    print("#include <stdlib.h>", file=H)
+    print('', file=H)
+    print("namespace grpc_core {", file=H)
+
+    for n in range(1, 33):
+        print('', file=H)
+        print("template <typename R, %s> R Switch(char idx, %s) {" % (
+            ", ".join("typename F%d" % i for i in range(0, n)),
+            ", ".join("F%d f%d" % (i, i) for i in range(0, n)),
+        ),
+              file=H)
+        print("  switch (idx) {", file=H)
+        for i in range(0, n):
+            print("   case %d: return f%d();" % (i, i), file=H)
+        print("  }", file=H)
+        print("  abort();", file=H)
+        print("}", file=H)
+
+    print('', file=H)
+    print("}", file=H)
+    print('', file=H)
+    print("#endif // GRPC_CORE_LIB_PROMISE_DETAIL_SWITCH_H", file=H)
diff --git a/tools/distrib/add-iwyu.py b/tools/distrib/add-iwyu.py
new file mode 100755 (executable)
index 0000000..e6d800c
--- /dev/null
@@ -0,0 +1,118 @@
+#!/usr/bin/env python3
+
+# Copyright 2021 gRPC authors.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+import collections
+import os
+
+
+def to_inc(filename):
+    """Given filename, synthesize what should go in an include statement to get that file"""
+    if filename.startswith("include/"):
+        return '<%s>' % filename[len("include/"):]
+    return '"%s"' % filename
+
+
+def set_pragma(filename, pragma):
+    """Set the file-level IWYU pragma in filename"""
+    lines = []
+    saw_first_define = False
+    for line in open(filename).read().splitlines():
+        if line.startswith('// IWYU pragma: '):
+            continue
+        lines.append(line)
+        if not saw_first_define and line.startswith('#define '):
+            saw_first_define = True
+            lines.append('')
+            lines.append('// IWYU pragma: %s' % pragma)
+            lines.append('')
+    open(filename, 'w').write('\n'.join(lines) + '\n')
+
+
+def set_exports(pub, cg):
+    """In file pub, mark the include for cg with IWYU pragma: export"""
+    lines = []
+    for line in open(pub).read().splitlines():
+        if line.startswith('#include %s' % to_inc(cg)):
+            lines.append('#include %s  // IWYU pragma: export' % to_inc(cg))
+        else:
+            lines.append(line)
+    open(pub, 'w').write('\n'.join(lines) + '\n')
+
+
+CG_ROOTS_GRPC = (
+    (r'sync', 'grpc/support/sync.h'),
+    (r'atm', 'grpc/support/atm.h'),
+)
+
+CG_ROOTS_GRPCPP = []
+
+
+def fix_tree(tree, cg_roots):
+    """Fix one include tree"""
+    # Map of filename --> paths including that filename
+    reverse_map = collections.defaultdict(list)
+    # The same, but for things with '/impl/codegen' in their names
+    cg_reverse_map = collections.defaultdict(list)
+    for root, dirs, files in os.walk(tree):
+        root_map = cg_reverse_map if '/impl/codegen' in root else reverse_map
+        for filename in files:
+            root_map[filename].append(root)
+    # For each thing in '/impl/codegen' figure out what exports it
+    for filename, paths in cg_reverse_map.items():
+        # Exclude non-headers
+        if not filename.endswith('.h'):
+            continue
+        pragma = None
+        # Check for our 'special' headers: if we see one of these, we just
+        # hardcode where they go to because there's some complicated rules.
+        for root, target in cg_roots:
+            if filename.startswith(root):
+                pragma = 'private, include <%s>' % target
+                if len(paths) == 1:
+                    path = paths[0]
+                    if filename.startswith(root + '.'):
+                        set_exports('include/' + target, path + '/' + filename)
+                    if filename.startswith(root + '_'):
+                        set_exports(path + '/' + root + '.h',
+                                    path + '/' + filename)
+        # If the path for a file in /impl/codegen is ambiguous, just don't bother
+        if not pragma and len(paths) == 1:
+            path = paths[0]
+            # Check if we have an exporting candidate
+            if filename in reverse_map:
+                proper = reverse_map[filename]
+                # And that it too is unambiguous
+                if len(proper) == 1:
+                    # Build the two relevant pathnames
+                    cg = path + '/' + filename
+                    pub = proper[0] + '/' + filename
+                    # And see if the public file actually includes the /impl/codegen file
+                    if ('#include %s' % to_inc(cg)) in open(pub).read():
+                        # Finally, if it does, we'll set that pragma
+                        pragma = 'private, include %s' % to_inc(pub)
+                        # And mark the export
+                        set_exports(pub, cg)
+        # If we can't find a good alternative include to point people to,
+        # mark things private anyway... we don't want to recommend people include
+        # from impl/codegen
+        if not pragma:
+            pragma = 'private'
+        for path in paths:
+            set_pragma(path + '/' + filename, pragma)
+
+
+fix_tree('include/grpc', CG_ROOTS_GRPC)
+fix_tree('include/grpcpp', CG_ROOTS_GRPCPP)
index 51b1fd9..16cfc70 100644 (file)
@@ -14,5 +14,5 @@
 
 # AUTO-GENERATED FROM `$REPO_ROOT/templates/tools/distrib/python/grpcio_tools/grpc_version.py.template`!!!
 
-VERSION = '1.40.0'
-PROTOBUF_VERSION = '3.15.8'
+VERSION = '1.41.0'
+PROTOBUF_VERSION = '3.17.3'
index 15a7641..5d85edc 100644 (file)
@@ -5,17 +5,12 @@ Package for gRPC Python tools.
 
 Supported Python Versions
 -------------------------
-Python >= 3.5
-
-Deprecated Python Versions
---------------------------
-Python == 2.7. Python 2.7 support will be removed on January 1, 2020.
+Python >= 3.6
 
 Installation
 ------------
 
-The gRPC Python tools package is available for Linux, Mac OS X, and Windows
-running Python 2.7.
+The gRPC Python tools package is available for Linux, Mac OS X, and Windows.
 
 Installing From PyPI
 ~~~~~~~~~~~~~~~~~~~~
index d407f40..2f1c70f 100644 (file)
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-#include <google/protobuf/compiler/command_line_interface.h>
-#include <google/protobuf/compiler/python/python_generator.h>
-
-#include "src/compiler/python_generator.h"
-
 #include "grpc_tools/main.h"
 
-#include <google/protobuf/compiler/code_generator.h>
-#include <google/protobuf/compiler/importer.h>
-#include <google/protobuf/descriptor.h>
-#include <google/protobuf/io/zero_copy_stream_impl_lite.h>
-
 #include <algorithm>
 #include <map>
 #include <string>
 #include <unordered_set>
 #include <vector>
 
+#include <google/protobuf/compiler/code_generator.h>
+#include <google/protobuf/compiler/command_line_interface.h>
+#include <google/protobuf/compiler/importer.h>
+#include <google/protobuf/compiler/python/python_generator.h>
+#include <google/protobuf/descriptor.h>
+#include <google/protobuf/io/zero_copy_stream_impl_lite.h>
+
+#include "src/compiler/python_generator.h"
+
 using ::google::protobuf::FileDescriptor;
 using ::google::protobuf::compiler::CodeGenerator;
 using ::google::protobuf::compiler::DiskSourceTree;
index e2fe06a..b916007 100644 (file)
@@ -14,5 +14,5 @@
 
 # AUTO-GENERATED FROM `$REPO_ROOT/templates/tools/distrib/python/grpcio_tools/grpc_version.py.template`!!!
 
-VERSION = '1.40.0'
-PROTOBUF_VERSION = '3.15.8'
+VERSION = '1.41.0'
+PROTOBUF_VERSION = '3.17.3'
index 66b5270..04705e2 100644 (file)
 # limitations under the License.
 
 # AUTO-GENERATED BY make_grpcio_tools.py!
-CC_FILES=['google/protobuf/compiler/zip_writer.cc', 'google/protobuf/compiler/subprocess.cc', 'google/protobuf/compiler/ruby/ruby_generator.cc', 'google/protobuf/compiler/python/python_generator.cc', 'google/protobuf/compiler/plugin.pb.cc', 'google/protobuf/compiler/plugin.cc', 'google/protobuf/compiler/php/php_generator.cc', 'google/protobuf/compiler/objectivec/objectivec_primitive_field.cc', 'google/protobuf/compiler/objectivec/objectivec_oneof.cc', 'google/protobuf/compiler/objectivec/objectivec_message_field.cc', 'google/protobuf/compiler/objectivec/objectivec_message.cc', 'google/protobuf/compiler/objectivec/objectivec_map_field.cc', 'google/protobuf/compiler/objectivec/objectivec_helpers.cc', 'google/protobuf/compiler/objectivec/objectivec_generator.cc', 'google/protobuf/compiler/objectivec/objectivec_file.cc', 'google/protobuf/compiler/objectivec/objectivec_field.cc', 'google/protobuf/compiler/objectivec/objectivec_extension.cc', 'google/protobuf/compiler/objectivec/objectivec_enum_field.cc', 'google/protobuf/compiler/objectivec/objectivec_enum.cc', 'google/protobuf/compiler/js/well_known_types_embed.cc', 'google/protobuf/compiler/js/js_generator.cc', 'google/protobuf/compiler/java/java_string_field_lite.cc', 'google/protobuf/compiler/java/java_string_field.cc', 'google/protobuf/compiler/java/java_shared_code_generator.cc', 'google/protobuf/compiler/java/java_service.cc', 'google/protobuf/compiler/java/java_primitive_field_lite.cc', 'google/protobuf/compiler/java/java_primitive_field.cc', 'google/protobuf/compiler/java/java_name_resolver.cc', 'google/protobuf/compiler/java/java_message_lite.cc', 'google/protobuf/compiler/java/java_message_field_lite.cc', 'google/protobuf/compiler/java/java_message_field.cc', 'google/protobuf/compiler/java/java_message_builder_lite.cc', 'google/protobuf/compiler/java/java_message_builder.cc', 'google/protobuf/compiler/java/java_message.cc', 'google/protobuf/compiler/java/java_map_field_lite.cc', 'google/protobuf/compiler/java/java_map_field.cc', 'google/protobuf/compiler/java/java_helpers.cc', 'google/protobuf/compiler/java/java_generator_factory.cc', 'google/protobuf/compiler/java/java_generator.cc', 'google/protobuf/compiler/java/java_file.cc', 'google/protobuf/compiler/java/java_field.cc', 'google/protobuf/compiler/java/java_extension_lite.cc', 'google/protobuf/compiler/java/java_extension.cc', 'google/protobuf/compiler/java/java_enum_lite.cc', 'google/protobuf/compiler/java/java_enum_field_lite.cc', 'google/protobuf/compiler/java/java_enum_field.cc', 'google/protobuf/compiler/java/java_enum.cc', 'google/protobuf/compiler/java/java_doc_comment.cc', 'google/protobuf/compiler/java/java_context.cc', 'google/protobuf/compiler/csharp/csharp_wrapper_field.cc', 'google/protobuf/compiler/csharp/csharp_source_generator_base.cc', 'google/protobuf/compiler/csharp/csharp_repeated_primitive_field.cc', 'google/protobuf/compiler/csharp/csharp_repeated_message_field.cc', 'google/protobuf/compiler/csharp/csharp_repeated_enum_field.cc', 'google/protobuf/compiler/csharp/csharp_reflection_class.cc', 'google/protobuf/compiler/csharp/csharp_primitive_field.cc', 'google/protobuf/compiler/csharp/csharp_message_field.cc', 'google/protobuf/compiler/csharp/csharp_message.cc', 'google/protobuf/compiler/csharp/csharp_map_field.cc', 'google/protobuf/compiler/csharp/csharp_helpers.cc', 'google/protobuf/compiler/csharp/csharp_generator.cc', 'google/protobuf/compiler/csharp/csharp_field_base.cc', 'google/protobuf/compiler/csharp/csharp_enum_field.cc', 'google/protobuf/compiler/csharp/csharp_enum.cc', 'google/protobuf/compiler/csharp/csharp_doc_comment.cc', 'google/protobuf/compiler/cpp/cpp_string_field.cc', 'google/protobuf/compiler/cpp/cpp_service.cc', 'google/protobuf/compiler/cpp/cpp_primitive_field.cc', 'google/protobuf/compiler/cpp/cpp_padding_optimizer.cc', 'google/protobuf/compiler/cpp/cpp_message_field.cc', 'google/protobuf/compiler/cpp/cpp_message.cc', 'google/protobuf/compiler/cpp/cpp_map_field.cc', 'google/protobuf/compiler/cpp/cpp_helpers.cc', 'google/protobuf/compiler/cpp/cpp_generator.cc', 'google/protobuf/compiler/cpp/cpp_file.cc', 'google/protobuf/compiler/cpp/cpp_field.cc', 'google/protobuf/compiler/cpp/cpp_extension.cc', 'google/protobuf/compiler/cpp/cpp_enum_field.cc', 'google/protobuf/compiler/cpp/cpp_enum.cc', 'google/protobuf/compiler/command_line_interface.cc', 'google/protobuf/compiler/code_generator.cc', 'google/protobuf/wrappers.pb.cc', 'google/protobuf/wire_format.cc', 'google/protobuf/util/type_resolver_util.cc', 'google/protobuf/util/time_util.cc', 'google/protobuf/util/message_differencer.cc', 'google/protobuf/util/json_util.cc', 'google/protobuf/util/internal/utility.cc', 'google/protobuf/util/internal/type_info_test_helper.cc', 'google/protobuf/util/internal/type_info.cc', 'google/protobuf/util/internal/protostream_objectwriter.cc', 'google/protobuf/util/internal/protostream_objectsource.cc', 'google/protobuf/util/internal/proto_writer.cc', 'google/protobuf/util/internal/object_writer.cc', 'google/protobuf/util/internal/json_stream_parser.cc', 'google/protobuf/util/internal/json_objectwriter.cc', 'google/protobuf/util/internal/json_escaping.cc', 'google/protobuf/util/internal/field_mask_utility.cc', 'google/protobuf/util/internal/error_listener.cc', 'google/protobuf/util/internal/default_value_objectwriter.cc', 'google/protobuf/util/internal/datapiece.cc', 'google/protobuf/util/field_mask_util.cc', 'google/protobuf/util/field_comparator.cc', 'google/protobuf/util/delimited_message_util.cc', 'google/protobuf/unknown_field_set.cc', 'google/protobuf/type.pb.cc', 'google/protobuf/timestamp.pb.cc', 'google/protobuf/text_format.cc', 'google/protobuf/stubs/substitute.cc', 'google/protobuf/struct.pb.cc', 'google/protobuf/source_context.pb.cc', 'google/protobuf/service.cc', 'google/protobuf/reflection_ops.cc', 'google/protobuf/message.cc', 'google/protobuf/map_field.cc', 'google/protobuf/io/tokenizer.cc', 'google/protobuf/io/printer.cc', 'google/protobuf/io/gzip_stream.cc', 'google/protobuf/generated_message_table_driven.cc', 'google/protobuf/generated_message_reflection.cc', 'google/protobuf/field_mask.pb.cc', 'google/protobuf/extension_set_heavy.cc', 'google/protobuf/empty.pb.cc', 'google/protobuf/dynamic_message.cc', 'google/protobuf/duration.pb.cc', 'google/protobuf/descriptor_database.cc', 'google/protobuf/descriptor.pb.cc', 'google/protobuf/descriptor.cc', 'google/protobuf/compiler/parser.cc', 'google/protobuf/compiler/importer.cc', 'google/protobuf/api.pb.cc', 'google/protobuf/any.pb.cc', 'google/protobuf/any.cc', 'google/protobuf/wire_format_lite.cc', 'google/protobuf/stubs/time.cc', 'google/protobuf/stubs/strutil.cc', 'google/protobuf/stubs/structurally_valid.cc', 'google/protobuf/stubs/stringprintf.cc', 'google/protobuf/stubs/stringpiece.cc', 'google/protobuf/stubs/statusor.cc', 'google/protobuf/stubs/status.cc', 'google/protobuf/stubs/int128.cc', 'google/protobuf/stubs/common.cc', 'google/protobuf/stubs/bytestream.cc', 'google/protobuf/repeated_field.cc', 'google/protobuf/parse_context.cc', 'google/protobuf/message_lite.cc', 'google/protobuf/map.cc', 'google/protobuf/io/zero_copy_stream_impl_lite.cc', 'google/protobuf/io/zero_copy_stream_impl.cc', 'google/protobuf/io/zero_copy_stream.cc', 'google/protobuf/io/strtod.cc', 'google/protobuf/io/io_win32.cc', 'google/protobuf/io/coded_stream.cc', 'google/protobuf/implicit_weak_message.cc', 'google/protobuf/generated_message_util.cc', 'google/protobuf/generated_message_table_driven_lite.cc', 'google/protobuf/generated_enum_util.cc', 'google/protobuf/extension_set.cc', 'google/protobuf/arenastring.cc', 'google/protobuf/arena.cc', 'google/protobuf/any_lite.cc']
+CC_FILES=['google/protobuf/compiler/zip_writer.cc', 'google/protobuf/compiler/subprocess.cc', 'google/protobuf/compiler/ruby/ruby_generator.cc', 'google/protobuf/compiler/python/python_generator.cc', 'google/protobuf/compiler/plugin.pb.cc', 'google/protobuf/compiler/plugin.cc', 'google/protobuf/compiler/php/php_generator.cc', 'google/protobuf/compiler/objectivec/objectivec_primitive_field.cc', 'google/protobuf/compiler/objectivec/objectivec_oneof.cc', 'google/protobuf/compiler/objectivec/objectivec_message_field.cc', 'google/protobuf/compiler/objectivec/objectivec_message.cc', 'google/protobuf/compiler/objectivec/objectivec_map_field.cc', 'google/protobuf/compiler/objectivec/objectivec_helpers.cc', 'google/protobuf/compiler/objectivec/objectivec_generator.cc', 'google/protobuf/compiler/objectivec/objectivec_file.cc', 'google/protobuf/compiler/objectivec/objectivec_field.cc', 'google/protobuf/compiler/objectivec/objectivec_extension.cc', 'google/protobuf/compiler/objectivec/objectivec_enum_field.cc', 'google/protobuf/compiler/objectivec/objectivec_enum.cc', 'google/protobuf/compiler/js/well_known_types_embed.cc', 'google/protobuf/compiler/js/js_generator.cc', 'google/protobuf/compiler/java/java_string_field_lite.cc', 'google/protobuf/compiler/java/java_string_field.cc', 'google/protobuf/compiler/java/java_shared_code_generator.cc', 'google/protobuf/compiler/java/java_service.cc', 'google/protobuf/compiler/java/java_primitive_field_lite.cc', 'google/protobuf/compiler/java/java_primitive_field.cc', 'google/protobuf/compiler/java/java_name_resolver.cc', 'google/protobuf/compiler/java/java_message_lite.cc', 'google/protobuf/compiler/java/java_message_field_lite.cc', 'google/protobuf/compiler/java/java_message_field.cc', 'google/protobuf/compiler/java/java_message_builder_lite.cc', 'google/protobuf/compiler/java/java_message_builder.cc', 'google/protobuf/compiler/java/java_message.cc', 'google/protobuf/compiler/java/java_map_field_lite.cc', 'google/protobuf/compiler/java/java_map_field.cc', 'google/protobuf/compiler/java/java_kotlin_generator.cc', 'google/protobuf/compiler/java/java_helpers.cc', 'google/protobuf/compiler/java/java_generator_factory.cc', 'google/protobuf/compiler/java/java_generator.cc', 'google/protobuf/compiler/java/java_file.cc', 'google/protobuf/compiler/java/java_field.cc', 'google/protobuf/compiler/java/java_extension_lite.cc', 'google/protobuf/compiler/java/java_extension.cc', 'google/protobuf/compiler/java/java_enum_lite.cc', 'google/protobuf/compiler/java/java_enum_field_lite.cc', 'google/protobuf/compiler/java/java_enum_field.cc', 'google/protobuf/compiler/java/java_enum.cc', 'google/protobuf/compiler/java/java_doc_comment.cc', 'google/protobuf/compiler/java/java_context.cc', 'google/protobuf/compiler/csharp/csharp_wrapper_field.cc', 'google/protobuf/compiler/csharp/csharp_source_generator_base.cc', 'google/protobuf/compiler/csharp/csharp_repeated_primitive_field.cc', 'google/protobuf/compiler/csharp/csharp_repeated_message_field.cc', 'google/protobuf/compiler/csharp/csharp_repeated_enum_field.cc', 'google/protobuf/compiler/csharp/csharp_reflection_class.cc', 'google/protobuf/compiler/csharp/csharp_primitive_field.cc', 'google/protobuf/compiler/csharp/csharp_message_field.cc', 'google/protobuf/compiler/csharp/csharp_message.cc', 'google/protobuf/compiler/csharp/csharp_map_field.cc', 'google/protobuf/compiler/csharp/csharp_helpers.cc', 'google/protobuf/compiler/csharp/csharp_generator.cc', 'google/protobuf/compiler/csharp/csharp_field_base.cc', 'google/protobuf/compiler/csharp/csharp_enum_field.cc', 'google/protobuf/compiler/csharp/csharp_enum.cc', 'google/protobuf/compiler/csharp/csharp_doc_comment.cc', 'google/protobuf/compiler/cpp/cpp_string_field.cc', 'google/protobuf/compiler/cpp/cpp_service.cc', 'google/protobuf/compiler/cpp/cpp_primitive_field.cc', 'google/protobuf/compiler/cpp/cpp_parse_function_generator.cc', 'google/protobuf/compiler/cpp/cpp_padding_optimizer.cc', 'google/protobuf/compiler/cpp/cpp_message_field.cc', 'google/protobuf/compiler/cpp/cpp_message.cc', 'google/protobuf/compiler/cpp/cpp_map_field.cc', 'google/protobuf/compiler/cpp/cpp_helpers.cc', 'google/protobuf/compiler/cpp/cpp_generator.cc', 'google/protobuf/compiler/cpp/cpp_file.cc', 'google/protobuf/compiler/cpp/cpp_field.cc', 'google/protobuf/compiler/cpp/cpp_extension.cc', 'google/protobuf/compiler/cpp/cpp_enum_field.cc', 'google/protobuf/compiler/cpp/cpp_enum.cc', 'google/protobuf/compiler/command_line_interface.cc', 'google/protobuf/compiler/code_generator.cc', 'google/protobuf/wrappers.pb.cc', 'google/protobuf/wire_format.cc', 'google/protobuf/util/type_resolver_util.cc', 'google/protobuf/util/time_util.cc', 'google/protobuf/util/message_differencer.cc', 'google/protobuf/util/json_util.cc', 'google/protobuf/util/internal/utility.cc', 'google/protobuf/util/internal/type_info_test_helper.cc', 'google/protobuf/util/internal/type_info.cc', 'google/protobuf/util/internal/protostream_objectwriter.cc', 'google/protobuf/util/internal/protostream_objectsource.cc', 'google/protobuf/util/internal/proto_writer.cc', 'google/protobuf/util/internal/object_writer.cc', 'google/protobuf/util/internal/json_stream_parser.cc', 'google/protobuf/util/internal/json_objectwriter.cc', 'google/protobuf/util/internal/json_escaping.cc', 'google/protobuf/util/internal/field_mask_utility.cc', 'google/protobuf/util/internal/error_listener.cc', 'google/protobuf/util/internal/default_value_objectwriter.cc', 'google/protobuf/util/internal/datapiece.cc', 'google/protobuf/util/field_mask_util.cc', 'google/protobuf/util/field_comparator.cc', 'google/protobuf/util/delimited_message_util.cc', 'google/protobuf/unknown_field_set.cc', 'google/protobuf/type.pb.cc', 'google/protobuf/timestamp.pb.cc', 'google/protobuf/text_format.cc', 'google/protobuf/stubs/substitute.cc', 'google/protobuf/struct.pb.cc', 'google/protobuf/source_context.pb.cc', 'google/protobuf/service.cc', 'google/protobuf/reflection_ops.cc', 'google/protobuf/message.cc', 'google/protobuf/map_field.cc', 'google/protobuf/io/tokenizer.cc', 'google/protobuf/io/printer.cc', 'google/protobuf/io/gzip_stream.cc', 'google/protobuf/generated_message_table_driven.cc', 'google/protobuf/generated_message_reflection.cc', 'google/protobuf/field_mask.pb.cc', 'google/protobuf/extension_set_heavy.cc', 'google/protobuf/empty.pb.cc', 'google/protobuf/dynamic_message.cc', 'google/protobuf/duration.pb.cc', 'google/protobuf/descriptor_database.cc', 'google/protobuf/descriptor.pb.cc', 'google/protobuf/descriptor.cc', 'google/protobuf/compiler/parser.cc', 'google/protobuf/compiler/importer.cc', 'google/protobuf/api.pb.cc', 'google/protobuf/any.pb.cc', 'google/protobuf/any.cc', 'google/protobuf/wire_format_lite.cc', 'google/protobuf/stubs/time.cc', 'google/protobuf/stubs/strutil.cc', 'google/protobuf/stubs/structurally_valid.cc', 'google/protobuf/stubs/stringprintf.cc', 'google/protobuf/stubs/stringpiece.cc', 'google/protobuf/stubs/statusor.cc', 'google/protobuf/stubs/status.cc', 'google/protobuf/stubs/int128.cc', 'google/protobuf/stubs/common.cc', 'google/protobuf/stubs/bytestream.cc', 'google/protobuf/repeated_field.cc', 'google/protobuf/parse_context.cc', 'google/protobuf/message_lite.cc', 'google/protobuf/map.cc', 'google/protobuf/io/zero_copy_stream_impl_lite.cc', 'google/protobuf/io/zero_copy_stream_impl.cc', 'google/protobuf/io/zero_copy_stream.cc', 'google/protobuf/io/strtod.cc', 'google/protobuf/io/io_win32.cc', 'google/protobuf/io/coded_stream.cc', 'google/protobuf/implicit_weak_message.cc', 'google/protobuf/generated_message_util.cc', 'google/protobuf/generated_message_table_driven_lite.cc', 'google/protobuf/generated_enum_util.cc', 'google/protobuf/field_access_listener.cc', 'google/protobuf/extension_set.cc', 'google/protobuf/arenastring.cc', 'google/protobuf/arena.cc', 'google/protobuf/any_lite.cc']
 PROTO_FILES=['google/protobuf/wrappers.proto', 'google/protobuf/type.proto', 'google/protobuf/timestamp.proto', 'google/protobuf/struct.proto', 'google/protobuf/source_context.proto', 'google/protobuf/field_mask.proto', 'google/protobuf/empty.proto', 'google/protobuf/duration.proto', 'google/protobuf/descriptor.proto', 'google/protobuf/compiler/plugin.proto', 'google/protobuf/api.proto', 'google/protobuf/any.proto']
 
 CC_INCLUDE='third_party/protobuf/src'
 PROTO_INCLUDE='third_party/protobuf/src'
 
-PROTOBUF_SUBMODULE_VERSION="436bd7880e458532901c58f4d9d1ea23fa7edd52"
+PROTOBUF_SUBMODULE_VERSION="909a0f36a10075c4b4bc70fdee2c7e32dd612a72"
index 4b0a04f..2f0cd7a 100755 (executable)
@@ -34,7 +34,8 @@ argp.add_argument('-j',
                   type=int,
                   default=multiprocessing.cpu_count(),
                   help='Number of CPUs to use')
-argp.set_defaults(fix=False)
+argp.add_argument('--only-changed', dest='only_changed', action='store_true')
+argp.set_defaults(fix=False, only_changed=False)
 args = argp.parse_args()
 
 # Explicitly passing the .clang-tidy config by reading it.
@@ -51,6 +52,19 @@ cmdline = [
 if args.fix:
     cmdline.append('--fix')
 
+if args.only_changed:
+    orig_files = set(args.files)
+    actual_files = []
+    output = subprocess.check_output(
+        ['git', 'diff', 'origin/master', 'HEAD', '--name-only'])
+    for line in output.decode('ascii').splitlines(False):
+        if line in orig_files:
+            print("check: %s" % line)
+            actual_files.append(line)
+        else:
+            print("skip: %s - not in the build" % line)
+    args.files = actual_files
+
 jobs = []
 for filename in args.files:
     jobs.append(
index 361cc9b..7bc58eb 100755 (executable)
@@ -18,8 +18,14 @@ set -ex
 cd $(dirname $0)/../..
 
 tools/buildgen/generate_projects.sh
-tools/distrib/clang_format_code.sh
+tools/distrib/check_include_guards.py --fix
 tools/distrib/check_copyright.py --fix
+tools/distrib/add-iwyu.py
 tools/distrib/check_trailing_newlines.sh --fix
 tools/run_tests/sanity/check_port_platform.py --fix
+tools/run_tests/sanity/check_include_style.py --fix || true
+tools/distrib/yapf_code.sh
+tools/distrib/isort_code.sh
+tools/distrib/clang_format_code.sh
+tools/distrib/buildifier_format_code.sh || true
 
@@ -12,7 +12,7 @@
 # See the License for the specific language governing permissions and
 # limitations under the License.
 
-FROM debian:stretch
+FROM debian:buster
 
 RUN apt-get update && apt-get install -y python3 python3-pip
 RUN pip3 install virtualenv==16.7.9
@@ -12,7 +12,7 @@
 # See the License for the specific language governing permissions and
 # limitations under the License.
 
-FROM i386/debian:stretch
+FROM i386/debian:buster
 
 RUN apt-get update && apt-get install -y python3 python3-pip
 
index 4c9e480..13f0a0a 100644 (file)
 # limitations under the License.
 
 # Docker file for building gRPC artifacts.
-# Updated: 2020-10-08
+# Updated: 2021-08-23
 
 ##################
 # Base
 
-FROM dockcross/manylinux2010-x64
+FROM dockcross/manylinux2010-x64:20210210-84c47e5
 
 # Install essential packages.
 RUN yum -y install golang strace
@@ -28,7 +28,8 @@ RUN yum -y install golang strace
 # Ruby dependencies
 
 # Install rvm
-RUN gpg --keyserver hkp://pool.sks-keyservers.net --recv-keys 409B6B1796C275462A1703113804BB82D39DC0E3 7D2BAF1CF37B13E2069D6956105BD0E739499BDB
+RUN curl -sSL https://rvm.io/mpapis.asc | gpg --import -
+RUN curl -sSL https://rvm.io/pkuczynski.asc | gpg --import -
 RUN \curl -sSL https://get.rvm.io | bash -s stable
 
 # Install Ruby 2.6
index 96effec..49f595e 100644 (file)
@@ -13,7 +13,7 @@
 # limitations under the License.
 
 # Docker file for building gRPC artifacts.
-# Updated: 2020-10-08
+# Updated: 2021-08-23
 
 ##################
 # Base
@@ -28,7 +28,8 @@ RUN yum -y install golang strace
 # Ruby dependencies
 
 # Install rvm
-RUN gpg --keyserver hkp://pool.sks-keyservers.net --recv-keys 409B6B1796C275462A1703113804BB82D39DC0E3 7D2BAF1CF37B13E2069D6956105BD0E739499BDB
+RUN curl -sSL https://rvm.io/mpapis.asc | gpg --import -
+RUN curl -sSL https://rvm.io/pkuczynski.asc | gpg --import -
 RUN \curl -sSL https://get.rvm.io | bash -s stable
 
 # Install Ruby 2.6
index 9af7874..aec4000 100644 (file)
@@ -22,10 +22,12 @@ RUN apt update && apt install -y build-essential zlib1g-dev libncurses5-dev libg
 
 ADD install_python_for_wheel_crosscompilation.sh /scripts/install_python_for_wheel_crosscompilation.sh
 
-RUN /scripts/install_python_for_wheel_crosscompilation.sh 3.6.13 /opt/python/cp36-cp36m
-RUN /scripts/install_python_for_wheel_crosscompilation.sh 3.7.10 /opt/python/cp37-cp37m
-RUN /scripts/install_python_for_wheel_crosscompilation.sh 3.8.8 /opt/python/cp38-cp38
-RUN /scripts/install_python_for_wheel_crosscompilation.sh 3.9.2 /opt/python/cp39-cp39
+RUN /scripts/install_python_for_wheel_crosscompilation.sh "3.6.13" "3.6.13" /opt/python/cp36-cp36m
+RUN /scripts/install_python_for_wheel_crosscompilation.sh "3.7.10" "3.7.10" /opt/python/cp37-cp37m
+RUN /scripts/install_python_for_wheel_crosscompilation.sh "3.8.8" "3.8.8" /opt/python/cp38-cp38
+RUN /scripts/install_python_for_wheel_crosscompilation.sh "3.9.2" "3.9.2" /opt/python/cp39-cp39
+RUN /scripts/install_python_for_wheel_crosscompilation.sh "3.9.2" "3.9.2" /opt/python/cp39-cp39
+RUN /scripts/install_python_for_wheel_crosscompilation.sh "3.10.0" "3.10.0rc1" /opt/python/cp310-cp310
 
 ENV AUDITWHEEL_ARCH armv7l
 ENV AUDITWHEEL_PLAT linux_armv7l
index cc7349b..0b5014c 100755 (executable)
@@ -19,11 +19,12 @@ set -ex
 # $1 - python version in "3.X.Y" format
 # $2 - python tags (as in manylinx images) e.g. "/opt/python/cp37-cp37m"
 PYTHON_VERSION="$1"
-PYTHON_PREFIX="$2"
+PYTHON_RELEASE="$2"
+PYTHON_PREFIX="$3"
 
-curl -O "https://www.python.org/ftp/python/${PYTHON_VERSION}/Python-${PYTHON_VERSION}.tar.xz"
-tar -xf "Python-${PYTHON_VERSION}.tar.xz"
-pushd "Python-${PYTHON_VERSION}"
+curl -O "https://www.python.org/ftp/python/${PYTHON_VERSION}/Python-${PYTHON_RELEASE}.tar.xz"
+tar -xf "Python-${PYTHON_RELEASE}.tar.xz"
+pushd "Python-${PYTHON_RELEASE}"
 
 # In this step, we are building python that can run on the architecture where the build runs (x64).
 # Since the CC, CXX and other env vars are set by default to point to the crosscompilation toolchain,
 # See the License for the specific language governing permissions and
 # limitations under the License.
 
-# The aarch64 wheels are being crosscompiled to allow running the build
-# on x64 machine. The dockcross/manylinux2014-aarch64 image is a x86_64
-# image with crosscompilation toolchain installed.
-# We use an older version of dockcross image that has gcc4.9.4 because it was built
-# before https://github.com/dockcross/dockcross/pull/449
-# Thanks to that, wheel build with this image aren't actually
-# compliant with manylinux2014, but only with manylinux_2_24
-FROM dockcross/manylinux2014-aarch64:20200929-608e6ac
+FROM dockcross/manylinux2014-aarch64:20210826-19322ba
 
-# Make the grpc wheels correctly tagged with manylinux_2_24
-# instead of the incorrect manylinux2014 (see the note above).
-ENV AUDITWHEEL_PLAT manylinux_2_24_$AUDITWHEEL_ARCH
+# manylinux_2_17 is the preferred alias of manylinux2014
+ENV AUDITWHEEL_PLAT manylinux_2_17_$AUDITWHEEL_ARCH
 
 ###################################
 # Install Python build requirements
-RUN /opt/python/cp35-cp35m/bin/pip install --upgrade cython
 RUN /opt/python/cp36-cp36m/bin/pip install --upgrade cython
 RUN /opt/python/cp37-cp37m/bin/pip install --upgrade cython
 RUN /opt/python/cp38-cp38/bin/pip install --upgrade cython
 RUN /opt/python/cp39-cp39/bin/pip install --upgrade cython
+RUN /opt/python/cp310-cp310/bin/pip install --upgrade cython
 
 # the dockcross docker image sets variables like CC, CXX etc.
 # to point to the crosscompilation toolchain, but doesn't set corresponding
index 7747552..4c855eb 100644 (file)
 # limitations under the License.
 
 # Docker file for building gRPC manylinux Python artifacts.
-# Updated: 2020-10-08
 
-FROM quay.io/pypa/manylinux2014_x86_64
+FROM quay.io/pypa/manylinux2014_x86_64:2021-08-26-12e5da0
+
+# manylinux_2_17 is the preferred alias of manylinux2014
+ENV AUDITWHEEL_PLAT manylinux_2_17_$AUDITWHEEL_ARCH
 
 # TODO(jtattermusch): revisit which of the deps are really required
 RUN yum update -y && yum install -y curl-devel expat-devel gettext-devel openssl-devel zlib-devel
 
 ###################################
 # Install Python build requirements
-RUN /opt/python/cp35-cp35m/bin/pip install --upgrade cython
 RUN /opt/python/cp36-cp36m/bin/pip install --upgrade cython
 RUN /opt/python/cp37-cp37m/bin/pip install --upgrade cython
 RUN /opt/python/cp38-cp38/bin/pip install --upgrade cython
 RUN /opt/python/cp39-cp39/bin/pip install --upgrade cython
+RUN /opt/python/cp310-cp310/bin/pip install --upgrade cython
index 45f64ac..837454b 100644 (file)
 # limitations under the License.
 
 # Docker file for building gRPC manylinux Python artifacts.
-# Updated: 2020-10-08
 
-FROM quay.io/pypa/manylinux2014_i686
+FROM quay.io/pypa/manylinux2014_i686:2021-08-26-12e5da0
+
+# manylinux_2_17 is the preferred alias of manylinux2014
+ENV AUDITWHEEL_PLAT manylinux_2_17_$AUDITWHEEL_ARCH
 
 # TODO(jtattermusch): revisit which of the deps are really required
 RUN yum update -y && yum install -y curl-devel expat-devel gettext-devel openssl-devel zlib-devel
 
 ###################################
 # Install Python build requirements
-RUN /opt/python/cp35-cp35m/bin/pip install --upgrade cython
 RUN /opt/python/cp36-cp36m/bin/pip install --upgrade cython
 RUN /opt/python/cp37-cp37m/bin/pip install --upgrade cython
 RUN /opt/python/cp38-cp38/bin/pip install --upgrade cython
 RUN /opt/python/cp39-cp39/bin/pip install --upgrade cython
+RUN /opt/python/cp310-cp310/bin/pip install --upgrade cython
index ff6f2f5..e12d5f2 100755 (executable)
@@ -16,7 +16,7 @@
 set -e
 
 # directories to run against
-DIRS="examples/cpp src/core/lib src/core/tsi src/core/ext src/cpp test/core test/cpp include src/compiler src/csharp src/ruby third_party/address_sorting src/objective-c tools/distrib/python"
+DIRS="examples/cpp examples/android/binder src/core/lib src/core/tsi src/core/ext src/cpp test/core test/cpp include src/compiler src/csharp src/ruby src/objective-c tools/distrib/python"
 
 # file matching patterns to check
 GLOB="*.h *.c *.cc *.m *.mm"
index adc91d1..5797237 100644 (file)
@@ -15,7 +15,7 @@
 FROM debian:bullseye
 
 # Install clang-tidy 11
-RUN apt-get update && apt-get install -y clang-tidy-11 jq
+RUN apt-get update && apt-get install -y clang-tidy-11 jq git
 ENV CLANG_TIDY=clang-tidy-11
 
 ADD clang_tidy_all_the_things.sh /
index e022ba2..782401d 100644 (file)
@@ -63,7 +63,7 @@ RUN apt-get update && apt-get install -y \
 RUN curl https://bootstrap.pypa.io/pip/2.7/get-pip.py | python2.7
 RUN pip install --upgrade pip==19.3.1
 RUN pip install virtualenv==16.7.9
-RUN pip install futures==2.2.0 enum34==1.0.4 protobuf==3.5.2.post1 six==1.15.0 twisted==17.5.0
+RUN pip install futures==3.1.1 enum34==1.1.10 protobuf==3.5.2.post1 six==1.16.0 twisted==19.10.0
 
 #================
 # C# dependencies
index e022ba2..782401d 100644 (file)
@@ -63,7 +63,7 @@ RUN apt-get update && apt-get install -y \
 RUN curl https://bootstrap.pypa.io/pip/2.7/get-pip.py | python2.7
 RUN pip install --upgrade pip==19.3.1
 RUN pip install virtualenv==16.7.9
-RUN pip install futures==2.2.0 enum34==1.0.4 protobuf==3.5.2.post1 six==1.15.0 twisted==17.5.0
+RUN pip install futures==3.1.1 enum34==1.1.10 protobuf==3.5.2.post1 six==1.16.0 twisted==19.10.0
 
 #================
 # C# dependencies
index e256ae9..a05e053 100644 (file)
@@ -12,7 +12,7 @@
 # See the License for the specific language governing permissions and
 # limitations under the License.
 
-FROM debian:jessie
+FROM debian:8
 
 
 # Install Git and basic packages.
@@ -64,7 +64,7 @@ RUN apt-get update && apt-get install -y \
 RUN curl https://bootstrap.pypa.io/pip/2.7/get-pip.py | python2.7
 RUN pip install --upgrade pip==19.3.1
 RUN pip install virtualenv==16.7.9
-RUN pip install futures==2.2.0 enum34==1.0.4 protobuf==3.5.2.post1 six==1.15.0 twisted==17.5.0
+RUN pip install futures==3.1.1 enum34==1.1.10 protobuf==3.5.2.post1 six==1.16.0 twisted==19.10.0
 
 #=================
 # C++ dependencies
index 3863cde..8ec46b2 100644 (file)
@@ -31,7 +31,7 @@ RUN apt-get update && apt-get install -y \
 RUN curl https://bootstrap.pypa.io/pip/2.7/get-pip.py | python2.7
 RUN pip install --upgrade pip==19.3.1
 RUN pip install virtualenv==16.7.9
-RUN pip install futures==2.2.0 enum34==1.0.4 protobuf==3.5.2.post1 six==1.15.0 twisted==17.5.0
+RUN pip install futures==3.1.1 enum34==1.1.10 protobuf==3.5.2.post1 six==1.16.0 twisted==19.10.0
 
 # Define the default command.
 CMD ["bash"]
index e067d31..bee821e 100644 (file)
@@ -31,7 +31,7 @@ RUN apt-get update && apt-get install -y \
 RUN curl https://bootstrap.pypa.io/pip/2.7/get-pip.py | python2.7
 RUN pip install --upgrade pip==19.3.1
 RUN pip install virtualenv==16.7.9
-RUN pip install futures==2.2.0 enum34==1.0.4 protobuf==3.5.2.post1 six==1.15.0 twisted==17.5.0
+RUN pip install futures==3.1.1 enum34==1.1.10 protobuf==3.5.2.post1 six==1.16.0 twisted==19.10.0
 
 # Define the default command.
 CMD ["bash"]
index 3863cde..8ec46b2 100644 (file)
@@ -31,7 +31,7 @@ RUN apt-get update && apt-get install -y \
 RUN curl https://bootstrap.pypa.io/pip/2.7/get-pip.py | python2.7
 RUN pip install --upgrade pip==19.3.1
 RUN pip install virtualenv==16.7.9
-RUN pip install futures==2.2.0 enum34==1.0.4 protobuf==3.5.2.post1 six==1.15.0 twisted==17.5.0
+RUN pip install futures==3.1.1 enum34==1.1.10 protobuf==3.5.2.post1 six==1.16.0 twisted==19.10.0
 
 # Define the default command.
 CMD ["bash"]
index 4ceff25..e214fcc 100644 (file)
@@ -31,7 +31,7 @@ RUN apt-get update && apt-get install -y \
 RUN curl https://bootstrap.pypa.io/pip/2.7/get-pip.py | python2.7
 RUN pip install --upgrade pip==19.3.1
 RUN pip install virtualenv==16.7.9
-RUN pip install futures==2.2.0 enum34==1.0.4 protobuf==3.5.2.post1 six==1.15.0 twisted==17.5.0
+RUN pip install futures==3.1.1 enum34==1.1.10 protobuf==3.5.2.post1 six==1.16.0 twisted==19.10.0
 
 # Define the default command.
 CMD ["bash"]
index 30bf79e..d8f1457 100644 (file)
@@ -31,7 +31,7 @@ RUN apt-get update && apt-get install -y \
 RUN curl https://bootstrap.pypa.io/pip/2.7/get-pip.py | python2.7
 RUN pip install --upgrade pip==19.3.1
 RUN pip install virtualenv==16.7.9
-RUN pip install futures==2.2.0 enum34==1.0.4 protobuf==3.5.2.post1 six==1.15.0 twisted==17.5.0
+RUN pip install futures==3.1.1 enum34==1.1.10 protobuf==3.5.2.post1 six==1.16.0 twisted==19.10.0
 
 RUN pip install twisted h2==2.6.1 hyper
 
index b7664b3..e7edd33 100644 (file)
@@ -12,7 +12,7 @@
 # See the License for the specific language governing permissions and
 # limitations under the License.
 
-FROM debian:jessie
+FROM debian:8
 
 
 RUN echo "deb http://archive.debian.org/debian/ jessie-backports main contrib non-free" > /etc/apt/sources.list.d/jessie-backports.list && \
index d71f43c..c02a333 100644 (file)
@@ -12,7 +12,7 @@
 # See the License for the specific language governing permissions and
 # limitations under the License.
 
-FROM debian:jessie
+FROM debian:8
 
 
 # Install Git and basic packages.
@@ -64,7 +64,7 @@ RUN apt-get update && apt-get install -y \
 RUN curl https://bootstrap.pypa.io/pip/2.7/get-pip.py | python2.7
 RUN pip install --upgrade pip==19.3.1
 RUN pip install virtualenv==16.7.9
-RUN pip install futures==2.2.0 enum34==1.0.4 protobuf==3.5.2.post1 six==1.15.0 twisted==17.5.0
+RUN pip install futures==3.1.1 enum34==1.1.10 protobuf==3.5.2.post1 six==1.16.0 twisted==19.10.0
 
 #==================
 # Node dependencies
index fd089f1..4143ac5 100644 (file)
@@ -12,7 +12,7 @@
 # See the License for the specific language governing permissions and
 # limitations under the License.
 
-FROM debian:jessie
+FROM debian:8
 
 
 # Install Git and basic packages.
index 77d7927..519274e 100644 (file)
@@ -12,7 +12,7 @@
 # See the License for the specific language governing permissions and
 # limitations under the License.
 
-FROM debian:jessie
+FROM debian:8
 
 
 #=================
index 6db1f56..e49dc4f 100644 (file)
@@ -63,14 +63,14 @@ RUN apt-get update && apt-get install -y \
 RUN curl https://bootstrap.pypa.io/pip/2.7/get-pip.py | python2.7
 RUN pip install --upgrade pip==19.3.1
 RUN pip install virtualenv==16.7.9
-RUN pip install futures==2.2.0 enum34==1.0.4 protobuf==3.5.2.post1 six==1.15.0 twisted==17.5.0
+RUN pip install futures==3.1.1 enum34==1.1.10 protobuf==3.5.2.post1 six==1.16.0 twisted==19.10.0
 
 #==================
 # Ruby dependencies
 
 # Install rvm
 RUN apt-get update && apt-get install -y gnupg2 && apt-get clean
-RUN gpg2 --keyserver hkp://pool.sks-keyservers.net --recv-keys 409B6B1796C275462A1703113804BB82D39DC0E3 7D2BAF1CF37B13E2069D6956105BD0E739499BDB
+RUN gpg2 --recv-keys 409B6B1796C275462A1703113804BB82D39DC0E3 7D2BAF1CF37B13E2069D6956105BD0E739499BDB
 RUN \curl -sSL https://get.rvm.io | bash -s stable
 
 # Install Ruby 2.5
index f317b5b..3ca9ebd 100644 (file)
@@ -28,7 +28,7 @@ RUN ln -s /usr/local/go/bin/go /usr/local/bin
 # Install Python packages from PyPI
 RUN pip install --upgrade pip==19.3.1
 RUN pip install virtualenv
-RUN pip install futures==2.2.0 enum34==1.0.4 protobuf==3.5.2.post1 six==1.15.0 twisted==17.5.0
+RUN pip install futures==3.1.1 enum34==1.1.10 protobuf==3.5.2.post1 six==1.16.0 twisted==19.10.0
 
 # Define the default command.
 CMD ["bash"]
index 473b490..7fee7be 100644 (file)
@@ -63,7 +63,7 @@ RUN apt-get update && apt-get install -y \
 RUN curl https://bootstrap.pypa.io/pip/2.7/get-pip.py | python2.7
 RUN pip install --upgrade pip==19.3.1
 RUN pip install virtualenv==16.7.9
-RUN pip install futures==2.2.0 enum34==1.0.4 protobuf==3.5.2.post1 six==1.15.0 twisted==17.5.0
+RUN pip install futures==3.1.1 enum34==1.1.10 protobuf==3.5.2.post1 six==1.16.0 twisted==19.10.0
 
 # Google Cloud platform API libraries
 RUN pip install --upgrade google-auth==1.24.0 google-api-python-client==1.12.8 oauth2client==4.1.0
index 7bd7eed..f81d811 100644 (file)
@@ -39,7 +39,7 @@ RUN apk update && apk add \
 # Install Python packages from PyPI
 RUN pip install --upgrade pip==19.3.1
 RUN pip install virtualenv
-RUN pip install futures==2.2.0 enum34==1.0.4 protobuf==3.5.2.post1 six==1.15.0 twisted==17.5.0
+RUN pip install futures==3.1.1 enum34==1.1.10 protobuf==3.5.2.post1 six==1.16.0 twisted==19.10.0
 RUN pip install --upgrade --ignore-installed PyYAML==5.4.1 --user
 
 # Google Cloud platform API libraries
index f133760..7fde1f0 100644 (file)
@@ -63,7 +63,7 @@ RUN apt-get update && apt-get install -y \
 RUN curl https://bootstrap.pypa.io/pip/2.7/get-pip.py | python2.7
 RUN pip install --upgrade pip==19.3.1
 RUN pip install virtualenv==16.7.9
-RUN pip install futures==2.2.0 enum34==1.0.4 protobuf==3.5.2.post1 six==1.15.0 twisted==17.5.0
+RUN pip install futures==3.1.1 enum34==1.1.10 protobuf==3.5.2.post1 six==1.16.0 twisted==19.10.0
 
 # Google Cloud platform API libraries
 RUN pip install --upgrade google-auth==1.24.0 google-api-python-client==1.12.8 oauth2client==4.1.0
index c26c5a5..1f3cfce 100644 (file)
@@ -63,7 +63,7 @@ RUN apt-get update && apt-get install -y \
 RUN curl https://bootstrap.pypa.io/pip/2.7/get-pip.py | python2.7
 RUN pip install --upgrade pip==19.3.1
 RUN pip install virtualenv==16.7.9
-RUN pip install futures==2.2.0 enum34==1.0.4 protobuf==3.5.2.post1 six==1.15.0 twisted==17.5.0
+RUN pip install futures==3.1.1 enum34==1.1.10 protobuf==3.5.2.post1 six==1.16.0 twisted==19.10.0
 
 # Google Cloud platform API libraries
 RUN pip install --upgrade google-auth==1.24.0 google-api-python-client==1.12.8 oauth2client==4.1.0
index bd59939..03f7494 100644 (file)
@@ -12,7 +12,7 @@
 # See the License for the specific language governing permissions and
 # limitations under the License.
 
-FROM debian:jessie
+FROM debian:8
 
 
 # Install Git and basic packages.
@@ -64,7 +64,7 @@ RUN apt-get update && apt-get install -y \
 RUN curl https://bootstrap.pypa.io/pip/2.7/get-pip.py | python2.7
 RUN pip install --upgrade pip==19.3.1
 RUN pip install virtualenv==16.7.9
-RUN pip install futures==2.2.0 enum34==1.0.4 protobuf==3.5.2.post1 six==1.15.0 twisted==17.5.0
+RUN pip install futures==3.1.1 enum34==1.1.10 protobuf==3.5.2.post1 six==1.16.0 twisted==19.10.0
 
 # Google Cloud platform API libraries
 RUN pip install --upgrade google-auth==1.24.0 google-api-python-client==1.12.8 oauth2client==4.1.0
index d5291bf..752eba9 100644 (file)
@@ -64,7 +64,7 @@ RUN apt-get update && apt-get install -y \
 RUN curl https://bootstrap.pypa.io/pip/2.7/get-pip.py | python2.7
 RUN pip install --upgrade pip==19.3.1
 RUN pip install virtualenv==16.7.9
-RUN pip install futures==2.2.0 enum34==1.0.4 protobuf==3.5.2.post1 six==1.15.0 twisted==17.5.0
+RUN pip install futures==3.1.1 enum34==1.1.10 protobuf==3.5.2.post1 six==1.16.0 twisted==19.10.0
 
 # Google Cloud platform API libraries
 RUN pip install --upgrade google-auth==1.24.0 google-api-python-client==1.12.8 oauth2client==4.1.0
index b5dfa6d..1d895b2 100644 (file)
@@ -63,7 +63,7 @@ RUN apt-get update && apt-get install -y \
 RUN curl https://bootstrap.pypa.io/pip/2.7/get-pip.py | python2.7
 RUN pip install --upgrade pip==19.3.1
 RUN pip install virtualenv==16.7.9
-RUN pip install futures==2.2.0 enum34==1.0.4 protobuf==3.5.2.post1 six==1.15.0 twisted==17.5.0
+RUN pip install futures==3.1.1 enum34==1.1.10 protobuf==3.5.2.post1 six==1.16.0 twisted==19.10.0
 
 # Google Cloud platform API libraries
 RUN pip install --upgrade google-auth==1.24.0 google-api-python-client==1.12.8 oauth2client==4.1.0
index db927f8..8201224 100644 (file)
@@ -63,7 +63,7 @@ RUN apt-get update && apt-get install -y \
 RUN curl https://bootstrap.pypa.io/pip/2.7/get-pip.py | python2.7
 RUN pip install --upgrade pip==19.3.1
 RUN pip install virtualenv==16.7.9
-RUN pip install futures==2.2.0 enum34==1.0.4 protobuf==3.5.2.post1 six==1.15.0 twisted==17.5.0
+RUN pip install futures==3.1.1 enum34==1.1.10 protobuf==3.5.2.post1 six==1.16.0 twisted==19.10.0
 
 # Google Cloud platform API libraries
 RUN pip install --upgrade google-auth==1.24.0 google-api-python-client==1.12.8 oauth2client==4.1.0
index 35e07a8..eb2e42e 100644 (file)
@@ -12,7 +12,7 @@
 # See the License for the specific language governing permissions and
 # limitations under the License.
 
-FROM debian:jessie
+FROM debian:8
 
 
 # Install Git and basic packages.
@@ -75,7 +75,7 @@ RUN apt-get update && apt-get install -y \
 RUN curl https://bootstrap.pypa.io/pip/2.7/get-pip.py | python2.7
 RUN pip install --upgrade pip==19.3.1
 RUN pip install virtualenv==16.7.9
-RUN pip install futures==2.2.0 enum34==1.0.4 protobuf==3.5.2.post1 six==1.15.0 twisted==17.5.0
+RUN pip install futures==3.1.1 enum34==1.1.10 protobuf==3.5.2.post1 six==1.16.0 twisted==19.10.0
 
 # Google Cloud platform API libraries
 RUN pip install --upgrade google-auth==1.24.0 google-api-python-client==1.12.8 oauth2client==4.1.0
index 446e287..6582ffc 100644 (file)
@@ -31,10 +31,10 @@ RUN cd pthreads && \
   make && \
   make install
 
-RUN curl https://bootstrap.pypa.io/get-pip.py | python2.7
+RUN curl https://bootstrap.pypa.io/pip/2.7/get-pip.py | python2.7
 RUN pip install --upgrade pip==19.3.1
 RUN pip install virtualenv==16.7.9
-RUN pip install futures==2.2.0 enum34==1.0.4 protobuf==3.5.2.post1 six==1.15.0 twisted==17.5.0
+RUN pip install futures==3.1.1 enum34==1.1.10 protobuf==3.5.2.post1 six==1.16.0 twisted==19.10.0
 
 RUN curl -sS https://getcomposer.org/installer | php
 RUN mv composer.phar /usr/local/bin/composer
index 2d6021c..db91aaa 100644 (file)
@@ -12,7 +12,7 @@
 # See the License for the specific language governing permissions and
 # limitations under the License.
 
-FROM debian:jessie
+FROM debian:8
 
 
 #=================
@@ -75,7 +75,7 @@ RUN apt-get update && apt-get install -y \
 RUN curl https://bootstrap.pypa.io/pip/2.7/get-pip.py | python2.7
 RUN pip install --upgrade pip==19.3.1
 RUN pip install virtualenv==16.7.9
-RUN pip install futures==2.2.0 enum34==1.0.4 protobuf==3.5.2.post1 six==1.15.0 twisted==17.5.0
+RUN pip install futures==3.1.1 enum34==1.1.10 protobuf==3.5.2.post1 six==1.16.0 twisted==19.10.0
 
 # Google Cloud platform API libraries
 RUN pip install --upgrade google-auth==1.24.0 google-api-python-client==1.12.8 oauth2client==4.1.0
index bf5f07a..eecb297 100644 (file)
@@ -39,7 +39,7 @@ RUN apk update && apk add \
 # Install Python packages from PyPI
 RUN pip install --upgrade pip==19.3.1
 RUN pip install virtualenv
-RUN pip install futures==2.2.0 enum34==1.0.4 protobuf==3.5.2.post1 six==1.15.0
+RUN pip install futures==3.1.1 enum34==1.1.10 protobuf==3.5.2.post1 six==1.16.0
 
 # Google Cloud platform API libraries
 RUN pip install --upgrade google-auth==1.24.0 google-api-python-client==1.12.8 oauth2client==4.1.0
index 80b9c33..f96d3be 100644 (file)
@@ -63,7 +63,7 @@ RUN apt-get update && apt-get install -y \
 RUN curl https://bootstrap.pypa.io/pip/2.7/get-pip.py | python2.7
 RUN pip install --upgrade pip==19.3.1
 RUN pip install virtualenv==16.7.9
-RUN pip install futures==2.2.0 enum34==1.0.4 protobuf==3.5.2.post1 six==1.15.0 twisted==17.5.0
+RUN pip install futures==3.1.1 enum34==1.1.10 protobuf==3.5.2.post1 six==1.16.0 twisted==19.10.0
 
 # Google Cloud platform API libraries
 RUN pip install --upgrade google-auth==1.24.0 google-api-python-client==1.12.8 oauth2client==4.1.0
@@ -73,7 +73,7 @@ RUN pip install --upgrade google-auth==1.24.0 google-api-python-client==1.12.8 o
 
 # Install rvm
 RUN apt-get update && apt-get install -y gnupg2 && apt-get clean
-RUN gpg2 --keyserver hkp://pool.sks-keyservers.net --recv-keys 409B6B1796C275462A1703113804BB82D39DC0E3 7D2BAF1CF37B13E2069D6956105BD0E739499BDB
+RUN gpg2 --recv-keys 409B6B1796C275462A1703113804BB82D39DC0E3 7D2BAF1CF37B13E2069D6956105BD0E739499BDB
 RUN \curl -sSL https://get.rvm.io | bash -s stable
 
 # Install Ruby 2.5
index cc7da15..a731387 100644 (file)
@@ -40,7 +40,7 @@ PROJECT_NAME           = "GRPC C++"
 # could be handy for archiving the generated documentation or if some version
 # control system is used.
 
-PROJECT_NUMBER         = 1.40.0
+PROJECT_NUMBER         = 1.41.0
 
 # Using the PROJECT_BRIEF tag one can provide an optional one line description
 # for a project that appears at the top of each page and should give viewer a
index e688b7d..d02d4bf 100644 (file)
@@ -40,7 +40,7 @@ PROJECT_NAME           = "GRPC C++"
 # could be handy for archiving the generated documentation or if some version
 # control system is used.
 
-PROJECT_NUMBER         = 1.40.0
+PROJECT_NUMBER         = 1.41.0
 
 # Using the PROJECT_BRIEF tag one can provide an optional one line description
 # for a project that appears at the top of each page and should give viewer a
@@ -1115,13 +1115,11 @@ src/core/ext/filters/client_channel/resolver.h \
 src/core/ext/filters/client_channel/resolver/dns/c_ares/dns_resolver_ares.cc \
 src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver.h \
 src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_event_engine.cc \
-src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_libuv.cc \
 src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_posix.cc \
 src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_windows.cc \
 src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper.cc \
 src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper.h \
 src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_event_engine.cc \
-src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_libuv.cc \
 src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_posix.cc \
 src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_windows.cc \
 src/core/ext/filters/client_channel/resolver/dns/dns_resolver_selection.cc \
@@ -1223,12 +1221,18 @@ src/core/ext/transport/chttp2/transport/frame_settings.cc \
 src/core/ext/transport/chttp2/transport/frame_settings.h \
 src/core/ext/transport/chttp2/transport/frame_window_update.cc \
 src/core/ext/transport/chttp2/transport/frame_window_update.h \
+src/core/ext/transport/chttp2/transport/hpack_constants.h \
 src/core/ext/transport/chttp2/transport/hpack_encoder.cc \
 src/core/ext/transport/chttp2/transport/hpack_encoder.h \
+src/core/ext/transport/chttp2/transport/hpack_encoder_index.h \
+src/core/ext/transport/chttp2/transport/hpack_encoder_table.cc \
+src/core/ext/transport/chttp2/transport/hpack_encoder_table.h \
 src/core/ext/transport/chttp2/transport/hpack_parser.cc \
 src/core/ext/transport/chttp2/transport/hpack_parser.h \
-src/core/ext/transport/chttp2/transport/hpack_table.cc \
-src/core/ext/transport/chttp2/transport/hpack_table.h \
+src/core/ext/transport/chttp2/transport/hpack_parser_table.cc \
+src/core/ext/transport/chttp2/transport/hpack_parser_table.h \
+src/core/ext/transport/chttp2/transport/hpack_utils.cc \
+src/core/ext/transport/chttp2/transport/hpack_utils.h \
 src/core/ext/transport/chttp2/transport/http2_settings.cc \
 src/core/ext/transport/chttp2/transport/http2_settings.h \
 src/core/ext/transport/chttp2/transport/huffsyms.cc \
@@ -1237,6 +1241,7 @@ src/core/ext/transport/chttp2/transport/incoming_metadata.cc \
 src/core/ext/transport/chttp2/transport/incoming_metadata.h \
 src/core/ext/transport/chttp2/transport/internal.h \
 src/core/ext/transport/chttp2/transport/parsing.cc \
+src/core/ext/transport/chttp2/transport/popularity_count.h \
 src/core/ext/transport/chttp2/transport/stream_lists.cc \
 src/core/ext/transport/chttp2/transport/stream_map.cc \
 src/core/ext/transport/chttp2/transport/stream_map.h \
@@ -1704,6 +1709,8 @@ src/core/lib/compression/stream_compression_gzip.cc \
 src/core/lib/compression/stream_compression_gzip.h \
 src/core/lib/compression/stream_compression_identity.cc \
 src/core/lib/compression/stream_compression_identity.h \
+src/core/lib/config/core_configuration.cc \
+src/core/lib/config/core_configuration.h \
 src/core/lib/debug/stats.cc \
 src/core/lib/debug/stats.h \
 src/core/lib/debug/stats_data.cc \
@@ -1750,11 +1757,6 @@ src/core/lib/gpr/time_precise.cc \
 src/core/lib/gpr/time_precise.h \
 src/core/lib/gpr/time_windows.cc \
 src/core/lib/gpr/tls.h \
-src/core/lib/gpr/tls_gcc.h \
-src/core/lib/gpr/tls_msvc.h \
-src/core/lib/gpr/tls_pthread.cc \
-src/core/lib/gpr/tls_pthread.h \
-src/core/lib/gpr/tls_stdcpp.h \
 src/core/lib/gpr/tmpfile.h \
 src/core/lib/gpr/tmpfile_msys.cc \
 src/core/lib/gpr/tmpfile_posix.cc \
@@ -1763,7 +1765,9 @@ src/core/lib/gpr/useful.h \
 src/core/lib/gpr/wrap_memcpy.cc \
 src/core/lib/gprpp/arena.cc \
 src/core/lib/gprpp/arena.h \
-src/core/lib/gprpp/atomic.h \
+src/core/lib/gprpp/atomic_utils.h \
+src/core/lib/gprpp/bitset.h \
+src/core/lib/gprpp/construct_destruct.h \
 src/core/lib/gprpp/debug_location.h \
 src/core/lib/gprpp/dual_ref_counted.h \
 src/core/lib/gprpp/examine_stack.cc \
@@ -1778,10 +1782,12 @@ src/core/lib/gprpp/global_config_generic.h \
 src/core/lib/gprpp/host_port.cc \
 src/core/lib/gprpp/host_port.h \
 src/core/lib/gprpp/manual_constructor.h \
+src/core/lib/gprpp/match.h \
 src/core/lib/gprpp/memory.h \
 src/core/lib/gprpp/mpscq.cc \
 src/core/lib/gprpp/mpscq.h \
 src/core/lib/gprpp/orphanable.h \
+src/core/lib/gprpp/overload.h \
 src/core/lib/gprpp/ref_counted.h \
 src/core/lib/gprpp/ref_counted_ptr.h \
 src/core/lib/gprpp/stat.h \
@@ -1821,7 +1827,6 @@ src/core/lib/iomgr/endpoint_cfstream.h \
 src/core/lib/iomgr/endpoint_pair.h \
 src/core/lib/iomgr/endpoint_pair_event_engine.cc \
 src/core/lib/iomgr/endpoint_pair_posix.cc \
-src/core/lib/iomgr/endpoint_pair_uv.cc \
 src/core/lib/iomgr/endpoint_pair_windows.cc \
 src/core/lib/iomgr/error.cc \
 src/core/lib/iomgr/error.h \
@@ -1882,7 +1887,6 @@ src/core/lib/iomgr/iomgr_internal.cc \
 src/core/lib/iomgr/iomgr_internal.h \
 src/core/lib/iomgr/iomgr_posix.cc \
 src/core/lib/iomgr/iomgr_posix_cfstream.cc \
-src/core/lib/iomgr/iomgr_uv.cc \
 src/core/lib/iomgr/iomgr_windows.cc \
 src/core/lib/iomgr/is_epollexclusive_available.cc \
 src/core/lib/iomgr/is_epollexclusive_available.h \
@@ -1903,8 +1907,6 @@ src/core/lib/iomgr/pollset_set_custom.cc \
 src/core/lib/iomgr/pollset_set_custom.h \
 src/core/lib/iomgr/pollset_set_windows.cc \
 src/core/lib/iomgr/pollset_set_windows.h \
-src/core/lib/iomgr/pollset_uv.cc \
-src/core/lib/iomgr/pollset_uv.h \
 src/core/lib/iomgr/pollset_windows.cc \
 src/core/lib/iomgr/pollset_windows.h \
 src/core/lib/iomgr/port.h \
@@ -1918,7 +1920,6 @@ src/core/lib/iomgr/resolve_address_windows.cc \
 src/core/lib/iomgr/resource_quota.cc \
 src/core/lib/iomgr/resource_quota.h \
 src/core/lib/iomgr/sockaddr.h \
-src/core/lib/iomgr/sockaddr_custom.h \
 src/core/lib/iomgr/sockaddr_posix.h \
 src/core/lib/iomgr/sockaddr_windows.h \
 src/core/lib/iomgr/socket_factory_posix.cc \
@@ -1930,7 +1931,6 @@ src/core/lib/iomgr/socket_utils_common_posix.cc \
 src/core/lib/iomgr/socket_utils_linux.cc \
 src/core/lib/iomgr/socket_utils_posix.cc \
 src/core/lib/iomgr/socket_utils_posix.h \
-src/core/lib/iomgr/socket_utils_uv.cc \
 src/core/lib/iomgr/socket_utils_windows.cc \
 src/core/lib/iomgr/socket_windows.cc \
 src/core/lib/iomgr/socket_windows.h \
@@ -1955,7 +1955,6 @@ src/core/lib/iomgr/tcp_server_utils_posix_common.cc \
 src/core/lib/iomgr/tcp_server_utils_posix_ifaddrs.cc \
 src/core/lib/iomgr/tcp_server_utils_posix_noifaddrs.cc \
 src/core/lib/iomgr/tcp_server_windows.cc \
-src/core/lib/iomgr/tcp_uv.cc \
 src/core/lib/iomgr/tcp_windows.cc \
 src/core/lib/iomgr/tcp_windows.h \
 src/core/lib/iomgr/time_averaged_stats.cc \
@@ -1970,7 +1969,6 @@ src/core/lib/iomgr/timer_heap.cc \
 src/core/lib/iomgr/timer_heap.h \
 src/core/lib/iomgr/timer_manager.cc \
 src/core/lib/iomgr/timer_manager.h \
-src/core/lib/iomgr/timer_uv.cc \
 src/core/lib/iomgr/udp_server.cc \
 src/core/lib/iomgr/udp_server.h \
 src/core/lib/iomgr/unix_sockets_posix.cc \
@@ -1999,6 +1997,8 @@ src/core/lib/security/authorization/authorization_policy_provider.h \
 src/core/lib/security/authorization/authorization_policy_provider_vtable.cc \
 src/core/lib/security/authorization/evaluate_args.cc \
 src/core/lib/security/authorization/evaluate_args.h \
+src/core/lib/security/authorization/sdk_server_authz_filter.cc \
+src/core/lib/security/authorization/sdk_server_authz_filter.h \
 src/core/lib/security/context/security_context.cc \
 src/core/lib/security/context/security_context.h \
 src/core/lib/security/credentials/alts/alts_credentials.cc \
index 2524a5c..b03a777 100644 (file)
@@ -40,7 +40,7 @@ PROJECT_NAME           = "GRPC Core"
 # could be handy for archiving the generated documentation or if some version
 # control system is used.
 
-PROJECT_NUMBER         = 18.0.0
+PROJECT_NUMBER         = 19.0.0
 
 # Using the PROJECT_BRIEF tag one can provide an optional one line description
 # for a project that appears at the top of each page and should give viewer a
index 72bb37c..aff4e8f 100644 (file)
@@ -40,7 +40,7 @@ PROJECT_NAME           = "GRPC Core"
 # could be handy for archiving the generated documentation or if some version
 # control system is used.
 
-PROJECT_NUMBER         = 18.0.0
+PROJECT_NUMBER         = 19.0.0
 
 # Using the PROJECT_BRIEF tag one can provide an optional one line description
 # for a project that appears at the top of each page and should give viewer a
@@ -940,13 +940,11 @@ src/core/ext/filters/client_channel/resolver/README.md \
 src/core/ext/filters/client_channel/resolver/dns/c_ares/dns_resolver_ares.cc \
 src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver.h \
 src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_event_engine.cc \
-src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_libuv.cc \
 src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_posix.cc \
 src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_windows.cc \
 src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper.cc \
 src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper.h \
 src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_event_engine.cc \
-src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_libuv.cc \
 src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_posix.cc \
 src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_windows.cc \
 src/core/ext/filters/client_channel/resolver/dns/dns_resolver_selection.cc \
@@ -1058,12 +1056,18 @@ src/core/ext/transport/chttp2/transport/frame_settings.cc \
 src/core/ext/transport/chttp2/transport/frame_settings.h \
 src/core/ext/transport/chttp2/transport/frame_window_update.cc \
 src/core/ext/transport/chttp2/transport/frame_window_update.h \
+src/core/ext/transport/chttp2/transport/hpack_constants.h \
 src/core/ext/transport/chttp2/transport/hpack_encoder.cc \
 src/core/ext/transport/chttp2/transport/hpack_encoder.h \
+src/core/ext/transport/chttp2/transport/hpack_encoder_index.h \
+src/core/ext/transport/chttp2/transport/hpack_encoder_table.cc \
+src/core/ext/transport/chttp2/transport/hpack_encoder_table.h \
 src/core/ext/transport/chttp2/transport/hpack_parser.cc \
 src/core/ext/transport/chttp2/transport/hpack_parser.h \
-src/core/ext/transport/chttp2/transport/hpack_table.cc \
-src/core/ext/transport/chttp2/transport/hpack_table.h \
+src/core/ext/transport/chttp2/transport/hpack_parser_table.cc \
+src/core/ext/transport/chttp2/transport/hpack_parser_table.h \
+src/core/ext/transport/chttp2/transport/hpack_utils.cc \
+src/core/ext/transport/chttp2/transport/hpack_utils.h \
 src/core/ext/transport/chttp2/transport/http2_settings.cc \
 src/core/ext/transport/chttp2/transport/http2_settings.h \
 src/core/ext/transport/chttp2/transport/huffsyms.cc \
@@ -1072,6 +1076,7 @@ src/core/ext/transport/chttp2/transport/incoming_metadata.cc \
 src/core/ext/transport/chttp2/transport/incoming_metadata.h \
 src/core/ext/transport/chttp2/transport/internal.h \
 src/core/ext/transport/chttp2/transport/parsing.cc \
+src/core/ext/transport/chttp2/transport/popularity_count.h \
 src/core/ext/transport/chttp2/transport/stream_lists.cc \
 src/core/ext/transport/chttp2/transport/stream_map.cc \
 src/core/ext/transport/chttp2/transport/stream_map.h \
@@ -1541,6 +1546,8 @@ src/core/lib/compression/stream_compression_gzip.cc \
 src/core/lib/compression/stream_compression_gzip.h \
 src/core/lib/compression/stream_compression_identity.cc \
 src/core/lib/compression/stream_compression_identity.h \
+src/core/lib/config/core_configuration.cc \
+src/core/lib/config/core_configuration.h \
 src/core/lib/debug/stats.cc \
 src/core/lib/debug/stats.h \
 src/core/lib/debug/stats_data.cc \
@@ -1588,11 +1595,6 @@ src/core/lib/gpr/time_precise.cc \
 src/core/lib/gpr/time_precise.h \
 src/core/lib/gpr/time_windows.cc \
 src/core/lib/gpr/tls.h \
-src/core/lib/gpr/tls_gcc.h \
-src/core/lib/gpr/tls_msvc.h \
-src/core/lib/gpr/tls_pthread.cc \
-src/core/lib/gpr/tls_pthread.h \
-src/core/lib/gpr/tls_stdcpp.h \
 src/core/lib/gpr/tmpfile.h \
 src/core/lib/gpr/tmpfile_msys.cc \
 src/core/lib/gpr/tmpfile_posix.cc \
@@ -1602,7 +1604,9 @@ src/core/lib/gpr/wrap_memcpy.cc \
 src/core/lib/gprpp/README.md \
 src/core/lib/gprpp/arena.cc \
 src/core/lib/gprpp/arena.h \
-src/core/lib/gprpp/atomic.h \
+src/core/lib/gprpp/atomic_utils.h \
+src/core/lib/gprpp/bitset.h \
+src/core/lib/gprpp/construct_destruct.h \
 src/core/lib/gprpp/debug_location.h \
 src/core/lib/gprpp/dual_ref_counted.h \
 src/core/lib/gprpp/examine_stack.cc \
@@ -1617,10 +1621,12 @@ src/core/lib/gprpp/global_config_generic.h \
 src/core/lib/gprpp/host_port.cc \
 src/core/lib/gprpp/host_port.h \
 src/core/lib/gprpp/manual_constructor.h \
+src/core/lib/gprpp/match.h \
 src/core/lib/gprpp/memory.h \
 src/core/lib/gprpp/mpscq.cc \
 src/core/lib/gprpp/mpscq.h \
 src/core/lib/gprpp/orphanable.h \
+src/core/lib/gprpp/overload.h \
 src/core/lib/gprpp/ref_counted.h \
 src/core/lib/gprpp/ref_counted_ptr.h \
 src/core/lib/gprpp/stat.h \
@@ -1661,7 +1667,6 @@ src/core/lib/iomgr/endpoint_cfstream.h \
 src/core/lib/iomgr/endpoint_pair.h \
 src/core/lib/iomgr/endpoint_pair_event_engine.cc \
 src/core/lib/iomgr/endpoint_pair_posix.cc \
-src/core/lib/iomgr/endpoint_pair_uv.cc \
 src/core/lib/iomgr/endpoint_pair_windows.cc \
 src/core/lib/iomgr/error.cc \
 src/core/lib/iomgr/error.h \
@@ -1722,7 +1727,6 @@ src/core/lib/iomgr/iomgr_internal.cc \
 src/core/lib/iomgr/iomgr_internal.h \
 src/core/lib/iomgr/iomgr_posix.cc \
 src/core/lib/iomgr/iomgr_posix_cfstream.cc \
-src/core/lib/iomgr/iomgr_uv.cc \
 src/core/lib/iomgr/iomgr_windows.cc \
 src/core/lib/iomgr/is_epollexclusive_available.cc \
 src/core/lib/iomgr/is_epollexclusive_available.h \
@@ -1743,8 +1747,6 @@ src/core/lib/iomgr/pollset_set_custom.cc \
 src/core/lib/iomgr/pollset_set_custom.h \
 src/core/lib/iomgr/pollset_set_windows.cc \
 src/core/lib/iomgr/pollset_set_windows.h \
-src/core/lib/iomgr/pollset_uv.cc \
-src/core/lib/iomgr/pollset_uv.h \
 src/core/lib/iomgr/pollset_windows.cc \
 src/core/lib/iomgr/pollset_windows.h \
 src/core/lib/iomgr/port.h \
@@ -1758,7 +1760,6 @@ src/core/lib/iomgr/resolve_address_windows.cc \
 src/core/lib/iomgr/resource_quota.cc \
 src/core/lib/iomgr/resource_quota.h \
 src/core/lib/iomgr/sockaddr.h \
-src/core/lib/iomgr/sockaddr_custom.h \
 src/core/lib/iomgr/sockaddr_posix.h \
 src/core/lib/iomgr/sockaddr_windows.h \
 src/core/lib/iomgr/socket_factory_posix.cc \
@@ -1770,7 +1771,6 @@ src/core/lib/iomgr/socket_utils_common_posix.cc \
 src/core/lib/iomgr/socket_utils_linux.cc \
 src/core/lib/iomgr/socket_utils_posix.cc \
 src/core/lib/iomgr/socket_utils_posix.h \
-src/core/lib/iomgr/socket_utils_uv.cc \
 src/core/lib/iomgr/socket_utils_windows.cc \
 src/core/lib/iomgr/socket_windows.cc \
 src/core/lib/iomgr/socket_windows.h \
@@ -1795,7 +1795,6 @@ src/core/lib/iomgr/tcp_server_utils_posix_common.cc \
 src/core/lib/iomgr/tcp_server_utils_posix_ifaddrs.cc \
 src/core/lib/iomgr/tcp_server_utils_posix_noifaddrs.cc \
 src/core/lib/iomgr/tcp_server_windows.cc \
-src/core/lib/iomgr/tcp_uv.cc \
 src/core/lib/iomgr/tcp_windows.cc \
 src/core/lib/iomgr/tcp_windows.h \
 src/core/lib/iomgr/time_averaged_stats.cc \
@@ -1810,7 +1809,6 @@ src/core/lib/iomgr/timer_heap.cc \
 src/core/lib/iomgr/timer_heap.h \
 src/core/lib/iomgr/timer_manager.cc \
 src/core/lib/iomgr/timer_manager.h \
-src/core/lib/iomgr/timer_uv.cc \
 src/core/lib/iomgr/udp_server.cc \
 src/core/lib/iomgr/udp_server.h \
 src/core/lib/iomgr/unix_sockets_posix.cc \
@@ -1839,6 +1837,8 @@ src/core/lib/security/authorization/authorization_policy_provider.h \
 src/core/lib/security/authorization/authorization_policy_provider_vtable.cc \
 src/core/lib/security/authorization/evaluate_args.cc \
 src/core/lib/security/authorization/evaluate_args.h \
+src/core/lib/security/authorization/sdk_server_authz_filter.cc \
+src/core/lib/security/authorization/sdk_server_authz_filter.h \
 src/core/lib/security/context/security_context.cc \
 src/core/lib/security/context/security_context.h \
 src/core/lib/security/credentials/alts/alts_credentials.cc \
index 8fa2ab7..c9242d5 100644 (file)
@@ -40,7 +40,7 @@ PROJECT_NAME           = "GRPC Objective-C"
 # could be handy for archiving the generated documentation or if some version
 # control system is used.
 
-PROJECT_NUMBER         = 1.40.0
+PROJECT_NUMBER         = 1.41.0
 
 # Using the PROJECT_BRIEF tag one can provide an optional one line description
 # for a project that appears at the top of each page and should give viewer a
index c3974ff..5901fa8 100644 (file)
@@ -40,7 +40,7 @@ PROJECT_NAME           = "GRPC Objective-C"
 # could be handy for archiving the generated documentation or if some version
 # control system is used.
 
-PROJECT_NUMBER         = 1.40.0
+PROJECT_NUMBER         = 1.41.0
 
 # Using the PROJECT_BRIEF tag one can provide an optional one line description
 # for a project that appears at the top of each page and should give viewer a
index aeee868..a1ebe5c 100644 (file)
@@ -40,7 +40,7 @@ PROJECT_NAME           = "GRPC PHP"
 # could be handy for archiving the generated documentation or if some version
 # control system is used.
 
-PROJECT_NUMBER         = 1.40.0
+PROJECT_NUMBER         = 1.41.0
 
 # Using the PROJECT_BRIEF tag one can provide an optional one line description
 # for a project that appears at the top of each page and should give viewer a
index 9885adc..f0e0e6a 100644 (file)
@@ -94,3 +94,20 @@ $Python39x64Config = @{
     PythonInstallerHash = "b61a33dc28f13b561452f3089c87eb63"
 }
 Install-Python @Python39x64Config
+
+# Python 3.10
+$Python310x86Config = @{
+    PythonVersion = "3.10.0"
+    PythonInstaller = "python-3.10.0rc1"
+    PythonInstallPath = "C:\Python310_32bit"
+    PythonInstallerHash = "6de353f2f7422aa030d4ccc788ffa75e"
+}
+Install-Python @Python310x86Config
+
+$Python310x64Config = @{
+    PythonVersion = "3.10.0"
+    PythonInstaller = "python-3.10.0rc1-amd64"
+    PythonInstallPath = "C:\Python310"
+    PythonInstallerHash = "39135519b044757f0a3b09d63612b0da"
+}
+Install-Python @Python310x64Config
diff --git a/tools/internal_ci/helper_scripts/list_leftover_loadtests.sh b/tools/internal_ci/helper_scripts/list_leftover_loadtests.sh
deleted file mode 100644 (file)
index ff8f326..0000000
+++ /dev/null
@@ -1,28 +0,0 @@
-#!/usr/bin/env bash
-# Copyright 2021 The gRPC Authors
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-set -ex
-
-echo "BEGIN Listing leftover tests."
-
-# Find tests that have running pods and are in Errored state.
-kubectl get pods --no-headers -o jsonpath='{range .items[*]}{.metadata.ownerReferences[0].name}{" "}{.status.phase}{"\n"}{end}' \
-    | grep Running \
-    | cut -f1 -d' ' \
-    | sort -u \
-    | xargs -r kubectl get loadtest --no-headers -o jsonpath='{range .items[*]}{.metadata.name}{" "}{.metadata.annotations.pool}{" "}{.metadata.annotations.scenario}{" "}{.status}{"\n"}{end}' \
-    | grep '"state":"Errored"' || true
-
-echo "END Listing leftover tests."
index e1a7ca0..0f33fd5 100644 (file)
@@ -35,7 +35,7 @@ export HOMEBREW_NO_AUTO_UPDATE=1
 brew config
 
 # Add GCP credentials for BQ access
-pip install --user google-api-python-client oauth2client six==1.15.0
+pip install --user google-api-python-client oauth2client six==1.16.0
 export GOOGLE_APPLICATION_CREDENTIALS=${KOKORO_GFILE_DIR}/GrpcTesting-d0eeee2db331.json
 DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" >/dev/null 2>&1 && pwd)"
 
@@ -123,6 +123,14 @@ then
     shasum -c /tmp/python_installer_checksum.sha256
     time sudo installer -pkg ./python-3.9.0-macosx10.9.pkg -target /
   fi
+
+  # Install Python 3.10 if it doesn't exist
+  if [ ! -f "/usr/local/bin/python3.10" ]; then
+    time curl -O https://www.python.org/ftp/python/3.10.0/python-3.10.0rc1-macos11.pkg
+    echo "5933d3d72438b03742d2bb3c8d6cb0e5db165d7110bbc95dac8016f5e31fae7b  python-3.10.0rc1-macos11.pkg" > /tmp/python_installer_checksum.sha256
+    shasum -c /tmp/python_installer_checksum.sha256
+    time sudo installer -pkg ./python-3.10.0rc1-macos11.pkg -target /
+  fi
 fi
 
 if [ "${PREPARE_BUILD_INSTALL_DEPS_CSHARP}" == "true" ]
index 45e05f4..d744f90 100644 (file)
@@ -27,7 +27,18 @@ cd /var/local/git/grpc
 echo $ANDROID_HOME
 echo $ANDROID_NDK_HOME
 
-# Build all basic targets using the strict warning option which leverages the
+# Build all targets using the strict warning option which leverages the
 # clang compiler to check if sources can pass a set of warning options.
+# CPU are specified because gRPC does not build with 32bit NDK (which has socklen_t
+# defined as int due to an accident).
+# The python option is for disabling python2 enforcement when packing APK
 bazel build --define=use_strict_warning=true \
-  //examples/android/binder/java/io/grpc/binder/cpp/example:app
+  --fat_apk_cpu=x86_64,arm64-v8a \
+  --extra_toolchains=@rules_python//python:autodetecting_toolchain_nonstrict \
+  //examples/android/binder/java/io/grpc/binder/cpp/example:app \
+  //examples/android/binder/java/io/grpc/binder/cpp/exampleserver:app
+
+# Make sure the Java code that will be invoked by binder transport
+# implementation builds
+bazel build --define=use_strict_warning=true \
+  @binder_transport_android_helper//io/grpc/binder/cpp:connection_helper
@@ -1,4 +1,4 @@
-# Copyright 2017 gRPC authors.
+# Copyright 2021 The gRPC Authors
 #
 # Licensed under the Apache License, Version 2.0 (the "License");
 # you may not use this file except in compliance with the License.
 # Config file for the internal CI (in protobuf text format)
 
 # Location of the continuous shell script in repository.
-build_file: "grpc/tools/internal_ci/windows/grpc_run_tests_matrix.bat"
+build_file: "grpc/tools/internal_ci/linux/grpc_distribtests_php.sh"
 timeout_mins: 240
 action {
   define_artifacts {
     regex: "**/*sponge_log.*"
     regex: "github/grpc/reports/**"
+    regex: "github/grpc/artifacts/**"
   }
 }
-
-env_vars {
-  key: "RUN_TESTS_FLAGS"
-  value: "-f portability windows -j 1 --inner_jobs 8 --internal_ci"
-}
diff --git a/tools/internal_ci/linux/grpc_distribtests_php.sh b/tools/internal_ci/linux/grpc_distribtests_php.sh
new file mode 100755 (executable)
index 0000000..a0de670
--- /dev/null
@@ -0,0 +1,51 @@
+#!/bin/bash
+# Copyright 2021 The gRPC Authors
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+set -ex
+
+# change to grpc repo root
+cd $(dirname $0)/../../..
+
+source tools/internal_ci/helper_scripts/prepare_build_linux_rc
+
+# Build all PHP linux artifacts
+tools/run_tests/task_runner.py -f artifact linux php -j 4 -x build_artifacts/sponge_log.xml || FAILED="true"
+
+# the next step expects to find the artifacts from the previous step in the "input_artifacts" folder.
+rm -rf input_artifacts
+mkdir -p input_artifacts
+cp -r artifacts/* input_artifacts/ || true
+rm -rf artifacts_from_build_artifacts_step
+mv artifacts artifacts_from_build_artifacts_step || true
+
+# This step mostly just copies artifacts from input_artifacts (but it also does some wheel stripping)
+tools/run_tests/task_runner.py -f package linux php -x build_packages/sponge_log.xml || FAILED="true"
+
+# the next step expects to find the artifacts from the previous step in the "input_artifacts" folder.
+# in addition to that, preserve the contents of "artifacts" directory since we want kokoro
+# to upload its contents as job output artifacts
+rm -rf input_artifacts
+mkdir -p input_artifacts
+cp -r artifacts/* input_artifacts/ || true
+
+# Run all PHP linux distribtests
+# We run the distribtests even if some of the artifacts have failed to build, since that gives
+# a better signal about which distribtest are affected by the currently broken artifact builds.
+tools/run_tests/task_runner.py -f distribtest linux php -j 4 -x distribtests/sponge_log.xml || FAILED="true"
+
+if [ "$FAILED" != "" ]
+then
+  exit 1
+fi
index aef9181..7192fcc 100755 (executable)
@@ -35,7 +35,7 @@ cp -r artifacts/* input_artifacts/ || true
 rm -rf artifacts_from_build_artifacts_step
 mv artifacts artifacts_from_build_artifacts_step || true
 
-# This step mostly just copies artifacts from input_artifacts (but it also does some wheel stripping)
+# This step only copies artifacts from input_artifacts
 tools/run_tests/task_runner.py -f package linux python -x build_packages/sponge_log.xml || FAILED="true"
 
 # the next step expects to find the artifacts from the previous step in the "input_artifacts" folder.
diff --git a/tools/internal_ci/linux/grpc_distribtests_ruby.cfg b/tools/internal_ci/linux/grpc_distribtests_ruby.cfg
new file mode 100644 (file)
index 0000000..4a3d83c
--- /dev/null
@@ -0,0 +1,26 @@
+# Copyright 2021 The gRPC Authors
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+# Config file for the internal CI (in protobuf text format)
+
+# Location of the continuous shell script in repository.
+build_file: "grpc/tools/internal_ci/linux/grpc_distribtests_ruby.sh"
+timeout_mins: 240
+action {
+  define_artifacts {
+    regex: "**/*sponge_log.*"
+    regex: "github/grpc/reports/**"
+    regex: "github/grpc/artifacts/**"
+  }
+}
diff --git a/tools/internal_ci/linux/grpc_distribtests_ruby.sh b/tools/internal_ci/linux/grpc_distribtests_ruby.sh
new file mode 100755 (executable)
index 0000000..bb794e7
--- /dev/null
@@ -0,0 +1,52 @@
+#!/bin/bash
+# Copyright 2021 The gRPC Authors
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+set -ex
+
+# change to grpc repo root
+cd $(dirname $0)/../../..
+
+source tools/internal_ci/helper_scripts/prepare_build_linux_rc
+
+set +ex
+[[ -s /etc/profile.d/rvm.sh ]] && . /etc/profile.d/rvm.sh
+set -e  # rvm commands are very verbose
+rvm --default use ruby-2.4.1
+set -ex
+
+# Build all ruby linux artifacts (this step actually builds all the binary wheels and source archives)
+tools/run_tests/task_runner.py -f artifact linux ruby -j 6 -x build_artifacts/sponge_log.xml || FAILED="true"
+
+# Ruby "build_package" step is basically just a passthough for the "grpc" gems, so it's enough to just
+# copy the native gems directly to the "distribtests" step and skip the "build_package" phase entirely.
+# Note that by skipping the "build_package" step, we are also skipping the build of "grpc-tools" gem
+# but that's fine since the distribtests only test the "grpc" native gems.
+
+# The next step expects to find the artifacts from the previous step in the "input_artifacts" folder.
+# in addition to that, preserve the contents of "artifacts" directory since we want kokoro
+# to upload its contents as job output artifacts.
+rm -rf input_artifacts
+mkdir -p input_artifacts
+cp -r artifacts/ruby_native_gem_*/* input_artifacts/ || true
+
+# Run all ruby linux distribtests
+# We run the distribtests even if some of the artifacts have failed to build, since that gives
+# a better signal about which distribtest are affected by the currently broken artifact builds.
+tools/run_tests/task_runner.py -f distribtest linux ruby -j 6 -x distribtests/sponge_log.xml || FAILED="true"
+
+if [ "$FAILED" != "" ]
+then
+  exit 1
+fi
index 3a4723a..1998567 100755 (executable)
@@ -24,15 +24,11 @@ source tools/internal_ci/helper_scripts/prepare_build_linux_rc
 # pre-built images in the optimization.
 gcloud auth configure-docker
 
-# Connect to benchmarks-prod cluster.
+# Connect to benchmarks-prod2 cluster.
 gcloud config set project grpc-testing
-gcloud container clusters get-credentials benchmarks-prod \
+gcloud container clusters get-credentials benchmarks-prod2 \
     --zone us-central1-b --project grpc-testing
 
-# List tests that have running pods and are in errored state.
-# This is an unexpected condition, and it is logged here for monitoring.
-source tools/internal_ci/helper_scripts/list_leftover_loadtests.sh
-
 # Set up environment variables.
 LOAD_TEST_PREFIX="${KOKORO_BUILD_INITIATOR}"
 # BEGIN differentiate experimental configuration from master configuration.
@@ -41,9 +37,12 @@ LOAD_TEST_PREFIX="${KOKORO_BUILD_INITIATOR}"
 BIGQUERY_TABLE_8CORE=e2e_benchmarks.ci_master_results_8core
 BIGQUERY_TABLE_32CORE=e2e_benchmarks.ci_master_results_32core
 # END differentiate experimental configuration from master configuration.
+CLOUD_LOGGING_URL="https://source.cloud.google.com/results/invocations/${KOKORO_BUILD_ID}"
 PREBUILT_IMAGE_PREFIX="gcr.io/grpc-testing/e2etesting/pre_built_workers/${LOAD_TEST_PREFIX}"
 UNIQUE_IDENTIFIER="$(date +%Y%m%d%H%M%S)"
 ROOT_DIRECTORY_OF_DOCKERFILES="../test-infra/containers/pre_built_workers/"
+# Head of the workspace checked out by Kokoro.
+GRPC_GITREF="$(git show --format="%H" --no-patch)"
 # Prebuilt workers for core languages are always built from grpc/grpc.
 if [[ "${KOKORO_GITHUB_COMMIT_URL%/*}" == "https://github.com/grpc/grpc/commit" ]]; then
     GRPC_CORE_GITREF="${KOKORO_GIT_COMMIT}"
@@ -58,7 +57,7 @@ WORKER_POOL_8CORE=workers-8core-ci
 WORKER_POOL_32CORE=workers-32core-ci
 
 # Update go version.
-TEST_INFRA_GOVERSION=go1.16.6
+TEST_INFRA_GOVERSION=go1.17
 go get "golang.org/dl/${TEST_INFRA_GOVERSION}"
 "${TEST_INFRA_GOVERSION}" download
 
@@ -80,6 +79,11 @@ buildConfigs() {
         -s client_pool="${pool}" -s server_pool="${pool}" \
         -s big_query_table="${table}" -s timeout_seconds=900 \
         -s prebuilt_image_prefix="${PREBUILT_IMAGE_PREFIX}" \
+        -a ci_buildNumber="${KOKORO_BUILD_NUMBER}" \
+        -a ci_buildUrl="${CLOUD_LOGGING_URL}" \
+        -a ci_jobName="${KOKORO_JOB_NAME}" \
+        -a ci_gitCommit="${GRPC_GITREF}" \
+        -a ci_gitActualCommit="${KOKORO_GIT_COMMIT}" \
         -s prebuilt_image_tag="${UNIQUE_IDENTIFIER}" \
         --prefix="${LOAD_TEST_PREFIX}" -u "${UNIQUE_IDENTIFIER}" -u "${pool}" \
         -a pool="${pool}" --category=scalable \
@@ -112,8 +116,9 @@ time ../test-infra/bin/prepare_prebuilt_workers \
     -t "${UNIQUE_IDENTIFIER}" \
     -r "${ROOT_DIRECTORY_OF_DOCKERFILES}"
 
-# Create reports directory.
-mkdir -p runner
+# Create reports directories.
+mkdir -p "runner/${WORKER_POOL_8CORE}" "runner/${WORKER_POOL_32CORE}"
+
 
 # Run tests.
 time ../test-infra/bin/runner \
index 6223327..ed0089a 100755 (executable)
@@ -24,15 +24,11 @@ source tools/internal_ci/helper_scripts/prepare_build_linux_rc
 # pre-built images in the optimization.
 gcloud auth configure-docker
 
-# Connect to benchmarks-prod cluster.
+# Connect to benchmarks-prod2 cluster.
 gcloud config set project grpc-testing
 gcloud container clusters get-credentials benchmarks-prod2 \
     --zone us-central1-b --project grpc-testing
 
-# List tests that have running pods and are in errored state.
-# This is an unexpected condition, and it is logged here for monitoring.
-source tools/internal_ci/helper_scripts/list_leftover_loadtests.sh
-
 # Set up environment variables.
 LOAD_TEST_PREFIX="${KOKORO_BUILD_INITIATOR}"
 # BEGIN differentiate experimental configuration from master configuration.
@@ -42,9 +38,12 @@ fi
 BIGQUERY_TABLE_8CORE=e2e_benchmarks.experimental_results
 BIGQUERY_TABLE_32CORE=e2e_benchmarks.experimental_results_32core
 # END differentiate experimental configuration from master configuration.
+CLOUD_LOGGING_URL="https://source.cloud.google.com/results/invocations/${KOKORO_BUILD_ID}"
 PREBUILT_IMAGE_PREFIX="gcr.io/grpc-testing/e2etesting/pre_built_workers/${LOAD_TEST_PREFIX}"
 UNIQUE_IDENTIFIER="$(date +%Y%m%d%H%M%S)"
 ROOT_DIRECTORY_OF_DOCKERFILES="../test-infra/containers/pre_built_workers/"
+# Head of the workspace checked out by Kokoro.
+GRPC_GITREF="$(git show --format="%H" --no-patch)"
 # Prebuilt workers for core languages are always built from grpc/grpc.
 if [[ "${KOKORO_GITHUB_COMMIT_URL%/*}" == "https://github.com/grpc/grpc/commit" ]]; then
     GRPC_CORE_GITREF="${KOKORO_GIT_COMMIT}"
@@ -59,7 +58,7 @@ WORKER_POOL_8CORE=workers-8core-ci
 WORKER_POOL_32CORE=workers-32core-ci
 
 # Update go version.
-TEST_INFRA_GOVERSION=go1.16.6
+TEST_INFRA_GOVERSION=go1.17
 go get "golang.org/dl/${TEST_INFRA_GOVERSION}"
 "${TEST_INFRA_GOVERSION}" download
 
@@ -82,6 +81,11 @@ buildConfigs() {
         -s big_query_table="${table}" -s timeout_seconds=900 \
         -s prebuilt_image_prefix="${PREBUILT_IMAGE_PREFIX}" \
         -s prebuilt_image_tag="${UNIQUE_IDENTIFIER}" \
+        -a ci_buildNumber="${KOKORO_BUILD_NUMBER}" \
+        -a ci_buildUrl="${CLOUD_LOGGING_URL}" \
+        -a ci_jobName="${KOKORO_JOB_NAME}" \
+        -a ci_gitCommit="${GRPC_GITREF}" \
+        -a ci_gitActualCommit="${KOKORO_GIT_COMMIT}" \
         --prefix="${LOAD_TEST_PREFIX}" -u "${UNIQUE_IDENTIFIER}" -u "${pool}" \
         -a pool="${pool}" --category=scalable \
         --allow_client_language=c++ --allow_server_language=c++ \
@@ -113,8 +117,8 @@ time ../test-infra/bin/prepare_prebuilt_workers \
     -t "${UNIQUE_IDENTIFIER}" \
     -r "${ROOT_DIRECTORY_OF_DOCKERFILES}"
 
-# Create reports directory.
-mkdir -p runner
+# Create reports directories.
+mkdir -p "runner/${WORKER_POOL_8CORE}" "runner/${WORKER_POOL_32CORE}"
 
 # Run tests.
 time ../test-infra/bin/runner \
index 1795f04..640e66e 100755 (executable)
@@ -13,6 +13,7 @@
 # See the License for the specific language governing permissions and
 # limitations under the License.
 
+trap 'date' DEBUG
 set -ex -o igncr || set -ex
 
 mkdir -p /var/local/git
@@ -63,6 +64,7 @@ bazel build //src/python/grpcio_tests/tests_py3_only/interop:xds_interop_client
 
 # Test cases "path_matching" and "header_matching" are not included in "all",
 # because not all interop clients in all languages support these new tests.
+export PYTHONUNBUFFERED=true
 GRPC_VERBOSITY=debug GRPC_TRACE=xds_client,xds_resolver,xds_cluster_manager_lb,cds_lb,xds_cluster_resolver_lb,priority_lb,xds_cluster_impl_lb,weighted_target_lb "$PYTHON" \
   tools/run_tests/run_xds_tests.py \
     --halt_after_fail \
@@ -74,4 +76,4 @@ GRPC_VERBOSITY=debug GRPC_TRACE=xds_client,xds_resolver,xds_cluster_manager_lb,c
     --gcp_suffix=$(date '+%s') \
     --verbose \
     ${XDS_V3_OPT-} \
-    --client_cmd='bazel run --test_env="PYTHONUNBUFFERED=true" //src/python/grpcio_tests/tests_py3_only/interop:xds_interop_client -- --server=xds:///{server_uri} --stats_port={stats_port} --qps={qps} {rpcs_to_send} {metadata_to_send}'
+    --client_cmd='bazel run //src/python/grpcio_tests/tests_py3_only/interop:xds_interop_client -- --server=xds:///{server_uri} --stats_port={stats_port} --qps={qps} {rpcs_to_send} {metadata_to_send}'
index 48680b1..e462cae 100755 (executable)
@@ -13,6 +13,7 @@
 # See the License for the specific language governing permissions and
 # limitations under the License.
 
+trap 'date' DEBUG
 set -ex -o igncr || set -ex
 
 mkdir -p /var/local/git
index fd0a6d3..eea2066 100644 (file)
@@ -87,6 +87,7 @@ gcloud_update() {
 #   GKE_CLUSTER_NAME
 #   GKE_CLUSTER_ZONE
 #   KUBE_CONTEXT: Populated with name of kubectl context with GKE cluster access
+#   SECONDARY_KUBE_CONTEXT: Populated with name of kubectl context with secondary GKE cluster access, if any
 # Arguments:
 #   None
 # Outputs:
@@ -94,6 +95,12 @@ gcloud_update() {
 #   Writes authorization info $HOME/.kube/config
 #######################################
 gcloud_get_cluster_credentials() {
+  if [[ -n "${SECONDARY_GKE_CLUSTER_NAME}" && -n "${SECONDARY_GKE_CLUSTER_ZONE}" ]]; then
+    gcloud container clusters get-credentials "${SECONDARY_GKE_CLUSTER_NAME}" --zone "${SECONDARY_GKE_CLUSTER_ZONE}"
+    readonly SECONDARY_KUBE_CONTEXT="$(kubectl config current-context)"
+  else
+    readonly SECONDARY_KUBE_CONTEXT=""
+  fi
   gcloud container clusters get-credentials "${GKE_CLUSTER_NAME}" --zone "${GKE_CLUSTER_ZONE}"
   readonly KUBE_CONTEXT="$(kubectl config current-context)"
 }
@@ -292,6 +299,7 @@ kokoro_setup_python_virtual_environment() {
 #   TEST_DRIVER_FLAGFILE: Populated with relative path to test driver flagfile
 #   TEST_XML_OUTPUT_DIR: Populated with the path to test xUnit XML report
 #   KUBE_CONTEXT: Populated with name of kubectl context with GKE cluster access
+#   SECONDARY_KUBE_CONTEXT: Populated with name of kubectl context with secondary GKE cluster access, if any
 #   GIT_ORIGIN_URL: Populated with the origin URL of git repo used for the build
 #   GIT_COMMIT: Populated with the SHA-1 of git commit being built
 #   GIT_COMMIT_SHORT: Populated with the short SHA-1 of git commit being built
@@ -341,6 +349,7 @@ kokoro_setup_test_driver() {
 #   GIT_COMMIT: Populated with the SHA-1 of git commit being built
 #   GIT_COMMIT_SHORT: Populated with the short SHA-1 of git commit being built
 #   KUBE_CONTEXT: Populated with name of kubectl context with GKE cluster access
+#   SECONDARY_KUBE_CONTEXT: Populated with name of kubectl context with secondary GKE cluster access, if any
 # Arguments:
 #   The path to the folder containing the build script
 # Outputs:
@@ -351,6 +360,7 @@ local_setup_test_driver() {
   readonly SRC_DIR="$(git -C "${script_dir}" rev-parse --show-toplevel)"
   parse_src_repo_git_info SRC_DIR
   readonly KUBE_CONTEXT="${KUBE_CONTEXT:-$(kubectl config current-context)}"
+  readonly SECONDARY_KUBE_CONTEXT="${SECONDARY_KUBE_CONTEXT}"
   local test_driver_repo_dir
   test_driver_repo_dir="${TEST_DRIVER_REPO_DIR:-$(mktemp -d)/${TEST_DRIVER_REPO_NAME}}"
   test_driver_install "${test_driver_repo_dir}"
diff --git a/tools/internal_ci/linux/grpc_xds_k8s_lb.cfg b/tools/internal_ci/linux/grpc_xds_k8s_lb.cfg
new file mode 100644 (file)
index 0000000..6ec4fa7
--- /dev/null
@@ -0,0 +1,26 @@
+# Copyright 2021 gRPC authors.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+# Config file for the internal CI (in protobuf text format)
+
+# Location of the continuous shell script in repository.
+build_file: "grpc/tools/internal_ci/linux/grpc_xds_k8s_lb.sh"
+timeout_mins: 90
+action {
+  define_artifacts {
+    regex: "artifacts/**/*sponge_log.xml"
+    regex: "artifacts/**/*sponge_log.log"
+    strip_prefix: "artifacts"
+  }
+}
diff --git a/tools/internal_ci/linux/grpc_xds_k8s_lb.sh b/tools/internal_ci/linux/grpc_xds_k8s_lb.sh
new file mode 100755 (executable)
index 0000000..2fc89d4
--- /dev/null
@@ -0,0 +1,158 @@
+#!/usr/bin/env bash
+# Copyright 2021 gRPC authors.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+set -eo pipefail
+
+# Constants
+readonly GITHUB_REPOSITORY_NAME="grpc"
+# GKE Cluster
+readonly GKE_CLUSTER_NAME="interop-test-psm-lb-v1-us-central1-a"
+readonly GKE_CLUSTER_ZONE="us-central1-a"
+readonly SECONDARY_GKE_CLUSTER_NAME="interop-test-psm-lb-v1-us-west1-b"
+readonly SECONDARY_GKE_CLUSTER_ZONE="us-west1-b"
+## xDS test client Docker images
+readonly SERVER_IMAGE_NAME="gcr.io/grpc-testing/xds-interop/cpp-server"
+readonly CLIENT_IMAGE_NAME="gcr.io/grpc-testing/xds-interop/cpp-client"
+readonly FORCE_IMAGE_BUILD="${FORCE_IMAGE_BUILD:-0}"
+readonly BUILD_APP_PATH="interop-testing/build/install/grpc-interop-testing"
+
+#######################################
+# Builds test app Docker images and pushes them to GCR
+# Globals:
+#   BUILD_APP_PATH
+#   SERVER_IMAGE_NAME: Test server Docker image name
+#   CLIENT_IMAGE_NAME: Test client Docker image name
+#   GIT_COMMIT: SHA-1 of git commit being built
+# Arguments:
+#   None
+# Outputs:
+#   Writes the output of `gcloud builds submit` to stdout, stderr
+#######################################
+build_test_app_docker_images() {
+  echo "Building C++ xDS interop test app Docker images"
+  docker build -f "${SRC_DIR}/tools/dockerfile/interoptest/grpc_interop_cxx_xds/Dockerfile.xds_client" -t "${CLIENT_IMAGE_NAME}:${GIT_COMMIT}" "${SRC_DIR}"
+  docker build -f "${SRC_DIR}/tools/dockerfile/interoptest/grpc_interop_cxx_xds/Dockerfile.xds_server" -t "${SERVER_IMAGE_NAME}:${GIT_COMMIT}" "${SRC_DIR}"
+  gcloud -q auth configure-docker
+  docker push "${CLIENT_IMAGE_NAME}:${GIT_COMMIT}"
+  docker push "${SERVER_IMAGE_NAME}:${GIT_COMMIT}"
+}
+
+#######################################
+# Builds test app and its docker images unless they already exist
+# Globals:
+#   SERVER_IMAGE_NAME: Test server Docker image name
+#   CLIENT_IMAGE_NAME: Test client Docker image name
+#   GIT_COMMIT: SHA-1 of git commit being built
+#   FORCE_IMAGE_BUILD
+# Arguments:
+#   None
+# Outputs:
+#   Writes the output to stdout, stderr
+#######################################
+build_docker_images_if_needed() {
+  # Check if images already exist
+  server_tags="$(gcloud_gcr_list_image_tags "${SERVER_IMAGE_NAME}" "${GIT_COMMIT}")"
+  printf "Server image: %s:%s\n" "${SERVER_IMAGE_NAME}" "${GIT_COMMIT}"
+  echo "${server_tags:-Server image not found}"
+
+  client_tags="$(gcloud_gcr_list_image_tags "${CLIENT_IMAGE_NAME}" "${GIT_COMMIT}")"
+  printf "Client image: %s:%s\n" "${CLIENT_IMAGE_NAME}" "${GIT_COMMIT}"
+  echo "${client_tags:-Client image not found}"
+
+  # Build if any of the images are missing, or FORCE_IMAGE_BUILD=1
+  if [[ "${FORCE_IMAGE_BUILD}" == "1" || -z "${server_tags}" || -z "${client_tags}" ]]; then
+    build_test_app_docker_images
+  else
+    echo "Skipping C++ test app build"
+  fi
+}
+
+#######################################
+# Executes the test case
+# Globals:
+#   TEST_DRIVER_FLAGFILE: Relative path to test driver flagfile
+#   KUBE_CONTEXT: The name of kubectl context with GKE cluster access
+#   SECONDARY_KUBE_CONTEXT: The name of kubectl context with secondary GKE cluster access, if any
+#   TEST_XML_OUTPUT_DIR: Output directory for the test xUnit XML report
+#   SERVER_IMAGE_NAME: Test server Docker image name
+#   CLIENT_IMAGE_NAME: Test client Docker image name
+#   GIT_COMMIT: SHA-1 of git commit being built
+# Arguments:
+#   Test case name
+# Outputs:
+#   Writes the output of test execution to stdout, stderr
+#   Test xUnit report to ${TEST_XML_OUTPUT_DIR}/${test_name}/sponge_log.xml
+#######################################
+run_test() {
+  # Test driver usage:
+  # https://github.com/grpc/grpc/tree/master/tools/run_tests/xds_k8s_test_driver#basic-usage
+  local test_name="${1:?Usage: run_test test_name}"
+  python -m "tests.${test_name}" \
+    --flagfile="${TEST_DRIVER_FLAGFILE}" \
+    --kube_context="${KUBE_CONTEXT}" \
+    --secondary_kube_context="${SECONDARY_KUBE_CONTEXT}" \
+    --server_image="${SERVER_IMAGE_NAME}:${GIT_COMMIT}" \
+    --client_image="${CLIENT_IMAGE_NAME}:${GIT_COMMIT}" \
+    --xml_output_file="${TEST_XML_OUTPUT_DIR}/${test_name}/sponge_log.xml"
+}
+
+#######################################
+# Main function: provision software necessary to execute tests, and run them
+# Globals:
+#   KOKORO_ARTIFACTS_DIR
+#   GITHUB_REPOSITORY_NAME
+#   SRC_DIR: Populated with absolute path to the source repo
+#   TEST_DRIVER_REPO_DIR: Populated with the path to the repo containing
+#                         the test driver
+#   TEST_DRIVER_FULL_DIR: Populated with the path to the test driver source code
+#   TEST_DRIVER_FLAGFILE: Populated with relative path to test driver flagfile
+#   TEST_XML_OUTPUT_DIR: Populated with the path to test xUnit XML report
+#   GIT_ORIGIN_URL: Populated with the origin URL of git repo used for the build
+#   GIT_COMMIT: Populated with the SHA-1 of git commit being built
+#   GIT_COMMIT_SHORT: Populated with the short SHA-1 of git commit being built
+#   KUBE_CONTEXT: Populated with name of kubectl context with GKE cluster access
+#   SECONDARY_KUBE_CONTEXT: Populated with name of kubectl context with secondary GKE cluster access, if any
+# Arguments:
+#   None
+# Outputs:
+#   Writes the output of test execution to stdout, stderr
+#######################################
+main() {
+  local script_dir
+  script_dir="$(dirname "$0")"
+  # shellcheck source=tools/internal_ci/linux/grpc_xds_k8s_install_test_driver.sh
+  source "${script_dir}/grpc_xds_k8s_install_test_driver.sh"
+  set -x
+  if [[ -n "${KOKORO_ARTIFACTS_DIR}" ]]; then
+    kokoro_setup_test_driver "${GITHUB_REPOSITORY_NAME}"
+  else
+    local_setup_test_driver "${script_dir}"
+  fi
+  build_docker_images_if_needed
+  # Run tests
+  cd "${TEST_DRIVER_FULL_DIR}"
+  local failed_tests=0
+  test_suites=("change_backend_service_test" "failover_test" "remove_neg_test" "round_robin_test" "affinity_test")
+  for test in "${test_suites[@]}"; do
+    run_test $test || (( failed_tests++ ))
+  done
+  echo "Failed test suites: ${failed_tests}"
+  if (( failed_tests > 0 )); then
+    exit 1
+  fi
+
+}
+
+main "$@"
diff --git a/tools/internal_ci/linux/grpc_xds_k8s_lb_python.cfg b/tools/internal_ci/linux/grpc_xds_k8s_lb_python.cfg
new file mode 100644 (file)
index 0000000..3a9eacd
--- /dev/null
@@ -0,0 +1,26 @@
+# Copyright 2021 gRPC authors.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+# Config file for the internal CI (in protobuf text format)
+
+# Location of the continuous shell script in repository.
+build_file: "grpc/tools/internal_ci/linux/grpc_xds_k8s_lb_python.sh"
+timeout_mins: 90
+action {
+  define_artifacts {
+    regex: "artifacts/**/*sponge_log.xml"
+    regex: "artifacts/**/*sponge_log.log"
+    strip_prefix: "artifacts"
+  }
+}
diff --git a/tools/internal_ci/linux/grpc_xds_k8s_lb_python.sh b/tools/internal_ci/linux/grpc_xds_k8s_lb_python.sh
new file mode 100755 (executable)
index 0000000..72766b1
--- /dev/null
@@ -0,0 +1,158 @@
+#!/usr/bin/env bash
+# Copyright 2021 gRPC authors.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+set -eo pipefail
+
+# Constants
+readonly GITHUB_REPOSITORY_NAME="grpc"
+# GKE Cluster
+readonly GKE_CLUSTER_NAME="interop-test-psm-sec-v2-us-central1-a"
+readonly GKE_CLUSTER_ZONE="us-central1-a"
+readonly SECONDARY_GKE_CLUSTER_NAME="interop-test-psm-sec-v2-us-west1-b"
+readonly SECONDARY_GKE_CLUSTER_ZONE="us-west1-b"
+## xDS test client Docker images
+readonly SERVER_IMAGE_NAME="gcr.io/grpc-testing/xds-interop/cpp-server:13171a8b293837517c0446ec0e149e9d10ea3d10"
+readonly CLIENT_IMAGE_NAME="gcr.io/grpc-testing/xds-interop/python-client"
+readonly FORCE_IMAGE_BUILD="${FORCE_IMAGE_BUILD:-0}"
+readonly BUILD_APP_PATH="interop-testing/build/install/grpc-interop-testing"
+readonly LANGUAGE_NAME="Python"
+
+#######################################
+# Builds test app Docker images and pushes them to GCR
+# Globals:
+#   BUILD_APP_PATH
+#   CLIENT_IMAGE_NAME: Test client Docker image name
+#   GIT_COMMIT: SHA-1 of git commit being built
+# Arguments:
+#   None
+# Outputs:
+#   Writes the output of `gcloud builds submit` to stdout, stderr
+#######################################
+build_test_app_docker_images() {
+  echo "Building ${LANGUAGE_NAME} xDS interop test app Docker images"
+
+  pushd "${SRC_DIR}"
+  docker build \
+    -f src/python/grpcio_tests/tests_py3_only/interop/Dockerfile.client \
+    -t "${CLIENT_IMAGE_NAME}:${GIT_COMMIT}" \
+    .
+
+  popd
+
+  gcloud -q auth configure-docker
+
+  docker push "${CLIENT_IMAGE_NAME}:${GIT_COMMIT}"
+}
+
+#######################################
+# Builds test app and its docker images unless they already exist
+# Globals:
+#   CLIENT_IMAGE_NAME: Test client Docker image name
+#   GIT_COMMIT: SHA-1 of git commit being built
+#   FORCE_IMAGE_BUILD
+# Arguments:
+#   None
+# Outputs:
+#   Writes the output to stdout, stderr
+#######################################
+build_docker_images_if_needed() {
+  # Check if images already exist
+  client_tags="$(gcloud_gcr_list_image_tags "${CLIENT_IMAGE_NAME}" "${GIT_COMMIT}")"
+  printf "Client image: %s:%s\n" "${CLIENT_IMAGE_NAME}" "${GIT_COMMIT}"
+  echo "${client_tags:-Client image not found}"
+
+  # Build if any of the images are missing, or FORCE_IMAGE_BUILD=1
+  if [[ "${FORCE_IMAGE_BUILD}" == "1" || -z "${client_tags}" ]]; then
+    build_test_app_docker_images
+  else
+    echo "Skipping ${LANGUAGE_NAME} test app build"
+  fi
+}
+
+#######################################
+# Executes the test case
+# Globals:
+#   TEST_DRIVER_FLAGFILE: Relative path to test driver flagfile
+#   KUBE_CONTEXT: The name of kubectl context with GKE cluster access
+#   SECONDARY_KUBE_CONTEXT: The name of kubectl context with secondary GKE cluster access, if any
+#   TEST_XML_OUTPUT_DIR: Output directory for the test xUnit XML report
+#   CLIENT_IMAGE_NAME: Test client Docker image name
+#   GIT_COMMIT: SHA-1 of git commit being built
+# Arguments:
+#   Test case name
+# Outputs:
+#   Writes the output of test execution to stdout, stderr
+#   Test xUnit report to ${TEST_XML_OUTPUT_DIR}/${test_name}/sponge_log.xml
+#######################################
+run_test() {
+  # Test driver usage:
+  # https://github.com/grpc/grpc/tree/master/tools/run_tests/xds_k8s_test_driver#basic-usage
+  local test_name="${1:?Usage: run_test test_name}"
+  python -m "tests.${test_name}" \
+    --flagfile="${TEST_DRIVER_FLAGFILE}" \
+    --kube_context="${KUBE_CONTEXT}" \
+    --secondary_kube_context="${SECONDARY_KUBE_CONTEXT}" \
+    --client_image="${CLIENT_IMAGE_NAME}:${GIT_COMMIT}" \
+    --server_image="${SERVER_IMAGE_NAME}" \
+    --xml_output_file="${TEST_XML_OUTPUT_DIR}/${test_name}/sponge_log.xml"
+}
+
+#######################################
+# Main function: provision software necessary to execute tests, and run them
+# Globals:
+#   KOKORO_ARTIFACTS_DIR
+#   GITHUB_REPOSITORY_NAME
+#   SRC_DIR: Populated with absolute path to the source repo
+#   TEST_DRIVER_REPO_DIR: Populated with the path to the repo containing
+#                         the test driver
+#   TEST_DRIVER_FULL_DIR: Populated with the path to the test driver source code
+#   TEST_DRIVER_FLAGFILE: Populated with relative path to test driver flagfile
+#   TEST_XML_OUTPUT_DIR: Populated with the path to test xUnit XML report
+#   GIT_ORIGIN_URL: Populated with the origin URL of git repo used for the build
+#   GIT_COMMIT: Populated with the SHA-1 of git commit being built
+#   GIT_COMMIT_SHORT: Populated with the short SHA-1 of git commit being built
+#   KUBE_CONTEXT: Populated with name of kubectl context with GKE cluster access
+#   SECONDARY_KUBE_CONTEXT: Populated with name of kubectl context with secondary GKE cluster access, if any
+# Arguments:
+#   None
+# Outputs:
+#   Writes the output of test execution to stdout, stderr
+#######################################
+main() {
+  local script_dir
+  script_dir="$(dirname "$0")"
+  # shellcheck source=tools/internal_ci/linux/grpc_xds_k8s_install_test_driver.sh
+  source "${script_dir}/grpc_xds_k8s_install_test_driver.sh"
+  set -x
+  if [[ -n "${KOKORO_ARTIFACTS_DIR}" ]]; then
+    kokoro_setup_test_driver "${GITHUB_REPOSITORY_NAME}"
+  else
+    local_setup_test_driver "${script_dir}"
+  fi
+  build_docker_images_if_needed
+  # Run tests
+  cd "${TEST_DRIVER_FULL_DIR}"
+  local failed_tests=0
+  test_suites=("change_backend_service_test" "failover_test" "remove_neg_test" "round_robin_test")
+  for test in "${test_suites[@]}"; do
+    run_test $test || (( failed_tests++ ))
+  done
+  echo "Failed test suites: ${failed_tests}"
+  if (( failed_tests > 0 )); then
+    exit 1
+  fi
+}
+
+main "$@"
diff --git a/tools/internal_ci/linux/grpc_xds_k8s_xlang.cfg b/tools/internal_ci/linux/grpc_xds_k8s_xlang.cfg
new file mode 100644 (file)
index 0000000..6b7c6d7
--- /dev/null
@@ -0,0 +1,26 @@
+# Copyright 2021 gRPC authors.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+# Config file for the internal CI (in protobuf text format)
+
+# Location of the continuous shell script in repository.
+build_file: "grpc/tools/internal_ci/linux/grpc_xds_k8s_xlang.sh"
+timeout_mins: 420
+action {
+  define_artifacts {
+    regex: "artifacts/**/*sponge_log.xml"
+    regex: "artifacts/**/*sponge_log.log"
+    strip_prefix: "artifacts"
+  }
+}
diff --git a/tools/internal_ci/linux/grpc_xds_k8s_xlang.sh b/tools/internal_ci/linux/grpc_xds_k8s_xlang.sh
new file mode 100755 (executable)
index 0000000..b44bd79
--- /dev/null
@@ -0,0 +1,120 @@
+#!/usr/bin/env bash
+# Copyright 2021 gRPC authors.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+set -eo pipefail
+
+# Constants
+readonly GITHUB_REPOSITORY_NAME="grpc"
+# GKE Cluster
+readonly GKE_CLUSTER_NAME="interop-test-psm-sec-v2-us-central1-a"
+readonly GKE_CLUSTER_ZONE="us-central1-a"
+
+## xDS test server/client Docker images
+readonly IMAGE_REPO="gcr.io/grpc-testing/xds-interop"
+readonly SERVER_LANG="cpp go java"
+readonly CLIENT_LANG="cpp go java"
+readonly VERSION_TAG="v1.40.x"
+
+#######################################
+# Executes the test case
+# Globals:
+#   TEST_DRIVER_FLAGFILE: Relative path to test driver flagfile
+#   KUBE_CONTEXT: The name of kubectl context with GKE cluster access
+#   TEST_XML_OUTPUT_DIR: Output directory for the test xUnit XML report
+#   SERVER_IMAGE_NAME: Test server Docker image name
+#   CLIENT_IMAGE_NAME: Test client Docker image name
+#   GIT_COMMIT: SHA-1 of git commit being built
+# Arguments:
+#   Test case name
+# Outputs:
+#   Writes the output of test execution to stdout, stderr
+#   Test xUnit report to ${TEST_XML_OUTPUT_DIR}/${test_name}/sponge_log.xml
+#######################################
+run_test() {
+  # Test driver usage:
+  # https://github.com/grpc/grpc/tree/master/tools/run_tests/xds_k8s_test_driver#basic-usage
+  local tag="${1:?Usage: run_test tag server_lang client_lang}"
+  local slang="${2:?Usage: run_test tag server_lang client_lang}"
+  local clang="${3:?Usage: run_test tag server_lang client_lang}"
+  local server_image_name="${IMAGE_REPO}/${slang}-server:${tag}"
+  local client_image_name="${IMAGE_REPO}/${clang}-client:${tag}"
+  # TODO(sanjaypujare): skip test if image not found (by using gcloud_gcr_list_image_tags)
+  set -x
+  python -m "tests.security_test" \
+    --flagfile="${TEST_DRIVER_FLAGFILE}" \
+    --kube_context="${KUBE_CONTEXT}" \
+    --server_image="${server_image_name}" \
+    --client_image="${client_image_name}" \
+    --xml_output_file="${TEST_XML_OUTPUT_DIR}/${tag}/${clang}-${slang}/sponge_log.xml" \
+    --force_cleanup \
+    --nocheck_local_certs
+  set +x
+}
+
+#######################################
+# Main function: provision software necessary to execute tests, and run them
+# Globals:
+#   KOKORO_ARTIFACTS_DIR
+#   GITHUB_REPOSITORY_NAME
+#   SRC_DIR: Populated with absolute path to the source repo
+#   TEST_DRIVER_REPO_DIR: Populated with the path to the repo containing
+#                         the test driver
+#   TEST_DRIVER_FULL_DIR: Populated with the path to the test driver source code
+#   TEST_DRIVER_FLAGFILE: Populated with relative path to test driver flagfile
+#   TEST_XML_OUTPUT_DIR: Populated with the path to test xUnit XML report
+#   GIT_ORIGIN_URL: Populated with the origin URL of git repo used for the build
+#   GIT_COMMIT: Populated with the SHA-1 of git commit being built
+#   GIT_COMMIT_SHORT: Populated with the short SHA-1 of git commit being built
+#   KUBE_CONTEXT: Populated with name of kubectl context with GKE cluster access
+# Arguments:
+#   None
+# Outputs:
+#   Writes the output of test execution to stdout, stderr
+#######################################
+main() {
+  local script_dir
+  script_dir="$(dirname "$0")"
+  # shellcheck source=tools/internal_ci/linux/grpc_xds_k8s_install_test_driver.sh
+  source "${script_dir}/grpc_xds_k8s_install_test_driver.sh"
+  set -x
+  if [[ -n "${KOKORO_ARTIFACTS_DIR}" ]]; then
+    kokoro_setup_test_driver "${GITHUB_REPOSITORY_NAME}"
+    cd "${TEST_DRIVER_FULL_DIR}"
+  else
+    local_setup_test_driver "${script_dir}"
+    cd "${SRC_DIR}/${TEST_DRIVER_PATH}"
+  fi
+
+  local failed_tests=0
+  # Run tests
+  for TAG in ${VERSION_TAG}
+  do
+    for CLANG in ${CLIENT_LANG}
+    do
+    for SLANG in ${SERVER_LANG}
+    do
+      if [ "${CLANG}" != "${SLANG}" ]; then
+        run_test "${TAG}" "${SLANG}" "${CLANG}" || (( failed_tests++ ))
+      fi
+    done
+    echo "Failed test suites: ${failed_tests}"
+    done
+  done
+  if (( failed_tests > 0 )); then
+    exit 1
+  fi
+}
+
+main "$@"
index 18c860c..b18f306 100755 (executable)
@@ -13,6 +13,7 @@
 # See the License for the specific language governing permissions and
 # limitations under the License.
 
+trap 'date' DEBUG
 set -ex -o igncr || set -ex
 
 mkdir -p /var/local/git
index 43d71ce..c6d8975 100755 (executable)
@@ -13,6 +13,7 @@
 # See the License for the specific language governing permissions and
 # limitations under the License.
 
+trap 'date' DEBUG
 set -ex -o igncr || set -ex
 
 mkdir -p /var/local/git
index 42bfb1e..ed070d2 100644 (file)
@@ -16,7 +16,7 @@
 
 # Location of the continuous shell script in repository.
 build_file: "grpc/tools/internal_ci/linux/grpc_xds_url_map.sh"
-timeout_mins: 120
+timeout_mins: 90
 action {
   define_artifacts {
     regex: "artifacts/**/*sponge_log.xml"
index ea173c4..f823f6c 100755 (executable)
@@ -91,6 +91,7 @@ run_test() {
     --flagfile="${TEST_DRIVER_FLAGFILE}" \
     --kube_context="${KUBE_CONTEXT}" \
     --client_image="${CLIENT_IMAGE_NAME}:${GIT_COMMIT}" \
+    --testing_version=$(echo "$KOKORO_JOB_NAME" | sed -E 's|^grpc/core/([^/]+)/.*|\1|') \
     --xml_output_file="${TEST_XML_OUTPUT_DIR}/${test_name}/sponge_log.xml" \
     --flagfile="config/url-map.cfg"
   set +x
index 0fb04aa..86a442d 100644 (file)
@@ -16,7 +16,7 @@
 
 # Location of the continuous shell script in repository.
 build_file: "grpc/tools/internal_ci/linux/grpc_xds_url_map_python.sh"
-timeout_mins: 120
+timeout_mins: 90
 action {
   define_artifacts {
     regex: "artifacts/**/*sponge_log.xml"
index 234ddd5..bb302c8 100755 (executable)
@@ -101,6 +101,7 @@ run_test() {
     --flagfile="${TEST_DRIVER_FLAGFILE}" \
     --kube_context="${KUBE_CONTEXT}" \
     --client_image="${CLIENT_IMAGE_NAME}:${GIT_COMMIT}" \
+    --testing_version=$(echo "$KOKORO_JOB_NAME" | sed -E 's|^grpc/core/([^/]+)/.*|\1|') \
     --xml_output_file="${TEST_XML_OUTPUT_DIR}/${test_name}/sponge_log.xml" \
     --flagfile="config/url-map.cfg"
   set +x
diff --git a/tools/internal_ci/macos/grpc_distribtests_php.cfg b/tools/internal_ci/macos/grpc_distribtests_php.cfg
new file mode 100644 (file)
index 0000000..e06b917
--- /dev/null
@@ -0,0 +1,27 @@
+# Copyright 2021 The gRPC Authors
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+# Config file for the internal CI (in protobuf text format)
+
+# Location of the continuous shell script in repository.
+build_file: "grpc/tools/internal_ci/macos/grpc_distribtests_php.sh"
+gfile_resources: "/bigstore/grpc-testing-secrets/gcp_credentials/GrpcTesting-d0eeee2db331.json"
+timeout_mins: 240
+action {
+  define_artifacts {
+    regex: "**/*sponge_log.*"
+    regex: "github/grpc/reports/**"
+    regex: "github/grpc/artifacts/**"
+  }
+}
diff --git a/tools/internal_ci/macos/grpc_distribtests_php.sh b/tools/internal_ci/macos/grpc_distribtests_php.sh
new file mode 100644 (file)
index 0000000..a6c3328
--- /dev/null
@@ -0,0 +1,47 @@
+#!/bin/bash
+# Copyright 2021 The gRPC Authors
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+set -ex
+
+# change to grpc repo root
+cd $(dirname $0)/../../..
+
+export PREPARE_BUILD_INSTALL_DEPS_PHP=true
+source tools/internal_ci/helper_scripts/prepare_build_macos_rc
+
+# Build all PHP macos artifacts
+tools/run_tests/task_runner.py -f artifact macos php -j 4 -x build_artifacts/sponge_log.xml || FAILED="true"
+
+# PHP's "build_package" step is basically just a passthough, so the build artifacts can be used
+# directly by the "distribtests" step (and we skip the "build_package" phase entirely on mac).
+
+# the next step expects to find the artifacts from the previous step in the "input_artifacts" folder.
+# in addition to that, preserve the contents of "artifacts" directory since we want kokoro
+# to upload its contents as job output artifacts
+rm -rf input_artifacts
+mkdir -p input_artifacts
+cp -r artifacts/php_pecl_package_macos_*/* input_artifacts/ || true
+
+# Run all PHP linux distribtests
+# We run the distribtests even if some of the artifacts have failed to build, since that gives
+# a better signal about which distribtest are affected by the currently broken artifact builds.
+tools/run_tests/task_runner.py -f distribtest macos php -j 4 -x distribtests/sponge_log.xml || FAILED="true"
+
+tools/internal_ci/helper_scripts/delete_nonartifacts.sh || true
+
+if [ "$FAILED" != "" ]
+then
+  exit 1
+fi
index aa86c06..a755f9b 100644 (file)
@@ -16,7 +16,7 @@
 
 # Location of the continuous shell script in repository.
 build_file: "grpc/tools/internal_ci/windows/grpc_run_tests_matrix.bat"
-timeout_mins: 240
+timeout_mins: 300
 action {
   define_artifacts {
     regex: "**/*sponge_log.*"
index 6a8ed32..5e58bdb 100644 (file)
@@ -114,6 +114,7 @@ LANG_RELEASE_MATRIX = {
             ('v1.36.3', ReleaseInfo()),
             ('v1.37.0', ReleaseInfo()),
             ('v1.38.0', ReleaseInfo()),
+            ('v1.39.0', ReleaseInfo()),
         ]),
     'go':
         OrderedDict([
@@ -189,7 +190,8 @@ LANG_RELEASE_MATRIX = {
             ('v1.37.0', ReleaseInfo(runtimes=['go1.11'])),
             # NOTE: starting from release v1.38.0, use runtimes=['go1.16']
             ('v1.38.1', ReleaseInfo(runtimes=['go1.16'])),
-            ('v1.39.0', ReleaseInfo(runtimes=['go1.16'])),
+            ('v1.39.1', ReleaseInfo(runtimes=['go1.16'])),
+            ('v1.40.0', ReleaseInfo(runtimes=['go1.16'])),
         ]),
     'java':
         OrderedDict([
@@ -263,6 +265,7 @@ LANG_RELEASE_MATRIX = {
             ('v1.37.1', ReleaseInfo()),
             ('v1.38.1', ReleaseInfo()),
             ('v1.39.0', ReleaseInfo()),
+            ('v1.40.1', ReleaseInfo()),
         ]),
     'python':
         OrderedDict([
@@ -327,6 +330,7 @@ LANG_RELEASE_MATRIX = {
             ('v1.36.3', ReleaseInfo(runtimes=['python'])),
             ('v1.37.0', ReleaseInfo(runtimes=['python'])),
             ('v1.38.0', ReleaseInfo(runtimes=['python'])),
+            ('v1.39.0', ReleaseInfo(runtimes=['python'])),
         ]),
     'node':
         OrderedDict([
@@ -394,6 +398,7 @@ LANG_RELEASE_MATRIX = {
             ('v1.36.3', ReleaseInfo()),
             ('v1.37.0', ReleaseInfo()),
             ('v1.38.0', ReleaseInfo()),
+            ('v1.39.0', ReleaseInfo()),
         ]),
     'php':
         OrderedDict([
@@ -434,6 +439,7 @@ LANG_RELEASE_MATRIX = {
             ('v1.36.3', ReleaseInfo()),
             ('v1.37.0', ReleaseInfo()),
             ('v1.38.0', ReleaseInfo()),
+            ('v1.39.0', ReleaseInfo()),
         ]),
     'csharp':
         OrderedDict([
@@ -478,5 +484,7 @@ LANG_RELEASE_MATRIX = {
             ('v1.35.0', ReleaseInfo()),
             ('v1.36.3', ReleaseInfo()),
             ('v1.37.0', ReleaseInfo()),
+            ('v1.38.1', ReleaseInfo()),
+            ('v1.39.1', ReleaseInfo()),
         ]),
 }
index b413ab4..bda9d9b 100755 (executable)
@@ -1,4 +1,4 @@
-#!/usr/bin/env python2.7
+#!/usr/bin/env python3
 # Copyright 2017 gRPC authors.
 #
 # Licensed under the Apache License, Version 2.0 (the "License");
@@ -339,7 +339,7 @@ def checkout_grpc_stack(lang, release):
                    do_newline=True)
 
     # Write git log to commit_log so it can be packaged with the docker image.
-    with open(os.path.join(stack_base, 'commit_log'), 'w') as f:
+    with open(os.path.join(stack_base, 'commit_log'), 'wb') as f:
         f.write(commit_log)
     return stack_base
 
index 0fa32cf..55c7ddb 100644 (file)
@@ -107,6 +107,11 @@ class PythonArtifact:
         self.py_version = py_version
         if 'manylinux' in platform:
             self.labels.append('linux')
+        if 'linux_extra' in platform:
+            # linux_extra wheels used to be built by a separate kokoro job.
+            # Their build is now much faster, so they can be included
+            # in the regular artifact build.
+            self.labels.append('linux')
 
     def pre_build_jobspecs(self):
         return []
@@ -201,7 +206,7 @@ class RubyArtifact:
         return create_jobspec(
             self.name, ['tools/run_tests/artifacts/build_artifact_ruby.sh'],
             use_workspace=True,
-            timeout_seconds=60 * 60)
+            timeout_seconds=90 * 60)
 
 
 class CSharpExtArtifact:
@@ -247,7 +252,7 @@ class CSharpExtArtifact:
                 if self.arch == 'aarch64':
                     # for aarch64, use a dockcross manylinux image that will
                     # give us both ready to use crosscompiler and sufficient backward compatibility
-                    dockerfile_dir = 'tools/dockerfile/grpc_artifact_python_manylinux_2_24_aarch64'
+                    dockerfile_dir = 'tools/dockerfile/grpc_artifact_python_manylinux2014_aarch64'
                 return create_docker_jobspec(
                     self.name, dockerfile_dir,
                     'tools/run_tests/artifacts/build_artifact_csharp.sh')
@@ -275,10 +280,15 @@ class PHPArtifact:
         return []
 
     def build_jobspec(self):
-        return create_docker_jobspec(
-            self.name,
-            'tools/dockerfile/test/php73_zts_stretch_{}'.format(self.arch),
-            'tools/run_tests/artifacts/build_artifact_php.sh')
+        if self.platform == 'linux':
+            return create_docker_jobspec(
+                self.name,
+                'tools/dockerfile/test/php73_zts_stretch_{}'.format(self.arch),
+                'tools/run_tests/artifacts/build_artifact_php.sh')
+        else:
+            return create_jobspec(
+                self.name, ['tools/run_tests/artifacts/build_artifact_php.sh'],
+                use_workspace=True)
 
 
 class ProtocArtifact:
@@ -348,50 +358,51 @@ def targets():
         CSharpExtArtifact('linux', 'android', arch_abi='armeabi-v7a'),
         CSharpExtArtifact('linux', 'android', arch_abi='x86'),
         CSharpExtArtifact('macos', 'ios'),
-        PythonArtifact('manylinux2014', 'x64', 'cp35-cp35m'),
         PythonArtifact('manylinux2014', 'x64', 'cp36-cp36m'),
         PythonArtifact('manylinux2014', 'x64', 'cp37-cp37m'),
         PythonArtifact('manylinux2014', 'x64', 'cp38-cp38'),
         PythonArtifact('manylinux2014', 'x64', 'cp39-cp39'),
-        PythonArtifact('manylinux2014', 'x86', 'cp35-cp35m'),
+        PythonArtifact('manylinux2014', 'x64', 'cp310-cp310'),
         PythonArtifact('manylinux2014', 'x86', 'cp36-cp36m'),
         PythonArtifact('manylinux2014', 'x86', 'cp37-cp37m'),
         PythonArtifact('manylinux2014', 'x86', 'cp38-cp38'),
         PythonArtifact('manylinux2014', 'x86', 'cp39-cp39'),
-        PythonArtifact('manylinux2010', 'x64', 'cp35-cp35m'),
+        PythonArtifact('manylinux2014', 'x86', 'cp310-cp310'),
         PythonArtifact('manylinux2010', 'x64', 'cp36-cp36m'),
         PythonArtifact('manylinux2010', 'x64', 'cp37-cp37m'),
         PythonArtifact('manylinux2010', 'x64', 'cp38-cp38'),
         PythonArtifact('manylinux2010', 'x64', 'cp39-cp39'),
-        PythonArtifact('manylinux2010', 'x86', 'cp35-cp35m'),
         PythonArtifact('manylinux2010', 'x86', 'cp36-cp36m'),
         PythonArtifact('manylinux2010', 'x86', 'cp37-cp37m'),
         PythonArtifact('manylinux2010', 'x86', 'cp38-cp38'),
         PythonArtifact('manylinux2010', 'x86', 'cp39-cp39'),
-        PythonArtifact('manylinux_2_24', 'aarch64', 'cp36-cp36m'),
-        PythonArtifact('manylinux_2_24', 'aarch64', 'cp37-cp37m'),
-        PythonArtifact('manylinux_2_24', 'aarch64', 'cp38-cp38'),
-        PythonArtifact('manylinux_2_24', 'aarch64', 'cp39-cp39'),
+        PythonArtifact('manylinux2014', 'aarch64', 'cp36-cp36m'),
+        PythonArtifact('manylinux2014', 'aarch64', 'cp37-cp37m'),
+        PythonArtifact('manylinux2014', 'aarch64', 'cp38-cp38'),
+        PythonArtifact('manylinux2014', 'aarch64', 'cp39-cp39'),
+        PythonArtifact('manylinux2014', 'aarch64', 'cp310-cp310'),
         PythonArtifact('linux_extra', 'armv7', 'cp36-cp36m'),
         PythonArtifact('linux_extra', 'armv7', 'cp37-cp37m'),
         PythonArtifact('linux_extra', 'armv7', 'cp38-cp38'),
         PythonArtifact('linux_extra', 'armv7', 'cp39-cp39'),
-        PythonArtifact('macos', 'x64', 'python3.5'),
+        PythonArtifact('linux_extra', 'armv7', 'cp310-cp310'),
         PythonArtifact('macos', 'x64', 'python3.6'),
         PythonArtifact('macos', 'x64', 'python3.7'),
         PythonArtifact('macos', 'x64', 'python3.8'),
         PythonArtifact('macos', 'x64', 'python3.9'),
-        PythonArtifact('windows', 'x86', 'Python35_32bit'),
+        PythonArtifact('macos', 'x64', 'python3.10'),
         PythonArtifact('windows', 'x86', 'Python36_32bit'),
         PythonArtifact('windows', 'x86', 'Python37_32bit'),
         PythonArtifact('windows', 'x86', 'Python38_32bit'),
         PythonArtifact('windows', 'x86', 'Python39_32bit'),
-        PythonArtifact('windows', 'x64', 'Python35'),
+        PythonArtifact('windows', 'x86', 'Python310_32bit'),
         PythonArtifact('windows', 'x64', 'Python36'),
         PythonArtifact('windows', 'x64', 'Python37'),
         PythonArtifact('windows', 'x64', 'Python38'),
         PythonArtifact('windows', 'x64', 'Python39'),
+        PythonArtifact('windows', 'x64', 'Python310'),
         RubyArtifact('linux', 'x64'),
         RubyArtifact('macos', 'x64'),
-        PHPArtifact('linux', 'x64')
+        PHPArtifact('linux', 'x64'),
+        PHPArtifact('macos', 'x64')
     ]
index 629718e..dd242d1 100755 (executable)
@@ -21,12 +21,5 @@ mkdir -p "${ARTIFACTS_OUT}"
 
 # Build the PHP extension archive (this just zips all the files up)
 pear package
-# Note: the extension compiled by this step is not being used in any
-# way, i.e. they are not the pacakge being distributed.
-# This is done here to get an early signal for compiling the PHP
-# extension in some form.
-find . -name "grpc-*.tgz" | cut -b3- | xargs pecl install
-# Verified that the grpc extension is built properly.
-php -d extension=grpc.so --re grpc | head -1
 
 cp -r grpc-*.tgz "${ARTIFACTS_OUT}"/
index 64f68cf..8f18eb3 100755 (executable)
@@ -19,9 +19,11 @@ cd "$(dirname "$0")/../../.."
 
 export GRPC_PYTHON_BUILD_WITH_CYTHON=1
 export PYTHON=${PYTHON:-python}
-export PIP=${PIP:-pip}
 export AUDITWHEEL=${AUDITWHEEL:-auditwheel}
 
+# Needed for building binary distribution wheels -- bdist_wheel
+"${PYTHON}" -m pip install --upgrade wheel
+
 if [ "$GRPC_SKIP_PIP_CYTHON_UPGRADE" == "" ]
 then
   # Install Cython to avoid source wheel build failure.
@@ -31,7 +33,7 @@ then
   # Any installation step is a potential source of breakages,
   # so we are trying to perform as few download-and-install operations
   # as possible.
-  "${PIP}" install --upgrade cython
+  "${PYTHON}" -m pip install --upgrade cython
 fi
 
 # Allow build_ext to build C/C++ files in parallel
@@ -124,35 +126,56 @@ ${SETARCH_CMD} "${PYTHON}" tools/distrib/python/grpcio_tools/setup.py sdist
 # shellcheck disable=SC2086
 ${SETARCH_CMD} "${PYTHON}" tools/distrib/python/grpcio_tools/setup.py bdist_wheel $WHEEL_PLAT_NAME_FLAG
 
+# run twine check before auditwheel, because auditwheel puts the repaired wheels into
+# the artifacts output dir.
+if [ "$GRPC_SKIP_TWINE_CHECK" == "" ]
+then
+  # Ensure the generated artifacts are valid.
+  # TODO(jtattermusch): avoid the need for always re-installing virtualenv and twine
+  "${PYTHON}" -m pip install virtualenv
+  "${PYTHON}" -m virtualenv venv || { "${PYTHON}" -m pip install virtualenv==16.7.9 && "${PYTHON}" -m virtualenv venv; }
+  venv/bin/python -m pip install "twine<=2.0"
+  venv/bin/python -m twine check dist/* tools/distrib/python/grpcio_tools/dist/*
+  rm -rf venv/
+fi
+
 if [ "$GRPC_RUN_AUDITWHEEL_REPAIR" != "" ]
 then
   for wheel in dist/*.whl; do
     "${AUDITWHEEL}" show "$wheel" | tee /dev/stderr |  grep -E -w "$AUDITWHEEL_PLAT"
-    "${AUDITWHEEL}" repair "$wheel" -w "$ARTIFACT_DIR"
+    "${AUDITWHEEL}" repair "$wheel" --strip --wheel-dir "$ARTIFACT_DIR"
     rm "$wheel"
   done
   for wheel in tools/distrib/python/grpcio_tools/dist/*.whl; do
     "${AUDITWHEEL}" show "$wheel" | tee /dev/stderr |  grep -E -w "$AUDITWHEEL_PLAT"
-    "${AUDITWHEEL}" repair "$wheel" -w "$ARTIFACT_DIR"
+    "${AUDITWHEEL}" repair "$wheel" --strip --wheel-dir "$ARTIFACT_DIR"
     rm "$wheel"
   done
+else
+  cp -r dist/*.whl "$ARTIFACT_DIR"
+  cp -r tools/distrib/python/grpcio_tools/dist/*.whl "$ARTIFACT_DIR"
 fi
 
+# grpcio and grpcio-tools wheels have already been copied to artifact_dir
+# by "auditwheel repair", now copy the .tar.gz source archives as well.
+cp -r dist/*.tar.gz "$ARTIFACT_DIR"
+cp -r tools/distrib/python/grpcio_tools/dist/*.tar.gz "$ARTIFACT_DIR"
+
 # We need to use the built grpcio-tools/grpcio to compile the health proto
 # Wheels are not supported by setup_requires/dependency_links, so we
 # manually install the dependency.  Note we should only do this if we
 # are in a docker image or in a virtualenv.
 if [ "$GRPC_BUILD_GRPCIO_TOOLS_DEPENDENTS" != "" ]
 then
-  "${PIP}" install -rrequirements.txt
+  "${PYTHON}" -m pip install -rrequirements.txt
 
   if [ "$("$PYTHON" -c "import sys; print(sys.version_info[0])")" == "2" ]
   then
-    "${PIP}" install futures>=2.2.0 enum34>=1.0.4
+    "${PYTHON}" -m pip install futures>=2.2.0 enum34>=1.0.4
   fi
 
-  "${PIP}" install grpcio --no-index --find-links "file://$ARTIFACT_DIR/"
-  "${PIP}" install grpcio-tools --no-index --find-links "file://$ARTIFACT_DIR/"
+  "${PYTHON}" -m pip install grpcio --no-index --find-links "file://$ARTIFACT_DIR/"
+  "${PYTHON}" -m pip install grpcio-tools --no-index --find-links "file://$ARTIFACT_DIR/"
 
   # Note(lidiz) setuptools's "sdist" command creates a source tarball, which
   # demands an extra step of building the wheel. The building step is merely ran
@@ -191,23 +214,10 @@ then
 
   # Build grpcio_admin source distribution and it needs the cutting-edge version
   # of Channelz and CSDS to be installed.
-  "${PIP}" install --upgrade xds-protos==0.0.8
-  "${PIP}" install grpcio-channelz --no-index --find-links "file://$ARTIFACT_DIR/"
-  "${PIP}" install grpcio-csds --no-index --find-links "file://$ARTIFACT_DIR/"
+  "${PYTHON}" -m pip install --upgrade xds-protos==0.0.8
+  "${PYTHON}" -m pip install grpcio-channelz --no-index --find-links "file://$ARTIFACT_DIR/"
+  "${PYTHON}" -m pip install grpcio-csds --no-index --find-links "file://$ARTIFACT_DIR/"
   ${SETARCH_CMD} "${PYTHON}" src/python/grpcio_admin/setup.py \
       sdist bdist_wheel
   cp -r src/python/grpcio_admin/dist/* "$ARTIFACT_DIR"
 fi
-
-if [ "$GRPC_SKIP_TWINE_CHECK" == "" ]
-then
-  # Ensure the generated artifacts are valid.
-  "${PYTHON}" -m pip install virtualenv
-  "${PYTHON}" -m virtualenv venv || { "${PYTHON}" -m pip install virtualenv==16.7.9 && "${PYTHON}" -m virtualenv venv; }
-  venv/bin/python -m pip install "twine<=2.0"
-  venv/bin/python -m twine check dist/* tools/distrib/python/grpcio_tools/dist/*
-  rm -rf venv/
-fi
-
-cp -r dist/* "$ARTIFACT_DIR"
-cp -r tools/distrib/python/grpcio_tools/dist/* "$ARTIFACT_DIR"
index e263e09..46c3d5b 100755 (executable)
@@ -20,4 +20,4 @@ cd "$(dirname "$0")/../../.."
 # All the PHP packages have been built in the artifact phase already
 # and we only collect them here to deliver them to the distribtest phase.
 mkdir -p artifacts/
-cp -r "${EXTERNAL_GIT_ROOT}"/input_artifacts/php_*/* artifacts/ || true
+cp -r "${EXTERNAL_GIT_ROOT}"/input_artifacts/php_pecl_package_linux_*/* artifacts/ || true
index 623eae7..29801a5 100755 (executable)
@@ -23,26 +23,6 @@ mkdir -p artifacts/
 # and we only collect them here to deliver them to the distribtest phase.
 cp -r "${EXTERNAL_GIT_ROOT}"/input_artifacts/python_*/* artifacts/ || true
 
-export PYTHON=${PYTHON:-python}
-
-strip_binary_wheel() {
-    WHEEL_PATH="$1"
-    TEMP_WHEEL_DIR=$(mktemp -d)
-    ${PYTHON} -m wheel unpack "$WHEEL_PATH" -d "$TEMP_WHEEL_DIR"
-    find "$TEMP_WHEEL_DIR" -name "_protoc_compiler*.so" -exec strip --strip-debug {} ";"
-    find "$TEMP_WHEEL_DIR" -name "cygrpc*.so" -exec strip --strip-debug {} ";"
-
-    WHEEL_FILE=$(basename "$WHEEL_PATH")
-    DISTRIBUTION_NAME=$(basename "$WHEEL_PATH" | cut -d '-' -f 1)
-    VERSION=$(basename "$WHEEL_PATH" | cut -d '-' -f 2)
-    ${PYTHON} -m wheel pack "$TEMP_WHEEL_DIR/$DISTRIBUTION_NAME-$VERSION" -d "$TEMP_WHEEL_DIR"
-    mv "$TEMP_WHEEL_DIR/$WHEEL_FILE" "$WHEEL_PATH"
-}
-
-for wheel in artifacts/*.whl; do
-    strip_binary_wheel "$wheel"
-done
-
 # TODO: all the artifact builder configurations generate a grpcio-VERSION.tar.gz
 # source distribution package, and only one of them will end up
 # in the artifacts/ directory. They should be all equivalent though.
index 14faab4..6a6a514 100755 (executable)
@@ -21,16 +21,18 @@ base=$(pwd)
 
 mkdir -p artifacts/
 
-# All the ruby packages have been built in the artifact phase already
+# All the "grpc" gems have been built in the artifact phase already
 # and we only collect them here to deliver them to the distribtest phase.
+# NOTE: Besides the platform-specific native gems, all the artifact build
+# jobs will generate a grpc-X.Y.Z.gem source package, and only one of them
+# will end up in the artifacts/ directory. They should be all equivalent
+# though.
 cp -r "${EXTERNAL_GIT_ROOT}"/input_artifacts/ruby_native_gem_*/* artifacts/ || true
 
+# Next, build the "grpc-tools" gem by collecting the protoc and grpc_ruby_plugin binaries
+# that have been built by the the artifact build phase previously.
 well_known_protos=( any api compiler/plugin descriptor duration empty field_mask source_context struct timestamp type wrappers )
 
-# TODO: all the artifact builder configurations generate a grpc-VERSION.gem
-# source distribution package, and only one of them will end up
-# in the artifacts/ directory. They should be all equivalent though.
-
 for arch in {x86,x64}; do
   case $arch in
     x64)
index 2379833..ad46605 100644 (file)
@@ -238,7 +238,7 @@ class PHP7DistribTest(object):
         self.platform = platform
         self.arch = arch
         self.docker_suffix = docker_suffix
-        self.labels = ['distribtest', 'php7', platform, arch]
+        self.labels = ['distribtest', 'php', 'php7', platform, arch]
         if docker_suffix:
             self.labels.append(docker_suffix)
 
@@ -344,13 +344,12 @@ def targets():
         CSharpDistribTest('windows', 'x86'),
         CSharpDistribTest('windows', 'x64'),
         # Python
-        PythonDistribTest('linux', 'x64', 'stretch'),
-        PythonDistribTest('linux', 'x86', 'stretch'),
+        PythonDistribTest('linux', 'x64', 'buster'),
+        PythonDistribTest('linux', 'x86', 'buster'),
         PythonDistribTest('linux', 'x64', 'centos7'),
         PythonDistribTest('linux', 'x64', 'fedora34'),
         PythonDistribTest('linux', 'x64', 'opensuse'),
         PythonDistribTest('linux', 'x64', 'arch'),
-        PythonDistribTest('linux', 'x64', 'ubuntu1604'),
         PythonDistribTest('linux', 'x64', 'ubuntu1804'),
         PythonDistribTest('linux', 'aarch64', 'python38_buster'),
         PythonDistribTest('linux', 'x64', 'alpine3.7', source=True),
@@ -359,7 +358,6 @@ def targets():
         PythonDistribTest('linux', 'x64', 'centos7', source=True),
         PythonDistribTest('linux', 'x64', 'fedora23', source=True),
         PythonDistribTest('linux', 'x64', 'arch', source=True),
-        PythonDistribTest('linux', 'x64', 'ubuntu1604', source=True),
         PythonDistribTest('linux', 'x64', 'ubuntu1804', source=True),
         # Ruby
         RubyDistribTest('linux', 'x64', 'jessie', ruby_version='ruby_2_4'),
index dcb778e..acf0571 100644 (file)
     "flaky": false,
     "gtest": false,
     "language": "c",
-    "name": "hpack_parser_test",
+    "name": "hpack_parser_table_test",
     "platforms": [
       "linux",
       "mac",
     "flaky": false,
     "gtest": false,
     "language": "c",
-    "name": "hpack_table_test",
+    "name": "hpack_parser_test",
     "platforms": [
       "linux",
       "mac",
     "flaky": false,
     "gtest": false,
     "language": "c",
-    "name": "tls_test",
+    "name": "transport_security_common_api_test",
     "platforms": [
       "linux",
       "mac",
       "posix",
       "windows"
     ],
-    "uses_polling": false
+    "uses_polling": true
   },
   {
     "args": [],
     "flaky": false,
     "gtest": false,
     "language": "c",
-    "name": "transport_security_common_api_test",
+    "name": "transport_security_test",
     "platforms": [
       "linux",
       "mac",
     "ci_platforms": [
       "linux",
       "mac",
-      "posix",
-      "windows"
+      "posix"
     ],
     "cpu_cost": 1.0,
     "exclude_configs": [],
     "flaky": false,
     "gtest": false,
     "language": "c",
-    "name": "transport_security_test",
+    "name": "udp_server_test",
     "platforms": [
       "linux",
       "mac",
-      "posix",
-      "windows"
+      "posix"
     ],
     "uses_polling": true
   },
     "ci_platforms": [
       "linux",
       "mac",
-      "posix"
+      "posix",
+      "windows"
     ],
     "cpu_cost": 1.0,
     "exclude_configs": [],
     "flaky": false,
     "gtest": false,
     "language": "c",
-    "name": "udp_server_test",
+    "name": "useful_test",
     "platforms": [
       "linux",
       "mac",
-      "posix"
+      "posix",
+      "windows"
     ],
-    "uses_polling": true
+    "uses_polling": false
   },
   {
     "args": [],
     "flaky": false,
     "gtest": false,
     "language": "c",
-    "name": "useful_test",
+    "name": "varint_test",
     "platforms": [
       "linux",
       "mac",
     "exclude_configs": [],
     "exclude_iomgrs": [],
     "flaky": false,
-    "gtest": false,
-    "language": "c",
-    "name": "varint_test",
+    "gtest": true,
+    "language": "c++",
+    "name": "activity_test",
     "platforms": [
       "linux",
       "mac",
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "binder_smoke_test",
+    "name": "binder_server_test",
+    "platforms": [
+      "linux",
+      "mac",
+      "posix",
+      "windows"
+    ],
+    "uses_polling": true
+  },
+  {
+    "args": [],
+    "benchmark": false,
+    "ci_platforms": [
+      "linux",
+      "mac",
+      "posix",
+      "windows"
+    ],
+    "cpu_cost": 1.0,
+    "exclude_configs": [],
+    "exclude_iomgrs": [],
+    "flaky": false,
+    "gtest": true,
+    "language": "c++",
+    "name": "binder_transport_test",
     "platforms": [
       "linux",
       "mac",
     "flaky": false,
     "gtest": true,
     "language": "c++",
+    "name": "capture_test",
+    "platforms": [
+      "linux",
+      "mac",
+      "posix",
+      "windows"
+    ],
+    "uses_polling": false
+  },
+  {
+    "args": [],
+    "benchmark": false,
+    "ci_platforms": [
+      "linux",
+      "mac",
+      "posix",
+      "windows"
+    ],
+    "cpu_cost": 1.0,
+    "exclude_configs": [],
+    "exclude_iomgrs": [],
+    "flaky": false,
+    "gtest": true,
+    "language": "c++",
     "name": "cel_authorization_engine_test",
     "platforms": [
       "linux",
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "delegating_channel_test",
+    "name": "context_test",
     "platforms": [
       "linux",
       "mac",
       "posix",
       "windows"
     ],
-    "uses_polling": true
+    "uses_polling": false
   },
   {
     "args": [],
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "destroy_grpclb_channel_with_active_connect_stress_test",
+    "name": "core_configuration_test",
     "platforms": [
       "linux",
       "mac",
       "posix",
       "windows"
     ],
-    "uses_polling": true
+    "uses_polling": false
   },
   {
     "args": [],
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "dual_ref_counted_test",
+    "name": "delegating_channel_test",
     "platforms": [
       "linux",
       "mac",
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "duplicate_header_bad_client_test",
+    "name": "destroy_grpclb_channel_with_active_connect_stress_test",
     "platforms": [
       "linux",
       "mac",
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "endpoint_config_test",
+    "name": "dual_ref_counted_test",
     "platforms": [
       "linux",
       "mac",
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "error_details_test",
+    "name": "duplicate_header_bad_client_test",
     "platforms": [
       "linux",
       "mac",
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "error_utils_test",
+    "name": "end2end_binder_transport_test",
     "platforms": [
       "linux",
       "mac",
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "evaluate_args_test",
+    "name": "endpoint_config_test",
     "platforms": [
       "linux",
       "mac",
     "ci_platforms": [
       "linux",
       "mac",
-      "posix"
-    ],
-    "cpu_cost": 1.0,
-    "exclude_configs": [],
-    "exclude_iomgrs": [],
-    "flaky": false,
-    "gtest": true,
-    "language": "c++",
-    "name": "examine_stack_test",
-    "platforms": [
-      "linux",
-      "mac",
-      "posix"
-    ],
-    "uses_polling": false
-  },
-  {
-    "args": [],
-    "benchmark": false,
-    "ci_platforms": [
-      "linux",
-      "mac",
       "posix",
       "windows"
     ],
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "exception_test",
+    "name": "error_details_test",
     "platforms": [
       "linux",
       "mac",
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "file_watcher_certificate_provider_factory_test",
+    "name": "error_utils_test",
     "platforms": [
       "linux",
       "mac",
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "filter_end2end_test",
+    "name": "evaluate_args_test",
     "platforms": [
       "linux",
       "mac",
     "ci_platforms": [
       "linux",
       "mac",
-      "posix",
-      "windows"
+      "posix"
     ],
     "cpu_cost": 1.0,
     "exclude_configs": [],
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "generic_end2end_test",
+    "name": "examine_stack_test",
     "platforms": [
       "linux",
       "mac",
-      "posix",
-      "windows"
+      "posix"
     ],
-    "uses_polling": true
+    "uses_polling": false
   },
   {
     "args": [],
     "ci_platforms": [
       "linux",
       "mac",
-      "posix"
+      "posix",
+      "windows"
     ],
     "cpu_cost": 1.0,
     "exclude_configs": [],
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "global_config_env_test",
+    "name": "exception_test",
     "platforms": [
       "linux",
       "mac",
-      "posix"
+      "posix",
+      "windows"
     ],
-    "uses_polling": false
+    "uses_polling": true
   },
   {
     "args": [],
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "global_config_test",
+    "name": "fake_binder_test",
     "platforms": [
       "linux",
       "mac",
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "google_mesh_ca_certificate_provider_factory_test",
+    "name": "file_watcher_certificate_provider_factory_test",
     "platforms": [
       "linux",
       "mac",
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "grpc_authorization_engine_test",
+    "name": "filter_end2end_test",
     "platforms": [
       "linux",
       "mac",
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "grpc_authorization_policy_provider_test",
+    "name": "flow_control_test",
     "platforms": [
       "linux",
       "mac",
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "grpc_tls_certificate_distributor_test",
+    "name": "for_each_test",
     "platforms": [
       "linux",
       "mac",
       "posix",
       "windows"
     ],
-    "uses_polling": true
+    "uses_polling": false
   },
   {
     "args": [],
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "grpc_tls_certificate_provider_test",
+    "name": "generic_end2end_test",
     "platforms": [
       "linux",
       "mac",
     "ci_platforms": [
       "linux",
       "mac",
-      "posix",
-      "windows"
+      "posix"
     ],
     "cpu_cost": 1.0,
     "exclude_configs": [],
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "grpc_tls_credentials_options_test",
+    "name": "global_config_env_test",
     "platforms": [
       "linux",
       "mac",
-      "posix",
-      "windows"
+      "posix"
     ],
-    "uses_polling": true
+    "uses_polling": false
   },
   {
     "args": [],
     "ci_platforms": [
       "linux",
       "mac",
-      "posix"
+      "posix",
+      "windows"
     ],
     "cpu_cost": 1.0,
     "exclude_configs": [],
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "grpc_tool_test",
+    "name": "global_config_test",
     "platforms": [
       "linux",
       "mac",
-      "posix"
+      "posix",
+      "windows"
     ],
-    "uses_polling": true
+    "uses_polling": false
   },
   {
     "args": [],
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "grpclb_api_test",
+    "name": "google_mesh_ca_certificate_provider_factory_test",
     "platforms": [
       "linux",
       "mac",
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "h2_ssl_session_reuse_test",
+    "name": "grpc_authorization_engine_test",
     "platforms": [
       "linux",
       "mac",
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "head_of_line_blocking_bad_client_test",
+    "name": "grpc_authorization_policy_provider_test",
     "platforms": [
       "linux",
       "mac",
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "headers_bad_client_test",
+    "name": "grpc_tls_certificate_distributor_test",
     "platforms": [
       "linux",
       "mac",
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "health_service_end2end_test",
+    "name": "grpc_tls_certificate_provider_test",
     "platforms": [
       "linux",
       "mac",
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "hybrid_end2end_test",
+    "name": "grpc_tls_credentials_options_test",
     "platforms": [
       "linux",
       "mac",
     "ci_platforms": [
       "linux",
       "mac",
-      "posix",
-      "windows"
+      "posix"
     ],
     "cpu_cost": 1.0,
     "exclude_configs": [],
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "init_test",
+    "name": "grpc_tool_test",
     "platforms": [
       "linux",
       "mac",
-      "posix",
-      "windows"
+      "posix"
     ],
-    "uses_polling": false
+    "uses_polling": true
   },
   {
     "args": [],
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "initial_settings_frame_bad_client_test",
+    "name": "grpclb_api_test",
     "platforms": [
       "linux",
       "mac",
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "insecure_security_connector_test",
+    "name": "h2_ssl_session_reuse_test",
     "platforms": [
       "linux",
       "mac",
     "ci_platforms": [
       "linux",
       "mac",
-      "posix"
+      "posix",
+      "windows"
     ],
     "cpu_cost": 1.0,
     "exclude_configs": [],
     "exclude_iomgrs": [],
     "flaky": false,
-    "gtest": false,
+    "gtest": true,
     "language": "c++",
-    "name": "interop_test",
+    "name": "head_of_line_blocking_bad_client_test",
     "platforms": [
       "linux",
       "mac",
-      "posix"
+      "posix",
+      "windows"
     ],
     "uses_polling": true
   },
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "json_test",
+    "name": "headers_bad_client_test",
     "platforms": [
       "linux",
       "mac",
       "posix",
       "windows"
     ],
-    "uses_polling": false
+    "uses_polling": true
   },
   {
     "args": [],
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "large_metadata_bad_client_test",
+    "name": "health_service_end2end_test",
     "platforms": [
       "linux",
       "mac",
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "lb_get_cpu_stats_test",
+    "name": "hpack_encoder_index_test",
     "platforms": [
       "linux",
       "mac",
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "lb_load_data_store_test",
+    "name": "hybrid_end2end_test",
     "platforms": [
       "linux",
       "mac",
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "linux_system_roots_test",
+    "name": "if_test",
     "platforms": [
       "linux",
       "mac",
       "posix",
       "windows"
     ],
-    "uses_polling": true
+    "uses_polling": false
   },
   {
     "args": [],
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "log_test",
+    "name": "init_test",
     "platforms": [
       "linux",
       "mac",
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "match_test",
+    "name": "initial_settings_frame_bad_client_test",
     "platforms": [
       "linux",
       "mac",
       "posix",
       "windows"
     ],
-    "uses_polling": false
+    "uses_polling": true
   },
   {
     "args": [],
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "matchers_test",
+    "name": "insecure_security_connector_test",
     "platforms": [
       "linux",
       "mac",
     "ci_platforms": [
       "linux",
       "mac",
-      "posix",
-      "windows"
+      "posix"
     ],
     "cpu_cost": 1.0,
     "exclude_configs": [],
     "exclude_iomgrs": [],
     "flaky": false,
-    "gtest": true,
+    "gtest": false,
     "language": "c++",
-    "name": "message_allocator_end2end_test",
+    "name": "interop_test",
     "platforms": [
       "linux",
       "mac",
-      "posix",
-      "windows"
+      "posix"
     ],
     "uses_polling": true
   },
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "mock_stream_test",
+    "name": "join_test",
     "platforms": [
       "linux",
       "mac",
       "posix",
       "windows"
     ],
-    "uses_polling": true
+    "uses_polling": false
   },
   {
     "args": [],
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "mock_test",
+    "name": "json_test",
     "platforms": [
       "linux",
       "mac",
       "posix",
       "windows"
     ],
-    "uses_polling": true
+    "uses_polling": false
   },
   {
     "args": [],
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "nonblocking_test",
+    "name": "large_metadata_bad_client_test",
     "platforms": [
       "linux",
       "mac",
   },
   {
     "args": [],
-    "benchmark": true,
+    "benchmark": false,
     "ci_platforms": [
       "linux",
       "mac",
     "exclude_configs": [],
     "exclude_iomgrs": [],
     "flaky": false,
-    "gtest": false,
+    "gtest": true,
     "language": "c++",
-    "name": "noop-benchmark",
+    "name": "latch_test",
     "platforms": [
       "linux",
       "mac",
       "posix",
       "windows"
     ],
-    "uses_polling": true
+    "uses_polling": false
   },
   {
     "args": [],
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "orphanable_test",
+    "name": "lb_get_cpu_stats_test",
     "platforms": [
       "linux",
       "mac",
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "out_of_bounds_bad_client_test",
+    "name": "lb_load_data_store_test",
     "platforms": [
       "linux",
       "mac",
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "overload_test",
+    "name": "linux_system_roots_test",
     "platforms": [
       "linux",
       "mac",
       "posix",
       "windows"
     ],
-    "uses_polling": false
+    "uses_polling": true
   },
   {
     "args": [],
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "pid_controller_test",
+    "name": "log_test",
     "platforms": [
       "linux",
       "mac",
       "posix",
       "windows"
     ],
-    "uses_polling": true
+    "uses_polling": false
   },
   {
     "args": [],
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "port_sharing_end2end_test",
+    "name": "loop_test",
     "platforms": [
       "linux",
       "mac",
       "posix",
       "windows"
     ],
-    "uses_polling": true
+    "uses_polling": false
   },
   {
     "args": [],
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "proto_server_reflection_test",
+    "name": "match_test",
     "platforms": [
       "linux",
       "mac",
       "posix",
       "windows"
     ],
-    "uses_polling": true
+    "uses_polling": false
   },
   {
     "args": [],
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "proto_utils_test",
+    "name": "matchers_test",
     "platforms": [
       "linux",
       "mac",
       "posix",
       "windows"
     ],
-    "uses_polling": false
+    "uses_polling": true
   },
   {
     "args": [],
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "raw_end2end_test",
+    "name": "message_allocator_end2end_test",
     "platforms": [
       "linux",
       "mac",
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "rbac_translator_test",
+    "name": "miscompile_with_no_unique_address_test",
     "platforms": [
       "linux",
       "mac",
       "posix",
       "windows"
     ],
-    "uses_polling": true
+    "uses_polling": false
   },
   {
     "args": [],
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "ref_counted_ptr_test",
+    "name": "mock_stream_test",
     "platforms": [
       "linux",
       "mac",
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "ref_counted_test",
+    "name": "mock_test",
     "platforms": [
       "linux",
       "mac",
     "ci_platforms": [
       "linux",
       "mac",
-      "posix"
-    ],
-    "cpu_cost": 1.0,
-    "exclude_configs": [],
-    "exclude_iomgrs": [],
-    "flaky": false,
-    "gtest": true,
-    "language": "c++",
-    "name": "remove_stream_from_stalled_lists_test",
-    "platforms": [
-      "linux",
-      "mac",
-      "posix"
-    ],
-    "uses_polling": true
-  },
-  {
-    "args": [],
-    "benchmark": false,
-    "ci_platforms": [
-      "linux",
-      "mac",
       "posix",
       "windows"
     ],
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "retry_throttle_test",
+    "name": "nonblocking_test",
     "platforms": [
       "linux",
       "mac",
       "posix",
       "windows"
     ],
-    "uses_polling": false
+    "uses_polling": true
   },
   {
     "args": [],
-    "benchmark": false,
+    "benchmark": true,
     "ci_platforms": [
       "linux",
       "mac",
     "exclude_configs": [],
     "exclude_iomgrs": [],
     "flaky": false,
-    "gtest": true,
+    "gtest": false,
     "language": "c++",
-    "name": "secure_auth_context_test",
+    "name": "noop-benchmark",
     "platforms": [
       "linux",
       "mac",
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "server_builder_plugin_test",
+    "name": "observable_test",
     "platforms": [
       "linux",
       "mac",
       "posix",
       "windows"
     ],
-    "uses_polling": true
-  },
-  {
-    "args": [],
-    "benchmark": false,
-    "ci_platforms": [
-      "linux",
-      "mac",
-      "posix"
-    ],
-    "cpu_cost": 1.0,
-    "exclude_configs": [],
-    "exclude_iomgrs": [],
-    "flaky": false,
-    "gtest": true,
-    "language": "c++",
-    "name": "server_builder_test",
-    "platforms": [
-      "linux",
-      "mac",
-      "posix"
-    ],
-    "uses_polling": true
+    "uses_polling": false
   },
   {
     "args": [],
     "ci_platforms": [
       "linux",
       "mac",
-      "posix"
+      "posix",
+      "windows"
     ],
     "cpu_cost": 1.0,
     "exclude_configs": [],
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "server_builder_with_socket_mutator_test",
+    "name": "orphanable_test",
     "platforms": [
       "linux",
       "mac",
-      "posix"
+      "posix",
+      "windows"
     ],
     "uses_polling": true
   },
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "server_chttp2_test",
+    "name": "out_of_bounds_bad_client_test",
     "platforms": [
       "linux",
       "mac",
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "server_context_test_spouse_test",
+    "name": "overload_test",
     "platforms": [
       "linux",
       "mac",
       "posix",
       "windows"
     ],
-    "uses_polling": true
+    "uses_polling": false
   },
   {
     "args": [],
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "server_early_return_test",
+    "name": "pid_controller_test",
     "platforms": [
       "linux",
       "mac",
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "server_interceptors_end2end_test",
+    "name": "pipe_test",
     "platforms": [
       "linux",
       "mac",
       "posix",
       "windows"
     ],
-    "uses_polling": true
+    "uses_polling": false
   },
   {
     "args": [],
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "server_registered_method_bad_client_test",
+    "name": "poll_test",
     "platforms": [
       "linux",
       "mac",
       "posix",
       "windows"
     ],
-    "uses_polling": true
+    "uses_polling": false
   },
   {
     "args": [],
     "ci_platforms": [
       "linux",
       "mac",
-      "posix"
+      "posix",
+      "windows"
     ],
     "cpu_cost": 1.0,
     "exclude_configs": [],
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "server_request_call_test",
+    "name": "popularity_count_test",
     "platforms": [
       "linux",
       "mac",
-      "posix"
+      "posix",
+      "windows"
     ],
     "uses_polling": true
   },
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "service_config_end2end_test",
+    "name": "port_sharing_end2end_test",
     "platforms": [
       "linux",
       "mac",
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "service_config_test",
+    "name": "promise_factory_test",
     "platforms": [
       "linux",
       "mac",
       "posix",
       "windows"
     ],
-    "uses_polling": true
+    "uses_polling": false
   },
   {
     "args": [],
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "shutdown_test",
+    "name": "promise_map_test",
     "platforms": [
       "linux",
       "mac",
       "posix",
       "windows"
     ],
-    "uses_polling": true
+    "uses_polling": false
   },
   {
     "args": [],
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "simple_request_bad_client_test",
+    "name": "promise_test",
     "platforms": [
       "linux",
       "mac",
       "posix",
       "windows"
     ],
-    "uses_polling": true
+    "uses_polling": false
   },
   {
     "args": [],
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "sockaddr_utils_test",
+    "name": "proto_server_reflection_test",
     "platforms": [
       "linux",
       "mac",
     "ci_platforms": [
       "linux",
       "mac",
-      "posix"
+      "posix",
+      "windows"
     ],
     "cpu_cost": 1.0,
     "exclude_configs": [],
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "stack_tracer_test",
+    "name": "proto_utils_test",
     "platforms": [
       "linux",
       "mac",
-      "posix"
+      "posix",
+      "windows"
     ],
     "uses_polling": false
   },
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "stat_test",
+    "name": "race_test",
     "platforms": [
       "linux",
       "mac",
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "static_metadata_test",
+    "name": "raw_end2end_test",
     "platforms": [
       "linux",
       "mac",
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "stats_test",
+    "name": "rbac_translator_test",
     "platforms": [
       "linux",
       "mac",
       "posix",
       "windows"
     ],
-    "uses_polling": false
+    "uses_polling": true
   },
   {
     "args": [],
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "status_helper_test",
+    "name": "ref_counted_ptr_test",
     "platforms": [
       "linux",
       "mac",
       "posix",
       "windows"
     ],
-    "uses_polling": false
+    "uses_polling": true
   },
   {
     "args": [],
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "status_metadata_test",
+    "name": "ref_counted_test",
     "platforms": [
       "linux",
       "mac",
       "posix",
       "windows"
     ],
-    "uses_polling": false
+    "uses_polling": true
   },
   {
     "args": [],
     "ci_platforms": [
       "linux",
       "mac",
-      "posix",
-      "windows"
+      "posix"
     ],
     "cpu_cost": 1.0,
     "exclude_configs": [],
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "status_util_test",
+    "name": "remove_stream_from_stalled_lists_test",
     "platforms": [
       "linux",
       "mac",
-      "posix",
-      "windows"
+      "posix"
     ],
-    "uses_polling": false
+    "uses_polling": true
   },
   {
     "args": [],
     "ci_platforms": [
       "linux",
       "mac",
-      "posix"
+      "posix",
+      "windows"
     ],
     "cpu_cost": 1.0,
     "exclude_configs": [],
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "stranded_event_test",
+    "name": "retry_throttle_test",
     "platforms": [
       "linux",
       "mac",
-      "posix"
+      "posix",
+      "windows"
     ],
-    "uses_polling": true
+    "uses_polling": false
   },
   {
     "args": [],
     "ci_platforms": [
       "linux",
       "mac",
-      "posix"
+      "posix",
+      "windows"
     ],
     "cpu_cost": 1.0,
     "exclude_configs": [],
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "streaming_throughput_test",
+    "name": "sdk_authz_end2end_test",
     "platforms": [
       "linux",
       "mac",
-      "posix"
+      "posix",
+      "windows"
     ],
     "uses_polling": true
   },
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "string_ref_test",
+    "name": "secure_auth_context_test",
     "platforms": [
       "linux",
       "mac",
       "posix",
       "windows"
     ],
-    "uses_polling": false
+    "uses_polling": true
   },
   {
     "args": [],
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "table_test",
+    "name": "seq_test",
     "platforms": [
       "linux",
       "mac",
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "test_cpp_client_credentials_test",
+    "name": "server_builder_plugin_test",
     "platforms": [
       "linux",
       "mac",
     "ci_platforms": [
       "linux",
       "mac",
-      "posix",
-      "windows"
+      "posix"
     ],
     "cpu_cost": 1.0,
     "exclude_configs": [],
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "test_cpp_server_credentials_test",
+    "name": "server_builder_test",
     "platforms": [
       "linux",
       "mac",
-      "posix",
-      "windows"
+      "posix"
     ],
     "uses_polling": true
   },
     "ci_platforms": [
       "linux",
       "mac",
-      "posix",
-      "windows"
+      "posix"
     ],
     "cpu_cost": 1.0,
     "exclude_configs": [],
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "test_cpp_util_slice_test",
+    "name": "server_builder_with_socket_mutator_test",
     "platforms": [
       "linux",
       "mac",
-      "posix",
-      "windows"
+      "posix"
     ],
-    "uses_polling": false
+    "uses_polling": true
   },
   {
     "args": [],
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "test_cpp_util_time_test",
+    "name": "server_chttp2_test",
     "platforms": [
       "linux",
       "mac",
       "posix",
       "windows"
     ],
-    "uses_polling": false
+    "uses_polling": true
   },
   {
     "args": [],
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "thread_manager_test",
+    "name": "server_context_test_spouse_test",
     "platforms": [
       "linux",
       "mac",
     "ci_platforms": [
       "linux",
       "mac",
-      "posix"
+      "posix",
+      "windows"
     ],
     "cpu_cost": 1.0,
     "exclude_configs": [],
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "thread_stress_test",
+    "name": "server_early_return_test",
     "platforms": [
       "linux",
       "mac",
-      "posix"
+      "posix",
+      "windows"
     ],
     "uses_polling": true
   },
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "time_util_test",
+    "name": "server_interceptors_end2end_test",
     "platforms": [
       "linux",
       "mac",
       "posix",
       "windows"
     ],
-    "uses_polling": false
+    "uses_polling": true
   },
   {
     "args": [],
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "timer_test",
+    "name": "server_registered_method_bad_client_test",
     "platforms": [
       "linux",
       "mac",
     "ci_platforms": [
       "linux",
       "mac",
-      "posix",
-      "windows"
+      "posix"
     ],
     "cpu_cost": 1.0,
     "exclude_configs": [],
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "tls_security_connector_test",
+    "name": "server_request_call_test",
     "platforms": [
       "linux",
       "mac",
-      "posix",
-      "windows"
+      "posix"
     ],
     "uses_polling": true
   },
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "too_many_pings_test",
+    "name": "service_config_end2end_test",
     "platforms": [
       "linux",
       "mac",
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "unknown_frame_bad_client_test",
+    "name": "service_config_test",
     "platforms": [
       "linux",
       "mac",
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "uri_parser_test",
+    "name": "shutdown_test",
     "platforms": [
       "linux",
       "mac",
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "window_overflow_bad_client_test",
+    "name": "simple_request_bad_client_test",
     "platforms": [
       "linux",
       "mac",
     "ci_platforms": [
       "linux",
       "mac",
-      "posix"
+      "posix",
+      "windows"
     ],
     "cpu_cost": 1.0,
     "exclude_configs": [],
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "work_serializer_test",
+    "name": "sockaddr_utils_test",
     "platforms": [
       "linux",
       "mac",
-      "posix"
+      "posix",
+      "windows"
     ],
     "uses_polling": true
   },
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "writes_per_rpc_test",
+    "name": "stack_tracer_test",
     "platforms": [
       "linux",
       "mac",
       "posix"
     ],
-    "uses_polling": true
+    "uses_polling": false
   },
   {
     "args": [],
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "xds_bootstrap_test",
+    "name": "stat_test",
     "platforms": [
       "linux",
       "mac",
       "posix",
       "windows"
     ],
-    "uses_polling": true
+    "uses_polling": false
   },
   {
     "args": [],
     "flaky": false,
     "gtest": true,
     "language": "c++",
-    "name": "xds_certificate_provider_test",
+    "name": "static_metadata_test",
+    "platforms": [
+      "linux",
+      "mac",
+      "posix",
+      "windows"
+    ],
+    "uses_polling": true
+  },
+  {
+    "args": [],
+    "benchmark": false,
+    "ci_platforms": [
+      "linux",
+      "mac",
+      "posix",
+      "windows"
+    ],
+    "cpu_cost": 1.0,
+    "exclude_configs": [],
+    "exclude_iomgrs": [],
+    "flaky": false,
+    "gtest": true,
+    "language": "c++",
+    "name": "stats_test",
+    "platforms": [
+      "linux",
+      "mac",
+      "posix",
+      "windows"
+    ],
+    "uses_polling": false
+  },
+  {
+    "args": [],
+    "benchmark": false,
+    "ci_platforms": [
+      "linux",
+      "mac",
+      "posix",
+      "windows"
+    ],
+    "cpu_cost": 1.0,
+    "exclude_configs": [],
+    "exclude_iomgrs": [],
+    "flaky": false,
+    "gtest": true,
+    "language": "c++",
+    "name": "status_helper_test",
+    "platforms": [
+      "linux",
+      "mac",
+      "posix",
+      "windows"
+    ],
+    "uses_polling": false
+  },
+  {
+    "args": [],
+    "benchmark": false,
+    "ci_platforms": [
+      "linux",
+      "mac",
+      "posix",
+      "windows"
+    ],
+    "cpu_cost": 1.0,
+    "exclude_configs": [],
+    "exclude_iomgrs": [],
+    "flaky": false,
+    "gtest": true,
+    "language": "c++",
+    "name": "status_metadata_test",
+    "platforms": [
+      "linux",
+      "mac",
+      "posix",
+      "windows"
+    ],
+    "uses_polling": false
+  },
+  {
+    "args": [],
+    "benchmark": false,
+    "ci_platforms": [
+      "linux",
+      "mac",
+      "posix",
+      "windows"
+    ],
+    "cpu_cost": 1.0,
+    "exclude_configs": [],
+    "exclude_iomgrs": [],
+    "flaky": false,
+    "gtest": true,
+    "language": "c++",
+    "name": "status_util_test",
+    "platforms": [
+      "linux",
+      "mac",
+      "posix",
+      "windows"
+    ],
+    "uses_polling": false
+  },
+  {
+    "args": [],
+    "benchmark": false,
+    "ci_platforms": [
+      "linux",
+      "mac",
+      "posix"
+    ],
+    "cpu_cost": 1.0,
+    "exclude_configs": [],
+    "exclude_iomgrs": [],
+    "flaky": false,
+    "gtest": true,
+    "language": "c++",
+    "name": "stranded_event_test",
+    "platforms": [
+      "linux",
+      "mac",
+      "posix"
+    ],
+    "uses_polling": true
+  },
+  {
+    "args": [],
+    "benchmark": false,
+    "ci_platforms": [
+      "linux",
+      "mac",
+      "posix"
+    ],
+    "cpu_cost": 1.0,
+    "exclude_configs": [],
+    "exclude_iomgrs": [],
+    "flaky": false,
+    "gtest": true,
+    "language": "c++",
+    "name": "streaming_throughput_test",
+    "platforms": [
+      "linux",
+      "mac",
+      "posix"
+    ],
+    "uses_polling": true
+  },
+  {
+    "args": [],
+    "benchmark": false,
+    "ci_platforms": [
+      "linux",
+      "mac",
+      "posix",
+      "windows"
+    ],
+    "cpu_cost": 1.0,
+    "exclude_configs": [],
+    "exclude_iomgrs": [],
+    "flaky": false,
+    "gtest": true,
+    "language": "c++",
+    "name": "string_ref_test",
+    "platforms": [
+      "linux",
+      "mac",
+      "posix",
+      "windows"
+    ],
+    "uses_polling": false
+  },
+  {
+    "args": [],
+    "benchmark": false,
+    "ci_platforms": [
+      "linux",
+      "mac",
+      "posix",
+      "windows"
+    ],
+    "cpu_cost": 1.0,
+    "exclude_configs": [],
+    "exclude_iomgrs": [],
+    "flaky": false,
+    "gtest": true,
+    "language": "c++",
+    "name": "table_test",
+    "platforms": [
+      "linux",
+      "mac",
+      "posix",
+      "windows"
+    ],
+    "uses_polling": false
+  },
+  {
+    "args": [],
+    "benchmark": false,
+    "ci_platforms": [
+      "linux",
+      "mac",
+      "posix",
+      "windows"
+    ],
+    "cpu_cost": 1.0,
+    "exclude_configs": [],
+    "exclude_iomgrs": [],
+    "flaky": false,
+    "gtest": true,
+    "language": "c++",
+    "name": "test_cpp_client_credentials_test",
+    "platforms": [
+      "linux",
+      "mac",
+      "posix",
+      "windows"
+    ],
+    "uses_polling": true
+  },
+  {
+    "args": [],
+    "benchmark": false,
+    "ci_platforms": [
+      "linux",
+      "mac",
+      "posix",
+      "windows"
+    ],
+    "cpu_cost": 1.0,
+    "exclude_configs": [],
+    "exclude_iomgrs": [],
+    "flaky": false,
+    "gtest": true,
+    "language": "c++",
+    "name": "test_cpp_server_credentials_test",
+    "platforms": [
+      "linux",
+      "mac",
+      "posix",
+      "windows"
+    ],
+    "uses_polling": true
+  },
+  {
+    "args": [],
+    "benchmark": false,
+    "ci_platforms": [
+      "linux",
+      "mac",
+      "posix",
+      "windows"
+    ],
+    "cpu_cost": 1.0,
+    "exclude_configs": [],
+    "exclude_iomgrs": [],
+    "flaky": false,
+    "gtest": true,
+    "language": "c++",
+    "name": "test_cpp_util_slice_test",
+    "platforms": [
+      "linux",
+      "mac",
+      "posix",
+      "windows"
+    ],
+    "uses_polling": false
+  },
+  {
+    "args": [],
+    "benchmark": false,
+    "ci_platforms": [
+      "linux",
+      "mac",
+      "posix",
+      "windows"
+    ],
+    "cpu_cost": 1.0,
+    "exclude_configs": [],
+    "exclude_iomgrs": [],
+    "flaky": false,
+    "gtest": true,
+    "language": "c++",
+    "name": "test_cpp_util_time_test",
+    "platforms": [
+      "linux",
+      "mac",
+      "posix",
+      "windows"
+    ],
+    "uses_polling": false
+  },
+  {
+    "args": [],
+    "benchmark": false,
+    "ci_platforms": [
+      "linux",
+      "mac",
+      "posix",
+      "windows"
+    ],
+    "cpu_cost": 1.0,
+    "exclude_configs": [],
+    "exclude_iomgrs": [],
+    "flaky": false,
+    "gtest": true,
+    "language": "c++",
+    "name": "thread_manager_test",
+    "platforms": [
+      "linux",
+      "mac",
+      "posix",
+      "windows"
+    ],
+    "uses_polling": true
+  },
+  {
+    "args": [],
+    "benchmark": false,
+    "ci_platforms": [
+      "linux",
+      "mac",
+      "posix"
+    ],
+    "cpu_cost": 1.0,
+    "exclude_configs": [],
+    "exclude_iomgrs": [],
+    "flaky": false,
+    "gtest": true,
+    "language": "c++",
+    "name": "thread_stress_test",
+    "platforms": [
+      "linux",
+      "mac",
+      "posix"
+    ],
+    "uses_polling": true
+  },
+  {
+    "args": [],
+    "benchmark": false,
+    "ci_platforms": [
+      "linux",
+      "mac",
+      "posix",
+      "windows"
+    ],
+    "cpu_cost": 1.0,
+    "exclude_configs": [],
+    "exclude_iomgrs": [],
+    "flaky": false,
+    "gtest": true,
+    "language": "c++",
+    "name": "time_util_test",
+    "platforms": [
+      "linux",
+      "mac",
+      "posix",
+      "windows"
+    ],
+    "uses_polling": false
+  },
+  {
+    "args": [],
+    "benchmark": false,
+    "ci_platforms": [
+      "linux",
+      "mac",
+      "posix",
+      "windows"
+    ],
+    "cpu_cost": 1.0,
+    "exclude_configs": [],
+    "exclude_iomgrs": [],
+    "flaky": false,
+    "gtest": true,
+    "language": "c++",
+    "name": "timer_test",
+    "platforms": [
+      "linux",
+      "mac",
+      "posix",
+      "windows"
+    ],
+    "uses_polling": true
+  },
+  {
+    "args": [],
+    "benchmark": false,
+    "ci_platforms": [
+      "linux",
+      "mac",
+      "posix",
+      "windows"
+    ],
+    "cpu_cost": 1.0,
+    "exclude_configs": [],
+    "exclude_iomgrs": [],
+    "flaky": false,
+    "gtest": true,
+    "language": "c++",
+    "name": "tls_security_connector_test",
+    "platforms": [
+      "linux",
+      "mac",
+      "posix",
+      "windows"
+    ],
+    "uses_polling": true
+  },
+  {
+    "args": [],
+    "benchmark": false,
+    "ci_platforms": [
+      "linux",
+      "mac",
+      "posix",
+      "windows"
+    ],
+    "cpu_cost": 1.0,
+    "exclude_configs": [],
+    "exclude_iomgrs": [],
+    "flaky": false,
+    "gtest": true,
+    "language": "c++",
+    "name": "tls_test",
+    "platforms": [
+      "linux",
+      "mac",
+      "posix",
+      "windows"
+    ],
+    "uses_polling": false
+  },
+  {
+    "args": [],
+    "benchmark": false,
+    "ci_platforms": [
+      "linux",
+      "mac",
+      "posix",
+      "windows"
+    ],
+    "cpu_cost": 1.0,
+    "exclude_configs": [],
+    "exclude_iomgrs": [],
+    "flaky": false,
+    "gtest": true,
+    "language": "c++",
+    "name": "too_many_pings_test",
+    "platforms": [
+      "linux",
+      "mac",
+      "posix",
+      "windows"
+    ],
+    "uses_polling": true
+  },
+  {
+    "args": [],
+    "benchmark": false,
+    "ci_platforms": [
+      "linux",
+      "mac",
+      "posix",
+      "windows"
+    ],
+    "cpu_cost": 1.0,
+    "exclude_configs": [],
+    "exclude_iomgrs": [],
+    "flaky": false,
+    "gtest": true,
+    "language": "c++",
+    "name": "transport_stream_receiver_test",
+    "platforms": [
+      "linux",
+      "mac",
+      "posix",
+      "windows"
+    ],
+    "uses_polling": false
+  },
+  {
+    "args": [],
+    "benchmark": false,
+    "ci_platforms": [
+      "linux",
+      "mac",
+      "posix",
+      "windows"
+    ],
+    "cpu_cost": 1.0,
+    "exclude_configs": [],
+    "exclude_iomgrs": [],
+    "flaky": false,
+    "gtest": true,
+    "language": "c++",
+    "name": "try_join_test",
+    "platforms": [
+      "linux",
+      "mac",
+      "posix",
+      "windows"
+    ],
+    "uses_polling": false
+  },
+  {
+    "args": [],
+    "benchmark": false,
+    "ci_platforms": [
+      "linux",
+      "mac",
+      "posix",
+      "windows"
+    ],
+    "cpu_cost": 1.0,
+    "exclude_configs": [],
+    "exclude_iomgrs": [],
+    "flaky": false,
+    "gtest": true,
+    "language": "c++",
+    "name": "try_seq_test",
+    "platforms": [
+      "linux",
+      "mac",
+      "posix",
+      "windows"
+    ],
+    "uses_polling": false
+  },
+  {
+    "args": [],
+    "benchmark": false,
+    "ci_platforms": [
+      "linux",
+      "mac",
+      "posix",
+      "windows"
+    ],
+    "cpu_cost": 1.0,
+    "exclude_configs": [],
+    "exclude_iomgrs": [],
+    "flaky": false,
+    "gtest": true,
+    "language": "c++",
+    "name": "unknown_frame_bad_client_test",
+    "platforms": [
+      "linux",
+      "mac",
+      "posix",
+      "windows"
+    ],
+    "uses_polling": true
+  },
+  {
+    "args": [],
+    "benchmark": false,
+    "ci_platforms": [
+      "linux",
+      "mac",
+      "posix",
+      "windows"
+    ],
+    "cpu_cost": 1.0,
+    "exclude_configs": [],
+    "exclude_iomgrs": [],
+    "flaky": false,
+    "gtest": true,
+    "language": "c++",
+    "name": "uri_parser_test",
+    "platforms": [
+      "linux",
+      "mac",
+      "posix",
+      "windows"
+    ],
+    "uses_polling": true
+  },
+  {
+    "args": [],
+    "benchmark": false,
+    "ci_platforms": [
+      "linux",
+      "mac",
+      "posix",
+      "windows"
+    ],
+    "cpu_cost": 1.0,
+    "exclude_configs": [],
+    "exclude_iomgrs": [],
+    "flaky": false,
+    "gtest": true,
+    "language": "c++",
+    "name": "window_overflow_bad_client_test",
+    "platforms": [
+      "linux",
+      "mac",
+      "posix",
+      "windows"
+    ],
+    "uses_polling": true
+  },
+  {
+    "args": [],
+    "benchmark": false,
+    "ci_platforms": [
+      "linux",
+      "mac",
+      "posix",
+      "windows"
+    ],
+    "cpu_cost": 1.0,
+    "exclude_configs": [],
+    "exclude_iomgrs": [],
+    "flaky": false,
+    "gtest": true,
+    "language": "c++",
+    "name": "wire_reader_test",
+    "platforms": [
+      "linux",
+      "mac",
+      "posix",
+      "windows"
+    ],
+    "uses_polling": false
+  },
+  {
+    "args": [],
+    "benchmark": false,
+    "ci_platforms": [
+      "linux",
+      "mac",
+      "posix",
+      "windows"
+    ],
+    "cpu_cost": 1.0,
+    "exclude_configs": [],
+    "exclude_iomgrs": [],
+    "flaky": false,
+    "gtest": true,
+    "language": "c++",
+    "name": "wire_writer_test",
+    "platforms": [
+      "linux",
+      "mac",
+      "posix",
+      "windows"
+    ],
+    "uses_polling": false
+  },
+  {
+    "args": [],
+    "benchmark": false,
+    "ci_platforms": [
+      "linux",
+      "mac",
+      "posix"
+    ],
+    "cpu_cost": 1.0,
+    "exclude_configs": [],
+    "exclude_iomgrs": [],
+    "flaky": false,
+    "gtest": true,
+    "language": "c++",
+    "name": "work_serializer_test",
+    "platforms": [
+      "linux",
+      "mac",
+      "posix"
+    ],
+    "uses_polling": true
+  },
+  {
+    "args": [],
+    "benchmark": false,
+    "ci_platforms": [
+      "linux",
+      "mac",
+      "posix"
+    ],
+    "cpu_cost": 1.0,
+    "exclude_configs": [],
+    "exclude_iomgrs": [],
+    "flaky": false,
+    "gtest": true,
+    "language": "c++",
+    "name": "writes_per_rpc_test",
+    "platforms": [
+      "linux",
+      "mac",
+      "posix"
+    ],
+    "uses_polling": true
+  },
+  {
+    "args": [],
+    "benchmark": false,
+    "ci_platforms": [
+      "linux",
+      "mac",
+      "posix",
+      "windows"
+    ],
+    "cpu_cost": 1.0,
+    "exclude_configs": [],
+    "exclude_iomgrs": [],
+    "flaky": false,
+    "gtest": true,
+    "language": "c++",
+    "name": "xds_bootstrap_test",
+    "platforms": [
+      "linux",
+      "mac",
+      "posix",
+      "windows"
+    ],
+    "uses_polling": true
+  },
+  {
+    "args": [],
+    "benchmark": false,
+    "ci_platforms": [
+      "linux",
+      "mac",
+      "posix",
+      "windows"
+    ],
+    "cpu_cost": 1.0,
+    "exclude_configs": [],
+    "exclude_iomgrs": [],
+    "flaky": false,
+    "gtest": true,
+    "language": "c++",
+    "name": "xds_certificate_provider_test",
     "platforms": [
       "linux",
       "mac",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "alts_credentials_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "client_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "hpack_parser_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_request_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "http_response_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "json_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_response_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "nanopb_fuzzer_serverlist_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "percent_decode_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "percent_decode_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "percent_decode_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "percent_decode_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "percent_decode_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "percent_decode_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "percent_decode_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "percent_decode_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "percent_decode_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "percent_decode_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "percent_decode_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "percent_decode_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "percent_decode_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "percent_decode_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "percent_decode_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "percent_decode_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "percent_decode_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "percent_decode_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "percent_decode_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "percent_decode_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "percent_decode_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "percent_decode_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "percent_decode_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "percent_decode_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "percent_decode_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "percent_decode_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "percent_decode_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "percent_encode_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "percent_encode_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "percent_encode_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "percent_encode_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "percent_encode_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "percent_encode_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "percent_encode_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "percent_encode_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "percent_encode_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "percent_encode_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "percent_encode_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "percent_encode_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "percent_encode_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "percent_encode_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "percent_encode_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "percent_encode_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "ssl_server_fuzzer_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
     "exclude_configs": [
       "tsan"
     ],
-    "exclude_iomgrs": [
-      "uv"
-    ],
     "flaky": false,
     "language": "c++",
     "name": "uri_fuzzer_test_one_entry",
index 6187c88..64e7c40 100755 (executable)
@@ -13,6 +13,7 @@
 # See the License for the specific language governing permissions and
 # limitations under the License.
 
+trap 'date' DEBUG
 set -ex
 
 # change to grpc repo root
index 7139cc3..9f0179a 100755 (executable)
@@ -62,14 +62,16 @@ def _upload_netperf_latency_csv_to_bigquery(dataset_id, table_id, result_file):
         sys.exit(1)
 
 
-def _upload_scenario_result_to_bigquery(dataset_id, table_id, result_file):
+def _upload_scenario_result_to_bigquery(dataset_id, table_id, result_file,
+                                        metadata_file, node_info_file):
     with open(result_file, 'r') as f:
         scenario_result = json.loads(f.read())
 
     bq = big_query_utils.create_big_query()
     _create_results_table(bq, dataset_id, table_id)
 
-    if not _insert_result(bq, dataset_id, table_id, scenario_result):
+    if not _insert_scenario_result(bq, dataset_id, table_id, scenario_result,
+                                   metadata_file, node_info_file):
         print('Error uploading result to bigquery.')
         sys.exit(1)
 
@@ -83,6 +85,22 @@ def _insert_result(bq, dataset_id, table_id, scenario_result, flatten=True):
                                        [row])
 
 
+def _insert_scenario_result(bq,
+                            dataset_id,
+                            table_id,
+                            scenario_result,
+                            test_metadata_file,
+                            node_info_file,
+                            flatten=True):
+    if flatten:
+        _flatten_result_inplace(scenario_result)
+    _populate_metadata_from_file(scenario_result, test_metadata_file)
+    _populate_node_metadata_from_file(scenario_result, node_info_file)
+    row = big_query_utils.make_row(str(uuid.uuid4()), scenario_result)
+    return big_query_utils.insert_rows(bq, _PROJECT_ID, dataset_id, table_id,
+                                       [row])
+
+
 def _create_results_table(bq, dataset_id, table_id):
     with open(os.path.dirname(__file__) + '/scenario_result_schema.json',
               'r') as f:
@@ -158,6 +176,72 @@ def _populate_metadata_inplace(scenario_result):
     scenario_result['metadata'] = metadata
 
 
+def _populate_metadata_from_file(scenario_result, test_metadata_file):
+    utc_timestamp = str(calendar.timegm(time.gmtime()))
+    metadata = {'created': utc_timestamp}
+
+    _annotation_to_bq_metadata_key_map = {
+        'ci_' + key: key for key in (
+            'buildNumber',
+            'buildUrl',
+            'jobName',
+            'gitCommit',
+            'gitActualCommit',
+        )
+    }
+
+    if os.access(test_metadata_file, os.R_OK):
+        with open(test_metadata_file, 'r') as f:
+            test_metadata = json.loads(f.read())
+
+        # eliminate managedFields from metadata set
+        if 'managedFields' in test_metadata:
+            del test_metadata['managedFields']
+
+        annotations = test_metadata.get('annotations', {})
+
+        # if use kubectl apply ..., kubectl will append current configuration to
+        # annotation, the field is deleted since it includes a lot of irrelevant
+        # information
+        if 'kubectl.kubernetes.io/last-applied-configuration' in annotations:
+            del annotations['kubectl.kubernetes.io/last-applied-configuration']
+
+        # dump all metadata as JSON to testMetadata field
+        scenario_result['testMetadata'] = json.dumps(test_metadata)
+        for key, value in _annotation_to_bq_metadata_key_map.items():
+            if key in annotations:
+                metadata[value] = annotations[key]
+
+    scenario_result['metadata'] = metadata
+
+
+def _populate_node_metadata_from_file(scenario_result, node_info_file):
+    node_metadata = {'driver': {}, 'servers': [], 'clients': []}
+    _node_info_to_bq_node_metadata_key_map = {
+        'Name': 'name',
+        'PodIP': 'podIP',
+        'NodeName': 'nodeName',
+    }
+
+    if os.access(node_info_file, os.R_OK):
+        with open(node_info_file, 'r') as f:
+            file_metadata = json.loads(f.read())
+        for key, value in _node_info_to_bq_node_metadata_key_map.items():
+            node_metadata['driver'][value] = file_metadata['Driver'][key]
+        for clientNodeInfo in file_metadata['Clients']:
+            node_metadata['clients'].append({
+                value: clientNodeInfo[key] for key, value in
+                _node_info_to_bq_node_metadata_key_map.items()
+            })
+        for serverNodeInfo in file_metadata['Servers']:
+            node_metadata['servers'].append({
+                value: serverNodeInfo[key] for key, value in
+                _node_info_to_bq_node_metadata_key_map.items()
+            })
+
+    scenario_result['nodeMetadata'] = node_metadata
+
+
 argp = argparse.ArgumentParser(description='Upload result to big query.')
 argp.add_argument('--bq_result_table',
                   required=True,
@@ -168,6 +252,14 @@ argp.add_argument('--file_to_upload',
                   default='scenario_result.json',
                   type=str,
                   help='Report file to upload.')
+argp.add_argument('--metadata_file_to_upload',
+                  default='metadata.json',
+                  type=str,
+                  help='Metadata file to upload.')
+argp.add_argument('--node_info_file_to_upload',
+                  default='node_info.json',
+                  type=str,
+                  help='Node information file to upload.')
 argp.add_argument('--file_format',
                   choices=['scenario_result', 'netperf_latency_csv'],
                   default='scenario_result',
@@ -182,5 +274,9 @@ if args.file_format == 'netperf_latency_csv':
                                             args.file_to_upload)
 else:
     _upload_scenario_result_to_bigquery(dataset_id, table_id,
-                                        args.file_to_upload)
-print('Successfully uploaded %s to BigQuery.\n' % args.file_to_upload)
+                                        args.file_to_upload,
+                                        args.metadata_file_to_upload,
+                                        args.node_info_file_to_upload)
+print('Successfully uploaded %s, %s and %s to BigQuery.\n' %
+      (args.file_to_upload, args.metadata_file_to_upload,
+       args.node_info_file_to_upload))
index 8b8ebb9..095f6c9 100644 (file)
     "mode": "NULLABLE", 
     "name": "serverCpuUsage", 
     "type": "FLOAT"
+  },
+  {
+    "mode": "NULLABLE",
+    "name": "testMetadata",
+    "type": "STRING"
+  },
+  {
+    "fields": [
+      {
+        "fields": [
+          {
+            "mode": "NULLABLE", 
+            "name": "name", 
+            "type": "STRING"
+          }, 
+          {
+            "mode": "NULLABLE", 
+            "name": "podIP", 
+            "type": "STRING"
+          }, 
+          {
+            "mode": "NULLABLE", 
+            "name": "nodeName", 
+            "type": "STRING"
+          }
+        ],
+        "mode": "NULLABLE", 
+        "name": "driver", 
+        "type": "RECORD"
+      }, 
+      {
+        "fields": [
+          {
+            "mode": "NULLABLE", 
+            "name": "name", 
+            "type": "STRING"
+          }, 
+          {
+            "mode": "NULLABLE", 
+            "name": "podIP", 
+            "type": "STRING"
+          }, 
+          {
+            "mode": "NULLABLE", 
+            "name": "nodeName", 
+            "type": "STRING"
+          }
+        ],
+        "mode": "REPEATED", 
+        "name": "servers", 
+        "type": "RECORD"
+      }, 
+      {
+        "fields": [
+          {
+            "mode": "NULLABLE", 
+            "name": "name", 
+            "type": "STRING"
+          }, 
+          {
+            "mode": "NULLABLE", 
+            "name": "podIP", 
+            "type": "STRING"
+          }, 
+          {
+            "mode": "NULLABLE", 
+            "name": "nodeName", 
+            "type": "STRING"
+          }
+        ],
+        "mode": "REPEATED", 
+        "name": "clients", 
+        "type": "RECORD"
+      }
+    ], 
+    "mode": "NULLABLE", 
+    "name": "nodeMetadata", 
+    "type": "RECORD"
   }
-]
\ No newline at end of file
+]
index 60ce0e0..a8bbf65 100755 (executable)
@@ -136,9 +136,9 @@ def message(tag, msg, explanatory_text=None, do_newline=False):
                 sys.stdout.write(
                     '%s%s%s\x1b[%d;%dm%s\x1b[0m: %s%s' %
                     (_BEGINNING_OF_LINE, _CLEAR_LINE, '\n%s' %
-                     explanatory_text.decode('utf8') if explanatory_text
-                     is not None else '', _COLORS[_TAG_COLOR[tag]][1],
-                     _COLORS[_TAG_COLOR[tag]][0], tag, msg, '\n'
+                     explanatory_text if explanatory_text is not None else '',
+                     _COLORS[_TAG_COLOR[tag]][1], _COLORS[_TAG_COLOR[tag]][0],
+                     tag, msg, '\n'
                      if do_newline or explanatory_text is not None else ''))
             sys.stdout.flush()
             return
index a176aed..baee928 100755 (executable)
@@ -273,23 +273,6 @@ class CLanguage(object):
                 # see https://github.com/grpc/grpc/blob/b5b8578b3f8b4a9ce61ed6677e19d546e43c5c68/tools/run_tests/artifacts/artifact_targets.py#L253
                 self._cmake_configure_extra_args.append('-DOPENSSL_NO_ASM=ON')
 
-        if args.iomgr_platform == "uv":
-            cflags = '-DGRPC_UV -DGRPC_CUSTOM_IOMGR_THREAD_CHECK -DGRPC_CUSTOM_SOCKET '
-            try:
-                cflags += subprocess.check_output(
-                    ['pkg-config', '--cflags', 'libuv']).strip() + ' '
-            except (subprocess.CalledProcessError, OSError):
-                pass
-            try:
-                ldflags = subprocess.check_output(
-                    ['pkg-config', '--libs', 'libuv']).strip() + ' '
-            except (subprocess.CalledProcessError, OSError):
-                ldflags = '-luv '
-            self._make_options += [
-                'EXTRA_CPPFLAGS={}'.format(cflags),
-                'EXTRA_LDLIBS={}'.format(ldflags)
-            ]
-
     def test_specs(self):
         out = []
         binaries = get_c_tests(self.args.travis, self.test_lang)
@@ -301,8 +284,6 @@ class CLanguage(object):
             polling_strategies = (_POLLING_STRATEGIES.get(
                 self.platform, ['all']) if target.get('uses_polling', True) else
                                   ['none'])
-            if self.args.iomgr_platform == 'uv':
-                polling_strategies = ['all']
             for polling_strategy in polling_strategies:
                 env = {
                     'GRPC_DEFAULT_SSL_ROOTS_FILE_PATH':
@@ -1464,7 +1445,7 @@ argp.add_argument(
     'Selects compiler to use. Allowed values depend on the platform and language.'
 )
 argp.add_argument('--iomgr_platform',
-                  choices=['native', 'uv', 'gevent', 'asyncio'],
+                  choices=['native', 'gevent', 'asyncio'],
                   default='native',
                   help='Selects iomgr platform to build on')
 argp.add_argument('--build_only',
index bde2aae..7e3d96c 100755 (executable)
@@ -340,19 +340,6 @@ def _create_portability_test_jobs(extra_args=[],
                                 ['--report_multi_target'],
                                 inner_jobs=inner_jobs)
 
-    # TODO(jtattermusch): a large portion of the libuv tests is failing,
-    # which can end up killing the kokoro job due to gigabytes of error logs
-    # generated. Remove the --build_only flag
-    # once https://github.com/grpc/grpc/issues/17556 is fixed.
-    test_jobs += _generate_jobs(languages=['c'],
-                                configs=['dbg'],
-                                platforms=['linux'],
-                                iomgr_platforms=['uv'],
-                                labels=['portability', 'corelang'],
-                                extra_args=extra_args + ['--build_only'],
-                                inner_jobs=inner_jobs,
-                                timeout_seconds=_CPP_RUNTESTS_TIMEOUT)
-
     return test_jobs
 
 
index cb884fc..c46f9dd 100755 (executable)
@@ -1169,7 +1169,6 @@ def test_api_listener(gcp, backend_service, instance_group,
                       alternate_backend_service):
     logger.info("Running api_listener")
     passed = True
-    new_config_suffix = ''
     try:
         wait_for_healthy_backends(gcp, backend_service, instance_group)
         backend_instances = get_instance_names(gcp, instance_group)
@@ -1180,9 +1179,10 @@ def test_api_listener(gcp, backend_service, instance_group,
         # ip address in fr for proxyless and also we violate ip:port uniqueness
         # for test purpose. See https://github.com/grpc/grpc-java/issues/8009
         new_config_suffix = '2'
-        create_url_map(gcp, url_map_name + new_config_suffix, backend_service,
-                       service_host_name)
-        create_target_proxy(gcp, target_proxy_name + new_config_suffix, False)
+        url_map_2 = create_url_map(gcp, url_map_name + new_config_suffix,
+                                   backend_service, service_host_name)
+        target_proxy_2 = create_target_proxy(
+            gcp, target_proxy_name + new_config_suffix, False, url_map_2)
         if not gcp.service_port:
             raise Exception(
                 'Faied to find a valid port for the forwarding rule')
@@ -1194,7 +1194,7 @@ def test_api_listener(gcp, backend_service, instance_group,
         create_global_forwarding_rule(gcp,
                                       forwarding_rule_name + new_config_suffix,
                                       [gcp.service_port],
-                                      potential_ip_addresses)
+                                      potential_ip_addresses, target_proxy_2)
         if gcp.service_port != _DEFAULT_SERVICE_PORT:
             patch_url_map_host_rule_with_port(gcp,
                                               url_map_name + new_config_suffix,
@@ -1203,9 +1203,9 @@ def test_api_listener(gcp, backend_service, instance_group,
         wait_until_all_rpcs_go_to_given_backends(backend_instances,
                                                  _WAIT_FOR_STATS_SEC)
 
-        delete_global_forwarding_rule(gcp, forwarding_rule_name)
-        delete_target_proxy(gcp, target_proxy_name)
-        delete_url_map(gcp, url_map_name)
+        delete_global_forwarding_rule(gcp, gcp.global_forwarding_rules[0])
+        delete_target_proxy(gcp, gcp.target_proxies[0])
+        delete_url_map(gcp, gcp.url_maps[0])
         verify_attempts = int(_WAIT_FOR_URL_MAP_PATCH_SEC / _NUM_TEST_RPCS *
                               args.qps)
         for i in range(verify_attempts):
@@ -1221,10 +1221,9 @@ def test_api_listener(gcp, backend_service, instance_group,
         raise
     finally:
         if passed or not args.halt_after_fail:
-            delete_global_forwarding_rule(
-                gcp, forwarding_rule_name + new_config_suffix)
-            delete_target_proxy(gcp, target_proxy_name + new_config_suffix)
-            delete_url_map(gcp, url_map_name + new_config_suffix)
+            delete_global_forwarding_rules(gcp)
+            delete_target_proxies(gcp)
+            delete_url_maps(gcp)
             create_url_map(gcp, url_map_name, backend_service,
                            service_host_name)
             create_target_proxy(gcp, target_proxy_name)
@@ -1248,7 +1247,7 @@ def test_forwarding_rule_port_match(gcp, backend_service, instance_group):
         backend_instances = get_instance_names(gcp, instance_group)
         wait_until_all_rpcs_go_to_given_backends(backend_instances,
                                                  _WAIT_FOR_STATS_SEC)
-        delete_global_forwarding_rule(gcp)
+        delete_global_forwarding_rules(gcp)
         create_global_forwarding_rule(gcp, forwarding_rule_name, [
             x for x in parse_port_range(_DEFAULT_PORT_RANGE)
             if x != gcp.service_port
@@ -1260,7 +1259,7 @@ def test_forwarding_rule_port_match(gcp, backend_service, instance_group):
         raise
     finally:
         if passed or not args.halt_after_fail:
-            delete_global_forwarding_rule(gcp)
+            delete_global_forwarding_rules(gcp)
             create_global_forwarding_rule(gcp, forwarding_rule_name,
                                           potential_service_ports)
             if gcp.service_port != _DEFAULT_SERVICE_PORT:
@@ -1282,7 +1281,7 @@ def test_forwarding_rule_default_port(gcp, backend_service, instance_group):
         if gcp.service_port == _DEFAULT_SERVICE_PORT:
             wait_until_all_rpcs_go_to_given_backends(backend_instances,
                                                      _WAIT_FOR_STATS_SEC)
-            delete_global_forwarding_rule(gcp)
+            delete_global_forwarding_rules(gcp)
             create_global_forwarding_rule(gcp, forwarding_rule_name,
                                           parse_port_range(_DEFAULT_PORT_RANGE))
             patch_url_map_host_rule_with_port(gcp, url_map_name,
@@ -1291,11 +1290,11 @@ def test_forwarding_rule_default_port(gcp, backend_service, instance_group):
         wait_until_no_rpcs_go_to_given_backends(backend_instances,
                                                 _WAIT_FOR_STATS_SEC)
         # expect success when no port in client request service uri, and no port in url-map
-        delete_global_forwarding_rule(gcp)
-        delete_target_proxy(gcp)
-        delete_url_map(gcp)
+        delete_global_forwarding_rule(gcp, gcp.global_forwarding_rules[0])
+        delete_target_proxy(gcp, gcp.target_proxies[0])
+        delete_url_map(gcp, gcp.url_maps[0])
         create_url_map(gcp, url_map_name, backend_service, service_host_name)
-        create_target_proxy(gcp, gcp.target_proxy.name, False)
+        create_target_proxy(gcp, target_proxy_name, False)
         potential_ip_addresses = []
         max_attempts = 10
         for i in range(max_attempts):
@@ -1316,9 +1315,9 @@ def test_forwarding_rule_default_port(gcp, backend_service, instance_group):
         raise
     finally:
         if passed or not args.halt_after_fail:
-            delete_global_forwarding_rule(gcp)
-            delete_target_proxy(gcp)
-            delete_url_map(gcp)
+            delete_global_forwarding_rules(gcp)
+            delete_target_proxies(gcp)
+            delete_url_maps(gcp)
             create_url_map(gcp, url_map_name, backend_service,
                            service_host_name)
             create_target_proxy(gcp, target_proxy_name)
@@ -2331,14 +2330,18 @@ def set_validate_for_proxyless(gcp, validate_for_proxyless):
         logger.debug(
             'Not setting validateForProxy because alpha is not enabled')
         return
+    if len(gcp.global_forwarding_rules) != 1 or len(
+            gcp.target_proxies) != 1 or len(gcp.url_maps) != 1:
+        logger.debug(
+            "Global forwarding rule, target proxy or url map not found.")
+        return
     # This function deletes global_forwarding_rule and target_proxy, then
     # recreate target_proxy with validateForProxyless=False. This is necessary
     # because patching target_grpc_proxy isn't supported.
-    delete_global_forwarding_rule(gcp)
-    delete_target_proxy(gcp)
-    create_target_proxy(gcp, gcp.target_proxy.name, validate_for_proxyless)
-    create_global_forwarding_rule(gcp, gcp.global_forwarding_rule.name,
-                                  [gcp.service_port])
+    delete_global_forwarding_rule(gcp, gcp.global_forwarding_rules[0])
+    delete_target_proxy(gcp, gcp.target_proxies[0])
+    create_target_proxy(gcp, target_proxy_name, validate_for_proxyless)
+    create_global_forwarding_rule(gcp, forwarding_rule_name, [gcp.service_port])
 
 
 def get_serving_status(instance, service_port):
@@ -2553,7 +2556,9 @@ def create_url_map(gcp, name, backend_service, host_name):
     result = gcp.compute.urlMaps().insert(
         project=gcp.project, body=config).execute(num_retries=_GCP_API_RETRIES)
     wait_for_global_operation(gcp, result['name'])
-    gcp.url_map = GcpResource(config['name'], result['targetLink'])
+    url_map = GcpResource(config['name'], result['targetLink'])
+    gcp.url_maps.append(url_map)
+    return url_map
 
 
 def patch_url_map_host_rule_with_port(gcp, name, backend_service, host_name):
@@ -2570,11 +2575,15 @@ def patch_url_map_host_rule_with_port(gcp, name, backend_service, host_name):
     wait_for_global_operation(gcp, result['name'])
 
 
-def create_target_proxy(gcp, name, validate_for_proxyless=True):
+def create_target_proxy(gcp, name, validate_for_proxyless=True, url_map=None):
+    if url_map:
+        arg_url_map_url = url_map.url
+    else:
+        arg_url_map_url = gcp.url_maps[0].url
     if gcp.alpha_compute:
         config = {
             'name': name,
-            'url_map': gcp.url_map.url,
+            'url_map': arg_url_map_url,
             'validate_for_proxyless': validate_for_proxyless
         }
         logger.debug('Sending GCP request with body=%s', config)
@@ -2584,20 +2593,27 @@ def create_target_proxy(gcp, name, validate_for_proxyless=True):
     else:
         config = {
             'name': name,
-            'url_map': gcp.url_map.url,
+            'url_map': arg_url_map_url,
         }
         logger.debug('Sending GCP request with body=%s', config)
         result = gcp.compute.targetHttpProxies().insert(
             project=gcp.project,
             body=config).execute(num_retries=_GCP_API_RETRIES)
     wait_for_global_operation(gcp, result['name'])
-    gcp.target_proxy = GcpResource(config['name'], result['targetLink'])
+    target_proxy = GcpResource(config['name'], result['targetLink'])
+    gcp.target_proxies.append(target_proxy)
+    return target_proxy
 
 
 def create_global_forwarding_rule(gcp,
                                   name,
                                   potential_ports,
-                                  potential_ip_addresses=['0.0.0.0']):
+                                  potential_ip_addresses=['0.0.0.0'],
+                                  target_proxy=None):
+    if target_proxy:
+        arg_target_proxy_url = target_proxy.url
+    else:
+        arg_target_proxy_url = gcp.target_proxies[0].url
     if gcp.alpha_compute:
         compute_to_use = gcp.alpha_compute
     else:
@@ -2611,15 +2627,16 @@ def create_global_forwarding_rule(gcp,
                     'portRange': str(port),
                     'IPAddress': ip_address,
                     'network': args.network,
-                    'target': gcp.target_proxy.url,
+                    'target': arg_target_proxy_url,
                 }
                 logger.debug('Sending GCP request with body=%s', config)
                 result = compute_to_use.globalForwardingRules().insert(
                     project=gcp.project,
                     body=config).execute(num_retries=_GCP_API_RETRIES)
                 wait_for_global_operation(gcp, result['name'])
-                gcp.global_forwarding_rule = GcpResource(
-                    config['name'], result['targetLink'])
+                global_forwarding_rule = GcpResource(config['name'],
+                                                     result['targetLink'])
+                gcp.global_forwarding_rules.append(global_forwarding_rule)
                 gcp.service_port = port
                 return
             except googleapiclient.errors.HttpError as http_error:
@@ -2663,17 +2680,19 @@ def get_backend_service(gcp, backend_service_name, record_error=True):
     return backend_service
 
 
-def get_url_map(gcp, url_map_name):
+def get_url_map(gcp, url_map_name, record_error=True):
     try:
         result = gcp.compute.urlMaps().get(project=gcp.project,
                                            urlMap=url_map_name).execute()
-        gcp.url_map = GcpResource(url_map_name, result['selfLink'])
+        url_map = GcpResource(url_map_name, result['selfLink'])
     except Exception as e:
-        gcp.errors.append(e)
-        gcp.url_map = GcpResource(url_map_name, None)
+        if record_error:
+            gcp.errors.append(e)
+        url_map = GcpResource(url_map_name, None)
+    gcp.url_maps.append(url_map)
 
 
-def get_target_proxy(gcp, target_proxy_name):
+def get_target_proxy(gcp, target_proxy_name, record_error=True):
     try:
         if gcp.alpha_compute:
             result = gcp.alpha_compute.targetGrpcProxies().get(
@@ -2683,21 +2702,25 @@ def get_target_proxy(gcp, target_proxy_name):
             result = gcp.compute.targetHttpProxies().get(
                 project=gcp.project,
                 targetHttpProxy=target_proxy_name).execute()
-        gcp.target_proxy = GcpResource(target_proxy_name, result['selfLink'])
+        target_proxy = GcpResource(target_proxy_name, result['selfLink'])
     except Exception as e:
-        gcp.errors.append(e)
-        gcp.target_proxy = GcpResource(target_proxy_name, None)
+        if record_error:
+            gcp.errors.append(e)
+        target_proxy = GcpResource(target_proxy_name, None)
+    gcp.target_proxies.append(target_proxy)
 
 
-def get_global_forwarding_rule(gcp, forwarding_rule_name):
+def get_global_forwarding_rule(gcp, forwarding_rule_name, record_error=True):
     try:
         result = gcp.compute.globalForwardingRules().get(
             project=gcp.project, forwardingRule=forwarding_rule_name).execute()
-        gcp.global_forwarding_rule = GcpResource(forwarding_rule_name,
-                                                 result['selfLink'])
+        global_forwarding_rule = GcpResource(forwarding_rule_name,
+                                             result['selfLink'])
     except Exception as e:
-        gcp.errors.append(e)
-        gcp.global_forwarding_rule = GcpResource(forwarding_rule_name, None)
+        if record_error:
+            gcp.errors.append(e)
+        global_forwarding_rule = GcpResource(forwarding_rule_name, None)
+    gcp.global_forwarding_rules.append(global_forwarding_rule)
 
 
 def get_instance_template(gcp, template_name):
@@ -2725,58 +2748,86 @@ def get_instance_group(gcp, zone, instance_group_name):
     return instance_group
 
 
-def delete_global_forwarding_rule(gcp, name=None):
-    if name:
-        forwarding_rule_to_delete = name
-    else:
-        forwarding_rule_to_delete = gcp.global_forwarding_rule.name
+def delete_global_forwarding_rule(gcp, forwarding_rule_to_delete=None):
+    if not forwarding_rule_to_delete:
+        return
     try:
-        logger.debug('Deleting forwarding rule %s', forwarding_rule_to_delete)
+        logger.debug('Deleting forwarding rule %s',
+                     forwarding_rule_to_delete.name)
         result = gcp.compute.globalForwardingRules().delete(
             project=gcp.project,
-            forwardingRule=forwarding_rule_to_delete).execute(
+            forwardingRule=forwarding_rule_to_delete.name).execute(
                 num_retries=_GCP_API_RETRIES)
         wait_for_global_operation(gcp, result['name'])
+        if forwarding_rule_to_delete in gcp.global_forwarding_rules:
+            gcp.global_forwarding_rules.remove(forwarding_rule_to_delete)
+        else:
+            logger.debug(
+                'Forwarding rule %s does not exist in gcp.global_forwarding_rules',
+                forwarding_rule_to_delete.name)
     except googleapiclient.errors.HttpError as http_error:
         logger.info('Delete failed: %s', http_error)
 
 
-def delete_target_proxy(gcp, name=None):
-    if name:
-        proxy_to_delete = name
-    else:
-        proxy_to_delete = gcp.target_proxy.name
+def delete_global_forwarding_rules(gcp):
+    for forwarding_rule in gcp.global_forwarding_rules:
+        delete_global_forwarding_rule(gcp, forwarding_rule)
+
+
+def delete_target_proxy(gcp, proxy_to_delete=None):
+    if not proxy_to_delete:
+        return
     try:
         if gcp.alpha_compute:
-            logger.debug('Deleting grpc proxy %s', proxy_to_delete)
+            logger.debug('Deleting grpc proxy %s', proxy_to_delete.name)
             result = gcp.alpha_compute.targetGrpcProxies().delete(
-                project=gcp.project, targetGrpcProxy=proxy_to_delete).execute(
+                project=gcp.project,
+                targetGrpcProxy=proxy_to_delete.name).execute(
                     num_retries=_GCP_API_RETRIES)
         else:
-            logger.debug('Deleting http proxy %s', proxy_to_delete)
+            logger.debug('Deleting http proxy %s', proxy_to_delete.name)
             result = gcp.compute.targetHttpProxies().delete(
-                project=gcp.project, targetHttpProxy=proxy_to_delete).execute(
+                project=gcp.project,
+                targetHttpProxy=proxy_to_delete.name).execute(
                     num_retries=_GCP_API_RETRIES)
         wait_for_global_operation(gcp, result['name'])
+        if proxy_to_delete in gcp.target_proxies:
+            gcp.target_proxies.remove(proxy_to_delete)
+        else:
+            logger.debug('Gcp proxy %s does not exist in gcp.target_proxies',
+                         proxy_to_delete.name)
     except googleapiclient.errors.HttpError as http_error:
         logger.info('Delete failed: %s', http_error)
 
 
-def delete_url_map(gcp, name=None):
-    if name:
-        url_map_to_delete = name
-    else:
-        url_map_to_delete = gcp.url_map.name
+def delete_target_proxies(gcp):
+    for target_proxy in gcp.target_proxies:
+        delete_target_proxy(gcp, target_proxy)
+
+
+def delete_url_map(gcp, url_map_to_delete=None):
+    if not url_map_to_delete:
+        return
     try:
-        logger.debug('Deleting url map %s', url_map_to_delete)
+        logger.debug('Deleting url map %s', url_map_to_delete.name)
         result = gcp.compute.urlMaps().delete(
             project=gcp.project,
-            urlMap=url_map_to_delete).execute(num_retries=_GCP_API_RETRIES)
+            urlMap=url_map_to_delete.name).execute(num_retries=_GCP_API_RETRIES)
         wait_for_global_operation(gcp, result['name'])
+        if url_map_to_delete in gcp.url_maps:
+            gcp.url_maps.remove(url_map_to_delete)
+        else:
+            logger.debug('Url map %s does not exist in gcp.url_maps',
+                         url_map_to_delete.name)
     except googleapiclient.errors.HttpError as http_error:
         logger.info('Delete failed: %s', http_error)
 
 
+def delete_url_maps(gcp):
+    for url_map in gcp.url_maps:
+        delete_url_map(gcp, url_map)
+
+
 def delete_backend_service(gcp, backend_service):
     try:
         logger.debug('Deleting backend service %s', backend_service.name)
@@ -2895,7 +2946,12 @@ def resize_instance_group(gcp,
 def patch_url_map_backend_service(gcp,
                                   backend_service=None,
                                   services_with_weights=None,
-                                  route_rules=None):
+                                  route_rules=None,
+                                  url_map=None):
+    if url_map:
+        url_map_name = url_map.name
+    else:
+        url_map_name = gcp.url_maps[0].name
     '''change url_map's backend service
 
     Only one of backend_service and service_with_weights can be not None.
@@ -2927,7 +2983,7 @@ def patch_url_map_backend_service(gcp,
     }
     logger.debug('Sending GCP request with body=%s', config)
     result = compute_to_use.urlMaps().patch(
-        project=gcp.project, urlMap=gcp.url_map.name,
+        project=gcp.project, urlMap=url_map_name,
         body=config).execute(num_retries=_GCP_API_RETRIES)
     wait_for_global_operation(gcp, result['name'])
 
@@ -3041,12 +3097,9 @@ def get_instance_names(gcp, instance_group):
 
 
 def clean_up(gcp):
-    if gcp.global_forwarding_rule:
-        delete_global_forwarding_rule(gcp)
-    if gcp.target_proxy:
-        delete_target_proxy(gcp)
-    if gcp.url_map:
-        delete_url_map(gcp)
+    delete_global_forwarding_rules(gcp)
+    delete_target_proxies(gcp)
+    delete_url_maps(gcp)
     delete_backend_services(gcp)
     if gcp.health_check_firewall_rule:
         delete_firewall(gcp)
@@ -3082,15 +3135,21 @@ class GcpState(object):
         self.health_check = None
         self.health_check_firewall_rule = None
         self.backend_services = []
-        self.url_map = None
-        self.target_proxy = None
-        self.global_forwarding_rule = None
+        self.url_maps = []
+        self.target_proxies = []
+        self.global_forwarding_rules = []
         self.service_port = None
         self.instance_template = None
         self.instance_groups = []
         self.errors = []
 
 
+logging.debug(
+    "script start time: %s",
+    datetime.datetime.now(
+        datetime.timezone.utc).astimezone().strftime("%Y-%m-%dT%H:%M:%S %Z"))
+logging.debug("logging local timezone: %s",
+              datetime.datetime.now(datetime.timezone.utc).astimezone().tzinfo)
 alpha_compute = None
 if args.compute_discovery_document:
     with open(args.compute_discovery_document, 'r') as discovery_doc:
@@ -3137,9 +3196,12 @@ try:
     extra_backend_service_name = _BASE_BACKEND_SERVICE_NAME + '-extra' + gcp_suffix
     more_extra_backend_service_name = _BASE_BACKEND_SERVICE_NAME + '-more-extra' + gcp_suffix
     url_map_name = _BASE_URL_MAP_NAME + gcp_suffix
+    url_map_name_2 = url_map_name + '2'
     service_host_name = _BASE_SERVICE_HOST + gcp_suffix
     target_proxy_name = _BASE_TARGET_PROXY_NAME + gcp_suffix
+    target_proxy_name_2 = target_proxy_name + '2'
     forwarding_rule_name = _BASE_FORWARDING_RULE_NAME + gcp_suffix
+    forwarding_rule_name_2 = forwarding_rule_name + '2'
     template_name = _BASE_TEMPLATE_NAME + gcp_suffix
     instance_group_name = _BASE_INSTANCE_GROUP_NAME + gcp_suffix
     same_zone_instance_group_name = _BASE_INSTANCE_GROUP_NAME + '-same-zone' + gcp_suffix
@@ -3161,6 +3223,11 @@ try:
         get_url_map(gcp, url_map_name)
         get_target_proxy(gcp, target_proxy_name)
         get_global_forwarding_rule(gcp, forwarding_rule_name)
+        get_url_map(gcp, url_map_name_2, record_error=False)
+        get_target_proxy(gcp, target_proxy_name_2, record_error=False)
+        get_global_forwarding_rule(gcp,
+                                   forwarding_rule_name_2,
+                                   record_error=False)
         get_instance_template(gcp, template_name)
         instance_group = get_instance_group(gcp, args.zone, instance_group_name)
         same_zone_instance_group = get_instance_group(
old mode 100644 (file)
new mode 100755 (executable)
similarity index 64%
rename from src/python/grpcio/grpc/_cython/_cygrpc/aio/iomgr/timer.pxd.pxi
rename to tools/run_tests/sanity/check_do_not_submit.sh
index 76c3be0..6e0438c
@@ -1,4 +1,5 @@
-# Copyright 2019 gRPC authors.
+#! /bin/bash
+# Copyright 2021 The gRPC Authors
 #
 # Licensed under the Apache License, Version 2.0 (the "License");
 # you may not use this file except in compliance with the License.
 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 # See the License for the specific language governing permissions and
 # limitations under the License.
+#
+# Checks if any file contains "DO NOT SUBMIT"
 
-cdef class _AsyncioTimer:
-    cdef:
-        grpc_custom_timer * _grpc_timer
-        object _timer_future
-        bint _active
-        object _loop
-
-    @staticmethod
-    cdef _AsyncioTimer create(grpc_custom_timer * grpc_timer, float timeout)
-
-    cdef stop(self)
+cd "$(dirname "$0")/../../.." || exit 1
+git grep -Irn 'DO NOT SUBMIT' -- \
+  './*' \
+  ':!*check_do_not_submit.sh' \
+  ':!third_party/'
+test $? -eq 1 || exit 1
diff --git a/tools/run_tests/sanity/check_include_style.py b/tools/run_tests/sanity/check_include_style.py
new file mode 100755 (executable)
index 0000000..602176b
--- /dev/null
@@ -0,0 +1,71 @@
+#!/usr/bin/env python3
+
+# Copyright 2021 gRPC authors.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+import os
+import re
+import sys
+
+os.chdir(os.path.join(os.path.dirname(sys.argv[0]), '../../..'))
+
+BAD_REGEXES = [
+    (r'\n#include "include/(.*)"', r'\n#include <\1>'),
+    (r'\n#include "grpc(.*)"', r'\n#include <grpc\1>'),
+]
+
+fix = sys.argv[1:] == ['--fix']
+if fix:
+    print("FIXING!")
+
+
+def check_include_style(directory_root):
+    bad_files = []
+    for root, dirs, files in os.walk(directory_root):
+        for filename in files:
+            path = os.path.join(root, filename)
+            if os.path.splitext(path)[1] not in ['.c', '.cc', '.h']:
+                continue
+            if filename.endswith('.pb.h') or filename.endswith('.pb.c'):
+                continue
+            # Skip check for upb generated code.
+            if (filename.endswith('.upb.h') or filename.endswith('.upb.c') or
+                    filename.endswith('.upbdefs.h') or
+                    filename.endswith('.upbdefs.c')):
+                continue
+            with open(path) as f:
+                text = f.read()
+            original = text
+            for regex, replace in BAD_REGEXES:
+                text = re.sub(regex, replace, text)
+            if text != original:
+                bad_files.append(path)
+                if fix:
+                    with open(path, 'w') as f:
+                        f.write(text)
+    return bad_files
+
+
+all_bad_files = []
+all_bad_files += check_include_style(os.path.join('src', 'core'))
+all_bad_files += check_include_style(os.path.join('src', 'cpp'))
+all_bad_files += check_include_style(os.path.join('test', 'core'))
+all_bad_files += check_include_style(os.path.join('test', 'cpp'))
+all_bad_files += check_include_style(os.path.join('include', 'grpc'))
+all_bad_files += check_include_style(os.path.join('include', 'grpcpp'))
+
+if all_bad_files:
+    for f in all_bad_files:
+        print("%s has badly formed grpc system header files" % f)
+    sys.exit(1)
index a9d7340..a01e309 100755 (executable)
@@ -29,15 +29,15 @@ cat << EOF | sort > "$want_submodules"
 third_party/abseil-cpp 997aaf3a28308eba1b9156aa35ab7bca9688e9f6
 third_party/benchmark 73d4d5e8d6d449fc8663765a42aa8aeeee844489
 third_party/bloaty 73594cde8c9a52a102c4341c244c833aa61b9c06
-third_party/boringssl-with-bazel bcc01b6c66b1c6fa2816b108e50a544b757fbd7b
+third_party/boringssl-with-bazel fc44652a42b396e1645d5e72aba053349992136a
 third_party/cares/cares e982924acee7f7313b4baa4ee5ec000c5e373c30
-third_party/envoy-api df3b1ab2773147f292c4f175f790c35448328161
+third_party/envoy-api 2f0d081fab0b0823f088c6e368f40e1992f46fcd
 third_party/googleapis 2f9af297c84c55c8b871ba4495e01ade42476c92
 third_party/googletest c9ccac7cb7345901884aabf5d1a786cfa6e2f397
 third_party/libuv 15ae750151ac9341e5945eb38f8982d59fb99201
 third_party/opencensus-proto 4aa53e15cbf1a47bc9087e6cfdca214c1eea4e89
 third_party/opentelemetry 60fa8754d890b5c55949a8c68dcfd7ab5c2395df
-third_party/protobuf 436bd7880e458532901c58f4d9d1ea23fa7edd52
+third_party/protobuf 909a0f36a10075c4b4bc70fdee2c7e32dd612a72
 third_party/protoc-gen-validate 59da36e59fef2267fc2b1849a05159e3ecdf24f3
 third_party/re2 aecba11114cf1fac5497aeb844b6966106de3eb6
 third_party/udpa 6414d713912e988471d192940b62bf552b11793a
index f7cd252..9d8d50c 100644 (file)
@@ -4,9 +4,11 @@
 - script: tools/run_tests/sanity/check_buildifier.sh
 - script: tools/run_tests/sanity/check_cache_mk.sh
 - script: tools/run_tests/sanity/check_deprecated_grpc++.py
+- script: tools/run_tests/sanity/check_do_not_submit.sh
 - script: tools/run_tests/sanity/check_illegal_terms.sh
 - script: tools/run_tests/sanity/check_owners.sh
 - script: tools/run_tests/sanity/check_port_platform.py
+- script: tools/run_tests/sanity/check_include_style.py
 - script: tools/run_tests/sanity/check_qps_scenario_changes.py
 - script: tools/run_tests/sanity/check_shellcheck.sh
 - script: tools/run_tests/sanity/check_submodules.sh
index 28ddab7..5d34464 100644 (file)
@@ -62,14 +62,20 @@ export WORKLOAD_SA_EMAIL="${WORKLOAD_SA_NAME}@${PROJECT_ID}.iam.gserviceaccount.
 Minimal requirements: [VPC-native](https://cloud.google.com/traffic-director/docs/security-proxyless-setup)
 cluster with [Workload Identity](https://cloud.google.com/kubernetes-engine/docs/how-to/workload-identity) enabled. 
 ```shell
-gcloud beta container clusters create "${CLUSTER_NAME}" \
+gcloud container clusters create "${CLUSTER_NAME}" \
+ --scopes=cloud-platform \
  --zone="${ZONE}" \
  --enable-ip-alias \
  --workload-pool="${PROJECT_ID}.svc.id.goog" \
+ --enable-workload-certificates \
  --workload-metadata=GKE_METADATA \
  --tags=allow-health-checks
 ```
 
+For security tests you also need to create CAs and configure the cluster to use those CAs
+as described
+[here](https://cloud.google.com/traffic-director/docs/security-proxyless-setup#configure-cas).
+
 ##### Create the firewall rule
 Allow [health checking mechanisms](https://cloud.google.com/traffic-director/docs/set-up-proxyless-gke#creating_the_health_check_firewall_rule_and_backend_service)
 to query the workloads health.  
@@ -95,10 +101,21 @@ gcloud iam service-accounts create "${WORKLOAD_SA_NAME}" \
 Enable the service account to [access the Traffic Director API](https://cloud.google.com/traffic-director/docs/prepare-for-envoy-setup#enable-service-account).
 ```shell
 gcloud projects add-iam-policy-binding "${PROJECT_ID}" \
-   --member="serviceAccount:${WORKLOAD_SERVICE_ACCOUNT}" \
+   --member="serviceAccount:${WORKLOAD_SA_EMAIL}" \
    --role="roles/trafficdirector.client"
 ```
 
+##### Allow access to images
+The test framework needs read access to the client and server images and the bootstrap
+generator image. You may have these images in your project but if you want to use these
+from the grpc-testing project you will have to grant the necessary access to these images
+using https://cloud.google.com/container-registry/docs/access-control#grant or a
+gsutil command. For example, to grant access to images stored in `grpc-testing` project GCR, run:
+
+```sh
+gsutil iam ch "serviceAccount:${GCE_SA}:objectViewer" gs://artifacts.grpc-testing.appspot.com/
+```
+
 ##### Allow test driver to configure workload identity automatically
 Test driver will automatically grant `roles/iam.workloadIdentityUser` to 
 allow the Kubernetes service account to impersonate the dedicated GCP workload
index 688b1c3..5a31dae 100644 (file)
@@ -6,3 +6,7 @@
 # 2. All UrlMap tests today are testing client-side logic.
 # grpc-java master: 438f8d9e7880b2f6ae2b376a35a9f5f32b4dbeaa TODO: use v1.40.0
 --server_image=gcr.io/grpc-testing/xds-interop/java-server:438f8d9e7880b2f6ae2b376a35a9f5f32b4dbeaa
+# Disables the GCP Workload Identity feature to simplify permission control
+--gcp_service_account=None
+--private_api_key_secret_name=None
+--noenable_workload_identity
index c5184a8..c9e18c7 100644 (file)
@@ -21,7 +21,9 @@ from absl import flags
 from google.cloud import secretmanager_v1
 from google.longrunning import operations_pb2
 from google.protobuf import json_format
+from google.protobuf import text_format
 from google.rpc import code_pb2
+from google.rpc import error_details_pb2
 from googleapiclient import discovery
 import googleapiclient.errors
 import googleapiclient.http
@@ -125,6 +127,8 @@ class GcpApiManager:
                 version,
                 api_key=self.private_api_key,
                 visibility_labels=['NETWORKSECURITY_ALPHA'])
+        elif version == 'v1beta1':
+            return self._build_from_discovery_v2(api_name, version)
 
         raise NotImplementedError(f'Network Security {version} not supported')
 
@@ -137,6 +141,8 @@ class GcpApiManager:
                 version,
                 api_key=self.private_api_key,
                 visibility_labels=['NETWORKSERVICES_ALPHA'])
+        elif version == 'v1beta1':
+            return self._build_from_discovery_v2(api_name, version)
 
         raise NotImplementedError(f'Network Services {version} not supported')
 
@@ -255,14 +261,24 @@ class OperationError(Error):
 
     def __init__(self, api_name, operation_response, message=None):
         self.api_name = api_name
-        operation = json_format.ParseDict(operation_response, Operation())
+        operation = json_format.ParseDict(
+            operation_response,
+            Operation(),
+            ignore_unknown_fields=True,
+            descriptor_pool=error_details_pb2.DESCRIPTOR.pool)
         self.name = operation.name or 'unknown'
-        self.error = operation.error
         self.code_name = code_pb2.Code.Name(operation.error.code)
+        self.error = operation.error
+        # Collect error details packed as Any without parsing concrete types.
+        self.error_details = [
+            text_format.MessageToString(any_error, as_one_line=True)
+            for any_error in self.error.details
+        ]
         if message is None:
             message = (f'{api_name} operation "{self.name}" failed. Error '
                        f'code: {self.error.code} ({self.code_name}), '
-                       f'message: {self.error.message}')
+                       f'message: {self.error.message}, '
+                       f'details: {self.error_details}')
         self.message = message
         super().__init__(message)
 
index 8d128ef..c17f4c7 100644 (file)
@@ -113,7 +113,8 @@ class ComputeV1(gcp.api.GcpProjectApiResource):
             name: str,
             health_check: GcpResource,
             affinity_header: str = None,
-            protocol: Optional[BackendServiceProtocol] = None) -> GcpResource:
+            protocol: Optional[BackendServiceProtocol] = None,
+            subset_size: Optional[int] = None) -> GcpResource:
         if not isinstance(protocol, self.BackendServiceProtocol):
             raise TypeError(f'Unexpected Backend Service protocol: {protocol}')
         body = {
@@ -130,6 +131,11 @@ class ComputeV1(gcp.api.GcpProjectApiResource):
             body['consistentHash'] = {
                 'httpHeaderName': affinity_header,
             }
+        if subset_size:
+            body['subsetting'] = {
+                'policy': 'CONSISTENT_HASH_SUBSETTING',
+                'subsetSize': subset_size
+            }
         return self._insert_resource(self.api.backendServices(), body)
 
     def get_backend_service_traffic_director(self, name: str) -> GcpResource:
index 9d93cc0..e97b177 100644 (file)
 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 # See the License for the specific language governing permissions and
 # limitations under the License.
+
+import abc
 import dataclasses
 import logging
+from typing import Any, Dict
 
 from google.rpc import code_pb2
 import tenacity
@@ -21,28 +24,53 @@ from framework.infrastructure import gcp
 
 logger = logging.getLogger(__name__)
 
-
-class NetworkSecurityV1Alpha1(gcp.api.GcpStandardCloudApiResource):
-    SERVER_TLS_POLICIES = 'serverTlsPolicies'
-    CLIENT_TLS_POLICIES = 'clientTlsPolicies'
-
-    @dataclasses.dataclass(frozen=True)
-    class ServerTlsPolicy:
-        url: str
-        name: str
-        server_certificate: dict
-        mtls_policy: dict
-        update_time: str
-        create_time: str
-
-    @dataclasses.dataclass(frozen=True)
-    class ClientTlsPolicy:
-        url: str
-        name: str
-        client_certificate: dict
-        server_validation_ca: list
-        update_time: str
-        create_time: str
+# Type aliases
+GcpResource = gcp.compute.ComputeV1.GcpResource
+
+
+@dataclasses.dataclass(frozen=True)
+class ServerTlsPolicy:
+    url: str
+    name: str
+    server_certificate: dict
+    mtls_policy: dict
+    update_time: str
+    create_time: str
+
+    @classmethod
+    def from_response(cls, name: str, response: Dict[str,
+                                                     Any]) -> 'ServerTlsPolicy':
+        return cls(name=name,
+                   url=response['name'],
+                   server_certificate=response.get('serverCertificate', {}),
+                   mtls_policy=response.get('mtlsPolicy', {}),
+                   create_time=response['createTime'],
+                   update_time=response['updateTime'])
+
+
+@dataclasses.dataclass(frozen=True)
+class ClientTlsPolicy:
+    url: str
+    name: str
+    client_certificate: dict
+    server_validation_ca: list
+    update_time: str
+    create_time: str
+
+    @classmethod
+    def from_response(cls, name: str, response: Dict[str,
+                                                     Any]) -> 'ClientTlsPolicy':
+        return cls(name=name,
+                   url=response['name'],
+                   client_certificate=response.get('clientCertificate', {}),
+                   server_validation_ca=response.get('serverValidationCa', []),
+                   create_time=response['createTime'],
+                   update_time=response['updateTime'])
+
+
+class _NetworkSecurityBase(gcp.api.GcpStandardCloudApiResource,
+                           metaclass=abc.ABCMeta):
+    """Base class for NetworkSecurity APIs."""
 
     def __init__(self, api_manager: gcp.api.GcpApiManager, project: str):
         super().__init__(api_manager.networksecurity(self.api_version), project)
@@ -53,68 +81,76 @@ class NetworkSecurityV1Alpha1(gcp.api.GcpStandardCloudApiResource):
     def api_name(self) -> str:
         return 'networksecurity'
 
+    def _execute(self, *args, **kwargs):  # pylint: disable=signature-differs
+        # Workaround TD bug: throttled operations are reported as internal.
+        # Ref b/175345578
+        retryer = tenacity.Retrying(
+            retry=tenacity.retry_if_exception(self._operation_internal_error),
+            wait=tenacity.wait_fixed(10),
+            stop=tenacity.stop_after_delay(5 * 60),
+            before_sleep=tenacity.before_sleep_log(logger, logging.DEBUG),
+            reraise=True)
+        retryer(super()._execute, *args, **kwargs)
+
+    @staticmethod
+    def _operation_internal_error(exception):
+        return (isinstance(exception, gcp.api.OperationError) and
+                exception.error.code == code_pb2.INTERNAL)
+
+
+class NetworkSecurityV1Beta1(_NetworkSecurityBase):
+    """NetworkSecurity API v1beta1."""
+
+    SERVER_TLS_POLICIES = 'serverTlsPolicies'
+    CLIENT_TLS_POLICIES = 'clientTlsPolicies'
+
     @property
     def api_version(self) -> str:
-        return 'v1alpha1'
+        return 'v1beta1'
 
-    def create_server_tls_policy(self, name, body: dict):
-        return self._create_resource(self._api_locations.serverTlsPolicies(),
-                                     body,
-                                     serverTlsPolicyId=name)
+    def create_server_tls_policy(self, name: str, body: dict) -> GcpResource:
+        return self._create_resource(
+            collection=self._api_locations.serverTlsPolicies(),
+            body=body,
+            serverTlsPolicyId=name)
 
     def get_server_tls_policy(self, name: str) -> ServerTlsPolicy:
-        result = self._get_resource(
+        response = self._get_resource(
             collection=self._api_locations.serverTlsPolicies(),
             full_name=self.resource_full_name(name, self.SERVER_TLS_POLICIES))
+        return ServerTlsPolicy.from_response(name, response)
 
-        return self.ServerTlsPolicy(name=name,
-                                    url=result['name'],
-                                    server_certificate=result.get(
-                                        'serverCertificate', {}),
-                                    mtls_policy=result.get('mtlsPolicy', {}),
-                                    create_time=result['createTime'],
-                                    update_time=result['updateTime'])
-
-    def delete_server_tls_policy(self, name):
+    def delete_server_tls_policy(self, name: str) -> bool:
         return self._delete_resource(
             collection=self._api_locations.serverTlsPolicies(),
             full_name=self.resource_full_name(name, self.SERVER_TLS_POLICIES))
 
-    def create_client_tls_policy(self, name, body: dict):
-        return self._create_resource(self._api_locations.clientTlsPolicies(),
-                                     body,
-                                     clientTlsPolicyId=name)
+    def create_client_tls_policy(self, name: str, body: dict) -> GcpResource:
+        return self._create_resource(
+            collection=self._api_locations.clientTlsPolicies(),
+            body=body,
+            clientTlsPolicyId=name)
 
     def get_client_tls_policy(self, name: str) -> ClientTlsPolicy:
-        result = self._get_resource(
+        response = self._get_resource(
             collection=self._api_locations.clientTlsPolicies(),
             full_name=self.resource_full_name(name, self.CLIENT_TLS_POLICIES))
+        return ClientTlsPolicy.from_response(name, response)
 
-        return self.ClientTlsPolicy(
-            name=name,
-            url=result['name'],
-            client_certificate=result.get('clientCertificate', {}),
-            server_validation_ca=result.get('serverValidationCa', []),
-            create_time=result['createTime'],
-            update_time=result['updateTime'])
-
-    def delete_client_tls_policy(self, name):
+    def delete_client_tls_policy(self, name: str) -> bool:
         return self._delete_resource(
             collection=self._api_locations.clientTlsPolicies(),
             full_name=self.resource_full_name(name, self.CLIENT_TLS_POLICIES))
 
-    def _execute(self, *args, **kwargs):  # pylint: disable=signature-differs
-        # Workaround TD bug: throttled operations are reported as internal.
-        # Ref b/175345578
-        retryer = tenacity.Retrying(
-            retry=tenacity.retry_if_exception(self._operation_internal_error),
-            wait=tenacity.wait_fixed(10),
-            stop=tenacity.stop_after_delay(5 * 60),
-            before_sleep=tenacity.before_sleep_log(logger, logging.DEBUG),
-            reraise=True)
-        retryer(super()._execute, *args, **kwargs)
 
-    @staticmethod
-    def _operation_internal_error(exception):
-        return (isinstance(exception, gcp.api.OperationError) and
-                exception.error.code == code_pb2.INTERNAL)
+class NetworkSecurityV1Alpha1(NetworkSecurityV1Beta1):
+    """NetworkSecurity API v1alpha1.
+
+    Note: extending v1beta1 class presumes that v1beta1 is just a v1alpha1 API
+    graduated into a more stable version. This is true in most cases. However,
+    v1alpha1 class can always override and reimplement incompatible methods.
+    """
+
+    @property
+    def api_version(self) -> str:
+        return 'v1alpha1'
index 0174336..59cd565 100644 (file)
@@ -12,6 +12,7 @@
 # See the License for the specific language governing permissions and
 # limitations under the License.
 
+import abc
 import dataclasses
 import logging
 from typing import Any, Dict, List, Optional, Tuple
@@ -23,8 +24,34 @@ from framework.infrastructure import gcp
 
 logger = logging.getLogger(__name__)
 
-_ComputeV1 = gcp.compute.ComputeV1
-GcpResource = _ComputeV1.GcpResource
+# Type aliases
+GcpResource = gcp.compute.ComputeV1.GcpResource
+
+
+@dataclasses.dataclass(frozen=True)
+class EndpointPolicy:
+    url: str
+    name: str
+    type: str
+    traffic_port_selector: dict
+    endpoint_matcher: dict
+    update_time: str
+    create_time: str
+    http_filters: Optional[dict] = None
+    server_tls_policy: Optional[str] = None
+
+    @classmethod
+    def from_response(cls, name: str, response: Dict[str,
+                                                     Any]) -> 'EndpointPolicy':
+        return cls(name=name,
+                   url=response['name'],
+                   type=response['type'],
+                   server_tls_policy=response.get('serverTlsPolicy', None),
+                   traffic_port_selector=response['trafficPortSelector'],
+                   endpoint_matcher=response['endpointMatcher'],
+                   http_filters=response.get('httpFilters', None),
+                   update_time=response['updateTime'],
+                   create_time=response['createTime'])
 
 
 @dataclasses.dataclass(frozen=True)
@@ -148,22 +175,9 @@ class GrpcRoute:
         )
 
 
-class NetworkServicesV1Alpha1(gcp.api.GcpStandardCloudApiResource):
-    ENDPOINT_CONFIG_SELECTORS = 'endpointConfigSelectors'
-    GRPC_ROUTES = 'grpcRoutes'
-    ROUTERS = 'routers'
-
-    @dataclasses.dataclass(frozen=True)
-    class EndpointConfigSelector:
-        url: str
-        name: str
-        type: str
-        server_tls_policy: Optional[str]
-        traffic_port_selector: dict
-        endpoint_matcher: dict
-        http_filters: dict
-        update_time: str
-        create_time: str
+class _NetworkServicesBase(gcp.api.GcpStandardCloudApiResource,
+                           metaclass=abc.ABCMeta):
+    """Base class for NetworkServices APIs."""
 
     def __init__(self, api_manager: gcp.api.GcpApiManager, project: str):
         super().__init__(api_manager.networkservices(self.api_version), project)
@@ -174,38 +188,6 @@ class NetworkServicesV1Alpha1(gcp.api.GcpStandardCloudApiResource):
     def api_name(self) -> str:
         return 'networkservices'
 
-    @property
-    def api_version(self) -> str:
-        return 'v1alpha1'
-
-    def create_endpoint_config_selector(self, name, body: dict):
-        return self._create_resource(
-            self._api_locations.endpointConfigSelectors(),
-            body,
-            endpointConfigSelectorId=name)
-
-    def get_endpoint_config_selector(self, name: str) -> EndpointConfigSelector:
-        result = self._get_resource(
-            collection=self._api_locations.endpointConfigSelectors(),
-            full_name=self.resource_full_name(name,
-                                              self.ENDPOINT_CONFIG_SELECTORS))
-        return self.EndpointConfigSelector(
-            name=name,
-            url=result['name'],
-            type=result['type'],
-            server_tls_policy=result.get('serverTlsPolicy', None),
-            traffic_port_selector=result['trafficPortSelector'],
-            endpoint_matcher=result['endpointMatcher'],
-            http_filters=result['httpFilters'],
-            update_time=result['updateTime'],
-            create_time=result['createTime'])
-
-    def delete_endpoint_config_selector(self, name):
-        return self._delete_resource(
-            collection=self._api_locations.endpointConfigSelectors(),
-            full_name=self.resource_full_name(name,
-                                              self.ENDPOINT_CONFIG_SELECTORS))
-
     def _execute(self, *args, **kwargs):  # pylint: disable=signature-differs
         # Workaround TD bug: throttled operations are reported as internal.
         # Ref b/175345578
@@ -217,17 +199,62 @@ class NetworkServicesV1Alpha1(gcp.api.GcpStandardCloudApiResource):
             reraise=True)
         retryer(super()._execute, *args, **kwargs)
 
-    def create_router(self, name: str, body: dict) -> GcpResource:
+    @staticmethod
+    def _operation_internal_error(exception):
+        return (isinstance(exception, gcp.api.OperationError) and
+                exception.error.code == code_pb2.INTERNAL)
+
+
+class NetworkServicesV1Beta1(_NetworkServicesBase):
+    """NetworkServices API v1beta1."""
+    ENDPOINT_POLICIES = 'endpointPolicies'
+
+    @property
+    def api_version(self) -> str:
+        return 'v1beta1'
+
+    def create_endpoint_policy(self, name, body: dict) -> GcpResource:
         return self._create_resource(
-            self._api_locations.routers(),
-            body,
-            routerId=name,
-        )
+            collection=self._api_locations.endpointPolicies(),
+            body=body,
+            endpointPolicyId=name)
+
+    def get_endpoint_policy(self, name: str) -> EndpointPolicy:
+        response = self._get_resource(
+            collection=self._api_locations.endpointPolicies(),
+            full_name=self.resource_full_name(name, self.ENDPOINT_POLICIES))
+        return EndpointPolicy.from_response(name, response)
+
+    def delete_endpoint_policy(self, name: str) -> bool:
+        return self._delete_resource(
+            collection=self._api_locations.endpointPolicies(),
+            full_name=self.resource_full_name(name, self.ENDPOINT_POLICIES))
+
+
+class NetworkServicesV1Alpha1(NetworkServicesV1Beta1):
+    """NetworkServices API v1alpha1.
+
+    Note: extending v1beta1 class presumes that v1beta1 is just a v1alpha1 API
+    graduated into a more stable version. This is true in most cases. However,
+    v1alpha1 class can always override and reimplement incompatible methods.
+    """
+
+    GRPC_ROUTES = 'grpcRoutes'
+    ROUTERS = 'routers'
+
+    @property
+    def api_version(self) -> str:
+        return 'v1alpha1'
+
+    def create_router(self, name: str, body: dict) -> GcpResource:
+        return self._create_resource(collection=self._api_locations.routers(),
+                                     body=body,
+                                     routerId=name)
 
     def get_router(self, name: str) -> Router:
+        full_name = self.resource_full_name(name, self.ROUTERS)
         result = self._get_resource(collection=self._api_locations.routers(),
-                                    full_name=self.resource_full_name(
-                                        name, self.ROUTERS))
+                                    full_name=full_name)
         return Router.from_response(name, result)
 
     def delete_router(self, name: str) -> bool:
@@ -236,22 +263,18 @@ class NetworkServicesV1Alpha1(gcp.api.GcpStandardCloudApiResource):
                                          name, self.ROUTERS))
 
     def create_grpc_route(self, name: str, body: dict) -> GcpResource:
-        return self._create_resource(self._api_locations.grpcRoutes(),
-                                     body,
-                                     grpcRouteId=name)
+        return self._create_resource(
+            collection=self._api_locations.grpcRoutes(),
+            body=body,
+            grpcRouteId=name)
 
     def get_grpc_route(self, name: str) -> GrpcRoute:
+        full_name = self.resource_full_name(name, self.GRPC_ROUTES)
         result = self._get_resource(collection=self._api_locations.grpcRoutes(),
-                                    full_name=self.resource_full_name(
-                                        name, self.GRPC_ROUTES))
+                                    full_name=full_name)
         return GrpcRoute.from_response(name, result)
 
     def delete_grpc_route(self, name: str) -> bool:
         return self._delete_resource(
             collection=self._api_locations.grpcRoutes(),
             full_name=self.resource_full_name(name, self.GRPC_ROUTES))
-
-    @staticmethod
-    def _operation_internal_error(exception):
-        return (isinstance(exception, gcp.api.OperationError) and
-                exception.error.code == code_pb2.INTERNAL)
index ebbc06e..326b23d 100644 (file)
@@ -14,7 +14,7 @@
 import functools
 import logging
 import random
-from typing import Any, Dict, Iterable, List, Optional, Set
+from typing import Any, Dict, List, Optional, Set
 
 from framework import xds_flags
 from framework.infrastructure import gcp
@@ -32,13 +32,14 @@ _BackendGRPC = BackendServiceProtocol.GRPC
 _HealthCheckGRPC = HealthCheckProtocol.GRPC
 
 # Network Security
-_NetworkSecurityV1Alpha1 = gcp.network_security.NetworkSecurityV1Alpha1
-ServerTlsPolicy = _NetworkSecurityV1Alpha1.ServerTlsPolicy
-ClientTlsPolicy = _NetworkSecurityV1Alpha1.ClientTlsPolicy
+_NetworkSecurityV1Beta1 = gcp.network_security.NetworkSecurityV1Beta1
+ServerTlsPolicy = gcp.network_security.ServerTlsPolicy
+ClientTlsPolicy = gcp.network_security.ClientTlsPolicy
 
 # Network Services
 _NetworkServicesV1Alpha1 = gcp.network_services.NetworkServicesV1Alpha1
-EndpointConfigSelector = _NetworkServicesV1Alpha1.EndpointConfigSelector
+_NetworkServicesV1Beta1 = gcp.network_services.NetworkServicesV1Beta1
+EndpointPolicy = gcp.network_services.EndpointPolicy
 
 # Testing metadata consts
 TEST_AFFINITY_METADATA_KEY = 'xds_md'
@@ -176,14 +177,21 @@ class TrafficDirectorManager:
         self.health_check = None
 
     def create_backend_service(
-            self, protocol: Optional[BackendServiceProtocol] = _BackendGRPC):
+            self,
+            protocol: Optional[BackendServiceProtocol] = _BackendGRPC,
+            subset_size: Optional[int] = None,
+            affinity_header: Optional[str] = None):
         if protocol is None:
             protocol = _BackendGRPC
 
         name = self.make_resource_name(self.BACKEND_SERVICE_NAME)
         logger.info('Creating %s Backend Service "%s"', protocol.name, name)
         resource = self.compute.create_backend_service_traffic_director(
-            name, health_check=self.health_check, protocol=protocol)
+            name,
+            health_check=self.health_check,
+            protocol=protocol,
+            subset_size=subset_size,
+            affinity_header=affinity_header)
         self.backend_service = resource
         self.backend_service_protocol = protocol
 
@@ -537,6 +545,8 @@ class TrafficDirectorAppNetManager(TrafficDirectorManager):
     GRPC_ROUTE_NAME = "grpc-route"
     ROUTER_NAME = "router"
 
+    netsvc: _NetworkServicesV1Alpha1
+
     def __init__(self,
                  gcp_api_manager: gcp.api.GcpApiManager,
                  project: str,
@@ -627,13 +637,14 @@ class TrafficDirectorAppNetManager(TrafficDirectorManager):
 
 
 class TrafficDirectorSecureManager(TrafficDirectorManager):
-    netsec: Optional[_NetworkSecurityV1Alpha1]
     SERVER_TLS_POLICY_NAME = "server-tls-policy"
     CLIENT_TLS_POLICY_NAME = "client-tls-policy"
-    # TODO(sergiitk): Rename to ENDPOINT_POLICY_NAME when upgraded to v1beta
-    ENDPOINT_CONFIG_SELECTOR_NAME = "endpoint-policy"
+    ENDPOINT_POLICY = "endpoint-policy"
     CERTIFICATE_PROVIDER_INSTANCE = "google_cloud_private_spiffe"
 
+    netsec: _NetworkSecurityV1Beta1
+    netsvc: _NetworkServicesV1Beta1
+
     def __init__(
         self,
         gcp_api_manager: gcp.api.GcpApiManager,
@@ -650,13 +661,13 @@ class TrafficDirectorSecureManager(TrafficDirectorManager):
                          network=network)
 
         # API
-        self.netsec = _NetworkSecurityV1Alpha1(gcp_api_manager, project)
-        self.netsvc = _NetworkServicesV1Alpha1(gcp_api_manager, project)
+        self.netsec = _NetworkSecurityV1Beta1(gcp_api_manager, project)
+        self.netsvc = _NetworkServicesV1Beta1(gcp_api_manager, project)
 
         # Managed resources
         self.server_tls_policy: Optional[ServerTlsPolicy] = None
-        self.ecs: Optional[EndpointConfigSelector] = None
         self.client_tls_policy: Optional[ClientTlsPolicy] = None
+        self.endpoint_policy: Optional[EndpointPolicy] = None
 
     def setup_server_security(self,
                               *,
@@ -666,9 +677,9 @@ class TrafficDirectorSecureManager(TrafficDirectorManager):
                               tls=True,
                               mtls=True):
         self.create_server_tls_policy(tls=tls, mtls=mtls)
-        self.create_endpoint_config_selector(server_namespace=server_namespace,
-                                             server_name=server_name,
-                                             server_port=server_port)
+        self.create_endpoint_policy(server_namespace=server_namespace,
+                                    server_name=server_name,
+                                    server_port=server_port)
 
     def setup_client_security(self,
                               *,
@@ -683,7 +694,7 @@ class TrafficDirectorSecureManager(TrafficDirectorManager):
     def cleanup(self, *, force=False):
         # Cleanup in the reverse order of creation
         super().cleanup(force=force)
-        self.delete_endpoint_config_selector(force=force)
+        self.delete_endpoint_policy(force=force)
         self.delete_server_tls_policy(force=force)
         self.delete_client_tls_policy(force=force)
 
@@ -720,10 +731,10 @@ class TrafficDirectorSecureManager(TrafficDirectorManager):
         self.netsec.delete_server_tls_policy(name)
         self.server_tls_policy = None
 
-    def create_endpoint_config_selector(self, server_namespace, server_name,
-                                        server_port):
-        name = self.make_resource_name(self.ENDPOINT_CONFIG_SELECTOR_NAME)
-        logger.info('Creating Endpoint Config Selector %s', name)
+    def create_endpoint_policy(self, *, server_namespace: str, server_name: str,
+                               server_port: int) -> None:
+        name = self.make_resource_name(self.ENDPOINT_POLICY)
+        logger.info('Creating Endpoint Policy %s', name)
         endpoint_matcher_labels = [{
             "labelName": "app",
             "labelValue": f"{server_namespace}-{server_name}"
@@ -731,37 +742,36 @@ class TrafficDirectorSecureManager(TrafficDirectorManager):
         port_selector = {"ports": [str(server_port)]}
         label_matcher_all = {
             "metadataLabelMatchCriteria": "MATCH_ALL",
-            "metadataLabels": endpoint_matcher_labels
+            "metadataLabels": endpoint_matcher_labels,
         }
         config = {
             "type": "GRPC_SERVER",
-            "httpFilters": {},
             "trafficPortSelector": port_selector,
             "endpointMatcher": {
-                "metadataLabelMatcher": label_matcher_all
+                "metadataLabelMatcher": label_matcher_all,
             },
         }
         if self.server_tls_policy:
             config["serverTlsPolicy"] = self.server_tls_policy.name
         else:
             logger.warning(
-                'Creating Endpoint Config Selector %s with '
+                'Creating Endpoint Policy %s with '
                 'no Server TLS policy attached', name)
 
-        self.netsvc.create_endpoint_config_selector(name, config)
-        self.ecs = self.netsvc.get_endpoint_config_selector(name)
-        logger.debug('Loaded Endpoint Config Selector: %r', self.ecs)
+        self.netsvc.create_endpoint_policy(name, config)
+        self.endpoint_policy = self.netsvc.get_endpoint_policy(name)
+        logger.debug('Loaded Endpoint Policy: %r', self.endpoint_policy)
 
-    def delete_endpoint_config_selector(self, force=False):
+    def delete_endpoint_policy(self, force: bool = False) -> None:
         if force:
-            name = self.make_resource_name(self.ENDPOINT_CONFIG_SELECTOR_NAME)
-        elif self.ecs:
-            name = self.ecs.name
+            name = self.make_resource_name(self.ENDPOINT_POLICY)
+        elif self.endpoint_policy:
+            name = self.endpoint_policy.name
         else:
             return
-        logger.info('Deleting Endpoint Config Selector %s', name)
-        self.netsvc.delete_endpoint_config_selector(name)
-        self.ecs = None
+        logger.info('Deleting Endpoint Policy %s', name)
+        self.netsvc.delete_endpoint_policy(name)
+        self.endpoint_policy = None
 
     def create_client_tls_policy(self, *, tls, mtls):
         name = self.make_resource_name(self.CLIENT_TLS_POLICY_NAME)
index 9a30dca..9645db9 100644 (file)
@@ -244,7 +244,8 @@ class KubernetesClientRunner(base_runner.KubernetesBaseRunner):
                  service_account_template='service-account.yaml',
                  reuse_namespace=False,
                  namespace_template=None,
-                 debug_use_port_forwarding=False):
+                 debug_use_port_forwarding=False,
+                 enable_workload_identity=True):
         super().__init__(k8s_namespace, namespace_template, reuse_namespace)
 
         # Settings
@@ -257,10 +258,15 @@ class KubernetesClientRunner(base_runner.KubernetesBaseRunner):
         self.network = network
         self.deployment_template = deployment_template
         self.debug_use_port_forwarding = debug_use_port_forwarding
+        self.enable_workload_identity = enable_workload_identity
         # Service account settings:
         # Kubernetes service account
-        self.service_account_name = service_account_name or deployment_name
-        self.service_account_template = service_account_template
+        if self.enable_workload_identity:
+            self.service_account_name = service_account_name or deployment_name
+            self.service_account_template = service_account_template
+        else:
+            self.service_account_name = None
+            self.service_account_template = None
         # GCP.
         self.gcp_project = gcp_project
         self.gcp_ui_url = gcp_api_manager.gcp_ui_url
@@ -296,19 +302,20 @@ class KubernetesClientRunner(base_runner.KubernetesBaseRunner):
 
         super().run()
 
-        # Allow Kubernetes service account to use the GCP service account
-        # identity.
-        self._grant_workload_identity_user(
-            gcp_iam=self.gcp_iam,
-            gcp_service_account=self.gcp_service_account,
-            service_account_name=self.service_account_name)
+        if self.enable_workload_identity:
+            # Allow Kubernetes service account to use the GCP service account
+            # identity.
+            self._grant_workload_identity_user(
+                gcp_iam=self.gcp_iam,
+                gcp_service_account=self.gcp_service_account,
+                service_account_name=self.service_account_name)
 
-        # Create service account
-        self.service_account = self._create_service_account(
-            self.service_account_template,
-            service_account_name=self.service_account_name,
-            namespace_name=self.k8s_namespace.name,
-            gcp_service_account=self.gcp_service_account)
+            # Create service account
+            self.service_account = self._create_service_account(
+                self.service_account_template,
+                service_account_name=self.service_account_name,
+                namespace_name=self.k8s_namespace.name,
+                gcp_service_account=self.gcp_service_account)
 
         # Always create a new deployment
         self.deployment = self._create_deployment(
@@ -356,7 +363,7 @@ class KubernetesClientRunner(base_runner.KubernetesBaseRunner):
         if self.deployment or force:
             self._delete_deployment(self.deployment_name)
             self.deployment = None
-        if self.service_account or force:
+        if self.enable_workload_identity and (self.service_account or force):
             self._revoke_workload_identity_user(
                 gcp_iam=self.gcp_iam,
                 gcp_service_account=self.gcp_service_account,
index 7fec8f1..bc2e092 100644 (file)
@@ -181,7 +181,8 @@ class KubernetesServerRunner(base_runner.KubernetesBaseRunner):
                  reuse_service=False,
                  reuse_namespace=False,
                  namespace_template=None,
-                 debug_use_port_forwarding=False):
+                 debug_use_port_forwarding=False,
+                 enable_workload_identity=True):
         super().__init__(k8s_namespace, namespace_template, reuse_namespace)
 
         # Settings
@@ -200,10 +201,16 @@ class KubernetesServerRunner(base_runner.KubernetesBaseRunner):
         self.service_template = service_template
         self.reuse_service = reuse_service
         self.debug_use_port_forwarding = debug_use_port_forwarding
+        self.enable_workload_identity = enable_workload_identity
         # Service account settings:
         # Kubernetes service account
-        self.service_account_name = service_account_name or deployment_name
-        self.service_account_template = service_account_template
+        if self.enable_workload_identity:
+            self.service_account_name = service_account_name or deployment_name
+            self.service_account_template = service_account_template
+        else:
+            self.service_account_name = None
+            self.service_account_template = None
+
         # GCP.
         self.gcp_project = gcp_project
         self.gcp_ui_url = gcp_api_manager.gcp_ui_url
@@ -244,6 +251,9 @@ class KubernetesServerRunner(base_runner.KubernetesBaseRunner):
                 isinstance(maintenance_port, int)):
             raise TypeError('Port numbers must be integer')
 
+        if secure_mode and not self.enable_workload_identity:
+            raise ValueError('Secure mode requires Workload Identity enabled.')
+
         logger.info(
             'Deploying xDS test server "%s" to k8s namespace %s: test_port=%s '
             'maintenance_port=%s secure_mode=%s server_id=%s replica_count=%s',
@@ -271,19 +281,20 @@ class KubernetesServerRunner(base_runner.KubernetesBaseRunner):
                 test_port=test_port)
         self._wait_service_neg(self.service_name, test_port)
 
-        # Allow Kubernetes service account to use the GCP service account
-        # identity.
-        self._grant_workload_identity_user(
-            gcp_iam=self.gcp_iam,
-            gcp_service_account=self.gcp_service_account,
-            service_account_name=self.service_account_name)
+        if self.enable_workload_identity:
+            # Allow Kubernetes service account to use the GCP service account
+            # identity.
+            self._grant_workload_identity_user(
+                gcp_iam=self.gcp_iam,
+                gcp_service_account=self.gcp_service_account,
+                service_account_name=self.service_account_name)
 
-        # Create service account
-        self.service_account = self._create_service_account(
-            self.service_account_template,
-            service_account_name=self.service_account_name,
-            namespace_name=self.k8s_namespace.name,
-            gcp_service_account=self.gcp_service_account)
+            # Create service account
+            self.service_account = self._create_service_account(
+                self.service_account_template,
+                service_account_name=self.service_account_name,
+                namespace_name=self.k8s_namespace.name,
+                gcp_service_account=self.gcp_service_account)
 
         # Always create a new deployment
         self.deployment = self._create_deployment(
@@ -351,7 +362,7 @@ class KubernetesServerRunner(base_runner.KubernetesBaseRunner):
         if (self.service and not self.reuse_service) or force:
             self._delete_service(self.service_name)
             self.service = None
-        if self.service_account or force:
+        if self.enable_workload_identity and (self.service_account or force):
             self._revoke_workload_identity_user(
                 gcp_iam=self.gcp_iam,
                 gcp_service_account=self.gcp_service_account,
index 801c83a..e259de8 100644 (file)
@@ -41,9 +41,12 @@ DEBUG_USE_PORT_FORWARDING = flags.DEFINE_bool(
     "debug_use_port_forwarding",
     default=False,
     help="Development only: use kubectl port-forward to connect to test app")
+ENABLE_WORKLOAD_IDENTITY = flags.DEFINE_bool(
+    "enable_workload_identity",
+    default=True,
+    help="Enable the WorkloadIdentity feature")
 
 flags.mark_flags_as_required([
-    "gcp_service_account",
     "kube_context",
     "td_bootstrap_image",
     "server_image",
index 336c82b..0e8bef8 100644 (file)
@@ -114,6 +114,7 @@ class XdsKubernetesTestCase(absltest.TestCase, metaclass=abc.ABCMeta):
         cls.force_cleanup = _FORCE_CLEANUP.value
         cls.debug_use_port_forwarding = \
             xds_k8s_flags.DEBUG_USE_PORT_FORWARDING.value
+        cls.enable_workload_identity = xds_k8s_flags.ENABLE_WORKLOAD_IDENTITY.value
         cls.check_local_certs = _CHECK_LOCAL_CERTS.value
 
         # Resource managers
@@ -346,7 +347,8 @@ class RegularXdsKubernetesTestCase(XdsKubernetesTestCase):
             gcp_service_account=self.gcp_service_account,
             xds_server_uri=self.xds_server_uri,
             network=self.network,
-            debug_use_port_forwarding=self.debug_use_port_forwarding)
+            debug_use_port_forwarding=self.debug_use_port_forwarding,
+            enable_workload_identity=self.enable_workload_identity)
 
     def initKubernetesClientRunner(self) -> KubernetesClientRunner:
         return KubernetesClientRunner(
@@ -361,6 +363,7 @@ class RegularXdsKubernetesTestCase(XdsKubernetesTestCase):
             xds_server_uri=self.xds_server_uri,
             network=self.network,
             debug_use_port_forwarding=self.debug_use_port_forwarding,
+            enable_workload_identity=self.enable_workload_identity,
             stats_port=self.client_port,
             reuse_namespace=self.server_namespace == self.client_namespace)
 
index 5a3843e..e3240c7 100644 (file)
@@ -145,14 +145,11 @@ class GcpResourceManager(metaclass=_MetaSingletonAndAbslFlags):
         # Pick a client_namespace_suffix if not set
         if self.resource_suffix is None:
             self.resource_suffix = ""
-            self.client_namespace_suffix = framework.helpers.rand.random_resource_suffix(
-            )
         else:
-            self.client_namespace_suffix = self.resource_suffix
-        logging.info(
-            'GcpResourceManager: resource prefix=%s, suffix=%s, client_namespace_suffix=%s',
-            self.resource_prefix, self.resource_suffix,
-            self.client_namespace_suffix)
+            raise NotImplementedError(
+                'Predefined resource_suffix is not supported for UrlMap tests')
+        logging.info('GcpResourceManager: resource prefix=%s, suffix=%s',
+                     self.resource_prefix, self.resource_suffix)
         # API managers
         self.k8s_api_manager = k8s.KubernetesApiManager(self.kube_context)
         self.gcp_api_manager = gcp.api.GcpApiManager()
@@ -166,27 +163,6 @@ class GcpResourceManager(metaclass=_MetaSingletonAndAbslFlags):
         # Kubernetes namespace
         self.k8s_namespace = k8s.KubernetesNamespace(self.k8s_api_manager,
                                                      self.resource_prefix)
-        if self.client_namespace_suffix != self.resource_suffix:
-            self.k8s_client_namespace = k8s.KubernetesNamespace(
-                self.k8s_api_manager,
-                client_app.KubernetesClientRunner.make_namespace_name(
-                    self.resource_prefix, self.client_namespace_suffix))
-        else:
-            self.k8s_client_namespace = self.k8s_namespace
-        # Kubernetes Test Client
-        self.test_client_runner = client_app.KubernetesClientRunner(
-            self.k8s_client_namespace,
-            deployment_name=self.client_name,
-            image_name=self.client_image,
-            gcp_project=self.project,
-            gcp_api_manager=self.gcp_api_manager,
-            gcp_service_account=self.gcp_service_account,
-            td_bootstrap_image=self.td_bootstrap_image,
-            xds_server_uri=self.xds_server_uri,
-            network=self.network,
-            debug_use_port_forwarding=self.debug_use_port_forwarding,
-            stats_port=self.client_port,
-            reuse_namespace=True)
         # Kubernetes Test Servers
         self.test_server_runner = server_app.KubernetesServerRunner(
             self.k8s_namespace,
@@ -197,7 +173,8 @@ class GcpResourceManager(metaclass=_MetaSingletonAndAbslFlags):
             gcp_service_account=self.gcp_service_account,
             td_bootstrap_image=self.td_bootstrap_image,
             xds_server_uri=self.xds_server_uri,
-            network=self.network)
+            network=self.network,
+            enable_workload_identity=self.enable_workload_identity)
         self.test_server_alternative_runner = server_app.KubernetesServerRunner(
             self.k8s_namespace,
             deployment_name=self.server_name + '-alternative',
@@ -208,6 +185,7 @@ class GcpResourceManager(metaclass=_MetaSingletonAndAbslFlags):
             td_bootstrap_image=self.td_bootstrap_image,
             xds_server_uri=self.xds_server_uri,
             network=self.network,
+            enable_workload_identity=self.enable_workload_identity,
             reuse_namespace=True)
         self.test_server_affinity_runner = server_app.KubernetesServerRunner(
             self.k8s_namespace,
@@ -219,17 +197,43 @@ class GcpResourceManager(metaclass=_MetaSingletonAndAbslFlags):
             td_bootstrap_image=self.td_bootstrap_image,
             xds_server_uri=self.xds_server_uri,
             network=self.network,
+            enable_workload_identity=self.enable_workload_identity,
             reuse_namespace=True)
         logging.info('Strategy of GCP resources management: %s', self.strategy)
 
+    def create_test_client_runner(self):
+        if self.resource_suffix:
+            client_namespace_suffix = self.resource_suffix
+        else:
+            client_namespace_suffix = framework.helpers.rand.random_resource_suffix(
+            )
+        logging.info('GcpResourceManager: client_namespace_suffix=%s',
+                     client_namespace_suffix)
+        # Kubernetes Test Client
+        return client_app.KubernetesClientRunner(
+            k8s.KubernetesNamespace(
+                self.k8s_api_manager,
+                client_app.KubernetesClientRunner.make_namespace_name(
+                    self.resource_prefix, client_namespace_suffix)),
+            deployment_name=self.client_name,
+            image_name=self.client_image,
+            gcp_project=self.project,
+            gcp_api_manager=self.gcp_api_manager,
+            gcp_service_account=self.gcp_service_account,
+            td_bootstrap_image=self.td_bootstrap_image,
+            xds_server_uri=self.xds_server_uri,
+            network=self.network,
+            debug_use_port_forwarding=self.debug_use_port_forwarding,
+            enable_workload_identity=self.enable_workload_identity,
+            stats_port=self.client_port)
+
     def _pre_cleanup(self):
         # Cleanup existing debris
         logging.info('GcpResourceManager: pre clean-up')
         self.td.cleanup(force=True)
-        self.test_client_runner.delete_namespace()
         self.test_server_runner.delete_namespace()
 
-    def setup(self, test_case_classes: 'Iterable[XdsUrlMapTestCase]') -> None:
+    def setup(self, test_case_classes: Iterable['XdsUrlMapTestCase']) -> None:
         if self.strategy not in ['create', 'keep']:
             logging.info('GcpResourceManager: skipping setup for strategy [%s]',
                          self.strategy)
@@ -245,16 +249,9 @@ class GcpResourceManager(metaclass=_MetaSingletonAndAbslFlags):
         # Health Checks
         self.td.create_health_check()
         # Backend Services
-        #
-        # The backend services are created with HTTP2 instead of GRPC (the
-        # default) to disable validate-for-proxyless, because the affinity
-        # settings are not accepted by RCTH yet.
-        #
-        # TODO: delete _BackendHTTP2 from the parameters, to use the default
-        # GRPC.
-        self.td.create_backend_service(_BackendHTTP2)
-        self.td.create_alternative_backend_service(_BackendHTTP2)
-        self.td.create_affinity_backend_service(_BackendHTTP2)
+        self.td.create_backend_service()
+        self.td.create_alternative_backend_service()
+        self.td.create_affinity_backend_service()
         # Construct UrlMap from test classes
         aggregator = _UrlMapChangeAggregator(
             url_map_name=self.td.make_resource_name(self.td.URL_MAP_NAME))
@@ -301,11 +298,6 @@ class GcpResourceManager(metaclass=_MetaSingletonAndAbslFlags):
         self.td.wait_for_affinity_backends_healthy_status()
 
     def cleanup(self) -> None:
-        if hasattr(self, 'test_client_runner'):
-            self.test_client_runner.cleanup(
-                force=True,
-                # Clean-up ephemeral client namespace
-                force_namespace=self.k8s_client_namespace != self.k8s_namespace)
         if self.strategy not in ['create']:
             logging.info(
                 'GcpResourceManager: skipping tear down for strategy [%s]',
index a3212e4..7e9dfb6 100644 (file)
@@ -18,6 +18,7 @@ from dataclasses import dataclass
 import datetime
 import json
 import os
+import re
 import sys
 import time
 from typing import Any, Iterable, Mapping, Optional, Tuple, Union
@@ -44,7 +45,9 @@ QPS = flags.DEFINE_integer('qps', default=25, help='The QPS client is sending')
 
 # Test configs
 _URL_MAP_PROPAGATE_TIMEOUT_SEC = 600
-_URL_MAP_PROPAGATE_CHECK_INTERVAL_SEC = 2
+# With the per-run IAM change, the first xDS response has a several minutes
+# delay. We want to increase the interval, reduce the log spam.
+_URL_MAP_PROPAGATE_CHECK_INTERVAL_SEC = 15
 URL_MAP_TESTCASE_FILE_SUFFIX = '_test.py'
 _CLIENT_CONFIGURE_WAIT_SEC = 2
 
@@ -59,6 +62,10 @@ JsonType = Any
 RpcTypeUnaryCall = 'UNARY_CALL'
 RpcTypeEmptyCall = 'EMPTY_CALL'
 
+# All client languages
+_CLIENT_LANGUAGES = ('cpp', 'java', 'go', 'python')
+_SERVER_LANGUAGES = _CLIENT_LANGUAGES
+
 
 def _split_camel(s: str, delimiter: str = '-') -> str:
     """Turn camel case name to snake-case-like name."""
@@ -66,6 +73,10 @@ def _split_camel(s: str, delimiter: str = '-') -> str:
                    for c in s).lstrip(delimiter)
 
 
+def _get_lang(image_name: str) -> str:
+    return re.search(r'/(\w+)-(client|server):', image_name).group(1)
+
+
 class DumpedXdsConfig(dict):
     """A convenience class to check xDS config.
 
@@ -222,6 +233,24 @@ class XdsUrlMapTestCase(absltest.TestCase, metaclass=_MetaXdsUrlMapTestCase):
     """
 
     @staticmethod
+    def supported_clients() -> Tuple[str]:
+        """Declare supported languages of clients.
+
+        Returns:
+          A tuple of strings contains the supported languages for this test.
+        """
+        return _CLIENT_LANGUAGES
+
+    @staticmethod
+    def supported_servers() -> Tuple[str]:
+        """Declare supported languages of servers.
+
+        Returns:
+          A tuple of strings contains the supported languages for this test.
+        """
+        return _SERVER_LANGUAGES
+
+    @staticmethod
     def client_init_config(rpc: str, metadata: str) -> Tuple[str, str]:
         """Updates the initial RPC configs for this test case.
 
@@ -302,12 +331,32 @@ class XdsUrlMapTestCase(absltest.TestCase, metaclass=_MetaXdsUrlMapTestCase):
             # Create the GCP resource once before the first test start
             GcpResourceManager().setup(cls.test_case_classes)
         cls.started_test_cases.add(cls.__name__)
-        # TODO(lidiz) concurrency is possible, pending multiple-instance change
-        GcpResourceManager().test_client_runner.cleanup(force=True)
+
+        # NOTE(lidiz) a manual skip mechanism is needed because absl/flags
+        # cannot be used in the built-in test-skipping decorators. See the
+        # official FAQs:
+        # https://abseil.io/docs/python/guides/flags#faqs
+        client_lang = _get_lang(GcpResourceManager().client_image)
+        server_lang = _get_lang(GcpResourceManager().server_image)
+        if client_lang not in cls.supported_clients():
+            cls.skip_reason = (f'Unsupported client language {client_lang} '
+                               f'not in {cls.supported_clients()}')
+            return
+        elif server_lang not in cls.supported_servers():
+            cls.skip_reason = (f'Unsupported server language {server_lang} '
+                               f'not in {cls.supported_servers()}')
+            return
+        else:
+            cls.skip_reason = None
+
+        # Create the test case's own client runner with it's own namespace,
+        # enables concurrent running with other test cases.
+        cls.test_client_runner = GcpResourceManager().create_test_client_runner(
+        )
         # Start the client, and allow the test to override the initial RPC config.
         rpc, metadata = cls.client_init_config(rpc="UnaryCall,EmptyCall",
                                                metadata="")
-        cls.test_client = GcpResourceManager().test_client_runner.run(
+        cls.test_client = cls.test_client_runner.run(
             server_target=f'xds:///{cls.hostname()}',
             rpc=rpc,
             metadata=metadata,
@@ -316,7 +365,9 @@ class XdsUrlMapTestCase(absltest.TestCase, metaclass=_MetaXdsUrlMapTestCase):
 
     @classmethod
     def tearDownClass(cls):
-        GcpResourceManager().test_client_runner.cleanup(force=True)
+        if cls.skip_reason is None:
+            # Clean up related resources for the client
+            cls.test_client_runner.cleanup(force=True, force_namespace=True)
         cls.finished_test_cases.add(cls.__name__)
         if cls.finished_test_cases == cls.test_case_names:
             # Tear down the GCP resource after all tests finished
@@ -331,17 +382,8 @@ class XdsUrlMapTestCase(absltest.TestCase, metaclass=_MetaXdsUrlMapTestCase):
         self.assertIsNotNone(config)
         # Found client config, test it.
         self._xds_json_config = json_format.MessageToDict(config)
-        try:
-            self.xds_config_validate(DumpedXdsConfig(self._xds_json_config))
-        except Exception as e:
-            # Log the exception for debugging purposes.
-            if type(self._last_xds_config_exception) != type(e) or str(
-                    self._last_xds_config_exception) != str(e):
-                # Suppress repetitive exception logs
-                logging.exception(e)
-                self._last_xds_config_exception = e
-            raise
-        return
+        # Execute the child class provided validation logic
+        self.xds_config_validate(DumpedXdsConfig(self._xds_json_config))
 
     def run(self, result: unittest.TestResult = None) -> None:
         """Abort this test case if CSDS check is failed.
@@ -355,7 +397,9 @@ class XdsUrlMapTestCase(absltest.TestCase, metaclass=_MetaXdsUrlMapTestCase):
             super().run(result)
 
     def test_client_config(self):
-        self._last_xds_config_exception = None
+        if self.skip_reason:
+            logging.info('Skipping: %s', self.skip_reason)
+            self.skipTest(self.skip_reason)
         retryer = retryers.constant_retryer(
             wait_fixed=datetime.timedelta(
                 seconds=_URL_MAP_PROPAGATE_CHECK_INTERVAL_SEC),
@@ -371,6 +415,9 @@ class XdsUrlMapTestCase(absltest.TestCase, metaclass=_MetaXdsUrlMapTestCase):
                     self._xds_json_config))
 
     def test_rpc_distribution(self):
+        if self.skip_reason:
+            logging.info('Skipping: %s', self.skip_reason)
+            self.skipTest(self.skip_reason)
         self.rpc_distribution_validate(self.test_client)
 
     @staticmethod
index 109086c..31ef54f 100644 (file)
@@ -18,7 +18,9 @@ spec:
         app: ${deployment_name}
         owner: xds-k8s-interop-test
     spec:
+      % if service_account_name:
       serviceAccountName: ${service_account_name}
+      % endif
       containers:
       - name: ${deployment_name}
         image: ${image_name}
index dbf2fa5..04f0cd6 100644 (file)
@@ -18,7 +18,9 @@ spec:
         app: ${deployment_name}
         owner: xds-k8s-interop-test
     spec:
+      % if service_account_name:
       serviceAccountName: ${service_account_name}
+      % endif
       containers:
       - name: ${deployment_name}
         image: ${image_name}
diff --git a/tools/run_tests/xds_k8s_test_driver/tests/affinity_test.py b/tools/run_tests/xds_k8s_test_driver/tests/affinity_test.py
new file mode 100644 (file)
index 0000000..bc93c6c
--- /dev/null
@@ -0,0 +1,158 @@
+# Copyright 2021 gRPC authors.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+import logging
+import time
+from typing import List, Optional
+
+from absl import flags
+from absl.testing import absltest
+from google.protobuf import json_format
+
+from framework import xds_k8s_testcase
+from framework import xds_url_map_testcase
+from framework.helpers import retryers
+from framework.infrastructure import k8s
+from framework.rpc import grpc_channelz
+from framework.test_app import server_app
+
+logger = logging.getLogger(__name__)
+flags.adopt_module_key_flags(xds_k8s_testcase)
+
+# Type aliases
+_XdsTestServer = xds_k8s_testcase.XdsTestServer
+_XdsTestClient = xds_k8s_testcase.XdsTestClient
+_ChannelzChannelState = grpc_channelz.ChannelState
+
+# Testing consts
+_TEST_AFFINITY_METADATA_KEY = 'xds_md'
+_TD_PROPAGATE_CHECK_INTERVAL_SEC = 10
+_TD_PROPAGATE_TIMEOUT = 600
+_REPLICA_COUNT = 3
+_RPC_COUNT = 100
+
+
+class AffinityTest(xds_k8s_testcase.RegularXdsKubernetesTestCase):
+
+    def test_affinity(self) -> None:
+
+        with self.subTest('00_create_health_check'):
+            self.td.create_health_check()
+
+        with self.subTest('01_create_backend_services'):
+            self.td.create_backend_service(
+                affinity_header=_TEST_AFFINITY_METADATA_KEY)
+
+        with self.subTest('02_create_url_map'):
+            self.td.create_url_map(self.server_xds_host, self.server_xds_port)
+
+        with self.subTest('03_create_target_proxy'):
+            self.td.create_target_proxy()
+
+        with self.subTest('04_create_forwarding_rule'):
+            self.td.create_forwarding_rule(self.server_xds_port)
+
+        with self.subTest('05_start_test_servers'):
+            self.test_servers: List[_XdsTestServer] = self.startTestServers(
+                replica_count=_REPLICA_COUNT)
+
+        with self.subTest('06_add_server_backends_to_backend_services'):
+            self.setupServerBackends()
+
+        with self.subTest('07_start_test_client'):
+            self.test_client: _XdsTestClient = self.startTestClient(
+                self.test_servers[0],
+                rpc='EmptyCall',
+                metadata='EmptyCall:%s:123' % _TEST_AFFINITY_METADATA_KEY)
+            # Validate the number of received endpoints and affinity configs.
+            config = self.test_client.csds.fetch_client_status(
+                log_level=logging.INFO)
+            self.assertIsNotNone(config)
+            json_config = json_format.MessageToDict(config)
+            parsed = xds_url_map_testcase.DumpedXdsConfig(json_config)
+            logging.info('Client received CSDS response: %s', parsed)
+            self.assertLen(parsed.endpoints, _REPLICA_COUNT)
+            self.assertEqual(
+                parsed.rds['virtualHosts'][0]['routes'][0]['route']
+                ['hashPolicy'][0]['header']['headerName'],
+                _TEST_AFFINITY_METADATA_KEY)
+            self.assertEqual(parsed.cds[0]['lbPolicy'], 'RING_HASH')
+
+        with self.subTest('08_test_client_xds_config_exists'):
+            self.assertXdsConfigExists(self.test_client)
+
+        with self.subTest('09_test_server_received_rpcs_from_test_client'):
+            self.assertSuccessfulRpcs(self.test_client)
+
+        with self.subTest('10_first_100_affinity_rpcs_pick_same_backend'):
+            rpc_stats = self.getClientRpcStats(self.test_client, _RPC_COUNT)
+            json_lb_stats = json_format.MessageToDict(rpc_stats)
+            rpc_distribution = xds_url_map_testcase.RpcDistributionStats(
+                json_lb_stats)
+            self.assertEqual(1, rpc_distribution.num_peers)
+            self.assertLen(
+                self.test_client.find_subchannels_with_state(
+                    _ChannelzChannelState.READY),
+                1,
+            )
+            self.assertLen(
+                self.test_client.find_subchannels_with_state(
+                    _ChannelzChannelState.IDLE),
+                2,
+            )
+            # Remember the backend inuse, and turn it down later.
+            self.first_backend_inuse = list(
+                rpc_distribution.raw['rpcsByPeer'].keys())[0]
+
+        with self.subTest('11_turn_down_server_in_use'):
+            for s in self.test_servers:
+                if s.pod_name == self.first_backend_inuse:
+                    logging.info('setting backend %s to NOT_SERVING',
+                                 s.pod_name)
+                    s.set_not_serving()
+
+        with self.subTest('12_wait_for_unhealth_status_propagation'):
+            deadline = time.time() + _TD_PROPAGATE_TIMEOUT
+            parsed = None
+            try:
+                while time.time() < deadline:
+                    config = self.test_client.csds.fetch_client_status(
+                        log_level=logging.INFO)
+                    self.assertIsNotNone(config)
+                    json_config = json_format.MessageToDict(config)
+                    parsed = xds_url_map_testcase.DumpedXdsConfig(json_config)
+                    if len(parsed.endpoints) == _REPLICA_COUNT - 1:
+                        break
+                    logging.info(
+                        'CSDS got unexpected endpoints, will retry after %d seconds',
+                        _TD_PROPAGATE_CHECK_INTERVAL_SEC)
+                    time.sleep(_TD_PROPAGATE_CHECK_INTERVAL_SEC)
+                else:
+                    self.fail(
+                        'unhealthy status did not propagate after 600 seconds')
+            finally:
+                logging.info('Client received CSDS response: %s', parsed)
+
+        with self.subTest('12_next_100_affinity_rpcs_pick_different_backend'):
+            rpc_stats = self.getClientRpcStats(self.test_client, _RPC_COUNT)
+            json_lb_stats = json_format.MessageToDict(rpc_stats)
+            rpc_distribution = xds_url_map_testcase.RpcDistributionStats(
+                json_lb_stats)
+            self.assertEqual(1, rpc_distribution.num_peers)
+            new_backend_inuse = list(
+                rpc_distribution.raw['rpcsByPeer'].keys())[0]
+            self.assertNotEqual(new_backend_inuse, self.first_backend_inuse)
+
+
+if __name__ == '__main__':
+    absltest.main(failfast=True)
index 68a05c8..8c31cfb 100644 (file)
@@ -42,7 +42,8 @@ class AppNetTest(xds_k8s_testcase.AppNetXdsKubernetesTestCase):
             self.td.create_router()
 
         with self.subTest('4_start_test_server'):
-            test_server: _XdsTestServer = self.startTestServer()
+            test_server: _XdsTestServer = self.startTestServers(
+                replica_count=1)[0]
 
         with self.subTest('5_setup_server_backends'):
             self.setupServerBackends()
diff --git a/tools/run_tests/xds_k8s_test_driver/tests/subsetting_test.py b/tools/run_tests/xds_k8s_test_driver/tests/subsetting_test.py
new file mode 100644 (file)
index 0000000..2b65224
--- /dev/null
@@ -0,0 +1,104 @@
+# Copyright 2021 The gRPC Authors
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+import collections
+from typing import List, Optional
+
+from absl import flags
+from absl import logging
+from absl.testing import absltest
+from google.protobuf import json_format
+
+from framework import xds_k8s_testcase
+from framework import xds_url_map_testcase
+from framework.infrastructure import k8s
+from framework.test_app import server_app
+
+flags.adopt_module_key_flags(xds_k8s_testcase)
+
+# Type aliases
+_XdsTestServer = xds_k8s_testcase.XdsTestServer
+_XdsTestClient = xds_k8s_testcase.XdsTestClient
+
+_SUBSET_SIZE = 4
+_NUM_BACKENDS = 8
+_NUM_CLIENTS = 3
+
+
+class SubsettingTest(xds_k8s_testcase.RegularXdsKubernetesTestCase):
+
+    def test_subsetting_basic(self) -> None:
+        with self.subTest('00_create_health_check'):
+            self.td.create_health_check()
+
+        with self.subTest('01_create_backend_services'):
+            self.td.create_backend_service(subset_size=_SUBSET_SIZE)
+
+        with self.subTest('02_create_url_map'):
+            self.td.create_url_map(self.server_xds_host, self.server_xds_port)
+
+        with self.subTest('03_create_target_proxy'):
+            self.td.create_target_proxy()
+
+        with self.subTest('04_create_forwarding_rule'):
+            self.td.create_forwarding_rule(self.server_xds_port)
+
+        with self.subTest('05_start_test_servers'):
+            self.test_servers: List[_XdsTestServer] = self.startTestServers(
+                replica_count=_NUM_BACKENDS)
+
+        with self.subTest('06_add_server_backends_to_backend_services'):
+            self.setupServerBackends()
+
+        rpc_distribution = collections.defaultdict(int)
+        with self.subTest('07_start_test_client'):
+            for i in range(_NUM_CLIENTS):
+                # Clean created client pods if there is any
+                self.client_runner.cleanup(force=True)
+                # Create a test client
+                test_client: _XdsTestClient = self.startTestClient(
+                    self.test_servers[0])
+                # Validate the number of received endpoints
+                config = test_client.csds.fetch_client_status(
+                    log_level=logging.INFO)
+                self.assertIsNotNone(config)
+                json_config = json_format.MessageToDict(config)
+                parsed = xds_url_map_testcase.DumpedXdsConfig(json_config)
+                logging.info('Client %d received endpoints (len=%s): %s', i,
+                             len(parsed.endpoints), parsed.endpoints)
+                self.assertLen(parsed.endpoints, _SUBSET_SIZE)
+                # Record RPC stats
+                lb_stats = self.getClientRpcStats(test_client,
+                                                  _NUM_BACKENDS * 25)
+                for key, value in lb_stats.rpcs_by_peer.items():
+                    rpc_distribution[key] += value
+
+        with self.subTest('08_log_rpc_distribution'):
+            server_entries = sorted(rpc_distribution.items(),
+                                    key=lambda x: -x[1])
+            # Validate if clients are receiving different sets of backends (3
+            # client received a total of 4 unique backends == FAIL, a total of 5
+            # unique backends == PASS)
+            self.assertGreater(len(server_entries), _SUBSET_SIZE)
+            logging.info('RPC distribution (len=%s): %s', len(server_entries),
+                         server_entries)
+            peak = server_entries[0][1]
+            mean = sum(map(lambda x: x[1],
+                           server_entries)) / len(server_entries)
+            logging.info('Peak=%d Mean=%.1f Peak-to-Mean-Ratio=%.2f', peak,
+                         mean, peak / mean)
+
+
+if __name__ == '__main__':
+    absltest.main(failfast=True)
index d8caf0c..fdbad45 100644 (file)
@@ -53,12 +53,13 @@ _TEST_METADATA = (
 _ChannelzChannelState = grpc_channelz.ChannelState
 
 
-@absltest.skipUnless('cpp-client' in xds_k8s_flags.CLIENT_IMAGE.value or \
-                     'java-client' in xds_k8s_flags.CLIENT_IMAGE.value,
-                     'Affinity is currently only implemented in C++ and Java.')
 class TestHeaderBasedAffinity(xds_url_map_testcase.XdsUrlMapTestCase):
 
     @staticmethod
+    def supported_clients() -> Tuple[str]:
+        return 'cpp', 'java'
+
+    @staticmethod
     def client_init_config(rpc: str, metadata: str):
         # Config the init RPCs to send with the same set of metadata. Without
         # this, the init RPCs will not have headers, and will pick random
@@ -116,13 +117,14 @@ class TestHeaderBasedAffinity(xds_url_map_testcase.XdsUrlMapTestCase):
         )
 
 
-@absltest.skipUnless('cpp-client' in xds_k8s_flags.CLIENT_IMAGE.value or \
-                     'java-client' in xds_k8s_flags.CLIENT_IMAGE.value,
-                     'Affinity is currently only implemented in C++ and Java.')
 class TestHeaderBasedAffinityMultipleHeaders(
         xds_url_map_testcase.XdsUrlMapTestCase):
 
     @staticmethod
+    def supported_clients() -> Tuple[str]:
+        return 'cpp', 'java'
+
+    @staticmethod
     def client_init_config(rpc: str, metadata: str):
         # Config the init RPCs to send with the same set of metadata. Without
         # this, the init RPCs will not have headers, and will pick random
@@ -215,3 +217,6 @@ class TestHeaderBasedAffinityMultipleHeaders(
 # TODO: add more test cases
 # 1. based on the basic test, turn down the backend in use, then verify that all
 #    RPCs are sent to another backend
+
+if __name__ == '__main__':
+    absltest.main()
index 8f61b10..ab0a2c6 100644 (file)
@@ -63,12 +63,13 @@ def _build_retry_route_rule(retryConditions, num_retries):
     }
 
 
-@absltest.skipUnless('cpp-client' in xds_k8s_flags.CLIENT_IMAGE.value or \
-                     'java-client' in xds_k8s_flags.CLIENT_IMAGE.value,
-                     'Xds-retry is currently only implemented in C++ and Java.')
 class TestRetryUpTo3AttemptsAndFail(xds_url_map_testcase.XdsUrlMapTestCase):
 
     @staticmethod
+    def supported_clients() -> Tuple[str]:
+        return 'cpp', 'java'
+
+    @staticmethod
     def url_map_change(
             host_rule: HostRule,
             path_matcher: PathMatcher) -> Tuple[HostRule, PathMatcher]:
@@ -101,12 +102,13 @@ class TestRetryUpTo3AttemptsAndFail(xds_url_map_testcase.XdsUrlMapTestCase):
                                  tolerance=_NON_RANDOM_ERROR_TOLERANCE)
 
 
-@absltest.skipUnless('cpp-client' in xds_k8s_flags.CLIENT_IMAGE.value or \
-                     'java-client' in xds_k8s_flags.CLIENT_IMAGE.value,
-                     'Xds-retry is currently only implemented in C++ Java.')
 class TestRetryUpTo4AttemptsAndSucceed(xds_url_map_testcase.XdsUrlMapTestCase):
 
     @staticmethod
+    def supported_clients() -> Tuple[str]:
+        return 'cpp', 'java'
+
+    @staticmethod
     def url_map_change(
             host_rule: HostRule,
             path_matcher: PathMatcher) -> Tuple[HostRule, PathMatcher]:
index 4f639bd..dd81306 100644 (file)
@@ -78,12 +78,14 @@ class _BaseXdsTimeOutTestCase(XdsUrlMapTestCase):
         raise NotImplementedError()
 
 
-# TODO(lidiz) either add support for rpc-behavior to other languages, or we
-# should always use Java server as backend.
-@absltest.skipUnless('java-server' in xds_k8s_flags.SERVER_IMAGE.value,
-                     'Only Java server supports the rpc-behavior metadata.')
 class TestTimeoutInRouteRule(_BaseXdsTimeOutTestCase):
 
+    @staticmethod
+    def supported_servers() -> Tuple[str]:
+        # TODO(lidiz) either add support for rpc-behavior to other languages, or we
+        # should always use Java server as backend.
+        return 'java',
+
     def rpc_distribution_validate(self, test_client: XdsTestClient):
         rpc_distribution = self.configure_and_send(
             test_client,
@@ -107,10 +109,12 @@ class TestTimeoutInRouteRule(_BaseXdsTimeOutTestCase):
             tolerance=_ERROR_TOLERANCE)
 
 
-@absltest.skipUnless('java-server' in xds_k8s_flags.SERVER_IMAGE.value,
-                     'Only Java server supports the rpc-behavior metadata.')
 class TestTimeoutInApplication(_BaseXdsTimeOutTestCase):
 
+    @staticmethod
+    def supported_servers() -> Tuple[str]:
+        return 'java',
+
     def rpc_distribution_validate(self, test_client: XdsTestClient):
         rpc_distribution = self.configure_and_send(
             test_client,